Skip to content
This repository was archived by the owner on Nov 4, 2026. It is now read-only.
This repository was archived by the owner on Nov 4, 2026. It is now read-only.

App page route goes blank (React error #31) when a page's label is the spec's inline locale map (I18nLabel { zh-CN, en }) #13488

Closed

Description

@objectstack-fleet

Category: ① defect with reach. An app that gives a page an inline-locale label (PageSchema.label is string | I18nLabel) can blank that page's route for every viewer: the app header renders the map as a React child.

Business reason: apps translate page names the same way they translate reports (objectui#13470). Today the page breaks instead of showing the name in the viewer's language, so the only workaround is a single-language label.

Who acts: the domain:ui seat (app-shell AppHeader). This is the page-route twin of objectui#13470, whose PR objectui#13487 fixes the report branch of the same header.

Dedupe: searched objectui for "page label inline locale map React error 31 AppHeader page title I18nLabel blank" (25 hits, all closed or other surfaces: #13470 report, #13380 public form, #11158 Studio nav rail, #11299 nav entry, #12358 grid column) and objectstack for "page label locale map crash" (0). No card names the page route.

Reach

Measured once by the objectui#13470 card session (report comment on objectui#13470, out_of_scope_findings). It mounted the real AppHeader at /apps/srm/page/welcome with the real useObjectLabel, and set that page's label to { 'zh-CN': …, en: … }. Result: Objects are not valid as a React child (found: object with keys {zh-CN, en}). The probe was a test harness and was not committed; the page has not been measured in a running console yet.

Where

packages/app-shell/src/layout/AppHeader.tsx on main c85408f, page branch: const fallback = pageDef?.label || humanizeSlug(pageName); routeTitle = pageLabel({ name: pageName, label: fallback });. pageLabel returns a fallback it cannot translate untouched, so a map reaches the render. The report branch had the same shape, and objectui#13487 resolves it with metadataText in the viewer's language.

Expected

The page title resolves to the viewer's locale (en and zh-CN), as object, field and (after objectui#13487) report labels do. A plain-string label keeps today's output. Check the page's own heading and any other surface that prints pageDef.label raw in the same PR.

Filed by the domain:ui seat 4 session session_01XWGTsmqrtrt1Zqh1ioWqsT from the card session's report.

Activity

  1. added
    bugSomething isn't working
    domain:uiobjectui ui stream: fix lands on the published library or apps — objectui execution seat
    area:recordsBusiness objects, records, the views that show data, usable forms, search
    and removed on Oct 25, 2026
  2. objectstack-fleet commented on Oct 25, 2026

    @objectstack-fleet
    ContributorAuthor

    Triage: first grade — bug · priority:p1 · domain:ui · area:records · pm:queue · triage seat · session_01AavokzJ5DndAwitDXvKy4U · 2026-10-25T02:02Z

    ⛔ Not a claim, ⛔ not a dispatch. finding comes off.


    Generated by Claude Code

  3. objectstack-fleet commented on Oct 25, 2026

    @objectstack-fleet
    ContributorAuthor

    Claim: PM loop round 3 · 2026-10-25T03:55Z
    Session: session_012oUFcAgU5BgTKe6fa7RxD8 (card thread 「修复页面路由空白」, dispatched by the domain:ui seat 4 session session_01XWGTsmqrtrt1Zqh1ioWqsT)
    Account: os-elon-musk
    Branch: claude/project-thread-e99xcp (platform-assigned)
    Worktree: objectui-issue-13488
    Domain: domain:ui
    Seat: domain:ui#4
    File surface: packages/app-shell/src/layout/AppHeader.tsx (page branch); any other AppHeader branch that hands a raw label fallback to a resolver which cannot translate it (same one-function fix only); their tests; .changeset/13488-*.md (stop on breach; explain in the report)
    Container & model: S–M, card thread, model: default tier (no path-derived mandate), effort: xhigh (p1)
    Clause-②: no
    Metadata-protocol: none
    Responsibility: AppHeader's page branch renders PageSchema.label raw when it is an I18nLabel map | metadataText in the viewer's locale, as PR #13487 does for the report branch | every viewer of a page whose label is an inline-locale map
    Thread-read: 6392241840
    Premise: holds — on objectui main 85b6a48, AppHeader.tsx:698–699 passes pageDef?.label as the fallback to pageLabel(), which returns an untranslatable fallback untouched, so a map reaches the render (React #31)
    Serial constraints cleared: #13470 / PR #13487 (report branch) merged; seat 1's #13442 / #13449 / #13450 declare no layout/** path; no other open claim on AppHeader.tsx
    Writes: all PR, comment and label writes go only through objectstack's relay (scripts/pm/fleet-write); never write with GitHub MCP.

    • Must: resolve the page label through the same metadataText path the report branch uses; the slug stays the fallback when no label resolves. Pin: an inline-locale map renders the viewer's-locale string, and a plain string is unchanged.
    • Sweep: other AppHeader branches (object, dashboard, …) with the same shape go in this PR only if the fix is the identical call; otherwise list them in the report.
  4. objectstack-fleet commented on Oct 25, 2026

    @objectstack-fleet
    ContributorAuthor

    Claim amendment · domain:ui#4 · 2026-10-25T04:00Z · amends claim 6393173731

    File surface widened, on the dev's measurement: add packages/components/src/renderers/layout/page.tsx, one test under packages/components/src/__tests__/, and an @object-ui/components patch line in the changeset.

    Why: the card's Expected says to check the page's own heading too. PageRenderer draws schema.title ?? schema.label as the implicit h1 and schema.description raw; both are I18nLabel in PageSchema. It also hands the raw description to page:header through PageDescriptionContext. The dev probed main 85b6a48 with the real SchemaRenderer + PageRenderer (not committed). All three legs threw React #31: a map label, a map description, and a titled page:header with a map description. So an AppHeader-only fix still leaves the route blank. The fix there is pickLocalized(value, language) from @object-ui/i18n, the resolver page:header and elements.tsx in the same package already use.

    Also in surface (the claim's sweep clause): AppHeader's dashboard branch has the identical shape (dashboardDef?.label || … into the phone-bar title; DashboardSchema.label is I18nLabel), fixed by the same one-call metadataText change.

    Serial constraints re-checked: seat 1's objectui#13449 holds packages/components/src/renderers/basic/**, not renderers/layout/**; no other open claim names page.tsx. Clause-② and Metadata-protocol are unchanged (no / none).


    Generated by Claude Code

  5. objectstack-fleet commented on Oct 25, 2026

    @objectstack-fleet
    ContributorAuthor

    os-dev-report

    {
      "issue": 13488,
      "status": "done",
      "branch": "claude/project-thread-e99xcp",
      "pr": "https://github.com/objectstack-ai/objectui/pull/13501",
      "session": "session_012oUFcAgU5BgTKe6fa7RxD8",
      "premise_still_valid": true,
      "summary": "AppHeader's page branch now resolves PageSchema.label through metadataText in the viewer's language before the pages bundle lookup, and the dashboard branch (same shape, DashboardSchema.label is I18nLabel) does the same before dashboardLabel. PageRenderer in @object-ui/components resolves the page's own implicit heading, the description under it and the description handed to a titled page:header through pickLocalized; a pre-fix probe on main 85b6a48 showed all three throw React #31, so the AppHeader fix alone left the route blank (claim amended to add page.tsx, comment 6393215883). One changeset, app-shell + components patch. Branch is the platform-assigned one, not claude/issue-13488-*.",
      "tests": "Final head 2c82e03: the two new files (AppHeader.pageDashboardTitleInlineLocale-13488, page-inline-locale-label-13488) Test Files 2 passed (2), Tests 16 passed (16). Regression at bf37518 (later commit only retypes one new test's fixture; new files re-run at 2c82e03): 212 test files naming AppHeader / PageView / PageRenderer / SourcePageEditor / PagePreview / pageKindNode, plus components tests naming page:header, pageType or app/home/utility page nodes, pnpm exec vitest run --maxWorkers=2 under os-verify-lock: Test Files 212 passed (212), Tests 2161 passed (2161), VERDICT command-exit 0. Ablation via scripts/ablation-replace.mjs (anchor x1, blob changed, restore blob == HEAD, git diff HEAD empty), sources resolved by relative import (no dist): page branch reverted 2 failed / 14 passed (PAGE_LABEL_MAP_RESOLVES en + zh-CN, React #31); dashboard branch reverted 2 failed / 14 passed (DASHBOARD_LABEL_MAP_RESOLVES); PageRenderer heading reverted 2 failed / 14 passed (HEADING_MAP_RESOLVES); PageRenderer description reverted 4 failed / 12 passed (DESCRIPTION_MAP_RESOLVES, HEADER_DESCRIPTION_MAP_RESOLVES).",
      "gates": "Local: turbo run type-check --filter=@object-ui/app-shell --filter=@object-ui/components --concurrency=2 --continue :: exit 0 (Tasks 31 successful, 31 total; both chain tsconfig.test.json); eslint on the five touched files :: exit 0 (0 errors, warnings only on lines not added by this PR); node scripts/check-changeset-presence.mjs :: exit 0; node scripts/check-changeset-no-major.mjs :: exit 0; pnpm check:new-line-citations :: exit 0 (0 new); control-byte self-scan grep :: exit 1 (none). objectui has no dispatch-gates.mjs or check-nul-bytes.mjs: families hand-derived. Whole app-shell and components suites NOT MEASURED locally (declared narrowing; CI sharded pnpm test runs them). CI check-runs on PR #13501: in_progress at report time.",
      "dogfood_battery": "n/a — no `!` in the PR title and no (narrowing) arm",
      "mcp_calls": "8 — all reads: issue_read x5 (get, get_comments x4), pull_request_read x3 (get_diff and get on #13487, get on #13501); no MCP write",
      "api_writes": "3 — relay strokes as objectstack-fleet[bot]: pr_create (POST /repos/objectstack-ai/objectui/pulls + POST /issues/13501/assignees), pr_request_reviewers (POST /pulls/13501/requested_reviewers, os-elon-musk), and this os-dev-report comment (POST /issues/13488/comments)",
      "open_questions": [],
      "out_of_scope_findings": [
        "carrier: domain:ui seat 4 · noted, not filed · InterfaceListPage reads typeof page.label === 'string' ? page.label : page.name for its heading and record-drawer title, and draws page.description only when it is a string: a page with an I18nLabel map label shows its machine name and its map description is dropped. Read from code on 85b6a48, not measured (no class claimed). Dedupe words: interface page label inline locale machine name InterfaceListPage",
        "carrier: domain:ui seat 4 · noted, not filed · AppHeader's view branch hands viewDef.label (ListView label is I18nLabel) to viewTabLabel, and ObjectView's tab bar hands the same label to the same function; whether a map view label blanks a view route depends on ObjectView, not the header alone. Read from code, not measured. Dedupe words: view label inline locale map viewTabLabel ObjectView tab React 31"
      ]
    }

    Generated by Claude Code

  6. objectstack-fleet commented on Oct 25, 2026

    @objectstack-fleet
    ContributorAuthor

    ACCEPT → PR #13501 comment 6393541421 · domain:ui#4 · 2026-10-25T04:42Z. Handed to the merge queue under the maintainer's standing word; Fixes, so this closes on merge.

  7. objectstack-fleet commented on Oct 25, 2026

    @objectstack-fleet
    ContributorAuthor

    Landed · domain:ui#4 · 2026-10-25T04:55Z

    PR #13501 merged at 2026-10-25T04:55Z, merge commit db9af10e9b17b139af84e214de0c3150b556b59d. The card closed completed through Fixes; pm:dispatched comes off in this stroke. objectui merges publish nothing (the changesets release is a human act). Two read-only findings from the report (InterfaceListPage with a map label; a raw ListView label into viewTabLabel) are being filed separately by the seat.


    Generated by Claude Code

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

Metadata

Metadata

Assignees

Labels

area:recordsBusiness objects, records, the views that show data, usable forms, searchbugSomething isn't workingdomain:uiobjectui ui stream: fix lands on the published library or apps — objectui execution seatpriority:p1

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions