mirror of
https://github.com/hanzoai/sentinel.git
synced 2026-09-29 22:34:33 +00:00
23 lines
627 B
TypeScript
23 lines
627 B
TypeScript
import {Alert} from 'sentry/components/alert';
|
|
import {t} from 'sentry/locale';
|
|
import type {Integration} from 'sentry/types';
|
|
import {getIntegrationStatus} from 'sentry/utils/integrationUtil';
|
|
|
|
type Props = {
|
|
integrations: Integration[] | null;
|
|
};
|
|
|
|
function ReinstallAlert({integrations = []}: Props) {
|
|
const statusList = integrations?.map(getIntegrationStatus);
|
|
if (statusList?.includes('disabled')) {
|
|
return (
|
|
<Alert data-test-id="disabled-alert" type="warning" showIcon>
|
|
{t('Reinstall required for disabled integrations.')}
|
|
</Alert>
|
|
);
|
|
}
|
|
return null;
|
|
}
|
|
|
|
export default ReinstallAlert;
|