Using Cancel button in Dashboard ui_form doesn't work

I haven’t used ui_form in quite a while but I’m developing a new feature which makes considerable use of them. Whereas the Submit button passes the data out of the form in msg.payload, if I click the cancel button no output message is produced and I am left stuck in the form.

I created a simple test flow to prove the point to myself.

[{"id":"9a08ae07d4142b92","type":"tab","label":"Flow 1","disabled":false,"info":"","env":[]},{"id":"6ae9316dbf0cfcbf","type":"inject","z":"9a08ae07d4142b92","name":"","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":320,"y":220,"wires":[["7e9c719fc96ec92c"]]},{"id":"7e9c719fc96ec92c","type":"ui_form","z":"9a08ae07d4142b92","name":"","label":"","group":"698fa448636501eb","order":0,"width":0,"height":0,"options":[{"label":"time","value":"time","type":"time","required":true,"rows":null}],"formValue":{"time":""},"payload":"","submit":"submit","cancel":"cancel","topic":"topic","topicType":"msg","splitLayout":"","className":"","x":550,"y":220,"wires":[["aafa204a3f555ff6"]]},{"id":"aafa204a3f555ff6","type":"debug","z":"9a08ae07d4142b92","name":"debug 117","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":830,"y":220,"wires":[]},{"id":"698fa448636501eb","type":"ui_group","name":"Test","tab":"62712bbf.888b94","order":4,"disp":true,"width":"6","collapse":false,"className":""},{"id":"62712bbf.888b94","type":"ui_tab","name":"test","icon":"dashboard","order":17,"disabled":false,"hidden":false}]

If I enter data into my form

Screenshot 2023-12-05 095030

and click Submit my Debug gives me

Screenshot 2023-12-05 095219

If I re-enter data and click Cancel, the form contents are cleared but the form itself is not exited. There is no output to my Debug Node.

I’m running NodeRed 16.0.2 in HomeAssistant 11.1

Can anyone tell me what I am doing wrong please