mirror of
https://github.com/bitbaum/botsmann.git
synced 2026-12-04 22:38:46 +01:00
Security fixes: - Add npm override for fast-xml-parser@^5.3.4 to fix RangeError DoS - Update @aws-sdk/client-ses to 3.980.0 - Reduces vulnerabilities from 25 to 8 (fixed 17 high severity) Code improvements (prep for future Next.js 15): - Replace <a> tags with <Link> components for internal navigation - Create ConsultationFormLoader client wrapper for dynamic imports - Use direct Analytics import instead of dynamic with ssr:false - Add eslint-disable for global-error.tsx (intentional <a> usage) Remaining vulnerabilities (require breaking changes): - 7 moderate: eslint circular reference stack overflow - 1 high: Next.js DoS (specific conditions, low practical risk) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
36 lines
1.2 KiB
TypeScript
36 lines
1.2 KiB
TypeScript
import { type FC } from 'react';
|
|
import Link from 'next/link';
|
|
|
|
interface BotNotFoundFallbackProps {
|
|
botName?: string;
|
|
}
|
|
|
|
/**
|
|
* Consistent error fallback when bot configuration is not found
|
|
*/
|
|
export const BotNotFoundFallback: FC<BotNotFoundFallbackProps> = ({ botName = 'Bot' }) => {
|
|
return (
|
|
<div className="min-h-screen flex items-center justify-center bg-white">
|
|
<div className="p-8 text-center">
|
|
<div className="text-6xl mb-4">🤖</div>
|
|
<h1 className="text-2xl font-semibold text-gray-900 mb-2">{botName} Not Found</h1>
|
|
<p className="text-gray-600 mb-6">The bot configuration could not be loaded.</p>
|
|
<Link
|
|
href="/bots"
|
|
className="inline-flex items-center px-4 py-2 bg-blue-600 text-white rounded-md hover:bg-blue-700 transition-colors"
|
|
>
|
|
<svg className="w-4 h-4 mr-2" fill="none" stroke="currentColor" viewBox="0 0 24 24">
|
|
<path
|
|
strokeLinecap="round"
|
|
strokeLinejoin="round"
|
|
strokeWidth={2}
|
|
d="M15 19l-7-7 7-7"
|
|
/>
|
|
</svg>
|
|
Back to All Bots
|
|
</Link>
|
|
</div>
|
|
</div>
|
|
);
|
|
};
|