feat(ui): migrate routes and app shell to controller-driven state

This commit is contained in:
2026-03-02 14:15:00 +00:00
parent 13e77294be
commit 531e77d900
8 changed files with 660 additions and 30 deletions

View File

@@ -2,6 +2,7 @@
import './layout.css';
import { onMount } from 'svelte';
import favicon from '$lib/assets/favicon.svg';
import { appController } from '$lib/app/controller';
let { children } = $props();
@@ -9,13 +10,10 @@
const bodyClasses = ['h-screen', 'bg-[#0a0a0c]', 'text-gray-200', 'overflow-hidden', 'flex'];
document.body.classList.add(...bodyClasses);
document.documentElement.dataset.theme = 'black';
const simWindow = window as Window & { __mobileSimLoaded?: boolean };
if (!simWindow.__mobileSimLoaded) {
simWindow.__mobileSimLoaded = true;
void import('$lib/sim/mobile-sim.js');
}
void appController.init();
return () => {
void appController.destroy();
document.body.classList.remove(...bodyClasses);
};
});