j1-template 2024.3.23 → 2024.3.24
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/gallery_app.html +102 -14
- 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/js/lightgallery.js +36 -17
- data/assets/theme/j1/modules/lightGallery/js/lightgallery.min.js +1 -8
- data/assets/theme/j1/modules/lightGallery/js/plugins/lg-video.js +423 -297
- 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 +41 -29
- data/assets/theme/j1/modules/videojs/css/themes/uno.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/players/dm/!examples/dailymotion-controls.html +4 -4
- data/assets/theme/j1/modules/videojs/plugins/players/dm/!examples/dailymotion-javascript.html +3 -3
- data/assets/theme/j1/modules/videojs/plugins/players/dm/!examples/dailymotion-playlist.html +3 -3
- data/assets/theme/j1/modules/videojs/plugins/players/dm/!examples/global-parameters.html +3 -3
- data/assets/theme/j1/modules/videojs/plugins/players/dm/!examples/simple.html +15 -4
- data/assets/theme/j1/modules/videojs/plugins/players/dm/!examples/switch.html +3 -3
- data/assets/theme/j1/modules/videojs/plugins/players/vm/!examples/index.html +3 -3
- data/assets/theme/j1/modules/videojs/plugins/players/vm/!examples/player/index.html +3 -3
- data/assets/theme/j1/modules/videojs/plugins/players/yt/!examples/global-parameters.html +5 -5
- data/assets/theme/j1/modules/videojs/plugins/players/yt/!examples/simple.html +5 -5
- data/assets/theme/j1/modules/videojs/plugins/players/yt/!examples/switch.html +5 -5
- data/assets/theme/j1/modules/videojs/plugins/players/yt/!examples/youtube-controls.html +5 -5
- data/assets/theme/j1/modules/videojs/plugins/players/yt/!examples/youtube-javascript.html +5 -5
- data/assets/theme/j1/modules/videojs/plugins/players/yt/!examples/youtube-list.html +5 -5
- data/assets/theme/j1/modules/videojs/plugins/players/yt/!examples/youtube-playlist.html +5 -5
- data/lib/j1/version.rb +1 -1
- data/lib/starter_web/README.md +5 -5
- data/lib/starter_web/_config.yml +1 -1
- data/lib/starter_web/_data/blocks/banner.yml +2 -2
- data/lib/starter_web/_data/modules/attics.yml +11 -0
- data/lib/starter_web/_data/modules/carousel.yml +1 -1
- data/lib/starter_web/_data/modules/defaults/masonry.yml +115 -22
- data/lib/starter_web/_data/modules/gallery.yml +163 -215
- data/lib/starter_web/_data/modules/masonry.yml +6 -0
- data/lib/starter_web/_data/templates/feed.xml +1 -1
- data/lib/starter_web/_includes/attributes.asciidoc +7 -0
- data/lib/starter_web/_plugins/index/lunr.rb +1 -1
- 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-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/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/index.html +3 -2
- data/lib/starter_web/package.json +1 -1
- data/lib/starter_web/pages/public/panels/intro_panel/_includes/attributes.asciidoc +1 -1
- data/lib/starter_web/pages/public/tools/previewer/preview_bootstrap_theme.adoc +5 -5
- 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 +18 -3
- data/lib/starter_web/pages/public/tour/_includes/attributes.asciidoc +1 -2
- 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 +24 -5
- metadata +11 -102
- 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/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/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/ideas-start-here-1920x1280-bw.jpg +0 -0
- data/lib/starter_web/assets/image/module/attic/ideas-start-here-1920x1280.jpg +0 -0
@@ -1,26 +0,0 @@
|
|
1
|
-
/*
|
2
|
-
# -----------------------------------------------------------------------------
|
3
|
-
# ~/assets/theme/j1/modules/lightGallery/js/plugins/lg-video.min.js
|
4
|
-
# Provides lightGallery JS code for the plugin lgVideo
|
5
|
-
#
|
6
|
-
# Product/Info:
|
7
|
-
# https://jekyll.one
|
8
|
-
#
|
9
|
-
# Copyright (C) 2025 Sachin Neravath
|
10
|
-
# Copyright (C) 2023-2025 Juergen Adams
|
11
|
-
#
|
12
|
-
# J1 Template is licensed under the MIT License.
|
13
|
-
# See: https://github.com/jekyll-one-org/j1-template/blob/main/LICENSE
|
14
|
-
# lightGallery is licensed under the GPLv3 license
|
15
|
-
# See: https://github.com/sachinchoolur/lightGallery/blob/master/LICENSE
|
16
|
-
# -----------------------------------------------------------------------------
|
17
|
-
*/
|
18
|
-
|
19
|
-
/*
|
20
|
-
* lightgallery | 2.7.2 | September 20th 2023
|
21
|
-
* http://www.lightgalleryjs.com/
|
22
|
-
* Copyright (c) 2020 Sachin Neravath;
|
23
|
-
* @license GPLv3
|
24
|
-
*/
|
25
|
-
|
26
|
-
!function(e,o){"object"==typeof exports&&"undefined"!=typeof module?module.exports=o():"function"==typeof define&&define.amd?define(o):(e="undefined"!=typeof globalThis?globalThis:e||self).lgVideo=o()}(this,(function(){"use strict";var e=new URL(window.location.href).origin,o=function(){return o=Object.assign||function(e){for(var o,t=1,i=arguments.length;t<i;t++)for(var s in o=arguments[t])Object.prototype.hasOwnProperty.call(o,s)&&(e[s]=o[s]);return e},o.apply(this,arguments)},t={autoplayFirstVideo:!0,htmlPlayerParams:!1,youTubePlayerParams:!1,vimeoPlayerParams:!1,dailymotionPlayerParams:!1,wistiaPlayerParams:!1,tiktokPlayerParams:!1,gotoNextSlideOnVideoEnd:!0,autoplayVideoOnSlide:!1,videojs:!1,videojsTheme:"",videojsOptions:{}},i="lgHasVideo",s="lgSlideItemLoad",n="lgBeforeSlide",a="lgAfterSlide",r="lgPosterClick",l=function(e){return Object.keys(e).map((function(o){return encodeURIComponent(o)+"="+encodeURIComponent(e[o])})).join("&")},d=function(t,i){if(!t.youtube)return"";var s=t.youtube[2]?function(e){return e.slice(1).split("&").map((function(e){return e.split("=")})).reduce((function(e,o){var t=o.map(decodeURIComponent),i=t[0],s=t[1];return e[i]=s,e}),{})}(t.youtube[2]):"",n=i||{},a=o(o(o({},{autoplay:0,controls:1,enablejsapi:1,hl:"en",loop:0,mute:1,wmode:"opaque",origin:e}),n),s);return"?"+l(a)},c=function(){function e(e){return this.core=e,this.settings=o(o({},t),this.core.settings),this}return e.prototype.init=function(){var e=this;this.core.LGel.on(i+".video",this.onHasVideo.bind(this)),this.core.LGel.on(r+".video",(function(){var o=e.core.getSlideItem(e.core.index);e.loadVideoOnPosterClick(o)})),this.core.LGel.on(s+".video",this.onSlideItemLoad.bind(this)),this.core.LGel.on(n+".video",this.onBeforeSlide.bind(this)),this.core.LGel.on(a+".video",this.onAfterSlide.bind(this))},e.prototype.onSlideItemLoad=function(e){var o=this,t=e.detail,i=t.isFirstSlide,s=t.index;this.settings.autoplayFirstVideo&&i&&s===this.core.index&&setTimeout((function(){o.loadAndPlayVideo(s)}),200),!i&&this.settings.autoplayVideoOnSlide&&s===this.core.index&&this.loadAndPlayVideo(s)},e.prototype.onHasVideo=function(e){var o=e.detail,t=o.index,i=o.src,s=o.html5Video;if(o.hasPoster)this.core.getSlideItem(t);else this.appendVideos(this.core.getSlideItem(t),{src:i,addClass:"lg-object",index:t,html5Video:s}),this.gotoNextSlideOnVideoEnd(i,t)},e.prototype.onBeforeSlide=function(e){if(this.core.lGalleryOn){var o=e.detail.prevIndex;this.pauseVideo(o)}},e.prototype.onAfterSlide=function(e){var o=this,t=e.detail,i=t.index,s=t.prevIndex,n=this.core.getSlideItem(i);this.settings.autoplayVideoOnSlide&&i!==s&&n.hasClass("lg-complete")&&setTimeout((function(){o.loadAndPlayVideo(i)}),100)},e.prototype.loadAndPlayVideo=function(e){var o=this.core.getSlideItem(e);this.core.galleryItems[e].poster?this.loadVideoOnPosterClick(o,!0):this.playVideo(e)},e.prototype.playVideo=function(e){this.controlVideo(e,"play")},e.prototype.pauseVideo=function(e){this.controlVideo(e,"pause")},e.prototype.getVideoHtml=function(e,o,t,i){var s="",n=this.core.galleryItems[t].__slideVideoInfo||{},a=this.core.galleryItems[t],r=a.title||a.alt;r=r?'title="'+r+'"':"";var c='allowtransparency="true"\n frameborder="0"\n scrolling="no"\n allowfullscreen\n mozallowfullscreen\n webkitallowfullscreen\n msallowfullscreen';if(n.youtube){var u="lg-youtube"+t,m=d(n,this.settings.youTubePlayerParams),f=function(e){return e.includes("youtube-nocookie.com")}(e);s='<iframe allow="autoplay" id='+u+' class="lg-video-object lg-youtube '+o+'" '+r+' src="'+(f?"//www.youtube-nocookie.com/":"//www.youtube.com/")+"embed/"+(n.youtube[1]+m)+'" '+c+"></iframe>"}else if(n.vimeo){u="lg-vimeo"+t;var h=function(e,o){if(!o||!o.vimeo)return"";var t=o.vimeo[2]||"",i=e&&0!==Object.keys(e).length?"&"+l(e):"",s=((o.vimeo[0].split("/").pop()||"").split("?")[0]||"").split("#")[0],n=o.vimeo[1]!==s;return n&&(t=t.replace("/"+s,"")),"?autoplay=0&muted=1"+(n?"&h="+s:"")+i+("?"==t[0]?"&"+t.slice(1):t||"")}(this.settings.vimeoPlayerParams,n);s='<iframe allow="autoplay" id='+u+' class="lg-video-object lg-vimeo '+o+'" '+r+' src="//player.vimeo.com/video/'+(n.vimeo[1]+h)+'" '+c+"></iframe>"}else if(n.wistia){var p="lg-wistia"+t;h=(h=l(this.settings.wistiaPlayerParams))?"?"+h:"",s='<iframe allow="autoplay" id="'+p+'" src="//fast.wistia.net/embed/'+n.wistia[3]+(n.wistia[4]+h)+'" '+r+' class="wistia_embed lg-video-object lg-wistia '+o+'" name="wistia_embed" '+c+"></iframe>"}else if(n.dailymotion){var v="lg-dailymotion"+t;h=(h=l(this.settings.dailymotionPlayerParams))?"?"+h:"",s='<iframe allow="autoplay" id="'+v+'" src="//www.dailymotion.com/embed/video/'+(n.dailymotion[1]+h)+'" '+r+' class="dailymotion_embed lg-video-object lg-dailymotion '+o+'" name="dailymotion_embed" '+c+"></iframe>"}else if(n.tiktoc){h=function(e,o){if(!o||!o.tiktok)return"";var t=o.tiktok[2]||"",i=e&&0!==Object.keys(e).length?"&"+l(e):"",s=((o.tiktok[0].split("/").pop()||"").split("?")[0]||"").split("#")[0];return o.tiktok[1]!==s&&(t=t.replace("/"+s,"")),"?autoplay=0&muted=1"+i+("?"==t[0]?"&"+t.slice(1):t||"")}(this.settings.TicTocPlayerParams);s='<iframe allow="autoplay" id='+u+' class="lg-video-object lg-tictoc '+o+'" '+r+' src="//tiktok.com/embed/'+n.tiktoc[1]+'" '+r+c+"></iframe>"}else if(n.html5){for(var y="",g=0;g<i.source.length;g++)y+='<source src="'+i.source[g].src+'" type="'+i.source[g].type+'">';if(i.tracks){var b=function(e){var o="",t=i.tracks[e];Object.keys(t||{}).forEach((function(e){o+=e+'="'+t[e]+'" '})),y+="<track "+o+">"};for(g=0;g<i.tracks.length;g++)b(g)}var w="",k=i.attributes||{};Object.keys(k||{}).forEach((function(e){w+=e+'="'+k[e]+'" '})),s='<video class="lg-video-object lg-html5 '+(this.settings.videojs&&this.settings.videojsTheme?this.settings.videojsTheme+" ":"")+" "+(this.settings.videojs?" video-js":"")+'" '+w+">\n "+y+"\n Your browser does not support HTML5 video.\n </video>"}return s},e.prototype.appendVideos=function(e,o){var t,i=this.getVideoHtml(o.src,o.addClass,o.index,o.html5Video);e.find(".lg-video-cont").append(i);var s=e.find(".lg-video-object").first();if(o.html5Video&&s.on("mousedown.lg.video",(function(e){e.stopPropagation()})),this.settings.videojs&&(null===(t=this.core.galleryItems[o.index].__slideVideoInfo)||void 0===t?void 0:t.html5))try{return videojs(s.get(),this.settings.videojsOptions)}catch(e){console.warn("lightGallery: Make sure you have included videojs")}},e.prototype.gotoNextSlideOnVideoEnd=function(e,o){var t=this,i=this.core.getSlideItem(o).find(".lg-video-object").first(),s=this.core.galleryItems[o].__slideVideoInfo||{};if(this.settings.gotoNextSlideOnVideoEnd)if(s.html5)i.on("ended",(function(){t.core.goToNextSlide()}));else if(s.vimeo)try{new Vimeo.Player(i.get()).on("ended",(function(){t.core.goToNextSlide()}))}catch(e){console.warn("lightGallery: Make sure you have included //github.com/vimeo/player.js")}else if(s.wistia)try{window._wq=window._wq||[],window._wq.push({id:i.attr("id"),onReady:function(e){e.bind("end",(function(){t.core.goToNextSlide()}))}})}catch(e){console.warn("lightGallery: Make sure you have included //fast.wistia.com/assets/external/E-v1.js")}},e.prototype.controlVideo=function(e,t){var i,s,n,a,r,l,d,c,u,m=!1;if(n=this.core.galleryItems[e].__slideVideoInfo||{},s=this.core.getSlideItem(e).find(".lg-video-object").first(),void 0!==this.core.galleryItems[this.core.index].video&&n.html5){if(void 0!==(r=JSON.parse(this.core.galleryItems[this.core.index].video)).tracks&&r.tracks.length>0)for(var f=0;f<r.tracks.length;f++)"chapters"==r.tracks[f].kind&&(i=r.tracks[f].src,m=!0);if(void 0!==s.selector?(l=s.selector.id,d=videojs(l)):d="unknown","unknown"!==d){var h=this.settings.videojsOptions.controlBar.hotkeysPlugin,p=this.settings.videojsOptions.controlBar.zoomPlugin,v=void 0!==this.settings.videojsOptions.controlBar.playbackRates?this.settings.videojsOptions.controlBar.playbackRates:"[0.25, 0.5, 1, 1.5, 2]";if(void 0!==this.settings.videojsOptions.videoStart&&(a=this.settings.videojsOptions.videoStart[e],d.on("play",(function(){var e=new Date("1970-01-01T"+a+"Z").getTime()/1e3;d.currentTime(e)}))),d.playbackRates(v),void 0!==h&&h.enabled&&(h.options=o(o({},{volumeStep:.1,seekStep:5,enableMute:!0,enableVolumeScroll:!0,enableHoverScroll:!1,enableFullscreen:!0,enableNumbers:!0,enableJogStyle:!1,alwaysCaptureHotkeys:!1,captureDocumentHotkeys:!1,enableModifiersForNumbers:!1,enableInactiveFocus:!0,skipInitialFocus:!1}),h.options),d.hotkeys({enableModifiersForNumbers:h.options.enableModifiersForNumbers})),void 0!==p&&p.enabled&&(p.options=o(o({},{moveX:0,moveY:0,rotate:0,zoom:1}),p.options),d.zoomPlugin({moveX:p.options.moveX,moveY:p.options.moveY,rotate:p.options.rotate,zoom:p.options.zoom})),m){var y=new WebVTTParser,g=[];function b(e){for(var o,t=y.parse(e,"metadata"),i=0;i<t.cues.length;i++)o={time:t.cues[i].startTime,label:t.cues[i].text},g.push(o)}c=i,u=b,new WebVTTParser,$.ajax({url:c,type:"GET",success:u,error:function(e){JSON.stringify(e,void 0,2)}}),d.on("play",(function(){d.currentTime(a);var e=d.duration(),o=$(d.controlBar.progressControl.children_[0].el_);setTimeout((function(){var t=setInterval((function(){if(g.length){for(var i=0;i<g.length;i++){var s=g[i].time/e*100+"%",n=g[i].time,a=$('<div class="vjs-chapter-marker" style="left: '+s+'" data-time="'+n+'"> <span>'+g[i].label+"</span></div>");a.click((function(){d.currentTime($(this).data("time"))})),o.append(a)}clearInterval(t)}}),10)}),1e3)}))}}}if(s.get())if(n.youtube)try{s.get().contentWindow.postMessage('{"event":"command","func":"'+t+'Video","args":""}',"*")}catch(w){console.error("lightGallery:- "+w)}else if(n.vimeo)try{new Vimeo.Player(s.get())[t]()}catch(k){console.warn("lightGallery: Make sure you have included //github.com/vimeo/player.js")}else if(n.html5)if(this.settings.videojs)try{videojs(s.get())[t]()}catch(V){console.warn("lightGallery: Make sure you have included videojs")}else s.get()[t]();else if(n.wistia)try{window._wq=window._wq||[],window._wq.push({id:s.attr("id"),onReady:function(e){e[t]()}})}catch(j){console.warn("lightGallery: Make sure you have included //fast.wistia.com/assets/external/E-v1.js")}},e.prototype.loadVideoOnPosterClick=function(e,o){var t=this;if(e.hasClass("lg-video-loaded"))o&&this.playVideo(this.core.index);else if(e.hasClass("lg-has-video"))this.playVideo(this.core.index);else{e.addClass("lg-has-video");var i=void 0,s=this.core.galleryItems[this.core.index].src,n=this.core.galleryItems[this.core.index].video;n&&(i="string"==typeof n?JSON.parse(n):n);var a=this.appendVideos(e,{src:s,addClass:"",index:this.core.index,html5Video:i});this.gotoNextSlideOnVideoEnd(s,this.core.index);var r=e.find(".lg-object").first().get();e.find(".lg-video-cont").first().append(r),e.addClass("lg-video-loading"),a&&a.ready((function(){a.on("loadedmetadata",(function(){t.onVideoLoadAfterPosterClick(e,t.core.index)}))})),e.find(".lg-video-object").first().on("load.lg error.lg loadedmetadata.lg",(function(){setTimeout((function(){t.onVideoLoadAfterPosterClick(e,t.core.index)}),50)}))}},e.prototype.onVideoLoadAfterPosterClick=function(e,o){e.addClass("lg-video-loaded"),this.playVideo(o)},e.prototype.destroy=function(){this.core.LGel.off(".lg.video"),this.core.LGel.off(".video")},e}();return c}));
|
@@ -1,207 +0,0 @@
|
|
1
|
-
/*
|
2
|
-
# -----------------------------------------------------------------------------
|
3
|
-
# ~/assets/theme/j1/modules/lightGallery/js/plugins/lg-vimeo-thumbnail.js
|
4
|
-
# Provides lightGallery JS code for the plugin lgVideo
|
5
|
-
#
|
6
|
-
# Product/Info:
|
7
|
-
# https://jekyll.one
|
8
|
-
#
|
9
|
-
# Copyright (C) 2025 Sachin Neravath
|
10
|
-
# Copyright (C) 2023-2025 Juergen Adams
|
11
|
-
#
|
12
|
-
# J1 Template is licensed under the MIT License.
|
13
|
-
# See: https://github.com/jekyll-one-org/j1-template/blob/main/LICENSE
|
14
|
-
# lightGallery is licensed under the GPLv3 license
|
15
|
-
# See: https://github.com/sachinchoolur/lightGallery/blob/master/LICENSE
|
16
|
-
# -----------------------------------------------------------------------------
|
17
|
-
*/
|
18
|
-
|
19
|
-
/*!
|
20
|
-
* lightgallery | 2.7.2 | September 20th 2023
|
21
|
-
* http://www.lightgalleryjs.com/
|
22
|
-
* Copyright (c) 2020 Sachin Neravath;
|
23
|
-
* @license GPLv3
|
24
|
-
*/
|
25
|
-
|
26
|
-
(function (global, factory) {
|
27
|
-
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
|
28
|
-
typeof define === 'function' && define.amd ? define(factory) :
|
29
|
-
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.lgVimeoThumbnail = factory());
|
30
|
-
}(this, (function () { 'use strict';
|
31
|
-
|
32
|
-
/*! *****************************************************************************
|
33
|
-
Copyright (c) Microsoft Corporation.
|
34
|
-
|
35
|
-
Permission to use, copy, modify, and/or distribute this software for any
|
36
|
-
purpose with or without fee is hereby granted.
|
37
|
-
|
38
|
-
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
39
|
-
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
40
|
-
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
41
|
-
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
42
|
-
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
43
|
-
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
44
|
-
PERFORMANCE OF THIS SOFTWARE.
|
45
|
-
***************************************************************************** */
|
46
|
-
|
47
|
-
var __assign = function() {
|
48
|
-
__assign = Object.assign || function __assign(t) {
|
49
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
50
|
-
s = arguments[i];
|
51
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
|
52
|
-
}
|
53
|
-
return t;
|
54
|
-
};
|
55
|
-
return __assign.apply(this, arguments);
|
56
|
-
};
|
57
|
-
|
58
|
-
function __awaiter(thisArg, _arguments, P, generator) {
|
59
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
60
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
61
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
62
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
63
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
64
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
65
|
-
});
|
66
|
-
}
|
67
|
-
|
68
|
-
function __generator(thisArg, body) {
|
69
|
-
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
70
|
-
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
71
|
-
function verb(n) { return function (v) { return step([n, v]); }; }
|
72
|
-
function step(op) {
|
73
|
-
if (f) throw new TypeError("Generator is already executing.");
|
74
|
-
while (_) try {
|
75
|
-
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
76
|
-
if (y = 0, t) op = [op[0] & 2, t.value];
|
77
|
-
switch (op[0]) {
|
78
|
-
case 0: case 1: t = op; break;
|
79
|
-
case 4: _.label++; return { value: op[1], done: false };
|
80
|
-
case 5: _.label++; y = op[1]; op = [0]; continue;
|
81
|
-
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
82
|
-
default:
|
83
|
-
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
84
|
-
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
85
|
-
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
86
|
-
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
87
|
-
if (t[2]) _.ops.pop();
|
88
|
-
_.trys.pop(); continue;
|
89
|
-
}
|
90
|
-
op = body.call(thisArg, _);
|
91
|
-
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
92
|
-
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
93
|
-
}
|
94
|
-
}
|
95
|
-
|
96
|
-
/**
|
97
|
-
* List of lightGallery events
|
98
|
-
* All events should be documented here
|
99
|
-
* Below interfaces are used to build the website documentations
|
100
|
-
* */
|
101
|
-
var lGEvents = {
|
102
|
-
afterAppendSlide: 'lgAfterAppendSlide',
|
103
|
-
init: 'lgInit',
|
104
|
-
hasVideo: 'lgHasVideo',
|
105
|
-
containerResize: 'lgContainerResize',
|
106
|
-
updateSlides: 'lgUpdateSlides',
|
107
|
-
afterAppendSubHtml: 'lgAfterAppendSubHtml',
|
108
|
-
beforeOpen: 'lgBeforeOpen',
|
109
|
-
afterOpen: 'lgAfterOpen',
|
110
|
-
slideItemLoad: 'lgSlideItemLoad',
|
111
|
-
beforeSlide: 'lgBeforeSlide',
|
112
|
-
afterSlide: 'lgAfterSlide',
|
113
|
-
posterClick: 'lgPosterClick',
|
114
|
-
dragStart: 'lgDragStart',
|
115
|
-
dragMove: 'lgDragMove',
|
116
|
-
dragEnd: 'lgDragEnd',
|
117
|
-
beforeNextSlide: 'lgBeforeNextSlide',
|
118
|
-
beforePrevSlide: 'lgBeforePrevSlide',
|
119
|
-
beforeClose: 'lgBeforeClose',
|
120
|
-
afterClose: 'lgAfterClose',
|
121
|
-
rotateLeft: 'lgRotateLeft',
|
122
|
-
rotateRight: 'lgRotateRight',
|
123
|
-
flipHorizontal: 'lgFlipHorizontal',
|
124
|
-
flipVertical: 'lgFlipVertical',
|
125
|
-
autoplay: 'lgAutoplay',
|
126
|
-
autoplayStart: 'lgAutoplayStart',
|
127
|
-
autoplayStop: 'lgAutoplayStop',
|
128
|
-
};
|
129
|
-
|
130
|
-
var vimeoSettings = {
|
131
|
-
showVimeoThumbnails: true,
|
132
|
-
showThumbnailWithPlayButton: false,
|
133
|
-
};
|
134
|
-
|
135
|
-
/**
|
136
|
-
* Creates the vimeo thumbnails plugin.
|
137
|
-
* @param {object} element - lightGallery element
|
138
|
-
*/
|
139
|
-
var VimeoThumbnail = /** @class */ (function () {
|
140
|
-
function VimeoThumbnail(instance) {
|
141
|
-
this.core = instance;
|
142
|
-
// extend module default settings with lightGallery core settings
|
143
|
-
this.settings = __assign(__assign({}, vimeoSettings), this.core.settings);
|
144
|
-
return this;
|
145
|
-
}
|
146
|
-
VimeoThumbnail.prototype.init = function () {
|
147
|
-
var _this = this;
|
148
|
-
if (!this.settings.showVimeoThumbnails) {
|
149
|
-
return;
|
150
|
-
}
|
151
|
-
this.core.LGel.on(lGEvents.init + ".vimeothumbnails", function (event) {
|
152
|
-
var pluginInstance = event.detail.instance;
|
153
|
-
var thumbCont = pluginInstance.$container
|
154
|
-
.find('.lg-thumb-outer')
|
155
|
-
.get();
|
156
|
-
if (thumbCont) {
|
157
|
-
_this.setVimeoThumbnails(pluginInstance);
|
158
|
-
}
|
159
|
-
});
|
160
|
-
};
|
161
|
-
VimeoThumbnail.prototype.setVimeoThumbnails = function (dynamicGallery) {
|
162
|
-
return __awaiter(this, void 0, void 0, function () {
|
163
|
-
var i, item, slideVideoInfo, response, vimeoInfo;
|
164
|
-
return __generator(this, function (_a) {
|
165
|
-
switch (_a.label) {
|
166
|
-
case 0:
|
167
|
-
i = 0;
|
168
|
-
_a.label = 1;
|
169
|
-
case 1:
|
170
|
-
if (!(i < dynamicGallery.galleryItems.length)) return [3 /*break*/, 5];
|
171
|
-
item = dynamicGallery.galleryItems[i];
|
172
|
-
slideVideoInfo = item.__slideVideoInfo || {};
|
173
|
-
if (!slideVideoInfo.vimeo) return [3 /*break*/, 4];
|
174
|
-
return [4 /*yield*/, fetch('https://vimeo.com/api/oembed.json?url=' +
|
175
|
-
encodeURIComponent(item.src))];
|
176
|
-
case 2:
|
177
|
-
response = _a.sent();
|
178
|
-
return [4 /*yield*/, response.json()];
|
179
|
-
case 3:
|
180
|
-
vimeoInfo = _a.sent();
|
181
|
-
dynamicGallery.$container
|
182
|
-
.find('.lg-thumb-item')
|
183
|
-
.eq(i)
|
184
|
-
.find('img')
|
185
|
-
.attr('src', this.settings.showThumbnailWithPlayButton
|
186
|
-
? vimeoInfo.thumbnail_url_with_play_button
|
187
|
-
: vimeoInfo.thumbnail_url);
|
188
|
-
_a.label = 4;
|
189
|
-
case 4:
|
190
|
-
i++;
|
191
|
-
return [3 /*break*/, 1];
|
192
|
-
case 5: return [2 /*return*/];
|
193
|
-
}
|
194
|
-
});
|
195
|
-
});
|
196
|
-
};
|
197
|
-
VimeoThumbnail.prototype.destroy = function () {
|
198
|
-
// Remove all event listeners added by vimeothumbnails plugin
|
199
|
-
this.core.LGel.off('.lg.vimeothumbnails');
|
200
|
-
this.core.LGel.off('.vimeothumbnails');
|
201
|
-
};
|
202
|
-
return VimeoThumbnail;
|
203
|
-
}());
|
204
|
-
|
205
|
-
return VimeoThumbnail;
|
206
|
-
|
207
|
-
})));
|
@@ -1,26 +0,0 @@
|
|
1
|
-
/*
|
2
|
-
# -----------------------------------------------------------------------------
|
3
|
-
# ~/assets/theme/j1/modules/lightGallery/js/plugins/lg-vimeo-thumbnail.min.js
|
4
|
-
# Provides lightGallery JS code for the plugin lgVideo
|
5
|
-
#
|
6
|
-
# Product/Info:
|
7
|
-
# https://jekyll.one
|
8
|
-
#
|
9
|
-
# Copyright (C) 2025 Sachin Neravath
|
10
|
-
# Copyright (C) 2023-2025 Juergen Adams
|
11
|
-
#
|
12
|
-
# J1 Template is licensed under the MIT License.
|
13
|
-
# See: https://github.com/jekyll-one-org/j1-template/blob/main/LICENSE
|
14
|
-
# lightGallery is licensed under the GPLv3 license
|
15
|
-
# See: https://github.com/sachinchoolur/lightGallery/blob/master/LICENSE
|
16
|
-
# -----------------------------------------------------------------------------
|
17
|
-
*/
|
18
|
-
|
19
|
-
/**
|
20
|
-
* lightgallery | 2.7.2 | September 20th 2023
|
21
|
-
* http://www.lightgalleryjs.com/
|
22
|
-
* Copyright (c) 2020 Sachin Neravath;
|
23
|
-
* @license GPLv3
|
24
|
-
*/
|
25
|
-
|
26
|
-
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).lgVimeoThumbnail=e()}(this,(function(){"use strict";var t=function(){return(t=Object.assign||function(t){for(var e,n=1,o=arguments.length;n<o;n++)for(var i in e=arguments[n])Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i]);return t}).apply(this,arguments)};function e(t,e,n,o){return new(n||(n=Promise))((function(i,r){function u(t){try{a(o.next(t))}catch(t){r(t)}}function l(t){try{a(o.throw(t))}catch(t){r(t)}}function a(t){var e;t.done?i(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(u,l)}a((o=o.apply(t,e||[])).next())}))}function n(t,e){var n,o,i,r,u={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return r={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(r[Symbol.iterator]=function(){return this}),r;function l(r){return function(l){return function(r){if(n)throw new TypeError("Generator is already executing.");for(;u;)try{if(n=1,o&&(i=2&r[0]?o.return:r[0]?o.throw||((i=o.return)&&i.call(o),0):o.next)&&!(i=i.call(o,r[1])).done)return i;switch(o=0,i&&(r=[2&r[0],i.value]),r[0]){case 0:case 1:i=r;break;case 4:return u.label++,{value:r[1],done:!1};case 5:u.label++,o=r[1],r=[0];continue;case 7:r=u.ops.pop(),u.trys.pop();continue;default:if(!(i=u.trys,(i=i.length>0&&i[i.length-1])||6!==r[0]&&2!==r[0])){u=0;continue}if(3===r[0]&&(!i||r[1]>i[0]&&r[1]<i[3])){u.label=r[1];break}if(6===r[0]&&u.label<i[1]){u.label=i[1],i=r;break}if(i&&u.label<i[2]){u.label=i[2],u.ops.push(r);break}i[2]&&u.ops.pop(),u.trys.pop();continue}r=e.call(t,u)}catch(t){r=[6,t],o=0}finally{n=i=0}if(5&r[0])throw r[1];return{value:r[0]?r[1]:void 0,done:!0}}([r,l])}}}var o="lgInit",i={showVimeoThumbnails:!0,showThumbnailWithPlayButton:!1};return function(){function r(e){return this.core=e,this.settings=t(t({},i),this.core.settings),this}return r.prototype.init=function(){var t=this;this.settings.showVimeoThumbnails&&this.core.LGel.on(o+".vimeothumbnails",(function(e){var n=e.detail.instance;n.$container.find(".lg-thumb-outer").get()&&t.setVimeoThumbnails(n)}))},r.prototype.setVimeoThumbnails=function(t){return e(this,void 0,void 0,(function(){var e,o,i;return n(this,(function(n){switch(n.label){case 0:e=0,n.label=1;case 1:return e<t.galleryItems.length?(o=t.galleryItems[e],(o.__slideVideoInfo||{}).vimeo?[4,fetch("https://vimeo.com/api/oembed.json?url="+encodeURIComponent(o.src))]:[3,4]):[3,5];case 2:return[4,n.sent().json()];case 3:i=n.sent(),t.$container.find(".lg-thumb-item").eq(e).find("img").attr("src",this.settings.showThumbnailWithPlayButton?i.thumbnail_url_with_play_button:i.thumbnail_url),n.label=4;case 4:return e++,[3,1];case 5:return[2]}}))}))},r.prototype.destroy=function(){this.core.LGel.off(".lg.vimeothumbnails"),this.core.LGel.off(".vimeothumbnails")},r}()}));
|