From 159bc0fb4ea7e64c02343dc4e2ea21e30a1d55e4 Mon Sep 17 00:00:00 2001 From: Lukas Rieger Date: Mon, 16 Dec 2024 17:01:14 +0100 Subject: [PATCH] WIP --- ui/src/app/user/user.component.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/src/app/user/user.component.ts b/ui/src/app/user/user.component.ts index dabb33081c..2bdb67968e 100644 --- a/ui/src/app/user/user.component.ts +++ b/ui/src/app/user/user.component.ts @@ -96,7 +96,7 @@ export class UserComponent implements OnInit { if (theme === Theme.SYSTEM) { attr = window.matchMedia("(prefers-color-scheme: dark)").matches ? Theme.DARK : Theme.LIGHT; } - document.documentElement.setAttribute("data-theme", attr); + document.body.setAttribute("data-theme", attr); } public static getPreferedColorSchemeFromTheme(theme: Theme) {