React PWA Designer
Design and build modern React progressive web applications using SuperDesign methodology, shadcn/ui components, and React best practices.
When to Use This Skill
Trigger this skill when the user requests:
- Designing or building React applications
- Creating progressive web apps (PWAs)
- Implementing shadcn/ui components
- Building modern, responsive web interfaces
- Creating React component libraries
- Designing with Tailwind CSS and modern design systems
- Converting designs to React components
MCP Server Prerequisites
This skill expects two MCP servers to be configured: shadcn (mcp__shadcn__*) for live component discovery and variant details, and context7 (mcp__context7__*) for official/latest library documentation. Both are optional. Without them the skill falls back to its bundled reference files (@reference/shadcn-components.md and the other @reference/* guides), so component listings may be incomplete and documentation may lag the latest releases.
Reference File Index
Getting Started
- README.md - Complete skill overview
- @reference/setup-guide.md - Project initialization, dependencies, configuration
templates/.superdesign/ - copy to the project root; design artifacts go in .superdesign/design_iterations/ (naming rules in the README inside it)
React Patterns
- @reference/react-hooks.md - Custom hooks and patterns
- @reference/component-patterns.md - Component architecture, compound components, render props
- @reference/state-management-patterns.md - useState vs Context vs Zustand vs React Query
Styling & Layout
- @reference/dynamic-styling-patterns.md - CSS Variables, Tailwind, inline styles
- @reference/layout-patterns.md - Flex scrolling, grid, responsive design, text overflow
- @reference/shadcn-components.md - shadcn/ui integration (check BEFORE MCP calls)
PWA
- @reference/pwa-checklist.md - PWA requirements checklist
- @reference/pwa-icon-validation.md - Icon validation (CRITICAL - read before generating icons!)
- @reference/pwa-troubleshooting.md - Installation, service worker, offline issues
Quality
- @reference/code-quality-tooling.md - ESLint, TypeScript, Prettier configuration
- @reference/common-pitfalls.md - Anti-patterns to avoid
- @reference/accessibility.md - WCAG AA patterns and examples
- @reference/implementation-examples.md - Complete code examples (Dashboard, Auth Flow)
Templates
- templates/vite.config.ts - Vite + PWA configuration
- templates/tailwind.config.js - Tailwind CSS setup
- templates/tsconfig.json - TypeScript configuration
- templates/manifest.json - PWA manifest template
templates/component-boilerplate.tsx - React component template
templates/custom-hook-template.ts - Custom hook structure
templates/service-worker.ts - Manual service worker implementation
SuperDesign Workflow
Four-phase methodology. Get user approval before proceeding at each phase.
Phase 1: Discovery & Planning
- Understand Requirements - App purpose, target users, PWA needs (offline, installable, notifications)
- Component Discovery - Use
mcp__shadcn__getComponents() and mcp__shadcn__getComponent() to identify matching components
- Architecture Planning - Component hierarchy, state management, routing, data fetching
Phase 2: Design
Reference: See SuperDesign.md for complete methodology.
- Layout Design - ASCII wireframes showing component structure and responsive breakpoints
- Theme Design - MUST use tool calls (never text output), save to
.superdesign/design_iterations/theme_[n].css
- Animation Design - Micro-syntax specs for transitions, loading states, interactions
- Component Implementation - Compose from shadcn primitives with proper TypeScript types
Phase 3: PWA Implementation
- Icons - MUST READ @reference/pwa-icon-validation.md first (dimension mismatches = silent install failure)
- Manifest - Use
templates/manifest.json as starting point
- Service Worker - Vite PWA Plugin (recommended) or manual via
templates/service-worker.ts
- Verify - See @reference/pwa-checklist.md for complete requirements
Phase 4: Development
- React patterns → @reference/react-hooks.md, @reference/component-patterns.md
- State management → @reference/state-management-patterns.md
- TypeScript & linting → @reference/code-quality-tooling.md
- Performance - React.memo, virtualization, code splitting, bundle monitoring
- Troubleshooting → @reference/pwa-troubleshooting.md
Session Scoping
- Limit to 15-20 files maximum per session
- Focus on single feature or component per iteration
- Complete cycle: Implementation → Tests → Commit before next scope
Tool Usage Decision Tree
Need component info?
├─ Common component details → Check @reference/shadcn-components.md FIRST
├─ Detailed implementation/variants → mcp__shadcn__getComponent("name")
└─ List all available components → mcp__shadcn__getComponents()
Need library documentation?
├─ React hooks/patterns → Check @reference/react-hooks.md FIRST
├─ State management → Check @reference/state-management-patterns.md FIRST
├─ Styling decisions → Check @reference/dynamic-styling-patterns.md FIRST
├─ PWA requirements → Check @reference/pwa-checklist.md FIRST
├─ Need official/latest docs → mcp__context7__resolve_library_id() then get_library_docs()
└─ Common Context7 libraries:
/facebook/react, /vite-pwa/vite-plugin-pwa, /GoogleChrome/workbox,
/tanstack/react-query, /pmndrs/zustand, /shadcn/ui
Rule: Always check reference files before MCP calls to save tokens.
Quick Decision Trees
Component Selection
Need interactive element?
├─ Button/action → <Button>
├─ Link/navigation → <Link> or <a>
├─ Input field → <Input> or <Textarea>
├─ Toggle → <Switch> or <Checkbox>
└─ Selection → <Select> or <RadioGroup>
Need layout container?
├─ Content box → <Card>
├─ Modal → <Dialog>
├─ Side panel → <Sheet>
├─ Dropdown → <DropdownMenu>
└─ Sections → <Tabs> or <Accordion>
Need feedback?
├─ Loading → <Skeleton> or <Progress>
├─ Notification → <Toast> or <Alert>
├─ Hint → <Tooltip>
└─ Confirmation → <AlertDialog>
State Management
What kind of state?
├─ Local to component → useState
├─ Shared (2-3 components) → Props or useContext
├─ Complex app state → Zustand or Jotai
├─ Server data → React Query or SWR
└─ Form state → React Hook Form + Zod
Critical Reminders
- ALWAYS use actual tool calls - Never output "Called tool: ..." as text
- Get user approval at each workflow step before proceeding
- Use tool calls for theme generation - Never output CSS as text
- Save to .superdesign/design_iterations/ for all design artifacts
- Check reference files before MCP for component details
- Follow React best practices - hooks, TypeScript, composition
- PWA icons MUST match manifest exactly - see @reference/pwa-icon-validation.md
- Avoid bootstrap blue colors - use modern design systems
- Mobile-first responsive - always design for smallest screen first
- Accessibility required - ARIA labels, keyboard nav, semantic HTML, WCAG AA contrast
Keep this skill current
When shadcn/ui, the Vite PWA plugin, or the MCP servers named here change an API or a component list, update the affected reference file in the same session. Replace the superseded text; do not append a note.
1---2name: react-pwa-designer3description: |4 Use when designing or building frontend interfaces in React: a progressive web app (PWA) that5 installs and works offline, a component-driven UI on shadcn/ui and Tailwind CSS, a responsive6 mobile-first layout, or a React component library. Covers frontend design through the7 SuperDesign workflow (layout, theme, animation, implementation), shadcn/ui component8 selection, service worker and manifest setup, PWA icon validation, state management choices,9 and WCAG AA accessibility. Uses the shadcn and context7 MCP servers when they are configured.10license: MIT11metadata:12 author: AeyeOps13 version: "0.3.2"14 summary: Frontend design and build guide for React progressive web apps on shadcn/ui and Tailwind, from wireframe to installable offline-first PWA.15---1617# React PWA Designer1819Design and build modern React progressive web applications using SuperDesign methodology, shadcn/ui components, and React best practices.2021## When to Use This Skill2223Trigger this skill when the user requests:24- Designing or building React applications25- Creating progressive web apps (PWAs)26- Implementing shadcn/ui components27- Building modern, responsive web interfaces28- Creating React component libraries29- Designing with Tailwind CSS and modern design systems30- Converting designs to React components3132### MCP Server Prerequisites3334This skill expects two MCP servers to be configured: **shadcn** (`mcp__shadcn__*`) for live component discovery and variant details, and **context7** (`mcp__context7__*`) for official/latest library documentation. Both are optional. Without them the skill falls back to its bundled reference files (`@reference/shadcn-components.md` and the other `@reference/*` guides), so component listings may be incomplete and documentation may lag the latest releases.3536## Reference File Index3738### Getting Started39- [README.md](README.md) - Complete skill overview40- @reference/setup-guide.md - Project initialization, dependencies, configuration41- `templates/.superdesign/` - copy to the project root; design artifacts go in `.superdesign/design_iterations/` (naming rules in the README inside it)4243### React Patterns44- @reference/react-hooks.md - Custom hooks and patterns45- @reference/component-patterns.md - Component architecture, compound components, render props46- @reference/state-management-patterns.md - useState vs Context vs Zustand vs React Query4748### Styling & Layout49- @reference/dynamic-styling-patterns.md - CSS Variables, Tailwind, inline styles50- @reference/layout-patterns.md - Flex scrolling, grid, responsive design, text overflow51- @reference/shadcn-components.md - shadcn/ui integration (check BEFORE MCP calls)5253### PWA54- @reference/pwa-checklist.md - PWA requirements checklist55- @reference/pwa-icon-validation.md - Icon validation (CRITICAL - read before generating icons!)56- @reference/pwa-troubleshooting.md - Installation, service worker, offline issues5758### Quality59- @reference/code-quality-tooling.md - ESLint, TypeScript, Prettier configuration60- @reference/common-pitfalls.md - Anti-patterns to avoid61- @reference/accessibility.md - WCAG AA patterns and examples62- @reference/implementation-examples.md - Complete code examples (Dashboard, Auth Flow)6364### Templates65- [templates/vite.config.ts](templates/vite.config.ts) - Vite + PWA configuration66- [templates/tailwind.config.js](templates/tailwind.config.js) - Tailwind CSS setup67- [templates/tsconfig.json](templates/tsconfig.json) - TypeScript configuration68- [templates/manifest.json](templates/manifest.json) - PWA manifest template69- `templates/component-boilerplate.tsx` - React component template70- `templates/custom-hook-template.ts` - Custom hook structure71- `templates/service-worker.ts` - Manual service worker implementation7273## SuperDesign Workflow7475Four-phase methodology. **Get user approval before proceeding at each phase.**7677### Phase 1: Discovery & Planning78791. **Understand Requirements** - App purpose, target users, PWA needs (offline, installable, notifications)802. **Component Discovery** - Use `mcp__shadcn__getComponents()` and `mcp__shadcn__getComponent()` to identify matching components813. **Architecture Planning** - Component hierarchy, state management, routing, data fetching8283### Phase 2: Design8485**Reference**: See [SuperDesign.md](SuperDesign.md) for complete methodology.86871. **Layout Design** - ASCII wireframes showing component structure and responsive breakpoints882. **Theme Design** - MUST use tool calls (never text output), save to `.superdesign/design_iterations/theme_[n].css`893. **Animation Design** - Micro-syntax specs for transitions, loading states, interactions904. **Component Implementation** - Compose from shadcn primitives with proper TypeScript types9192### Phase 3: PWA Implementation93941. **Icons** - MUST READ @reference/pwa-icon-validation.md first (dimension mismatches = silent install failure)952. **Manifest** - Use `templates/manifest.json` as starting point963. **Service Worker** - Vite PWA Plugin (recommended) or manual via `templates/service-worker.ts`974. **Verify** - See @reference/pwa-checklist.md for complete requirements9899### Phase 4: Development100101- **React patterns** → @reference/react-hooks.md, @reference/component-patterns.md102- **State management** → @reference/state-management-patterns.md103- **TypeScript & linting** → @reference/code-quality-tooling.md104- **Performance** - React.memo, virtualization, code splitting, bundle monitoring105- **Troubleshooting** → @reference/pwa-troubleshooting.md106107### Session Scoping108109- Limit to 15-20 files maximum per session110- Focus on single feature or component per iteration111- Complete cycle: Implementation → Tests → Commit before next scope112113## Tool Usage Decision Tree114115```116Need component info?117├─ Common component details → Check @reference/shadcn-components.md FIRST118├─ Detailed implementation/variants → mcp__shadcn__getComponent("name")119└─ List all available components → mcp__shadcn__getComponents()120121Need library documentation?122├─ React hooks/patterns → Check @reference/react-hooks.md FIRST123├─ State management → Check @reference/state-management-patterns.md FIRST124├─ Styling decisions → Check @reference/dynamic-styling-patterns.md FIRST125├─ PWA requirements → Check @reference/pwa-checklist.md FIRST126├─ Need official/latest docs → mcp__context7__resolve_library_id() then get_library_docs()127└─ Common Context7 libraries:128 /facebook/react, /vite-pwa/vite-plugin-pwa, /GoogleChrome/workbox,129 /tanstack/react-query, /pmndrs/zustand, /shadcn/ui130```131132**Rule**: Always check reference files before MCP calls to save tokens.133134## Quick Decision Trees135136### Component Selection137138```139Need interactive element?140├─ Button/action → <Button>141├─ Link/navigation → <Link> or <a>142├─ Input field → <Input> or <Textarea>143├─ Toggle → <Switch> or <Checkbox>144└─ Selection → <Select> or <RadioGroup>145146Need layout container?147├─ Content box → <Card>148├─ Modal → <Dialog>149├─ Side panel → <Sheet>150├─ Dropdown → <DropdownMenu>151└─ Sections → <Tabs> or <Accordion>152153Need feedback?154├─ Loading → <Skeleton> or <Progress>155├─ Notification → <Toast> or <Alert>156├─ Hint → <Tooltip>157└─ Confirmation → <AlertDialog>158```159160### State Management161162```163What kind of state?164├─ Local to component → useState165├─ Shared (2-3 components) → Props or useContext166├─ Complex app state → Zustand or Jotai167├─ Server data → React Query or SWR168└─ Form state → React Hook Form + Zod169```170171## Critical Reminders1721731. **ALWAYS use actual tool calls** - Never output "Called tool: ..." as text1742. **Get user approval** at each workflow step before proceeding1753. **Use tool calls for theme generation** - Never output CSS as text1764. **Save to .superdesign/design_iterations/** for all design artifacts1775. **Check reference files before MCP** for component details1786. **Follow React best practices** - hooks, TypeScript, composition1797. **PWA icons MUST match manifest exactly** - see @reference/pwa-icon-validation.md1808. **Avoid bootstrap blue colors** - use modern design systems1819. **Mobile-first responsive** - always design for smallest screen first18210. **Accessibility required** - ARIA labels, keyboard nav, semantic HTML, WCAG AA contrast183184## Keep this skill current185186When shadcn/ui, the Vite PWA plugin, or the MCP servers named here change an API or a component list, update the affected reference file in the same session. Replace the superseded text; do not append a note.