Bidirectional 'Slide to Confirm' Card - prevent accidental taps!

I looked at implementing the slide to confirm card (GitHub - itsbrianburton/slide-confirm: Slide to Confirm is a custom card for Home Assistant that prevents accidental button presses by requiring the user perform a slide action to trigger a service. · GitHub) to control my kettle and coffee machine so that they weren’t accidentally switched on by the tap of a button, but found that was just a single action - great for unlocking a door, but not so good for turning the coffee machine on and off.

So, I looked at developing a bidirectional version of it that reacts to the state of the device that it is controlling.
It was mostly coded with AI, but after plenty of troubleshooting and some manual development, it seems quite solid.
There is a GUI for configuration and that seems to work well too - it could probably do with some extra configuration.

Apart from the sligthly buggy configuration GUI, all seems to be working fine for me at the moment with the actual cards.

You can find the repo here, and can add it via a HACS custom repository:
https://github.com/ChadH360/slide-toggle-card

Hope it’s of use to someone :smiley: