Skip to main content

Empty

An empty state with a media slot, a title, a description and actions, revealed with a stagger and a layered hover motion.

No presets saved
Create a spring preset to reuse timing and blur across components.
created=0

Customize

Reveal blur (px)4
Speed1

Installation

npx shadcn@latest add @kinetic/empty

Usage

Compose EmptyHeader (media, title, description) and EmptyContent for actions.

import { FolderOpenIcon } from "@heroicons/react/24/outline";
import { Button } from "@/components/kinetic/ui/button";
import {
  Empty,
  EmptyContent,
  EmptyDescription,
  EmptyHeader,
  EmptyMedia,
  EmptyTitle,
} from "@/components/kinetic/ui/empty";

export function NoProjects() {
  return (
    <Empty>
      <EmptyHeader>
        <EmptyMedia variant="icon">
          <FolderOpenIcon />
        </EmptyMedia>
        <EmptyTitle>No projects yet</EmptyTitle>
        <EmptyDescription>Create your first project to get started.</EmptyDescription>
      </EmptyHeader>
      <EmptyContent>
        <Button size="sm">New project</Button>
      </EmptyContent>
    </Empty>
  );
}

Media

EmptyMedia with variant="icon" draws a layered icon box. The default variant is a plain wrapper for images or illustrations.

<EmptyMedia>
  <img src="/empty.svg" alt="" className="size-24" />
</EmptyMedia>

Motion

animateOnMount plays the staggered reveal on first render, and hoverMotion fans the media layers apart on hover. Override hoverMotion per EmptyMedia.

<Empty animateOnMount={false} hoverMotion={false}>...</Empty>

Motion preferences

Use blurPx and speed to tune the reveal. Reduced motion shows the content at once.

API Reference

Empty

Zero-dependency empty-state container orchestrating EmptyMedia reveal, staggered blur-fade content choreography, and layered hover motion.

PropTypeDefaultDescription
animateOnMountbooleantruePlays media entrance and staggered child reveal when mounted.
hoverMotionbooleantrueEnables the layered fan-out on mouse hover.
blurPxnumber4Blur radius in pixels applied during staggered reveal (clamped 0-16).
speednumber1Speed multiplier shared by mount reveal, content stagger, and hover motion (clamped 0.25-4).

EmptyMedia

Leading visual container supporting unstyled media or a layered 40x40 icon.

PropTypeDefaultDescription
variant"default" | "icon""default"Renders transparent wrapper or a layered 40x40 icon box when set to "icon".
hoverMotionboolean-Overrides the parent hover motion setting.

EmptyHeader / EmptyTitle / EmptyDescription / EmptyContent

Centered header stack, heading, description block, and action area targeted by Empty stagger choreography.

PropTypeDefaultDescription
...propsReact.ComponentProps<"div">-Forwards standard div attributes and spacing utilities.

Notes

Use Empty instead of hand-rolled empty placeholder divs. Note that EmptyDescription is typed with paragraph props in TypeScript while rendering a div.