New set of custom icons: official weather icons from Home Assistant

Hi!

I’ve been working on extracting the weather icons shipped with Home Assistant and provide them as custom icons so they can be used in badges, cards, etc.

The project lives in GitHub - scinos/lovelace-weather-icons: Official weather icons from Home Assistant

The icons provided so far are:

Name Icon
wi:clear-night Icon wi:clear-night
wi:cloudy Icon wi:cloudy
wi:fog Icon wi:fog
wi:hail Icon wi:hail
wi:lightning-rainy Icon wi:lightning-rainy
wi:lightning Icon wi:lightning
wi:partlycloudy-night Icon wi:partlycloudy-night
wi:partlycloudy Icon wi:partlycloudy
wi:pouring Icon wi:pouring
wi:rainy Icon wi:rainy
wi:snowy-rainy Icon wi:snowy-rainy
wi:snowy Icon wi:snowy
wi:sunny Icon wi:sunny
wi:windy-variant Icon wi:windy-variant
wi:windy Icon wi:windy

Usage

I’m using this to customize the hourly weather card, now that support for custom icons has landed. This is how the card looks like with these icons:

Tech details

As far as I’m aware, this is the first iconset to provide multiple colors. Most sets are monotone and some are duotone, but this one is full color.

From a tech point of view, Home Assistant expects iconset to just be one SVG path. Some iconset (like fontawesome, thanks for the inspiration) provide two paths. I generalized that idea and this iconset is defined as full SVGs, not just path. This should allow injecting any valid SVG, including shapes, gradients…

Check the implementation of src/loader.js to see how it’s done.

2 Likes

I am very interested in this topic and I think it should be closed using the universal symbols defined by the WMO.

There are many symbols and many preferences, but these are the official ones and Home Assistant (as an example of an app that uses standards) should definitely close this topic using these:

Note that it clearly differentiates day and night, which Home Assistant does not.