assets/themes/j1/adapter/js/dropdowns.js in j1-template-2022.3.0.rc1 vs assets/themes/j1/adapter/js/dropdowns.js in j1-template-2022.3.0
- old
+ new
@@ -46,12 +46,10 @@
{% comment %} Set config options
-------------------------------------------------------------------------------- {% endcomment %}
{% assign dropdowns_options = dropdowns_defaults | merge: dropdowns_settings %}
-{% comment %} Detect prod mode
--------------------------------------------------------------------------------- {% endcomment %}
{% assign production = false %}
{% if environment == 'prod' or environment == 'production' %}
{% assign production = true %}
{% endif %}
@@ -127,10 +125,10 @@
// create settings object from frontmatterOptions
frontmatterOptions = options != null ? $.extend({}, options) : {};
moduleOptions = $.extend({}, {{dropdowns_options | replace: 'nil', 'null' | replace: '=>', ':' }});
if (typeof frontmatterOptions !== 'undefined') {
- moduleOptions = $.extend({}, moduleOptions, frontmatterOptions);;
+ moduleOptions = j1.mergeData(moduleOptions, frontmatterOptions);
}
var dependencies_met_j1_finished = setInterval(function() {
if (j1.getState() == 'finished') {
var elms = document.querySelectorAll('.dropdowns');