Files
gridpilot.gg/apps/website/ui/ErrorActionButtons.tsx
2026-01-18 23:24:30 +01:00

29 lines
681 B
TypeScript

import { Home, RefreshCw } from 'lucide-react';
import { Box } from './Box';
import { Button } from './Button';
export interface ErrorActionButtonsProps {
onRetry?: () => void;
onGoHome?: () => void;
}
export const ErrorActionButtons = ({
onRetry,
onGoHome
}: ErrorActionButtonsProps) => {
return (
<Box display="flex" alignItems="center" gap={4}>
{onRetry && (
<Button variant="primary" onClick={onRetry} icon={<RefreshCw size={16} />}>
Retry
</Button>
)}
{onGoHome && (
<Button variant="secondary" onClick={onGoHome} icon={<Home size={16} />}>
Go Home
</Button>
)}
</Box>
);
};