v0.3.1 StableFoundation ComponentReact 18 & 19Zero Runtime CSS

EmptyState

A composed explanation and next action for empty content.

Interactive preview

No projects yet

Create a workspace to get started.

Usage

import { EmptyState, Button } from "@devvy-ui/react";

<EmptyState title="No projects yet" description="Create a workspace to get started."><Button>Create project</Button></EmptyState>

API reference

Native HTML attributes, className, style and a forwarded ref are supported. Component-specific props:

PropTypeDefaultDescription
title / descriptionReactNoderequired / optionalReadable state and context.
headingLevel2 | 3 | 4 | 5 | 63Document heading rank.
icon / childrenReactNode—Decorative icon and composed actions.

Accessibility & behavior

Platform Behavior & Guidelines

The section is named by its heading; choose a rank appropriate to the page. Icons are decorative. Actions are caller-owned native buttons/links; no network work is implied. Async announcement and loading/error choices belong to the parent. The optional Glass scope can style this surface.

Source ownership

Run npx @devvy-ui/cli init once in your React project, then add the source:

npx @devvy-ui/cli add empty-state

Make the source yours.

Start from the canonical implementation used by the package and registry. Change the code, keep the MIT notice, and build the behavior your project needs.

EmptyState.tsxREACT / TSX

Edit your own copy. Downloaded source uses your changes; the component preview above uses the shipped version. Run the source installer first to include shared helpers.