adminlte_rails 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (324) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +8 -0
  3. data/.travis.yml +5 -0
  4. data/CODE_OF_CONDUCT.md +74 -0
  5. data/Gemfile +6 -0
  6. data/LICENSE.txt +21 -0
  7. data/README.md +51 -0
  8. data/Rakefile +10 -0
  9. data/adminlte_rails.gemspec +27 -0
  10. data/bin/console +14 -0
  11. data/bin/setup +8 -0
  12. data/lib/adminlte_rails.rb +5 -0
  13. data/lib/adminlte_rails/engine.rb +7 -0
  14. data/lib/adminlte_rails/version.rb +3 -0
  15. data/vendor/assets/javascripts/adminlte.js +3 -0
  16. data/vendor/assets/javascripts/adminlte.min.js +3 -0
  17. data/vendor/assets/javascripts/adminlte/adminlte.js +1129 -0
  18. data/vendor/assets/javascripts/adminlte/adminlte.min.js +14 -0
  19. data/vendor/assets/javascripts/adminlte/plugins/bootstrap-colorpicker/bootstrap-colorpicker.js +1319 -0
  20. data/vendor/assets/javascripts/adminlte/plugins/bootstrap-colorpicker/bootstrap-colorpicker.min.js +5 -0
  21. data/vendor/assets/javascripts/adminlte/plugins/bootstrap-datepicker/bootstrap-datepicker.js +2030 -0
  22. data/vendor/assets/javascripts/adminlte/plugins/bootstrap-datepicker/bootstrap-datepicker.min.js +8 -0
  23. data/vendor/assets/javascripts/adminlte/plugins/bootstrap-daterangepicker/bootstrap-daterangepicker.js +1653 -0
  24. data/vendor/assets/javascripts/adminlte/plugins/bootstrap-slider/bootstrap-slider.js +427 -0
  25. data/vendor/assets/javascripts/adminlte/plugins/bootstrap-timepicker/bootstrap-timepicker.js +1177 -0
  26. data/vendor/assets/javascripts/adminlte/plugins/bootstrap/bootstrap.js +2377 -0
  27. data/vendor/assets/javascripts/adminlte/plugins/bootstrap/bootstrap.min.js +7 -0
  28. data/vendor/assets/javascripts/adminlte/plugins/jquery/jquery.js +10364 -0
  29. data/vendor/assets/javascripts/adminlte/plugins/jquery/jquery.min.js +2 -0
  30. data/vendor/assets/javascripts/adminlte/plugins/select2/.bower.json +24 -0
  31. data/vendor/assets/javascripts/adminlte/plugins/select2/.editorconfig +6 -0
  32. data/vendor/assets/javascripts/adminlte/plugins/select2/.github/CONTRIBUTING.md +203 -0
  33. data/vendor/assets/javascripts/adminlte/plugins/select2/.github/ISSUE_TEMPLATE.md +20 -0
  34. data/vendor/assets/javascripts/adminlte/plugins/select2/.github/PULL_REQUEST_TEMPLATE.md +13 -0
  35. data/vendor/assets/javascripts/adminlte/plugins/select2/.gitignore +3 -0
  36. data/vendor/assets/javascripts/adminlte/plugins/select2/.jshintignore +4 -0
  37. data/vendor/assets/javascripts/adminlte/plugins/select2/.jshintrc +25 -0
  38. data/vendor/assets/javascripts/adminlte/plugins/select2/.travis.yml +22 -0
  39. data/vendor/assets/javascripts/adminlte/plugins/select2/CHANGELOG.md +272 -0
  40. data/vendor/assets/javascripts/adminlte/plugins/select2/Gruntfile.js +380 -0
  41. data/vendor/assets/javascripts/adminlte/plugins/select2/LICENSE.md +21 -0
  42. data/vendor/assets/javascripts/adminlte/plugins/select2/README.md +123 -0
  43. data/vendor/assets/javascripts/adminlte/plugins/select2/bower.json +13 -0
  44. data/vendor/assets/javascripts/adminlte/plugins/select2/component.json +19 -0
  45. data/vendor/assets/javascripts/adminlte/plugins/select2/composer.json +25 -0
  46. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/css/select2.css +484 -0
  47. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/css/select2.min.css +1 -0
  48. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/af.js +3 -0
  49. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/ar.js +3 -0
  50. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/az.js +3 -0
  51. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/bg.js +3 -0
  52. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/bs.js +3 -0
  53. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/ca.js +3 -0
  54. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/cs.js +3 -0
  55. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/da.js +3 -0
  56. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/de.js +3 -0
  57. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/dsb.js +3 -0
  58. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/el.js +3 -0
  59. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/en.js +3 -0
  60. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/es.js +3 -0
  61. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/et.js +3 -0
  62. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/eu.js +3 -0
  63. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/fa.js +3 -0
  64. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/fi.js +3 -0
  65. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/fr.js +3 -0
  66. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/gl.js +3 -0
  67. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/he.js +3 -0
  68. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/hi.js +3 -0
  69. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/hr.js +3 -0
  70. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/hsb.js +3 -0
  71. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/hu.js +3 -0
  72. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/hy.js +3 -0
  73. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/id.js +3 -0
  74. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/is.js +3 -0
  75. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/it.js +3 -0
  76. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/ja.js +3 -0
  77. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/km.js +3 -0
  78. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/ko.js +3 -0
  79. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/lt.js +3 -0
  80. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/lv.js +3 -0
  81. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/mk.js +3 -0
  82. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/ms.js +3 -0
  83. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/nb.js +3 -0
  84. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/nl.js +3 -0
  85. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/pl.js +3 -0
  86. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/ps.js +3 -0
  87. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/pt-BR.js +3 -0
  88. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/pt.js +3 -0
  89. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/ro.js +3 -0
  90. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/ru.js +3 -0
  91. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/sk.js +3 -0
  92. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/sl.js +3 -0
  93. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/sr-Cyrl.js +3 -0
  94. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/sr.js +3 -0
  95. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/sv.js +3 -0
  96. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/th.js +3 -0
  97. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/tr.js +3 -0
  98. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/uk.js +3 -0
  99. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/vi.js +3 -0
  100. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/zh-CN.js +3 -0
  101. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/i18n/zh-TW.js +3 -0
  102. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/select2.full.js +6457 -0
  103. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/select2.full.min.js +1 -0
  104. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/select2.js +5746 -0
  105. data/vendor/assets/javascripts/adminlte/plugins/select2/dist/js/select2.min.js +1 -0
  106. data/vendor/assets/javascripts/adminlte/plugins/select2/docs/README.md +1 -0
  107. data/vendor/assets/javascripts/adminlte/plugins/select2/docs/announcements-4.0.html +12 -0
  108. data/vendor/assets/javascripts/adminlte/plugins/select2/docs/community.html +12 -0
  109. data/vendor/assets/javascripts/adminlte/plugins/select2/docs/examples.html +12 -0
  110. data/vendor/assets/javascripts/adminlte/plugins/select2/docs/index.html +12 -0
  111. data/vendor/assets/javascripts/adminlte/plugins/select2/docs/options-old.html +12 -0
  112. data/vendor/assets/javascripts/adminlte/plugins/select2/docs/options.html +12 -0
  113. data/vendor/assets/javascripts/adminlte/plugins/select2/package.json +73 -0
  114. data/vendor/assets/javascripts/adminlte/plugins/select2/select2.jquery.json +32 -0
  115. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/banner.end.js +6 -0
  116. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/banner.start.js +6 -0
  117. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/jquery.mousewheel.shim.js +6 -0
  118. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/jquery.select2.js +57 -0
  119. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/jquery.shim.js +14 -0
  120. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/compat/containerCss.js +56 -0
  121. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/compat/dropdownCss.js +56 -0
  122. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/compat/initSelection.js +42 -0
  123. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/compat/inputData.js +127 -0
  124. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/compat/matcher.js +42 -0
  125. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/compat/query.js +26 -0
  126. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/compat/utils.js +43 -0
  127. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/core.js +612 -0
  128. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/data/ajax.js +109 -0
  129. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/data/array.js +79 -0
  130. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/data/base.js +40 -0
  131. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/data/maximumInputLength.js +31 -0
  132. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/data/maximumSelectionLength.js +31 -0
  133. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/data/minimumInputLength.js +30 -0
  134. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/data/select.js +285 -0
  135. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/data/tags.js +128 -0
  136. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/data/tokenizer.js +116 -0
  137. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/defaults.js +396 -0
  138. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/diacritics.js +847 -0
  139. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/dropdown.js +42 -0
  140. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/dropdown/attachBody.js +222 -0
  141. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/dropdown/attachContainer.js +18 -0
  142. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/dropdown/closeOnSelect.js +35 -0
  143. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/dropdown/hidePlaceholder.js +42 -0
  144. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/dropdown/infiniteScroll.js +89 -0
  145. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/dropdown/minimumResultsForSearch.js +39 -0
  146. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/dropdown/search.js +101 -0
  147. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/dropdown/selectOnClose.js +50 -0
  148. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/dropdown/stopPropagation.js +38 -0
  149. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/af.js +44 -0
  150. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/ar.js +30 -0
  151. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/az.js +27 -0
  152. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/bg.js +47 -0
  153. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/bs.js +55 -0
  154. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/ca.js +52 -0
  155. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/cs.js +61 -0
  156. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/da.js +36 -0
  157. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/de.js +40 -0
  158. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/dsb.js +48 -0
  159. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/el.js +52 -0
  160. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/en.js +44 -0
  161. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/es.js +52 -0
  162. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/et.js +53 -0
  163. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/eu.js +51 -0
  164. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/fa.js +38 -0
  165. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/fi.js +30 -0
  166. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/fr.js +33 -0
  167. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/gl.js +39 -0
  168. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/he.js +56 -0
  169. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/hi.js +39 -0
  170. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/hr.js +44 -0
  171. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/hsb.js +48 -0
  172. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/hu.js +30 -0
  173. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/hy.js +38 -0
  174. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/id.js +30 -0
  175. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/is.js +41 -0
  176. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/it.js +48 -0
  177. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/ja.js +36 -0
  178. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/km.js +36 -0
  179. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/ko.js +36 -0
  180. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/lt.js +52 -0
  181. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/lv.js +51 -0
  182. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/mk.js +47 -0
  183. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/ms.js +30 -0
  184. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/nb.js +32 -0
  185. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/nl.js +43 -0
  186. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/pl.js +45 -0
  187. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/ps.js +45 -0
  188. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/pt-BR.js +46 -0
  189. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/pt.js +40 -0
  190. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/ro.js +46 -0
  191. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/ru.js +58 -0
  192. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/sk.js +59 -0
  193. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/sl.js +54 -0
  194. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/sr-Cyrl.js +55 -0
  195. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/sr.js +55 -0
  196. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/sv.js +37 -0
  197. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/th.js +36 -0
  198. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/tr.js +36 -0
  199. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/uk.js +43 -0
  200. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/vi.js +37 -0
  201. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/zh-CN.js +36 -0
  202. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/i18n/zh-TW.js +33 -0
  203. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/keys.js +25 -0
  204. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/options.js +122 -0
  205. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/results.js +523 -0
  206. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/selection/allowClear.js +97 -0
  207. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/selection/base.js +158 -0
  208. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/selection/clickMask.js +29 -0
  209. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/selection/eventRelay.js +45 -0
  210. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/selection/multiple.js +109 -0
  211. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/selection/placeholder.js +49 -0
  212. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/selection/search.js +222 -0
  213. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/selection/single.js +99 -0
  214. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/selection/stopPropagation.js +38 -0
  215. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/translation.js +36 -0
  216. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/select2/utils.js +276 -0
  217. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/wrapper.end.js +12 -0
  218. data/vendor/assets/javascripts/adminlte/plugins/select2/src/js/wrapper.start.js +38 -0
  219. data/vendor/assets/javascripts/adminlte/plugins/select2/src/scss/_dropdown.scss +73 -0
  220. data/vendor/assets/javascripts/adminlte/plugins/select2/src/scss/_multiple.scss +35 -0
  221. data/vendor/assets/javascripts/adminlte/plugins/select2/src/scss/_single.scss +34 -0
  222. data/vendor/assets/javascripts/adminlte/plugins/select2/src/scss/core.scss +48 -0
  223. data/vendor/assets/javascripts/adminlte/plugins/select2/src/scss/mixins/_gradients.scss +13 -0
  224. data/vendor/assets/javascripts/adminlte/plugins/select2/src/scss/theme/classic/_defaults.scss +34 -0
  225. data/vendor/assets/javascripts/adminlte/plugins/select2/src/scss/theme/classic/_multiple.scss +93 -0
  226. data/vendor/assets/javascripts/adminlte/plugins/select2/src/scss/theme/classic/_single.scss +124 -0
  227. data/vendor/assets/javascripts/adminlte/plugins/select2/src/scss/theme/classic/layout.scss +64 -0
  228. data/vendor/assets/javascripts/adminlte/plugins/select2/src/scss/theme/default/_multiple.scss +98 -0
  229. data/vendor/assets/javascripts/adminlte/plugins/select2/src/scss/theme/default/_single.scss +83 -0
  230. data/vendor/assets/javascripts/adminlte/plugins/select2/src/scss/theme/default/layout.scss +97 -0
  231. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/a11y/search-tests.js +51 -0
  232. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/a11y/selection-tests.js +154 -0
  233. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/data/array-tests.js +318 -0
  234. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/data/base-tests.js +29 -0
  235. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/data/inputData-tests.js +158 -0
  236. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/data/maximumInputLength-tests.js +138 -0
  237. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/data/maximumSelectionLength-tests.js +202 -0
  238. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/data/minimumInputLength-tests.js +138 -0
  239. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/data/select-tests.js +489 -0
  240. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/data/tags-tests.js +276 -0
  241. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/data/tokenizer-tests.js +219 -0
  242. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/dropdown/dropdownCss-tests.js +104 -0
  243. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/dropdown/positioning-tests.js +177 -0
  244. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/dropdown/selectOnClose-tests.js +137 -0
  245. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/dropdown/stopPropagation-tests.js +33 -0
  246. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/helpers.js +46 -0
  247. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/integration.html +21 -0
  248. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/integration/dom-changes.js +257 -0
  249. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/integration/jquery-calls.js +30 -0
  250. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/integration/select2-methods.js +139 -0
  251. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/options/ajax-tests.js +32 -0
  252. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/options/data-tests.js +44 -0
  253. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/options/deprecated-tests.js +250 -0
  254. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/options/translation-tests.js +28 -0
  255. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/options/width-tests.js +66 -0
  256. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/results/focusing-tests.js +138 -0
  257. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/selection/allowClear-tests.js +218 -0
  258. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/selection/containerCss-tests.js +104 -0
  259. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/selection/multiple-tests.js +149 -0
  260. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/selection/placeholder-tests.js +74 -0
  261. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/selection/search-tests.js +191 -0
  262. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/selection/single-tests.js +117 -0
  263. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/selection/stopPropagation-tests.js +33 -0
  264. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/unit.html +95 -0
  265. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/utils/decorator-tests.js +189 -0
  266. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/utils/escapeMarkup-tests.js +36 -0
  267. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/vendor/jquery-1.7.2.js +9404 -0
  268. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/vendor/qunit-1.23.1.css +305 -0
  269. data/vendor/assets/javascripts/adminlte/plugins/select2/tests/vendor/qunit-1.23.1.js +4334 -0
  270. data/vendor/assets/javascripts/adminlte/plugins/select2/vendor/jquery-2.1.0.js +9111 -0
  271. data/vendor/assets/stylesheets/adminlte.min.scss +27 -0
  272. data/vendor/assets/stylesheets/adminlte.scss +6 -0
  273. data/vendor/assets/stylesheets/adminlte/adminlte.css +4977 -0
  274. data/vendor/assets/stylesheets/adminlte/adminlte.min.css +7 -0
  275. data/vendor/assets/stylesheets/adminlte/fonts/FontAwesome.otf +0 -0
  276. data/vendor/assets/stylesheets/adminlte/fonts/fontawesome-webfont.eot +0 -0
  277. data/vendor/assets/stylesheets/adminlte/fonts/fontawesome-webfont.svg +2671 -0
  278. data/vendor/assets/stylesheets/adminlte/fonts/fontawesome-webfont.ttf +0 -0
  279. data/vendor/assets/stylesheets/adminlte/fonts/fontawesome-webfont.woff +0 -0
  280. data/vendor/assets/stylesheets/adminlte/fonts/fontawesome-webfont.woff2 +0 -0
  281. data/vendor/assets/stylesheets/adminlte/fonts/glyphicons-halflings-regular.eot +0 -0
  282. data/vendor/assets/stylesheets/adminlte/fonts/glyphicons-halflings-regular.svg +288 -0
  283. data/vendor/assets/stylesheets/adminlte/fonts/glyphicons-halflings-regular.ttf +0 -0
  284. data/vendor/assets/stylesheets/adminlte/fonts/glyphicons-halflings-regular.woff +0 -0
  285. data/vendor/assets/stylesheets/adminlte/fonts/glyphicons-halflings-regular.woff2 +0 -0
  286. data/vendor/assets/stylesheets/adminlte/plugins/bootstrap-colorpicker/bootstrap-colorpicker.css +230 -0
  287. data/vendor/assets/stylesheets/adminlte/plugins/bootstrap-datepicker/bootstrap-datepicker.css +477 -0
  288. data/vendor/assets/stylesheets/adminlte/plugins/bootstrap-datepicker/bootstrap-datepicker.standalone.css +510 -0
  289. data/vendor/assets/stylesheets/adminlte/plugins/bootstrap-datepicker/bootstrap-datepicker3.css +684 -0
  290. data/vendor/assets/stylesheets/adminlte/plugins/bootstrap-datepicker/bootstrap-datepicker3.standalone.css +713 -0
  291. data/vendor/assets/stylesheets/adminlte/plugins/bootstrap-daterangepicker/bootstrap-daterangepicker.css +269 -0
  292. data/vendor/assets/stylesheets/adminlte/plugins/bootstrap-slider/bootstrap-slider.css +178 -0
  293. data/vendor/assets/stylesheets/adminlte/plugins/bootstrap-timepicker/bootstrap-timepicker.less +172 -0
  294. data/vendor/assets/stylesheets/adminlte/plugins/bootstrap/bootstrap.css.map +1 -0
  295. data/vendor/assets/stylesheets/adminlte/plugins/bootstrap/bootstrap.scss +6757 -0
  296. data/vendor/assets/stylesheets/adminlte/plugins/font-awesome/font-awesome.scss +2341 -0
  297. data/vendor/assets/stylesheets/adminlte/plugins/select2/select2.css +484 -0
  298. data/vendor/assets/stylesheets/adminlte/skins/_all-skins.css +1781 -0
  299. data/vendor/assets/stylesheets/adminlte/skins/_all-skins.min.css +1 -0
  300. data/vendor/assets/stylesheets/adminlte/skins/skin-black-light.css +171 -0
  301. data/vendor/assets/stylesheets/adminlte/skins/skin-black-light.min.css +1 -0
  302. data/vendor/assets/stylesheets/adminlte/skins/skin-black.css +161 -0
  303. data/vendor/assets/stylesheets/adminlte/skins/skin-black.min.css +1 -0
  304. data/vendor/assets/stylesheets/adminlte/skins/skin-blue-light.css +163 -0
  305. data/vendor/assets/stylesheets/adminlte/skins/skin-blue-light.min.css +1 -0
  306. data/vendor/assets/stylesheets/adminlte/skins/skin-blue.css +142 -0
  307. data/vendor/assets/stylesheets/adminlte/skins/skin-blue.min.css +1 -0
  308. data/vendor/assets/stylesheets/adminlte/skins/skin-green-light.css +152 -0
  309. data/vendor/assets/stylesheets/adminlte/skins/skin-green-light.min.css +1 -0
  310. data/vendor/assets/stylesheets/adminlte/skins/skin-green.css +134 -0
  311. data/vendor/assets/stylesheets/adminlte/skins/skin-green.min.css +1 -0
  312. data/vendor/assets/stylesheets/adminlte/skins/skin-purple-light.css +152 -0
  313. data/vendor/assets/stylesheets/adminlte/skins/skin-purple-light.min.css +1 -0
  314. data/vendor/assets/stylesheets/adminlte/skins/skin-purple.css +134 -0
  315. data/vendor/assets/stylesheets/adminlte/skins/skin-purple.min.css +1 -0
  316. data/vendor/assets/stylesheets/adminlte/skins/skin-red-light.css +152 -0
  317. data/vendor/assets/stylesheets/adminlte/skins/skin-red-light.min.css +1 -0
  318. data/vendor/assets/stylesheets/adminlte/skins/skin-red.css +134 -0
  319. data/vendor/assets/stylesheets/adminlte/skins/skin-red.min.css +1 -0
  320. data/vendor/assets/stylesheets/adminlte/skins/skin-yellow-light.css +152 -0
  321. data/vendor/assets/stylesheets/adminlte/skins/skin-yellow-light.min.css +1 -0
  322. data/vendor/assets/stylesheets/adminlte/skins/skin-yellow.css +134 -0
  323. data/vendor/assets/stylesheets/adminlte/skins/skin-yellow.min.css +1 -0
  324. metadata +408 -0
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: c2f516d905276a9a8fd21eb5a08e6766b97520a6
4
+ data.tar.gz: f27132872f6c10783fc75883a7df72ed76753f9e
5
+ SHA512:
6
+ metadata.gz: c01e5e8ebea834036f78ffd76b7056b7e774c9a81c38373465925bd6a755c94b5927656e29f06d724f320c306c113d777a18df4e95bd7d8aabd12f9c8dcf7b29
7
+ data.tar.gz: 33fb96bb5ee5bd8be66b34cd9050fa59015bf51f910561a92690995e405b9e96b12aebd6557683c4819453ae5d0a7eda0efdd6d17a1e93fb87fba5be140b7358
@@ -0,0 +1,8 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /_yardoc/
4
+ /coverage/
5
+ /doc/
6
+ /pkg/
7
+ /spec/reports/
8
+ /tmp/
@@ -0,0 +1,5 @@
1
+ sudo: false
2
+ language: ruby
3
+ rvm:
4
+ - 2.4.2
5
+ before_install: gem install bundler -v 1.16.0
@@ -0,0 +1,74 @@
1
+ # Contributor Covenant Code of Conduct
2
+
3
+ ## Our Pledge
4
+
5
+ In the interest of fostering an open and welcoming environment, we as
6
+ contributors and maintainers pledge to making participation in our project and
7
+ our community a harassment-free experience for everyone, regardless of age, body
8
+ size, disability, ethnicity, gender identity and expression, level of experience,
9
+ nationality, personal appearance, race, religion, or sexual identity and
10
+ orientation.
11
+
12
+ ## Our Standards
13
+
14
+ Examples of behavior that contributes to creating a positive environment
15
+ include:
16
+
17
+ * Using welcoming and inclusive language
18
+ * Being respectful of differing viewpoints and experiences
19
+ * Gracefully accepting constructive criticism
20
+ * Focusing on what is best for the community
21
+ * Showing empathy towards other community members
22
+
23
+ Examples of unacceptable behavior by participants include:
24
+
25
+ * The use of sexualized language or imagery and unwelcome sexual attention or
26
+ advances
27
+ * Trolling, insulting/derogatory comments, and personal or political attacks
28
+ * Public or private harassment
29
+ * Publishing others' private information, such as a physical or electronic
30
+ address, without explicit permission
31
+ * Other conduct which could reasonably be considered inappropriate in a
32
+ professional setting
33
+
34
+ ## Our Responsibilities
35
+
36
+ Project maintainers are responsible for clarifying the standards of acceptable
37
+ behavior and are expected to take appropriate and fair corrective action in
38
+ response to any instances of unacceptable behavior.
39
+
40
+ Project maintainers have the right and responsibility to remove, edit, or
41
+ reject comments, commits, code, wiki edits, issues, and other contributions
42
+ that are not aligned to this Code of Conduct, or to ban temporarily or
43
+ permanently any contributor for other behaviors that they deem inappropriate,
44
+ threatening, offensive, or harmful.
45
+
46
+ ## Scope
47
+
48
+ This Code of Conduct applies both within project spaces and in public spaces
49
+ when an individual is representing the project or its community. Examples of
50
+ representing a project or community include using an official project e-mail
51
+ address, posting via an official social media account, or acting as an appointed
52
+ representative at an online or offline event. Representation of a project may be
53
+ further defined and clarified by project maintainers.
54
+
55
+ ## Enforcement
56
+
57
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be
58
+ reported by contacting the project team at github@roy.cc. All
59
+ complaints will be reviewed and investigated and will result in a response that
60
+ is deemed necessary and appropriate to the circumstances. The project team is
61
+ obligated to maintain confidentiality with regard to the reporter of an incident.
62
+ Further details of specific enforcement policies may be posted separately.
63
+
64
+ Project maintainers who do not follow or enforce the Code of Conduct in good
65
+ faith may face temporary or permanent repercussions as determined by other
66
+ members of the project's leadership.
67
+
68
+ ## Attribution
69
+
70
+ This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
71
+ available at [http://contributor-covenant.org/version/1/4][version]
72
+
73
+ [homepage]: http://contributor-covenant.org
74
+ [version]: http://contributor-covenant.org/version/1/4/
data/Gemfile ADDED
@@ -0,0 +1,6 @@
1
+ source "https://rubygems.org"
2
+
3
+ git_source(:github) {|repo_name| "https://github.com/#{repo_name}" }
4
+
5
+ # Specify your gem's dependencies in adminlte_rails.gemspec
6
+ gemspec
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2018 Roy Zheng
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
@@ -0,0 +1,51 @@
1
+ # AdminlteRails
2
+
3
+ Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/adminlte_rails`. To experiment with that code, run `bin/console` for an interactive prompt.
4
+
5
+ TODO: Delete this and the text above, and describe your gem
6
+
7
+ ## Installation
8
+
9
+ Add this line to your application's Gemfile:
10
+
11
+ ```ruby
12
+ gem 'adminlte_rails'
13
+ ```
14
+
15
+ And then execute:
16
+
17
+ $ bundle
18
+
19
+ Or install it yourself as:
20
+
21
+ $ gem install adminlte_rails
22
+
23
+ ## Usage
24
+
25
+ # Include adminlte_rails in your assets files
26
+ add the following to your app/assets/javascripts/application.js:
27
+ ```javascript
28
+ //= require adminlte
29
+ ```
30
+ add the following to your app/assets/stylesheets/application.css:
31
+ ```stylesheets
32
+ *= require adminlte
33
+ ```
34
+
35
+ ## Development
36
+
37
+ After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake test` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
38
+
39
+ To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
40
+
41
+ ## Contributing
42
+
43
+ Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/adminlte_rails. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.
44
+
45
+ ## License
46
+
47
+ The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
48
+
49
+ ## Code of Conduct
50
+
51
+ Everyone interacting in the AdminlteRails project’s codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/[USERNAME]/adminlte_rails/blob/master/CODE_OF_CONDUCT.md).
@@ -0,0 +1,10 @@
1
+ require "bundler/gem_tasks"
2
+ require "rake/testtask"
3
+
4
+ Rake::TestTask.new(:test) do |t|
5
+ t.libs << "test"
6
+ t.libs << "lib"
7
+ t.test_files = FileList["test/**/*_test.rb"]
8
+ end
9
+
10
+ task :default => :test
@@ -0,0 +1,27 @@
1
+
2
+ lib = File.expand_path("../lib", __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require "adminlte_rails/version"
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "adminlte_rails"
8
+ spec.version = AdminlteRails::VERSION
9
+ spec.authors = ["Roy Zheng"]
10
+ spec.email = ["github@roy.cc"]
11
+
12
+ spec.summary = %q{AdminLTE2 on rails}
13
+ spec.description = %q{AdminLTE2 on rails}
14
+ spec.homepage = "https://github.com/royzheng/adminlte_rails"
15
+ spec.license = "MIT"
16
+
17
+ spec.files = `git ls-files -z`.split("\x0").reject do |f|
18
+ f.match(%r{^(test|spec|features)/})
19
+ end
20
+ spec.bindir = "exe"
21
+ spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
22
+ spec.require_paths = ["lib"]
23
+
24
+ spec.add_development_dependency "bundler", "~> 1.16"
25
+ spec.add_development_dependency "rake", "~> 10.0"
26
+ spec.add_development_dependency "minitest", "~> 5.0"
27
+ end
@@ -0,0 +1,14 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require "bundler/setup"
4
+ require "adminlte_rails"
5
+
6
+ # You can add fixtures and/or initialization code here to make experimenting
7
+ # with your gem easier. You can also use a different console, if you like.
8
+
9
+ # (If you use this, don't forget to add pry to your Gemfile!)
10
+ # require "pry"
11
+ # Pry.start
12
+
13
+ require "irb"
14
+ IRB.start(__FILE__)
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+ set -vx
5
+
6
+ bundle install
7
+
8
+ # Do any other automated setup that you need to do here
@@ -0,0 +1,5 @@
1
+ require "adminlte_rails/version"
2
+
3
+ module AdminlteRails
4
+ require 'adminlte_rails/engine'
5
+ end
@@ -0,0 +1,7 @@
1
+ require "adminlte_rails/version"
2
+
3
+ module AdminlteRails
4
+ class Engine < ::Rails::Engine
5
+
6
+ end
7
+ end
@@ -0,0 +1,3 @@
1
+ module AdminlteRails
2
+ VERSION = "0.1.0"
3
+ end
@@ -0,0 +1,3 @@
1
+ //= require adminlte/plugins/jquery/jquery
2
+ //= require adminlte/plugins/bootstrap/bootstrap
3
+ //= require adminlte/adminlte
@@ -0,0 +1,3 @@
1
+ //= require adminlte/plugins/jquery/jquery.min
2
+ //= require adminlte/plugins/bootstrap/bootstrap.min
3
+ //= require adminlte/adminlte.min
@@ -0,0 +1,1129 @@
1
+ /*! AdminLTE app.js
2
+ * ================
3
+ * Main JS application file for AdminLTE v2. This file
4
+ * should be included in all pages. It controls some layout
5
+ * options and implements exclusive AdminLTE plugins.
6
+ *
7
+ * @Author Almsaeed Studio
8
+ * @Support <https://www.almsaeedstudio.com>
9
+ * @Email <abdullah@almsaeedstudio.com>
10
+ * @version 2.4.2
11
+ * @repository git://github.com/almasaeed2010/AdminLTE.git
12
+ * @license MIT <http://opensource.org/licenses/MIT>
13
+ */
14
+
15
+ // Make sure jQuery has been loaded
16
+ if (typeof jQuery === 'undefined') {
17
+ throw new Error('AdminLTE requires jQuery')
18
+ }
19
+
20
+ /* BoxRefresh()
21
+ * =========
22
+ * Adds AJAX content control to a box.
23
+ *
24
+ * @Usage: $('#my-box').boxRefresh(options)
25
+ * or add [data-widget="box-refresh"] to the box element
26
+ * Pass any option as data-option="value"
27
+ */
28
+ +function ($) {
29
+ 'use strict';
30
+
31
+ var DataKey = 'lte.boxrefresh';
32
+
33
+ var Default = {
34
+ source : '',
35
+ params : {},
36
+ trigger : '.refresh-btn',
37
+ content : '.box-body',
38
+ loadInContent : true,
39
+ responseType : '',
40
+ overlayTemplate: '<div class="overlay"><div class="fa fa-refresh fa-spin"></div></div>',
41
+ onLoadStart : function () {
42
+ },
43
+ onLoadDone : function (response) {
44
+ return response;
45
+ }
46
+ };
47
+
48
+ var Selector = {
49
+ data: '[data-widget="box-refresh"]'
50
+ };
51
+
52
+ // BoxRefresh Class Definition
53
+ // =========================
54
+ var BoxRefresh = function (element, options) {
55
+ this.element = element;
56
+ this.options = options;
57
+ this.$overlay = $(options.overlay);
58
+
59
+ if (options.source === '') {
60
+ throw new Error('Source url was not defined. Please specify a url in your BoxRefresh source option.');
61
+ }
62
+
63
+ this._setUpListeners();
64
+ this.load();
65
+ };
66
+
67
+ BoxRefresh.prototype.load = function () {
68
+ this._addOverlay();
69
+ this.options.onLoadStart.call($(this));
70
+
71
+ $.get(this.options.source, this.options.params, function (response) {
72
+ if (this.options.loadInContent) {
73
+ $(this.options.content).html(response);
74
+ }
75
+ this.options.onLoadDone.call($(this), response);
76
+ this._removeOverlay();
77
+ }.bind(this), this.options.responseType !== '' && this.options.responseType);
78
+ };
79
+
80
+ // Private
81
+
82
+ BoxRefresh.prototype._setUpListeners = function () {
83
+ $(this.element).on('click', Selector.trigger, function (event) {
84
+ if (event) event.preventDefault();
85
+ this.load();
86
+ }.bind(this));
87
+ };
88
+
89
+ BoxRefresh.prototype._addOverlay = function () {
90
+ $(this.element).append(this.$overlay);
91
+ };
92
+
93
+ BoxRefresh.prototype._removeOverlay = function () {
94
+ $(this.element).remove(this.$overlay);
95
+ };
96
+
97
+ // Plugin Definition
98
+ // =================
99
+ function Plugin(option) {
100
+ return this.each(function () {
101
+ var $this = $(this);
102
+ var data = $this.data(DataKey);
103
+
104
+ if (!data) {
105
+ var options = $.extend({}, Default, $this.data(), typeof option == 'object' && option);
106
+ $this.data(DataKey, (data = new BoxRefresh($this, options)));
107
+ }
108
+
109
+ if (typeof data == 'string') {
110
+ if (typeof data[option] == 'undefined') {
111
+ throw new Error('No method named ' + option);
112
+ }
113
+ data[option]();
114
+ }
115
+ });
116
+ }
117
+
118
+ var old = $.fn.boxRefresh;
119
+
120
+ $.fn.boxRefresh = Plugin;
121
+ $.fn.boxRefresh.Constructor = BoxRefresh;
122
+
123
+ // No Conflict Mode
124
+ // ================
125
+ $.fn.boxRefresh.noConflict = function () {
126
+ $.fn.boxRefresh = old;
127
+ return this;
128
+ };
129
+
130
+ // BoxRefresh Data API
131
+ // =================
132
+ $(window).on('load', function () {
133
+ $(Selector.data).each(function () {
134
+ Plugin.call($(this));
135
+ });
136
+ });
137
+
138
+ }(jQuery);
139
+
140
+
141
+ /* BoxWidget()
142
+ * ======
143
+ * Adds box widget functions to boxes.
144
+ *
145
+ * @Usage: $('.my-box').boxWidget(options)
146
+ * This plugin auto activates on any element using the `.box` class
147
+ * Pass any option as data-option="value"
148
+ */
149
+ +function ($) {
150
+ 'use strict';
151
+
152
+ var DataKey = 'lte.boxwidget';
153
+
154
+ var Default = {
155
+ animationSpeed : 500,
156
+ collapseTrigger: '[data-widget="collapse"]',
157
+ removeTrigger : '[data-widget="remove"]',
158
+ collapseIcon : 'fa-minus',
159
+ expandIcon : 'fa-plus',
160
+ removeIcon : 'fa-times'
161
+ };
162
+
163
+ var Selector = {
164
+ data : '.box',
165
+ collapsed: '.collapsed-box',
166
+ header : '.box-header',
167
+ body : '.box-body',
168
+ footer : '.box-footer',
169
+ tools : '.box-tools'
170
+ };
171
+
172
+ var ClassName = {
173
+ collapsed: 'collapsed-box'
174
+ };
175
+
176
+ var Event = {
177
+ collapsed: 'collapsed.boxwidget',
178
+ expanded : 'expanded.boxwidget',
179
+ removed : 'removed.boxwidget'
180
+ };
181
+
182
+ // BoxWidget Class Definition
183
+ // =====================
184
+ var BoxWidget = function (element, options) {
185
+ this.element = element;
186
+ this.options = options;
187
+
188
+ this._setUpListeners();
189
+ };
190
+
191
+ BoxWidget.prototype.toggle = function () {
192
+ var isOpen = !$(this.element).is(Selector.collapsed);
193
+
194
+ if (isOpen) {
195
+ this.collapse();
196
+ } else {
197
+ this.expand();
198
+ }
199
+ };
200
+
201
+ BoxWidget.prototype.expand = function () {
202
+ var expandedEvent = $.Event(Event.expanded);
203
+ var collapseIcon = this.options.collapseIcon;
204
+ var expandIcon = this.options.expandIcon;
205
+
206
+ $(this.element).removeClass(ClassName.collapsed);
207
+
208
+ $(this.element)
209
+ .children(Selector.header + ', ' + Selector.body + ', ' + Selector.footer)
210
+ .children(Selector.tools)
211
+ .find('.' + expandIcon)
212
+ .removeClass(expandIcon)
213
+ .addClass(collapseIcon);
214
+
215
+ $(this.element).children(Selector.body + ', ' + Selector.footer)
216
+ .slideDown(this.options.animationSpeed, function () {
217
+ $(this.element).trigger(expandedEvent);
218
+ }.bind(this));
219
+ };
220
+
221
+ BoxWidget.prototype.collapse = function () {
222
+ var collapsedEvent = $.Event(Event.collapsed);
223
+ var collapseIcon = this.options.collapseIcon;
224
+ var expandIcon = this.options.expandIcon;
225
+
226
+ $(this.element)
227
+ .children(Selector.header + ', ' + Selector.body + ', ' + Selector.footer)
228
+ .children(Selector.tools)
229
+ .find('.' + collapseIcon)
230
+ .removeClass(collapseIcon)
231
+ .addClass(expandIcon);
232
+
233
+ $(this.element).children(Selector.body + ', ' + Selector.footer)
234
+ .slideUp(this.options.animationSpeed, function () {
235
+ $(this.element).addClass(ClassName.collapsed);
236
+ $(this.element).trigger(collapsedEvent);
237
+ }.bind(this));
238
+ };
239
+
240
+ BoxWidget.prototype.remove = function () {
241
+ var removedEvent = $.Event(Event.removed);
242
+
243
+ $(this.element).slideUp(this.options.animationSpeed, function () {
244
+ $(this.element).trigger(removedEvent);
245
+ $(this.element).remove();
246
+ }.bind(this));
247
+ };
248
+
249
+ // Private
250
+
251
+ BoxWidget.prototype._setUpListeners = function () {
252
+ var that = this;
253
+
254
+ $(this.element).on('click', this.options.collapseTrigger, function (event) {
255
+ if (event) event.preventDefault();
256
+ that.toggle($(this));
257
+ return false;
258
+ });
259
+
260
+ $(this.element).on('click', this.options.removeTrigger, function (event) {
261
+ if (event) event.preventDefault();
262
+ that.remove($(this));
263
+ return false;
264
+ });
265
+ };
266
+
267
+ // Plugin Definition
268
+ // =================
269
+ function Plugin(option) {
270
+ return this.each(function () {
271
+ var $this = $(this);
272
+ var data = $this.data(DataKey);
273
+
274
+ if (!data) {
275
+ var options = $.extend({}, Default, $this.data(), typeof option == 'object' && option);
276
+ $this.data(DataKey, (data = new BoxWidget($this, options)));
277
+ }
278
+
279
+ if (typeof option == 'string') {
280
+ if (typeof data[option] == 'undefined') {
281
+ throw new Error('No method named ' + option);
282
+ }
283
+ data[option]();
284
+ }
285
+ });
286
+ }
287
+
288
+ var old = $.fn.boxWidget;
289
+
290
+ $.fn.boxWidget = Plugin;
291
+ $.fn.boxWidget.Constructor = BoxWidget;
292
+
293
+ // No Conflict Mode
294
+ // ================
295
+ $.fn.boxWidget.noConflict = function () {
296
+ $.fn.boxWidget = old;
297
+ return this;
298
+ };
299
+
300
+ // BoxWidget Data API
301
+ // ==================
302
+ $(window).on('load', function () {
303
+ $(Selector.data).each(function () {
304
+ Plugin.call($(this));
305
+ });
306
+ });
307
+ }(jQuery);
308
+
309
+
310
+ /* ControlSidebar()
311
+ * ===============
312
+ * Toggles the state of the control sidebar
313
+ *
314
+ * @Usage: $('#control-sidebar-trigger').controlSidebar(options)
315
+ * or add [data-toggle="control-sidebar"] to the trigger
316
+ * Pass any option as data-option="value"
317
+ */
318
+ +function ($) {
319
+ 'use strict';
320
+
321
+ var DataKey = 'lte.controlsidebar';
322
+
323
+ var Default = {
324
+ slide: true
325
+ };
326
+
327
+ var Selector = {
328
+ sidebar: '.control-sidebar',
329
+ data : '[data-toggle="control-sidebar"]',
330
+ open : '.control-sidebar-open',
331
+ bg : '.control-sidebar-bg',
332
+ wrapper: '.wrapper',
333
+ content: '.content-wrapper',
334
+ boxed : '.layout-boxed'
335
+ };
336
+
337
+ var ClassName = {
338
+ open : 'control-sidebar-open',
339
+ fixed: 'fixed'
340
+ };
341
+
342
+ var Event = {
343
+ collapsed: 'collapsed.controlsidebar',
344
+ expanded : 'expanded.controlsidebar'
345
+ };
346
+
347
+ // ControlSidebar Class Definition
348
+ // ===============================
349
+ var ControlSidebar = function (element, options) {
350
+ this.element = element;
351
+ this.options = options;
352
+ this.hasBindedResize = false;
353
+
354
+ this.init();
355
+ };
356
+
357
+ ControlSidebar.prototype.init = function () {
358
+ // Add click listener if the element hasn't been
359
+ // initialized using the data API
360
+ if (!$(this.element).is(Selector.data)) {
361
+ $(this).on('click', this.toggle);
362
+ }
363
+
364
+ this.fix();
365
+ $(window).resize(function () {
366
+ this.fix();
367
+ }.bind(this));
368
+ };
369
+
370
+ ControlSidebar.prototype.toggle = function (event) {
371
+ if (event) event.preventDefault();
372
+
373
+ this.fix();
374
+
375
+ if (!$(Selector.sidebar).is(Selector.open) && !$('body').is(Selector.open)) {
376
+ this.expand();
377
+ } else {
378
+ this.collapse();
379
+ }
380
+ };
381
+
382
+ ControlSidebar.prototype.expand = function () {
383
+ if (!this.options.slide) {
384
+ $('body').addClass(ClassName.open);
385
+ } else {
386
+ $(Selector.sidebar).addClass(ClassName.open);
387
+ }
388
+
389
+ $(this.element).trigger($.Event(Event.expanded));
390
+ };
391
+
392
+ ControlSidebar.prototype.collapse = function () {
393
+ $('body, ' + Selector.sidebar).removeClass(ClassName.open);
394
+ $(this.element).trigger($.Event(Event.collapsed));
395
+ };
396
+
397
+ ControlSidebar.prototype.fix = function () {
398
+ if ($('body').is(Selector.boxed)) {
399
+ this._fixForBoxed($(Selector.bg));
400
+ }
401
+ };
402
+
403
+ // Private
404
+
405
+ ControlSidebar.prototype._fixForBoxed = function (bg) {
406
+ bg.css({
407
+ position: 'absolute',
408
+ height : $(Selector.wrapper).height()
409
+ });
410
+ };
411
+
412
+ // Plugin Definition
413
+ // =================
414
+ function Plugin(option) {
415
+ return this.each(function () {
416
+ var $this = $(this);
417
+ var data = $this.data(DataKey);
418
+
419
+ if (!data) {
420
+ var options = $.extend({}, Default, $this.data(), typeof option == 'object' && option);
421
+ $this.data(DataKey, (data = new ControlSidebar($this, options)));
422
+ }
423
+
424
+ if (typeof option == 'string') data.toggle();
425
+ });
426
+ }
427
+
428
+ var old = $.fn.controlSidebar;
429
+
430
+ $.fn.controlSidebar = Plugin;
431
+ $.fn.controlSidebar.Constructor = ControlSidebar;
432
+
433
+ // No Conflict Mode
434
+ // ================
435
+ $.fn.controlSidebar.noConflict = function () {
436
+ $.fn.controlSidebar = old;
437
+ return this;
438
+ };
439
+
440
+ // ControlSidebar Data API
441
+ // =======================
442
+ $(document).on('click', Selector.data, function (event) {
443
+ if (event) event.preventDefault();
444
+ Plugin.call($(this), 'toggle');
445
+ });
446
+
447
+ }(jQuery);
448
+
449
+
450
+ /* DirectChat()
451
+ * ===============
452
+ * Toggles the state of the control sidebar
453
+ *
454
+ * @Usage: $('#my-chat-box').directChat()
455
+ * or add [data-widget="direct-chat"] to the trigger
456
+ */
457
+ +function ($) {
458
+ 'use strict';
459
+
460
+ var DataKey = 'lte.directchat';
461
+
462
+ var Selector = {
463
+ data: '[data-widget="chat-pane-toggle"]',
464
+ box : '.direct-chat'
465
+ };
466
+
467
+ var ClassName = {
468
+ open: 'direct-chat-contacts-open'
469
+ };
470
+
471
+ // DirectChat Class Definition
472
+ // ===========================
473
+ var DirectChat = function (element) {
474
+ this.element = element;
475
+ };
476
+
477
+ DirectChat.prototype.toggle = function ($trigger) {
478
+ $trigger.parents(Selector.box).first().toggleClass(ClassName.open);
479
+ };
480
+
481
+ // Plugin Definition
482
+ // =================
483
+ function Plugin(option) {
484
+ return this.each(function () {
485
+ var $this = $(this);
486
+ var data = $this.data(DataKey);
487
+
488
+ if (!data) {
489
+ $this.data(DataKey, (data = new DirectChat($this)));
490
+ }
491
+
492
+ if (typeof option == 'string') data.toggle($this);
493
+ });
494
+ }
495
+
496
+ var old = $.fn.directChat;
497
+
498
+ $.fn.directChat = Plugin;
499
+ $.fn.directChat.Constructor = DirectChat;
500
+
501
+ // No Conflict Mode
502
+ // ================
503
+ $.fn.directChat.noConflict = function () {
504
+ $.fn.directChat = old;
505
+ return this;
506
+ };
507
+
508
+ // DirectChat Data API
509
+ // ===================
510
+ $(document).on('click', Selector.data, function (event) {
511
+ if (event) event.preventDefault();
512
+ Plugin.call($(this), 'toggle');
513
+ });
514
+
515
+ }(jQuery);
516
+
517
+
518
+ /* Layout()
519
+ * ========
520
+ * Implements AdminLTE layout.
521
+ * Fixes the layout height in case min-height fails.
522
+ *
523
+ * @usage activated automatically upon window load.
524
+ * Configure any options by passing data-option="value"
525
+ * to the body tag.
526
+ */
527
+ +function ($) {
528
+ 'use strict';
529
+
530
+ var DataKey = 'lte.layout';
531
+
532
+ var Default = {
533
+ slimscroll : true,
534
+ resetHeight: true
535
+ };
536
+
537
+ var Selector = {
538
+ wrapper : '.wrapper',
539
+ contentWrapper: '.content-wrapper',
540
+ layoutBoxed : '.layout-boxed',
541
+ mainFooter : '.main-footer',
542
+ mainHeader : '.main-header',
543
+ sidebar : '.sidebar',
544
+ controlSidebar: '.control-sidebar',
545
+ fixed : '.fixed',
546
+ sidebarMenu : '.sidebar-menu',
547
+ logo : '.main-header .logo'
548
+ };
549
+
550
+ var ClassName = {
551
+ fixed : 'fixed',
552
+ holdTransition: 'hold-transition'
553
+ };
554
+
555
+ var Layout = function (options) {
556
+ this.options = options;
557
+ this.bindedResize = false;
558
+ this.activate();
559
+ };
560
+
561
+ Layout.prototype.activate = function () {
562
+ this.fix();
563
+ this.fixSidebar();
564
+
565
+ $('body').removeClass(ClassName.holdTransition);
566
+
567
+ if (this.options.resetHeight) {
568
+ $('body, html, ' + Selector.wrapper).css({
569
+ 'height' : 'auto',
570
+ 'min-height': '100%'
571
+ });
572
+ }
573
+
574
+ if (!this.bindedResize) {
575
+ $(window).resize(function () {
576
+ this.fix();
577
+ this.fixSidebar();
578
+
579
+ $(Selector.logo + ', ' + Selector.sidebar).one('webkitTransitionEnd otransitionend oTransitionEnd msTransitionEnd transitionend', function () {
580
+ this.fix();
581
+ this.fixSidebar();
582
+ }.bind(this));
583
+ }.bind(this));
584
+
585
+ this.bindedResize = true;
586
+ }
587
+
588
+ $(Selector.sidebarMenu).on('expanded.tree', function () {
589
+ this.fix();
590
+ this.fixSidebar();
591
+ }.bind(this));
592
+
593
+ $(Selector.sidebarMenu).on('collapsed.tree', function () {
594
+ this.fix();
595
+ this.fixSidebar();
596
+ }.bind(this));
597
+ };
598
+
599
+ Layout.prototype.fix = function () {
600
+ // Remove overflow from .wrapper if layout-boxed exists
601
+ $(Selector.layoutBoxed + ' > ' + Selector.wrapper).css('overflow', 'hidden');
602
+
603
+ // Get window height and the wrapper height
604
+ var footerHeight = $(Selector.mainFooter).outerHeight() || 0;
605
+ var neg = $(Selector.mainHeader).outerHeight() + footerHeight;
606
+ var windowHeight = $(window).height();
607
+ var sidebarHeight = $(Selector.sidebar).height() || 0;
608
+
609
+ // Set the min-height of the content and sidebar based on
610
+ // the height of the document.
611
+ if ($('body').hasClass(ClassName.fixed)) {
612
+ $(Selector.contentWrapper).css('min-height', windowHeight - footerHeight);
613
+ } else {
614
+ var postSetHeight;
615
+
616
+ if (windowHeight >= sidebarHeight) {
617
+ $(Selector.contentWrapper).css('min-height', windowHeight - neg);
618
+ postSetHeight = windowHeight - neg;
619
+ } else {
620
+ $(Selector.contentWrapper).css('min-height', sidebarHeight);
621
+ postSetHeight = sidebarHeight;
622
+ }
623
+
624
+ // Fix for the control sidebar height
625
+ var $controlSidebar = $(Selector.controlSidebar);
626
+ if (typeof $controlSidebar !== 'undefined') {
627
+ if ($controlSidebar.height() > postSetHeight)
628
+ $(Selector.contentWrapper).css('min-height', $controlSidebar.height());
629
+ }
630
+ }
631
+ };
632
+
633
+ Layout.prototype.fixSidebar = function () {
634
+ // Make sure the body tag has the .fixed class
635
+ if (!$('body').hasClass(ClassName.fixed)) {
636
+ if (typeof $.fn.slimScroll !== 'undefined') {
637
+ $(Selector.sidebar).slimScroll({ destroy: true }).height('auto');
638
+ }
639
+ return;
640
+ }
641
+
642
+ // Enable slimscroll for fixed layout
643
+ if (this.options.slimscroll) {
644
+ if (typeof $.fn.slimScroll !== 'undefined') {
645
+ // Destroy if it exists
646
+ // $(Selector.sidebar).slimScroll({ destroy: true }).height('auto')
647
+
648
+ // Add slimscroll
649
+ $(Selector.sidebar).slimScroll({
650
+ height: ($(window).height() - $(Selector.mainHeader).height()) + 'px'
651
+ });
652
+ }
653
+ }
654
+ };
655
+
656
+ // Plugin Definition
657
+ // =================
658
+ function Plugin(option) {
659
+ return this.each(function () {
660
+ var $this = $(this);
661
+ var data = $this.data(DataKey);
662
+
663
+ if (!data) {
664
+ var options = $.extend({}, Default, $this.data(), typeof option === 'object' && option);
665
+ $this.data(DataKey, (data = new Layout(options)));
666
+ }
667
+
668
+ if (typeof option === 'string') {
669
+ if (typeof data[option] === 'undefined') {
670
+ throw new Error('No method named ' + option);
671
+ }
672
+ data[option]();
673
+ }
674
+ });
675
+ }
676
+
677
+ var old = $.fn.layout;
678
+
679
+ $.fn.layout = Plugin;
680
+ $.fn.layout.Constuctor = Layout;
681
+
682
+ // No conflict mode
683
+ // ================
684
+ $.fn.layout.noConflict = function () {
685
+ $.fn.layout = old;
686
+ return this;
687
+ };
688
+
689
+ // Layout DATA-API
690
+ // ===============
691
+ $(window).on('load', function () {
692
+ Plugin.call($('body'));
693
+ });
694
+ }(jQuery);
695
+
696
+
697
+ /* PushMenu()
698
+ * ==========
699
+ * Adds the push menu functionality to the sidebar.
700
+ *
701
+ * @usage: $('.btn').pushMenu(options)
702
+ * or add [data-toggle="push-menu"] to any button
703
+ * Pass any option as data-option="value"
704
+ */
705
+ +function ($) {
706
+ 'use strict';
707
+
708
+ var DataKey = 'lte.pushmenu';
709
+
710
+ var Default = {
711
+ collapseScreenSize : 767,
712
+ expandOnHover : false,
713
+ expandTransitionDelay: 200
714
+ };
715
+
716
+ var Selector = {
717
+ collapsed : '.sidebar-collapse',
718
+ open : '.sidebar-open',
719
+ mainSidebar : '.main-sidebar',
720
+ contentWrapper: '.content-wrapper',
721
+ searchInput : '.sidebar-form .form-control',
722
+ button : '[data-toggle="push-menu"]',
723
+ mini : '.sidebar-mini',
724
+ expanded : '.sidebar-expanded-on-hover',
725
+ layoutFixed : '.fixed'
726
+ };
727
+
728
+ var ClassName = {
729
+ collapsed : 'sidebar-collapse',
730
+ open : 'sidebar-open',
731
+ mini : 'sidebar-mini',
732
+ expanded : 'sidebar-expanded-on-hover',
733
+ expandFeature: 'sidebar-mini-expand-feature',
734
+ layoutFixed : 'fixed'
735
+ };
736
+
737
+ var Event = {
738
+ expanded : 'expanded.pushMenu',
739
+ collapsed: 'collapsed.pushMenu'
740
+ };
741
+
742
+ // PushMenu Class Definition
743
+ // =========================
744
+ var PushMenu = function (options) {
745
+ this.options = options;
746
+ this.init();
747
+ };
748
+
749
+ PushMenu.prototype.init = function () {
750
+ if (this.options.expandOnHover
751
+ || ($('body').is(Selector.mini + Selector.layoutFixed))) {
752
+ this.expandOnHover();
753
+ $('body').addClass(ClassName.expandFeature);
754
+ }
755
+
756
+ $(Selector.contentWrapper).click(function () {
757
+ // Enable hide menu when clicking on the content-wrapper on small screens
758
+ if ($(window).width() <= this.options.collapseScreenSize && $('body').hasClass(ClassName.open)) {
759
+ this.close();
760
+ }
761
+ }.bind(this));
762
+
763
+ // __Fix for android devices
764
+ $(Selector.searchInput).click(function (e) {
765
+ e.stopPropagation();
766
+ });
767
+ };
768
+
769
+ PushMenu.prototype.toggle = function () {
770
+ var windowWidth = $(window).width();
771
+ var isOpen = !$('body').hasClass(ClassName.collapsed);
772
+
773
+ if (windowWidth <= this.options.collapseScreenSize) {
774
+ isOpen = $('body').hasClass(ClassName.open);
775
+ }
776
+
777
+ if (!isOpen) {
778
+ this.open();
779
+ } else {
780
+ this.close();
781
+ }
782
+ };
783
+
784
+ PushMenu.prototype.open = function () {
785
+ var windowWidth = $(window).width();
786
+
787
+ if (windowWidth > this.options.collapseScreenSize) {
788
+ $('body').removeClass(ClassName.collapsed)
789
+ .trigger($.Event(Event.expanded));
790
+ }
791
+ else {
792
+ $('body').addClass(ClassName.open)
793
+ .trigger($.Event(Event.expanded));
794
+ }
795
+ };
796
+
797
+ PushMenu.prototype.close = function () {
798
+ var windowWidth = $(window).width();
799
+ if (windowWidth > this.options.collapseScreenSize) {
800
+ $('body').addClass(ClassName.collapsed)
801
+ .trigger($.Event(Event.collapsed));
802
+ } else {
803
+ $('body').removeClass(ClassName.open + ' ' + ClassName.collapsed)
804
+ .trigger($.Event(Event.collapsed));
805
+ }
806
+ };
807
+
808
+ PushMenu.prototype.expandOnHover = function () {
809
+ $(Selector.mainSidebar).hover(function () {
810
+ if ($('body').is(Selector.mini + Selector.collapsed)
811
+ && $(window).width() > this.options.collapseScreenSize) {
812
+ this.expand();
813
+ }
814
+ }.bind(this), function () {
815
+ if ($('body').is(Selector.expanded)) {
816
+ this.collapse();
817
+ }
818
+ }.bind(this));
819
+ };
820
+
821
+ PushMenu.prototype.expand = function () {
822
+ setTimeout(function () {
823
+ $('body').removeClass(ClassName.collapsed)
824
+ .addClass(ClassName.expanded);
825
+ }, this.options.expandTransitionDelay);
826
+ };
827
+
828
+ PushMenu.prototype.collapse = function () {
829
+ setTimeout(function () {
830
+ $('body').removeClass(ClassName.expanded)
831
+ .addClass(ClassName.collapsed);
832
+ }, this.options.expandTransitionDelay);
833
+ };
834
+
835
+ // PushMenu Plugin Definition
836
+ // ==========================
837
+ function Plugin(option) {
838
+ return this.each(function () {
839
+ var $this = $(this);
840
+ var data = $this.data(DataKey);
841
+
842
+ if (!data) {
843
+ var options = $.extend({}, Default, $this.data(), typeof option == 'object' && option);
844
+ $this.data(DataKey, (data = new PushMenu(options)));
845
+ }
846
+
847
+ if (option === 'toggle') data.toggle();
848
+ });
849
+ }
850
+
851
+ var old = $.fn.pushMenu;
852
+
853
+ $.fn.pushMenu = Plugin;
854
+ $.fn.pushMenu.Constructor = PushMenu;
855
+
856
+ // No Conflict Mode
857
+ // ================
858
+ $.fn.pushMenu.noConflict = function () {
859
+ $.fn.pushMenu = old;
860
+ return this;
861
+ };
862
+
863
+ // Data API
864
+ // ========
865
+ $(document).on('click', Selector.button, function (e) {
866
+ e.preventDefault();
867
+ Plugin.call($(this), 'toggle');
868
+ });
869
+ $(window).on('load', function () {
870
+ Plugin.call($(Selector.button));
871
+ });
872
+ }(jQuery);
873
+
874
+
875
+ /* TodoList()
876
+ * =========
877
+ * Converts a list into a todoList.
878
+ *
879
+ * @Usage: $('.my-list').todoList(options)
880
+ * or add [data-widget="todo-list"] to the ul element
881
+ * Pass any option as data-option="value"
882
+ */
883
+ +function ($) {
884
+ 'use strict';
885
+
886
+ var DataKey = 'lte.todolist';
887
+
888
+ var Default = {
889
+ onCheck : function (item) {
890
+ return item;
891
+ },
892
+ onUnCheck: function (item) {
893
+ return item;
894
+ }
895
+ };
896
+
897
+ var Selector = {
898
+ data: '[data-widget="todo-list"]'
899
+ };
900
+
901
+ var ClassName = {
902
+ done: 'done'
903
+ };
904
+
905
+ // TodoList Class Definition
906
+ // =========================
907
+ var TodoList = function (element, options) {
908
+ this.element = element;
909
+ this.options = options;
910
+
911
+ this._setUpListeners();
912
+ };
913
+
914
+ TodoList.prototype.toggle = function (item) {
915
+ item.parents(Selector.li).first().toggleClass(ClassName.done);
916
+ if (!item.prop('checked')) {
917
+ this.unCheck(item);
918
+ return;
919
+ }
920
+
921
+ this.check(item);
922
+ };
923
+
924
+ TodoList.prototype.check = function (item) {
925
+ this.options.onCheck.call(item);
926
+ };
927
+
928
+ TodoList.prototype.unCheck = function (item) {
929
+ this.options.onUnCheck.call(item);
930
+ };
931
+
932
+ // Private
933
+
934
+ TodoList.prototype._setUpListeners = function () {
935
+ var that = this;
936
+ $(this.element).on('change ifChanged', 'input:checkbox', function () {
937
+ that.toggle($(this));
938
+ });
939
+ };
940
+
941
+ // Plugin Definition
942
+ // =================
943
+ function Plugin(option) {
944
+ return this.each(function () {
945
+ var $this = $(this);
946
+ var data = $this.data(DataKey);
947
+
948
+ if (!data) {
949
+ var options = $.extend({}, Default, $this.data(), typeof option == 'object' && option);
950
+ $this.data(DataKey, (data = new TodoList($this, options)));
951
+ }
952
+
953
+ if (typeof data == 'string') {
954
+ if (typeof data[option] == 'undefined') {
955
+ throw new Error('No method named ' + option);
956
+ }
957
+ data[option]();
958
+ }
959
+ });
960
+ }
961
+
962
+ var old = $.fn.todoList;
963
+
964
+ $.fn.todoList = Plugin;
965
+ $.fn.todoList.Constructor = TodoList;
966
+
967
+ // No Conflict Mode
968
+ // ================
969
+ $.fn.todoList.noConflict = function () {
970
+ $.fn.todoList = old;
971
+ return this;
972
+ };
973
+
974
+ // TodoList Data API
975
+ // =================
976
+ $(window).on('load', function () {
977
+ $(Selector.data).each(function () {
978
+ Plugin.call($(this));
979
+ });
980
+ });
981
+
982
+ }(jQuery);
983
+
984
+
985
+ /* Tree()
986
+ * ======
987
+ * Converts a nested list into a multilevel
988
+ * tree view menu.
989
+ *
990
+ * @Usage: $('.my-menu').tree(options)
991
+ * or add [data-widget="tree"] to the ul element
992
+ * Pass any option as data-option="value"
993
+ */
994
+ +function ($) {
995
+ 'use strict';
996
+
997
+ var DataKey = 'lte.tree';
998
+
999
+ var Default = {
1000
+ animationSpeed: 500,
1001
+ accordion : true,
1002
+ followLink : false,
1003
+ trigger : '.treeview a'
1004
+ };
1005
+
1006
+ var Selector = {
1007
+ tree : '.tree',
1008
+ treeview : '.treeview',
1009
+ treeviewMenu: '.treeview-menu',
1010
+ open : '.menu-open, .active',
1011
+ li : 'li',
1012
+ data : '[data-widget="tree"]',
1013
+ active : '.active'
1014
+ };
1015
+
1016
+ var ClassName = {
1017
+ open: 'menu-open',
1018
+ tree: 'tree'
1019
+ };
1020
+
1021
+ var Event = {
1022
+ collapsed: 'collapsed.tree',
1023
+ expanded : 'expanded.tree'
1024
+ };
1025
+
1026
+ // Tree Class Definition
1027
+ // =====================
1028
+ var Tree = function (element, options) {
1029
+ this.element = element;
1030
+ this.options = options;
1031
+
1032
+ $(this.element).addClass(ClassName.tree);
1033
+
1034
+ $(Selector.treeview + Selector.active, this.element).addClass(ClassName.open);
1035
+
1036
+ this._setUpListeners();
1037
+ };
1038
+
1039
+ Tree.prototype.toggle = function (link, event) {
1040
+ var treeviewMenu = link.next(Selector.treeviewMenu);
1041
+ var parentLi = link.parent();
1042
+ var isOpen = parentLi.hasClass(ClassName.open);
1043
+
1044
+ if (!parentLi.is(Selector.treeview)) {
1045
+ return;
1046
+ }
1047
+
1048
+ if (!this.options.followLink || link.attr('href') === '#') {
1049
+ event.preventDefault();
1050
+ }
1051
+
1052
+ if (isOpen) {
1053
+ this.collapse(treeviewMenu, parentLi);
1054
+ } else {
1055
+ this.expand(treeviewMenu, parentLi);
1056
+ }
1057
+ };
1058
+
1059
+ Tree.prototype.expand = function (tree, parent) {
1060
+ var expandedEvent = $.Event(Event.expanded);
1061
+
1062
+ if (this.options.accordion) {
1063
+ var openMenuLi = parent.siblings(Selector.open);
1064
+ var openTree = openMenuLi.children(Selector.treeviewMenu);
1065
+ this.collapse(openTree, openMenuLi);
1066
+ }
1067
+
1068
+ parent.addClass(ClassName.open);
1069
+ tree.slideDown(this.options.animationSpeed, function () {
1070
+ $(this.element).trigger(expandedEvent);
1071
+ }.bind(this));
1072
+ };
1073
+
1074
+ Tree.prototype.collapse = function (tree, parentLi) {
1075
+ var collapsedEvent = $.Event(Event.collapsed);
1076
+
1077
+ tree.find(Selector.open).removeClass(ClassName.open);
1078
+ parentLi.removeClass(ClassName.open);
1079
+ tree.slideUp(this.options.animationSpeed, function () {
1080
+ tree.find(Selector.open + ' > ' + Selector.treeview).slideUp();
1081
+ $(this.element).trigger(collapsedEvent);
1082
+ }.bind(this));
1083
+ };
1084
+
1085
+ // Private
1086
+
1087
+ Tree.prototype._setUpListeners = function () {
1088
+ var that = this;
1089
+
1090
+ $(this.element).on('click', this.options.trigger, function (event) {
1091
+ that.toggle($(this), event);
1092
+ });
1093
+ };
1094
+
1095
+ // Plugin Definition
1096
+ // =================
1097
+ function Plugin(option) {
1098
+ return this.each(function () {
1099
+ var $this = $(this);
1100
+ var data = $this.data(DataKey);
1101
+
1102
+ if (!data) {
1103
+ var options = $.extend({}, Default, $this.data(), typeof option == 'object' && option);
1104
+ $this.data(DataKey, new Tree($this, options));
1105
+ }
1106
+ });
1107
+ }
1108
+
1109
+ var old = $.fn.tree;
1110
+
1111
+ $.fn.tree = Plugin;
1112
+ $.fn.tree.Constructor = Tree;
1113
+
1114
+ // No Conflict Mode
1115
+ // ================
1116
+ $.fn.tree.noConflict = function () {
1117
+ $.fn.tree = old;
1118
+ return this;
1119
+ };
1120
+
1121
+ // Tree Data API
1122
+ // =============
1123
+ $(window).on('load', function () {
1124
+ $(Selector.data).each(function () {
1125
+ Plugin.call($(this));
1126
+ });
1127
+ });
1128
+
1129
+ }(jQuery);