@shipfox/client-shell 2.0.0 → 4.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/apple-touch-icon.png +0 -0
- package/assets/favicon-96x96.png +0 -0
- package/assets/favicon.ico +0 -0
- package/assets/favicon.svg +1 -0
- package/assets/site.webmanifest +22 -0
- package/assets/web-app-manifest-192x192.png +0 -0
- package/assets/web-app-manifest-512x512.png +0 -0
- package/dist/runtime/auth.d.ts +4 -0
- package/dist/runtime/auth.d.ts.map +1 -1
- package/dist/runtime/auth.js +64 -19
- package/dist/runtime/auth.js.map +1 -1
- package/dist/runtime/last-workspace.d.ts +1 -1
- package/dist/runtime/last-workspace.d.ts.map +1 -1
- package/dist/runtime/last-workspace.js +33 -14
- package/dist/runtime/last-workspace.js.map +1 -1
- package/dist/tsconfig.test.tsbuildinfo +1 -1
- package/dist/vite/index.d.ts +1 -0
- package/dist/vite/index.d.ts.map +1 -1
- package/dist/vite/index.js +1 -0
- package/dist/vite/index.js.map +1 -1
- package/dist/vite/manifest.d.ts +3 -0
- package/dist/vite/manifest.d.ts.map +1 -0
- package/dist/vite/manifest.js +140 -0
- package/dist/vite/manifest.js.map +1 -0
- package/package.json +11 -27
- package/.turbo/turbo-build.log +0 -2
- package/.turbo/turbo-type$colon$emit.log +0 -1
- package/.turbo/turbo-type.log +0 -1
- package/CHANGELOG.md +0 -59
- package/src/components/main-layout.tsx +0 -45
- package/src/components/nav-bar.tsx +0 -41
- package/src/components/nav-tabs.test.tsx +0 -60
- package/src/components/nav-tabs.tsx +0 -47
- package/src/components/not-found-page.tsx +0 -14
- package/src/components/settings-nav.tsx +0 -35
- package/src/components/user-menu.tsx +0 -59
- package/src/components/workspace-crumb.tsx +0 -43
- package/src/components/workspace-switcher.tsx +0 -75
- package/src/compose/compose-routes.test.ts +0 -112
- package/src/compose/compose-routes.ts +0 -60
- package/src/compose/errors.ts +0 -54
- package/src/compose/merge-config.test.ts +0 -26
- package/src/compose/merge-config.ts +0 -27
- package/src/compose/normalize-route-path.ts +0 -6
- package/src/compose/validate-providers.test.ts +0 -31
- package/src/compose/validate-providers.ts +0 -36
- package/src/compose/validate-registries.test.ts +0 -92
- package/src/compose/validate-registries.ts +0 -61
- package/src/config/config-screen.test.tsx +0 -37
- package/src/config/shell-config.ts +0 -10
- package/src/contract.ts +0 -47
- package/src/index.ts +0 -1
- package/src/runtime/active-workspace.ts +0 -13
- package/src/runtime/anchor-paths.ts +0 -18
- package/src/runtime/anchors.tsx +0 -106
- package/src/runtime/assemble-route-tree.ts +0 -42
- package/src/runtime/auth.tsx +0 -213
- package/src/runtime/chrome-context.tsx +0 -22
- package/src/runtime/compose-client-app.tsx +0 -122
- package/src/runtime/define-route.test.ts +0 -15
- package/src/runtime/define-route.ts +0 -33
- package/src/runtime/index.ts +0 -19
- package/src/runtime/last-workspace.ts +0 -22
- package/src/runtime/nav-order.ts +0 -1
- package/src/runtime/provider-stack.tsx +0 -39
- package/src/runtime/providers.test.tsx +0 -51
- package/src/runtime/registries.test.tsx +0 -100
- package/src/runtime/registries.ts +0 -42
- package/src/runtime/router-context.ts +0 -9
- package/src/runtime/routes.test.tsx +0 -48
- package/src/runtime/workspace-setup.tsx +0 -61
- package/src/testing/index.test.tsx +0 -57
- package/src/testing/index.tsx +0 -51
- package/src/vite/evaluate-features.test.ts +0 -89
- package/src/vite/evaluate-features.ts +0 -114
- package/src/vite/generate.test.ts +0 -22
- package/src/vite/generate.ts +0 -99
- package/src/vite/generated-router.test.tsx +0 -58
- package/src/vite/index.ts +0 -1
- package/src/vite/plugin.test.ts +0 -231
- package/src/vite/plugin.ts +0 -101
- package/src/vite/validate.test.ts +0 -166
- package/test/default-route-impl.tsx +0 -3
- package/test/external/FINDINGS.md +0 -41
- package/test/external/README.md +0 -37
- package/test/external/fixture/index.html +0 -12
- package/test/external/fixture/package.json +0 -31
- package/test/external/fixture/src/app.fixture.tsx +0 -104
- package/test/external/fixture/src/features/external-settings.tsx +0 -19
- package/test/external/fixture/src/features/login-override.tsx +0 -9
- package/test/external/fixture/src/features.collision.ts +0 -15
- package/test/external/fixture/src/features.ts +0 -50
- package/test/external/fixture/src/link-typecheck.tsx +0 -10
- package/test/external/fixture/src/main.tsx +0 -86
- package/test/external/fixture/src/provider.ts +0 -45
- package/test/external/fixture/tsconfig.json +0 -15
- package/test/external/fixture/vite.config.ts +0 -21
- package/test/external/fixture/vitest.config.ts +0 -17
- package/test/external/verify.mjs +0 -488
- package/test/fixtures/features.ts +0 -56
- package/test/named-route-impl.tsx +0 -3
- package/test/render.tsx +0 -67
- package/test/search-route-impl.tsx +0 -7
- package/test/setup.ts +0 -3
- package/test/typecheck/shipfox-app.gen.ts +0 -85
- package/test/typecheck/types.tsx +0 -23
- package/tsconfig.build.json +0 -10
- package/tsconfig.build.tsbuildinfo +0 -1
- package/tsconfig.json +0 -1
- package/tsconfig.test.json +0 -12
- package/vitest.config.ts +0 -22
|
@@ -1,85 +0,0 @@
|
|
|
1
|
-
// GENERATED by @shipfox/client-shell/vite. Do not edit.
|
|
2
|
-
// biome-ignore-all format: generated code has stable, reviewable output.
|
|
3
|
-
// biome-ignore-all assist/source/organizeImports: generated imports follow route order.
|
|
4
|
-
import {createRoute, createRouter} from '@tanstack/react-router';
|
|
5
|
-
import {buildAnchorSkeleton, isRouteImpl, type RouteImpl, type RouterContext} from '@shipfox/client-shell/runtime';
|
|
6
|
-
import * as route0Module from "#test/search-route-impl.js";
|
|
7
|
-
import * as route1Module from "#test/default-route-impl.js";
|
|
8
|
-
import * as route2Module from "#test/named-route-impl.js";
|
|
9
|
-
|
|
10
|
-
function routeOptions<T extends RouteImpl>(routeImpl: T, impl: string, path: string): T['options'] {
|
|
11
|
-
if (!isRouteImpl(routeImpl)) {
|
|
12
|
-
throw new TypeError(`Route implementation "${impl}" for "${path}" must export default defineRoute(...).`);
|
|
13
|
-
}
|
|
14
|
-
return routeImpl.options;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
const skeleton = buildAnchorSkeleton({
|
|
18
|
-
navigation: [
|
|
19
|
-
{
|
|
20
|
-
"id": "projects",
|
|
21
|
-
"scope": "workspace",
|
|
22
|
-
"label": "Projects",
|
|
23
|
-
"to": "/workspaces/$wid/projects/$pid/overview",
|
|
24
|
-
"order": 100
|
|
25
|
-
},
|
|
26
|
-
{
|
|
27
|
-
"id": "insights",
|
|
28
|
-
"scope": "workspace",
|
|
29
|
-
"label": "Insights",
|
|
30
|
-
"to": "/workspaces/$wid/insights",
|
|
31
|
-
"order": 200
|
|
32
|
-
}
|
|
33
|
-
],
|
|
34
|
-
settingsSections: [
|
|
35
|
-
{
|
|
36
|
-
"id": "members",
|
|
37
|
-
"pathSegment": "members",
|
|
38
|
-
"label": "Members",
|
|
39
|
-
"icon": "users",
|
|
40
|
-
"order": 100
|
|
41
|
-
}
|
|
42
|
-
],
|
|
43
|
-
});
|
|
44
|
-
|
|
45
|
-
const route0 = createRoute({
|
|
46
|
-
getParentRoute: () => skeleton.projectLayout,
|
|
47
|
-
path: "/overview",
|
|
48
|
-
...routeOptions(route0Module.default, "#test/search-route-impl.js", "/workspaces/$wid/projects/$pid/overview"),
|
|
49
|
-
});
|
|
50
|
-
|
|
51
|
-
const route1 = createRoute({
|
|
52
|
-
getParentRoute: () => skeleton.workspaceSettings,
|
|
53
|
-
path: "/members",
|
|
54
|
-
...routeOptions(route1Module.default, "#test/default-route-impl.js", "/workspaces/$wid/settings/members"),
|
|
55
|
-
});
|
|
56
|
-
|
|
57
|
-
const route2 = createRoute({
|
|
58
|
-
getParentRoute: () => skeleton.workspaceLayout,
|
|
59
|
-
path: "/insights",
|
|
60
|
-
...routeOptions(route2Module.default, "#test/named-route-impl.js", "/workspaces/$wid/insights"),
|
|
61
|
-
});
|
|
62
|
-
|
|
63
|
-
const projectLayout = skeleton.projectLayout.addChildren([route0]);
|
|
64
|
-
const workspaceSettings = skeleton.workspaceSettings.addChildren([route1]);
|
|
65
|
-
const workspaceLayout = skeleton.workspaceLayout.addChildren([
|
|
66
|
-
route2,
|
|
67
|
-
projectLayout,
|
|
68
|
-
workspaceSettings,
|
|
69
|
-
]);
|
|
70
|
-
|
|
71
|
-
export const routeTree = skeleton.rootRoute.addChildren([
|
|
72
|
-
workspaceLayout,
|
|
73
|
-
]);
|
|
74
|
-
|
|
75
|
-
export const router = createRouter({
|
|
76
|
-
routeTree,
|
|
77
|
-
context: {auth: undefined, queryClient: undefined} satisfies RouterContext,
|
|
78
|
-
scrollRestoration: true,
|
|
79
|
-
});
|
|
80
|
-
|
|
81
|
-
declare module '@tanstack/react-router' {
|
|
82
|
-
interface Register {
|
|
83
|
-
router: typeof router;
|
|
84
|
-
}
|
|
85
|
-
}
|
package/test/typecheck/types.tsx
DELETED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import {getRouteApi, Link, useSearch} from '@tanstack/react-router';
|
|
2
|
-
import './shipfox-app.gen.js';
|
|
3
|
-
|
|
4
|
-
export function CompositionTypes(): React.ReactNode {
|
|
5
|
-
const search = useSearch({from: '/workspaces/$wid/projects/$pid/overview'});
|
|
6
|
-
const tab: 'activity' | 'overview' = search.tab;
|
|
7
|
-
|
|
8
|
-
getRouteApi('/workspaces/$wid/projects/$pid/overview');
|
|
9
|
-
|
|
10
|
-
// @ts-expect-error The generated route tree rejects unknown route ids.
|
|
11
|
-
getRouteApi('/not-a-route');
|
|
12
|
-
|
|
13
|
-
return (
|
|
14
|
-
<>
|
|
15
|
-
<Link to="/workspaces/$wid/insights" params={{wid: 'workspace'}}>
|
|
16
|
-
Insights
|
|
17
|
-
</Link>
|
|
18
|
-
<span>{tab}</span>
|
|
19
|
-
{/* @ts-expect-error The generated route tree rejects unknown paths. */}
|
|
20
|
-
<Link to="/not-a-route">Missing route</Link>
|
|
21
|
-
</>
|
|
22
|
-
);
|
|
23
|
-
}
|
package/tsconfig.build.json
DELETED