j1-template 2024.1.5 → 2024.2.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (195) hide show
  1. checksums.yaml +4 -4
  2. data/_includes/themes/j1/layouts/content_generator_page.html +0 -34
  3. data/_includes/themes/j1/modules/searcher/generator.html +4 -1
  4. data/_includes/themes/j1/modules/searcher/procedures/topsearch.proc +59 -56
  5. data/assets/data/authclient.html +1 -8
  6. data/assets/data/banner.html +1 -7
  7. data/assets/data/fab.html +2 -13
  8. data/assets/data/footer.html +0 -3
  9. data/assets/data/galeries.html +2 -13
  10. data/assets/data/gemini-ui.html +74 -21
  11. data/assets/data/iframes.html +1 -4
  12. data/assets/data/masonry.html +1 -13
  13. data/assets/data/masterslider.html +10 -21
  14. data/assets/data/menu.html +6 -14
  15. data/assets/data/mmenu.html +6 -5
  16. data/assets/data/mmenu_toc.html +2 -1
  17. data/assets/data/panel.html +4 -11
  18. data/assets/data/particles.yml +8 -8
  19. data/assets/data/quicklinks.html +4 -23
  20. data/assets/data/rtext_resizer.html +3 -1
  21. data/assets/data/slick.html +9 -11
  22. data/assets/data/translator.html +0 -1
  23. data/assets/themes/j1/adapter/js/advertising.js +143 -182
  24. data/assets/themes/j1/adapter/js/algolia.js +61 -54
  25. data/assets/themes/j1/adapter/js/analytics.js +68 -52
  26. data/assets/themes/j1/adapter/js/asciidoctor.js +32 -20
  27. data/assets/themes/j1/adapter/js/attic.js +75 -69
  28. data/assets/themes/j1/adapter/js/bmd.js +44 -26
  29. data/assets/themes/j1/adapter/js/carousel.js +117 -92
  30. data/assets/themes/j1/adapter/js/chatbot.js +77 -35
  31. data/assets/themes/j1/adapter/js/clipboard.js +67 -49
  32. data/assets/themes/j1/adapter/js/comments.js +93 -70
  33. data/assets/themes/j1/adapter/js/cookieConsent.js +157 -159
  34. data/assets/themes/j1/adapter/js/customFunctions.js +52 -35
  35. data/assets/themes/j1/adapter/js/customModule.js +61 -50
  36. data/assets/themes/j1/adapter/js/docsearch.js +55 -34
  37. data/assets/themes/j1/adapter/js/dropdowns.js +66 -52
  38. data/assets/themes/j1/adapter/js/fab.js +124 -109
  39. data/assets/themes/j1/adapter/js/gallery.js +68 -49
  40. data/assets/themes/j1/adapter/js/gemini.js +961 -301
  41. data/assets/themes/j1/adapter/js/iconPicker.js +76 -54
  42. data/assets/themes/j1/adapter/js/iconPickerPage.js +279 -0
  43. data/assets/themes/j1/adapter/js/iframer.js +84 -63
  44. data/assets/themes/j1/adapter/js/j1.js +605 -542
  45. data/assets/themes/j1/adapter/js/lazyLoader.js +43 -24
  46. data/assets/themes/j1/adapter/js/lightbox.js +53 -52
  47. data/assets/themes/j1/adapter/js/logger.js +78 -66
  48. data/assets/themes/j1/adapter/js/lunr.js +684 -86
  49. data/assets/themes/j1/adapter/js/masonry.js +84 -68
  50. data/assets/themes/j1/adapter/js/masterslider.js +136 -137
  51. data/assets/themes/j1/adapter/js/mmenu.js +102 -66
  52. data/assets/themes/j1/adapter/js/navigator.js +291 -356
  53. data/assets/themes/j1/adapter/js/particles.js +62 -40
  54. data/assets/themes/j1/adapter/js/rangeSlider.js +66 -48
  55. data/assets/themes/j1/adapter/js/rouge.js +63 -44
  56. data/assets/themes/j1/adapter/js/rtable.js +56 -40
  57. data/assets/themes/j1/adapter/js/rtextResizer.js +57 -44
  58. data/assets/themes/j1/adapter/js/scroller.js +170 -133
  59. data/assets/themes/j1/adapter/js/slick.js +99 -97
  60. data/assets/themes/j1/adapter/js/slimSelect.js +288 -0
  61. data/assets/themes/j1/adapter/js/speak2me.js +124 -128
  62. data/assets/themes/j1/adapter/js/themeToggler.js +118 -97
  63. data/assets/themes/j1/adapter/js/{themer.js → themes.js} +144 -113
  64. data/assets/themes/j1/adapter/js/toccer.js +88 -54
  65. data/assets/themes/j1/adapter/js/translator.js +74 -70
  66. data/assets/themes/j1/adapter/js/waves.js +75 -58
  67. data/assets/themes/j1/core/css/themes/unolight/bootstrap.css +29 -11
  68. data/assets/themes/j1/core/css/themes/unolight/bootstrap.min.css +2 -2
  69. data/assets/themes/j1/core/js/template.js +474 -420
  70. data/assets/themes/j1/core/js/template.min.js +7 -7
  71. data/assets/themes/j1/core/js/template.min.js.map +1 -1
  72. data/assets/themes/j1/modules/carousel/css/theme/uno.css +4 -4
  73. data/assets/themes/j1/modules/carousel/css/theme/uno.min.css +1 -1
  74. data/assets/themes/j1/modules/clipboard/js/clipboard.js +0 -1
  75. data/assets/themes/j1/modules/cookieConsent/js/cookieConsent.js +27 -21
  76. data/assets/themes/j1/modules/iconPicker/css/theme/uno.css +58 -0
  77. data/assets/themes/j1/modules/iconPicker/css/theme/uno.min.css +16 -0
  78. data/assets/themes/j1/modules/iconPicker/js/universal-icon-picker.0.js +493 -0
  79. data/assets/themes/j1/modules/iconPicker/js/universal-icon-picker.js +7 -7
  80. data/assets/themes/j1/modules/js-cookies/js/js.cookie.js +147 -0
  81. data/assets/themes/j1/modules/js-cookies/js/js.cookie.min.js +2 -0
  82. data/assets/themes/j1/modules/lightGallery/js/plugins/lg-video.js +4 -4
  83. data/assets/themes/j1/modules/lightGallery/js/plugins/lg-video.min.js +2 -10
  84. data/assets/themes/j1/modules/lunr/css/j1.css +12 -6
  85. data/assets/themes/j1/modules/lunr/css/j1.min.css +1 -1
  86. data/assets/themes/j1/modules/lunr/js/j1.js +46 -43
  87. data/assets/themes/j1/modules/lunr/js/j1.min.js +1 -1
  88. data/assets/themes/j1/modules/masterslider/js/masterslider.js +1 -1
  89. data/assets/themes/j1/modules/scroller/js/scroller.js +64 -74
  90. data/assets/themes/j1/modules/scroller/js/scroller.min.js +1 -1
  91. data/assets/themes/j1/modules/slick/slider/css/theme/uno.css +4 -4
  92. data/assets/themes/j1/modules/slick/slider/css/theme/uno.min.css +1 -1
  93. data/assets/themes/j1/modules/slimSelect/js/select.js +1865 -1821
  94. data/assets/themes/j1/modules/slimSelect/js/select.min.js +2 -1
  95. data/assets/themes/j1/modules/themeSwitcher/js/switcher.js +87 -89
  96. data/assets/themes/j1/modules/themeSwitcher/js/switcher.min.js +1 -1
  97. data/assets/themes/j1/modules/videojs/js/plugins/vm/api/player.min.js +5 -7
  98. data/assets/themes/j1/modules/videojs/js/plugins/vm/api/v2.20.1/player.min.js +23 -0
  99. data/lib/j1/version.rb +1 -1
  100. data/lib/starter_web/Gemfile +2 -2
  101. data/lib/starter_web/README.md +5 -5
  102. data/lib/starter_web/_config.yml +1 -1
  103. data/lib/starter_web/_data/blocks/_panel.yml +775 -0
  104. data/lib/starter_web/_data/blocks/panel.yml +53 -53
  105. data/lib/starter_web/_data/j1_config.yml +3 -2
  106. data/lib/starter_web/_data/layouts/default.yml +0 -2
  107. data/lib/starter_web/_data/modules/_scroller.yml +102 -0
  108. data/lib/starter_web/_data/modules/carousel.yml +3 -3
  109. data/lib/starter_web/_data/modules/defaults/attics.yml +5 -5
  110. data/lib/starter_web/_data/modules/defaults/docsearch.yml +1 -1
  111. data/lib/starter_web/_data/modules/defaults/gemini.yml +204 -46
  112. data/lib/starter_web/_data/modules/defaults/{iconPicker.yml → icon_picker.yml} +6 -12
  113. data/lib/starter_web/_data/modules/defaults/lunr.yml +20 -5
  114. data/lib/starter_web/_data/modules/defaults/masterslider.yml +4 -4
  115. data/lib/starter_web/_data/modules/defaults/navigator.yml +20 -24
  116. data/lib/starter_web/_data/modules/defaults/particles.yml +3 -3
  117. data/lib/starter_web/_data/modules/defaults/slim_select.yml +54 -0
  118. data/lib/starter_web/_data/modules/defaults/{themer.yml → themes.yml} +10 -10
  119. data/lib/starter_web/_data/modules/defaults/toccer.yml +1 -1
  120. data/lib/starter_web/_data/modules/gallery.yml +33 -38
  121. data/lib/starter_web/_data/modules/gemini.yml +42 -3
  122. data/lib/starter_web/_data/modules/{iconPicker.yml → icon_picker.yml} +31 -3
  123. data/lib/starter_web/_data/modules/lunr.yml +12 -1
  124. data/lib/starter_web/_data/modules/masonry.yml +37 -38
  125. data/lib/starter_web/_data/modules/masterslider.yml +78 -95
  126. data/lib/starter_web/_data/modules/navigator_menu.yml +12 -20
  127. data/lib/starter_web/_data/modules/particles.yml +3 -3
  128. data/lib/starter_web/_data/modules/scroller.yml +3 -3
  129. data/lib/starter_web/_data/modules/slim_select.yml +110 -0
  130. data/lib/starter_web/_data/modules/{themer.yml → themes.yml} +4 -4
  131. data/lib/starter_web/_data/resources.yml +83 -47
  132. data/lib/starter_web/_data/templates/feed.xml +1 -1
  133. data/lib/starter_web/_includes/attributes.asciidoc +354 -355
  134. data/lib/starter_web/_plugins/asciidoctor/gemini-ui-block.rb +1 -1
  135. data/lib/starter_web/_plugins/asciidoctor/slim-select-block.rb +45 -0
  136. data/lib/starter_web/_plugins/index/lunr.rb +1 -1
  137. data/lib/starter_web/collections/asciidoc_skeletons/simple-post/_posts/yyyy-mm-dd-your-post-name.asciidoc +5 -2
  138. data/lib/starter_web/collections/posts/public/featured/_posts/0000-00-00-welcome-to-j1.adoc.erb +3 -3
  139. data/lib/starter_web/collections/posts/public/featured/_posts/2021-01-01-about-cookies.adoc +9 -9
  140. data/lib/starter_web/collections/posts/public/featured/_posts/2021-02-01-static-site-generators.adoc +4 -4
  141. data/lib/starter_web/collections/posts/public/featured/_posts/2022-02-01-about-j1.adoc +3 -2
  142. data/lib/starter_web/collections/posts/public/featured/_posts/2023-10-18-url-types.adoc +12 -12
  143. data/lib/starter_web/package.json +1 -1
  144. data/lib/starter_web/pages/public/about/features.adoc +1 -1
  145. data/lib/starter_web/pages/public/about/reporting_issues.adoc +1 -0
  146. data/lib/starter_web/pages/public/asciidoc_skeletons/documentation/_includes/attributes.asciidoc +44 -44
  147. data/lib/starter_web/pages/public/asciidoc_skeletons/documentation/documentation.adoc +1 -0
  148. data/lib/starter_web/pages/public/asciidoc_skeletons/multi-document/_includes/attributes.asciidoc +12 -12
  149. data/lib/starter_web/pages/public/blog/navigator/archive/allview.html +1 -1
  150. data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/_includes/attributes.asciidoc +42 -28
  151. data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/highlghter_rouge.adoc +1 -0
  152. data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/lunr_search.adoc +1 -0
  153. data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/present_audio_video.adoc +18 -2
  154. data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/present_images.adoc +43 -50
  155. data/lib/starter_web/pages/public/legal/en/100_copyright.adoc +6 -11
  156. data/lib/starter_web/pages/public/legal/en/200_impress.adoc +4 -11
  157. data/lib/starter_web/pages/public/legal/en/300_privacy.adoc +5 -12
  158. data/lib/starter_web/pages/public/legal/en/400_comment_policy.adoc +5 -10
  159. data/lib/starter_web/pages/public/tools/previewer/_includes/attributes.asciidoc +10 -9
  160. data/lib/starter_web/pages/public/tools/previewer/preview_bootstrap_theme.adoc +77 -75
  161. metadata +52 -46
  162. data/lib/starter_web/pages/public/manuals/integrations/gemini/_includes/attributes.asciidoc +0 -47
  163. data/lib/starter_web/pages/public/manuals/integrations/gemini/_includes/documents/preview_google_adsense.asciidoc +0 -448
  164. data/lib/starter_web/pages/public/manuals/integrations/gemini/_includes/documents/readme +0 -0
  165. data/lib/starter_web/pages/public/manuals/integrations/gemini/_includes/tables/readme +0 -0
  166. data/lib/starter_web/pages/public/manuals/integrations/gemini/gemini.adoc +0 -525
  167. data/lib/starter_web/pages/public/manuals/integrations/gemini/security.asccidoc +0 -274
  168. data/lib/starter_web/pages/public/manuals/integrations/gemini/security.hrml +0 -560
  169. /data/lib/starter_web/pages/public/{legal/learn → learn}/bookshelf/article_previewer/viewer_biography.adoc +0 -0
  170. /data/lib/starter_web/pages/public/{legal/learn → learn}/bookshelf/article_previewer/viewer_fantasy.adoc +0 -0
  171. /data/lib/starter_web/pages/public/{legal/learn → learn}/bookshelf/article_previewer/viewer_romance.adoc +0 -0
  172. /data/lib/starter_web/pages/public/{legal/learn → learn}/bookshelf/jekyll_collections.adoc +0 -0
  173. /data/lib/starter_web/pages/public/{legal/learn → learn}/bookshelf/viewer_all_books.adoc +0 -0
  174. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/_includes/documents/100_gistblock.asciidoc +0 -0
  175. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/_includes/documents/410_bottom_info.asciidoc +0 -0
  176. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/_includes/documents/410_bottom_left_warning.asciidoc +0 -0
  177. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/_includes/documents/410_bottom_right_danger.asciidoc +0 -0
  178. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/_includes/documents/410_central_success.asciidoc +0 -0
  179. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/_includes/documents/410_full_height_left_info.asciidoc +0 -0
  180. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/_includes/documents/410_full_height_right_success.asciidoc +0 -0
  181. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/_includes/documents/410_table_bs_modal_examples.asciidoc +0 -0
  182. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/_includes/documents/410_top_info.asciidoc +0 -0
  183. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/_includes/documents/410_top_left_info.asciidoc +0 -0
  184. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/_includes/documents/410_top_right_success.asciidoc +0 -0
  185. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/_includes/documents/419_advanced_modals_demo.asciidoc +0 -0
  186. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/_includes/documents/tables/bs_modal_examples.asciidoc +0 -0
  187. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/_includes/documents/themes_bootstrap.asciidoc +0 -0
  188. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/_includes/documents/themes_rouge.asciidoc +0 -0
  189. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/asciidoc_extensions.adoc +0 -0
  190. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/bootstrap_themes.adoc +0 -0
  191. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/icon_fonts.adoc +0 -0
  192. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/modal_extentions.adoc +0 -0
  193. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/responsive_tables.adoc +0 -0
  194. /data/lib/starter_web/pages/public/{legal/learn → learn}/roundtrip/typography.adoc +0 -0
  195. /data/lib/starter_web/pages/public/{legal/learn → learn}/where_to_go.adoc +0 -0
@@ -63,7 +63,6 @@ regenerate: true
63
63
  {% assign production = true %}
64
64
  {% endif %}
65
65
 
66
-
67
66
  /*
68
67
  # -----------------------------------------------------------------------------
69
68
  # ~/assets/themes/j1/adapter/js/carousel.js
@@ -87,33 +86,41 @@ regenerate: true
87
86
  /* eslint indent: "off" */
88
87
  // -----------------------------------------------------------------------------
89
88
  'use strict';
90
- j1.adapter.carousel = (function (j1, window) {
89
+ j1.adapter.carousel = ((j1, window) => {
91
90
  var environment = '{{environment}}';
92
91
  var dragging = false;
93
92
  var state = 'not_started';
94
93
  var carouselDefaults;
95
94
  var carouselSettings;
96
95
  var carouselOptions;
96
+
97
97
  var _this;
98
98
  var logger;
99
99
  var logText;
100
100
 
101
+ // date|time
102
+ var startTime;
103
+ var endTime;
104
+ var startTimeModule;
105
+ var endTimeModule;
106
+ var timeSeconds;
107
+
101
108
  // ---------------------------------------------------------------------------
102
- // Helper functions
109
+ // helper functions
103
110
  // ---------------------------------------------------------------------------
104
111
 
105
112
  // ---------------------------------------------------------------------------
106
- // Main object
113
+ // main
107
114
  // ---------------------------------------------------------------------------
108
115
  return {
109
116
 
110
117
  // -------------------------------------------------------------------------
111
- // Initializer
118
+ // adapter initializer
112
119
  // -------------------------------------------------------------------------
113
- init: function (options) {
120
+ init: (options) => {
114
121
 
115
122
  // -----------------------------------------------------------------------
116
- // Default module settings
123
+ // default module settings
117
124
  // -----------------------------------------------------------------------
118
125
  var settings = $.extend({
119
126
  module_name: 'j1.adapter.carousel',
@@ -121,23 +128,29 @@ j1.adapter.carousel = (function (j1, window) {
121
128
  }, options);
122
129
 
123
130
  // -----------------------------------------------------------------------
124
- // Global variable settings
131
+ // global variable settings
125
132
  // -----------------------------------------------------------------------
126
133
  _this = j1.adapter.carousel;
127
134
  logger = log4javascript.getLogger('j1.adapter.carousel');
128
135
 
129
- // Load module DEFAULTS|CONFIG
136
+ // load module DEFAULTS|CONFIG
130
137
  carouselDefaults = $.extend({}, {{analytics_defaults | replace: 'nil', 'null' | replace: '=>', ':' }});
131
138
  carouselSettings = $.extend({}, {{analytics_settings | replace: 'nil', 'null' | replace: '=>', ':' }});
132
139
  carouselOptions = $.extend(true, {}, carouselDefaults, carouselSettings);
133
140
 
134
- var dependencies_met_page_finished = setInterval(function() {
135
- var pageState = $('#no_flicker').css("display");
136
- var pageVisible = (pageState == 'block') ? true : false;
137
- var atticFinished = (j1.adapter.attic.getState() == 'finished') ? true: false;
141
+ // intialize select data (for later access)
142
+ _this.carousels = {};
143
+
144
+ // -----------------------------------------------------------------------
145
+ // module initializer
146
+ // -----------------------------------------------------------------------
147
+ var dependencies_met_page_finished = setInterval (() => {
148
+ var pageState = $('#content').css("display");
149
+ var pageVisible = (pageState === 'block') ? true : false;
150
+ var j1CoreFinished = (j1.getState() === 'finished') ? true : false;
138
151
 
139
- if (j1.getState() == 'finished' && pageVisible) {
140
- // if (j1.getState() == 'finished' && pageVisible && atticFinished) {
152
+ if (j1CoreFinished && pageVisible) {
153
+ startTimeModule = Date.now();
141
154
 
142
155
  _this.setState('started');
143
156
  logger.debug('\n' + 'state: ' + _this.getState());
@@ -159,7 +172,7 @@ j1.adapter.carousel = (function (j1, window) {
159
172
  {% assign gridify = item.show.gridify %}
160
173
  {% assign lazyLoad = item.show.lightbox %}
161
174
 
162
- // Create an Carousel INSTANCE if slider on id: {{slider_id}} exists
175
+ // create an Carousel INSTANCE if slider on id: {{slider_id}} exists
163
176
  if ($('#{{slider_id}}').length) {
164
177
 
165
178
  logText = '\n' + 'slider is being processed on id: #{{slider_id}}';
@@ -167,7 +180,7 @@ j1.adapter.carousel = (function (j1, window) {
167
180
  _this.setState('processing');
168
181
 
169
182
  {% if item.show.slide_height != null %}
170
- // Set slide_height: {{item.show.slide_height}}vh
183
+ // set slide_height: {{item.show.slide_height}}vh
171
184
  {% assign slide_height = item.show.slide_height %}
172
185
  $('head').append('<style>.owl-carousel .item{height: {{slide_height}}vh;}</style>');
173
186
  {% endif %}
@@ -197,7 +210,7 @@ j1.adapter.carousel = (function (j1, window) {
197
210
  {% unless parallax %} {% if slider_type == 'text' %}
198
211
  $('head').append('<style>#{{slider_id}}{border-left: 3px solid #0072ff;}</style>');
199
212
  // wait until carousel has been initialized
200
- var dependency_met_owl_initialized = setInterval (function () {
213
+ var dependency_met_owl_initialized = setInterval (() => {
201
214
  if ($('#{{slider_id}} > .owl-wrapper-outer').length) {
202
215
  {% if font_size %}
203
216
  $('head').append('<style>#{{slider_id}}{font-size:{{font_size}}}</style>');
@@ -243,9 +256,15 @@ j1.adapter.carousel = (function (j1, window) {
243
256
  {% endif %}
244
257
 
245
258
  {% if text_color %}
246
- $('#{{slider_id}}').addClass('md-{{text_color}}');
247
- {% else %}
248
- $('#{{slider_id}}').addClass('md-grey-100');
259
+ setTimeout(() => {
260
+ var parentContainer = document.querySelector('#{{slider_id}} div div');
261
+ var paragraphs = parentContainer.getElementsByTagName('p');
262
+
263
+ // add each paragraph custom color
264
+ for (var i=0; i<paragraphs.length; i++) {
265
+ paragraphs[i].style.color = '{{text_color}}';
266
+ }
267
+ }, 500)
249
268
  {% endif %}
250
269
 
251
270
  {% if font_size %}
@@ -266,7 +285,7 @@ j1.adapter.carousel = (function (j1, window) {
266
285
 
267
286
  {% endif %}
268
287
 
269
- // Initialize individual show parameters
288
+ // initialize individual show parameters
270
289
  /* eslint-disable */
271
290
  $('#{{slider_id}}').owlCarousel({
272
291
  {% for option in item.show.options %}
@@ -281,8 +300,8 @@ j1.adapter.carousel = (function (j1, window) {
281
300
  });
282
301
  /* eslint-enable */
283
302
 
284
- // Initialize instance variable (for later access)
285
- j1['{{slider_id}}'] = $('#{{slider_id}}').data('owlCarousel');
303
+ // set instance variable (for later access)
304
+ _this.carousels.{{slider_id}} = $('#{{slider_id}}').data('owlCarousel');
286
305
 
287
306
  // custom show data functions (each slide show)
288
307
  function customDataSuccess_{{forloop.index}}(data){
@@ -358,8 +377,7 @@ j1.adapter.carousel = (function (j1, window) {
358
377
  // );
359
378
 
360
379
  _this.setState('processed');
361
- logText = '\n' + 'processing slider finished on id: {{slider_id}}';
362
- logger.info(logText);
380
+ logger.debug('\n' + 'processing slider finished on id: {{slider_id}}');
363
381
  } // END customDataSuccess_{{forloop.index}}
364
382
  } // END if carousel exists
365
383
  {% endif %}
@@ -367,12 +385,18 @@ j1.adapter.carousel = (function (j1, window) {
367
385
 
368
386
  clearInterval(dependencies_met_page_finished);
369
387
 
370
- var dependencies_met_sliders_processed = setInterval(function() {
371
- if (_this.getState() == 'processed') {
388
+ var dependencies_met_sliders_processed = setInterval(() => {
389
+ var slidersProcessed = (_this.getState() === 'processed') ? true : false;
390
+
391
+ if (slidersProcessed) {
392
+
372
393
  _this.setState('finished');
373
394
  logger.debug('\n' + 'state: ' + _this.getState());
374
395
  logger.info('\n' + 'initializing module finished');
375
396
 
397
+ endTimeModule = Date.now();
398
+ logger.info('\n' + 'module initializing time: ' + (endTimeModule-startTimeModule) + 'ms');
399
+
376
400
  clearInterval(dependencies_met_sliders_processed);
377
401
  }
378
402
  }, 10); // END 'dependencies_met_sliders_processed'
@@ -380,58 +404,15 @@ j1.adapter.carousel = (function (j1, window) {
380
404
  }, 10); // END 'dependencies_met_page_finished'
381
405
  }, // END init
382
406
 
383
- // -------------------------------------------------------------------------
384
- // messageHandler: MessageHandler for J1 CookieConsent module
385
- // Manage messages send from other J1 modules
386
- // -------------------------------------------------------------------------
387
- messageHandler: function (sender, message) {
388
- var json_message = JSON.stringify(message, undefined, 2);
389
-
390
- logText = '\n' + 'received message from ' + sender + ': ' + json_message;
391
- logger.debug(logText);
392
-
393
- // -----------------------------------------------------------------------
394
- // Process commands|actions
395
- // -----------------------------------------------------------------------
396
- if (message.type === 'command' && message.action === 'module_initialized') {
397
- //
398
- // Place handling of command|action here
399
- //
400
- logger.info('\n' + message.text);
401
- }
402
-
403
- //
404
- // Place handling of other command|action here
405
- //
406
-
407
- return true;
408
- }, // END messageHandler
409
-
410
- // -------------------------------------------------------------------------
411
- // setState()
412
- // Sets the current (processing) state of the module
413
- // -------------------------------------------------------------------------
414
- setState: function (stat) {
415
- _this.state = stat;
416
- }, // END setState
417
-
418
- // -------------------------------------------------------------------------
419
- // getState()
420
- // Returns the current (processing) state of the module
421
- // -------------------------------------------------------------------------
422
- getState: function () {
423
- return _this.state;
424
- }, // END getState
425
-
426
407
  // -----------------------------------------------------------------------
427
408
  // Caption text animation (currently NOT used)
428
409
  // -----------------------------------------------------------------------
429
410
 
430
411
  // -------------------------------------------------------------------------
431
412
  // fadeIn()
432
- // Animation (caption): fadeIn
413
+ // animation (caption): fadeIn
433
414
  // -------------------------------------------------------------------------
434
- fadeIn: function (id, options) {
415
+ fadeIn: (id, options) => {
435
416
  $(id + '.active .caption .fadeIn-1').stop().delay(options.delay)
436
417
  .animate({
437
418
  opacity: options.opacity
@@ -457,9 +438,9 @@ j1.adapter.carousel = (function (j1, window) {
457
438
 
458
439
  // -------------------------------------------------------------------------
459
440
  // fadeInUp()
460
- // Animation (caption): fadeInUp
441
+ // animation (caption): fadeInUp
461
442
  // -------------------------------------------------------------------------
462
- fadeInUp: function (id, options) {
443
+ fadeInUp: (id, options) => {
463
444
  $(id + '.active .caption .fadeInUp-1')
464
445
  .stop()
465
446
  .delay(options.delay)
@@ -494,9 +475,9 @@ j1.adapter.carousel = (function (j1, window) {
494
475
 
495
476
  // -------------------------------------------------------------------------
496
477
  // fadeInRight()
497
- // Animation (caption): fadeInRight
478
+ // animation (caption): fadeInRight
498
479
  // -------------------------------------------------------------------------
499
- fadeInRight: function (id, options) {
480
+ fadeInRight: (id, options) => {
500
481
  $(id + '.active .caption .fadeInRight-1')
501
482
  .stop()
502
483
  .delay(options.delay)
@@ -531,9 +512,9 @@ j1.adapter.carousel = (function (j1, window) {
531
512
 
532
513
  // -------------------------------------------------------------------------
533
514
  // fadeInDown()
534
- // Animation (caption): fadeInDown
515
+ // animation (caption): fadeInDown
535
516
  // -------------------------------------------------------------------------
536
- fadeInDown: function (id, options) {
517
+ fadeInDown: (id, options) => {
537
518
  $('#item-1').backstretch();
538
519
  $(id + '.active .caption .fadeInDown-1')
539
520
  .stop()
@@ -569,9 +550,9 @@ j1.adapter.carousel = (function (j1, window) {
569
550
 
570
551
  // -------------------------------------------------------------------------
571
552
  // fadeInLeft()
572
- // Animation (caption): fadeInLeft
553
+ // animation (caption): fadeInLeft
573
554
  // -------------------------------------------------------------------------
574
- fadeInLeft: function (id, options) {
555
+ fadeInLeft: (id, options) => {
575
556
  $('#item-2').backstretch();
576
557
  $(id + '.active .caption .fadeInLeft-1')
577
558
  .stop()
@@ -607,9 +588,9 @@ j1.adapter.carousel = (function (j1, window) {
607
588
 
608
589
  // -------------------------------------------------------------------------
609
590
  // fadeInReset()
610
- // Reset animation (caption): fadeIn
591
+ // reset animation (caption): fadeIn
611
592
  // -------------------------------------------------------------------------
612
- fadeInReset: function (id, options) {
593
+ fadeInReset: (id, options) => {
613
594
  if (!options.dragging) {
614
595
  $(id + '.caption .fadeIn-1,' +
615
596
  id + '.caption .fadeIn-2,' +
@@ -634,9 +615,9 @@ j1.adapter.carousel = (function (j1, window) {
634
615
 
635
616
  // -------------------------------------------------------------------------
636
617
  // fadeInUpReset()
637
- // Reset animation (caption): fadeInUp
618
+ // reset animation (caption): fadeInUp
638
619
  // -------------------------------------------------------------------------
639
- fadeInUpReset: function (id, options) {
620
+ fadeInUpReset: (id, options) => {
640
621
  if (!options.dragging) {
641
622
  $(id + '.caption .fadeInUp-1,' +
642
623
  id + '.caption .fadeInUp-2,' +
@@ -663,9 +644,9 @@ j1.adapter.carousel = (function (j1, window) {
663
644
 
664
645
  // -------------------------------------------------------------------------
665
646
  // fadeInRightReset()
666
- // Reset animation (caption): fadeInRight
647
+ // reset animation (caption): fadeInRight
667
648
  // -------------------------------------------------------------------------
668
- fadeInRightReset: function (id, options) {
649
+ fadeInRightReset: (id, options) => {
669
650
  if (!options.dragging) {
670
651
  $(id + '.caption .fadeInRight-1,' +
671
652
  id + '.caption .fadeInRight-2,' +
@@ -692,9 +673,9 @@ j1.adapter.carousel = (function (j1, window) {
692
673
 
693
674
  // -------------------------------------------------------------------------
694
675
  // fadeOutDown()
695
- // Reset animation (caption): fadeInDown
676
+ // reset animation (caption): fadeInDown
696
677
  // -------------------------------------------------------------------------
697
- fadeInDownReset: function (id, options) {
678
+ fadeInDownReset: (id, options) => {
698
679
  if (!options.dragging) {
699
680
  $(id + '.caption .fadeInDown-1,' +
700
681
  id + '.caption .fadeInDown-2,' +
@@ -721,9 +702,9 @@ j1.adapter.carousel = (function (j1, window) {
721
702
 
722
703
  // -------------------------------------------------------------------------
723
704
  // fadeInLeftReset()
724
- // Reset animation (caption): fadeInLeft
705
+ // reset animation (caption): fadeInLeft
725
706
  // -------------------------------------------------------------------------
726
- fadeInLeftReset: function (id, options) {
707
+ fadeInLeftReset: (id, options) => {
727
708
  if (!options.dragging) {
728
709
  $(id + '.caption .fadeInLeft-1,' +
729
710
  id + '.caption .fadeInLeft-2,' +
@@ -748,8 +729,52 @@ j1.adapter.carousel = (function (j1, window) {
748
729
  }
749
730
  }, // END fadeInLeftReset
750
731
 
751
- }; // END return
732
+ // -------------------------------------------------------------------------
733
+ // messageHandler()
734
+ // manage messages send from other J1 modules
735
+ // -------------------------------------------------------------------------
736
+ messageHandler: (sender, message) => {
737
+ var json_message = JSON.stringify(message, undefined, 2);
738
+
739
+ logText = '\n' + 'received message from ' + sender + ': ' + json_message;
740
+ logger.debug(logText);
741
+
742
+ // -----------------------------------------------------------------------
743
+ // process commands|actions
744
+ // -----------------------------------------------------------------------
745
+ if (message.type === 'command' && message.action === 'module_initialized') {
746
+
747
+ //
748
+ // place handling of command|action here
749
+ //
750
+
751
+ logger.info('\n' + message.text);
752
+ }
753
+
754
+ //
755
+ // place handling of other command|action here
756
+ //
757
+
758
+ return true;
759
+ }, // END messageHandler
760
+
761
+ // -------------------------------------------------------------------------
762
+ // setState()
763
+ // sets the current (processing) state of the module
764
+ // -------------------------------------------------------------------------
765
+ setState: (stat) => {
766
+ _this.state = stat;
767
+ }, // END setState
768
+
769
+ // -------------------------------------------------------------------------
770
+ // getState()
771
+ // Returns the current (processing) state of the module
772
+ // -------------------------------------------------------------------------
773
+ getState: () => {
774
+ return _this.state;
775
+ } // END getState
752
776
 
777
+ }; // END main (return)
753
778
  })(j1, window);
754
779
 
755
780
  {% endcapture %}