You have what’s possibly the best home automation platform in the world, with support for virtually every single controllable device out there - commercial or diy.
And you take a tiny, tiny part of that - the frontend - and jump through hoops to make that perform tasks that the rest of the system eats for breakfast?
Why? Why limit this to - not even just mqtt devices - but ONE mqtt device?
Give it an entity id, and make it tell Home Assistant to do what Home Assistant does best - controll your devices!
This is an awesome card. Does something everyone has been asking for (way way nicer than mine that I mentioned in your reddit thread). Well written, well documented and well behaved (You use ha-card. Bravo! And especially styling it via a class rather than the element itself - your users’ll appreciate that without even knowing.). But it’s so severely and, above all, pointlessly limited!
tl;dr; Awesome! Most importantly, Awesome! Please remove the “mqtt”-part from… everything.
Edit: Please don’t take this too hard. This really is an awesome thing, and lots of people have been asking me to make something like it. It’s just… it could be so much more with (seriosly) less trouble than you must have gone through… I’d gladly give you whatever pointers you need to make this realize it’s full potential.
Probably things started on a wrong track Using color wheel on a card instead of having to go into properties it’s something many users wanted, not only for MQTT lights.
Your current card should also work with MiLight/Limitless emulator integration done over MQTT (not the native UDP). I will test and post the results tomorrow.
With MQTT json used by MiLight it should work to control both i) state of the lights that are currently on and ii) (if possible to pass individual rgb/hs/xy components from the card to lights, thus I think it might need an entity ID) state of the lights that are off to use the same settings as the ones that are current on.
May I have a suggestion: could you also include a state topic in the component? It would allow syncing of the card from different places in HA such as from an automation or from a physical remote that uses the same state topic as the card.