Custom brand icons for Home Assistant
At the moment I have integrated only the main icons of Philips Hue products!
These are the official icons from the philips developer channel
Icon | Name |
---|---|
mini | |
window-sensor | |
bridge | |
usb-smart-adaptor | |
smart-plug-sonoff | |
smart-camera |
Icon | Name |
---|---|
moes-switch-single | |
moes-switch-dual | |
moes-switch-triple |
Icon | Name |
---|---|
nexxt | |
fastgate |
Icon | Name |
---|---|
battery-charged | |
battery-full | |
battery-good | |
battery-half | |
battery-low | |
battery-critical |
We recommend installing Custom brand icons card via Home Assistant Community Store
- Add the folowing to the
frontend
section of yourconfiguration.yaml
frontend:
extra_module_url:
- /local/community/custom-brand-icons/custom-brand-icons.js
- (optional) Or add the following to your lovelace configuration using the Raw Config editor under Configure UI or ui-lovelace.yaml if using YAML mode.
resources:
- type: js
url: /local/community/custom-brand-icons/custom-brand-icons.js
To add custom repositories please follow this guide. Set URL to https://github.com/elax46/custom-brand-icons
and category to Lovelace
.
-
Download
custom-brand-icons.js
file from the latest release. -
Copy the
custom-brand-icons.js
file into<config>/www/
the directory where yourconfiguration.yaml
resides. -
Add the folowing to the
frontend
section of yourconfiguration.yaml
frontend:
extra_module_url:
- /local/custom-brand-icons.js
Or add the following to your lovelace configuration using the Raw Config editor under Configure UI or ui-lovelace.yaml if using YAML mode.
resources:
- type: js
url: /local/custom-brand-icons.js
Restart home-assistant.
you can use icons by entering the prefix phu:
Example of integration in the card
entities:
- entity: light.lampada_entrance
icon: 'phu:go'
name: Go
- entity: light.monitor_2_right
icon: 'phu:play'
name: play 1
- entity: light.monitor_2_left
icon: 'phu:play'
name: play 2
show_header_toggle: false
title: Custom brand icons
type: entities
The icon is not there? open a custom icon request
In case you want to create your own perfix you can edit the last line of the custom-brand-icons.js
window.customIconsets["yourprefix"] = getIcon;
It probably depends on the cache. Open Home assistant from an incognito window and check that the icon loads if yes then it depends on the cache, otherwise double check the installation
Attention I remind you that the icons must be in svg format
If you like, you can help me expand the number of icons available. Just add to the variable var icons
let's take the first string for example:
"Bollard": [0, 0, 32.0, 32.0, "string"]
-
Bollard
= icon name -
0, 0, 32.0, 32.0
= this data can be recovered from the svg filetransform="scale(0, 0, 32.0, 32.0)
If this data is not present in the file you can leave the one indicated by me -
String
= this data can be recovered from the svg file<path d="M21,12.5 C21,13.33 18.76,...."
thanks to for @mutzl your contribution
Do you like these icons? Support the project with a pizza ๐๐