Files
Verso/services/web/frontend/js/features/pdf-preview/components/pdf-code-check-failed-notice.tsx
T
David 1d648f9755 Merge pull request #23502 from overleaf/dp-pdf-typescript
Convert PDF Preview components to typescript

GitOrigin-RevId: 34594d21143727fa42b8b595aa12125a4dd7ae5e
2025-02-13 09:06:41 +00:00

31 lines
870 B
TypeScript

import { memo } from 'react'
import { useTranslation } from 'react-i18next'
import Icon from '../../../shared/components/icon'
import OLNotification from '@/features/ui/components/ol/ol-notification'
import { bsVersion } from '@/features/utils/bootstrap-5'
import BootstrapVersionSwitcher from '@/features/ui/components/bootstrap-5/bootstrap-version-switcher'
function PdfCodeCheckFailedNotice() {
const { t } = useTranslation()
return (
<OLNotification
type="error"
content={
<>
<BootstrapVersionSwitcher
bs3={
<>
<Icon type="exclamation-triangle" fw />{' '}
</>
}
/>
{t('code_check_failed_explanation')}
</>
}
className={bsVersion({ bs5: 'm-0', bs3: 'mb-2' })}
/>
)
}
export default memo(PdfCodeCheckFailedNotice)