Skip to content

feat: Escape key dismisses confirmation dialogs (#864)#984

Open
Xenon010101 wants to merge 1 commit into
Charushi06:mainfrom
Xenon010101:fix/escape-confirm-864
Open

feat: Escape key dismisses confirmation dialogs (#864)#984
Xenon010101 wants to merge 1 commit into
Charushi06:mainfrom
Xenon010101:fix/escape-confirm-864

Conversation

@Xenon010101
Copy link
Copy Markdown

Adds Escape key support for custom confirmation dialogs created by Toast.confirm().

Changes

  • Adds keydown listener when confirmation modal opens
  • Pressing Escape dismisses the dialog with false (same as clicking Cancel)
  • Listener is properly cleaned up when dialog closes (via button, backdrop click, or Escape)

Closes #864

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: Custom Confirmation Dialogs Cannot Be Dismissed with Escape Key

1 participant