feat(desktop): sync title bar theme with resolved app theme

This commit is contained in:
Mohamed Boudra
2026-03-29 09:26:21 +07:00
parent 921ddf47a8
commit 147482d6ed
3 changed files with 24 additions and 0 deletions
@@ -27,3 +27,12 @@ export async function isDesktopFullscreen(): Promise<boolean> {
}
return await win.isFullscreen();
}
export async function setDesktopTitleBarTheme(theme: "light" | "dark"): Promise<void> {
const win = getDesktopWindow();
if (!win || typeof win.setTitleBarTheme !== "function") {
return;
}
await win.setTitleBarTheme(theme);
}
+1
View File
@@ -51,6 +51,7 @@ export interface DesktopWindowBridge {
endMove?: () => void;
toggleMaximize?: () => Promise<void>;
isFullscreen?: () => Promise<boolean>;
setTitleBarTheme?: (theme: "light" | "dark") => Promise<void>;
onResized?: <TEvent = unknown>(
handler: (event: TEvent) => void,
) => Promise<() => void> | (() => void);