From e6333f6576f9ee323ee3493cf770ac2231d32182 Mon Sep 17 00:00:00 2001 From: Lan_zhijiang Date: Wed, 4 Nov 2026 22:17:38 +0800 Subject: [PATCH] =?UTF-8?q?ref(apps):=20=E7=BB=9F=E4=B8=80=20Web=20?= =?UTF-8?q?=E5=BA=94=E7=94=A8=E4=B8=8E=20Peer=20=E5=91=BD=E5=90=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 将应用目录和包名迁移为 web 与 webext,更新构建、发布、检查和文档引用 - 以新 Runtime 导入名消费真实旧发布包,保留存储、浏览器身份、MF ABI 与部署兼容标识 - 对旧 Runtime 限定更新 Zod 依赖并记录兼容标识的移除条件 --- .changeset/app-peer-naming.md | 16 ++++++ .changeset/core-app-separation.md | 4 +- .changeset/observability-unification.md | 4 +- .github/pages-preview-closed/index.html | 2 +- .github/preview/extensions.json | 10 ++-- .github/workflows/ci.yml | 8 +-- .github/workflows/pages-deploy.yml | 4 +- .github/workflows/pages-preview.yml | 4 +- .oxlintrc.json | 2 +- .vscode/default.code-snippets | 2 +- AGENTS.md | 6 +-- ARCHITECTURE.md | 8 +-- CONTRIBUTING.md | 6 +-- FILESYSTEM.md | 12 ++--- README.md | 4 +- apps/{client-web => web}/AGENTS.md | 10 ++-- apps/{client-web => web}/CHANGELOG.md | 0 apps/{client-web => web}/env.d.ts | 0 apps/{client-web => web}/index.html | 0 apps/{client-web => web}/package.json | 4 +- apps/{client-web => web}/playwright.config.ts | 0 apps/{client-web => web}/public/_headers | 0 apps/{client-web => web}/public/favicon.ico | Bin apps/{client-web => web}/public/logo/256.svg | 0 apps/{client-web => web}/public/logo/32.svg | 0 apps/{client-web => web}/src/App.vue | 0 .../src/components/AGENTS.md | 8 +-- .../common/AppSidePanel/AppSidePanel.md | 0 .../common/AppSidePanel/AppSidePanel.scss | 0 .../common/AppSidePanel/AppSidePanel.ts | 0 .../common/AppSidePanel/AppSidePanel.vue | 0 .../extension/extensionCard/extensionCard.md | 0 .../extensionCard/extensionCard.scss | 0 .../extension/extensionCard/extensionCard.ts | 0 .../extension/extensionCard/extensionCard.vue | 0 .../use-extension-info-dialogs.ts | 2 +- .../use-extension-peer-runtime.ts | 2 +- .../use-extension-version-dialog.ts | 2 +- .../BlockInspectorPopup.scss | 0 .../BlockInspectorPopup.ts | 0 .../BlockInspectorPopup.vue | 0 .../info-base/BlockNode/BlockNode.scss | 0 .../info-base/BlockNode/BlockNode.ts | 0 .../info-base/BlockNode/BlockNode.vue | 0 .../components/info-base/InfoBaseViewTabs.vue | 0 .../PreviewRenderer/PreviewRenderer.ts | 0 .../PreviewRenderer/PreviewRenderer.vue | 0 .../info-base/RelationEdge/RelationEdge.scss | 0 .../info-base/RelationEdge/RelationEdge.ts | 0 .../info-base/RelationEdge/RelationEdge.vue | 0 .../RelationInspectorPopup.ts | 0 .../RelationInspectorPopup.vue | 0 .../SolvedContentPopup.scss | 0 .../SolvedContentPopup/SolvedContentPopup.ts | 0 .../SolvedContentPopup/SolvedContentPopup.vue | 0 .../SolvedContentRenderer.ts | 0 .../SolvedContentRenderer.vue | 0 .../info-base/resolvers/ContentAudio.vue | 0 .../info-base/resolvers/ContentFile.vue | 0 .../info-base/resolvers/ContentHtml.vue | 0 .../info-base/resolvers/ContentImage.vue | 0 .../info-base/resolvers/ContentPreview.vue | 0 .../info-base/resolvers/ContentText.vue | 0 .../info-base/resolvers/ContentVideo.vue | 0 .../src/components/job/JobCard/JobCard.md | 0 .../src/components/job/JobCard/JobCard.scss | 0 .../src/components/job/JobCard/JobCard.ts | 0 .../src/components/job/JobCard/JobCard.vue | 0 .../components/obsrv/LogsViewer/LogsViewer.md | 0 .../components/obsrv/LogsViewer/LogsViewer.ts | 0 .../obsrv/LogsViewer/LogsViewer.vue | 0 .../ObservationExplorer.md | 0 .../ObservationExplorer.scss | 0 .../ObservationExplorer.ts | 0 .../ObservationExplorer.vue | 0 .../src/components/peer/peerCard/peerCard.md | 0 .../components/peer/peerCard/peerCard.scss | 0 .../src/components/peer/peerCard/peerCard.ts | 0 .../src/components/peer/peerCard/peerCard.vue | 0 .../components/peer/peerList/peerList.scss | 0 .../src/components/peer/peerList/peerList.ts | 0 .../src/components/peer/peerList/peerList.vue | 0 .../src/components/recall/RecallSearch.vue | 0 .../src/components/recall/recall-search.ts | 0 .../schemaConfigEditor/schemaConfigEditor.md | 0 .../schemaConfigEditor/schemaConfigEditor.vue | 0 .../source/createSource/createSource.md | 0 .../source/createSource/createSource.scss | 0 .../source/createSource/createSource.ts | 0 .../source/createSource/createSource.vue | 0 .../source/sourceCard/sourceCard.md | 0 .../source/sourceCard/sourceCard.scss | 0 .../source/sourceCard/sourceCard.ts | 0 .../source/sourceCard/sourceCard.vue | 0 .../source/sourceForm/sourceForm.md | 0 .../source/sourceForm/sourceForm.scss | 0 .../source/sourceForm/sourceForm.ts | 0 .../source/sourceForm/sourceForm.vue | 0 .../src/components/toast/ToastHost.scss | 0 .../src/components/toast/ToastHost.vue | 0 .../src/components/toast/toast.ts | 0 .../src/composables/use-async-state.ts | 0 .../src/composables/use-either.ts | 0 .../src/composables/use-page-object-title.ts | 0 apps/{client-web => web}/src/core.ts | 20 ++++---- .../src/extension-peer-control.ts | 2 +- apps/{client-web => web}/src/locales/index.ts | 0 .../src/locales/messages/en.json | 0 .../src/locales/messages/zh-CN.json | 0 apps/{client-web => web}/src/main.ts | 0 apps/{client-web => web}/src/router.ts | 0 .../{client-web => web}/src/storages/index.ts | 0 .../src/styles/_mixins.scss | 0 .../src/styles/entity-card.scss | 0 .../{client-web => web}/src/styles/index.scss | 0 apps/{client-web => web}/src/utils/base.ts | 0 apps/{client-web => web}/src/utils/cron.ts | 0 apps/{client-web => web}/src/utils/format.ts | 0 .../src/utils/vue-props.ts | 0 .../src/views/extensions/extensions.scss | 0 .../src/views/extensions/extensions.vue | 4 +- .../views/info-base/graph/graph-layouts.ts | 0 .../src/views/info-base/graph/graph-model.ts | 0 .../src/views/info-base/graph/graph.scss | 0 .../src/views/info-base/graph/graph.ts | 0 .../src/views/info-base/graph/graph.vue | 0 .../views/info-base/graph/useGraphScene.ts | 0 .../src/views/info-base/list/list.scss | 0 .../src/views/info-base/list/list.vue | 0 .../src/views/jobs/job/job.scss | 0 .../src/views/jobs/job/job.vue | 0 .../src/views/observability/observability.vue | 0 .../src/views/peers/peers.scss | 0 .../src/views/peers/peers.vue | 0 .../src/views/settings/settings.scss | 0 .../src/views/settings/settings.vue | 0 .../src/views/sources/source/source.md | 0 .../src/views/sources/source/source.scss | 0 .../src/views/sources/source/source.ts | 0 .../src/views/sources/source/source.vue | 0 .../views/sources/source/use-cron-manager.ts | 0 .../views/sources/source/use-job-creator.ts | 0 .../views/sources/source/use-source-detail.ts | 0 .../src/views/sources/sources.scss | 0 .../src/views/sources/sources.vue | 0 .../tests/accessibility.spec.ts | 0 apps/{client-web => web}/tsconfig.app.json | 0 apps/{client-web => web}/tsconfig.json | 0 apps/{client-web => web}/tsconfig.node.json | 0 apps/{client-web => web}/uno.config.ts | 0 .../vite-plugins/joint-dev-extension.ts | 10 ++-- apps/{client-web => web}/vite.config.ts | 6 +-- apps/{client-webext => webext}/.gitignore | 0 apps/{client-webext => webext}/CHANGELOG.md | 0 .../{client-webext => webext}/CONTRIBUTING.md | 0 apps/{client-webext => webext}/LICENSE | 0 apps/{client-webext => webext}/README.md | 4 +- .../chromium-key.json | 0 .../components/collection/MaterialReader.vue | 0 .../entrypoints/background.ts | 0 .../entrypoints/collection.content.ts | 0 .../entrypoints/options/Options.vue | 0 .../entrypoints/options/index.html | 0 .../entrypoints/options/main.ts | 0 .../entrypoints/parser/index.html | 0 .../entrypoints/parser/main.ts | 0 .../entrypoints/popup/Popup.vue | 0 .../entrypoints/popup/index.html | 0 .../entrypoints/popup/main.ts | 0 .../logic/collection/capture.ts | 0 .../logic/collection/database.ts | 0 .../logic/collection/fetch.ts | 0 .../logic/collection/imports.ts | 0 .../logic/collection/legacy-storage.ts | 0 .../logic/collection/messages.ts | 0 .../logic/collection/outbox.ts | 0 .../logic/collection/parse-html.ts | 0 .../logic/collection/permissions.ts | 0 .../logic/collection/runtime.ts | 0 .../logic/collection/store.ts | 0 .../logic/collection/transfer.ts | 0 .../logic/collection/ui.css | 0 .../logic/collection/ui.ts | 0 apps/{client-webext => webext}/package.json | 2 +- .../styles/design/_tokens.scss | 0 .../{client-webext => webext}/styles/index.ts | 0 .../styles/main.scss | 0 apps/{client-webext => webext}/tsconfig.json | 0 apps/{client-webext => webext}/vue-shim.d.ts | 0 apps/{client-webext => webext}/wxt.config.ts | 0 docs/30-unit-tdd/README.md | 4 +- ...ation.md => app-runtime-and-delegation.md} | 8 +-- docs/30-unit-tdd/info-base.md | 2 +- docs/30-unit-tdd/native-extension-runtime.md | 10 ++-- docs/30-unit-tdd/webext-collection.md | 6 +-- docs/40-deployment/README.md | 2 +- docs/40-deployment/development-runtime.md | 16 +++--- .../native-extension-delivery.md | 15 +++--- docs/40-deployment/web-delivery.md | 38 +++++++++++---- docs/40-deployment/webext-delivery.md | 6 +-- docs/index.md | 2 +- extensions/.agents/assets/vite.config.ts.md | 4 +- extensions/AGENTS.md | 2 +- extensions/caldav/package.json | 2 +- extensions/caldav/src/setup.ts | 2 +- extensions/caldav/vite.config.ts | 2 +- extensions/capture/README.md | 2 +- extensions/capture/vite.config.ts | 2 +- extensions/github/README.md | 2 +- extensions/github/tsconfig.json | 2 +- extensions/github/vite.config.ts | 2 +- extensions/local-files/vite.config.ts | 2 +- extensions/mail/tsconfig.json | 2 +- extensions/mail/vite.config.ts | 2 +- extensions/memos/package.json | 2 +- extensions/memos/src/MemosSetup.vue | 2 +- extensions/memos/src/setup.ts | 2 +- extensions/memos/vite.config.ts | 2 +- extensions/mf-shared.ts | 2 +- extensions/twitter/package.json | 2 +- extensions/twitter/src/setup-api.ts | 2 +- extensions/twitter/tsconfig.json | 2 +- extensions/twitter/vite.config.ts | 2 +- package.json | 2 +- packages/core/AGENTS.md | 2 +- packages/core/src/auth/defaults.ts | 2 +- packages/core/src/config/schema.ts | 2 +- packages/core/src/obsrv/telemetry.ts | 2 +- pnpm-lock.yaml | 30 +++++------- pnpm-workspace.yaml | 2 + pyproject.toml | 2 +- scripts/check-local-runtime-contract.mjs | 24 ++++----- scripts/check-locale-keys.mjs | 4 +- scripts/check-package-contract.mjs | 46 +++++++++--------- scripts/check-workspace-contract.mjs | 8 +-- scripts/core-release-lib.mjs | 4 +- scripts/database-runtime-lib.mjs | 9 ++-- scripts/dev-wxt.mjs | 2 +- scripts/dev.mjs | 3 +- scripts/doctor.mjs | 2 +- scripts/probe-dev.mjs | 1 + scripts/publish-first-party-extensions.mjs | 4 +- scripts/report-pages-preview.mjs | 2 +- scripts/test-e2e.mjs | 4 +- scripts/test-extension-publication.mjs | 2 +- scripts/test-webext-e2e.mjs | 2 +- scripts/tests/database-probe.test.mjs | 2 +- .../independent-extension-release.test.mjs | 2 +- scripts/tests/pages-preview.test.mjs | 2 +- scripts/tests/twitter-rendering/specimens.vue | 8 +-- .../tests/twitter-rendering/vite.config.ts | 2 +- scripts/tests/ui-source.test.mjs | 2 +- scripts/tests/webext-release.test.mjs | 4 +- scripts/type-check-ui.mjs | 2 +- scripts/verify-pages-deployment.mjs | 5 +- ...web-release.mjs => verify-web-release.mjs} | 10 ++-- scripts/webext-release.mjs | 14 ++---- tests/e2e/browser-extension-fixture.ts | 2 +- tests/e2e/browser-extension.spec.ts | 8 +-- tests/e2e/github-native.ts | 4 +- tests/e2e/mail-info-base.spec.ts | 2 +- tests/e2e/peer-database.spec.ts | 14 +++--- tsconfig.json | 2 +- 263 files changed, 300 insertions(+), 269 deletions(-) create mode 100644 .changeset/app-peer-naming.md rename apps/{client-web => web}/AGENTS.md (82%) rename apps/{client-web => web}/CHANGELOG.md (100%) rename apps/{client-web => web}/env.d.ts (100%) rename apps/{client-web => web}/index.html (100%) rename apps/{client-web => web}/package.json (89%) rename apps/{client-web => web}/playwright.config.ts (100%) rename apps/{client-web => web}/public/_headers (100%) rename apps/{client-web => web}/public/favicon.ico (100%) rename apps/{client-web => web}/public/logo/256.svg (100%) rename apps/{client-web => web}/public/logo/32.svg (100%) rename apps/{client-web => web}/src/App.vue (100%) rename apps/{client-web => web}/src/components/AGENTS.md (67%) rename apps/{client-web => web}/src/components/common/AppSidePanel/AppSidePanel.md (100%) rename apps/{client-web => web}/src/components/common/AppSidePanel/AppSidePanel.scss (100%) rename apps/{client-web => web}/src/components/common/AppSidePanel/AppSidePanel.ts (100%) rename apps/{client-web => web}/src/components/common/AppSidePanel/AppSidePanel.vue (100%) rename apps/{client-web => web}/src/components/extension/extensionCard/extensionCard.md (100%) rename apps/{client-web => web}/src/components/extension/extensionCard/extensionCard.scss (100%) rename apps/{client-web => web}/src/components/extension/extensionCard/extensionCard.ts (100%) rename apps/{client-web => web}/src/components/extension/extensionCard/extensionCard.vue (100%) rename apps/{client-web => web}/src/components/extension/extensionCard/use-extension-info-dialogs.ts (99%) rename apps/{client-web => web}/src/components/extension/extensionCard/use-extension-peer-runtime.ts (99%) rename apps/{client-web => web}/src/components/extension/extensionCard/use-extension-version-dialog.ts (99%) rename apps/{client-web => web}/src/components/info-base/BlockInspectorPopup/BlockInspectorPopup.scss (100%) rename apps/{client-web => web}/src/components/info-base/BlockInspectorPopup/BlockInspectorPopup.ts (100%) rename apps/{client-web => web}/src/components/info-base/BlockInspectorPopup/BlockInspectorPopup.vue (100%) rename apps/{client-web => web}/src/components/info-base/BlockNode/BlockNode.scss (100%) rename apps/{client-web => web}/src/components/info-base/BlockNode/BlockNode.ts (100%) rename apps/{client-web => web}/src/components/info-base/BlockNode/BlockNode.vue (100%) rename apps/{client-web => web}/src/components/info-base/InfoBaseViewTabs.vue (100%) rename apps/{client-web => web}/src/components/info-base/PreviewRenderer/PreviewRenderer.ts (100%) rename apps/{client-web => web}/src/components/info-base/PreviewRenderer/PreviewRenderer.vue (100%) rename apps/{client-web => web}/src/components/info-base/RelationEdge/RelationEdge.scss (100%) rename apps/{client-web => web}/src/components/info-base/RelationEdge/RelationEdge.ts (100%) rename apps/{client-web => web}/src/components/info-base/RelationEdge/RelationEdge.vue (100%) rename apps/{client-web => web}/src/components/info-base/RelationInspectorPopup/RelationInspectorPopup.ts (100%) rename apps/{client-web => web}/src/components/info-base/RelationInspectorPopup/RelationInspectorPopup.vue (100%) rename apps/{client-web => web}/src/components/info-base/SolvedContentPopup/SolvedContentPopup.scss (100%) rename apps/{client-web => web}/src/components/info-base/SolvedContentPopup/SolvedContentPopup.ts (100%) rename apps/{client-web => web}/src/components/info-base/SolvedContentPopup/SolvedContentPopup.vue (100%) rename apps/{client-web => web}/src/components/info-base/SolvedContentRenderer/SolvedContentRenderer.ts (100%) rename apps/{client-web => web}/src/components/info-base/SolvedContentRenderer/SolvedContentRenderer.vue (100%) rename apps/{client-web => web}/src/components/info-base/resolvers/ContentAudio.vue (100%) rename apps/{client-web => web}/src/components/info-base/resolvers/ContentFile.vue (100%) rename apps/{client-web => web}/src/components/info-base/resolvers/ContentHtml.vue (100%) rename apps/{client-web => web}/src/components/info-base/resolvers/ContentImage.vue (100%) rename apps/{client-web => web}/src/components/info-base/resolvers/ContentPreview.vue (100%) rename apps/{client-web => web}/src/components/info-base/resolvers/ContentText.vue (100%) rename apps/{client-web => web}/src/components/info-base/resolvers/ContentVideo.vue (100%) rename apps/{client-web => web}/src/components/job/JobCard/JobCard.md (100%) rename apps/{client-web => web}/src/components/job/JobCard/JobCard.scss (100%) rename apps/{client-web => web}/src/components/job/JobCard/JobCard.ts (100%) rename apps/{client-web => web}/src/components/job/JobCard/JobCard.vue (100%) rename apps/{client-web => web}/src/components/obsrv/LogsViewer/LogsViewer.md (100%) rename apps/{client-web => web}/src/components/obsrv/LogsViewer/LogsViewer.ts (100%) rename apps/{client-web => web}/src/components/obsrv/LogsViewer/LogsViewer.vue (100%) rename apps/{client-web => web}/src/components/obsrv/ObservationExplorer/ObservationExplorer.md (100%) rename apps/{client-web => web}/src/components/obsrv/ObservationExplorer/ObservationExplorer.scss (100%) rename apps/{client-web => web}/src/components/obsrv/ObservationExplorer/ObservationExplorer.ts (100%) rename apps/{client-web => web}/src/components/obsrv/ObservationExplorer/ObservationExplorer.vue (100%) rename apps/{client-web => web}/src/components/peer/peerCard/peerCard.md (100%) rename apps/{client-web => web}/src/components/peer/peerCard/peerCard.scss (100%) rename apps/{client-web => web}/src/components/peer/peerCard/peerCard.ts (100%) rename apps/{client-web => web}/src/components/peer/peerCard/peerCard.vue (100%) rename apps/{client-web => web}/src/components/peer/peerList/peerList.scss (100%) rename apps/{client-web => web}/src/components/peer/peerList/peerList.ts (100%) rename apps/{client-web => web}/src/components/peer/peerList/peerList.vue (100%) rename apps/{client-web => web}/src/components/recall/RecallSearch.vue (100%) rename apps/{client-web => web}/src/components/recall/recall-search.ts (100%) rename apps/{client-web => web}/src/components/schemaConfigEditor/schemaConfigEditor.md (100%) rename apps/{client-web => web}/src/components/schemaConfigEditor/schemaConfigEditor.vue (100%) rename apps/{client-web => web}/src/components/source/createSource/createSource.md (100%) rename apps/{client-web => web}/src/components/source/createSource/createSource.scss (100%) rename apps/{client-web => web}/src/components/source/createSource/createSource.ts (100%) rename apps/{client-web => web}/src/components/source/createSource/createSource.vue (100%) rename apps/{client-web => web}/src/components/source/sourceCard/sourceCard.md (100%) rename apps/{client-web => web}/src/components/source/sourceCard/sourceCard.scss (100%) rename apps/{client-web => web}/src/components/source/sourceCard/sourceCard.ts (100%) rename apps/{client-web => web}/src/components/source/sourceCard/sourceCard.vue (100%) rename apps/{client-web => web}/src/components/source/sourceForm/sourceForm.md (100%) rename apps/{client-web => web}/src/components/source/sourceForm/sourceForm.scss (100%) rename apps/{client-web => web}/src/components/source/sourceForm/sourceForm.ts (100%) rename apps/{client-web => web}/src/components/source/sourceForm/sourceForm.vue (100%) rename apps/{client-web => web}/src/components/toast/ToastHost.scss (100%) rename apps/{client-web => web}/src/components/toast/ToastHost.vue (100%) rename apps/{client-web => web}/src/components/toast/toast.ts (100%) rename apps/{client-web => web}/src/composables/use-async-state.ts (100%) rename apps/{client-web => web}/src/composables/use-either.ts (100%) rename apps/{client-web => web}/src/composables/use-page-object-title.ts (100%) rename apps/{client-web => web}/src/core.ts (96%) rename apps/{client-web => web}/src/extension-peer-control.ts (98%) rename apps/{client-web => web}/src/locales/index.ts (100%) rename apps/{client-web => web}/src/locales/messages/en.json (100%) rename apps/{client-web => web}/src/locales/messages/zh-CN.json (100%) rename apps/{client-web => web}/src/main.ts (100%) rename apps/{client-web => web}/src/router.ts (100%) rename apps/{client-web => web}/src/storages/index.ts (100%) rename apps/{client-web => web}/src/styles/_mixins.scss (100%) rename apps/{client-web => web}/src/styles/entity-card.scss (100%) rename apps/{client-web => web}/src/styles/index.scss (100%) rename apps/{client-web => web}/src/utils/base.ts (100%) rename apps/{client-web => web}/src/utils/cron.ts (100%) rename apps/{client-web => web}/src/utils/format.ts (100%) rename apps/{client-web => web}/src/utils/vue-props.ts (100%) rename apps/{client-web => web}/src/views/extensions/extensions.scss (100%) rename apps/{client-web => web}/src/views/extensions/extensions.vue (98%) rename apps/{client-web => web}/src/views/info-base/graph/graph-layouts.ts (100%) rename apps/{client-web => web}/src/views/info-base/graph/graph-model.ts (100%) rename apps/{client-web => web}/src/views/info-base/graph/graph.scss (100%) rename apps/{client-web => web}/src/views/info-base/graph/graph.ts (100%) rename apps/{client-web => web}/src/views/info-base/graph/graph.vue (100%) rename apps/{client-web => web}/src/views/info-base/graph/useGraphScene.ts (100%) rename apps/{client-web => web}/src/views/info-base/list/list.scss (100%) rename apps/{client-web => web}/src/views/info-base/list/list.vue (100%) rename apps/{client-web => web}/src/views/jobs/job/job.scss (100%) rename apps/{client-web => web}/src/views/jobs/job/job.vue (100%) rename apps/{client-web => web}/src/views/observability/observability.vue (100%) rename apps/{client-web => web}/src/views/peers/peers.scss (100%) rename apps/{client-web => web}/src/views/peers/peers.vue (100%) rename apps/{client-web => web}/src/views/settings/settings.scss (100%) rename apps/{client-web => web}/src/views/settings/settings.vue (100%) rename apps/{client-web => web}/src/views/sources/source/source.md (100%) rename apps/{client-web => web}/src/views/sources/source/source.scss (100%) rename apps/{client-web => web}/src/views/sources/source/source.ts (100%) rename apps/{client-web => web}/src/views/sources/source/source.vue (100%) rename apps/{client-web => web}/src/views/sources/source/use-cron-manager.ts (100%) rename apps/{client-web => web}/src/views/sources/source/use-job-creator.ts (100%) rename apps/{client-web => web}/src/views/sources/source/use-source-detail.ts (100%) rename apps/{client-web => web}/src/views/sources/sources.scss (100%) rename apps/{client-web => web}/src/views/sources/sources.vue (100%) rename apps/{client-web => web}/tests/accessibility.spec.ts (100%) rename apps/{client-web => web}/tsconfig.app.json (100%) rename apps/{client-web => web}/tsconfig.json (100%) rename apps/{client-web => web}/tsconfig.node.json (100%) rename apps/{client-web => web}/uno.config.ts (100%) rename apps/{client-web => web}/vite-plugins/joint-dev-extension.ts (95%) rename apps/{client-web => web}/vite.config.ts (94%) rename apps/{client-webext => webext}/.gitignore (100%) rename apps/{client-webext => webext}/CHANGELOG.md (100%) rename apps/{client-webext => webext}/CONTRIBUTING.md (100%) rename apps/{client-webext => webext}/LICENSE (100%) rename apps/{client-webext => webext}/README.md (97%) rename apps/{client-webext => webext}/chromium-key.json (100%) rename apps/{client-webext => webext}/components/collection/MaterialReader.vue (100%) rename apps/{client-webext => webext}/entrypoints/background.ts (100%) rename apps/{client-webext => webext}/entrypoints/collection.content.ts (100%) rename apps/{client-webext => webext}/entrypoints/options/Options.vue (100%) rename apps/{client-webext => webext}/entrypoints/options/index.html (100%) rename apps/{client-webext => webext}/entrypoints/options/main.ts (100%) rename apps/{client-webext => webext}/entrypoints/parser/index.html (100%) rename apps/{client-webext => webext}/entrypoints/parser/main.ts (100%) rename apps/{client-webext => webext}/entrypoints/popup/Popup.vue (100%) rename apps/{client-webext => webext}/entrypoints/popup/index.html (100%) rename apps/{client-webext => webext}/entrypoints/popup/main.ts (100%) rename apps/{client-webext => webext}/logic/collection/capture.ts (100%) rename apps/{client-webext => webext}/logic/collection/database.ts (100%) rename apps/{client-webext => webext}/logic/collection/fetch.ts (100%) rename apps/{client-webext => webext}/logic/collection/imports.ts (100%) rename apps/{client-webext => webext}/logic/collection/legacy-storage.ts (100%) rename apps/{client-webext => webext}/logic/collection/messages.ts (100%) rename apps/{client-webext => webext}/logic/collection/outbox.ts (100%) rename apps/{client-webext => webext}/logic/collection/parse-html.ts (100%) rename apps/{client-webext => webext}/logic/collection/permissions.ts (100%) rename apps/{client-webext => webext}/logic/collection/runtime.ts (100%) rename apps/{client-webext => webext}/logic/collection/store.ts (100%) rename apps/{client-webext => webext}/logic/collection/transfer.ts (100%) rename apps/{client-webext => webext}/logic/collection/ui.css (100%) rename apps/{client-webext => webext}/logic/collection/ui.ts (100%) rename apps/{client-webext => webext}/package.json (96%) rename apps/{client-webext => webext}/styles/design/_tokens.scss (100%) rename apps/{client-webext => webext}/styles/index.ts (100%) rename apps/{client-webext => webext}/styles/main.scss (100%) rename apps/{client-webext => webext}/tsconfig.json (100%) rename apps/{client-webext => webext}/vue-shim.d.ts (100%) rename apps/{client-webext => webext}/wxt.config.ts (100%) rename docs/30-unit-tdd/{client-runtime-and-delegation.md => app-runtime-and-delegation.md} (98%) rename scripts/{verify-client-web-release.mjs => verify-web-release.mjs} (82%) diff --git a/.changeset/app-peer-naming.md b/.changeset/app-peer-naming.md new file mode 100644 index 00000000..387c0ee7 --- /dev/null +++ b/.changeset/app-peer-naming.md @@ -0,0 +1,16 @@ +--- +'@inkcre/core': patch +'@inkcre/web': patch +'@inkcre/webext': patch +'@inkcre/ext-caldav': patch +'@inkcre/ext-capture': patch +'@inkcre/ext-github': patch +'@inkcre/ext-local-files': patch +'@inkcre/ext-mail': patch +'@inkcre/ext-memos': patch +'@inkcre/ext-twitter': patch +--- + +将应用命名统一为 Web / WebExt,明确应用与运行 Peer 的角色;保留浏览器身份、存储、已发布扩展协议与部署兼容入口,构建和开发工具采用新的应用目录与 Runtime 导入名。 + +对仍准入的 Runtime 0.4.2 单独更新 Zod 依赖至修复版,保留原发布包身份与完整性。 diff --git a/.changeset/core-app-separation.md b/.changeset/core-app-separation.md index 6f1de44b..26fccd7b 100644 --- a/.changeset/core-app-separation.md +++ b/.changeset/core-app-separation.md @@ -1,7 +1,7 @@ --- '@inkcre/core': patch -'@inkcre/client-web': patch -'@inkcre/client-webext': patch +'@inkcre/web': patch +'@inkcre/webext': patch --- 在既有 0.4 兼容线新增无 Vue/Pinia 依赖的 `@inkcre/core/sdk` 入口,提供显式连接的数据访问、字节存储、认证与协议合同;现有应用入口保留兼容,并复用相同传输和存储实现。Web/WebExt 随其内嵌 Core 更新,不要求 MF 分发迁移 Host ABI。 diff --git a/.changeset/observability-unification.md b/.changeset/observability-unification.md index 51270e27..bbcb3a2e 100644 --- a/.changeset/observability-unification.md +++ b/.changeset/observability-unification.md @@ -1,7 +1,7 @@ --- '@inkcre/core': patch -'@inkcre/client-web': patch -'@inkcre/client-webext': patch +'@inkcre/web': patch +'@inkcre/webext': patch --- 统一观测记录的采集与查询,默认使用内置信息库,选定 Loki 时通过具备能力的 Peer 读写;Web 提供全局筛选、关联时间线与明确的后端/历史状态,Job 生命周期记录不再依赖额外 OTEL 出口开关。 diff --git a/.github/pages-preview-closed/index.html b/.github/pages-preview-closed/index.html index bc7dec3d..07e96d96 100644 --- a/.github/pages-preview-closed/index.html +++ b/.github/pages-preview-closed/index.html @@ -9,7 +9,7 @@

This pull-request preview is closed.

-

Review the accepted client at app.inkcre.dev.

+

Review the accepted Web App at app.inkcre.dev.

diff --git a/.github/preview/extensions.json b/.github/preview/extensions.json index cadcc92d..ccc70f2a 100644 --- a/.github/preview/extensions.json +++ b/.github/preview/extensions.json @@ -4,27 +4,27 @@ { "kind": "module_federation", "producer": "../../extensions/caldav/package.json", - "artifact": "../../extensions/caldav/dist/client-web" + "artifact": "../../extensions/caldav/dist/web" }, { "kind": "module_federation", "producer": "../../extensions/capture/package.json", - "artifact": "../../extensions/capture/dist/client-web" + "artifact": "../../extensions/capture/dist/web" }, { "kind": "module_federation", "producer": "../../extensions/twitter/package.json", - "artifact": "../../extensions/twitter/dist/client-web" + "artifact": "../../extensions/twitter/dist/web" }, { "kind": "module_federation", "producer": "../../extensions/mail/package.json", - "artifact": "../../extensions/mail/dist/client-web" + "artifact": "../../extensions/mail/dist/web" }, { "kind": "module_federation", "producer": "../../extensions/github/package.json", - "artifact": "../../extensions/github/dist/client-web" + "artifact": "../../extensions/github/dist/web" } ] } diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index dd975694..6586dd07 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,4 +1,4 @@ -name: Client checks +name: App checks on: pull_request: @@ -17,7 +17,7 @@ permissions: concurrency: group: >- - client-checks-${{ + app-checks-${{ github.event.pull_request.number || github.ref }} @@ -122,6 +122,7 @@ jobs: scripts/tests/pages-preview.test.mjs peer-database: + # Existing branch protection binds this exact check name. name: client-web E2E needs: core-release runs-on: ubuntu-latest @@ -171,6 +172,7 @@ jobs: retention-days: 7 browser-extension: + # Existing branch protection binds this exact check name. name: client-webext E2E runs-on: ubuntu-latest steps: @@ -198,7 +200,7 @@ jobs: run: pnpm test:e2e:webext - name: Build the Firefox extension - run: pnpm --filter @inkcre/client-webext build:firefox + run: pnpm --filter @inkcre/webext build:firefox - name: Verify WebExt delivery rules run: node --test scripts/tests/webext-release.test.mjs diff --git a/.github/workflows/pages-deploy.yml b/.github/workflows/pages-deploy.yml index 324b92d1..c91a301c 100644 --- a/.github/workflows/pages-deploy.yml +++ b/.github/workflows/pages-deploy.yml @@ -97,7 +97,7 @@ jobs: wranglerVersion: 4.114.0 workingDirectory: release command: >- - pages deploy apps/client-web/dist + pages deploy apps/web/dist --project-name=${{ vars.CLOUDFLARE_PAGES_PROJECT }} --branch=main --commit-hash=${{ needs.identity.outputs.source_sha }} @@ -108,4 +108,4 @@ jobs: env: CLOUDFLARE_PAGES_DEPLOYMENT_ID: ${{ steps.pages.outputs.pages-deployment-id }} CLOUDFLARE_PAGES_DEPLOYMENT_URL: ${{ steps.pages.outputs.deployment-url }} - INKCRE_CLIENT_WEB_ORIGIN: https://app.inkcre.dev + INKCRE_WEB_ORIGIN: https://app.inkcre.dev diff --git a/.github/workflows/pages-preview.yml b/.github/workflows/pages-preview.yml index a987efd4..dcd3e625 100644 --- a/.github/workflows/pages-preview.yml +++ b/.github/workflows/pages-preview.yml @@ -115,8 +115,8 @@ jobs: --inventory .github/preview/extensions.json \ --public-origin "$PREVIEW_ORIGIN" \ --output .preview-registry - cp -R .preview-registry/. apps/client-web/dist/ - cp -R apps/client-web/dist "$GITHUB_WORKSPACE/.pages-preview" + cp -R .preview-registry/. apps/web/dist/ + cp -R apps/web/dist "$GITHUB_WORKSPACE/.pages-preview" - name: Bind Module Federation assets to the selected snapshot env: diff --git a/.oxlintrc.json b/.oxlintrc.json index a6eef3ed..742c160a 100644 --- a/.oxlintrc.json +++ b/.oxlintrc.json @@ -10,7 +10,7 @@ }, "ignorePatterns": [ "docs/_shared/**", - "apps/client-webext/components.d.ts", + "apps/webext/components.d.ts", ".agents/skills/**", "tasks/**" ], diff --git a/.vscode/default.code-snippets b/.vscode/default.code-snippets index 13ffda19..92beb1c9 100644 --- a/.vscode/default.code-snippets +++ b/.vscode/default.code-snippets @@ -1,5 +1,5 @@ { - // Place your client-web workspace snippets here. Each snippet is defined under a snippet name and has a scope, prefix, body and + // Place your web workspace snippets here. Each snippet is defined under a snippet name and has a scope, prefix, body and // description. Add comma separated ids of the languages where the snippet is applicable in the scope field. If scope // is left empty or omitted, the snippet gets applied to all languages. The prefix is what is // used to trigger the snippet and the body will be expanded and inserted. Possible variables are: diff --git a/AGENTS.md b/AGENTS.md index 4e19fde7..14dde33d 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -30,8 +30,8 @@ Before choosing a design, identify shared state, business contracts, and each pa ## Repository Map -- `apps/client-web/`: static Vue SPA (the web peer) -- `apps/client-webext/`: WXT browser extension (the browser-extension peer) +- `apps/web/`: static Vue SPA (the web peer) +- `apps/webext/`: WXT browser extension (the browser-extension peer) - `packages/core/`: shared models, protocols, storage/resolver mechanics, Extension Host - `packages/ext-dev-utils/`: extension development utilities - `extensions/`: independently versioned native Module Federation producers (mail, memos, twitter) @@ -48,7 +48,7 @@ For UI work, read the installed `@inkcre/ui-web` package's `DESIGN.md` and `skil - Runtime: Node.js 22.22.3; package manager: pnpm 11.11.0. Exact commands live in `package.json` and `docs/40-deployment/`. - `.env` files are dotenv data, not shell scripts. Load them through the application because values may contain shell metacharacters. - Generated contracts under `contracts/` are checked-in projections. Change their source and regenerate; do not edit them directly. -- The `apps/client-webext/` WXT extension and the `apps/client-web/` Vue SPA share `@inkcre/core` but run in different security contexts. Changes that cross the seam must be validated against both runtimes. +- The `apps/webext/` WXT extension and the `apps/web/` Vue SPA share `@inkcre/core` but run in different security contexts. Changes that cross the seam must be validated against both runtimes. - Follow `.agents/prompts/code-for-human.md` for source changes. ## Governance And Workflow diff --git a/ARCHITECTURE.md b/ARCHITECTURE.md index 87145a21..e7835f0a 100644 --- a/ARCHITECTURE.md +++ b/ARCHITECTURE.md @@ -1,6 +1,6 @@ # Repository Architecture -This monorepo implements three logical client-side units across shared packages, applications, and +This monorepo implements three logical browser units across shared packages, applications, and independently built Extension producers. ```text @@ -12,7 +12,7 @@ Module Federation producers ---+ | | ## Logical Units -- [Client Runtime and Delegation](docs/30-unit-tdd/client-runtime-and-delegation.md) owns the +- [App Runtime and Delegation](docs/30-unit-tdd/app-runtime-and-delegation.md) owns the environment-neutral browser Peer, bootstrap/authentication authority, exact capability delegation, and navigation hosts. - [Info-Base](docs/30-unit-tdd/info-base.md) owns graph models, hydration, byte storage, exact @@ -40,8 +40,8 @@ locations, not Unit boundaries. - `packages/core/` - shared models, database access, Peer protocols, storage/Resolver mechanics, configuration/authentication, and Extension Host. -- `apps/client-web/` - Vue SPA, graph/list surfaces, settings, and static Vite artifact. -- `apps/client-webext/` - WXT browser surfaces and content scripts. +- `apps/web/` - Vue SPA, graph/list surfaces, settings, and static Vite artifact. +- `apps/webext/` - WXT browser surfaces and content scripts. - `extensions/` - independently built native Module Federation producers. - `packages/ext-dev-utils/` - producer development support consumed by applications. diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index b339b7f6..1ddcfcb0 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -40,14 +40,14 @@ development or production info-base. ## Monorepo boundaries and change names -- `apps/client-web/` and `apps/client-webext/` are independently delivered applications. +- `apps/web/` and `apps/webext/` are independently delivered applications. - `packages/core/` and `packages/ext-dev-utils/` are shared packages. - Each `extensions//` is an independently versioned Module Federation distribution. -Use the primary area as the `type(scope): summary` scope: `client-web`, `client-webext`, `core`, +Use the primary area as the `type(scope): summary` scope: `web`, `webext`, `core`, `ext-dev-utils`, or an Extension ID such as `twitter`. Use `extensions` for one coherent change spanning several Extensions and `release` for release tooling. The title does not select versions; -list every affected release project in the pull-request body. Examples: `fix(client-web): retain peer +list every affected release project in the pull-request body. Examples: `fix(web): retain peer selection`, `feat(twitter): show archived media`, and `ref(extensions): share host bootstrap`. For user-visible behavior or another delivered contract, run `pnpm changeset` and select the exact diff --git a/FILESYSTEM.md b/FILESYSTEM.md index d4a53821..a81e17e4 100644 --- a/FILESYSTEM.md +++ b/FILESYSTEM.md @@ -5,8 +5,8 @@ - `.agents/` - Consumer-owned Agent prompts and shared-doc workflow bridge. - `.github/` - CI, release, deployment, contextual coding instructions, and explicit preview inventories under `.github/preview/`. -- `apps/client-web/` - Static Vue application. -- `apps/client-webext/` - WXT browser extension. +- `apps/web/` - Static Vue application. +- `apps/webext/` - WXT browser extension. - `contracts/` - Checked upstream release and compatibility inputs. - `docs/` - Local durable technical owners; `_shared/` is the read-only Hub reference. - `extensions/` - Independently versioned native Module Federation producers. @@ -18,10 +18,10 @@ ## Primary Entrypoints -- `apps/client-web/src/main.ts` - Web bootstrap. -- `apps/client-web/src/core.ts` - Core registration and initialization. -- `apps/client-web/src/router.ts` - Web route authority. -- `apps/client-webext/entrypoints/` - WXT-discovered extension surfaces. +- `apps/web/src/main.ts` - Web bootstrap. +- `apps/web/src/core.ts` - Core registration and initialization. +- `apps/web/src/router.ts` - Web route authority. +- `apps/webext/entrypoints/` - WXT-discovered extension surfaces. - `packages/core/src/sdk.ts` - Independent SDK exports with explicit connections. - `packages/core/src/index.ts` - Published Vue/MF compatibility exports. - `extensions/*/src/index.ts` - Host-consumed Extension exports. diff --git a/README.md b/README.md index 79c4c8a6..862402e2 100644 --- a/README.md +++ b/README.md @@ -7,8 +7,8 @@ The TypeScript peer of InKCre — the web application, the browser extension, an ## Repository shape - `packages/core/` — `@inkcre/core` shared SDK (info-base model, storage, resolvers, retrieval, extension host) -- `apps/client-web/` — Vue 3 web application (static Vite artifact) -- `apps/client-webext/` — WXT browser extension +- `apps/web/` — Vue 3 web application (static Vite artifact) +- `apps/webext/` — WXT browser extension - `extensions/` — independently built native Module Federation producers (`ext-github`, `ext-mail`, `ext-twitter`, `ext-memos`) ## Quickstart diff --git a/apps/client-web/AGENTS.md b/apps/web/AGENTS.md similarity index 82% rename from apps/client-web/AGENTS.md rename to apps/web/AGENTS.md index b707bbc3..edf4189f 100644 --- a/apps/client-web/AGENTS.md +++ b/apps/web/AGENTS.md @@ -1,10 +1,10 @@ -# Client-Web +# Web App Static Vue application and equal InKCre database Peer. ## Owners -- Runtime, Peer delegation, configuration, and authentication: `../../docs/30-unit-tdd/client-runtime-and-delegation.md`. +- Runtime, Peer delegation, configuration, and authentication: `../../docs/30-unit-tdd/app-runtime-and-delegation.md`. - Info-Base and Resolver contracts: `../../docs/30-unit-tdd/info-base.md`. - Native Extension Host: `../../docs/30-unit-tdd/native-extension-runtime.md`. - Local and sibling-UI development lanes: `../../docs/40-deployment/development-runtime.md`. @@ -14,12 +14,12 @@ Static Vue application and equal InKCre database Peer. - Keep deployable artifacts environment-neutral: no service origin, Peer identity, JWT secret, Worker runtime, or `/api/config` fallback. - Browser-owned settings are runtime authority. Keep the JWT signing secret masked during ordinary display and absent from logs. The explicit full-browser export includes it so another browser can restore the same experience. -- Use **Peer** for InKCre runtime nodes in both technical contracts and product UI. Keep “client” only for actual application or protocol client roles. +- Use **Peer** for InKCre runtime nodes in both technical contracts and product UI. Keep “client” only for actual protocol client roles. - Preserve exact capability delegation and typed unknown outcomes; do not replace them with a generic Core API path or automatic retry after ambiguous dispatch. - Start development through root commands so SVC and Portless preserve worktree identity. The sibling UI source lane is explicitly non-release evidence. ## Checks -- `pnpm --filter @inkcre/client-web type-check` -- `pnpm --filter @inkcre/client-web build` +- `pnpm --filter @inkcre/web type-check` +- `pnpm --filter @inkcre/web build` - `pnpm check` diff --git a/apps/client-web/CHANGELOG.md b/apps/web/CHANGELOG.md similarity index 100% rename from apps/client-web/CHANGELOG.md rename to apps/web/CHANGELOG.md diff --git a/apps/client-web/env.d.ts b/apps/web/env.d.ts similarity index 100% rename from apps/client-web/env.d.ts rename to apps/web/env.d.ts diff --git a/apps/client-web/index.html b/apps/web/index.html similarity index 100% rename from apps/client-web/index.html rename to apps/web/index.html diff --git a/apps/client-web/package.json b/apps/web/package.json similarity index 89% rename from apps/client-web/package.json rename to apps/web/package.json index 009942ed..e3384805 100644 --- a/apps/client-web/package.json +++ b/apps/web/package.json @@ -1,5 +1,5 @@ { - "name": "@inkcre/client-web", + "name": "@inkcre/web", "version": "0.2.1", "private": true, "type": "module", @@ -15,7 +15,7 @@ "dependencies": { "@dagrejs/dagre": "^3.1.2", "@inkcre/core": "workspace:*", - "@inkcre/extension-runtime-client-web": "https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz", + "@inkcre/extension-runtime-web": "https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz", "@inkcre/ui-web": "2.7.0", "@module-federation/runtime": "^0.21.4", "@supabase/postgrest-js": "^2.118.0", diff --git a/apps/client-web/playwright.config.ts b/apps/web/playwright.config.ts similarity index 100% rename from apps/client-web/playwright.config.ts rename to apps/web/playwright.config.ts diff --git a/apps/client-web/public/_headers b/apps/web/public/_headers similarity index 100% rename from apps/client-web/public/_headers rename to apps/web/public/_headers diff --git a/apps/client-web/public/favicon.ico b/apps/web/public/favicon.ico similarity index 100% rename from apps/client-web/public/favicon.ico rename to apps/web/public/favicon.ico diff --git a/apps/client-web/public/logo/256.svg b/apps/web/public/logo/256.svg similarity index 100% rename from apps/client-web/public/logo/256.svg rename to apps/web/public/logo/256.svg diff --git a/apps/client-web/public/logo/32.svg b/apps/web/public/logo/32.svg similarity index 100% rename from apps/client-web/public/logo/32.svg rename to apps/web/public/logo/32.svg diff --git a/apps/client-web/src/App.vue b/apps/web/src/App.vue similarity index 100% rename from apps/client-web/src/App.vue rename to apps/web/src/App.vue diff --git a/apps/client-web/src/components/AGENTS.md b/apps/web/src/components/AGENTS.md similarity index 67% rename from apps/client-web/src/components/AGENTS.md rename to apps/web/src/components/AGENTS.md index f70bcdc4..bc120712 100644 --- a/apps/client-web/src/components/AGENTS.md +++ b/apps/web/src/components/AGENTS.md @@ -1,6 +1,6 @@ # Component Subtree Instructions -Scope: `apps/client-web/src/components/**`. +Scope: `apps/web/src/components/**`. ## Hazards and Owners @@ -8,7 +8,7 @@ Scope: `apps/client-web/src/components/**`. component-local copy of a model merely to shape props or emits. - Solved-content renderer selection belongs to the core `Resolver` registration. Keep `SolvedContentRenderer` as a dynamic handoff; do not add a second resolver-to-component map here. -- Keep InKCre runtime-node names under `peer/` and use “Peer” in user-facing copy. Use “client” only for actual application or protocol client roles. +- Keep InKCre runtime-node names under `peer/` and use “Peer” in user-facing copy. Use “client” only for actual protocol client roles. General component file guidance lives in [component.instructions.md](../../../../.github/instructions/component.instructions.md). Stable @@ -16,5 +16,5 @@ runtime and Info-Base semantics belong to `../../../../docs/30-unit-tdd/`. ## Checks -- Run `pnpm --filter @inkcre/client-web type-check` after changing component contracts or Vue code. -- Run `pnpm --filter @inkcre/client-web test` when changing behavior covered by component specs. +- Run `pnpm --filter @inkcre/web type-check` after changing component contracts or Vue code. +- Run `pnpm --filter @inkcre/web test` when changing behavior covered by component specs. diff --git a/apps/client-web/src/components/common/AppSidePanel/AppSidePanel.md b/apps/web/src/components/common/AppSidePanel/AppSidePanel.md similarity index 100% rename from apps/client-web/src/components/common/AppSidePanel/AppSidePanel.md rename to apps/web/src/components/common/AppSidePanel/AppSidePanel.md diff --git a/apps/client-web/src/components/common/AppSidePanel/AppSidePanel.scss b/apps/web/src/components/common/AppSidePanel/AppSidePanel.scss similarity index 100% rename from apps/client-web/src/components/common/AppSidePanel/AppSidePanel.scss rename to apps/web/src/components/common/AppSidePanel/AppSidePanel.scss diff --git a/apps/client-web/src/components/common/AppSidePanel/AppSidePanel.ts b/apps/web/src/components/common/AppSidePanel/AppSidePanel.ts similarity index 100% rename from apps/client-web/src/components/common/AppSidePanel/AppSidePanel.ts rename to apps/web/src/components/common/AppSidePanel/AppSidePanel.ts diff --git a/apps/client-web/src/components/common/AppSidePanel/AppSidePanel.vue b/apps/web/src/components/common/AppSidePanel/AppSidePanel.vue similarity index 100% rename from apps/client-web/src/components/common/AppSidePanel/AppSidePanel.vue rename to apps/web/src/components/common/AppSidePanel/AppSidePanel.vue diff --git a/apps/client-web/src/components/extension/extensionCard/extensionCard.md b/apps/web/src/components/extension/extensionCard/extensionCard.md similarity index 100% rename from apps/client-web/src/components/extension/extensionCard/extensionCard.md rename to apps/web/src/components/extension/extensionCard/extensionCard.md diff --git a/apps/client-web/src/components/extension/extensionCard/extensionCard.scss b/apps/web/src/components/extension/extensionCard/extensionCard.scss similarity index 100% rename from apps/client-web/src/components/extension/extensionCard/extensionCard.scss rename to apps/web/src/components/extension/extensionCard/extensionCard.scss diff --git a/apps/client-web/src/components/extension/extensionCard/extensionCard.ts b/apps/web/src/components/extension/extensionCard/extensionCard.ts similarity index 100% rename from apps/client-web/src/components/extension/extensionCard/extensionCard.ts rename to apps/web/src/components/extension/extensionCard/extensionCard.ts diff --git a/apps/client-web/src/components/extension/extensionCard/extensionCard.vue b/apps/web/src/components/extension/extensionCard/extensionCard.vue similarity index 100% rename from apps/client-web/src/components/extension/extensionCard/extensionCard.vue rename to apps/web/src/components/extension/extensionCard/extensionCard.vue diff --git a/apps/client-web/src/components/extension/extensionCard/use-extension-info-dialogs.ts b/apps/web/src/components/extension/extensionCard/use-extension-info-dialogs.ts similarity index 99% rename from apps/client-web/src/components/extension/extensionCard/use-extension-info-dialogs.ts rename to apps/web/src/components/extension/extensionCard/use-extension-info-dialogs.ts index 250d2a2f..ab42786e 100644 --- a/apps/client-web/src/components/extension/extensionCard/use-extension-info-dialogs.ts +++ b/apps/web/src/components/extension/extensionCard/use-extension-info-dialogs.ts @@ -4,7 +4,7 @@ import { ExtensionModel, ExtensionRegistryOriginResolver, configStore } from '@i import { getExtensionDocumentation, type ExtensionDocumentationLink, -} from '@inkcre/extension-runtime-client-web' +} from '@inkcre/extension-runtime-web' import type { JsonEditorValidation } from '@inkcre/ui-web' import type { ExtensionCardData, useExtensionPeerRuntime } from './use-extension-peer-runtime' diff --git a/apps/client-web/src/components/extension/extensionCard/use-extension-peer-runtime.ts b/apps/web/src/components/extension/extensionCard/use-extension-peer-runtime.ts similarity index 99% rename from apps/client-web/src/components/extension/extensionCard/use-extension-peer-runtime.ts rename to apps/web/src/components/extension/extensionCard/use-extension-peer-runtime.ts index 4533cbbf..c2a104fb 100644 --- a/apps/client-web/src/components/extension/extensionCard/use-extension-peer-runtime.ts +++ b/apps/web/src/components/extension/extensionCard/use-extension-peer-runtime.ts @@ -19,7 +19,7 @@ import { type NativeDistribution, type Peer, } from '@inkcre/core' -import { manageExtensionOnPeer } from '@inkcre/extension-runtime-client-web' +import { manageExtensionOnPeer } from '@inkcre/extension-runtime-web' import { extensionHostRestoreState, extensionHostConnectionReady, diff --git a/apps/client-web/src/components/extension/extensionCard/use-extension-version-dialog.ts b/apps/web/src/components/extension/extensionCard/use-extension-version-dialog.ts similarity index 99% rename from apps/client-web/src/components/extension/extensionCard/use-extension-version-dialog.ts rename to apps/web/src/components/extension/extensionCard/use-extension-version-dialog.ts index 33dd96bc..77de26f4 100644 --- a/apps/client-web/src/components/extension/extensionCard/use-extension-version-dialog.ts +++ b/apps/web/src/components/extension/extensionCard/use-extension-version-dialog.ts @@ -12,7 +12,7 @@ import { RegistryReleaseError, sortPublishedReleases, type ReleaseRecord, -} from '@inkcre/extension-runtime-client-web' +} from '@inkcre/extension-runtime-web' import { getExtensionHost, getExtensionRegistry } from '@/core' import { selectExtensionPeerVersion } from '@/extension-peer-control' import type { ExtensionCardData, useExtensionPeerRuntime } from './use-extension-peer-runtime' diff --git a/apps/client-web/src/components/info-base/BlockInspectorPopup/BlockInspectorPopup.scss b/apps/web/src/components/info-base/BlockInspectorPopup/BlockInspectorPopup.scss similarity index 100% rename from apps/client-web/src/components/info-base/BlockInspectorPopup/BlockInspectorPopup.scss rename to apps/web/src/components/info-base/BlockInspectorPopup/BlockInspectorPopup.scss diff --git a/apps/client-web/src/components/info-base/BlockInspectorPopup/BlockInspectorPopup.ts b/apps/web/src/components/info-base/BlockInspectorPopup/BlockInspectorPopup.ts similarity index 100% rename from apps/client-web/src/components/info-base/BlockInspectorPopup/BlockInspectorPopup.ts rename to apps/web/src/components/info-base/BlockInspectorPopup/BlockInspectorPopup.ts diff --git a/apps/client-web/src/components/info-base/BlockInspectorPopup/BlockInspectorPopup.vue b/apps/web/src/components/info-base/BlockInspectorPopup/BlockInspectorPopup.vue similarity index 100% rename from apps/client-web/src/components/info-base/BlockInspectorPopup/BlockInspectorPopup.vue rename to apps/web/src/components/info-base/BlockInspectorPopup/BlockInspectorPopup.vue diff --git a/apps/client-web/src/components/info-base/BlockNode/BlockNode.scss b/apps/web/src/components/info-base/BlockNode/BlockNode.scss similarity index 100% rename from apps/client-web/src/components/info-base/BlockNode/BlockNode.scss rename to apps/web/src/components/info-base/BlockNode/BlockNode.scss diff --git a/apps/client-web/src/components/info-base/BlockNode/BlockNode.ts b/apps/web/src/components/info-base/BlockNode/BlockNode.ts similarity index 100% rename from apps/client-web/src/components/info-base/BlockNode/BlockNode.ts rename to apps/web/src/components/info-base/BlockNode/BlockNode.ts diff --git a/apps/client-web/src/components/info-base/BlockNode/BlockNode.vue b/apps/web/src/components/info-base/BlockNode/BlockNode.vue similarity index 100% rename from apps/client-web/src/components/info-base/BlockNode/BlockNode.vue rename to apps/web/src/components/info-base/BlockNode/BlockNode.vue diff --git a/apps/client-web/src/components/info-base/InfoBaseViewTabs.vue b/apps/web/src/components/info-base/InfoBaseViewTabs.vue similarity index 100% rename from apps/client-web/src/components/info-base/InfoBaseViewTabs.vue rename to apps/web/src/components/info-base/InfoBaseViewTabs.vue diff --git a/apps/client-web/src/components/info-base/PreviewRenderer/PreviewRenderer.ts b/apps/web/src/components/info-base/PreviewRenderer/PreviewRenderer.ts similarity index 100% rename from apps/client-web/src/components/info-base/PreviewRenderer/PreviewRenderer.ts rename to apps/web/src/components/info-base/PreviewRenderer/PreviewRenderer.ts diff --git a/apps/client-web/src/components/info-base/PreviewRenderer/PreviewRenderer.vue b/apps/web/src/components/info-base/PreviewRenderer/PreviewRenderer.vue similarity index 100% rename from apps/client-web/src/components/info-base/PreviewRenderer/PreviewRenderer.vue rename to apps/web/src/components/info-base/PreviewRenderer/PreviewRenderer.vue diff --git a/apps/client-web/src/components/info-base/RelationEdge/RelationEdge.scss b/apps/web/src/components/info-base/RelationEdge/RelationEdge.scss similarity index 100% rename from apps/client-web/src/components/info-base/RelationEdge/RelationEdge.scss rename to apps/web/src/components/info-base/RelationEdge/RelationEdge.scss diff --git a/apps/client-web/src/components/info-base/RelationEdge/RelationEdge.ts b/apps/web/src/components/info-base/RelationEdge/RelationEdge.ts similarity index 100% rename from apps/client-web/src/components/info-base/RelationEdge/RelationEdge.ts rename to apps/web/src/components/info-base/RelationEdge/RelationEdge.ts diff --git a/apps/client-web/src/components/info-base/RelationEdge/RelationEdge.vue b/apps/web/src/components/info-base/RelationEdge/RelationEdge.vue similarity index 100% rename from apps/client-web/src/components/info-base/RelationEdge/RelationEdge.vue rename to apps/web/src/components/info-base/RelationEdge/RelationEdge.vue diff --git a/apps/client-web/src/components/info-base/RelationInspectorPopup/RelationInspectorPopup.ts b/apps/web/src/components/info-base/RelationInspectorPopup/RelationInspectorPopup.ts similarity index 100% rename from apps/client-web/src/components/info-base/RelationInspectorPopup/RelationInspectorPopup.ts rename to apps/web/src/components/info-base/RelationInspectorPopup/RelationInspectorPopup.ts diff --git a/apps/client-web/src/components/info-base/RelationInspectorPopup/RelationInspectorPopup.vue b/apps/web/src/components/info-base/RelationInspectorPopup/RelationInspectorPopup.vue similarity index 100% rename from apps/client-web/src/components/info-base/RelationInspectorPopup/RelationInspectorPopup.vue rename to apps/web/src/components/info-base/RelationInspectorPopup/RelationInspectorPopup.vue diff --git a/apps/client-web/src/components/info-base/SolvedContentPopup/SolvedContentPopup.scss b/apps/web/src/components/info-base/SolvedContentPopup/SolvedContentPopup.scss similarity index 100% rename from apps/client-web/src/components/info-base/SolvedContentPopup/SolvedContentPopup.scss rename to apps/web/src/components/info-base/SolvedContentPopup/SolvedContentPopup.scss diff --git a/apps/client-web/src/components/info-base/SolvedContentPopup/SolvedContentPopup.ts b/apps/web/src/components/info-base/SolvedContentPopup/SolvedContentPopup.ts similarity index 100% rename from apps/client-web/src/components/info-base/SolvedContentPopup/SolvedContentPopup.ts rename to apps/web/src/components/info-base/SolvedContentPopup/SolvedContentPopup.ts diff --git a/apps/client-web/src/components/info-base/SolvedContentPopup/SolvedContentPopup.vue b/apps/web/src/components/info-base/SolvedContentPopup/SolvedContentPopup.vue similarity index 100% rename from apps/client-web/src/components/info-base/SolvedContentPopup/SolvedContentPopup.vue rename to apps/web/src/components/info-base/SolvedContentPopup/SolvedContentPopup.vue diff --git a/apps/client-web/src/components/info-base/SolvedContentRenderer/SolvedContentRenderer.ts b/apps/web/src/components/info-base/SolvedContentRenderer/SolvedContentRenderer.ts similarity index 100% rename from apps/client-web/src/components/info-base/SolvedContentRenderer/SolvedContentRenderer.ts rename to apps/web/src/components/info-base/SolvedContentRenderer/SolvedContentRenderer.ts diff --git a/apps/client-web/src/components/info-base/SolvedContentRenderer/SolvedContentRenderer.vue b/apps/web/src/components/info-base/SolvedContentRenderer/SolvedContentRenderer.vue similarity index 100% rename from apps/client-web/src/components/info-base/SolvedContentRenderer/SolvedContentRenderer.vue rename to apps/web/src/components/info-base/SolvedContentRenderer/SolvedContentRenderer.vue diff --git a/apps/client-web/src/components/info-base/resolvers/ContentAudio.vue b/apps/web/src/components/info-base/resolvers/ContentAudio.vue similarity index 100% rename from apps/client-web/src/components/info-base/resolvers/ContentAudio.vue rename to apps/web/src/components/info-base/resolvers/ContentAudio.vue diff --git a/apps/client-web/src/components/info-base/resolvers/ContentFile.vue b/apps/web/src/components/info-base/resolvers/ContentFile.vue similarity index 100% rename from apps/client-web/src/components/info-base/resolvers/ContentFile.vue rename to apps/web/src/components/info-base/resolvers/ContentFile.vue diff --git a/apps/client-web/src/components/info-base/resolvers/ContentHtml.vue b/apps/web/src/components/info-base/resolvers/ContentHtml.vue similarity index 100% rename from apps/client-web/src/components/info-base/resolvers/ContentHtml.vue rename to apps/web/src/components/info-base/resolvers/ContentHtml.vue diff --git a/apps/client-web/src/components/info-base/resolvers/ContentImage.vue b/apps/web/src/components/info-base/resolvers/ContentImage.vue similarity index 100% rename from apps/client-web/src/components/info-base/resolvers/ContentImage.vue rename to apps/web/src/components/info-base/resolvers/ContentImage.vue diff --git a/apps/client-web/src/components/info-base/resolvers/ContentPreview.vue b/apps/web/src/components/info-base/resolvers/ContentPreview.vue similarity index 100% rename from apps/client-web/src/components/info-base/resolvers/ContentPreview.vue rename to apps/web/src/components/info-base/resolvers/ContentPreview.vue diff --git a/apps/client-web/src/components/info-base/resolvers/ContentText.vue b/apps/web/src/components/info-base/resolvers/ContentText.vue similarity index 100% rename from apps/client-web/src/components/info-base/resolvers/ContentText.vue rename to apps/web/src/components/info-base/resolvers/ContentText.vue diff --git a/apps/client-web/src/components/info-base/resolvers/ContentVideo.vue b/apps/web/src/components/info-base/resolvers/ContentVideo.vue similarity index 100% rename from apps/client-web/src/components/info-base/resolvers/ContentVideo.vue rename to apps/web/src/components/info-base/resolvers/ContentVideo.vue diff --git a/apps/client-web/src/components/job/JobCard/JobCard.md b/apps/web/src/components/job/JobCard/JobCard.md similarity index 100% rename from apps/client-web/src/components/job/JobCard/JobCard.md rename to apps/web/src/components/job/JobCard/JobCard.md diff --git a/apps/client-web/src/components/job/JobCard/JobCard.scss b/apps/web/src/components/job/JobCard/JobCard.scss similarity index 100% rename from apps/client-web/src/components/job/JobCard/JobCard.scss rename to apps/web/src/components/job/JobCard/JobCard.scss diff --git a/apps/client-web/src/components/job/JobCard/JobCard.ts b/apps/web/src/components/job/JobCard/JobCard.ts similarity index 100% rename from apps/client-web/src/components/job/JobCard/JobCard.ts rename to apps/web/src/components/job/JobCard/JobCard.ts diff --git a/apps/client-web/src/components/job/JobCard/JobCard.vue b/apps/web/src/components/job/JobCard/JobCard.vue similarity index 100% rename from apps/client-web/src/components/job/JobCard/JobCard.vue rename to apps/web/src/components/job/JobCard/JobCard.vue diff --git a/apps/client-web/src/components/obsrv/LogsViewer/LogsViewer.md b/apps/web/src/components/obsrv/LogsViewer/LogsViewer.md similarity index 100% rename from apps/client-web/src/components/obsrv/LogsViewer/LogsViewer.md rename to apps/web/src/components/obsrv/LogsViewer/LogsViewer.md diff --git a/apps/client-web/src/components/obsrv/LogsViewer/LogsViewer.ts b/apps/web/src/components/obsrv/LogsViewer/LogsViewer.ts similarity index 100% rename from apps/client-web/src/components/obsrv/LogsViewer/LogsViewer.ts rename to apps/web/src/components/obsrv/LogsViewer/LogsViewer.ts diff --git a/apps/client-web/src/components/obsrv/LogsViewer/LogsViewer.vue b/apps/web/src/components/obsrv/LogsViewer/LogsViewer.vue similarity index 100% rename from apps/client-web/src/components/obsrv/LogsViewer/LogsViewer.vue rename to apps/web/src/components/obsrv/LogsViewer/LogsViewer.vue diff --git a/apps/client-web/src/components/obsrv/ObservationExplorer/ObservationExplorer.md b/apps/web/src/components/obsrv/ObservationExplorer/ObservationExplorer.md similarity index 100% rename from apps/client-web/src/components/obsrv/ObservationExplorer/ObservationExplorer.md rename to apps/web/src/components/obsrv/ObservationExplorer/ObservationExplorer.md diff --git a/apps/client-web/src/components/obsrv/ObservationExplorer/ObservationExplorer.scss b/apps/web/src/components/obsrv/ObservationExplorer/ObservationExplorer.scss similarity index 100% rename from apps/client-web/src/components/obsrv/ObservationExplorer/ObservationExplorer.scss rename to apps/web/src/components/obsrv/ObservationExplorer/ObservationExplorer.scss diff --git a/apps/client-web/src/components/obsrv/ObservationExplorer/ObservationExplorer.ts b/apps/web/src/components/obsrv/ObservationExplorer/ObservationExplorer.ts similarity index 100% rename from apps/client-web/src/components/obsrv/ObservationExplorer/ObservationExplorer.ts rename to apps/web/src/components/obsrv/ObservationExplorer/ObservationExplorer.ts diff --git a/apps/client-web/src/components/obsrv/ObservationExplorer/ObservationExplorer.vue b/apps/web/src/components/obsrv/ObservationExplorer/ObservationExplorer.vue similarity index 100% rename from apps/client-web/src/components/obsrv/ObservationExplorer/ObservationExplorer.vue rename to apps/web/src/components/obsrv/ObservationExplorer/ObservationExplorer.vue diff --git a/apps/client-web/src/components/peer/peerCard/peerCard.md b/apps/web/src/components/peer/peerCard/peerCard.md similarity index 100% rename from apps/client-web/src/components/peer/peerCard/peerCard.md rename to apps/web/src/components/peer/peerCard/peerCard.md diff --git a/apps/client-web/src/components/peer/peerCard/peerCard.scss b/apps/web/src/components/peer/peerCard/peerCard.scss similarity index 100% rename from apps/client-web/src/components/peer/peerCard/peerCard.scss rename to apps/web/src/components/peer/peerCard/peerCard.scss diff --git a/apps/client-web/src/components/peer/peerCard/peerCard.ts b/apps/web/src/components/peer/peerCard/peerCard.ts similarity index 100% rename from apps/client-web/src/components/peer/peerCard/peerCard.ts rename to apps/web/src/components/peer/peerCard/peerCard.ts diff --git a/apps/client-web/src/components/peer/peerCard/peerCard.vue b/apps/web/src/components/peer/peerCard/peerCard.vue similarity index 100% rename from apps/client-web/src/components/peer/peerCard/peerCard.vue rename to apps/web/src/components/peer/peerCard/peerCard.vue diff --git a/apps/client-web/src/components/peer/peerList/peerList.scss b/apps/web/src/components/peer/peerList/peerList.scss similarity index 100% rename from apps/client-web/src/components/peer/peerList/peerList.scss rename to apps/web/src/components/peer/peerList/peerList.scss diff --git a/apps/client-web/src/components/peer/peerList/peerList.ts b/apps/web/src/components/peer/peerList/peerList.ts similarity index 100% rename from apps/client-web/src/components/peer/peerList/peerList.ts rename to apps/web/src/components/peer/peerList/peerList.ts diff --git a/apps/client-web/src/components/peer/peerList/peerList.vue b/apps/web/src/components/peer/peerList/peerList.vue similarity index 100% rename from apps/client-web/src/components/peer/peerList/peerList.vue rename to apps/web/src/components/peer/peerList/peerList.vue diff --git a/apps/client-web/src/components/recall/RecallSearch.vue b/apps/web/src/components/recall/RecallSearch.vue similarity index 100% rename from apps/client-web/src/components/recall/RecallSearch.vue rename to apps/web/src/components/recall/RecallSearch.vue diff --git a/apps/client-web/src/components/recall/recall-search.ts b/apps/web/src/components/recall/recall-search.ts similarity index 100% rename from apps/client-web/src/components/recall/recall-search.ts rename to apps/web/src/components/recall/recall-search.ts diff --git a/apps/client-web/src/components/schemaConfigEditor/schemaConfigEditor.md b/apps/web/src/components/schemaConfigEditor/schemaConfigEditor.md similarity index 100% rename from apps/client-web/src/components/schemaConfigEditor/schemaConfigEditor.md rename to apps/web/src/components/schemaConfigEditor/schemaConfigEditor.md diff --git a/apps/client-web/src/components/schemaConfigEditor/schemaConfigEditor.vue b/apps/web/src/components/schemaConfigEditor/schemaConfigEditor.vue similarity index 100% rename from apps/client-web/src/components/schemaConfigEditor/schemaConfigEditor.vue rename to apps/web/src/components/schemaConfigEditor/schemaConfigEditor.vue diff --git a/apps/client-web/src/components/source/createSource/createSource.md b/apps/web/src/components/source/createSource/createSource.md similarity index 100% rename from apps/client-web/src/components/source/createSource/createSource.md rename to apps/web/src/components/source/createSource/createSource.md diff --git a/apps/client-web/src/components/source/createSource/createSource.scss b/apps/web/src/components/source/createSource/createSource.scss similarity index 100% rename from apps/client-web/src/components/source/createSource/createSource.scss rename to apps/web/src/components/source/createSource/createSource.scss diff --git a/apps/client-web/src/components/source/createSource/createSource.ts b/apps/web/src/components/source/createSource/createSource.ts similarity index 100% rename from apps/client-web/src/components/source/createSource/createSource.ts rename to apps/web/src/components/source/createSource/createSource.ts diff --git a/apps/client-web/src/components/source/createSource/createSource.vue b/apps/web/src/components/source/createSource/createSource.vue similarity index 100% rename from apps/client-web/src/components/source/createSource/createSource.vue rename to apps/web/src/components/source/createSource/createSource.vue diff --git a/apps/client-web/src/components/source/sourceCard/sourceCard.md b/apps/web/src/components/source/sourceCard/sourceCard.md similarity index 100% rename from apps/client-web/src/components/source/sourceCard/sourceCard.md rename to apps/web/src/components/source/sourceCard/sourceCard.md diff --git a/apps/client-web/src/components/source/sourceCard/sourceCard.scss b/apps/web/src/components/source/sourceCard/sourceCard.scss similarity index 100% rename from apps/client-web/src/components/source/sourceCard/sourceCard.scss rename to apps/web/src/components/source/sourceCard/sourceCard.scss diff --git a/apps/client-web/src/components/source/sourceCard/sourceCard.ts b/apps/web/src/components/source/sourceCard/sourceCard.ts similarity index 100% rename from apps/client-web/src/components/source/sourceCard/sourceCard.ts rename to apps/web/src/components/source/sourceCard/sourceCard.ts diff --git a/apps/client-web/src/components/source/sourceCard/sourceCard.vue b/apps/web/src/components/source/sourceCard/sourceCard.vue similarity index 100% rename from apps/client-web/src/components/source/sourceCard/sourceCard.vue rename to apps/web/src/components/source/sourceCard/sourceCard.vue diff --git a/apps/client-web/src/components/source/sourceForm/sourceForm.md b/apps/web/src/components/source/sourceForm/sourceForm.md similarity index 100% rename from apps/client-web/src/components/source/sourceForm/sourceForm.md rename to apps/web/src/components/source/sourceForm/sourceForm.md diff --git a/apps/client-web/src/components/source/sourceForm/sourceForm.scss b/apps/web/src/components/source/sourceForm/sourceForm.scss similarity index 100% rename from apps/client-web/src/components/source/sourceForm/sourceForm.scss rename to apps/web/src/components/source/sourceForm/sourceForm.scss diff --git a/apps/client-web/src/components/source/sourceForm/sourceForm.ts b/apps/web/src/components/source/sourceForm/sourceForm.ts similarity index 100% rename from apps/client-web/src/components/source/sourceForm/sourceForm.ts rename to apps/web/src/components/source/sourceForm/sourceForm.ts diff --git a/apps/client-web/src/components/source/sourceForm/sourceForm.vue b/apps/web/src/components/source/sourceForm/sourceForm.vue similarity index 100% rename from apps/client-web/src/components/source/sourceForm/sourceForm.vue rename to apps/web/src/components/source/sourceForm/sourceForm.vue diff --git a/apps/client-web/src/components/toast/ToastHost.scss b/apps/web/src/components/toast/ToastHost.scss similarity index 100% rename from apps/client-web/src/components/toast/ToastHost.scss rename to apps/web/src/components/toast/ToastHost.scss diff --git a/apps/client-web/src/components/toast/ToastHost.vue b/apps/web/src/components/toast/ToastHost.vue similarity index 100% rename from apps/client-web/src/components/toast/ToastHost.vue rename to apps/web/src/components/toast/ToastHost.vue diff --git a/apps/client-web/src/components/toast/toast.ts b/apps/web/src/components/toast/toast.ts similarity index 100% rename from apps/client-web/src/components/toast/toast.ts rename to apps/web/src/components/toast/toast.ts diff --git a/apps/client-web/src/composables/use-async-state.ts b/apps/web/src/composables/use-async-state.ts similarity index 100% rename from apps/client-web/src/composables/use-async-state.ts rename to apps/web/src/composables/use-async-state.ts diff --git a/apps/client-web/src/composables/use-either.ts b/apps/web/src/composables/use-either.ts similarity index 100% rename from apps/client-web/src/composables/use-either.ts rename to apps/web/src/composables/use-either.ts diff --git a/apps/client-web/src/composables/use-page-object-title.ts b/apps/web/src/composables/use-page-object-title.ts similarity index 100% rename from apps/client-web/src/composables/use-page-object-title.ts rename to apps/web/src/composables/use-page-object-title.ts diff --git a/apps/client-web/src/core.ts b/apps/web/src/core.ts similarity index 96% rename from apps/client-web/src/core.ts rename to apps/web/src/core.ts index a730e76c..95fd7c8b 100644 --- a/apps/client-web/src/core.ts +++ b/apps/web/src/core.ts @@ -1,7 +1,7 @@ /** - * Core Package Integration for client-web + * Core Package Integration for web * - * This file initializes @inkcre/core with client-web specific configuration. + * This file initializes @inkcre/core with web specific configuration. * Initialize from App.vue before mounting business views. */ @@ -39,7 +39,7 @@ import { ExtensionManager, RegistryReleaseReader, type WebExtensionModule, -} from '@inkcre/extension-runtime-client-web' +} from '@inkcre/extension-runtime-web' import * as InKCreCore from '@inkcre/core' import * as InKCreUi from '@inkcre/ui-web' import * as Zod from 'zod' @@ -146,10 +146,10 @@ export function setupResolvers(): void { // Configuration // ============================================================================ -type ClientExtensionModule = WebExtensionModule & ExtensionModule -type ClientExtensionManager = ExtensionManager +type AppExtensionModule = WebExtensionModule & ExtensionModule +type AppExtensionManager = ExtensionManager -let extensionHost: ClientExtensionManager | null = null +let extensionHost: AppExtensionManager | null = null let extensionHostStartup: Promise | null = null let extensionHostConnection: MetaConfig | null = null export const extensionHostConnectionReady = Vue.ref(false) @@ -165,7 +165,7 @@ export const webPeerConnectionState = Vue.ref< 'idle' | 'connecting' | 'ready' | 'disabled' | 'failed' >('idle') -export function initializeExtensionHost(): ClientExtensionManager { +export function initializeExtensionHost(): AppExtensionManager { extensionHostStartup = null extensionHostRestoreState.value = 'idle' extensionHostConnection = { ...configStore.metaConfig } @@ -177,7 +177,7 @@ export function initializeExtensionHost(): ClientExtensionManager { registryOrigin: getExtensionRegistryOrigin, hostSdk: { name: '@inkcre/core', version: corePackageJson.version }, }) - extensionHost = new ExtensionManager({ + extensionHost = new ExtensionManager({ peerId: configStore.metaConfig.INKCRE_PEER_ID, releases: extensionRegistry, moduleFederation, @@ -213,7 +213,7 @@ export function startExtensionHost(): Promise { return restore } -export function getExtensionHost(): ClientExtensionManager { +export function getExtensionHost(): AppExtensionManager { if (!extensionHost) { throw new Error('Web Extension Host state port has not been initialized.') } @@ -237,7 +237,7 @@ export function getExtensionRegistryOrigin(): Promise { return extensionRegistryOrigin.resolve() } -/** Project the running native module into the Client-owned setup popup contract. */ +/** Project the running native module into the App-owned setup popup contract. */ export function getExtensionSetupContribution(name: string): ExtensionSetupContribution | null { return getExtensionHost().getModule(name)?.setup ?? null } diff --git a/apps/client-web/src/extension-peer-control.ts b/apps/web/src/extension-peer-control.ts similarity index 98% rename from apps/client-web/src/extension-peer-control.ts rename to apps/web/src/extension-peer-control.ts index 5c9bdf90..02bb0206 100644 --- a/apps/client-web/src/extension-peer-control.ts +++ b/apps/web/src/extension-peer-control.ts @@ -12,7 +12,7 @@ import { readExtensionPeerStatus, type ExtensionManager, type RegistryReleaseReader, -} from '@inkcre/extension-runtime-client-web' +} from '@inkcre/extension-runtime-web' export { EXTENSION_MANAGEMENT_CAPABILITY } export type ExtensionPeerControlMode = 'current-runtime' | 'remote-host' | 'desired-state' diff --git a/apps/client-web/src/locales/index.ts b/apps/web/src/locales/index.ts similarity index 100% rename from apps/client-web/src/locales/index.ts rename to apps/web/src/locales/index.ts diff --git a/apps/client-web/src/locales/messages/en.json b/apps/web/src/locales/messages/en.json similarity index 100% rename from apps/client-web/src/locales/messages/en.json rename to apps/web/src/locales/messages/en.json diff --git a/apps/client-web/src/locales/messages/zh-CN.json b/apps/web/src/locales/messages/zh-CN.json similarity index 100% rename from apps/client-web/src/locales/messages/zh-CN.json rename to apps/web/src/locales/messages/zh-CN.json diff --git a/apps/client-web/src/main.ts b/apps/web/src/main.ts similarity index 100% rename from apps/client-web/src/main.ts rename to apps/web/src/main.ts diff --git a/apps/client-web/src/router.ts b/apps/web/src/router.ts similarity index 100% rename from apps/client-web/src/router.ts rename to apps/web/src/router.ts diff --git a/apps/client-web/src/storages/index.ts b/apps/web/src/storages/index.ts similarity index 100% rename from apps/client-web/src/storages/index.ts rename to apps/web/src/storages/index.ts diff --git a/apps/client-web/src/styles/_mixins.scss b/apps/web/src/styles/_mixins.scss similarity index 100% rename from apps/client-web/src/styles/_mixins.scss rename to apps/web/src/styles/_mixins.scss diff --git a/apps/client-web/src/styles/entity-card.scss b/apps/web/src/styles/entity-card.scss similarity index 100% rename from apps/client-web/src/styles/entity-card.scss rename to apps/web/src/styles/entity-card.scss diff --git a/apps/client-web/src/styles/index.scss b/apps/web/src/styles/index.scss similarity index 100% rename from apps/client-web/src/styles/index.scss rename to apps/web/src/styles/index.scss diff --git a/apps/client-web/src/utils/base.ts b/apps/web/src/utils/base.ts similarity index 100% rename from apps/client-web/src/utils/base.ts rename to apps/web/src/utils/base.ts diff --git a/apps/client-web/src/utils/cron.ts b/apps/web/src/utils/cron.ts similarity index 100% rename from apps/client-web/src/utils/cron.ts rename to apps/web/src/utils/cron.ts diff --git a/apps/client-web/src/utils/format.ts b/apps/web/src/utils/format.ts similarity index 100% rename from apps/client-web/src/utils/format.ts rename to apps/web/src/utils/format.ts diff --git a/apps/client-web/src/utils/vue-props.ts b/apps/web/src/utils/vue-props.ts similarity index 100% rename from apps/client-web/src/utils/vue-props.ts rename to apps/web/src/utils/vue-props.ts diff --git a/apps/client-web/src/views/extensions/extensions.scss b/apps/web/src/views/extensions/extensions.scss similarity index 100% rename from apps/client-web/src/views/extensions/extensions.scss rename to apps/web/src/views/extensions/extensions.scss diff --git a/apps/client-web/src/views/extensions/extensions.vue b/apps/web/src/views/extensions/extensions.vue similarity index 98% rename from apps/client-web/src/views/extensions/extensions.vue rename to apps/web/src/views/extensions/extensions.vue index 48dcffc8..972a2b7a 100644 --- a/apps/client-web/src/views/extensions/extensions.vue +++ b/apps/web/src/views/extensions/extensions.vue @@ -13,7 +13,7 @@ import { type ExtensionParticipation, type InstalledExtension, } from '@inkcre/core' -import type { ReleaseRecord } from '@inkcre/extension-runtime-client-web' +import type { ReleaseRecord } from '@inkcre/extension-runtime-web' import { observeExtensionPeer, selectExtensionPeerVersion } from '@/extension-peer-control' import extensionCard from '@/components/extension/extensionCard/extensionCard.vue' import { @@ -167,6 +167,8 @@ async function loadBrowseUrl(): Promise { browseError.value = null try { const url = new URL(await getExtensionRegistryOrigin()) + url.searchParams.set('app_origin', window.location.origin) + // Existing Registry deployments still read this alias; both identify the same App. url.searchParams.set('client_origin', window.location.origin) browseUrl.value = url.href } catch (error) { diff --git a/apps/client-web/src/views/info-base/graph/graph-layouts.ts b/apps/web/src/views/info-base/graph/graph-layouts.ts similarity index 100% rename from apps/client-web/src/views/info-base/graph/graph-layouts.ts rename to apps/web/src/views/info-base/graph/graph-layouts.ts diff --git a/apps/client-web/src/views/info-base/graph/graph-model.ts b/apps/web/src/views/info-base/graph/graph-model.ts similarity index 100% rename from apps/client-web/src/views/info-base/graph/graph-model.ts rename to apps/web/src/views/info-base/graph/graph-model.ts diff --git a/apps/client-web/src/views/info-base/graph/graph.scss b/apps/web/src/views/info-base/graph/graph.scss similarity index 100% rename from apps/client-web/src/views/info-base/graph/graph.scss rename to apps/web/src/views/info-base/graph/graph.scss diff --git a/apps/client-web/src/views/info-base/graph/graph.ts b/apps/web/src/views/info-base/graph/graph.ts similarity index 100% rename from apps/client-web/src/views/info-base/graph/graph.ts rename to apps/web/src/views/info-base/graph/graph.ts diff --git a/apps/client-web/src/views/info-base/graph/graph.vue b/apps/web/src/views/info-base/graph/graph.vue similarity index 100% rename from apps/client-web/src/views/info-base/graph/graph.vue rename to apps/web/src/views/info-base/graph/graph.vue diff --git a/apps/client-web/src/views/info-base/graph/useGraphScene.ts b/apps/web/src/views/info-base/graph/useGraphScene.ts similarity index 100% rename from apps/client-web/src/views/info-base/graph/useGraphScene.ts rename to apps/web/src/views/info-base/graph/useGraphScene.ts diff --git a/apps/client-web/src/views/info-base/list/list.scss b/apps/web/src/views/info-base/list/list.scss similarity index 100% rename from apps/client-web/src/views/info-base/list/list.scss rename to apps/web/src/views/info-base/list/list.scss diff --git a/apps/client-web/src/views/info-base/list/list.vue b/apps/web/src/views/info-base/list/list.vue similarity index 100% rename from apps/client-web/src/views/info-base/list/list.vue rename to apps/web/src/views/info-base/list/list.vue diff --git a/apps/client-web/src/views/jobs/job/job.scss b/apps/web/src/views/jobs/job/job.scss similarity index 100% rename from apps/client-web/src/views/jobs/job/job.scss rename to apps/web/src/views/jobs/job/job.scss diff --git a/apps/client-web/src/views/jobs/job/job.vue b/apps/web/src/views/jobs/job/job.vue similarity index 100% rename from apps/client-web/src/views/jobs/job/job.vue rename to apps/web/src/views/jobs/job/job.vue diff --git a/apps/client-web/src/views/observability/observability.vue b/apps/web/src/views/observability/observability.vue similarity index 100% rename from apps/client-web/src/views/observability/observability.vue rename to apps/web/src/views/observability/observability.vue diff --git a/apps/client-web/src/views/peers/peers.scss b/apps/web/src/views/peers/peers.scss similarity index 100% rename from apps/client-web/src/views/peers/peers.scss rename to apps/web/src/views/peers/peers.scss diff --git a/apps/client-web/src/views/peers/peers.vue b/apps/web/src/views/peers/peers.vue similarity index 100% rename from apps/client-web/src/views/peers/peers.vue rename to apps/web/src/views/peers/peers.vue diff --git a/apps/client-web/src/views/settings/settings.scss b/apps/web/src/views/settings/settings.scss similarity index 100% rename from apps/client-web/src/views/settings/settings.scss rename to apps/web/src/views/settings/settings.scss diff --git a/apps/client-web/src/views/settings/settings.vue b/apps/web/src/views/settings/settings.vue similarity index 100% rename from apps/client-web/src/views/settings/settings.vue rename to apps/web/src/views/settings/settings.vue diff --git a/apps/client-web/src/views/sources/source/source.md b/apps/web/src/views/sources/source/source.md similarity index 100% rename from apps/client-web/src/views/sources/source/source.md rename to apps/web/src/views/sources/source/source.md diff --git a/apps/client-web/src/views/sources/source/source.scss b/apps/web/src/views/sources/source/source.scss similarity index 100% rename from apps/client-web/src/views/sources/source/source.scss rename to apps/web/src/views/sources/source/source.scss diff --git a/apps/client-web/src/views/sources/source/source.ts b/apps/web/src/views/sources/source/source.ts similarity index 100% rename from apps/client-web/src/views/sources/source/source.ts rename to apps/web/src/views/sources/source/source.ts diff --git a/apps/client-web/src/views/sources/source/source.vue b/apps/web/src/views/sources/source/source.vue similarity index 100% rename from apps/client-web/src/views/sources/source/source.vue rename to apps/web/src/views/sources/source/source.vue diff --git a/apps/client-web/src/views/sources/source/use-cron-manager.ts b/apps/web/src/views/sources/source/use-cron-manager.ts similarity index 100% rename from apps/client-web/src/views/sources/source/use-cron-manager.ts rename to apps/web/src/views/sources/source/use-cron-manager.ts diff --git a/apps/client-web/src/views/sources/source/use-job-creator.ts b/apps/web/src/views/sources/source/use-job-creator.ts similarity index 100% rename from apps/client-web/src/views/sources/source/use-job-creator.ts rename to apps/web/src/views/sources/source/use-job-creator.ts diff --git a/apps/client-web/src/views/sources/source/use-source-detail.ts b/apps/web/src/views/sources/source/use-source-detail.ts similarity index 100% rename from apps/client-web/src/views/sources/source/use-source-detail.ts rename to apps/web/src/views/sources/source/use-source-detail.ts diff --git a/apps/client-web/src/views/sources/sources.scss b/apps/web/src/views/sources/sources.scss similarity index 100% rename from apps/client-web/src/views/sources/sources.scss rename to apps/web/src/views/sources/sources.scss diff --git a/apps/client-web/src/views/sources/sources.vue b/apps/web/src/views/sources/sources.vue similarity index 100% rename from apps/client-web/src/views/sources/sources.vue rename to apps/web/src/views/sources/sources.vue diff --git a/apps/client-web/tests/accessibility.spec.ts b/apps/web/tests/accessibility.spec.ts similarity index 100% rename from apps/client-web/tests/accessibility.spec.ts rename to apps/web/tests/accessibility.spec.ts diff --git a/apps/client-web/tsconfig.app.json b/apps/web/tsconfig.app.json similarity index 100% rename from apps/client-web/tsconfig.app.json rename to apps/web/tsconfig.app.json diff --git a/apps/client-web/tsconfig.json b/apps/web/tsconfig.json similarity index 100% rename from apps/client-web/tsconfig.json rename to apps/web/tsconfig.json diff --git a/apps/client-web/tsconfig.node.json b/apps/web/tsconfig.node.json similarity index 100% rename from apps/client-web/tsconfig.node.json rename to apps/web/tsconfig.node.json diff --git a/apps/client-web/uno.config.ts b/apps/web/uno.config.ts similarity index 100% rename from apps/client-web/uno.config.ts rename to apps/web/uno.config.ts diff --git a/apps/client-web/vite-plugins/joint-dev-extension.ts b/apps/web/vite-plugins/joint-dev-extension.ts similarity index 95% rename from apps/client-web/vite-plugins/joint-dev-extension.ts rename to apps/web/vite-plugins/joint-dev-extension.ts index c92c756e..51fa89cf 100644 --- a/apps/client-web/vite-plugins/joint-dev-extension.ts +++ b/apps/web/vite-plugins/joint-dev-extension.ts @@ -96,7 +96,7 @@ export async function useExtensionDevServer(options: ExtensionDevOptions) { .filter((e) => e.mode === 'dev') .forEach((e) => { // 这里的路径规则根据你的实际需求调整 - proxyConfig[`^/${e.id}/client-web`] = { + proxyConfig[`^/${e.id}/web`] = { target: `http://localhost:${e.port}`, changeOrigin: true, } @@ -133,7 +133,7 @@ export async function useExtensionDevServer(options: ExtensionDevOptions) { } for (const ext of staticExts) { - const outDir = path.join(ext.dir, 'dist/client-web') + const outDir = path.join(ext.dir, 'dist/web') const entryFile = path.join(outDir, 'index.html') // 1. 如果没有构建产物,自动执行构建 @@ -151,15 +151,15 @@ export async function useExtensionDevServer(options: ExtensionDevOptions) { } // 2. 注册静态文件中间件 (使用 sirv) - // 拦截路径: /extension-id/client-web/... - const routePrefix = `/${ext.id}/client-web` + // 拦截路径: /extension-id/web/... + const routePrefix = `/${ext.id}/web` // sirv 实例 (dev 模式下开启 etag 等) const serve = sirv(outDir, { dev: true, single: true }) server.middlewares.use((req, res, next) => { if (req.url?.startsWith(routePrefix)) { - // URL Rewrite: 把 /extension-a/client-web/assets/app.js 变成 /assets/app.js + // URL Rewrite: 把 /extension-a/web/assets/app.js 变成 /assets/app.js const originalUrl = req.url req.url = req.url.slice(routePrefix.length) if (req.url === '') req.url = '/' // 处理根路径 diff --git a/apps/client-web/vite.config.ts b/apps/web/vite.config.ts similarity index 94% rename from apps/client-web/vite.config.ts rename to apps/web/vite.config.ts index 590dcb61..f0992f93 100644 --- a/apps/client-web/vite.config.ts +++ b/apps/web/vite.config.ts @@ -16,7 +16,7 @@ import { import { useExtensionDevServer } from './vite-plugins/joint-dev-extension' const appRoot = fileURLToPath(new URL('.', import.meta.url)) -const clientScssRoots = ['components', 'views', 'extensions'].map((directory) => +const appScssRoots = ['components', 'views', 'extensions'].map((directory) => fileURLToPath(new URL(`./src/${directory}`, import.meta.url)) ) @@ -96,7 +96,7 @@ export default defineConfig(async ({ command, mode }) => { ...(uiSource ? { dedupe: uiSourceDedupe } : {}), }, optimizeDeps: { - exclude: ['@inkcre/extension-runtime-client-web', ...(uiSource ? ['@inkcre/ui-web'] : [])], + exclude: ['@inkcre/extension-runtime-web', ...(uiSource ? ['@inkcre/ui-web'] : [])], }, server: { host: '127.0.0.1', @@ -124,7 +124,7 @@ export default defineConfig(async ({ command, mode }) => { preprocessorOptions: { scss: { additionalData: (source: string, file: string) => { - if (clientScssRoots.some((root) => isPathInside(root, file))) { + if (appScssRoots.some((root) => isPathInside(root, file))) { return `@use "@inkcre/ui-web/styles/mixins" as *;@use "@inkcre/ui-web/styles/functions" as *;@use "@/styles/index.scss" as *;${source}` } if (uiSourceComponents && isPathInside(uiSourceComponents, file)) { diff --git a/apps/client-webext/.gitignore b/apps/webext/.gitignore similarity index 100% rename from apps/client-webext/.gitignore rename to apps/webext/.gitignore diff --git a/apps/client-webext/CHANGELOG.md b/apps/webext/CHANGELOG.md similarity index 100% rename from apps/client-webext/CHANGELOG.md rename to apps/webext/CHANGELOG.md diff --git a/apps/client-webext/CONTRIBUTING.md b/apps/webext/CONTRIBUTING.md similarity index 100% rename from apps/client-webext/CONTRIBUTING.md rename to apps/webext/CONTRIBUTING.md diff --git a/apps/client-webext/LICENSE b/apps/webext/LICENSE similarity index 100% rename from apps/client-webext/LICENSE rename to apps/webext/LICENSE diff --git a/apps/client-webext/README.md b/apps/webext/README.md similarity index 97% rename from apps/client-webext/README.md rename to apps/webext/README.md index 092506c3..604046ea 100644 --- a/apps/client-webext/README.md +++ b/apps/webext/README.md @@ -1,6 +1,6 @@ # InKCre WebExt -浏览器扩展本身是一个 Peer。它连接共享 PostgREST 协议,采集浏览中的材料,保存选区、附注和在线 PDF,预览并导入当前浏览器的书签与历史。核心路径不要求 client-web 页面、登录态或代理,也不需要网页专用数据库 RPC。 +浏览器扩展本身是一个 Peer。它连接共享 PostgREST 协议,采集浏览中的材料,保存选区、附注和在线 PDF,预览并导入当前浏览器的书签与历史。核心路径不要求 web 页面、登录态或代理,也不需要网页专用数据库 RPC。 ## 使用 @@ -34,7 +34,7 @@ Explain、Writing Assist、旧选区浮栏、图编辑侧栏和模型设置已 设置页沿用 WebExt 原有的灰底方角卡片、白底字段、紧凑排版与 teal 主动作。公开 `ui-web` 组件承载控件,宿主通过原有 palette 适配系统 token;Switch 使用 `xs`,显示 ON/OFF,保留可访问名称、状态与键盘操作。宽屏、390px 窄屏和深色截图与尺寸检查属于 UI 回归。自动测试默认后台运行,不连接日常浏览器会话。 -WebExt 固定使用正式发布的 `@inkcre/ui-web` 2.6.0,通过内置密码显隐能力、公开 `INK_I18N_KEY` 和中文词典提供按钮名称,不另写密码组件。2.5.0 和 2.6.0 的普通可编辑输入框都会额外渲染只读值和重复 ID,因此仓库分别维护版本限定的 pnpm patch,各修正一个渲染条件;升级到上游修复版后移除对应补丁。这次仅 WebExt 升级,client-web、twitter 和 ext-dev-utils 继续使用原 2.5.0 及其补丁,不改变组件 API、样式或仍使用 2.3.0 的扩展。 +WebExt 固定使用正式发布的 `@inkcre/ui-web` 2.6.0,通过内置密码显隐能力、公开 `INK_I18N_KEY` 和中文词典提供按钮名称,不另写密码组件。2.5.0 和 2.6.0 的普通可编辑输入框都会额外渲染只读值和重复 ID,因此仓库分别维护版本限定的 pnpm patch,各修正一个渲染条件;升级到上游修复版后移除对应补丁。这次仅 WebExt 升级,web、twitter 和 ext-dev-utils 继续使用原 2.5.0 及其补丁,不改变组件 API、样式或仍使用 2.3.0 的扩展。 根目录 `pnpm test:e2e:webext` 真正加载扩展。指定 `INKCRE_CHROMIUM_BINARY=/Applications/Helium.app/Contents/MacOS/Helium` 使用 Helium 的隔离测试 profile,测试结束清理,不连接日常会话。真实数据旅程还需要可销毁数据库/PostgREST 的 `INKCRE_E2E_WEBEXT_PGREST` 与 `INKCRE_E2E_WEBEXT_JWT_SECRET`。测试副本只对合成 localhost 资料预授予权限;原生权限 UI 另行验证,生产 manifest 保持 optional 权限。 diff --git a/apps/client-webext/chromium-key.json b/apps/webext/chromium-key.json similarity index 100% rename from apps/client-webext/chromium-key.json rename to apps/webext/chromium-key.json diff --git a/apps/client-webext/components/collection/MaterialReader.vue b/apps/webext/components/collection/MaterialReader.vue similarity index 100% rename from apps/client-webext/components/collection/MaterialReader.vue rename to apps/webext/components/collection/MaterialReader.vue diff --git a/apps/client-webext/entrypoints/background.ts b/apps/webext/entrypoints/background.ts similarity index 100% rename from apps/client-webext/entrypoints/background.ts rename to apps/webext/entrypoints/background.ts diff --git a/apps/client-webext/entrypoints/collection.content.ts b/apps/webext/entrypoints/collection.content.ts similarity index 100% rename from apps/client-webext/entrypoints/collection.content.ts rename to apps/webext/entrypoints/collection.content.ts diff --git a/apps/client-webext/entrypoints/options/Options.vue b/apps/webext/entrypoints/options/Options.vue similarity index 100% rename from apps/client-webext/entrypoints/options/Options.vue rename to apps/webext/entrypoints/options/Options.vue diff --git a/apps/client-webext/entrypoints/options/index.html b/apps/webext/entrypoints/options/index.html similarity index 100% rename from apps/client-webext/entrypoints/options/index.html rename to apps/webext/entrypoints/options/index.html diff --git a/apps/client-webext/entrypoints/options/main.ts b/apps/webext/entrypoints/options/main.ts similarity index 100% rename from apps/client-webext/entrypoints/options/main.ts rename to apps/webext/entrypoints/options/main.ts diff --git a/apps/client-webext/entrypoints/parser/index.html b/apps/webext/entrypoints/parser/index.html similarity index 100% rename from apps/client-webext/entrypoints/parser/index.html rename to apps/webext/entrypoints/parser/index.html diff --git a/apps/client-webext/entrypoints/parser/main.ts b/apps/webext/entrypoints/parser/main.ts similarity index 100% rename from apps/client-webext/entrypoints/parser/main.ts rename to apps/webext/entrypoints/parser/main.ts diff --git a/apps/client-webext/entrypoints/popup/Popup.vue b/apps/webext/entrypoints/popup/Popup.vue similarity index 100% rename from apps/client-webext/entrypoints/popup/Popup.vue rename to apps/webext/entrypoints/popup/Popup.vue diff --git a/apps/client-webext/entrypoints/popup/index.html b/apps/webext/entrypoints/popup/index.html similarity index 100% rename from apps/client-webext/entrypoints/popup/index.html rename to apps/webext/entrypoints/popup/index.html diff --git a/apps/client-webext/entrypoints/popup/main.ts b/apps/webext/entrypoints/popup/main.ts similarity index 100% rename from apps/client-webext/entrypoints/popup/main.ts rename to apps/webext/entrypoints/popup/main.ts diff --git a/apps/client-webext/logic/collection/capture.ts b/apps/webext/logic/collection/capture.ts similarity index 100% rename from apps/client-webext/logic/collection/capture.ts rename to apps/webext/logic/collection/capture.ts diff --git a/apps/client-webext/logic/collection/database.ts b/apps/webext/logic/collection/database.ts similarity index 100% rename from apps/client-webext/logic/collection/database.ts rename to apps/webext/logic/collection/database.ts diff --git a/apps/client-webext/logic/collection/fetch.ts b/apps/webext/logic/collection/fetch.ts similarity index 100% rename from apps/client-webext/logic/collection/fetch.ts rename to apps/webext/logic/collection/fetch.ts diff --git a/apps/client-webext/logic/collection/imports.ts b/apps/webext/logic/collection/imports.ts similarity index 100% rename from apps/client-webext/logic/collection/imports.ts rename to apps/webext/logic/collection/imports.ts diff --git a/apps/client-webext/logic/collection/legacy-storage.ts b/apps/webext/logic/collection/legacy-storage.ts similarity index 100% rename from apps/client-webext/logic/collection/legacy-storage.ts rename to apps/webext/logic/collection/legacy-storage.ts diff --git a/apps/client-webext/logic/collection/messages.ts b/apps/webext/logic/collection/messages.ts similarity index 100% rename from apps/client-webext/logic/collection/messages.ts rename to apps/webext/logic/collection/messages.ts diff --git a/apps/client-webext/logic/collection/outbox.ts b/apps/webext/logic/collection/outbox.ts similarity index 100% rename from apps/client-webext/logic/collection/outbox.ts rename to apps/webext/logic/collection/outbox.ts diff --git a/apps/client-webext/logic/collection/parse-html.ts b/apps/webext/logic/collection/parse-html.ts similarity index 100% rename from apps/client-webext/logic/collection/parse-html.ts rename to apps/webext/logic/collection/parse-html.ts diff --git a/apps/client-webext/logic/collection/permissions.ts b/apps/webext/logic/collection/permissions.ts similarity index 100% rename from apps/client-webext/logic/collection/permissions.ts rename to apps/webext/logic/collection/permissions.ts diff --git a/apps/client-webext/logic/collection/runtime.ts b/apps/webext/logic/collection/runtime.ts similarity index 100% rename from apps/client-webext/logic/collection/runtime.ts rename to apps/webext/logic/collection/runtime.ts diff --git a/apps/client-webext/logic/collection/store.ts b/apps/webext/logic/collection/store.ts similarity index 100% rename from apps/client-webext/logic/collection/store.ts rename to apps/webext/logic/collection/store.ts diff --git a/apps/client-webext/logic/collection/transfer.ts b/apps/webext/logic/collection/transfer.ts similarity index 100% rename from apps/client-webext/logic/collection/transfer.ts rename to apps/webext/logic/collection/transfer.ts diff --git a/apps/client-webext/logic/collection/ui.css b/apps/webext/logic/collection/ui.css similarity index 100% rename from apps/client-webext/logic/collection/ui.css rename to apps/webext/logic/collection/ui.css diff --git a/apps/client-webext/logic/collection/ui.ts b/apps/webext/logic/collection/ui.ts similarity index 100% rename from apps/client-webext/logic/collection/ui.ts rename to apps/webext/logic/collection/ui.ts diff --git a/apps/client-webext/package.json b/apps/webext/package.json similarity index 96% rename from apps/client-webext/package.json rename to apps/webext/package.json index a6ae8825..ea6b3581 100644 --- a/apps/client-webext/package.json +++ b/apps/webext/package.json @@ -1,5 +1,5 @@ { - "name": "@inkcre/client-webext", + "name": "@inkcre/webext", "version": "0.2.0", "private": true, "description": "InKCre's Web extension", diff --git a/apps/client-webext/styles/design/_tokens.scss b/apps/webext/styles/design/_tokens.scss similarity index 100% rename from apps/client-webext/styles/design/_tokens.scss rename to apps/webext/styles/design/_tokens.scss diff --git a/apps/client-webext/styles/index.ts b/apps/webext/styles/index.ts similarity index 100% rename from apps/client-webext/styles/index.ts rename to apps/webext/styles/index.ts diff --git a/apps/client-webext/styles/main.scss b/apps/webext/styles/main.scss similarity index 100% rename from apps/client-webext/styles/main.scss rename to apps/webext/styles/main.scss diff --git a/apps/client-webext/tsconfig.json b/apps/webext/tsconfig.json similarity index 100% rename from apps/client-webext/tsconfig.json rename to apps/webext/tsconfig.json diff --git a/apps/client-webext/vue-shim.d.ts b/apps/webext/vue-shim.d.ts similarity index 100% rename from apps/client-webext/vue-shim.d.ts rename to apps/webext/vue-shim.d.ts diff --git a/apps/client-webext/wxt.config.ts b/apps/webext/wxt.config.ts similarity index 100% rename from apps/client-webext/wxt.config.ts rename to apps/webext/wxt.config.ts diff --git a/docs/30-unit-tdd/README.md b/docs/30-unit-tdd/README.md index e09b9bf5..d610f656 100644 --- a/docs/30-unit-tdd/README.md +++ b/docs/30-unit-tdd/README.md @@ -1,4 +1,4 @@ -# Client-Web Unit TDD +# Web App Unit TDD This directory owns stable internal design for the logical units implemented by this repository. The units cross package and application directory boundaries; paths are implementation locations, @@ -6,7 +6,7 @@ not architectural boundaries. ## Owners -- [Client Runtime and Delegation](client-runtime-and-delegation.md) owns the static browser Peer, +- [App Runtime and Delegation](app-runtime-and-delegation.md) owns the static browser Peer, bootstrap configuration, authentication, exact capability delegation, and application navigation hosts. - [Info-Base](info-base.md) owns peer-local graph models, hydration, byte storage, exact Resolvers, diff --git a/docs/30-unit-tdd/client-runtime-and-delegation.md b/docs/30-unit-tdd/app-runtime-and-delegation.md similarity index 98% rename from docs/30-unit-tdd/client-runtime-and-delegation.md rename to docs/30-unit-tdd/app-runtime-and-delegation.md index 9a6d6b86..d9657388 100644 --- a/docs/30-unit-tdd/client-runtime-and-delegation.md +++ b/docs/30-unit-tdd/app-runtime-and-delegation.md @@ -1,8 +1,8 @@ -# Client Runtime and Delegation +# App Runtime and Delegation ## Boundary -Client-Web is an environment-neutral static Vue application and an equal database-protocol Peer. +Web App is an environment-neutral static Vue application and an equal database-protocol Peer. It reads and writes admitted PostgreSQL facts through PostgREST and delegates business capabilities through exact Peer advertisements. These are separate paths: there is no generic Core API client, generic capability endpoint, or delegation job table. @@ -118,7 +118,7 @@ browser signer's 24-hour default lifetime, independently of database admission p regenerates the token when the secret changes and clears it when the secret is removed. PostgREST JSON access, raw byte access, and Peer HTTP delegation reuse this single authentication authority. -Web Peer registration publishes the client-web application version and a best-effort browser/version/system +Web Peer registration publishes the web application version and a best-effort browser/version/system default name only when creating a new identity. Later registration refreshes runtime-owned version and schema without replacing the Human-owned name or Peer config. @@ -187,7 +187,7 @@ success. `PeerOutcomeUnknown` remains visible and does not trigger reload or aut ## Invariants -- InKCre runtime nodes are **Peers** in technical contracts and product UI; “client” remains only for actual application or protocol client roles. +- InKCre runtime nodes are **Peers** in technical contracts and product UI; “client” remains only for actual protocol client roles. - Database facts and capability commands remain distinct paths. - Exact-target routing never degrades to best-effort routing. - Ambiguous dispatch is never retried automatically. diff --git a/docs/30-unit-tdd/info-base.md b/docs/30-unit-tdd/info-base.md index 0e54e21d..3c923190 100644 --- a/docs/30-unit-tdd/info-base.md +++ b/docs/30-unit-tdd/info-base.md @@ -4,7 +4,7 @@ The Info-Base unit spans the core models and mechanics, extension-provided semantics, and browser rendering surfaces. It executes admitted reads/writes, hydration, interpretation, and rendering -locally; being a browser application does not make Client-Web a thin proxy to core-py. +locally; being a browser application does not make Web App a thin proxy to core-py. ```text PostgreSQL/PostgREST --> Block + Relation --> hydrate --> exact Resolver diff --git a/docs/30-unit-tdd/native-extension-runtime.md b/docs/30-unit-tdd/native-extension-runtime.md index 94cacb26..5196bcef 100644 --- a/docs/30-unit-tdd/native-extension-runtime.md +++ b/docs/30-unit-tdd/native-extension-runtime.md @@ -1,5 +1,7 @@ # Native Extension Runtime Unit +Runtime 的新导入名、精确旧包来源与已发布 ABI 兼容边界见 [App 命名与兼容身份](../40-deployment/web-delivery.md#app-命名与兼容身份)。 + ## Boundary The native Extension Runtime spans the browser Web Extension Host, its SDK-owned durable models, and @@ -13,7 +15,7 @@ artifact delivery belong to [First-party Extension Delivery](../40-deployment/native-extension-delivery.md). The browser supports the Module Federation native distribution. Registry v2 resolves an exact -`(name, module_federation, version)` release; other Peers independently select their native distributions. `@inkcre/extension-runtime-client-web`, maintained in +`(name, module_federation, version)` release; other Peers independently select their native distributions. `@inkcre/extension-runtime-web`, maintained in ext-reg, owns the Web Host and Registry consumers. `@inkcre/core` owns the shared models, Peer transport, and browser configuration. There is no generic target matcher or cross-format artifact manifest. @@ -40,7 +42,7 @@ Host 与 Web 扩展通过现有 Module Federation 配置共享 `@inkcre/ui-web` The producer emits the native `mf-manifest.json`, Remote entry, and referenced shared/exposed asset closure with relative asset semantics. The Registry Release records an immutable manifest association and typed Host SDK association. These are runtime inputs to the Host, not a second -manifest invented by the client. +manifest invented by the App. Before fetching executable bytes, the Host reads the exact Release, requires an associated Module Federation distribution, requires `host_sdk === '@inkcre/core'`, and verifies that its strict local @@ -143,7 +145,7 @@ lifecycle work. Initial restore consumes enabled intent without rewriting it. Th local lifecycle work per Extension and rechecks the selected coordinate and enabled intent before and after executable loading, initialization and activation. A superseded candidate is disposed without entering the running projection. Local serialization does not make direct writes by other -admitted clients atomic; fresh persistent observations remain necessary. +admitted Apps atomic; fresh persistent observations remain necessary. An operation can persist intent and still fail during activation or shutdown. The Extension card therefore reads both participation and actual runtime after success or failure and retains the @@ -158,7 +160,7 @@ when all formats supported by that Peer are known to lack published releases. A catalog can explain why the browser has no compatible choice without guessing from application names. An explicit card refresh discards those catalog observations and allows another read. -The Client Web shell opens database views before native Extension restore finishes. A cold deep link can therefore encounter an unregistered Extension resolver. The content popup and graph preview retry only that early lookup failure once after the Host completes restore, while preserving other read failures. Graph pending additions and restore completion both check the retry condition; scene generation, connection and Host ownership reject stale callbacks. A missing resolver after that attempt stays visibly unavailable. Extension cards wait for the same restore before observing current-Peer runtime status; a persisted enabled intent alone does not establish that the module is running. +The Web App shell opens database views before native Extension restore finishes. A cold deep link can therefore encounter an unregistered Extension resolver. The content popup and graph preview retry only that early lookup failure once after the Host completes restore, while preserving other read failures. Graph pending additions and restore completion both check the retry condition; scene generation, connection and Host ownership reject stale callbacks. A missing resolver after that attempt stays visibly unavailable. Extension cards wait for the same restore before observing current-Peer runtime status; a persisted enabled intent alone does not establish that the module is running. A restore attempt isolates module failures. Completing the attempt, including an aggregate failure, allows registered resolvers to serve content and exposes each module’s actual status; an unknown resolver after that attempt remains a visible error. diff --git a/docs/30-unit-tdd/webext-collection.md b/docs/30-unit-tdd/webext-collection.md index 6fada8c5..8c652262 100644 --- a/docs/30-unit-tdd/webext-collection.md +++ b/docs/30-unit-tdd/webext-collection.md @@ -1,6 +1,6 @@ # WebExt 运行时与网页材料 -`apps/client-webext` 是 WXT 浏览器 Peer,`packages/web-collection` 拥有网页材料的领域形状与普通图读写。它们共用 core 数据库、Storage 和 Resolver 能力,不依赖 client-web 私有代码,也不把业务编排放进数据库函数。 +`apps/webext` 是 WXT 浏览器 Peer,`packages/web-collection` 拥有网页材料的领域形状与普通图读写。它们共用 core 数据库、Storage 和 Resolver 能力,不依赖 web 私有代码,也不把业务编排放进数据库函数。 设置中的信息库连接代表本 WebExt 加入共享系统:PostgREST 是共享数据库协议的传输,不是一个接收 Peer。连接保存独立的本地标识、共享地址、凭据及本 Peer ID;本地标识用于维持待办归属,不创造数据库上的接收者身份。主人可直接读改完整配置,本机保存只验证输入,不等待网络。修改现有连接保留 connectionId/peerId;主人明确修正同库地址后,既有待办使用新地址。另一个信息库另建连接,不自动猜测两个地址是否属于同一系统。界面以“信息库 / 本 Peer / 加入信息库”呈现,不称“保存目标”。 @@ -50,6 +50,6 @@ SPA 路由使用 WXT 的 location-change 能力,不另建后台导航转发; 可编辑草稿排除,`contenteditable="false"` 的只读正文保留。JSON-LD 只作为来源声明数据解析;不解析任意应用启动脚本、不展开隐藏评论、不下载字幕或附件。正文直接使用普通 HTML,保留代码空白、表格单元、引用与链接;不为每帖建 Block,也不增加 Organization 操作。 -[Hister](https://github.com/asciimoo/hister) 的来源结构处理与取得后客户端提取提供了参考,核对修订 `2e017c05cf544b812b8fd509ff3fc07c5c7e464e`。本实现独立编写,复用已有 Mozilla Readability 与普通格式库;未复制、改写或运行其 AGPL-3.0-or-later 源码。致谢属于项目说明,不进入用户正文,也不表示上游背书。 +[Hister](https://github.com/asciimoo/hister) 的来源结构处理与取得后浏览器内提取提供了参考,核对修订 `2e017c05cf544b812b8fd509ff3fc07c5c7e464e`。本实现独立编写,复用已有 Mozilla Readability 与普通格式库;未复制、改写或运行其 AGPL-3.0-or-later 源码。致谢属于项目说明,不进入用户正文,也不表示上游背书。 -Chromium 当前最低版本为 116,不能直接使用更高版本的 offscreen 检查接口而只靠类型检查宣布支持。Firefox 构建与运行分别验证。运行代码随扩展打包,不加载 client-web 的远程 Module Federation 模块。 +Chromium 当前最低版本为 116,不能直接使用更高版本的 offscreen 检查接口而只靠类型检查宣布支持。Firefox 构建与运行分别验证。运行代码随扩展打包,不加载 web 的远程 Module Federation 模块。 diff --git a/docs/40-deployment/README.md b/docs/40-deployment/README.md index f6566056..f268b66a 100644 --- a/docs/40-deployment/README.md +++ b/docs/40-deployment/README.md @@ -5,7 +5,7 @@ configuration and automation remain authoritative when implementation details ch - [Development runtime](development-runtime.md): worktree capabilities, database providers, ownership, readiness, reset, and cleanup boundaries. -- [Web delivery](web-delivery.md): the environment-neutral client artifact and Cloudflare Pages +- [Web delivery](web-delivery.md): the environment-neutral Web App artifact and Cloudflare Pages preview and production responsibilities. - [First-party Extension delivery](native-extension-delivery.md): release intent, Version PRs, self-built Registry publication, and local no-publish guardrails. diff --git a/docs/40-deployment/development-runtime.md b/docs/40-deployment/development-runtime.md index 3105306f..74618660 100644 --- a/docs/40-deployment/development-runtime.md +++ b/docs/40-deployment/development-runtime.md @@ -73,7 +73,7 @@ Web、mail、twitter 和 ext-dev-utils 锁定同一正式 UI 版本;生产构 维护 UI 消费代码前,从对应 workspace 的 `node_modules/@inkcre/ui-web/DESIGN.md` 读取同版本的设计决策,再按随包 `skills/ui-web/SKILL.md` 选择组件与组合指南。 各消费者的 `intent.skills` 已显式声明该包,可在相应 workspace 运行 -`pnpm exec intent load @inkcre/ui-web#ui-web`(例如先 `cd apps/client-web`)。 +`pnpm exec intent load @inkcre/ui-web#ui-web`(例如先 `cd apps/web`)。 仓库根目录只安装 Intent CLI,不另建一份 UI 依赖或复制 DESIGN.md;更新依赖时同步核对指南。 ## Browser Runtime Configuration @@ -112,12 +112,12 @@ owns provider parsing and transport safety. Compose project, Docker daemon, contract revision, migration head, source fingerprint, descriptor, and live readiness agree. -For a client-owned `local` or `ssh` runtime, the database provisioner resolves impl-py's admitted +For a App-owned `local` or `ssh` runtime, the database provisioner resolves impl-py's admitted `stable` channel once to an immutable digest. The selected image supplies the raw schema and role artifact; fresh pgvector PostgreSQL is restored before that exact core service reconciles runtime credentials and development data, with PostgREST serving the resulting database. The PostgreSQL health check uses TCP so the temporary socket-only initialization server cannot release the restore -step before the final server is listening. Client-web owns no +step before the final server is listening. Web App owns no migration SQL, role definitions, seed ordering, or startup sleeps. Those semantics remain an impl-py capability boundary. [`runtime/database.compose.yml`](../../runtime/database.compose.yml), [`contracts/core-release.json`](../../contracts/core-release.json), and @@ -125,9 +125,9 @@ capability boundary. [`runtime/database.compose.yml`](../../runtime/database.com owners. `pnpm db:ready` emits machine-readable readiness. `pnpm db:reset` requires explicit confirmation, -accepts only a ready development runtime, and resets only this worktree's client-owned database. -`pnpm dev:stop` removes only this worktree's Portless routes and client-owned database/tunnel -resources. Client-web refuses to reset or stop an external core-py runtime; recovery and cleanup +accepts only a ready development runtime, and resets only this worktree's App-owned database. +`pnpm dev:stop` removes only this worktree's Portless routes and App-owned database/tunnel +resources. Web App refuses to reset or stop an external core-py runtime; recovery and cleanup must go through core-py. Browser E2E always creates and removes its own isolated database runtime. `svc dev status database --repo . --json` 的 probe 输出区分 descriptor、contract 和 transport 阶段。 @@ -141,10 +141,10 @@ owner 已保存的 readiness 一致;当前 Python 工作树是否已收敛, doctor 的 provider 检查不代表服务已就绪;业务验收前仍需检查上述 runtime probe。 The checked database projection records the contract revision intentionally adopted by this -consumer. Update it with `pnpm contract:sync` when client work adopts a newer compatible revision; +consumer. Update it with `pnpm contract:sync` when App work adopts a newer compatible revision; an unrelated pull request does not chase a moving `stable` channel. CI still resolves `stable` once to an immutable image and runs that real core service through the isolated browser/database chain, -which proves the checked client remains compatible with current delivery. A breaking contract +which proves the checked App remains compatible with current delivery. A breaking contract revision requires the coordinated producer-first migration defined by the shared contract. Pull-request evidence does not establish source-branch or migration equality between repositories. diff --git a/docs/40-deployment/native-extension-delivery.md b/docs/40-deployment/native-extension-delivery.md index bf92310f..248021b1 100644 --- a/docs/40-deployment/native-extension-delivery.md +++ b/docs/40-deployment/native-extension-delivery.md @@ -1,6 +1,6 @@ # First-party Extension Delivery -This document owns the operational Release and Registry delivery contract for first-party client-web +This document owns the operational Release and Registry delivery contract for first-party web Extensions. Extension lifecycle and Host internals belong to [Native Extension Runtime](../30-unit-tdd/native-extension-runtime.md). A producer is an `extensions/*/package.json` declaring `inkcre.module_federation`; its package version is the @@ -56,7 +56,7 @@ read-only, with write permissions confined to reconciliation. GitHub may require select **Approve workflows to run** on a token-created Version PR before its checks execute; do not replace this gate with an empty-check merge or a broader credential. -Client checks, Pages production, and Pages preview are separate application lifecycles. They cannot +App checks, Pages production, and Pages preview are separate application lifecycles. They cannot publish first-party Extensions. Local development and local verification must never publish either. Python and Module Federation are independent native releases. Each producer owns @@ -95,7 +95,7 @@ Version outputs are committed; no duplicate pending intent remains for the next This is the one-time delivery boundary for this cutover. Ordinary feature work continues to submit Changesets and use the automated Version PR described above. -Client Web consumes the official Runtime SDK 0.4.1 tarball and Toolkit 0.5 wheel through exact GitHub +The original Peer-participation cutover consumed the official Runtime SDK 0.4.1 tarball and Toolkit 0.5 wheel through exact GitHub Release asset URLs and lock-file integrity. Consumers install prebuilt packages without checking out Registry SDK source or running its SDK preparation. Runtime SDK 0.4.1 also qualifies its own build with the official Core SDK 0.4 prebuilt asset, removing the earlier Git-package bootstrap. @@ -111,6 +111,9 @@ are published or have a saved production candidate; it does not create a second If either a published coordinate or a saved candidate exists, preserve its original bytes instead of rebuilding the same version. Subsequent producer changes continue to use ordinary Changesets. +Current package identity and the exact admitted Runtime 0.4.2 asset are recorded in +[App 命名与兼容身份](web-delivery.md#app-命名与兼容身份); the earlier qualification history above does not select today's dependency. + Required database checks normally resolve the protected Core `stable` artifact. During this cutover, `contracts/core-release.json` can admit a `canonical_candidate` with an existing canonical Core image digest, its protected-main source SHA and exact database contract revision. The consumer @@ -138,7 +141,7 @@ Registry origin, Extension identity, or snapshot ID. The first-party deployment broad `*.inkcre.dev` DNS/TLS catch-all while Registry admits only `registry-docs-{snapshot}.inkcre.dev`; therefore DNS resolution or a successful TLS handshake is not documentation availability. A 421 response is a rejected Host, not a URL pattern for the Web -client to repair or retry under another subdomain. +App to repair or retry under another subdomain. ## Failure and Recovery @@ -180,7 +183,7 @@ This is a publisher regression check, not evidence of production R2 latency. ## Snapshot and Verification Each producer retains the relative artifact base `base: './'`, emits -`dist/client-web/mf-manifest.json`, and declares its Registry association in package metadata. The +`dist/web/mf-manifest.json`, and declares its Registry association in package metadata. The distribution verifier checks the manifest Remote entry and every synchronous or asynchronous shared/exposed JavaScript and CSS reference, then compares every file in the uploaded snapshot, including transitive chunks and generated metadata. The uploaded snapshot is self-contained and @@ -203,5 +206,5 @@ pnpm --filter './extensions/*' build node scripts/verify-native-extension-distribution.mjs inspect-local \ --package extensions//package.json \ --core-package packages/core/package.json \ - --artifact-directory extensions//dist/client-web + --artifact-directory extensions//dist/web ``` diff --git a/docs/40-deployment/web-delivery.md b/docs/40-deployment/web-delivery.md index 0bc898b9..198356e2 100644 --- a/docs/40-deployment/web-delivery.md +++ b/docs/40-deployment/web-delivery.md @@ -2,20 +2,38 @@ ## Artifact Contract -`apps/client-web` 构建静态且与部署环境无关的 Vite 产物。部署实例的连接地址、Peer 身份与 JWT 凭据 +`apps/web` 构建静态且与部署环境无关的 Vite 产物。部署实例的连接地址、Peer 身份与 JWT 凭据 由运行时持有,不能编入生产或预览产物;公共业务链接和产品 Registry 默认地址不选择部署实例。 Pages 只提供静态托管,本仓库没有应用 Worker 或运行时配置接口。 -[`scripts/verify-client-web-release.mjs`](../../scripts/verify-client-web-release.mjs) 和 +[`scripts/verify-web-release.mjs`](../../scripts/verify-web-release.mjs) 和 [`scripts/check-package-contract.mjs`](../../scripts/check-package-contract.mjs) 共同执行此边界。 两个入口都先执行源码配置检查,再检查构建输出,独立 release 验证与 workspace CI 使用相同的部署配置规则。 -The **Client checks** workflow in [`.github/workflows/ci.yml`](../../.github/workflows/ci.yml) +The **App checks** workflow in [`.github/workflows/ci.yml`](../../.github/workflows/ci.yml) validates the candidate but uploads no deployable SPA, Module Federation, or Registry handoff artifact. Preview and production each build at their own authority boundary and cannot publish first-party Extensions. The browser-side authority behind this invariant belongs to -[Client Runtime and Delegation](../30-unit-tdd/client-runtime-and-delegation.md). +[App Runtime and Delegation](../30-unit-tdd/app-runtime-and-delegation.md). + +## App 命名与兼容身份 + +源码与工作区包使用 `apps/web` / `@inkcre/web` 和 `apps/webext` / `@inkcre/webext`。App 是应用交付,Peer 是运行参与者;数据库、HTTP、OAuth 的 client 仍表示具体协议角色。两个应用保持现有版本线与历史 changelog,待消费 Changeset 使用新包名,不重新发布旧版本。 + +部署保持生产 origin `app.inkcre.dev`、Pages 项目、`preview/client-web/pr-` 分支与对应预览别名;这些名字已关联外部资源及浏览器同源存储。本地 Portless 的 `client-web-` / `client-web-ui-` origin 也保留,以读取已有设置。需要改域时必须另行提供同源数据转移,不能把目录改名当作数据迁移。 + +GitHub 的 `client-web E2E` / `client-webext E2E` check 名仍与已有分支保护绑定;工作流显示名改为 App checks。后续若调整 check 名,应先同步远端 required-check 绑定并取得新检查证据。本次不变更保护规则。部署调用使用 `INKCRE_WEB_ORIGIN`,验证脚本仍接受旧 `INKCRE_CLIENT_WEB_ORIGIN` 入站别名;旧部署调用方迁移后才移除别名。 + +浏览器配置键 `inkcre_app_config`、Peer ID 和旧 `client_id` / `INKCRE_CLIENT_ID` 迁移输入不变。WebExt 的 Chromium 公钥、Gecko ID、IndexedDB `inkcre-webext-collection`、导出格式、`webext-v` 标签和下载文件名也不变;继续按原安装目录覆盖更新,不卸载现有实例。新建的开发数据库使用 `inkcre-web-` 命名,已有 runtime state 中的项目名、凭据和数据继续沿用。开发凭据派生继续使用旧 `inkcre-client-web` 命名空间,避免重建一次性数据库后浏览器中已保存的凭据失效;修改它属于凭据轮换,需要单独迁移。 + +应用以 `@inkcre/extension-runtime-web` 导入 Runtime SDK;当前依赖仍固定到 ext-reg 已发布的 `runtime-client-web-v0.4.2` 精确 tarball。安装别名不表示新名称的包已发布,正式新包发布后再更新 artifact URL、完整性与版本准入。现有 `@inkcre/core` Host ABI、`module_federation` distribution ID 和已发布 Release/manifest URL 不改写,新源码构建输出采用 `dist/web`。 + +该旧 tarball 的 Zod 4.1.12 受 [GHSA-mrhx-c7xc-m3w5](https://github.com/advisories/GHSA-mrhx-c7xc-m3w5) 影响;工作区只对 Runtime 0.4.2 的这条依赖覆写为已有的 4.6.7,保留 tarball 原始字节和身份。采用直接依赖已修复版本的新 Runtime 后移除该覆写,不关闭依赖安全检查。 + +访问 Registry 时发送 `app_origin`,同时携带同值的旧 `client_origin`,兼容已部署 Registry 的安装返回地址。新 Registry 接受同值别名并拒绝冲突输入;待旧版本退出准入后才能移除旧参数。 + +OTEL 新记录的 `service.name` 为 `inkcre.web`。旧 `inkcre.client-web` 历史保持原值,跨切换窗口的外部诊断需包含两者;业务 Peer/Job 身份没有变化。 `public/_headers` gives Vite's content-hashed `/assets/` files a one-year immutable browser cache. HTML keeps Pages' revalidation policy so a new visit discovers the current asset names. @@ -53,15 +71,15 @@ Restore automatic delivery only after the cutover has been verified. ### Breaking database protocol upgrades Pages delivery changes the HTML and assets served to new visits; it does not replace JavaScript -already running in an open tab. Client Web 0.1.2 and Core SDK 0.3 use the global Extension +already running in an open tab. Web App 0.1.2 and Core SDK 0.3 use the global Extension `version`, `enabled` and `config_schema` columns. The Peer-participation migration removes those columns, so an old tab can fail Extension reads and writes even while unrelated information remains -readable. Reloading before the matching App is deployed still loads an incompatible client. +readable. Reloading before the matching App is deployed still loads an incompatible App. The deployment owner coordinates a maintenance window across the affected Core/PostgREST deployment -and Client Web. Pause browser writes and close old connected tabs before the database cutover. Keep +and Web App. Pause browser writes and close old connected tabs before the database cutover. Keep the browser's connection settings and Peer ID. Resume use only after the deployment's -`extension-peer-participation-v2` database and management endpoint are ready and Client Web 0.1.3 +`extension-peer-participation-v2` database and management endpoint are ready and Web App 0.1.3 has been deployed, then fully reload each connected tab. A startup error's Retry button performs that full reload; it cannot repair an incompatible database or update a tab while it remains open. The Core deployment documentation owns backup, migration and service recovery commands. @@ -153,7 +171,7 @@ explicit positive PR number and applies the same closed internal-PR identity che 浏览器出口必须是部署 owner 已验证的公开受限写入入口,或受控按请求转发入口; 不得把 Grafana/其他 SaaS 的服务端 ingest token 放入浏览器配置、URL、静态环境变量 -或前端代码。URL 校验拒绝 userinfo、query 和 fragment,不接受任意自定义认证 headers。 +或 Web 源码。URL 校验拒绝 userinfo、query 和 fragment,不接受任意自定义认证 headers。 如使用 core-py 的受控中转,在浏览器连接设置显式填写 `telemetry_peer_relay_url`,例如 `https://peer.example/telemetry`。SDK 追加 `/v1/{traces,logs,metrics}`,每批请求用现有 签名 authority 产生此连接的短期 Peer JWT;私密 SaaS headers 仍只在服务器。 @@ -162,7 +180,7 @@ core 中转只接受此格式,Trace/Span ID 与 Links 由标准 protobuf 消 JSON 字节转换。该地址需属于可信部署 Peer;填写地址不会启用遥测,失败也不会切回公开出口。 留空时沿用共享公开出口且不附加 Peer JWT。 负责入口的部署 owner 须验证 CORS、写入权限、部署归属、配额和失效行为。浏览器自报的 -部署 ID 只是关联属性,不能作为授权依据。客户端不提供常驻 Collector,也不代表某个 +部署 ID 只是关联属性,不能作为授权依据。Web App 不提供常驻 Collector,也不代表某个 SaaS 的真实账号、免费额度或入口已经验收。 Peer HTTP 入口需要在原有认证和 CORS 配置下允许 `traceparent`、`tracestate`;CORS diff --git a/docs/40-deployment/webext-delivery.md b/docs/40-deployment/webext-delivery.md index 53c559f2..b68e6b50 100644 --- a/docs/40-deployment/webext-delivery.md +++ b/docs/40-deployment/webext-delivery.md @@ -1,6 +1,6 @@ # WebExt 版本与分发 -WebExt 是独立交付的浏览器 Peer,不属于 Module Federation Extension。Chromium 和 Firefox 共享 `apps/client-webext/package.json` 的版本,构建不同浏览器产物;不随 client-web、Core 或 MF Registry 的版本发布。 +WebExt 是独立交付的浏览器 Peer,不属于 Module Federation Extension。Chromium 和 Firefox 共享 `apps/webext/package.json` 的版本,构建不同浏览器产物;不随 web、Core 或 MF Registry 的版本发布。 ## 安装和手动更新 @@ -14,7 +14,7 @@ Firefox ZIP **未签名,仅供 `about:debugging` 临时加载**,不能作为 固定公钥写入 manifest 后,解压目录变化不再改变 Chromium 扩展 ID。早期没有公钥的安装按路径生成另一 ID,浏览器不会把它的存储自动交给新身份。先完成一次数据转移,此后的固定身份版本按普通更新处理。 -1. 从相同源码执行 `pnpm --filter @inkcre/client-webext zip:migration`。这是不带固定公钥的过渡构建,只用于早期安装的数据导出,不是正式发布包。保留旧目录副本后,将过渡构建放到原安装的**完全相同路径**,重新加载;确认信息库与待办仍在。不要把带固定公钥的正常构建直接覆盖到这个路径。 +1. 从相同源码执行 `pnpm --filter @inkcre/webext zip:migration`。这是不带固定公钥的过渡构建,只用于早期安装的数据导出,不是正式发布包。保留旧目录副本后,将过渡构建放到原安装的**完全相同路径**,重新加载;确认信息库与待办仍在。不要把带固定公钥的正常构建直接覆盖到这个路径。 2. 在设置页暂停自动采集和运行中的导入,等待正在发送的工作结束,关闭其他扩展页面。展开“本机数据迁移”,导出文件;随后停用旧实例,不要卸载。 3. 在另一个目录加载正常固定身份构建,在空实例中迁入文件。已有连接、待办、导入或封存记录的实例会拒绝迁入,不合并或覆盖。 4. 核对信息库、待办和导入进度。点击“检查连接”重新授权数据库地址,重新启用需要的网站权限;书签、历史权限也需重新授予。重新加载新扩展后按需恢复采集与导入。不要同时启用承载相同 Peer 身份的旧、新实例。 @@ -25,7 +25,7 @@ Firefox ZIP **未签名,仅供 `about:debugging` 临时加载**,不能作为 ## 准备版本与产物 -用户可见变更携带针对 `@inkcre/client-webext` 的 Changeset。复用工作区 Version PR 消费这些文件,更新版本和 changelog;不要手改生成的 manifest。重写首次交付使用 minor 变更意图,由 Version PR 将当前 `0.1.4` 准备为 `0.2.0`,不是仅合并功能 PR 就发布当前版本。 +用户可见变更携带针对 `@inkcre/webext` 的 Changeset。复用工作区 Version PR 消费这些文件,更新版本和 changelog;不要手改生成的 manifest。重写首次交付使用 minor 变更意图,由 Version PR 将当前 `0.1.4` 准备为 `0.2.0`,不是仅合并功能 PR 就发布当前版本。 版本使用三段纯数字 SemVer,每段不超过 65535。不要以 `-beta` 后缀区分浏览器包:WXT 会把后缀从 manifest 版本中去掉,两个候选可能因此成为同一个浏览器版本。测试候选用来源提交区分,不冒充正式新版本。 diff --git a/docs/index.md b/docs/index.md index 81b0dcf1..7146a9a2 100644 --- a/docs/index.md +++ b/docs/index.md @@ -3,7 +3,7 @@ - [Repository architecture](../ARCHITECTURE.md) - [Filesystem map](../FILESYSTEM.md) - [Unit TDD](30-unit-tdd/README.md) - - [Client Runtime and Delegation](30-unit-tdd/client-runtime-and-delegation.md) + - [App Runtime and Delegation](30-unit-tdd/app-runtime-and-delegation.md) - [Info-Base](30-unit-tdd/info-base.md) - [Native Extension Runtime](30-unit-tdd/native-extension-runtime.md) - [Deployment and Runtime](40-deployment/README.md) diff --git a/extensions/.agents/assets/vite.config.ts.md b/extensions/.agents/assets/vite.config.ts.md index 93b719a2..a7b81b1b 100644 --- a/extensions/.agents/assets/vite.config.ts.md +++ b/extensions/.agents/assets/vite.config.ts.md @@ -26,10 +26,10 @@ export default defineConfig({ shared: mfShared, }), ], - base: "/{extension_id}/client-web/", + base: "/{extension_id}/web/", build: { target: "esnext", - outDir: "dist/client-web", + outDir: "dist/web", sourcemap: true }, css: { diff --git a/extensions/AGENTS.md b/extensions/AGENTS.md index d03bdbd6..4f26c11f 100644 --- a/extensions/AGENTS.md +++ b/extensions/AGENTS.md @@ -12,7 +12,7 @@ Host/producer runtime contracts belong to `package.json#inkcre.name`, version, nickname, and `module_federation` association are Registry identity and compatibility inputs, not playground metadata. - Keep production remotes relocatable: `vite.config.ts` must retain `base: './'`, emit the native - `mf-manifest.json`, and write `dist/client-web`. + `mf-manifest.json`, and write `dist/web`. - Export host-consumed capabilities from `src/index.ts`; keep `src/main.ts` limited to the local playground. Do not make the Host depend on playground bootstrap behavior. - Changes to a native producer must preserve asset-closure validation. Record its native release intent diff --git a/extensions/caldav/package.json b/extensions/caldav/package.json index 44b42f02..242856ab 100644 --- a/extensions/caldav/package.json +++ b/extensions/caldav/package.json @@ -12,7 +12,7 @@ }, "dependencies": { "@inkcre/core": "workspace:*", - "@inkcre/extension-runtime-client-web": "https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz", + "@inkcre/extension-runtime-web": "https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz", "ical.js": "2.2.1" }, "devDependencies": { diff --git a/extensions/caldav/src/setup.ts b/extensions/caldav/src/setup.ts index a463e286..22f6ec98 100644 --- a/extensions/caldav/src/setup.ts +++ b/extensions/caldav/src/setup.ts @@ -14,7 +14,7 @@ import { readExtensionPeerStatus, RegistryReleaseReader, sortPublishedReleases, -} from '@inkcre/extension-runtime-client-web' +} from '@inkcre/extension-runtime-web' import { configuredRegistry, diff --git a/extensions/caldav/vite.config.ts b/extensions/caldav/vite.config.ts index 7c9375d6..6f6e1d24 100644 --- a/extensions/caldav/vite.config.ts +++ b/extensions/caldav/vite.config.ts @@ -20,5 +20,5 @@ export default defineConfig({ }), ], base: './', - build: { target: 'es2022', outDir: 'dist/client-web', sourcemap: true }, + build: { target: 'es2022', outDir: 'dist/web', sourcemap: true }, }) diff --git a/extensions/capture/README.md b/extensions/capture/README.md index 414ec300..34476c6d 100644 --- a/extensions/capture/README.md +++ b/extensions/capture/README.md @@ -6,6 +6,6 @@ Host SDK 要求 `@inkcre/core >=0.4.0 <0.5.0`。通过 Registry 选择并启用 共享图与提交语义由 [Capture Extension 合同](https://github.com/InKCre/docs/blob/main/20-product-tdd/capture-contract.md) 维护;字段验证在 `src/schema.ts`,顺序和引用校验在 `src/resolver.ts`。缺失材料显示错误,不触发采集端重新抓取。来源 URL 只允许 HTTP(S) 作为可点击链接。 -运行 `pnpm --filter @inkcre/ext-capture type-check` 与仓库 `pnpm build`。`dist/client-web` 是可重定位的发布制品,`src/main.ts` 只用于开发说明页。真实验收应安装生产构建,停止原采集者后冷启动打开共享根 Block,检查原文、图片字节、顺序和附注。 +运行 `pnpm --filter @inkcre/ext-capture type-check` 与仓库 `pnpm build`。`dist/web` 是可重定位的发布制品,`src/main.ts` 只用于开发说明页。真实验收应安装生产构建,停止原采集者后冷启动打开共享根 Block,检查原文、图片字节、顺序和附注。 Mac 自行通过共享数据库原子写入,不依赖 Python Peer。此 Web 分发只负责读取与呈现,未启用它不影响采集写入。 diff --git a/extensions/capture/vite.config.ts b/extensions/capture/vite.config.ts index c566915d..0e71e99a 100644 --- a/extensions/capture/vite.config.ts +++ b/extensions/capture/vite.config.ts @@ -31,5 +31,5 @@ export default defineConfig({ }), ], base: './', - build: { target: 'es2022', outDir: 'dist/client-web', sourcemap: true }, + build: { target: 'es2022', outDir: 'dist/web', sourcemap: true }, }) diff --git a/extensions/github/README.md b/extensions/github/README.md index db6ca82f..d70c42fc 100644 --- a/extensions/github/README.md +++ b/extensions/github/README.md @@ -10,4 +10,4 @@ 模块导入不注册 resolver;initialize 注册三个精确 class,dispose 仅注销自身 class。Host 在部分 initialize 失败时同样调用 dispose,因此停用后新的 resolver 查找失败,重新启用同一 class 允许复用现有缓存;更换 class 后下一次缓存读取释放旧实例并创建新实例。这不保证物理清空缓存。详情打开与刷新重新读取 Block 并创建 Resolver;关系显式刷新读取当前 edges,不依赖 focal Block 时间戳变化。共享 Block、Relation、Extension config/state 不由这些生命周期操作修改。 -本地开发入口是 `src/main.ts`,Host 加载入口是 `src/index.ts`。构建遵循同仓原生 MF 规则,输出可重定位 `dist/client-web` 和 `mf-manifest.json`。初次版本由 minor Changeset 与正常 Version PR 从未发布占位 `0.0.0` 生成 `0.1.0`;占位源码有待消费 Changeset,不能作为生产候选发布。正式发布遵循 [独立 MF 交付流程](../../docs/40-deployment/native-extension-delivery.md)。 +本地开发入口是 `src/main.ts`,Host 加载入口是 `src/index.ts`。构建遵循同仓原生 MF 规则,输出可重定位 `dist/web` 和 `mf-manifest.json`。初次版本由 minor Changeset 与正常 Version PR 从未发布占位 `0.0.0` 生成 `0.1.0`;占位源码有待消费 Changeset,不能作为生产候选发布。正式发布遵循 [独立 MF 交付流程](../../docs/40-deployment/native-extension-delivery.md)。 diff --git a/extensions/github/tsconfig.json b/extensions/github/tsconfig.json index 1a8623e9..0f5e8782 100644 --- a/extensions/github/tsconfig.json +++ b/extensions/github/tsconfig.json @@ -8,7 +8,7 @@ "jsxImportSource": "vue", "skipLibCheck": true, "paths": { - "@/*": ["../../apps/client-web/src/*"], + "@/*": ["../../apps/web/src/*"], "@inkcre/core": ["../../packages/core/src/index.ts"], "@inkcre/core/*": ["../../packages/core/src/*"] } diff --git a/extensions/github/vite.config.ts b/extensions/github/vite.config.ts index a3183a2a..dcd58feb 100644 --- a/extensions/github/vite.config.ts +++ b/extensions/github/vite.config.ts @@ -20,7 +20,7 @@ export const githubArtifactBase = './' export const githubBuildTarget = 'es2022' export const githubBuildOptions = { target: githubBuildTarget, - outDir: 'dist/client-web', + outDir: 'dist/web', sourcemap: true, } export const githubFederationOptions = { diff --git a/extensions/local-files/vite.config.ts b/extensions/local-files/vite.config.ts index 68fd2a7e..d812fac0 100644 --- a/extensions/local-files/vite.config.ts +++ b/extensions/local-files/vite.config.ts @@ -36,5 +36,5 @@ export default defineConfig({ }), ], base: './', - build: { target: 'es2022', outDir: 'dist/client-web', sourcemap: true }, + build: { target: 'es2022', outDir: 'dist/web', sourcemap: true }, }) diff --git a/extensions/mail/tsconfig.json b/extensions/mail/tsconfig.json index b4f1efff..2093f785 100644 --- a/extensions/mail/tsconfig.json +++ b/extensions/mail/tsconfig.json @@ -7,7 +7,7 @@ "jsxImportSource": "vue", "skipLibCheck": true, "paths": { - "@/*": ["../../apps/client-web/src/*"], + "@/*": ["../../apps/web/src/*"], "@inkcre/core": ["../../packages/core/src/index.ts"], "@inkcre/core/*": ["../../packages/core/src/*"] } diff --git a/extensions/mail/vite.config.ts b/extensions/mail/vite.config.ts index da0c59ff..5cd940fc 100644 --- a/extensions/mail/vite.config.ts +++ b/extensions/mail/vite.config.ts @@ -21,7 +21,7 @@ export const mailArtifactBase = './' export const mailBuildTarget = 'es2022' export const mailBuildOptions = { target: mailBuildTarget, - outDir: 'dist/client-web', + outDir: 'dist/web', sourcemap: true, } export const mailFederationOptions = { diff --git a/extensions/memos/package.json b/extensions/memos/package.json index 3306c346..93f946d2 100644 --- a/extensions/memos/package.json +++ b/extensions/memos/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@inkcre/core": "workspace:*", - "@inkcre/extension-runtime-client-web": "https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz" + "@inkcre/extension-runtime-web": "https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz" }, "devDependencies": { "@inkcre/ext-dev-utils": "workspace:*", diff --git a/extensions/memos/src/MemosSetup.vue b/extensions/memos/src/MemosSetup.vue index 67bacf4e..99c1ad20 100644 --- a/extensions/memos/src/MemosSetup.vue +++ b/extensions/memos/src/MemosSetup.vue @@ -10,7 +10,7 @@ import { type InstalledExtension, type Peer, } from '@inkcre/core' -import { manageExtensionOnPeer } from '@inkcre/extension-runtime-client-web' +import { manageExtensionOnPeer } from '@inkcre/extension-runtime-web' import { extensionName, ensureMemosParticipation, diff --git a/extensions/memos/src/setup.ts b/extensions/memos/src/setup.ts index 3b07d5fa..68c8b8be 100644 --- a/extensions/memos/src/setup.ts +++ b/extensions/memos/src/setup.ts @@ -16,7 +16,7 @@ import { manageExtensionOnPeer, readExtensionPeerStatus, listAdvertisedExtensionManagementPeers, -} from '@inkcre/extension-runtime-client-web' +} from '@inkcre/extension-runtime-web' export const extensionName = 'inkcre/memos' export const tokenPattern = /^memos_pat_[0-9A-Za-z]{32}$/ diff --git a/extensions/memos/vite.config.ts b/extensions/memos/vite.config.ts index bff7c744..c0b3e026 100644 --- a/extensions/memos/vite.config.ts +++ b/extensions/memos/vite.config.ts @@ -20,5 +20,5 @@ export default defineConfig({ }), ], base: './', - build: { target: 'es2022', outDir: 'dist/client-web', sourcemap: true }, + build: { target: 'es2022', outDir: 'dist/web', sourcemap: true }, }) diff --git a/extensions/mf-shared.ts b/extensions/mf-shared.ts index 4db94f1b..709c7e61 100644 --- a/extensions/mf-shared.ts +++ b/extensions/mf-shared.ts @@ -1,6 +1,6 @@ // Shared dependencies for Module Federation remote (extensions). -import packageJson from '../apps/client-web/package.json' +import packageJson from '../apps/web/package.json' export default function mfShared(hostSdkVersion: string, uiVersion: string) { return { '@inkcre/ui-web': { diff --git a/extensions/twitter/package.json b/extensions/twitter/package.json index 7bbb44de..443832b3 100644 --- a/extensions/twitter/package.json +++ b/extensions/twitter/package.json @@ -11,7 +11,7 @@ }, "dependencies": { "@inkcre/core": "workspace:*", - "@inkcre/extension-runtime-client-web": "https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz" + "@inkcre/extension-runtime-web": "https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz" }, "devDependencies": { "@inkcre/ext-dev-utils": "workspace:*", diff --git a/extensions/twitter/src/setup-api.ts b/extensions/twitter/src/setup-api.ts index 1f049d18..b1f9a20b 100644 --- a/extensions/twitter/src/setup-api.ts +++ b/extensions/twitter/src/setup-api.ts @@ -4,7 +4,7 @@ import { sortPublishedReleases, manageExtensionOnPeer, readExtensionPeerStatus, -} from '@inkcre/extension-runtime-client-web' +} from '@inkcre/extension-runtime-web' import { ExtensionParticipationModel, ExtensionRegistryOriginResolver, diff --git a/extensions/twitter/tsconfig.json b/extensions/twitter/tsconfig.json index 02e2856f..7e3ed4e2 100644 --- a/extensions/twitter/tsconfig.json +++ b/extensions/twitter/tsconfig.json @@ -8,7 +8,7 @@ "jsxImportSource": "vue", "skipLibCheck": true, "paths": { - "@/*": ["../../apps/client-web/src/*"], + "@/*": ["../../apps/web/src/*"], "@inkcre/core": ["../../packages/core/src/index.ts"], "@inkcre/core/*": ["../../packages/core/src/*"] } diff --git a/extensions/twitter/vite.config.ts b/extensions/twitter/vite.config.ts index acdca3b7..f90d6e2d 100644 --- a/extensions/twitter/vite.config.ts +++ b/extensions/twitter/vite.config.ts @@ -20,7 +20,7 @@ export const twitterArtifactBase = './' export const twitterBuildTarget = 'es2022' export const twitterBuildOptions = { target: twitterBuildTarget, - outDir: 'dist/client-web', + outDir: 'dist/web', sourcemap: true, } export const twitterFederationOptions = { diff --git a/package.json b/package.json index efd405d4..99a2968f 100644 --- a/package.json +++ b/package.json @@ -28,7 +28,7 @@ "type-check:ui": "node scripts/type-check-ui.mjs", "check:runtime": "node --test scripts/tests/browser-runtime-contract.test.mjs scripts/tests/database-probe.test.mjs scripts/tests/ui-source.test.mjs && node scripts/check-local-runtime-contract.mjs", "check:database": "node scripts/check-database-contract.mjs", - "check:release:web": "node scripts/verify-client-web-release.mjs", + "check:release:web": "node scripts/verify-web-release.mjs", "check:locale": "node scripts/check-locale-keys.mjs", "check:workspace": "node scripts/check-workspace-contract.mjs", "check:package": "node scripts/check-package-contract.mjs", diff --git a/packages/core/AGENTS.md b/packages/core/AGENTS.md index 4b76c7b4..dbf3e78b 100644 --- a/packages/core/AGENTS.md +++ b/packages/core/AGENTS.md @@ -5,7 +5,7 @@ Shared models, Peer protocols, storage/resolver mechanics, and native Extension ## Owners - Package role and cross-package flows: `../../ARCHITECTURE.md`. -- Client runtime and delegation: `../../docs/30-unit-tdd/client-runtime-and-delegation.md`. +- App runtime and delegation: `../../docs/30-unit-tdd/app-runtime-and-delegation.md`. - Info-Base hydration, storage, Resolver outcomes, and browser handles: `../../docs/30-unit-tdd/info-base.md`. - Native Extension Host and lifecycle: `../../docs/30-unit-tdd/native-extension-runtime.md`. - Shared cross-unit contracts: `../../docs/_shared/20-product-tdd/`. diff --git a/packages/core/src/auth/defaults.ts b/packages/core/src/auth/defaults.ts index 6f349810..8ad8a100 100644 --- a/packages/core/src/auth/defaults.ts +++ b/packages/core/src/auth/defaults.ts @@ -1,2 +1,2 @@ -// Signing defaults are client policy; admission limits belong to the connected database. +// Signing defaults are Peer policy; admission limits belong to the connected database. export const DEFAULT_PEER_JWT_LIFETIME_SECONDS = 86_400 diff --git a/packages/core/src/config/schema.ts b/packages/core/src/config/schema.ts index a0ed2f37..60ec62e4 100644 --- a/packages/core/src/config/schema.ts +++ b/packages/core/src/config/schema.ts @@ -22,7 +22,7 @@ export const LLMProviderConfigSchema = z.object({ export type LLMProviderConfig = z.infer /** - * AI configuration schema (from client-webext) + * AI configuration schema (from webext) */ export const AIConfigSchema = z.object({ llmProviders: z.array(LLMProviderConfigSchema).default([]).meta({ title: 'AI providers' }), diff --git a/packages/core/src/obsrv/telemetry.ts b/packages/core/src/obsrv/telemetry.ts index f8411c3b..cb5f29c8 100644 --- a/packages/core/src/obsrv/telemetry.ts +++ b/packages/core/src/obsrv/telemetry.ts @@ -140,7 +140,7 @@ export async function configureTelemetry( : undefined const { resourceFromAttributes } = await import('@opentelemetry/resources') const resource = resourceFromAttributes({ - 'service.name': 'inkcre.client-web', + 'service.name': 'inkcre.web', 'service.version': version, 'service.instance.id': crypto.randomUUID(), 'inkcre.deployment.id': config.deployment_id, diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 7498dde1..09ad34fb 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -14,6 +14,7 @@ catalogs: version: 3.3.8 overrides: + '@inkcre/extension-runtime-client-web@0.4.2>zod': 4.6.7 '@inkcre/ui-web@2.3.0': https://github.com/InKCre/ui/releases/download/%40inkcre%2Fui-web%402.3.0/inkcre-ui-web-2.3.0.tgz '@inkcre/ui-web@2.5.0': https://github.com/InKCre/ui/releases/download/%40inkcre%2Fui-web%402.5.0/inkcre-ui-web-2.5.0.tgz '@inkcre/ui-web@2.7.0': https://github.com/InKCre/ui/releases/download/%40inkcre%2Fui-web%402.7.0/inkcre-ui-web-2.7.0.tgz @@ -94,7 +95,7 @@ importers: specifier: 4.114.0 version: 4.114.0 - apps/client-web: + apps/web: dependencies: '@dagrejs/dagre': specifier: ^3.1.2 @@ -102,9 +103,9 @@ importers: '@inkcre/core': specifier: workspace:* version: link:../../packages/core - '@inkcre/extension-runtime-client-web': + '@inkcre/extension-runtime-web': specifier: https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz - version: https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz(@inkcre/core@packages+core)(@module-federation/runtime@0.21.6) + version: '@inkcre/extension-runtime-client-web@https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz(@inkcre/core@packages+core)(@module-federation/runtime@0.21.6)' '@inkcre/ui-web': specifier: https://github.com/InKCre/ui/releases/download/%40inkcre%2Fui-web%402.7.0/inkcre-ui-web-2.7.0.tgz version: https://github.com/InKCre/ui/releases/download/%40inkcre%2Fui-web%402.7.0/inkcre-ui-web-2.7.0.tgz(unocss@66.7.5(vite@7.3.6(@types/node@22.17.2)(jiti@2.7.0)(lightningcss@1.33.0)(sass-embedded@1.90.0)(sass@1.101.6)(yaml@2.9.0)))(vue@3.5.44(typescript-native-bridge@6.0.3-bridge.19.tsgo.7.0.2)) @@ -212,7 +213,7 @@ importers: specifier: 'catalog:' version: 3.3.8(typescript-native-bridge@6.0.3-bridge.19.tsgo.7.0.2) - apps/client-webext: + apps/webext: dependencies: '@inkcre/core': specifier: workspace:* @@ -257,9 +258,9 @@ importers: '@inkcre/core': specifier: workspace:* version: link:../../packages/core - '@inkcre/extension-runtime-client-web': + '@inkcre/extension-runtime-web': specifier: https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz - version: https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz(@inkcre/core@packages+core)(@module-federation/runtime@0.22.1) + version: '@inkcre/extension-runtime-client-web@https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz(@inkcre/core@packages+core)(@module-federation/runtime@0.22.1)' '@vueuse/core': specifier: ^14.0.0 version: 14.4.0(vue@3.5.44(typescript-native-bridge@6.0.3-bridge.19.tsgo.7.0.2)) @@ -505,9 +506,9 @@ importers: '@inkcre/core': specifier: workspace:* version: link:../../packages/core - '@inkcre/extension-runtime-client-web': + '@inkcre/extension-runtime-web': specifier: https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz - version: https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz(@inkcre/core@packages+core)(@module-federation/runtime@0.22.1) + version: '@inkcre/extension-runtime-client-web@https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz(@inkcre/core@packages+core)(@module-federation/runtime@0.22.1)' '@vueuse/core': specifier: ^14.0.0 version: 14.3.0(vue@3.5.44(typescript-native-bridge@6.0.3-bridge.19.tsgo.7.0.2)) @@ -554,9 +555,9 @@ importers: '@inkcre/core': specifier: workspace:* version: link:../../packages/core - '@inkcre/extension-runtime-client-web': + '@inkcre/extension-runtime-web': specifier: https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz - version: https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz(@inkcre/core@packages+core)(@module-federation/runtime@0.22.1) + version: '@inkcre/extension-runtime-client-web@https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz(@inkcre/core@packages+core)(@module-federation/runtime@0.22.1)' '@vueuse/core': specifier: ^14.0.0 version: 14.3.0(vue@3.5.44(typescript-native-bridge@6.0.3-bridge.19.tsgo.7.0.2)) @@ -6069,9 +6070,6 @@ packages: yaml: optional: true - zod@4.1.12: - resolution: {integrity: sha512-JInaHOamG8pt5+Ey8kGmdcAcg3OL9reK8ltczgHTAwNhMys/6ThXHityHxVV2p3fkw/c+MAvBHFVYHFZDmjMCQ==} - zod@4.4.3: resolution: {integrity: sha512-ytENFjIJFl2UwYglde2jchW2Hwm4GJFLDiSXWdTrJQBIN9Fcyp7n4DhxJEiWNAJMV1/BqWfW/kkg71UDcHJyTQ==} @@ -6943,14 +6941,14 @@ snapshots: '@inkcre/core': link:packages/core '@module-federation/runtime': 0.21.6 semver: 7.8.5 - zod: 4.1.12 + zod: 4.6.7 '@inkcre/extension-runtime-client-web@https://github.com/InKCre/ext-reg/releases/download/runtime-client-web-v0.4.2/inkcre-extension-runtime-client-web-0.4.2.tgz(@inkcre/core@packages+core)(@module-federation/runtime@0.22.1)': dependencies: '@inkcre/core': link:packages/core '@module-federation/runtime': 0.22.1 semver: 7.8.5 - zod: 4.1.12 + zod: 4.6.7 '@inkcre/ui-web@https://github.com/InKCre/ui/releases/download/%40inkcre%2Fui-web%402.3.0/inkcre-ui-web-2.3.0.tgz(unocss@66.7.5(vite@7.3.6(@types/node@22.17.2)(jiti@2.7.0)(lightningcss@1.33.0)(sass-embedded@1.90.0)(sass@1.101.6)(yaml@2.9.0)))(vue@3.5.44(typescript-native-bridge@6.0.3-bridge.19.tsgo.7.0.2))': dependencies: @@ -11231,8 +11229,6 @@ snapshots: json5: 2.2.3 yaml: 2.9.0 - zod@4.1.12: {} - zod@4.4.3: {} zod@4.6.7: {} diff --git a/pnpm-workspace.yaml b/pnpm-workspace.yaml index 11c4b304..5f0ff9cd 100644 --- a/pnpm-workspace.yaml +++ b/pnpm-workspace.yaml @@ -17,6 +17,8 @@ allowBuilds: workerd: false overrides: + # GHSA-mrhx-c7xc-m3w5: keep the admitted tarball; remove after adopting a fixed Runtime release. + '@inkcre/extension-runtime-client-web@0.4.2>zod': 4.6.7 '@inkcre/ui-web@2.3.0': https://github.com/InKCre/ui/releases/download/%40inkcre%2Fui-web%402.3.0/inkcre-ui-web-2.3.0.tgz '@inkcre/ui-web@2.5.0': https://github.com/InKCre/ui/releases/download/%40inkcre%2Fui-web%402.5.0/inkcre-ui-web-2.5.0.tgz '@inkcre/ui-web@2.7.0': https://github.com/InKCre/ui/releases/download/%40inkcre%2Fui-web%402.7.0/inkcre-ui-web-2.7.0.tgz diff --git a/pyproject.toml b/pyproject.toml index 7608be97..d04d6bf6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,5 +1,5 @@ [project] -name = "inkcre-client-web-tooling" +name = "inkcre-web-tooling" version = "0.0.0" description = "Repository-level development tooling for the InKCre Web monorepo" requires-python = ">=3.13,<3.14" diff --git a/scripts/check-local-runtime-contract.mjs b/scripts/check-local-runtime-contract.mjs index d2b7c09a..022cefff 100644 --- a/scripts/check-local-runtime-contract.mjs +++ b/scripts/check-local-runtime-contract.mjs @@ -37,7 +37,7 @@ async function sourceFiles(relativeDirectory) { } const rootPackage = await readJson('package.json') -const webPackage = await readJson('apps/client-web/package.json') +const webPackage = await readJson('apps/web/package.json') const svcConfig = await readJson('svc.json') const nodeRuntime = rootPackage.devEngines?.runtime @@ -89,15 +89,15 @@ if (rootPackage.scripts?.['dev:stop'] !== 'node scripts/dev-stop.mjs') { for (const dependency of ['@cloudflare/workers-types', 'hono', 'wrangler']) { if (webPackage.dependencies?.[dependency] || webPackage.devDependencies?.[dependency]) { - errors.push(`static client must not depend on legacy runtime tool "${dependency}"`) + errors.push(`static Web App must not depend on legacy runtime tool "${dependency}"`) } } for (const path of [ - 'apps/client-web/.env.cloudflare', - 'apps/client-web/.env.example', - 'apps/client-web/server/index.ts', - 'apps/client-web/wrangler.jsonc', + 'apps/web/.env.cloudflare', + 'apps/web/.env.example', + 'apps/web/server/index.ts', + 'apps/web/wrangler.jsonc', 'deploy/profiles/legacy-endpoints.json', 'deploy/profiles/production.json', 'packages/core/src/database/production-profile.ts', @@ -111,10 +111,10 @@ for (const path of [ const runtimeSources = [ ...(await sourceFiles('packages/core/src')), ...(await sourceFiles('packages/ext-dev-utils/src')), - ...(await sourceFiles('apps/client-web/src')), - ...(await sourceFiles('apps/client-webext/components')), - ...(await sourceFiles('apps/client-webext/entrypoints')), - ...(await sourceFiles('apps/client-webext/logic')), + ...(await sourceFiles('apps/web/src')), + ...(await sourceFiles('apps/webext/components')), + ...(await sourceFiles('apps/webext/entrypoints')), + ...(await sourceFiles('apps/webext/logic')), ...( await Promise.all( ( @@ -270,7 +270,7 @@ for (const required of [ } } -for (const path of ['apps/client-web/vite.config.ts', 'extensions/twitter/vite.config.ts']) { +for (const path of ['apps/web/vite.config.ts', 'extensions/twitter/vite.config.ts']) { const config = await readFile(`${repoRoot}/${path}`, 'utf8') for (const required of [ 'createUiSourceAliases', @@ -287,7 +287,7 @@ for (const path of ['apps/client-web/vite.config.ts', 'extensions/twitter/vite.c } } -const wxtConfig = await readFile(`${repoRoot}/apps/client-webext/wxt.config.ts`, 'utf8') +const wxtConfig = await readFile(`${repoRoot}/apps/webext/wxt.config.ts`, 'utf8') if (wxtConfig.includes('--remote-debugging-port=9222')) { errors.push('WXT development must not reuse the fixed Chromium debugging port 9222') } diff --git a/scripts/check-locale-keys.mjs b/scripts/check-locale-keys.mjs index 00f0e59a..48d6c973 100644 --- a/scripts/check-locale-keys.mjs +++ b/scripts/check-locale-keys.mjs @@ -2,7 +2,7 @@ /** * Locale key coverage check. * - * Every literal `t('a.b.c')` call in the client source must resolve in BOTH + * Every literal `t('a.b.c')` call in the Web App source must resolve in BOTH * locale catalogs (en and zh-CN). The overhaul batch that reorganized the * locale files dropped a few keys whose usages survived (sidePanel.managing, * sidePanel.infoBase, source.saveFailed), which rendered raw i18n keys in @@ -16,7 +16,7 @@ import { join, relative } from 'node:path' import { fileURLToPath } from 'node:url' const root = join(fileURLToPath(import.meta.url), '..', '..') -const srcDir = join(root, 'apps/client-web/src') +const srcDir = join(root, 'apps/web/src') const catalogs = ['en', 'zh-CN'].map((name) => ({ name, messages: JSON.parse(readFileSync(join(srcDir, 'locales/messages', `${name}.json`), 'utf8')), diff --git a/scripts/check-package-contract.mjs b/scripts/check-package-contract.mjs index 30f350cd..55f20aad 100644 --- a/scripts/check-package-contract.mjs +++ b/scripts/check-package-contract.mjs @@ -32,18 +32,18 @@ await Promise.all( 'packages/core/dist/index.js.map', 'packages/core/dist/index.d.ts', 'packages/core/dist/index.d.ts.map', - 'apps/client-web/dist/index.html', - 'apps/client-webext/.output/chrome-mv3/manifest.json', - 'apps/client-webext/.output/chrome-mv3/content-scripts/collection.js', - 'apps/client-webext/.output/chrome-mv3/options.html', - 'apps/client-webext/.output/chrome-mv3/popup.html', - 'extensions/github/dist/client-web/remoteEntry.js', - 'extensions/caldav/dist/client-web/remoteEntry.js', - 'extensions/capture/dist/client-web/remoteEntry.js', - 'extensions/local-files/dist/client-web/remoteEntry.js', - 'extensions/mail/dist/client-web/remoteEntry.js', - 'extensions/memos/dist/client-web/remoteEntry.js', - 'extensions/twitter/dist/client-web/remoteEntry.js', + 'apps/web/dist/index.html', + 'apps/webext/.output/chrome-mv3/manifest.json', + 'apps/webext/.output/chrome-mv3/content-scripts/collection.js', + 'apps/webext/.output/chrome-mv3/options.html', + 'apps/webext/.output/chrome-mv3/popup.html', + 'extensions/github/dist/web/remoteEntry.js', + 'extensions/caldav/dist/web/remoteEntry.js', + 'extensions/capture/dist/web/remoteEntry.js', + 'extensions/local-files/dist/web/remoteEntry.js', + 'extensions/mail/dist/web/remoteEntry.js', + 'extensions/memos/dist/web/remoteEntry.js', + 'extensions/twitter/dist/web/remoteEntry.js', ].map((path) => requireFile(`${repoRoot}/${path}`)) ) @@ -62,12 +62,10 @@ for (const entry of await readdir(`${repoRoot}/extensions`, { withFileTypes: tru await inspectNativeModuleFederation({ packagePath: `${directory}/package.json`, corePackagePath: `${coreRoot}/package.json`, - artifactDirectory: `${directory}/dist/client-web`, + artifactDirectory: `${directory}/dist/web`, }) if (entry.name === 'twitter') { - const manifest = JSON.parse( - await readFile(`${directory}/dist/client-web/mf-manifest.json`, 'utf8') - ) + const manifest = JSON.parse(await readFile(`${directory}/dist/web/mf-manifest.json`, 'utf8')) if (!manifest.shared?.some((shared) => shared.name === '@inkcre/ui-web')) { errors.push('Twitter UI components must share @inkcre/ui-web with the Host') } @@ -77,11 +75,11 @@ for (const entry of await readdir(`${repoRoot}/extensions`, { withFileTypes: tru } } -const twitterRemoteEntry = `${repoRoot}/extensions/twitter/dist/client-web/remoteEntry.js` +const twitterRemoteEntry = `${repoRoot}/extensions/twitter/dist/web/remoteEntry.js` try { const content = await readFile(twitterRemoteEntry, 'utf8') - if (content.includes('/twitter/client-web/')) { - errors.push('Twitter remote entry retains an absolute /twitter/client-web/ artifact base') + if (/\/twitter\/(?:client-web|web)\//.test(content)) { + errors.push('Twitter remote entry retains an absolute application artifact base') } if (!content.includes('./assets/')) { errors.push( @@ -115,11 +113,11 @@ async function builtFiles(directory) { return files } -const webDist = `${repoRoot}/apps/client-web/dist` -const webextDist = `${repoRoot}/apps/client-webext/.output/chrome-mv3` +const webDist = `${repoRoot}/apps/web/dist` +const webextDist = `${repoRoot}/apps/webext/.output/chrome-mv3` try { await access(`${webDist}/_worker.js`) - errors.push('unexpected Worker output: apps/client-web/dist/_worker.js') + errors.push('unexpected Worker output: apps/web/dist/_worker.js') } catch { // The web application is a static Pages artifact. } @@ -159,7 +157,7 @@ if ( errors.push('packages/core/package.json does not match the ESM-only dist contract') } -const consumerPackage = `${repoRoot}/apps/client-web/node_modules/@inkcre/core` +const consumerPackage = `${repoRoot}/apps/web/node_modules/@inkcre/core` try { const resolvedPackage = await realpath(consumerPackage) const expectedPackage = await realpath(coreRoot) @@ -175,7 +173,7 @@ try { process.execPath, ['--input-type=module', '--eval', "await import('@inkcre/core')"], { - cwd: `${repoRoot}/apps/client-web`, + cwd: `${repoRoot}/apps/web`, stdio: ['ignore', 'pipe', 'pipe'], timeout: 10000, } diff --git a/scripts/check-workspace-contract.mjs b/scripts/check-workspace-contract.mjs index cd2de91a..917d94c8 100644 --- a/scripts/check-workspace-contract.mjs +++ b/scripts/check-workspace-contract.mjs @@ -43,15 +43,15 @@ const workspaces = [ buildExemption: 'source-only browser material contract; consuming peers own output', }, { - path: 'apps/client-web', - name: '@inkcre/client-web', + path: 'apps/web', + name: '@inkcre/web', requiredScripts: ['build', 'dev', 'type-check'], builder: 'vite', builderScript: 'build-only', }, { - path: 'apps/client-webext', - name: '@inkcre/client-webext', + path: 'apps/webext', + name: '@inkcre/webext', requiredScripts: ['build', 'build:firefox', 'dev', 'type-check'], builder: 'wxt', }, diff --git a/scripts/core-release-lib.mjs b/scripts/core-release-lib.mjs index 460476a5..9dcd9579 100644 --- a/scripts/core-release-lib.mjs +++ b/scripts/core-release-lib.mjs @@ -102,7 +102,7 @@ export function validateRuntimeContract(contract, manifest) { /** * Project the image-owned runtime document into the compatibility facts consumed * by browser peers. Image provenance remains execution evidence, not a checked-in - * client interface. + * database-consumer interface. */ export function projectDatabaseCompatibilityContract(contract) { const compatibility = { @@ -142,7 +142,7 @@ export function validateDatabaseCompatibilityContract(contract) { const hasExpectedFields = hasExactKeys(contract, ['format', 'revision', 'protocol', 'jwt']) const hasExpectedProtocol = hasExactKeys(contract.protocol, ['format', 'schema']) if (!hasExpectedFields || !hasExpectedProtocol) { - throw new Error('database compatibility contract contains non-client fields') + throw new Error('database compatibility contract contains non-consumer fields') } return compatibility } diff --git a/scripts/database-runtime-lib.mjs b/scripts/database-runtime-lib.mjs index 63455e48..aaabb036 100644 --- a/scripts/database-runtime-lib.mjs +++ b/scripts/database-runtime-lib.mjs @@ -46,10 +46,11 @@ export function runtimeDirectory(instance) { } export function projectName(instance) { - return `inkcre-client-web-${validateInstance(instance)}` + return `inkcre-web-${validateInstance(instance)}` } function localSecret(instance, purpose) { + // Keep existing browser credentials valid when this worktree's disposable database is rebuilt. return createHash('sha256').update(`inkcre-client-web/${instance}/${purpose}`).digest('hex') } @@ -89,7 +90,7 @@ async function writeRuntimeFiles(state, credentials) { }, peer: { id: BROWSER_PEER_ID, - name: 'client-web-development', + name: 'web-development', }, core: { peer_id: CORE_PEER_ID, @@ -326,9 +327,7 @@ export async function ensureDatabaseRuntime(instance, options = {}) { export async function stopDatabaseRuntime(instance, options = {}) { const state = await runtimeState(instance) if (state.provider.kind === 'external') { - throw new Error( - `runtime ${state.runtime_instance} is owned by impl-py; client-web cannot stop it` - ) + throw new Error(`runtime ${state.runtime_instance} is owned by impl-py; web cannot stop it`) } try { compose(instance, ['down', '--volumes', '--remove-orphans'], { diff --git a/scripts/dev-wxt.mjs b/scripts/dev-wxt.mjs index 0e8c9a47..2d352703 100644 --- a/scripts/dev-wxt.mjs +++ b/scripts/dev-wxt.mjs @@ -20,7 +20,7 @@ const profileDir = `${repoRoot}/.runtime/dev/${instance}/chromium-profile` await mkdir(profileDir, { recursive: true }) const child = spawn('pnpm', ['exec', 'wxt'], { - cwd: `${repoRoot}/apps/client-webext`, + cwd: `${repoRoot}/apps/webext`, env: { ...process.env, INKCRE_WXT_PROFILE_DIR: profileDir, diff --git a/scripts/dev.mjs b/scripts/dev.mjs index 01e28aac..bb1e6e60 100644 --- a/scripts/dev.mjs +++ b/scripts/dev.mjs @@ -57,10 +57,11 @@ async function runDeclaredTarget() { } } + // Browser settings belong to this origin; a source/package rename must not strand them. const routePrefix = target === 'web-ui' ? 'client-web-ui' : target === 'web' ? 'client-web' : 'webext' const name = `${routePrefix}-${instance}` - const cwd = `${repoRoot}/${isWebTarget ? 'apps/client-web' : 'apps/client-webext'}` + const cwd = `${repoRoot}/${isWebTarget ? 'apps/web' : 'apps/webext'}` const command = isWebTarget ? ['pnpm', 'exec', 'vite'] : ['node', '../../scripts/dev-wxt.mjs'] return run('pnpm', ['exec', 'portless', name, ...command], { diff --git a/scripts/doctor.mjs b/scripts/doctor.mjs index 33b84254..984b9d8f 100644 --- a/scripts/doctor.mjs +++ b/scripts/doctor.mjs @@ -59,7 +59,7 @@ record( ) record( 'wxt-generated-state', - (await exists('apps/client-webext/.wxt/tsconfig.json')) ? 'ok' : 'error', + (await exists('apps/webext/.wxt/tsconfig.json')) ? 'ok' : 'error', 'generated by the frozen-install postinstall' ) diff --git a/scripts/probe-dev.mjs b/scripts/probe-dev.mjs index 55168cf2..ed79aebd 100644 --- a/scripts/probe-dev.mjs +++ b/scripts/probe-dev.mjs @@ -9,6 +9,7 @@ const instance = process.argv[3] const repoRoot = fileURLToPath(new URL('..', import.meta.url)) const portlessBin = `${repoRoot}/node_modules/.bin/portless` const names = { + // Keep the browser origin stable so existing local settings remain readable. web: 'client-web', 'web-ui': 'client-web-ui', webext: 'webext', diff --git a/scripts/publish-first-party-extensions.mjs b/scripts/publish-first-party-extensions.mjs index f56ae27f..42d66d84 100644 --- a/scripts/publish-first-party-extensions.mjs +++ b/scripts/publish-first-party-extensions.mjs @@ -134,7 +134,7 @@ export async function captureCandidates({ ) continue } - const artifactDirectory = path.join(path.dirname(packagePath), 'dist/client-web') + const artifactDirectory = path.join(path.dirname(packagePath), 'dist/web') const local = await inspectNativeModuleFederation({ packagePath, corePackagePath: path.join(workspace, 'packages/core/package.json'), @@ -350,7 +350,7 @@ async function main() { provenance: { source_repository: repository, source_revision: revision, - build_id: `client-web-extension-release-${runId}`, + build_id: `web-extension-release-${runId}`, }, } if (command === 'capture') { diff --git a/scripts/report-pages-preview.mjs b/scripts/report-pages-preview.mjs index 88c20984..a0801206 100644 --- a/scripts/report-pages-preview.mjs +++ b/scripts/report-pages-preview.mjs @@ -22,7 +22,7 @@ if (!/^[a-f0-9]{40}$/.test(revision ?? '')) throw new Error('Missing or invalid if (!process.env.GITHUB_STEP_SUMMARY) throw new Error('Missing GitHub job summary path') const summary = [ - '## Client-Web 预览', + '## Web App 预览', '', `- [打开 PR 预览](${previewUrl})`, `- [本次部署快照](${deploymentUrl})`, diff --git a/scripts/test-e2e.mjs b/scripts/test-e2e.mjs index bed0a998..27d4d2a8 100644 --- a/scripts/test-e2e.mjs +++ b/scripts/test-e2e.mjs @@ -78,7 +78,7 @@ try { const ownsRuntime = state.provider.kind !== 'external' const baseline = ownsRuntime ? developmentFingerprint(instance) : null - run('pnpm', ['--filter', '@inkcre/client-web', 'build-only']) + run('pnpm', ['--filter', '@inkcre/web', 'build-only']) run('pnpm', ['--filter', '@inkcre/ext-github...', 'build']) const webPort = await availablePort() const webUrl = `http://127.0.0.1:${webPort}/` @@ -86,7 +86,7 @@ try { 'pnpm', [ '--filter', - '@inkcre/client-web', + '@inkcre/web', 'exec', 'vite', 'preview', diff --git a/scripts/test-extension-publication.mjs b/scripts/test-extension-publication.mjs index bcab4a97..fb9c8ad2 100644 --- a/scripts/test-extension-publication.mjs +++ b/scripts/test-extension-publication.mjs @@ -30,7 +30,7 @@ void test('an unknown MF-only upload resumes the saved ZIP and verifies even an const workspace = await mkdtemp(path.join(os.tmpdir(), 'inkcre-publication-test-')) let registryUrl = 'https://registry.example.test' const prefix = '/extensions/test/source/1.0.0/module-federation/' - const build = path.join(workspace, 'extensions/source/dist/client-web') + const build = path.join(workspace, 'extensions/source/dist/web') const uploaded = path.join(workspace, 'uploaded') let prepared let published = false diff --git a/scripts/test-webext-e2e.mjs b/scripts/test-webext-e2e.mjs index 5e631e5b..1f6100d2 100644 --- a/scripts/test-webext-e2e.mjs +++ b/scripts/test-webext-e2e.mjs @@ -12,5 +12,5 @@ function run(command, args) { } run('pnpm', ['--filter', '@inkcre/core', 'build']) -run('pnpm', ['--filter', '@inkcre/client-webext', 'build']) +run('pnpm', ['--filter', '@inkcre/webext', 'build']) run('pnpm', ['exec', 'playwright', 'test', '--project', 'browser-extension']) diff --git a/scripts/tests/database-probe.test.mjs b/scripts/tests/database-probe.test.mjs index 79830a8d..7365aba3 100644 --- a/scripts/tests/database-probe.test.mjs +++ b/scripts/tests/database-probe.test.mjs @@ -116,7 +116,7 @@ void test('database probe distinguishes stale provenance from transport failure }, } ), - /owned by impl-py; client-web cannot stop it/ + /owned by impl-py; web cannot stop it/ ) assert.ok(requests.every((method) => method === 'GET')) assert.deepEqual(JSON.parse(await readFile(descriptorPath, 'utf8')), descriptor) diff --git a/scripts/tests/independent-extension-release.test.mjs b/scripts/tests/independent-extension-release.test.mjs index 6743adf1..c7cf94c7 100644 --- a/scripts/tests/independent-extension-release.test.mjs +++ b/scripts/tests/independent-extension-release.test.mjs @@ -72,7 +72,7 @@ void test('a prepared Mail release does not publish another producer with pendin }, }) } - const build = 'extensions/mail/dist/client-web' + const build = 'extensions/mail/dist/web' await mkdir(path.join(workspace, build), { recursive: true }) await json(`${build}/mf-manifest.json`, { metaData: { publicPath: './', remoteEntry: { name: 'remoteEntry.js' } }, diff --git a/scripts/tests/pages-preview.test.mjs b/scripts/tests/pages-preview.test.mjs index 739385c4..14ac3984 100644 --- a/scripts/tests/pages-preview.test.mjs +++ b/scripts/tests/pages-preview.test.mjs @@ -6,7 +6,7 @@ import { join } from 'node:path' import test from 'node:test' import { preparePagesPreview } from '../prepare-pages-preview.mjs' -const requireWeb = createRequire(new URL('../../apps/client-web/package.json', import.meta.url)) +const requireWeb = createRequire(new URL('../../apps/web/package.json', import.meta.url)) const requireRuntime = createRequire(requireWeb.resolve('@module-federation/runtime')) const { generateSnapshotFromManifest } = requireRuntime('@module-federation/sdk') diff --git a/scripts/tests/twitter-rendering/specimens.vue b/scripts/tests/twitter-rendering/specimens.vue index a92f4476..f9d6afa8 100644 --- a/scripts/tests/twitter-rendering/specimens.vue +++ b/scripts/tests/twitter-rendering/specimens.vue @@ -2,10 +2,10 @@ import { computed, markRaw, ref } from 'vue' import { VueFlow } from '@vue-flow/core' import { setInfoBaseRouter, type InfoBaseRoute } from '@inkcre/core' -import SolvedContentRenderer from '../../../apps/client-web/src/components/info-base/SolvedContentRenderer/SolvedContentRenderer.vue' -import PreviewRenderer from '../../../apps/client-web/src/components/info-base/PreviewRenderer/PreviewRenderer.vue' -import BlockNode from '../../../apps/client-web/src/components/info-base/BlockNode/BlockNode.vue' -import SolvedContentPopup from '../../../apps/client-web/src/components/info-base/SolvedContentPopup/SolvedContentPopup.vue' +import SolvedContentRenderer from '../../../apps/web/src/components/info-base/SolvedContentRenderer/SolvedContentRenderer.vue' +import PreviewRenderer from '../../../apps/web/src/components/info-base/PreviewRenderer/PreviewRenderer.vue' +import BlockNode from '../../../apps/web/src/components/info-base/BlockNode/BlockNode.vue' +import SolvedContentPopup from '../../../apps/web/src/components/info-base/SolvedContentPopup/SolvedContentPopup.vue' import { specimens, blocks, resolverFor, solvedFor } from './fixtures' const selected = ref(100) diff --git a/scripts/tests/twitter-rendering/vite.config.ts b/scripts/tests/twitter-rendering/vite.config.ts index 04db1da4..8919bd7a 100644 --- a/scripts/tests/twitter-rendering/vite.config.ts +++ b/scripts/tests/twitter-rendering/vite.config.ts @@ -4,7 +4,7 @@ import { createRequire } from 'node:module' import vue from '@vitejs/plugin-vue' const root = fileURLToPath(new URL('../../..', import.meta.url)) -const app = resolve(root, 'apps/client-web') +const app = resolve(root, 'apps/web') const require = createRequire(resolve(app, 'package.json')) export default { diff --git a/scripts/tests/ui-source.test.mjs b/scripts/tests/ui-source.test.mjs index d61751fa..b60ba5b3 100644 --- a/scripts/tests/ui-source.test.mjs +++ b/scripts/tests/ui-source.test.mjs @@ -12,7 +12,7 @@ const require = createRequire(import.meta.url) void test('UI source type checking accepts an external checkout and rejects its type errors', async (context) => { const root = await mkdtemp(join(tmpdir(), 'inkcre-ui-types-')) context.after(() => rm(root, { recursive: true, force: true })) - const appRoot = join(root, 'impl-ts/apps/client-web') + const appRoot = join(root, 'impl-ts/apps/web') const uiRoot = join(root, 'ui/packages/web') const runtimeRoot = join(root, 'impl-ts/.runtime/ui-source') for (const path of [join(appRoot, 'src'), uiRoot, runtimeRoot]) { diff --git a/scripts/tests/webext-release.test.mjs b/scripts/tests/webext-release.test.mjs index 7d8882de..d607df24 100644 --- a/scripts/tests/webext-release.test.mjs +++ b/scripts/tests/webext-release.test.mjs @@ -10,7 +10,7 @@ import { preparedVersion, } from '../webext-release.mjs' -const require = createRequire(new URL('../../apps/client-webext/package.json', import.meta.url)) +const require = createRequire(new URL('../../apps/webext/package.json', import.meta.url)) void test('only a prepared numeric WebExt version is selected, independently of other units', () => { assert.equal(preparedVersion('0.2.0', '# WebExt\n\n## 0.2.0\nNews', false), true) @@ -50,7 +50,7 @@ void test('a new draft uses its creation response before release inventory catch }) void test('browser artifacts preserve identity, numeric version and readable toolbar variants', async () => { - const root = new URL('../../apps/client-webext/', import.meta.url) + const root = new URL('../../apps/webext/', import.meta.url) const metadata = JSON.parse(await readFile(new URL('package.json', root), 'utf8')) const { key } = JSON.parse(await readFile(new URL('chromium-key.json', root), 'utf8')) assert.match(extensionId(key), /^[a-p]{32}$/) diff --git a/scripts/type-check-ui.mjs b/scripts/type-check-ui.mjs index e9ef1eea..84de1b86 100644 --- a/scripts/type-check-ui.mjs +++ b/scripts/type-check-ui.mjs @@ -6,7 +6,7 @@ import { resolve } from 'node:path' import { createUiSourceTsconfig, readUiSourceInput, resolveUiSourcePackage } from './ui-source.mjs' const repoRoot = fileURLToPath(new URL('..', import.meta.url)) -const appRoot = resolve(repoRoot, 'apps/client-web') +const appRoot = resolve(repoRoot, 'apps/web') const runtimeRoot = resolve(repoRoot, '.runtime/ui-source') const configPath = resolve(runtimeRoot, 'tsconfig.json') diff --git a/scripts/verify-pages-deployment.mjs b/scripts/verify-pages-deployment.mjs index a76ad6f9..9330f34e 100644 --- a/scripts/verify-pages-deployment.mjs +++ b/scripts/verify-pages-deployment.mjs @@ -1,6 +1,7 @@ const deploymentId = process.env.CLOUDFLARE_PAGES_DEPLOYMENT_ID const deploymentUrl = process.env.CLOUDFLARE_PAGES_DEPLOYMENT_URL -const productionUrl = process.env.INKCRE_CLIENT_WEB_ORIGIN +// Retain the old deployment variable for externally owned invocation scripts. +const productionUrl = process.env.INKCRE_WEB_ORIGIN ?? process.env.INKCRE_CLIENT_WEB_ORIGIN const expectedPagesOrigin = process.env.INKCRE_EXPECTED_PAGES_ORIGIN const previewProducer = process.env.INKCRE_PREVIEW_PRODUCER @@ -38,7 +39,7 @@ async function readStaticPage(targetOrigin, path, attempts = 5) { throw new Error(`Pages smoke ${path} did not return HTML`) } if (!body.includes('
')) { - throw new Error(`Pages smoke ${path} did not return the client-web shell`) + throw new Error(`Pages smoke ${path} did not return the web shell`) } return } catch (error) { diff --git a/scripts/verify-client-web-release.mjs b/scripts/verify-web-release.mjs similarity index 82% rename from scripts/verify-client-web-release.mjs rename to scripts/verify-web-release.mjs index a96f13b7..3e037d71 100644 --- a/scripts/verify-client-web-release.mjs +++ b/scripts/verify-web-release.mjs @@ -4,7 +4,7 @@ import { fileURLToPath } from 'node:url' import { inspectBrowserArtifact } from './browser-runtime-contract.mjs' const repoRoot = fileURLToPath(new URL('..', import.meta.url)) -const distRoot = `${repoRoot}/apps/client-web/dist` +const distRoot = `${repoRoot}/apps/web/dist` const errors = [] try { @@ -36,16 +36,16 @@ for (const relativePath of ['index.html']) { try { await access(`${distRoot}/${relativePath}`) } catch { - errors.push(`missing web release output: apps/client-web/dist/${relativePath}`) + errors.push(`missing web release output: apps/web/dist/${relativePath}`) } } for (const relativePath of ['_worker.js']) { try { await access(`${distRoot}/${relativePath}`) - errors.push(`unexpected runtime output: apps/client-web/dist/${relativePath}`) + errors.push(`unexpected runtime output: apps/web/dist/${relativePath}`) } catch { - // The client release is a static Pages artifact. + // The Web App release is a static Pages artifact. } } @@ -71,5 +71,5 @@ if (errors.length > 0) { } process.exitCode = 1 } else { - console.log('[OK] client-web release is a static, environment-neutral Pages artifact') + console.log('[OK] web release is a static, environment-neutral Pages artifact') } diff --git a/scripts/webext-release.mjs b/scripts/webext-release.mjs index 0a12db34..812be437 100644 --- a/scripts/webext-release.mjs +++ b/scripts/webext-release.mjs @@ -7,7 +7,7 @@ import { fileURLToPath } from 'node:url' import { readJson, stableJson } from './core-release-lib.mjs' const directory = '.webext-delivery' -const app = 'apps/client-webext' +const app = 'apps/webext' const repository = 'InKCre/impl-ts' const sha256 = (bytes) => createHash('sha256').update(bytes).digest('hex') const run = (command, args) => execFileSync(command, args, { stdio: 'inherit' }) @@ -113,7 +113,7 @@ export async function createDraftRelease({ tag, source, version, news }) { async function verifyCandidate() { const receipt = await readJson(`${directory}/source.json`) - assert.equal(receipt.name, '@inkcre/client-webext') + assert.equal(receipt.name, '@inkcre/webext') assert.match(receipt.version, /^\d+\.\d+\.\d+$/) assert.match(receipt.source_revision, /^[0-9a-f]{40}$/) assert.deepEqual(receipt.assets.map((asset) => asset.name).sort(), [ @@ -144,7 +144,7 @@ async function versionPrepared(version) { run('pnpm', ['exec', 'changeset', 'status', '--output', `${directory}/changesets.json`]) const status = await readJson(`${directory}/changesets.json`) const pending = status.changesets.some((item) => - item.releases.some((release) => release.name === '@inkcre/client-webext') + item.releases.some((release) => release.name === '@inkcre/webext') ) let changelog = '' try { @@ -179,11 +179,7 @@ export async function main(command) { await mkdir(directory, { recursive: true }) const names = [] for (const browser of ['chrome', 'firefox']) { - run('pnpm', [ - '--filter', - '@inkcre/client-webext', - browser === 'chrome' ? 'zip' : 'zip:firefox', - ]) + run('pnpm', ['--filter', '@inkcre/webext', browser === 'chrome' ? 'zip' : 'zip:firefox']) const name = `inkcre-webext-${version}-${browser}.zip` await copyFile( `${app}/.output/inkcre-webext-${version}-${browser}-production.zip`, @@ -195,7 +191,7 @@ export async function main(command) { run('git', ['archive', '--format=tar.gz', `--output=${directory}/${sourceName}`, source]) names.push(sourceName) const receipt = { - name: '@inkcre/client-webext', + name: '@inkcre/webext', version, source_revision: source, chromium_id: extensionId(key), diff --git a/tests/e2e/browser-extension-fixture.ts b/tests/e2e/browser-extension-fixture.ts index c2e1a0fe..90b05945 100644 --- a/tests/e2e/browser-extension-fixture.ts +++ b/tests/e2e/browser-extension-fixture.ts @@ -5,7 +5,7 @@ import { tmpdir } from 'node:os' import { join } from 'node:path' const extensionPath = fileURLToPath( - new URL('../../apps/client-webext/.output/chrome-mv3', import.meta.url) + new URL('../../apps/webext/.output/chrome-mv3', import.meta.url) ) export const test = base.extend<{ diff --git a/tests/e2e/browser-extension.spec.ts b/tests/e2e/browser-extension.spec.ts index 841ba96c..957abe0e 100644 --- a/tests/e2e/browser-extension.spec.ts +++ b/tests/e2e/browser-extension.spec.ts @@ -408,9 +408,7 @@ test('built Chromium extension sizes its native toolbar popup and opens independ const pageErrors: string[] = [] const manifest = JSON.parse( await readFile( - fileURLToPath( - new URL('../../apps/client-webext/.output/chrome-mv3/manifest.json', import.meta.url) - ), + fileURLToPath(new URL('../../apps/webext/.output/chrome-mv3/manifest.json', import.meta.url)), 'utf8' ) ) @@ -430,9 +428,7 @@ test('built Chromium extension sizes its native toolbar popup and opens independ ]) await expect( access( - fileURLToPath( - new URL('../../apps/client-webext/.output/chrome-mv3/' + path, import.meta.url) - ) + fileURLToPath(new URL('../../apps/webext/.output/chrome-mv3/' + path, import.meta.url)) ) ).rejects.toThrow() expect(manifest.action.default_icon).toEqual({ diff --git a/tests/e2e/github-native.ts b/tests/e2e/github-native.ts index e0e1c9b9..58bec78c 100644 --- a/tests/e2e/github-native.ts +++ b/tests/e2e/github-native.ts @@ -75,7 +75,7 @@ export function registerGitHubNativeTests(): void { await remoteEntryGate } const file = fileURLToPath( - new URL(`../../extensions/github/dist/client-web/${relative}`, import.meta.url) + new URL(`../../extensions/github/dist/web/${relative}`, import.meta.url) ) let body = await readFile(file) if (relative === 'mf-manifest.json') { @@ -343,7 +343,7 @@ export function registerGitHubNativeTests(): void { content.getByRole('heading', { name: 'fixture-org/demo', exact: true }) ).toBeVisible() // Background participation does not own the local reader Host. - // Client-side navigation keeps the document (and the MF host instance) alive. + // Browser navigation keeps the document (and the MF host instance) alive. async function openSettings(): Promise { // The unified entity UI renders object views as modal popups; close any // open one so the header controls are clickable. diff --git a/tests/e2e/mail-info-base.spec.ts b/tests/e2e/mail-info-base.spec.ts index 128310c4..8b02ee71 100644 --- a/tests/e2e/mail-info-base.spec.ts +++ b/tests/e2e/mail-info-base.spec.ts @@ -100,7 +100,7 @@ test.beforeEach(async ({ page }) => { test('Mail is used through the generic InfoBase navigation host', async ({ page }) => { const graph = await locateAcceptanceGraph() const remoteEntry = page.waitForResponse( - (response) => response.url().includes('/mail/client-web/remoteEntry.js') && response.ok() + (response) => response.url().includes('/mail/web/remoteEntry.js') && response.ok() ) const trackerRequests: string[] = [] page.on('request', (request) => { diff --git a/tests/e2e/peer-database.spec.ts b/tests/e2e/peer-database.spec.ts index 593d5a69..036bf9e4 100644 --- a/tests/e2e/peer-database.spec.ts +++ b/tests/e2e/peer-database.spec.ts @@ -6,8 +6,8 @@ import { registerGitHubNativeTests } from './github-native' const postgrestUrl = process.env.INKCRE_E2E_POSTGREST_URL! const jwtSecret = process.env.INKCRE_E2E_JWT_SECRET! const coreUrl = process.env.INKCRE_E2E_CORE_URL! -const clientVersion = JSON.parse( - readFileSync(new URL('../../apps/client-web/package.json', import.meta.url), 'utf8') +const appVersion = JSON.parse( + readFileSync(new URL('../../apps/web/package.json', import.meta.url), 'utf8') ).version /** Navigate to Settings without replacing the document, so in-page runtimes and @@ -468,7 +468,7 @@ test('a new browser identity waits for insertion before opening business pages', inserting = true const inserted = route.request().postDataJSON() expect(inserted.id).toBe(peerId) - expect(inserted.application_version).toBe(clientVersion) + expect(inserted.application_version).toBe(appVersion) expect(inserted.capabilities).toEqual([]) await gate await route.fulfill({ @@ -1176,9 +1176,7 @@ test('failed remote enablement reads back persisted intent without claiming a ru }) test('wrong and absent credentials are rejected', async ({ page }) => { - const wrongAuthorization = `Bearer ${await token( - 'wrong-client-web-jwt-secret-at-least-32-bytes' - )}` + const wrongAuthorization = `Bearer ${await token('wrong-web-jwt-secret-at-least-32-bytes')}` const statuses = await page.evaluate( async ({ postgrestUrl, wrongAuthorization }) => { const wrong = await fetch(`${postgrestUrl}peers?select=id`, { @@ -1224,7 +1222,7 @@ test('Web Peer publishes its app identity and preserves a user name', async ({ p }) .toEqual({ name: expect.stringMatching(/^Chrome \d+ · (Linux|macOS|Windows)$/), - application_version: clientVersion, + application_version: appVersion, }) const renamed = await fetch(endpoint, { @@ -1241,7 +1239,7 @@ test('Web Peer publishes its app identity and preserves a user name', async ({ p }) return response.ok ? (await response.json())[0] : null }) - .toEqual({ name: 'My browser Peer', application_version: clientVersion }) + .toEqual({ name: 'My browser Peer', application_version: appVersion }) await page.goto('/') await expect(page).toHaveTitle(/My browser Peer/) } finally { diff --git a/tsconfig.json b/tsconfig.json index 5652ab3e..96d1e649 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -3,7 +3,7 @@ "references": [ { "path": "./packages/core" }, { "path": "./packages/ext-dev-utils" }, - { "path": "./apps/client-web" }, + { "path": "./apps/web" }, { "path": "./extensions/twitter" } ] }