fix(desktop): eliminate white flash on window resize in dark mode
Set native window backgroundColor to match the app's surface0 color so the backing layer is dark during resize repaints. Extend the existing updateWindowControls IPC to also call setBackgroundColor on all platforms (including macOS), keeping the renderer as the single source of truth for theme resolution. Add a prefers-color-scheme CSS rule in index.html to cover the HTML-to-React mount gap.
This commit is contained in:
@@ -19,6 +19,12 @@
|
||||
body {
|
||||
overflow: hidden;
|
||||
}
|
||||
/* Prevent white flash before React mounts */
|
||||
@media (prefers-color-scheme: dark) {
|
||||
html, body {
|
||||
background-color: #181B1A;
|
||||
}
|
||||
}
|
||||
/* These styles make the root element full-height */
|
||||
#root {
|
||||
display: flex;
|
||||
|
||||
Reference in New Issue
Block a user