feat(ui): migrate remaining P1/P2 surfaces to shadcn/Radix primitives#209
Merged
Conversation
Replaces handwritten dialog/overlay/menu implementations with shared shadcn+Radix primitives across dialogs, command palette, notifications, People panel, passive intelligence, mobile menus/sheets, nested readers, tooltips, cell history, evidence previews, and notebook patch overlays. Focus trapping, Escape handling, outside dismissal, collision placement, and focus restoration now route through the shared primitives instead of per-surface hand-rolled logic. Specialized spreadsheet, notebook, deck, and graph interaction engines remain intentionally specialized. Adds src/design/uiLayerPolicy.ts + scripts/ui-layer-audit.ts to gate the layer boundary, wired into design:audit. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Resolves 6 conflicts. Import blocks in Chat.tsx and Artifact.tsx keep both sides. All four xlsx-export conflicts in Artifact.tsx resolve to origin/main, whose applyExportCell handles imported styles, fonts, fills, alignment, borders and numFmts; the local side was an earlier draft superseded by PRs #191-#208. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…migration Playwright capture against built previews of origin/main (before) and this branch (after), plus a behavioural probe of the command palette. Records honestly that focus trap, Escape, outside-dismiss and focus restoration already worked before this change, and that the background aria-hidden question is unresolved on both sides. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Scaffold Handoff — For Your Coding Agent
Immutability CheckMode: advisory ✅ No immutable files were modified in this branch. Changed Files
Needs Adversarial Review — Do NOT Apply YetThese proposals passed the reject check but have not been approved by
Safety Boundary
Immutable files (never modify):
Scaffold files (safe to modify):
|
The mobile FAB fan migrated to Radix DropdownMenu, so its items expose role=menuitem. Query the accurate role instead of the old literal <button>. Verified against the built preview: 120s click-timeout -> 6.8s pass. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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.
What
Migrates the remaining P1/P2 surfaces in
docs/design/RADIX_PRIMITIVE_AUDIT.mdontoshared shadcn/Radix primitives: dialogs, command palette, notifications, People panel,
passive intelligence, mobile menus/sheets, nested readers, tooltips, cell history,
evidence previews, and notebook patch overlays.
Adds
src/design/uiLayerPolicy.ts+scripts/ui-layer-audit.tsto gate the layerboundary, wired into
design:audit.Specialized spreadsheet, notebook, deck, and graph interaction engines remain
intentionally specialized.
Honest scope note
This does not fix broken behaviour — it removes duplicated behaviour. A Playwright
probe against
origin/mainconfirms focus trapping, Escape handling, outside dismissaland focus restoration already worked. The value here is that every surface now inherits
one implementation instead of re-deriving it per surface.
Before/after proof
Captured with Playwright against built previews of
origin/main(before) and thisbranch (after) — see
docs/design/ui-contract/20260717-radix-primitives/.Room surface is visually unchanged (
before-02/after-02identical size). Only visibledelta: command-palette rows are ~3px tighter from shadcn
CommandItempadding, fittingone more row in the height-capped list.
Gates
npm run floor: 2,499/2,501 passed. The 2 failures (proofloopStandaloneRunnerDogfood,spreadsheetBenchChunkedRepair) are pre-existing 5s-timeout load flakes and pass inisolation; neither is touched by this branch.
design:audit+ui:layer-audit: pass (588 source files). The 531 token-drift warningsare advisory and pre-existing.
@convex-dev/auth, which degradedDataModelFromSchemaDefinitiontoId<string>;fixed by
npm install, not by this branch.)Known follow-up (not addressed here)
Neither implementation marks
#rootaria-hiddenwhile a modal is open, so backgroundcontent stays in the a11y tree on both sides.
beforehadaria-modal="true";afterdoes not (Radix drops it in favour of
hideOthers, which is not marking#roothere).Worth a focused follow-up.
🤖 Generated with Claude Code