Callout
A visual message component to attract user's attention.
Callout Props
Prop | Type | Default |
---|---|---|
type | "grey" | "success" | "alert" | "gradient" | "accent" | "attention" | "normal" | "grey" |
outline | boolean | false |
highContrast | boolean | false |
action | ReactNode | - |
dismissible | boolean | false |
icon | ReactNode | InfoCircledIcon |
onDismiss | () => void | - |
children | ReactNode | - |
width | string | number | - |
className | string | - |
Examples
Type
The Callout component offers different type options. You can customize the visual style using the type
prop:
Outline
The Callout component can be rendered with or without an outline border:
High Contrast
The Callout component supports high contrast mode for better visibility:
Dismissible
The Callout component can be made dismissible:
With Action
The Callout component can include an action button:
Custom Width
The Callout component supports custom width:
Accessibility
The Callout component includes appropriate ARIA attributes for accessibility:
- Uses semantic HTML elements for proper structure
- Dismiss button includes
aria-label
for screen readers - Interactive elements are keyboard accessible