I have a different use case and possible approach. I have energy monitoring outlets that I “never” want to turn off. They monitor things like my sump pump, dehumidifier, etc. Perhaps these entities could be extended to include a “protection-mode” switch that has to be disabled as a separate step in order to operate the entity (switch, outlet, cover, etc.). This way if the UI button is accidentally trigger, it would throw an error.
FWIW, here’s what happened to me. I loaded theMushroom strategy dashboard and clicked a button that I didn’t know would turn off all items of that type. It turned off all my switches including power monitoring outlets and I didn’t become aware until there was water seeping through the floor. My bad, I know, but it got me to thinking about how to solve this.