something like this
[{"id":"839b0fab.0972e8","type":"inject","z":"5a245aa1.510164","name":"Setup ","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":true,"onceDelay":"","topic":"","payload":"","payloadType":"str","x":340,"y":3540,"wires":[["557c0081.636f88"]]},{"id":"557c0081.636f88","type":"change","z":"5a245aa1.510164","name":"","rules":[{"t":"set","p":"X","pt":"flow","to":"$exists($flowContext(\"X\")) ? \t$flowContext(\"X\") : 0","tot":"jsonata"},{"t":"set","p":"feedback","pt":"msg","to":"$flowContext(\"X\") = 0 ?\t{\"colour\": \"blue\",\t\"txt\": \"blue/red\",\t\"fontClr\": \"red\"} \t:\t{\"colour\": \"red\",\t\"txt\": \"black/red\",\t\"fontClr\": \"black\"}\t","tot":"jsonata"}],"action":"","property":"","from":"","to":"","reg":false,"x":530,"y":3540,"wires":[["3c7dc256.8e3e46"]]},{"id":"3c7dc256.8e3e46","type":"ui_button","z":"5a245aa1.510164","name":"RBE Button","group":"8b5cde76.edd58","order":5,"width":"1","height":"1","passthru":false,"label":"{{feedback.txt}}","tooltip":"","color":"{{feedback.fontClr}}","bgcolor":"{{feedback.colour}}","icon":"","payload":"X","payloadType":"flow","topic":"","topicType":"str","x":320,"y":3630,"wires":[["bef22d71.9f0ae8"]]},{"id":"bef22d71.9f0ae8","type":"change","z":"5a245aa1.510164","name":"","rules":[{"t":"set","p":"X","pt":"flow","to":"payload = 1 ? 0 : 1","tot":"jsonata"},{"t":"set","p":"feedback","pt":"msg","to":"payload = 1 ?\t{\"colour\": \"blue\",\t\"txt\": \"blue/red\",\t\"fontClr\": \"red\"} \t:\t{\"colour\": \"red\",\t\"txt\": \"black/red\",\t\"fontClr\": \"black\"}\t","tot":"jsonata"}],"action":"","property":"","from":"","to":"","reg":false,"x":340,"y":3680,"wires":[["d4db2e96.f67258","3c7dc256.8e3e46"]]},{"id":"d4db2e96.f67258","type":"debug","z":"5a245aa1.510164","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":570,"y":3680,"wires":[]},{"id":"80d7b072.b72b88","type":"comment","z":"5a245aa1.510164","name":"Push Button Flow","info":"This has two states:\nA and B.\nAll future refrence is to these two state names.\n\nREQUIRED:\nInputs:\nButton background colour for state A. msg.colurA\nButton background colour for state B. msg.colourB\nButton text for state A. msg.txtA\nButton text for state B. msg.txtB\nFont colour for state A. msg.txtclrA\nFont colour for state B. msg.txtclrB\nPayload for state A. msg.payloadA\nPayload for state B. msg.payloadB\nTopic. msg.topicSET\n\nOutputs:\nmsg.payload - this is used to control what ever you need.\nmsg.topic - this is if it is needed for control of the next node.\nmsg.colour - this sets the colour of the button.\nmsg.txt - this is the text to be displayed in the button.\nmsg.fontclr - this is the colour of the text on the button.\n","x":300,"y":3490,"wires":[]},{"id":"8b5cde76.edd58","type":"ui_group","name":"","tab":"8f03e639.85956","order":1,"disp":true,"width":"6","collapse":false},{"id":"8f03e639.85956","type":"ui_tab","name":"Home","icon":"dashboard","disabled":false,"hidden":false}]