mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-09-22 13:39:35 +00:00
improv ui: use radix modal mode for Modals
Using the modal mode ensures that interaction with outside elements is disabled ( for e.g scroll ) and only dialog content is visible to screen readers.
This commit is contained in:
@@ -72,7 +72,7 @@ ModalContent.displayName = "ModalContent";
|
||||
|
||||
export type ModalProps = Omit<DialogPrimitive.DialogProps, "open"> & { isOpen?: boolean };
|
||||
export const Modal = ({ isOpen, ...props }: ModalProps) => (
|
||||
<DialogPrimitive.Root open={isOpen} {...props} />
|
||||
<DialogPrimitive.Root open={isOpen} {...props} modal/>
|
||||
);
|
||||
|
||||
export const ModalTrigger = DialogPrimitive.Trigger;
|
||||
|
||||
Reference in New Issue
Block a user