Open damianeickhoff opened 2 years ago
Looks like I already fixed it with a edited template:
chip_icon_state_navigate:
template: chips
triggers_update:
- "[[[ variables.ulm_chip_icon_state_entity ]]]"
tap_action:
action: navigate
navigation_path: "[[[ return variables.ulm_chip_navigate_path; ]]]"
label: |
[[[
var icon = '❔';
if (variables.ulm_chip_icon_state_icon){
var icon = variables.ulm_chip_icon_state_icon;
}
var state = '';
if (states[variables.ulm_chip_icon_state_entity].state){
var state = states[variables.ulm_chip_icon_state_entity].state;
}
return icon + ' ' + state;
]]]
Card:
- type: 'custom:button-card'
template:
- chip_icon_state_navigate
variables:
ulm_chip_navigate_path: verlichting
ulm_chip_icon_state_icon: '💡'
ulm_chip_icon_state_entity: sensor.current_lights_on
But also, as mentioned in #35 the state doenst update unless a page reload.
just set triggers_update
in your template to:
triggers_update: all
Should be fixed in next release with https://github.com/UI-Lovelace-Minimalist/UI/issues/35
Is it possible to give a emoji to a Navigation Chip? For now, only a MDI will work.
When giving a card the Navigation Template and the Icon Only template, it shows the Emoji, but the margin is off.
This is what it looks like.