ConceptPortal-public/rsconcept/frontend/src/app/ErrorFallback.tsx
Ivan 91dbd0e88f
Some checks are pending
Frontend CI / build (22.x) (push) Waiting to run
F: Rework colors using tailwind configs
2024-12-17 00:05:45 +03:00

17 lines
556 B
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import { type FallbackProps } from 'react-error-boundary';
import InfoError from '../components/info/InfoError';
import Button from '../components/ui/Button';
function ErrorFallback({ error, resetErrorBoundary }: FallbackProps) {
return (
<div className='flex flex-col gap-3 items-center antialiased' role='alert'>
<h1>Что-то пошло не так!</h1>
<Button onClick={resetErrorBoundary} text='Попробовать еще раз' />
<InfoError error={error as Error} />
</div>
);
}
export default ErrorFallback;