Skip to content

feat(ui): adopt Shadcn AI Elements in the deferred workspace - #39

Open
robinbraemer wants to merge 32 commits into
mainfrom
codex/shadcn-ui-system
Open

feat(ui): adopt Shadcn AI Elements in the deferred workspace#39
robinbraemer wants to merge 32 commits into
mainfrom
codex/shadcn-ui-system

Conversation

@robinbraemer

@robinbraemer robinbraemer commented Aug 11, 2026

Copy link
Copy Markdown
Member

Outcome

Flect now uses Shadcn v4 as the neutral UI foundation and the official AI Elements registry for its agent experience. The protected workspace remains an Astro island on Vite: the static shell loads first, while the Preact-compatible workspace and Effect-owned runtime remain deferred until needed.

What changed

  • Added the Shadcn v4/Radix component foundation and neutral light/dark tokens.
  • Added official AI Elements compositions for conversation, messages, composer, reasoning, and tool activity.
  • Removed superseded bespoke chat primitives and the old persistent pink accent.
  • Kept agent workflows, cancellation, and resources in Effect; AI Elements owns presentation only.
  • Restored the canonical protected-workspace bundle budget and emits a sorted per-island dependency report from the existing bundle gate.
  • Fixed the normal Astro development origin so a real browser can create a Pi session.
  • Fixed asynchronous continuity updates from overwriting an in-progress composer draft.
  • Made the packaged macOS verifier locate the composer through its public accessibility role and name.
  • Moved protected Settings out of the conversation rail: it uses the complete left workspace at wide sizes, and the full viewport at compact sizes.
  • Simplified first run to one clear creation action; canvas-only controls stay hidden until an interface exists. The product surface no longer carries Flect branding, and a larger protected desktop drag strip is available above it.
  • Replaced the global canvas-editing bar with a compact overlay trigger and a viewport-safe contextual palette attached to the selected element. Hover preview, capsule selection, Move earlier/later, resize presets, clearing, busy state, and the existing attributable agent/revision workflow remain connected.
  • Added observable Light/Dark WCAG, viewport-containment, capsule-action, and full direct-edit regression coverage for the contextual overlay.
  • Reworked the chat into one chronological turn timeline with compact grouped tool activity, expandable bounded details, clearer success/attention states, and a calmer composer surface.
  • Moved the model, provider, and reasoning picker into a native top-layer dialog so the canvas cannot clip or cover it.

Current evidence

  • Final local commit: 6698b9a.
  • bun run check passed: 905 Vitest tests (1 intentional skip), type-checking, lint, Effect and product-quality gates.
  • The production and diagnostic browser bundle gates pass with the protected workspace still below its decoded and gzip budgets.
  • Production Chromium passed the grouped tool disclosure closed/open contract and chronological persistence through reload.
  • Production Chromium passed the full Select element → target → Move later flow through the same agent and revision path.
  • Production Chromium passed contextual-overlay WCAG A/AA, viewport containment, hover targeting, and screenshots in both Light and Dark appearances.
  • The full production-Chromium suite passed: 91/91 flows, including settings-as-overlay, model selection, forced-colors, disposable role workspaces, local control, sharing, and the interaction/performance budgets.
  • Rust formatting and 26 native tests passed; the ad-hoc signed macOS .app bundle built successfully.
  • Prior packaged macOS verification passed ad-hoc signature verification, actionable setup, editable draft, sidecar-loss recovery, restored draft, native menus/controls, and one window.
  • Dated baseline evidence: verification report.
  • The hosted Flect quality gate passed for 6698b9a (run 31706281232).

External evidence deliberately not claimed

This host has no xctrace/Instruments, AgentOS cluster, Windows/Linux target, clean second machine, or manual VoiceOver environment. Those remain external release gates and are not represented as complete in this PR.

Review focus

  • Verify AI Elements remains behind the Astro island boundary.
  • Verify application workflows remain Effect-owned.
  • Review the Settings workspace, starter flow, desktop drag region, and contextual selection overlay.
  • Confirm neutral tokens, selected-element visibility, and contextual controls in both appearances.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant