give this a try
[{"id":"2e88253.7f5dbda","type":"switch","z":"b7eb5457.b00758","name":"","property":"switch","propertyType":"flow","rules":[{"t":"eq","v":"on","vt":"str"},{"t":"eq","v":"off","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":230,"y":1681,"wires":[["14f62ee4.e04971"],["c2c59c67.3b499"]]},{"id":"14f62ee4.e04971","type":"function","z":"b7eb5457.b00758","name":"if is on","func":"msg.color = \"black\";\nmsg.background = \"#EF2F4F\";\nmsg.text = \"TURN OFF\";\nreturn msg;","outputs":1,"noerr":0,"x":359,"y":1662,"wires":[["fd6bda5d.76b828"]]},{"id":"c2c59c67.3b499","type":"function","z":"b7eb5457.b00758","name":"if is off","func":"msg.color = \"black\";\nmsg.background = \"#B4EEB4\";\nmsg.text = \"TURN ON\";\nreturn msg;","outputs":1,"noerr":0,"x":359,"y":1702,"wires":[["fd6bda5d.76b828"]]},{"id":"fd6bda5d.76b828","type":"ui_button","z":"b7eb5457.b00758","name":"on/off","group":"f21f2722.4727c8","order":5,"width":"7","height":"1","passthru":false,"label":"{{msg.text}}","color":"{{msg.color}}","bgcolor":"{{msg.background}}","icon":"","payload":"","payloadType":"str","topic":"button","x":543,"y":1678,"wires":[["b89410e2.c92a2"]]},{"id":"8bbeaf5b.07a0a","type":"switch","z":"b7eb5457.b00758","name":"","property":"switch","propertyType":"flow","rules":[{"t":"eq","v":"on","vt":"str"},{"t":"eq","v":"off","vt":"str"}],"checkall":"true","repair":false,"outputs":2,"x":816,"y":1679,"wires":[["ff1995a1.0f5498"],["d0d18551.0c6338"]]},{"id":"b89410e2.c92a2","type":"switch","z":"b7eb5457.b00758","name":"","property":"topic","propertyType":"msg","rules":[{"t":"eq","v":"button","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":685,"y":1678,"wires":[["8bbeaf5b.07a0a"]]},{"id":"ff1995a1.0f5498","type":"change","z":"b7eb5457.b00758","name":"","rules":[{"t":"set","p":"switch","pt":"flow","to":"off","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"0","tot":"num"}],"action":"","property":"","from":"","to":"","reg":false,"x":970,"y":1651,"wires":[["23485693.901fba"]]},{"id":"6e2bfdfc.71f3f4","type":"inject","z":"b7eb5457.b00758","name":"","topic":"","payload":"","payloadType":"date","repeat":"1","crontab":"","once":true,"onceDelay":0.1,"x":93,"y":1682,"wires":[["2e88253.7f5dbda"]]},{"id":"d0d18551.0c6338","type":"change","z":"b7eb5457.b00758","name":"","rules":[{"t":"set","p":"switch","pt":"flow","to":"on","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"1","tot":"num"}],"action":"","property":"","from":"","to":"","reg":false,"x":972,"y":1700,"wires":[["23485693.901fba"]]},{"id":"23485693.901fba","type":"debug","z":"b7eb5457.b00758","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","x":1162,"y":1673,"wires":[]},{"id":"fc21644c.625668","type":"inject","z":"b7eb5457.b00758","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":true,"onceDelay":0.1,"x":801,"y":1614,"wires":[["ff1995a1.0f5498"]]},{"id":"f21f2722.4727c8","type":"ui_group","z":"","name":"test","tab":"95e900a4.9d5ff","order":1,"disp":true,"width":"10","collapse":true},{"id":"95e900a4.9d5ff","type":"ui_tab","z":"","name":"test","icon":"dashboard","order":26}]
If you wanted faster behaviour just reduce the time from the inject node at the left from 1 to 0.1 sec