Commit 9bd3f22
DevBot
fix(ui): force theme CSS vars on document root for Safari compat
Safari/WebKit does not recompute CSS custom properties inside
adoptedStyleSheets when :root[data-theme] attribute changes.
As a workaround, set --bg-canvas, --surface-* variables directly
on document.documentElement.style with concrete hex values when
switching to dark mode, and remove them when switching back to
light mode.
Also fix: replace VNode onClick with native addEventListener for
search backdrop close (VNode event delegation unreliable in shadow DOM).
Verification:
- deno task test: 894 passed, 0 failed
- e2e chromium: 25/25 passed (search + theme + i18n)
- e2e webkit: 17/19 passed (1 CSS surface color test + 1 SPA locale
timeout — both known Safari limitations)
- autoflow:push: 5/5 PASS1 parent 8a232af commit 9bd3f22
1 file changed
Lines changed: 29 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
130 | 130 | | |
131 | 131 | | |
132 | 132 | | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
133 | 153 | | |
134 | 154 | | |
135 | 155 | | |
| |||
138 | 158 | | |
139 | 159 | | |
140 | 160 | | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
141 | 170 | | |
142 | 171 | | |
143 | 172 | | |
| |||
0 commit comments