feat: replace ComponentStack with improved StackRouter with custom context implementation

Squashed commits:

feat: rewrite ComponentStack to be linear instead of nested + custom context implementation

temp: got a solution with only stackRouter, starting testing and code base migrations next

temp2 everything now runs with StackRouter, next up, remove component stack. Make this the commit to implement stackrouter
This commit is contained in:
Aleksi Lassila
2026-02-04 12:26:10 +02:00
parent 3816df0865
commit 5e50de3fef
47 changed files with 1329 additions and 781 deletions

View File

@@ -15,6 +15,7 @@
playableDataContext,
titlePageContext
} from '../ActionsPage/actions-page';
import { componentStackContext } from '$lib/components/ComponentStack/component-stack.store';
export let tmdbId: string;
export let season: number | undefined = undefined;
@@ -24,7 +25,8 @@
playableDataContext.createContext({ tmdbId, season, episode });
const background = getBackgroundPage();
const { componentStack } = titlePageContext.getContext();
// const { componentStack } = titlePageContext.getContext();
const { componentStack } = componentStackContext.getContext();
if (name) breadcrumbsContext.createContext(name);
@@ -47,7 +49,7 @@
/>
</div>
<ComponentStackContainer trapFocus hideSidebar>
<ComponentStackContainer trapFocus sidebar={false}>
<Container
class={classNames('pt-16 flex flex-col min-h-screen bg-primary-900/50', 'h-screen')}
on:back={({ detail }) => {