This commit is contained in:
seb
2026-10-28 00:08:45 +01:00
parent fab291f68e
commit 96d0ae6742
88 changed files with 3871 additions and 5334 deletions

View File

@@ -9,17 +9,11 @@ import App from './App';
import { getActiveTheme } from './theme';
import { installCssVars } from './colors';
import { disableTouchAutofocus } from './utils/touch';
import './index.css';
// Globally suppress automatic focus on touch devices to avoid virtual keyboard popups
disableTouchAutofocus();
// Side-effect imports: each module registers its automat and subscribes to
// authAutomat, so the stores must be evaluated before the session bootstraps.
import './automats';
import { initPwa } from './automats';
import PwaUpdateDialog from './components/PwaUpdateDialog';
import './index.css';
// Publish the color tokens as CSS custom properties so index.css (and any
// other plain-CSS stylesheet) reads the same palette as the React components.
installCssVars();
@@ -29,12 +23,6 @@ installCssVars();
const AutomatInspector = import.meta.env.DEV
? lazy(() => import('./devtools/AutomatInspector'))
: null;
const SseMonitor = import.meta.env.DEV
? lazy(() => import('./devtools/SseMonitor'))
: null;
const ChunkCacheMonitor = import.meta.env.DEV
? lazy(() => import('./devtools/ChunkCacheMonitor'))
: null;
async function clearDevServiceWorker() {
if (!import.meta.env.DEV || !('serviceWorker' in navigator)) return;
@@ -50,9 +38,6 @@ if (import.meta.env.DEV) {
void clearDevServiceWorker();
}
// Initialize PWA service worker registration and update listener in production
initPwa();
createRoot(document.getElementById('root')).render(
<ThemeProvider theme={getActiveTheme()}>
<CssBaseline />
@@ -74,17 +59,6 @@ createRoot(document.getElementById('root')).render(
</Suspense>
) : null}
</Box>
{SseMonitor ? (
<Suspense fallback={null}>
<SseMonitor />
</Suspense>
) : null}
{ChunkCacheMonitor ? (
<Suspense fallback={null}>
<ChunkCacheMonitor />
</Suspense>
) : null}
<PwaUpdateDialog />
</AuthBootstrap>
</SnackbarProvider>
</ThemeProvider>,