This repository was archived by the owner on Nov 4, 2026. It is now read-only.
Repository navigation
docs(app-shell): DashboardView's header comment stops attributing title to the spec - #7520
Merged
Merged
Conversation
…tle` to the spec
The block over the header title fallback claimed "Per @objectstack/spec,
`DashboardSchema.title` is 'the dashboard title displayed in the header'".
Measured on the installed `@objectstack/spec@17.2.0`, `DashboardSchema` refuses
`title` BY NAME — `unrecognized_keys(title)` at the document root, against a
spec-legal control (`{ name, label, widgets }`) that parses — and its 20 keys
spell the display name `label`. `header` declares `showTitle` /
`showDescription` / `actions` only, so it toggles a title and never carries one
(`{ header: { title } }` is refused as `unrecognized_keys(title)@header`).
The wording made `title` read as authorable dashboard metadata, which is the
expensive way to learn it is not: the save route refuses the whole body with
`422 INVALID_METADATA` / `unrecognized_keys` before persistence, so an author
following the comment gets a rejected document and no header. The replacement
says what `title` actually is — the legacy objectui spelling, the same
legacy-then-canonical pair `DashboardRenderer` reads — and states the 422,
which is the fact the next reader needs.
It also corrects a second reading the old block invited: `previewSchema` is not
a host-supplied preview channel. `DashboardView` takes no such prop; the value
is the view's own widget-pruned copy of `dashboard`, so both arms of
`headerSrc` read the same stored document.
Comment-only: no type, schema, export or runtime path is touched, hence an
empty-frontmatter changeset.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01EMrWaQw3XS5DxTHxp4yRyC
Contributor
✅ Console Performance Budget
The eager closure is every chunk the entry reaches through static imports — what the browser fetches and parses before the app renders. The entry chunk on its own is a small fraction of it. 📦 Bundle Size Report
Size Limits
|
os-project-manager
marked this pull request as ready for review
September 3, 2026 16:38
os-project-manager
deleted the
claude/issue-7509-dashboard-title-claim
branch
September 3, 2026 16:59
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Refs #7509 — deliberately not a closing reference. The card asked for two things; only the first is delivered here, because the census it asked for came back zero in-repo suppliers, which turns the second into a behaviour change and therefore a maintainer call.
1. What landed: the comment correction (zero risk)
packages/app-shell/src/views/DashboardView.tsxclaimed:Replaced with a block that states what
titleis (the legacy objectui spelling), that the spec refuses it by name, and — the fact the next reader actually needs — that authoring it earns a422 INVALID_METADATA/unrecognized_keysfrom the save route before persistence, not a header. It also corrects a second misreading the old block invited, on which more below.No type, schema, export or runtime path is touched. The
.changesethas empty frontmatter — declared as releasing nothing, the repo's explicit exemption.2. Spec readings, re-measured on this branch
@objectstack/spec@17.2.0, resolved from this worktree'snode_modules, viaDashboardSchema.safeParse:{ name, label, widgets }{ …control, title: "T" }unrecognized_keys(title)@root{ …control, header: { title: "T" } }unrecognized_keys(title)@header20 keys,
labelamong them,titlenot:_lock, _lockDocsUrl, _lockReason, _lockSource, _packageId, _packageVersion, _provenance, aria, columns, dateRange, description, gap, globalFilters, header, label, name, performance, protection, refreshInterval, widgets.headerdeclaresshowTitle/showDescription/actionsonly — it toggles a title, it never carries one.The card's readings reproduce exactly. Note the control matters: the card's "control (no title) ACCEPT" only holds when
labelis present, sincelabelis required — a bare{ name, widgets }control fails onlabel, not ontitle, and would have read as a false positive.3. The census the card asked for
Every probe below is a declaration/AST-shaped query, not a bare word count, and every zero is reported next to a control that lit in the same run.
3a. Supply — who puts a root
titleon a dashboard?title*.json, structural walk for a dashboard-shaped node (has awidgetsarray)*.ts/*.tsx, TS-AST object literals with awidgetsarray initializerlabel8,name21, same probetitlemember anywhere in the treedocument.title,out.titlein chart normalizers,this.schema.titlein the builder)X.label = …lit at 20 sitesTriaging the hits:
examples/schema-catalog/src/schemas/plugin-dashboard/filtered-dashboard*.json. They are objectui component schemas (type: "dashboard", noname), consumed bySchemaRenderer→DashboardRenderer. They never reachDashboardView, which resolves dashboards bynameout ofuseMetadata().dashboards.DashboardConfigSchema, objectui's ownDashboardConfig, not the document). The two remaining non-test hits:packages/plugin-dashboard/src/index.tsx:350—defaultPropsfor thedashboard-gridcomponent registration, not a document.packages/plugin-designer/src/pages/DashboardDesignPage.tsx:39— a seed literal{ type, name, title, columns, widgets: [] }, reachable only on the!dashboardbranch, and that branch early-returns "not found" without ever callinghandleChange/saveSchema. It cannot persist.packages/app-shell/src/views/metadata-admin/dashboard-schema.ts, derives its whole form from specDashboardSchemaviaz.toJSONSchema, and nameslabel"dashboard display name rendered as a dedicated control". It structurally cannot emittitle.Result: zero in-repo suppliers of a root
titleon a dashboard document.3b. Read points of a dashboard-root
titleTS-AST census of every
expr.title/expr['title']read in non-test source: 436 sites, of which 5 have a dashboard-root receiver (the rest are widget-, card-, item- and unrelated-component-level; the receiver grouping is what separates them):packages/app-shell/src/views/DashboardView.tsx:178headerSrc.title— this cardpackages/plugin-dashboard/src/DashboardRenderer.tsx:947schema.title || schema.label— its comment is already accurate, callingtitle"the legacy objectui spelling"packages/plugin-dashboard/src/DashboardGridLayout.tsx:394schema.title || pickLocalized(schema.label) || 'Dashboard'packages/plugin-designer/src/DashboardEditor.tsx:467packages/plugin-designer/src/pages/DashboardDesignPage.tsx:138(dashboard as any).label || (dashboard as any).titleSo the arm this card is about is one of five, and it is the only one whose comment got the attribution wrong.
3c. Fixtures
DashboardViewhas exactly one test file,packages/app-shell/src/views/DashboardView.modalTarget.test.tsx. Its dashboard fixture is{ name: 'sales_overview', label: 'Sales Overview', widgets: [] }— notitle(control:labellit in that file at:91). No test anywhere pinsDashboardView'stitlearm.4. The card's premise, corrected on one point
The card reasons that "the fallback chain still works for a host that passes a
previewSchemacarryingtitle". There is no such host channel.DashboardViewtakes one prop,dataSource;previewSchemais auseMemolocal to this view (lines 129-142) producing a widget-pruned copy ofdashboard. SoheaderSrc.titleisdashboard.titlein every case — a key on the storedsys_dashboarddocument, which is exactly the surface the spec refuses. The new comment says so, since the old one is what invited the reading.This does not weaken the card; it sharpens it. The
titlearm is not "preview-only", it is legacy-document-only.5. Why disposition 2 is not in this PR
With zero in-repo suppliers, deleting the
titleread arm and its fallback stops being a comment fix and becomes a behaviour change on documents this repo cannot see: dashboard documents are served by the platform, andDashboardRenderer's comment dates the spelling to framework#1878 / #1891, so legacy stored documents carryingtitleare the population at risk. The same-class precedents the card names, #5830 and #5852, were both retirements of keys that nothing read; this one is read at five sites. That difference is the maintainer's call, not mine, so the card stays open and this PR does not close it.Verification
Union re-run on the final commit
90abd60c:pnpm --filter '@object-ui/app-shell^...' buildpnpm exec vitest run packages/app-shell/src/views/DashboardView.modalTarget.test.tsxTest Files 1 passed (1),Tests 5 passed (5),VITEST_EXIT=0pnpm --filter @object-ui/app-shell run type-checkTYPECHECK_EXIT=0; script name echoed as@object-ui/app-shell@17.6.0 type-check(not a zero-match no-op), andtsc --listFilesconfirmsviews/DashboardView.tsxis in the checked setpnpm exec eslint packages/app-shell --format jsonESLINT_EXIT=0; 1062 files checked, 0 errors. The edited file carries 10 warnings, all pre-existingno-explicit-any/set-state-in-effecton lines the comment merely shiftednode scripts/check-control-bytes.mjscheck-control-bytes: OK (scanned 6195 tracked text file(s); skipped 85 binary)node scripts/check-spec-symbol-derivation.mjs1344 files scanned against 4959 spec export namesnode scripts/check-changeset-presence.mjsnode scripts/check-changeset-no-major.mjsnode scripts/check-changeset-overwrite.mjsExit codes were captured by redirecting to a file before reading, never through a pipe.
Declared narrowing: the repo-wide
pnpm lint(turbo run lint, every package) was narrowed topackages/app-shell. Three pieces of evidence, not a guess: (i) the checked population comes from eslint's own config resolution, not my guess about which files count; (ii) the count, 1062 files, is read from--format jsonoutput; (iii)eslint.config.jsenables no type-aware linting — itslanguageOptionscarries noparserOptions.projectand noprojectService(control:rulesoccurs 10 times in that file, so the grep shape is live) — so every rule is evaluated per-file and a comment edit in one app-shell file cannot move the verdict on any file it does not touch. CI runs the full farm regardless.🤖 Generated with Claude Code
Generated by Claude Code
Generated by Claude Code