Alerts/InfoBox: Replaces all uses of InfoBox & FeatureInfoBox with Alert (#33352)

* Alerts/InfoBox: Replaces all uses of InfoBox & FeatureInfoBox with Alert

* Fixes some more stuff

* fixed border radius
This commit is contained in:
Torkel Ödegaard
2021-04-26 07:18:46 +02:00
committed by GitHub
parent 19739f4af2
commit cf2d557974
23 changed files with 235 additions and 334 deletions

View File

@@ -1,6 +1,6 @@
import React, { FC, useMemo } from 'react';
import { GrafanaTheme } from '@grafana/data';
import { PageToolbar, ToolbarButton, useStyles, CustomScrollbar, Spinner, Alert, InfoBox } from '@grafana/ui';
import { PageToolbar, ToolbarButton, useStyles, CustomScrollbar, Spinner, Alert } from '@grafana/ui';
import { css } from '@emotion/css';
import { AlertTypeStep } from './AlertTypeStep';
@@ -100,9 +100,10 @@ export const AlertRuleForm: FC<Props> = ({ existing }) => {
<CustomScrollbar autoHeightMin="100%" hideHorizontalTrack={true}>
<div className={styles.contentInner}>
{hasErrors && (
<InfoBox severity="error">
There are errors in the form below. Please fix them and try saving again.
</InfoBox>
<Alert
severity="error"
title="There are errors in the form below. Please fix them and try saving again"
/>
)}
{submitState.error && (
<Alert severity="error" title="Error saving rule">