j1-template 2024.3.22 → 2024.3.23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (287) hide show
  1. checksums.yaml +4 -4
  2. data/assets/data/{galeries.html → gallery_app.html} +4 -4
  3. data/assets/theme/bla +0 -0
  4. data/assets/theme/j1/adapter/js/amplitude.js +144 -52
  5. data/assets/theme/j1/adapter/js/gallery.js +1 -1
  6. data/assets/theme/j1/adapter/js/themes.js +41 -69
  7. data/assets/theme/j1/core/css/themes/unolight/bootstrap.css +19 -52
  8. data/assets/theme/j1/core/css/themes/unolight/bootstrap.min.css +1 -1
  9. data/assets/theme/j1/modules/amplitudejs/js/tech/ytp.js +466 -396
  10. data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/lg-transitions.css +984 -0
  11. data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/lg-transitions.min.css +26 -0
  12. data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/lightgallery-bundle.css +1627 -0
  13. data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/lightgallery-bundle.min.css +25 -0
  14. data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/uno.css +1 -1
  15. data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/uno.min.css +1 -1
  16. data/assets/theme/j1/modules/lightGallery/!v2.7.2/fonts/lg.svg +54 -0
  17. data/assets/theme/j1/modules/lightGallery/!v2.7.2/fonts/lg.ttf +0 -0
  18. data/assets/theme/j1/modules/lightGallery/!v2.7.2/fonts/lg.woff +0 -0
  19. data/assets/theme/j1/modules/lightGallery/!v2.7.2/fonts/lg.woff2 +0 -0
  20. data/assets/theme/j1/modules/lightGallery/!v2.7.2/images/loading.gif +0 -0
  21. data/assets/theme/j1/modules/lightGallery/!v2.7.2/img/loading.gif +0 -0
  22. data/assets/theme/j1/modules/lightGallery/!v2.7.2/img/video-play.png +0 -0
  23. data/assets/theme/j1/modules/lightGallery/!v2.7.2/img/vimeo-play.png +0 -0
  24. data/assets/theme/j1/modules/lightGallery/!v2.7.2/img/youtube-play.png +0 -0
  25. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/lightgallery.js +2782 -0
  26. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/lightgallery.min.js +26 -0
  27. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/parser/webvtt/LICENSE.md +44 -0
  28. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/parser/webvtt/README.md +37 -0
  29. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/parser/webvtt/parser.js +890 -0
  30. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/parser/webvtt/parser.min.js +8 -0
  31. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/j1/lg-video.1.js +585 -0
  32. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-autoplay.js +275 -0
  33. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-autoplay.min.js +26 -0
  34. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-comment.js +230 -0
  35. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-comment.min.js +26 -0
  36. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-fullscreen.js +160 -0
  37. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-fullscreen.min.js +26 -0
  38. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-hash.js +223 -0
  39. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-hash.min.js +27 -0
  40. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-medium-zoom.js +157 -0
  41. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-medium-zoom.min.js +26 -0
  42. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-pager.js +164 -0
  43. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-pager.min.js +26 -0
  44. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-rotate.js +299 -0
  45. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-rotate.min.js +26 -0
  46. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-share.js +244 -0
  47. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-share.min.js +27 -0
  48. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-thumbnail.js +509 -0
  49. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-thumbnail.min.js +26 -0
  50. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-video.js +909 -0
  51. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-video.min.js +26 -0
  52. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-vimeo-thumbnail.js +207 -0
  53. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-vimeo-thumbnail.min.js +26 -0
  54. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-zoom.js +999 -0
  55. data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-zoom.min.js +26 -0
  56. data/assets/theme/j1/modules/lightGallery/css/lg-transitions.css +3 -126
  57. data/assets/theme/j1/modules/lightGallery/css/lg-transitions.min.css +3 -10
  58. data/assets/theme/j1/modules/lightGallery/css/lightgallery-bundle.css +70 -237
  59. data/assets/theme/j1/modules/lightGallery/css/lightgallery-bundle.min.css +4 -10
  60. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/animation-w.png +0 -0
  61. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/customize-w.png +0 -0
  62. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/dynamic-w.png +0 -0
  63. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/facebook-icon.svg +10 -0
  64. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/googleplus-icon.svg +30 -0
  65. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/html5-w.png +0 -0
  66. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/linked-in.png +0 -0
  67. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/module-w.png +0 -0
  68. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/play-button-hover.svg +94 -0
  69. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/play-button.png +0 -0
  70. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/play-button.svg +93 -0
  71. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/responsive-w.png +0 -0
  72. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/thumb-w.png +0 -0
  73. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/touch-w.png +0 -0
  74. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/twitter-icon.svg +15 -0
  75. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/twitter.png +0 -0
  76. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/video1-w.png +0 -0
  77. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/zoom-w.png +0 -0
  78. data/assets/theme/j1/modules/lightGallery/css/theme/uno/icons/zoom.png +0 -0
  79. data/assets/theme/j1/modules/lightGallery/css/theme/uno/uno.css +276 -0
  80. data/assets/theme/j1/modules/lightGallery/css/theme/uno/uno.min.css +17 -0
  81. data/assets/theme/j1/modules/lightGallery/js/lightgallery.js +163 -120
  82. data/assets/theme/j1/modules/lightGallery/js/lightgallery.min.js +6 -6
  83. data/assets/theme/j1/modules/lightGallery/js/plugins/j1/lg-thumbnail.0.js +495 -0
  84. data/assets/theme/j1/modules/lightGallery/js/plugins/j1/lg-thumbnail.1.js +513 -0
  85. data/assets/theme/j1/modules/lightGallery/js/plugins/j1/lg-video.0.js +553 -0
  86. data/assets/theme/j1/modules/lightGallery/js/plugins/j1/lg-video.1.js +1 -1
  87. data/assets/theme/j1/modules/lightGallery/js/plugins/j1/lg-video.2.js +914 -0
  88. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-autoplay.js +4 -4
  89. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-autoplay.min.js +5 -5
  90. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-comment.js +5 -5
  91. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-comment.min.js +6 -6
  92. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-fullscreen.js +4 -4
  93. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-fullscreen.min.js +5 -5
  94. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-hash.js +4 -4
  95. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-hash.min.js +5 -6
  96. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-medium-zoom.js +5 -5
  97. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-medium-zoom.min.js +6 -6
  98. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-pager.js +4 -4
  99. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-pager.min.js +5 -5
  100. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-relative-caption.js +179 -0
  101. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-relative-caption.min.js +32 -0
  102. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-rotate.js +4 -4
  103. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-rotate.min.js +6 -6
  104. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-share.js +4 -4
  105. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-share.min.js +6 -7
  106. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-thumbnail.js +27 -20
  107. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-thumbnail.min.js +5 -5
  108. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-video.js +77 -125
  109. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-video.min.js +6 -6
  110. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-vimeo-thumbnail.js +4 -4
  111. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-vimeo-thumbnail.min.js +5 -5
  112. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-zoom.js +11 -5
  113. data/assets/theme/j1/modules/lightGallery/js/plugins/lg-zoom.min.js +5 -5
  114. data/assets/theme/j1/modules/themeSwitcher/js/switcher.js +13 -12
  115. data/assets/theme/j1/modules/videoPlayer/tiktoc/README.md +1 -0
  116. data/assets/theme/j1/modules/videojs/!v8.12.0/css/font/README.md +151 -0
  117. data/assets/theme/j1/modules/videojs/!v8.12.0/css/font/VideoJS.svg +150 -0
  118. data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/city.css +147 -0
  119. data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/city.min.css +5 -0
  120. data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/fantasy.css +113 -0
  121. data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/fantasy.min.css +5 -0
  122. data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/forest.css +166 -0
  123. data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/forest.min.css +5 -0
  124. data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/sea.css +72 -0
  125. data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/sea.min.css +5 -0
  126. data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/uno.css +311 -0
  127. data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/uno.min.css +19 -0
  128. data/assets/theme/j1/modules/videojs/!v8.12.0/css/videojs.css +1686 -0
  129. data/assets/theme/j1/modules/videojs/!v8.12.0/css/videojs.min.css +13 -0
  130. data/assets/theme/j1/modules/videojs/!v8.12.0/js/video.js +65226 -0
  131. data/assets/theme/j1/modules/videojs/!v8.12.0/js/video.min.js +55 -0
  132. data/assets/theme/j1/modules/videojs/assets/README.md +1 -0
  133. data/assets/theme/j1/modules/videojs/assets/icons/speedometer-medium.svg +35 -0
  134. data/assets/theme/j1/modules/videojs/css/font/VideoJS.ttf +0 -0
  135. data/assets/theme/j1/modules/videojs/css/font/VideoJS.woff +0 -0
  136. data/assets/theme/j1/modules/videojs/css/themes/uno.css +157 -22
  137. data/assets/theme/j1/modules/videojs/css/themes/uno.min.css +1 -1
  138. data/assets/theme/j1/modules/videojs/css/videojs.css +674 -316
  139. data/assets/theme/j1/modules/videojs/css/videojs.min.css +4 -3
  140. data/assets/theme/j1/modules/videojs/js/video.js +15893 -12288
  141. data/assets/theme/j1/modules/videojs/js/video.min.js +22 -23
  142. data/assets/theme/j1/modules/videojs/plugins/controls/aspect-ratio-panel/!examples/index.html +31 -0
  143. data/assets/theme/j1/modules/videojs/plugins/controls/aspect-ratio-panel/LICENSE +19 -0
  144. data/assets/theme/j1/modules/videojs/plugins/controls/aspect-ratio-panel/README.md +69 -0
  145. data/assets/theme/j1/modules/videojs/plugins/controls/aspect-ratio-panel/css/aspect-ratio-panel.css +2 -0
  146. data/assets/theme/j1/modules/videojs/plugins/controls/aspect-ratio-panel/css/aspect-ratio-panel.min.css +2 -0
  147. data/assets/theme/j1/modules/videojs/plugins/controls/aspect-ratio-panel/js/aspect-ratio-panel.js +339 -0
  148. data/assets/theme/j1/modules/videojs/plugins/controls/aspect-ratio-panel/js/aspect-ratio-panel.min.js +2 -0
  149. data/assets/theme/j1/modules/videojs/{js/plugins/controls/autocaption → plugins/controls/autocaption/js}/autocaption.js +0 -5
  150. data/assets/theme/j1/modules/videojs/plugins/controls/persist-settings/!examples/index.html +29 -0
  151. data/assets/theme/j1/modules/videojs/plugins/controls/persist-settings/LICENSE +19 -0
  152. data/assets/theme/j1/modules/videojs/plugins/controls/persist-settings/README.md +90 -0
  153. data/assets/theme/j1/modules/videojs/plugins/controls/persist-settings/js/videojs-persist.js +120 -0
  154. data/assets/theme/j1/modules/videojs/plugins/controls/persist-settings/js/videojs-persist.min.js +2 -0
  155. data/assets/theme/j1/modules/videojs/plugins/controls/playbackrate-adjuster/!examples/index.html +37 -0
  156. data/assets/theme/j1/modules/videojs/plugins/controls/playbackrate-adjuster/LICENSE +19 -0
  157. data/assets/theme/j1/modules/videojs/plugins/controls/playbackrate-adjuster/README.md +61 -0
  158. data/assets/theme/j1/modules/videojs/plugins/controls/playbackrate-adjuster/js/playbackrate-adjuster.js +94 -0
  159. data/assets/theme/j1/modules/videojs/plugins/controls/playbackrate-adjuster/js/playbackrate-adjuster.min.js +20 -0
  160. data/assets/theme/j1/modules/videojs/{js/plugins → plugins}/controls/skipbuttons/README.md +25 -11
  161. data/assets/theme/j1/modules/videojs/{css/plugins/controls → plugins/controls/zoom/css}/zoom.css +7 -6
  162. data/assets/theme/j1/modules/videojs/plugins/controls/zoom/css/zoom.min.css +22 -0
  163. data/assets/theme/j1/modules/videojs/{js/plugins/players/dm → plugins/players/dm/js}/dailymotion.js +1 -1
  164. data/assets/theme/j1/modules/videojs/plugins/players/vm/!unused/vimeo.0.js +521 -0
  165. data/assets/theme/j1/modules/videojs/plugins/players/vm/!unused/vimeo.1.js +605 -0
  166. data/assets/theme/j1/modules/videojs/plugins/players/vm/!unused/vimeo.3.js +643 -0
  167. data/assets/theme/j1/modules/videojs/plugins/players/vm/!unused/vimeo.4.js +583 -0
  168. data/assets/theme/j1/modules/videojs/plugins/players/vm/!unused/vimeo.5.js +665 -0
  169. data/assets/theme/j1/modules/videojs/plugins/players/vm/!unused/vimeo.6.js +642 -0
  170. data/assets/theme/j1/modules/videojs/plugins/players/vm/!unused/vimeo.7.js +673 -0
  171. data/assets/theme/j1/modules/videojs/{js/plugins/players/vm/api → plugins/players/vm/api/js}/vimeo.js +1 -1
  172. data/assets/theme/j1/modules/videojs/{js/plugins/players/vm/api → plugins/players/vm/api/js}/vimeo.min.js +1 -1
  173. data/assets/theme/j1/modules/videojs/{js/plugins/players/vm → plugins/players/vm/js}/vimeo.js +4 -5
  174. data/assets/theme/j1/modules/videojs/plugins/players/vm/js/vimeo.min.js +28 -0
  175. data/assets/theme/j1/modules/videojs/plugins/players/wt/!unused/wistia.0.js +395 -0
  176. data/assets/theme/j1/modules/videojs/plugins/players/wt/!unused/wistia.1.js +401 -0
  177. data/lib/j1/version.rb +1 -1
  178. data/lib/starter_web/README.md +5 -5
  179. data/lib/starter_web/_config.yml +1 -1
  180. data/lib/starter_web/_data/modules/amplitude_playlists.yml +16 -1
  181. data/lib/starter_web/_data/modules/defaults/gallery.yml +3 -3
  182. data/lib/starter_web/_data/modules/gallery.yml +83 -87
  183. data/lib/starter_web/_data/modules/navigator_menu.yml +3 -3
  184. data/lib/starter_web/_data/resources.yml +16 -12
  185. data/lib/starter_web/_data/templates/feed.xml +1 -1
  186. data/lib/starter_web/_plugins/asciidoctor/videojs-block.rb +50 -30
  187. data/lib/starter_web/_plugins/asciidoctor/youtube-block.rb +37 -23
  188. data/lib/starter_web/_plugins/index/lunr.rb +1 -1
  189. data/lib/starter_web/assets/video/poster/vimeo/fall_2011.jpg +0 -0
  190. data/lib/starter_web/package.json +1 -1
  191. data/lib/starter_web/pages/public/tools/tester/videojs_macro_tester.adoc +282 -0
  192. data/lib/starter_web/pages/public/tour/video_data.adoc +1 -0
  193. metadata +221 -106
  194. data/assets/data/swiper_app.2.html +0 -757
  195. data/assets/data/swiper_app.4.html +0 -769
  196. data/assets/theme/j1/modules/videojs/css/plugins/controls/skipbuttons.0.css +0 -32
  197. data/assets/theme/j1/modules/videojs/css/plugins/controls/skipbuttons.1.css +0 -31
  198. data/assets/theme/j1/modules/videojs/css/plugins/controls/zoom.min.css +0 -21
  199. data/assets/theme/j1/modules/videojs/js/plugins/players/vm/vimeo.min.js +0 -16
  200. data/assets/theme/j1/modules/videojs/js/plugins/players/wt/api/src/WistiaPlayer.ts +0 -1617
  201. data/lib/starter_web/assets/video/poster/vimeo/stay_colorful.jpg +0 -0
  202. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/animation-w.png +0 -0
  203. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/customize-w.png +0 -0
  204. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/dynamic-w.png +0 -0
  205. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/facebook-icon.svg +0 -0
  206. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/googleplus-icon.svg +0 -0
  207. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/html5-w.png +0 -0
  208. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/linked-in.png +0 -0
  209. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/module-w.png +0 -0
  210. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/play-button-hover.svg +0 -0
  211. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/play-button.png +0 -0
  212. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/play-button.svg +0 -0
  213. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/responsive-w.png +0 -0
  214. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/thumb-w.png +0 -0
  215. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/touch-w.png +0 -0
  216. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/twitter-icon.svg +0 -0
  217. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/twitter.png +0 -0
  218. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/video1-w.png +0 -0
  219. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/zoom-w.png +0 -0
  220. /data/assets/theme/j1/modules/lightGallery/{css → !v2.7.2/css}/themes/uno/icons/zoom.png +0 -0
  221. /data/assets/theme/j1/modules/lightGallery/{js → !v2.7.2/js}/plugins/j1/j1-video.js +0 -0
  222. /data/assets/theme/j1/modules/lightGallery/{js → !v2.7.2/js}/plugins/j1/j1-video.min.js +0 -0
  223. /data/assets/theme/j1/modules/videoPlayer/dailymotion/js/{!readme → README.md} +0 -0
  224. /data/assets/theme/j1/modules/videoPlayer/tiktoc/{js/player.min.js → player.min.js} +0 -0
  225. /data/assets/theme/j1/modules/videoPlayer/vimeo/js/{!readme → README.md} +0 -0
  226. /data/assets/theme/j1/modules/videoPlayer/wistia/js/{!readme → README.md} +0 -0
  227. /data/assets/theme/j1/modules/videojs/{css → !v8.12.0/css}/font/video-js-cdn.css +0 -0
  228. /data/assets/theme/j1/modules/videojs/{js/plugins → plugins}/controls/autocaption/LICENSE +0 -0
  229. /data/assets/theme/j1/modules/videojs/{js/plugins → plugins}/controls/autocaption/README.md +0 -0
  230. /data/assets/theme/j1/modules/videojs/{js/plugins/controls/autocaption → plugins/controls/autocaption/js}/autocaption.min.js +0 -0
  231. /data/assets/theme/j1/modules/videojs/{js/plugins/controls/hotkeys/examples → plugins/controls/hotkeys/!examples}/example.html +0 -0
  232. /data/assets/theme/j1/modules/videojs/{js/plugins → plugins}/controls/hotkeys/LICENSE.md +0 -0
  233. /data/assets/theme/j1/modules/videojs/{js/plugins → plugins}/controls/hotkeys/README.md +0 -0
  234. /data/assets/theme/j1/modules/videojs/{js/plugins/controls/hotkeys → plugins/controls/hotkeys/js}/hotkeys.js +0 -0
  235. /data/assets/theme/j1/modules/videojs/{js/plugins/controls/hotkeys → plugins/controls/hotkeys/js}/hotkeys.min.js +0 -0
  236. /data/assets/theme/j1/modules/videojs/{css/plugins/controls → plugins/controls/skipbuttons/css}/skipbuttons.css +0 -0
  237. /data/assets/theme/j1/modules/videojs/{css/plugins/controls → plugins/controls/skipbuttons/css}/skipbuttons.min.css +0 -0
  238. /data/assets/theme/j1/modules/videojs/{js/plugins/controls/skipbuttons → plugins/controls/skipbuttons/js}/skipbuttons.js +0 -0
  239. /data/assets/theme/j1/modules/videojs/{js/plugins/controls/skipbuttons → plugins/controls/skipbuttons/js}/skipbuttons.min.js +0 -0
  240. /data/assets/theme/j1/modules/videojs/{js/plugins/controls/zoom/examples → plugins/controls/zoom/!examples}/index.html +0 -0
  241. /data/assets/theme/j1/modules/videojs/{js/plugins/controls/zoom/examples → plugins/controls/zoom/!examples}/index.js +0 -0
  242. /data/assets/theme/j1/modules/videojs/{js/plugins/controls/zoom/examples → plugins/controls/zoom/!examples}/styles.css +0 -0
  243. /data/assets/theme/j1/modules/videojs/{js/plugins → plugins}/controls/zoom/LICENSE.md +0 -0
  244. /data/assets/theme/j1/modules/videojs/{js/plugins → plugins}/controls/zoom/README.md +0 -0
  245. /data/assets/theme/j1/modules/videojs/{js/plugins/controls/zoom → plugins/controls/zoom/js}/zoom.js +0 -0
  246. /data/assets/theme/j1/modules/videojs/{js/plugins/controls/zoom → plugins/controls/zoom/js}/zoom.min.js +0 -0
  247. /data/assets/theme/j1/modules/videojs/{js/plugins/players/dm/examples → plugins/players/dm/!examples}/dailymotion-controls.html +0 -0
  248. /data/assets/theme/j1/modules/videojs/{js/plugins/players/dm/examples → plugins/players/dm/!examples}/dailymotion-javascript.html +0 -0
  249. /data/assets/theme/j1/modules/videojs/{js/plugins/players/dm/examples → plugins/players/dm/!examples}/dailymotion-playlist.html +0 -0
  250. /data/assets/theme/j1/modules/videojs/{js/plugins/players/dm/examples → plugins/players/dm/!examples}/global-parameters.html +0 -0
  251. /data/assets/theme/j1/modules/videojs/{js/plugins/players/dm/examples → plugins/players/dm/!examples}/simple.html +0 -0
  252. /data/assets/theme/j1/modules/videojs/{js/plugins/players/dm/examples → plugins/players/dm/!examples}/switch.html +0 -0
  253. /data/assets/theme/j1/modules/videojs/{js/plugins → plugins}/players/dm/LICENSE +0 -0
  254. /data/assets/theme/j1/modules/videojs/{js/plugins/players/dm/doc → plugins/players/dm}/README.md +0 -0
  255. /data/assets/theme/j1/modules/videojs/{js/plugins → plugins}/players/dm/api/LICENSE +0 -0
  256. /data/assets/theme/j1/modules/videojs/{js/plugins/players/dm/api/doc → plugins/players/dm/api}/README.md +0 -0
  257. /data/assets/theme/j1/modules/videojs/{js/plugins/players/dm/api → plugins/players/dm/api/js}/dailymotion.sdk.js +0 -0
  258. /data/assets/theme/j1/modules/videojs/{js/plugins/players/dm/api → plugins/players/dm/api/js}/dailymotion.sdk.min.js +0 -0
  259. /data/assets/theme/j1/modules/videojs/{js/plugins → plugins}/players/dm/icon/scalable/dailymotion.svg +0 -0
  260. /data/assets/theme/j1/modules/videojs/{js/plugins/players/dm → plugins/players/dm/js}/dailymotion.min.js +0 -0
  261. /data/assets/theme/j1/modules/videojs/{js/plugins/players/vm/examples → plugins/players/vm/!examples}/index.html +0 -0
  262. /data/assets/theme/j1/modules/videojs/{js/plugins/players/vm/examples → plugins/players/vm/!examples}/player/index.html +0 -0
  263. /data/assets/theme/j1/modules/videojs/{js/plugins → plugins}/players/vm/LICENSE +0 -0
  264. /data/assets/theme/j1/modules/videojs/{js/plugins/players/vm/doc → plugins/players/vm}/README.md +0 -0
  265. /data/assets/theme/j1/modules/videojs/{js/plugins/players/vm/api/doc → plugins/players/vm/api}/README.md +0 -0
  266. /data/assets/theme/j1/modules/videojs/{js/plugins → plugins}/players/vm/api/css/embed.player.css +0 -0
  267. /data/assets/theme/j1/modules/videojs/{js/plugins → plugins}/players/vm/api/css/embed.player.uno.css +0 -0
  268. /data/assets/theme/j1/modules/videojs/{js/plugins → plugins}/players/vm/api/css/player.css +0 -0
  269. /data/assets/theme/j1/modules/videojs/{js/plugins/players/wt/doc → plugins/players/wt}/README.md +0 -0
  270. /data/assets/theme/j1/modules/videojs/{js/plugins/players/wt/api/doc/Readme.txt → plugins/players/wt/api/README.md} +0 -0
  271. /data/assets/theme/j1/modules/videojs/{js/plugins/players/wt/api → plugins/players/wt/api/js}/wistia.min.js +0 -0
  272. /data/assets/theme/j1/modules/videojs/{js/plugins/players/wt → plugins/players/wt/js}/wistia.js +0 -0
  273. /data/assets/theme/j1/modules/videojs/{js/plugins/players/wt → plugins/players/wt/js}/wistia.min.js +0 -0
  274. /data/assets/theme/j1/modules/videojs/{js/plugins/players/yt/examples → plugins/players/yt/!examples}/global-parameters.html +0 -0
  275. /data/assets/theme/j1/modules/videojs/{js/plugins/players/yt/examples → plugins/players/yt/!examples}/simple.html +0 -0
  276. /data/assets/theme/j1/modules/videojs/{js/plugins/players/yt/examples → plugins/players/yt/!examples}/switch.html +0 -0
  277. /data/assets/theme/j1/modules/videojs/{js/plugins/players/yt/examples → plugins/players/yt/!examples}/youtube-controls.html +0 -0
  278. /data/assets/theme/j1/modules/videojs/{js/plugins/players/yt/examples → plugins/players/yt/!examples}/youtube-javascript.html +0 -0
  279. /data/assets/theme/j1/modules/videojs/{js/plugins/players/yt/examples → plugins/players/yt/!examples}/youtube-list.html +0 -0
  280. /data/assets/theme/j1/modules/videojs/{js/plugins/players/yt/examples → plugins/players/yt/!examples}/youtube-playlist.html +0 -0
  281. /data/assets/theme/j1/modules/videojs/{js/plugins/players/yt/v3.0.0 → plugins/players/yt/!v3.0.0}/youtube.js +0 -0
  282. /data/assets/theme/j1/modules/videojs/{js/plugins/players/yt/v3.0.0 → plugins/players/yt/!v3.0.0}/youtube.min.js +0 -0
  283. /data/assets/theme/j1/modules/videojs/{js/plugins → plugins}/players/yt/LICENSE +0 -0
  284. /data/assets/theme/j1/modules/videojs/{js/plugins/players/yt/doc → plugins/players/yt}/README.md +0 -0
  285. /data/assets/theme/j1/modules/videojs/{js/plugins/players/yt/api → plugins/players/yt/api/js}/youtube.min.js +0 -0
  286. /data/assets/theme/j1/modules/videojs/{js/plugins/players/yt → plugins/players/yt/js}/youtube.js +0 -0
  287. /data/assets/theme/j1/modules/videojs/{js/plugins/players/yt → plugins/players/yt/js}/youtube.min.js +0 -0
@@ -0,0 +1,605 @@
1
+ /*
2
+ # -----------------------------------------------------------------------------
3
+ # ~/assets/theme/j1/modules/videojs/js/vimeo/vimeo.js
4
+ # Provides Vimeo Playback Technology (Tech) for Video.js V8 and newer
5
+ #
6
+ # Product/Info:
7
+ # http://jekyll.one
8
+ #
9
+ # Copyright (C) 2023-2025 Juergen Adams
10
+ #
11
+ # J1 Theme is licensed under MIT License.
12
+ # See: https://github.com/jekyll-one-org/j1-template/blob/main/LICENSE
13
+ # -----------------------------------------------------------------------------
14
+ */
15
+
16
+ /* global define, VM */
17
+ (function (root, factory) {
18
+ if(typeof exports==='object' && typeof module!=='undefined') {
19
+ var videojs = require('video.js');
20
+ module.exports = factory(videojs.default || videojs);
21
+ } else if(typeof define === 'function' && define.amd) {
22
+ define(['videojs'], function(videojs){
23
+ return (root.Vimeo = factory(videojs));
24
+ });
25
+ } else {
26
+ root.Vimeo = factory(root.videojs);
27
+ }
28
+ }(this, function(videojs) {
29
+ 'use strict';
30
+
31
+ var logger = log4javascript.getLogger('videoJS.plugin.vimeo');
32
+ var _isOnMobile = videojs.browser.IS_IOS || videojs.browser.IS_ANDROID;
33
+ var Tech = videojs.getTech('Tech');
34
+ var cssInjected = false;
35
+
36
+ var startTimeModule;
37
+ var endTimeModule;
38
+
39
+ class Vimeo extends Tech {
40
+
41
+ /**
42
+ * Vimeo - Wrapper for Video Player API
43
+ *
44
+ * @param {Object=} options Object of option names and values
45
+ * @param {Function=} ready Ready callback function
46
+ * @extends Tech
47
+ * @class Vimeo
48
+ */
49
+ constructor(options, ready) {
50
+ super(options, ready);
51
+
52
+ // jadams: enable VJS controlbar
53
+ var divElement = document.getElementById(options.playerId);
54
+ divElement.classList.remove("vjs-controls-disabled");
55
+
56
+ this.setPoster(options.poster);
57
+
58
+ // Set the vjs-vimeo class on the player PARENT node.
59
+ // When not set, yet so we have to wait a tick
60
+ var vm = this;
61
+ setTimeout(function() {
62
+ if (this.el_) {
63
+ this.el_.parentNode.className += ' vjs-vimeo';
64
+
65
+ if (_isOnMobile) {
66
+ this.el_.parentNode.className += ' vjs-vimeo-mobile';
67
+ }
68
+
69
+ if (Vimeo.isSdkReady) {
70
+ vm.initVMPlayer();
71
+ } else {
72
+ Vimeo.sdkReadyQueue.push(vm);
73
+ }
74
+ }
75
+ }.bind(this));
76
+
77
+ } // END Constructor
78
+
79
+
80
+ initVMPlayer() {
81
+ const vimeoOptions = {
82
+ url: this.options_.source.src,
83
+ byline: false,
84
+ controls: false,
85
+ portrait: false,
86
+ title: false
87
+ };
88
+
89
+ if (this.options_.autoplay) {
90
+ vimeoOptions.autoplay = true;
91
+ }
92
+ if (this.options_.height) {
93
+ vimeoOptions.height = this.options_.height;
94
+ }
95
+ if (this.options_.width) {
96
+ vimeoOptions.width = this.options_.width;
97
+ }
98
+ if (this.options_.maxheight) {
99
+ vimeoOptions.maxheight = this.options_.maxheight;
100
+ }
101
+ if (this.options_.maxwidth) {
102
+ vimeoOptions.maxwidth = this.options_.maxwidth;
103
+ }
104
+ if (this.options_.loop) {
105
+ vimeoOptions.loop = this.options_.loop;
106
+ }
107
+ if (this.options_.color) {
108
+ // vimeo is the only API on earth to reject hex color with leading #
109
+ vimeoOptions.color = this.options_.color.replace(/^#/, '');
110
+ }
111
+
112
+ this.vmPlayer = new VM.Player(this.el(), vimeoOptions);
113
+ this.initVimeoState();
114
+
115
+ // setup API events
116
+ var apiEvents = [
117
+ 'play', 'playing', 'pause', 'ended', 'loaded',
118
+ 'timeupdate', 'progress', 'seeking', 'seeked',
119
+ 'ready'
120
+ ];
121
+ apiEvents.forEach(e => {
122
+ this.vmPlayer.on(e, (progress) => {
123
+ if (this._vimeoState.progress.duration !== progress.duration) {
124
+ this.trigger('durationchange');
125
+ }
126
+ this._vimeoState.progress = progress;
127
+ this.trigger(e);
128
+ });
129
+
130
+ this.vmPlayer.on(e, (ready) => {
131
+ this.vmPlayer.getVideoEmbedCode()
132
+ .then (function(embedCode) {
133
+ var code = embedCode
134
+ })
135
+ .catch(function(error) {
136
+ console.err('Vimeo API: an error occurred');
137
+ });
138
+ });
139
+
140
+ this.vmPlayer.on(e, (timeupdate) => {
141
+ if (this._vimeoState.progress.duration !== progress.duration) {
142
+ this.trigger('durationchange');
143
+ }
144
+ this._vimeoState.progress = progress;
145
+ this.trigger(e);
146
+ });
147
+
148
+ this.vmPlayer.on('pause', () => this._vimeoState.playing = false);
149
+
150
+ this.vmPlayer.on('play', () => {
151
+ this._vimeoState.playing = true;
152
+ this._vimeoState.ended = false;
153
+ });
154
+ }); // END forEach apiEvents
155
+
156
+
157
+
158
+
159
+ this.vmPlayer.on('ended', () => {
160
+ this._vimeoState.playing = false;
161
+ this._vimeoState.ended = true;
162
+ });
163
+
164
+ this.vmPlayer.on('volumechange', (v) => this._vimeoState.volume = v);
165
+ this.vmPlayer.on('error', e => this.trigger('error', e));
166
+
167
+ this.triggerReady();
168
+
169
+ logger.debug('\n' + 'created player ID on: ' + this.vmPlayer.element.id);
170
+ } // END initVMPlayer
171
+
172
+ initVimeoState() {
173
+ const state = this._vimeoState = {
174
+ ended: false,
175
+ playing: false,
176
+ muted: false,
177
+ volume: 0,
178
+ progress: {
179
+ seconds: 0,
180
+ percent: 0,
181
+ duration: 0
182
+ }
183
+ };
184
+
185
+ this.vmPlayer.getCurrentTime().then(time => state.progress.seconds = time);
186
+ this.vmPlayer.getDuration().then(time => state.progress.duration = time);
187
+ this.vmPlayer.getPaused().then(paused => state.playing = !paused);
188
+ this.vmPlayer.getVolume().then(volume => state.volume = volume);
189
+ } // END initVimeoState
190
+
191
+ createEl() {
192
+ // jadams: videojs.createEl() is deprecated
193
+ // const div = videojs.createEl('div', {
194
+ const div = videojs.dom.createEl('div', {
195
+ id: this.options_.techId
196
+ });
197
+
198
+ div.style.cssText = 'width:100%;height:100%;top:0;left:0;position:absolute';
199
+ div.className = 'vjs-vimeo';
200
+
201
+ return div;
202
+ } // END createEl
203
+
204
+ controls() {
205
+ return true;
206
+ } // END controls
207
+
208
+ supportsFullScreen() {
209
+ return true;
210
+ } // END supportsFullScreen
211
+
212
+ src() {
213
+ // @note: Not sure why this is needed but videojs requires it
214
+ return this.options_.source;
215
+ // return '//player.vimeo.com/api/player.js';
216
+ } // END
217
+
218
+ currentSrc() {
219
+ return this.options_.source.src;
220
+ } // END currentSrc
221
+
222
+ volume() {
223
+ // return this._vimeoState.volume;
224
+ this.vmPlayer.getVolume().then((volume) => {
225
+ // volume = the volume level of the player
226
+ return volume;
227
+ }).catch(function(error) {
228
+ // an error occurred
229
+ });
230
+ } // END volume
231
+
232
+ setVolume(volume) {
233
+ // return this.vmPlayer.setVolume(volume);
234
+
235
+ this.vmPlayer.setVolume(volume).then((volume) => {
236
+ // volume was set
237
+ this.trigger('volumechange');
238
+ return volume;
239
+ }).catch(function(error) {
240
+ switch (error.name) {
241
+ case 'RangeError':
242
+ // the volume was less than 0 or greater than 1
243
+ break;
244
+ default:
245
+ // some other error occurred
246
+ break;
247
+ }
248
+ });
249
+ } // END setVolume
250
+
251
+ muted() {} // END muted
252
+
253
+ setMuted(mute) {
254
+ var isMuted = !this._vimeoState.muted; // toggle mute state
255
+ var _this = this;
256
+
257
+ this.vmPlayer.setMuted(isMuted).then((muted) => {
258
+
259
+ _this._vimeoState.muted = muted;
260
+ return muted;
261
+ }).catch(function(error) {
262
+ // an error occurred
263
+ });
264
+ }
265
+
266
+ buffered() {
267
+ const progress = this._vimeoState.progress;
268
+
269
+ return videojs.time.createTimeRanges(0, progress.percent * progress.duration);
270
+ } // END
271
+
272
+ paused() {
273
+ return !this._vimeoState.playing;
274
+ } // END
275
+
276
+ pause() {
277
+ this.vmPlayer.pause();
278
+ } // END
279
+
280
+ play() {
281
+ this.vmPlayer.play();
282
+ } // END
283
+
284
+ ended() {
285
+ return this._vimeoState.ended;
286
+ } // END
287
+
288
+
289
+ // currentTime() {
290
+ // return this._vimeoState.progress.seconds;
291
+ // } // END
292
+ //
293
+ // setCurrentTime(time) {
294
+ // // this.vmPlayer.setCurrentTime(time);
295
+ // this.vmPlayer.setCurrentTime(30.456).then(function(seconds) {
296
+ // // seconds = the actual time that the player seeked to
297
+ // var currentTime = seconds
298
+ // }).catch(function(error) {
299
+ // switch (error.name) {
300
+ // case 'RangeError':
301
+ // // the time was less than 0 or greater than the video’s duration
302
+ // break;
303
+ // default:
304
+ // // some other error occurred
305
+ // break;
306
+ // }
307
+ // });
308
+ // } // END setCurrentTime
309
+
310
+ // currentTime() {
311
+ // var currentTime = this.vmPlayer ? this.vmPlayer.getCurrentTime() : 0;
312
+ // return currentTime;
313
+ // }
314
+
315
+ currentTime() {
316
+ this.vmPlayer.getCurrentTime().then(function(seconds) {
317
+ // seconds = the current playback position
318
+ return seconds;
319
+ }).catch(function(error) {
320
+ // an error occurred
321
+ });
322
+ }
323
+
324
+ setCurrentTime(seconds) {
325
+ if (this.lastState === vmPlayer.getPaused()) {
326
+ this.timeBeforeSeek = this.currentTime();
327
+ }
328
+
329
+ if (!this.isSeeking) {
330
+ this.wasPausedBeforeSeek = this.paused();
331
+ }
332
+
333
+ this.vmPlayer.seekTo(seconds, true);
334
+ this.trigger('timeupdate');
335
+ this.trigger('seeking');
336
+ this.isSeeking = true;
337
+
338
+ // A seek event during pause does not return an event to trigger a seeked event,
339
+ // so run an interval timer to look for the currentTime to change
340
+ if (this.lastState === vmPlayer.getPaused() && this.timeBeforeSeek !== seconds) {
341
+ clearInterval(this.checkSeekedInPauseInterval);
342
+ this.checkSeekedInPauseInterval = setInterval(function() {
343
+ if (this.lastState !== vmPlayer.getPaused() || !this.isSeeking) {
344
+ // If something changed while we were waiting for the currentTime to change,
345
+ // clear the interval timer
346
+ clearInterval(this.checkSeekedInPauseInterval);
347
+ } else if (this.currentTime() !== this.timeBeforeSeek) {
348
+ this.trigger('timeupdate');
349
+ this.onSeeked();
350
+ }
351
+ }.bind(this), 250);
352
+ }
353
+ } // END setCurrentTime
354
+
355
+ seeking() {
356
+ return this.isSeeking;
357
+ }
358
+
359
+ // jadams, 2023-10-01: videojs.createTimeRange() deprecated in VideoJS 9
360
+ //
361
+ seekable() {
362
+ if(!this.vmPlayer) {
363
+ // return videojs.createTimeRange();
364
+ return videojs.time.createTimeRanges();
365
+ }
366
+ // return videojs.createTimeRange(0, this.vmPlayer.getDuration());
367
+ return videojs.time.createTimeRanges(0, this.vmPlayer.getDuration());
368
+ }
369
+
370
+ onSeeked() {
371
+ clearInterval(this.checkSeekedInPauseInterval);
372
+ this.isSeeking = false;
373
+
374
+ if (this.wasPausedBeforeSeek) {
375
+ this.pause();
376
+ }
377
+
378
+ this.trigger('seeked');
379
+ }
380
+
381
+ playbackRate() {
382
+ return this.vmPlayer ? this.vmPlayer.getPlaybackRate() : 1;
383
+ }
384
+
385
+ setPlaybackRate(suggestedRate) {
386
+ if (!this.vmPlayer) {
387
+ return;
388
+ }
389
+
390
+ this.vmPlayer.setPlaybackRate(suggestedRate);
391
+ }
392
+
393
+ // duration() {
394
+ // var duration = this.vmPlayer ? this.vmPlayer.getDuration() : 0;
395
+ // return duration;
396
+ // }
397
+
398
+ // duration() {
399
+ // return this._vimeoState.progress.duration;
400
+ // } // END
401
+
402
+ duration() {
403
+ this.vmPlayer.getDuration().then(function(duration) {
404
+ // duration = the duration of the video in seconds
405
+ return duration;
406
+ }).catch(function(error) {
407
+ // an error occurred
408
+ });
409
+ }
410
+
411
+ } // END class Vimeo
412
+
413
+ Vimeo.prototype.featuresTimeupdateEvents = true;
414
+
415
+ Vimeo.isSupported = function() {
416
+ return true;
417
+ };
418
+
419
+ // Add Source Handler pattern functions to this tech
420
+ Tech.withSourceHandlers(Vimeo);
421
+
422
+ Vimeo.nativeSourceHandler = {};
423
+
424
+ /**
425
+ * Check if Vimeo can play the given videotype
426
+ * @param {String} type The mimetype to check
427
+ * @return {String} 'maybe', or '' (empty string)
428
+ */
429
+ Vimeo.nativeSourceHandler.canPlayType = function(source) {
430
+ if (source === 'video/vimeo') {
431
+ return 'maybe';
432
+ }
433
+
434
+ return '';
435
+ };
436
+
437
+ /*
438
+ * Check Vimeo can handle the source natively
439
+ *
440
+ * @param {Object} source The source object
441
+ * @return {String} 'maybe', or '' (empty string)
442
+ * @note: Copied over from YouTube — not sure this is relevant
443
+ */
444
+ Vimeo.nativeSourceHandler.canHandleSource = function(source) {
445
+ if (source.type) {
446
+ return Vimeo.nativeSourceHandler.canPlayType(source.type);
447
+ } else if (source.src) {
448
+ return Vimeo.nativeSourceHandler.canPlayType(source.src);
449
+ }
450
+
451
+ return '';
452
+ };
453
+
454
+ // @note: Copied over from YouTube — not sure this is relevant
455
+ Vimeo.nativeSourceHandler.handleSource = function(source, tech) {
456
+ tech.src(source.src);
457
+ };
458
+
459
+ // @note: Copied over from YouTube — not sure this is relevant
460
+ Vimeo.nativeSourceHandler.dispose = function() { };
461
+
462
+ Vimeo.registerSourceHandler(Vimeo.nativeSourceHandler);
463
+
464
+ // Include the version number
465
+ Vimeo.VERSION = '1.0.0';
466
+
467
+ Vimeo.sdkReadyQueue = [];
468
+
469
+ // Since the iframe can't be touched using Vimeo's way of embedding,
470
+ // let's add a new styling rule to have the same style as `vjs-tech`
471
+ //
472
+ function injectCss() {
473
+ if (cssInjected) {
474
+ return;
475
+ }
476
+ cssInjected = true;
477
+
478
+ // const css = `
479
+ // .vjs-vimeo iframe {
480
+ // position: absolute;
481
+ // top: 0;
482
+ // left: 0;
483
+ // width: 100%;
484
+ // height: 100%;
485
+ // }
486
+ // .vjs-vimeo .vjs-iframe-blocker { display: none; }
487
+ // .vjs-vimeo.vjs-user-inactive .vjs-iframe-blocker { display: block; }
488
+ // .vjs-vimeo .vjs-poster { background-size: cover; }'
489
+ // .vjs-vimeo-mobile .vjs-big-play-button { display: none; }
490
+ //
491
+ // .vjs-vimeo .vjs-duration { display: none; }
492
+ // .vjs-vimeo .vjs-remaining-time { display: none; }
493
+ //
494
+ // .vjs-vimeo .vjs-big-play-button { display: block; }
495
+ // .player .vp-player-ui-overlays { display: none !important; }
496
+ // `;
497
+
498
+ const css = `
499
+ .vjs-vimeo iframe {
500
+ position: absolute;
501
+ top: 0;
502
+ left: 0;
503
+ width: 100%;
504
+ height: 100%;
505
+ }
506
+
507
+ .vjs-control-bar { display: block; }
508
+ .vjs-vimeo .vjs-iframe-blocker { display: none; }
509
+ .vjs-vimeo.vjs-user-inactive .vjs-iframe-blocker { display: block; }
510
+ .vjs-vimeo .vjs-poster { background-size: cover; }'
511
+ .vjs-vimeo-mobile .vjs-big-play-button { display: none; }
512
+
513
+ .vjs-vimeo .vjs-duration { display: none; }
514
+ .vjs-vimeo .vjs-remaining-time { display: none; }
515
+ `;
516
+
517
+ const head = document.head || document.getElementsByTagName('head')[0];
518
+ const style = document.createElement('style');
519
+ style.type = 'text/css';
520
+
521
+ if (style.styleSheet) {
522
+ style.styleSheet.cssText = css;
523
+ } else {
524
+ style.appendChild(document.createTextNode(css));
525
+ }
526
+
527
+ logger.debug('\n' + 'added additional CSS styles');
528
+ head.appendChild(style);
529
+ } // END injectCss
530
+
531
+ function apiLoaded() {
532
+ Vimeo.isSdkReady = true;
533
+
534
+ for (var i = 0; i < Vimeo.sdkReadyQueue.length; ++i) {
535
+ Vimeo.sdkReadyQueue[i].initVMPlayer();
536
+ }
537
+ logger.debug('\n' + 'created all players from queue: #' + i);
538
+
539
+ endTimeModule = Date.now();
540
+ logger.debug('\n' + 'initializing plugin: finished');
541
+ logger.debug('\n' + 'plugin initializing time: ' + (endTimeModule-startTimeModule) + 'ms');
542
+ } // END apiLoaded
543
+
544
+ function loadScript(src, callback) {
545
+ var loaded = false;
546
+ var tag = document.createElement('script');
547
+ var firstScriptTag = document.getElementsByTagName('script')[0];
548
+
549
+ if (!firstScriptTag) {
550
+ // when loaded in jest without jsdom setup it doesn't get any element.
551
+ // In jest it doesn't really make sense to do anything, because no one is watching dailymotion in jest
552
+ return;
553
+ }
554
+
555
+ firstScriptTag.parentNode.insertBefore(tag, firstScriptTag);
556
+ tag.onload = function () {
557
+ if (!loaded) {
558
+ loaded = true;
559
+ callback();
560
+ }
561
+ };
562
+
563
+ tag.onreadystatechange = function () {
564
+ if (!loaded && (this.readyState === 'complete' || this.readyState === 'loaded')) {
565
+ loaded = true;
566
+ callback();
567
+ }
568
+ };
569
+
570
+ tag.src = src;
571
+ } // END loadScript
572
+
573
+ // initialize plugin if page ready
574
+ // -------------------------------------------------------------------------
575
+ var dependencies_met_page_ready = setInterval (() => {
576
+ var pageState = $('#content').css("display");
577
+ var pageVisible = (pageState === 'block') ? true : false;
578
+ var j1CoreFinished = (j1.getState() === 'finished') ? true : false;
579
+ var atticFinished = (j1.adapter.attic.getState() == 'finished') ? true : false;
580
+
581
+ if (j1CoreFinished && pageVisible && atticFinished) {
582
+ startTimeModule = Date.now();
583
+
584
+ logger.debug('\n' + 'initializing plugin: started');
585
+ logger.debug('\n' + 'version of videoJS detected: ' + videojs.VERSION);
586
+
587
+ // load script loaded from local because of NemeSpace conflicts (Vimeo -> VM)
588
+ loadScript('/assets/theme/j1/modules/videojs/js/plugins/vm/api/vimeo.min.js', apiLoaded);
589
+ // loadScript('https://player.vimeo.com/api/player.js', apiLoaded);
590
+
591
+ injectCss();
592
+
593
+ clearInterval(dependencies_met_page_ready);
594
+ } // END pageVisible
595
+ }, 10); // END dependencies_met_page_ready
596
+
597
+
598
+ // Check VJS versions to register Wistia TECH
599
+ if (typeof videojs.registerTech !== 'undefined') {
600
+ videojs.registerTech('Vimeo', Vimeo);
601
+ } else {
602
+ console.error('\n' + 'invalid version of videoJS detected: ' + videojs.VERSION);
603
+ }
604
+
605
+ }));