Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tap actions do not work for sub items if they do not have an entity #337

Open
i00 opened this issue Jun 28, 2024 · 1 comment
Open

Tap actions do not work for sub items if they do not have an entity #337

i00 opened this issue Jun 28, 2024 · 1 comment

Comments

@i00
Copy link

i00 commented Jun 28, 2024

I want to have a sub item without an entity so that I can show some custom text so I have:

- entity: none
  default: 'Boost'
  tap_action:
    action: navigate
    navigation_path: /lovelace/ev-boost

It looks like you can click on it - but if the entity is set up this way, clicking on it does nothing!

@ildar170975
Copy link

According to docs:

if you define entities as objects, either entity, attribute or icon needs to be specified

and if you define an entity option - it is supposed to have a valid entity_id:
image

means - your working trick with entity: none is not officially supported.

From my understanding the source code, processing a tap_action here NEEDS an valid defined entity - either THIS entity or a main entity. Since you defined a non-existing entity - tap_action is not processed. Just my guess.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants