fix: sync PWA status bar theme-color with app color scheme (#28006)

This commit is contained in:
黑墨水鱼
2026-05-18 00:12:02 +00:00
committed by GitHub
parent 32f37d86f0
commit 71b27a1b0f
6 changed files with 8 additions and 4 deletions
+4
View File
@@ -16,6 +16,10 @@
document.documentElement.dataset.theme = themeId
document.documentElement.dataset.colorScheme = mode
// Update theme-color meta tag to match app color scheme
var metas = document.querySelectorAll("meta[name='theme-color']")
if (metas.length > 0) metas[0].setAttribute("content", isDark ? "#131010" : "#F8F7F7")
if (themeId === "oc-2") return
var css = localStorage.getItem("opencode-theme-css-" + mode)