phcthemes_web_theme_pack 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (250) hide show
  1. checksums.yaml +7 -0
  2. data/MIT-LICENSE +20 -0
  3. data/README.md +0 -0
  4. data/Rakefile +32 -0
  5. data/app/assets/config/phcthemes_web_theme_pack_manifest.js +3 -0
  6. data/app/assets/javascripts/common/backstretch/jquery.backstretch.js +1602 -0
  7. data/app/assets/javascripts/common/bootstrap-datepicker/bootstrap-datepicker.js +2039 -0
  8. data/app/assets/javascripts/common/bootstrap-markdown/bootstrap-markdown.js +1390 -0
  9. data/app/assets/javascripts/common/bootstrap-select/bootstrap-select.js +3139 -0
  10. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-am_ET.js +46 -0
  11. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-am_ET.js.map +1 -0
  12. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-am_ET.min.js +8 -0
  13. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ar_AR.js +51 -0
  14. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ar_AR.js.map +1 -0
  15. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ar_AR.min.js +8 -0
  16. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-bg_BG.js +46 -0
  17. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-bg_BG.js.map +1 -0
  18. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-bg_BG.min.js +8 -0
  19. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-cs_CZ.js +39 -0
  20. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-cs_CZ.js.map +1 -0
  21. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-cs_CZ.min.js +8 -0
  22. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-da_DK.js +46 -0
  23. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-da_DK.js.map +1 -0
  24. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-da_DK.min.js +8 -0
  25. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-de_DE.js +46 -0
  26. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-de_DE.js.map +1 -0
  27. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-de_DE.min.js +8 -0
  28. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-en_US.js +46 -0
  29. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-en_US.js.map +1 -0
  30. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-en_US.min.js +8 -0
  31. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-es_CL.js +39 -0
  32. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-es_CL.js.map +1 -0
  33. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-es_CL.min.js +8 -0
  34. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-es_ES.js +39 -0
  35. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-es_ES.js.map +1 -0
  36. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-es_ES.min.js +8 -0
  37. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-et_EE.js +46 -0
  38. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-et_EE.js.map +1 -0
  39. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-et_EE.min.js +8 -0
  40. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-eu.js +39 -0
  41. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-eu.js.map +1 -0
  42. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-eu.min.js +8 -0
  43. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fa_IR.js +39 -0
  44. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fa_IR.js.map +1 -0
  45. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fa_IR.min.js +8 -0
  46. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fi_FI.js +46 -0
  47. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fi_FI.js.map +1 -0
  48. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fi_FI.min.js +8 -0
  49. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fr_FR.js +46 -0
  50. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fr_FR.js.map +1 -0
  51. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fr_FR.min.js +8 -0
  52. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-hr_HR.js +46 -0
  53. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-hr_HR.js.map +1 -0
  54. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-hr_HR.min.js +8 -0
  55. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-hu_HU.js +46 -0
  56. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-hu_HU.js.map +1 -0
  57. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-hu_HU.min.js +8 -0
  58. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-id_ID.js +39 -0
  59. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-id_ID.js.map +1 -0
  60. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-id_ID.min.js +8 -0
  61. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-it_IT.js +41 -0
  62. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-it_IT.js.map +1 -0
  63. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-it_IT.min.js +8 -0
  64. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ja_JP.js +39 -0
  65. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ja_JP.js.map +1 -0
  66. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ja_JP.min.js +8 -0
  67. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-kh_KM.js +46 -0
  68. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-kh_KM.js.map +1 -0
  69. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-kh_KM.min.js +8 -0
  70. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ko_KR.js +46 -0
  71. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ko_KR.js.map +1 -0
  72. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ko_KR.min.js +8 -0
  73. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-lt_LT.js +46 -0
  74. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-lt_LT.js.map +1 -0
  75. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-lt_LT.min.js +8 -0
  76. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-lv_LV.js +46 -0
  77. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-lv_LV.js.map +1 -0
  78. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-lv_LV.min.js +8 -0
  79. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-nb_NO.js +46 -0
  80. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-nb_NO.js.map +1 -0
  81. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-nb_NO.min.js +8 -0
  82. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-nl_NL.js +39 -0
  83. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-nl_NL.js.map +1 -0
  84. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-nl_NL.min.js +8 -0
  85. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pl_PL.js +39 -0
  86. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pl_PL.js.map +1 -0
  87. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pl_PL.min.js +8 -0
  88. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pt_BR.js +39 -0
  89. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pt_BR.js.map +1 -0
  90. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pt_BR.min.js +8 -0
  91. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pt_PT.js +39 -0
  92. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pt_PT.js.map +1 -0
  93. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pt_PT.min.js +8 -0
  94. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ro_RO.js +40 -0
  95. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ro_RO.js.map +1 -0
  96. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ro_RO.min.js +8 -0
  97. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ru_RU.js +40 -0
  98. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ru_RU.js.map +1 -0
  99. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ru_RU.min.js +8 -0
  100. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sk_SK.js +39 -0
  101. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sk_SK.js.map +1 -0
  102. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sk_SK.min.js +8 -0
  103. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sl_SI.js +44 -0
  104. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sl_SI.js.map +1 -0
  105. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sl_SI.min.js +8 -0
  106. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sv_SE.js +46 -0
  107. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sv_SE.js.map +1 -0
  108. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sv_SE.min.js +8 -0
  109. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-tr_TR.js +46 -0
  110. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-tr_TR.js.map +1 -0
  111. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-tr_TR.min.js +8 -0
  112. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ua_UA.js +39 -0
  113. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ua_UA.js.map +1 -0
  114. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ua_UA.min.js +8 -0
  115. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-vi_VN.js +46 -0
  116. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-vi_VN.js.map +1 -0
  117. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-vi_VN.min.js +8 -0
  118. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-zh_CN.js +39 -0
  119. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-zh_CN.js.map +1 -0
  120. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-zh_CN.min.js +8 -0
  121. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-zh_TW.js +39 -0
  122. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-zh_TW.js.map +1 -0
  123. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-zh_TW.min.js +8 -0
  124. data/app/assets/javascripts/common/bootstrap/bootstrap.bundle.js +7013 -0
  125. data/app/assets/javascripts/common/custom/custom.js +0 -0
  126. data/app/assets/javascripts/common/daterangepicker/daterangepicker.js +1565 -0
  127. data/app/assets/javascripts/common/flexslider/jquery.flexslider.js +1252 -0
  128. data/app/assets/javascripts/common/greenstock/greensock.js +36 -0
  129. data/app/assets/javascripts/common/icheck/icheck.js +509 -0
  130. data/app/assets/javascripts/common/imagesloaded/imagesloaded.pkgd.js +497 -0
  131. data/app/assets/javascripts/common/isotope/isotope.pkgd.js +3563 -0
  132. data/app/assets/javascripts/common/jquery-countdown/jquery.countdown.js +246 -0
  133. data/app/assets/javascripts/common/jquery-filterizer/jquery.filterizr.min.js +1 -0
  134. data/app/assets/javascripts/common/jquery-placeholder/jquery.placeholder.js +281 -0
  135. data/app/assets/javascripts/common/jquery-validation/jquery.validate.js +1650 -0
  136. data/app/assets/javascripts/common/jqvmap/jquery.vmap.js +1281 -0
  137. data/app/assets/javascripts/common/jqvmap/jquery.vmap.min.js +10 -0
  138. data/app/assets/javascripts/common/jqvmap/maps/continents/jquery.vmap.africa.js +2 -0
  139. data/app/assets/javascripts/common/jqvmap/maps/continents/jquery.vmap.asia.js +2 -0
  140. data/app/assets/javascripts/common/jqvmap/maps/continents/jquery.vmap.australia.js +2 -0
  141. data/app/assets/javascripts/common/jqvmap/maps/continents/jquery.vmap.europe.js +2 -0
  142. data/app/assets/javascripts/common/jqvmap/maps/continents/jquery.vmap.north-america.js +2 -0
  143. data/app/assets/javascripts/common/jqvmap/maps/continents/jquery.vmap.south-america.js +2 -0
  144. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.algeria.js +2 -0
  145. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.argentina.js +1 -0
  146. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.brazil.js +2 -0
  147. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.canada.js +2 -0
  148. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.europe.js +2 -0
  149. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.france.js +1 -0
  150. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.germany.js +2 -0
  151. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.greece.js +1 -0
  152. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.iran.js +6 -0
  153. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.iraq.js +1 -0
  154. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.russia.js +2 -0
  155. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.tunisia.js +2 -0
  156. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.turkey.js +11 -0
  157. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.usa.js +2 -0
  158. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.world.js +2 -0
  159. data/app/assets/javascripts/common/js-cookie/js.cookie.js +165 -0
  160. data/app/assets/javascripts/common/layerslider/layerslider.kreaturamedia.jquery.js +13 -0
  161. data/app/assets/javascripts/common/layerslider/layerslider.origami.js +13 -0
  162. data/app/assets/javascripts/common/layerslider/layerslider.timeline.js +13 -0
  163. data/app/assets/javascripts/common/layerslider/layerslider.transitions.js +13 -0
  164. data/app/assets/javascripts/common/leaflet/leaflet.js +5 -0
  165. data/app/assets/javascripts/common/magnific-popup/jquery.magnific-popup.js +1860 -0
  166. data/app/assets/javascripts/common/mapbox/mapbox.js +51 -0
  167. data/app/assets/javascripts/common/moderizer/modernizr.js +11 -0
  168. data/app/assets/javascripts/common/owl-carousel/owl.carousel.js +3448 -0
  169. data/app/assets/javascripts/common/pace/pace.js +935 -0
  170. data/app/assets/javascripts/common/paroller/jquery.paroller.js +228 -0
  171. data/app/assets/javascripts/common/particlejs/particles.js +1541 -0
  172. data/app/assets/javascripts/common/plyr/plyr.js +9137 -0
  173. data/app/assets/javascripts/common/rangeslider/rangeslider.js +498 -0
  174. data/app/assets/javascripts/common/retina/retina.js +100 -0
  175. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.actions.js +386 -0
  176. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.carousel.js +365 -0
  177. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.kenburn.js +199 -0
  178. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.layeranimation.js +2524 -0
  179. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.migration.js +260 -0
  180. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.navigation.js +1156 -0
  181. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.parallax.js +465 -0
  182. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.slideanims.js +1447 -0
  183. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.video.js +1464 -0
  184. data/app/assets/javascripts/common/rev-slider/jquery.themepunch.revolution.js +3286 -0
  185. data/app/assets/javascripts/common/rev-slider/jquery.themepunch.tools.min.js +8710 -0
  186. data/app/assets/javascripts/common/scrollup/jquery.scrollUp.js +168 -0
  187. data/app/assets/javascripts/common/select2/select2.full.js +6597 -0
  188. data/app/assets/javascripts/common/selectbox/jquery.selectBox.js +1092 -0
  189. data/app/assets/javascripts/common/smooth-scroll/SmoothScroll.js +788 -0
  190. data/app/assets/javascripts/common/spectrum/spectrum.js +2323 -0
  191. data/app/assets/javascripts/common/stepper/jquery.fs.stepper.js +339 -0
  192. data/app/assets/javascripts/common/swiper/swiper.js +8124 -0
  193. data/app/assets/javascripts/common/typed/typed.js +1045 -0
  194. data/app/assets/javascripts/common/visable/jquery.visible.js +68 -0
  195. data/app/assets/javascripts/common/waypoints/jquery.waypoints.js +662 -0
  196. data/app/assets/javascripts/phcthemes_web_theme_pack_appstrap.js +11 -0
  197. data/app/assets/javascripts/phcthemes_web_theme_pack_basic.js +39 -0
  198. data/app/assets/javascripts/phcthemes_web_theme_pack_bold.js +34 -0
  199. data/app/assets/javascripts/phcthemes_web_theme_pack_coloradmin.js +12 -0
  200. data/app/assets/javascripts/phcthemes_web_theme_pack_devine_villas.js +20 -0
  201. data/app/assets/javascripts/phcthemes_web_theme_pack_smarty.js +57 -0
  202. data/app/assets/javascripts/phcthemes_web_theme_pack_xero.js +18 -0
  203. data/app/assets/javascripts/phcthemes_web_theme_pack_zoner.js +24 -0
  204. data/app/assets/javascripts/themes/appstrap/custom/custom.js +0 -0
  205. data/app/assets/javascripts/themes/appstrap/theme/custom-script.js +69 -0
  206. data/app/assets/javascripts/themes/appstrap/theme/script.js +3096 -0
  207. data/app/assets/javascripts/themes/basic/custom/custom.js +0 -0
  208. data/app/assets/javascripts/themes/bold/custom/custom.js +0 -0
  209. data/app/assets/javascripts/themes/coloradmin/custom/custom.js +0 -0
  210. data/app/assets/javascripts/themes/coloradmin/theme/apps.js +236 -0
  211. data/app/assets/javascripts/themes/devine_villas/custom/custom.js +0 -0
  212. data/app/assets/javascripts/themes/devine_villas/theme/dashboard.js +19 -0
  213. data/app/assets/javascripts/themes/devine_villas/theme/main.js +384 -0
  214. data/app/assets/javascripts/themes/devine_villas/theme/map.js +563 -0
  215. data/app/assets/javascripts/themes/devine_villas/theme/searchmap.js +69 -0
  216. data/app/assets/javascripts/themes/smarty/custom/custom.js +0 -0
  217. data/app/assets/javascripts/themes/smarty/theme/scripts.js +4271 -0
  218. data/app/assets/javascripts/themes/xero/custom/custom.js +0 -0
  219. data/app/assets/javascripts/themes/xero/theme/app.js +696 -0
  220. data/app/assets/javascripts/themes/zoner/custom-maps/custom-map.js +289 -0
  221. data/app/assets/javascripts/themes/zoner/custom/custom.js +0 -0
  222. data/app/assets/javascripts/themes/zoner/draggable/draggable.js +196 -0
  223. data/app/assets/javascripts/themes/zoner/jquery-dependclass/dependclass.js +56 -0
  224. data/app/assets/javascripts/themes/zoner/jquery-slider/jquery.slider.js +700 -0
  225. data/app/assets/javascripts/themes/zoner/jquery-vanillabox/jquery.vanillabox.min.js +24 -0
  226. data/app/assets/javascripts/themes/zoner/jshashtable/hashtable.js +402 -0
  227. data/app/assets/javascripts/themes/zoner/numberformatter/numberformatter.js +566 -0
  228. data/app/assets/javascripts/themes/zoner/simple-js-templating/tmpl.js +35 -0
  229. data/app/assets/javascripts/themes/zoner/theme/main.js +667 -0
  230. data/app/assets/stylesheets/common/custom/custom.scss +0 -0
  231. data/app/assets/stylesheets/phcthemes_web_theme_pack_appstrap.scss +28 -0
  232. data/app/assets/stylesheets/phcthemes_web_theme_pack_basic.scss +0 -0
  233. data/app/assets/stylesheets/phcthemes_web_theme_pack_bold.scss +21 -0
  234. data/app/assets/stylesheets/phcthemes_web_theme_pack_coloradmin.scss +22 -0
  235. data/app/assets/stylesheets/phcthemes_web_theme_pack_devine_villas.scss +28 -0
  236. data/app/assets/stylesheets/phcthemes_web_theme_pack_smarty.scss +47 -0
  237. data/app/assets/stylesheets/phcthemes_web_theme_pack_xero.scss +28 -0
  238. data/app/assets/stylesheets/phcthemes_web_theme_pack_zoner.scss +22 -0
  239. data/app/assets/stylesheets/themes/appstrap/custom/custom.scss +0 -0
  240. data/app/assets/stylesheets/themes/bold/custom/custom.scss +0 -0
  241. data/app/assets/stylesheets/themes/coloradmin/custom/custom.scss +0 -0
  242. data/app/assets/stylesheets/themes/devine_villas/custom/custom.scss +0 -0
  243. data/app/assets/stylesheets/themes/smarty/custom/custom.scss +0 -0
  244. data/app/assets/stylesheets/themes/xero/custom/custom.scss +0 -0
  245. data/app/assets/stylesheets/themes/zoner/custom/custom.scss +0 -0
  246. data/lib/phcthemes_web_theme_pack.rb +5 -0
  247. data/lib/phcthemes_web_theme_pack/engine.rb +13 -0
  248. data/lib/phcthemes_web_theme_pack/version.rb +3 -0
  249. data/lib/tasks/phcthemes_web_theme_pack_tasks.rake +4 -0
  250. metadata +375 -0
@@ -0,0 +1,2524 @@
1
+ /************************************************
2
+ * REVOLUTION 5.4.6.5 EXTENSION - LAYER ANIMATION
3
+ * @version: 3.6.5 (10.06.2018)
4
+ * @requires jquery.themepunch.revolution.js
5
+ * @author ThemePunch
6
+ ************************************************/
7
+ ;(function($) {
8
+ "use strict";
9
+
10
+ var _R = jQuery.fn.revolution,
11
+ _ISM = _R.is_mobile(),
12
+ _ANDROID = _R.is_android(),
13
+ extension = { alias:"LayerAnimation Min JS",
14
+ name:"revolution.extensions.layeranimation.min.js",
15
+ min_core: "5.4.6.4",
16
+ version:"3.6.5"
17
+ };
18
+
19
+
20
+ ///////////////////////////////////////////
21
+ // EXTENDED FUNCTIONS AVAILABLE GLOBAL //
22
+ ///////////////////////////////////////////
23
+ jQuery.extend(true,_R, {
24
+
25
+ updateMarkup : function(layer,o) {
26
+
27
+ var d = jQuery(layer).data();
28
+
29
+ if (d.start!==undefined && !d.frames_added && d.frames===undefined) {
30
+
31
+ var frames = new Array(),
32
+ oin = getAnimDatas(newAnimObject(),d.transform_in,undefined, false),
33
+ oout = getAnimDatas(newAnimObject(),d.transform_out,undefined, false),
34
+ oh = getAnimDatas(newAnimObject(),d.transform_hover,undefined, false);
35
+
36
+ if (jQuery.isNumeric(d.end) && jQuery.isNumeric(d.start) && jQuery.isNumeric(oin.speed)) {
37
+ d.end = (parseInt(d.end,0) - (parseInt(d.start,0)+parseFloat(oin.speed,0)));
38
+ }
39
+
40
+ frames.push({frame:"0", delay:d.start, from:d.transform_in, to:d.transform_idle, split:d.splitin, speed:oin.speed, ease:oin.anim.ease, mask:d.mask_in, splitdelay:d.elementdelay});
41
+ frames.push({frame:"5", delay:d.end, to:d.transform_out, split:d.splitout, speed:oout.speed, ease:oout.anim.ease, mask:d.mask_out, splitdelay:d.elementdelay});
42
+ if (d.transform_hover)
43
+ frames.push({frame:"hover", to:d.transform_hover, style:d.style_hover, speed:oh.speed, ease:oh.anim.ease, splitdelay:d.elementdelay});
44
+ d.frames = frames;
45
+ //layer.frames_added = true;
46
+ }
47
+
48
+ if (!d.frames_added) {
49
+ d.inframeindex = 0;
50
+ d.outframeindex = -1;
51
+ d.hoverframeindex = -1;
52
+ if (d.frames!==undefined) {
53
+ for (var i=0;i<d.frames.length;i++) {
54
+ // CHECK FOR BLOCK SFX ANIMATION
55
+ if (d.frames[i].sfx_effect!==undefined && d.frames[i].sfx_effect.indexOf('block')>=0) {
56
+ if (i===0) {
57
+ d.frames[i].from = "o:0";
58
+ d.frames[i].to = "o:1";
59
+ } else {
60
+ d.frames[i].to = "o:0";
61
+ }
62
+
63
+ d._sfx = "block";
64
+ }
65
+
66
+ if (d.frames[0].from===undefined) d.frames[0].from = "o:inherit";
67
+
68
+ if (d.frames[0].delay===0) d.frames[0].delay=20;
69
+
70
+ if (d.frames[i].frame==="hover")
71
+ d.hoverframeindex = i;
72
+ else
73
+ if (d.frames[i].frame==="frame_999" || d.frames[i].frame==="frame_out" || d.frames[i].frame==="last" || d.frames[i].frame==="end")
74
+ d.outframeindex = i;
75
+
76
+ if (d.frames[i].split!==undefined && d.frames[i].split.match(/chars|words|lines/g))
77
+ d.splittext = true;
78
+ }
79
+
80
+ }
81
+
82
+ d.outframeindex = d.outframeindex===-1 ? d.hoverframeindex === -1 ? d.frames.length-1 : d.frames.length -2 : d.outframeindex; // CHECK LATER !!!
83
+ d.frames_added = true;
84
+
85
+ }
86
+
87
+ },
88
+
89
+ // MAKE SURE THE ANIMATION ENDS WITH A CLEANING ON MOZ TRANSFORMS
90
+ animcompleted : function(_nc,opt) {
91
+
92
+ var _ = _nc.data(),
93
+ t = _.videotype,
94
+ ap = _.autoplay,
95
+ an = _.autoplayonlyfirsttime;
96
+
97
+ if (t!=undefined && t!="none")
98
+ if (ap==true || ap=="true" || ap=="on" || ap=="1sttime" || an) {
99
+ if (opt.sliderType!=="carousel" ||
100
+ (opt.sliderType==="carousel" && opt.carousel.showLayersAllTime==="on" && _nc.closest('li').hasClass("active-revslide")) ||
101
+ (opt.sliderType==="carousel" && opt.carousel.showLayersAllTime!=="on" && _nc.closest('li').hasClass("active-revslide"))
102
+ )
103
+ _R.playVideo(_nc,opt);
104
+
105
+
106
+ _R.toggleState(_nc.data('videotoggledby'));
107
+ if ( an || ap=="1sttime") {
108
+ _.autoplayonlyfirsttime = false;
109
+ _.autoplay = "off";
110
+ }
111
+ } else {
112
+ if (ap=="no1sttime")
113
+ _.datasetautoplay = 'on';
114
+ _R.unToggleState(_nc.data('videotoggledby'));
115
+ }
116
+
117
+ },
118
+
119
+ /********************************************************
120
+ - PREPARE AND DEFINE STATIC LAYER DIRECTIONS -
121
+ *********************************************************/
122
+ handleStaticLayers : function(_nc,opt) {
123
+
124
+ var s = parseInt(_nc.data('startslide'),0),
125
+ e = parseInt(_nc.data('endslide'),0);
126
+
127
+ if (s < 0)
128
+ s=0;
129
+ if (e <0 )
130
+ e = opt.realslideamount;
131
+ if (s===0 && e===opt.realslideamount-1)
132
+ e = opt.realslideamount+1;
133
+ _nc.data('startslide',s);
134
+ _nc.data('endslide',e);
135
+ },
136
+
137
+ /************************************
138
+ ANIMATE ALL CAPTIONS
139
+ *************************************/
140
+ animateTheCaptions : function(obj) {
141
+
142
+
143
+ if (_R.compare_version(extension).check==="stop") return false;
144
+
145
+
146
+ var opt = obj.opt,
147
+ nextli = obj.slide,
148
+ recall = obj.recall,
149
+ mtl = obj.maintimeline,
150
+ preset = obj.preset,
151
+ startSlideAnimAt = obj.startslideanimat,
152
+ base_offsetx = opt.sliderType==="carousel" ? 0 : opt.width/2 - (opt.gridwidth[opt.curWinRange]*opt.bw)/2,
153
+ base_offsety=0,
154
+ index = nextli.data('index');
155
+
156
+ // COLLECTION OF LAYERS
157
+ opt.layers = opt.layers || new Object();
158
+ opt.layers[index] = opt.layers[index] || nextli.find('.tp-caption');
159
+ opt.layers["static"] = opt.layers["static"] || opt.c.find('.tp-static-layers').find('.tp-caption');
160
+
161
+ if (opt.timelines === undefined) _R.createTimelineStructure(opt);
162
+
163
+ opt.conh = opt.c.height();
164
+ opt.conw = opt.c.width();
165
+ opt.ulw = opt.ul.width();
166
+ opt.ulh = opt.ul.height();
167
+
168
+ /* ENABLE DEBUG MODE */
169
+ if (opt.debugMode) {
170
+ nextli.addClass("indebugmode");
171
+ nextli.find('.helpgrid').remove();
172
+ opt.c.find('.hglayerinfo').remove();
173
+ nextli.append('<div class="helpgrid" style="width:'+(opt.gridwidth[opt.curWinRange]*opt.bw)+'px;height:'+(opt.gridheight[opt.curWinRange]*opt.bw)+'px;"></div>');
174
+ var hg = nextli.find('.helpgrid');
175
+ hg.append('<div class="hginfo">Zoom:'+(Math.round(opt.bw*100))+'% &nbsp;&nbsp;&nbsp; Device Level:'+opt.curWinRange+'&nbsp;&nbsp;&nbsp; Grid Preset:'+opt.gridwidth[opt.curWinRange]+'x'+opt.gridheight[opt.curWinRange]+'</div>')
176
+ opt.c.append('<div class="hglayerinfo"></div>')
177
+ hg.append('<div class="tlhg"></div>');
178
+ }
179
+
180
+ // PREPARE THE LAYERS
181
+ if (index!==undefined && opt.layers[index])
182
+ jQuery.each(opt.layers[index], function(i,a) {
183
+ var _t = jQuery(this);
184
+ _R.updateMarkup(this,opt);
185
+ _R.prepareSingleCaption({caption:_t, opt:opt, offsetx:base_offsetx, offsety:base_offsety, index:i, recall:recall, preset:preset});
186
+ if (!preset || startSlideAnimAt===0) _R.buildFullTimeLine({caption:_t, opt:opt, offsetx:base_offsetx, offsety:base_offsety, index:i, recall:recall, preset:preset, regenerate: startSlideAnimAt===0});
187
+
188
+ if (recall && opt.sliderType==="carousel" && opt.carousel.showLayersAllTime==="on") _R.animcompleted(_t,opt);
189
+ });
190
+
191
+ if (opt.layers["static"])
192
+ jQuery.each(opt.layers["static"], function(i,a) {
193
+ var _t = jQuery(this),
194
+ _ = _t.data();
195
+
196
+ if (_.hoveredstatus!==true && _.inhoveroutanimation!==true) {
197
+ _R.updateMarkup(this,opt);
198
+ _R.prepareSingleCaption({caption:_t, opt:opt, offsetx:base_offsetx, offsety:base_offsety, index:i, recall:recall, preset:preset});
199
+
200
+ if ((!preset || startSlideAnimAt===0) && _.veryfirstststic !==true) {
201
+ _R.buildFullTimeLine({caption:_t, opt:opt, offsetx:base_offsetx, offsety:base_offsety, index:i, recall:recall, preset:preset, regenerate: startSlideAnimAt===0});
202
+ _.veryfirstststic = true;
203
+ }
204
+ if (recall && opt.sliderType==="carousel" && opt.carousel.showLayersAllTime==="on") _R.animcompleted(_t,opt);
205
+
206
+ } else {
207
+ _R.prepareSingleCaption({caption:_t, opt:opt, offsetx:base_offsetx, offsety:base_offsety, index:i, recall:recall, preset:preset});
208
+ }
209
+ });
210
+
211
+
212
+ // RECALCULATE HEIGHTS OF SLIDE IF ROW EXIST
213
+ var _actli = opt.nextSlide === -1 || opt.nextSlide===undefined ? 0 : opt.nextSlide;
214
+ if (opt.rowzones!==undefined)
215
+ _actli = _actli>opt.rowzones.length ? opt.rowzones.length : _actli;
216
+ if (opt.rowzones!=undefined && opt.rowzones.length>0 && opt.rowzones[_actli]!=undefined && _actli>=0 && _actli<=opt.rowzones.length && opt.rowzones[_actli].length>0)
217
+ _R.setSize(opt);
218
+
219
+
220
+ // RESTART ANIMATION TIMELINES
221
+
222
+ if (!preset)
223
+ if (startSlideAnimAt!==undefined) {
224
+ if (index!==undefined)
225
+ jQuery.each(opt.timelines[index].layers,function(key,o) {
226
+ var _ = o.layer.data();
227
+ if (o.wrapper==="none" || o.wrapper===undefined) {
228
+ if (o.triggerstate=="keep" && _.triggerstate==="on")
229
+ _R.playAnimationFrame({caption:o.layer,opt:opt,frame:"frame_0", triggerdirection:"in", triggerframein:"frame_0", triggerframeout:"frame_999"});
230
+ else
231
+ o.timeline.restart();
232
+ }
233
+ });
234
+ if (opt.timelines.staticlayers)
235
+ jQuery.each(opt.timelines.staticlayers.layers,function(key,o) {
236
+
237
+ var _ = o.layer.data(),
238
+ in_v_range = _actli>=o.firstslide && _actli<=o.lastslide,
239
+ in_uv_range = _actli<o.firstslide || _actli>o.lastslide,
240
+ flt = o.timeline.getLabelTime("slide_"+o.firstslide),
241
+ elt = o.timeline.getLabelTime("slide_"+o.lastslide),
242
+ ct = _.static_layer_timeline_time,
243
+ isvisible = _.animdirection==="in" ? true : _.animdirection==="out" ? false : undefined,
244
+ triggered_in = _.frames[0].delay==="bytrigger",
245
+ triggered_out = _.frames[_.frames.length-1].delay==="bytrigger",
246
+ layer_start_status = _.triggered_startstatus,
247
+ triggerstate = _.lasttriggerstate;
248
+
249
+ if (_.hoveredstatus===true || _.inhoveroutanimation==true) return;
250
+
251
+ /*console.log("-----------------------")
252
+ console.log("Show Static Layer Start")
253
+ console.log("-----------------------")
254
+ console.log(ct);
255
+ console.log(isvisible)*/
256
+
257
+ // LAYER ALREADY VISIBLE, TIMER IS NOT UNKNOW ANY MORE
258
+ if (ct!==undefined && isvisible) {
259
+ if (triggerstate=="keep") {
260
+
261
+ _R.playAnimationFrame({caption:o.layer,opt:opt,frame:"frame_0", triggerdirection:"in", triggerframein:"frame_0", triggerframeout:"frame_999"});
262
+ _.triggeredtimeline.time(ct);
263
+ }
264
+ else {
265
+
266
+ if (_.hoveredstatus!==true)
267
+ o.timeline.time(ct);
268
+ }
269
+ }
270
+
271
+
272
+
273
+ // RESET STATUS ALWAYS TO HIDDEN
274
+ if (triggerstate==="reset" && layer_start_status==="hidden") {
275
+ //console.log("Pre Path X");
276
+ o.timeline.time(0);
277
+ _.animdirection = "out";
278
+ }
279
+
280
+ //console.log("in Range:"+in_v_range+" "+o.firstslide+" <= "+_actli+" <= "+o.lastslide);
281
+ // LAYER IS ON SLIDE TO SHOW, OR LAYER NEED TO DISAPPEAR
282
+ if (in_v_range) {
283
+ if (isvisible) {
284
+ //console.log("Path A");
285
+ if (_actli===o.lastslide) {
286
+ //console.log("Path A.1");
287
+ o.timeline.play(elt);
288
+ _.animdirection = "in";
289
+ }
290
+ } else {
291
+ //console.log("Path B");
292
+ //console.log(triggered_in+" "+_.animdirection)
293
+ if (!triggered_in && _.animdirection!=="in") {
294
+ //console.log("Path B.1")
295
+ o.timeline.play(flt);
296
+ }
297
+ if ((layer_start_status=="visible" && triggerstate!=="keep") || (triggerstate==="keep" && isvisible===true) || (layer_start_status=="visible" && isvisible===undefined)) {
298
+ //console.log("Path B.2");
299
+ o.timeline.play(flt+0.01);
300
+ _.animdirection = "in";
301
+ }
302
+ }
303
+ } else {
304
+ //console.log("Path C");
305
+ if (in_uv_range) {
306
+ //console.log("Path C.1");
307
+ if (isvisible) {
308
+ //console.log("Path C.1.1")
309
+ o.timeline.play("frame_999");
310
+ } else {
311
+ //console.log("Path C.1.2")
312
+ }
313
+ }
314
+ }
315
+
316
+ });
317
+
318
+ }
319
+
320
+
321
+
322
+ // RESUME THE MAIN TIMELINE NOW
323
+ if (mtl != undefined) setTimeout(function() {
324
+
325
+ mtl.resume();
326
+ },30);
327
+
328
+
329
+
330
+
331
+ },
332
+
333
+
334
+
335
+ /********************************************
336
+ PREPARE ALL LAYER SIZES, POSITION
337
+ ********************************************/
338
+ prepareSingleCaption : function(obj) {
339
+
340
+ var _nc = obj.caption,
341
+ _ = _nc.data(),
342
+ opt = obj.opt,
343
+ recall = obj.recall,
344
+ internrecall = obj.recall,
345
+ preset = obj.preset,
346
+ rtl = jQuery('body').hasClass("rtl"),
347
+ datas;
348
+
349
+ _._pw = _._pw===undefined ? _nc.closest('.tp-parallax-wrap') : _._pw;
350
+ _._lw = _._lw===undefined ? _nc.closest('.tp-loop-wrap') : _._lw;
351
+ _._mw = _._mw===undefined ? _nc.closest('.tp-mask-wrap') : _._mw;
352
+
353
+ _._responsive = _.responsive || "on";
354
+ _._respoffset = _.responsive_offset || "on";
355
+ _._ba = _.basealign || "grid";
356
+ _._gw = _._ba==="grid" ? opt.width : opt.ulw;
357
+ _._gh = _._ba==="grid" ? opt.height : opt.ulh;
358
+
359
+
360
+ _._lig = _._lig===undefined ? _nc.hasClass("rev_layer_in_group") ? _nc.closest('.rev_group') : _nc.hasClass("rev_layer_in_column") ?_nc.closest('.rev_column_inner') : _nc.hasClass("rev_column_inner") ? _nc.closest(".rev_row") : "none" : _._lig,
361
+ _._column = _._column===undefined ? _nc.hasClass("rev_column_inner") ? _nc.closest(".rev_column") : "none" : _._column,
362
+ _._row = _._row===undefined ? _nc.hasClass("rev_column_inner") ? _nc.closest(".rev_row") : "none" : _._row,
363
+ _._ingroup = _._ingroup===undefined ? !_nc.hasClass('rev_group') && _nc.closest('.rev_group') ? true : false :_._ingroup;
364
+ _._isgroup = _._isgroup===undefined ? _nc.hasClass("rev_group") ? true : false : _._isgroup;
365
+ _._nctype = _.type || "none";
366
+ _._cbgc_auto = _._cbgc_auto===undefined ? _._nctype==="column" ? _._pw.find('.rev_column_bg_auto_sized') : false : _._cbgc_auto;
367
+ _._cbgc_man = _._cbgc_man===undefined ? _._nctype==="column" ? _._pw.find('.rev_column_bg_man_sized') : false : _._cbgc_man;
368
+ _._slideid = _._slideid || _nc.closest('.tp-revslider-slidesli').data('index');
369
+ _._id = _._id===undefined ? _nc.data('id') || _nc.attr('id') : _._id;
370
+ _._slidelink = _._slidelink===undefined ? _nc.hasClass("slidelink")===undefined ? false : _nc.hasClass("slidelink") : _._slidelink;
371
+
372
+ if (_._li===undefined)
373
+ if (_nc.hasClass("tp-static-layer")) {
374
+ _._isstatic = true;
375
+ _._li = _nc.closest('.tp-static-layers');
376
+ _._slideid = "staticlayers";
377
+ } else {
378
+ _._li = _nc.closest('.tp-revslider-slidesli');
379
+ }
380
+
381
+ _._row = _._row===undefined ? _._nctype==="column" ? _._pw.closest('.rev_row') : false : _._row;
382
+
383
+ if (_._togglelisteners===undefined && _nc.find('.rs-toggled-content')) {
384
+ _._togglelisteners = true;
385
+ if (_.actions===undefined) _nc.click(function() {_R.swaptoggleState(_nc); })
386
+
387
+ } else {
388
+ _._togglelisteners = false;
389
+ }
390
+
391
+ if (opt.sliderLayout=="fullscreen")
392
+ obj.offsety = _._gh/2 - (opt.gridheight[opt.curWinRange]*opt.bh)/2;
393
+
394
+ if (opt.autoHeight=="on" || (opt.minHeight!=undefined && opt.minHeight>0))
395
+ obj.offsety = opt.conh/2 - (opt.gridheight[opt.curWinRange]*opt.bh)/2;;
396
+
397
+ if (obj.offsety<0) obj.offsety=0;
398
+
399
+ // LAYER GRID FOR DEBUGGING
400
+ if (opt.debugMode) {
401
+ _nc.closest('li').find('.helpgrid').css({top:obj.offsety+"px", left:obj.offsetx+"px"});
402
+ var linfo = opt.c.find('.hglayerinfo');
403
+ _nc.on("hover, mouseenter",function() {
404
+ var ltxt = "",
405
+ spa = 0;
406
+ if (_nc.data())
407
+ jQuery.each(_nc.data(),function(key,val) {
408
+ if (typeof val !== "object") {
409
+
410
+ ltxt = ltxt + '<span style="white-space:nowrap"><span style="color:#27ae60">'+key+":</span>"+val+"</span>&nbsp; &nbsp; ";
411
+
412
+ }
413
+ });
414
+ linfo.html(ltxt);
415
+ });
416
+ }
417
+ /* END OF DEBUGGING */
418
+
419
+ var handlecaption=0,
420
+ layervisible = _.visibility === undefined ? "oon" : makeArray(_.visibility,opt)[opt.forcedWinRange] || makeArray(_.visibility,opt) || "ooon";
421
+
422
+ // HIDE CAPTION IF RESOLUTION IS TOO LOW
423
+ if (layervisible==="off" || (_._gw<opt.hideCaptionAtLimit && _.captionhidden=="on") || (_._gw<opt.hideAllCaptionAtLimit))
424
+ _._pw.addClass("tp-hidden-caption");
425
+ else
426
+ _._pw.removeClass("tp-hidden-caption")
427
+
428
+ _.layertype = "html";
429
+
430
+
431
+ if (obj.offsetx<0) obj.offsetx=0;
432
+
433
+ // FALL BACK TO NORMAL IMAGES
434
+ if (_.thumbimage !=undefined && _.videoposter==undefined)
435
+ _.videoposter = _.thumbimage;
436
+
437
+ // IF IT IS AN IMAGE
438
+ if (_nc.find('img').length>0) {
439
+ var im = _nc.find('img');
440
+ _.layertype = "image";
441
+ if (im.width()==0) im.css({width:"auto"});
442
+ if (im.height()==0) im.css({height:"auto"});
443
+ if (im.data('ww') == undefined && im.width()>0) im.data('ww',im.width());
444
+ if (im.data('hh') == undefined && im.height()>0) im.data('hh',im.height());
445
+
446
+
447
+ var ww = im.data('ww'),
448
+ hh = im.data('hh'),
449
+ fuw = _._ba =="slide" ? opt.ulw : opt.gridwidth[opt.curWinRange],
450
+ fuh = _._ba =="slide" ? opt.ulh : opt.gridheight[opt.curWinRange];
451
+
452
+ ww = makeArray(im.data('ww'),opt)[opt.curWinRange] || makeArray(im.data('ww'),opt) || "auto",
453
+ hh = makeArray(im.data('hh'),opt)[opt.curWinRange] || makeArray(im.data('hh'),opt) || "auto";
454
+
455
+
456
+
457
+ var wful = ww==="full" || ww === "full-proportional",
458
+ hful = hh==="full" || hh === "full-proportional";
459
+
460
+ if (ww==="full-proportional") {
461
+ var ow = im.data('owidth'),
462
+ oh = im.data('oheight');
463
+ if (ow/fuw < oh/fuh) {
464
+ ww = fuw;
465
+ hh = oh*(fuw/ow);
466
+ } else {
467
+ hh = fuh;
468
+ ww = ow*(fuh/oh);
469
+ }
470
+ } else {
471
+
472
+ ww = wful ? fuw : !jQuery.isNumeric(ww) && ww.indexOf("%")>0 ? ww : parseFloat(ww);
473
+ hh = hful ? fuh : !jQuery.isNumeric(hh) && hh.indexOf("%")>0 ? hh : parseFloat(hh);
474
+ }
475
+
476
+ ww = ww===undefined ? 0 : ww;
477
+ hh = hh===undefined ? 0 : hh;
478
+
479
+
480
+ if (_._responsive!=="off") {
481
+ if (_._ba!="grid" && wful)
482
+ if (jQuery.isNumeric(ww))
483
+ im.css({width:ww+"px"});
484
+ else
485
+ im.css({width:ww});
486
+ else
487
+ if (jQuery.isNumeric(ww))
488
+ im.css({width:(ww*opt.bw)+"px"});
489
+ else
490
+ im.css({width:ww});
491
+
492
+ if (_._ba!="grid" && hful)
493
+ if (jQuery.isNumeric(hh))
494
+ im.css({height:hh+"px"});
495
+ else
496
+ im.css({height:hh});
497
+
498
+ else
499
+ if (jQuery.isNumeric(hh))
500
+ im.css({height:(hh*opt.bh)+"px"});
501
+ else
502
+ im.css({height:hh});
503
+
504
+ } else {
505
+ im.css({width:ww, height:hh});
506
+
507
+ }
508
+
509
+
510
+ if (_._ingroup && _._nctype!=="row") {
511
+ if (ww!==undefined && !jQuery.isNumeric(ww) && jQuery.type(ww)==="string" && ww.indexOf("%")>0)
512
+ punchgs.TweenLite.set([_._lw,_._pw,_._mw],{minWidth:ww});
513
+
514
+
515
+ if (hh!==undefined && !jQuery.isNumeric(hh) && jQuery.type(hh)==="string" && hh.indexOf("%")>0)
516
+ punchgs.TweenLite.set([_._lw,_._pw,_._mw],{minHeight:hh});
517
+ }
518
+
519
+
520
+ }
521
+
522
+
523
+ if (_._ba==="slide") {
524
+ obj.offsetx = 0;
525
+ obj.offsety=0;
526
+ } else {
527
+ if (_._isstatic && opt.carousel!==undefined && opt.carousel.horizontal_align!==undefined && opt.sliderType==="carousel") {
528
+ switch (opt.carousel.horizontal_align) {
529
+ case "center":
530
+ obj.offsetx = 0 + (opt.ulw - (opt.gridwidth[opt.curWinRange]*opt.bw))/2;
531
+
532
+ break;
533
+ case "left":
534
+ break;
535
+ case "right":
536
+ obj.offsetx = (opt.ulw - (opt.gridwidth[opt.curWinRange]*opt.bw));
537
+ break;
538
+ }
539
+ obj.offsetx = obj.offsetx<0 ? 0 : obj.offsetx;
540
+ }
541
+ }
542
+
543
+
544
+
545
+ var tag = _.audio=="html5" ? "audio" : "video";
546
+
547
+ // IF IT IS A VIDEO LAYER
548
+ if (_nc.hasClass("tp-videolayer") || _nc.hasClass("tp-audiolayer") || _nc.find('iframe').length>0 || _nc.find(tag).length>0) {
549
+
550
+ _.layertype = "video";
551
+ if (_R.manageVideoLayer) _R.manageVideoLayer(_nc,opt,recall,internrecall);
552
+ if (!recall && !internrecall) {
553
+ var t = _.videotype;
554
+ if (_R.resetVideo) _R.resetVideo(_nc,opt,obj.preset);
555
+ }
556
+
557
+ var asprat = _.aspectratio;
558
+ if (asprat!=undefined && asprat.split(":").length>1)
559
+ _R.prepareCoveredVideo(opt,_nc);
560
+
561
+ var im = _nc.find('iframe') ? _nc.find('iframe') : im = _nc.find(tag),
562
+ html5vid = _nc.find('iframe') ? false : true,
563
+ yvcover = _nc.hasClass('coverscreenvideo');
564
+
565
+ im.css({display:"block"});
566
+
567
+ // SET WIDTH / HEIGHT
568
+ if (_nc.data('videowidth') == undefined) {
569
+ _nc.data('videowidth',im.width());
570
+ _nc.data('videoheight',im.height());
571
+ }
572
+ var ww = makeArray(_nc.data('videowidth'),opt)[opt.curWinRange] || makeArray(_nc.data('videowidth'),opt) || "auto",
573
+ hh = makeArray(_nc.data('videoheight'),opt)[opt.curWinRange] || makeArray(_nc.data('videoheight'),opt) || "auto";
574
+
575
+ /*if (!jQuery.isNumeric(ww) && ww.indexOf("%")>0) {
576
+ hh = (parseFloat(hh)*opt.bh)+"px";
577
+ } else {
578
+ ww = (parseFloat(ww)*opt.bw)+"px";
579
+ hh = (parseFloat(hh)*opt.bh)+"px";
580
+ }*/
581
+
582
+
583
+ if (ww==="auto" || (!jQuery.isNumeric(ww) && ww.indexOf("%")>0)) {
584
+ ww = ww==="auto" ? "auto" : _._ba==="grid" ? opt.gridwidth[opt.curWinRange]*opt.bw : _._gw;
585
+ } else {
586
+ ww = (parseFloat(ww)*opt.bw)+"px";
587
+ }
588
+
589
+ if (hh==="auto" || (!jQuery.isNumeric(hh) && hh.indexOf("%")>0)) {
590
+ hh = hh==="auto" ? "auto" : _._ba==="grid" ? opt.gridheight[opt.curWinRange]*opt.bw : _._gh;
591
+ } else {
592
+ hh = (parseFloat(hh)*opt.bh)+"px";
593
+ }
594
+
595
+
596
+ // READ AND WRITE CSS SETTINGS OF IFRAME AND VIDEO FOR RESIZING ELEMENST ON DEMAND
597
+ _.cssobj = _.cssobj===undefined ? getcssParams(_nc,0) : _.cssobj;
598
+
599
+
600
+ var ncobj = setResponsiveCSSValues(_.cssobj,opt);
601
+
602
+
603
+ // IE8 FIX FOR AUTO LINEHEIGHT
604
+ if (ncobj.lineHeight=="auto") ncobj.lineHeight = ncobj.fontSize+4;
605
+
606
+
607
+ if (!_nc.hasClass('fullscreenvideo') && !yvcover) {
608
+
609
+ punchgs.TweenLite.set(_nc,{
610
+ paddingTop: Math.round((ncobj.paddingTop * opt.bh)) + "px",
611
+ paddingBottom: Math.round((ncobj.paddingBottom * opt.bh)) + "px",
612
+ paddingLeft: Math.round((ncobj.paddingLeft* opt.bw)) + "px",
613
+ paddingRight: Math.round((ncobj.paddingRight * opt.bw)) + "px",
614
+ marginTop: (ncobj.marginTop * opt.bh) + "px",
615
+ marginBottom: (ncobj.marginBottom * opt.bh) + "px",
616
+ marginLeft: (ncobj.marginLeft * opt.bw) + "px",
617
+ marginRight: (ncobj.marginRight * opt.bw) + "px",
618
+ borderTopWidth: Math.round(ncobj.borderTopWidth * opt.bh) + "px",
619
+ borderBottomWidth: Math.round(ncobj.borderBottomWidth * opt.bh) + "px",
620
+ borderLeftWidth: Math.round(ncobj.borderLeftWidth * opt.bw) + "px",
621
+ borderRightWidth: Math.round(ncobj.borderRightWidth * opt.bw) + "px",
622
+ width:ww,
623
+ height:hh
624
+ });
625
+ } else {
626
+ obj.offsetx=0; obj.offsety=0;
627
+ _nc.data('x',0)
628
+ _nc.data('y',0)
629
+
630
+ var ovhh = _._gh;
631
+ if (opt.autoHeight=="on") ovhh = opt.conh
632
+ _nc.css({'width':_._gw, 'height':ovhh });
633
+ }
634
+
635
+
636
+ if ((html5vid == false && !yvcover) || ((_.forcecover!=1 && !_nc.hasClass('fullscreenvideo') && !yvcover))) {
637
+
638
+ im.width(ww);
639
+ im.height(hh);
640
+ }
641
+
642
+ if (_._ingroup) {
643
+ if (_.videowidth!==null && _.videowidth!==undefined && !jQuery.isNumeric(_.videowidth) && _.videowidth.indexOf("%")>0)
644
+ punchgs.TweenLite.set([_._lw,_._pw,_._mw],{minWidth:_.videowidth});
645
+ }
646
+
647
+ } // END OF POSITION AND STYLE READ OUTS OF VIDEO
648
+
649
+
650
+
651
+ // RESPONIVE HANDLING OF CURRENT LAYER
652
+ calcCaptionResponsive(_nc,opt,0,_._responsive);
653
+
654
+
655
+ // ALL ELEMENTS IF THE MAIN ELEMENT IS REKURSIVE RESPONSIVE SHOULD BE REPONSIVE HANDLED
656
+ if (_nc.hasClass("tp-resizeme"))
657
+ _nc.find('*').each(function() {
658
+ calcCaptionResponsive(jQuery(this),opt,"rekursive",_._responsive);
659
+ });
660
+
661
+ // _nc FRONTCORNER CHANGES
662
+ var ncch = _nc.outerHeight(),
663
+ bgcol = _nc.css('backgroundColor');
664
+ sharpCorners(_nc,'.frontcorner','left','borderRight','borderTopColor',ncch,bgcol);
665
+ sharpCorners(_nc,'.frontcornertop','left','borderRight','borderBottomColor',ncch,bgcol);
666
+ sharpCorners(_nc,'.backcorner','right','borderLeft','borderBottomColor',ncch,bgcol);
667
+ sharpCorners(_nc,'.backcornertop','right','borderLeft','borderTopColor',ncch,bgcol);
668
+
669
+
670
+ if (opt.fullScreenAlignForce == "on") {
671
+ obj.offsetx=0;
672
+ obj.offsety=0;
673
+ }
674
+
675
+ // BLOCK ANIMATION ON LAYERS
676
+ if (_._sfx==="block")
677
+ if (_._bmask === undefined) {
678
+ _._bmask = jQuery('<div class="tp-blockmask"></div>');
679
+ _._mw.append(_._bmask);
680
+ }
681
+
682
+
683
+ _.arrobj = new Object();
684
+ _.arrobj.voa = makeArray(_.voffset,opt)[opt.curWinRange] || makeArray(_.voffset,opt)[0];
685
+ _.arrobj.hoa = makeArray(_.hoffset,opt)[opt.curWinRange] || makeArray(_.hoffset,opt)[0];
686
+ _.arrobj.elx = makeArray(_.x,opt)[opt.curWinRange] || makeArray(_.x,opt)[0];
687
+ _.arrobj.ely = makeArray(_.y,opt)[opt.curWinRange] || makeArray(_.y,opt)[0];
688
+
689
+
690
+ var voa = _.arrobj.voa.length==0 ? 0 : _.arrobj.voa,
691
+ hoa = _.arrobj.hoa.length==0 ? 0 : _.arrobj.hoa,
692
+ elx = _.arrobj.elx.length==0 ? 0 : _.arrobj.elx,
693
+ ely = _.arrobj.ely.length==0 ? 0 : _.arrobj.ely;
694
+
695
+
696
+
697
+
698
+ _.eow = _nc.outerWidth(true);
699
+ _.eoh = _nc.outerHeight(true);
700
+
701
+
702
+
703
+
704
+ // NEED CLASS FOR FULLWIDTH AND FULLHEIGHT LAYER SETTING !!
705
+ if (_.eow==0 && _.eoh==0) {
706
+ _.eow = opt.ulw;
707
+ _.eoh = opt.ulh;
708
+ }
709
+
710
+
711
+ var vofs= _._respoffset !=="off" ? parseInt(voa,0)*opt.bw : parseInt(voa,0),
712
+ hofs= _._respoffset !=="off" ? parseInt(hoa,0)*opt.bw : parseInt(hoa,0),
713
+ crw = _._ba==="grid" ? opt.gridwidth[opt.curWinRange]*opt.bw : _._gw,
714
+ crh = _._ba==="grid" ? opt.gridheight[opt.curWinRange]*opt.bw : _._gh;
715
+
716
+
717
+ if (opt.fullScreenAlignForce == "on") {
718
+ crw = opt.ulw;
719
+ crh = opt.ulh;
720
+ }
721
+
722
+ // ALIGN POSITIONED ELEMENTS
723
+ if (_._lig!=="none" && _._lig!=undefined) {
724
+ crw=_._lig.width();
725
+ crh=_._lig.height();
726
+ obj.offsetx =0;
727
+ obj.offsety = 0;
728
+ }
729
+
730
+
731
+ elx = elx==="center" || elx==="middle" ? (crw/2 - _.eow/2) + hofs : elx==="left" ? hofs : elx==="right" ? (crw - _.eow) - hofs : _._respoffset !=="off" ? elx * opt.bw : elx;
732
+ ely = ely=="center" || ely=="middle" ? (crh/2 - _.eoh/2) + vofs : ely =="top" ? vofs : ely=="bottom" ? (crh - _.eoh)-vofs : _._respoffset !=="off" ? ely*opt.bw : ely;
733
+
734
+ if (rtl && !_._slidelink)
735
+ elx = elx + _.eow;
736
+
737
+ if (_._slidelink) elx=0;
738
+
739
+
740
+
741
+ _.calcx = (parseInt(elx,0)+obj.offsetx);
742
+ _.calcy = (parseInt(ely,0)+obj.offsety);
743
+
744
+
745
+ var tpcapindex = _nc.css("z-Index");
746
+
747
+
748
+
749
+ // SET TOP/LEFT POSITION OF LAYER
750
+ if (_._nctype!=="row" && _._nctype!=="column")
751
+ punchgs.TweenLite.set(_._pw,{zIndex:tpcapindex, top:_.calcy,left:_.calcx,overwrite:"auto"});
752
+ else
753
+ if (_._nctype!=="row")
754
+ punchgs.TweenLite.set(_._pw,{zIndex:tpcapindex, width:_.columnwidth, top:0,left:0,overwrite:"auto"});
755
+ else
756
+ if (_._nctype==="row") {
757
+ var _roww = _._ba==="grid" ? crw+"px" : "100%";
758
+ punchgs.TweenLite.set(_._pw,{zIndex:tpcapindex, width:_roww, top:0,left:obj.offsetx,overwrite:"auto"});
759
+ }
760
+ if (_.blendmode!==undefined)
761
+ punchgs.TweenLite.set(_._pw,{mixBlendMode:_.blendmode});
762
+
763
+ /*if (_._nctype==="svg") {
764
+ _.svgcontainer = _.svgcontainer===undefined ? _nc.find('.tp-svg-innercontainer') : _.svgcontainer;
765
+ punchgs.TweenLite.set(_.svgcontainer,{ ... });
766
+ }*/
767
+
768
+ //SET ROW BROKEN / TABLE FORMED
769
+ if (_._nctype==="row") {
770
+ if (_.columnbreak<=opt.curWinRange) {
771
+ _nc.addClass("rev_break_columns");
772
+ } else {
773
+ _nc.removeClass("rev_break_columns");
774
+ }
775
+ }
776
+
777
+ // LOOP ANIMATION WIDTH/HEIGHT
778
+ if (_.loopanimation=="on") punchgs.TweenLite.set(_._lw,{minWidth:_.eow,minHeight:_.eoh});
779
+
780
+ //Preset Position of BG
781
+ if (_._nctype==="column") {
782
+ var tempy = _nc[0]._gsTransform !==undefined ? _nc[0]._gsTransform.y : 0,
783
+ pT = parseInt(_._column[0].style.paddingTop,0);
784
+ punchgs.TweenLite.set(_nc,{y:0});
785
+ punchgs.TweenLite.set(_._cbgc_man,{y:parseInt(( pT+_._column.offset().top-_nc.offset().top),0)});
786
+ punchgs.TweenLite.set(_nc,{y:tempy});
787
+ }
788
+
789
+ // ELEMENT IN GROUPS WITH % WIDTH AND HEIGHT SHOULD EXTEND PARRENT SIZES
790
+ if (_._ingroup && _._nctype!=="row") {
791
+ if (_._groupw!==undefined && !jQuery.isNumeric(_._groupw) && _._groupw.indexOf("%")>0)
792
+ punchgs.TweenLite.set([_._lw,_._pw,_._mw],{minWidth:_._groupw});
793
+
794
+ if (_._grouph!==undefined && !jQuery.isNumeric(_._grouph) && _._grouph.indexOf("%")>0)
795
+ punchgs.TweenLite.set([_._lw,_._pw,_._mw],{minHeight:_._grouph});
796
+ }
797
+
798
+ },
799
+
800
+
801
+ /********************************************
802
+ BUILD THE TIMELINE STRUCTURES
803
+ ********************************************/
804
+ createTimelineStructure : function(opt) {
805
+
806
+
807
+ // COLLECTION OF TIMELINES
808
+ opt.timelines = opt.timelines || new Object();
809
+
810
+ function addTimeLineWithLabel(layer,opt,parentobject,slideid) {
811
+ var timeline = new punchgs.TimelineLite({paused:true}),
812
+ c;
813
+
814
+
815
+ parentobject = parentobject || new Object();
816
+ parentobject[layer.attr('id')] = parentobject[layer.attr('id')] || new Object();
817
+ if (slideid==="staticlayers") {
818
+ parentobject[layer.attr('id')].firstslide = layer.data('startslide');
819
+ parentobject[layer.attr('id')].lastslide = layer.data('endslide');
820
+ }
821
+
822
+
823
+ layer.data('slideid',slideid);
824
+ parentobject[layer.attr('id')].defclasses=c=layer[0].className;
825
+ parentobject[layer.attr('id')].wrapper = c.indexOf("rev_layer_in_column")>=0 ? layer.closest('.rev_column_inner') : c.indexOf("rev_column_inner")>=0 ? layer.closest(".rev_row") : c.indexOf("rev_layer_in_group")>=0 ? layer.closest(".rev_group") : "none";
826
+ parentobject[layer.attr('id')].timeline = timeline;
827
+ parentobject[layer.attr('id')].layer = layer;
828
+ parentobject[layer.attr('id')].triggerstate = layer.data('lasttriggerstate');
829
+ parentobject[layer.attr('id')].dchildren = c.indexOf("rev_row")>=0 ? layer[0].getElementsByClassName('rev_column_inner') : c.indexOf("rev_column_inner")>=0 ? layer[0].getElementsByClassName('tp-caption') : c.indexOf("rev_group")>=0 ? layer[0].getElementsByClassName('rev_layer_in_group') : "none";
830
+ layer.data('timeline',timeline);
831
+
832
+ }
833
+
834
+
835
+ //GO THROUGH ALL LI
836
+ opt.c.find('.tp-revslider-slidesli, .tp-static-layers').each(function() {
837
+ var slide = jQuery(this),
838
+ index = slide.data('index');
839
+ opt.timelines[index] = opt.timelines[index] || {};
840
+
841
+ opt.timelines[index].layers = opt.timelines[index].layers || new Object();
842
+
843
+
844
+ // COLLECT LAYERS
845
+ slide.find('.tp-caption').each(function(i) {
846
+ addTimeLineWithLabel(jQuery(this),opt,opt.timelines[index].layers,index);
847
+ });
848
+
849
+ });
850
+
851
+
852
+
853
+
854
+ },
855
+
856
+
857
+
858
+ /***************************************
859
+ - BUILD CAPTION FULL TIMELINES -
860
+ ***************************************/
861
+ buildFullTimeLine : function(obj) {
862
+
863
+ //if (obj.recall) return;
864
+
865
+ var _nc = obj.caption,
866
+ _ = _nc.data(),
867
+ opt = obj.opt,
868
+ $svg = {},
869
+ _nc_tl_obj,
870
+ _nc_timeline,
871
+ $hover = newHoverAnimObject(),
872
+ timelineprog = 0;
873
+
874
+ _nc_tl_obj = opt.timelines[_._slideid]["layers"][_._id];
875
+
876
+
877
+ if (_nc_tl_obj.generated && obj.regenerate!==true) return;
878
+ _nc_timeline = _nc_tl_obj.timeline;
879
+
880
+ _nc_tl_obj.generated = true;
881
+
882
+ if (_.current_timeline!==undefined && obj.regenerate!==true) {
883
+ _.current_timeline_pause = _.current_timeline.paused();
884
+ _.current_timeline_time = _.current_timeline.time();
885
+ _.current_is_nc_timeline = _nc_timeline === _.current_timeline;
886
+ _.static_layer_timeline_time = _.current_timeline_time;
887
+ } else {
888
+ _.static_layer_timeline_time = _.current_timeline_time;
889
+ _.current_timeline_time = 0;
890
+ if (_.current_timeline) _.current_timeline.clear();
891
+ }
892
+
893
+
894
+
895
+ _nc_timeline.clear();
896
+
897
+
898
+ // PRESET SVG STYLE
899
+ $svg.svg = _.svg_src!=undefined ? _nc.find('svg') : false;
900
+ if ($svg.svg) {
901
+ _.idlesvg = setSVGAnimObject(_.svg_idle,newSVGHoverAnimObject());
902
+ punchgs.TweenLite.set($svg.svg,_.idlesvg.anim);
903
+ }
904
+
905
+
906
+ // HOVER ANIMATION
907
+ if (_.hoverframeindex!==-1 && _.hoverframeindex!==undefined) {
908
+
909
+ if (!_nc.hasClass("rs-hover-ready")) {
910
+
911
+ _nc.addClass("rs-hover-ready");
912
+ _.hovertimelines = {};
913
+
914
+ _.hoveranim = getAnimDatas($hover,_.frames[_.hoverframeindex].to);
915
+ _.hoveranim = convertHoverStyle(_.hoveranim,_.frames[_.hoverframeindex].style);
916
+
917
+ if ($svg.svg) {
918
+
919
+ var $svghover = setSVGAnimObject(_.svg_hover,newSVGHoverAnimObject());
920
+ if (_.hoveranim.anim.color!=undefined) {
921
+ $svghover.anim.fill = _.hoveranim.anim.color;
922
+
923
+ _.idlesvg.anim.css.fill = $svg.svg.css("fill");
924
+
925
+ }
926
+
927
+
928
+
929
+ _.hoversvg = $svghover;
930
+ }
931
+
932
+ _nc.hover(function(e) {
933
+
934
+ var obj = {caption:jQuery(e.currentTarget), opt:opt, firstframe : "frame_0", lastframe:"frame_999"},
935
+ tl = getTLInfos(obj),
936
+ nc = obj.caption,
937
+ _ = nc.data(),
938
+ frame = _.frames[_.hoverframeindex],
939
+ animended = true;
940
+
941
+ _.forcehover = frame.force;
942
+
943
+ if (animended) {
944
+ _.hovertimelines.item = punchgs.TweenLite.to(nc,frame.speed/1000,_.hoveranim.anim);
945
+ if (_.hoverzIndex || (_.hoveranim.anim && _.hoveranim.anim.zIndex)) {
946
+ _.basiczindex = _.basiczindex===undefined ? _.cssobj.zIndex : _.basiczindex;
947
+ _.hoverzIndex = _.hoverzIndex===undefined ? _.hoveranim.anim.zIndex : _.hoverzIndex;
948
+ _.inhoverinanimation = true;
949
+ if (frame.speed===0) _.inhoverinanimation= false;
950
+
951
+ _.hovertimelines.pwhoveranim = punchgs.TweenLite.to(_._pw,frame.speed/1000,{overwrite:"auto",zIndex:_.hoverzIndex});
952
+ _.hovertimelines.pwhoveranim.eventCallback("onComplete",function(_) {
953
+ _.inhoverinanimation=false;;
954
+ },[_])
955
+ }
956
+ if ($svg.svg)
957
+ _.hovertimelines.svghoveranim = punchgs.TweenLite.to([$svg.svg, $svg.svg.find('path')],frame.speed/1000,_.hoversvg.anim);
958
+ _.hoveredstatus = true;
959
+ }
960
+ },
961
+ function(e) {
962
+
963
+ var obj = {caption:jQuery(e.currentTarget), opt:opt, firstframe : "frame_0", lastframe:"frame_999"},
964
+ tl = getTLInfos(obj),
965
+ nc = obj.caption,
966
+ _ = nc.data(),
967
+ frame = _.frames[_.hoverframeindex],
968
+ animended = true;
969
+
970
+
971
+ if (animended) {
972
+ _.hoveredstatus = false;
973
+ _.inhoveroutanimation = true;
974
+ _.hovertimelines.item.pause();
975
+ _.hovertimelines.item = punchgs.TweenLite.to(nc,frame.speed/1000,jQuery.extend(true,{},_._gsTransformTo));
976
+
977
+
978
+ if (frame.speed==0) _.inhoveroutanimation= false;
979
+ _.hovertimelines.item.eventCallback("onComplete",function(_) {
980
+
981
+ _.inhoveroutanimation=false;;
982
+ },[_])
983
+ if (_.hovertimelines.pwhoveranim!==undefined) _.hovertimelines.pwhoveranim = punchgs.TweenLite.to(_._pw,frame.speed/1000,{overwrite:"auto",zIndex:_.basiczindex});
984
+ if ($svg.svg) punchgs.TweenLite.to([$svg.svg, $svg.svg.find('path')],frame.speed/1000,_.idlesvg.anim);
985
+ }
986
+ });
987
+ }
988
+ } // END IF HOVER ANIMATION
989
+
990
+
991
+ // LOOP TROUGH THE FRAMES AND CREATE FRAME TWEENS AND TL'S ON THE MAIN TIMELINE
992
+ for (var frame_index=0; frame_index<_.frames.length;frame_index++) {
993
+
994
+ if (frame_index !== _.hoverframeindex) {
995
+
996
+ // Create a new Timeline for each Frame
997
+ var frame_name = frame_index === _.inframeindex ? "frame_0" : frame_index===_.outframeindex || _.frames[frame_index].frame==="frame_999" ? "frame_999" : "frame_"+frame_index;
998
+ _.frames[frame_index].framename = frame_name;
999
+
1000
+ _nc_tl_obj[frame_name] = {};
1001
+ _nc_tl_obj[frame_name].timeline = new punchgs.TimelineLite({align:"normal"});
1002
+
1003
+
1004
+ var $start = _.frames[frame_index].delay,
1005
+ $start_status = _.triggered_startstatus,
1006
+ mdelay = $start !== undefined ? jQuery.inArray($start,["slideenter","bytrigger","wait"])>=0 ? $start : parseInt($start,0)/1000 : "wait";
1007
+
1008
+
1009
+ // ADD STARTLABEL FOR STATIC LAYERS
1010
+ if (_nc_tl_obj.firstslide!==undefined && frame_name==="frame_0") {
1011
+ _nc_timeline.addLabel("slide_"+_nc_tl_obj.firstslide+"_pause",0);
1012
+ _nc_timeline.addPause("slide_"+_nc_tl_obj.firstslide+"_pause");
1013
+ _nc_timeline.addLabel("slide_"+_nc_tl_obj.firstslide,"+=0.005");
1014
+ }
1015
+
1016
+ // ADD ENDSLIDE LABEL FOR STATIC LAYERS
1017
+ if (_nc_tl_obj.lastslide!==undefined && frame_name==="frame_999") {
1018
+ _nc_timeline.addLabel("slide_"+_nc_tl_obj.lastslide+"_pause","+=0.01");
1019
+ _nc_timeline.addPause("slide_"+_nc_tl_obj.lastslide+"_pause");
1020
+ _nc_timeline.addLabel("slide_"+_nc_tl_obj.lastslide,"+=0.005");
1021
+ }
1022
+
1023
+ if (!jQuery.isNumeric(mdelay)) {
1024
+ _nc_timeline.addLabel("pause_"+frame_index,"+=0.01");
1025
+ _nc_timeline.addPause("pause_"+frame_index);
1026
+ _nc_timeline.addLabel(frame_name,"+=0.01");
1027
+ } else {
1028
+ _nc_timeline.addLabel(frame_name,"+="+mdelay);
1029
+ }
1030
+
1031
+
1032
+ _nc_timeline = _R.createFrameOnTimeline({caption:obj.caption, timeline : _nc_timeline, label:frame_name, frameindex : frame_index, opt:opt });
1033
+
1034
+
1035
+
1036
+ } //
1037
+ } // END OF LOOP THROUGH FRAMES AND CREATING NEW TWEENS
1038
+ //_nc_timeline.time(timelineprog);
1039
+
1040
+ if (!obj.regenerate) {
1041
+ if (_.current_is_nc_timeline)
1042
+ _.current_timeline = _nc_timeline;
1043
+ if (_.current_timeline_pause)
1044
+ _nc_timeline.pause(_.current_timeline_time);
1045
+ else
1046
+ _nc_timeline.time(_.current_timeline_time);
1047
+ }
1048
+
1049
+ return;
1050
+ },
1051
+
1052
+ /////////////////////////////////////
1053
+ // BUILD A FRAME ON THE TIMELINE //
1054
+ /////////////////////////////////////
1055
+ createFrameOnTimeline : function(obj) {
1056
+ var _nc = obj.caption,
1057
+ _ = _nc.data(),
1058
+ label = obj.label,
1059
+ timeline = obj.timeline,
1060
+ frame_index = obj.frameindex,
1061
+ opt = obj.opt,
1062
+ animobject = _nc,
1063
+ tweens = {},
1064
+ _nc_tl_obj = opt.timelines[_._slideid]["layers"][_._id],
1065
+ verylastframe = _.frames.length-1,
1066
+ $split = _.frames[frame_index].split,
1067
+ $splitdir = _.frames[frame_index].split_direction,
1068
+ $sfx = _.frames[frame_index].sfx_effect,
1069
+ $splitnow = false;
1070
+
1071
+ $splitdir = $splitdir === undefined ? "forward" : $splitdir;
1072
+
1073
+ if (_.hoverframeindex!==-1 && _.hoverframeindex==verylastframe) verylastframe=verylastframe-1;
1074
+
1075
+ tweens.content = new punchgs.TimelineLite({align:"normal"});
1076
+ tweens.mask = new punchgs.TimelineLite({align:"normal"});
1077
+
1078
+
1079
+ if (timeline.vars.id===undefined)
1080
+ timeline.vars.id=Math.round(Math.random()*100000);
1081
+ if (_._nctype==="column") {
1082
+ timeline.add(punchgs.TweenLite.set(_._cbgc_man,{visibility:"visible"}),label);
1083
+ timeline.add(punchgs.TweenLite.set(_._cbgc_auto,{visibility:"hidden"}),label);
1084
+
1085
+
1086
+ }
1087
+
1088
+ if (_.splittext && frame_index===0) {
1089
+ if (_.mySplitText !== undefined) _.mySplitText.revert();
1090
+ var splittarget = _nc.find('a').length>0 ? _nc.find('a') : _nc;
1091
+ _.mySplitText = new punchgs.SplitText(splittarget,{type:"chars,words,lines",charsClass:"tp-splitted tp-charsplit",wordsClass:"tp-splitted tp-wordsplit",linesClass:"tp-splitted tp-linesplit"});
1092
+
1093
+ _nc.addClass("splitted");
1094
+ }
1095
+
1096
+ if ( _.mySplitText !==undefined && $split && $split.match(/chars|words|lines/g)) {
1097
+ animobject = _.mySplitText[$split];
1098
+ $splitnow = true;
1099
+ }
1100
+
1101
+
1102
+ // ANIMATE THE FRAME
1103
+
1104
+ var $to = frame_index!==_.outframeindex ? getAnimDatas(newAnimObject(),_.frames[frame_index].to,undefined,$splitnow,animobject.length-1) : _.frames[frame_index].to !==undefined && _.frames[frame_index].to.match(/auto:auto/g)===null ? getAnimDatas(newEndAnimObject(),_.frames[frame_index].to,opt.sdir==1,$splitnow,(animobject.length-1)) : getAnimDatas(newEndAnimObject(),_.frames[_.inframeindex].from,opt.sdir==0,$splitnow,(animobject.length-1)),
1105
+ $from = _.frames[frame_index].from !==undefined ? getAnimDatas($to,_.frames[_.inframeindex].from,opt.sdir==1,$splitnow,animobject.length-1) : undefined, // ANIMATE FROM THE VERY FIRST SETTING, OR FROM PREVIOUS SETTING
1106
+ $elemdelay = _.frames[frame_index].splitdelay,
1107
+ $mask_from,$mask_to;
1108
+
1109
+ if (frame_index===0 && !obj.fromcurrentstate)
1110
+ $mask_from = getMaskDatas(_.frames[frame_index].mask);
1111
+ else
1112
+ $mask_to = getMaskDatas(_.frames[frame_index].mask);
1113
+
1114
+ $to.anim.ease = _.frames[frame_index].ease===undefined ? punchgs.Power1.easeInOut : _.frames[frame_index].ease;
1115
+
1116
+ if ($from!==undefined) {
1117
+ $from.anim.ease = _.frames[frame_index].ease===undefined ? punchgs.Power1.easeInOut : _.frames[frame_index].ease;
1118
+ $from.speed = _.frames[frame_index].speed === undefined ? $from.speed : _.frames[frame_index].speed;
1119
+ $from.anim.x = $from.anim.x * opt.bw || getBorderDirections($from.anim.x,opt,_.eow,_.eoh,_.calcy,_.calcx, "horizontal" );
1120
+ $from.anim.y = $from.anim.y * opt.bw || getBorderDirections($from.anim.y,opt,_.eow,_.eoh,_.calcy,_.calcx, "vertical" );
1121
+
1122
+ }
1123
+
1124
+ if ($to!==undefined) {
1125
+ $to.anim.ease = _.frames[frame_index].ease===undefined ? punchgs.Power1.easeInOut : _.frames[frame_index].ease;
1126
+ $to.speed = _.frames[frame_index].speed === undefined ? $to.speed : _.frames[frame_index].speed;
1127
+ $to.anim.x = $to.anim.x * opt.bw || getBorderDirections($to.anim.x,opt,_.eow,_.eoh,_.calcy,_.calcx, "horizontal" );
1128
+ $to.anim.y = $to.anim.y * opt.bw || getBorderDirections($to.anim.y,opt,_.eow,_.eoh,_.calcy,_.calcx, "vertical" );
1129
+
1130
+
1131
+ }
1132
+
1133
+ // FIX VISIBLE IFRAME BUG IN SAFARI
1134
+ if (_nc.data('iframes')) timeline.add(punchgs.TweenLite.set(_nc.find('iframe'),{autoAlpha:1}),label+"+=0.001");
1135
+
1136
+
1137
+
1138
+ // IN CASE LAST FRAME REACHED, AND ANIMATION IS SET TO AUTO (REVERSE PLAYING)
1139
+ if (frame_index===_.outframeindex) {
1140
+ if (_.frames[frame_index].to && _.frames[frame_index].to.match(/auto:auto/g)) {
1141
+ //
1142
+ }
1143
+
1144
+ $to.speed = _.frames[frame_index].speed === undefined || _.frames[frame_index].speed==="inherit" ? _.frames[_.inframeindex].speed : _.frames[frame_index].speed;
1145
+ $to.anim.ease = _.frames[frame_index].ease === undefined || _.frames[frame_index].ease==="inherit" ? _.frames[_.inframeindex].ease : _.frames[frame_index].ease;
1146
+ $to.anim.overwrite ="auto";
1147
+ }
1148
+
1149
+
1150
+ // IN CASE FIRST FRAME REACHED
1151
+ if (frame_index===0 && !obj.fromcurrentstate) {
1152
+
1153
+ if (animobject != _nc) {
1154
+ var old = jQuery.extend({},$to.anim,true);
1155
+ timeline.add(punchgs.TweenLite.set(_nc, $to.anim),label);
1156
+ $to = newAnimObject();
1157
+ $to.ease = old.ease;
1158
+ if (old.filter!==undefined) $to.anim.filter = old.filter;
1159
+ if (old["-webkit-filter"]!==undefined) $to.anim["-webkit-filter"] = old["-webkit-filter"];
1160
+ }
1161
+
1162
+
1163
+ $from.anim.visibility = "hidden";
1164
+ $from.anim.immediateRender = true;
1165
+ $to.anim.visibility = "visible";
1166
+
1167
+
1168
+ //_nc.data('speed',$from.speed);
1169
+ //_nc.data('ease',$to.anim.ease);
1170
+ } else
1171
+
1172
+ if (frame_index===0 && obj.fromcurrentstate) {
1173
+ $to.speed = $from.speed;
1174
+ }
1175
+
1176
+ if (obj.fromcurrentstate) {
1177
+ $to.anim.immediateRender = true;
1178
+ }
1179
+
1180
+ // SPECIAL EFFECT LAYER ANIMATIONS
1181
+ var $sfx_blockdelay = -1;
1182
+
1183
+
1184
+ //Boxed Mask Animation 0 or 999 Frame
1185
+ if ((frame_index===0 && !obj.fromcurrentstate && _._bmask!==undefined && $sfx!==undefined && $sfx.indexOf("block")>=0) ||
1186
+ (frame_index===_.outframeindex && !obj.fromcurrentstate && _._bmask!==undefined && $sfx!==undefined && $sfx.indexOf("block")>=0)) {
1187
+ var $sfx_speed = frame_index===0 ? ($from.speed/1000)/2 : ($to.speed/1000)/2,
1188
+ $sfx_ft = [{scaleY:1,scaleX:0,transformOrigin:"0% 50%"},{scaleY:1,scaleX:1,ease:$to.anim.ease}],
1189
+ $sfx_t = {scaleY:1,scaleX:0,transformOrigin:"100% 50%",ease:$to.anim.ease};
1190
+
1191
+ $sfx_blockdelay = $elemdelay === undefined ? $sfx_speed : $elemdelay + $sfx_speed;
1192
+
1193
+ switch ($sfx) {
1194
+ case "blocktoleft":
1195
+ case "blockfromright":
1196
+ $sfx_ft[0].transformOrigin = "100% 50%";
1197
+ $sfx_t.transformOrigin = "0% 50%";
1198
+ break;
1199
+
1200
+ case "blockfromtop":
1201
+ case "blocktobottom":
1202
+ $sfx_ft = [{scaleX:1,scaleY:0,transformOrigin:"50% 0%"},{scaleX:1,scaleY:1,ease:$to.anim.ease}];
1203
+ $sfx_t = {scaleX:1,scaleY:0,transformOrigin:"50% 100%",ease:$to.anim.ease};
1204
+ break;
1205
+
1206
+ case "blocktotop":
1207
+ case "blockfrombottom":
1208
+ $sfx_ft = [{scaleX:1,scaleY:0,transformOrigin:"50% 100%"},{scaleX:1,scaleY:1,ease:$to.anim.ease}];
1209
+ $sfx_t = {scaleX:1,scaleY:0,transformOrigin:"50% 0%",ease:$to.anim.ease};
1210
+ break;
1211
+ }
1212
+ $sfx_ft[0].background = _.frames[frame_index].sfxcolor;
1213
+
1214
+ timeline.add(tweens.mask.fromTo(_._bmask,$sfx_speed, $sfx_ft[0], $sfx_ft[1],$elemdelay),label);
1215
+ timeline.add(tweens.mask.to(_._bmask,$sfx_speed,$sfx_t,$sfx_blockdelay),label);
1216
+ }
1217
+
1218
+
1219
+
1220
+ if ($splitnow)
1221
+ var ri = getSplitTextDirs(animobject.length-1, $splitdir);
1222
+
1223
+ if (frame_index===0 && !obj.fromcurrentstate) {
1224
+ if (_._sfx_in==="block")
1225
+ timeline.add(tweens.content.staggerFromTo(animobject,0.05,{x:0,y:0,autoAlpha:0},{x:0,y:0,autoAlpha:1,delay:$sfx_blockdelay}),label);
1226
+ else {
1227
+ if ($splitnow && ri!==undefined) {
1228
+
1229
+ var cycles = {from:getCycles($from.anim), to:getCycles($to.anim)};
1230
+
1231
+ for (var si in animobject) {
1232
+ var $fanim = jQuery.extend({},$from.anim),
1233
+ $tanim = jQuery.extend({},$to.anim);
1234
+ for (var k in cycles.from) {
1235
+ $fanim[k] = parseInt(cycles.from[k].values[cycles.from[k].index],0);
1236
+ cycles.from[k].index = cycles.from[k].index < cycles.from[k].len ? cycles.from[k].index+1 : 0;
1237
+ }
1238
+ $tanim.ease = $fanim.ease;
1239
+ if (_.frames[frame_index].color!==undefined) {
1240
+ $fanim.color = _.frames[frame_index].color;
1241
+ $tanim.color = _.cssobj.styleProps.color;
1242
+ }
1243
+
1244
+ if (_.frames[frame_index].bgcolor!==undefined) {
1245
+ $fanim.backgroundColor = _.frames[frame_index].bgcolor;
1246
+ $tanim.backgroundColor = _.cssobj.styleProps["background-color"];
1247
+
1248
+ }
1249
+ timeline.add(tweens.content.fromTo(animobject[ri[si]],$from.speed/1000,$fanim,$tanim,$elemdelay*si),label);
1250
+ }
1251
+ } else {
1252
+ if (_.frames[frame_index].color!==undefined) {
1253
+ $from.anim.color = _.frames[frame_index].color;
1254
+ $to.anim.color = _.cssobj.styleProps.color;
1255
+ }
1256
+
1257
+ if (_.frames[frame_index].bgcolor!==undefined) {
1258
+ $from.anim.backgroundColor = _.frames[frame_index].bgcolor;
1259
+ $to.anim.backgroundColor = _.cssobj.styleProps["background-color"];
1260
+
1261
+ }
1262
+ timeline.add(tweens.content.staggerFromTo(animobject,$from.speed/1000,$from.anim,$to.anim,$elemdelay),label);
1263
+ }
1264
+
1265
+
1266
+ }
1267
+ } else {
1268
+ if (_._sfx_out==="block" && frame_index===_.outframeindex) {
1269
+ timeline.add(tweens.content.staggerTo(animobject,0.001,{autoAlpha:0,delay:$sfx_blockdelay}),label);
1270
+ timeline.add(tweens.content.staggerTo(animobject,((($to.speed/1000)/2)-0.001),{x:0,delay:$sfx_blockdelay}),label+"+=0.001");
1271
+ } else
1272
+ if ($splitnow && ri!==undefined) {
1273
+
1274
+ var cycles = {to:getCycles($to.anim)};
1275
+
1276
+ for (var si in animobject) {
1277
+ var $tanim = jQuery.extend({},$to.anim);
1278
+ for (var k in cycles.to) {
1279
+ $tanim[k] = parseInt(cycles.to[k].values[cycles.to[k].index],0);
1280
+ cycles.to[k].index = cycles.to[k].index < cycles.to[k].len ? cycles.to[k].index+1 : 0;
1281
+ }
1282
+ if (_.frames[frame_index].color!==undefined)
1283
+ $tanim.color = _.frames[frame_index].color;
1284
+
1285
+ if (_.frames[frame_index].bgcolor!==undefined)
1286
+ $tanim.backgroundColor = _.frames[frame_index].bgcolor;
1287
+
1288
+ timeline.add(tweens.content.to(animobject[ri[si]],$to.speed/1000,$tanim,$elemdelay*si),label);
1289
+ }
1290
+ } else {
1291
+ if (_.frames[frame_index].color!==undefined)
1292
+ $to.anim.color = _.frames[frame_index].color;
1293
+
1294
+ if (_.frames[frame_index].bgcolor!==undefined)
1295
+ $to.anim.backgroundColor = _.frames[frame_index].bgcolor;
1296
+
1297
+ timeline.add(tweens.content.staggerTo(animobject,$to.speed/1000,$to.anim,$elemdelay),label);
1298
+ }
1299
+ }
1300
+
1301
+
1302
+ if ($mask_to!==undefined && $mask_to!==false && (frame_index!==0 || !obj.ignorefirstframe)) {
1303
+ $mask_to.anim.ease = $mask_to.anim.ease === undefined || $mask_to.anim.ease==="inherit" ? _.frames[0].ease : $mask_to.anim.ease;
1304
+ $mask_to.anim.overflow = "hidden";
1305
+ $mask_to.anim.x = $mask_to.anim.x * opt.bw || getBorderDirections($mask_to.anim.x,opt,_.eow,_.eoh,_.calcy,_.calcx,"horizontal");
1306
+ $mask_to.anim.y = $mask_to.anim.y * opt.bw || getBorderDirections($mask_to.anim.y,opt,_.eow,_.eoh,_.calcy,_.calcx,"vertical");
1307
+ }
1308
+
1309
+ if ((frame_index===0 && $mask_from && $mask_from!==false && !obj.fromcurrentstate) || (frame_index===0 && obj.ignorefirstframe)) {
1310
+ $mask_to = new Object();
1311
+ $mask_to.anim = new Object();
1312
+ $mask_to.anim.overwrite = "auto";
1313
+ $mask_to.anim.ease = $to.anim.ease;
1314
+ $mask_to.anim.x = $mask_to.anim.y = 0;
1315
+ if ($mask_from && $mask_from!==false) {
1316
+ $mask_from.anim.x = $mask_from.anim.x * opt.bw || getBorderDirections($mask_from.anim.x,opt,_.eow,_.eoh,_.calcy,_.calcx,"horizontal");
1317
+ $mask_from.anim.y = $mask_from.anim.y * opt.bw || getBorderDirections($mask_from.anim.y,opt,_.eow,_.eoh,_.calcy,_.calcx,"vertical");
1318
+ $mask_from.anim.overflow ="hidden";
1319
+ }
1320
+ } else
1321
+ if (frame_index===0)
1322
+ timeline.add(tweens.mask.set(_._mw,{overflow:"visible"}),label);
1323
+
1324
+
1325
+ if ($mask_from!==undefined && $mask_to!==undefined && $mask_from!==false && $mask_to!==false)
1326
+ timeline.add(tweens.mask.fromTo(_._mw,$from.speed/1000,$mask_from.anim,$mask_to.anim,$elemdelay),label);
1327
+ else
1328
+ if ($mask_to!==undefined && $mask_to!==false)
1329
+ timeline.add(tweens.mask.to(_._mw,$to.speed/1000,$mask_to.anim,$elemdelay),label);
1330
+
1331
+ timeline.addLabel(label+"_end");
1332
+
1333
+ // Reset Hover Effect when Last Frame (Out Animation) ordered
1334
+ if (_._gsTransformTo && frame_index===verylastframe && _.hoveredstatus)
1335
+ _.hovertimelines.item = punchgs.TweenLite.to(_nc,0,_._gsTransformTo);
1336
+
1337
+ _._gsTransformTo = false;
1338
+
1339
+
1340
+
1341
+ // ON START
1342
+ tweens.content.eventCallback("onStart",tweenOnStart,[frame_index,_nc_tl_obj,_._pw,_,timeline,$to.anim,_nc,obj.updateStaticTimeline,opt]);
1343
+
1344
+
1345
+
1346
+ // ON UPDATE
1347
+ tweens.content.eventCallback("onUpdate",tweenOnUpdate,[label,_._id,_._pw,_,timeline,frame_index,jQuery.extend(true,{},$to.anim),obj.updateStaticTimeline,_nc,opt]);
1348
+
1349
+
1350
+
1351
+ // ON COMPLETE
1352
+ tweens.content.eventCallback("onComplete",tweenOnComplete,[frame_index,_.frames.length,verylastframe,_._pw,_,timeline,obj.updateStaticTimeline,_nc,opt]);
1353
+
1354
+
1355
+ return timeline;
1356
+ },
1357
+
1358
+
1359
+
1360
+
1361
+
1362
+ //////////////////////////////
1363
+ // MOVE OUT THE CAPTIONS //
1364
+ ////////////////////////////
1365
+ endMoveCaption : function(obj) {
1366
+ obj.firstframe="frame_0";
1367
+ obj.lastframe="frame_999";
1368
+
1369
+ var nc = getTLInfos(obj),
1370
+ _ = obj.caption.data();
1371
+
1372
+ if (obj.frame!==undefined)
1373
+ nc.timeline.play(obj.frame);
1374
+ else
1375
+ if (!nc.static || (obj.currentslide>=nc.removeonslide) || (obj.currentslide<nc.showonslide)) {
1376
+ nc.outnow = new punchgs.TimelineLite;
1377
+ nc.timeline.pause();
1378
+ if (_.visibleelement===true)
1379
+ _R.createFrameOnTimeline({caption:obj.caption, timeline : nc.outnow, label:"outnow", frameindex : obj.caption.data("outframeindex"), opt:obj.opt, fromcurrentstate:true}).play();
1380
+ }
1381
+
1382
+ if (obj.checkchildrens)
1383
+ if (nc.timeline_obj && nc.timeline_obj.dchildren && nc.timeline_obj.dchildren!=="none" && nc.timeline_obj.dchildren.length>0)
1384
+ for (var q = 0; q<nc.timeline_obj.dchildren.length;q++) {
1385
+ _R.endMoveCaption({caption:jQuery(nc.timeline_obj.dchildren[q]), opt:obj.opt});
1386
+ }
1387
+ },
1388
+
1389
+ //////////////////////////////////
1390
+ // MOVE CAPTIONS TO xx FRAME //
1391
+ /////////////////////////////////
1392
+ playAnimationFrame : function(obj) {
1393
+ obj.firstframe = obj.triggerframein;
1394
+ obj.lastframe = obj.triggerframeout;
1395
+
1396
+
1397
+ var nc = getTLInfos(obj),
1398
+ _ = obj.caption.data(),
1399
+ frameindex,
1400
+ i=0;
1401
+
1402
+
1403
+
1404
+ for (var k in _.frames) {
1405
+ if (_.frames[k].framename === obj.frame) frameindex = i;
1406
+ i++;
1407
+ }
1408
+
1409
+
1410
+
1411
+ if (_.triggeredtimeline!==undefined) _.triggeredtimeline.pause();
1412
+ _.triggeredtimeline = new punchgs.TimelineLite;
1413
+ nc.timeline.pause();
1414
+
1415
+ var fcs = _.visibleelement===true ? true : false;
1416
+
1417
+
1418
+ _.triggeredtimeline = _R.createFrameOnTimeline({caption:obj.caption, timeline : _.triggeredtimeline, label:"triggered", frameindex : frameindex, updateStaticTimeline:true, opt:obj.opt, ignorefirstframe:true, fromcurrentstate:fcs}).play();
1419
+
1420
+
1421
+
1422
+ //nc.timeline.play(obj.frame);
1423
+
1424
+ },
1425
+
1426
+ //////////////////////////
1427
+ // REMOVE THE CAPTIONS //
1428
+ /////////////////////////
1429
+ removeTheCaptions : function(actli,opt) {
1430
+
1431
+ if (_R.compare_version(extension).check==="stop") return false;
1432
+ var removetime = 0,
1433
+ index = actli.data('index'),
1434
+ allcaptions = new Array;
1435
+
1436
+ // COLLECT ALL CAPTIONS
1437
+ if (opt.layers[index])
1438
+ jQuery.each(opt.layers[index], function(i,a) { allcaptions.push(a); });
1439
+
1440
+ /*if (opt.layers["static"])
1441
+ jQuery.each(opt.layers["static"], function(i,a) { allcaptions.push(a); });*/
1442
+
1443
+ var slideindex = _R.currentSlideIndex(opt);
1444
+
1445
+
1446
+ // GO THROUGH ALL CAPTIONS, AND MANAGE THEM
1447
+ if (allcaptions)
1448
+ jQuery.each(allcaptions,function(i) {
1449
+ var _nc=jQuery(this);
1450
+ if (opt.sliderType==="carousel" && opt.carousel.showLayersAllTime==="on") {
1451
+ clearTimeout(_nc.data('videoplaywait'));
1452
+ if (_R.stopVideo) _R.stopVideo(_nc,opt);
1453
+ if (_R.removeMediaFromList) _R.removeMediaFromList(_nc,opt);
1454
+ opt.lastplayedvideos = [];
1455
+ } else {
1456
+ killCaptionLoops(_nc);
1457
+ clearTimeout(_nc.data('videoplaywait'));
1458
+ _R.endMoveCaption({caption:_nc,opt:opt, currentslide:slideindex});
1459
+ if (_R.removeMediaFromList) _R.removeMediaFromList(_nc,opt);
1460
+ opt.lastplayedvideos = [];
1461
+ }
1462
+
1463
+ });
1464
+ }
1465
+ });
1466
+
1467
+
1468
+
1469
+
1470
+
1471
+ /**********************************************************************************************
1472
+ - HELPER FUNCTIONS FOR LAYER TRANSFORMS -
1473
+ **********************************************************************************************/
1474
+
1475
+
1476
+ var tweenOnStart = function(frame_index,ncobj,pw,_,tl,toanim,_nc,ust,opt){
1477
+
1478
+ var data={};
1479
+ data.layer = _nc;
1480
+ data.eventtype = frame_index===0 ? "enterstage" : frame_index===_.outframeindex ? "leavestage" : "framestarted";
1481
+ data.layertype = _nc.data('layertype');
1482
+ _.active = true;
1483
+ //_nc.data('active',true);
1484
+
1485
+ //_.idleanimadded = false;
1486
+ data.frame_index = frame_index;
1487
+ data.layersettings = _nc.data();
1488
+ opt.c.trigger("revolution.layeraction",[data]);
1489
+ if (_.loopanimation=="on") callCaptionLoops(_._lw,opt.bw);
1490
+
1491
+ if (data.eventtype==="enterstage") {
1492
+ _.animdirection="in";
1493
+ _.visibleelement=true;
1494
+ _R.toggleState(_.layertoggledby);
1495
+ }
1496
+ if (ncobj.dchildren!=="none" && ncobj.dchildren!==undefined && ncobj.dchildren.length>0) {
1497
+ if (frame_index===0)
1498
+ for (var q=0;q<ncobj.dchildren.length;q++) {
1499
+ jQuery(ncobj.dchildren[q]).data('timeline').play(0);
1500
+ }
1501
+ else
1502
+ if (frame_index===_.outframeindex)
1503
+ for (var q=0;q<ncobj.dchildren.length;q++) {
1504
+ _R.endMoveCaption({caption:jQuery(ncobj.dchildren[q]), opt:opt, checkchildrens:true});
1505
+ }
1506
+ }
1507
+ punchgs.TweenLite.set(pw,{visibility:"visible"});
1508
+ _.current_frame = frame_index;
1509
+ _.current_timeline = tl;
1510
+ _.current_timeline_time = tl.time();
1511
+ if (ust) _.static_layer_timeline_time = _.current_timeline_time;
1512
+ _.last_frame_started = frame_index;
1513
+
1514
+
1515
+ }
1516
+
1517
+ var tweenOnUpdate = function(label,id,pw,_,tl,frame_index,toanim,ust,_nc,opt) {
1518
+ if (_._nctype==="column") setColumnBgDimension(_nc,opt);
1519
+ punchgs.TweenLite.set(pw,{visibility:"visible"});
1520
+ _.current_frame = frame_index;
1521
+ _.current_timeline = tl;
1522
+ _.current_timeline_time = tl.time();
1523
+ if (ust) _.static_layer_timeline_time = _.current_timeline_time;
1524
+
1525
+ if (_.hoveranim !== undefined && _._gsTransformTo===false) {
1526
+ _._gsTransformTo = toanim;
1527
+ if (_._gsTransformTo && _._gsTransformTo.startAt) delete _._gsTransformTo.startAt;
1528
+
1529
+ if (_.cssobj.styleProps.css===undefined)
1530
+ _._gsTransformTo = jQuery.extend(true,{},_.cssobj.styleProps,_._gsTransformTo);
1531
+ else
1532
+ _._gsTransformTo = jQuery.extend(true,{},_.cssobj.styleProps.css,_._gsTransformTo);
1533
+ }
1534
+
1535
+ _.visibleelement=true;
1536
+
1537
+ }
1538
+
1539
+ var tweenOnComplete = function(frame_index,frame_max,verylastframe,pw,_,tl,ust,_nc,opt) {
1540
+ var data={};
1541
+ data.layer = _nc;
1542
+
1543
+ data.eventtype = frame_index===0 ? "enteredstage" : frame_index===frame_max-1 || frame_index===verylastframe ? "leftstage" : "frameended";
1544
+ data.layertype = _nc.data('layertype');
1545
+ data.layersettings = _nc.data();
1546
+
1547
+ opt.c.trigger("revolution.layeraction",[data]);
1548
+ if (data.eventtype!=="leftstage") _R.animcompleted(_nc,opt);
1549
+ if (data.eventtype==="leftstage")
1550
+ if (_R.stopVideo) _R.stopVideo(_nc,opt);
1551
+
1552
+ if (_._nctype==="column") {
1553
+ punchgs.TweenLite.to(_._cbgc_man,0.01,{visibility:"hidden"});
1554
+ punchgs.TweenLite.to(_._cbgc_auto,0.01,{visibility:"visible"});
1555
+ }
1556
+ if (data.eventtype === "leftstage") {
1557
+ _.active = false;
1558
+ punchgs.TweenLite.set(pw,{visibility:"hidden",overwrite:"auto"});
1559
+ _.animdirection="out";
1560
+ _.visibleelement=false;
1561
+ _R.unToggleState(_.layertoggledby);
1562
+ //RESET VIDEO AFTER REMOVING LAYER
1563
+ if (_._nctype==="video" && _R.resetVideo) setTimeout(function() {
1564
+ _R.resetVideo(_nc,opt);
1565
+ },100);
1566
+ }
1567
+ _.current_frame = frame_index;
1568
+ _.current_timeline = tl;
1569
+ _.current_timeline_time = tl.time();
1570
+ if (ust) _.static_layer_timeline_time = _.current_timeline_time;
1571
+
1572
+
1573
+ }
1574
+
1575
+ //////////////////////////////////////////////
1576
+ // - GET TIMELINE INFOS FROM CAPTION - //
1577
+ /////////////////////////////////////////////
1578
+ var getTLInfos = function(obj) {
1579
+ var _ = {};
1580
+
1581
+ obj.firstframe=obj.firstframe===undefined ? "frame_0" : obj.firstframe;
1582
+ obj.lastframe=obj.lastframe===undefined ? "frame_999" : obj.lastframe;
1583
+
1584
+ _.id = obj.caption.data('id') || obj.caption.attr('id');
1585
+ _.slideid = obj.caption.data('slideid') || obj.caption.closest('.tp-revslider-slidesli').data('index');
1586
+ _.timeline_obj = obj.opt.timelines[_.slideid]["layers"][_.id];
1587
+ _.timeline = _.timeline_obj.timeline;
1588
+ _.ffs = _.timeline.getLabelTime(obj.firstframe);
1589
+ _.ffe = _.timeline.getLabelTime(obj.firstframe+"_end");
1590
+ _.lfs = _.timeline.getLabelTime(obj.lastframe);
1591
+ _.lfe = _.timeline.getLabelTime(obj.lastframe+"_end");
1592
+ _.ct = _.timeline.time();
1593
+ _.static = _.timeline_obj.firstslide!=undefined || _.timeline_obj.lastslide!=undefined;
1594
+ if (_.static) {
1595
+ _.showonslide = _.timeline_obj.firstslide;
1596
+ _.removeonslide = _.timeline_obj.lastslide;
1597
+ }
1598
+
1599
+ return _;
1600
+ }
1601
+
1602
+
1603
+
1604
+ //////////////////////////////////////////////
1605
+ // - GET SPLITTEXT DIRECTION ARRAY - //
1606
+ /////////////////////////////////////////////
1607
+
1608
+ var shuffleArray = function(array) {
1609
+ var currentIndex = array.length, temporaryValue, randomIndex;
1610
+
1611
+ // While there remain elements to shuffle...
1612
+ while (0 !== currentIndex) {
1613
+
1614
+ // Pick a remaining element...
1615
+ randomIndex = Math.floor(Math.random() * currentIndex);
1616
+ currentIndex -= 1;
1617
+
1618
+ // And swap it with the current element.
1619
+ temporaryValue = array[currentIndex];
1620
+ array[currentIndex] = array[randomIndex];
1621
+ array[randomIndex] = temporaryValue;
1622
+ }
1623
+ return array;
1624
+ }
1625
+
1626
+ var getSplitTextDirs = function(alen,d) {
1627
+ var ri = new Array();
1628
+
1629
+ switch (d) {
1630
+ case "forward":
1631
+ case "random":
1632
+ for (var si=0;si<=alen;si++) { ri.push(si);}
1633
+ if (d==="random") ri = shuffleArray(ri);
1634
+ break;
1635
+ case "backward":
1636
+ for (var si=0;si<=alen;si++) { ri.push(alen-si); }
1637
+ break;
1638
+ case "middletoedge":
1639
+ var cc = Math.ceil(alen/2),
1640
+ mm = cc-1,
1641
+ pp = cc+1;
1642
+ ri.push(cc);
1643
+ for (var si=0;si<cc;si++) {
1644
+ if (mm>=0) ri.push(mm);
1645
+ if (pp<=alen) ri.push(pp);
1646
+ mm--;
1647
+ pp++;
1648
+ }
1649
+ break;
1650
+ case "edgetomiddle":
1651
+ var mm = alen,
1652
+ pp = 0;
1653
+ for (var si=0;si<=Math.floor(alen/2);si++) {
1654
+ ri.push(mm);
1655
+ if (pp<mm) ri.push(pp);
1656
+ mm--;
1657
+ pp++;
1658
+ }
1659
+ break;
1660
+ }
1661
+
1662
+ return ri;
1663
+ }
1664
+
1665
+
1666
+ //////////////////////////////////////////////
1667
+ // - GET SPLITTEXT CYCLES ANIMATION - //
1668
+ /////////////////////////////////////////////
1669
+ var getCycles = function(anim) {
1670
+ var _ = {};
1671
+ for (var a in anim) {
1672
+ if (typeof anim[a] === "string" && anim[a].indexOf("|")>=0) {
1673
+ if (_[a]===undefined) _[a] = {index:0};
1674
+ _[a].values = ((anim[a].replace("[","")).replace("]","")).split("|");
1675
+ _[a].len = _[a].values.length-1;
1676
+ }
1677
+ }
1678
+ return _;
1679
+ }
1680
+
1681
+
1682
+ /////////////////////////////////////
1683
+ // - CREATE ANIMATION OBJECT - //
1684
+ /////////////////////////////////////
1685
+ var newAnimObject = function(a) {
1686
+ a = a===undefined ? new Object() : a;
1687
+ a.anim = a.anim===undefined ? new Object() : a.anim;
1688
+ a.anim.x = a.anim.x===undefined ? 0 : a.anim.x;
1689
+ a.anim.y = a.anim.y===undefined ? 0 : a.anim.y;
1690
+ a.anim.z = a.anim.z===undefined ? 0 : a.anim.z;
1691
+ a.anim.rotationX = a.anim.rotationX===undefined ? 0 : a.anim.rotationX;
1692
+ a.anim.rotationY = a.anim.rotationY===undefined ? 0 : a.anim.rotationY;
1693
+ a.anim.rotationZ = a.anim.rotationZ===undefined ? 0 : a.anim.rotationZ;
1694
+ a.anim.scaleX = a.anim.scaleX===undefined ? 1 : a.anim.scaleX;
1695
+ a.anim.scaleY = a.anim.scaleY===undefined ? 1 : a.anim.scaleY;
1696
+ a.anim.skewX = a.anim.skewX===undefined ? 0 : a.anim.skewX;
1697
+ a.anim.skewY = a.anim.skewY===undefined ? 0 : a.anim.skewY;
1698
+ a.anim.opacity = a.anim.opacity===undefined ? 1 : a.anim.opacity;
1699
+ a.anim.transformOrigin = a.anim.transformOrigin===undefined ? "50% 50%" : a.anim.transformOrigin;
1700
+ a.anim.transformPerspective = a.anim.transformPerspective===undefined ? 600 : a.anim.transformPerspective;
1701
+ a.anim.rotation = a.anim.rotation===undefined ? 0 : a.anim.rotation;
1702
+ //a.anim.ease = a.anim.ease===undefined ? punchgs.Power3.easeOut : a.anim.ease;
1703
+ a.anim.force3D = a.anim.force3D===undefined ? "auto" : a.anim.force3D;
1704
+ a.anim.autoAlpha = a.anim.autoAlpha===undefined ? 1 : a.anim.autoAlpha;
1705
+ a.anim.visibility = a.anim.visibility===undefined ? "visible" : a.anim.visibility;
1706
+ a.anim.overwrite = a.anim.overwrite===undefined ? "auto" : a.anim.overwrite;
1707
+ a.speed = a.speed===undefined ? 0.3 : a.speed;
1708
+ a.filter = a.filter===undefined ? "blur(0px) grayscale(0%) brightness(100%)" : a.filter;
1709
+ a["-webkit-filter"] = a["-webkit-filter"]===undefined ? "blur(0px) grayscale(0%) brightness(100%)" : a["-webkit-filter"];
1710
+
1711
+
1712
+ return a;
1713
+ }
1714
+
1715
+ var newSVGHoverAnimObject = function() {
1716
+ var a = new Object();
1717
+ a.anim = new Object();
1718
+
1719
+ a.anim.stroke="none";
1720
+ a.anim.strokeWidth=0;
1721
+ a.anim.strokeDasharray="none";
1722
+ a.anim.strokeDashoffset="0";
1723
+ return a;
1724
+ }
1725
+
1726
+ var setSVGAnimObject = function(data,a) {
1727
+ var customarray = data.split(';');
1728
+ if (customarray)
1729
+ jQuery.each(customarray,function(index,pa) {
1730
+ var p = pa.split(":")
1731
+ var w = p[0],
1732
+ v = p[1];
1733
+
1734
+ if (w=="sc") a.anim.stroke=v;
1735
+ if (w=="sw") a.anim.strokeWidth=v;
1736
+ if (w=="sda") a.anim.strokeDasharray=v;
1737
+ if (w=="sdo") a.anim.strokeDashoffset=v;
1738
+ });
1739
+
1740
+ return a;
1741
+ }
1742
+
1743
+
1744
+
1745
+ var newEndAnimObject = function() {
1746
+ var a = new Object();
1747
+ a.anim = new Object();
1748
+ a.anim.x=0;
1749
+ a.anim.y=0;
1750
+ a.anim.z=0;
1751
+ return a;
1752
+ }
1753
+
1754
+ var newHoverAnimObject = function() {
1755
+ var a = new Object();
1756
+ a.anim = new Object();
1757
+ a.speed = 0.2;
1758
+ return a;
1759
+ }
1760
+
1761
+ var animDataTranslator = function(val,defval,$split,$splitamount,ext) {
1762
+ ext = ext===undefined ? "" : ext;
1763
+ if (jQuery.isNumeric(parseFloat(val))) {
1764
+ return parseFloat(val)+ext;
1765
+ } else
1766
+ if (val===undefined || val==="inherit") {
1767
+ return defval+"ext";
1768
+ } else
1769
+ if (val.split("{").length>1) {
1770
+ var min = val.split(","),
1771
+ max = parseFloat(min[1].split("}")[0]);
1772
+ min = parseFloat(min[0].split("{")[1]);
1773
+
1774
+ if ($split!==undefined && $splitamount!==undefined) {
1775
+
1776
+ val=="["+(parseInt(Math.random()*(max-min),0) + parseInt(min,0))+"ext";
1777
+ for (var i=0;i<$splitamount;i++) {
1778
+ val = val+"|"+(parseInt(Math.random()*(max-min),0) + parseInt(min,0))+ext;
1779
+ }
1780
+ val = val+"]";
1781
+ } else {
1782
+ val = Math.random()*(max-min) + min;
1783
+ }
1784
+ }
1785
+
1786
+ return val;
1787
+ }
1788
+
1789
+ var getBorderDirections = function (x,o,w,h,top,left,direction) {
1790
+
1791
+ if (!jQuery.isNumeric(x) && x.match(/%]/g)) {
1792
+ x = x.split("[")[1].split("]")[0];
1793
+ if (direction=="horizontal")
1794
+ x = (w+2)*parseInt(x,0)/100;
1795
+ else
1796
+ if (direction=="vertical")
1797
+ x = (h+2)*parseInt(x,0)/100;
1798
+ } else {
1799
+
1800
+ x = x === "layer_left" ? (0-w) : x === "layer_right" ? w : x;
1801
+ x = x === "layer_top" ? (0-h) : x==="layer_bottom" ? h : x;
1802
+ x = x === "left" || x==="stage_left" ? (0-w-left) : x === "right" || x==="stage_right" ? o.conw-left : x === "center" || x === "stage_center" ? (o.conw/2 - w/2)-left : x;
1803
+ x = x === "top" || x==="stage_top" ? (0-h-top) : x==="bottom" || x==="stage_bottom" ? o.conh-top : x === "middle" || x === "stage_middle" ? (o.conh/2 - h/2)-top : x;
1804
+ }
1805
+
1806
+
1807
+ return x;
1808
+ }
1809
+
1810
+ ///////////////////////////////////////////////////
1811
+ // ANALYSE AND READ OUT DATAS FROM HTML CAPTIONS //
1812
+ ///////////////////////////////////////////////////
1813
+ var getAnimDatas = function(frm,data,reversed,$split,$splitamount) {
1814
+
1815
+ var o = new Object();
1816
+ o = jQuery.extend(true,{},o, frm);
1817
+ if (data === undefined)
1818
+ return o;
1819
+
1820
+ var customarray = data.split(';'),
1821
+ tmpf="";
1822
+
1823
+
1824
+
1825
+ if (customarray)
1826
+ jQuery.each(customarray,function(index,pa) {
1827
+ var p = pa.split(":")
1828
+ var w = p[0],
1829
+ v = p[1];
1830
+
1831
+
1832
+ if (reversed && reversed!=="none" && v!=undefined && v.length>0 && v.match(/\(R\)/)) {
1833
+ v = v.replace("(R)","");
1834
+ v = v==="right" ? "left" : v==="left" ? "right" : v==="top" ? "bottom" : v==="bottom" ? "top" : v;
1835
+ if (v[0]==="[" && v[1]==="-") v = v.replace("[-","[");
1836
+ else
1837
+ if (v[0]==="[" && v[1]!=="-") v = v.replace("[","[-");
1838
+ else
1839
+ if (v[0]==="-") v = v.replace("-","");
1840
+ else
1841
+ if (v[0].match(/[1-9]/)) v="-"+v;
1842
+ }
1843
+
1844
+ if (v!=undefined) {
1845
+ v = v.replace(/\(R\)/,'');
1846
+
1847
+
1848
+ if (w=="rotationX" || w=="rX") o.anim.rotationX = animDataTranslator(v,o.anim.rotationX,$split,$splitamount,"deg");
1849
+ if (w=="rotationY" || w=="rY") o.anim.rotationY = animDataTranslator(v,o.anim.rotationY,$split,$splitamount,"deg");
1850
+ if (w=="rotationZ" || w=="rZ") o.anim.rotation = animDataTranslator(v,o.anim.rotationZ,$split,$splitamount,"deg");
1851
+ if (w=="scaleX" || w=="sX") o.anim.scaleX = animDataTranslator(v,o.anim.scaleX,$split,$splitamount);
1852
+ if (w=="scaleY" || w=="sY") o.anim.scaleY = animDataTranslator(v,o.anim.scaleY,$split,$splitamount);
1853
+ if (w=="opacity" || w=="o") o.anim.opacity = animDataTranslator(v,o.anim.opacity,$split,$splitamount);
1854
+ //if (w=="letterspacing" || w=="ls") o.anim.letterSpacing = animDataTranslator(v,o.anim.letterSpacing);
1855
+ if (w=="fb") tmpf = tmpf==="" ? 'blur('+parseInt(v,0)+'px)' : tmpf+" "+'blur('+parseInt(v,0)+'px)';
1856
+ if (w=="fg") tmpf = tmpf==="" ? 'grayscale('+parseInt(v,0)+'%)' : tmpf+" "+'grayscale('+parseInt(v,0)+'%)';
1857
+ if (w=="fbr") tmpf = tmpf==="" ? 'brightness('+parseInt(v,0)+'%)' : tmpf+" "+'brightness('+parseInt(v,0)+'%)';
1858
+
1859
+ if (o.anim.opacity===0) o.anim.autoAlpha = 0;
1860
+
1861
+ o.anim.opacity = o.anim.opacity == 0 ? 0.0001 : o.anim.opacity;
1862
+
1863
+ if (w=="skewX" || w=="skX") o.anim.skewX = animDataTranslator(v,o.anim.skewX,$split,$splitamount);
1864
+ if (w=="skewY" || w=="skY") o.anim.skewY = animDataTranslator(v,o.anim.skewY,$split,$splitamount);
1865
+ if (w=="x") o.anim.x = animDataTranslator(v,o.anim.x,$split,$splitamount);
1866
+ if (w=="y") o.anim.y = animDataTranslator(v,o.anim.y,$split,$splitamount);
1867
+ if (w=="z") o.anim.z = animDataTranslator(v,o.anim.z,$split,$splitamount);
1868
+ if (w=="transformOrigin" || w=="tO") o.anim.transformOrigin = v.toString();
1869
+ if (w=="transformPerspective" || w=="tP") o.anim.transformPerspective=parseInt(v,0);
1870
+ if (w=="speed" || w=="s") o.speed = parseFloat(v);
1871
+
1872
+ //if (w=="ease" || w=="e") o.anim.ease = v;
1873
+ }
1874
+ })
1875
+ if (tmpf!=="") {
1876
+ o.anim['-webkit-filter'] = tmpf;
1877
+ o.anim['filter'] = tmpf;
1878
+ }
1879
+
1880
+ return o;
1881
+ }
1882
+
1883
+
1884
+
1885
+ /////////////////////////////////
1886
+ // BUILD MASK ANIMATION OBJECT //
1887
+ /////////////////////////////////
1888
+ var getMaskDatas = function(d) {
1889
+ if (d === undefined)
1890
+ return false;
1891
+
1892
+ var o = new Object();
1893
+ o.anim = new Object();
1894
+ var s = d.split(';')
1895
+ if (s)
1896
+ jQuery.each(s,function(index,param) {
1897
+ param = param.split(":")
1898
+ var w = param[0],
1899
+ v = param[1];
1900
+ if (w=="x") o.anim.x = v;
1901
+ if (w=="y") o.anim.y = v;
1902
+ if (w=="s") o.speed = parseFloat(v);
1903
+ if (w=="e" || w=="ease") o.anim.ease = v;
1904
+ });
1905
+
1906
+ return o;
1907
+ }
1908
+
1909
+
1910
+
1911
+
1912
+ ////////////////////////
1913
+ // SHOW THE CAPTION //
1914
+ ///////////////////////
1915
+
1916
+ var makeArray = function(obj,opt,show) {
1917
+
1918
+ if (obj==undefined) obj = 0;
1919
+
1920
+ if (!jQuery.isArray(obj) && jQuery.type(obj)==="string" && (obj.split(",").length>1 || obj.split("[").length>1)) {
1921
+ obj = obj.replace("[","");
1922
+ obj = obj.replace("]","");
1923
+ var newobj = obj.match(/'/g) ? obj.split("',") : obj.split(",");
1924
+ obj = new Array();
1925
+ if (newobj)
1926
+ jQuery.each(newobj,function(index,element) {
1927
+ element = element.replace("'","");
1928
+ element = element.replace("'","");
1929
+ obj.push(element);
1930
+ })
1931
+ } else {
1932
+ var tempw = obj;
1933
+ if (!jQuery.isArray(obj) ) {
1934
+ obj = new Array();
1935
+ obj.push(tempw);
1936
+ }
1937
+ }
1938
+
1939
+ var tempw = obj[obj.length-1];
1940
+
1941
+ if (obj.length<opt.rle) {
1942
+ for (var i=1;i<=opt.curWinRange;i++) {
1943
+ obj.push(tempw);
1944
+ }
1945
+ }
1946
+ return obj;
1947
+ }
1948
+
1949
+
1950
+ /* CREATE SHARP CORNERS */
1951
+ function sharpCorners(nc,$class, $side,$borderh,$borderv,ncch,bgcol) {
1952
+ var a = nc.find($class);
1953
+ a.css('borderWidth',ncch+"px");
1954
+ a.css($side,(0-ncch)+'px');
1955
+ a.css($borderh,'0px solid transparent');
1956
+ a.css($borderv,bgcol);
1957
+ }
1958
+
1959
+
1960
+ var convertHoverStyle = function(t,s) {
1961
+ if (s===undefined) return t;
1962
+ s = s.replace("c:","color:");
1963
+ s = s.replace("bg:","background-color:");
1964
+ s = s.replace("bw:","border-width:");
1965
+ s = s.replace("bc:","border-color:");
1966
+ s = s.replace("br:","borderRadius:");
1967
+ s = s.replace("bs:","border-style:");
1968
+ s = s.replace("td:","text-decoration:");
1969
+ s = s.replace("zi:","zIndex:");
1970
+ var sp = s.split(";");
1971
+ if (sp)
1972
+ jQuery.each(sp,function(key,cont){
1973
+ var attr = cont.split(":");
1974
+ if (attr[0].length>0) {
1975
+ if (attr[0]==="background-color" && attr[1].indexOf("gradient")>=0) attr[0]="background";
1976
+ t.anim[attr[0]] = attr[1];
1977
+ }
1978
+ })
1979
+ return t;
1980
+
1981
+ }
1982
+
1983
+
1984
+ ////////////////////////////////////////////////
1985
+ // - GET CSS ATTRIBUTES OF ELEMENT - //
1986
+ ////////////////////////////////////////////////
1987
+ var getcssParams = function(nc,level) {
1988
+
1989
+ var obj = new Object(),
1990
+ gp = false,
1991
+ pc;
1992
+
1993
+
1994
+ // CHECK IF CURRENT ELEMENT SHOULD RESPECT REKURSICVE RESIZES, AND SHOULD OWN THE SAME ATTRIBUTES FROM PARRENT ELEMENT
1995
+ if (level=="rekursive") {
1996
+ pc = nc.closest('.tp-caption');
1997
+ if (pc && (
1998
+ (nc.css("fontSize") === pc.css("fontSize")) &&
1999
+ (nc.css("fontWeight") === pc.css("fontWeight")) &&
2000
+ (nc.css("lineHeight") === pc.css("lineHeight"))
2001
+ ))
2002
+ gp = true;
2003
+ }
2004
+
2005
+
2006
+ obj.basealign = nc.data('basealign') || "grid";
2007
+ obj.fontSize = gp ? pc.data('fontsize')===undefined ? parseInt(pc.css('fontSize'),0) || 0 : pc.data('fontsize') : nc.data('fontsize')===undefined ? parseInt(nc.css('fontSize'),0) || 0 : nc.data('fontsize');
2008
+ obj.fontWeight = gp ? pc.data('fontweight')===undefined ? parseInt(pc.css('fontWeight'),0) || 0 : pc.data('fontweight') : nc.data('fontweight')===undefined ? parseInt(nc.css('fontWeight'),0) || 0 : nc.data('fontweight');
2009
+
2010
+ obj.whiteSpace = gp ? pc.data('whitespace')===undefined ? pc.css('whitespace') || "normal" : pc.data('whitespace') : nc.data('whitespace')===undefined ? nc.css('whitespace') || "normal" : nc.data('whitespace');
2011
+ obj.textAlign = gp ? pc.data('textalign')===undefined ? pc.css('textalign') || "inherit" : pc.data('textalign') : nc.data('textalign')===undefined ? nc.css('textalign') || "inherit" : nc.data('textalign');
2012
+ obj.zIndex = gp ? pc.data('zIndex')===undefined ? pc.css('zIndex') || "inherit" : pc.data('zIndex') : nc.data('zIndex')===undefined ? nc.css('zIndex') || "inherit" : nc.data('zIndex');
2013
+
2014
+ if (jQuery.inArray(nc.data('layertype'),["video","image","audio"])===-1 && !nc.is("img"))
2015
+ obj.lineHeight = gp ? pc.data('lineheight')===undefined ? parseInt(pc.css('lineHeight'),0) || 0 : pc.data('lineheight') : nc.data('lineheight')===undefined ? parseInt(nc.css('lineHeight'),0) || 0 : nc.data('lineheight');
2016
+ else
2017
+ obj.lineHeight = 0;
2018
+
2019
+ obj.letterSpacing = gp ? pc.data('letterspacing')===undefined ? parseFloat(pc.css('letterSpacing'),0) || 0 : pc.data('letterspacing') : nc.data('letterspacing')===undefined ? parseFloat(nc.css('letterSpacing')) || 0 : nc.data('letterspacing');
2020
+
2021
+ obj.paddingTop = nc.data('paddingtop')===undefined ? parseInt(nc.css('paddingTop'),0) || 0 : nc.data('paddingtop');
2022
+ obj.paddingBottom = nc.data('paddingbottom')===undefined ? parseInt(nc.css('paddingBottom'),0) || 0 : nc.data('paddingbottom');
2023
+ obj.paddingLeft = nc.data('paddingleft')===undefined ? parseInt(nc.css('paddingLeft'),0) || 0 : nc.data('paddingleft');
2024
+ obj.paddingRight = nc.data('paddingright')===undefined ? parseInt(nc.css('paddingRight'),0) || 0 : nc.data('paddingright');
2025
+
2026
+ obj.marginTop = nc.data('margintop')===undefined ? parseInt(nc.css('marginTop'),0) || 0 : nc.data('margintop');
2027
+ obj.marginBottom = nc.data('marginbottom')===undefined ? parseInt(nc.css('marginBottom'),0) || 0 : nc.data('marginbottom');
2028
+ obj.marginLeft = nc.data('marginleft')===undefined ? parseInt(nc.css('marginLeft'),0) || 0 : nc.data('marginleft');
2029
+ obj.marginRight = nc.data('marginright')===undefined ? parseInt(nc.css('marginRight'),0) || 0 : nc.data('marginright');
2030
+ obj.borderTopWidth = nc.data('bordertopwidth')===undefined ? parseInt(nc.css('borderTopWidth'),0) || 0 : nc.data('bordertopwidth');
2031
+ obj.borderBottomWidth = nc.data('borderbottomwidth')===undefined ? parseInt(nc.css('borderBottomWidth'),0) || 0 : nc.data('borderbottomwidth');
2032
+ obj.borderLeftWidth = nc.data('borderleftwidth')===undefined ? parseInt(nc.css('borderLeftWidth'),0) || 0 : nc.data('borderleftwidth');
2033
+ obj.borderRightWidth = nc.data('borderrightwidth')===undefined ? parseInt(nc.css('borderRightWidth'),0) || 0 : nc.data('borderrightwidth');
2034
+
2035
+ if (level!="rekursive") {
2036
+ obj.color = nc.data('color')===undefined ? "nopredefinedcolor" : nc.data('color');
2037
+
2038
+ obj.whiteSpace = gp ? pc.data('whitespace')===undefined ? pc.css('whiteSpace') || "nowrap" : pc.data('whitespace') : nc.data('whitespace')===undefined ? nc.css('whiteSpace') || "nowrap" : nc.data('whitespace');
2039
+ obj.textAlign = gp ? pc.data('textalign')===undefined ? pc.css('textalign') || "inherit" : pc.data('textalign') : nc.data('textalign')===undefined ? nc.css('textalign') || "inherit" : nc.data('textalign');
2040
+ obj.fontWeight = gp ? pc.data('fontweight')===undefined ? parseInt(pc.css('fontWeight'),0) || 0 : pc.data('fontweight') : nc.data('fontweight')===undefined ? parseInt(nc.css('fontWeight'),0) || 0 : nc.data('fontweight');
2041
+
2042
+ obj.minWidth = nc.data('width')===undefined ? parseInt(nc.css('minWidth'),0) || 0 : nc.data('width');
2043
+ obj.minHeight = nc.data('height')===undefined ? parseInt(nc.css('minHeight'),0) || 0 : nc.data('height');
2044
+
2045
+ if (nc.data('videowidth')!=undefined && nc.data('videoheight')!=undefined) {
2046
+ var vwid = nc.data('videowidth'),
2047
+ vhei = nc.data('videoheight');
2048
+ vwid = vwid==="100%" ? "none" : vwid;
2049
+ vhei = vhei==="100%" ? "none" : vhei;
2050
+
2051
+ nc.data('width',vwid);
2052
+ nc.data('height',vhei);
2053
+ }
2054
+
2055
+ obj.maxWidth = nc.data('width')===undefined ? parseInt(nc.css('maxWidth'),0) || "none" : nc.data('width');
2056
+ obj.maxHeight = jQuery.inArray(nc.data('type'),["column","row"])!==-1 ? "none" : nc.data('height')===undefined ? parseInt(nc.css('maxHeight'),0) || "none" : nc.data('height');
2057
+
2058
+ obj.wan = nc.data('wan')===undefined ? parseInt(nc.css('-webkit-transition'),0) || "none" : nc.data('wan');
2059
+ obj.moan = nc.data('moan')===undefined ? parseInt(nc.css('-moz-animation-transition'),0) || "none" : nc.data('moan');
2060
+ obj.man = nc.data('man')===undefined ? parseInt(nc.css('-ms-animation-transition'),0) || "none" : nc.data('man');
2061
+ obj.ani = nc.data('ani')===undefined ? parseInt(nc.css('transition'),0) || "none" : nc.data('ani');
2062
+ }
2063
+
2064
+
2065
+ obj.styleProps = { borderTopLeftRadius : nc[0].style.borderTopLeftRadius,
2066
+ borderTopRightRadius : nc[0].style.borderTopRightRadius,
2067
+ borderBottomRightRadius : nc[0].style.borderBottomRightRadius,
2068
+ borderBottomLeftRadius : nc[0].style.borderBottomLeftRadius,
2069
+ "background" : nc[0].style["background"],
2070
+ "boxShadow" : nc[0].style["boxShadow"],
2071
+ "background-color" : nc[0].style["background-color"],
2072
+ "border-top-color" : nc[0].style["border-top-color"],
2073
+ "border-bottom-color" : nc[0].style["border-bottom-color"],
2074
+ "border-right-color" : nc[0].style["border-right-color"],
2075
+ "border-left-color" : nc[0].style["border-left-color"],
2076
+ "border-top-style" : nc[0].style["border-top-style"],
2077
+ "border-bottom-style" : nc[0].style["border-bottom-style"],
2078
+ "border-left-style" : nc[0].style["border-left-style"],
2079
+ "border-right-style" : nc[0].style["border-right-style"],
2080
+ "border-left-width" : nc[0].style["border-left-width"],
2081
+ "border-right-width" : nc[0].style["border-right-width"],
2082
+ "border-bottom-width" : nc[0].style["border-bottom-width"],
2083
+ "border-top-width" : nc[0].style["border-top-width"],
2084
+ "color" : nc[0].style["color"],
2085
+ "text-decoration" : nc[0].style["text-decoration"],
2086
+ "font-style" : nc[0].style["font-style"]
2087
+ };
2088
+
2089
+ if (obj.styleProps.background==="" || obj.styleProps.background===undefined || obj.styleProps.background === obj.styleProps["background-color"])
2090
+ delete obj.styleProps.background;
2091
+ if (obj.styleProps.color=="")
2092
+ obj.styleProps.color = nc.css("color");
2093
+
2094
+ return obj;
2095
+ }
2096
+
2097
+ // READ SINGLE OR ARRAY VALUES OF OBJ CSS ELEMENTS
2098
+ var setResponsiveCSSValues = function(obj,opt) {
2099
+ var newobj = new Object();
2100
+ if (obj)
2101
+ jQuery.each(obj,function(key,val){
2102
+ var res_a = makeArray(val,opt)[opt.curWinRange];
2103
+ newobj[key] = res_a!==undefined ? res_a : obj[key];
2104
+ });
2105
+ return newobj;
2106
+ }
2107
+
2108
+ var minmaxconvert = function(a,m,r,fr) {
2109
+
2110
+ a = jQuery.isNumeric(a) ? (a * m)+"px" : a;
2111
+ a = a==="full" ? fr : a==="auto" || a==="none" ? r : a;
2112
+ return a;
2113
+
2114
+ }
2115
+
2116
+ /////////////////////////////////////////////////////////////////
2117
+ // - CALCULATE THE RESPONSIVE SIZES OF THE CAPTIONS - //
2118
+ /////////////////////////////////////////////////////////////////
2119
+ var calcCaptionResponsive = function(nc,opt,level,responsive) {
2120
+
2121
+ var _=nc.data();
2122
+
2123
+
2124
+ _ = _===undefined ? {} : _;
2125
+
2126
+ try{
2127
+ if (nc[0].nodeName=="BR" || nc[0].tagName=="br"
2128
+ /*|| nc[0].nodeName=="b" || nc[0].tagName=="b" ||
2129
+ nc[0].nodeName=="strong" || nc[0].tagName=="STRONG"*/
2130
+ )
2131
+ return false;
2132
+ } catch(e) {
2133
+
2134
+ }
2135
+
2136
+ _.cssobj = _.cssobj===undefined ? getcssParams(nc,level) : _.cssobj;
2137
+
2138
+ var obj = setResponsiveCSSValues(_.cssobj,opt),
2139
+ bw=opt.bw,
2140
+ bh=opt.bh;
2141
+
2142
+ if (responsive==="off") {
2143
+ bw=1;
2144
+ bh=1;
2145
+ }
2146
+
2147
+ // IE8 FIX FOR AUTO LINEHEIGHT
2148
+ if (obj.lineHeight=="auto") obj.lineHeight = obj.fontSize+4;
2149
+
2150
+ var objmargins = { Top: obj.marginTop,
2151
+ Bottom: obj.marginBottom,
2152
+ Left: obj.marginLeft,
2153
+ Right: obj.marginRight
2154
+ }
2155
+ if (_._nctype==="column") {
2156
+ punchgs.TweenLite.set(_._column,{
2157
+ paddingTop: Math.round((obj.marginTop * bh)) + "px",
2158
+ paddingBottom: Math.round((obj.marginBottom * bh)) + "px",
2159
+ paddingLeft: Math.round((obj.marginLeft* bw)) + "px",
2160
+ paddingRight: Math.round((obj.marginRight * bw)) + "px"});
2161
+ objmargins = { Top: 0,
2162
+ Bottom: 0,
2163
+ Left: 0,
2164
+ Right: 0
2165
+ }
2166
+
2167
+ }
2168
+
2169
+
2170
+
2171
+ if (!nc.hasClass("tp-splitted")) {
2172
+
2173
+ nc.css("-webkit-transition", "none");
2174
+ nc.css("-moz-transition", "none");
2175
+ nc.css("-ms-transition", "none");
2176
+ nc.css("transition", "none");
2177
+
2178
+ var hashover = nc.data('transform_hover')!==undefined || nc.data('style_hover')!==undefined;
2179
+ if (hashover) punchgs.TweenLite.set(nc,obj.styleProps);
2180
+
2181
+
2182
+ punchgs.TweenLite.set(nc,{
2183
+
2184
+ fontSize: Math.round((obj.fontSize * bw))+"px",
2185
+ fontWeight: obj.fontWeight,
2186
+ letterSpacing:Math.floor((obj.letterSpacing * bw))+"px",
2187
+ paddingTop: Math.round((obj.paddingTop * bh)) + "px",
2188
+ paddingBottom: Math.round((obj.paddingBottom * bh)) + "px",
2189
+ paddingLeft: Math.round((obj.paddingLeft* bw)) + "px",
2190
+ paddingRight: Math.round((obj.paddingRight * bw)) + "px",
2191
+ marginTop: (objmargins.Top * bh) + "px",
2192
+ marginBottom: (objmargins.Bottom * bh) + "px",
2193
+ marginLeft: (objmargins.Left * bw) + "px",
2194
+ marginRight: (objmargins.Right * bw) + "px",
2195
+ borderTopWidth: Math.round(obj.borderTopWidth * bh) + "px",
2196
+ borderBottomWidth: Math.round(obj.borderBottomWidth * bh) + "px",
2197
+ borderLeftWidth: Math.round(obj.borderLeftWidth * bw) + "px",
2198
+ borderRightWidth: Math.round(obj.borderRightWidth * bw) + "px",
2199
+ lineHeight: Math.round(obj.lineHeight * bh) + "px",
2200
+ textAlign:(obj.textAlign),
2201
+ overwrite:"auto"});
2202
+
2203
+
2204
+ if (level!="rekursive") {
2205
+
2206
+
2207
+
2208
+ var winw = obj.basealign =="slide" ? opt.ulw : opt.gridwidth[opt.curWinRange],
2209
+ winh = obj.basealign =="slide" ? opt.ulh : opt.gridheight[opt.curWinRange],
2210
+ maxw = minmaxconvert(obj.maxWidth,bw,"none",winw),
2211
+ maxh = minmaxconvert(obj.maxHeight,bh,"none",winh),
2212
+ minw = minmaxconvert(obj.minWidth,bw,"0px",winw),
2213
+ minh = minmaxconvert(obj.minHeight,bh,"0px",winh);
2214
+
2215
+
2216
+
2217
+ // TWEEN FIX ISSUES
2218
+ minw=minw===undefined ? 0 : minw;
2219
+ minh=minh===undefined ? 0 : minh;
2220
+ maxw=maxw===undefined ? "none" : maxw;
2221
+ maxh=maxh===undefined ? "none" : maxh;
2222
+
2223
+
2224
+ if (_._isgroup) {
2225
+
2226
+
2227
+ if (minw==="#1/1#") minw = maxw = winw;
2228
+ if (minw==="#1/2#") minw = maxw = winw / 2;
2229
+ if (minw==="#1/3#") minw = maxw = winw/3;
2230
+
2231
+ if (minw==="#1/4#") minw = maxw = winw / 4;
2232
+ if (minw==="#1/5#") minw = maxw = winw / 5;
2233
+ if (minw==="#1/6#") minw = maxw = winw / 6;
2234
+
2235
+ if (minw==="#2/3#") minw = maxw = (winw / 3) * 2;
2236
+ if (minw==="#3/4#") minw = maxw = (winw / 4) * 3;
2237
+ if (minw==="#2/5#") minw = maxw = (winw / 5) * 2;
2238
+ if (minw==="#3/5#") minw = maxw = (winw / 5) * 3;
2239
+ if (minw==="#4/5#") minw = maxw = (winw / 5) * 4;
2240
+
2241
+ if (minw==="#3/6#") minw = maxw = (winw / 6) * 3;
2242
+ if (minw==="#4/6#") minw = maxw = (winw / 6) * 4;
2243
+ if (minw==="#5/6#") minw = maxw = (winw / 6) * 5;
2244
+
2245
+ }
2246
+
2247
+ if (_._ingroup) {
2248
+ _._groupw = minw;
2249
+ _._grouph = minh;
2250
+ }
2251
+
2252
+
2253
+ punchgs.TweenLite.set(nc,{
2254
+ maxWidth:maxw,
2255
+ maxHeight:maxh,
2256
+ minWidth:minw,
2257
+ minHeight:minh,
2258
+ whiteSpace:obj.whiteSpace,
2259
+ textAlign:(obj.textAlign),
2260
+ overwrite:"auto"
2261
+ });
2262
+
2263
+ if (obj.color!="nopredefinedcolor")
2264
+ punchgs.TweenLite.set(nc,{color:obj.color,overwrite:"auto"});
2265
+
2266
+ if (_.svg_src!=undefined) {
2267
+ var scolto = obj.color!="nopredefinedcolor" && obj.color!=undefined ? obj.color : obj.css!=undefined && obj.css.color!="nopredefinedcolor" && obj.css.color!=undefined ? obj.css.color : obj.styleProps.color!=undefined ? obj.styleProps.color : obj.styleProps.css!=undefined && obj.styleProps.css.color!=undefined ? obj.styleProps.css.color : false;
2268
+ if (scolto!=false) {
2269
+ punchgs.TweenLite.set(nc.find('svg'),{fill:scolto,overwrite:"auto"});
2270
+ punchgs.TweenLite.set(nc.find('svg path'),{fill:scolto,overwrite:"auto"});
2271
+ }
2272
+ }
2273
+
2274
+ }
2275
+
2276
+ if (_._nctype==="column") {
2277
+
2278
+ if (_._column_bg_set===undefined) {
2279
+ _._column_bg_set = nc.css('backgroundColor');
2280
+ _._column_bg_image = nc.css('backgroundImage');
2281
+ _._column_bg_image_repeat =nc.css('backgroundRepeat');
2282
+ _._column_bg_image_position =nc.css('backgroundPosition');
2283
+ _._column_bg_image_size =nc.css('backgroundSize');
2284
+ _._column_bg_opacity = nc.data('bgopacity');
2285
+ _._column_bg_opacity = _._column_bg_opacity===undefined ? 1 : _._column_bg_opacity;
2286
+
2287
+
2288
+ punchgs.TweenLite.set(nc,{
2289
+ backgroundColor:"transparent",
2290
+ backgroundImage:""
2291
+ });
2292
+ }
2293
+
2294
+
2295
+ setTimeout(function() {
2296
+ setColumnBgDimension(nc,opt);
2297
+ },1);
2298
+
2299
+
2300
+ // DYNAMIC HEIGHT AUTO CALCULATED BY BROWSER
2301
+ if (_._cbgc_auto && _._cbgc_auto.length>0) {
2302
+ _._cbgc_auto[0].style.backgroundSize = _._column_bg_image_size;
2303
+ if (jQuery.isArray(obj.marginLeft)) {
2304
+ punchgs.TweenLite.set(_._cbgc_auto,{
2305
+ borderTopWidth: (obj.marginTop[opt.curWinRange] * bh) + "px",
2306
+ borderLeftWidth: (obj.marginLeft[opt.curWinRange] * bw) + "px",
2307
+ borderRightWidth: (obj.marginRight[opt.curWinRange] * bw) + "px",
2308
+ borderBottomWidth:(obj.marginBottom[opt.curWinRange] * bh) + "px",
2309
+ backgroundColor:_._column_bg_set,
2310
+ backgroundImage:_._column_bg_image,
2311
+ backgroundRepeat:_._column_bg_image_repeat,
2312
+ backgroundPosition:_._column_bg_image_position,
2313
+ opacity:_._column_bg_opacity
2314
+
2315
+ });
2316
+ } else {
2317
+ punchgs.TweenLite.set(_._cbgc_auto,{
2318
+ borderTopWidth: (obj.marginTop * bh) + "px",
2319
+ borderLeftWidth: (obj.marginLeft * bw) + "px",
2320
+ borderRightWidth: (obj.marginRight * bw) + "px",
2321
+ borderBottomWidth:(obj.marginBottom * bh) + "px",
2322
+ backgroundColor:_._column_bg_set,
2323
+ backgroundImage:_._column_bg_image,
2324
+ backgroundRepeat:_._column_bg_image_repeat,
2325
+ backgroundPosition:_._column_bg_image_position,
2326
+ opacity:_._column_bg_opacity
2327
+
2328
+ });
2329
+ }
2330
+
2331
+
2332
+ }
2333
+ }
2334
+
2335
+ setTimeout(function() {
2336
+ nc.css("-webkit-transition", nc.data('wan'));
2337
+ nc.css("-moz-transition", nc.data('moan'));
2338
+ nc.css("-ms-transition", nc.data('man'));
2339
+ nc.css("transition", nc.data('ani'));
2340
+ },30);
2341
+ }
2342
+ }
2343
+
2344
+
2345
+ var setColumnBgDimension = function(nc,opt) {
2346
+ // DYNAMIC HEIGHT BASED ON ROW HEIGHT
2347
+ var _ = nc.data();
2348
+ if (_._cbgc_man && _._cbgc_man.length>0) {
2349
+
2350
+
2351
+ var _l,_t,_b,_r,_h,_o;
2352
+
2353
+ if (!jQuery.isArray(_.cssobj.marginLeft)) {
2354
+ _l = (_.cssobj.marginLeft * opt.bw);
2355
+ _t = (_.cssobj.marginTop * opt.bh);
2356
+ _b = (_.cssobj.marginBottom * opt.bh);
2357
+ _r = (_.cssobj.marginRight * opt.bw);
2358
+ } else {
2359
+ _l = (_.cssobj.marginLeft[opt.curWinRange] * opt.bw);
2360
+ _t = (_.cssobj.marginTop[opt.curWinRange] * opt.bh);
2361
+ _b = (_.cssobj.marginBottom[opt.curWinRange] * opt.bh);
2362
+ _r = (_.cssobj.marginRight[opt.curWinRange] * opt.bw);
2363
+ }
2364
+ _h = _._row.hasClass("rev_break_columns") ? "100%" : (_._row.height() - (_t+_b))+"px";
2365
+
2366
+ _._cbgc_man[0].style.backgroundSize = _._column_bg_image_size;
2367
+
2368
+ punchgs.TweenLite.set(_._cbgc_man,{
2369
+ width:"100%",
2370
+ height:_h,
2371
+ backgroundColor:_._column_bg_set,
2372
+ backgroundImage:_._column_bg_image,
2373
+ backgroundRepeat:_._column_bg_image_repeat,
2374
+ backgroundPosition:_._column_bg_image_position,
2375
+ overwrite:"auto",
2376
+ opacity:_._column_bg_opacity
2377
+ });
2378
+
2379
+ }
2380
+ }
2381
+
2382
+ //////////////////////
2383
+ // CAPTION LOOPS //
2384
+ //////////////////////
2385
+ var callCaptionLoops = function(el,factor) {
2386
+ var _ = el.data();
2387
+ // SOME LOOPING ANIMATION ON INTERNAL ELEMENTS
2388
+ if (el.hasClass("rs-pendulum")) {
2389
+ if (_._loop_timeline==undefined) {
2390
+ _._loop_timeline = new punchgs.TimelineLite;
2391
+ var startdeg = el.data('startdeg')==undefined ? -20 : el.data('startdeg'),
2392
+ enddeg = el.data('enddeg')==undefined ? 20 : el.data('enddeg'),
2393
+ speed = el.data('speed')==undefined ? 2 : el.data('speed'),
2394
+ origin = el.data('origin')==undefined ? "50% 50%" : el.data('origin'),
2395
+ easing = el.data('easing')==undefined ? punchgs.Power2.easeInOut : el.data('easing');
2396
+
2397
+
2398
+ startdeg = startdeg * factor;
2399
+ enddeg = enddeg * factor;
2400
+
2401
+ _._loop_timeline.append(new punchgs.TweenLite.fromTo(el,speed,{force3D:"auto",rotation:startdeg,transformOrigin:origin},{rotation:enddeg,ease:easing}));
2402
+ _._loop_timeline.append(new punchgs.TweenLite.fromTo(el,speed,{force3D:"auto",rotation:enddeg,transformOrigin:origin},{rotation:startdeg,ease:easing,onComplete:function() {
2403
+ _._loop_timeline.restart();
2404
+ }}));
2405
+ }
2406
+
2407
+ }
2408
+
2409
+ // SOME LOOPING ANIMATION ON INTERNAL ELEMENTS
2410
+ if (el.hasClass("rs-rotate")) {
2411
+ if (_._loop_timeline==undefined) {
2412
+ _._loop_timeline = new punchgs.TimelineLite;
2413
+ var startdeg = el.data('startdeg')==undefined ? 0 : el.data('startdeg'),
2414
+ enddeg = el.data('enddeg')==undefined ? 360 : el.data('enddeg'),
2415
+ speed = el.data('speed')==undefined ? 2 : el.data('speed'),
2416
+ origin = el.data('origin')==undefined ? "50% 50%" : el.data('origin'),
2417
+ easing = el.data('easing')==undefined ? punchgs.Power2.easeInOut : el.data('easing');
2418
+
2419
+ startdeg = startdeg * factor;
2420
+ enddeg = enddeg * factor;
2421
+
2422
+ _._loop_timeline.append(new punchgs.TweenLite.fromTo(el,speed,{force3D:"auto",rotation:startdeg,transformOrigin:origin},{rotation:enddeg,ease:easing,onComplete:function() {
2423
+ _._loop_timeline.restart();
2424
+ }}));
2425
+ }
2426
+
2427
+ }
2428
+
2429
+ // SOME LOOPING ANIMATION ON INTERNAL ELEMENTS
2430
+ if (el.hasClass("rs-slideloop")) {
2431
+ if (_._loop_timeline==undefined) {
2432
+ _._loop_timeline = new punchgs.TimelineLite;
2433
+ var xs = el.data('xs')==undefined ? 0 : el.data('xs'),
2434
+ ys = el.data('ys')==undefined ? 0 : el.data('ys'),
2435
+ xe = el.data('xe')==undefined ? 0 : el.data('xe'),
2436
+ ye = el.data('ye')==undefined ? 0 : el.data('ye'),
2437
+ speed = el.data('speed')==undefined ? 2 : el.data('speed'),
2438
+ easing = el.data('easing')==undefined ? punchgs.Power2.easeInOut : el.data('easing');
2439
+
2440
+ xs = xs * factor;
2441
+ ys = ys * factor;
2442
+ xe = xe * factor;
2443
+ ye = ye * factor;
2444
+
2445
+ _._loop_timeline.append(new punchgs.TweenLite.fromTo(el,speed,{force3D:"auto",x:xs,y:ys},{x:xe,y:ye,ease:easing}));
2446
+ _._loop_timeline.append(new punchgs.TweenLite.fromTo(el,speed,{force3D:"auto",x:xe,y:ye},{x:xs,y:ys,onComplete:function() {
2447
+ _._loop_timeline.restart();
2448
+ }}));
2449
+ }
2450
+ }
2451
+
2452
+ // SOME LOOPING ANIMATION ON INTERNAL ELEMENTS
2453
+ if (el.hasClass("rs-pulse")) {
2454
+ if (_._loop_timeline==undefined) {
2455
+ _._loop_timeline = new punchgs.TimelineLite;
2456
+ var zoomstart = el.data('zoomstart')==undefined ? 0 : el.data('zoomstart'),
2457
+ zoomend = el.data('zoomend')==undefined ? 0 : el.data('zoomend'),
2458
+ speed = el.data('speed')==undefined ? 2 : el.data('speed'),
2459
+ easing = el.data('easing')==undefined ? punchgs.Power2.easeInOut : el.data('easing');
2460
+
2461
+ _._loop_timeline.append(new punchgs.TweenLite.fromTo(el,speed,{force3D:"auto",scale:zoomstart},{scale:zoomend,ease:easing}));
2462
+ _._loop_timeline.append(new punchgs.TweenLite.fromTo(el,speed,{force3D:"auto",scale:zoomend},{scale:zoomstart,onComplete:function() {
2463
+ _._loop_timeline.restart();
2464
+ }}));
2465
+ }
2466
+ }
2467
+
2468
+ if (el.hasClass("rs-wave")) {
2469
+ if (_._loop_timeline==undefined) {
2470
+ _._loop_timeline = new punchgs.TimelineLite;
2471
+
2472
+ var angle= el.data('angle')==undefined ? 10 : parseInt(el.data('angle'),0),
2473
+ radius = el.data('radius')==undefined ? 10 : parseInt(el.data('radius'),0),
2474
+ speed = el.data('speed')==undefined ? -20 : el.data('speed'),
2475
+ origin = el.data('origin')==undefined ? "50% 50%" : el.data('origin'),
2476
+ ors = origin.split(" "),
2477
+ oo = new Object();
2478
+
2479
+ if (ors.length>=1) {
2480
+ oo.x = ors[0];
2481
+ oo.y = ors[1];
2482
+ } else {
2483
+ oo.x = "50%";
2484
+ oo.y = "50%";
2485
+ }
2486
+
2487
+ radius = radius * factor;
2488
+
2489
+ var _ox = ((parseInt(oo.x,0)/100)-0.5) * el.width(),
2490
+ _oy = ((parseInt(oo.y,0)/100)-0.5) * el.height(),
2491
+ yo = (-1*radius) + _oy,
2492
+ xo = 0 + _ox,
2493
+ angobj= {a:0, ang : angle, element:el, unit:radius, xoffset:xo, yoffset:yo},
2494
+ ang = parseInt(angle,0),
2495
+ waveanim = new punchgs.TweenLite.fromTo(angobj,speed,{ a:(0+ang) },{ a:(360+ang),force3D:"auto",ease:punchgs.Linear.easeNone});
2496
+
2497
+ waveanim.eventCallback("onUpdate",function(angobj) {
2498
+ var rad = angobj.a * (Math.PI / 180),
2499
+ yy = angobj.yoffset+(angobj.unit * (1 - Math.sin(rad))),
2500
+ xx = angobj.xoffset+Math.cos(rad) * angobj.unit;
2501
+ punchgs.TweenLite.to(angobj.element,0.1,{force3D:"auto",x:xx, y:yy});
2502
+ },[angobj]);
2503
+
2504
+ waveanim.eventCallback("onComplete",function(_) {
2505
+ _._loop_timeline.restart();
2506
+ },[_]);
2507
+
2508
+ _._loop_timeline.append(waveanim);
2509
+ }
2510
+ }
2511
+ }
2512
+
2513
+ var killCaptionLoops = function(nextcaption) {
2514
+ // SOME LOOPING ANIMATION ON INTERNAL ELEMENTS
2515
+ nextcaption.closest('.rs-pendulum, .rs-slideloop, .rs-pulse, .rs-wave').each(function() {
2516
+ var _ = this;
2517
+ if (_._loop_timeline!=undefined) {
2518
+ _._loop_timeline.pause();
2519
+ _._loop_timeline = null;
2520
+ }
2521
+ });
2522
+ }
2523
+
2524
+ })(jQuery);