CodeAI

Dialog

Blocking confirmation overlay with short title, message, and usually two actions.

Appearance

Content

Layout & behavior

Props — Dialog
View MUI docs
PropTypeDescription
type"default" | "iconTop" | "customContent"Layout variant for the confirmation overlay.
titleReactNodeDialog heading.
descriptionReactNodeShort confirmation message.
hasImagebooleanShow an image slot in the body.
imageReactNodeImage content when hasImage is set.
topIconNameFaIconName | stringFloating badge icon when type is iconTop (Figma shortcode).
hasSecondaryActionbooleanShow the secondary footer button.
primaryActionLabelReactNodePrimary button label.
secondaryActionLabelReactNodeSecondary button label.
isDismissablebooleanAllow dismiss via close control or backdrop.
onClose() => voidCalled when the dialog is dismissed.
openbooleanControls dialog visibility.
childrenReactNodeCustom body when type is customContent.
surfaceOnlybooleanRender the dialog surface without open/close behavior.