Skip to content

armgit / vaul

Public Imported from GitHub
0

A drawer component for React.

feat: Don't autofocus within Dialog (#437)

Emil Kowalskiaa780d0b3fa3
diff --git a/src/index.tsx b/src/index.tsx
index 14277d1..db9b68f 100644
--- a/src/index.tsx
+++ b/src/index.tsx
@@ -785,6 +785,7 @@ export const Content = React.forwardRef<HTMLDivElement, ContentProps>(function (
pointerStartRef.current = { x: event.pageX, y: event.pageY };
onPress(event);
}}
+ onOpenAutoFocus={(e) => e.preventDefault()}
onPointerDownOutside={(e) => {
onPointerDownOutside?.(e);