Submit
Path:
~
/
/
usr
/
share
/
grafana
/
public
/
app
/
features
/
alerting
/
unified
/
components
/
contact-points
/
components
/
File Content:
GlobalConfig.tsx
import React from 'react'; import { Alert } from '@grafana/ui'; import { useAlertmanagerConfig } from '../../../hooks/useAlertmanagerConfig'; import { useAlertmanager } from '../../../state/AlertmanagerContext'; import { GlobalConfigForm } from '../../receivers/GlobalConfigForm'; const NewMessageTemplate = () => { const { selectedAlertmanager } = useAlertmanager(); const { data, isLoading, error } = useAlertmanagerConfig(selectedAlertmanager); if (isLoading && !data) { return 'loading...'; } if (error) { return ( <Alert severity="error" title="Failed to fetch notification template"> {String(error)} </Alert> ); } if (!data) { return null; } return <GlobalConfigForm config={data} alertManagerSourceName={selectedAlertmanager!} />; }; export default NewMessageTemplate;
Submit
FILE
FOLDER
INFO
Name
Size
Permission
Action
ContactPointsFilter.tsx
1662 bytes
0644
GlobalConfig.tsx
838 bytes
0644
GlobalConfigAlert.tsx
1161 bytes
0644
Modals.tsx
2630 bytes
0644
UnusedBadge.tsx
330 bytes
0644
N4ST4R_ID | Naxtarrr