Dialog

The Dialog component is used to show dialog popup.

1. Import

KUMUI exports 8 Dialog-related components:

import { Dialog, DialogTrigger, DialogContent, DialogHeader, DialogTitle, DialogDescription, DialogFooter, DialogClose } from "@rohitgadekar/kimui";

2. Usage


3. API

3.1 Dialog

AttributeTypeDescriptionDefault
children

React.ReactNode

Dialog components, such as trigger, content, header, footer, etc.-

3.2 DialogTrigger

AttributeTypeDescriptionDefault
asChild

boolean

If true, it will wrap the trigger component (Button) as a childfalse

3.3 DialogContent

AttributeTypeDescriptionDefault
children

React.ReactNode

Content of the Dialog, such as the header, description, and footer-

3.4 DialogHeader

AttributeTypeDescriptionDefault
children

React.ReactNode

Header content for the Dialog, such as a title-

3.5 DialogTitle

AttributeTypeDescriptionDefault
children

React.ReactNode

The title text of the dialog-

3.6 DialogDescription

AttributeTypeDescriptionDefault
children

React.ReactNode

Content for the description of the dialog (e.g., instructions or additional details)-
className

string

Custom CSS class for styling-

3.7 DialogFooter

AttributeTypeDescriptionDefault
children

React.ReactNode

Footer content, typically used for actions like close or submit-

3.8 DialogClose

AttributeTypeDescriptionDefault
children

React.ReactNode

The content that triggers the closing of the dialog (usually a button)-