diff --git a/public/app/features/alerting/unified/PanelAlertTabContent.test.tsx b/public/app/features/alerting/unified/PanelAlertTabContent.test.tsx index 0e3b84c1c79..016e70e87b0 100644 --- a/public/app/features/alerting/unified/PanelAlertTabContent.test.tsx +++ b/public/app/features/alerting/unified/PanelAlertTabContent.test.tsx @@ -181,7 +181,6 @@ const server = setupMswServer(); describe('PanelAlertTabContent', () => { beforeEach(() => { - jest.resetAllMocks(); grantUserPermissions([ AccessControlAction.AlertingRuleRead, AccessControlAction.AlertingRuleUpdate, diff --git a/public/app/features/alerting/unified/PanelAlertTabContent.tsx b/public/app/features/alerting/unified/PanelAlertTabContent.tsx index e0be9d23f81..41d38cd6014 100644 --- a/public/app/features/alerting/unified/PanelAlertTabContent.tsx +++ b/public/app/features/alerting/unified/PanelAlertTabContent.tsx @@ -2,7 +2,8 @@ import { css } from '@emotion/css'; import { GrafanaTheme2 } from '@grafana/data'; import { selectors } from '@grafana/e2e-selectors'; -import { Alert, CustomScrollbar, LoadingPlaceholder, useStyles2 } from '@grafana/ui'; +import { Alert, LoadingPlaceholder, useStyles2 } from '@grafana/ui'; +import { ScrollContainer } from '@grafana/ui/src/unstable'; import { contextSrv } from 'app/core/services/context_srv'; import { DashboardModel, PanelModel } from 'app/features/dashboard/state'; @@ -46,7 +47,7 @@ export const PanelAlertTabContent = ({ dashboard, panel }: Props) => { if (rules.length) { return ( - +
{alert} @@ -54,7 +55,7 @@ export const PanelAlertTabContent = ({ dashboard, panel }: Props) => { )}
-
+ ); } diff --git a/public/app/features/alerting/unified/components/rule-editor/alert-rule-form/AlertRuleForm.tsx b/public/app/features/alerting/unified/components/rule-editor/alert-rule-form/AlertRuleForm.tsx index b10805b707c..fba035a6daa 100644 --- a/public/app/features/alerting/unified/components/rule-editor/alert-rule-form/AlertRuleForm.tsx +++ b/public/app/features/alerting/unified/components/rule-editor/alert-rule-form/AlertRuleForm.tsx @@ -5,7 +5,7 @@ import { useParams } from 'react-router-dom-v5-compat'; import { GrafanaTheme2 } from '@grafana/data'; import { config, locationService } from '@grafana/runtime'; -import { Button, ConfirmModal, CustomScrollbar, Spinner, Stack, useStyles2 } from '@grafana/ui'; +import { Button, ConfirmModal, Spinner, Stack, useStyles2 } from '@grafana/ui'; import { AppChromeUpdate } from 'app/core/components/AppChrome/AppChromeUpdate'; import { useAppNotification } from 'app/core/copy/appNotification'; import { contextSrv } from 'app/core/core'; @@ -285,38 +285,36 @@ export const AlertRuleForm = ({ existing, prefill }: Props) => {
e.preventDefault()} className={styles.form}>
{isPaused && } - - - {/* Step 1 */} - - {/* Step 2 */} - - {/* Step 3-4-5 */} - {showDataSourceDependantStep && ( - <> - {/* Step 3 */} - {isGrafanaManagedRuleByType(type) && ( - - )} + + {/* Step 1 */} + + {/* Step 2 */} + + {/* Step 3-4-5 */} + {showDataSourceDependantStep && ( + <> + {/* Step 3 */} + {isGrafanaManagedRuleByType(type) && ( + + )} - {type === RuleFormType.cloudAlerting && } + {type === RuleFormType.cloudAlerting && } - {type === RuleFormType.cloudRecording && } + {type === RuleFormType.cloudRecording && } - {/* Step 4 & 5 */} - {/* Notifications step*/} - - {/* Annotations only for cloud and Grafana */} - {!isRecordingRuleByType(type) && } - - )} - - + {/* Step 4 & 5 */} + {/* Notifications step*/} + + {/* Annotations only for cloud and Grafana */} + {!isRecordingRuleByType(type) && } + + )} +
{showDeleteModal ? ( diff --git a/public/app/features/alerting/unified/components/rule-editor/alert-rule-form/ModifyExportRuleForm.tsx b/public/app/features/alerting/unified/components/rule-editor/alert-rule-form/ModifyExportRuleForm.tsx index 79eef183128..099b00dd47f 100644 --- a/public/app/features/alerting/unified/components/rule-editor/alert-rule-form/ModifyExportRuleForm.tsx +++ b/public/app/features/alerting/unified/components/rule-editor/alert-rule-form/ModifyExportRuleForm.tsx @@ -2,7 +2,7 @@ import { memo, useCallback, useEffect, useMemo, useState } from 'react'; import { FormProvider, useForm } from 'react-hook-form'; import { useAsync } from 'react-use'; -import { Button, CustomScrollbar, LinkButton, LoadingPlaceholder, Stack } from '@grafana/ui'; +import { Button, LinkButton, LoadingPlaceholder, Stack } from '@grafana/ui'; import { useAppNotification } from 'app/core/copy/appNotification'; import { useQueryParams } from 'app/core/hooks/useQueryParams'; @@ -85,28 +85,26 @@ export function ModifyExportRuleForm({ ruleForm, alertUid }: ModifyExportRuleFor
e.preventDefault()}>
- - - {/* Step 1 */} - - {/* Step 2 */} - - {/* Step 3-4-5 */} + + {/* Step 1 */} + + {/* Step 2 */} + + {/* Step 3-4-5 */} - + - {/* Step 4 & 5 */} - {/* Notifications step*/} - - {/* Annotations only for cloud and Grafana */} - - - + {/* Step 4 & 5 */} + {/* Notifications step*/} + + {/* Annotations only for cloud and Grafana */} + +
{exportData && }