mirror of
https://github.com/iflytek/skillhub.git
synced 2026-10-24 05:43:52 +00:00
19 lines
556 B
TypeScript
19 lines
556 B
TypeScript
import type { ReactNode } from 'react'
|
|
|
|
interface EmptyStateProps {
|
|
title: string
|
|
description?: string
|
|
action?: ReactNode
|
|
}
|
|
|
|
export function EmptyState({ title, description, action }: EmptyStateProps) {
|
|
return (
|
|
<div className="flex flex-col items-center justify-center py-12 text-center">
|
|
<h3 className="text-lg font-semibold text-foreground">{title}</h3>
|
|
{description && (
|
|
<p className="mt-2 text-sm text-muted-foreground">{description}</p>
|
|
)}
|
|
{action && <div className="mt-4">{action}</div>}
|
|
</div>
|
|
)
|
|
}
|