@devicechain/widgets 0.23.0-rc.1 → 0.24.0-rc.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/README.md +8 -3
- package/dist/aggregate-fold.d.ts +3 -2
- package/dist/aggregate-strings.d.ts +1 -0
- package/dist/alarm-strings.d.ts +18 -0
- package/dist/binding-policy.d.ts +4 -0
- package/dist/bound-devices-notice.d.ts +30 -0
- package/dist/builtin-descriptors.d.ts +290 -249
- package/dist/builtin-option-docs.d.ts +2 -0
- package/dist/builtin-registry.d.ts +249 -226
- package/dist/category-geometry.d.ts +1 -0
- package/dist/chunks/{aggregate-feed-BD3CHNFU.js → aggregate-feed-4FSBQYJL.js} +39 -11
- package/dist/chunks/aggregate-feed-4FSBQYJL.js.map +7 -0
- package/dist/chunks/{aggregate-widgets-HZQI5HTX.js → aggregate-widgets-2ZQBW3YF.js} +376 -182
- package/dist/chunks/aggregate-widgets-2ZQBW3YF.js.map +7 -0
- package/dist/chunks/alarm-widgets-X4PX5MYJ.js +72 -0
- package/dist/chunks/alarm-widgets-X4PX5MYJ.js.map +7 -0
- package/dist/chunks/chunk-546TK2QG.js +722 -0
- package/dist/chunks/chunk-546TK2QG.js.map +7 -0
- package/dist/chunks/{chunk-WBKHYZU2.js → chunk-62CHYCHI.js} +6 -62
- package/dist/chunks/chunk-62CHYCHI.js.map +7 -0
- package/dist/chunks/chunk-BMFQOTYG.js +41 -0
- package/dist/chunks/chunk-BMFQOTYG.js.map +7 -0
- package/dist/chunks/{chunk-2D7JNKFE.js → chunk-JFH4QMLA.js} +28 -4
- package/dist/chunks/chunk-JFH4QMLA.js.map +7 -0
- package/dist/chunks/chunk-QMGKB6J3.js +84 -0
- package/dist/chunks/chunk-QMGKB6J3.js.map +7 -0
- package/dist/chunks/chunk-XNEBAY4J.js +19 -0
- package/dist/chunks/chunk-XNEBAY4J.js.map +7 -0
- package/dist/chunks/chunk-YYJV54BV.js +58 -0
- package/dist/chunks/chunk-YYJV54BV.js.map +7 -0
- package/dist/chunks/compare-feed-AY3CVKUZ.js +346 -0
- package/dist/chunks/compare-feed-AY3CVKUZ.js.map +7 -0
- package/dist/chunks/{control-widgets-3V2LSSRF.js → control-widgets-UCTJJJ2D.js} +267 -78
- package/dist/chunks/control-widgets-UCTJJJ2D.js.map +7 -0
- package/dist/chunks/event-markers-feed-GEGTIHXT.js +373 -0
- package/dist/chunks/event-markers-feed-GEGTIHXT.js.map +7 -0
- package/dist/chunks/{fleet-feed-5QGDLOV5.js → fleet-feed-2SKDR6ZQ.js} +47 -8
- package/dist/chunks/fleet-feed-2SKDR6ZQ.js.map +7 -0
- package/dist/chunks/presence-widgets-2LIUKN4Y.js +350 -0
- package/dist/chunks/presence-widgets-2LIUKN4Y.js.map +7 -0
- package/dist/command-control-strings.d.ts +5 -0
- package/dist/compare-feed.d.ts +13 -0
- package/dist/compare-model.d.ts +38 -0
- package/dist/compare-strings.d.ts +13 -0
- package/dist/documented-descriptors.d.ts +4826 -0
- package/dist/event-markers-feed.d.ts +11 -0
- package/dist/event-markers-model.d.ts +38 -0
- package/dist/event-markers-strings.d.ts +20 -0
- package/dist/event-markers-types.d.ts +7 -0
- package/dist/fleet-count-model.d.ts +13 -0
- package/dist/fleet-feed.d.ts +1 -0
- package/dist/fleet-model.d.ts +1 -0
- package/dist/fleet-strings.d.ts +11 -0
- package/dist/index.d.ts +6 -3
- package/dist/index.js +946 -398
- package/dist/index.js.map +4 -4
- package/dist/presence-feed.d.ts +24 -0
- package/dist/presence-model.d.ts +13 -0
- package/dist/presence-strings.d.ts +19 -0
- package/dist/sparkline.d.ts +23 -0
- package/dist/use-bound-devices.d.ts +26 -0
- package/dist/widgets/aggregate-lazy.d.ts +81 -46
- package/dist/widgets/aggregate-widgets.d.ts +1 -0
- package/dist/widgets/alarm-grouped.d.ts +17 -0
- package/dist/widgets/alarm-lazy.d.ts +63 -16
- package/dist/widgets/alarm-severity.d.ts +8 -0
- package/dist/widgets/alarm-table.d.ts +2 -0
- package/dist/widgets/alarm-type-tabs.d.ts +10 -0
- package/dist/widgets/alarm-widgets.d.ts +2 -0
- package/dist/widgets/command-stepper.d.ts +22 -0
- package/dist/widgets/control-lazy.d.ts +16 -24
- package/dist/widgets/device-status.d.ts +4 -0
- package/dist/widgets/fleet-count.d.ts +2 -0
- package/dist/widgets/gauge.d.ts +2 -15
- package/dist/widgets/image.d.ts +2 -6
- package/dist/widgets/label.d.ts +2 -6
- package/dist/widgets/latest-card.d.ts +2 -13
- package/dist/widgets/lazy-chunk.d.ts +7 -2
- package/dist/widgets/level-lazy.d.ts +14 -96
- package/dist/widgets/map.d.ts +8 -5
- package/dist/widgets/online-doughnut.d.ts +2 -0
- package/dist/widgets/presence-lazy.d.ts +27 -0
- package/dist/widgets/presence-widgets.d.ts +3 -0
- package/dist/widgets/selection-lazy.d.ts +2 -4
- package/dist/widgets/table-lazy.d.ts +2 -7
- package/dist/widgets/time-series-chart.d.ts +62 -12
- package/package.json +13 -13
- package/dist/chunks/aggregate-feed-BD3CHNFU.js.map +0 -7
- package/dist/chunks/aggregate-widgets-HZQI5HTX.js.map +0 -7
- package/dist/chunks/alarm-widgets-7UY6MIYZ.js +0 -9
- package/dist/chunks/alarm-widgets-7UY6MIYZ.js.map +0 -7
- package/dist/chunks/chunk-2D7JNKFE.js.map +0 -7
- package/dist/chunks/chunk-6OGI4UFJ.js +0 -367
- package/dist/chunks/chunk-6OGI4UFJ.js.map +0 -7
- package/dist/chunks/chunk-WBKHYZU2.js.map +0 -7
- package/dist/chunks/control-widgets-3V2LSSRF.js.map +0 -7
- package/dist/chunks/fleet-feed-5QGDLOV5.js.map +0 -7
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import { type WidgetScale } from '@devicechain/widget-sdk';
|
|
3
|
+
import { type Binding } from '../command-control-core';
|
|
4
|
+
import { type CommandSender } from '../command-control';
|
|
5
|
+
type Bound = Extract<Binding, {
|
|
6
|
+
ok: true;
|
|
7
|
+
}>;
|
|
8
|
+
export declare function StepperBody({ binding, label, draft, lastValue, sender, captionId, hintId, caption, onStage, onCommit, onDiscard, scale: ws, }: {
|
|
9
|
+
binding: Bound;
|
|
10
|
+
label: string;
|
|
11
|
+
draft: number | null;
|
|
12
|
+
lastValue: number | undefined;
|
|
13
|
+
sender: CommandSender;
|
|
14
|
+
captionId: string;
|
|
15
|
+
hintId: string;
|
|
16
|
+
caption: ReactNode;
|
|
17
|
+
onStage: (v: number) => void;
|
|
18
|
+
onCommit: () => void;
|
|
19
|
+
onDiscard: () => void;
|
|
20
|
+
scale: WidgetScale;
|
|
21
|
+
}): import("react").JSX.Element;
|
|
22
|
+
export {};
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
export declare const loadControlWidgets: () => Promise<typeof import("./control-widgets")>;
|
|
2
|
-
export declare const commandSliderWidget: import("@devicechain/widget-sdk").WidgetDefinition<"control", {
|
|
2
|
+
export declare const commandSliderWidget: import("@devicechain/widget-sdk").WidgetDefinition<"control", import("../builtin-descriptors").DocumentedSpecs<{
|
|
3
3
|
readonly title: {
|
|
4
4
|
readonly kind: 'string';
|
|
5
5
|
readonly labelId: 'widgetLabelTitle';
|
|
6
|
-
readonly doc: 'Heading shown in the widget frame. Blank hides the frame heading.';
|
|
7
6
|
};
|
|
8
7
|
readonly commandName: {
|
|
9
8
|
readonly kind: 'string';
|
|
@@ -11,14 +10,12 @@ export declare const commandSliderWidget: import("@devicechain/widget-sdk").Widg
|
|
|
11
10
|
readonly labelId: 'widgetCommandHeading';
|
|
12
11
|
readonly helpId: 'widgetCommandFieldHint';
|
|
13
12
|
readonly control: 'command-vocabulary';
|
|
14
|
-
readonly doc: 'Command key issued to the target device. Without it the control cannot send.';
|
|
15
13
|
};
|
|
16
14
|
readonly commandLabel: {
|
|
17
15
|
readonly kind: 'string';
|
|
18
16
|
readonly labelId: 'widgetCommandHeading';
|
|
19
17
|
readonly helpId: 'widgetCommandFieldHint';
|
|
20
18
|
readonly control: 'command-vocabulary';
|
|
21
|
-
readonly doc: 'Name of the control for assistive technology. Defaults to the command key.';
|
|
22
19
|
};
|
|
23
20
|
readonly parameterSchema: {
|
|
24
21
|
readonly kind: 'string';
|
|
@@ -26,39 +23,43 @@ export declare const commandSliderWidget: import("@devicechain/widget-sdk").Widg
|
|
|
26
23
|
readonly labelId: 'widgetCommandHeading';
|
|
27
24
|
readonly helpId: 'widgetCommandFieldHint';
|
|
28
25
|
readonly control: 'command-vocabulary';
|
|
29
|
-
readonly doc: "The command's parameter descriptors, baked in as JSON at author time. Gives the control its range and its refusals.";
|
|
30
26
|
};
|
|
31
27
|
readonly parameter: {
|
|
32
28
|
readonly kind: 'string';
|
|
33
29
|
readonly labelId: 'widgetLabelParameter';
|
|
34
30
|
readonly helpId: 'widgetHintControlParameter';
|
|
35
|
-
readonly doc: 'Which parameter of the command this control sets. May be left blank when the command has exactly one parameter of the right type.';
|
|
36
31
|
};
|
|
37
32
|
readonly min: {
|
|
38
33
|
readonly kind: "number";
|
|
39
34
|
readonly labelId: "widgetLabelMin";
|
|
40
35
|
readonly helpId: "widgetHintSliderRange";
|
|
41
|
-
readonly doc: "Lowest value, used only when the command's parameter declares no minimum.";
|
|
42
36
|
};
|
|
43
37
|
readonly max: {
|
|
44
38
|
readonly kind: "number";
|
|
45
39
|
readonly labelId: "widgetLabelMax";
|
|
46
40
|
readonly helpId: "widgetHintSliderRange";
|
|
47
|
-
readonly doc: "Highest value, used only when the command's parameter declares no maximum.";
|
|
48
41
|
};
|
|
49
42
|
readonly step: {
|
|
50
43
|
readonly kind: "number";
|
|
51
44
|
readonly min: 0;
|
|
52
45
|
readonly labelId: "widgetLabelStep";
|
|
53
46
|
readonly helpId: "widgetHintSliderStep";
|
|
54
|
-
readonly doc: "Distance between values. Defaults to 1 for a whole-number parameter, else a hundredth of the range.";
|
|
55
47
|
};
|
|
56
|
-
|
|
57
|
-
|
|
48
|
+
readonly mode: {
|
|
49
|
+
readonly kind: "enum";
|
|
50
|
+
readonly values: readonly ["slider", "stepper"];
|
|
51
|
+
readonly labelId: "widgetLabelControlMode";
|
|
52
|
+
readonly valueLabelIds: {
|
|
53
|
+
readonly slider: "widgetControlModeSlider";
|
|
54
|
+
readonly stepper: "widgetControlModeStepper";
|
|
55
|
+
};
|
|
56
|
+
readonly placeholderId: "widgetPlaceholderDefault";
|
|
57
|
+
};
|
|
58
|
+
}>>;
|
|
59
|
+
export declare const commandToggleWidget: import("@devicechain/widget-sdk").WidgetDefinition<"control", import("../builtin-descriptors").DocumentedSpecs<{
|
|
58
60
|
readonly title: {
|
|
59
61
|
readonly kind: 'string';
|
|
60
62
|
readonly labelId: 'widgetLabelTitle';
|
|
61
|
-
readonly doc: 'Heading shown in the widget frame. Blank hides the frame heading.';
|
|
62
63
|
};
|
|
63
64
|
readonly commandName: {
|
|
64
65
|
readonly kind: 'string';
|
|
@@ -66,14 +67,12 @@ export declare const commandToggleWidget: import("@devicechain/widget-sdk").Widg
|
|
|
66
67
|
readonly labelId: 'widgetCommandHeading';
|
|
67
68
|
readonly helpId: 'widgetCommandFieldHint';
|
|
68
69
|
readonly control: 'command-vocabulary';
|
|
69
|
-
readonly doc: 'Command key issued to the target device. Without it the control cannot send.';
|
|
70
70
|
};
|
|
71
71
|
readonly commandLabel: {
|
|
72
72
|
readonly kind: 'string';
|
|
73
73
|
readonly labelId: 'widgetCommandHeading';
|
|
74
74
|
readonly helpId: 'widgetCommandFieldHint';
|
|
75
75
|
readonly control: 'command-vocabulary';
|
|
76
|
-
readonly doc: 'Name of the control for assistive technology. Defaults to the command key.';
|
|
77
76
|
};
|
|
78
77
|
readonly parameterSchema: {
|
|
79
78
|
readonly kind: 'string';
|
|
@@ -81,20 +80,17 @@ export declare const commandToggleWidget: import("@devicechain/widget-sdk").Widg
|
|
|
81
80
|
readonly labelId: 'widgetCommandHeading';
|
|
82
81
|
readonly helpId: 'widgetCommandFieldHint';
|
|
83
82
|
readonly control: 'command-vocabulary';
|
|
84
|
-
readonly doc: "The command's parameter descriptors, baked in as JSON at author time. Gives the control its range and its refusals.";
|
|
85
83
|
};
|
|
86
84
|
readonly parameter: {
|
|
87
85
|
readonly kind: 'string';
|
|
88
86
|
readonly labelId: 'widgetLabelParameter';
|
|
89
87
|
readonly helpId: 'widgetHintControlParameter';
|
|
90
|
-
readonly doc: 'Which parameter of the command this control sets. May be left blank when the command has exactly one parameter of the right type.';
|
|
91
88
|
};
|
|
92
|
-
}
|
|
93
|
-
export declare const commandButtonWidget: import("@devicechain/widget-sdk").WidgetDefinition<"control", {
|
|
89
|
+
}>>;
|
|
90
|
+
export declare const commandButtonWidget: import("@devicechain/widget-sdk").WidgetDefinition<"control", import("../builtin-descriptors").DocumentedSpecs<{
|
|
94
91
|
readonly title: {
|
|
95
92
|
readonly kind: 'string';
|
|
96
93
|
readonly labelId: 'widgetLabelTitle';
|
|
97
|
-
readonly doc: 'Heading shown in the widget frame. Blank hides the frame heading.';
|
|
98
94
|
};
|
|
99
95
|
readonly commandName: {
|
|
100
96
|
readonly kind: "string";
|
|
@@ -102,14 +98,12 @@ export declare const commandButtonWidget: import("@devicechain/widget-sdk").Widg
|
|
|
102
98
|
readonly labelId: "widgetCommandHeading";
|
|
103
99
|
readonly helpId: "widgetCommandFieldHint";
|
|
104
100
|
readonly control: "command-vocabulary";
|
|
105
|
-
readonly doc: "Command key issued to the target device. Without it the widget cannot send.";
|
|
106
101
|
};
|
|
107
102
|
readonly commandLabel: {
|
|
108
103
|
readonly kind: "string";
|
|
109
104
|
readonly labelId: "widgetCommandHeading";
|
|
110
105
|
readonly helpId: "widgetCommandFieldHint";
|
|
111
106
|
readonly control: "command-vocabulary";
|
|
112
|
-
readonly doc: "Text on the send button. Defaults to the command key.";
|
|
113
107
|
};
|
|
114
108
|
readonly parameterSchema: {
|
|
115
109
|
readonly kind: "string";
|
|
@@ -117,7 +111,6 @@ export declare const commandButtonWidget: import("@devicechain/widget-sdk").Widg
|
|
|
117
111
|
readonly labelId: "widgetCommandHeading";
|
|
118
112
|
readonly helpId: "widgetCommandFieldHint";
|
|
119
113
|
readonly control: "command-vocabulary";
|
|
120
|
-
readonly doc: "The command's parameter descriptors, baked in as JSON at author time. Drives the typed form.";
|
|
121
114
|
};
|
|
122
115
|
readonly maxRows: {
|
|
123
116
|
readonly kind: "number";
|
|
@@ -125,6 +118,5 @@ export declare const commandButtonWidget: import("@devicechain/widget-sdk").Widg
|
|
|
125
118
|
readonly min: 1;
|
|
126
119
|
readonly labelId: "widgetLabelMaxRows";
|
|
127
120
|
readonly helpId: "widgetMaxRowsCommandHint";
|
|
128
|
-
readonly doc: "Recent commands shown in the history. Default 20.";
|
|
129
121
|
};
|
|
130
|
-
}
|
|
122
|
+
}>>;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { type WidgetProps } from '@devicechain/widget-sdk';
|
|
2
|
+
export declare const OFFLINE_LEVEL: 'major';
|
|
3
|
+
export declare function formatLastSeen(at: number, locale?: string | undefined): string;
|
|
4
|
+
export declare function DeviceStatus({ widget, data }: WidgetProps): import("react").JSX.Element;
|
package/dist/widgets/gauge.d.ts
CHANGED
|
@@ -4,32 +4,27 @@ export declare function Gauge({ widget, data }: WidgetProps): import("react").JS
|
|
|
4
4
|
export declare namespace Gauge {
|
|
5
5
|
export { loadChartEngine as preload };
|
|
6
6
|
}
|
|
7
|
-
export declare const gaugeWidget: import("@devicechain/widget-sdk").WidgetDefinition<"measurement", {
|
|
7
|
+
export declare const gaugeWidget: import("@devicechain/widget-sdk").WidgetDefinition<"measurement", import("../builtin-descriptors").DocumentedSpecs<{
|
|
8
8
|
readonly title: {
|
|
9
9
|
readonly kind: 'string';
|
|
10
10
|
readonly labelId: 'widgetLabelTitle';
|
|
11
|
-
readonly doc: 'Heading shown in the widget frame. Defaults to the displayed measurement name.';
|
|
12
11
|
};
|
|
13
12
|
readonly measurement: {
|
|
14
13
|
readonly kind: "string";
|
|
15
14
|
readonly labelId: "widgetLabelMeasurement";
|
|
16
15
|
readonly helpId: "widgetHintMeasurement";
|
|
17
|
-
readonly doc: "Which measurement to display. Defaults to the first the datasource selects.";
|
|
18
16
|
};
|
|
19
17
|
readonly min: {
|
|
20
18
|
readonly kind: "number";
|
|
21
19
|
readonly labelId: "widgetLabelMin";
|
|
22
|
-
readonly doc: "Low end of the gauge scale. Default 0.";
|
|
23
20
|
};
|
|
24
21
|
readonly max: {
|
|
25
22
|
readonly kind: "number";
|
|
26
23
|
readonly labelId: "widgetLabelMax";
|
|
27
|
-
readonly doc: "High end of the gauge scale. Default 100.";
|
|
28
24
|
};
|
|
29
25
|
readonly unit: {
|
|
30
26
|
readonly kind: 'string';
|
|
31
27
|
readonly labelId: 'widgetLabelUnit';
|
|
32
|
-
readonly doc: 'Unit suffix shown beside the value.';
|
|
33
28
|
};
|
|
34
29
|
readonly precision: {
|
|
35
30
|
readonly kind: 'number';
|
|
@@ -38,20 +33,17 @@ export declare const gaugeWidget: import("@devicechain/widget-sdk").WidgetDefini
|
|
|
38
33
|
readonly max: 100;
|
|
39
34
|
readonly labelId: 'widgetLabelPrecision';
|
|
40
35
|
readonly helpId: 'widgetHintPrecision';
|
|
41
|
-
readonly doc: 'Decimal places to round displayed values to. Unset rounds to at most 3 decimals (4 significant digits under 1).';
|
|
42
36
|
};
|
|
43
37
|
readonly thresholds: {
|
|
44
38
|
readonly kind: 'list';
|
|
45
39
|
readonly maxItems: 12;
|
|
46
40
|
readonly labelId: 'widgetLabelThresholds';
|
|
47
41
|
readonly helpId: 'widgetHintThresholds';
|
|
48
|
-
readonly doc: 'Severity bands over the value. Each entry starts a band at its value that runs to the next entry; below the first, and in a normal band, the widget keeps its own colour.';
|
|
49
42
|
readonly item: {
|
|
50
43
|
readonly value: {
|
|
51
44
|
readonly kind: 'number';
|
|
52
45
|
readonly required: true;
|
|
53
46
|
readonly labelId: 'widgetLabelThresholdValue';
|
|
54
|
-
readonly doc: 'The value at which this band starts.';
|
|
55
47
|
};
|
|
56
48
|
readonly level: {
|
|
57
49
|
readonly kind: 'enum';
|
|
@@ -66,12 +58,10 @@ export declare const gaugeWidget: import("@devicechain/widget-sdk").WidgetDefini
|
|
|
66
58
|
readonly critical: 'widgetSeverityCritical';
|
|
67
59
|
};
|
|
68
60
|
readonly placeholderId: 'widgetPlaceholderThresholdLevel';
|
|
69
|
-
readonly doc: 'The severity of this band. The theme decides the colour; normal has none.';
|
|
70
61
|
};
|
|
71
62
|
readonly label: {
|
|
72
63
|
readonly kind: 'string';
|
|
73
64
|
readonly labelId: 'widgetLabelThresholdLabel';
|
|
74
|
-
readonly doc: 'Text shown on the chart line for this threshold. Defaults to its value.';
|
|
75
65
|
};
|
|
76
66
|
};
|
|
77
67
|
};
|
|
@@ -79,7 +69,6 @@ export declare const gaugeWidget: import("@devicechain/widget-sdk").WidgetDefini
|
|
|
79
69
|
readonly kind: 'boolean';
|
|
80
70
|
readonly labelId: 'widgetFlashOnChange';
|
|
81
71
|
readonly helpId: 'widgetFlashOnChangeHint';
|
|
82
|
-
readonly doc: 'Briefly tint a value green on a rise and red on a fall when it changes.';
|
|
83
72
|
};
|
|
84
73
|
readonly staleAfterSeconds: {
|
|
85
74
|
readonly kind: 'number';
|
|
@@ -87,7 +76,6 @@ export declare const gaugeWidget: import("@devicechain/widget-sdk").WidgetDefini
|
|
|
87
76
|
readonly min: 1;
|
|
88
77
|
readonly labelId: 'widgetLabelStaleAfter';
|
|
89
78
|
readonly helpId: 'widgetHintStaleAfter';
|
|
90
|
-
readonly doc: 'Seconds after which the newest sample is called stale: the value is greyed out and badged. Unset shows the sample age only and never marks the widget stale.';
|
|
91
79
|
};
|
|
92
80
|
readonly window: {
|
|
93
81
|
readonly kind: 'number';
|
|
@@ -95,6 +83,5 @@ export declare const gaugeWidget: import("@devicechain/widget-sdk").WidgetDefini
|
|
|
95
83
|
readonly min: 1;
|
|
96
84
|
readonly labelId: 'widgetLabelWindow';
|
|
97
85
|
readonly helpId: 'widgetHintWindow';
|
|
98
|
-
readonly doc: 'Samples retained across ALL of the widget\'s measurements before the oldest are dropped. Bounds memory; only the chart draws them. Default 300.';
|
|
99
86
|
};
|
|
100
|
-
}
|
|
87
|
+
}>>;
|
package/dist/widgets/image.d.ts
CHANGED
|
@@ -1,21 +1,18 @@
|
|
|
1
1
|
import { type WidgetProps } from '@devicechain/widget-sdk';
|
|
2
2
|
export declare function Image({ widget }: WidgetProps<null>): import("react").JSX.Element;
|
|
3
|
-
export declare const imageWidget: import("@devicechain/widget-sdk").WidgetDefinition<"none", {
|
|
3
|
+
export declare const imageWidget: import("@devicechain/widget-sdk").WidgetDefinition<"none", import("../builtin-descriptors").DocumentedSpecs<{
|
|
4
4
|
readonly title: {
|
|
5
5
|
readonly kind: 'string';
|
|
6
6
|
readonly labelId: 'widgetLabelTitle';
|
|
7
|
-
readonly doc: 'Heading shown in the widget frame. Blank hides the frame heading.';
|
|
8
7
|
};
|
|
9
8
|
readonly url: {
|
|
10
9
|
readonly kind: "string";
|
|
11
10
|
readonly required: true;
|
|
12
11
|
readonly labelId: "widgetLabelImageUrl";
|
|
13
|
-
readonly doc: "Source URL of the image.";
|
|
14
12
|
};
|
|
15
13
|
readonly alt: {
|
|
16
14
|
readonly kind: "string";
|
|
17
15
|
readonly labelId: "widgetLabelAltText";
|
|
18
|
-
readonly doc: "Alternative text describing the image for assistive technology.";
|
|
19
16
|
};
|
|
20
17
|
readonly fit: {
|
|
21
18
|
readonly kind: "enum";
|
|
@@ -27,6 +24,5 @@ export declare const imageWidget: import("@devicechain/widget-sdk").WidgetDefini
|
|
|
27
24
|
readonly fill: "widgetFitFill";
|
|
28
25
|
};
|
|
29
26
|
readonly placeholderId: "widgetPlaceholderDefault";
|
|
30
|
-
readonly doc: "How the image fills its box. Default contain.";
|
|
31
27
|
};
|
|
32
|
-
}
|
|
28
|
+
}>>;
|
package/dist/widgets/label.d.ts
CHANGED
|
@@ -1,16 +1,14 @@
|
|
|
1
1
|
import { type WidgetProps } from '@devicechain/widget-sdk';
|
|
2
2
|
export declare function Label({ widget }: WidgetProps<null>): import("react").JSX.Element;
|
|
3
|
-
export declare const labelWidget: import("@devicechain/widget-sdk").WidgetDefinition<"none", {
|
|
3
|
+
export declare const labelWidget: import("@devicechain/widget-sdk").WidgetDefinition<"none", import("../builtin-descriptors").DocumentedSpecs<{
|
|
4
4
|
readonly title: {
|
|
5
5
|
readonly kind: 'string';
|
|
6
6
|
readonly labelId: 'widgetLabelTitle';
|
|
7
|
-
readonly doc: 'Heading shown in the widget frame. Blank hides the frame heading.';
|
|
8
7
|
};
|
|
9
8
|
readonly text: {
|
|
10
9
|
readonly kind: "string";
|
|
11
10
|
readonly required: true;
|
|
12
11
|
readonly labelId: "widgetLabelText";
|
|
13
|
-
readonly doc: "The text to show. Rendered as plain text — markup is never interpreted.";
|
|
14
12
|
};
|
|
15
13
|
readonly align: {
|
|
16
14
|
readonly kind: "enum";
|
|
@@ -22,13 +20,11 @@ export declare const labelWidget: import("@devicechain/widget-sdk").WidgetDefini
|
|
|
22
20
|
readonly right: "widgetAlignRight";
|
|
23
21
|
};
|
|
24
22
|
readonly placeholderId: "widgetPlaceholderDefault";
|
|
25
|
-
readonly doc: "Horizontal alignment of the text. Default center.";
|
|
26
23
|
};
|
|
27
24
|
readonly fontSize: {
|
|
28
25
|
readonly kind: "number";
|
|
29
26
|
readonly min: 1;
|
|
30
27
|
readonly labelId: "widgetLabelFontSize";
|
|
31
28
|
readonly helpId: "widgetHintFontSize";
|
|
32
|
-
readonly doc: "Text size in pixels at the comfortable density; it scales with the board density. Default 16.";
|
|
33
29
|
};
|
|
34
|
-
}
|
|
30
|
+
}>>;
|
|
@@ -1,21 +1,18 @@
|
|
|
1
1
|
import { type WidgetProps } from '@devicechain/widget-sdk';
|
|
2
2
|
export declare function LatestCard({ widget, data }: WidgetProps): import("react").JSX.Element;
|
|
3
|
-
export declare const latestCardWidget: import("@devicechain/widget-sdk").WidgetDefinition<"measurement", {
|
|
3
|
+
export declare const latestCardWidget: import("@devicechain/widget-sdk").WidgetDefinition<"measurement", import("../builtin-descriptors").DocumentedSpecs<{
|
|
4
4
|
readonly title: {
|
|
5
5
|
readonly kind: 'string';
|
|
6
6
|
readonly labelId: 'widgetLabelTitle';
|
|
7
|
-
readonly doc: 'Heading shown in the widget frame. Defaults to the displayed measurement name.';
|
|
8
7
|
};
|
|
9
8
|
readonly measurement: {
|
|
10
9
|
readonly kind: "string";
|
|
11
10
|
readonly labelId: "widgetLabelMeasurement";
|
|
12
11
|
readonly helpId: "widgetHintMeasurement";
|
|
13
|
-
readonly doc: "Which measurement to display. Defaults to the first the datasource selects.";
|
|
14
12
|
};
|
|
15
13
|
readonly unit: {
|
|
16
14
|
readonly kind: 'string';
|
|
17
15
|
readonly labelId: 'widgetLabelUnit';
|
|
18
|
-
readonly doc: 'Unit suffix shown beside the value.';
|
|
19
16
|
};
|
|
20
17
|
readonly precision: {
|
|
21
18
|
readonly kind: 'number';
|
|
@@ -24,20 +21,17 @@ export declare const latestCardWidget: import("@devicechain/widget-sdk").WidgetD
|
|
|
24
21
|
readonly max: 100;
|
|
25
22
|
readonly labelId: 'widgetLabelPrecision';
|
|
26
23
|
readonly helpId: 'widgetHintPrecision';
|
|
27
|
-
readonly doc: 'Decimal places to round displayed values to. Unset rounds to at most 3 decimals (4 significant digits under 1).';
|
|
28
24
|
};
|
|
29
25
|
readonly thresholds: {
|
|
30
26
|
readonly kind: 'list';
|
|
31
27
|
readonly maxItems: 12;
|
|
32
28
|
readonly labelId: 'widgetLabelThresholds';
|
|
33
29
|
readonly helpId: 'widgetHintThresholds';
|
|
34
|
-
readonly doc: 'Severity bands over the value. Each entry starts a band at its value that runs to the next entry; below the first, and in a normal band, the widget keeps its own colour.';
|
|
35
30
|
readonly item: {
|
|
36
31
|
readonly value: {
|
|
37
32
|
readonly kind: 'number';
|
|
38
33
|
readonly required: true;
|
|
39
34
|
readonly labelId: 'widgetLabelThresholdValue';
|
|
40
|
-
readonly doc: 'The value at which this band starts.';
|
|
41
35
|
};
|
|
42
36
|
readonly level: {
|
|
43
37
|
readonly kind: 'enum';
|
|
@@ -52,12 +46,10 @@ export declare const latestCardWidget: import("@devicechain/widget-sdk").WidgetD
|
|
|
52
46
|
readonly critical: 'widgetSeverityCritical';
|
|
53
47
|
};
|
|
54
48
|
readonly placeholderId: 'widgetPlaceholderThresholdLevel';
|
|
55
|
-
readonly doc: 'The severity of this band. The theme decides the colour; normal has none.';
|
|
56
49
|
};
|
|
57
50
|
readonly label: {
|
|
58
51
|
readonly kind: 'string';
|
|
59
52
|
readonly labelId: 'widgetLabelThresholdLabel';
|
|
60
|
-
readonly doc: 'Text shown on the chart line for this threshold. Defaults to its value.';
|
|
61
53
|
};
|
|
62
54
|
};
|
|
63
55
|
};
|
|
@@ -65,7 +57,6 @@ export declare const latestCardWidget: import("@devicechain/widget-sdk").WidgetD
|
|
|
65
57
|
readonly kind: 'boolean';
|
|
66
58
|
readonly labelId: 'widgetFlashOnChange';
|
|
67
59
|
readonly helpId: 'widgetFlashOnChangeHint';
|
|
68
|
-
readonly doc: 'Briefly tint a value green on a rise and red on a fall when it changes.';
|
|
69
60
|
};
|
|
70
61
|
readonly staleAfterSeconds: {
|
|
71
62
|
readonly kind: 'number';
|
|
@@ -73,7 +64,6 @@ export declare const latestCardWidget: import("@devicechain/widget-sdk").WidgetD
|
|
|
73
64
|
readonly min: 1;
|
|
74
65
|
readonly labelId: 'widgetLabelStaleAfter';
|
|
75
66
|
readonly helpId: 'widgetHintStaleAfter';
|
|
76
|
-
readonly doc: 'Seconds after which the newest sample is called stale: the value is greyed out and badged. Unset shows the sample age only and never marks the widget stale.';
|
|
77
67
|
};
|
|
78
68
|
readonly window: {
|
|
79
69
|
readonly kind: 'number';
|
|
@@ -81,6 +71,5 @@ export declare const latestCardWidget: import("@devicechain/widget-sdk").WidgetD
|
|
|
81
71
|
readonly min: 1;
|
|
82
72
|
readonly labelId: 'widgetLabelWindow';
|
|
83
73
|
readonly helpId: 'widgetHintWindow';
|
|
84
|
-
readonly doc: 'Samples retained across ALL of the widget\'s measurements before the oldest are dropped. Bounds memory; only the chart draws them. Default 300.';
|
|
85
74
|
};
|
|
86
|
-
}
|
|
75
|
+
}>>;
|
|
@@ -1,7 +1,12 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { type ComponentType } from 'react';
|
|
2
|
+
import { type MeasurementStreamState, type WidgetProps } from '@devicechain/widget-sdk';
|
|
3
|
+
import type { WidgetInstance } from '@devicechain/dashboards';
|
|
4
|
+
export declare function ChunkLoadingFrame({ widget }: {
|
|
5
|
+
widget: WidgetInstance;
|
|
6
|
+
}): import("react").JSX.Element;
|
|
2
7
|
export declare function lazyChunk<M extends Record<string, unknown>, D = MeasurementStreamState>(importer: () => Promise<M>): {
|
|
3
8
|
load: () => Promise<M>;
|
|
4
|
-
component: <P = D, Props extends object = WidgetProps<P>>(name: keyof M & string, alsoPreload?: () => Promise<unknown>) => {
|
|
9
|
+
component: <P = D, Props extends object = WidgetProps<P>>(name: keyof M & string, alsoPreload?: () => Promise<unknown>, Fallback?: ComponentType<Props>) => {
|
|
5
10
|
(props: Props): import("react").JSX.Element | null;
|
|
6
11
|
displayName: string;
|
|
7
12
|
preload: () => Promise<M>;
|