A Custom Lovelace Card for Home Assistant wich displays an icon next to a title.
- on Lovelace UI, click on Edit Dashboard and add a new card
- select Manual and paste the following code:
type: 'custom:icon-title'
title: <title>
icon: mdi:<icon-name>
- replace
<title>
with the title you want to display (e.g.Scences
) - replace
<icon-name>
with the name of the icon you want to display (e.g.lamps
)
- Open HACS UI
- Go to Frontend tab
- Click the three dots in the top right corner and select Custom Repositories
- Add the URL of this repository and select Lovelace as category
- URL: https://github.com/marttasch/HA-icon-title
- Category: Lovelace
- Click Add
- Click the plus icon in the bottom right corner and search for icon-title and install it
- Download
icon-title.js
from the latest release. - Place the file in your
config/www
folder. - Add a reference to
icon-title.js
in Dashboard. There are two ways to do this:- Using UI: Settings → Dashboards → More Options icon → Resources → Add Resource → Set Url as
/local/icon-title.js
→ Set Resource type asJavaScript Module
. Note: If you do not see the Resources menu, you will need to enable Advanced Mode in your User Profile - Using YAML: Add following code to
lovelace
section.resources: - url: /local/icon-title.js type: module
- Using UI: Settings → Dashboards → More Options icon → Resources → Add Resource → Set Url as