@jskit-ai/agent-docs 0.1.149 → 0.1.150
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/guide/agent/app-setup/existing-application-migration.md +8 -6
- package/guide/agent/app-setup/initial-scaffolding.md +9 -7
- package/guide/agent/app-setup/quickstart.md +9 -6
- package/guide/agent/framework/application-operations.md +91 -0
- package/guide/agent/framework/crud-operations.md +83 -0
- package/guide/agent/framework/material-3.md +112 -0
- package/guide/agent/framework/ui-operations.md +78 -0
- package/guide/agent/index.md +13 -3
- package/package.json +1 -1
- package/patterns/feature-package/example/booking-engine/package.json +1 -1
- package/patterns/minimal-foundation/example/AGENTS.md +8 -8
- package/patterns/minimal-foundation/example/package.json +4 -5
- package/patterns/shell-foundation/example/AGENTS.md +8 -8
- package/patterns/shell-foundation/example/package.json +5 -6
- package/patterns/shell-foundation/example/packages/main/package.json +1 -1
- package/reference/autogen/PATTERN_INDEX.md +61 -61
- package/skills/jskit/SKILL.md +8 -5
- package/skills/jskit/references/app-operations.md +12 -11
- package/skills/jskit/references/crud-operations.md +10 -6
- package/skills/jskit/references/existing-application-migration.md +9 -12
- package/skills/jskit/references/material-3.md +2 -0
- package/skills/jskit/references/pattern-index.md +61 -61
- package/skills/jskit/references/patterns/app/minimal-foundation/PATTERN.md +105 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/.nvmrc +1 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/AGENTS.md +17 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/Procfile +2 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/app.json +14 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/bin/develop.js +71 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/bin/server.js +8 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/config/public.js +40 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/config/server.js +1 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/config/surfaceAccessPolicies.js +3 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/eslint.config.mjs +19 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/favicon.svg +7 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/gitignore +9 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/index.html +13 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/jsconfig.json +8 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/package.json +62 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/packages/main/package.json +42 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/packages/main/src/shared/index.js +10 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/packages/main/src/shared/schemas/index.js +22 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/playwright.config.mjs +31 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/server/lib/runtimeEnv.js +45 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/server/lib/surfaceRuntime.js +10 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/server.js +195 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/src/App.vue +13 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/src/main.js +85 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/src/pages/home/index.vue +48 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/src/pages/home.vue +13 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/src/views/NotFound.vue +13 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/tests/client/smoke.vitest.js +7 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/tests/e2e/base-shell.spec.ts +23 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/tests/server/smoke.test.js +16 -0
- package/skills/jskit/references/patterns/app/minimal-foundation/example/vite.config.mjs +80 -0
- package/skills/jskit/references/patterns/app/shell-foundation/PATTERN.md +111 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/.nvmrc +1 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/AGENTS.md +17 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/Procfile +2 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/app.json +14 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/bin/develop.js +71 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/bin/server.js +8 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/config/public.js +40 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/config/server.js +1 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/config/surfaceAccessPolicies.js +3 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/eslint.config.mjs +19 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/favicon.svg +7 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/gitignore +9 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/index.html +13 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/jsconfig.json +8 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/package.json +64 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/packages/main/package.json +56 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/packages/main/src/client/index.js +9 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/packages/main/src/client/providers/MainClientProvider.js +18 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/packages/main/src/shared/index.js +10 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/packages/main/src/shared/schemas/index.js +22 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/playwright.config.mjs +31 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/server/lib/runtimeEnv.js +45 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/server/lib/surfaceRuntime.js +10 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/server.js +195 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/src/App.vue +11 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/src/components/ShellLayout.vue +12 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/src/components/menus/MenuLinkItem.vue +30 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/src/components/menus/SurfaceAwareMenuLinkItem.vue +42 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/src/components/menus/TabLinkItem.vue +42 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/src/error.js +19 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/src/main.js +85 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/src/pages/home/index.vue +116 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/src/pages/home/settings/general/index.vue +40 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/src/pages/home/settings/index.vue +7 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/src/pages/home/settings.vue +109 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/src/pages/home.vue +20 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/src/placement.js +56 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/src/placementTopology.js +149 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/src/views/NotFound.vue +13 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/tests/client/smoke.vitest.js +7 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/tests/e2e/adaptive-shell.spec.ts +10 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/tests/e2e/base-shell.spec.ts +23 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/tests/server/smoke.test.js +16 -0
- package/skills/jskit/references/patterns/app/shell-foundation/example/vite.config.mjs +80 -0
- package/skills/jskit/references/patterns/assistant/assistant-surface/PATTERN.md +77 -0
- package/skills/jskit/references/patterns/assistant/assistant-surface/example/config/public.js +19 -0
- package/skills/jskit/references/patterns/assistant/assistant-surface/example/config/server.js +9 -0
- package/skills/jskit/references/patterns/assistant/assistant-surface/example/src/pages/admin/assistant/index.vue +7 -0
- package/skills/jskit/references/patterns/assistant/assistant-surface/example/src/pages/admin/settings/assistant/index.vue +7 -0
- package/skills/jskit/references/patterns/assistant/assistant-surface/example/src/placement.js +38 -0
- package/skills/jskit/references/patterns/auth/auth-surface/PATTERN.md +90 -0
- package/skills/jskit/references/patterns/auth/auth-surface/example/src/pages/auth/login.vue +17 -0
- package/skills/jskit/references/patterns/auth/auth-surface/example/src/pages/auth/reset-password.vue +17 -0
- package/skills/jskit/references/patterns/auth/auth-surface/example/src/pages/auth/signout.vue +17 -0
- package/skills/jskit/references/patterns/auth/auth-surface/example/src/runtime/authGuardRuntime.js +7 -0
- package/skills/jskit/references/patterns/auth/auth-surface/example/src/runtime/authHttpClient.js +1 -0
- package/skills/jskit/references/patterns/auth/auth-surface/example/src/runtime/useSignOut.js +1 -0
- package/skills/jskit/references/patterns/auth/auth-surface/example/src/views/auth/LoginView.vue +7 -0
- package/skills/jskit/references/patterns/auth/auth-surface/example/src/views/auth/ResetPasswordView.vue +7 -0
- package/skills/jskit/references/patterns/auth/auth-surface/example/src/views/auth/SignOutView.vue +7 -0
- package/skills/jskit/references/patterns/auth/auth-surface/example/tools/preview-identity +5 -0
- package/skills/jskit/references/patterns/auth/supabase-auth/PATTERN.md +67 -0
- package/skills/jskit/references/patterns/auth/supabase-auth/example/.env.example +4 -0
- package/skills/jskit/references/patterns/auth/supabase-auth/example/config/server.js +11 -0
- package/skills/jskit/references/patterns/auth/supabase-auth/example/package.json +7 -0
- package/skills/jskit/references/patterns/console/console-surface/PATTERN.md +58 -0
- package/skills/jskit/references/patterns/console/console-surface/example/src/pages/console/index.vue +62 -0
- package/skills/jskit/references/patterns/console/console-surface/example/src/pages/console/settings/index.vue +17 -0
- package/skills/jskit/references/patterns/console/console-surface/example/src/pages/console/settings.vue +95 -0
- package/skills/jskit/references/patterns/console/console-surface/example/src/pages/console.vue +20 -0
- package/skills/jskit/references/patterns/crud/crud-screen-set/PATTERN.md +88 -0
- package/skills/jskit/references/patterns/crud/crud-screen-set/example/books/BookEditPage.vue +54 -0
- package/skills/jskit/references/patterns/crud/crud-screen-set/example/books/BookFormFields.vue +52 -0
- package/skills/jskit/references/patterns/crud/crud-screen-set/example/books/BookListPage.vue +54 -0
- package/skills/jskit/references/patterns/crud/crud-screen-set/example/books/BookNewPage.vue +45 -0
- package/skills/jskit/references/patterns/crud/crud-screen-set/example/books/BookViewPage.vue +50 -0
- package/skills/jskit/references/patterns/crud/crud-screen-set/example/books/formFields.js +31 -0
- package/skills/jskit/references/patterns/crud/crud-screen-set/example/books/listExtensions.js +9 -0
- package/skills/jskit/references/patterns/crud/json-api-resource-package/PATTERN.md +160 -0
- package/skills/jskit/references/patterns/crud/json-api-resource-package/example/migrations/20260815000000_books.cjs +22 -0
- package/skills/jskit/references/patterns/crud/json-api-resource-package/example/packages/books/package.json +41 -0
- package/skills/jskit/references/patterns/crud/json-api-resource-package/example/packages/books/src/server/BooksFeature.js +13 -0
- package/skills/jskit/references/patterns/crud/json-api-resource-package/example/packages/books/src/shared/bookResource.js +83 -0
- package/skills/jskit/references/patterns/crud/json-api-resource-package/example/packages/books/src/shared/index.js +1 -0
- package/skills/jskit/references/patterns/crud/resource-contract/PATTERN.md +102 -0
- package/skills/jskit/references/patterns/crud/resource-contract/example/bookResource.js +87 -0
- package/skills/jskit/references/patterns/database/mysql-application/PATTERN.md +80 -0
- package/skills/jskit/references/patterns/database/mysql-application/example/.env.example +5 -0
- package/skills/jskit/references/patterns/database/mysql-application/example/.github/workflows/verify.yml +39 -0
- package/skills/jskit/references/patterns/database/mysql-application/example/knexfile.js +11 -0
- package/skills/jskit/references/patterns/database/mysql-application/example/package.json +13 -0
- package/skills/jskit/references/patterns/database/mysql-application/example/scripts/prepare-database.js +3 -0
- package/skills/jskit/references/patterns/database/postgres-application/PATTERN.md +80 -0
- package/skills/jskit/references/patterns/database/postgres-application/example/.env.example +5 -0
- package/skills/jskit/references/patterns/database/postgres-application/example/.github/workflows/verify.yml +38 -0
- package/skills/jskit/references/patterns/database/postgres-application/example/knexfile.js +11 -0
- package/skills/jskit/references/patterns/database/postgres-application/example/package.json +13 -0
- package/skills/jskit/references/patterns/database/postgres-application/example/scripts/prepare-database.js +3 -0
- package/skills/jskit/references/patterns/mobile/android-application/PATTERN.md +71 -0
- package/skills/jskit/references/patterns/mobile/android-application/example/capacitor.config.json +10 -0
- package/skills/jskit/references/patterns/realtime/realtime-application/PATTERN.md +69 -0
- package/skills/jskit/references/patterns/realtime/realtime-application/example/.env.example +1 -0
- package/skills/jskit/references/patterns/realtime/realtime-application/example/package.json +8 -0
- package/skills/jskit/references/patterns/realtime/realtime-application/example/src/placement.js +17 -0
- package/skills/jskit/references/patterns/server/feature-package/PATTERN.md +108 -0
- package/skills/jskit/references/patterns/server/feature-package/example/booking-engine/package.json +48 -0
- package/skills/jskit/references/patterns/server/feature-package/example/booking-engine/src/server/BookingEngineProvider.js +33 -0
- package/skills/jskit/references/patterns/server/feature-package/example/booking-engine/src/server/actions.js +26 -0
- package/skills/jskit/references/patterns/server/feature-package/example/booking-engine/src/server/inputSchemas.js +19 -0
- package/skills/jskit/references/patterns/server/feature-package/example/variations/AvailabilityEngineProvider.js +31 -0
- package/skills/jskit/references/patterns/server/feature-package/example/variations/InvoiceRollupProvider.js +36 -0
- package/skills/jskit/references/patterns/server/feature-package/example/variations/customKnexRepository.js +34 -0
- package/skills/jskit/references/patterns/server/feature-package/example/variations/orchestratorService.js +23 -0
- package/skills/jskit/references/patterns/shell/application-shell/PATTERN.md +66 -0
- package/skills/jskit/references/patterns/shell/application-shell/example/expected-existing/src/App.vue +13 -0
- package/skills/jskit/references/patterns/shell/application-shell/example/expected-existing/src/pages/home/index.vue +48 -0
- package/skills/jskit/references/patterns/shell/application-shell/example/expected-existing/src/pages/home.vue +13 -0
- package/skills/jskit/references/patterns/shell/application-shell/example/src/App.vue +11 -0
- package/skills/jskit/references/patterns/shell/application-shell/example/src/components/ShellLayout.vue +13 -0
- package/skills/jskit/references/patterns/shell/application-shell/example/src/components/menus/MenuLinkItem.vue +30 -0
- package/skills/jskit/references/patterns/shell/application-shell/example/src/components/menus/SurfaceAwareMenuLinkItem.vue +42 -0
- package/skills/jskit/references/patterns/shell/application-shell/example/src/components/menus/TabLinkItem.vue +42 -0
- package/skills/jskit/references/patterns/shell/application-shell/example/src/error.js +19 -0
- package/skills/jskit/references/patterns/shell/application-shell/example/src/pages/home/index.vue +106 -0
- package/skills/jskit/references/patterns/shell/application-shell/example/src/pages/home/settings/general/index.vue +40 -0
- package/skills/jskit/references/patterns/shell/application-shell/example/src/pages/home/settings/index.vue +7 -0
- package/skills/jskit/references/patterns/shell/application-shell/example/src/pages/home/settings.vue +109 -0
- package/skills/jskit/references/patterns/shell/application-shell/example/src/pages/home.vue +20 -0
- package/skills/jskit/references/patterns/shell/application-shell/example/src/placement.js +56 -0
- package/skills/jskit/references/patterns/shell/application-shell/example/src/placementTopology.js +149 -0
- package/skills/jskit/references/patterns/shell/application-shell/example/tests/e2e/adaptive-shell.spec.ts +10 -0
- package/skills/jskit/references/patterns/ui/page-and-placement/PATTERN.md +76 -0
- package/skills/jskit/references/patterns/ui/page-and-placement/example/packages/main/src/client/providers/MainClientProvider.js +14 -0
- package/skills/jskit/references/patterns/ui/page-and-placement/example/src/components/SyncStatusElement.vue +16 -0
- package/skills/jskit/references/patterns/ui/page-and-placement/example/src/pages/home/reports/activity.vue +8 -0
- package/skills/jskit/references/patterns/ui/page-and-placement/example/src/pages/home/reports/index.vue +7 -0
- package/skills/jskit/references/patterns/ui/page-and-placement/example/src/pages/home/reports/overview.vue +8 -0
- package/skills/jskit/references/patterns/ui/page-and-placement/example/src/pages/home/reports.vue +33 -0
- package/skills/jskit/references/patterns/ui/page-and-placement/example/src/placement.js +52 -0
- package/skills/jskit/references/patterns/ui/page-and-placement/example/src/placementTopology.js +29 -0
- package/skills/jskit/references/patterns/users/account-settings/PATTERN.md +61 -0
- package/skills/jskit/references/patterns/users/account-settings/example/src/components/account/settings/AccountSettingsNotificationsSection.vue +81 -0
- package/skills/jskit/references/patterns/users/account-settings/example/src/components/account/settings/AccountSettingsPreferencesSection.vue +151 -0
- package/skills/jskit/references/patterns/users/account-settings/example/src/components/account/settings/AccountSettingsProfileSection.vue +120 -0
- package/skills/jskit/references/patterns/users/account-settings/example/src/pages/account/index.vue +17 -0
- package/skills/jskit/references/patterns/users/user-administration-server/PATTERN.md +64 -0
- package/skills/jskit/references/patterns/users/user-administration-server/example/packages/users/package.json +42 -0
- package/skills/jskit/references/patterns/users/user-administration-server/example/packages/users/src/server/UsersFeature.js +13 -0
- package/skills/jskit/references/patterns/users/user-administration-server/example/packages/users/src/shared/index.js +1 -0
- package/skills/jskit/references/patterns/users/user-administration-server/example/packages/users/src/shared/userResource.js +69 -0
- package/skills/jskit/references/patterns/users/user-administration-server/example/packages/users-workspace/package.json +43 -0
- package/skills/jskit/references/patterns/users/user-administration-server/example/packages/users-workspace/src/server/UsersWorkspaceFeature.js +22 -0
- package/skills/jskit/references/patterns/users/user-administration-server/example/packages/users-workspace/src/shared/index.js +1 -0
- package/skills/jskit/references/patterns/users/user-administration-server/example/packages/users-workspace/src/shared/userResource.js +56 -0
- package/skills/jskit/references/patterns/workspaces/workspace-server/PATTERN.md +60 -0
- package/skills/jskit/references/patterns/workspaces/workspace-server/example/config/roles.js +27 -0
- package/skills/jskit/references/patterns/workspaces/workspace-server/example/packages/main/src/server/email/workspaceInviteEmail.js +23 -0
- package/skills/jskit/references/patterns/workspaces/workspace-surfaces/PATTERN.md +63 -0
- package/skills/jskit/references/patterns/workspaces/workspace-surfaces/example/packages/main/src/client/components/AccountPendingInvitesCue.vue +106 -0
- package/skills/jskit/references/patterns/workspaces/workspace-surfaces/example/packages/main/src/client/components/AccountSettingsInvitesSection.vue +7 -0
- package/skills/jskit/references/patterns/workspaces/workspace-surfaces/example/src/components/WorkspaceNotFoundCard.vue +53 -0
- package/skills/jskit/references/patterns/workspaces/workspace-surfaces/example/src/composables/useWorkspaceNotFoundState.js +41 -0
- package/skills/jskit/references/patterns/workspaces/workspace-surfaces/example/src/pages/admin/members/index.vue +7 -0
- package/skills/jskit/references/patterns/workspaces/workspace-surfaces/example/src/pages/admin/workspace/settings/index.vue +23 -0
- package/skills/jskit/references/patterns/workspaces/workspace-surfaces/example/src/pages/admin/workspace/settings.vue +95 -0
- package/skills/jskit/references/patterns/workspaces/workspace-surfaces/example/src/pages/invite/[token].vue +7 -0
- package/skills/jskit/references/patterns/workspaces/workspace-surfaces/example/src/surfaces/admin/index.vue +85 -0
- package/skills/jskit/references/patterns/workspaces/workspace-surfaces/example/src/surfaces/admin/root.vue +20 -0
- package/skills/jskit/references/patterns/workspaces/workspace-surfaces/example/src/surfaces/app/index.vue +46 -0
- package/skills/jskit/references/patterns/workspaces/workspace-surfaces/example/src/surfaces/app/root.vue +20 -0
- package/skills/jskit/references/ui-operations.md +5 -3
- package/templates/app/AGENTS.md +8 -8
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
import { fileURLToPath, URL } from "node:url";
|
|
2
|
+
import { defineConfig } from "vite";
|
|
3
|
+
import vue from "@vitejs/plugin-vue";
|
|
4
|
+
import vuetify from "vite-plugin-vuetify";
|
|
5
|
+
import VueRouter from "vue-router/vite";
|
|
6
|
+
import { createJskitClientBootstrapPlugin } from "@jskit-ai/kernel/client/vite";
|
|
7
|
+
|
|
8
|
+
const configuredDevPort = Number.parseInt(String(process.env.VITE_DEV_PORT || "").trim(), 10);
|
|
9
|
+
const devPort = Number.isInteger(configuredDevPort) && configuredDevPort > 0 ? configuredDevPort : 5173;
|
|
10
|
+
const apiProxyTarget = String(process.env.VITE_API_PROXY_TARGET || "").trim() || "http://localhost:3000";
|
|
11
|
+
const clientEntry = (() => {
|
|
12
|
+
const normalized = String(process.env.VITE_CLIENT_ENTRY || "").trim();
|
|
13
|
+
if (!normalized) {
|
|
14
|
+
return "/src/main.js";
|
|
15
|
+
}
|
|
16
|
+
if (normalized.startsWith("/")) {
|
|
17
|
+
return normalized;
|
|
18
|
+
}
|
|
19
|
+
if (normalized.startsWith("src/")) {
|
|
20
|
+
return `/${normalized}`;
|
|
21
|
+
}
|
|
22
|
+
return `/src/${normalized}`;
|
|
23
|
+
})();
|
|
24
|
+
|
|
25
|
+
export default defineConfig({
|
|
26
|
+
resolve: {
|
|
27
|
+
alias: {
|
|
28
|
+
"@": fileURLToPath(new URL("./src", import.meta.url))
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
plugins: [
|
|
32
|
+
createJskitClientBootstrapPlugin({
|
|
33
|
+
proxyTarget: apiProxyTarget
|
|
34
|
+
}),
|
|
35
|
+
VueRouter({
|
|
36
|
+
routesFolder: "src/pages",
|
|
37
|
+
// Generated on the first Vite dev/build scan and intentionally gitignored.
|
|
38
|
+
dts: "src/typed-router.d.ts",
|
|
39
|
+
nestedChildren: false
|
|
40
|
+
}),
|
|
41
|
+
vue(),
|
|
42
|
+
vuetify({
|
|
43
|
+
autoImport: true
|
|
44
|
+
}),
|
|
45
|
+
{
|
|
46
|
+
name: "jskit-client-entry",
|
|
47
|
+
transformIndexHtml(source) {
|
|
48
|
+
return String(source || "")
|
|
49
|
+
.replace(/\/src\/%VITE_CLIENT_ENTRY%/g, clientEntry)
|
|
50
|
+
.replace(/\/src\/main\.js/g, clientEntry);
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
],
|
|
54
|
+
test: {
|
|
55
|
+
include: ["tests/client/**/*.vitest.js"]
|
|
56
|
+
},
|
|
57
|
+
optimizeDeps: {
|
|
58
|
+
entries: [
|
|
59
|
+
"index.html",
|
|
60
|
+
"src/**/*.{js,ts,vue}"
|
|
61
|
+
]
|
|
62
|
+
},
|
|
63
|
+
server: {
|
|
64
|
+
port: devPort,
|
|
65
|
+
warmup: {
|
|
66
|
+
clientFiles: [
|
|
67
|
+
"src/main.{js,ts}",
|
|
68
|
+
"src/router/**/*.{js,ts}",
|
|
69
|
+
"src/pages/**/*.{js,ts,vue}",
|
|
70
|
+
"src/components/**/*.{js,ts,vue}"
|
|
71
|
+
]
|
|
72
|
+
},
|
|
73
|
+
proxy: {
|
|
74
|
+
"/api": {
|
|
75
|
+
target: apiProxyTarget,
|
|
76
|
+
changeOrigin: true
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
});
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
---
|
|
2
|
+
id: app/shell-foundation
|
|
3
|
+
title: Adaptive-shell JSKIT application foundation
|
|
4
|
+
summary: A concrete JSKIT web application foundation with responsive shell navigation, settings, placements, and browser verification.
|
|
5
|
+
keywords: app, foundation, material, navigation, placements, shell, vite, vue
|
|
6
|
+
requires: @jskit-ai/http-runtime, @jskit-ai/kernel, @jskit-ai/shell-web
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
# Adaptive-shell JSKIT application foundation
|
|
10
|
+
|
|
11
|
+
## Use when
|
|
12
|
+
|
|
13
|
+
Use this pattern for a new browser application that needs the normal JSKIT
|
|
14
|
+
adaptive shell: responsive navigation, route surfaces, settings, placement
|
|
15
|
+
topology, app-local providers, server/runtime composition, and representative
|
|
16
|
+
browser coverage. It is the normal starting point for a full JSKIT product.
|
|
17
|
+
|
|
18
|
+
The example is a concrete `reading-room` application. An agent may copy it
|
|
19
|
+
directly, adapt a narrow set of files, or use it as evidence while authoring a
|
|
20
|
+
different layout through the same public framework APIs.
|
|
21
|
+
|
|
22
|
+
## Do not use when
|
|
23
|
+
|
|
24
|
+
Do not impose this tree on an existing application. Do not use it for a
|
|
25
|
+
command-line service, an API-only service, or a product whose navigation model
|
|
26
|
+
is still unknown. Use the minimal foundation when the shell would be
|
|
27
|
+
premature.
|
|
28
|
+
|
|
29
|
+
## Product decisions
|
|
30
|
+
|
|
31
|
+
Decide the application name, initial surface, navigation vocabulary, public or
|
|
32
|
+
authenticated access, and which settings actually exist. Decide database,
|
|
33
|
+
authentication, tenancy, and domain capabilities separately. The pattern does
|
|
34
|
+
not convert those choices into a generator questionnaire.
|
|
35
|
+
|
|
36
|
+
## Invariants
|
|
37
|
+
|
|
38
|
+
- Materialize source inside the existing project without disturbing `.git` or
|
|
39
|
+
any existing project/agent context.
|
|
40
|
+
- Inspect and resolve file collisions; never force-overwrite product source.
|
|
41
|
+
- Keep placements and topology explicit and use shell public components.
|
|
42
|
+
- Keep one app-owned `npm run develop` entry that runs the API on loopback and
|
|
43
|
+
Vite on the host-supplied preview port; do not require a host to infer or
|
|
44
|
+
supervise framework-specific processes.
|
|
45
|
+
- Keep Vite's default `resolve.preserveSymlinks: false` so linked application
|
|
46
|
+
packages resolve to mutable `/packages/` source during development.
|
|
47
|
+
- If the application adds a production service worker, never cache Vite
|
|
48
|
+
development paths. Cache JavaScript and CSS only through content-hashed
|
|
49
|
+
`/assets/` URLs.
|
|
50
|
+
- Keep `packages/main` as composition and light glue, not a feature dumping
|
|
51
|
+
ground.
|
|
52
|
+
- Declare `packages/*` as an npm workspace and depend on app-local packages by
|
|
53
|
+
their exact package versions, never through `file:` paths.
|
|
54
|
+
- Preserve accessible navigation, 48px compact interaction targets, warm-cache
|
|
55
|
+
state hydration, skeleton loading, and toast-based transient errors.
|
|
56
|
+
- Use public shell controls in browser tests rather than implementation-detail
|
|
57
|
+
scrims or coordinates.
|
|
58
|
+
- Do not attach generator provenance, receipts, completion state, or replay
|
|
59
|
+
history to copied source.
|
|
60
|
+
|
|
61
|
+
## Framework APIs
|
|
62
|
+
|
|
63
|
+
The example uses `@jskit-ai/shell-web` for layout, navigation, placement, and
|
|
64
|
+
adaptive shell testing; `@jskit-ai/kernel` for provider/runtime composition;
|
|
65
|
+
and `@jskit-ai/http-runtime` for the server boundary. Application routes,
|
|
66
|
+
placement declarations, surface access, and app-local providers remain normal
|
|
67
|
+
source files.
|
|
68
|
+
|
|
69
|
+
## Example files
|
|
70
|
+
|
|
71
|
+
`example/` contains the complete reference tree. Rename `example/gitignore` to
|
|
72
|
+
`.gitignore` when copying it to an app. Managed preview identity belongs to the
|
|
73
|
+
authentication surface pattern, not the shell foundation.
|
|
74
|
+
|
|
75
|
+
Read these together before adapting the shell:
|
|
76
|
+
|
|
77
|
+
- `example/src/App.vue`
|
|
78
|
+
- `example/src/components/ShellLayout.vue`
|
|
79
|
+
- `example/src/placement.js`
|
|
80
|
+
- `example/src/placementTopology.js`
|
|
81
|
+
- `example/config/surfaceAccessPolicies.js`
|
|
82
|
+
- `example/src/pages/home.vue`
|
|
83
|
+
- `example/src/pages/home/settings.vue`
|
|
84
|
+
- `example/tests/e2e/adaptive-shell.spec.ts`
|
|
85
|
+
|
|
86
|
+
## Variation points
|
|
87
|
+
|
|
88
|
+
Rename the example, replace the home content, add or remove settings routes,
|
|
89
|
+
and change placements through their public contracts. Use package-owned
|
|
90
|
+
patterns for auth, users, databases, CRUD, realtime, and other capabilities.
|
|
91
|
+
Do not preinstall capabilities solely because they appear in another app.
|
|
92
|
+
|
|
93
|
+
## Verification
|
|
94
|
+
|
|
95
|
+
Install the declared packages once, run `npm run develop` for the live
|
|
96
|
+
application, then run lint, server tests, client tests, the production build,
|
|
97
|
+
and the adaptive browser smoke at compact, medium, and expanded viewports.
|
|
98
|
+
Verify navigation through accessible controls and confirm there is no
|
|
99
|
+
horizontal overflow.
|
|
100
|
+
|
|
101
|
+
## Avoid
|
|
102
|
+
|
|
103
|
+
- Do not run `create-app` or reproduce its options in another command.
|
|
104
|
+
- Do not create a temporary scaffold directory.
|
|
105
|
+
- Do not require `.generated-ui-screen` or another magic class to recognize a
|
|
106
|
+
valid screen.
|
|
107
|
+
- Do not add spinners for ordinary screen loading; use structure-matching
|
|
108
|
+
skeletons.
|
|
109
|
+
- Do not push content down with persistent transient-error banners; use the
|
|
110
|
+
standard toast/error presentation.
|
|
111
|
+
- Do not preserve historical template ownership after copying.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
26
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# App Agent Instructions
|
|
2
|
+
|
|
3
|
+
Use current project context, JSKIT public APIs, and the official framework
|
|
4
|
+
documentation as the source of truth for application work.
|
|
5
|
+
|
|
6
|
+
Framework references:
|
|
7
|
+
|
|
8
|
+
- `https://mobily-enterprises.github.io/jskit-ai/guide/`
|
|
9
|
+
- `https://mobily-enterprises.github.io/jskit-ai/patterns/`
|
|
10
|
+
|
|
11
|
+
Before implementation, read the narrow relevant source pattern completely. If
|
|
12
|
+
its owner package is installed, prefer that version-matched package-owned copy.
|
|
13
|
+
Do not install an unrelated runtime package only to read documentation.
|
|
14
|
+
|
|
15
|
+
Copied pattern source is ordinary application source. Do not add generator
|
|
16
|
+
provenance, receipts, completion ledgers, or tooling-operation history. Keep
|
|
17
|
+
changes scoped to the user request and verify runtime behavior directly.
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import { spawn } from "node:child_process";
|
|
2
|
+
import { startServer } from "../server.js";
|
|
3
|
+
|
|
4
|
+
const LOOPBACK_HOST = "127.0.0.1";
|
|
5
|
+
|
|
6
|
+
function requiredPort(value, fallback = 3000) {
|
|
7
|
+
const normalized = String(value || "").trim();
|
|
8
|
+
const parsed = Number.parseInt(normalized || String(fallback), 10);
|
|
9
|
+
if (!Number.isInteger(parsed) || parsed < 1 || parsed > 65_535) {
|
|
10
|
+
throw new Error(`Invalid development port: ${normalized || "(empty)"}.`);
|
|
11
|
+
}
|
|
12
|
+
return parsed;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
function waitForChild(child) {
|
|
16
|
+
return new Promise((resolve, reject) => {
|
|
17
|
+
child.once("error", reject);
|
|
18
|
+
child.once("exit", (code, signal) => resolve({ code, signal }));
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
const previewHost = String(process.env.HOST || "").trim() || "0.0.0.0";
|
|
23
|
+
const previewPort = requiredPort(process.env.PORT);
|
|
24
|
+
let apiServer = null;
|
|
25
|
+
let viteProcess = null;
|
|
26
|
+
let requestedSignal = "";
|
|
27
|
+
|
|
28
|
+
function requestShutdown(signal) {
|
|
29
|
+
requestedSignal = signal;
|
|
30
|
+
if (viteProcess && !viteProcess.killed) {
|
|
31
|
+
viteProcess.kill(signal);
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
process.once("SIGINT", () => requestShutdown("SIGINT"));
|
|
36
|
+
process.once("SIGTERM", () => requestShutdown("SIGTERM"));
|
|
37
|
+
|
|
38
|
+
try {
|
|
39
|
+
apiServer = await startServer({ host: LOOPBACK_HOST, port: 0 });
|
|
40
|
+
const apiPort = requiredPort(apiServer.server.address()?.port);
|
|
41
|
+
const npmCommand = process.platform === "win32" ? "npm.cmd" : "npm";
|
|
42
|
+
viteProcess = spawn(
|
|
43
|
+
npmCommand,
|
|
44
|
+
["run", "dev", "--", "--host", previewHost, "--port", String(previewPort), "--strictPort"],
|
|
45
|
+
{
|
|
46
|
+
cwd: process.cwd(),
|
|
47
|
+
env: {
|
|
48
|
+
...process.env,
|
|
49
|
+
HOST: previewHost,
|
|
50
|
+
PORT: String(previewPort),
|
|
51
|
+
VITE_API_PROXY_TARGET: `http://${LOOPBACK_HOST}:${apiPort}`,
|
|
52
|
+
VITE_DEV_PORT: String(previewPort)
|
|
53
|
+
},
|
|
54
|
+
stdio: "inherit"
|
|
55
|
+
}
|
|
56
|
+
);
|
|
57
|
+
|
|
58
|
+
const result = await waitForChild(viteProcess);
|
|
59
|
+
if (!requestedSignal && result.code !== 0) {
|
|
60
|
+
throw new Error(
|
|
61
|
+
`Vite development server stopped unexpectedly (${result.signal || `exit ${result.code ?? "unknown"}`}).`
|
|
62
|
+
);
|
|
63
|
+
}
|
|
64
|
+
} catch (error) {
|
|
65
|
+
console.error("Failed to start the development application:", error);
|
|
66
|
+
process.exitCode = 1;
|
|
67
|
+
} finally {
|
|
68
|
+
if (apiServer) {
|
|
69
|
+
await apiServer.close().catch(() => {});
|
|
70
|
+
}
|
|
71
|
+
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { surfaceAccessPolicies } from "./surfaceAccessPolicies.js";
|
|
2
|
+
|
|
3
|
+
export const config = {};
|
|
4
|
+
|
|
5
|
+
config.surfaceModeAll = "all";
|
|
6
|
+
config.surfaceDefaultId = "home";
|
|
7
|
+
config.webRootAllowed = "no";
|
|
8
|
+
config.surfaceAccessPolicies = surfaceAccessPolicies;
|
|
9
|
+
config.mobile = {
|
|
10
|
+
enabled: false,
|
|
11
|
+
strategy: "",
|
|
12
|
+
appId: "",
|
|
13
|
+
appName: "",
|
|
14
|
+
assetMode: "bundled",
|
|
15
|
+
devServerUrl: "",
|
|
16
|
+
apiBaseUrl: "",
|
|
17
|
+
auth: {
|
|
18
|
+
callbackPath: "/auth/login",
|
|
19
|
+
customScheme: "",
|
|
20
|
+
appLinkDomains: []
|
|
21
|
+
},
|
|
22
|
+
android: {
|
|
23
|
+
packageName: "",
|
|
24
|
+
minSdk: 26,
|
|
25
|
+
targetSdk: 35,
|
|
26
|
+
versionCode: 1,
|
|
27
|
+
versionName: "1.0.0"
|
|
28
|
+
}
|
|
29
|
+
};
|
|
30
|
+
config.surfaceDefinitions = {};
|
|
31
|
+
config.surfaceDefinitions.home = {
|
|
32
|
+
id: "home",
|
|
33
|
+
label: "Home",
|
|
34
|
+
pagesRoot: "home",
|
|
35
|
+
enabled: true,
|
|
36
|
+
requiresAuth: false,
|
|
37
|
+
requiresWorkspace: false,
|
|
38
|
+
accessPolicyId: "public",
|
|
39
|
+
origin: ""
|
|
40
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const config = {};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { baseConfig, nodeConfig, vueConfig, webConfig } from "@jskit-ai/config-eslint/server";
|
|
2
|
+
|
|
3
|
+
export default [
|
|
4
|
+
{
|
|
5
|
+
ignores: ["dist/**", "node_modules/**", "coverage/**", "test-results/**", ".jskit/**"]
|
|
6
|
+
},
|
|
7
|
+
{
|
|
8
|
+
files: ["src/pages/**/*.vue"],
|
|
9
|
+
languageOptions: {
|
|
10
|
+
globals: {
|
|
11
|
+
definePage: "readonly"
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
},
|
|
15
|
+
...baseConfig,
|
|
16
|
+
...vueConfig,
|
|
17
|
+
...webConfig,
|
|
18
|
+
...nodeConfig
|
|
19
|
+
];
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<!doctype html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="UTF-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
|
+
<link rel="icon" type="image/svg+xml" href="/favicon.svg" />
|
|
7
|
+
<title>Reading Room</title>
|
|
8
|
+
</head>
|
|
9
|
+
<body>
|
|
10
|
+
<div id="app"></div>
|
|
11
|
+
<script type="module" src="/src/main.js"></script>
|
|
12
|
+
</body>
|
|
13
|
+
</html>
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "reading-room",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"private": true,
|
|
5
|
+
"type": "module",
|
|
6
|
+
"description": "JSKIT shell-web app (Fastify + Vue)",
|
|
7
|
+
"engines": {
|
|
8
|
+
"node": "26.x"
|
|
9
|
+
},
|
|
10
|
+
"workspaces": [
|
|
11
|
+
"packages/*"
|
|
12
|
+
],
|
|
13
|
+
"scripts": {
|
|
14
|
+
"server": "node ./bin/server.js",
|
|
15
|
+
"server:all": "node ./bin/server.js",
|
|
16
|
+
"server:home": "SERVER_SURFACE=home node ./bin/server.js",
|
|
17
|
+
"start": "node ./bin/server.js",
|
|
18
|
+
"develop": "node ./bin/develop.js",
|
|
19
|
+
"dev": "vite",
|
|
20
|
+
"dev:all": "vite",
|
|
21
|
+
"dev:home": "VITE_SURFACE=home vite",
|
|
22
|
+
"build": "vite build",
|
|
23
|
+
"build:all": "vite build",
|
|
24
|
+
"build:home": "VITE_SURFACE=home vite build",
|
|
25
|
+
"preview": "vite preview",
|
|
26
|
+
"lint": "eslint .",
|
|
27
|
+
"test": "node --test",
|
|
28
|
+
"test:client": "vitest run tests/client",
|
|
29
|
+
"test:e2e": "playwright test tests/e2e",
|
|
30
|
+
"jskit:update": "npx --yes @jskit-ai/jskit-catalog@latest update",
|
|
31
|
+
"jskit:check": "jskit check",
|
|
32
|
+
"verify": "npm run jskit:check && npm run lint && npm run test && npm run test:client && npm run build"
|
|
33
|
+
},
|
|
34
|
+
"dependencies": {
|
|
35
|
+
"@local/main": "0.1.0",
|
|
36
|
+
"@fastify/static": "^10.1.3",
|
|
37
|
+
"@jskit-ai/kernel": "0.1.178",
|
|
38
|
+
"@tanstack/vue-query": "^5.101.0",
|
|
39
|
+
"fastify": "^5.8.5",
|
|
40
|
+
"json-rest-schema": "^1.0.17",
|
|
41
|
+
"pinia": "^3.0.4",
|
|
42
|
+
"vue": "^3.5.38",
|
|
43
|
+
"vue-router": "^5.1.0",
|
|
44
|
+
"vuetify": "^4.1.2",
|
|
45
|
+
"@jskit-ai/http-runtime": "0.1.176",
|
|
46
|
+
"@mdi/js": "^7.4.47",
|
|
47
|
+
"@jskit-ai/shell-web": "0.1.182"
|
|
48
|
+
},
|
|
49
|
+
"devDependencies": {
|
|
50
|
+
"@jskit-ai/config-eslint": "0.1.175",
|
|
51
|
+
"@jskit-ai/jskit-catalog": "0.1.203",
|
|
52
|
+
"@playwright/test": "1.61.1",
|
|
53
|
+
"@vitejs/plugin-vue": "^6.0.7",
|
|
54
|
+
"eslint": "^10.8.0",
|
|
55
|
+
"vite": "^8.2.1",
|
|
56
|
+
"vite-plugin-vuetify": "^2.1.3",
|
|
57
|
+
"vitest": "^4.1.9"
|
|
58
|
+
},
|
|
59
|
+
"allowScripts": {
|
|
60
|
+
"fsevents@2.3.2": true,
|
|
61
|
+
"fsevents@2.3.3": true,
|
|
62
|
+
"vue-demi@0.14.10": true
|
|
63
|
+
}
|
|
64
|
+
}
|
package/skills/jskit/references/patterns/app/shell-foundation/example/packages/main/package.json
ADDED
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@local/main",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"private": true,
|
|
5
|
+
"type": "module",
|
|
6
|
+
"exports": {
|
|
7
|
+
"./client": "./src/client/index.js",
|
|
8
|
+
"./shared": "./src/shared/index.js"
|
|
9
|
+
},
|
|
10
|
+
"description": "App-local runtime composition and lightweight glue.",
|
|
11
|
+
"dependencies": {
|
|
12
|
+
"@jskit-ai/kernel": "0.1.178"
|
|
13
|
+
},
|
|
14
|
+
"jskit": {
|
|
15
|
+
"kind": "runtime",
|
|
16
|
+
"capabilities": {
|
|
17
|
+
"provides": [],
|
|
18
|
+
"requires": []
|
|
19
|
+
},
|
|
20
|
+
"runtime": {
|
|
21
|
+
"client": {
|
|
22
|
+
"providers": [
|
|
23
|
+
{
|
|
24
|
+
"entrypoint": "src/client/providers/MainClientProvider.js",
|
|
25
|
+
"export": "MainClientProvider"
|
|
26
|
+
}
|
|
27
|
+
]
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
"metadata": {
|
|
31
|
+
"jskit": {
|
|
32
|
+
"ownershipGuidance": {
|
|
33
|
+
"title": "App-local main lane",
|
|
34
|
+
"summary": "Keep @local/main focused on app composition and lightweight glue. Substantial server features should become dedicated packages instead of growing inside packages/main.",
|
|
35
|
+
"responsibilities": [
|
|
36
|
+
"packages/main server code: bootstraps app-local configuration and lightweight wiring only",
|
|
37
|
+
"substantial server features: author a dedicated app-local package from the relevant framework pattern",
|
|
38
|
+
"packages/main: do not add service/controller/route/repository feature trees here"
|
|
39
|
+
],
|
|
40
|
+
"examples": [
|
|
41
|
+
"packages/booking-engine owns booking operations",
|
|
42
|
+
"packages/availability-engine owns availability orchestration"
|
|
43
|
+
]
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
"server": {
|
|
47
|
+
"routes": []
|
|
48
|
+
},
|
|
49
|
+
"ui": {
|
|
50
|
+
"routes": [],
|
|
51
|
+
"elements": [],
|
|
52
|
+
"overrides": []
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Client entrypoint for @local/main.
|
|
3
|
+
*
|
|
4
|
+
* Export browser-facing modules from here.
|
|
5
|
+
*
|
|
6
|
+
* This package contributes its named UI components through one explicit
|
|
7
|
+
* capability provider.
|
|
8
|
+
*/
|
|
9
|
+
export { MainClientProvider } from "./providers/MainClientProvider.js";
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { defineProvider } from "@jskit-ai/kernel/shared/capabilities";
|
|
2
|
+
import MenuLinkItem from "/src/components/menus/MenuLinkItem.vue";
|
|
3
|
+
import SurfaceAwareMenuLinkItem from "/src/components/menus/SurfaceAwareMenuLinkItem.vue";
|
|
4
|
+
import TabLinkItem from "/src/components/menus/TabLinkItem.vue";
|
|
5
|
+
|
|
6
|
+
const MainClientProvider = defineProvider({
|
|
7
|
+
id: "local.main.client",
|
|
8
|
+
requires: {
|
|
9
|
+
components: "client.components"
|
|
10
|
+
},
|
|
11
|
+
setup({ components }) {
|
|
12
|
+
components.register("local.main.ui.menu-link-item", MenuLinkItem);
|
|
13
|
+
components.register("local.main.ui.surface-aware-menu-link-item", SurfaceAwareMenuLinkItem);
|
|
14
|
+
components.register("local.main.ui.tab-link-item", TabLinkItem);
|
|
15
|
+
}
|
|
16
|
+
});
|
|
17
|
+
|
|
18
|
+
export { MainClientProvider };
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* App-local shared transport validators/resources live here.
|
|
3
|
+
* Dedicated feature packages should keep their own schemas with the feature.
|
|
4
|
+
*
|
|
5
|
+
* Example:
|
|
6
|
+
* import { createSchema } from "json-rest-schema";
|
|
7
|
+
*
|
|
8
|
+
* export const helloQuerySchema = createSchema({
|
|
9
|
+
* name: { type: "string", minLength: 1, maxLength: 80 }
|
|
10
|
+
* });
|
|
11
|
+
*
|
|
12
|
+
* export const helloResponseSchema = {
|
|
13
|
+
* type: "object",
|
|
14
|
+
* additionalProperties: false,
|
|
15
|
+
* required: ["ok", "message"],
|
|
16
|
+
* properties: {
|
|
17
|
+
* ok: { type: "boolean" },
|
|
18
|
+
* message: { type: "string", minLength: 1 }
|
|
19
|
+
* }
|
|
20
|
+
* };
|
|
21
|
+
*/
|
|
22
|
+
export {};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { defineConfig } from "@playwright/test";
|
|
2
|
+
|
|
3
|
+
const managedBaseUrl = String(process.env.PLAYWRIGHT_BASE_URL || "")
|
|
4
|
+
.trim()
|
|
5
|
+
.replace(/\/+$/u, "");
|
|
6
|
+
const baseURL = managedBaseUrl || "http://127.0.0.1:4173";
|
|
7
|
+
const storageState = String(process.env.VIBE64_PLAYWRIGHT_STORAGE_STATE || "").trim();
|
|
8
|
+
|
|
9
|
+
export default defineConfig({
|
|
10
|
+
testDir: "./tests/e2e",
|
|
11
|
+
timeout: 60_000,
|
|
12
|
+
expect: {
|
|
13
|
+
timeout: 10_000
|
|
14
|
+
},
|
|
15
|
+
use: {
|
|
16
|
+
baseURL,
|
|
17
|
+
headless: true,
|
|
18
|
+
...(storageState ? { storageState } : {})
|
|
19
|
+
},
|
|
20
|
+
...(managedBaseUrl ? {} : {
|
|
21
|
+
webServer: {
|
|
22
|
+
command: "npm run build && node ./bin/server.js",
|
|
23
|
+
env: {
|
|
24
|
+
PORT: "4173"
|
|
25
|
+
},
|
|
26
|
+
url: `${baseURL}/api/health`,
|
|
27
|
+
reuseExistingServer: true,
|
|
28
|
+
timeout: 180_000
|
|
29
|
+
}
|
|
30
|
+
})
|
|
31
|
+
});
|