lib/starter_web/assets/themes/j1/adapter/js/stickybits.js in j1_template-2019.4.7 vs lib/starter_web/assets/themes/j1/adapter/js/stickybits.js in j1_template-2019.4.8
- old
+ new
@@ -42,32 +42,33 @@
{% assign blocks = site.data.blocks %}
{% assign modules = site.data.modules %}
{% comment %} Set config data
-------------------------------------------------------------------------------- {% endcomment %}
-{% assign stickybits_config = modules.j1_stickybits.default %}
+{% assign stickybits_defaults = modules.defaults.stickybits.defaults %}
+{% assign stickybits_settings = modules.stickybits.settings %}
{% comment %} Set config options
-------------------------------------------------------------------------------- {% endcomment %}
+{% assign stickybits_options = stickybits_defaults | merge: stickybits_settings %}
/*
# -----------------------------------------------------------------------------
- # ~/assets/themes/j1/adapter/js/stickybits.js
- # JS Adapter for J1 Stickybits
+ # ~/assets/themes/j1/adapter/js/stickybits.js
+ # JS Adapter for J1 Stickybits
#
- # Product/Info:
- # https://jekyll.one
- # https://github.com/dollarshaveclub/stickybits
+ # Product/Info:
+ # https://jekyll.one
+ # https://github.com/dollarshaveclub/stickybits
#
- # Copyright (C) 2019 Juergen Adams
- # Copyright (C) 2016 Dollar Shave Club, Inc.
+ # Copyright (C) 2019 Juergen Adams
+ # Copyright (C) 2016 Dollar Shave Club, Inc.
#
- # J1 Template is licensed under the MIT License.
- # For details, see https://jekyll.one
- #
+ # J1 Template is licensed under the MIT License.
+ # For details, see https://jekyll.one
# -----------------------------------------------------------------------------
- # Adapter generated: {{site.time}}
+ # Adapter generated: {{site.time}}
# -----------------------------------------------------------------------------
*/
'use strict';
{% comment %} Main
@@ -100,10 +101,10 @@
logger = log4javascript.getLogger('j1.adapter.stickybits');
state = 'started';
logger.info('state: ' + state);
- stickybitsInstance = stickybits('{{stickybits_config.selector}}', {
+ stickybitsInstance = stickybits('{{stickybits_options.selector}}', {
useStickyClasses: {{site.data.modules.j1_stickybits.default.useStickyClasses}},
stickyBitStickyOffset: "{{site.data.modules.j1_stickybits.default.offset}}px"
});
state = 'finished';