diff --git a/src/dist/js/qrcode-style-tools.js b/src/dist/js/qrcode-style-tools.js index 7efc934..39abe1f 100644 --- a/src/dist/js/qrcode-style-tools.js +++ b/src/dist/js/qrcode-style-tools.js @@ -95,9 +95,18 @@ }); document.querySelectorAll('#foreground, #background').forEach(function (input) { - input.addEventListener('change', function () { - updateStylePreview(scopeOf(input)); - }); + // bootstrap-colorpicker sets the value and fires 'change' via jQuery's + // synthetic .trigger(), which a native addEventListener never sees - so the + // preview only updates via jQuery's event binding, not the native one below. + if (window.jQuery) { + jQuery(input).on('change', function () { + updateStylePreview(scopeOf(input)); + }); + } else { + input.addEventListener('change', function () { + updateStylePreview(scopeOf(input)); + }); + } }); document.querySelectorAll('select[name="level"]').forEach(function (select) { diff --git a/src/forms/qrcode_options.php b/src/forms/qrcode_options.php index 7f1507e..7c69790 100644 --- a/src/forms/qrcode_options.php +++ b/src/forms/qrcode_options.php @@ -58,7 +58,7 @@ if (QRCODE_GENERATOR === "internal-chillerlan.qrcode") {