j1-template 2024.3.23 → 2024.3.25
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.
- checksums.yaml +4 -4
- data/assets/data/apps/amplitudehtml +1147 -0
- data/assets/data/apps/gallery.html +342 -0
- data/assets/data/{masonry.html → apps/masonry.html} +22 -9
- data/assets/data/apps/swiper.html +901 -0
- data/assets/data/gallery_app.html +102 -14
- data/assets/data/masonry_app.html +521 -0
- data/assets/theme/j1/adapter/js/gallery.js +13 -2
- data/assets/theme/j1/core/css/themes/unolight/bootstrap.css +29 -0
- data/assets/theme/j1/core/css/themes/unolight/bootstrap.min.css +1 -1
- data/assets/theme/j1/core/css/vendor.css +1 -1
- data/assets/theme/j1/core/css/vendor.min.css +1 -1
- data/assets/theme/j1/modules/lightGallery/css/theme/uno/uno.css +21 -13
- data/assets/theme/j1/modules/lightGallery/css/theme/uno/uno.min.css +1 -2
- data/assets/theme/j1/modules/lightGallery/js/lightgallery.js +48 -28
- data/assets/theme/j1/modules/lightGallery/js/lightgallery.min.js +1 -8
- data/assets/theme/j1/modules/lightGallery/js/plugins/lg-video.js +463 -298
- data/assets/theme/j1/modules/lightGallery/js/plugins/lg-video.min.js +1 -8
- data/assets/theme/j1/modules/rtable/css/theme/uno/rtable.css +11 -1
- data/assets/theme/j1/modules/videojs/css/themes/uno.css +53 -31
- data/assets/theme/j1/modules/videojs/css/themes/uno.min.css +1 -1
- data/assets/theme/j1/modules/videojs/css/videojs.css +2 -3
- data/assets/theme/j1/modules/videojs/css/videojs.min.css +1 -1
- data/assets/theme/j1/modules/videojs/plugins/controls/aspect-ratio-panel/!examples/index.html +4 -9
- data/assets/theme/j1/modules/videojs/plugins/controls/hotkeys/!examples/example.html +1 -1
- data/assets/theme/j1/modules/videojs/plugins/controls/persist-settings/!examples/index.html +3 -7
- data/assets/theme/j1/modules/videojs/plugins/controls/playbackrate-adjuster/!examples/index.html +3 -8
- data/assets/theme/j1/modules/videojs/plugins/controls/zoom/css/zoom.css +55 -55
- data/assets/theme/j1/modules/videojs/plugins/controls/zoom/css/zoom.min.css +2 -1
- data/assets/theme/j1/modules/videojs/plugins/controls/zoom/js/zoom.js +590 -382
- data/assets/theme/j1/modules/videojs/plugins/controls/zoom/js/zoom.min.js +1 -1
- data/assets/theme/j1/modules/videojs/plugins/j1_core/template.min.js +31 -0
- data/assets/theme/j1/modules/videojs/plugins/players/dm/!examples/index.html +32 -0
- data/assets/theme/j1/modules/videojs/plugins/players/dm/js/dailymotion.0.js +647 -0
- data/assets/theme/j1/modules/videojs/plugins/players/dm/js/dailymotion.1.js +653 -0
- data/assets/theme/j1/modules/videojs/plugins/players/vm/!examples/{player → iframe_api}/index.html +6 -6
- data/assets/theme/j1/modules/videojs/plugins/players/vm/!examples/videojs_api/index.html +38 -0
- data/assets/theme/j1/modules/videojs/plugins/players/vm/api/js/v2.21.0/vimeo.js +3562 -0
- data/assets/theme/j1/modules/videojs/plugins/players/vm/api/js/v2.21.0/vimeo.min.js +36 -0
- data/assets/theme/j1/modules/videojs/plugins/players/vm/api/js/vimeo.js +451 -1849
- data/assets/theme/j1/modules/videojs/plugins/players/vm/api/js/vimeo.min.js +2 -14
- data/assets/theme/j1/modules/videojs/plugins/players/vm/js/LICENSE +21 -0
- data/assets/theme/j1/modules/videojs/plugins/players/vm/js/README.md +54 -0
- data/assets/theme/j1/modules/videojs/plugins/players/vm/js/old/vimeo.js +666 -0
- data/assets/theme/j1/modules/videojs/plugins/players/vm/js/old/vimeo.min.js +28 -0
- data/assets/theme/j1/modules/videojs/plugins/players/vm/js/vimeo.js +2318 -548
- data/assets/theme/j1/modules/videojs/plugins/players/vm/js/vimeo.min.js +12 -18
- data/assets/theme/j1/modules/videojs/plugins/players/yt/!examples/index.html +31 -0
- data/assets/theme/j1/modules/videojs/plugins/players/yt/js/youtube.js +12 -5
- data/assets/theme/j1/modules/videojs/plugins/players/yt/js/youtube.min.js +1 -1
- data/lib/j1/version.rb +1 -1
- data/lib/starter_web/Gemfile +1 -1
- data/lib/starter_web/README.md +5 -5
- data/lib/starter_web/_config.yml +2 -2
- data/lib/starter_web/_data/blocks/banner.yml +3 -3
- data/lib/starter_web/_data/j1_config.yml +1 -1
- data/lib/starter_web/_data/layouts/home.yml +1 -1
- data/lib/starter_web/_data/modules/attics.yml +11 -0
- data/lib/starter_web/_data/modules/authentication.yml +1 -2
- data/lib/starter_web/_data/modules/carousel.yml +1 -1
- data/lib/starter_web/_data/modules/defaults/masonry.yml +116 -23
- data/lib/starter_web/_data/modules/gallery.yml +197 -238
- data/lib/starter_web/_data/modules/log4javascript.yml +1 -1
- data/lib/starter_web/_data/modules/masonry.yml +36 -14
- data/lib/starter_web/_data/modules/navigator.yml +1 -1
- data/lib/starter_web/_data/modules/navigator_menu.yml +12 -8
- data/lib/starter_web/_data/templates/feed.xml +1 -1
- data/lib/starter_web/_includes/attributes.asciidoc +7 -0
- data/lib/starter_web/_plugins/asciidoctor/dailymotion-block.rb +206 -24
- data/lib/starter_web/_plugins/index/lunr.rb +1 -1
- data/lib/starter_web/assets/image/module/attic/1920x1280/admin-dashboard-bootstrap.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/alexander-redl.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/alexander-shatov.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/alexey-ruban.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/andrea-badino.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/bootstrap-modal.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/bp-miller.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/brad-neathery.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/brigitta-schneiter.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/build-with-gemini.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/clem-onojeghuo.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/crawford-jolly.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/eleni-afiontzi.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/fly-d.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/guillaume-bolduc.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/ideas-start-here-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/isaac-davis.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/j1-launch.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/j1-mockup.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/john-schnobrich-2.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/josep-martins.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/josh-liu.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/kelly-sikkemal.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/kira-auf-der-heide.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/kristopher-roller.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/markus-spiske.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/martin-sanchez.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/material_symbols.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/matthaeus.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/melanie-deziel.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/milad-fakurian.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/mohammad-rahmani.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/nasa.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/quino-al-2.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/stories-ink-tattoo-care.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/towfiqu-barbhuiya.jpg +0 -0
- data/lib/starter_web/assets/image/page/tour/bootswatch-themes.jpg +0 -0
- data/lib/starter_web/collections/posts/public/featured/_posts/0000-00-00-welcome-to-j1.adoc.erb +1 -1
- data/lib/starter_web/collections/posts/public/featured/_posts/2022-02-01-about-j1.adoc +2 -2
- data/lib/starter_web/collections/posts/public/featured/_posts/2023-10-18-url-types.adoc +2 -2
- data/lib/starter_web/config.ru +1 -1
- data/lib/starter_web/dot.gitattributes +1 -1
- data/lib/starter_web/index.html +8 -7
- data/lib/starter_web/package.json +1 -1
- data/lib/starter_web/pages/public/about/features.adoc +5 -5
- data/lib/starter_web/pages/public/about/reporting_issues.adoc +5 -5
- data/lib/starter_web/pages/public/about/site.adoc +14 -10
- data/lib/starter_web/pages/public/asciidoc_skeletons/documentation/000_intro.adoc +1 -1
- data/lib/starter_web/pages/public/asciidoc_skeletons/documentation/100_converter.adoc +1 -1
- data/lib/starter_web/pages/public/asciidoc_skeletons/documentation/200_themes.adoc +1 -1
- data/lib/starter_web/pages/public/asciidoc_skeletons/documentation/documentation.adoc +1 -1
- data/lib/starter_web/pages/public/asciidoc_skeletons/multi-document/multi.adoc +1 -1
- data/lib/starter_web/pages/public/asciidoc_skeletons/simple-document/simple.adoc +1 -1
- data/lib/starter_web/pages/public/blog/navigator/archive/allview.html +1 -1
- data/lib/starter_web/pages/public/blog/navigator/archive/categoryview.html +1 -1
- data/lib/starter_web/pages/public/blog/navigator/archive/dateview.html +1 -1
- data/lib/starter_web/pages/public/blog/navigator/archive/tagview.html +1 -1
- data/lib/starter_web/pages/public/blog/navigator/index.html +1 -1
- data/lib/starter_web/pages/public/learn/bookshelf/article_previewer/viewer_biography.adoc +1 -1
- data/lib/starter_web/pages/public/learn/bookshelf/article_previewer/viewer_fantasy.adoc +1 -1
- data/lib/starter_web/pages/public/learn/bookshelf/article_previewer/viewer_romance.adoc +1 -1
- data/lib/starter_web/pages/public/learn/bookshelf/jekyll_collections.adoc +1 -1
- data/lib/starter_web/pages/public/learn/bookshelf/viewer_all_books.adoc +1 -1
- data/lib/starter_web/pages/public/learn/where_to_go.adoc +1 -1
- data/lib/starter_web/pages/public/legal/en/100_copyright.adoc +3 -3
- data/lib/starter_web/pages/public/legal/en/200_impress.adoc +3 -3
- data/lib/starter_web/pages/public/legal/en/300_privacy.adoc +3 -3
- data/lib/starter_web/pages/public/legal/en/400_comment_policy.adoc +3 -3
- data/lib/starter_web/pages/public/panels/intro_panel/_includes/attributes.asciidoc +1 -1
- data/lib/starter_web/pages/public/panels/intro_panel/panel.adoc +1 -4
- data/lib/starter_web/pages/public/plans/plans.adoc +1 -1
- data/lib/starter_web/pages/public/tools/previewer/preview_bootstrap_theme.adoc +6 -6
- data/lib/starter_web/pages/public/tools/tester/app_tester_amplitudejs_yt.adoc +7 -3
- data/lib/starter_web/pages/public/tools/tester/app_tester_swiperjs.adoc +7 -3
- data/lib/starter_web/pages/public/tools/tester/videojs_macro_tester.adoc +122 -34
- data/lib/starter_web/pages/public/tour/_includes/attributes.asciidoc +1 -2
- data/lib/starter_web/pages/public/tour/_includes/documents/419_advanced_modals_demo.asciidoc +1 -1
- data/lib/starter_web/pages/public/tour/_includes/documents/themes_bootstrap.asciidoc +1 -1
- data/lib/starter_web/pages/public/tour/asciidoc_extensions.adoc +7 -3
- data/lib/starter_web/pages/public/tour/bootstrap_themes.adoc +62 -7
- data/lib/starter_web/pages/public/tour/icon_fonts.adoc +4 -8
- data/lib/starter_web/pages/public/tour/modal_extentions.adoc +2 -2
- data/lib/starter_web/pages/public/tour/responsive_tables.adoc +21 -15
- data/lib/starter_web/pages/public/tour/typography.adoc +5 -5
- data/lib/starter_web/pages/public/tour/video_data.adoc +51 -26
- metadata +34 -149
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/lg-transitions.css +0 -984
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/lg-transitions.min.css +0 -26
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/lightgallery-bundle.css +0 -1627
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/lightgallery-bundle.min.css +0 -25
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/animation-w.png +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/customize-w.png +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/dynamic-w.png +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/facebook-icon.svg +0 -10
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/googleplus-icon.svg +0 -30
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/html5-w.png +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/linked-in.png +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/module-w.png +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/play-button-hover.svg +0 -94
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/play-button.png +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/play-button.svg +0 -93
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/responsive-w.png +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/thumb-w.png +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/touch-w.png +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/twitter-icon.svg +0 -15
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/twitter.png +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/video1-w.png +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/zoom-w.png +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/icons/zoom.png +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/uno.css +0 -140
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/css/themes/uno/uno.min.css +0 -19
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/fonts/lg.svg +0 -54
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/fonts/lg.ttf +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/fonts/lg.woff +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/fonts/lg.woff2 +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/images/loading.gif +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/img/loading.gif +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/img/video-play.png +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/img/vimeo-play.png +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/img/youtube-play.png +0 -0
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/lightgallery.js +0 -2782
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/lightgallery.min.js +0 -26
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/parser/webvtt/LICENSE.md +0 -44
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/parser/webvtt/README.md +0 -37
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/parser/webvtt/parser.js +0 -890
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/parser/webvtt/parser.min.js +0 -8
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/j1/j1-video.js +0 -402
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/j1/j1-video.min.js +0 -7
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/j1/lg-video.1.js +0 -585
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-autoplay.js +0 -275
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-autoplay.min.js +0 -26
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-comment.js +0 -230
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-comment.min.js +0 -26
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-fullscreen.js +0 -160
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-fullscreen.min.js +0 -26
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-hash.js +0 -223
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-hash.min.js +0 -27
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-medium-zoom.js +0 -157
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-medium-zoom.min.js +0 -26
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-pager.js +0 -164
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-pager.min.js +0 -26
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-rotate.js +0 -299
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-rotate.min.js +0 -26
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-share.js +0 -244
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-share.min.js +0 -27
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-thumbnail.js +0 -509
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-thumbnail.min.js +0 -26
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-video.js +0 -909
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-video.min.js +0 -26
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-vimeo-thumbnail.js +0 -207
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-vimeo-thumbnail.min.js +0 -26
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-zoom.js +0 -999
- data/assets/theme/j1/modules/lightGallery/!v2.7.2/js/plugins/lg-zoom.min.js +0 -26
- data/assets/theme/j1/modules/lightGallery/js/plugins/j1/lg-thumbnail.0.js +0 -495
- data/assets/theme/j1/modules/lightGallery/js/plugins/j1/lg-thumbnail.1.js +0 -513
- data/assets/theme/j1/modules/lightGallery/js/plugins/j1/lg-video.0.js +0 -553
- data/assets/theme/j1/modules/lightGallery/js/plugins/j1/lg-video.1.js +0 -585
- data/assets/theme/j1/modules/lightGallery/js/plugins/j1/lg-video.2.js +0 -914
- data/assets/theme/j1/modules/videojs/!v8.12.0/css/font/README.md +0 -151
- data/assets/theme/j1/modules/videojs/!v8.12.0/css/font/VideoJS.svg +0 -150
- data/assets/theme/j1/modules/videojs/!v8.12.0/css/font/video-js-cdn.css +0 -2012
- data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/city.css +0 -147
- data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/city.min.css +0 -5
- data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/fantasy.css +0 -113
- data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/fantasy.min.css +0 -5
- data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/forest.css +0 -166
- data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/forest.min.css +0 -5
- data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/sea.css +0 -72
- data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/sea.min.css +0 -5
- data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/uno.css +0 -311
- data/assets/theme/j1/modules/videojs/!v8.12.0/css/themes/uno.min.css +0 -19
- data/assets/theme/j1/modules/videojs/!v8.12.0/css/videojs.css +0 -1686
- data/assets/theme/j1/modules/videojs/!v8.12.0/css/videojs.min.css +0 -13
- data/assets/theme/j1/modules/videojs/!v8.12.0/js/video.js +0 -65226
- data/assets/theme/j1/modules/videojs/!v8.12.0/js/video.min.js +0 -55
- data/assets/theme/j1/modules/videojs/plugins/players/dm/!examples/dailymotion-controls.html +0 -18
- data/assets/theme/j1/modules/videojs/plugins/players/dm/!examples/dailymotion-javascript.html +0 -28
- data/assets/theme/j1/modules/videojs/plugins/players/dm/!examples/dailymotion-playlist.html +0 -19
- data/assets/theme/j1/modules/videojs/plugins/players/dm/!examples/global-parameters.html +0 -30
- data/assets/theme/j1/modules/videojs/plugins/players/dm/!examples/simple.html +0 -20
- data/assets/theme/j1/modules/videojs/plugins/players/dm/!examples/switch.html +0 -39
- data/assets/theme/j1/modules/videojs/plugins/players/vm/!examples/index.html +0 -34
- data/assets/theme/j1/modules/videojs/plugins/players/yt/!examples/global-parameters.html +0 -34
- data/assets/theme/j1/modules/videojs/plugins/players/yt/!examples/simple.html +0 -22
- data/assets/theme/j1/modules/videojs/plugins/players/yt/!examples/switch.html +0 -39
- data/assets/theme/j1/modules/videojs/plugins/players/yt/!examples/youtube-controls.html +0 -20
- data/assets/theme/j1/modules/videojs/plugins/players/yt/!examples/youtube-javascript.html +0 -29
- data/assets/theme/j1/modules/videojs/plugins/players/yt/!examples/youtube-list.html +0 -21
- data/assets/theme/j1/modules/videojs/plugins/players/yt/!examples/youtube-playlist.html +0 -21
- data/lib/starter_web/_data/modules/gallery_app.yml +0 -1002
- data/lib/starter_web/_data/modules/gallery_playlists.yml +0 -534
- data/lib/starter_web/assets/image/module/attic/1920x1280/alina-grubnyak.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/bruno-figueiredo.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/harpal-singh.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/hayden-mills-2.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/j1-content-mockup-1.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/j1-content-mockup-2.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/j1-content-mockup-3.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/j1-starter-mockup-1.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/recha-oktaviani.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/1920x1280/tiny_desk.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/admin-dashboard-bootstrap-1280x600.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/alice-donovan-rouse-2.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/building-blocks-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/christina-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/franck-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/giammarco-boscaro-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/ideas-start-here-1920x1280-bw.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/ideas-start-here-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/jessica-ruscello-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/joanna-kosinska-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/leon-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/lianhao-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/library-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/markus-krisetya-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/markus-spiske-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/markus-spiske4-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/matthaeus-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/matthew-dockery-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/no-time-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/rirri-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/shubham-dhage-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/shutterstock_sponsor-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/sigmund-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/szabo-viktor-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/themes-1920x1280-bw.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/tldr-1920x800.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/vladislav-klapin-1920x1280.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/yellow-cactus-1920x1280.jpg +0 -0
- /data/assets/theme/j1/modules/videojs/plugins/players/vm/{LICENSE → js/old/LICENSE} +0 -0
- /data/assets/theme/j1/modules/videojs/plugins/players/vm/{README.md → js/old/README.md} +0 -0
@@ -0,0 +1,32 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
<html>
|
3
|
+
<head>
|
4
|
+
<link type="text/css" rel="stylesheet" href="../../../../css/videojs.min.css" />
|
5
|
+
<!-- script src="../../j1_core/template.min.js"></script -->
|
6
|
+
<script src="../../../../../log4javascript/js/log4javascript.min.js"></script>
|
7
|
+
<script src="../../../../../jquery/js/jquery.min.js"></script>
|
8
|
+
</head>
|
9
|
+
<body id="content" style="display: block;">
|
10
|
+
<video
|
11
|
+
id="vid_x887s09"
|
12
|
+
class="video-js vjs-default-skin"
|
13
|
+
controls
|
14
|
+
autoplay
|
15
|
+
width="640"
|
16
|
+
height="264"
|
17
|
+
data-setup='{
|
18
|
+
"techOrder": [
|
19
|
+
"dailymotion", "html5"
|
20
|
+
],
|
21
|
+
"sources": [{
|
22
|
+
"type": "video/dailymotion",
|
23
|
+
"src": "//dai.ly/x887s09"
|
24
|
+
}]
|
25
|
+
}'
|
26
|
+
>
|
27
|
+
</video>
|
28
|
+
|
29
|
+
<script src="../../../../js/video.js"></script>
|
30
|
+
<script src="../js/dailymotion.js"></script>
|
31
|
+
</body>
|
32
|
+
</html>
|
@@ -0,0 +1,647 @@
|
|
1
|
+
/*
|
2
|
+
# -----------------------------------------------------------------------------
|
3
|
+
# ~/assets/theme/j1/modules/videojs/js/plugins/players/dm/dailymotion.js
|
4
|
+
# Provides Dailymotion Playback Technology (Tech) for Video.js V8 and newer
|
5
|
+
#
|
6
|
+
# Product/Info:
|
7
|
+
# http://jekyll.one
|
8
|
+
#
|
9
|
+
# Copyright (C) 2020 John Law
|
10
|
+
# Copyright (C) 2023-2025 Juergen Adams
|
11
|
+
#
|
12
|
+
# videojs-dailymotion is licensed under MIT License.
|
13
|
+
# See: https://github.com/lawchihon/videojs-dailymotion/blob/master/LICENSE
|
14
|
+
# J1 Theme is licensed under MIT License.
|
15
|
+
# See: https://github.com/jekyll-one-org/j1-template/blob/main/LICENSE
|
16
|
+
# -----------------------------------------------------------------------------
|
17
|
+
*/
|
18
|
+
|
19
|
+
/* Version 1.0, updated version for videoJS V8 + J1 Template */
|
20
|
+
|
21
|
+
/*global define, DM*/
|
22
|
+
(function (root, factory) {
|
23
|
+
if (typeof exports==='object' && typeof module!=='undefined') {
|
24
|
+
var videojs = require('video.js');
|
25
|
+
module.exports = factory(videojs.default || videojs);
|
26
|
+
} else if (typeof define === 'function' && define.amd) {
|
27
|
+
define(['videojs'], function(videojs){
|
28
|
+
return (root.Dailymotion = factory(videojs));
|
29
|
+
});
|
30
|
+
} else {
|
31
|
+
root.Dailymotion = factory(root.videojs);
|
32
|
+
}
|
33
|
+
}(this, function(videojs) {
|
34
|
+
'use strict';
|
35
|
+
|
36
|
+
const isDev = (j1.env === "development" || j1.env === "dev") ? true : false;
|
37
|
+
|
38
|
+
var logger = log4javascript.getLogger('videoJS.plugin.dailymotion');
|
39
|
+
var _isOnMobile = videojs.browser.IS_IOS || videojs.browser.IS_ANDROID;
|
40
|
+
var Tech = videojs.getTech('Tech');
|
41
|
+
|
42
|
+
var startTimeModule;
|
43
|
+
var endTimeModule;
|
44
|
+
|
45
|
+
class Dailymotion extends Tech {
|
46
|
+
|
47
|
+
constructor(options, ready) {
|
48
|
+
super(options, ready);
|
49
|
+
|
50
|
+
this.setPoster(options.poster);
|
51
|
+
this.setSrc(this.options_.source, true);
|
52
|
+
|
53
|
+
// set the vjs-dailymotion class to the player's parent node,
|
54
|
+
// when is not set, wait a tick
|
55
|
+
var vm = this;
|
56
|
+
setTimeout(function() {
|
57
|
+
if (this.el_) {
|
58
|
+
this.el_.parentNode.className += ' vjs-dailymotion';
|
59
|
+
|
60
|
+
if (_isOnMobile) {
|
61
|
+
this.el_.parentNode.className += ' vjs-dailymotion-mobile';
|
62
|
+
}
|
63
|
+
|
64
|
+
if (Dailymotion.isSdkReady) {
|
65
|
+
vm.initDMPlayer();
|
66
|
+
} else {
|
67
|
+
Dailymotion.sdkReadyQueue.push(vm);
|
68
|
+
}
|
69
|
+
}
|
70
|
+
}.bind(this));
|
71
|
+
} // END Constructor
|
72
|
+
|
73
|
+
getPlayerParams() {
|
74
|
+
var playerParams = {
|
75
|
+
autoplay: false,
|
76
|
+
mute: false,
|
77
|
+
controls: false,
|
78
|
+
'queue-autoplay-next': false,
|
79
|
+
'queue-enable': false
|
80
|
+
};
|
81
|
+
|
82
|
+
// Let the user set any Dailymotion parameter
|
83
|
+
// https://developer.dailymotion.com/player/#player-parameters
|
84
|
+
// To use Dailymotion controls, you must use dmControls instead
|
85
|
+
var params = [
|
86
|
+
'api', 'autoplay', 'autoplay-mute', 'id', 'mute', 'origin',
|
87
|
+
'quality', 'queue-autoplay-next', 'queue-enable', 'sharing-enable',
|
88
|
+
'start', 'subtitles-default', 'syndication', 'ui-highlight',
|
89
|
+
'ui-logo','ui-start-screen-info', 'ui-theme', 'apimode',
|
90
|
+
'playlist'
|
91
|
+
];
|
92
|
+
var options = this.options_;
|
93
|
+
|
94
|
+
params.forEach((param) => {
|
95
|
+
if (typeof options[param] === 'undefined') {
|
96
|
+
return;
|
97
|
+
}
|
98
|
+
playerParams[param] = options[param];
|
99
|
+
});
|
100
|
+
|
101
|
+
if (typeof this.options_.dmControls !== 'undefined') {
|
102
|
+
playerParams.controls = this.options_.dmControls;
|
103
|
+
}
|
104
|
+
|
105
|
+
// Overwriting playlist if it is included in url
|
106
|
+
if (this.url && typeof this.url.playlist !== 'undefined') {
|
107
|
+
playerParams.playlist = this.url.playlist;
|
108
|
+
}
|
109
|
+
|
110
|
+
// Allow undocumented options to be passed along via customVars
|
111
|
+
if (typeof this.options_.customVars !== 'undefined') {
|
112
|
+
var customVars = this.options_.customVars;
|
113
|
+
Object.keys(customVars).forEach((key) => {
|
114
|
+
playerParams[key] = customVars[key];
|
115
|
+
});
|
116
|
+
}
|
117
|
+
|
118
|
+
return playerParams;
|
119
|
+
} // END getPlayerParams
|
120
|
+
|
121
|
+
getPlayerConfig() {
|
122
|
+
var playerConfig = {
|
123
|
+
width: '100%',
|
124
|
+
height: '100%',
|
125
|
+
params: this.getPlayerParams()
|
126
|
+
};
|
127
|
+
|
128
|
+
if (this.url && typeof this.url.video !== 'undefined') {
|
129
|
+
playerConfig.video = this.url.video;
|
130
|
+
} else if (typeof this.options_.video !== 'undefined') {
|
131
|
+
playerConfig.video = this.options_.video;
|
132
|
+
}
|
133
|
+
|
134
|
+
return playerConfig;
|
135
|
+
} // END getPlayerConfig
|
136
|
+
|
137
|
+
initDMPlayer() {
|
138
|
+
if (this.dmPlayer) {
|
139
|
+
|
140
|
+
// jadams, 2024-06-26:
|
141
|
+
this.dmPlayer.dmPlayerState = {
|
142
|
+
ended: false,
|
143
|
+
playing: false,
|
144
|
+
muted: false,
|
145
|
+
volume: 0,
|
146
|
+
progress: {
|
147
|
+
seconds: 0,
|
148
|
+
percent: 0,
|
149
|
+
duration: 0
|
150
|
+
}
|
151
|
+
};
|
152
|
+
|
153
|
+
return;
|
154
|
+
}
|
155
|
+
|
156
|
+
this.dmPlayer = new DM.player(
|
157
|
+
document.getElementById(this.options_.techId),
|
158
|
+
this.getPlayerConfig()
|
159
|
+
);
|
160
|
+
var vm = this;
|
161
|
+
this.isApiReady = false;
|
162
|
+
this.dmPlayer.addEventListener('apiready', () => {
|
163
|
+
vm.triggerReady();
|
164
|
+
vm.isApiReady = true;
|
165
|
+
});
|
166
|
+
this.dmPlayer.addEventListener('durationchange', () => {
|
167
|
+
vm.trigger('durationchange');
|
168
|
+
});
|
169
|
+
this.dmPlayer.addEventListener('end', () => {
|
170
|
+
vm.trigger('ended');
|
171
|
+
});
|
172
|
+
this.dmPlayer.addEventListener('error', () => {
|
173
|
+
vm.trigger('error');
|
174
|
+
});
|
175
|
+
this.dmPlayer.addEventListener('loadedmetadata', () => {
|
176
|
+
vm.trigger('loadeddata');
|
177
|
+
vm.trigger('loadedmetadata');
|
178
|
+
});
|
179
|
+
this.dmPlayer.addEventListener('pause', () =>{
|
180
|
+
vm.trigger('pause');
|
181
|
+
});
|
182
|
+
this.dmPlayer.addEventListener('play', () => {
|
183
|
+
// jadams, 2024-06-26:
|
184
|
+
// this.dmPlayer.dmPlayerState.playing = true;
|
185
|
+
|
186
|
+
vm.trigger('loadStart');
|
187
|
+
vm.trigger('play');
|
188
|
+
vm.trigger('playing');
|
189
|
+
vm.trigger('waiting');
|
190
|
+
});
|
191
|
+
this.dmPlayer.addEventListener('playback_ready', () => {
|
192
|
+
vm.trigger('loadeddata');
|
193
|
+
});
|
194
|
+
this.dmPlayer.addEventListener('timeupdate', () => {
|
195
|
+
vm.trigger('timeupdate');
|
196
|
+
});
|
197
|
+
this.dmPlayer.addEventListener('volumechange', () => {
|
198
|
+
vm.trigger('volumechange');
|
199
|
+
});
|
200
|
+
|
201
|
+
this.triggerReady();
|
202
|
+
isDev && logger.debug('\n' + 'created ' + this.name_ + ' player on ID: ' + vm.dmPlayer.id);
|
203
|
+
} // END initDMPlayer
|
204
|
+
|
205
|
+
autoplay(autoplay) {
|
206
|
+
if (typeof autoplay !== 'undefined') {
|
207
|
+
return this.setAutoplay(autoplay);
|
208
|
+
}
|
209
|
+
|
210
|
+
return this.options_.autoplay;
|
211
|
+
} // END autoplay
|
212
|
+
|
213
|
+
setAutoplay(val) {
|
214
|
+
return this.options_.autoplay = val;
|
215
|
+
} // END setAutoplay
|
216
|
+
|
217
|
+
buffered() {
|
218
|
+
if(!this.dmPlayer || !this.dmPlayer.bufferedTime) {
|
219
|
+
return videojs.time.createTimeRanges();
|
220
|
+
}
|
221
|
+
|
222
|
+
return videojs.time.createTimeRanges(0, this.dmPlayer.bufferedTime);
|
223
|
+
} // END buffered
|
224
|
+
|
225
|
+
createEl() {
|
226
|
+
var div = document.createElement('div');
|
227
|
+
div.setAttribute('id', this.options_.techId);
|
228
|
+
div.setAttribute('style', 'cursor: default; width:100%; height:100%; top:0; left:0; position:absolute');
|
229
|
+
div.setAttribute('class', 'vjs-tech');
|
230
|
+
|
231
|
+
var divWrapper = document.createElement('div');
|
232
|
+
divWrapper.appendChild(div);
|
233
|
+
|
234
|
+
return divWrapper;
|
235
|
+
} // END createEl
|
236
|
+
|
237
|
+
currentSrc() {
|
238
|
+
return this.source && this.source.src;
|
239
|
+
} // END currentSrc
|
240
|
+
|
241
|
+
currentTime(seconds) {
|
242
|
+
if (typeof seconds !== 'undefined') {
|
243
|
+
return this.setCurrentTime(seconds);
|
244
|
+
}
|
245
|
+
|
246
|
+
return this.dmPlayer && this.dmPlayer.currentTime;
|
247
|
+
} // END currentTime
|
248
|
+
|
249
|
+
setCurrentTime(seconds) {
|
250
|
+
if (!this.dmPlayer || !this.dmPlayer.seek) {
|
251
|
+
return;
|
252
|
+
}
|
253
|
+
|
254
|
+
return this.dmPlayer.seek(seconds);
|
255
|
+
} // END setCurrentTime
|
256
|
+
|
257
|
+
dispose() {
|
258
|
+
if (DM && DM.destroy) {
|
259
|
+
//Destroy the Dailymotion Player
|
260
|
+
DM.destroy(this.options_.techId);
|
261
|
+
} else {
|
262
|
+
//Dailymotion API hasn't finished loading or the player is already disposed
|
263
|
+
var index = Dailymotion.sdkReadyQueue.indexOf(this);
|
264
|
+
if (index !== -1) {
|
265
|
+
Dailymotion.sdkReadyQueue.splice(index, 1);
|
266
|
+
}
|
267
|
+
}
|
268
|
+
this.dmPlayer = undefined;
|
269
|
+
|
270
|
+
this.el_.parentNode.className = this.el_.parentNode.className
|
271
|
+
.replace(' vjs-dailymotion', '')
|
272
|
+
.replace(' vjs-dailymotion-mobile', '');
|
273
|
+
this.el_.parentNode.removeChild(this.el_);
|
274
|
+
|
275
|
+
// Needs to be called after the Dailymotion player is destroyed,
|
276
|
+
// otherwise there will be a undefined reference exception
|
277
|
+
Tech.prototype.dispose.call(this);
|
278
|
+
} // END dispose
|
279
|
+
|
280
|
+
duration(seconds) {
|
281
|
+
if (typeof seconds !== 'undefined') {
|
282
|
+
return this.setDuration(seconds);
|
283
|
+
}
|
284
|
+
|
285
|
+
return this.dmPlayer ? this.dmPlayer.duration : 0;
|
286
|
+
} // END duration
|
287
|
+
|
288
|
+
setDuration(seconds) {
|
289
|
+
if (!this.dmPlayer || !this.dmPlayer.seek) {
|
290
|
+
return;
|
291
|
+
}
|
292
|
+
|
293
|
+
return this.dmPlayer.seek(seconds);
|
294
|
+
} // END setDuration
|
295
|
+
|
296
|
+
ended() {
|
297
|
+
return this.dmPlayer && this.dmPlayer.ended;
|
298
|
+
} // END ended
|
299
|
+
|
300
|
+
enterFullWindow() {
|
301
|
+
if (!this.dmPlayer || !this.dmPlayer.setFullscreen) {
|
302
|
+
return;
|
303
|
+
}
|
304
|
+
|
305
|
+
return this.dmPlayer.setFullscreen(true);
|
306
|
+
} // END enterFullWindow
|
307
|
+
|
308
|
+
error() {
|
309
|
+
return this.dmPlayer && this.dmPlayer.error;
|
310
|
+
} // END error
|
311
|
+
|
312
|
+
exitFullscreen() {
|
313
|
+
if (!this.dmPlayer || !this.dmPlayer.setFullscreen) {
|
314
|
+
return;
|
315
|
+
}
|
316
|
+
|
317
|
+
return this.dmPlayer.setFullscreen(false);
|
318
|
+
} // END exitFullscreen
|
319
|
+
|
320
|
+
isFullscreen() {
|
321
|
+
return this.dmPlayer && this.dmPlayer.fullscreen;
|
322
|
+
} // END isFullscreen
|
323
|
+
|
324
|
+
// not supported by Dailymotion
|
325
|
+
language() {
|
326
|
+
return undefined;
|
327
|
+
} // END language
|
328
|
+
|
329
|
+
// not supported by Dailymotion
|
330
|
+
languages() {
|
331
|
+
return undefined;
|
332
|
+
} // END languages
|
333
|
+
|
334
|
+
load() {
|
335
|
+
if (!this.dmPlayer || !this.dmPlayer.load) {
|
336
|
+
return;
|
337
|
+
}
|
338
|
+
|
339
|
+
return this.dmPlayer.load(this.getPlayerConfig());
|
340
|
+
} // END load
|
341
|
+
|
342
|
+
// not supported by Dailymotion
|
343
|
+
loop() {
|
344
|
+
return undefined;
|
345
|
+
} // END loop
|
346
|
+
|
347
|
+
muted(muted) {
|
348
|
+
if (typeof muted !== undefined) {
|
349
|
+
return this.setMuted(muted);
|
350
|
+
}
|
351
|
+
|
352
|
+
return this.dmPlayer && this.dmPlayer.mute;
|
353
|
+
} // END muted
|
354
|
+
|
355
|
+
setMuted(mute) {
|
356
|
+
if (typeof mute === 'undefined' || !this.dmPlayer || !this.dmPlayer.setMuted) {
|
357
|
+
return;
|
358
|
+
}
|
359
|
+
|
360
|
+
if (mute) {
|
361
|
+
this.volumeBeforeMute = this.volume();
|
362
|
+
this.setVolume(0);
|
363
|
+
} else {
|
364
|
+
this.setVolume(this.volumeBeforeMute);
|
365
|
+
}
|
366
|
+
|
367
|
+
this.dmPlayer.setMuted(mute);
|
368
|
+
} // END setMuted
|
369
|
+
|
370
|
+
networkState() {
|
371
|
+
if (!this.dmPlayer || this.dmPlayer.error) {
|
372
|
+
return 0; //NETWORK_EMPTY
|
373
|
+
}
|
374
|
+
|
375
|
+
if (this.dmPlayer.seeking) {
|
376
|
+
return 2; //NETWORK_LOADING
|
377
|
+
}
|
378
|
+
} // END networkState
|
379
|
+
|
380
|
+
pause() {
|
381
|
+
if (!this.dmPlayer || !this.dmPlayer.pause) {
|
382
|
+
return;
|
383
|
+
}
|
384
|
+
|
385
|
+
return this.dmPlayer.pause();
|
386
|
+
} // END pause
|
387
|
+
|
388
|
+
paused() {
|
389
|
+
return this.dmPlayer && this.dmPlayer.paused;
|
390
|
+
} // END paused
|
391
|
+
|
392
|
+
play() {
|
393
|
+
if (!this.isApiReady || !this.dmPlayer || !this.dmPlayer.play) {
|
394
|
+
return;
|
395
|
+
}
|
396
|
+
|
397
|
+
this.trigger('loadStart');
|
398
|
+
this.trigger('waiting');
|
399
|
+
return this.dmPlayer.play();
|
400
|
+
} // END play
|
401
|
+
|
402
|
+
// not supported by Dailymotion
|
403
|
+
playbackRate() {
|
404
|
+
return 1;
|
405
|
+
} // END playbackRate
|
406
|
+
|
407
|
+
// not supported by Dailymotion
|
408
|
+
poster() {
|
409
|
+
return undefined;
|
410
|
+
} // END poster
|
411
|
+
|
412
|
+
// not supported by Dailymotion
|
413
|
+
preload() {
|
414
|
+
return undefined;
|
415
|
+
} // END preload
|
416
|
+
|
417
|
+
readyState() {
|
418
|
+
if (!this.dmPlayer || this.dmPlayer.error) {
|
419
|
+
return 0; //NETWORK_EMPTY
|
420
|
+
}
|
421
|
+
|
422
|
+
if (this.dmPlayer.seeking) {
|
423
|
+
return 1; //HAVE_METADATA
|
424
|
+
}
|
425
|
+
return 4; //HAVE_ENOUGH_DATA
|
426
|
+
} // END readyState
|
427
|
+
|
428
|
+
remainingTime() {
|
429
|
+
return this.dmPlayer && (this.dmPlayer.duration - this.dmPlayer.currentTime);
|
430
|
+
} // END remainingTime
|
431
|
+
|
432
|
+
requestFullscreen() {
|
433
|
+
return this.enterFullWindow();
|
434
|
+
} // END requestFullscreen
|
435
|
+
|
436
|
+
enterFullScreen() {
|
437
|
+
return this.enterFullWindow();
|
438
|
+
} // END enterFullScreen
|
439
|
+
|
440
|
+
reset() {
|
441
|
+
this.load();
|
442
|
+
} // END reset
|
443
|
+
|
444
|
+
seekable() {
|
445
|
+
if(!this.ytPlayer) {
|
446
|
+
return videojs.time.createTimeRanges();
|
447
|
+
}
|
448
|
+
|
449
|
+
return videojs.time.createTimeRanges(0, this.ytPlayer.getDuration());
|
450
|
+
} // END seekable
|
451
|
+
|
452
|
+
seeking() {
|
453
|
+
return this.dmPlayer && this.dmPlayer.seeking;
|
454
|
+
} // END seeking
|
455
|
+
|
456
|
+
src(source) {
|
457
|
+
if (typeof source !== 'undefined') {
|
458
|
+
return this.setSrc(source);
|
459
|
+
}
|
460
|
+
|
461
|
+
return this.source;
|
462
|
+
} // END src
|
463
|
+
|
464
|
+
setSrc(source) {
|
465
|
+
if (typeof source === 'undefined') {
|
466
|
+
return;
|
467
|
+
}
|
468
|
+
|
469
|
+
this.source = source;
|
470
|
+
this.url = Dailymotion.parseUrl(source.src || source);
|
471
|
+
|
472
|
+
// Load the video if sdk is ready
|
473
|
+
if (Dailymotion.isSdkReady) {
|
474
|
+
this.load();
|
475
|
+
}
|
476
|
+
return this.source;
|
477
|
+
} // END setSrc
|
478
|
+
|
479
|
+
supportsFullScreen() {
|
480
|
+
return true;
|
481
|
+
} // END supportsFullScreen
|
482
|
+
|
483
|
+
volume() {
|
484
|
+
return this.dmPlayer ? this.dmPlayer.volume : 1;
|
485
|
+
} // END volume
|
486
|
+
|
487
|
+
// if (DMPlayerState.playing === true) {
|
488
|
+
// setVolume(percentAsDecimal) {
|
489
|
+
// if (!this.dmPlayer || !this.dmPlayer.setMuted || !this.dmPlayer.setVolume) {
|
490
|
+
// return;
|
491
|
+
// }
|
492
|
+
//
|
493
|
+
// this.dmPlayer.setMuted(false);
|
494
|
+
// this.dmPlayer.setVolume(percentAsDecimal);
|
495
|
+
// } // END setVolume
|
496
|
+
// }
|
497
|
+
|
498
|
+
setVolume(percentAsDecimal) {
|
499
|
+
if (!this.dmPlayer || !this.dmPlayer.setMuted || !this.dmPlayer.setVolume) {
|
500
|
+
return;
|
501
|
+
}
|
502
|
+
|
503
|
+
// jadams, 2024-06-26:
|
504
|
+
// if (this.dmPlayer.dmPlayerState.playing === true) {
|
505
|
+
if (this.dmPlayer.apiReady) {
|
506
|
+
this.dmPlayer.setMuted(false);
|
507
|
+
this.dmPlayer.setVolume(percentAsDecimal);
|
508
|
+
}
|
509
|
+
|
510
|
+
} // END setVolume
|
511
|
+
|
512
|
+
} // END class Dailymotion
|
513
|
+
|
514
|
+
Dailymotion.isSupported = () => {
|
515
|
+
return true;
|
516
|
+
};
|
517
|
+
|
518
|
+
Dailymotion.canPlaySource = (event) => {
|
519
|
+
return Dailymotion.canPlayType(event.type);
|
520
|
+
};
|
521
|
+
|
522
|
+
Dailymotion.canPlayType = (event) => {
|
523
|
+
return (event === 'video/dailymotion');
|
524
|
+
};
|
525
|
+
|
526
|
+
Dailymotion.parseUrl = (url) => {
|
527
|
+
var result = {};
|
528
|
+
|
529
|
+
var regex = /video\/[^?|^\/]*/;
|
530
|
+
var match = url.match(regex);
|
531
|
+
|
532
|
+
if (match && match[0]) {
|
533
|
+
result.video = match[0].replace('video/', '');
|
534
|
+
}
|
535
|
+
|
536
|
+
var regPlaylist = /playlist(=|\/)[^&]*/;
|
537
|
+
match = url.match(regPlaylist);
|
538
|
+
|
539
|
+
if(match && match[0]) {
|
540
|
+
result.playlist = match[0].replace(/playlist(=|\/)/, '');
|
541
|
+
}
|
542
|
+
|
543
|
+
return result;
|
544
|
+
};
|
545
|
+
|
546
|
+
function apiLoaded() {
|
547
|
+
isDev && logger.debug('\n' + 'API loaded successfully');
|
548
|
+
|
549
|
+
Dailymotion.isSdkReady = true;
|
550
|
+
|
551
|
+
for (var i = 0; i < Dailymotion.sdkReadyQueue.length; ++i) {
|
552
|
+
Dailymotion.sdkReadyQueue[i].initDMPlayer();
|
553
|
+
}
|
554
|
+
isDev && logger.debug('\n' + 'created all players from queue: #' + i);
|
555
|
+
|
556
|
+
endTimeModule = Date.now();
|
557
|
+
isDev && logger.debug('\n' + 'initializing plugin: finished');
|
558
|
+
isDev && logger.debug('\n' + 'plugin initializing time: ' + (endTimeModule-startTimeModule) + 'ms');
|
559
|
+
} // END apiLoaded
|
560
|
+
|
561
|
+
function loadScript(src, callback) {
|
562
|
+
var loaded = false;
|
563
|
+
var tag = document.createElement('script');
|
564
|
+
var firstScriptTag = document.getElementsByTagName('script')[0];
|
565
|
+
|
566
|
+
if (!firstScriptTag) {
|
567
|
+
// when loaded in jest without jsdom setup it doesn't get any element.
|
568
|
+
// In jest it doesn't really make sense to do anything, because no one is watching dailymotion in jest
|
569
|
+
return;
|
570
|
+
}
|
571
|
+
|
572
|
+
firstScriptTag.parentNode.insertBefore(tag, firstScriptTag);
|
573
|
+
tag.onload = () => {
|
574
|
+
if (!loaded) {
|
575
|
+
loaded = true;
|
576
|
+
callback();
|
577
|
+
}
|
578
|
+
};
|
579
|
+
|
580
|
+
tag.onreadystatechange = () => {
|
581
|
+
if (!loaded && (this.readyState === 'complete' || this.readyState === 'loaded')) {
|
582
|
+
loaded = true;
|
583
|
+
callback();
|
584
|
+
}
|
585
|
+
};
|
586
|
+
|
587
|
+
tag.src = src;
|
588
|
+
} // END loadScript
|
589
|
+
|
590
|
+
function injectCss() {
|
591
|
+
|
592
|
+
const css = `
|
593
|
+
.vjs-dailymotion .vjs-iframe-blocker { display: none; }
|
594
|
+
.vjs-dailymotion.vjs-user-inactive .vjs-iframe-blocker { display: block; }
|
595
|
+
.vjs-dailymotion .vjs-poster { background-size: cover; }
|
596
|
+
.vjs-dailymotion-mobile .vjs-big-play-button { display: none; }
|
597
|
+
`;
|
598
|
+
|
599
|
+
var head = document.head || document.getElementsByTagName('head')[0];
|
600
|
+
|
601
|
+
var style = document.createElement('style');
|
602
|
+
style.setAttribute('type', 'text/css');
|
603
|
+
|
604
|
+
if (style.styleSheet){
|
605
|
+
style.styleSheet.cssText = css;
|
606
|
+
} else {
|
607
|
+
style.appendChild(document.createTextNode(css));
|
608
|
+
}
|
609
|
+
|
610
|
+
head.appendChild(style);
|
611
|
+
isDev && logger.debug('\n' + 'added additional CSS styles');
|
612
|
+
} // END injectCss
|
613
|
+
|
614
|
+
// Include the version number
|
615
|
+
Dailymotion.VERSION = '1.0.0';
|
616
|
+
|
617
|
+
Dailymotion.sdkReadyQueue = [];
|
618
|
+
|
619
|
+
// initialize plugin if page ready
|
620
|
+
// -------------------------------------------------------------------------
|
621
|
+
var dependencies_met_page_ready = setInterval (() => {
|
622
|
+
var pageState = $('#content').css("display");
|
623
|
+
var pageVisible = (pageState === 'block') ? true : false;
|
624
|
+
var j1CoreFinished = (j1.getState() === 'finished') ? true : false;
|
625
|
+
|
626
|
+
if (j1CoreFinished && pageVisible) {
|
627
|
+
startTimeModule = Date.now();
|
628
|
+
|
629
|
+
isDev && logger.debug('\n' + 'initializing plugin: started');
|
630
|
+
isDev && logger.debug('\n' + 'version of videoJS detected: ' + videojs.VERSION);
|
631
|
+
|
632
|
+
loadScript('//api.dmcdn.net/all.js', apiLoaded);
|
633
|
+
// loadScript('/assets/theme/j1/modules/videojs/plugins/players/dm/api/dailymotion.sdk.min.js', apiLoaded);
|
634
|
+
injectCss();
|
635
|
+
|
636
|
+
clearInterval(dependencies_met_page_ready);
|
637
|
+
} // END pageVisible
|
638
|
+
}, 10); // END dependencies_met_page_ready
|
639
|
+
|
640
|
+
// Older versions of VJS5 doesn't have the registerTech function
|
641
|
+
if (typeof videojs.registerTech !== 'undefined') {
|
642
|
+
videojs.registerTech('Dailymotion', Dailymotion);
|
643
|
+
} else {
|
644
|
+
videojs.registerComponent('Dailymotion', Dailymotion);
|
645
|
+
}
|
646
|
+
|
647
|
+
}));
|