---
title: Alert
description: A callout for displaying important information.
---
## Preview
## Installation
CLI
Manual
```bash
npx @olyx/cli@latest add alert
```
Copy and paste the following code into your project.
Update the import paths to match your project setup.
## Usage
```tsx
import {
Alert,
AlertContent,
AlertTitle,
AlertDescription,
AlertIcon,
} from "@/components/ui/alert"
```
```tsx
Heads up!
You can add components to your app using the CLI.
```
## API Reference
#### Alert
Root container for the alert. Custom component, not a Base UI wrapper.
| Prop | Type | Default |
| --------- | -------------------------------------------------------------------- | ----------- |
| `variant` | `"filled" \| "light" \| "lighter" \| "stroke"` | - |
| `status` | `"error" \| "warning" \| "success" \| "information" \| "feature"` | - |
| `size` | `"sm" \| "md" \| "lg"` | `"md"` |
#### AlertContent
Container for alert content. Renders as a styled `div`.
#### AlertTitle
Title text for the alert. Renders as a styled `div`.
#### AlertDescription
Description text for the alert. Renders as a styled `div`.
#### AlertIcon
Container for the alert icon. Renders as a styled `div`.
#### AlertClose
Close button with built-in icon. Uses Button component internally.
## Examples
### Error
### Warning
### Success
### Information
### Feature
### With Close Button
### Sizes