Skills for Claude Code CLI such as full stack dev Cloudflare, React, Tailwind v4, and AI integrations.
Python aianthropicautomationclaude-codeclaude-skillscloudflaredevtoolsproductivityreactskillstailwindvite
feat(icon-design): Add icon selection skill with sub-agent
Jez72e667b15cbc
diff --git a/skills/icon-design/.claude-plugin/plugin.json b/skills/icon-design/.claude-plugin/plugin.jsonnew file mode 100644index 00000000..d463ca17--- /dev/null+++ b/skills/icon-design/.claude-plugin/plugin.json@@ -0,0 +1,12 @@+{+ "name": "icon-design",+ "description": "Select semantically appropriate icons for websites using Lucide, Heroicons, or Phosphor. Covers concept-to-icon mapping, React/HTML templates, and tree-shaking patterns. Use when: building feature sections, service grids, contact info, navigation, or any UI needing icons. Prevents emoji usage, ensures consistency.",+ "version": "1.0.0",+ "author": {+ "name": "Jeremy Dawes",+ "email": "[email protected]"+ },+ "license": "MIT",+ "repository": "https://github.com/jezweb/claude-skills",+ "keywords": []+}diff --git a/skills/icon-design/README.md b/skills/icon-design/README.mdnew file mode 100644index 00000000..3bae0ede--- /dev/null+++ b/skills/icon-design/README.md@@ -0,0 +1,67 @@+# Icon Design Skill++Select semantically appropriate icons for websites and applications.++## Auto-Trigger Keywords++This skill activates when discussing:++### Icon Libraries+- lucide, lucide-react, lucide icons+- heroicons, @heroicons/react, heroicons outline, heroicons solid+- phosphor, phosphor icons, @phosphor-icons/react+- icon library, icon package, icon set++### Selection Tasks+- which icon, what icon, select icon, choose icon, pick icon+- icon for, icon representing, icon that means+- feature icons, service icons, benefit icons+- navigation icons, menu icons, UI icons+- contact icons, social icons++### Specific Concepts+- trophy icon, award icon, quality icon+- price icon, value icon, money icon, tag icon+- location icon, map icon, pin icon+- support icon, chat icon, message icon+- security icon, shield icon, lock icon+- speed icon, fast icon, lightning icon, bolt icon+- phone icon, email icon, mail icon++### Templates & Patterns+- icon button, icon card, icon list+- inline icon, feature card icon+- icon with text, icon container+- icon styling, icon sizing++### Migration+- font awesome to lucide, fa to lucide+- material icons to lucide+- feather icons, feather to lucide+- replace emoji with icons+- icon migration++### Problems & Errors+- icons not showing, icon tree shaking+- icons all bundled, icon bundle size+- wrong icon, inappropriate icon+- icon consistency, icon style mismatch+- emoji instead of icon++## Quick Start++```tsx+// Install+npm install lucide-react++// Import specific icons (tree-shakeable)+import { Trophy, MapPin, Shield } from 'lucide-react'++// Use with Tailwind+<Trophy className="w-8 h-8 text-primary" />+```++## Related Skills++- `tailwind-v4-shadcn` - Semantic colour tokens+- `react-patterns` - Tree-shaking preventiondiff --git a/skills/icon-design/SKILL.md b/skills/icon-design/SKILL.mdnew file mode 100644index 00000000..76eb7f56--- /dev/null+++ b/skills/icon-design/SKILL.md@@ -0,0 +1,113 @@+---+name: icon-design+description: |+ Select semantically appropriate icons for websites using Lucide, Heroicons, or Phosphor. Covers concept-to-icon mapping, React/HTML templates, and tree-shaking patterns.++ Use when: building feature sections, service grids, contact info, navigation, or any UI needing icons. Prevents emoji usage, ensures consistency.+---++# Icon Design++Select the right icon for the job. Maps concepts to icons, provides templates, prevents common mistakes.++## Quick Reference (Top 20 Concepts)++| Concept | Lucide | Heroicons | Phosphor |+|---------|--------|-----------|----------|+| Award/Quality | `Trophy` | `trophy` | `Trophy` |+| Price/Value | `Tag` | `tag` | `Tag` |+| Location | `MapPin` | `map-pin` | `MapPin` |+| Expertise | `GraduationCap` | `academic-cap` | `GraduationCap` |+| Support | `MessageCircle` | `chat-bubble-left-right` | `ChatCircle` |+| Security | `Shield` | `shield-check` | `Shield` |+| Speed | `Zap` | `bolt` | `Lightning` |+| Phone | `Phone` | `phone` | `Phone` |+| Email | `Mail` | `envelope` | `Envelope` |+| User/Profile | `User` | `user` | `User` |+| Team | `Users` | `user-group` | `Users` |+| Settings | `Settings` | `cog-6-tooth` | `Gear` |+| Home | `Home` | `home` | `House` |+| Search | `Search` | `magnifying-glass` | `MagnifyingGlass` |+| Check/Success | `Check` | `check` | `Check` |+| Close/Cancel | `X` | `x-mark` | `X` |+| Menu | `Menu` | `bars-3` | `List` |+| Calendar | `Calendar` | `calendar` | `Calendar` |+| Clock/Time | `Clock` | `clock` | `Clock` |+| Heart/Favourite | `Heart` | `heart` | `Heart` |++## Library Selection++| Library | Best For | Package |+|---------|----------|---------|+| **Lucide** | General use, React projects | `lucide-react` |+| **Heroicons** | Tailwind projects, minimal style | `@heroicons/react` |+| **Phosphor** | Weight variations needed | `@phosphor-icons/react` |++**Default recommendation**: Lucide (1,400+ icons, excellent React integration)++See `references/library-comparison.md` for detailed comparison.++## Icon Style Rules++### Sizing++| Context | Tailwind Class | Pixels |+|---------|----------------|--------|+| Inline with text | `w-4 h-4` or `w-5 h-5` | 16-20px |+| Feature cards | `w-8 h-8` | 32px |+| Hero sections | `w-10 h-10` or `w-12 h-12` | 40-48px |+| Large decorative | `w-16 h-16` | 64px |++### Consistency Rules++1. **Never mix styles** - Use all outline OR all solid in a section+2. **Never use emoji** - Use proper icon components (tree-shakeable)+3. **Use currentColor** - Icons inherit text color via `stroke="currentColor"`+4. **Semantic colours** - Use `text-primary`, not `text-blue-500`++### Tree-Shaking (Critical)++Dynamic icon selection breaks tree-shaking. Use explicit maps:++```tsx+// BAD - all icons bundled+import * as Icons from 'lucide-react'+const Icon = Icons[iconName] // Tree-shaken away!++// GOOD - explicit map+import { Home, Users, Settings, type LucideIcon } from 'lucide-react'+const ICON_MAP: Record<string, LucideIcon> = { Home, Users, Settings }+const Icon = ICON_MAP[iconName]+```++## Selection Process++1. **Identify the concept** - What does the label/title communicate?+2. **Check semantic mapping** - See `references/semantic-mapping.md`+3. **Choose library** - Lucide (default), Heroicons (Tailwind), Phosphor (weights)+4. **Apply template** - See `references/icon-templates.md`+5. **Verify consistency** - Same style, same size in section++## Decision Tree++When unsure which icon:++```+Is it about recognition/awards? → Trophy, Star, Award+Is it about money/price? → Tag, DollarSign, CreditCard+Is it about location? → MapPin, Globe, Map+Is it about people/team? → Users, UserGroup, User+Is it about communication? → MessageCircle, Phone, Mail+Is it about safety/trust? → Shield, Lock, ShieldCheck+Is it about speed/time? → Zap, Clock, Timer+Is it trade-specific? → Check semantic-mapping.md+Still unsure? → CheckCircle (generic positive) or Sparkles (generic feature)+```++## Resources++- `references/semantic-mapping.md` - Full concept→icon tables by category+- `references/icon-templates.md` - React/HTML patterns with Tailwind+- `references/library-comparison.md` - Lucide vs Heroicons vs Phosphor+- `references/migration-guide.md` - FA/Material → modern equivalents+- `rules/icon-design.md` - Correction rules for projectsdiff --git a/skills/icon-design/agents/icon-selector.md b/skills/icon-design/agents/icon-selector.mdnew file mode 100644index 00000000..ef3711f5--- /dev/null+++ b/skills/icon-design/agents/icon-selector.md@@ -0,0 +1,133 @@+---+name: icon-selector+description: |+ Icon selection specialist. MUST BE USED when selecting icons, choosing icon libraries, auditing icon usage, or migrating from emoji/Font Awesome. Use PROACTIVELY for any icon-related task.+tools: Read, Write, Edit, Glob, Grep, Bash, WebFetch+model: sonnet+---++# Icon Selector Agent++You are an icon selection specialist that helps choose semantically appropriate icons for websites and applications.++## When Invoked++This agent handles:+- Selecting icons for feature sections, service grids, navigation+- Recommending icon libraries (Lucide, Heroicons, Phosphor)+- Auditing existing icon usage for consistency and appropriateness+- Migrating from emoji or legacy libraries (Font Awesome, Material)+- Resolving icon-related build issues (tree-shaking, bundle size)++## Process++### 1. Understand the Context++- What type of content? (features, services, contact, navigation)+- What framework? (React, Vue, vanilla HTML)+- Existing icon library in use? (check package.json)+- Design style? (minimal, detailed, branded)++### 2. Check Existing Patterns++If project already uses icons:+```bash+# Find icon imports+grep -r "lucide-react\|@heroicons\|@phosphor-icons" src/+```++Match existing library and style for consistency.++### 3. Select Icons++For each concept:+1. Read `~/.claude/skills/icon-design/references/semantic-mapping.md`+2. Find the category (Quality, Price, Location, Support, etc.)+3. Choose the best-match icon from the recommended library+4. Verify the icon visually represents the concept++### 4. Apply Templates++Read `~/.claude/skills/icon-design/references/icon-templates.md` for:+- Feature card icons (rounded containers)+- Inline icons (with text)+- Button icons+- Navigation icons++### 5. Verify Consistency++- All icons same style (outline OR solid)+- All icons same size within section+- Semantic colours used (text-primary, not text-blue-500)+- Tree-shaking safe imports++## Output Format++When selecting icons, provide a table:++| Concept | Icon | Library | Usage |+|---------|------|---------|-------|+| Award-Winning | `Trophy` | Lucide | Feature card |+| Local Business | `MapPin` | Lucide | Feature card |+| 24/7 Support | `MessageCircle` | Lucide | Feature card |++Then provide implementation code:++```tsx+import { Trophy, MapPin, MessageCircle } from 'lucide-react'++const features = [+ { icon: Trophy, title: 'Award-Winning', ... },+ { icon: MapPin, title: 'Local Business', ... },+ { icon: MessageCircle, title: '24/7 Support', ... },+]+```++## Library Recommendations++| Situation | Recommend |+|-----------|-----------|+| React + Tailwind project | Lucide or Heroicons |+| Need weight variations (thin/bold/fill) | Phosphor |+| Already using Feather | Migrate to Lucide |+| Minimal bundle size priority | Heroicons |+| Maximum icon variety | Phosphor |++## Migration Tasks++When migrating from legacy libraries:++1. Read `~/.claude/skills/icon-design/references/migration-guide.md`+2. Map old icons to modern equivalents+3. Update imports+4. Verify tree-shaking (no `import *`)+5. Test bundle size impact++## Audit Tasks++When auditing icon usage:++1. Find all icon imports: `grep -r "Icon\|lucide\|heroicon\|phosphor" src/`+2. Check for emoji usage: `grep -rE "[\x{1F300}-\x{1F9FF}]" src/` (approximate)+3. Verify consistent sizing within sections+4. Check for hardcoded colours (should use semantic tokens)+5. Ensure tree-shaking safe imports++## Common Corrections++| Issue | Fix |+|-------|-----|+| Emoji in UI | Replace with Lucide icon |+| Mixed styles | Standardize on outline OR solid |+| `import * as Icons` | Use named imports + ICON_MAP |+| `text-blue-500` | Use `text-primary` |+| Inconsistent sizes | Standardize per section |++## References++Always read these skill files:+- `~/.claude/skills/icon-design/SKILL.md` - Quick reference+- `~/.claude/skills/icon-design/references/semantic-mapping.md` - Concept→icon tables+- `~/.claude/skills/icon-design/references/icon-templates.md` - React patterns+- `~/.claude/skills/icon-design/references/library-comparison.md` - Library guide+- `~/.claude/skills/icon-design/references/migration-guide.md` - Migration mappingsdiff --git a/skills/icon-design/references/icon-templates.md b/skills/icon-design/references/icon-templates.mdnew file mode 100644index 00000000..04cdd217--- /dev/null+++ b/skills/icon-design/references/icon-templates.md@@ -0,0 +1,246 @@+# Icon Templates++Ready-to-use patterns for common icon layouts using Tailwind v4 semantic colours.++## Feature Card Icon (Rounded Square)++```tsx+import { Trophy } from 'lucide-react'++<div className="w-14 h-14 rounded-xl bg-primary/10 flex items-center justify-center">+ <Trophy className="w-8 h-8 text-primary" />+</div>+```++**Heroicons variant:**+```tsx+import { TrophyIcon } from '@heroicons/react/24/outline'++<div className="w-14 h-14 rounded-xl bg-primary/10 flex items-center justify-center">+ <TrophyIcon className="w-8 h-8 text-primary" />+</div>+```++## Feature Card Icon (Circle)++```tsx+import { Shield } from 'lucide-react'++<div className="w-12 h-12 rounded-full bg-primary/10 flex items-center justify-center">+ <Shield className="w-6 h-6 text-primary" />+</div>+```++## Inline Icon (Contact Info)++```tsx+import { Phone, Mail, MapPin } from 'lucide-react'++<span className="inline-flex items-center gap-2 text-muted-foreground">+ <Phone className="w-4 h-4" />+ <span>1300 123 456</span>+</span>++<span className="inline-flex items-center gap-2 text-muted-foreground">+ <Mail className="w-4 h-4" />+ <span>[email protected]</span>+</span>++<span className="inline-flex items-center gap-2 text-muted-foreground">+ <MapPin className="w-4 h-4" />+ <span>Sydney, Australia</span>+</span>+```++## List Item with Icon++```tsx+import { Check } from 'lucide-react'++<ul className="space-y-3">+ <li className="flex items-start gap-3">+ <Check className="w-5 h-5 text-primary flex-shrink-0 mt-0.5" />+ <span>First benefit or feature</span>+ </li>+ <li className="flex items-start gap-3">+ <Check className="w-5 h-5 text-primary flex-shrink-0 mt-0.5" />+ <span>Second benefit or feature</span>+ </li>+</ul>+```++## Button with Icon++```tsx+import { ArrowRight } from 'lucide-react'++// Primary button+<button className="inline-flex items-center gap-2 px-4 py-2 bg-primary text-primary-foreground rounded-lg hover:bg-primary/90">+ <span>Get Started</span>+ <ArrowRight className="w-4 h-4" />+</button>++// Secondary/outline button+<button className="inline-flex items-center gap-2 px-4 py-2 border border-border rounded-lg hover:bg-muted">+ <span>Learn More</span>+ <ArrowRight className="w-4 h-4" />+</button>+```++## Icon-Only Button++```tsx+import { Menu, X, Search } from 'lucide-react'++// Mobile menu toggle+<button+ className="p-2 rounded-lg hover:bg-muted transition-colors"+ aria-label="Open menu"+>+ <Menu className="w-6 h-6" />+</button>++// Close button+<button+ className="p-2 rounded-lg hover:bg-muted transition-colors"+ aria-label="Close"+>+ <X className="w-5 h-5" />+</button>++// Search button+<button+ className="p-2 rounded-lg hover:bg-muted transition-colors"+ aria-label="Search"+>+ <Search className="w-5 h-5" />+</button>+```++## Feature Grid Card++```tsx+import { Shield, Zap, Users, Trophy } from 'lucide-react'++const features = [+ { icon: Shield, title: 'Secure', description: 'Enterprise-grade security' },+ { icon: Zap, title: 'Fast', description: 'Lightning quick response' },+ { icon: Users, title: 'Support', description: '24/7 expert help' },+ { icon: Trophy, title: 'Award-Winning', description: 'Industry recognized' },+]++<div className="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-4 gap-6">+ {features.map(({ icon: Icon, title, description }) => (+ <div key={title} className="p-6 rounded-xl bg-card border border-border">+ <div className="w-12 h-12 rounded-lg bg-primary/10 flex items-center justify-center mb-4">+ <Icon className="w-6 h-6 text-primary" />+ </div>+ <h3 className="font-semibold text-card-foreground mb-2">{title}</h3>+ <p className="text-sm text-muted-foreground">{description}</p>+ </div>+ ))}+</div>+```++## Status Badge with Icon++```tsx+import { CheckCircle, XCircle, AlertTriangle, Clock } from 'lucide-react'++// Success+<span className="inline-flex items-center gap-1.5 px-2.5 py-1 rounded-full bg-green-500/10 text-green-600 text-sm">+ <CheckCircle className="w-4 h-4" />+ <span>Active</span>+</span>++// Error+<span className="inline-flex items-center gap-1.5 px-2.5 py-1 rounded-full bg-destructive/10 text-destructive text-sm">+ <XCircle className="w-4 h-4" />+ <span>Failed</span>+</span>++// Warning+<span className="inline-flex items-center gap-1.5 px-2.5 py-1 rounded-full bg-yellow-500/10 text-yellow-600 text-sm">+ <AlertTriangle className="w-4 h-4" />+ <span>Warning</span>+</span>++// Pending+<span className="inline-flex items-center gap-1.5 px-2.5 py-1 rounded-full bg-muted text-muted-foreground text-sm">+ <Clock className="w-4 h-4" />+ <span>Pending</span>+</span>+```++## Navigation Item++```tsx+import { Home, Users, Settings, type LucideIcon } from 'lucide-react'++interface NavItemProps {+ icon: LucideIcon+ label: string+ href: string+ active?: boolean+}++function NavItem({ icon: Icon, label, href, active }: NavItemProps) {+ return (+ <a+ href={href}+ className={cn(+ 'flex items-center gap-3 px-3 py-2 rounded-lg transition-colors',+ active+ ? 'bg-primary/10 text-primary'+ : 'text-muted-foreground hover:bg-muted hover:text-foreground'+ )}+ >+ <Icon className="w-5 h-5" />+ <span>{label}</span>+ </a>+ )+}+```++## Input with Icon++```tsx+import { Search, Mail } from 'lucide-react'++// Search input+<div className="relative">+ <Search className="absolute left-3 top-1/2 -translate-y-1/2 w-4 h-4 text-muted-foreground" />+ <input+ type="text"+ placeholder="Search..."+ className="w-full pl-10 pr-4 py-2 rounded-lg border border-border bg-background focus:outline-none focus:ring-2 focus:ring-primary"+ />+</div>++// Email input+<div className="relative">+ <Mail className="absolute left-3 top-1/2 -translate-y-1/2 w-4 h-4 text-muted-foreground" />+ <input+ type="email"+ placeholder="Enter your email"+ className="w-full pl-10 pr-4 py-2 rounded-lg border border-border bg-background focus:outline-none focus:ring-2 focus:ring-primary"+ />+</div>+```++---++## Colour Reference++All templates use Tailwind v4 semantic tokens:++| Token | Use |+|-------|-----|+| `text-primary` | Icon accent colour |+| `bg-primary/10` | Icon background (10% opacity) |+| `text-muted-foreground` | Secondary/subtle icons |+| `text-foreground` | Default icon colour |+| `text-card-foreground` | Icons on card backgrounds |+| `text-destructive` | Error/delete icons |++**Never use raw colours** like `text-blue-500` - always use semantic tokens.diff --git a/skills/icon-design/references/library-comparison.md b/skills/icon-design/references/library-comparison.mdnew file mode 100644index 00000000..d862a764--- /dev/null+++ b/skills/icon-design/references/library-comparison.md@@ -0,0 +1,199 @@+# Icon Library Comparison++Detailed comparison of Lucide, Heroicons, and Phosphor icon libraries.++## Overview++| Feature | Lucide | Heroicons | Phosphor |+|---------|--------|-----------|----------|+| **Icons** | 1,400+ | 292 | 7,000+ |+| **Weights** | 1 | 2 (outline, solid) | 6 (thin→fill) |+| **Package** | `lucide-react` | `@heroicons/react` | `@phosphor-icons/react` |+| **Size (gzip)** | ~5KB per icon set | ~3KB | ~7KB |+| **Tree-shakeable** | Yes | Yes | Yes |+| **License** | ISC | MIT | MIT |+| **Origin** | Fork of Feather | Tailwind Labs | Independent |++## When to Use Each++### Lucide (Default Recommendation)++**Best for:**+- React/Vue/Svelte projects+- General-purpose applications+- When you need variety (1,400+ icons)+- Teams already familiar with Feather Icons++**Installation:**+```bash+npm install lucide-react+```++**Usage:**+```tsx+import { Home, Settings, User } from 'lucide-react'++<Home className="w-6 h-6" />+<Settings className="w-6 h-6" strokeWidth={1.5} />+```++**Pros:**+- Large library with frequent updates+- Excellent React integration+- Fork of popular Feather Icons+- PascalCase component names+- Customizable stroke width++**Cons:**+- No weight variations (outline only)+- Some inconsistency from community contributions++---++### Heroicons++**Best for:**+- Tailwind CSS projects+- Minimal, clean aesthetic+- Projects using Tailwind UI components+- When you need outline AND solid variants++**Installation:**+```bash+npm install @heroicons/react+```++**Usage:**+```tsx+// Outline (24px)+import { HomeIcon } from '@heroicons/react/24/outline'++// Solid (24px)+import { HomeIcon } from '@heroicons/react/24/solid'++// Mini (20px)+import { HomeIcon } from '@heroicons/react/20/solid'++<HomeIcon className="w-6 h-6" />+```++**Pros:**+- Official Tailwind integration+- Consistent, polished design+- Two styles (outline/solid) per icon+- Three sizes (16, 20, 24px)+- kebab-case naming matches Tailwind++**Cons:**+- Smaller library (292 icons)+- Only 2 weight variations+- Import paths can be verbose++---++### Phosphor++**Best for:**+- When you need weight variations (thin, light, regular, bold, fill, duotone)+- Large icon needs (7,000+ icons)+- Design-heavy projects+- When brand consistency requires specific weights++**Installation:**+```bash+npm install @phosphor-icons/react+```++**Usage:**+```tsx+import { House, Gear, User } from '@phosphor-icons/react'++// Default (regular weight)+<House size={24} />++// Specific weights+<House size={24} weight="thin" />+<House size={24} weight="light" />+<House size={24} weight="regular" />+<House size={24} weight="bold" />+<House size={24} weight="fill" />+<House size={24} weight="duotone" />+```++**Pros:**+- Largest library (7,000+ icons)+- 6 weight variations per icon+- Consistent design language+- Duotone variant is unique++**Cons:**+- Larger bundle if using multiple weights+- Less React-ecosystem adoption+- PascalCase differs from Tailwind conventions++---++## Import Patterns++### Tree-Shaking Safe++All three libraries support tree-shaking when importing specific icons:++```tsx+// Lucide - GOOD+import { Home, User, Settings } from 'lucide-react'++// Heroicons - GOOD+import { HomeIcon, UserIcon } from '@heroicons/react/24/outline'++// Phosphor - GOOD+import { House, User, Gear } from '@phosphor-icons/react'+```++### Dynamic Icons (All Libraries)++**Never do this** (breaks tree-shaking):+```tsx+import * as Icons from 'lucide-react'+const Icon = Icons[iconName] // All icons bundled!+```++**Do this instead** (explicit map):+```tsx+import { Home, User, Settings, type LucideIcon } from 'lucide-react'++const ICON_MAP: Record<string, LucideIcon> = {+ home: Home,+ user: User,+ settings: Settings,+}++const Icon = ICON_MAP[iconName]+```++---++## Size Comparison++For a typical project using 20 icons:++| Library | Bundle Impact |+|---------|---------------|+| Lucide | ~15KB |+| Heroicons | ~12KB |+| Phosphor (single weight) | ~18KB |+| Phosphor (6 weights) | ~100KB |++---++## Recommendation Matrix++| Project Type | Recommended Library |+|--------------|---------------------|+| React + Tailwind | Heroicons or Lucide |+| React general | Lucide |+| Vue/Svelte | Lucide |+| Design-heavy, brand-consistent | Phosphor |+| Minimal bundle size | Heroicons |+| Maximum icon variety | Phosphor |+| Legacy Feather migration | Lucide |diff --git a/skills/icon-design/references/migration-guide.md b/skills/icon-design/references/migration-guide.mdnew file mode 100644index 00000000..5014827e--- /dev/null+++ b/skills/icon-design/references/migration-guide.md@@ -0,0 +1,177 @@+# Icon Migration Guide++Migrate from legacy icon libraries to modern alternatives.++## Font Awesome → Lucide/Phosphor++### Common Mappings++| Font Awesome | Lucide | Phosphor |+|--------------|--------|----------|+| `fa-home` | `Home` | `House` |+| `fa-user` | `User` | `User` |+| `fa-users` | `Users` | `Users` |+| `fa-cog` / `fa-gear` | `Settings` | `Gear` |+| `fa-search` | `Search` | `MagnifyingGlass` |+| `fa-envelope` | `Mail` | `Envelope` |+| `fa-phone` | `Phone` | `Phone` |+| `fa-map-marker` | `MapPin` | `MapPin` |+| `fa-check` | `Check` | `Check` |+| `fa-times` / `fa-close` | `X` | `X` |+| `fa-plus` | `Plus` | `Plus` |+| `fa-minus` | `Minus` | `Minus` |+| `fa-trash` | `Trash2` | `Trash` |+| `fa-edit` / `fa-pencil` | `Pencil` | `Pencil` |+| `fa-star` | `Star` | `Star` |+| `fa-heart` | `Heart` | `Heart` |+| `fa-bell` | `Bell` | `Bell` |+| `fa-calendar` | `Calendar` | `Calendar` |+| `fa-clock` | `Clock` | `Clock` |+| `fa-file` | `File` | `File` |+| `fa-folder` | `Folder` | `Folder` |+| `fa-download` | `Download` | `Download` |+| `fa-upload` | `Upload` | `Upload` |+| `fa-share` | `Share2` | `Share` |+| `fa-link` | `Link` | `Link` |+| `fa-lock` | `Lock` | `Lock` |+| `fa-unlock` | `Unlock` | `LockOpen` |+| `fa-eye` | `Eye` | `Eye` |+| `fa-eye-slash` | `EyeOff` | `EyeSlash` |+| `fa-bars` | `Menu` | `List` |+| `fa-arrow-right` | `ArrowRight` | `ArrowRight` |+| `fa-arrow-left` | `ArrowLeft` | `ArrowLeft` |+| `fa-chevron-down` | `ChevronDown` | `CaretDown` |+| `fa-chevron-up` | `ChevronUp` | `CaretUp` |+| `fa-external-link` | `ExternalLink` | `ArrowSquareOut` |+| `fa-shopping-cart` | `ShoppingCart` | `ShoppingCart` |+| `fa-credit-card` | `CreditCard` | `CreditCard` |+| `fa-dollar` | `DollarSign` | `CurrencyDollar` |+| `fa-percent` | `Percent` | `Percent` |+| `fa-tag` | `Tag` | `Tag` |+| `fa-gift` | `Gift` | `Gift` |+| `fa-trophy` | `Trophy` | `Trophy` |+| `fa-shield` | `Shield` | `Shield` |+| `fa-bolt` / `fa-lightning` | `Zap` | `Lightning` |+| `fa-spinner` | `Loader2` | `CircleNotch` |++### Font Awesome Styles → Modern Equivalents++| FA Style | Lucide | Heroicons | Phosphor |+|----------|--------|-----------|----------|+| `fa-regular` (outline) | Default | `/24/outline` | `weight="regular"` |+| `fa-solid` | N/A | `/24/solid` | `weight="fill"` |+| `fa-light` | N/A | N/A | `weight="light"` |+| `fa-thin` | N/A | N/A | `weight="thin"` |+| `fa-duotone` | N/A | N/A | `weight="duotone"` |++---++## Material Icons → Lucide/Phosphor++### Common Mappings++| Material Icon | Lucide | Phosphor |+|---------------|--------|----------|+| `home` | `Home` | `House` |+| `person` | `User` | `User` |+| `people` / `group` | `Users` | `Users` |+| `settings` | `Settings` | `Gear` |+| `search` | `Search` | `MagnifyingGlass` |+| `mail` / `email` | `Mail` | `Envelope` |+| `phone` | `Phone` | `Phone` |+| `place` / `location_on` | `MapPin` | `MapPin` |+| `check` | `Check` | `Check` |+| `close` | `X` | `X` |+| `add` | `Plus` | `Plus` |+| `remove` | `Minus` | `Minus` |+| `delete` | `Trash2` | `Trash` |+| `edit` | `Pencil` | `Pencil` |+| `star` | `Star` | `Star` |+| `favorite` | `Heart` | `Heart` |+| `notifications` | `Bell` | `Bell` |+| `event` / `calendar_today` | `Calendar` | `Calendar` |+| `schedule` / `access_time` | `Clock` | `Clock` |+| `description` | `FileText` | `FileText` |+| `folder` | `Folder` | `Folder` |+| `file_download` | `Download` | `Download` |+| `file_upload` | `Upload` | `Upload` |+| `share` | `Share2` | `Share` |+| `link` | `Link` | `Link` |+| `lock` | `Lock` | `Lock` |+| `lock_open` | `Unlock` | `LockOpen` |+| `visibility` | `Eye` | `Eye` |+| `visibility_off` | `EyeOff` | `EyeSlash` |+| `menu` | `Menu` | `List` |+| `arrow_forward` | `ArrowRight` | `ArrowRight` |+| `arrow_back` | `ArrowLeft` | `ArrowLeft` |+| `expand_more` | `ChevronDown` | `CaretDown` |+| `expand_less` | `ChevronUp` | `CaretUp` |+| `open_in_new` | `ExternalLink` | `ArrowSquareOut` |+| `shopping_cart` | `ShoppingCart` | `ShoppingCart` |+| `credit_card` | `CreditCard` | `CreditCard` |+| `attach_money` | `DollarSign` | `CurrencyDollar` |+| `local_offer` | `Tag` | `Tag` |+| `card_giftcard` | `Gift` | `Gift` |+| `emoji_events` | `Trophy` | `Trophy` |+| `security` | `Shield` | `Shield` |+| `flash_on` / `bolt` | `Zap` | `Lightning` |+| `autorenew` / `sync` | `RefreshCw` | `ArrowsClockwise` |++---++## Feather Icons → Lucide++Lucide is a direct fork of Feather Icons with the same naming:++| Feather | Lucide |+|---------|--------|+| `feather-home` | `Home` |+| `feather-user` | `User` |+| `feather-settings` | `Settings` |+| ... | (same names, PascalCase) |++**Migration is straightforward:**+```tsx+// Before (Feather)+import { Home, User, Settings } from 'feather-icons-react'++// After (Lucide)+import { Home, User, Settings } from 'lucide-react'+```++---++## Emoji → Icons++**Never use emoji for UI icons.** Replace with proper icon components:++| Emoji | Lucide | Heroicons | Phosphor |+|-------|--------|-----------|----------|+| ✅ | `Check` | `check` | `Check` |+| ❌ | `X` | `x-mark` | `X` |+| ⚠️ | `AlertTriangle` | `exclamation-triangle` | `Warning` |+| ℹ️ | `Info` | `information-circle` | `Info` |+| 📞 | `Phone` | `phone` | `Phone` |+| ✉️ | `Mail` | `envelope` | `Envelope` |+| 📍 | `MapPin` | `map-pin` | `MapPin` |+| 🔒 | `Lock` | `lock-closed` | `Lock` |+| ⚡ | `Zap` | `bolt` | `Lightning` |+| ⭐ | `Star` | `star` | `Star` |+| ❤️ | `Heart` | `heart` | `Heart` |+| 🏆 | `Trophy` | `trophy` | `Trophy` |+| 🎁 | `Gift` | `gift` | `Gift` |+| 🔔 | `Bell` | `bell` | `Bell` |+| 📅 | `Calendar` | `calendar` | `Calendar` |+| ⏰ | `Clock` | `clock` | `Clock` |+| 🔍 | `Search` | `magnifying-glass` | `MagnifyingGlass` |+| 👤 | `User` | `user` | `User` |+| 👥 | `Users` | `user-group` | `Users` |+| 🏠 | `Home` | `home` | `House` |+| ⚙️ | `Settings` | `cog-6-tooth` | `Gear` |++**Why icons over emoji:**+1. **Consistency** - Same style across all icons+2. **Accessibility** - Screen readers handle them better+3. **Styling** - Can change colour, size, stroke width+4. **Performance** - Tree-shakeable, no font loading+5. **Professional** - Emoji render differently across platformsdiff --git a/skills/icon-design/references/semantic-mapping.md b/skills/icon-design/references/semantic-mapping.mdnew file mode 100644index 00000000..3f6bb1a6--- /dev/null+++ b/skills/icon-design/references/semantic-mapping.md@@ -0,0 +1,190 @@+# Semantic Icon Mapping++Maps concepts to icons across Lucide, Heroicons, and Phosphor libraries.++## How to Use++1. Find the category matching your content+2. Look up the specific concept+3. Choose from recommended icons (first is best match)+4. Use the icon name for your chosen library++---++## Quality & Recognition++| Concept | Lucide | Heroicons | Phosphor |+|---------|--------|-----------|----------|+| Award-Winning | `Trophy` | `trophy` | `Trophy` |+| Quality Assured | `BadgeCheck` | `badge-check` | `SealCheck` |+| Certified | `Award` | `document-check` | `Certificate` |+| Excellence | `Star` | `star` | `Star` |+| Trusted | `ShieldCheck` | `shield-check` | `ShieldCheck` |+| Verified | `CheckCircle` | `check-badge` | `CheckCircle` |+| Best/Top Rated | `Crown` | `star` | `Crown` |+| Premium | `Gem` | `sparkles` | `Diamond` |++## Price & Value++| Concept | Lucide | Heroicons | Phosphor |+|---------|--------|-----------|----------|+| Best Price | `Tag` | `tag` | `Tag` |+| Value | `Gift` | `gift` | `Gift` |+| Savings | `Percent` | `receipt-percent` | `Percent` |+| Free Quote | `FileText` | `document-text` | `FileText` |+| Affordable | `DollarSign` | `currency-dollar` | `CurrencyDollar` |+| No Hidden Fees | `Eye` | `eye` | `Eye` |+| Budget Friendly | `Wallet` | `wallet` | `Wallet` |+| Money Back | `RefreshCcw` | `arrow-path` | `ArrowCounterClockwise` |++## Location & Local++| Concept | Lucide | Heroicons | Phosphor |+|---------|--------|-----------|----------|+| Local Business | `MapPin` | `map-pin` | `MapPin` |+| Location | `MapPin` | `map-pin` | `MapPin` |+| Service Area | `Map` | `map` | `Map` |+| Australian | `Globe` | `globe-alt` | `Globe` |+| Community | `Users` | `users` | `Users` |+| Nearby | `Navigation` | `map-pin` | `NavigationArrow` |+| Address | `MapPin` | `map-pin` | `MapPin` |+| Directions | `Route` | `map` | `Path` |++## Expertise & Professional++| Concept | Lucide | Heroicons | Phosphor |+|---------|--------|-----------|----------|+| Expert | `GraduationCap` | `academic-cap` | `GraduationCap` |+| Professional | `Briefcase` | `briefcase` | `Briefcase` |+| Experienced | `Clock` | `clock` | `Clock` |+| Team | `Users` | `user-group` | `Users` |+| Qualified | `FileCheck` | `document-check` | `FileCheck` |+| Specialists | `Beaker` | `beaker` | `Flask` |+| Industry Leader | `TrendingUp` | `arrow-trending-up` | `TrendUp` |+| Knowledge | `BookOpen` | `book-open` | `BookOpen` |++## Support & Service++| Concept | Lucide | Heroicons | Phosphor |+|---------|--------|-----------|----------|+| Support | `MessageCircle` | `chat-bubble-left-right` | `ChatCircle` |+| Contact | `Phone` | `phone` | `Phone` |+| Help | `LifeBuoy` | `lifebuoy` | `Lifebuoy` |+| Available | `Clock` | `clock` | `Clock` |+| Responsive | `Zap` | `bolt` | `Lightning` |+| Friendly | `Smile` | `face-smile` | `Smiley` |+| Live Chat | `MessageSquare` | `chat-bubble-left` | `Chat` |+| FAQ | `HelpCircle` | `question-mark-circle` | `Question` |++## Security & Trust++| Concept | Lucide | Heroicons | Phosphor |+|---------|--------|-----------|----------|+| Secure | `Shield` | `shield-check` | `Shield` |+| Safe | `ShieldCheck` | `shield-check` | `ShieldCheck` |+| Protected | `Lock` | `lock-closed` | `Lock` |+| Private | `EyeOff` | `eye-slash` | `EyeSlash` |+| Insured | `FileCheck` | `document-check` | `FileCheck` |+| Licensed | `BadgeCheck` | `badge-check` | `Certificate` |+| Encrypted | `KeyRound` | `key` | `Key` |+| Warranty | `Shield` | `shield-check` | `ShieldCheck` |++## Speed & Efficiency++| Concept | Lucide | Heroicons | Phosphor |+|---------|--------|-----------|----------|+| Fast | `Zap` | `bolt` | `Lightning` |+| Quick | `Clock` | `clock` | `Clock` |+| Efficient | `TrendingUp` | `arrow-trending-up` | `TrendUp` |+| Same Day | `Calendar` | `calendar` | `Calendar` |+| Emergency | `AlertTriangle` | `exclamation-triangle` | `Warning` |+| 24/7 | `Clock` | `clock` | `Clock` |+| Instant | `Zap` | `bolt` | `Lightning` |+| On Time | `Timer` | `clock` | `Timer` |++## Trade-Specific++| Concept | Lucide | Heroicons | Phosphor |+|---------|--------|-----------|----------|+| Tools/Repairs | `Wrench` | `wrench-screwdriver` | `Wrench` |+| Electrical | `Zap` | `bolt` | `Lightning` |+| Plumbing | `Droplet` | `beaker` | `Drop` |+| Building | `Building2` | `building-office-2` | `Buildings` |+| Roofing | `Home` | `home` | `House` |+| Cleaning | `Sparkles` | `sparkles` | `Sparkle` |+| Transport | `Truck` | `truck` | `Truck` |+| Food/Restaurant | `UtensilsCrossed` | `cake` | `ForkKnife` |+| Health/Medical | `Heart` | `heart` | `Heart` |+| Legal | `Scale` | `scale` | `Scales` |+| Finance | `Banknote` | `banknotes` | `Money` |+| Education | `GraduationCap` | `academic-cap` | `GraduationCap` |+| Technology | `Cpu` | `cpu-chip` | `Cpu` |+| Creative | `Palette` | `paint-brush` | `Palette` |+| Photography | `Camera` | `camera` | `Camera` |+| Music | `Music` | `musical-note` | `MusicNote` |+| Fitness | `Dumbbell` | `heart` | `Barbell` |+| Real Estate | `Home` | `home` | `House` |+| Automotive | `Car` | `truck` | `Car` |+| Agriculture | `Leaf` | `leaf` | `Leaf` |++## Contact Information++| Element | Lucide | Heroicons | Phosphor |+|---------|--------|-----------|----------|+| Phone | `Phone` | `phone` | `Phone` |+| Mobile | `Smartphone` | `device-phone-mobile` | `DeviceMobile` |+| Email | `Mail` | `envelope` | `Envelope` |+| Address | `MapPin` | `map-pin` | `MapPin` |+| Website | `Globe` | `globe-alt` | `Globe` |+| Hours | `Clock` | `clock` | `Clock` |++**Social Media** (use brand SVGs, not icon libraries):+- Facebook, Instagram, LinkedIn, Twitter/X, YouTube+- Download from official brand resources or use `react-icons/fa`++## Navigation & Actions++| Element | Lucide | Heroicons | Phosphor |+|---------|--------|-----------|----------|+| Menu | `Menu` | `bars-3` | `List` |+| Close | `X` | `x-mark` | `X` |+| Back | `ArrowLeft` | `arrow-left` | `ArrowLeft` |+| Forward | `ArrowRight` | `arrow-right` | `ArrowRight` |+| Up | `ArrowUp` | `arrow-up` | `ArrowUp` |+| Down | `ArrowDown` | `arrow-down` | `ArrowDown` |+| Home | `Home` | `home` | `House` |+| Search | `Search` | `magnifying-glass` | `MagnifyingGlass` |+| Filter | `Filter` | `funnel` | `Funnel` |+| Sort | `ArrowUpDown` | `arrows-up-down` | `ArrowsDownUp` |+| Settings | `Settings` | `cog-6-tooth` | `Gear` |+| User | `User` | `user` | `User` |+| Logout | `LogOut` | `arrow-right-on-rectangle` | `SignOut` |+| Login | `LogIn` | `arrow-left-on-rectangle` | `SignIn` |++## Status & Feedback++| Element | Lucide | Heroicons | Phosphor |+|---------|--------|-----------|----------|+| Success | `CheckCircle` | `check-circle` | `CheckCircle` |+| Error | `XCircle` | `x-circle` | `XCircle` |+| Warning | `AlertTriangle` | `exclamation-triangle` | `Warning` |+| Info | `Info` | `information-circle` | `Info` |+| Loading | `Loader2` | `arrow-path` | `CircleNotch` |+| Pending | `Clock` | `clock` | `Clock` |++---++## Decision Tree++When the concept doesn't match tables above:++1. **Is it about achievement/quality?** → Trophy, Star, Award, BadgeCheck+2. **Is it about money/cost?** → Tag, DollarSign, Wallet, Percent+3. **Is it about place/location?** → MapPin, Globe, Map, Navigation+4. **Is it about people/users?** → User, Users, UserGroup+5. **Is it about communication?** → MessageCircle, Phone, Mail, Chat+6. **Is it about safety/security?** → Shield, Lock, ShieldCheck, Key+7. **Is it about time/speed?** → Zap, Clock, Timer, Calendar+8. **Is it industry-specific?** → Check Trade-Specific table+9. **Generic positive?** → CheckCircle, ThumbsUp, Sparkles+10. **Generic feature?** → Sparkles, Star, Zapdiff --git a/skills/icon-design/rules/icon-design.md b/skills/icon-design/rules/icon-design.mdnew file mode 100644index 00000000..190493f6--- /dev/null+++ b/skills/icon-design/rules/icon-design.md@@ -0,0 +1,145 @@+# Icon Design Rules++Correction rules for icon usage in React/TypeScript projects.++## Never Use Emoji for UI Icons++Emoji render inconsistently across platforms and can't be styled.++| If Claude suggests... | Use instead... |+|----------------------|----------------|+| `<span>✅</span>` | `<Check className="w-4 h-4" />` |+| `<span>⚠️</span>` | `<AlertTriangle className="w-4 h-4" />` |+| `✉️ Email` | `<Mail className="w-4 h-4" /> Email` |+| `📍 Location` | `<MapPin className="w-4 h-4" /> Location` |++## Tree-Shaking Prevention++Dynamic icon access breaks tree-shaking, bundling ALL icons.++| If Claude suggests... | Use instead... |+|----------------------|----------------|+| `import * as Icons from 'lucide-react'` | Named imports only |+| `Icons[iconName]` | Explicit `ICON_MAP` object |+| `require('lucide-react')[name]` | Static imports |++Correct pattern:++```tsx+import { Home, User, Settings, type LucideIcon } from 'lucide-react'++const ICON_MAP: Record<string, LucideIcon> = {+ home: Home,+ user: User,+ settings: Settings,+}++const Icon = ICON_MAP[iconName]+if (!Icon) throw new Error(`Unknown icon: ${iconName}`)+```++## Use Semantic Colours++Icons should use Tailwind v4 semantic tokens, not raw colours.++| If Claude suggests... | Use instead... |+|----------------------|----------------|+| `className="text-blue-500"` | `className="text-primary"` |+| `className="text-gray-500"` | `className="text-muted-foreground"` |+| `className="text-red-500"` | `className="text-destructive"` |+| `stroke="#3B82F6"` | `className="text-primary"` (uses currentColor) |++## Consistent Sizing++Use standard size classes within a section.++| Context | Class | Notes |+|---------|-------|-------|+| Inline text | `w-4 h-4` or `w-5 h-5` | Match line height |+| Feature cards | `w-6 h-6` to `w-8 h-8` | Inside container |+| Hero sections | `w-10 h-10` to `w-12 h-12` | Decorative |++| If Claude suggests... | Use instead... |+|----------------------|----------------|+| Mixed sizes in one section | Same size for all icons in section |+| `size={24}` (Phosphor) | `className="w-6 h-6"` (Tailwind) |+| `width="20" height="20"` | `className="w-5 h-5"` |++## Style Consistency++Never mix outline and solid icons in the same section.++| If Claude suggests... | Use instead... |+|----------------------|----------------|+| `CheckIcon` (solid) next to `HomeIcon` (outline) | All outline OR all solid |+| Heroicons `/24/outline` mixed with `/24/solid` | Pick one style for section |+| Phosphor `weight="fill"` mixed with `weight="regular"` | Single weight per section |++## Heroicons Import Paths++Heroicons have specific import paths for sizes and styles.++| If Claude suggests... | Use instead... |+|----------------------|----------------|+| `@heroicons/react/outline` | `@heroicons/react/24/outline` |+| `@heroicons/react/solid` | `@heroicons/react/24/solid` |+| `import { Home }` | `import { HomeIcon }` (suffix required) |++Correct patterns:++```tsx+// 24px outline (default)+import { HomeIcon } from '@heroicons/react/24/outline'++// 24px solid+import { HomeIcon } from '@heroicons/react/24/solid'++// 20px solid (mini)+import { HomeIcon } from '@heroicons/react/20/solid'+```++## Accessibility++Decorative icons need proper handling.++| If Claude suggests... | Use instead... |+|----------------------|----------------|+| `<Icon />` (no label) | `<Icon aria-hidden="true" />` or with `aria-label` |+| Icon-only button without label | Add `aria-label="Description"` to button |++Correct patterns:++```tsx+// Decorative icon (alongside text)+<span className="flex items-center gap-2">+ <Phone aria-hidden="true" className="w-4 h-4" />+ <span>Call us</span>+</span>++// Icon-only button+<button aria-label="Open menu">+ <Menu className="w-6 h-6" />+</button>++// Meaningful standalone icon+<CheckCircle aria-label="Completed" className="w-5 h-5 text-green-500" />+```++## Lucide Wrapper Elements++Lucide icons don't accept HTML attributes like `title` directly.++| If Claude suggests... | Use instead... |+|----------------------|----------------|+| `<Trophy title="Award" />` | `<span title="Award"><Trophy /></span>` |+| `<Icon aria-label="..." />` | Wrap in element with aria-label |++## currentColor Pattern++Icons should inherit colour from parent text.++| If Claude suggests... | Use instead... |+|----------------------|----------------|+| `stroke="#000000"` | Use default (currentColor) |+| `fill="blue"` | `className="text-primary"` |+| Hardcoded colours in SVG | Let CSS control via currentColor |