From ef0108e8aa9bc737f263de994cd1a42896abcffc Mon Sep 17 00:00:00 2001 From: Andras Bacsai <5845193+andrasbacsai@users.noreply.github.com> Date: Fri, 16 Oct 2026 00:24:26 +0200 Subject: [PATCH] fix(ui): stop Firefox tab restore from switching theme to custom Closes #11813 Co-Authored-By: Claude Opus 5.5 --- .ai/lessons.md | 3 +++ resources/views/components/theme-controls/picker.blade.php | 4 +++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/.ai/lessons.md b/.ai/lessons.md index 091f8b933c..22b9b3295e 100644 --- a/.ai/lessons.md +++ b/.ai/lessons.md @@ -107,3 +107,6 @@ ## Cached and stored state - `StandaloneDocker`/`SwarmDocker` `server` uses `Server::findCached()`, a per-process identity map that is flushed only when the `servers` row updates. A `ServerSetting` save does not flush it, so pass the current `Server` instance (`setRelation('server', $server)`) when generated output depends on just-saved settings. - Application deployments use the stored `custom_labels` when they exist. When a server-level setting changes the generated labels, regenerate the stored labels of read-only (`is_container_label_readonly_enabled`) applications, or a redeploy keeps the old labels. + +## Keep browser form restore away from app state +- Firefox session restore writes saved input values back and fires a trusted `input` event. Add `autocomplete="off"` to inputs that only mirror client state (for example an Alpine-bound color picker), or their handlers run without a user action. diff --git a/resources/views/components/theme-controls/picker.blade.php b/resources/views/components/theme-controls/picker.blade.php index f4b1ede294..4f8dcc4537 100644 --- a/resources/views/components/theme-controls/picker.blade.php +++ b/resources/views/components/theme-controls/picker.blade.php @@ -19,7 +19,9 @@