@checkstack/anomaly-frontend 0.4.3 → 0.4.5
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,61 @@
|
|
|
1
1
|
# @checkstack/anomaly-frontend
|
|
2
2
|
|
|
3
|
+
## 0.4.5
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- f23f3c9: Gate decorative motion and blur effects behind
|
|
8
|
+
`usePerformance().isLowPower` on a focused set of high-traffic plugin
|
|
9
|
+
pages (Dashboard, Dependency map, System node, Notification bell,
|
|
10
|
+
Announcement banner / cards, Anomaly field overrides editor, SLO
|
|
11
|
+
attribution chart, Catalog droppable group). Hover scales, backdrop
|
|
12
|
+
blurs, `animate-pulse`/`animate-ping` accents, and entry transitions
|
|
13
|
+
now drop to static states on low-power devices; functional UX
|
|
14
|
+
transitions (Drawer/Dialog open-close, colour transitions) are left
|
|
15
|
+
alone.
|
|
16
|
+
|
|
17
|
+
Standardise the post-mutation error-toast voice on plugin pages by
|
|
18
|
+
migrating multi-clause `toast.error(extractErrorMessage(error, "Failed
|
|
19
|
+
to X"))` call sites onto the `toastError(toast, "Failed to X", error)`
|
|
20
|
+
helper from `@checkstack/ui`. The helper applies the canonical
|
|
21
|
+
`"action: message"` prefix and 100-character truncation in one place,
|
|
22
|
+
and the now-orphaned `extractErrorMessage` imports are dropped from
|
|
23
|
+
the affected files. No business logic or component APIs changed.
|
|
24
|
+
|
|
25
|
+
- Updated dependencies [f23f3c9]
|
|
26
|
+
- Updated dependencies [f23f3c9]
|
|
27
|
+
- Updated dependencies [f23f3c9]
|
|
28
|
+
- Updated dependencies [f23f3c9]
|
|
29
|
+
- Updated dependencies [f23f3c9]
|
|
30
|
+
- Updated dependencies [f23f3c9]
|
|
31
|
+
- Updated dependencies [f23f3c9]
|
|
32
|
+
- Updated dependencies [f23f3c9]
|
|
33
|
+
- @checkstack/common@0.11.0
|
|
34
|
+
- @checkstack/healthcheck-frontend@0.19.5
|
|
35
|
+
- @checkstack/notification-common@1.2.0
|
|
36
|
+
- @checkstack/notification-frontend@0.4.5
|
|
37
|
+
- @checkstack/frontend-api@0.5.2
|
|
38
|
+
- @checkstack/ui@1.10.0
|
|
39
|
+
- @checkstack/anomaly-common@1.2.2
|
|
40
|
+
- @checkstack/catalog-common@2.2.2
|
|
41
|
+
- @checkstack/healthcheck-common@1.1.2
|
|
42
|
+
- @checkstack/signal-frontend@0.1.4
|
|
43
|
+
|
|
44
|
+
## 0.4.4
|
|
45
|
+
|
|
46
|
+
### Patch Changes
|
|
47
|
+
|
|
48
|
+
- Updated dependencies [a06b899]
|
|
49
|
+
- Updated dependencies [a06b899]
|
|
50
|
+
- Updated dependencies [a06b899]
|
|
51
|
+
- @checkstack/notification-common@1.1.1
|
|
52
|
+
- @checkstack/healthcheck-frontend@0.19.4
|
|
53
|
+
- @checkstack/ui@1.9.0
|
|
54
|
+
- @checkstack/anomaly-common@1.2.1
|
|
55
|
+
- @checkstack/catalog-common@2.2.1
|
|
56
|
+
- @checkstack/healthcheck-common@1.1.1
|
|
57
|
+
- @checkstack/notification-frontend@0.4.4
|
|
58
|
+
|
|
3
59
|
## 0.4.3
|
|
4
60
|
|
|
5
61
|
### Patch Changes
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@checkstack/anomaly-frontend",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.5",
|
|
4
4
|
"license": "Elastic-2.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "src/index.tsx",
|
|
@@ -13,16 +13,16 @@
|
|
|
13
13
|
"lint:code": "eslint . --max-warnings 0"
|
|
14
14
|
},
|
|
15
15
|
"dependencies": {
|
|
16
|
-
"@checkstack/anomaly-common": "1.2.
|
|
17
|
-
"@checkstack/catalog-common": "2.2.
|
|
16
|
+
"@checkstack/anomaly-common": "1.2.1",
|
|
17
|
+
"@checkstack/catalog-common": "2.2.1",
|
|
18
18
|
"@checkstack/common": "0.10.0",
|
|
19
19
|
"@checkstack/frontend-api": "0.5.1",
|
|
20
|
-
"@checkstack/healthcheck-common": "1.1.
|
|
21
|
-
"@checkstack/healthcheck-frontend": "0.19.
|
|
22
|
-
"@checkstack/notification-common": "1.1.
|
|
23
|
-
"@checkstack/notification-frontend": "0.4.
|
|
20
|
+
"@checkstack/healthcheck-common": "1.1.1",
|
|
21
|
+
"@checkstack/healthcheck-frontend": "0.19.4",
|
|
22
|
+
"@checkstack/notification-common": "1.1.1",
|
|
23
|
+
"@checkstack/notification-frontend": "0.4.4",
|
|
24
24
|
"@checkstack/signal-frontend": "0.1.3",
|
|
25
|
-
"@checkstack/ui": "1.
|
|
25
|
+
"@checkstack/ui": "1.9.0",
|
|
26
26
|
"date-fns": "^4.1.0",
|
|
27
27
|
"lucide-react": "^0.344.0",
|
|
28
28
|
"react": "^18.2.0",
|
|
@@ -24,6 +24,8 @@ import {
|
|
|
24
24
|
Slider,
|
|
25
25
|
Input,
|
|
26
26
|
Tooltip,
|
|
27
|
+
cn,
|
|
28
|
+
usePerformance,
|
|
27
29
|
} from "@checkstack/ui";
|
|
28
30
|
import type {
|
|
29
31
|
AnomalyFieldConfig,
|
|
@@ -362,6 +364,7 @@ function FieldAccordionItem({
|
|
|
362
364
|
onResetField,
|
|
363
365
|
applyPreset,
|
|
364
366
|
}: FieldAccordionItemProps) {
|
|
367
|
+
const { isLowPower } = usePerformance();
|
|
365
368
|
const [advancedOpen, setAdvancedOpen] = useState(preset === "custom");
|
|
366
369
|
// Tracks an explicit "Custom" click — needed because clicking Custom doesn't
|
|
367
370
|
// change values, so `detectPreset` still resolves to whatever the prior
|
|
@@ -400,10 +403,13 @@ function FieldAccordionItem({
|
|
|
400
403
|
return (
|
|
401
404
|
<AccordionItem
|
|
402
405
|
value={field}
|
|
403
|
-
className={
|
|
404
|
-
rounded-xl border bg-card text-card-foreground shadow-sm
|
|
405
|
-
|
|
406
|
-
|
|
406
|
+
className={cn(
|
|
407
|
+
"rounded-xl border bg-card text-card-foreground shadow-sm overflow-hidden",
|
|
408
|
+
!isLowPower && "transition-all duration-200",
|
|
409
|
+
isOverridden
|
|
410
|
+
? "border-primary/40 shadow-md"
|
|
411
|
+
: "border-border/40 opacity-80 hover:opacity-100",
|
|
412
|
+
)}
|
|
407
413
|
>
|
|
408
414
|
<AccordionTrigger className="px-5 py-4 hover:no-underline">
|
|
409
415
|
<div className="flex items-center justify-between flex-1 gap-4 mr-4">
|
|
@@ -544,6 +550,7 @@ interface PresetSelectorProps {
|
|
|
544
550
|
}
|
|
545
551
|
|
|
546
552
|
function PresetSelector({ value, onChange, disabled }: PresetSelectorProps) {
|
|
553
|
+
const { isLowPower } = usePerformance();
|
|
547
554
|
const options: Preset[] = ["strict", "balanced", "relaxed", "custom"];
|
|
548
555
|
const description =
|
|
549
556
|
value === "custom"
|
|
@@ -567,16 +574,14 @@ function PresetSelector({ value, onChange, disabled }: PresetSelectorProps) {
|
|
|
567
574
|
type="button"
|
|
568
575
|
onClick={() => onChange(opt)}
|
|
569
576
|
disabled={disabled}
|
|
570
|
-
className={
|
|
571
|
-
px-4 py-1.5 text-xs font-semibold rounded-md
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
capitalize
|
|
579
|
-
`}
|
|
577
|
+
className={cn(
|
|
578
|
+
"px-4 py-1.5 text-xs font-semibold rounded-md",
|
|
579
|
+
!isLowPower && "transition-all",
|
|
580
|
+
selected
|
|
581
|
+
? "bg-background text-foreground shadow-sm"
|
|
582
|
+
: "text-muted-foreground hover:text-foreground",
|
|
583
|
+
"disabled:opacity-50 disabled:cursor-not-allowed capitalize",
|
|
584
|
+
)}
|
|
580
585
|
>
|
|
581
586
|
{opt}
|
|
582
587
|
</button>
|
|
@@ -667,6 +672,7 @@ function AdvancedDisclosure({
|
|
|
667
672
|
onToggle,
|
|
668
673
|
children,
|
|
669
674
|
}: AdvancedDisclosureProps) {
|
|
675
|
+
const { isLowPower } = usePerformance();
|
|
670
676
|
return (
|
|
671
677
|
<div className="border border-border/40 rounded-md bg-background/30">
|
|
672
678
|
<button
|
|
@@ -676,7 +682,11 @@ function AdvancedDisclosure({
|
|
|
676
682
|
>
|
|
677
683
|
<span>Advanced</span>
|
|
678
684
|
<ChevronDown
|
|
679
|
-
className={
|
|
685
|
+
className={cn(
|
|
686
|
+
"w-4 h-4",
|
|
687
|
+
!isLowPower && "transition-transform",
|
|
688
|
+
open && "rotate-180",
|
|
689
|
+
)}
|
|
680
690
|
/>
|
|
681
691
|
</button>
|
|
682
692
|
{open && (
|