Skip to content

Commit

Permalink
[Desktop] Fix AlertDialog dismiss on click to Dialog content. (#359)
Browse files Browse the repository at this point in the history
  • Loading branch information
dima-avdeev-jb authored and eymar committed Jan 13, 2023
1 parent 86865e8 commit 221ca51
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,11 @@ object PopupAlertDialogProvider : AlertDialogProvider {
},
contentAlignment = Alignment.Center
) {
Surface(elevation = 24.dp) {
Surface(Modifier.pointerInput(onDismissRequest) {
detectTapGestures(onPress = {
// Workaround to disable clicks on Surface background https://github.com/JetBrains/compose-jb/issues/2581
})
}, elevation = 24.dp) {
content()
}
}
Expand Down

0 comments on commit 221ca51

Please sign in to comment.