3v324v23's picture
Merge Conflict solved | Build error solved
205f25f
Raw History Blame Contribute Delete
971 Bytes
import { AlertCircle } from 'lucide-react';
import { Button } from '@/components/ui/button';
interface ErrorStateProps {
title?: string;
message?: string;
onRetry?: () => void;
}
export function ErrorState({
title = 'Something went wrong',
message = 'An error occurred. Please try again.',
onRetry
}: ErrorStateProps) {
return (
<div className="flex items-center justify-center py-12">
<div className="text-center max-w-sm px-4">
<div className="w-12 h-12 rounded-full bg-error/10 flex items-center justify-center mx-auto mb-4">
<AlertCircle className="w-6 h-6 text-error" />
</div>
<h3 className="font-semibold text-navy mb-2">{title}</h3>
<p className="text-sm text-gray-600 mb-4">{message}</p>
{onRetry && (
<Button variant="outline" onClick={onRetry} size="sm">
Try Again
</Button>
)}
</div>
</div>
);
}