index.haml 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106
  1. -# coding: utf-8
  2. .inner-wrap
  3. .fixed
  4. %nav.top-bar
  5. %ul.title-area
  6. %li.name
  7. %h1
  8. %a{href: "#"} rSeed
  9. %li.toggle-topbar.menu-icon
  10. %a{href: "#"}
  11. %span Menu
  12. %section.top-bar-section
  13. %ul.right
  14. %li
  15. %a
  16. %span.disk-info
  17. %span.disk-bar
  18. %span.inner-bar
  19. %span.text-info
  20. %li.divider
  21. %li.has-form
  22. %a.button.radius.success
  23. %i.fi-arrow-up
  24. %strong#up-info
  25. %li.divider
  26. %li.has-form
  27. %a.button.radius
  28. %i.fi-arrow-down
  29. %strong#down-info
  30. %ul.left
  31. %li
  32. %a.button.radius.alert{href: "", data:{reveal_id: "addModal"}} Add
  33. %section.main-section{style: "margin: 60px 20px 0 20px"}
  34. %table{style: "width: 100%;"}
  35. %thead
  36. %tr
  37. %th Torrent
  38. %th Ratio
  39. %th Upload
  40. %th Download
  41. %th Actions
  42. %tbody
  43. - tlist.each do |t|
  44. %tr{data: {:torrent_id => "#{t["hash"]}"}}
  45. %td.name
  46. #{t["name"]}
  47. %span.space.label.secondary.round.right
  48. %td.text-center.ratio
  49. %td.text-center.upspeed
  50. %td.text-center.downspeed
  51. %td.text-center
  52. %a.share-torrent{data: {:torrent_id => "#{t["hash"][0,10]}"} }
  53. %i.fi-cloud
  54. |
  55. %a.del-torrent{data: {:torrent_id => "#{t["hash"][0,10]}"} }
  56. %i.fi-trash
  57. #addModal.reveal-modal.medium{"data-reveal" => ""}
  58. %h2 Add a torrent
  59. %dl.sub-nav{"data-tab" => ""}
  60. %dd.active
  61. %a{href: "#panel-link"} Link
  62. %dd
  63. %a{href: "#panel-file"} File
  64. %dd
  65. %a{href: "#panel-search"} Search Engine
  66. .tabs-content
  67. #panel-link.content.active{style: "width: 100%;"}
  68. %form#form-add-link{data: {:abide => ""}, action: "/add/link"}
  69. .row
  70. .large-12.columns
  71. %input{type: "text", name: "link", required: "", pattern: "url", placeholder: "Link to .torrent (http, https, ftp and magnet)"}
  72. %small.error URL not valid !
  73. .panel.radius
  74. %p HTTP, HTTPS, FTP and Magnet are natively supported by rTorrent.
  75. %p For the moment we use the native feature of rTorrent.
  76. %p rTorrent doesn't support self-signed cert (for HTTPS).
  77. %p To use Magnet link be sure DHT is activated in your .rtorrent.rc
  78. #panel-file.content
  79. %form#form-add-file{action: "/"}
  80. .row
  81. .large-12.columns
  82. %input{type: "file"}
  83. .large-12.columns
  84. %input{type: "submit", value: "Send .torrent"}
  85. #panel-search.content
  86. %form#search-engine{action: "/"}
  87. .row
  88. .large-12.columns
  89. %input{type: "text", placeholder: "Search for a torrent :)"}
  90. #search-results
  91. %a.close-reveal-modal ×
  92. #shareModal.reveal-modal.small{"data-reveal" => ""}
  93. %h3 Share your download !
  94. %p Here is the public link for :
  95. %strong.share-torrent-name.text-center torrent-name-here
  96. %input.share-torrent-link{type: "text", value: "torrent-public-link-here"}
  97. %a.close-reveal-modal ×
  98. %script{:src => '/js/vendor/jquery.js'}
  99. %script{:src => '/js/foundation.min.js'}
  100. %script{:src => '/js/alertify.min.js'}
  101. %script{:src => '/js/custom.js'}
  102. %script
  103. $(document).foundation();