From c7ac66a5cd444c6da7859c05ef2ebe1cfce3f562 Mon Sep 17 00:00:00 2001 From: nobswebdev Date: Sun, 6 Sep 2026 00:42:10 +0200 Subject: [PATCH] set explicit color-scheme on storefront theme roots Align native browser controls with the active light or dark theme instead of using light dark on html. Co-authored-by: Cursor --- .../src/modules/storefrontCore/public/css/storefront.css | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/backend/src/modules/storefrontCore/public/css/storefront.css b/backend/src/modules/storefrontCore/public/css/storefront.css index 3eb68f9..afa33dd 100644 --- a/backend/src/modules/storefrontCore/public/css/storefront.css +++ b/backend/src/modules/storefrontCore/public/css/storefront.css @@ -1,4 +1,5 @@ :root { + color-scheme: light; --sf-font-sans: 'Helvetica Neue', Helvetica, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', Arial, sans-serif; --sf-font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; @@ -52,6 +53,7 @@ @media (prefers-color-scheme: dark) { :root:not([data-theme='light']) { + color-scheme: dark; --sf-bg: #0a0a0a; --sf-surface: #141414; --sf-surface-muted: #262727; @@ -85,6 +87,7 @@ } :root[data-theme='dark'] { + color-scheme: dark; --sf-bg: #0a0a0a; --sf-surface: #141414; --sf-surface-muted: #262727; @@ -117,6 +120,7 @@ } :root[data-theme='light'] { + color-scheme: light; --sf-bg: #ffffff; --sf-surface: #ffffff; --sf-surface-muted: #f5f7fa; @@ -154,10 +158,6 @@ box-sizing: border-box; } -html { - color-scheme: light dark; -} - body.sf-body { margin: 0; min-height: 100vh;