[feat] improve custom icon build script with TypeScript and error handling (#5202)

- Convert customIconCollection.js to TypeScript with proper interfaces
- Add comprehensive SVG validation and error handling
- Implement graceful failure - malformed icons don't break builds
- Remove verbose logging, keep only errors/warnings
- Update documentation in README.md, CONTRIBUTING.md, icons/README.md
- Add missing @iconify/tailwind dependency

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-authored-by: Claude <noreply@anthropic.com>
This commit is contained in:
Christian Byrne
2025-08-25 17:55:47 -07:00
committed by GitHub
parent 50e0e29016
commit 7d6e252814
6 changed files with 125 additions and 34 deletions

View File

@@ -265,7 +265,7 @@ The project supports three types of icons, all with automatic imports (no manual
2. **Iconify Icons** - 200,000+ icons from various libraries: `<i-lucide:settings />`, `<i-mdi:folder />`
3. **Custom Icons** - Your own SVG icons: `<i-comfy:workflow />`
Icons are powered by the unplugin-icons system, which automatically discovers and imports icons as Vue components. Custom icons are stored in `src/assets/icons/custom/`.
Icons are powered by the unplugin-icons system, which automatically discovers and imports icons as Vue components. Custom icons are stored in `src/assets/icons/custom/` and processed by `build/customIconCollection.ts` with automatic validation.
For detailed instructions and code examples, see [src/assets/icons/README.md](src/assets/icons/README.md).