Skip to content

feat(app): add the shadcn + tailwind design-system layer - #2386

Merged
DeliciousBuding merged 1 commit into
masterfrom
feat/shadcn-foundation
Oct 19, 2026
Merged

DeliciousBuding merged 1 commit into
masterfrom
feat/shadcn-foundation

Conversation

@DeliciousBuding

Copy link
Copy Markdown
Collaborator

First step of the frontend rebuild: the shadcn/ui + Tailwind layer that the conversation UI will be built on. No component is migrated yet — this PR only makes the layer real, verified and mergeable, so the UI slices that follow are pure component work.

What it adds

  • Tailwind v4 (tailwindcss + @tailwindcss/vite) plugged into both renderers (web, desktop), with the stylesheet imported once per entry.
  • shared/src/styles/shadcn.css — the token bridge. The design system already exposed shadcn-shaped variables (--background, --foreground, --primary, --muted, --card, --border, --ring, --input, --popover, --accent, --destructive), so @theme inline maps Tailwind's colour namespace onto them and onto the existing --r-xs..xl radius scale. Palette and radius stay single-sourced in tokens-base.css / themes.css.
  • Preflight is deliberately not imported. It resets margins, headings, lists and form controls globally and would silently restyle every component still on CSS Modules. Only the one preflight rule shadcn actually needs is re-declared (zero-width solid border so border utilities draw a real border). Full preflight lands with the last old-UI removal.
  • shared/components.json so pnpm dlx shadcn@latest add … keeps working against this repo's aliases (@shared/shadcn/ui, @shared/lib/utils).
  • shared/src/lib/utils.ts (cn() = clsx + tailwind-merge) and the vendored button component as the first official shadcn primitive, with a render test.

Components are vendored one at a time as a surface adopts them — the other eight primitives I pulled while wiring the registry were untested dead weight and are not in this PR.

Verified

  • pnpm --filter agenthub-web build: passes; the emitted index-*.css contains --color-background / --radius-md, i.e. the theme bridge really is in the bundle.
  • pnpm --filter @agenthub/shared typecheck, agenthub-desktop typecheck: pass.
  • pnpm --filter @agenthub/shared lint: 0 errors (agenthub-web lint --max-warnings 0: pass).
  • vitest run shared/src/shadcn: 2/2.

Next slices

  1. Composer → shadcn InputGroup + Attachment + Button.
  2. Transcript rows → Message / Bubble / Tool / Reasoning, keeping the existing transcript data model.
  3. Sidebar + shell chrome, then delete the CSS Modules and the visual-QA baselines that covered them.

Co-authored-by: Codex <codex@delicious233.com>
@coderabbitai

coderabbitai Bot commented Oct 19, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration
  • Configuration used: Repository: TokenDanceLab/AgentHub/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: d5e61d55-5dda-43e4-aad4-37834d2bd61b

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@DeliciousBuding
DeliciousBuding merged commit b8ba9db into master Oct 19, 2026
39 checks passed
@DeliciousBuding
DeliciousBuding deleted the feat/shadcn-foundation branch October 19, 2026 14:49
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