Apply theme to body so popovers get themed too, make selected popover item more clear

This commit is contained in:
Jon Staab
2025-05-12 09:35:41 -07:00
parent 2f9010cd13
commit 4aaa19ea1b
3 changed files with 23 additions and 15 deletions

View File

@@ -51,9 +51,9 @@
import {setupTracking} from "@app/tracking"
import {setupAnalytics} from "@app/analytics"
import {nsecDecode} from "@lib/util"
import {theme} from "@app/theme"
import {INDEXER_RELAYS, userMembership, ensureUnwrapped, canDecrypt} from "@app/state"
import {loadUserData, listenForNotifications} from "@app/requests"
import {theme} from "@app/theme"
import * as commands from "@app/commands"
import * as requests from "@app/requests"
import * as notifications from "@app/notifications"
@@ -121,6 +121,11 @@
}
}
// Sync theme
theme.subscribe($theme => {
document.body.setAttribute("data-theme", $theme)
})
if (!db) {
setupTracking()
setupAnalytics()
@@ -228,9 +233,9 @@
</svelte:head>
{#await ready}
<div data-theme={$theme}></div>
<div></div>
{:then}
<div data-theme={$theme}>
<div>
<AppContainer>
{@render children()}
</AppContainer>