import { EmptyStateIllustration } from "../../presentation/EmptyStateIllustration";

interface EmptyStateProps {
    title?: string;
    description?: string;
    illustration?: React.ReactNode;
}

export const EmptyState = ({
    title = "暂无数据",
    description = "当前列表为空，请稍后再试",
    illustration: Illustration = <EmptyStateIllustration></EmptyStateIllustration>
}: EmptyStateProps) => {
    return (
        <div className="flex flex-col items-center justify-center">
            {Illustration}
            <h3 className="mb-2 text-xl font-medium text-slate-800">
                {title}
            </h3>
            <p className="text-slate-500">
                {description}
            </p>
        </div>
    );
};