'use client'; import { AlertCircle, RefreshCw, X } from 'lucide-react'; import { cn } from '@djangocfg/ui-core/lib'; import { useChatDestructiveStyles } from '../styles'; export interface ErrorBannerProps { error: string | null; onDismiss?: () => void; onRetry?: () => void; className?: string; } export function ErrorBanner({ error, onDismiss, onRetry, className }: ErrorBannerProps) { const styles = useChatDestructiveStyles(); if (!error) return null; return (
{error}
{onRetry ? ( ) : null} {onDismiss ? ( ) : null}