overleaf/services/web/frontend/js/features/pdf-preview/components/pdf-code-check-failed-notice.jsx

31 lines
870 B
React
Raw Normal View History

import { memo } from 'react'
import { useTranslation } from 'react-i18next'
import Icon from '../../../shared/components/icon'
2024-10-23 03:32:40 -04:00
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 (
2024-10-23 03:32:40 -04:00
<OLNotification
type="error"
content={
<>
<BootstrapVersionSwitcher
bs3={
<>
<Icon type="exclamation-triangle" fw />{' '}
</>
}
/>
{t('code_check_failed_explanation')}
2024-10-23 03:32:40 -04:00
</>
}
className={bsVersion({ bs5: 'm-0', bs3: 'mb-2' })}
/>
)
}
export default memo(PdfCodeCheckFailedNotice)