@checkstack/slo-frontend 0.2.9 → 0.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,46 @@
1
1
  # @checkstack/slo-frontend
2
2
 
3
+ ## 0.3.1
4
+
5
+ ### Patch Changes
6
+
7
+ - @checkstack/dashboard-frontend@0.4.1
8
+
9
+ ## 0.3.0
10
+
11
+ ### Minor Changes
12
+
13
+ - bb1fea0: Redesign system detail page with hero banner, two-column layout, plugin metric tiles, and health check slide-over drawer.
14
+
15
+ ### New Components
16
+
17
+ - **MetricTile** (`@checkstack/ui`): Compact stat tile with icon, label, value, variant coloring
18
+ - **Sheet** (`@checkstack/ui`): Slide-over drawer built on Radix Dialog primitives
19
+
20
+ ### New Extension Slot
21
+
22
+ - **SystemOverviewMetricsSlot** (`@checkstack/catalog-common`): Plugin-contributed at-a-glance metric tiles in the system detail hero banner
23
+
24
+ ### Layout Changes
25
+
26
+ - System detail page now uses a hero banner with breadcrumb, status badges, and metric tile strip
27
+ - Two-column layout: monitoring content (left) and system context (right)
28
+ - Health checks rendered as compact card rows instead of heavy accordions
29
+ - Clicking a health check opens a slide-over drawer with summary tiles, timeline charts, and recent runs
30
+ - Right column uses lightweight borderless sections with dividers instead of heavy Card wrappers
31
+
32
+ ### Plugin Extensions
33
+
34
+ - Health check, SLO, Incident, and Maintenance plugins each contribute a metric tile to the hero banner
35
+
36
+ ### Patch Changes
37
+
38
+ - Updated dependencies [bb1fea0]
39
+ - Updated dependencies [bb1fea0]
40
+ - @checkstack/dashboard-frontend@0.4.0
41
+ - @checkstack/ui@1.4.0
42
+ - @checkstack/catalog-common@1.4.0
43
+
3
44
  ## 0.2.9
4
45
 
5
46
  ### Patch Changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@checkstack/slo-frontend",
3
- "version": "0.2.9",
3
+ "version": "0.3.1",
4
4
  "type": "module",
5
5
  "main": "src/index.tsx",
6
6
  "checkstack": {
@@ -7,15 +7,14 @@ import { SLO_STATUS_CHANGED, sloRoutes } from "@checkstack/slo-common";
7
7
  import { resolveRoute } from "@checkstack/common";
8
8
  import { ErrorBudgetBar } from "./ErrorBudgetBar";
9
9
  import { BurnRateIndicator } from "./BurnRateIndicator";
10
- import { Card, CardContent, CardHeader, CardTitle } from "@checkstack/ui";
11
10
  import { Target } from "lucide-react";
12
11
  import { Link } from "react-router-dom";
13
12
 
14
13
  type Props = SlotContext<typeof SystemDetailsTopSlot>;
15
14
 
16
15
  /**
17
- * SLO panel embedded in the system detail page.
18
- * Shows all SLO objectives for the system with error budget bars.
16
+ * Compact SLO panel embedded in the system detail page alert strip.
17
+ * Shows SLO objectives with error budget bars in a minimal layout.
19
18
  */
20
19
  export const SystemSloPanel: React.FC<Props> = ({ system }) => {
21
20
  const sloClient = usePluginClient(SloApi);
@@ -35,31 +34,29 @@ export const SystemSloPanel: React.FC<Props> = ({ system }) => {
35
34
  if (!objectives || objectives.length === 0) return;
36
35
 
37
36
  return (
38
- <Card className="border-border shadow-sm">
39
- <CardHeader className="border-b border-border bg-muted/30">
37
+ <div className="rounded-md border border-border bg-card">
38
+ <div className="flex items-center justify-between px-3 py-2 border-b border-border/50">
40
39
  <div className="flex items-center gap-2">
41
- <Target className="h-5 w-5 text-muted-foreground" />
42
- <CardTitle className="text-lg font-semibold">
43
- Service Level Objectives
44
- </CardTitle>
40
+ <Target className="h-3.5 w-3.5 text-muted-foreground" />
41
+ <span className="text-sm font-medium">SLO</span>
45
42
  </div>
46
- </CardHeader>
47
- <CardContent className="p-6">
48
- <div className="space-y-4">
49
- {objectives.map((item) => (
50
- <Link
51
- key={item.objective.id}
52
- to={resolveRoute(sloRoutes.routes.detail, {
53
- sloId: item.objective.id,
54
- })}
55
- className="block space-y-2 rounded-md border border-border p-3 transition-colors hover:border-primary/50 no-underline"
56
- >
57
- <div className="flex items-center justify-between">
58
- <span className="text-sm font-medium">
59
- {item.objective.target}% / {item.objective.windowDays}d
60
- </span>
61
- <BurnRateIndicator burnRate={item.status.burnRate} />
62
- </div>
43
+ </div>
44
+ <div className="divide-y divide-border/50">
45
+ {objectives.map((item) => (
46
+ <Link
47
+ key={item.objective.id}
48
+ to={resolveRoute(sloRoutes.routes.detail, {
49
+ sloId: item.objective.id,
50
+ })}
51
+ className="flex items-center gap-3 px-3 py-2 hover:bg-muted/50 transition-colors no-underline"
52
+ >
53
+ <div className="flex items-center gap-2 min-w-0 shrink-0">
54
+ <span className="text-xs font-medium whitespace-nowrap">
55
+ {item.objective.target}% / {item.objective.windowDays}d
56
+ </span>
57
+ <BurnRateIndicator burnRate={item.status.burnRate} />
58
+ </div>
59
+ <div className="flex-1 min-w-0">
63
60
  <ErrorBudgetBar
64
61
  consumedPercent={
65
62
  100 - item.status.errorBudgetRemainingPercent
@@ -71,20 +68,13 @@ export const SystemSloPanel: React.FC<Props> = ({ system }) => {
71
68
  item.objective.burnRateThresholds.criticalPercent
72
69
  }
73
70
  />
74
- <div className="flex items-center justify-between text-xs text-muted-foreground">
75
- <span>
76
- {item.status.currentAvailability?.toFixed(3) ?? "—"}%
77
- availability
78
- </span>
79
- <span>
80
- {item.status.errorBudgetRemainingMinutes.toFixed(1)} min
81
- remaining
82
- </span>
83
- </div>
84
- </Link>
85
- ))}
86
- </div>
87
- </CardContent>
88
- </Card>
71
+ </div>
72
+ <span className="text-xs text-muted-foreground whitespace-nowrap shrink-0">
73
+ {item.status.currentAvailability?.toFixed(3) ?? "—"}%
74
+ </span>
75
+ </Link>
76
+ ))}
77
+ </div>
78
+ </div>
89
79
  );
90
80
  };
package/src/index.tsx CHANGED
@@ -3,21 +3,17 @@ import {
3
3
  createSlotExtension,
4
4
  UserMenuItemsSlot,
5
5
  } from "@checkstack/frontend-api";
6
- import {
7
- sloRoutes,
8
- pluginMetadata,
9
- sloAccess,
10
- } from "@checkstack/slo-common";
11
- import {
12
- SystemDetailsTopSlot,
13
- SystemStateBadgesSlot,
14
- } from "@checkstack/catalog-common";
6
+ import { sloRoutes, pluginMetadata, sloAccess } from "@checkstack/slo-common";
15
7
  import { SloOverviewPage } from "./pages/SloOverviewPage";
16
8
  import { SloConfigPage } from "./pages/SloConfigPage";
17
9
  import { SloDetailPage } from "./pages/SloDetailPage";
18
10
  import { SystemSloPanel } from "./components/SystemSloPanel";
19
11
  import { SystemSloBadge } from "./components/SystemSloBadge";
20
12
  import { SloMenuItems } from "./components/SloMenuItems";
13
+ import {
14
+ SystemDetailsTopSlot,
15
+ SystemStateBadgesSlot,
16
+ } from "@checkstack/catalog-common";
21
17
 
22
18
  export default createFrontendPlugin({
23
19
  metadata: pluginMetadata,