Lovelace: Mini Media Player

This is media-player-card 1.2.0:
0

This media-player-card 1.2.1:
1

And this is media-player-card 1.2.1 with mini-media-player-base-color: 'var(--state-icon-color)' in theme:
1-with-theme

I want colors like in 1.2.0 version.

Thanks for the details, will be fixed in the next version.
https://github.com/kalkih/mini-media-player/commit/dd2d7ca25a43b7d27d34fb5e1165b2dd9bc2e958
The entity icon will be the color of paper-item-icon-color (like the default state-badge), unless mini-media-player-base-color is set.

2 Likes

Do you mind sharing your config for the remote?

Nothing special. I just used the Mini Media Player based on te documentation with these scripts:

Have you had any issues with some devices not accepting commands from relay? Only a subset of my devices appear to work :man_shrugging:

Actually yes, I used it to broadcast messages & start spotify playback on cast devices/groups, but at some point starting playback didn’t function anymore, broadcasting continued to work fine though.
I didn’t really look into it and used this instead, which has been working fine for the last few months.

Probably going to switch to spotcast at some point, since it does seem to support speaker groups now.

Cool. Thanks for the alternatives

i got help to install this, i workt great, BUT then i removed:
lovelace:
mode: yaml

do be avalebe to use card, and its gone:( have no ide what i need to change to make come back.

resources:
  - url: /local/community/mini-media-player/mini-media-player.js?v=1.2.2
    type: module
title: Home title
views:
  - title: First tab
    cards:
      - type: custom:mini-media-player
        entity: media_player.kok
        icon: mdi:spotify
        artwork: cover
        hide:
          volume: true
          source: true
          power_state: false

is my lovelace.ymal

Is there any way to make the overlay/background of this transparent/none so that it fits in to my theme set up as below? At the moment it shows a solid background.

Hey, when you disable yaml mode, ui-locelace.yaml is no longer being used, so you’ll have to add the card resource reference through the raw config editor in the home assistant user interface.
See step 3 here.

Yes, the card background is based on the style variable --ha-card-background, so you can either change this variable in your theme (will apply to all cards) or set it manually for specific card(s) using something like lovelace-card-mod.

Edit: Btw, make sure you got the latest release of the card, the background color was based on --paper-card-background-color in earlier releases.

Thanks heaps for fast response! Have tried that but doesn’t seem to do anything. Am on v1.2.2 as well which looks like the latest on HACS. Here is my code:

      - type: custom:mini-media-player
        style: |
          ha-card {
            border-radius: 12px;
            overflow: hidden;
            box-shadow: none;
            --paper-item-icon-color: var(--primary-text-color);
            ha-card-background: rgba(148,50,52,0.0)
          }
        entity: media_player.kids_google_home

Any ideas why it might not be working?

1 Like

Ignore me, got it to work by adding the – :slight_smile: thanks so much!

1 Like

I did make the changes i the raw config, save and restart. but no media player.
I just copy the url i had in my old file, what i know work using the other methed.
bu no luck

resources:
-url: /local/community/mini-media-player/mini-media-player.js?v=1.2.2
type: js

your indentation is wrong.

Try, type: module, if that doesn’t work try clearing the browser cache.
And If still no luck, try installing the card from scratch, this guide by @thomasloven is great, combined with the card readme on github.

http://hassio.local:8123/community_plugin/mini-media-player/mini-media-player.js:1:68547 Uncaught NotSupportedError: Failed to execute ‘define’ on ‘CustomElementRegistry’: the name “mmp-group-item” has already been used with this registry

i get this

Okay, that seems to suggest that the code is being loaded twice, make sure the resource reference is only included once, could be a cache issue, try clearing the browser cache manually,

no luck:/

i just get No card type found.
i am using HACS and i have check the so the name of the patch i correct, i have cleard the cache 5times. Will try install it the old way and see if its get me any luck. Starting to think somthing is wrong whit HACS insall, cant get any one to work from it

EDIT: i tried install it the “old” way, and not using HACS i now works like a charm. now i need to figuer out how to write the code to make it work like i whant:S

i mange to get it to works… took way to long but now it works.

dont know if this is the thing i looking for but, maybe some one can show me the patch:)

I want to make a media play for example mini media player to play music from spotify and be available to chose if i want to play it in kitchen, livingroom and so one.

Is mini media player the right thing?

regard

Great, what was the issue?

What type of media devices are they? You could potentially do this through mini media player shortcuts but I would need to know what kind of media devices you got to give you an explicit example.