From c6523b30f92f3744c3d88783e9a49403b395a902 Mon Sep 17 00:00:00 2001 From: xiaoqidun Date: Sat, 31 Oct 2026 16:12:09 +0800 Subject: [PATCH] =?UTF-8?q?feat(=E7=95=8C=E9=9D=A2=E8=AE=BE=E8=AE=A1):=20?= =?UTF-8?q?=E8=A1=A5=E9=BD=90=E4=BA=91=E6=AF=8DAlt=E5=91=BD=E5=90=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- assets/webui/index.html | 2 +- assets/webui/ofdgo.css | 4 ++-- internal/webview/webview_theme.go | 6 +++--- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/assets/webui/index.html b/assets/webui/index.html index b33bc13..0a18b2c 100644 --- a/assets/webui/index.html +++ b/assets/webui/index.html @@ -481,7 +481,7 @@
- +
diff --git a/assets/webui/ofdgo.css b/assets/webui/ofdgo.css index e1be214..e086b6d 100644 --- a/assets/webui/ofdgo.css +++ b/assets/webui/ofdgo.css @@ -5101,7 +5101,7 @@ audio.page-media { .theme-light-icon, .theme-dark-icon, .material-solid-icon, -.material-mica-icon, +.material-mica-alt-icon, .material-acrylic-icon { display: inline-block; width: 18px; @@ -5130,7 +5130,7 @@ audio.page-media { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='3' width='18' height='18' rx='1'/%3E%3Cpath d='M6 6h12v12H6z' fill='black' fill-opacity='.25' stroke='none'/%3E%3C/svg%3E"); } -.material-mica-icon { +.material-mica-alt-icon { --icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='3' width='18' height='18' rx='1'/%3E%3Cpath d='M3 13c6-7 12 7 18-2M3 18c6-7 12 7 18-2'/%3E%3C/svg%3E"); } diff --git a/internal/webview/webview_theme.go b/internal/webview/webview_theme.go index a030b9e..064d6da 100644 --- a/internal/webview/webview_theme.go +++ b/internal/webview/webview_theme.go @@ -72,7 +72,7 @@ func (a applicationTheme) validate() error { if a.Mode == "light" && a.Dark || a.Mode == "dark" && !a.Dark { return fmt.Errorf("主题配色无效") } - if a.Material != "solid" && a.Material != "mica" && a.Material != "acrylic" { + if a.Material != "solid" && a.Material != "mica-alt" && a.Material != "acrylic" { return fmt.Errorf("窗口材质无效") } return nil @@ -92,7 +92,7 @@ func (h *Host) themeIndex() ([]byte, error) { mode = "system" } materials := []string{"solid"} - for _, choice := range []string{"acrylic", "mica"} { + for _, choice := range []string{"acrylic", "mica-alt"} { if windowMaterial(choice) != guigo.WindowSolid { materials = append(materials, choice) } @@ -163,7 +163,7 @@ func (h *Host) setTheme(value applicationTheme) (err error) { func windowMaterial(value string) guigo.WindowMaterial { material := guigo.WindowSolid switch value { - case "mica": + case "mica-alt": material = guigo.WindowMicaAlt case "acrylic": material = guigo.WindowAcrylic