j1-template 2024.3.15 → 2024.3.16
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/assets/data/amplitude.html +7 -7
- data/assets/data/panel.html +4 -3
- data/assets/theme/j1/adapter/js/amplitude.js +100 -81
- data/assets/theme/j1/adapter/js/masonry.js +2 -2
- data/assets/theme/j1/adapter/js/videojs.js +212 -0
- data/assets/theme/j1/core/css/themes/unolight/bootstrap.css +7 -4
- data/assets/theme/j1/core/css/themes/unolight/bootstrap.css.map +1 -1
- data/assets/theme/j1/core/css/themes/unolight/bootstrap.min.css +1 -1
- data/assets/theme/j1/core/css/themes/unolight/bootstrap.min.css.map +1 -1
- data/assets/theme/j1/core/js/template.js +4 -0
- data/assets/theme/j1/core/js/template.min.js +2 -2
- data/assets/theme/j1/core/js/template.min.js.map +1 -1
- data/assets/theme/j1/modules/amplitudejs/css/theme/uno/dark/amplitude.css +81 -1
- data/assets/theme/j1/modules/amplitudejs/css/theme/uno/dark/amplitude.min.css +1 -1
- data/assets/theme/j1/modules/amplitudejs/css/theme/uno/dark/player/compact.css +3 -2
- data/assets/theme/j1/modules/amplitudejs/css/theme/uno/dark/player/compact.min.css +1 -1
- data/assets/theme/j1/modules/amplitudejs/css/theme/uno/dark/player/large.css +19 -4
- data/assets/theme/j1/modules/amplitudejs/css/theme/uno/dark/player/large.min.css +1 -1
- data/assets/theme/j1/modules/amplitudejs/icons/player/dark/artist.svg +78 -0
- data/assets/theme/j1/modules/amplitudejs/icons/player/dark/mute.svg +52 -20
- data/assets/theme/j1/modules/amplitudejs/icons/player/dark/next.svg +20 -39
- data/assets/theme/j1/modules/amplitudejs/icons/player/dark/now-playing.svg +24 -38
- data/assets/theme/j1/modules/amplitudejs/icons/player/dark/playlist-hide.svg +85 -0
- data/assets/theme/j1/modules/amplitudejs/icons/player/dark/playlist-music.svg +85 -0
- data/assets/theme/j1/modules/amplitudejs/icons/player/dark/playlist-show.svg +85 -0
- data/assets/theme/j1/modules/amplitudejs/icons/player/dark/playlist.svg +85 -0
- data/assets/theme/j1/modules/amplitudejs/icons/player/dark/previous.svg +18 -37
- data/assets/theme/j1/modules/amplitudejs/icons/player/dark/skip-backward.svg +33 -30
- data/assets/theme/j1/modules/amplitudejs/icons/player/dark/skip-forward.svg +33 -29
- data/assets/theme/j1/modules/amplitudejs/icons/player/dark/small/next.svg +55 -14
- data/assets/theme/j1/modules/amplitudejs/icons/player/dark/small/previous.svg +56 -14
- data/assets/theme/j1/modules/amplitudejs/icons/player/dark/volume.svg +38 -21
- data/assets/theme/j1/modules/amplitudejs/js/amplitude.map +20 -20
- data/assets/theme/j1/modules/amplitudejs/js/tech/youtube_example.js +211 -0
- data/assets/theme/j1/modules/lightGallery/js/plugins/lg-video.js +206 -122
- data/assets/theme/j1/modules/videojs/assets/icons/custom-icons/next.svg +82 -0
- data/assets/theme/j1/modules/videojs/css/font/README.md +151 -0
- data/assets/theme/j1/modules/videojs/css/font/VideoJS.svg +150 -0
- data/assets/theme/j1/modules/videojs/css/font/video-js-cdn.css +2012 -0
- data/assets/theme/j1/modules/videojs/css/plugins/controls/skipbuttons.0.css +32 -0
- data/assets/theme/j1/modules/videojs/css/plugins/controls/skipbuttons.1.css +31 -0
- data/assets/theme/j1/modules/videojs/css/plugins/controls/skipbuttons.css +31 -0
- data/assets/theme/j1/modules/videojs/css/plugins/controls/skipbuttons.min.css +21 -0
- data/assets/theme/j1/modules/videojs/css/themes/uno.css +14 -3
- data/assets/theme/j1/modules/videojs/css/themes/uno.min.css +1 -1
- data/assets/theme/j1/modules/videojs/css/videojs.css +1 -0
- data/assets/theme/j1/modules/videojs/js/plugins/controls/autocaption/LICENSE +13 -0
- data/assets/theme/j1/modules/videojs/js/plugins/controls/autocaption/README.md +75 -0
- data/assets/theme/j1/modules/videojs/js/plugins/controls/autocaption/autocaption.js +149 -0
- data/assets/theme/j1/modules/videojs/js/plugins/controls/autocaption/autocaption.min.js +21 -0
- data/assets/theme/j1/modules/videojs/js/plugins/controls/hotkeys/README.md +76 -30
- data/assets/theme/j1/modules/videojs/js/plugins/controls/hotkeys/hotkeys.js +64 -53
- data/assets/theme/j1/modules/videojs/js/plugins/controls/hotkeys/hotkeys.min.js +1 -1
- data/assets/theme/j1/modules/videojs/js/plugins/controls/skipbuttons/README.md +133 -0
- data/assets/theme/j1/modules/videojs/js/plugins/controls/skipbuttons/skipbuttons.js +137 -0
- data/assets/theme/j1/modules/videojs/js/plugins/controls/skipbuttons/skipbuttons.min.js +21 -0
- data/assets/theme/j1/modules/videojs/js/plugins/controls/zoom/zoom.js +15 -12
- data/assets/theme/j1/modules/videojs/js/plugins/players/yt/youtube.js +43 -16
- data/lib/j1/patches/rubygems/eventmachine-1.2.7-x64-mingw32/lib/3.3/fastfilereaderext.so +0 -0
- data/lib/j1/patches/rubygems/eventmachine-1.2.7-x64-mingw32/lib/3.3/rubyeventmachine.so +0 -0
- data/lib/j1/patches/rubygems/eventmachine-1.2.7-x64-mingw32/lib/3.4/fastfilereaderext.so +0 -0
- data/lib/j1/patches/rubygems/eventmachine-1.2.7-x64-mingw32/lib/3.4/rubyeventmachine.so +0 -0
- data/lib/j1/version.rb +1 -1
- data/lib/j1_app/j1_auth_manager/config.rb +0 -4
- data/lib/starter_web/Gemfile +45 -22
- data/lib/starter_web/README.md +5 -5
- data/lib/starter_web/_config.yml +4 -6
- data/lib/starter_web/_data/modules/amplitude.yml +9 -399
- data/lib/starter_web/_data/modules/defaults/gallery.yml +42 -0
- data/lib/starter_web/_data/modules/defaults/videojs.yml +107 -0
- data/lib/starter_web/_data/modules/gallery.yml +30 -14
- data/lib/starter_web/_data/modules/masonry.yml +15 -0
- data/lib/starter_web/_data/modules/videojs.yml +57 -0
- data/lib/starter_web/_data/resources.yml +9 -27
- data/lib/starter_web/_data/templates/feed.xml +1 -1
- data/lib/starter_web/_includes/tables/jekyll_variables.asciidoc +1 -0
- data/lib/starter_web/_plugins/asciidoctor/dailymotion-block.rb +4 -1
- data/lib/starter_web/_plugins/asciidoctor/videojs-block.rb +145 -24
- data/lib/starter_web/_plugins/asciidoctor/vimeo-block.rb +4 -1
- data/lib/starter_web/_plugins/asciidoctor/wistia-block.rb +313 -0
- data/lib/starter_web/_plugins/asciidoctor/youtube-block.rb +192 -17
- data/lib/starter_web/_plugins/index/lunr.rb +1 -1
- data/lib/starter_web/package.json +1 -1
- data/lib/starter_web/pages/public/amplitude_yt_tester.adoc +20 -7
- data/lib/starter_web/pages/public/manuals/integrations/amplitudejs/amplitudejs-api.adoc +1 -1
- data/lib/starter_web/pages/public/manuals/integrations/videojs/youtube-api.adoc +1638 -0
- data/lib/starter_web/pages/public/tools/previewer/preview_bootstrap_theme.adoc +5 -6
- data/lib/starter_web/pages/public/tools/previewer/preview_videojs.adoc +203 -0
- data/lib/starter_web/pages/{tour → public/tour}/play_audio.adoc +3 -10
- data/lib/starter_web/pages/{tour → public/tour}/play_video.adoc +49 -40
- metadata +61 -41
- data/assets/theme/j1/modules/amplitudejs/icons/player/dark/_pause.svg +0 -19
- data/assets/theme/j1/modules/amplitudejs/icons/player/dark/_play.svg +0 -18
- data/assets/theme/j1/modules/amplitudejs/icons/player/dark/show-playlist.svg +0 -15
- data/assets/theme/j1/modules/jqueryScrollbar/LICENSE +0 -20
- data/assets/theme/j1/modules/jqueryScrollbar/README.md +0 -28
- data/assets/theme/j1/modules/jqueryScrollbar/css/scrollbar.css +0 -939
- data/assets/theme/j1/modules/jqueryScrollbar/css/scrollbar.min.css +0 -20
- data/assets/theme/j1/modules/jqueryScrollbar/js/scrollbar.js +0 -851
- data/assets/theme/j1/modules/jqueryScrollbar/js/scrollbar.min.js +0 -36
- data/assets/theme/j1/modules/jqueryScrollbar/sass/scrollbar.scss +0 -806
- data/assets/theme/j1/modules/lightGallery/js/plugins/lg-video.0.js +0 -794
- /data/lib/starter_web/pages/{tour → public/tour}/_includes/attributes.asciidoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/_includes/documents/100_gistblock.asciidoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/_includes/documents/410_bottom_info.asciidoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/_includes/documents/410_bottom_left_warning.asciidoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/_includes/documents/410_bottom_right_danger.asciidoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/_includes/documents/410_central_success.asciidoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/_includes/documents/410_full_height_left_info.asciidoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/_includes/documents/410_full_height_right_success.asciidoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/_includes/documents/410_table_bs_modal_examples.asciidoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/_includes/documents/410_top_info.asciidoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/_includes/documents/410_top_left_info.asciidoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/_includes/documents/410_top_right_success.asciidoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/_includes/documents/419_advanced_modals_demo.asciidoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/_includes/documents/tables/bs_modal_examples.asciidoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/_includes/documents/themes_bootstrap.asciidoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/_includes/documents/themes_rouge.asciidoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/asciidoc_extensions.adoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/bootstrap_themes.adoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/highlghter_rouge.adoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/icon_fonts.adoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/modal_extentions.adoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/present_images.adoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/quicksearch.adoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/responsive_tables.adoc +0 -0
- /data/lib/starter_web/pages/{tour → public/tour}/typography.adoc +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 251fb8bf58d0e8b429cc9977024e2cdb33ed2fdbe3c4fd40bee91071a4cfbde7
|
4
|
+
data.tar.gz: 4a29a03ae20e9929dcf8750b57199d1307d2061657414ee1f1bca619f7cb1ea7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0a4be674066ffc6b70b91cc8a6c8db8b3e6cf50dbe3810a363049bd6e69fd0523c353900271a3c4fb32a9accd359885f9d8d66da4b4c18a720af9f481ed01f56
|
7
|
+
data.tar.gz: 0b89aeade5c213100a07267077fdff3391443ac3b13c7a9580c0fe8563a8395f1dd69eed1ffd7d64e9a0b80aaedf3d314825d9c1dee1eb958bd759c5a8d5050d
|
data/assets/data/amplitude.html
CHANGED
@@ -327,8 +327,8 @@ amplitude_defaults: {{amplitude_defaults | debug}}
|
|
327
327
|
<div id="playlist_screen_{{player_id}}" class="compact-player-playlist slide-in-top">
|
328
328
|
|
329
329
|
<div id="hide_playlist_{{player_id}}" class="compact-player-header hide-playlist">
|
330
|
-
<img class="compact-player-header-arrows" src="/assets/theme/j1/modules/amplitudejs/icons/player/dark/
|
331
|
-
|
330
|
+
<img class="compact-player-header-arrows" src="/assets/theme/j1/modules/amplitudejs/icons/player/dark/playlist-hide.svg" alt="Hide Playlist">
|
331
|
+
Playlist
|
332
332
|
</div> <!-- END playlist-screen header (toggle playlist) -->
|
333
333
|
|
334
334
|
{% if playlist_controls %}
|
@@ -375,7 +375,7 @@ amplitude_defaults: {{amplitude_defaults | debug}}
|
|
375
375
|
<!-- START playlist items (COMPACT player )-->
|
376
376
|
<div
|
377
377
|
id="compact_player_title_list_{{player_playlist}}"
|
378
|
-
class="compact-player-title-list">
|
378
|
+
class="amplitude-scroller-gradient compact-player-title-list">
|
379
379
|
{% for item in playlist_items %} {% if item.enabled %}
|
380
380
|
<!-- START list item -->
|
381
381
|
<div
|
@@ -458,8 +458,8 @@ amplitude_defaults: {{amplitude_defaults | debug}}
|
|
458
458
|
</span>
|
459
459
|
<img
|
460
460
|
class="compact-player-header-arrows"
|
461
|
-
src="/assets/theme/j1/modules/amplitudejs/icons/player/dark/
|
462
|
-
alt="
|
461
|
+
src="/assets/theme/j1/modules/amplitudejs/icons/player/dark/playlist-show.svg"
|
462
|
+
alt="Show Playlist">
|
463
463
|
</div> <!-- END compact player header (toggle playlist) -->
|
464
464
|
|
465
465
|
<div class="player-top">
|
@@ -669,7 +669,7 @@ amplitude_defaults: {{amplitude_defaults | debug}}
|
|
669
669
|
<!-- START create player instance on ID: {{player_id}} of type: {{player_type}} -->
|
670
670
|
{% capture large_player_left_side %}
|
671
671
|
<!-- START LARGE player left TOP -->
|
672
|
-
<div
|
672
|
+
<div class="player-left-top">
|
673
673
|
|
674
674
|
<div class="large-player-playlist-header">
|
675
675
|
<span class="audio-artist">
|
@@ -933,7 +933,7 @@ amplitude_defaults: {{amplitude_defaults | debug}}
|
|
933
933
|
<!-- START playlist items (Large Player) -->
|
934
934
|
<div
|
935
935
|
id="large_player_title_list_{{player_playlist}}"
|
936
|
-
class="large-player-title-list">
|
936
|
+
class="amplitude-scroller-gradient large-player-title-list">
|
937
937
|
{% for item in playlist_items %}{% if item.enabled %}
|
938
938
|
<!-- START list item -->
|
939
939
|
<div
|
data/assets/data/panel.html
CHANGED
@@ -21,7 +21,7 @@ exclude_from_search: true
|
|
21
21
|
# NOTE: All panel id's are prefixed by 'panel_'
|
22
22
|
#
|
23
23
|
# -----------------------------------------------------------------------------
|
24
|
-
# Test data:
|
24
|
+
# Test data:More articles can be found
|
25
25
|
# {{ variable | debug }}
|
26
26
|
# -----------------------------------------------------------------------------
|
27
27
|
{% endcomment %}
|
@@ -853,12 +853,13 @@ exclude_from_search: true
|
|
853
853
|
|
854
854
|
<div id="previewer" class="previewer-headline">
|
855
855
|
<div class="post-headline">
|
856
|
-
<h2 id="post-headline" class="notoc notranslate mt-3">
|
856
|
+
<h2 id="post-headline" class="notoc notranslate mt-3">Preview</h2>
|
857
857
|
</div>
|
858
858
|
</div>
|
859
859
|
|
860
860
|
<!-- [INFO ] [~/assets/data/panel.html ] [ blocktype detected as: {{card_block}} ] -->
|
861
861
|
{% if card_block == 'card-list' %}
|
862
|
+
<!-- Recent posts (card-list) -->
|
862
863
|
<div id="{{panel_settings.id}}" class="preview_content">
|
863
864
|
<ul id="{{panel_settings.id}}-scroll-group" class="scroll-group scroll-group-horizontal align-items-stretch flex-wrap">
|
864
865
|
<!-- [INFO ] [~/assets/data/panel.html ] [ write post items (card_block == 'card-list')] -->
|
@@ -929,7 +930,7 @@ exclude_from_search: true
|
|
929
930
|
{% endif %}
|
930
931
|
|
931
932
|
{% if card_block == 'card-deck' %}
|
932
|
-
<!-- Recent posts -->
|
933
|
+
<!-- Recent posts (card-deck) -->
|
933
934
|
<div id="{{panel_settings.id}}" class="row card-deck">
|
934
935
|
<!-- [INFO ] [~/assets/data/panel.html ] [ write post items (card_block == 'card-deck')] -->
|
935
936
|
{% for post in site.posts %} {% for category in post.categories %}
|
@@ -87,10 +87,10 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
87
87
|
|
88
88
|
// göobal settings
|
89
89
|
// ---------------------------------------------------------------------------
|
90
|
-
var environment
|
91
|
-
var cookie_names
|
92
|
-
var user_state
|
93
|
-
var state
|
90
|
+
var environment = '{{environment}}';
|
91
|
+
var cookie_names = j1.getCookieNames();
|
92
|
+
var user_state = j1.readCookie(cookie_names.user_state);
|
93
|
+
var state = 'not_started';
|
94
94
|
|
95
95
|
// module settings
|
96
96
|
// ---------------------------------------------------------------------------
|
@@ -156,23 +156,6 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
156
156
|
// ---------------------------------------------------------------------------
|
157
157
|
// var playerWaveformSampleRate = '{{amplitude_defaults.player.waveform_sample_rate}}';
|
158
158
|
|
159
|
-
// ---------------------------------------------------------------------------
|
160
|
-
// YouTube Player Tech (loaded early, runs on Document Ready)
|
161
|
-
// ---------------------------------------------------------------------------
|
162
|
-
//
|
163
|
-
// $(function() {
|
164
|
-
// // Load YTP API code asynchronously and create a player for later use
|
165
|
-
// var techScript;
|
166
|
-
// var tech = document.createElement('script');
|
167
|
-
//
|
168
|
-
// tech.id = 'yt_player_init';
|
169
|
-
// tech.src = "/assets/theme/j1/modules/amplitudejs/js/tech/ytp.js";
|
170
|
-
// techScript = document.getElementsByTagName('script')[0];
|
171
|
-
//
|
172
|
-
// // Append Tech script
|
173
|
-
// techScript.parentNode.insertBefore(tech, techScript);
|
174
|
-
// });
|
175
|
-
|
176
159
|
// ---------------------------------------------------------------------------
|
177
160
|
// helper functions
|
178
161
|
// ---------------------------------------------------------------------------
|
@@ -208,7 +191,6 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
208
191
|
_this = j1.adapter.amplitude;
|
209
192
|
logger = log4javascript.getLogger('j1.adapter.amplitude');
|
210
193
|
|
211
|
-
|
212
194
|
// -----------------------------------------------------------------------
|
213
195
|
// module initializer
|
214
196
|
// -----------------------------------------------------------------------
|
@@ -224,8 +206,6 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
224
206
|
logger.debug('\n' + 'module state: ' + _this.getState());
|
225
207
|
logger.info('\n' + 'module is being initialized');
|
226
208
|
|
227
|
-
// jQuery('.scrollbar-rail').scrollbar();
|
228
|
-
|
229
209
|
// -------------------------------------------------------------------
|
230
210
|
// create global playlist (songs)
|
231
211
|
// -------------------------------------------------------------------
|
@@ -355,7 +335,7 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
355
335
|
);
|
356
336
|
|
357
337
|
// dynamic loader variable to setup the player on ID {{player.id}}
|
358
|
-
dependency
|
338
|
+
dependency = 'dependencies_met_html_loaded_{{player.id}}';
|
359
339
|
load_dependencies[dependency] = '';
|
360
340
|
|
361
341
|
// ---------------------------------------------------------------------
|
@@ -396,7 +376,6 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
396
376
|
// initApi
|
397
377
|
// -------------------------------------------------------------------------
|
398
378
|
initApi: (songlist) => {
|
399
|
-
|
400
379
|
logger.info('\n' + 'initialze API: started');
|
401
380
|
|
402
381
|
{% comment %} collect playlists
|
@@ -456,6 +435,7 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
456
435
|
// See: https://521dimensions.com/open-source/amplitudejs/docs
|
457
436
|
// NOTE: slider VALUE (volume) is set by DEFAULT settings (player)
|
458
437
|
Amplitude.init({
|
438
|
+
|
459
439
|
bindings: {
|
460
440
|
33: 'play_pause',
|
461
441
|
37: 'prev',
|
@@ -530,13 +510,16 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
530
510
|
} // END if pause on next title
|
531
511
|
}
|
532
512
|
}, // END callbacks
|
513
|
+
|
533
514
|
// waveforms: {
|
534
515
|
// sample_rate: playerWaveformSampleRate
|
535
516
|
// },
|
517
|
+
|
536
518
|
continue_next: playerPlayNextTitle,
|
537
519
|
volume: playerVolumeValue,
|
538
520
|
volume_decrement: playerVolumeSliderStep,
|
539
521
|
volume_increment: playerVolumeSliderStep
|
522
|
+
|
540
523
|
}); // END Amplitude init
|
541
524
|
|
542
525
|
}, // END initApi
|
@@ -548,10 +531,10 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
548
531
|
|
549
532
|
var dependencies_met_player_instances_initialized = setInterval (() => {
|
550
533
|
if (apiInitialized.state) {
|
551
|
-
logger.info('\n' + 'initialize player specific UI events: started');
|
552
|
-
|
553
534
|
var parentContainer = (document.getElementById('{{xhr_container_id}}') !== null) ? true : false;
|
554
535
|
var parentContainerExist = ($('#' + '{{xhr_container_id}}')[0] !== undefined) ? true : false;
|
536
|
+
|
537
|
+
logger.info('\n' + 'initialize player specific UI events: started');
|
555
538
|
|
556
539
|
{% for player in amplitude_options.players %} {% if player.enabled %}
|
557
540
|
{% assign xhr_data_path = amplitude_options.xhr_data_path %}
|
@@ -566,7 +549,7 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
566
549
|
logger.debug('\n' + 'set playlist {{player.playlist}} on id #{{player.id}} with title: ' + playListTitle);
|
567
550
|
|
568
551
|
// dynamic loader variable to setup the player on ID {{player.id}}
|
569
|
-
dependency
|
552
|
+
dependency = 'dependencies_met_player_loaded_{{player.id}}';
|
570
553
|
load_dependencies[dependency] = '';
|
571
554
|
|
572
555
|
// -----------------------------------------------------------------
|
@@ -578,7 +561,6 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
578
561
|
var playerExistsInPage = ($('#' + '{{xhr_container_id}}')[0] !== undefined) ? true : false;
|
579
562
|
|
580
563
|
if (xhrLoadState === 'success' && playerExistsInPage) {
|
581
|
-
// if (xhrLoadState === 'success') {
|
582
564
|
|
583
565
|
// set song (title) specific audio info links
|
584
566
|
// -------------------------------------------------------------
|
@@ -630,11 +612,11 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
630
612
|
{% if player.id contains 'compact' %}
|
631
613
|
// ---------------------------------------------------------
|
632
614
|
// START compact player UI events
|
633
|
-
//
|
615
|
+
//
|
634
616
|
if (document.getElementById('{{player.id}}') !== null) {
|
635
617
|
|
636
|
-
// show|hide scrollbar in playlist
|
637
|
-
// -------------------------------------------------------
|
618
|
+
// show|hide scrollbar in playlist (compact player)
|
619
|
+
// -------------------------------------------------------
|
638
620
|
const songsInPlaylist = Amplitude.getSongsInPlaylist(playListName);
|
639
621
|
if (songsInPlaylist.length <= 8) {
|
640
622
|
const titleListCompactPlayer = document.getElementById('compact_player_title_list_' + playListName);
|
@@ -674,28 +656,28 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
674
656
|
}
|
675
657
|
}
|
676
658
|
}); // END EventListener 'click' (compact player|show playlist)
|
677
|
-
}
|
659
|
+
} // END if showPlaylist
|
678
660
|
|
679
|
-
|
680
|
-
|
681
|
-
|
682
|
-
|
683
|
-
|
661
|
+
// hide playlist
|
662
|
+
var hidePlaylist = document.getElementById("hide_playlist_{{player.id}}");
|
663
|
+
if (hidePlaylist !== null) {
|
664
|
+
hidePlaylist.addEventListener('click', function(event) {
|
665
|
+
var playlistScreen = document.getElementById("playlist_screen_{{player.id}}");
|
684
666
|
|
685
|
-
|
686
|
-
|
687
|
-
|
688
|
-
|
667
|
+
playlistScreen.classList.remove('slide-in-top');
|
668
|
+
playlistScreen.classList.add('slislide-out-top');
|
669
|
+
playlistScreen.style.display = "none";
|
670
|
+
playlistScreen.style.zIndex = "1";
|
689
671
|
|
690
|
-
|
691
|
-
|
692
|
-
|
693
|
-
|
694
|
-
|
695
|
-
|
672
|
+
// enable scrolling
|
673
|
+
if ($('body').hasClass('stop-scrolling')) {
|
674
|
+
$('body').removeClass('stop-scrolling');
|
675
|
+
}
|
676
|
+
}); // END EventListener 'click' (compact player|show playlist)
|
677
|
+
} // END if hidePlaylist
|
696
678
|
|
697
|
-
|
698
|
-
|
679
|
+
// click on progress bar
|
680
|
+
// -------------------------------------------------------
|
699
681
|
|
700
682
|
// getElementsByClassName returns an Array-like object
|
701
683
|
var progressBars = document.getElementsByClassName("compact-player-progress");
|
@@ -709,7 +691,7 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
709
691
|
Amplitude.setSongPlayedPercentage(
|
710
692
|
(parseFloat(xpos)/parseFloat(this.offsetWidth))*100);
|
711
693
|
}); // END EventListener 'click'
|
712
|
-
}
|
694
|
+
} // END for
|
713
695
|
|
714
696
|
// click on skip forward|backward (compact player)
|
715
697
|
// See: https://github.com/serversideup/amplitudejs/issues/384
|
@@ -727,8 +709,8 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
727
709
|
|
728
710
|
if (currentTime > 0) {
|
729
711
|
Amplitude.setSongPlayedPercentage((targetTime / duration) * 100);
|
730
|
-
}
|
731
|
-
});
|
712
|
+
}
|
713
|
+
}); // END EventListener 'click'
|
732
714
|
} // END if ID
|
733
715
|
} // END for SkipForwardButtons
|
734
716
|
|
@@ -744,8 +726,8 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
744
726
|
|
745
727
|
if (currentTime > 0) {
|
746
728
|
Amplitude.setSongPlayedPercentage((targetTime / duration) * 100);
|
747
|
-
}
|
748
|
-
});
|
729
|
+
}
|
730
|
+
}); // END EventListener 'click'
|
749
731
|
} // END if ID
|
750
732
|
} // END for SkipBackwardButtons
|
751
733
|
|
@@ -754,6 +736,7 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
754
736
|
if (compactPlayerShuffleButton) {
|
755
737
|
compactPlayerShuffleButton.addEventListener('click', function(event) {
|
756
738
|
var shuffleState = (document.getElementById('compact_player_shuffle').className.includes('amplitude-shuffle-on')) ? true : false;
|
739
|
+
|
757
740
|
Amplitude.setShuffle(shuffleState)
|
758
741
|
}); // END EventListener 'click'
|
759
742
|
} // END compactPlayerShuffleButton
|
@@ -763,6 +746,7 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
763
746
|
if (compactPlayerRepeatButton) {
|
764
747
|
compactPlayerRepeatButton.addEventListener('click', function(event) {
|
765
748
|
var repeatState = (document.getElementById('compact_player_repeat').className.includes('amplitude-repeat-on')) ? true : false;
|
749
|
+
|
766
750
|
Amplitude.setRepeat(repeatState)
|
767
751
|
}); // END EventListener 'click'
|
768
752
|
} // END compactPlayerRepeatButton
|
@@ -783,7 +767,7 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
783
767
|
if (largePlayerPreviousButton && largePlayerPreviousButton.getAttribute("data-amplitude-source") === 'youtube') {
|
784
768
|
largePlayerPreviousButton.addEventListener('click', function(event) {
|
785
769
|
var playlist = this.getAttribute("data-amplitude-playlist");
|
786
|
-
var songIndex = ytpSongIndex;
|
770
|
+
var songIndex = ytpSongIndex; // Amplitude.getActiveIndex();
|
787
771
|
|
788
772
|
}); // END EventListener 'click'
|
789
773
|
}
|
@@ -827,7 +811,7 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
827
811
|
if (largePlayerNextButton && largePlayerPlayButton.getAttribute("data-amplitude-source") === 'youtube') {
|
828
812
|
largePlayerNextButton.addEventListener('click', function(event) {
|
829
813
|
var playlist = this.getAttribute("data-amplitude-playlist");
|
830
|
-
var songIndex = ytpSongIndex;
|
814
|
+
var songIndex = ytpSongIndex; // Amplitude.getActiveIndex();
|
831
815
|
}); // END EventListener 'click'
|
832
816
|
}
|
833
817
|
|
@@ -838,8 +822,8 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
838
822
|
largetPlayerSongContainer[i].addEventListener('click', function(event) {
|
839
823
|
var playlist = this.getAttribute("data-amplitude-playlist");
|
840
824
|
var playlistLength = largetPlayerSongContainer.length;
|
841
|
-
ytpSongIndex
|
842
|
-
});
|
825
|
+
ytpSongIndex = this.getAttribute("data-amplitude-song-index");
|
826
|
+
}); // END EventListener 'click'
|
843
827
|
} // END if Attribute
|
844
828
|
} // END for
|
845
829
|
|
@@ -854,7 +838,7 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
854
838
|
Amplitude.setSongPlayedPercentage(
|
855
839
|
(parseFloat(xpos)/parseFloat(this.offsetWidth))*100);
|
856
840
|
}); // END EventListener 'click'
|
857
|
-
}
|
841
|
+
} // END for
|
858
842
|
|
859
843
|
// click on skip forward|backward (large player)
|
860
844
|
// See: https://github.com/serversideup/amplitudejs/issues/384
|
@@ -885,9 +869,8 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
885
869
|
if (currentTime > 0) {
|
886
870
|
Amplitude.setSongPlayedPercentage((targetTime / duration) * 100);
|
887
871
|
}
|
888
|
-
}); // END EventListener 'click
|
889
|
-
}
|
890
|
-
|
872
|
+
}); // END EventListener 'click'
|
873
|
+
} // END else
|
891
874
|
} // END if ID
|
892
875
|
} // END for SkipForwardButtons
|
893
876
|
|
@@ -910,8 +893,7 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
910
893
|
Amplitude.setSongPlayedPercentage((targetTime / duration) * 100);
|
911
894
|
}
|
912
895
|
}); // END EventListener 'click'
|
913
|
-
}
|
914
|
-
|
896
|
+
} // END else
|
915
897
|
} // END if ID
|
916
898
|
} // END for SkipBackwardButtons
|
917
899
|
|
@@ -931,14 +913,14 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
931
913
|
var repeatState = (document.getElementById('large_player_repeat').className.includes('amplitude-repeat-on')) ? true : false;
|
932
914
|
Amplitude.setRepeat(repeatState)
|
933
915
|
}); // END EventListener 'click'
|
934
|
-
} // END largePlayerRepeatButton
|
916
|
+
} // END if largePlayerRepeatButton
|
935
917
|
|
936
|
-
// enable|disable scrolling on playlist
|
918
|
+
// enable|disable scrolling on playlist (large player)
|
937
919
|
// -------------------------------------------------------
|
938
920
|
if (document.getElementById('large_player_right') !== null) {
|
939
921
|
|
940
922
|
// show|hide scrollbar in playlist
|
941
|
-
//
|
923
|
+
// -----------------------------------------------------
|
942
924
|
const songsInPlaylist = Amplitude.getSongsInPlaylist(playListName);
|
943
925
|
|
944
926
|
if (songsInPlaylist.length <= 8) {
|
@@ -948,18 +930,38 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
948
930
|
}
|
949
931
|
}
|
950
932
|
|
951
|
-
// scroll to player top position
|
952
|
-
//
|
953
|
-
|
954
|
-
|
955
|
-
|
956
|
-
|
933
|
+
// scroll to player top position (large player)
|
934
|
+
//
|
935
|
+
// Bootstrap grid breakpoints
|
936
|
+
// SN: 576px Mobile
|
937
|
+
// MD: 768px Small Desktop|Tablet
|
938
|
+
// LG: 992px Default Desktop
|
939
|
+
// XL: 1200px Large Desktop
|
940
|
+
// XXL: 1400px X Large Desktop
|
941
|
+
// -----------------------------------------------------
|
942
|
+
var largePlayerPlaylistHeader = document.getElementById("playlist_header_{{player.id}}");
|
943
|
+
|
944
|
+
largePlayerPlaylistHeader.addEventListener('click', function(event) {
|
945
|
+
var playerRight = document.getElementById("{{player.id}}");
|
946
|
+
var playlistHeader = document.getElementById("playlist_header_{{player.id}}");
|
947
|
+
var scrollOffset = (window.innerWidth >= 992) ? -130 : -43;
|
948
|
+
|
949
|
+
// scroll player|playlist to top position (large player)
|
950
|
+
//
|
951
|
+
const targetDivPlayerRight = playerRight;
|
952
|
+
const targetDivPositionPlayerRight = targetDivPlayerRight.offsetTop;
|
953
|
+
const targetDivPlaylistHeader = playlistHeader;
|
954
|
+
const targetDivPositionplaylistHeader = targetDivPlaylistHeader.offsetTop;
|
955
|
+
|
956
|
+
// NOTE: depending on WINDOW SIZE the relation changes to TOP POSITION (targetDivPosition)
|
957
|
+
//
|
958
|
+
if (targetDivPositionPlayerRight > targetDivPositionplaylistHeader) {
|
959
|
+
window.scrollTo(0, targetDivPositionPlayerRight + targetDivPlaylistHeader.offsetParent.firstElementChild.clientHeight + scrollOffset);
|
960
|
+
} else {
|
961
|
+
window.scrollTo(0, targetDivPositionplaylistHeader + scrollOffset);
|
962
|
+
}
|
957
963
|
|
958
|
-
|
959
|
-
const targetDiv = document.getElementById("playlist_header_{{player.id}}");
|
960
|
-
const targetDivPosition = targetDiv.offsetTop;
|
961
|
-
window.scrollTo(0, targetDivPosition + scrollOffset);
|
962
|
-
}); // END EventListener 'click'
|
964
|
+
}); // END EventListener largePlayerPlaylistHeader 'click'
|
963
965
|
|
964
966
|
// disable scrolling (if window viewport >= BS Medium and above)
|
965
967
|
document.getElementById('large_player_right').addEventListener('mouseenter', function() {
|
@@ -981,6 +983,23 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
981
983
|
|
982
984
|
} // END enable|disable scrolling on playlist
|
983
985
|
|
986
|
+
// set volume slider presets (for the player when exists|enabled)
|
987
|
+
//
|
988
|
+
var volumeSlider = document.getElementById('volume_slider_{{player.id}}');
|
989
|
+
if (volumeSlider !== null) {
|
990
|
+
const volumeMin = parseInt('{{player.volume_slider.min_value}}');
|
991
|
+
const volumeMax = parseInt('{{player.volume_slider.max_value}}');
|
992
|
+
const volumeValue = parseInt('{{player.volume_slider.preset_value}}');
|
993
|
+
const volumeStep = parseInt('{{player.volume_slider.slider_step}}');
|
994
|
+
|
995
|
+
// if player has NO slider presets, use amplitude defaults
|
996
|
+
//
|
997
|
+
volumeSlider.min = (isNaN(volumeMin)) ? parseInt('{{amplitude_defaults.player.volume_slider.min_value}}') : volumeMin;
|
998
|
+
volumeSlider.max = (isNaN(volumeMax)) ? parseInt('{{amplitude_defaults.player.volume_slider.max_value}}') : volumeMax;
|
999
|
+
volumeSlider.value = (isNaN(volumeValue)) ? parseInt('{{amplitude_defaults.player.volume_slider.preset_value}}') : volumeValue;
|
1000
|
+
volumeSlider.step = (isNaN(volumeStep)) ? parseInt('{{amplitude_defaults.player.volume_slider.slider_step}}') : volumeStep;
|
1001
|
+
} // END volumeSlider exists
|
1002
|
+
|
984
1003
|
} // END large player UI events
|
985
1004
|
{% endif %}
|
986
1005
|
|
@@ -1135,4 +1154,4 @@ j1.adapter.amplitude = ((j1, window) => {
|
|
1135
1154
|
{{ cache|strip_empty_lines }}
|
1136
1155
|
{%- endif -%}
|
1137
1156
|
|
1138
|
-
{%- assign cache = false -%}
|
1157
|
+
{%- assign cache = false -%}
|
@@ -141,7 +141,7 @@ j1.adapter.masonry = ((j1, window) => {
|
|
141
141
|
// Load module DEFAULTS|CONFIG
|
142
142
|
masonryDefaults = $.extend({}, {{masonry_defaults | replace: 'nil', 'null' | replace: '=>', ':' }});
|
143
143
|
masonrySettings = $.extend({}, {{masonry_settings | replace: 'nil', 'null' | replace: '=>', ':' }});
|
144
|
-
masonryOptions
|
144
|
+
masonryOptions = $.extend(true, {}, masonryDefaults, masonrySettings);
|
145
145
|
|
146
146
|
// load HTML portion for all grids
|
147
147
|
_this.loadGridHTML(masonryOptions, masonryOptions.grids);
|
@@ -153,7 +153,7 @@ j1.adapter.masonry = ((j1, window) => {
|
|
153
153
|
var pageState = $('#content').css("display");
|
154
154
|
var pageVisible = (pageState === 'block') ? true: false;
|
155
155
|
var j1CoreFinished = (j1.getState() === 'finished') ? true : false;
|
156
|
-
|
156
|
+
// var atticFinished = (j1.adapter.attic.getState() == 'finished') ? true : false;
|
157
157
|
|
158
158
|
if (j1CoreFinished && pageVisible) {
|
159
159
|
startTimeModule = Date.now();
|