Unverified Commit 5ba81d62 authored by Huang Cheng Ting's avatar Huang Cheng Ting Committed by GitHub

fix: prevent default focus behavior on open and close events in sheet (#4998)

parent 76ca258f
...@@ -72,6 +72,13 @@ const SheetContent = React.forwardRef< ...@@ -72,6 +72,13 @@ const SheetContent = React.forwardRef<
"data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t", "data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t",
className, className,
)} )}
onOpenAutoFocus={(e) => {
e.preventDefault();
}}
onCloseAutoFocus={(e) => {
e.preventDefault();
document.body.style.pointerEvents = "auto";
}}
{...props} {...props}
> >
{children} {children}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment