<#3701 [UI Feature] Escape key press closes UI mod...
# flyte-github
a
#3701 [UI Feature] Escape key press closes UI modal or dialog popups. Issue created by FrankFlitton Motivation: Why do you think this is important? User convenience: Many users are familiar with the convention of using the Escape key to dismiss or close a dialog box or modal. It provides a quick and intuitive way for users to close the modal without relying solely on mouse interactions. Consistency and standardization: The Escape key has become a widely accepted convention for dismissing overlays, dialogs, and modals across various platforms and applications. Accessibility: Keyboard accessibility is crucial for users who rely on alternative input methods or assistive technologies. By allowing users to close a modal with the Escape key, developers ensure that individuals with motor impairments or who prefer keyboard navigation can easily dismiss the modal without having to rely on complex mouse movements or interactions. Goal: What should the final outcome look like, ideally? Across the UI when someone presses
Escape
the modal closes. Propose: Link/Inline OR Additional context Create a react hook that listens for the
Escape
key press and modifies the
<Modal />
or
<Dialog />
component's
open
state. Are you sure this issue hasn't been raised already? ☑︎ Yes Have you read the Code of Conduct? ☑︎ Yes flyteorg/flyte