feat(icons): implement shared SVG icon system across packages

- Create centralized SVG files in core icons package assets directory
- Add rollup-plugin-string to core icons for SVG file processing
- Export SVG_ICONS object from core package for cross-package sharing
- Refactor html-icons to import SVG strings from @vjs-10/icons
- Remove hardcoded SVG strings in favor of shared definitions
- Add TypeScript declarations for SVG imports

This establishes a foundation for sharing more code across the monorepo
while maintaining proper package boundaries and build system integration.

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

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Christian Pillsbury
2025-08-13 14:06:51 -07:00
co-authored by Claude
parent 69670e8d71
commit e0be58e094
16 changed files with 73 additions and 26 deletions
+17
View File
@@ -1,3 +1,20 @@
// Import SVG files as strings
import playSvg from '../assets/play.svg';
import pauseSvg from '../assets/pause.svg';
import volumeHighSvg from '../assets/volume-high.svg';
import volumeLowSvg from '../assets/volume-low.svg';
import volumeOffSvg from '../assets/volume-off.svg';
// Export SVG strings directly
export const SVG_ICONS = {
play: playSvg,
pause: pauseSvg,
volumeHigh: volumeHighSvg,
volumeLow: volumeLowSvg,
volumeOff: volumeOffSvg,
} as const;
// Legacy interface for backward compatibility
export interface IconDefinition {
name: string;
viewBox: string;
+4
View File
@@ -0,0 +1,4 @@
declare module '*.svg' {
const content: string;
export default content;
}