mirror of
https://github.com/toeverything/AFFiNE.git
synced 2024-12-30 07:03:52 +03:00
fix(component): mobile toast dark mode (#9142)
This commit is contained in:
parent
729c37977e
commit
87bbcae5e2
@ -1,8 +1,12 @@
|
||||
import { useTheme } from 'next-themes';
|
||||
import { Toaster } from 'sonner';
|
||||
|
||||
import { sonner } from './styles.css';
|
||||
|
||||
export function MobileNotificationCenter() {
|
||||
const theme = useTheme();
|
||||
const resolvedTheme = theme.resolvedTheme as 'light' | 'dark';
|
||||
|
||||
return (
|
||||
<Toaster
|
||||
className={sonner}
|
||||
@ -13,6 +17,7 @@ export function MobileNotificationCenter() {
|
||||
top: 'calc(env(safe-area-inset-top) + 16px)',
|
||||
pointerEvents: 'auto',
|
||||
}}
|
||||
theme={resolvedTheme}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user