import { ErrorComponent, Link, rootRouteId, useMatch, useRouter, } from '@tanstack/react-router' import type { ErrorComponentProps } from '@tanstack/react-router' import { Button } from '@/components/ui/button' import { Alert, AlertDescription, AlertTitle } from '@/components/ui/alert' import { AlertCircle } from 'lucide-react' export function DefaultCatchBoundary({ error }: ErrorComponentProps) { const router = useRouter() const isRoot = useMatch({ strict: false, select: (state) => state.id === rootRouteId, }) console.error('DefaultCatchBoundary Error:', error) return (