you’re right. What you wrote helped me realize that --rgb-deep-orange and --rgb-blue are part of the Mushroom default theme that came with that old slider.
Once I swapped in my own theme defined values the original card_mod you suggested worked!
This might be out of scope for this repo, but would it be possible to add support for navigating to different screens when clicking the tile feature buttons?
Wow, such an amazing addition!!! Immediately tried it out and noticed that @xvlw had the exact question I had
I was wondering though if it could be a nice addition to optionally indicate that the colour set by the Tile should be followed. E.g. the new Tile adjusts itself for a Climate entity based on the fact if it is heating or cooling like so:
This is so much cleaner than the card mod edit and it fixes an issue i was having on mobile where it was coming through transparent that I hadn’t dove into
hm… I think, I will give it a try…
Right now, I am always using “mushroom number card” whenever there is an entity, where I would like to have a slider to set another number value, since the tile-card itself does not yet provide such a slider.
I might give it a try with the tile features service call instead.
[update]
OK, here’s one example I am struggling a bit, since I usually don’t work much with these service calls…
The upper card is the ‘Mushroom Number Entity Card’ - that does provide the Number-Slider by default.
The one below is the tile card, with the ServiceCall feature enabled.
This is the Service Call from the Development-Area:
Limit is the State of Charge that I want to set.
Device ID is the "vehicle to set the charge limit for, usefull, if you have more than one car provided by this integration.
Now, how to apply this within the Service Call from the Card?
value_attribute should be set to to whatever numerical attribute you want the slider to track/set values for (it defaults to the tile or service call data entity ID state which it looks like it’s doing now).
I’m not familiar with this integration but from what I’m seeing in it’s code it’s services only accept device_id and not entity_id, which isn’t great since Home Assistant services should always accept entity_id and it may break some of the logic I use to track and set the slider value. If it doesn’t work try adding device_id and entity_id to the data field. If that throws an error please create a bug for it on Github so I can remember to add support for weird cases like this.
I actually installed this specifically for the mode selector. It is amazing to me that no one else has thought of it/needed it. Thank you very much for putting this together. Your project is a life saver!
I haven’t made the mode selector yet! It’s next on my list but I have to fix some possible bugs with this and do a big refactor on my other project (android-tv-card) before I get around to it. For now we have to settle for buttons.
I put out a small bug fix release which should help with weird custom services that do not use entity ID or use a separate entity for the slider and the service call. Try this:
type: custom:service-call
entries:
- type: slider
service: skodaconnect.set_charge_limit
entity_id: input_number.ladebegrenzung # entity ID of the slider
autofill_entity_id: false
data:
limit: VALUE
device_id: 2c1c0d706fe211bd09c09d56a282aecc
Took the input selector I jammed in at the top of my card to flip between 2 climate devices and you made it even better.
I have a small request, and I believe this is achievable by using templates but having it as default may be cleaner to follow how the default Tile Card acts.
Can you make it so that the icon colour inverts based on which input is selected?
Example: If you see the second row of buttons displaying the heat / cool / off buttons. Once one of the buttons is selected, the icon colour inverts to white (snowflake is white in this case).
When heat is selected the flame icon turns white and the snowflake goes back to black.
I completely missed the icon inversion since I’m always in dark mode. It should be as easy as applying filter: invert(1) to the icon and label. But I should only do so when in light mode so I’ll have to figure out how to detect that.
Edit: Or even better, calculate the luma of the icon color and invert if it’s too dark. I’ll enable this by default and add a toggle to disable. Nope too hard. I’ll make the whole thing off by default and allow users to enable it.
Edit 2: Released v2.1.1, which adds selector invert_icon and invert_label options at both the entry and option level of selectors. Figuring out how to do it only for light mode or by icon color would be much more difficult to implement so I’m indefinitely shelving that idea.
Tested this morning and the invert is working, however the colour it inverts to looks like a grey. Specifically #dedede whereas the default Tile icon inverts to straight #ffffff
I know its a bit tricky, and grey is better than black for both but wanted to report what i saw back in case there was an adjustment that could be made.
edit 1
Upon further testing, I changed my theme to the Home Assistant default one and tested and it looks like it is working correctly just using the default theme. So maybe the grey issue lies inside my theme file. I’ll have to dig through it and see
Which theme were you using? I’m out of town for the next week but can look more into it after. I could add more explicit options for defining selected icon/label text in the future.