Repository navigation
docs(site): correct the bare-keyword claimant list in registerCatalogBlocks - #6468
Merged
Merged
Conversation
…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
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Fixes #6442
Comment-only. The
IMPORT ORDER IS CONTRACTnote inapps/site/app/components/registerCatalogBlocks.tsjustified the import order with abare-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 sameone that feeds the CLI whitelist and judges doc snippets:
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 brokenread.
Bare
charthas one package claimant,plugin-charts.plugin-dashboardregistersdashboard,dashboard-grid,metric,metric-card,object-data-table,object-metric,object-pivotandpivot;plugin-reportregistersreport,spec-reportandreport-viewer. Neither registerschartat all. The twoapps/consolesites that also hold the key areregisterLazy('chart', () => import('@object-ui/plugin-charts'), …)— stubs of the very package that claims it, andRegistry.registerdrops them unconditionally once a real component lands(
packages/core/src/registry/Registry.ts:270-271, outside theskipFallbackbranch). Astub is a placeholder, not a competing claimant.
The
calendarhalf, re-confirmed with the same read, needed the same correction. Thecard had not checked it in depth. Bare
calendaralso has one package claimant,plugin-calendar(src/index.tsx:303,namespace: 'view', noskipFallback, so it takesthe bare fallback).
@object-ui/componentsregisters the date-picker primitive atrenderers/form/calendar.tsx:13withskipFallback: trueand says why in place:"
calendarcollides with the plugin-calendar full CRUD calendar VIEW, which owns the baretype: 'calendar'schema keyword". It therefore never enters the bare keyword — that issettled 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 diffrestricted to every**/src/index.ts(x)returns 0lines, and 0 files under
packages/changed at all. The diff is one comment block inapps/siteplus one empty-frontmatter changeset (the repo's first-class "no release"declaration —
check-changeset-presenceconfirms none was owed).Verification — all at
dc276a970, the final commitExit codes captured before any pipe; verdicts are each gate's own line.
check:doc-types✅ Every documented component type is registered.check:docs-route-closure✅ all 13 packages named in apps/site/app/components/registerCatalogBlocks.ts are accounted for: 11 recorded payload, 2 already reachablecheck:control-bytes✅ check-control-bytes: OK (scanned 5345 tracked text file(s); skipped 85 binary).check-changeset-presence✅ No source of a released package changed in this range, so no changeset is owed.check-changeset-no-majormajorbump.check:shell-escape-residue✅ 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):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.tsandscripts/__tests__/site-playground-layout-registration-3904.test.ts.pnpm --filter @object-ui/site run type-checkexit 0 (fumadocs-mdx && next typegen && tsc --noEmit) — afterpnpm --filter '@object-ui/site^...' build, because a fresh worktree'sunbuilt
dist/*.d.tsproduces aTS2882false red that has nothing to do with this diff.Lint, narrowed and measured
pnpm lintisturbo run lint(each package lints itself). Two scopes were run witheslint's own
--format json:@object-ui/site(eslint .): 32 files selected by eslint's config, exit 0, 0errors / 7 pre-existing warnings. The edited file is in that set at 0 errors, 0 warnings.
lint:root): 206 files, exit 0, 0 errors / 28 pre-existing warnings. 0.mdfiles and 0.changeset/files are in any eslint population, so the changesetcannot move a lint verdict.
Nothing outside those sets can move:
eslint.config.jsextendstseslint.configs.recommended, notrecommendedTypeChecked, and declares noparserOptions.projectorprojectServiceanywhere — linting is not type-aware. All sevencustom rules in
eslint-rules/were grepped forreadFileSync/readdirSync/fsimports and do none, so every verdict is a pure function of that file's own text plus the
config. This diff adds one
.tsfile to that computation and one.mdfile that eslintdoes not select.
Generated by Claude Code
Generated by Claude Code