swarm-ui: a header bell with the count of firing alerts opens a list of them and a link to Grafana
This commit is contained in:
parent
ffcba2b026
commit
70e5de5571
1 changed files with 218 additions and 5 deletions
|
|
@ -19,7 +19,13 @@ import { StaleNote } from "../ui/polled/StaleNote.js";
|
|||
import { Table, type TableColumn } from "../ui/table/Table.js";
|
||||
import { TableSkeleton } from "../ui/table/TableSkeleton.js";
|
||||
import { Toolbar } from "../ui/toolbar/Toolbar.js";
|
||||
import { activeSinceMs, alertKey, listedAlerts, type Alert } from "./alerts.js";
|
||||
import {
|
||||
GRAFANA_ALERTS_URL,
|
||||
activeSinceMs,
|
||||
alertKey,
|
||||
listedAlerts,
|
||||
type Alert,
|
||||
} from "./alerts.js";
|
||||
|
||||
const STATE_TONE: Record<string, BadgeTone> = {
|
||||
Alerting: "negative",
|
||||
|
|
@ -28,10 +34,6 @@ const STATE_TONE: Record<string, BadgeTone> = {
|
|||
Pending: "warning",
|
||||
};
|
||||
|
||||
// Grafana's own alert list, for what this page does not show.
|
||||
const GRAFANA_ALERTS_URL =
|
||||
"https://grafana.constellation.darkest.space/alerting/groups";
|
||||
|
||||
const COLUMNS: TableColumn<Alert>[] = [
|
||||
{
|
||||
key: "name",
|
||||
|
|
|
|||
Loading…
Reference in a new issue