Refine admin PWA dark theme controls
This commit is contained in:
@@ -66,14 +66,15 @@ createRoot(rootEl).render(
|
||||
function AdminApp() {
|
||||
const { resolved } = useAppearance();
|
||||
const themeName = resolved ?? 'light';
|
||||
const adminThemeName = themeName === 'dark' ? 'adminDark' : 'adminLight';
|
||||
|
||||
React.useEffect(() => {
|
||||
prefetchMobileRoutes();
|
||||
}, []);
|
||||
|
||||
return (
|
||||
<TamaguiProvider config={tamaguiConfig} defaultTheme={themeName}>
|
||||
<Theme name={themeName}>
|
||||
<TamaguiProvider config={tamaguiConfig} defaultTheme={adminThemeName}>
|
||||
<Theme name={adminThemeName}>
|
||||
<ConsentProvider>
|
||||
<QueryClientProvider client={queryClient}>
|
||||
<AuthProvider>
|
||||
@@ -87,8 +88,12 @@ function AdminApp() {
|
||||
)}
|
||||
>
|
||||
<div
|
||||
className="font-[Manrope] text-[14px] font-normal leading-[1.6]"
|
||||
style={{ backgroundColor: 'var(--background)', color: 'var(--color)' }}
|
||||
className="tenant-admin-theme font-[Manrope] text-[14px] font-normal leading-[1.6]"
|
||||
style={{
|
||||
backgroundColor: 'var(--background)',
|
||||
color: 'var(--foreground)',
|
||||
colorScheme: themeName === 'dark' ? 'dark' : 'light',
|
||||
}}
|
||||
>
|
||||
<RouterProvider router={router} />
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user