Skip to content

Commit 4c50ec7

Browse files
docs(skills): objectstack-ui teaches one way to open a record from an object's list; navigation.mode is deprecated there (#35870) (#36302)
<!-- claude-projects-attribution: {"github_login":"os-project-manager"} --> _Requested by **Leehom** · [project thread](https://claude.ai/code/project/chan_01TenzsRopZj4jMbvjX8uz1X?thread=cmsg_01TenzsRopZj4jMbvjX8uz1XC63go34oEMBFaBgqpoDC8N)_ Part of #35870 Clause-②: no Metadata-protocol: none repo:objectstack#4 · os-project-manager · session_01FEkQ5kDGa1ViantgrfH797 `Part of`, not a closing line: this PR is the skills half of the card. The card's other half, the dated add-only note on ADR-0050 §2, is not in this diff (no `docs/adr/**` path); the claim proposes it as a row on the weekly ADR revisions card 36086, and the seat routes it. ## 维护者速读 - 用户能看到什么变化:照着界面技能搭应用的作者和 AI,以前被教「在列表视图上声明整页打开」;现在技能教的是今天的规则:在对象列表里点记录名称进整页,鼠标移到这一行时名称旁的图标从侧边打开,什么都不用声明。 - 为什么做:属于「记录详情页重做」专题的收尾。维护者已裁定列表上的「打开方式」声明废弃,技能还按旧规则教,AI 会写出一个不起作用的设置。 - 出错会怎样:只改技能文字和一条评测用例,不动运行时;写错的话作者读到的是一句不准确的说明,直接撤回这个 PR 即可。 - 要你做什么:无。 ## What changes The source for every new sentence is the spec's own text on `origin/main`: the `[DEPRECATED]` describe of `mode` in `NavigationConfigSchema` (`packages/spec/src/ui/view.zod.ts`) and the ADR-0087 D3 semantic entry `navigation-mode-record-open-deprecated`. Ruling: the maintainer's 「废弃」 on the parent card (comment 7039654214). - `skills/objectstack-ui/rules/record-page.md`, step 5. Was: the drawer unless the object declares `page`, with `navigation: { mode: 'page' }` on the list view as the way to the full page. Now: on an object's list the name opens the page and its hover icon the drawer; `navigation.mode` is deprecated there (`drawer`, `page`, `new_window` change nothing, so omit it); `none` still means rows open nothing (prefer `preventNavigation: true`); a page block's `navigation` honours every value. The `modal` / `split` / `popover` refusal and "A phone always pages" stay. - Same file, step 6. The Display menu's Open records choice and the drawer's ⤢ leave the list of the reader's own choices: the setting and the drawer's full-width state were removed with the same change. The two dragged widths and the `size` bucket stay. - `skills/objectstack-ui/rules/navigation.md`, the Surface bullet of Record Presentation. Was: "A clicked record opens in the drawer, which expands to the full page; `page` only by declaration". Now the same one rule, pointing at Record Page steps 5 and 6. - `skills/objectstack-ui/evals/README.md`: the `record-page.json` summary line names the new rule. - `skills/objectstack-ui/SKILL.md` (rework round, contract review 7074880702 S1 and N3). Principle 5 was: "how a record opens is one list-view key". Now: how a record opens from an object's list is not authored (the name opens the page, its hover icon the drawer); the reader's-own-choices clause and the Record Page link stay. The Where-to-go row "drawer or page" now reads "how a record opens". - `.changeset/35870-navigation-mode-skills.md`: `@objectstack/skills` patch. Left as is, measured: - `skills/objectstack-ui/references/react-blocks.md` line 61 (`navigation` on the `ListView` block of a `kind: 'react'` page) and `rules/pages.md` line 218 (`navigation={{ mode: 'none' }}` on a block): a page block still honours every value of the key, so neither teaches the retired meaning. `react-blocks.md` is generator-owned. ## Evals `skills/objectstack-ui/evals/record-page.json`, case 2 only; id and prompt unchanged ("Contracts should open as a full page, not the side drawer. Reps also keep asking for records to open beside the list"). - `expected_output`: nothing to author. The record's name opens the full page and the hover icon beside it opens the drawer over the list; `navigation.mode` is deprecated on an object's list, so the contract list view declares neither `page` nor `drawer`; a pane beside the list is not offered (`split`, `modal`, `popover` are refused). - `must_contain`: `navigation: { mode: 'page' }` and `Display menu` are replaced by `icon`, the one word an answer that knows the rule has to use and that the bundle teaches ("hover icon"). - `must_not_contain`: adds the two code spellings of the declaration, `mode: 'page' },` and `mode: 'page',`, following the file's own convention for a forbidden declaration (cases 1 and 5 forbid a key with its trailing comma or brace), so an answer that names the key as the thing to omit is not failed. The three retired values and `definePage(` stay. No eval round was run (a round is the eval seat's). Both token lists changed, so earlier records of this case are set apart on a regrade. ## Tests Round-one readings below are at head `a48596646`, merge base `76cb36661`. Rework head `f65f4181d` (SKILL.md and the changeset only): token ratchet exit 0, `skills/objectstack-ui/SKILL.md` 2186 tokens (ceiling 2272), no ceiling row moved; `dispatch-gates.mjs --ran`: 50 derived, 48 run, 2 NOT MEASURED (whole-workspace build), 0 UNRUN; overlap-check clean against `8925d5bcb`. No eval file moved after `a48596646`, where the skill-evals test passed 38 of 38. Rework report: card comment 7075067101. <details><summary>Token ratchet, size and line budget</summary> - `node scripts/check-skills-token-ratchet.mjs`: exit 0. `skills/objectstack-ui/rules/record-page.md is 988 tokens (ceiling 991; headroom 3)`; `skills/objectstack-ui/rules/navigation.md is 2554 tokens (ceiling 2564; headroom 10)`. No ceiling row moved. - `rules/record-page.md`: 64 lines before and after; 3951 to 3952 bytes; 988 tokens before and after. The added sentences are paid in the same file by the removed `mode: 'page'` sentence, the step 5 aside "(always the standard page)" (step 4 already says the drawer draws the standard page) and the two step 6 items. - `rules/navigation.md`: 191 lines before and after; 10219 to 10216 bytes; 2555 to 2554 tokens. - `evals/README.md`: 54 lines before and after; 637 to 636 tokens. `evals/record-page.json`: 117 to 118 lines; 1834 to 1826 tokens. - Every `SKILL.md` summed: 4947 lines before and after (none touched). Bundle total 289859 to 289849 tokens; ratcheted authored total 197477 to 197476; eval fixtures 77775 to 77766. - PR net added lines (`git diff --shortstat` against the merge base, changeset included): 27 added, 13 deleted, net +14. Budget 20. </details> <details><summary>Gates run locally</summary> - Derived list (`node scripts/pm/dispatch-gates.mjs --commands`, 47 commands), each run under `scripts/pm/os-verify-lock.sh`, each exit code captured before any pipe: 43 exit 0. `check:doc-formula-expressions` first answered exit 3 (prerequisite), and exit 0 after `turbo run build` of `@objectstack/formula` and `@objectstack/lint`. - `node scripts/pm/dispatch-gates.mjs --ran`: `47 derived, 43 run, 4 NOT-MEASURED, 0 UNRUN`. NOT MEASURED, exit 3 `PREREQUISITE NOT MET`, each asks for a whole-workspace `pnpm build` and reads built `dist/` trees this diff cannot move (declared narrowing, left to CI): `check:dts-closure`, `check:dual-build-cjs-loads`, `check:lean-entry-closure`, `check:sourcemap-no-sources-content`. - `pnpm --filter @objectstack/scenarios exec vitest run --maxWorkers=2 test/skill-evals/skill-evals.test.ts`, after building that package's dependency closure: `Test Files 1 passed (1)`, `Tests 38 passed (38)`, lock verdict `command-exit 0`. The first attempt, before the closure build, loaded no test (unresolved workspace entry): not a reading. - `pnpm --filter @objectstack/scenarios run skill-evals --dry-run --skills objectstack-ui`: exit 0, `objectstack-ui: 47 case(s)`, no case refused, `dry run: no login read, no model called, nothing written`. - Outside the derived list, run because a changed path sits in their roster directory: `pnpm check:changeset-fixed` exit 0, `pnpm check:skill-top-level-keys` exit 0. - NOT MEASURED: `pnpm --filter @objectstack/spec run check:skill-examples`, exit 3 (prerequisite); outside the derived list, and the fenced example blocks of both rule files are byte-identical to the merge base. - `node scripts/pm/overlap-check.mjs --branch=claude/issue-35870-navigation-mode-skills` against `origin/main` `b57f778b1`: `VERDICT clean exit 0`, 0 PR heads share a file. </details> No ablation: the diff changes prose and an eval fixture, no tested behaviour. ## Acceptance notes - The claim's file surface lists four skills files and a changeset. `rules/navigation.md` is added to it: its Surface bullet taught the same retired rule ("`page` only by declaration") and the card's grep words do not reach it. `references/react-blocks.md` is on the claim's list as "measure" and is unchanged. - Step 5 and the eval say "drawer" where the spec describe says "side panel": the rest of the rule file (steps 4 and 6) already calls that surface the drawer, and the `size` describe in the same schema does too. - `openNewTab: true` (the spec's replacement for a list that declared `new_window`) is not taught here: the bundle never taught `new_window` on a list, and the `mode` describe this text follows does not carry it. Noted, not filed. - `ui/packages/app-shell/src/views/objectViewRecordNavigation.ts` line 34: a doc comment still names the reader's Open records preference, which no longer exists. A comment, noted, not filed. - `ui/scripts/check-skill-eval-tokens.mjs` lists no row for `skills/objectstack-ui` (its bundle root is `skills/objectui`), so no gate holds this bundle's `must_contain` tokens to its own markdown; checked by hand here (`icon` is taught in `rules/record-page.md` step 5). An observation, noted, not filed. - The ADR-0050 §2 note: carrier is the weekly ADR revisions card 36086 (see top). ## Verification Read first, by risk: 1. `skills/objectstack-ui/rules/record-page.md`, the step 5 hunk: every clause against the `[DEPRECATED]` describe of `mode` in `packages/spec/src/ui/view.zod.ts`. 2. `skills/objectstack-ui/evals/record-page.json`, case 2: the single `must_contain` token and the two forbidden code spellings. 3. `skills/objectstack-ui/rules/navigation.md`, the Surface bullet: the one hunk outside the claim's file list. Two-minute check: `git grep -n "mode: 'page'" -- skills/objectstack-ui/rules skills/objectstack-ui/evals` prints two lines, both in `evals/record-page.json` under case 2's `must_not_contain`; no rule file teaches the declaration. --- _Generated by [Claude Code](https://claude.ai/code/session_01FEkQ5kDGa1ViantgrfH797)_ <!-- signed: repo:objectstack#4 · os-project-manager · session_01FEkQ5kDGa1ViantgrfH797 --> --------- Co-authored-by: Claude <noreply@anthropic.com>
1 parent e100a37 commit 4c50ec7

6 files changed

Lines changed: 31 additions & 15 deletions

File tree

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
'@objectstack/skills': patch
3+
---
4+
5+
Clause-②: no
6+
Metadata-protocol: none
7+
8+
The `objectstack-ui` skill teaches how an object's list opens a record after `navigation.mode` was deprecated there:
9+
10+
- Record-page rule, step 5: on an object's list the record's name opens the full page and the hover icon beside it opens the drawer. `navigation.mode` is deprecated there: `drawer`, `page` and `new_window` change nothing, so the key is omitted; `none` still means rows open nothing (prefer `preventNavigation: true`); a page block's `navigation` still honours every value. The step no longer teaches `navigation: { mode: 'page' }` as the way to open the full page.
11+
- Step 6 no longer lists the Display menu's Open records choice or the drawer's full-width state among the reader's own choices: both were removed.
12+
- The navigation rule's Surface bullet states the same rule in place of "`page` only by declaration".
13+
- `SKILL.md` principle 5 says how a record opens from an object's list is not authored, in place of "one list-view key"; its Where-to-go row for the record page no longer reads "drawer or page".
14+
- Eval `record-page` case 2 ("open contracts as a full page, and beside the list") now expects nothing to be authored: it requires the answer to name the icon and forbids a `mode: 'page'` declaration. The case has a new hash, so `skill-evals --regrade` sets it apart from a round recorded before this change.

‎skills/objectstack-ui/SKILL.md‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,8 @@ Two more: [List Views](#list-views), [Actions](#actions).
6565
must never be what keeps a user from someone else's data.
6666
5. **The object declares its record page.** Related lists, their order and
6767
filter are flags on the object and its fields, not a page file; how a record
68-
opens is one list-view key, and the reader's own display choices are never
68+
opens from an object's list is not authored (the name opens the page, its
69+
hover icon the drawer), and the reader's own display choices are never
6970
metadata ([Record Page](./rules/record-page.md)).
7071

7172
## Where to go
@@ -75,7 +76,7 @@ Two more: [List Views](#list-views), [Actions](#actions).
7576
| A list, board, calendar, gallery or gantt: columns, `filter`, quick filters, toolbar search, sorting, grouping | `src/views/*.view.ts` | [List Views](./rules/list-views.md) |
7677
| A form (`simple` / `tabbed` / `wizard`): width, columns and `sections`; master-detail (a parent with line items), a public form, field conditional rules | `src/views/*.view.ts` | [Form Views](./rules/list-views.md#form-views) |
7778
| An app and its navigation; who sees or opens it; object nav, a `filters` slice or an interface page | `src/apps/*.app.ts` | [Navigation](./rules/navigation.md) |
78-
| What a record page shows: related lists, a slotted or full page, drawer or page | the object | [Record Page](./rules/record-page.md) |
79+
| What a record page shows: related lists, a slotted or full page; how a record opens | the object | [Record Page](./rules/record-page.md) |
7980
| A button or operation: `locations`, visibility, dialog and toast copy, params, new tab, the body's `ctx`, refusing by code (`refusals`) | `src/actions/*.action.ts`, `*.actions.ts` | [Actions](./rules/actions.md) |
8081
| A number, chart, KPI or report over records: datasets, widgets, dashboard filters, `compareTo`, date bucketing, drilldown, cubes | `src/datasets/*.dataset.ts`, `src/dashboards/*.dashboard.ts`, `src/reports/*.report.ts` | [Dashboards](./rules/dashboards.md) |
8182
| A page (regions, components, print, `kind: 'html'` / `'react'` source, styling) or package docs | `*.page.ts`, `src/docs/*.md` | [Pages & Docs](./rules/pages.md) |

‎skills/objectstack-ui/evals/README.md‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ view / page / dashboard / report metadata.
1515
put first, and the attachments tab removed, by the parent's `relatedLists`
1616
naming every tab it keeps (no page file); a field placed in its group's
1717
own `fields`; a child table placed between field sections by a group's
18-
`relatedList`; `navigation: { mode: 'page' }` on the list view with the
19-
reader's own open choice left out of metadata; and `placedActions: true`
18+
`relatedList`; an object's list opening a record one way, with the
19+
deprecated `navigation.mode` left unauthored; and `placedActions: true`
2020
on a full page's `page:header` so packaged header actions draw without an
2121
id list.
2222
- `report-period-export.json` — a non-`joined` report's `dateRange` (one

‎skills/objectstack-ui/evals/record-page.json‎

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,14 +25,15 @@
2525
{
2626
"id": 2,
2727
"prompt": "Contracts should open as a full page, not the side drawer. Reps also keep asking for records to open beside the list — add that to the contract object too.",
28-
"expected_output": "One declaration: `navigation: { mode: 'page' }` on the contract list view. A pane beside the list is no longer offered: the split pane is retired. How a record opens is each reader's own choice in the list's Display menu (Open records: drawer, the default, or full page), kept in the browser and offered for drawer-mode objects only, so nothing is authored for it; `split`, `modal` and `popover` were removed in @objectstack/spec 18.3.0 and are refused.",
28+
"expected_output": "Nothing to author. On an object's list the record's name opens the full page and the hover icon beside it opens the drawer over the list, for every reader. `navigation.mode` is deprecated there: `page` and `drawer` still parse and change nothing, so the contract list view declares neither. A pane beside the list is not offered: `split`, `modal` and `popover` were removed in @objectstack/spec 18.3.0 and are refused.",
2929
"files": [],
3030
"assertions": {
3131
"must_contain": [
32-
"navigation: { mode: 'page' }",
33-
"Display menu"
32+
"icon"
3433
],
3534
"must_not_contain": [
35+
"mode: 'page' },",
36+
"mode: 'page',",
3637
"mode: 'split'",
3738
"mode: 'modal'",
3839
"mode: 'popover'",

‎skills/objectstack-ui/rules/navigation.md‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -167,8 +167,8 @@ at runtime from the client viewport, because an author
167167
(especially an AI) cannot know the client's screen. **Write the data (fields,
168168
`fieldGroups`); let the platform lay it out.**
169169

170-
- **Surface.** A clicked record opens in the **drawer**, which expands to the full
171-
page; `page` only by declaration ([Record Page](./record-page.md) §5–6). Create /
170+
- **Surface.** On an object's list the record's name opens the **page**, the
171+
hover icon beside it the **drawer** ([Record Page](./record-page.md) §5–6). Create /
172172
edit opens in a **modal**, or the full-page route when the object declares `editMode: 'page'`.
173173
- **Field width.** **Omit it** (`auto` sizes by widget type × current columns —
174174
textarea / rich-text / file take the row). Both keys are valid: `colSpan`

‎skills/objectstack-ui/rules/record-page.md‎

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -40,15 +40,15 @@ A phone and the drawer draw the standard page (steps 1–3); no key keeps a full
4040
there, only a page named in the URL (a print page) draws everywhere. The standard page
4141
draws no `record_section` action: one that must show there also lists `record_more`.
4242

43-
**5 · The drawer, unless the object declares `page`.** A clicked row opens the
44-
record in the drawer (always the standard page), which expands to the full page;
45-
`navigation: { mode: 'page' }` on the object's list view opens it as the full page;
43+
**5 · On an object's list the name opens the page, its hover icon the drawer.**
44+
`navigation.mode` is deprecated there: `drawer`, `page`, `new_window` change
45+
nothing, so omit it; `none` still means rows open nothing (prefer
46+
`preventNavigation: true`); a page block's `navigation` honours every value;
4647
`modal` / `split` / `popover` are refused with their fix. A phone always pages.
4748

4849
**6 · The reader's own choices are not metadata.** ⛔ Never author these: the
49-
Display menu's **Open records**, the
50-
tabs' order and hidden set (per user × object), the details column's dragged width,
51-
the drawer's dragged width and ⤢. On `navigation` only the `size`
50+
tabs' order and hidden set (per user × object), the details column's and the
51+
drawer's dragged widths. On `navigation` only the `size`
5252
bucket (`sm`…`full`) nudges the drawer's starting width.
5353

5454
<!-- os:check -->

0 commit comments

Comments
 (0)