import type { ReactNode } from "react" import { AlertTriangle } from "lucide-react" import { Card, CardContent, CardHeader } from "~/components/ui/card" import { Skeleton } from "~/components/ui/skeleton" type EmptyStateProps = { icon?: ReactNode title: string description?: ReactNode action?: ReactNode secondaryAction?: ReactNode /** When true, wrap the body in a bordered card frame. Default false — * a bare dashed surface that reads as "nothing here yet". */ framed?: boolean } /** Shared empty state. Centred icon disc + title + description + optional * actions, using theme tokens only. Pair with EmptyState → ErrorState → * content branching so a route never renders a bare blank surface. */ export function EmptyState({ icon, title, description, action, secondaryAction, framed = false, }: EmptyStateProps) { const body = (
{title}
{description ? ({description}
) : null}{title}
{message}