import { css } from '@emotion/css'; import React from 'react'; import { PluginErrorCode, PluginSignatureStatus } from '@grafana/data'; import { selectors } from '@grafana/e2e-selectors'; import { HorizontalGroup, InfoBox, List, PluginSignatureBadge, useTheme } from '@grafana/ui'; import { useGetErrors, useFetchStatus } from '../admin/state/hooks'; export function PluginsErrorsInfo(): React.ReactElement | null { const errors = useGetErrors(); const { isLoading } = useFetchStatus(); const theme = useTheme(); if (isLoading || errors.length === 0) { return null; } return (

Unsigned plugins were found during plugin initialization. Grafana Labs cannot guarantee the integrity of these plugins. We recommend only using signed plugins.

The following plugins are disabled and not shown in the list below: (
{error.pluginId}
)} />
); } function mapPluginErrorCodeToSignatureStatus(code: PluginErrorCode) { switch (code) { case PluginErrorCode.invalidSignature: return PluginSignatureStatus.invalid; case PluginErrorCode.missingSignature: return PluginSignatureStatus.missing; case PluginErrorCode.modifiedSignature: return PluginSignatureStatus.modified; default: return PluginSignatureStatus.missing; } }