phcthemes_admin_panel_pack 0.16.0 → 0.17.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (243) hide show
  1. checksums.yaml +4 -4
  2. data/MIT-LICENSE +1 -1
  3. data/Rakefile +0 -5
  4. data/lib/phcthemes_admin_panel_pack/railtie.rb +4 -0
  5. data/lib/phcthemes_admin_panel_pack/version.rb +1 -1
  6. data/lib/phcthemes_admin_panel_pack.rb +1 -1
  7. metadata +10 -239
  8. data/app/assets/config/phcthemes_admin_panel_pack_manifest.js +0 -3
  9. data/app/assets/javascripts/common/backstretch/jquery.backstretch.js +0 -1602
  10. data/app/assets/javascripts/common/bootstrap/bootstrap.bundle.js +0 -7013
  11. data/app/assets/javascripts/common/bootstrap/bootstrap.three.js +0 -2377
  12. data/app/assets/javascripts/common/bootstrap-datepicker/bootstrap-datepicker.js +0 -2039
  13. data/app/assets/javascripts/common/bootstrap-markdown/bootstrap-markdown.js +0 -1390
  14. data/app/assets/javascripts/common/bootstrap-select/bootstrap-select.js +0 -3139
  15. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-am_ET.js +0 -46
  16. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-am_ET.js.map +0 -1
  17. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-am_ET.min.js +0 -8
  18. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ar_AR.js +0 -51
  19. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ar_AR.js.map +0 -1
  20. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ar_AR.min.js +0 -8
  21. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-bg_BG.js +0 -46
  22. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-bg_BG.js.map +0 -1
  23. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-bg_BG.min.js +0 -8
  24. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-cs_CZ.js +0 -39
  25. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-cs_CZ.js.map +0 -1
  26. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-cs_CZ.min.js +0 -8
  27. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-da_DK.js +0 -46
  28. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-da_DK.js.map +0 -1
  29. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-da_DK.min.js +0 -8
  30. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-de_DE.js +0 -46
  31. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-de_DE.js.map +0 -1
  32. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-de_DE.min.js +0 -8
  33. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-en_US.js +0 -46
  34. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-en_US.js.map +0 -1
  35. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-en_US.min.js +0 -8
  36. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-es_CL.js +0 -39
  37. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-es_CL.js.map +0 -1
  38. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-es_CL.min.js +0 -8
  39. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-es_ES.js +0 -39
  40. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-es_ES.js.map +0 -1
  41. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-es_ES.min.js +0 -8
  42. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-et_EE.js +0 -46
  43. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-et_EE.js.map +0 -1
  44. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-et_EE.min.js +0 -8
  45. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-eu.js +0 -39
  46. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-eu.js.map +0 -1
  47. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-eu.min.js +0 -8
  48. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fa_IR.js +0 -39
  49. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fa_IR.js.map +0 -1
  50. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fa_IR.min.js +0 -8
  51. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fi_FI.js +0 -46
  52. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fi_FI.js.map +0 -1
  53. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fi_FI.min.js +0 -8
  54. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fr_FR.js +0 -46
  55. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fr_FR.js.map +0 -1
  56. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fr_FR.min.js +0 -8
  57. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-hr_HR.js +0 -46
  58. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-hr_HR.js.map +0 -1
  59. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-hr_HR.min.js +0 -8
  60. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-hu_HU.js +0 -46
  61. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-hu_HU.js.map +0 -1
  62. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-hu_HU.min.js +0 -8
  63. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-id_ID.js +0 -39
  64. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-id_ID.js.map +0 -1
  65. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-id_ID.min.js +0 -8
  66. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-it_IT.js +0 -41
  67. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-it_IT.js.map +0 -1
  68. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-it_IT.min.js +0 -8
  69. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ja_JP.js +0 -39
  70. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ja_JP.js.map +0 -1
  71. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ja_JP.min.js +0 -8
  72. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-kh_KM.js +0 -46
  73. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-kh_KM.js.map +0 -1
  74. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-kh_KM.min.js +0 -8
  75. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ko_KR.js +0 -46
  76. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ko_KR.js.map +0 -1
  77. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ko_KR.min.js +0 -8
  78. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-lt_LT.js +0 -46
  79. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-lt_LT.js.map +0 -1
  80. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-lt_LT.min.js +0 -8
  81. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-lv_LV.js +0 -46
  82. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-lv_LV.js.map +0 -1
  83. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-lv_LV.min.js +0 -8
  84. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-nb_NO.js +0 -46
  85. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-nb_NO.js.map +0 -1
  86. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-nb_NO.min.js +0 -8
  87. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-nl_NL.js +0 -39
  88. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-nl_NL.js.map +0 -1
  89. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-nl_NL.min.js +0 -8
  90. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pl_PL.js +0 -39
  91. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pl_PL.js.map +0 -1
  92. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pl_PL.min.js +0 -8
  93. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pt_BR.js +0 -39
  94. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pt_BR.js.map +0 -1
  95. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pt_BR.min.js +0 -8
  96. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pt_PT.js +0 -39
  97. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pt_PT.js.map +0 -1
  98. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pt_PT.min.js +0 -8
  99. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ro_RO.js +0 -40
  100. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ro_RO.js.map +0 -1
  101. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ro_RO.min.js +0 -8
  102. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ru_RU.js +0 -40
  103. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ru_RU.js.map +0 -1
  104. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ru_RU.min.js +0 -8
  105. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sk_SK.js +0 -39
  106. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sk_SK.js.map +0 -1
  107. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sk_SK.min.js +0 -8
  108. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sl_SI.js +0 -44
  109. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sl_SI.js.map +0 -1
  110. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sl_SI.min.js +0 -8
  111. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sv_SE.js +0 -46
  112. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sv_SE.js.map +0 -1
  113. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sv_SE.min.js +0 -8
  114. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-tr_TR.js +0 -46
  115. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-tr_TR.js.map +0 -1
  116. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-tr_TR.min.js +0 -8
  117. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ua_UA.js +0 -39
  118. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ua_UA.js.map +0 -1
  119. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ua_UA.min.js +0 -8
  120. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-vi_VN.js +0 -46
  121. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-vi_VN.js.map +0 -1
  122. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-vi_VN.min.js +0 -8
  123. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-zh_CN.js +0 -39
  124. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-zh_CN.js.map +0 -1
  125. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-zh_CN.min.js +0 -8
  126. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-zh_TW.js +0 -39
  127. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-zh_TW.js.map +0 -1
  128. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-zh_TW.min.js +0 -8
  129. data/app/assets/javascripts/common/chartjs/chart.js +0 -14680
  130. data/app/assets/javascripts/common/custom/custom.js +0 -0
  131. data/app/assets/javascripts/common/datatables/datatables.js +0 -15310
  132. data/app/assets/javascripts/common/daterangepicker/daterangepicker.js +0 -1565
  133. data/app/assets/javascripts/common/fastclick/fastclick.js +0 -841
  134. data/app/assets/javascripts/common/flexslider/jquery.flexslider.js +0 -1252
  135. data/app/assets/javascripts/common/greenstock/greensock.js +0 -36
  136. data/app/assets/javascripts/common/icheck/icheck.js +0 -509
  137. data/app/assets/javascripts/common/imagesloaded/imagesloaded.pkgd.js +0 -497
  138. data/app/assets/javascripts/common/isotope/isotope.pkgd.js +0 -3563
  139. data/app/assets/javascripts/common/jquery/jquery-3.4.1.js +0 -10598
  140. data/app/assets/javascripts/common/jquery-countdown/jquery.countdown.js +0 -246
  141. data/app/assets/javascripts/common/jquery-filterizer/jquery.filterizr.min.js +0 -1
  142. data/app/assets/javascripts/common/jquery-jvectormap/jquery-jvectormap.js +0 -44
  143. data/app/assets/javascripts/common/jquery-placeholder/jquery.placeholder.js +0 -281
  144. data/app/assets/javascripts/common/jquery-slimscroll/jquery.slimscroll.js +0 -474
  145. data/app/assets/javascripts/common/jquery-sparkline/jquery.sparkline.js +0 -3054
  146. data/app/assets/javascripts/common/jquery-ui/jquery-ui.js +0 -18706
  147. data/app/assets/javascripts/common/jquery-validation/jquery.validate.js +0 -1650
  148. data/app/assets/javascripts/common/jqvmap/jquery.vmap.js +0 -1281
  149. data/app/assets/javascripts/common/jqvmap/jquery.vmap.min.js +0 -10
  150. data/app/assets/javascripts/common/jqvmap/maps/continents/jquery.vmap.africa.js +0 -2
  151. data/app/assets/javascripts/common/jqvmap/maps/continents/jquery.vmap.asia.js +0 -2
  152. data/app/assets/javascripts/common/jqvmap/maps/continents/jquery.vmap.australia.js +0 -2
  153. data/app/assets/javascripts/common/jqvmap/maps/continents/jquery.vmap.europe.js +0 -2
  154. data/app/assets/javascripts/common/jqvmap/maps/continents/jquery.vmap.north-america.js +0 -2
  155. data/app/assets/javascripts/common/jqvmap/maps/continents/jquery.vmap.south-america.js +0 -2
  156. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.algeria.js +0 -2
  157. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.argentina.js +0 -1
  158. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.brazil.js +0 -2
  159. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.canada.js +0 -2
  160. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.europe.js +0 -2
  161. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.france.js +0 -1
  162. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.germany.js +0 -2
  163. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.greece.js +0 -1
  164. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.iran.js +0 -6
  165. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.iraq.js +0 -1
  166. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.russia.js +0 -2
  167. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.tunisia.js +0 -2
  168. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.turkey.js +0 -11
  169. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.usa.js +0 -2
  170. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.world.js +0 -2
  171. data/app/assets/javascripts/common/js-cookie/js.cookie.js +0 -165
  172. data/app/assets/javascripts/common/layerslider/layerslider.kreaturamedia.jquery.js +0 -13
  173. data/app/assets/javascripts/common/layerslider/layerslider.origami.js +0 -13
  174. data/app/assets/javascripts/common/layerslider/layerslider.timeline.js +0 -13
  175. data/app/assets/javascripts/common/layerslider/layerslider.transitions.js +0 -13
  176. data/app/assets/javascripts/common/leaflet/leaflet.js +0 -5
  177. data/app/assets/javascripts/common/magnific-popup/jquery.magnific-popup.js +0 -1860
  178. data/app/assets/javascripts/common/mapbox/mapbox.js +0 -51
  179. data/app/assets/javascripts/common/metismenu/metisMenu.js +0 -340
  180. data/app/assets/javascripts/common/moderizer/modernizr.js +0 -11
  181. data/app/assets/javascripts/common/owl-carousel/owl.carousel.js +0 -3448
  182. data/app/assets/javascripts/common/pace/pace.js +0 -935
  183. data/app/assets/javascripts/common/paroller/jquery.paroller.js +0 -228
  184. data/app/assets/javascripts/common/particlejs/particles.js +0 -1541
  185. data/app/assets/javascripts/common/perfect-scrollbar/perfect-scrollbar.common.js +0 -1318
  186. data/app/assets/javascripts/common/perfect-scrollbar/perfect-scrollbar.esm.js +0 -1316
  187. data/app/assets/javascripts/common/perfect-scrollbar/perfect-scrollbar.js +0 -1324
  188. data/app/assets/javascripts/common/plyr/plyr.js +0 -9137
  189. data/app/assets/javascripts/common/rangeslider/rangeslider.js +0 -498
  190. data/app/assets/javascripts/common/retina/retina.js +0 -100
  191. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.actions.js +0 -386
  192. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.carousel.js +0 -365
  193. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.kenburn.js +0 -199
  194. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.layeranimation.js +0 -2524
  195. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.migration.js +0 -260
  196. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.navigation.js +0 -1156
  197. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.parallax.js +0 -465
  198. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.slideanims.js +0 -1447
  199. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.video.js +0 -1464
  200. data/app/assets/javascripts/common/rev-slider/jquery.themepunch.revolution.js +0 -3286
  201. data/app/assets/javascripts/common/rev-slider/jquery.themepunch.tools.min.js +0 -8710
  202. data/app/assets/javascripts/common/scrollup/jquery.scrollUp.js +0 -168
  203. data/app/assets/javascripts/common/select2/select2.full.js +0 -6597
  204. data/app/assets/javascripts/common/selectbox/jquery.selectBox.js +0 -1092
  205. data/app/assets/javascripts/common/smooth-scroll/SmoothScroll.js +0 -788
  206. data/app/assets/javascripts/common/spectrum/spectrum.js +0 -2323
  207. data/app/assets/javascripts/common/stepper/jquery.fs.stepper.js +0 -339
  208. data/app/assets/javascripts/common/swiper/swiper.js +0 -8124
  209. data/app/assets/javascripts/common/toaster/toastr.js +0 -476
  210. data/app/assets/javascripts/common/typed/typed.js +0 -1045
  211. data/app/assets/javascripts/common/visable/jquery.visible.js +0 -68
  212. data/app/assets/javascripts/common/waypoints/jquery.waypoints.js +0 -662
  213. data/app/assets/javascripts/phcthemes_admin_panel_pack_adminlte.js +0 -12
  214. data/app/assets/javascripts/phcthemes_admin_panel_pack_basic.js +0 -5
  215. data/app/assets/javascripts/phcthemes_admin_panel_pack_boomerang.js +0 -0
  216. data/app/assets/javascripts/phcthemes_admin_panel_pack_coloradmin.js +0 -10
  217. data/app/assets/javascripts/phcthemes_admin_panel_pack_inspinia.js +0 -10
  218. data/app/assets/javascripts/phcthemes_admin_panel_pack_metronic.js +0 -4
  219. data/app/assets/javascripts/phcthemes_admin_panel_pack_quilpro.js +0 -5
  220. data/app/assets/javascripts/phcthemes_admin_panel_pack_starlight.js +0 -5
  221. data/app/assets/javascripts/themes/adminlte/custom/custom.js +0 -0
  222. data/app/assets/javascripts/themes/adminlte/theme/adminlte.js +0 -1141
  223. data/app/assets/javascripts/themes/boomerang/custom/custom.1.js +0 -0
  224. data/app/assets/javascripts/themes/boomerang/custom/custom.js +0 -0
  225. data/app/assets/javascripts/themes/coloradmin/theme/apps.js +0 -1650
  226. data/app/assets/javascripts/themes/coloradmin/theme/default.js +0 -152
  227. data/app/assets/javascripts/themes/inspinia/custom/custom.js +0 -0
  228. data/app/assets/javascripts/themes/inspinia/theme/inspinia.js +0 -279
  229. data/app/assets/javascripts/themes/metronic/theme/scripts.bundle.js +0 -9916
  230. data/app/assets/javascripts/themes/metronic/theme/vendors.bundle.js +0 -91352
  231. data/app/assets/stylesheets/common/custom/custom.scss +0 -0
  232. data/app/assets/stylesheets/phcthemes_admin_panel_pack_adminlte.scss +0 -13
  233. data/app/assets/stylesheets/phcthemes_admin_panel_pack_basic.scss +0 -6
  234. data/app/assets/stylesheets/phcthemes_admin_panel_pack_boomerang.scss +0 -24
  235. data/app/assets/stylesheets/phcthemes_admin_panel_pack_coloradmin.scss +0 -15
  236. data/app/assets/stylesheets/phcthemes_admin_panel_pack_inspinia.scss +0 -15
  237. data/app/assets/stylesheets/phcthemes_admin_panel_pack_metronic.scss +0 -7
  238. data/app/assets/stylesheets/phcthemes_admin_panel_pack_quilpro.scss +0 -16
  239. data/app/assets/stylesheets/phcthemes_admin_panel_pack_starlight.scss +0 -12
  240. data/app/assets/stylesheets/themes/adminlte/custom/custom.scss +0 -0
  241. data/app/assets/stylesheets/themes/boomerang/custom/custom.scss +0 -0
  242. data/app/assets/stylesheets/themes/coloradmin/custom/custom.scss +0 -0
  243. data/lib/phcthemes_admin_panel_pack/engine.rb +0 -19
@@ -1,1650 +0,0 @@
1
- /*
2
- Template Name: Color Admin - Responsive Admin Dashboard Template build with Twitter Bootstrap 4
3
- Version: 4.3.0
4
- Author: Sean Ngu
5
- Website: http://www.seantheme.com/color-admin-v4.3/admin/
6
- ----------------------------
7
- APPS CONTENT TABLE
8
- ----------------------------
9
-
10
- <!-- ======== GLOBAL SCRIPT SETTING ======== -->
11
- 01. Handle Scrollbar
12
- 02. Handle Sidebar - Menu
13
- 03. Handle Sidebar - Mobile View Toggle
14
- 04. Handle Sidebar - Minify / Expand
15
- 05. Handle Page Load - Fade in
16
- 06. Handle Panel - Remove / Reload / Collapse / Expand
17
- 07. Handle Panel - Draggable
18
- 08. Handle Tooltip & Popover Activation
19
- 09. Handle Scroll to Top Button Activation
20
-
21
- <!-- ======== Added in V1.2 ======== -->
22
- 10. Handle Theme & Page Structure Configuration - added in V1.2
23
- 11. Handle Theme Panel Expand - added in V1.2
24
- 12. Handle After Page Load Add Class Function - added in V1.2
25
-
26
- <!-- ======== Added in V1.5 ======== -->
27
- 13. Handle Save Panel Position Function - added in V1.5
28
- 14. Handle Draggable Panel Local Storage Function - added in V1.5
29
- 15. Handle Reset Local Storage - added in V1.5
30
-
31
- <!-- ======== Added in V1.6 ======== -->
32
- 16. Handle IE Full Height Page Compatibility - added in V1.6
33
- 17. Handle Unlimited Nav Tabs - added in V1.6
34
-
35
- <!-- ======== Added in V1.9 ======== -->
36
- 18. Handle Top Menu - Unlimited Top Menu Render - added in V1.9
37
- 19. Handle Top Menu - Sub Menu Toggle - added in V1.9
38
- 20. Handle Top Menu - Mobile Sub Menu Toggle - added in V1.9
39
- 21. Handle Top Menu - Mobile Top Menu Toggle - added in V1.9
40
- 22. Handle Clear Sidebar Selection & Hide Mobile Menu - added in V1.9
41
-
42
- <!-- ======== Added in V4.0 ======== -->
43
- 23. Handle Check Bootstrap Version - added in V4.0
44
- 24. Handle Page Scroll Class - added in V4.0
45
- 25. Handle Toggle Navbar Profile - added in V4.0
46
- 26. Handle Sidebar Scroll Memory - added in V4.0
47
- 27. Handle Sidebar Minify Sub Menu - added in V4.0
48
- 28. Handle Ajax Mode - added in V4.0
49
- 29. Handle Float Navbar Search - added in V4.0
50
-
51
- <!-- ======== APPLICATION SETTING ======== -->
52
- Application Controller
53
- */
54
-
55
-
56
-
57
- /* 01. Handle Scrollbar
58
- ------------------------------------------------ */
59
- var handleSlimScroll = function() {
60
- "use strict";
61
- $.when($('[data-scrollbar=true]').each( function() {
62
- generateSlimScroll($(this));
63
- })).done(function() {
64
- $('[data-scrollbar="true"]').mouseover();
65
- });
66
- };
67
- var generateSlimScroll = function(element) {
68
- if ($(element).attr('data-init')) {
69
- return;
70
- }
71
- var dataHeight = $(element).attr('data-height');
72
- dataHeight = (!dataHeight) ? $(element).height() : dataHeight;
73
-
74
- var scrollBarOption = {
75
- height: dataHeight
76
- };
77
- if(/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)) {
78
- $(element).css('height', dataHeight);
79
- $(element).css('overflow-x','scroll');
80
- } else {
81
- $(element).slimScroll(scrollBarOption);
82
- }
83
- $(element).attr('data-init', true);
84
- $('.slimScrollBar').hide();
85
- };
86
-
87
-
88
- /* 02. Handle Sidebar - Menu
89
- ------------------------------------------------ */
90
- var handleSidebarMenu = function() {
91
- "use strict";
92
-
93
- var expandTime = ($('.sidebar').attr('data-disable-slide-animation')) ? 0 : 250;
94
- $('.sidebar .nav > .has-sub > a').click(function() {
95
- var target = $(this).next('.sub-menu');
96
- var otherMenu = $('.sidebar .nav > li.has-sub > .sub-menu').not(target);
97
-
98
- if ($('.page-sidebar-minified').length === 0) {
99
- $(otherMenu).closest('li').addClass('closing');
100
- $(otherMenu).slideUp(expandTime, function() {
101
- $(otherMenu).closest('li').addClass('closed').removeClass('expand closing');
102
- });
103
- if ($(target).is(':visible')) {
104
- $(target).closest('li').addClass('closing').removeClass('expand');
105
- } else {
106
- $(target).closest('li').addClass('expanding').removeClass('closed');
107
- }
108
- $(target).slideToggle(expandTime, function() {
109
- var targetLi = $(this).closest('li');
110
- if (!$(target).is(':visible')) {
111
- $(targetLi).addClass('closed');
112
- $(targetLi).removeClass('expand');
113
- } else {
114
- $(targetLi).addClass('expand');
115
- $(targetLi).removeClass('closed');
116
- }
117
- $(targetLi).removeClass('expanding closing');
118
- });
119
- }
120
- });
121
- $('.sidebar .nav > .has-sub .sub-menu li.has-sub > a').click(function() {
122
- if ($('.page-sidebar-minified').length === 0) {
123
- var target = $(this).next('.sub-menu');
124
- if ($(target).is(':visible')) {
125
- $(target).closest('li').addClass('closing').removeClass('expand');
126
- } else {
127
- $(target).closest('li').addClass('expanding').removeClass('closed');
128
- }
129
- $(target).slideToggle(expandTime, function() {
130
- var targetLi = $(this).closest('li');
131
- if (!$(target).is(':visible')) {
132
- $(targetLi).addClass('closed');
133
- $(targetLi).removeClass('expand');
134
- } else {
135
- $(targetLi).addClass('expand');
136
- $(targetLi).removeClass('closed');
137
- }
138
- $(targetLi).removeClass('expanding closing');
139
- });
140
- }
141
- });
142
- };
143
-
144
-
145
- /* 03. Handle Sidebar - Mobile View Toggle
146
- ------------------------------------------------ */
147
- var handleMobileSidebarToggle = function() {
148
- var sidebarProgress = false;
149
-
150
- $('.sidebar').bind('click touchstart', function(e) {
151
- if ($(e.target).closest('.sidebar').length !== 0) {
152
- sidebarProgress = true;
153
- } else {
154
- sidebarProgress = false;
155
- e.stopPropagation();
156
- }
157
- });
158
-
159
- $(document).bind('click touchstart', function(e) {
160
- if ($(e.target).closest('.sidebar').length === 0) {
161
- sidebarProgress = false;
162
- }
163
- if ($(e.target).closest('#float-sub-menu').length !== 0) {
164
- sidebarProgress = true;
165
- }
166
-
167
- if (!e.isPropagationStopped() && sidebarProgress !== true) {
168
- if ($('#page-container').hasClass('page-sidebar-toggled')) {
169
- sidebarProgress = true;
170
- $('#page-container').removeClass('page-sidebar-toggled');
171
- }
172
- if ($(window).width() <= 767) {
173
- if ($('#page-container').hasClass('page-right-sidebar-toggled')) {
174
- sidebarProgress = true;
175
- $('#page-container').removeClass('page-right-sidebar-toggled');
176
- }
177
- }
178
- }
179
- });
180
-
181
- $('[data-click=right-sidebar-toggled]').click(function(e) {
182
- e.stopPropagation();
183
- var targetContainer = '#page-container';
184
- var targetClass = 'page-right-sidebar-collapsed';
185
- targetClass = ($(window).width() < 979) ? 'page-right-sidebar-toggled' : targetClass;
186
- if ($(targetContainer).hasClass(targetClass)) {
187
- $(targetContainer).removeClass(targetClass);
188
- } else if (sidebarProgress !== true) {
189
- $(targetContainer).addClass(targetClass);
190
- } else {
191
- sidebarProgress = false;
192
- }
193
- if ($(window).width() < 480) {
194
- $('#page-container').removeClass('page-sidebar-toggled');
195
- }
196
- $(window).trigger('resize');
197
- });
198
-
199
- $('[data-click=sidebar-toggled]').click(function(e) {
200
- e.stopPropagation();
201
- var sidebarClass = 'page-sidebar-toggled';
202
- var targetContainer = '#page-container';
203
-
204
- if ($(targetContainer).hasClass(sidebarClass)) {
205
- $(targetContainer).removeClass(sidebarClass);
206
- } else if (sidebarProgress !== true) {
207
- $(targetContainer).addClass(sidebarClass);
208
- } else {
209
- sidebarProgress = false;
210
- }
211
- if ($(window).width() < 480) {
212
- $('#page-container').removeClass('page-right-sidebar-toggled');
213
- }
214
- });
215
- };
216
-
217
-
218
- /* 04. Handle Sidebar - Minify / Expand
219
- ------------------------------------------------ */
220
- var handleSidebarMinify = function() {
221
- $(document).on('click', '[data-click=sidebar-minify]', function(e) {
222
- e.preventDefault();
223
- var sidebarClass = 'page-sidebar-minified';
224
- var targetContainer = '#page-container';
225
-
226
- if ($(targetContainer).hasClass(sidebarClass)) {
227
- $(targetContainer).removeClass(sidebarClass);
228
- } else {
229
- $(targetContainer).addClass(sidebarClass);
230
-
231
- if(/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)) {
232
- $('#sidebar [data-scrollbar="true"]').css('margin-top','0');
233
- $('#sidebar [data-scrollbar="true"]').css('overflow-x', 'scroll');
234
- }
235
- }
236
- $(window).trigger('resize');
237
- });
238
- };
239
-
240
-
241
- /* 05. Handle Page Load - Fade in
242
- ------------------------------------------------ */
243
- var handlePageContentView = function() {
244
- "use strict";
245
-
246
- var hideClass = '';
247
- var showClass = '';
248
- var removeClass = '';
249
- var bootstrapVersion = handleCheckBootstrapVersion();
250
-
251
- if (bootstrapVersion >= 3 && bootstrapVersion < 4) {
252
- hideClass = 'hide';
253
- showClass = 'in';
254
- } else if (bootstrapVersion >= 4 && bootstrapVersion < 5) {
255
- hideClass = 'd-none';
256
- showClass = 'show';
257
- }
258
- $(window).on('load', function() {
259
- $.when($('#page-loader').addClass(hideClass)).done(function() {
260
- $('#page-container').addClass(showClass);
261
- });
262
- });
263
- };
264
-
265
-
266
- /* 06. Handle Panel - Remove / Reload / Collapse / Expand
267
- ------------------------------------------------ */
268
- var panelActionRunning = false;
269
- var handlePanelAction = function() {
270
- "use strict";
271
-
272
- if (panelActionRunning) {
273
- return false;
274
- }
275
- panelActionRunning = true;
276
-
277
- // remove
278
- $(document).on('hover', '[data-click=panel-remove]', function(e) {
279
- if (!$(this).attr('data-init')) {
280
- $(this).tooltip({
281
- title: 'Remove',
282
- placement: 'bottom',
283
- trigger: 'hover',
284
- container: 'body'
285
- });
286
- $(this).tooltip('show');
287
- $(this).attr('data-init', true);
288
- }
289
- });
290
- $(document).on('click', '[data-click=panel-remove]', function(e) {
291
- e.preventDefault();
292
- var bootstrapVersion = handleCheckBootstrapVersion();
293
-
294
- if (bootstrapVersion >= 4 && bootstrapVersion < 5) {
295
- $(this).tooltip('dispose');
296
- } else {
297
- $(this).tooltip('destroy');
298
- }
299
- $(this).closest('.panel').remove();
300
- });
301
-
302
- // collapse
303
- $(document).on('hover', '[data-click=panel-collapse]', function(e) {
304
- if (!$(this).attr('data-init')) {
305
- $(this).tooltip({
306
- title: 'Collapse / Expand',
307
- placement: 'bottom',
308
- trigger: 'hover',
309
- container: 'body'
310
- });
311
- $(this).tooltip('show');
312
- $(this).attr('data-init', true);
313
- }
314
- });
315
- $(document).on('click', '[data-click=panel-collapse]', function(e) {
316
- e.preventDefault();
317
- $(this).closest('.panel').find('.panel-body').slideToggle();
318
- });
319
-
320
- // reload
321
- $(document).on('hover', '[data-click=panel-reload]', function(e) {
322
- if (!$(this).attr('data-init')) {
323
- $(this).tooltip({
324
- title: 'Reload',
325
- placement: 'bottom',
326
- trigger: 'hover',
327
- container: 'body'
328
- });
329
- $(this).tooltip('show');
330
- $(this).attr('data-init', true);
331
- }
332
- });
333
- $(document).on('click', '[data-click=panel-reload]', function(e) {
334
- e.preventDefault();
335
- var target = $(this).closest('.panel');
336
- if (!$(target).hasClass('panel-loading')) {
337
- var targetBody = $(target).find('.panel-body');
338
- var spinnerHtml = '<div class="panel-loader"><span class="spinner-small"></span></div>';
339
- $(target).addClass('panel-loading');
340
- $(targetBody).prepend(spinnerHtml);
341
- setTimeout(function() {
342
- $(target).removeClass('panel-loading');
343
- $(target).find('.panel-loader').remove();
344
- }, 2000);
345
- }
346
- });
347
-
348
- // expand
349
- $(document).on('hover', '[data-click=panel-expand]', function(e) {
350
- if (!$(this).attr('data-init')) {
351
- $(this).tooltip({
352
- title: 'Expand / Compress',
353
- placement: 'bottom',
354
- trigger: 'hover',
355
- container: 'body'
356
- });
357
- $(this).tooltip('show');
358
- $(this).attr('data-init', true);
359
- }
360
- });
361
- $(document).on('click', '[data-click=panel-expand]', function(e) {
362
- e.preventDefault();
363
- var target = $(this).closest('.panel');
364
- var targetBody = $(target).find('.panel-body');
365
- var targetTop = 40;
366
- if ($(targetBody).length !== 0) {
367
- var targetOffsetTop = $(target).offset().top;
368
- var targetBodyOffsetTop = $(targetBody).offset().top;
369
- targetTop = targetBodyOffsetTop - targetOffsetTop;
370
- }
371
-
372
- if ($('body').hasClass('panel-expand') && $(target).hasClass('panel-expand')) {
373
- $('body, .panel').removeClass('panel-expand');
374
- $('.panel').removeAttr('style');
375
- $(targetBody).removeAttr('style');
376
- } else {
377
- $('body').addClass('panel-expand');
378
- $(this).closest('.panel').addClass('panel-expand');
379
-
380
- if ($(targetBody).length !== 0 && targetTop != 40) {
381
- var finalHeight = 40;
382
- $(target).find(' > *').each(function() {
383
- var targetClass = $(this).attr('class');
384
-
385
- if (targetClass != 'panel-heading' && targetClass != 'panel-body') {
386
- finalHeight += $(this).height() + 30;
387
- }
388
- });
389
- if (finalHeight != 40) {
390
- $(targetBody).css('top', finalHeight + 'px');
391
- }
392
- }
393
- }
394
- $(window).trigger('resize');
395
- });
396
- };
397
-
398
-
399
- /* 07. Handle Panel - Draggable
400
- ------------------------------------------------ */
401
- var handleDraggablePanel = function() {
402
- "use strict";
403
- var target = $('.panel:not([data-sortable="false"])').parent('[class*=col]');
404
- var targetHandle = '.panel-heading';
405
- var connectedTarget = '.row > [class*=col]';
406
-
407
- $(target).sortable({
408
- handle: targetHandle,
409
- connectWith: connectedTarget,
410
- stop: function(event, ui) {
411
- ui.item.find('.panel-title').append('<i class="fa fa-refresh fa-spin m-l-5" data-id="title-spinner"></i>');
412
- handleSavePanelPosition(ui.item);
413
- }
414
- });
415
- };
416
-
417
-
418
- /* 08. Handle Tooltip & Popover Activation
419
- ------------------------------------------------ */
420
- var handelTooltipPopoverActivation = function() {
421
- "use strict";
422
- if ($('[data-toggle="tooltip"]').length !== 0) {
423
- $('[data-toggle=tooltip]').tooltip();
424
- }
425
- if ($('[data-toggle="popover"]').length !== 0) {
426
- $('[data-toggle=popover]').popover();
427
- }
428
- };
429
-
430
-
431
- /* 09. Handle Scroll to Top Button Activation
432
- ------------------------------------------------ */
433
- var handleScrollToTopButton = function() {
434
- "use strict";
435
- var bootstrapVersion = handleCheckBootstrapVersion();
436
- var showClass = '';
437
-
438
- if (bootstrapVersion >= 3 && bootstrapVersion < 4) {
439
- showClass = 'in';
440
- } else if (bootstrapVersion >= 4 && bootstrapVersion < 5) {
441
- showClass = 'show';
442
- }
443
- $(document).scroll( function() {
444
- var totalScroll = $(document).scrollTop();
445
-
446
- if (totalScroll >= 200) {
447
- $('[data-click=scroll-top]').addClass(showClass);
448
- } else {
449
- $('[data-click=scroll-top]').removeClass(showClass);
450
- }
451
- });
452
-
453
- $('[data-click=scroll-top]').click(function(e) {
454
- e.preventDefault();
455
- $('html, body').animate({
456
- scrollTop: $("body").offset().top
457
- }, 500);
458
- });
459
- };
460
-
461
-
462
- /* 10. Handle Theme & Page Structure Configuration - added in V1.2
463
- ------------------------------------------------ */
464
- var handleThemePageStructureControl = function() {
465
-
466
- // THEME - theme selection
467
- $(document).on('click', '.theme-list [data-theme]', function() {
468
- var cssFileSrc = $(this).attr('data-theme-file');
469
- $('#theme').attr('href', cssFileSrc);
470
- $('.theme-list [data-theme]').not(this).closest('li').removeClass('active');
471
- $(this).closest('li').addClass('active');
472
- Cookies.set('theme', $(this).attr('data-theme'));
473
- });
474
-
475
- // COOKIE - theme selection
476
- if (Cookies && Cookies.get('theme')) {
477
- if ($('.theme-list [data-theme]').length !== 0) {
478
- $('.theme-list [data-theme="'+ Cookies.get('theme') +'"]').trigger('click');
479
- }
480
- }
481
-
482
- // HEADER - header styling selection
483
- $(document).on('change', '.theme-panel [name=header-styling]', function() {
484
- var targetClassAdd = ($(this).val() == 1) ? 'navbar-default' : 'navbar-inverse';
485
- var targetClassRemove = ($(this).val() == 1) ? 'navbar-inverse' : 'navbar-default';
486
- $('#header').removeClass(targetClassRemove).addClass(targetClassAdd);
487
- Cookies.set('header-styling', $(this).val());
488
- });
489
-
490
- // COOKIE - header styling selection
491
- if (Cookies && Cookies.get('header-styling')) {
492
- var targetElm = '.theme-panel [name="header-styling"]';
493
- if ($(targetElm).length !== 0) {
494
- $(targetElm + ' option[value="'+ Cookies.get('header-styling') +'"]').prop('selected', true);
495
- $(targetElm).trigger('change');
496
- }
497
- }
498
-
499
- // SIDEBAR - sidebar styling selection
500
- $(document).on('change', '.theme-panel [name=sidebar-styling]', function() {
501
- if ($(this).val() == 2) {
502
- $('#sidebar').addClass('sidebar-grid');
503
- Cookies.set('sidebar-styling', $(this).val());
504
- } else {
505
- $('#sidebar').removeClass('sidebar-grid');
506
- Cookies.set('sidebar-styling', $(this).val());
507
- }
508
- });
509
-
510
- // COOKIE - sidebar styling selection
511
- if (Cookies && Cookies.get('sidebar-styling')) {
512
- var targetElm = '.theme-panel [name="sidebar-styling"]';
513
- if ($(targetElm).length !== 0) {
514
- $(targetElm + ' option[value="'+ Cookies.get('sidebar-styling') +'"]').prop('selected', true);
515
- $(targetElm).trigger('change');
516
- }
517
- }
518
-
519
- // CONTENT - content gradient selection
520
- $(document).on('change', '.theme-panel [name=content-gradient]', function() {
521
- if ($(this).val() == 2) {
522
- $('#page-container').addClass('gradient-enabled');
523
- Cookies.set('content-gradient', $(this).val());
524
- } else {
525
- $('#page-container').removeClass('gradient-enabled');
526
- Cookies.set('content-gradient', $(this).val());
527
- }
528
- });
529
-
530
- // COOKIE - content gradient selection
531
- if (Cookies && Cookies.get('content-gradient')) {
532
- var targetElm = '.theme-panel [name="content-gradient"]';
533
- if ($(targetElm).length !== 0) {
534
- $(targetElm + ' option[value="'+ Cookies.get('content-gradient') +'"]').prop('selected', true);
535
- $(targetElm).trigger('change');
536
- }
537
- }
538
-
539
- // CONTENT - content styling selection
540
- $(document).on('change', '.theme-panel [name=content-styling]', function() {
541
- if ($(this).val() == 2) {
542
- $('body').addClass('flat-black');
543
- Cookies.set('content-styling', $(this).val());
544
- } else {
545
- $('body').removeClass('flat-black');
546
- Cookies.set('content-styling', $(this).val());
547
- }
548
- });
549
-
550
- // COOKIE - content styling selection
551
- if (Cookies && Cookies.get('content-styling')) {
552
- var targetElm = '.theme-panel [name="content-styling"]';
553
- if ($(targetElm).length !== 0) {
554
- $(targetElm + ' option[value="'+ Cookies.get('content-styling') +'"]').prop('selected', true);
555
- $(targetElm).trigger('change');
556
- }
557
- }
558
-
559
- // DIRECTION - direction selection
560
- $(document).on('change', '.theme-panel [name=direction]', function() {
561
- if ($(this).val() == 2) {
562
- $('body').addClass('rtl-mode');
563
- Cookies.set('direction', $(this).val());
564
- } else {
565
- $('body').removeClass('rtl-mode');
566
- Cookies.set('direction', $(this).val());
567
- }
568
- });
569
-
570
- // COOKIE - direction selection
571
- if (Cookies && Cookies.get('direction')) {
572
- var targetElm = '.theme-panel [name="direction"]';
573
- if ($(targetElm).length !== 0) {
574
- $(targetElm + ' option[value="'+ Cookies.get('direction') +'"]').prop('selected', true);
575
- $(targetElm).trigger('change');
576
- }
577
- }
578
-
579
- // SIDEBAR - sidebar fixed selection
580
- $(document).on('change', '.theme-panel [name=sidebar-fixed]', function() {
581
- if ($(this).val() == 1) {
582
- if ($('.theme-panel [name=header-fixed]').val() == 2) {
583
- alert('Default Header with Fixed Sidebar option is not supported. Proceed with Fixed Header with Fixed Sidebar.');
584
- $('.theme-panel [name=header-fixed] option[value="1"]').prop('selected', true);
585
- $('#page-container').addClass('page-header-fixed');
586
- }
587
- $('#page-container').addClass('page-sidebar-fixed');
588
- if (!$('#page-container').hasClass('page-sidebar-minified')) {
589
- generateSlimScroll($('.sidebar [data-scrollbar="true"]'));
590
- }
591
- } else {
592
- $('#page-container').removeClass('page-sidebar-fixed');
593
- if ($('.sidebar .slimScrollDiv').length !== 0) {
594
- if ($(window).width() <= 979) {
595
- $('.sidebar').each(function() {
596
- if (!($('#page-container').hasClass('page-with-two-sidebar') && $(this).hasClass('sidebar-right'))) {
597
- $(this).find('.slimScrollBar').remove();
598
- $(this).find('.slimScrollRail').remove();
599
- $(this).find('[data-scrollbar="true"]').removeAttr('style');
600
- var targetElement = $(this).find('[data-scrollbar="true"]').parent();
601
- var targetHtml = $(targetElement).html();
602
- $(targetElement).replaceWith(targetHtml);
603
- }
604
- });
605
- } else if ($(window).width() > 979) {
606
- $('.sidebar [data-scrollbar="true"]').slimScroll({destroy: true});
607
- $('.sidebar [data-scrollbar="true"]').removeAttr('style');
608
- $('.sidebar [data-scrollbar="true"]').removeAttr('data-init');
609
- }
610
- }
611
- if ($('#page-container .sidebar-bg').length === 0) {
612
- $('#page-container').append('<div class="sidebar-bg"></div>');
613
- }
614
- }
615
- });
616
-
617
- // HEADER - fixed or default
618
- $(document).on('change', '.theme-panel [name=header-fixed]', function() {
619
- if ($(this).val() == 1) {
620
- $('#header').addClass('navbar-fixed-top');
621
- $('#page-container').addClass('page-header-fixed');
622
- Cookies.set('header-fixed', true);
623
- } else {
624
- if ($('.theme-panel [name=sidebar-fixed]').val() == 1) {
625
- alert('Default Header with Fixed Sidebar option is not supported. Proceed with Default Header with Default Sidebar.');
626
- $('.theme-panel [name=sidebar-fixed] option[value="2"]').prop('selected', true);
627
- $('.theme-panel [name=sidebar-fixed]').trigger('change');
628
- if ($('#page-container .sidebar-bg').length === 0) {
629
- $('#page-container').append('<div class="sidebar-bg"></div>');
630
- }
631
- }
632
- $('#header').removeClass('navbar-fixed-top');
633
- $('#page-container').removeClass('page-header-fixed');
634
- Cookies.set('header-fixed', false);
635
- }
636
- });
637
- };
638
-
639
-
640
- /* 11. Handle Theme Panel Expand - added in V1.2
641
- ------------------------------------------------ */
642
- var handleThemePanelExpand = function() {
643
- $(document).on('click', '[data-click="theme-panel-expand"]', function() {
644
- var targetContainer = '.theme-panel';
645
- var targetClass = 'active';
646
- if ($(targetContainer).hasClass(targetClass)) {
647
- $(targetContainer).removeClass(targetClass);
648
- } else {
649
- $(targetContainer).addClass(targetClass);
650
- }
651
- });
652
- };
653
-
654
-
655
- /* 12. Handle After Page Load Add Class Function - added in V1.2
656
- ------------------------------------------------ */
657
- var handleAfterPageLoadAddClass = function() {
658
- if ($('[data-pageload-addclass]').length !== 0) {
659
- $(window).on('load', function() {
660
- $('[data-pageload-addclass]').each(function() {
661
- var targetClass = $(this).attr('data-pageload-addclass');
662
- $(this).addClass(targetClass);
663
- });
664
- });
665
- }
666
- };
667
-
668
-
669
- /* 13. Handle Save Panel Position Function - added in V1.5
670
- ------------------------------------------------ */
671
- var handleSavePanelPosition = function(element) {
672
- "use strict";
673
- if ($('.ui-sortable').length !== 0) {
674
- var newValue = [];
675
- var index = 0;
676
- $.when($('.ui-sortable').each(function() {
677
- var panelSortableElement = $(this).find('[data-sortable-id]');
678
- if (panelSortableElement.length !== 0) {
679
- var columnValue = [];
680
- $(panelSortableElement).each(function() {
681
- var targetSortId = $(this).attr('data-sortable-id');
682
- columnValue.push({id: targetSortId});
683
- });
684
- newValue.push(columnValue);
685
- } else {
686
- newValue.push([]);
687
- }
688
- index++;
689
- })).done(function() {
690
- var targetPage = window.location.href;
691
- targetPage = targetPage.split('?');
692
- targetPage = targetPage[0];
693
- localStorage.setItem(targetPage, JSON.stringify(newValue));
694
- $(element).find('[data-id="title-spinner"]').delay(500).fadeOut(500, function() {
695
- $(this).remove();
696
- });
697
- });
698
- }
699
- };
700
-
701
-
702
- /* 14. Handle Draggable Panel Local Storage Function - added in V1.5
703
- ------------------------------------------------ */
704
- var handleLocalStorage = function() {
705
- "use strict";
706
- try {
707
- if (typeof(Storage) !== 'undefined' && typeof(localStorage) !== 'undefined') {
708
- var targetPage = window.location.href;
709
- targetPage = targetPage.split('?');
710
- targetPage = targetPage[0];
711
- var panelPositionData = localStorage.getItem(targetPage);
712
-
713
- if (panelPositionData) {
714
- panelPositionData = JSON.parse(panelPositionData);
715
- var i = 0;
716
- $.when($('.panel:not([data-sortable="false"])').parent('[class*="col-"]').each(function() {
717
- var storageData = panelPositionData[i];
718
- var targetColumn = $(this);
719
- if (storageData) {
720
- $.each(storageData, function(index, data) {
721
- var targetId = $('[data-sortable-id="'+ data.id +'"]').not('[data-init="true"]');
722
- if ($(targetId).length !== 0) {
723
- var targetHtml = $(targetId).clone();
724
- $(targetId).remove();
725
- $(targetColumn).append(targetHtml);
726
- $('[data-sortable-id="'+ data.id +'"]').attr('data-init','true');
727
- }
728
- });
729
- }
730
- i++;
731
- })).done(function() {
732
- window.dispatchEvent(new CustomEvent('localstorage-position-loaded'));
733
- });
734
- }
735
- } else {
736
- alert('Your browser is not supported with the local storage');
737
- }
738
- } catch (error) {
739
- console.log(error);
740
- }
741
- };
742
-
743
-
744
- /* 15. Handle Reset Local Storage - added in V1.5
745
- ------------------------------------------------ */
746
- var handleResetLocalStorage = function() {
747
- "use strict";
748
- $(document).on('click', '[data-click=reset-local-storage]', function(e) {
749
- e.preventDefault();
750
-
751
- var targetModalHtml = ''+
752
- '<div class="modal fade" data-modal-id="reset-local-storage-confirmation">'+
753
- ' <div class="modal-dialog">'+
754
- ' <div class="modal-content">'+
755
- ' <div class="modal-header">'+
756
- ' <h4 class="modal-title"><i class="fa fa-redo m-r-5"></i> Reset Local Storage Confirmation</h4>'+
757
- ' <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>'+
758
- ' </div>'+
759
- ' <div class="modal-body">'+
760
- ' <div class="alert alert-info m-b-0">Would you like to RESET all your saved widgets and clear Local Storage?</div>'+
761
- ' </div>'+
762
- ' <div class="modal-footer">'+
763
- ' <a href="javascript:;" class="btn btn-sm btn-default" data-dismiss="modal"><i class="fa fa-times"></i> No</a>'+
764
- ' <a href="javascript:;" class="btn btn-sm btn-inverse" data-click="confirm-reset-local-storage"><i class="fa fa-check"></i> Yes</a>'+
765
- ' </div>'+
766
- ' </div>'+
767
- ' </div>'+
768
- '</div>';
769
-
770
- $('body').append(targetModalHtml);
771
- $('[data-modal-id="reset-local-storage-confirmation"]').modal('show');
772
- });
773
- $(document).on('hidden.bs.modal', '[data-modal-id="reset-local-storage-confirmation"]', function(e) {
774
- $('[data-modal-id="reset-local-storage-confirmation"]').remove();
775
- });
776
- $(document).on('click', '[data-click=confirm-reset-local-storage]', function(e) {
777
- e.preventDefault();
778
- var localStorageName = window.location.href;
779
- localStorageName = localStorageName.split('?');
780
- localStorageName = localStorageName[0];
781
- localStorage.removeItem(localStorageName);
782
-
783
- location.reload();
784
- });
785
- };
786
-
787
-
788
- /* 16. Handle IE Full Height Page Compatibility - added in V1.6
789
- ------------------------------------------------ */
790
- var handleIEFullHeightContent = function() {
791
- var userAgent = window.navigator.userAgent;
792
- var msie = userAgent.indexOf("MSIE ");
793
-
794
- if (msie > 0) {
795
- $('.vertical-box-row [data-scrollbar="true"][data-height="100%"]').each(function() {
796
- var targetRow = $(this).closest('.vertical-box-row');
797
- var targetHeight = $(targetRow).height();
798
- $(targetRow).find('.vertical-box-cell').height(targetHeight);
799
- });
800
- }
801
- };
802
-
803
-
804
- /* 17. Handle Unlimited Nav Tabs - added in V1.6
805
- ------------------------------------------------ */
806
- var handleUnlimitedTabsRender = function() {
807
-
808
- // function handle tab overflow scroll width
809
- function handleTabOverflowScrollWidth(obj, animationSpeed) {
810
- var targetElm = 'li.active';
811
-
812
- if ($(obj).find('li').first().hasClass('nav-item')) {
813
- targetElm = $(obj).find('.nav-item .active').closest('li');
814
- }
815
- var targetCss = ($('body').hasClass('rtl-mode')) ? 'margin-right' : 'margin-left';
816
- var marginLeft = parseInt($(obj).css(targetCss));
817
- var viewWidth = $(obj).width();
818
- var prevWidth = $(obj).find(targetElm).width();
819
- var speed = (animationSpeed > -1) ? animationSpeed : 150;
820
- var fullWidth = 0;
821
-
822
- $(obj).find(targetElm).prevAll().each(function() {
823
- prevWidth += $(this).width();
824
- });
825
-
826
- $(obj).find('li').each(function() {
827
- fullWidth += $(this).width();
828
- });
829
-
830
- if (prevWidth >= viewWidth) {
831
- var finalScrollWidth = prevWidth - viewWidth;
832
- if (fullWidth != prevWidth) {
833
- finalScrollWidth += 40;
834
- }
835
- if ($('body').hasClass('rtl-mode')) {
836
- $(obj).find('.nav.nav-tabs').animate({ marginRight: '-' + finalScrollWidth + 'px'}, speed);
837
- } else {
838
- $(obj).find('.nav.nav-tabs').animate({ marginLeft: '-' + finalScrollWidth + 'px'}, speed);
839
- }
840
- }
841
-
842
- if (prevWidth != fullWidth && fullWidth >= viewWidth) {
843
- $(obj).addClass('overflow-right');
844
- } else {
845
- $(obj).removeClass('overflow-right');
846
- }
847
-
848
- if (prevWidth >= viewWidth && fullWidth >= viewWidth) {
849
- $(obj).addClass('overflow-left');
850
- } else {
851
- $(obj).removeClass('overflow-left');
852
- }
853
- }
854
-
855
- // function handle tab button action - next / prev
856
- function handleTabButtonAction(element, direction) {
857
- var obj = $(element).closest('.tab-overflow');
858
- var targetCss = ($('body').hasClass('rtl-mode')) ? 'margin-right' : 'margin-left';
859
- var marginLeft = parseInt($(obj).find('.nav.nav-tabs').css(targetCss));
860
- var containerWidth = $(obj).width();
861
- var totalWidth = 0;
862
- var finalScrollWidth = 0;
863
-
864
- $(obj).find('li').each(function() {
865
- if (!$(this).hasClass('next-button') && !$(this).hasClass('prev-button')) {
866
- totalWidth += $(this).width();
867
- }
868
- });
869
-
870
- switch (direction) {
871
- case 'next':
872
- var widthLeft = totalWidth + marginLeft - containerWidth;
873
- if (widthLeft <= containerWidth) {
874
- finalScrollWidth = widthLeft - marginLeft;
875
- setTimeout(function() {
876
- $(obj).removeClass('overflow-right');
877
- }, 150);
878
- } else {
879
- finalScrollWidth = containerWidth - marginLeft - 80;
880
- }
881
-
882
- if (finalScrollWidth !== 0) {
883
- if (!$('body').hasClass('rtl-mode')) {
884
- $(obj).find('.nav.nav-tabs').animate({ marginLeft: '-' + finalScrollWidth + 'px'}, 150, function() {
885
- $(obj).addClass('overflow-left');
886
- });
887
- } else {
888
- $(obj).find('.nav.nav-tabs').animate({ marginRight: '-' + finalScrollWidth + 'px'}, 150, function() {
889
- $(obj).addClass('overflow-left');
890
- });
891
- }
892
- }
893
- break;
894
- case 'prev':
895
- var widthLeft = -marginLeft;
896
-
897
- if (widthLeft <= containerWidth) {
898
- $(obj).removeClass('overflow-left');
899
- finalScrollWidth = 0;
900
- } else {
901
- finalScrollWidth = widthLeft - containerWidth + 80;
902
- }
903
- if (!$('body').hasClass('rtl-mode')) {
904
- $(obj).find('.nav.nav-tabs').animate({ marginLeft: '-' + finalScrollWidth + 'px'}, 150, function() {
905
- $(obj).addClass('overflow-right');
906
- });
907
- } else {
908
- $(obj).find('.nav.nav-tabs').animate({ marginRight: '-' + finalScrollWidth + 'px'}, 150, function() {
909
- $(obj).addClass('overflow-right');
910
- });
911
- }
912
- break;
913
- }
914
- }
915
-
916
- // handle page load active tab focus
917
- function handlePageLoadTabFocus() {
918
- $('.tab-overflow').each(function() {
919
- handleTabOverflowScrollWidth(this, 0);
920
- });
921
- }
922
-
923
- // handle tab next button click action
924
- $('[data-click="next-tab"]').click(function(e) {
925
- e.preventDefault();
926
- handleTabButtonAction(this,'next');
927
- });
928
-
929
- // handle tab prev button click action
930
- $('[data-click="prev-tab"]').click(function(e) {
931
- e.preventDefault();
932
- handleTabButtonAction(this,'prev');
933
- });
934
-
935
- // handle unlimited tabs responsive setting
936
- $(window).resize(function() {
937
- $('.tab-overflow .nav.nav-tabs').removeAttr('style');
938
- handlePageLoadTabFocus();
939
- });
940
-
941
- handlePageLoadTabFocus();
942
- };
943
-
944
-
945
- /* 18. Handle Top Menu - Unlimited Top Menu Render - added in V1.9
946
- ------------------------------------------------ */
947
- var handleUnlimitedTopMenuRender = function() {
948
- "use strict";
949
- // function handle menu button action - next / prev
950
- function handleMenuButtonAction(element, direction) {
951
- var obj = $(element).closest('.nav');
952
- var targetCss = ($('body').hasClass('rtl-mode')) ? 'margin-right' : 'margin-left';
953
- var marginLeft = parseInt($(obj).css(targetCss));
954
- var containerWidth = $('.top-menu').width() - 88;
955
- var totalWidth = 0;
956
- var finalScrollWidth = 0;
957
-
958
- $(obj).find('li').each(function() {
959
- if (!$(this).hasClass('menu-control')) {
960
- totalWidth += $(this).width();
961
- }
962
- });
963
-
964
- switch (direction) {
965
- case 'next':
966
- var widthLeft = totalWidth + marginLeft - containerWidth;
967
- if (widthLeft <= containerWidth) {
968
- finalScrollWidth = widthLeft - marginLeft + 128;
969
- setTimeout(function() {
970
- $(obj).find('.menu-control.menu-control-right').removeClass('show');
971
- }, 150);
972
- } else {
973
- finalScrollWidth = containerWidth - marginLeft - 128;
974
- }
975
-
976
- if (finalScrollWidth !== 0) {
977
- if (!$('body').hasClass('rtl-mode')) {
978
- $(obj).animate({ marginLeft: '-' + finalScrollWidth + 'px'}, 150, function() {
979
- $(obj).find('.menu-control.menu-control-left').addClass('show');
980
- });
981
- } else {
982
- $(obj).animate({ marginRight: '-' + finalScrollWidth + 'px'}, 150, function() {
983
- $(obj).find('.menu-control.menu-control-left').addClass('show');
984
- });
985
- }
986
- }
987
- break;
988
- case 'prev':
989
- var widthLeft = -marginLeft;
990
-
991
- if (widthLeft <= containerWidth) {
992
- $(obj).find('.menu-control.menu-control-left').removeClass('show');
993
- finalScrollWidth = 0;
994
- } else {
995
- finalScrollWidth = widthLeft - containerWidth + 88;
996
- }
997
- if (!$('body').hasClass('rtl-mode')) {
998
- $(obj).animate({ marginLeft: '-' + finalScrollWidth + 'px'}, 150, function() {
999
- $(obj).find('.menu-control.menu-control-right').addClass('show');
1000
- });
1001
- } else {
1002
- $(obj).animate({ marginRight: '-' + finalScrollWidth + 'px'}, 150, function() {
1003
- $(obj).find('.menu-control.menu-control-right').addClass('show');
1004
- });
1005
- }
1006
- break;
1007
- }
1008
- }
1009
-
1010
- // handle page load active menu focus
1011
- function handlePageLoadMenuFocus() {
1012
- var targetMenu = $('.top-menu .nav');
1013
- var targetList = $('.top-menu .nav > li');
1014
- var targetActiveList = $('.top-menu .nav > li.active');
1015
- var targetContainer = $('.top-menu');
1016
- var targetCss = ($('body').hasClass('rtl-mode')) ? 'margin-right' : 'margin-left';
1017
- var marginLeft = parseInt($(targetMenu).css(targetCss));
1018
- var viewWidth = $(targetContainer).width() - 128;
1019
- var prevWidth = $('.top-menu .nav > li.active').width();
1020
- var speed = 0;
1021
- var fullWidth = 0;
1022
-
1023
- $(targetActiveList).prevAll().each(function() {
1024
- prevWidth += $(this).width();
1025
- });
1026
-
1027
- $(targetList).each(function() {
1028
- if (!$(this).hasClass('menu-control')) {
1029
- fullWidth += $(this).width();
1030
- }
1031
- });
1032
-
1033
- if (prevWidth >= viewWidth) {
1034
- var finalScrollWidth = prevWidth - viewWidth + 128;
1035
- if (!$('body').hasClass('rtl-mode')) {
1036
- $(targetMenu).animate({ marginLeft: '-' + finalScrollWidth + 'px'}, speed);
1037
- } else {
1038
- $(targetMenu).animate({ marginRight: '-' + finalScrollWidth + 'px'}, speed);
1039
- }
1040
- }
1041
-
1042
- if (prevWidth != fullWidth && fullWidth >= viewWidth) {
1043
- $(targetMenu).find('.menu-control.menu-control-right').addClass('show');
1044
- } else {
1045
- $(targetMenu).find('.menu-control.menu-control-right').removeClass('show');
1046
- }
1047
-
1048
- if (prevWidth >= viewWidth && fullWidth >= viewWidth) {
1049
- $(targetMenu).find('.menu-control.menu-control-left').addClass('show');
1050
- } else {
1051
- $(targetMenu).find('.menu-control.menu-control-left').removeClass('show');
1052
- }
1053
- }
1054
-
1055
- // handle menu next button click action
1056
- $('[data-click="next-menu"]').click(function(e) {
1057
- e.preventDefault();
1058
- handleMenuButtonAction(this,'next');
1059
- });
1060
-
1061
- // handle menu prev button click action
1062
- $('[data-click="prev-menu"]').click(function(e) {
1063
- e.preventDefault();
1064
- handleMenuButtonAction(this,'prev');
1065
- });
1066
-
1067
- // handle unlimited menu responsive setting
1068
- $(window).resize(function() {
1069
- $('.top-menu .nav').removeAttr('style');
1070
- handlePageLoadMenuFocus();
1071
- });
1072
-
1073
- handlePageLoadMenuFocus();
1074
- };
1075
-
1076
-
1077
- /* 19. Handle Top Menu - Sub Menu Toggle - added in V1.9
1078
- ------------------------------------------------ */
1079
- var handleTopMenuSubMenu = function() {
1080
- "use strict";
1081
- $('.top-menu .sub-menu .has-sub > a').click(function() {
1082
- var target = $(this).closest('li').find('.sub-menu').first();
1083
- var otherMenu = $(this).closest('ul').find('.sub-menu').not(target);
1084
- $(otherMenu).not(target).slideUp(250, function() {
1085
- $(this).closest('li').removeClass('expand');
1086
- });
1087
- $(target).slideToggle(250, function() {
1088
- var targetLi = $(this).closest('li');
1089
- if ($(targetLi).hasClass('expand')) {
1090
- $(targetLi).removeClass('expand');
1091
- } else {
1092
- $(targetLi).addClass('expand');
1093
- }
1094
- });
1095
- });
1096
- };
1097
-
1098
-
1099
- /* 20. Handle Top Menu - Mobile Sub Menu Toggle - added in V1.9
1100
- ------------------------------------------------ */
1101
- var handleMobileTopMenuSubMenu = function() {
1102
- "use strict";
1103
- $('.top-menu .nav > li.has-sub > a').click(function() {
1104
- if ($(window).width() <= 767) {
1105
- var target = $(this).closest('li').find('.sub-menu').first();
1106
- var otherMenu = $(this).closest('ul').find('.sub-menu').not(target);
1107
- $(otherMenu).not(target).slideUp(250, function() {
1108
- $(this).closest('li').removeClass('expand');
1109
- });
1110
- $(target).slideToggle(250, function() {
1111
- var targetLi = $(this).closest('li');
1112
- if ($(targetLi).hasClass('expand')) {
1113
- $(targetLi).removeClass('expand');
1114
- } else {
1115
- $(targetLi).addClass('expand');
1116
- }
1117
- });
1118
- }
1119
- });
1120
- };
1121
-
1122
-
1123
- /* 21. Handle Top Menu - Mobile Top Menu Toggle - added in V1.9
1124
- ------------------------------------------------ */
1125
- var handleTopMenuMobileToggle = function() {
1126
- "use strict";
1127
- $('[data-click="top-menu-toggled"]').click(function() {
1128
- $('.top-menu').slideToggle(250);
1129
- });
1130
- };
1131
-
1132
-
1133
- /* 22. Handle Clear Sidebar Selection & Hide Mobile Menu - added in V1.9
1134
- ------------------------------------------------ */
1135
- var handleClearSidebarSelection = function() {
1136
- $('.sidebar .nav > li, .sidebar .nav .sub-menu').removeClass('expand').removeAttr('style');
1137
- };
1138
- var handleClearSidebarMobileSelection = function() {
1139
- $('#page-container').removeClass('page-sidebar-toggled');
1140
- };
1141
-
1142
-
1143
- /* 23. Handle Check Bootstrap Version - added in V4.0
1144
- ------------------------------------------------ */
1145
- var handleCheckBootstrapVersion = function() {
1146
- return parseInt($.fn.tooltip.Constructor.VERSION);
1147
- };
1148
-
1149
-
1150
- /* 24. Handle Page Scroll Class - added in V4.0
1151
- ------------------------------------------------ */
1152
- var handleCheckScrollClass = function() {
1153
- if ($(window).scrollTop() > 0) {
1154
- $('#page-container').addClass('has-scroll');
1155
- } else {
1156
- $('#page-container').removeClass('has-scroll');
1157
- }
1158
- };
1159
- var handlePageScrollClass = function() {
1160
- $(window).on('scroll', function() {
1161
- handleCheckScrollClass();
1162
- });
1163
- handleCheckScrollClass();
1164
- };
1165
-
1166
-
1167
- /* 25. Handle Toggle Navbar Profile - added in V4.0
1168
- ------------------------------------------------ */
1169
- var handleToggleNavProfile = function() {
1170
- var expandTime = ($('.sidebar').attr('data-disable-slide-animation')) ? 0 : 250;
1171
-
1172
- $('[data-toggle="nav-profile"]').click(function(e) {
1173
- e.preventDefault();
1174
-
1175
- var targetLi = $(this).closest('li');
1176
- var targetProfile = $('.sidebar .nav.nav-profile');
1177
- var targetClass = 'active';
1178
- var targetExpandingClass = 'expanding';
1179
- var targetExpandClass = 'expand';
1180
- var targetClosingClass = 'closing';
1181
- var targetClosedClass = 'closed';
1182
-
1183
- if ($(targetProfile).is(':visible')) {
1184
- $(targetLi).removeClass(targetClass);
1185
- $(targetProfile).removeClass(targetClosingClass);
1186
- } else {
1187
- $(targetLi).addClass(targetClass);
1188
- $(targetProfile).addClass(targetExpandingClass);
1189
- }
1190
- $(targetProfile).slideToggle(expandTime, function() {
1191
- if (!$(targetProfile).is(':visible')) {
1192
- $(targetProfile).addClass(targetClosedClass);
1193
- $(targetProfile).removeClass(targetExpandClass);
1194
- } else {
1195
- $(targetProfile).addClass(targetExpandClass);
1196
- $(targetProfile).removeClass(targetClosedClass);
1197
- }
1198
- $(targetProfile).removeClass(targetExpandingClass + ' ' + targetClosingClass);
1199
- });
1200
- });
1201
- };
1202
-
1203
-
1204
- /* 26. Handle Sidebar Scroll Memory - added in V4.0
1205
- ------------------------------------------------ */
1206
- var handleSidebarScrollMemory = function() {
1207
- if (!(/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent))) {
1208
- try {
1209
- if (typeof(Storage) !== 'undefined' && typeof(localStorage) !== 'undefined') {
1210
- $('.sidebar [data-scrollbar="true"]').slimScroll().bind('slimscrolling', function(e, pos) {
1211
- localStorage.setItem('sidebarScrollPosition', pos + 'px');
1212
- });
1213
-
1214
- var defaultScroll = localStorage.getItem('sidebarScrollPosition');
1215
- if (defaultScroll) {
1216
- $('.sidebar [data-scrollbar="true"]').slimScroll({ scrollTo: defaultScroll });
1217
- }
1218
- }
1219
- } catch (error) {
1220
- console.log(error);
1221
- }
1222
- }
1223
- };
1224
-
1225
-
1226
- /* 27. Handle Sidebar Minify Sub Menu - added in V4.0
1227
- ------------------------------------------------ */
1228
- var floatSubMenuTimeout;
1229
- var targetFloatMenu;
1230
- var handleMouseoverFloatSubMenu = function(elm) {
1231
- clearTimeout(floatSubMenuTimeout);
1232
- };
1233
- var handleMouseoutFloatSubMenu = function(elm) {
1234
- floatSubMenuTimeout = setTimeout(function() {
1235
- $('#float-sub-menu').remove();
1236
- }, 150);
1237
- };
1238
- var handleSidebarMinifyFloatMenu = function() {
1239
- $(document).on('click', '#float-sub-menu li.has-sub > a', function(e) {
1240
- var target = $(this).next('.sub-menu');
1241
- var targetLi = $(target).closest('li');
1242
- var close = false;
1243
- var expand = false;
1244
- if ($(target).is(':visible')) {
1245
- $(targetLi).addClass('closing');
1246
- close = true;
1247
- } else {
1248
- $(targetLi).addClass('expanding');
1249
- expand = true;
1250
- }
1251
- $(target).slideToggle({
1252
- duration: 250,
1253
- progress: function() {
1254
- var targetMenu = $('#float-sub-menu');
1255
- var targetHeight = $(targetMenu).height();
1256
- var targetOffset = $(targetMenu).offset();
1257
- var targetOriTop = $(targetMenu).attr('data-offset-top');
1258
- var targetMenuTop = $(targetMenu).attr('data-menu-offset-top');
1259
- var targetTop = targetOffset.top - $(window).scrollTop();
1260
- var windowHeight = $(window).height();
1261
- if (close) {
1262
- if (targetTop > targetOriTop) {
1263
- targetTop = (targetTop > targetOriTop) ? targetOriTop : targetTop;
1264
- $('#float-sub-menu').css({ 'top': targetTop + 'px', 'bottom': 'auto' });
1265
- $('#float-sub-menu-arrow').css({ 'top': '20px', 'bottom': 'auto' });
1266
- $('#float-sub-menu-line').css({ 'top': '20px', 'bottom': 'auto' });
1267
- }
1268
- }
1269
- if (expand) {
1270
- if ((windowHeight - targetTop) < targetHeight) {
1271
- var arrowBottom = (windowHeight - targetMenuTop) - 22;
1272
- $('#float-sub-menu').css({ 'top': 'auto', 'bottom': 0 });
1273
- $('#float-sub-menu-arrow').css({ 'top': 'auto', 'bottom': arrowBottom + 'px' });
1274
- $('#float-sub-menu-line').css({ 'top': '20px', 'bottom': arrowBottom + 'px' });
1275
- }
1276
- }
1277
- },
1278
- complete: function() {
1279
- if ($(target).is(':visible')) {
1280
- $(targetLi).addClass('expand');
1281
- } else {
1282
- $(targetLi).addClass('closed');
1283
- }
1284
- $(targetLi).removeClass('closing expanding');
1285
- }
1286
- });
1287
- });
1288
- $('.sidebar .nav > li.has-sub > a').hover(function() {
1289
- if ($('#page-container').hasClass('page-sidebar-minified')) {
1290
- clearTimeout(floatSubMenuTimeout);
1291
-
1292
- var targetMenu = $(this).closest('li').find('.sub-menu').first();
1293
- if (targetFloatMenu == this && $('#float-sub-menu').length !== 0) {
1294
- return;
1295
- } else {
1296
- targetFloatMenu = this;
1297
- }
1298
- var targetMenuHtml = $(targetMenu).html();
1299
- if (targetMenuHtml) {
1300
- var sidebarOffset = $('#sidebar').offset();
1301
- var sidebarX = (!$('#page-container').hasClass('page-with-right-sidebar')) ? (sidebarOffset.left + 60) : ($(window).width() - sidebarOffset.left);
1302
- var targetHeight = $(targetMenu).height();
1303
- var targetOffset = $(this).offset();
1304
- var targetTop = targetOffset.top - $(window).scrollTop();
1305
- var targetLeft = (!$('#page-container').hasClass('page-with-right-sidebar')) ? sidebarX : 'auto';
1306
- var targetRight = (!$('#page-container').hasClass('page-with-right-sidebar')) ? 'auto' : sidebarX;
1307
- var windowHeight = $(window).height();
1308
-
1309
- if ($('#float-sub-menu').length === 0) {
1310
- targetMenuHtml = ''+
1311
- '<div class="float-sub-menu-container" id="float-sub-menu" data-offset-top="'+ targetTop +'" data-menu-offset-top="'+ targetTop +'" onmouseover="handleMouseoverFloatSubMenu(this)" onmouseout="handleMouseoutFloatSubMenu(this)">'+
1312
- ' <div class="float-sub-menu-arrow" id="float-sub-menu-arrow"></div>'+
1313
- ' <div class="float-sub-menu-line" id="float-sub-menu-line"></div>'+
1314
- ' <ul class="float-sub-menu">'+ targetMenuHtml + '</ul>'+
1315
- '</div>';
1316
- $('#page-container').append(targetMenuHtml);
1317
- } else {
1318
- $('#float-sub-menu').attr('data-offset-top', targetTop);
1319
- $('#float-sub-menu').attr('data-menu-offset-top', targetTop);
1320
- $('.float-sub-menu').html(targetMenuHtml);
1321
- }
1322
-
1323
- if ((windowHeight - targetTop) > targetHeight) {
1324
- $('#float-sub-menu').css({
1325
- 'top': targetTop,
1326
- 'left': targetLeft,
1327
- 'bottom': 'auto',
1328
- 'right': targetRight
1329
- });
1330
- $('#float-sub-menu-arrow').css({ 'top': '20px', 'bottom': 'auto' });
1331
- $('#float-sub-menu-line').css({ 'top': '20px', 'bottom': 'auto' });
1332
- } else {
1333
- $('#float-sub-menu').css({
1334
- 'bottom': 0,
1335
- 'top': 'auto',
1336
- 'left': targetLeft,
1337
- 'right': targetRight
1338
- });
1339
- var arrowBottom = (windowHeight - targetTop) - 21;
1340
- $('#float-sub-menu-arrow').css({ 'top': 'auto', 'bottom': arrowBottom + 'px' });
1341
- $('#float-sub-menu-line').css({ 'top': '20px', 'bottom': arrowBottom + 'px' });
1342
- }
1343
- } else {
1344
- $('#float-sub-menu').remove();
1345
- targetFloatMenu = '';
1346
- }
1347
- }
1348
- }, function() {
1349
- if ($('#page-container').hasClass('page-sidebar-minified')) {
1350
- floatSubMenuTimeout = setTimeout(function() {
1351
- $('#float-sub-menu').remove();
1352
- targetFloatMenu = '';
1353
- }, 250);
1354
- }
1355
- });
1356
- };
1357
-
1358
-
1359
- /* 28. Handle Ajax Mode - added in V4.0
1360
- ------------------------------------------------ */
1361
- var CLEAR_OPTION = '';
1362
- var handleAjaxMode = function(setting) {
1363
- var emptyHtml = (setting.emptyHtml) ? setting.emptyHtml : '<div class="p-t-40 p-b-40 text-center f-s-20 content"><i class="fa fa-warning fa-lg text-muted m-r-5"></i> <span class="f-w-600 text-inverse">Error 404! Page not found.</span></div>';
1364
- var defaultUrl = (setting.ajaxDefaultUrl) ? setting.ajaxDefaultUrl : '';
1365
- defaultUrl = (window.location.hash) ? window.location.hash : defaultUrl;
1366
-
1367
- if (defaultUrl === '') {
1368
- $('#content').html(emptyHtml);
1369
- } else {
1370
- renderAjax(defaultUrl, '', true);
1371
- }
1372
-
1373
- function clearElement() {
1374
- $('.jvectormap-label, .jvector-label, .AutoFill_border ,#gritter-notice-wrapper, .ui-autocomplete, .colorpicker, .FixedHeader_Header, .FixedHeader_Cloned .lightboxOverlay, .lightbox, .introjs-hints, .nvtooltip, #float-sub-menu').remove();
1375
- if ($.fn.DataTable) {
1376
- $('.dataTable').DataTable().destroy();
1377
- }
1378
- if ($('#page-container').hasClass('page-sidebar-toggled')) {
1379
- $('#page-container').removeClass('page-sidebar-toggled');
1380
- }
1381
- }
1382
-
1383
- function checkSidebarActive(url) {
1384
- var targetElm = '#sidebar [data-toggle="ajax"][href="'+ url +'"]';
1385
- if ($(targetElm).length !== 0) {
1386
- $('#sidebar li').removeClass('active');
1387
- $(targetElm).closest('li').addClass('active');
1388
- $(targetElm).parents().addClass('active');
1389
- }
1390
- }
1391
-
1392
- function checkPushState(url) {
1393
- var targetUrl = url.replace('#','');
1394
- var targetUserAgent = window.navigator.userAgent;
1395
- var isIE = targetUserAgent.indexOf('MSIE ');
1396
-
1397
- if (isIE && (isIE > 0 && isIE < 9)) {
1398
- window.location.href = targetUrl;
1399
- } else {
1400
- history.pushState('', '', '#' + targetUrl);
1401
- }
1402
- }
1403
-
1404
- function checkClearOption() {
1405
- if (CLEAR_OPTION) {
1406
- App.clearPageOption(CLEAR_OPTION);
1407
- CLEAR_OPTION = '';
1408
- }
1409
- }
1410
-
1411
- function checkLoading(load) {
1412
- if (!load) {
1413
- if ($('#page-content-loader').length === 0) {
1414
- $('body').addClass('page-content-loading');
1415
- $('#content').append('<div id="page-content-loader"><span class="spinner"></span></div>');
1416
- }
1417
- } else {
1418
- $('#page-content-loader').remove();
1419
- $('body').removeClass('page-content-loading');
1420
- }
1421
- }
1422
-
1423
- function renderAjax(url, elm, disablePushState) {
1424
- Pace.restart();
1425
-
1426
- checkLoading(false);
1427
- clearElement();
1428
- checkSidebarActive(url);
1429
- checkClearOption();
1430
- if (!disablePushState) {
1431
- checkPushState(url);
1432
- }
1433
-
1434
- var targetContainer= '#content';
1435
- var targetUrl = url.replace('#','');
1436
- var targetType = (setting.ajaxType) ? setting.ajaxType : 'GET';
1437
- var targetDataType = (setting.ajaxDataType) ? setting.ajaxDataType : 'html';
1438
- if (elm) {
1439
- targetDataType = ($(elm).attr('data-type')) ? $(elm).attr('data-type') : targetDataType;
1440
- targetDataDataType = ($(elm).attr('data-data-type')) ? $(elm).attr('data-data-type') : targetDataType;
1441
- }
1442
-
1443
- $.ajax({
1444
- url: targetUrl,
1445
- type: targetType,
1446
- dataType: targetDataType,
1447
- success: function(data) {
1448
- $(targetContainer).html(data);
1449
- },
1450
- error: function(jqXHR, textStatus, errorThrown) {
1451
- $(targetContainer).html(emptyHtml);
1452
- }
1453
- }).done(function() {
1454
- checkLoading(true);
1455
- $('html, body').animate({ scrollTop: 0 }, 0);
1456
- App.initComponent();
1457
- });
1458
- }
1459
-
1460
- $(window).on('hashchange', function() {
1461
- if (window.location.hash) {
1462
- renderAjax(window.location.hash, '', true);
1463
- }
1464
- });
1465
-
1466
- $(document).on('click', '[data-toggle="ajax"]', function(e) {
1467
- e.preventDefault();
1468
- renderAjax($(this).attr('href'), this);
1469
- });
1470
- };
1471
- var handleSetPageOption = function(option) {
1472
- if (option.pageContentFullHeight) {
1473
- $('#page-container').addClass('page-content-full-height');
1474
- }
1475
- if (option.pageSidebarLight) {
1476
- $('#page-container').addClass('page-with-light-sidebar');
1477
- }
1478
- if (option.pageSidebarRight) {
1479
- $('#page-container').addClass('page-with-right-sidebar');
1480
- }
1481
- if (option.pageSidebarWide) {
1482
- $('#page-container').addClass('page-with-wide-sidebar');
1483
- }
1484
- if (option.pageSidebarMinified) {
1485
- $('#page-container').addClass('page-sidebar-minified');
1486
- }
1487
- if (option.pageSidebarTransparent) {
1488
- $('#sidebar').addClass('sidebar-transparent');
1489
- }
1490
- if (option.pageContentFullWidth) {
1491
- $('#content').addClass('content-full-width');
1492
- }
1493
- if (option.pageContentInverseMode) {
1494
- $('#content').addClass('content-inverse-mode');
1495
- }
1496
- if (option.pageBoxedLayout) {
1497
- $('body').addClass('boxed-layout');
1498
- }
1499
- if (option.clearOptionOnLeave) {
1500
- CLEAR_OPTION = option;
1501
- }
1502
- };
1503
- var handleClearPageOption = function(option) {
1504
- if (option.pageContentFullHeight) {
1505
- $('#page-container').removeClass('page-content-full-height');
1506
- }
1507
- if (option.pageSidebarLight) {
1508
- $('#page-container').removeClass('page-with-light-sidebar');
1509
- }
1510
- if (option.pageSidebarRight) {
1511
- $('#page-container').removeClass('page-with-right-sidebar');
1512
- }
1513
- if (option.pageSidebarWide) {
1514
- $('#page-container').removeClass('page-with-wide-sidebar');
1515
- }
1516
- if (option.pageSidebarMinified) {
1517
- $('#page-container').removeClass('page-sidebar-minified');
1518
- }
1519
- if (option.pageSidebarTransparent) {
1520
- $('#sidebar').removeClass('sidebar-transparent');
1521
- }
1522
- if (option.pageContentFullWidth) {
1523
- $('#content').removeClass('content-full-width');
1524
- }
1525
- if (option.pageContentInverseMode) {
1526
- $('#content').removeClass('content-inverse-mode');
1527
- }
1528
- if (option.pageBoxedLayout) {
1529
- $('body').removeClass('boxed-layout');
1530
- }
1531
- };
1532
-
1533
-
1534
- /* 29. Handle Float Navbar Search - added in V4.0
1535
- ------------------------------------------------ */
1536
- var handleToggleNavbarSearch = function() {
1537
- $('[data-toggle="navbar-search"]').click(function(e) {
1538
- e.preventDefault();
1539
- $('.header').addClass('header-search-toggled');
1540
- });
1541
-
1542
- $('[data-dismiss="navbar-search"]').click(function(e) {
1543
- e.preventDefault();
1544
- $('.header').removeClass('header-search-toggled');
1545
- });
1546
- };
1547
-
1548
-
1549
- /* Application Controller
1550
- ------------------------------------------------ */
1551
- var App = function () {
1552
- "use strict";
1553
-
1554
- var setting;
1555
-
1556
- return {
1557
- //main function
1558
- init: function (option) {
1559
- if (option) {
1560
- setting = option;
1561
- }
1562
- this.initLocalStorage();
1563
- this.initSidebar();
1564
- this.initTopMenu();
1565
- this.initComponent();
1566
- this.initThemePanel();
1567
- this.initPageLoad();
1568
- $(window).trigger('load');
1569
-
1570
- if (setting && setting.ajaxMode) {
1571
- this.initAjax();
1572
- }
1573
- },
1574
- initSidebar: function() {
1575
- handleSidebarMenu();
1576
- handleMobileSidebarToggle();
1577
- handleSidebarMinify();
1578
- handleSidebarMinifyFloatMenu();
1579
- handleToggleNavProfile();
1580
- handleToggleNavbarSearch();
1581
-
1582
- if (!setting || (setting && !setting.disableSidebarScrollMemory)) {
1583
- handleSidebarScrollMemory();
1584
- }
1585
- },
1586
- initSidebarSelection: function() {
1587
- handleClearSidebarSelection();
1588
- },
1589
- initSidebarMobileSelection: function() {
1590
- handleClearSidebarMobileSelection();
1591
- },
1592
- initTopMenu: function() {
1593
- handleUnlimitedTopMenuRender();
1594
- handleTopMenuSubMenu();
1595
- handleMobileTopMenuSubMenu();
1596
- handleTopMenuMobileToggle();
1597
- },
1598
- initPageLoad: function() {
1599
- handlePageContentView();
1600
- },
1601
- initComponent: function() {
1602
- if (!setting || (setting && !setting.disableDraggablePanel)) {
1603
- handleDraggablePanel();
1604
- }
1605
- handleIEFullHeightContent();
1606
- handleSlimScroll();
1607
- handleUnlimitedTabsRender();
1608
- handlePanelAction();
1609
- handelTooltipPopoverActivation();
1610
- handleScrollToTopButton();
1611
- handleAfterPageLoadAddClass();
1612
- handlePageScrollClass();
1613
- },
1614
- initLocalStorage: function() {
1615
- if (!setting || (setting && !setting.disableLocalStorage)) {
1616
- handleLocalStorage();
1617
- }
1618
- },
1619
- initThemePanel: function() {
1620
- handleThemePageStructureControl();
1621
- handleThemePanelExpand();
1622
- handleResetLocalStorage();
1623
- },
1624
- initAjax: function() {
1625
- handleAjaxMode(setting);
1626
- $.ajaxSetup({
1627
- cache: true
1628
- });
1629
- },
1630
- setPageTitle: function(pageTitle) {
1631
- document.title = pageTitle;
1632
- },
1633
- setPageOption: function(option) {
1634
- handleSetPageOption(option);
1635
- },
1636
- clearPageOption: function(option) {
1637
- handleClearPageOption(option);
1638
- },
1639
- restartGlobalFunction: function() {
1640
- this.initLocalStorage();
1641
- this.initTopMenu();
1642
- this.initComponent();
1643
- },
1644
- scrollTop: function() {
1645
- $('html, body').animate({
1646
- scrollTop: $('body').offset().top
1647
- }, 0);
1648
- }
1649
- };
1650
- }();