mini-media-player icon indicating copy to clipboard operation
mini-media-player copied to clipboard

Mute icon not showing up

Open niccolobusato opened this issue 4 years ago • 13 comments

Mute option is not showing up even if my media_player entity support it.

i can't figure out why..

not a problem with hide: properties.

niccolobusato avatar Apr 18 '20 10:04 niccolobusato

Came here to look for this same issue - on 1.7 and no mute icon. I use a Roku which doesn't support set volume so have:

artwork: full-cover entity: media_player.roku_tv type: 'custom:mini-media-player' volume_stateless: true hide: power: true mute: false

image

lawrence-jeff avatar Apr 19 '20 18:04 lawrence-jeff

Hello, the mute button is not supported and won't render on entities which doesn't support a mute state.

kalkih avatar May 24 '20 11:05 kalkih

my entity does support mute.

niccolobusato avatar May 24 '20 11:05 niccolobusato

What media player component is it and what attributes does it expose if you go to /developer-tools/state.

kalkih avatar May 24 '20 11:05 kalkih

Is a TV integrated via smartir (broadlink cloning and sending codes)

Schermata 2020-05-24 alle 13 57 44

i've also have another tv with the same config and it works great with your card..

niccolobusato avatar May 24 '20 11:05 niccolobusato

Please turn the entity on and press the media_player.televisore_camera text, go to the top of the page and copy all the attributes visible there.

kalkih avatar May 24 '20 12:05 kalkih

Schermata 2020-05-24 alle 14 33 17

like this?

also on this screenshot you can see that the default media player does support mute (and is working) but on the left side there is your card without the mute option..

Schermata 2020-05-24 alle 14 31 17

niccolobusato avatar May 24 '20 12:05 niccolobusato

Yes, thanks. As I described before the card doesn't display the mute icon if there's no mute state exposed by the entity, which there isn't in this case.

kalkih avatar May 24 '20 12:05 kalkih

but the other tv (the one in the living room) integrated in the same way is working.

screenshot here: Schermata 2020-05-24 alle 16 02 02

Schermata 2020-05-24 alle 16 02 29

niccolobusato avatar May 24 '20 14:05 niccolobusato

Not to clutter the thread - but I believe my media player also supports mute, it is exposed via the Roku remote card. Looking at the media player state in developer tools it lists: supported_features: 18876 Which if I translate to binary is 100100110111100 According to the constants file the bitflag for mute on a media device is 8 (1000)

That bit is 1 in 18876 - so it seems like it thinks it supports mute. If there is an easier way to confirm please let me know

lawrence-jeff avatar May 24 '20 22:05 lawrence-jeff

As I described before the card doesn't display the mute icon if there's no mute state exposed by the entity, which there isn't in this case.

The card will currently only display the mute icon if the is_volume_muted attribute is defined on the entity.

https://github.com/kalkih/mini-media-player/blob/fa1427db8be8b7f099d01df4b7feb8df954b68a7/src/model.js#L185-L187

We could potentially change this in the future to go by the supported features attribute instead, feel free to submit a PR.

kalkih avatar May 25 '20 16:05 kalkih

@niccolobusato can you share your theme please? Thanks.

agneevX avatar Jul 09 '20 08:07 agneevX

@agneevX should be this one. https://github.com/niccolobusato/Main-Home-AssistantConfig/blob/2020/themes/dark_green.yaml

niccolobusato avatar Jul 14 '20 12:07 niccolobusato