You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
From the docs, I saw that the "confirm" type of toaster message caters for closing the toaster on ESC:
Toastr: confirm
The confirm method takes two arguments. The first one is the message and the second one is an object where you can specify what will happen when the user clicks on ok or on the cancel buttons or on keypress enter/esc.
Ideally this should be an option for all types of toasters - when focus is on the toaster, you should be able to use the ESC key to close it, as per accessibility standards for modal dialogs: https://bitsofco.de/accessible-modal-dialog/
The text was updated successfully, but these errors were encountered:
Looks like I could do something similar to this #244 (comment) and just add an ESC key handler to the X button - in my case that's enough, because the only focusable element in our toaster is the X button. However, it is still worth fixing properly with a prop in case other focusable elements are included in the toaster for any reason.
From the docs, I saw that the "confirm" type of toaster message caters for closing the toaster on ESC:
Ideally this should be an option for all types of toasters - when focus is on the toaster, you should be able to use the ESC key to close it, as per accessibility standards for modal dialogs: https://bitsofco.de/accessible-modal-dialog/
The text was updated successfully, but these errors were encountered: