Close notification using the escape key#5835
Conversation
|
While experimenting with the feature, a limitation became apparent: is it permissible for the user to close a notification that is awaiting user action? For example, if I am selecting nodes for the catch node and I close the notification, the workspace is in a broken state.
|
|
I think you are over complicating it. We don't need actions to close notifications. We have other places where Escape is handled outside the regular keyboard handling. That's all we need here; if a notification adds a cancel button, add a short-lived event handler to trigger the close. |
|
We have no way of knowing which button cancels the action. Notifications that aren't fixed and optionally have a timeout already have click-based triggering. Not certain that adding the shortcut would be useful for them. |
Types of changes
Proposed changes
Request from: https://discourse.nodered.org/t/escape-key-closes-notification/101315
escapekey.ctrl-escapekey.Checklist
npm run testto verify the unit tests pass