"use client"; /* * Documentation: * Button — https://app.subframe.com/f023064a5ca0/library?component=Button_3b777358-b86b-40af-9327-891efc6826fe * Empty State — https://app.subframe.com/f023064a5ca0/library?component=Empty+State_9fcf03a9-ada9-4a3d-80bc-87ff6ce78023 */ import React from "react"; import * as SubframeUtils from "../../utils"; export interface EmptyStateRootProps extends Omit, "title"> { variant?: "default" | "no-results" | "error"; outlined?: boolean; fillContainer?: boolean; title?: React.ReactNode; body?: React.ReactNode; // Optional call-to-action rendered below the text. When omitted (the default), // no button is shown. Replaces the previous hard-coded "Create project" button. action?: React.ReactNode; className?: string; } const EmptyStateRoot = React.forwardRef(function EmptyStateRoot( { variant = "default", outlined = false, fillContainer = false, title, body, action, className, ...otherProps }: EmptyStateRootProps, ref ) { return (
{title ? {title} : null} {body ? ( {body} ) : null}
{action ?
{action}
: null}
); }); export const EmptyState = EmptyStateRoot;