A minimal multi-color weather icon set containing 100 icons offered in multiple integration options.
- 100 minimal weather icons
- Multi-color support for enhanced visual communication
- TypeScript support with auto-completion
- Tree-shaking for optimal bundle sizes
- Accessibility features (ARIA labels)
- Customizable props (size, color, className)
- SVG sprites for performance optimization
- Webfont generation (WOFF2, WOFF, TTF, EOT)
- PNG exports in multiple sizes (16px to 128px) with retina support
Note
Originally made for the weather app temps.
All 100 weather icons with exemplary multi-color visual previews:
Tip
Search for specific icons within the landing page: https://jackd248.github.io/weather-iconic/
Note
Icons are also available in single-color versions in the same packages.
npm install weather-iconic
<!-- Include the CSS -->
<link rel="stylesheet" href="node_modules/weather-iconic/dist/weather-iconic.css">
<!-- Use icons with proper classes -->
<i class="weather weather-sun"></i>
<i class="weather weather-cloud-rain weather-icon--lg"></i>
Tip
See the CodePen example for more details.
<!-- Use sprite icons directly -->
<svg width="32" height="32">
<use xlink:href="/path/to/sprites.svg#weather-sun"></use>
</svg>
<svg width="32" height="32">
<use xlink:href="/path/to/sprites.svg#weather-moon"></use>
</svg>
Weather Iconic supports multi-color icons for enhanced visual communication. Many weather icons contain multiple elements (e.g., thermometer mercury + body, sun + cloud) that can be styled with different colors.
Tip
Color Philosophy: The primary color (--weather-primary-fill
) is used for highlight elements like lightning bolts, sun rays, or thermometer mercury. The secondary color (--weather-secondary-fill
) serves as the base color for clouds, thermometer bodies, and single-element icons. This creates a natural visual hierarchy where important elements stand out.
<!-- Include enhanced CSS for multi-color support -->
<link rel="stylesheet" href="node_modules/weather-iconic/dist/weather-iconic-enhanced.css">
/* Basic multi-color usage with CSS custom properties */
.weather-multi-color {
--weather-primary-fill: #80BBB2; /* Highlight color (lightning, sun rays, mercury) */
--weather-secondary-fill: #666666; /* Base color (clouds, bodies, single elements) */
}
<!-- Multi-color with CSS custom properties -->
<div class="weather-multi-color" style="--weather-primary-fill: #80BBB2; --weather-secondary-fill: #666666;">
<svg><use xlink:href="/path/to/sprites.svg#weather-sun-cloud-lightning"></use></svg>
</div>
<!-- Multi-color with utility classes -->
<div class="weather-multi-color weather-primary-teal">
<svg><use xlink:href="/path/to/sprites.svg#weather-sun-cloud-lightning"></use></svg>
</div>
/* Primary color utilities */
.weather-primary-red { --weather-primary-fill: #dc3545; }
.weather-primary-blue { --weather-primary-fill: #007bff; }
.weather-primary-green { --weather-primary-fill: #28a745; }
.weather-primary-yellow { --weather-primary-fill: #ffc107; }
/* Secondary color utilities */
.weather-secondary-red { --weather-secondary-fill: #dc3545; }
.weather-secondary-blue { --weather-secondary-fill: #007bff; }
.weather-secondary-green { --weather-secondary-fill: #28a745; }
.weather-secondary-yellow { --weather-secondary-fill: #ffc107; }
/* Automatic dark mode detection */
@media (prefers-color-scheme: dark) {
.weather-multi-color {
--weather-secondary-fill: #cccccc;
}
}
/* Manual dark mode toggle */
[data-theme="dark"] .weather-multi-color {
--weather-secondary-fill: #cccccc;
}
Note
Multi-color support works with icons that have multiple paths or groups. Single-path icons will use the primary color for the entire icon.
npm run build:icons # Process and optimize SVGs
npm run build:components # Generate React/Vue components
npm run build:sprite # Create SVG sprite
npm run build:fonts # Generate webfonts (WOFF2, WOFF, TTF, EOT)
npm run build:png # Export PNG images (multiple sizes + retina)
npm run build # Full build pipeline
# open test page
cd tests
npm install
open index.html
- Bundle Sizes: SVG Sprite (~189KB), Webfonts (~100KB), JS Bundles (~14KB)
- Total Package: ~390KB (optimized distribution without PNG assets)
- Formats: SVG sprites, webfonts with TypeScript definitions, ES/CJS modules
- Font Formats: WOFF2, WOFF, TTF, EOT for maximum browser support
- Node.js: Requires Node.js >=16.0.0
This work is licensed under Creative Commons' Attribution-ShareAlike 3.0 United States (CC BY-SA 3.0)