1
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

23 lines
769 B

import { CallToActionCard } from '@grafana/ui';
import EmptyListCTA from 'app/core/components/EmptyListCTA/EmptyListCTA';
import { contextSrv } from 'app/core/services/context_srv';
import React, { FC } from 'react';
import { makeAMLink } from '../../utils/misc';
type Props = {
alertManagerSourceName: string;
};
export const NoSilencesSplash: FC<Props> = ({ alertManagerSourceName }) => {
if (contextSrv.isEditor) {
return (
<EmptyListCTA
title="You haven't created any silences yet"
buttonIcon="bell-slash"
buttonLink={makeAMLink('alerting/silence/new', alertManagerSourceName)}
buttonTitle="New silence"
/>
);
}
return <CallToActionCard callToActionElement={<div />} message="No silences found." />;
};