SDAIA
SDAIA LogoSDAIA Logo
ComponentsAlerts
IntroductionInstallationFAQBrands
ColorsTypographySpacingRadiusGrid layoutsAll Tokens
All Components
AccordionActivityArea ChartAudio PlayerAvatarAvatarGroupCarousel ImageChartChipCode SnippetColumn ChartContext MenuDigital StampDividerDonut ChartDraggable ListDropdownEmpty StateFiltrationFooterImage ViewerLine ChartListMedia GalleryMenuMetricNav BarNav HeaderNumberPDF ViewerPie ChartPopoverProgress CircleQuoteRadial StepperScatterSecond Nav HeaderSlideout MenuStructured ListTableTable of ContentTree ViewVertical TabsVideo Player
BreadcrumbButtonButton MenuButton SplitContent SwitcherDate PickerFloating ButtonHorizontal TabsLinkModalPaginationRadio ButtonSwitchTag
AutocompleteCheckboxFile UploadNumber InputRange SliderRich Text EditorSelectSignatureSliderText AreaText Input
AlertsBadgeCardFeedbackFeedback OverviewHelp IconLoading IndicatorNotification BannerNotification PopupNotificationsProgress BarRatingRating OverviewSkeletonSkeleton/AvatarsTooltip
Sdaia Logo Animation
Sdaia Touch ButtonsSdaia Touch Switch

Alerts

Alerts provide contextual feedback messages for typical user actions.

Loading preview…
1<Alert
2 state="success"
3 type="standard"
4 title="Changes saved successfully"
5 description="Your profile has been updated and is now live across all SDAIA services."

Installation

npx sdaia-ui@latest add alerts

Usage

import { Alert } from "@/components/ui/alert"
1<Alert>
2 <AlertTitle>Title</AlertTitle>
3 <AlertDescription>Description</AlertDescription>
4</Alert>

Examples

Default

A basic alert with a title and description.

Loading preview…
1'use client';
2
3import { Alert, Button } from 'sdaia-ui';
4
5export default function AlertStandard() {

Outline

Use `type="Outline"` for a bordered alert with no background fill.

Loading preview…
1'use client';
2
3import { Alert, Button } from 'sdaia-ui';
4
5export default function AlertOutline() {

Solid

Use `type="Solid"` for a high-contrast background. Use sparingly.

Loading preview…
1'use client';
2
3import { Alert, Button } from 'sdaia-ui';
4
5export default function AlertSolid() {

Alert

Use `state="Neutral"` for a general-purpose message with no semantic colour.

Loading preview…
1'use client';
2
3import { Alert, Button } from 'sdaia-ui';
4
5export default function AlertNeutral() {

Info

Use `state="Info"` for hints, tips, or supplementary information.

Loading preview…
1'use client';
2
3import { Alert, Button } from 'sdaia-ui';
4
5export default function AlertInfo() {

Success

Use `state="Success"` to confirm a completed action or process.

Loading preview…
1'use client';
2
3import { Alert, Button } from 'sdaia-ui';
4
5export default function AlertSuccess() {

Warning

Use `state="Warning"` for conditions that may need the user's attention.

Loading preview…
1'use client';
2
3import { Alert, Button } from 'sdaia-ui';
4
5export default function AlertWarning() {

Destructive

Use `state="Error"` for critical problems that must be resolved.

Loading preview…
1'use client';
2
3import { Alert, Button } from 'sdaia-ui';
4import { usePreviewDir } from '@/context/PreviewDirContext';
5

API Reference

AlertProps

Props for the Alert component.

Prop

Type

Default

Required

type

'standard' | 'outline' | 'solid'

'standard'

optional

state

'neutral' | 'info' | 'error' | 'warning' | 'success'

-

optional

variant

'neutral' | 'info' | 'error' | 'warning' | 'success'

deprecated

optional

title

string

-

optional

description

string

-

optional

closable

boolean

false

optional

onClose

() => void

-

optional

leadingIcon

ReactNode | boolean

-

optional

icon

ReactNode

deprecated

optional

actions

ReactNode

-

optional

iconTop

boolean

false

optional

children

ReactNode

-

optional
Text Input
Badge
On this page

Profile Settings

SDAIA Admin

Changes saved successfully

Your profile has been updated. The changes are now live across all SDAIA services.

Full nameSarah Ahmed
Emailsarah.ahmed@sdaia.gov.sa
RoleData Analyst
DepartmentAI & Analytics
Last updated just now

Your session will expire soon

For your security, you will be automatically signed out after 5 minutes of inactivity. Save any unsaved work.

Review before submitting

Please review your application details carefully. Once submitted, no further changes can be made.

Platform update available

Version 3.2 includes improved data visualisation tools, faster load times, and enhanced security features.

Your session will expire soon

For your security, you will be automatically signed out after 5 minutes of inactivity. Save any unsaved work.

Scheduled maintenance on Thursday

SDAIA services will be briefly unavailable on 9 May from 2:00 AM – 4:00 AM (AST) for planned maintenance.

Application submitted successfully

Your registration has been received. A confirmation email has been sent to your registered address.

Data export limit approaching

You have used 85% of your monthly data export allowance. Contact your administrator to increase the limit.

Payment could not be processed

Your Mada card was declined. Please verify your card details or try a different payment method.