So what exactly is going wrong?
The SVG code seems right, I can see it in Inkscape and it fits the box well.
So what exactly is going wrong?
The SVG code seems right, I can see it in Inkscape and it fits the box well.
Thanks for the reply…
I update the js file, do a “ha core restart” and the damn icon is still blank…
Possibly browser caching issue? Try clearing your cache, and/or appending a cache-busting string to the resource url, e.g.:
frontend:
extra_module_url:
- /local/hass-kongo09-icons.js?cache_bust=1234567890
or
resources:
- type: js
url: /local/hass-kongo09-icons.js?cache_bust=1234567890
if you’re doing it in the lovelace config.
The important thing is that the string after the question mark be unique each time you edit your file…I usually just increment by one: 12344, 12345, 12346…As long as it’s unique, the browser treats it like a new file and downloads it anew.
Thank you, that was it! That’s a good trick to refresh the cache…
It is unfortunate that icons are believed to be a simple path and a viewBox. This eliminates many of the above methods from using things like animation. Say I have the fan icon and add a simple animation to make it spin based on speed, one cannot use the path/viewBox method or even CSS mods to set speed.
Thomas can you use SVG files in HA? I have a ton of them I made up in Fontastic but did not think we could use them. I am guessing you have to use customize for each one you want to change. Too bad since it makes four nice packages of .eot, .svg, .ttf, and .woff of all the icons. It gives you a styles.css file to integrate it in.
Not sure if it fits your use case but hass-fontawesome allows you to use single, custom to your instance, .svg files as icons.
For example:
apro:lamp
will get the icon in the file <Home Assistant Config>/custom_icons/lamp.svg.
Yeah someone else just point that out too. Thanks for the assist!
for hours i have been trying different ways to use my own icons.
However, with every integration / variant without success.
It just doesn’t show any new icons.
Tried different browsers, deleted cache, restarted HA …
Even if I “duplicate” an existing icon from the code and change the name, it is not displayed to me.
did I forget something?