Skip to content

spec(ui): the react-tier ListView onNavigate declaration says (recordId, action: 'view' | 'edit') while every reference call site sends 'view' or 'new_window' and never 'edit' — the mode union becomes 'view' | 'new_window' (objectui#9547 ruling C: protocol first) #19057

Description

@hotlong

Filed by the director seat (objectstack #12708, summon #24, session_01Wj1HUjzyeiBQ8atRf1ZhaL) executing decision batch #166 item 1 — maintainer 「同意」 to C on objectui#9547: the false sentence is in the protocol, so the protocol is corrected first and objectui's four faces align after.

The reading (objectui seat 3, 5730004939, verified at source)

  • packages/spec/src/ui/react-blocks.ts:321 declares { name: 'onNavigate', type: "(recordId, action: 'view' | 'edit') => void", kind: 'callback', … }.
  • The reference implementation's four call sites (objectui packages/react/src/hooks/useNavigationOverlay.ts, :314 / :337 among them) emit 'view' and 'new_window' (Cmd-click opens a new window); 'edit' is never sent.
  • The second argument is a navigation-MODE token with a closed vocabulary — the protocol's own retirement note for view.list.navigation.view (packages/spec/src/ui/view.zod.ts:1815-1822, removed in 17.5.0) says so verbatim: 「the navigation-MODE argument of the console's onNavigate, where anything other than edit or view matched no branch」. The authored view name that flows into that slot on objectui's current pin (17.4.0) is the retired defect, not a member of the vocabulary.

What lands

  1. react-blocks.ts:321: action: 'view' | 'new_window'edit is dropped (no branch sends it, no branch reads it); the docblock names the two modes and says the slot is closed.
  2. If the literal string is pinned anywhere (the seat did not measure this), the pin moves with it.
  3. Reference page regenerated; changeset @objectstack/spec minor with the note that a declared value nobody emitted is removed and one that two call sites emit is added; Clause-②: yes (published declaration moves) — spec-lane review at tier.

Downstream

objectui#9547 (pm:blocked on this card + objectui's bump to @objectstack/spec ≥ 17.5.0): ObjectGridComponentProps.onNavigate is declared with the same closed union, and the three sibling faces (ObjectGridSchema.onNavigate, ListViewRuntimeProps.onNavigate, UseNavigationOverlayOptions.onNavigate) say the same sentence in one pass; the live navigation.view consumer at useNavigationOverlay.ts:275 goes with the bump (objectui#9667 covers the parity pin, not that consumer — the seat files or folds it).

Refs

objectui#9547 (ruling) · objectui#9667 · ADR-0049 (the navigation.view retirement)

Dedup terms: onNavigate react-blocks ListView action union new_window, navigation mode token closed vocabulary


Generated by Claude Code

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions