Skip to content
nexubDesign System
v12.7.0

Components · Data Display

Error State

StableAdded v0.0.1

Full-page or section error view with retry action.

import { ErrorState } from '@nexub/react';
View as Markdown

Playground

Props

tone

Something went wrong

We could not load the data. Please try again.

TSX
<ErrorState onRetry={() => {}} description="We could not load the data. Please try again." title="Something went wrong" />

Examples

Default

Something went wrong

We could not load the data. Please try again.

Warning

Connection issue

Check your network and try again.

States

  • Something went wrong

    We could not load the data. Please try again.

    default
  • Something went wrong

    We could not load the data. Please try again.

    tone="error"
  • Something went wrong

    We could not load the data. Please try again.

    tone="info"
  • Something went wrong

    We could not load the data. Please try again.

    tone="warning"

Props

Props
PropTypeDefaultDescription
titlerequiredstring—Primary error heading shown to the user.
descriptionstring—Supporting text with more detail about the error or recovery steps.
tone'error' | 'info' | 'warning''error'Controls the icon and colour scheme of the error state.
onRetry(() => void)—When provided, renders a "Try again" button that calls this function on click.
retryLabelReact.ReactNode'Try again'Text of the retry button.