<Dialog />
The
Dialog component.The
Dialog component is typically rendered conditionally. It also needs an onClose property to function as expected:import {useCallback, useState} from 'react'
const [open, setOpen] = useState(false)
const onClose = useCallback(() => setOpen(false), [])
const onOpen = useCallback(() => setOpen(true), [])
With that in place, it’s straight-forward to build a basic open/close flow using the
Dialog component:animate?: booleanWhether the dialog should animate in on mount
cardRadius?: number | number[]cardShadow?: number | number[]footer?: React.ReactNodeheader?: React.ReactNodeid: stringonClose?: () => voidscheme?: 'dark' | 'light'width?: number | number[]zOffset?: number