Skip to content

docs(site): correct the bare-keyword claimant list in registerCatalogBlocks - #6468

Merged
os-support-ai merged 1 commit into
mainfrom
claude/issue-6442-catalog-blocks-comment
Aug 26, 2026
Merged

os-support-ai merged 1 commit into
mainfrom
claude/issue-6442-catalog-blocks-comment

Conversation

@claude

@claude claude Bot commented Aug 26, 2026

Copy link
Copy Markdown
Contributor

Fixes #6442

Comment-only. The IMPORT ORDER IS CONTRACT note in
apps/site/app/components/registerCatalogBlocks.ts justified the import order with a
bare-keyword claimant list naming two packages that do not claim the key.

Re-derived, not inherited from the card

Run at repo root on origin/main @ e929c562a, with the repo's own derivation — the same
one that feeds the CLI whitelist and judges doc snippets:

node -e "import('./scripts/check-doc-component-types.mjs').then(m=>{
  const {keys}=m.deriveRegistryKeys(process.cwd());
  for (const k of ['chart','calendar','ui:calendar','dashboard','report'])
    console.log(k, '<-', (keys.get(k)||[]).join(' , '));
})"
chart       <- apps/console/src/preview-gallery.tsx:42 ,
               apps/console/src/register-plugins.ts:71 ,
               packages/plugin-charts/src/index.tsx:88
calendar    <- apps/console/src/register-plugins.ts:111 ,
               packages/plugin-calendar/src/index.tsx:303
ui:calendar <- packages/components/src/renderers/form/calendar.tsx:13
dashboard   <- apps/console/src/preview-gallery.tsx:36 ,
               apps/console/src/register-plugins.ts:65 ,
               packages/plugin-dashboard/src/index.tsx:79
report      <- apps/console/src/register-plugins.ts:135 ,
               packages/plugin-report/src/index.tsx:75

Counters for that run: {"sourceFiles":136,"callSites":240,"resolved":235,"open":2,"indirect":133},
findings: 0 — and the same call returned 0 sites for a key nothing registers
(definitely-not-a-registered-key-6442), so a zero is a measurement here and not a broken
read.

Bare chart has one package claimant, plugin-charts. plugin-dashboard registers
dashboard, dashboard-grid, metric, metric-card, object-data-table,
object-metric, object-pivot and pivot; plugin-report registers report,
spec-report and report-viewer. Neither registers chart at all. The two
apps/console sites that also hold the key are registerLazy('chart', () => import('@object-ui/plugin-charts'), …) — stubs of the very package that claims it, and
Registry.register drops them unconditionally once a real component lands
(packages/core/src/registry/Registry.ts:270-271, outside the skipFallback branch). A
stub is a placeholder, not a competing claimant.

The calendar half, re-confirmed with the same read, needed the same correction. The
card had not checked it in depth. Bare calendar also has one package claimant,
plugin-calendar (src/index.tsx:303, namespace: 'view', no skipFallback, so it takes
the bare fallback). @object-ui/components registers the date-picker primitive at
renderers/form/calendar.tsx:13 with skipFallback: true and says why in place:
"calendar collides with the plugin-calendar full CRUD calendar VIEW, which owns the bare
type: 'calendar' schema keyword". It therefore never enters the bare keyword — that is
settled at the registration site, not by import order.

So the sentence's opening claim was the thing that was actually false. Measured across the
whole workspace, exactly one bare key is claimed by two distinct packages — page-header
(layout, components) — and neither is among the thirteen packages this file imports.
The note now states the mechanism (last registration of a bare keyword wins), the measured
fact that nothing in this list contests one today, and why the order stays fixed anyway.

Scope

Per the triage ruling, no derivation pin and no generated sentence: the two render pins the
comment names already guard the list, and the smallest true comment wins. No test was added
to justify the PR — a comment-only diff plus a changeset is the whole shape.

No public surface change. git diff restricted to every **/src/index.ts(x) returns 0
lines, and 0 files under packages/ changed at all. The diff is one comment block in
apps/site plus one empty-frontmatter changeset (the repo's first-class "no release"
declaration — check-changeset-presence confirms none was owed).

Verification — all at dc276a970, the final commit

Exit codes captured before any pipe; verdicts are each gate's own line.

check exit verdict
check:doc-types 0 ✅ Every documented component type is registered.
check:docs-route-closure 0 ✅ all 13 packages named in apps/site/app/components/registerCatalogBlocks.ts are accounted for: 11 recorded payload, 2 already reachable
check:control-bytes 0 ✅ check-control-bytes: OK (scanned 5345 tracked text file(s); skipped 85 binary).
check-changeset-presence 0 ✅ No source of a released package changed in this range, so no changeset is owed.
check-changeset-no-major 0 ✅ No changeset declares a major bump.
check:shell-escape-residue 0 ✅ check-shell-escape-residue: OK (4/4 root(s) resolved …)

The two render pins the comment names, plus the three script tests that read this file
(vitest run --maxWorkers=2, exit 0):

Test Files  5 passed (5)
     Tests  668 passed (668)

covering examples/schema-catalog/test/catalog-gallery-render.test.tsx,
examples/schema-catalog/test/plugin-dashboard-gallery-render.test.tsx,
scripts/__tests__/check-doc-component-types.test.ts,
scripts/__tests__/check-docs-route-eager-closure.test.ts and
scripts/__tests__/site-playground-layout-registration-3904.test.ts.

pnpm --filter @object-ui/site run type-check exit 0 (fumadocs-mdx && next typegen && tsc --noEmit) — after pnpm --filter '@object-ui/site^...' build, because a fresh worktree's
unbuilt dist/*.d.ts produces a TS2882 false red that has nothing to do with this diff.

Lint, narrowed and measured

pnpm lint is turbo run lint (each package lints itself). Two scopes were run with
eslint's own --format json:

  • @object-ui/site (eslint .): 32 files selected by eslint's config, exit 0, 0
    errors / 7 pre-existing warnings. The edited file is in that set at 0 errors, 0 warnings.
  • root scope (lint:root): 206 files, exit 0, 0 errors / 28 pre-existing warnings. 0
    .md files and 0 .changeset/ files
    are in any eslint population, so the changeset
    cannot move a lint verdict.

Nothing outside those sets can move: eslint.config.js extends
tseslint.configs.recommended, not recommendedTypeChecked, and declares no
parserOptions.project or projectService anywhere — linting is not type-aware. All seven
custom rules in eslint-rules/ were grepped for readFileSync / readdirSync / fs
imports and do none, so every verdict is a pure function of that file's own text plus the
config. This diff adds one .ts file to that computation and one .md file that eslint
does not select.

Generated by Claude Code


Generated by Claude Code

…Blocks

The `IMPORT ORDER IS CONTRACT` note justified the import order with a claimant
list naming two packages that do not claim the key: it said bare `chart` is
claimed by plugin-charts, plugin-dashboard and plugin-report. Re-derived with
the repo's own `deriveRegistryKeys` (scripts/check-doc-component-types.mjs),
bare `chart` has one package claimant, plugin-charts. Neither plugin-dashboard
nor plugin-report registers it at all, and the two apps/console sites that also
hold the key are registerLazy stubs whose loader is @object-ui/plugin-charts
itself, which Registry.register drops unconditionally once the real component
arrives.

The same re-derivation extends the correction to the calendar half the card had
not checked in depth: bare `calendar` likewise has one package claimant,
plugin-calendar, because @object-ui/components registers the date-picker
primitive as ui:calendar with skipFallback so it does not take the bare keyword.
The note therefore no longer opens by asserting that several packages register
the same bare keyword. The mechanism and the reason the order stays fixed are
kept.

Comment-only. No code, no imports and no assertions changed.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011SfZeFWrhGLHmfq61xbz4q
@github-actions github-actions Bot added the apps label Aug 26, 2026
@os-support-ai
os-support-ai marked this pull request as ready for review August 26, 2026 02:22
@os-support-ai
os-support-ai added this pull request to the merge queue Aug 26, 2026
Merged via the queue into main with commit f7c52e2 Aug 26, 2026
28 checks passed
@os-support-ai
os-support-ai deleted the claude/issue-6442-catalog-blocks-comment branch August 26, 2026 02:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

registerCatalogBlocks' import-order comment names two packages that do not claim bare chart

2 participants