feat: add edutainment drawing and visual package flows

This commit is contained in:
2026-05-14 14:17:10 +08:00
parent 10e8beea80
commit e444266e1e
109 changed files with 8788 additions and 996 deletions

View File

@@ -25,6 +25,9 @@ export type AppRouteMatch =
| {
kind: 'child-motion-demo';
}
| {
kind: 'baby-love-drawing';
}
| {
kind: 'game';
};
@@ -43,6 +46,9 @@ const Match3DPlaygroundApp = lazy(() => import('../Match3DPlaygroundApp')) as Ap
const BarkBattlePlaygroundApp = lazy(() => import('../BarkBattlePlaygroundApp')) as AppRouteComponent;
const PuzzlePlaygroundApp = lazy(() => import('../PuzzlePlaygroundApp')) as AppRouteComponent;
const ChildMotionDemoApp = lazy(() => import('../ChildMotionDemoApp')) as AppRouteComponent;
const BabyLoveDrawingRuntimeApp = lazy(
() => import('../components/edutainment-runtime/BabyLoveDrawingRuntimeShell'),
) as AppRouteComponent;
function normalizeRoutePath(pathname: string) {
return normalizeAppPath(pathname);
@@ -84,6 +90,15 @@ export function matchAppRoute(pathname: string): AppRouteMatch {
};
}
if (
normalizedPath === '/runtime/baby-love-drawing' &&
isEdutainmentEntryEnabled()
) {
return {
kind: 'baby-love-drawing',
};
}
return {
kind: 'game',
};
@@ -137,6 +152,15 @@ export function resolveAppRoute(pathname: string): ResolvedAppRoute {
};
}
if (matchedRoute.kind === 'baby-love-drawing') {
return {
kind: 'baby-love-drawing',
loadingEyebrow: '正在载入宝贝爱画',
loadingText: '正在进入画板...',
Component: BabyLoveDrawingRuntimeApp,
};
}
return {
kind: 'game',
loadingEyebrow: '正在载入游戏',