ui-storylisted
Install: claude install-skill treq-dev/treq
# ui-story (Storybook stories for treq components)
## What this skill is for
Storybook here exists to let a reviewer *see* a changed presentational
component in isolation — different props, different variants, light/dark —
without running the full Tauri app or a real jj repo. It is not a
replacement for `/app-qa`, which verifies real app behavior against a real
repo. If the component you're working on can't be meaningfully rendered
without live app state (a `useQuery` hook, `invoke()` calls, `ThemeProvider`
context that reads settings from the Rust backend, etc.), that's a signal
it isn't presentational yet — either stub/inject that dependency via props,
or skip Storybook for it and rely on `/app-qa` instead.
## Setup already in place
- `.storybook/main.ts` — stories glob is `src/**/*.stories.@(ts|tsx)`,
framework is `@storybook/react-vite`.
- `.storybook/preview.tsx` — imports `src/index.css` (Tailwind + the app's
CSS variables), and adds a toolbar **Theme** control that toggles the
`.dark` class on `<html>`, matching how `useTheme` applies dark mode in
the real app. Stories automatically get real treq styling in both themes
without needing `ThemeProvider`.
- `npm run storybook` — dev server on port 6006.
- `npm run build-storybook` — static build to `storybook-static/` (what CI
deploys).
- Example: `src/components/ui/button.stories.tsx`.
## Where stories live
Colocate the story next to the component it documents:
`src/components/ui/button.tsx` → `src/compo