expo / react-native-action-sheet

A cross-platform ActionSheet for React Native
MIT License
1.4k stars 226 forks source link

Close action sheet with escape on desktop web #194

Closed szaboat closed 3 years ago

szaboat commented 3 years ago

Hi,

I was looking for a way to close the action sheet on a web application when hitting escape. It seems as a standard interaction for me that modals / popovers are dismissable on hitting the ESC key. I haven't seen this feature in the library also I could not found a way to implement it with the current API.

What's your opinion about the feature? I'm happy to send a PR if maintainers find it valuable.

Thanks!

bradbyte commented 3 years ago

I'm not 100% sure about handing it natively in the app, but idea that comes to mind is adding the ability to programmatically dismiss the modal (which has been requested before), so then you could wire that into a key handler for web.

github-actions[bot] commented 2 years ago

:tada: This issue has been resolved in version 3.13.0 :tada:

The release is available on:

Your semantic-release bot :package::rocket: