Hypfer / lovelace-valetudo-map-card

Display the map from a valetudo-enabled robot in a home assistant dashboard card.
MIT License
236 stars 36 forks source link

Customizable actions #53

Closed jghaanstra closed 3 years ago

jghaanstra commented 4 years ago

Thank you for the great work. I'd like to request a feature where you can define buttons with scripts, similar as seen here:

https://macbury.github.io/SmartHouse/HomeAssistant/Vacuum/

This would allow for go to target buttons of clean zone buttons etc.

TheLastProject commented 4 years ago

I agree that this would be nice. I'd prefer there to first be an option for each default button to be able to hide them.

I may get to this at some point, but I need to take stuff a bit slower for a bit. So if someone else beats me to it, that'd be great :)

TODO list for this:

  1. A new show option for each button in https://github.com/TheLastProject/lovelace-valetudo-map-card/blob/2a01bfcb8174ec113e56ccd3fb68e0b5a416e329/valetudo-map-card.js#L310-L319
  2. A check for show_whatever needs to be added to each button in https://github.com/TheLastProject/lovelace-valetudo-map-card/blob/2a01bfcb8174ec113e56ccd3fb68e0b5a416e329/valetudo-map-card.js#L501-L594
  3. A loop for custom_buttons or however it'll be called around https://github.com/TheLastProject/lovelace-valetudo-map-card/blob/2a01bfcb8174ec113e56ccd3fb68e0b5a416e329/valetudo-map-card.js#L582