The latest version of the mini media player is awesome (as was the previous one :wink: ).
I am currently using the buttons (as part of the shortcuts) for my TV.
I really would like to extend the use of these buttons. Would it be possible to also call scripts and/or services with these buttons?
Then I can add a Netflix button to my Nvidia Shield media player which is integrated in the card :grin:
Currently I am using custom button card to achieve this. But that's not that nice as it is a separate button and I have to add it in a conditional card to hide the buttons when the Shield is off.
- type: custom:button-card
icon: mdi:netflix
color: 'var(--accent-color)'
size: 20%
style:
- font-weight: bold
- color: 'var(--primary-text-color)'
action: service
service:
domain: media_player
action: androidtv_intent
data:
entity_id: media_player.shield_tv
intent: '-n com.netflix.ninja/.MainActivity'
Thanks @gerard33, I appreciate it!
Great suggestion, I'd prefer to not add more complexity to the card, but adding support for triggering scripts should be simple and would work with the current option syntax as well (no breaking changes required).
Let me think about service calls for a bit, but scripts for sure!
Triggering scripts through shortcuts is now available in the latest release.
# Example button to trigger script
- type: custom:mini-media-player
entity: media_player.example
shortcuts:
buttons:
- name: Channel 4
id: script.change_channel
type: script
Thanks! This works really great :+1:
Most helpful comment
Thanks @gerard33, I appreciate it!
Great suggestion, I'd prefer to not add more complexity to the card, but adding support for triggering scripts should be simple and would work with the current option syntax as well (no breaking changes required).
Let me think about service calls for a bit, but scripts for sure!