fix dialog back button for android (#3428)

* fix types

* remove unused async

* add try/catch
This commit is contained in:
Hailey 2024-04-05 12:52:53 -07:00 committed by GitHub
parent c80dcc565e
commit cd29dba761
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 39 additions and 23 deletions

View file

@ -135,8 +135,7 @@ export function Action({
const {gtMobile} = useBreakpoints()
const {close} = Dialog.useDialogContext()
const handleOnPress = React.useCallback(() => {
close()
onPress()
close(onPress)
}, [close, onPress])
return (