Repository navigation
Group and DataTable pass the renderer checks as the guide composes them - #318
Conversation
DataTable trims its cells', pills' and rename arrow's text to the capitals in the font it draws them in, a table in a Group recolors the group's edge away instead of removing it, and useTableProps gives each row its own step's progress. A kit browser spec holds the composition to the label-centring and frame-edges probes. Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
🟡 Changes recommended
Unscheduled rows fail to reach the correct After state, while stage construction introduces quadratic rendering costs and the new tests do not exercise staged progression.
3 open issues
What changed in this PR
Updates the renderer kit so the guide’s ContentView > Group > DataTable composition satisfies label, frame-edge, and step-hold checks.
Changes:
- Aligns code-font text, change pills, and arrows on their capitals.
- Preserves the group’s edge while making it transparent.
- Adds per-row scheduled progress, browser coverage, and documentation.
| File | Description |
|---|---|
| packages/renderers/kit/test/table.test.mjs | Updates pill markup expectations. |
| packages/renderers/kit/test/diff.test.mjs | Updates arrow markup expectations. |
| packages/renderers/kit/styles/table.css | Centres reserved values and recolors group edges. |
| packages/renderers/kit/src/react/diff-components.tsx | Applies label trimming to inline arrows. |
| packages/renderers/kit/src/react/data-table.tsx | Derives per-row progress from the schedule. |
| packages/renderers/kit/src/react/data-table-row.tsx | Corrects code-font and pill label markup. |
| packages/renderers/kit/browser/data-table.spec.ts | Adds label and frame probe checks. |
| packages/renderers/kit/browser/data-table-page.ts | Adds the composed table fixture. |
| docs/guides/renderer-kit-components.md | Documents automatic per-row progress. |
| changelog.d/318.md | Records the renderer-kit fixes. |
Review effort: Balanced
…ws After at the end Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
🟡 Changes recommended
DataTable’s entity-only lookup ignores relationship step assignments, leaving additions invisible and removals visible until progress reaches 1 instead of updating at their assigned step.
1 open issue
3 resolved since last review
Review effort: Balanced
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
pk-label on an inline-flex Tag trimmed nothing; its text is now a flex item of its own. The kit browser spec measures Tags beside the DataTable. Regenerates renderer-kit.md. Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
🔵 Needs a closer look
Browser-specific text trimming and rounded-edge rendering still require real-host scrub/frame inspection and WebKit validation, which execution restrictions prevented.
No open issues 🎉
1 resolved since last review
Review effort: Balanced
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
🔵 Needs a closer look
The animation timing and cap-height/border changes require real-host intermediate-frame inspection and cross-engine visual checks unavailable in this environment, with WebKit validation deferred to CI.
No open issues 🎉
Review effort: Balanced


What changed
The setup guide puts a table renderer together as
ContentView>Group>DataTable. Four setup trials used that layout and failedprojections check. A custom renderer scaffolded withprojections init --renderer customfollowing the guide failed three checks:.pk-group:has(> .pk-table-frame)::after { content: none }rule removed the group's edge, which the check forbids renderer rules from doing.useTablePropsgave every row the frame's progress, so each value switched at progress 0.5, during the host's hold between steps.All three fixes are in the kit:
DataTablemarks a code column's text itself as an identifier rather than an inner span, so the trim measures the drawn font. Progress-mode pills now hold their value in apk-label, andValueChange's inline arrow is apk-labeltoo. Cells that reserve room for the other version centre the version they show.Groupnow makes the group's::afteredge transparent (a recolor, which the check allows) instead of removing it.useTablePropslooks up each row's step in the props'scheduleand passes its progress through that step asrowProgress. A row that no step names shows Before until the end and After there. So the guide's one-line<DataTable {...useTableProps(props)} …/>stays still between steps.A new kit browser spec,
kit/browser/data-table.spec.ts, renders the guide's composition (code columns, a rename, a changed value, an added row and an unchanged row) in diff and progress modes. It runs the checks'labelsandframesprobes and expects neither to flag anything.Before: the scaffolded renderer fails label-centring, frame-edges and hold motion.
After: every renderer check passes.
Two more kit components that failed their own checks in setup trials:
Tagputpk-labelon itsinline-flexbox, andtext-boxtrims nothing in a flex container, so a<Tag code>sat off centre. Its text is now a flex item of its own (pk-tag > pk-label), trimmed in the font it is drawn in. The kit browser spec measures a code Tag and a word Tag beside the table.ValueListsaid a modified item withwasonly as "was … now", with no status word, so status-text failed on a documented use. It now says "Modified" before it, as its added and removed items say theirs.Evidence
npx playwright test --project=chromium-desktop kit/browser/data-table(from the harness) passes. Without the fix it fails on the first-column cells and the pills. With only the old::afterrule restored, it fails on that rule.A custom renderer scaffolded with
projections init --renderer custom, rewritten to the guide'sContentView>Group>DataTableexample and built against the packed SDK:npx playwright test(the renderer checks) failed those three checks before the fix and passes after.node --test packages/renderers/kit/test/*.test.mjs(198 tests, including a new one that renders throughuseTablePropswith a three-step schedule and checks that every hold draws one frame, forward and backward; it fails without the fix) (197 tests) andnpm run tools -- check --fastpass.Not run here: the WebKit projects, which CI runs.
Documentation that this change affects is updated, and generated reference
pages are regenerated (
npm run docs:generate).Fixes include a regression test.
A changelog fragment at
changelog.d/<this PR's number>.mddescribes whatusers will notice, or the PR has the
no changeloglabel (seechangelog.d/README.md).
No credentials, private source or machine-specific paths are included.