From daf3d93bb375ffdf123eccd9bf6f08324ee6a19c Mon Sep 17 00:00:00 2001 From: Tammo ter Hark Date: Tue, 24 Nov 2026 22:33:11 +0100 Subject: [PATCH] fix(options): no loading-spinner flash on options-page load (Prompt I) Remove the show/hide around the init prepare() call in options.js; the spinner keeps its display:none default and is only shown during a real upload (onBeforeSend/onSuccess in BindUpload). Bump OPTIONS_JS_TOKEN to 20261124.4 so browsers fetch the changed options.js once. Generated by Mistral Vibe. Co-Authored-By: Mistral Vibe --- options/options.js | 9 +++++---- options/options.twig | 2 +- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/options/options.js b/options/options.js index 33a088f..3db6ff9 100644 --- a/options/options.js +++ b/options/options.js @@ -694,10 +694,11 @@ $(function () { return deferred.promise(); }; - $('.simple-template-edit-loading').css('display', 'block'); - prepare().then(function (runsesolve) { - $('.simple-template-edit-loading').css('display', 'none'); - }); + // THEME CHANGE (Prompt I): the spinner is NOT shown on page load — nothing + // asynchronous is awaited here (the 650ms timeout existed only to flash it). + // It is still shown during a real upload (onBeforeSend/onSuccess in BindUpload + // below); the element keeps its display:none default in options.twig. + prepare(); $('.selector__open_lightbox').on('click', function (e) { e.preventDefault(); diff --git a/options/options.twig b/options/options.twig index 0dee1d6..7690837 100644 --- a/options/options.twig +++ b/options/options.twig @@ -43,7 +43,7 @@ heuristically cached copy (the file has only Last-Modified/ETag, no Cache-Control). Re-register it with a version token: bump OPTIONS_JS_TOKEN below whenever options/options.js changes, so every browser fetches the new file once. #} -{% set OPTIONS_JS_TOKEN = '20261124.3' %} +{% set OPTIONS_JS_TOKEN = '20261124.4' %} {{ unregisterScriptFile(optionsPath ~ '/options.js') }} {{ registerScriptFile(optionsPath ~ '/options.js?v=' ~ OPTIONS_JS_TOKEN, 'POS_END') }}