You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 3ab9136
Browse filesBrowse the repository at this point in the historyBrowse files
fix(studio): the landing page names the .custom customization route, not the environment overlay (#29537)
<!-- claude-projects-attribution: {"github_login":"zhuangjianguo"} -->
_Requested by **Steedos** · [project
thread](https://claude.ai/code/project/chan_018ETKaNwMZCNRYD7D8Q9Ubb?thread=cmsg_018ETKaNwMZCNRYD7D8Q9UbbBNo2iwVzPjRLwtsGTXAWgt)_Fixes#29489
Clause-②: no
Metadata-protocol: none
The two lines are copied from the claim (comment 6583617139).
## 维护者速读
- 改了什么:Studio 首页(App
Builder)的页面说明和"已安装(只读)"区的提示语,英文与中文两份,不再叫用户"用环境覆盖定制"只读包,改为指向现有路径:打开条目,用「自定义」或「新建类似」,修改存进该包配对的
.custom 定制包,升级仍到达已安装的包。
- 为什么改:ADR-0146 D11 之后,不带包的写入落到已打包条目会被 403 NOT_OVERRIDABLE 拒绝并点名 .custom
配对包;首页教的第一条路正是被拒的那条。
- 风险与回滚:只改两个文案值(en、zh)和 BuilderLanding.tsx 里两段注释,不加不删键,没有行为改动。回滚即撤销本 PR。
- 先看:`ui/packages/i18n/src/namespaces/studio/en.ts` 的
`engine.studio.landing.description` 与
`engine.studio.landing.readonlyHint`;重钉的
`BuilderLanding.environmentOverlayCopy-12171.test.ts`;新测试
`BuilderLanding.customizeCopy-29489.test.tsx`。
- 两分钟验证:`pnpm --dir ui exec vitest run
packages/app-shell/src/views/studio-design/BuilderLanding.customizeCopy-29489.test.tsx
packages/app-shell/src/views/studio-design/BuilderLanding.environmentOverlayCopy-12171.test.ts`,预期
6 个用例全过(换回 main 的文案时其中 3 个转红)。
- 需要你做的:无,席位落地。
## What changes
- **`engine.studio.landing.description`** (en, zh): the page
description's last clause said read-only packages are customized "with
an environment overlay". It now says their items are changed with
Customize or New similar, which save into the package's `.custom`
customization package.
- **`engine.studio.landing.readonlyHint`** (en, zh): the read-only
section's hint said "Customize one with an environment overlay, for the
metadata types that accept one". It now says: open an item and choose
Customize or New similar; the change is saved in the package's `.custom`
customization package, and upgrades keep reaching the installed package.
The comment above the en row names the routes that exist now.
- **`BuilderLanding.tsx`**: two code comments that still described a
read-only package as customized by environment overlay now name its
`.custom` pair. Comments only; no code changes.
- The words are the tables' own: the Customize and New similar action
labels (`engine.studio.customize.action`,
`engine.studio.auto.newSimilar.action`; zh 「自定义」, 「新建类似」), and zh 定制包 as
in the landing's existing customization-package strings. No key is added
or removed.
- **Where the keys live:** only in the Studio namespace tables
(`ui/packages/i18n/src/namespaces/studio/en.ts` and `zh.ts`). None of
the ten `locales/*.ts` packs carries `engine.studio.landing.*`, so the
locale-pack parity tests do not read them, and only en and zh change.
## Tests
- **Re-pinned `BuilderLanding.environmentOverlayCopy-12171.test.ts`.**
Same population (every designer table `readDesignerPairs` reads that
carries the keys) and same reader control. The org-axis pin still covers
all three keys. The pin that required every value to name the
environment overlay is split: the two landing keys must name no
environment overlay / 环境覆盖, and must name the `.custom` package and the
table's own Customize label; `perm.readOnly.artifact.hint` keeps its
environment-overlay assertion, which is now the matcher's lit control
(that hint names the overlay because it says the overlay is refused).
- **New `BuilderLanding.customizeCopy-29489.test.tsx`.** Renders the
real `BuilderLanding` with a read-only package in en and in zh (through
`I18nProvider`, the zh studio catalogue preloaded at module scope). It
reads the description and the hint off the page, checks they are the
tables' rows, and checks each names `.custom`, Customize and New
similar, with no overlay phrase.
- **Red on main:** with both tables restored to the main blob (`git
restore --source=c88467d4`, mutation counted on disk: old en phrase 1,
old zh phrase 1, new en phrase 0), 3 cases go red: the 12171 landing pin
and both 29489 locale cases. Restored with `git checkout HEAD --`, `git
diff HEAD` empty, both blob hashes equal HEAD.
## Acceptance notes
- **Does any metadata type still take a package-less environment
overlay?** Not as a route the landing can offer. Read on `main`
c88467d: `packagelessCloseSubject`
(`packages/metadata-protocol/src/protocol-packageless-overlay-migration.ts`)
closes the package-less save, publish, delete and rollback onto an item
one read-only code package ships, wherever `os migrate
packageless-overlays` could move its row, with `403 NOT_OVERRIDABLE`
naming the pair (`packagelessOverlayWriteRefusal`). It stays open only
for rows that ceremony leaves: an item more than one package ships, a
base with no pair id, a stored row declaring a foreign override or
shadowed by the pair, an `email_template` locale the base does not ship,
or a base that records no version. A package-less row for a name no
read-only package ships is environment metadata, not an overlay. The pin
is the `metadata-protocol` suite "an item a CODE package ships: the
package-less write is closed (ADR-0146 D11)" in
`protocol.packageless-save-address.test.ts`. Not confirmed live on a
running server.
- **Noted, not changed:** `view` and `dashboard` (and `report`,
`translation`, `email_template`) still declare `allowEnvironmentOverlay:
true` in `DEFAULT_METADATA_TYPE_REGISTRY`
(`packages/spec/src/kernel/metadata-plugin.zod.ts`). On the write, the
D11 close wins: ADR-0146 D11 keeps the flag as the predicate the
migration reads and the read path honours for an unmigrated row, not as
a write door. The spec stays off this PR.
- **Noted, not changed:** `engine.studio.pkg.readonlyLink` ("Read-only ·
Customize with an overlay", zh 「只读 · 用覆盖定制」) is no longer rendered
anywhere; only `StudioReadOnlyLink.overlay-27356.test.tsx` reads it, as
the label that must be absent. It is a dead row teaching the closed
route, invisible to users, and outside this card's surface.
- Docs and the turned-off sentence are #29374's and are untouched here.
## Verification
All on head f1c366f (base c88467d), in worktree
`objectstack-issue-29489`.
<details><summary>Tests</summary>
- `pnpm --dir ui exec vitest run --maxWorkers=2` over the 2 touched test
files: 2 files, 6 tests passed.
- The same, over every app-shell and console test naming
`BuilderLanding`, `studio.landing`, `readDesignerPairs` or
`zh-base-term` (37 files, including `zh-base-term.i18n-13131.test.ts`
and the `StudioRoute.*` console tests), plus `packages/i18n/`: 132 files
passed, 1706 tests passed, 13 skipped.
- `pnpm --dir ui exec vitest run scripts/`: 169 files passed, 2 skipped;
4921 tests passed.
- `pnpm exec turbo run type-check --filter=@object-ui/app-shell
--filter=@object-ui/i18n`: 66 of 66 tasks successful (app-shell runs
`tsc --noEmit` and `tsc -p tsconfig.test.json`).
- `pnpm exec eslint` over the five touched ui files: exit 0.
</details>
<details><summary>Gates</summary>
- `node scripts/pm/dispatch-gates.mjs --commands`: 34 derived families.
All 34 ran and exited 0, including `check-sdui-manifest.mjs` and its
`--self-test`, `check-changeset-no-major`,
`check-adr-0087-registration`, `check-closing-keyword-parity`,
`check-empty-changeset`, `check:published-files` and
`check:cross-package-test-inputs`.
- `dispatch-gates --ran`: 34 derived, 34 run, 0 NOT-MEASURED, 0 UNRUN.
- `pnpm --dir ui check:new-line-citations`: 0 new citations.
- Dogfood battery: n/a, because there is no `!` in the title and no
(narrowing) arm.
</details>
---
_Generated by [Claude
Code](https://claude.ai/code/session_01QsR2jTSExv2so3yrUvy5Qz)_
Co-authored-by: Claude <noreply@anthropic.com>
fix(i18n): the Studio landing page tells users to customize a read-only package in its `.custom` customization package, not with an environment overlay
6
+
7
+
Clause-②: no
8
+
Metadata-protocol: none
9
+
10
+
The App Builder landing page's description (`engine.studio.landing.description`) and its read-only section hint (`engine.studio.landing.readonlyHint`) told users to customize a code or installed package "with an environment overlay". A write naming no package onto an item a read-only package ships is now refused with `403 NOT_OVERRIDABLE`, and the refusal names the package's `.custom` pair. Both strings, in English and Chinese, now name the route that is open: open an item and choose Customize or New similar; the change is saved in the package's `.custom` customization package, and upgrades keep reaching the installed package.
11
+
12
+
Only the two values change. No key is added or removed, and nothing else on the page changes.
'Saved as a draft in this deployment’s customization of {baseName}, and opened on the canvas. The navigation of {baseName} stays as it was installed.',
3235
3235
'engine.studio.app.scaffoldNav': "Add this package's objects as menu items",
3236
3236
'engine.studio.landing.title': 'App Builder',
3237
-
'engine.studio.landing.description': 'Design objects, forms, automations and interfaces inside a writable package; edits save as drafts and the whole package publishes in one release. Code and installed packages are read-only: browse them here, and customize them with an environment overlay.',
3237
+
'engine.studio.landing.description': 'Design objects, forms, automations and interfaces inside a writable package; edits save as drafts and the whole package publishes in one release. Code and installed packages are read-only: browse them here, and change their items with Customize or New similar, which save into the package’s .custom customization package.',
// objectui#11808 — the routes a read-only package does have (ADR-0070 D2,
3249
-
// ADR-0005): an environment overlay, and the marketplace where the runtime has one.
3250
-
'engine.studio.landing.readonlyHint': 'Code and installed packages are read-only, so they are not edited or duplicated here. Customize one with an environment overlay, for the metadata types that accept one.',
3248
+
// The routes a read-only package does have (objectstack ADR-0146 D2, D3, D11):
3249
+
// Customize or New similar into its paired `.custom` package, and the
3250
+
// marketplace where the runtime has one. A package-less overlay is not one.
3251
+
'engine.studio.landing.readonlyHint': 'Code and installed packages are read-only, so they are not edited or duplicated here. To change one, open an item and choose Customize or New similar: the change is saved in the package’s .custom customization package, and upgrades keep reaching the installed package.',
3251
3252
'engine.studio.landing.marketplace': 'Or install a template app from the marketplace',
3252
3253
// ADR-0146 D3 — a read-only base's card says what this deployment changed on
3253
3254
// it, from the server's per-package customization read.
0 commit comments