swift-design
This skill should be used when the user asks to "review SwiftUI code", "check HIG compliance", "audit iOS design quality", "generate SwiftUI views", "create an iOS screen", "improve SwiftUI design", "iterate on SwiftUI feedback", "fix accessibility in SwiftUI", "modernize SwiftUI code", "check deprecated APIs", "review this screenshot for iOS design", "add animations to SwiftUI", "add haptics to SwiftUI", or is working with SwiftUI views where design quality, accessibility, or Apple HIG compliance matters. Provides 40 enforceable rules, design token references, modern API guidance, animation/haptics patterns, and visual review rubrics for iOS design excellence.
What this skill does
# SwiftUI Design Excellence Encode Apple's Human Interface Guidelines as machine-enforceable rules for SwiftUI code review, generation, and iteration. Target: iOS 17+ by default (configurable via settings). ## Operational Modes ### Review Mode Accept SwiftUI code (files or inline) and evaluate against 40 enforceable rules. **Process:** 1. Read the target SwiftUI file(s) 2. Check settings for iOS target version and strictness — read `.claude/swift-design.local.md` if it exists (see Settings section below) 3. Load `references/review-checklist.md` for the complete rule set 4. Evaluate code against each applicable rule category in priority order: - Modern API compliance (M1–M6) — load `references/deprecated-apis.md` for replacement patterns - Accessibility (A1–A7) — load `references/accessibility-guide.md` for detailed checks - Platform idioms (P1–P6) — load `references/component-patterns.md` for correct patterns - Spacing & layout (S1–S7) - Typography (T1–T5) - Color & contrast (C1–C4) 5. Calculate letter grade per the rubric in `references/review-checklist.md` 6. Output findings grouped by severity: 🔴 Critical → 🟡 Warning → 🔵 Suggestion → 🟢 Praise 7. Each finding: rule ID, file:line, description, concrete fix **When iterating on existing code** (review + feedback argument): - Focus analysis on the areas mentioned in feedback - Load the relevant reference file for that area - Apply targeted improvements as a minimal diff - Re-run the checklist on modified code - Report what changed and the new grade ### Visual Review Mode Accept a screenshot or mockup of an iOS screen. **Process:** 1. Load `references/visual-review-rubric.md` 2. Evaluate the screenshot across 5 dimensions: - Platform nativeness (30% weight) - Visual hierarchy (25%) - Spacing consistency (20%) - Color coherence (15%) - Typography discipline (10%) 3. Score each dimension 1–5 with specific observations 4. Calculate weighted average and map to letter grade 5. Provide top 3 actionable improvements ### Generation Mode Accept a natural language description (or screenshot as reference) and produce HIG-compliant SwiftUI code. **Process:** 1. Load `references/design-tokens.md` for spacing, typography, color tokens 2. Load `references/hig-rules.md` for generation guidelines 3. Load `references/component-patterns.md` for structural patterns 4. Load `references/deprecated-apis.md` to ensure modern API usage 5. Generate SwiftUI code that: - Uses semantic font styles and colors - Follows 8pt spacing grid via design tokens - Handles all view states (loading, empty, error, content) - Includes accessibility labels and proper tap targets - Uses `@Observable`, `NavigationStack`, `Tab` API - Applies spring animations and appropriate haptics 6. Self-verify output against `references/review-checklist.md` 7. Output the code plus a design specification noting: - Type hierarchy used (which text styles, why) - Spacing choices (which tokens, why) - Color decisions (which semantic colors, why) - Accessibility considerations applied ## Settings Read settings from `.claude/swift-design.local.md` if present: ```yaml --- ios-target: 17 strictness: standard --- ``` **ios-target** (16 | 17 | 18, default: 17): - iOS 16: M2 (@Observable) becomes suggestion, M3 (Tab API) becomes suggestion - iOS 17: M3 (Tab API) becomes suggestion, all others at listed severity - iOS 18: All 40 rules at their listed severity **strictness** (relaxed | standard | strict, default: standard): - relaxed: Only 🔴 Critical rules reported - standard: 🔴 Critical + 🟡 Warning reported, 🔵 Suggestions at end - strict: All findings reported, grade penalizes suggestions ## Key Anti-Patterns The most common failures in AI-generated SwiftUI — check these first: 1. **NavigationStack wrapping TabView** (P2) — tab bar disappears during navigation 2. **NavigationView instead of NavigationStack** (M1) — deprecated since iOS 16 3. **ObservableObject instead of @Observable** (M2) — causes unnecessary re-renders 4. **Color.black/Color.white** (C1) — invisible in dark mode 5. **Hardcoded font sizes** (T1) — breaks Dynamic Type 6. **.onTapGesture instead of Button** (A4) — invisible to VoiceOver See `references/anti-patterns.md` for the complete anti-pattern catalog with examples. ## Reference Files Consult these for detailed guidance: | File | Contents | When to Load | |------|----------|-------------| | `references/review-checklist.md` | 40 rules, severity, grade rubric | Every review | | `references/deprecated-apis.md` | Before/after for every deprecated API | Reviews with modern API violations, generation | | `references/design-tokens.md` | Spacing, typography, color, radius tokens | Generation mode | | `references/hig-rules.md` | HIG fundamentals for generation | Generation mode | | `references/accessibility-guide.md` | VoiceOver, Dynamic Type, contrast, motor | Reviews with accessibility issues | | `references/component-patterns.md` | TabView, NavigationStack, List, Form, states | Reviews with structural issues, generation | | `references/animation-guide.md` | Spring animations, haptics, micro-interactions | Generation, animation reviews | | `references/visual-review-rubric.md` | 5-dimension screenshot evaluation | Visual review mode | | `references/anti-patterns.md` | AI-generated code smells and fixes | Quick checks, all reviews |
Related in Design
contribute
IncludedLocal-only OSS contribution command center. Auto-refreshes the user's in-flight PR and issue state on invoke so conversations start with full context — no need to brief Claude on what's in flight. Helps the user find issues to contribute to on GitHub, builds per-repo dossiers of what each upstream expects (CLA, DCO, branch convention, AI policy, draft-first, review bots, issue templates), runs deterministic gates before any external action so AI-assisted contributions don't reach maintainers as slop. State is markdown-only: candidate files at ~/.contribute-system/candidates/, repo dossiers at ~/.contribute-system/research/, append-only event log at ~/.contribute-system/log.jsonl. No database, no cloud calls. Use when the user asks about their PRs / issues / contributions, wants to find new work to take on, claim an issue, build/refresh a repo's dossier, or draft a Design Issue or PR. Trigger with "/contribute", "what's my PR status", "find a contribution", "claim issue X", "draft a Design Issue for Y", "refresh dossier for Z".
architectural-analysis
IncludedUser-triggered deep architectural analysis of a codebase or scoped subtree across eight modes — information architecture, data flow, integration points, UI surfaces, interaction patterns, data model, control flow, and failure modes. This skill should be used when the user asks to "diagram this codebase," "map the architecture," "show the data flow," "give me an ERD," "trace control flow," "find the integration points," "verify the layout pattern," "audit the UX architecture," or any similar request whose primary deliverable is mermaid diagrams plus cited reports under docs/architecture/. Dispatches haiku/sonnet sub-agents in parallel for per-mode exploration, then verifies every citation mechanically before any node lands in a diagram. Not for one-off prose explanations of code (use code-explanation) or for high-level system design from scratch (use system-design).
mcp
IncludedModel Context Protocol (MCP) server development and tool management. Languages: Python, TypeScript. Capabilities: build MCP servers, integrate external APIs, discover/execute MCP tools, manage multi-server configs, design agent-centric tools. Actions: create, build, integrate, discover, execute, configure MCP servers/tools. Keywords: MCP, Model Context Protocol, MCP server, MCP tool, stdio transport, SSE transport, tool discovery, resource provider, prompt template, external API integration, Gemini CLI MCP, Claude MCP, agent tools, tool execution, server config. Use when: building MCP servers, integrating external APIs as MCP tools, discovering available MCP tools, executing MCP capabilities, configuring multi-server setups, designing tools for AI agents.
react-native-skia
IncludedDesign, build, debug, and optimise high-polish animated graphics in React Native or Expo using @shopify/react-native-skia, Reanimated, and Gesture Handler. Use when the user wants canvas-driven UI, shaders, paths, rich text, image filters, sprite fields, Skottie, video frames, snapshots, web CanvasKit setup, or performance tuning for custom motion-heavy elements such as loaders, hero art, cards, charts, progress indicators, particle systems, or gesture-driven surfaces. Also use when the user asks for fluid, glow, glass, blob, parallax, 60fps/120fps, or GPU-friendly animated effects in React Native, even if they do not explicitly say "Skia". Do not use for ordinary form/layout work with standard views.
plaid
IncludedProduct Led AI Development — guides founders from idea to launched product. Six capabilities: Idea (discover a product idea), Validate (pressure-test the idea against fatal flaws, problem reality, competition, and 2-week MVP feasibility), Plan (vision intake + document generation), Design (translate image references into a design.md spec), Launch (go-to-market strategy), and Build (roadmap execution). Use when someone says "PLAID", "plaid idea", "help me find an idea", "product idea", "idea from my business", "idea from my expertise", "plaid validate", "validate my idea", "pressure-test", "is this idea good", "find fatal flaws", "validate the problem", "plan a product", "define my vision", "generate a PRD", "product strategy", "plaid design", "design from image", "translate image to design", "create design.md", "extract design tokens", "plaid launch", "go-to-market", "launch plan", "GTM strategy", "launch playbook", "plaid build", "build the app", "start building", or "execute the roadmap".
nextjs-framer-motion-animations
IncludedAdds production-safe Motion for React or Framer Motion animations to Next.js apps, including reveal, hover and tap micro-interactions, whileInView, stagger, AnimatePresence, layout and layoutId transitions, reorder, scroll-linked UI, and lightweight route-content transitions. Use when the user asks to add, refactor, or debug Motion or Framer Motion in App Router or Pages Router codebases, especially around server/client boundaries, reduced motion, LazyMotion, bundle size, hydration, or route transitions. Avoid for GSAP-style timelines, WebGL or 3D scenes, heavy scroll storytelling, or CSS-only effects unless Motion is explicitly requested.