LogsTableEmptyState.tsx30 lines · main
| 1 | import { Search } from 'lucide-react' |
| 2 | |
| 3 | const EmptyStateRow = () => { |
| 4 | return ( |
| 5 | <div className="relative flex h-4 w-32 items-center rounded-sm border border-dashed border-stronger px-2" /> |
| 6 | ) |
| 7 | } |
| 8 | |
| 9 | export function LogsTableEmptyState({ |
| 10 | title = 'No results found', |
| 11 | description = 'Try another search or adjust the filters', |
| 12 | }: { |
| 13 | title?: string |
| 14 | description?: string |
| 15 | }) { |
| 16 | return ( |
| 17 | <div className="flex scale-100 flex-col items-center justify-center gap-6 text-center opacity-100 h-full"> |
| 18 | <div className="flex flex-col gap-1 relative"> |
| 19 | <EmptyStateRow /> |
| 20 | <EmptyStateRow /> |
| 21 | <EmptyStateRow /> |
| 22 | <Search size={30} className="absolute right-3 -bottom-2 text-foreground-lighter" /> |
| 23 | </div> |
| 24 | <div className="flex flex-col gap-1 px-5"> |
| 25 | <h3 className="text-lg text-foreground">{title}</h3> |
| 26 | <p className="text-sm max-w-xs text-foreground-lighter">{description}</p> |
| 27 | </div> |
| 28 | </div> |
| 29 | ) |
| 30 | } |