Commit Graph

3 Commits

  • feat(icons): add PackyCode provider icon support
    Add PackyCode as a supported AI provider icon with proper metadata
    and filtering configuration.
    
    Changes:
    - Add 'packycode' to icon filter whitelist in filter-icons.js
    - Register PackyCode metadata with display name, category, and keywords
    - Import PackyCode SVG icon file
    - Export icon through index.ts for use in provider configurations
    
    The PackyCode icon uses currentColor to adapt to theme styling.
  • chore(deps): add icon library and update preset configurations
    Add dependencies and utility scripts for icon system:
    
    ## Dependencies (package.json)
    - Add @lobehub/icons-static-svg@1.73.0
      - High-quality SVG icon library for AI providers
      - Source for extracted icons in src/icons/extracted/
    - Update pnpm-lock.yaml accordingly
    
    ## Provider Preset Updates (src/config/claudeProviderPresets.ts)
    - Add optional `icon` and `iconColor` fields to ProviderPreset interface
    - Apply to Anthropic Official preset as example:
      - icon: "anthropic"
      - iconColor: "#D4915D"
    - Future presets can include default icon configurations
    
    ## Utility Script (scripts/filter-icons.js) [NEW]
    - Helper script for filtering and managing icon assets
    - Supports icon discovery and validation workflow
    - Complements extract-icons.js and generate-icon-index.js
    
    This completes the icon system infrastructure, providing all
    necessary tools and dependencies for icon customization.
  • feat(ui): add icon picker, color picker and provider icon components
    Implement comprehensive icon selection system for provider customization:
    
    ## New Components
    
    ### ProviderIcon (src/components/ProviderIcon.tsx)
    - Render SVG icons by name with automatic fallback
    - Display provider initials when icon not found
    - Support custom sizing via size prop
    - Use dangerouslySetInnerHTML for inline SVG rendering
    
    ### IconPicker (src/components/IconPicker.tsx)
    - Grid-based icon selection with visual preview
    - Real-time search filtering by name and keywords
    - Integration with icon metadata for display names
    - Responsive grid layout (6-10 columns based on screen)
    
    ### ColorPicker (src/components/ColorPicker.tsx)
    - 12 preset colors for quick selection
    - Native color input for custom color picking
    - Hex input field for precise color entry
    - Visual feedback for selected color state
    
    ## Icon Assets (src/icons/extracted/)
    - 38 high-quality SVG icons for AI providers and platforms
    - Includes: OpenAI, Claude, DeepSeek, Qwen, Kimi, Gemini, etc.
    - Cloud platforms: AWS, Azure, Google Cloud, Cloudflare
    - Auto-generated index.ts with getIcon/hasIcon helpers
    - Metadata system with searchable keywords per icon
    
    ## Build Scripts
    - scripts/extract-icons.js: Extract icons from simple-icons
    - scripts/generate-icon-index.js: Generate TypeScript index file