Skip to content
  • Android
  • iOS
  • Web

Alert

Show a status message with a title and optional description.

Engine API NAlertnayan-ui/components

Live examples

Example.tsx

Attributes

NAlert attributes
NameTypeDefaultDetails
typestringdefaultSets the indicator and title color. Use default, info, success, warning, or error.
messageReactNodeOptionalDetail text below the title.
titleReactNodeOptionalA short heading for the alert.
iconReactNodeOptionalOverrides the status icon. Pass null to hide it.
actionsReactNodeOptionalAdditional controls beside the message.
classNamestringOptionalSupported Tailwind-style utilities, resolved entirely in Rust. See the engine README.
titleClassNamestringOptionalClasses applied to the title.
messageClassNamestringOptionalClasses applied to the message.
closeClassNamestringOptionalClasses applied to the close button.
onClose(() => void)OptionalAdds a close button and runs when it is pressed.
rolestringOptional
childrenReactNodeOptional
descriptionstringOptional

Tags