e9c3dc1120
保留 SpacetimeDB 历史表、迁移白名单与旧业务源码 切换前端 active 入口并解除旧创作页面和路由编译链 移除旧后端路由、worker 与纯业务 crate 依赖 收敛 SpacetimeDB 模块为历史数据壳 同步 Nginx、Pingora、验证门禁与架构文档
40 lines
909 B
TypeScript
40 lines
909 B
TypeScript
/* eslint-disable react-refresh/only-export-components */
|
|
|
|
import { type ComponentType, lazy, type LazyExoticComponent } from 'react';
|
|
|
|
type AppRouteComponent = LazyExoticComponent<
|
|
ComponentType<Record<string, unknown>>
|
|
>;
|
|
|
|
export type AppRouteMatch = {
|
|
kind: 'platform';
|
|
};
|
|
|
|
export type ResolvedAppRoute = {
|
|
kind: AppRouteMatch['kind'];
|
|
loadingEyebrow: string;
|
|
loadingText: string;
|
|
Component: AppRouteComponent;
|
|
};
|
|
|
|
const PlatformApp = lazy(
|
|
() => import('../AuthenticatedApp'),
|
|
) as AppRouteComponent;
|
|
|
|
export function shouldUseRecommendationRouteLoading() {
|
|
return false;
|
|
}
|
|
|
|
export function matchAppRoute(_pathname = ''): AppRouteMatch {
|
|
return { kind: 'platform' };
|
|
}
|
|
|
|
export function resolveAppRoute(_pathname = ''): ResolvedAppRoute {
|
|
return {
|
|
kind: 'platform',
|
|
loadingEyebrow: '正在载入平台',
|
|
loadingText: '正在加载内容',
|
|
Component: PlatformApp,
|
|
};
|
|
}
|