Skip to content

finding(docs/gate): the root README's flagship dashboard example teaches stat-card, which nothing registers — and the root README is outside every doc gate's scan surface #7115

Description

@os-warren

Found while re-censusing the authored corpus for objectui#7015 (text expression channel). Not that card's defect class, so it is filed rather than fixed there.

The defect

README.md lines 290-293 — the repository's flagship "dashboard in JSON" example — author four widgets as:

{ "type": "stat-card", "title": "Revenue", "value": "${stats.revenue}", "trend": "+12%", "w": 3, "h": 1 }

stat-card is registered nowhere. Measured on 3476c2c25: a repo-wide search for the string returns exactly four hits, all of them these four README lines, and zero registrations.

Control for that zero, from the same sweep: statistic — the type these widgets presumably mean — resolves to a real registration at packages/components/src/renderers/data-display/statistic.tsx:64, ComponentRegistry.register('statistic', StatisticRenderer, ...).

A reader who copies the README's headline example gets four OBJUI-001 "Unknown component type" panels. This is exactly the failure class check-doc-component-types was built for (objectui#4823, and the three prior recurrences its header records).

Why no gate caught it

check-doc-component-types's scan surface is stated in its own header as:

every .mdx and .md page under content/docs, plus every packages/NAME/README.md

The rootREADME.md is in neither set. So the single most-read authored file in the repository is the one teaching surface no doc gate reads. check-doc-snippet-types uses the same two-part surface and likewise does not reach it.

This is adjacent to objectui#5106 (that gate's scan surface stopping at code fences) but distinct: that one was about what is scanned within a covered file; this is about a file that is not covered at all.

Two things worth deciding together

  1. The content fix — retarget the four widgets onto a registered type. Note statistic genuinely declares a value carriage row, so "value": "${...}" there evaluates correctly and would need no further change.
  2. The gate fix — add the root README.md to the scan surface of the doc gates. Worth doing as one change with (1), since fixing the content without widening the surface leaves the blind spot for the next author.

Second-order note from the same sweep, same blind-spot family: packages/plugin-dashboard/README.md authors metric-card with "value": "${data.metrics.totalUsers}", and packages/react/README.md authors an input with value: '${user.name}'. Both are inside the gate's surface for the type question, but neither metric-card nor input carries a value row in the expression carriage map, so both likely render the literal ${...}. Filed here as an observation, not measured in a browser.

Activity

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

Metadata

Metadata

Labels

documentationImprovements or additions to documentationdomain:uiobjectui ui stream: fix lands on the published library or apps — objectui execution seat

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions