This commit is contained in:
Hailey
2024-10-02 16:49:36 -07:00
parent 10cb87b695
commit 431f1ffe8d
4 changed files with 5 additions and 3 deletions
+2 -2
View File
@@ -124,9 +124,9 @@ export const Button = React.forwardRef<View, ButtonProps>(
) => {
// This will pick the correct default pressable to use. If we are inside a dialog, we need to use the RNGH
// pressable so that it is usable inside the dialog.
const dialogContext = useDialogContext()
const {insideDialog} = useDialogContext()
if (!Component) {
if (dialogContext) {
if (insideDialog) {
Component = NormalizedRNGHPressable
} else {
Component = Pressable