Icon System
89 SVG icons across 6 categories. Zero external dependencies. Automatic dark mode.
โก Quick Usage
Icons use stroke="currentColor" so they automatically inherit text color and work in both light and dark mode.
| Usage Type | Code Snippet |
|---|---|
| Basic | <MallIcon name="actions/heart" /> |
| With Size | <MallIcon name="nav/search" size={18} /> |
| With Class | <MallIcon name="status/loader" class="spin" /> |
IMPORTANT
Import: import MallIcon from '$mall/icons/MallIcon.svelte';
๐จ Icon Gallery
[[Demo:IconGallery]]
๐ Customization Workflow
The MallIcon component loads SVGs via import.meta.glob, making icon customization a simple file swap.
1. Direct Inkscape Editing
Open any existing icon directly from your terminal:
inkscape src/mall/icons/commerce/shopping-cart.svg
Unreal Hot-Reload: As soon as you hit Save in Inkscape, Vite detects the change and hot-reloads the icon in your browser instantly.
2. Design on the 24ร24 Grid
- Viewbox:
0 0 24 24 - Stroke:
currentColorโ enables dark mode - Fill:
none(brand icons may usefill="currentColor") - Stroke width: 1.5px default
3. Save as Plain SVG
In Inkscape: File โ Save As โ Plain SVG (not Inkscape SVG).
โจ Mall Brand Identity Tips
- Rounded Terminals: Softer line caps (round) for a friendlier feel.
- Subtle M Motif: Incorporate the Mallnline "M" into hero icons.
- Consistent Weight: Keep 1.5px stroke for UI icons.
๐ File Structure
src/mall/icons/
โโโ MallIcon.svelte โ Component
โโโ actions/ โ 25 icons
โโโ brand/ โ 10 icons
โโโ commerce/ โ 5 icons
โโโ content/ โ 28 icons
โโโ nav/ โ 12 icons
โโโ status/ โ 8 icons