import React from 'react'; import { Modal, useStyles2, VerticalGroup } from '@grafana/ui'; import { GrafanaTheme2 } from '@grafana/data'; import { css } from '@emotion/css'; export interface UpdatePluginModalProps { onDismiss: () => void; id: string; name: string; } export function UpdatePluginModal({ onDismiss, id, name }: UpdatePluginModalProps): JSX.Element { const styles = useStyles2(getStyles); return (

Type the following on the command line to update {name}.

            grafana-cli plugins update {id}
          
Check out {name} on Grafana.com for README and changelog. If you do not have access to the command line, ask your Grafana administator.

grafana logo Pro tip: To update all plugins at once, type{' '} grafana-cli plugins update-all on the command line.

); } function getStyles(theme: GrafanaTheme2) { return { small: css` font-size: ${theme.typography.bodySmall.fontSize}; font-weight: ${theme.typography.bodySmall.fontWeight}; `, weak: css` color: ${theme.colors.text.disabled}; font-size: ${theme.typography.bodySmall.fontSize}; `, logo: css` vertical-align: sub; margin-right: ${theme.spacing(0.3)}; width: ${theme.spacing(2)}; `, codeSmall: css` white-space: nowrap; margin: 0 ${theme.spacing(0.25)}; padding: ${theme.spacing(0.25)}; `, }; }