@aiquants/console-ui 0.4.3 → 0.5.0
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 +95 -35
- package/dist/chunk-34QJXV5R.js +1 -0
- package/dist/chunk-6WVTEB4S.cjs +1 -0
- package/dist/{chunk-IR2WTSOW.cjs → chunk-7M4I26BS.cjs} +1 -1
- package/dist/{chunk-BMGBEN26.js → chunk-FXEGLGL7.js} +1 -1
- package/dist/core.cjs +1 -1
- package/dist/core.d.cts +176 -113
- package/dist/core.d.ts +176 -113
- package/dist/core.js +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +252 -40
- package/dist/index.d.ts +252 -40
- package/dist/index.js +1 -1
- package/dist/styles/console-ui.css +480 -25
- package/dist/testing.cjs +1 -1
- package/dist/testing.d.cts +6 -1
- package/dist/testing.d.ts +6 -1
- package/dist/testing.js +1 -1
- package/package.json +4 -2
- package/dist/chunk-A4D4K2WF.cjs +0 -1
- package/dist/chunk-BUX2DNVR.js +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { ConsoleUiLocale, ConsoleUiLabels, ColumnWidth,
|
|
2
|
-
export { AccentRole, CONSOLE_UI_LABEL_CATALOGS, CONTRAST_MINIMUM, CONTRAST_PAIRS, ColorScheme, ColorToken, ColumnWidthSource, CommandOutcome, ConsoleUiTokens, ContrastRole, HTTP_FORBIDDEN, LATTICE_PX, MasterDetailOptions, MasterDetailPlan, MotionToken, PageFailure, PagedValue, ROW_WITH_CONTROL_PX, RadiusToken, ReloadCause, SchemeColor, SizeToken, Srgb, StrokeToken, SurfaceRole, TARGET_PX, TOKENS, TileGridPlan, TileGridStep, TokenName, WeightToken, ZonedTimeError, ZonedTimeErrorReason, beginPage, beginPagedReload, beginReload, ceil8, ceilToLattice, contrastRatio, cssVar, flatMapOutcome, formatCount, formatInstant, hexToSrgb, keepLastGood, mapOutcome, mapPagedList, masterDetailPlan, monoTextWidthEm, reasonAside, resolveConsoleUiLabels, settleFirstPage, settlePage, tableMinInlinePx, textWidthEm, tileGridPlan, toOffsetIso, toWallTime } from "./core.js";
|
|
1
|
+
import { ConsoleUiLocale, ConsoleUiLabels, ColumnWidth, FgRole, TypeToken, SpaceToken, ResourceFailure, TextFace, ResourceOutcome, KeysetPage, NextPage, PagedState, PagedContent, ResourceState } from "./core.js";
|
|
2
|
+
export { AccentRole, COMPACT_ROW_PX, CONSOLE_UI_LABEL_CATALOGS, CONTRAST_MINIMUM, CONTRAST_PAIRS, CellContent, ColorScheme, ColorToken, ColumnHeaderText, ColumnWidthSource, CommandOutcome, ConsoleUiTokens, ContrastRole, FIGURE_RING_REACH_PX, FLEXIBLE_COLUMN_MIN_PX, FigureBoxLines, FigureBoxPlan, FigureDiscLabelPlan, HTTP_FORBIDDEN, LATTICE_PX, MasterDetailOptions, MasterDetailPlan, MotionToken, PageFailure, PagedValue, ROW_WITH_CONTROL_PX, RadiusToken, ReloadCause, SchemeColor, SizeToken, Srgb, StrokeToken, SurfaceRole, TARGET_PX, TOKENS, TileGridPlan, TileGridStep, TokenName, WeightToken, ZonedTimeError, ZonedTimeErrorReason, beginPage, beginPagedReload, beginReload, ceil8, ceilToLattice, cellContentInlinePx, comparisonAttributePx, contrastRatio, countSampleText, cssVar, figureBoxPlan, figureDiscLabelPlan, fixedColumnPx, flatMapOutcome, formatCount, formatInstant, hexToSrgb, instantSampleText, isReadableText, keepLastGood, mapOutcome, mapPagedList, masterDetailPlan, monoTextWidthEm, readDecimalText, readIntegerText, reasonAside, resolveConsoleUiLabels, settleFirstPage, settlePage, spacedTextWidthEm, tableFrameMinInlinePx, tableMinInlinePx, textWidthEm, tileGridPlan, tileMinInlinePx, toOffsetIso, toWallTime } from "./core.js";
|
|
3
3
|
import * as react from "react";
|
|
4
|
-
import { ReactNode, MouseEvent, Ref, RefObject, RefCallback, KeyboardEvent } from "react";
|
|
4
|
+
import { ReactNode, MouseEvent, Ref, DOMAttributes, RefObject, RefCallback, KeyboardEvent } from "react";
|
|
5
5
|
type BreadcrumbItem = {
|
|
6
6
|
readonly id: string;
|
|
7
7
|
readonly label: string;
|
|
@@ -15,6 +15,13 @@ type BreadcrumbProps = {
|
|
|
15
15
|
};
|
|
16
16
|
declare const Breadcrumb: ({ items, current, onNavigate, testId }: BreadcrumbProps) => react.JSX.Element;
|
|
17
17
|
type DataAttributes = Readonly<Record<`data-${string}`, string | number | boolean>>;
|
|
18
|
+
type Unavailable = {
|
|
19
|
+
readonly reason: string;
|
|
20
|
+
readonly reasonId?: undefined;
|
|
21
|
+
} | {
|
|
22
|
+
readonly reasonId: string;
|
|
23
|
+
readonly reason?: undefined;
|
|
24
|
+
};
|
|
18
25
|
type ButtonVariant = "primary" | "secondary" | "danger" | "link";
|
|
19
26
|
type ButtonProps = {
|
|
20
27
|
readonly variant: ButtonVariant;
|
|
@@ -22,9 +29,8 @@ type ButtonProps = {
|
|
|
22
29
|
readonly testId: string;
|
|
23
30
|
readonly type?: "button" | "submit";
|
|
24
31
|
readonly onClick?: (event: MouseEvent<HTMLButtonElement>) => void;
|
|
25
|
-
readonly unavailable?:
|
|
26
|
-
|
|
27
|
-
};
|
|
32
|
+
readonly unavailable?: Unavailable;
|
|
33
|
+
readonly describedBy?: string;
|
|
28
34
|
readonly expanded?: boolean;
|
|
29
35
|
readonly controls?: string;
|
|
30
36
|
readonly ref?: Ref<HTMLButtonElement>;
|
|
@@ -34,9 +40,9 @@ type ButtonProps = {
|
|
|
34
40
|
readonly busyLabel?: undefined;
|
|
35
41
|
} | {
|
|
36
42
|
readonly busy: boolean;
|
|
37
|
-
readonly busyLabel:
|
|
43
|
+
readonly busyLabel: ReactNode;
|
|
38
44
|
});
|
|
39
|
-
declare const Button: ({ variant, children, testId, type, onClick, unavailable, expanded, controls, ref, dataAttributes, busy, busyLabel }: ButtonProps) => react.JSX.Element;
|
|
45
|
+
declare const Button: ({ variant, children, testId, type, onClick, unavailable, describedBy, expanded, controls, ref, dataAttributes, busy, busyLabel }: ButtonProps) => react.JSX.Element;
|
|
40
46
|
type LinkProps = {
|
|
41
47
|
readonly onNavigate: () => void;
|
|
42
48
|
readonly children: ReactNode;
|
|
@@ -44,30 +50,45 @@ type LinkProps = {
|
|
|
44
50
|
readonly ref?: Ref<HTMLButtonElement>;
|
|
45
51
|
};
|
|
46
52
|
declare const Link: ({ onNavigate, children, testId, ref }: LinkProps) => react.JSX.Element;
|
|
53
|
+
type FragmentLinkProps = {
|
|
54
|
+
readonly targetId: string;
|
|
55
|
+
readonly children: ReactNode;
|
|
56
|
+
readonly testId: string;
|
|
57
|
+
readonly onFollow?: () => void;
|
|
58
|
+
readonly dataAttributes?: DataAttributes;
|
|
59
|
+
};
|
|
60
|
+
declare const FragmentLink: ({ targetId, children, testId, onFollow, dataAttributes }: FragmentLinkProps) => react.JSX.Element;
|
|
47
61
|
type CardProps = {
|
|
48
62
|
readonly id?: string;
|
|
49
63
|
readonly title: string;
|
|
50
64
|
readonly description?: ReactNode;
|
|
51
65
|
readonly actions?: ReactNode;
|
|
66
|
+
readonly onEscape?: () => void;
|
|
52
67
|
readonly testId: string;
|
|
53
68
|
readonly headingRef?: Ref<HTMLHeadingElement>;
|
|
54
69
|
readonly ref?: Ref<HTMLElement>;
|
|
55
70
|
readonly dataAttributes?: DataAttributes;
|
|
56
71
|
readonly children: ReactNode;
|
|
57
72
|
};
|
|
58
|
-
declare const Card: ({ id, title, description, actions, testId, headingRef, ref, dataAttributes, children }: CardProps) => react.JSX.Element;
|
|
73
|
+
declare const Card: ({ id, title, description, actions, onEscape, testId, headingRef, ref, dataAttributes, children }: CardProps) => react.JSX.Element;
|
|
59
74
|
type CardSectionProps = {
|
|
60
75
|
readonly id?: string;
|
|
61
76
|
readonly title: string;
|
|
62
77
|
readonly subtitle?: ReactNode;
|
|
63
|
-
readonly
|
|
78
|
+
readonly level?: 3 | 4;
|
|
64
79
|
readonly testId: string;
|
|
65
80
|
readonly headingRef?: Ref<HTMLHeadingElement>;
|
|
66
81
|
readonly ref?: Ref<HTMLElement>;
|
|
67
82
|
readonly dataAttributes?: DataAttributes;
|
|
68
83
|
readonly children: ReactNode;
|
|
69
|
-
}
|
|
70
|
-
|
|
84
|
+
} & ({
|
|
85
|
+
readonly region?: false;
|
|
86
|
+
readonly onEscape?: never;
|
|
87
|
+
} | {
|
|
88
|
+
readonly region: true;
|
|
89
|
+
readonly onEscape?: () => void;
|
|
90
|
+
});
|
|
91
|
+
declare const CardSection: ({ id, title, subtitle, level, region, onEscape, testId, headingRef, ref, dataAttributes, children }: CardSectionProps) => react.JSX.Element;
|
|
71
92
|
type CodeBlockProps = {
|
|
72
93
|
readonly label: string;
|
|
73
94
|
readonly code: string;
|
|
@@ -114,9 +135,21 @@ declare const useAnnounce: () => ((text: string) => void);
|
|
|
114
135
|
type ColumnDef<T> = {
|
|
115
136
|
readonly key: string;
|
|
116
137
|
readonly header: string;
|
|
138
|
+
readonly note?: ReactNode;
|
|
117
139
|
readonly width: ColumnWidth;
|
|
118
140
|
readonly align: "start" | "end";
|
|
119
141
|
readonly cell: (row: T) => ReactNode;
|
|
142
|
+
} & ({
|
|
143
|
+
readonly rowHeader?: never;
|
|
144
|
+
readonly rowHeaderNote?: never;
|
|
145
|
+
} | {
|
|
146
|
+
readonly rowHeader: true;
|
|
147
|
+
readonly rowHeaderNote?: (row: T) => ReactNode;
|
|
148
|
+
});
|
|
149
|
+
type DataTableRowDetail<T> = {
|
|
150
|
+
readonly open: (row: T) => boolean;
|
|
151
|
+
readonly id: (row: T) => string;
|
|
152
|
+
readonly render: (row: T) => ReactNode;
|
|
120
153
|
};
|
|
121
154
|
type DataTableProps<T> = {
|
|
122
155
|
readonly caption: string;
|
|
@@ -126,12 +159,17 @@ type DataTableProps<T> = {
|
|
|
126
159
|
readonly rowKey: (row: T) => string;
|
|
127
160
|
readonly rowTestId: string;
|
|
128
161
|
readonly rowData?: (row: T) => DataAttributes;
|
|
129
|
-
readonly rowSize: "row" | "row-control";
|
|
130
162
|
readonly empty: string;
|
|
131
163
|
readonly testId: string;
|
|
132
164
|
readonly ref?: Ref<HTMLDivElement>;
|
|
133
|
-
}
|
|
134
|
-
|
|
165
|
+
} & ({
|
|
166
|
+
readonly rowSize: "row" | "row-control";
|
|
167
|
+
readonly rowDetail?: DataTableRowDetail<T>;
|
|
168
|
+
} | {
|
|
169
|
+
readonly rowSize: "row-compact";
|
|
170
|
+
readonly rowDetail?: never;
|
|
171
|
+
});
|
|
172
|
+
declare const DataTable: <T>({ caption, captionHidden, columns, rows, rowKey, rowTestId, rowData, rowSize, rowDetail, empty, testId, ref }: DataTableProps<T>) => react.JSX.Element;
|
|
135
173
|
type DescriptionItem = {
|
|
136
174
|
readonly key: string;
|
|
137
175
|
readonly term: string;
|
|
@@ -144,14 +182,15 @@ type DescriptionListProps = {
|
|
|
144
182
|
declare const DescriptionList: ({ items, testId }: DescriptionListProps) => react.JSX.Element;
|
|
145
183
|
type DialogProps = {
|
|
146
184
|
readonly title: string;
|
|
185
|
+
readonly description?: ReactNode;
|
|
147
186
|
readonly open: boolean;
|
|
148
187
|
readonly onClose: () => void;
|
|
149
188
|
readonly testId: string;
|
|
150
189
|
readonly children: ReactNode;
|
|
151
190
|
};
|
|
152
|
-
declare const Dialog: ({ title, open, onClose, testId, children }: DialogProps) => react.JSX.Element;
|
|
191
|
+
declare const Dialog: ({ title, description, open, onClose, testId, children }: DialogProps) => react.JSX.Element;
|
|
153
192
|
type DisclosureProps = {
|
|
154
|
-
readonly summary:
|
|
193
|
+
readonly summary: ReactNode;
|
|
155
194
|
readonly open: boolean;
|
|
156
195
|
readonly onOpenChange: (open: boolean) => void;
|
|
157
196
|
readonly testId: string;
|
|
@@ -163,7 +202,10 @@ type FieldControl = {
|
|
|
163
202
|
readonly "aria-describedby": string | undefined;
|
|
164
203
|
readonly "aria-invalid": true | undefined;
|
|
165
204
|
};
|
|
166
|
-
type
|
|
205
|
+
type FieldErrorId = {
|
|
206
|
+
readonly errorId?: string;
|
|
207
|
+
};
|
|
208
|
+
type FieldTexts = FieldErrorId & {
|
|
167
209
|
readonly label: string;
|
|
168
210
|
readonly description?: string;
|
|
169
211
|
readonly error?: string;
|
|
@@ -172,11 +214,14 @@ type FieldProps = FieldTexts & {
|
|
|
172
214
|
readonly testId: string;
|
|
173
215
|
readonly children: (control: FieldControl) => ReactNode;
|
|
174
216
|
};
|
|
175
|
-
declare const Field: ({ label, description, error, testId, children }: FieldProps) => react.JSX.Element;
|
|
217
|
+
declare const Field: ({ label, description, error, errorId: namedErrorId, testId, children }: FieldProps) => react.JSX.Element;
|
|
176
218
|
type TextInputProps = FieldTexts & {
|
|
177
219
|
readonly value: string;
|
|
178
220
|
readonly onValueChange: (value: string) => void;
|
|
179
221
|
readonly type: "text" | "search" | "datetime-local";
|
|
222
|
+
readonly inputMode?: "numeric" | "decimal";
|
|
223
|
+
readonly prefix?: string;
|
|
224
|
+
readonly labelHidden?: boolean;
|
|
180
225
|
readonly list?: string;
|
|
181
226
|
readonly required?: boolean;
|
|
182
227
|
readonly testId: string;
|
|
@@ -187,6 +232,7 @@ type PasswordInputProps = FieldTexts & {
|
|
|
187
232
|
readonly onValueChange: (value: string) => void;
|
|
188
233
|
readonly autoComplete: "new-password" | "current-password";
|
|
189
234
|
readonly required?: boolean;
|
|
235
|
+
readonly labelHidden?: boolean;
|
|
190
236
|
readonly testId: string;
|
|
191
237
|
readonly ref?: Ref<HTMLInputElement>;
|
|
192
238
|
};
|
|
@@ -199,7 +245,7 @@ type TextAreaProps = FieldTexts & {
|
|
|
199
245
|
readonly testId: string;
|
|
200
246
|
readonly ref?: Ref<HTMLTextAreaElement>;
|
|
201
247
|
};
|
|
202
|
-
declare const TextArea: ({ label, description, error, value, onValueChange, required, testId, ref }: TextAreaProps) => react.JSX.Element;
|
|
248
|
+
declare const TextArea: ({ label, description, error, errorId: namedErrorId, value, onValueChange, required, testId, ref }: TextAreaProps) => react.JSX.Element;
|
|
203
249
|
type FieldOption = {
|
|
204
250
|
readonly value: string;
|
|
205
251
|
readonly label: string;
|
|
@@ -208,11 +254,13 @@ type SelectProps = FieldTexts & {
|
|
|
208
254
|
readonly value: string;
|
|
209
255
|
readonly options: readonly FieldOption[];
|
|
210
256
|
readonly onValueChange: (value: string) => void;
|
|
257
|
+
readonly labelHidden?: boolean;
|
|
258
|
+
readonly unavailable?: Unavailable;
|
|
211
259
|
readonly testId: string;
|
|
212
260
|
readonly ref?: Ref<HTMLSelectElement>;
|
|
213
261
|
};
|
|
214
|
-
declare const Select: ({ label, description, error, value, options, onValueChange, testId, ref }: SelectProps) => react.JSX.Element;
|
|
215
|
-
type RadioGroupProps = {
|
|
262
|
+
declare const Select: ({ label, description, error, errorId: namedErrorId, value, options, onValueChange, labelHidden, unavailable, testId, ref }: SelectProps) => react.JSX.Element;
|
|
263
|
+
type RadioGroupProps = FieldErrorId & {
|
|
216
264
|
readonly legend: string;
|
|
217
265
|
readonly description?: string;
|
|
218
266
|
readonly error?: string;
|
|
@@ -222,16 +270,18 @@ type RadioGroupProps = {
|
|
|
222
270
|
readonly testId: string;
|
|
223
271
|
readonly ref?: Ref<HTMLInputElement>;
|
|
224
272
|
};
|
|
225
|
-
declare const RadioGroup: ({ legend, description, error, value, options, onValueChange, testId, ref }: RadioGroupProps) => react.JSX.Element;
|
|
226
|
-
type
|
|
227
|
-
|
|
228
|
-
readonly
|
|
229
|
-
readonly
|
|
273
|
+
declare const RadioGroup: ({ legend, description, error, errorId: namedErrorId, value, options, onValueChange, testId, ref }: RadioGroupProps) => react.JSX.Element;
|
|
274
|
+
type CheckboxGroupProps = FieldErrorId & {
|
|
275
|
+
readonly legend: string;
|
|
276
|
+
readonly description?: string;
|
|
277
|
+
readonly error?: string;
|
|
278
|
+
readonly values: readonly string[];
|
|
279
|
+
readonly options: readonly FieldOption[];
|
|
280
|
+
readonly onValuesChange: (values: readonly string[]) => void;
|
|
230
281
|
readonly testId: string;
|
|
231
|
-
readonly
|
|
232
|
-
readonly children: ReactNode;
|
|
282
|
+
readonly ref?: Ref<HTMLInputElement>;
|
|
233
283
|
};
|
|
234
|
-
declare const
|
|
284
|
+
declare const CheckboxGroup: ({ legend, description, error, errorId: namedErrorId, values, options, onValuesChange, testId, ref }: CheckboxGroupProps) => react.JSX.Element;
|
|
235
285
|
type PillTone = "neutral" | "info" | "success" | "warning" | "danger";
|
|
236
286
|
type PillProps = {
|
|
237
287
|
readonly tone: PillTone;
|
|
@@ -241,6 +291,102 @@ type PillProps = {
|
|
|
241
291
|
readonly children: ReactNode;
|
|
242
292
|
};
|
|
243
293
|
declare const Pill: ({ tone, variant, testId, dataAttributes, children }: PillProps) => react.JSX.Element;
|
|
294
|
+
type FigurePointer = {
|
|
295
|
+
readonly cursor: "grab" | "grabbing" | "pointer";
|
|
296
|
+
readonly handlers: Pick<DOMAttributes<SVGSVGElement>, "onPointerDown" | "onPointerMove" | "onPointerUp" | "onPointerCancel" | "onPointerLeave" | "onWheel">;
|
|
297
|
+
};
|
|
298
|
+
type FigureProps = {
|
|
299
|
+
readonly kind: "group";
|
|
300
|
+
readonly label: string;
|
|
301
|
+
readonly widthPx: number;
|
|
302
|
+
readonly heightPx: number;
|
|
303
|
+
readonly onEscape?: () => void;
|
|
304
|
+
readonly testId: string;
|
|
305
|
+
readonly dataAttributes?: DataAttributes;
|
|
306
|
+
readonly children: ReactNode;
|
|
307
|
+
} | {
|
|
308
|
+
readonly kind: "decorative";
|
|
309
|
+
readonly widthPx: number;
|
|
310
|
+
readonly heightPx: number;
|
|
311
|
+
readonly viewBox?: string;
|
|
312
|
+
readonly pointer?: FigurePointer;
|
|
313
|
+
readonly svgRef?: Ref<SVGSVGElement>;
|
|
314
|
+
readonly testId: string;
|
|
315
|
+
readonly dataAttributes?: DataAttributes;
|
|
316
|
+
readonly children: ReactNode;
|
|
317
|
+
};
|
|
318
|
+
type FigureNodeNote = {
|
|
319
|
+
readonly text: string;
|
|
320
|
+
readonly fg: FgRole;
|
|
321
|
+
};
|
|
322
|
+
type FigureNodePress = {
|
|
323
|
+
readonly label: string;
|
|
324
|
+
readonly description?: string;
|
|
325
|
+
readonly expanded: boolean;
|
|
326
|
+
readonly controls?: string;
|
|
327
|
+
readonly onPress: () => void;
|
|
328
|
+
};
|
|
329
|
+
type FigureNodeShape = {
|
|
330
|
+
readonly kind: "box";
|
|
331
|
+
readonly widthPx: number;
|
|
332
|
+
} | {
|
|
333
|
+
readonly kind: "disc";
|
|
334
|
+
readonly radiusPx: number;
|
|
335
|
+
};
|
|
336
|
+
type FigureNodeCommonProps = {
|
|
337
|
+
readonly x: number;
|
|
338
|
+
readonly y: number;
|
|
339
|
+
readonly tone: PillTone;
|
|
340
|
+
readonly outline: "solid" | "dashed";
|
|
341
|
+
readonly selected: boolean;
|
|
342
|
+
readonly title?: string;
|
|
343
|
+
readonly press?: FigureNodePress;
|
|
344
|
+
readonly testId: string;
|
|
345
|
+
readonly dataAttributes?: DataAttributes;
|
|
346
|
+
};
|
|
347
|
+
type FigureNodeProps = FigureNodeCommonProps & ({
|
|
348
|
+
readonly shape: {
|
|
349
|
+
readonly kind: "box";
|
|
350
|
+
readonly widthPx: number;
|
|
351
|
+
};
|
|
352
|
+
readonly name: string;
|
|
353
|
+
readonly notes?: readonly FigureNodeNote[];
|
|
354
|
+
} | {
|
|
355
|
+
readonly shape: {
|
|
356
|
+
readonly kind: "disc";
|
|
357
|
+
readonly radiusPx: number;
|
|
358
|
+
};
|
|
359
|
+
readonly name: string | null;
|
|
360
|
+
readonly notes?: never;
|
|
361
|
+
});
|
|
362
|
+
type FigureEdgeProps = {
|
|
363
|
+
readonly d: string;
|
|
364
|
+
readonly emphasis: "normal" | "high";
|
|
365
|
+
readonly weight: 1 | 2 | 3 | 4;
|
|
366
|
+
readonly arrow: boolean;
|
|
367
|
+
readonly title?: string;
|
|
368
|
+
readonly testId: string;
|
|
369
|
+
readonly dataAttributes?: DataAttributes;
|
|
370
|
+
};
|
|
371
|
+
declare const Figure: (props: FigureProps) => react.JSX.Element;
|
|
372
|
+
declare const FigureNode: (props: FigureNodeProps) => react.JSX.Element;
|
|
373
|
+
declare const FigureEdge: ({ d, emphasis, weight, arrow, title, testId, dataAttributes }: FigureEdgeProps) => react.JSX.Element;
|
|
374
|
+
type HeadingType = Extract<TypeToken, "title" | "heading" | "display" | "display-lg">;
|
|
375
|
+
type HeadingProps = {
|
|
376
|
+
readonly level: 1 | 2 | 3;
|
|
377
|
+
readonly type: HeadingType;
|
|
378
|
+
readonly testId: string;
|
|
379
|
+
readonly headingRef?: Ref<HTMLHeadingElement>;
|
|
380
|
+
readonly children: ReactNode;
|
|
381
|
+
};
|
|
382
|
+
declare const Heading: ({ level, type, testId, headingRef, children }: HeadingProps) => react.JSX.Element;
|
|
383
|
+
type InlineChangeKind = "removed" | "added";
|
|
384
|
+
type InlineChangeProps = {
|
|
385
|
+
readonly kind: InlineChangeKind;
|
|
386
|
+
readonly testId: string;
|
|
387
|
+
readonly children: string;
|
|
388
|
+
};
|
|
389
|
+
declare const InlineChange: ({ kind, testId, children }: InlineChangeProps) => react.JSX.Element;
|
|
244
390
|
type ProgressBarProps = {
|
|
245
391
|
readonly label: string;
|
|
246
392
|
readonly valueText: string;
|
|
@@ -267,6 +413,29 @@ type JobCardProps = {
|
|
|
267
413
|
readonly children?: ReactNode;
|
|
268
414
|
};
|
|
269
415
|
declare const JobCard: ({ title, status, progress, cancel, testId, children }: JobCardProps) => react.JSX.Element;
|
|
416
|
+
type ListTextType = Extract<TypeToken, "body" | "prose">;
|
|
417
|
+
type ListMarking = {
|
|
418
|
+
readonly marker: "bullet" | "number";
|
|
419
|
+
readonly type: ListTextType;
|
|
420
|
+
} | {
|
|
421
|
+
readonly marker: "none";
|
|
422
|
+
readonly ordered: boolean;
|
|
423
|
+
};
|
|
424
|
+
type ListProps = ListMarking & {
|
|
425
|
+
readonly gap: SpaceToken;
|
|
426
|
+
readonly label?: string;
|
|
427
|
+
readonly id?: string;
|
|
428
|
+
readonly hidden?: boolean;
|
|
429
|
+
readonly testId: string;
|
|
430
|
+
readonly children: ReactNode;
|
|
431
|
+
};
|
|
432
|
+
declare const List: (props: ListProps) => react.JSX.Element;
|
|
433
|
+
type ListItemProps = {
|
|
434
|
+
readonly testId: string;
|
|
435
|
+
readonly dataAttributes?: DataAttributes;
|
|
436
|
+
readonly children: ReactNode;
|
|
437
|
+
};
|
|
438
|
+
declare const ListItem: ({ testId, dataAttributes, children }: ListItemProps) => react.JSX.Element;
|
|
270
439
|
type LoadMoreProps = {
|
|
271
440
|
readonly onLoad: () => void;
|
|
272
441
|
readonly busy: boolean;
|
|
@@ -291,12 +460,21 @@ type MasterDetailProps = {
|
|
|
291
460
|
readonly testId: string;
|
|
292
461
|
};
|
|
293
462
|
declare const MasterDetail: ({ master, detail, masterMinPx, detailMinPx, testId }: MasterDetailProps) => react.JSX.Element;
|
|
463
|
+
type MeasuredKeep = "whole" | "wrap";
|
|
294
464
|
type MeasuredProps = {
|
|
295
465
|
readonly value: number | null;
|
|
296
466
|
readonly unit?: string;
|
|
467
|
+
readonly text?: never;
|
|
468
|
+
readonly keep?: never;
|
|
469
|
+
readonly testId: string;
|
|
470
|
+
} | {
|
|
471
|
+
readonly text: string | null;
|
|
472
|
+
readonly keep: MeasuredKeep;
|
|
473
|
+
readonly value?: never;
|
|
474
|
+
readonly unit?: never;
|
|
297
475
|
readonly testId: string;
|
|
298
476
|
};
|
|
299
|
-
declare const Measured: (
|
|
477
|
+
declare const Measured: (props: MeasuredProps) => react.JSX.Element;
|
|
300
478
|
type MeterProps = {
|
|
301
479
|
readonly label: string;
|
|
302
480
|
readonly value: number;
|
|
@@ -318,6 +496,20 @@ type AlertMessageProps = {
|
|
|
318
496
|
readonly children: ReactNode;
|
|
319
497
|
};
|
|
320
498
|
declare const AlertMessage: ({ occurrence, testId, children }: AlertMessageProps) => react.JSX.Element;
|
|
499
|
+
type PanelTab = {
|
|
500
|
+
readonly id: string;
|
|
501
|
+
readonly label: string;
|
|
502
|
+
};
|
|
503
|
+
type PanelTabsProps = {
|
|
504
|
+
readonly label: string;
|
|
505
|
+
readonly items: readonly PanelTab[];
|
|
506
|
+
readonly value: string;
|
|
507
|
+
readonly onValueChange: (id: string) => void;
|
|
508
|
+
readonly testId: string;
|
|
509
|
+
readonly panelDescribedBy?: string;
|
|
510
|
+
readonly children: ReactNode;
|
|
511
|
+
};
|
|
512
|
+
declare const PanelTabs: ({ label, items, value, onValueChange, testId, panelDescribedBy, children }: PanelTabsProps) => react.JSX.Element;
|
|
321
513
|
type ResourceFailedProps = {
|
|
322
514
|
readonly failure: ResourceFailure;
|
|
323
515
|
readonly onReload: () => void;
|
|
@@ -381,7 +573,10 @@ type StackProps = {
|
|
|
381
573
|
readonly children: ReactNode;
|
|
382
574
|
};
|
|
383
575
|
declare const Stack: ({ gap, testId, children }: StackProps) => react.JSX.Element;
|
|
384
|
-
|
|
576
|
+
type ClusterProps = StackProps & {
|
|
577
|
+
readonly as?: "div" | "span";
|
|
578
|
+
};
|
|
579
|
+
declare const Cluster: ({ gap, as: Element, testId, children }: ClusterProps) => react.JSX.Element;
|
|
385
580
|
type StepState = "done" | "current" | "pending";
|
|
386
581
|
type StepperItem = {
|
|
387
582
|
readonly id: string;
|
|
@@ -395,12 +590,16 @@ type StepperProps = {
|
|
|
395
590
|
};
|
|
396
591
|
declare const Stepper: ({ label, steps, testId }: StepperProps) => react.JSX.Element;
|
|
397
592
|
type SwitchProps = {
|
|
398
|
-
readonly label:
|
|
593
|
+
readonly label: ReactNode;
|
|
594
|
+
readonly labelHidden?: boolean;
|
|
399
595
|
readonly checked: boolean;
|
|
400
596
|
readonly onCheckedChange: (checked: boolean) => void;
|
|
597
|
+
readonly unavailable?: Unavailable;
|
|
401
598
|
readonly testId: string;
|
|
599
|
+
readonly ref?: Ref<HTMLButtonElement>;
|
|
600
|
+
readonly dataAttributes?: DataAttributes;
|
|
402
601
|
};
|
|
403
|
-
declare const Switch: ({ label, checked, onCheckedChange, testId }: SwitchProps) => react.JSX.Element;
|
|
602
|
+
declare const Switch: ({ label, labelHidden, checked, onCheckedChange, unavailable, testId, ref, dataAttributes }: SwitchProps) => react.JSX.Element;
|
|
404
603
|
type TabItem = {
|
|
405
604
|
readonly id: string;
|
|
406
605
|
readonly label: string;
|
|
@@ -414,29 +613,37 @@ type TabsProps = {
|
|
|
414
613
|
readonly testId: string;
|
|
415
614
|
};
|
|
416
615
|
declare const Tabs: ({ label, items, currentId, onNavigate, testId }: TabsProps) => react.JSX.Element;
|
|
417
|
-
type TextFace = "sans" | "mono";
|
|
418
616
|
type TextProps = {
|
|
419
617
|
readonly fg: FgRole;
|
|
420
618
|
readonly type: TypeToken;
|
|
421
619
|
readonly face?: TextFace;
|
|
422
620
|
readonly as?: "span" | "p" | "div";
|
|
621
|
+
readonly space?: "preserve";
|
|
423
622
|
readonly testId?: string;
|
|
424
623
|
readonly id?: string;
|
|
425
624
|
readonly tabIndex?: -1;
|
|
426
625
|
readonly ref?: Ref<HTMLElement>;
|
|
427
626
|
readonly children: ReactNode;
|
|
428
627
|
};
|
|
429
|
-
declare const Text: ({ fg, type, face, as: Element, testId, id, tabIndex, ref, children }: TextProps) => react.JSX.Element;
|
|
628
|
+
declare const Text: ({ fg, type, face, as: Element, space, testId, id, tabIndex, ref, children }: TextProps) => react.JSX.Element;
|
|
430
629
|
type MetricTileTone = "neutral" | "danger" | "warning" | "success";
|
|
630
|
+
type MetricTileValue = {
|
|
631
|
+
readonly value: number | null;
|
|
632
|
+
readonly unit?: string;
|
|
633
|
+
readonly text?: never;
|
|
634
|
+
} | {
|
|
635
|
+
readonly text: string | null;
|
|
636
|
+
readonly value?: never;
|
|
637
|
+
readonly unit?: never;
|
|
638
|
+
};
|
|
431
639
|
type MetricTileProps = {
|
|
432
640
|
readonly label: string;
|
|
433
641
|
readonly sublabel: string;
|
|
434
|
-
readonly value: number | null;
|
|
435
642
|
readonly tone: MetricTileTone;
|
|
436
643
|
readonly testId: string;
|
|
437
644
|
readonly dataAttributes?: DataAttributes;
|
|
438
|
-
};
|
|
439
|
-
declare const MetricTile: (
|
|
645
|
+
} & MetricTileValue;
|
|
646
|
+
declare const MetricTile: (props: MetricTileProps) => react.JSX.Element;
|
|
440
647
|
type TileGridProps = {
|
|
441
648
|
readonly count: number;
|
|
442
649
|
readonly minInlinePx: number;
|
|
@@ -464,6 +671,11 @@ type UsePagedResourceResult<K, T, C, M> = {
|
|
|
464
671
|
readonly updateList: (key: K, map: (content: PagedContent<T, M>) => PagedContent<T, M>) => void;
|
|
465
672
|
};
|
|
466
673
|
declare const usePagedResource: <K extends string | number, T, C extends string | number, M>(key: K | null, loaders: PagedLoaders<T, C, M>, revision: number) => UsePagedResourceResult<K, T, C, M>;
|
|
674
|
+
type PendingPress = {
|
|
675
|
+
readonly pendingKey: string | null;
|
|
676
|
+
readonly press: (key: string, action: () => unknown) => void;
|
|
677
|
+
};
|
|
678
|
+
declare const usePendingPress: () => PendingPress;
|
|
467
679
|
type UseResourceResult<K, T> = {
|
|
468
680
|
readonly state: ResourceState<T>;
|
|
469
681
|
readonly reload: () => void;
|
|
@@ -476,4 +688,4 @@ type VisuallyHiddenProps = {
|
|
|
476
688
|
readonly children: ReactNode;
|
|
477
689
|
};
|
|
478
690
|
declare const VisuallyHidden: ({ testId, children }: VisuallyHiddenProps) => react.JSX.Element;
|
|
479
|
-
export { ANNOUNCE_SETTLE_MS, AlertMessage, type AlertMessageProps, Breadcrumb, type BreadcrumbItem, type BreadcrumbProps, Button, type ButtonProps, type ButtonVariant, Card, type CardProps, CardSection, type CardSectionProps, Cluster, CodeBlock, type CodeBlockProps, type ColumnDef, ColumnWidth, type ComparisonAttribute, type ComparisonColumn, ComparisonGrid, type ComparisonGridProps, type ComparisonLayout, type ConsoleUiContextValue, ConsoleUiLabels, ConsoleUiLocale, ConsoleUiRoot, type ConsoleUiRootProps, type DataAttributes, DataTable, type DataTableProps, type DescriptionItem, DescriptionList, type DescriptionListProps, Dialog, type DialogProps, Disclosure, type DisclosureProps, FgRole, Field, type FieldControl, type FieldOption, type FieldProps, Heading, type HeadingProps, type HeadingType, type JobCancel, JobCard, type JobCardProps, KeysetPage, Link, type LinkProps, LoadMore, type LoadMoreProps, MasterDetail, type MasterDetailProps, Measured, type MeasuredProps, Meter, type MeterProps, MetricTile, type MetricTileProps, type MetricTileTone, NextPage, Notice, type NoticeProps, PagedContent, type PagedLoaders, PagedState, PasswordInput, type PasswordInputProps, Pill, type PillProps, type PillTone, ProgressBar, type ProgressBarProps, RadioGroup, type RadioGroupProps, ResourceFailed, type ResourceFailedProps, ResourceFailure, ResourceOutcome, ResourceState, RowButton, type RowButtonProps, SegmentedControl, type SegmentedControlProps, type SegmentedOption, Select, type SelectProps, SelectableList, type SelectableListProps, Slider, type SliderProps, SpaceToken, Stack, type StackProps, type StepState, Stepper, type StepperItem, type StepperProps, Switch, type SwitchProps, type TabItem, Tabs, type TabsProps, Text, TextArea, type TextAreaProps,
|
|
691
|
+
export { ANNOUNCE_SETTLE_MS, AlertMessage, type AlertMessageProps, Breadcrumb, type BreadcrumbItem, type BreadcrumbProps, Button, type ButtonProps, type ButtonVariant, Card, type CardProps, CardSection, type CardSectionProps, CheckboxGroup, type CheckboxGroupProps, Cluster, type ClusterProps, CodeBlock, type CodeBlockProps, type ColumnDef, ColumnWidth, type ComparisonAttribute, type ComparisonColumn, ComparisonGrid, type ComparisonGridProps, type ComparisonLayout, type ConsoleUiContextValue, ConsoleUiLabels, ConsoleUiLocale, ConsoleUiRoot, type ConsoleUiRootProps, type DataAttributes, DataTable, type DataTableProps, type DataTableRowDetail, type DescriptionItem, DescriptionList, type DescriptionListProps, Dialog, type DialogProps, Disclosure, type DisclosureProps, FgRole, Field, type FieldControl, type FieldOption, type FieldProps, Figure, FigureEdge, type FigureEdgeProps, FigureNode, type FigureNodeNote, type FigureNodePress, type FigureNodeProps, type FigureNodeShape, type FigurePointer, type FigureProps, FragmentLink, type FragmentLinkProps, Heading, type HeadingProps, type HeadingType, InlineChange, type InlineChangeKind, type InlineChangeProps, type JobCancel, JobCard, type JobCardProps, KeysetPage, Link, type LinkProps, List, ListItem, type ListItemProps, type ListMarking, type ListProps, type ListTextType, LoadMore, type LoadMoreProps, MasterDetail, type MasterDetailProps, Measured, type MeasuredKeep, type MeasuredProps, Meter, type MeterProps, MetricTile, type MetricTileProps, type MetricTileTone, NextPage, Notice, type NoticeProps, PagedContent, type PagedLoaders, PagedState, type PanelTab, PanelTabs, type PanelTabsProps, PasswordInput, type PasswordInputProps, type PendingPress, Pill, type PillProps, type PillTone, ProgressBar, type ProgressBarProps, RadioGroup, type RadioGroupProps, ResourceFailed, type ResourceFailedProps, ResourceFailure, ResourceOutcome, ResourceState, RowButton, type RowButtonProps, SegmentedControl, type SegmentedControlProps, type SegmentedOption, Select, type SelectProps, SelectableList, type SelectableListProps, Slider, type SliderProps, SpaceToken, Stack, type StackProps, type StepState, Stepper, type StepperItem, type StepperProps, Switch, type SwitchProps, type TabItem, Tabs, type TabsProps, Text, TextArea, type TextAreaProps, TextFace, TextInput, type TextInputProps, type TextProps, TileGrid, type TileGridProps, Toolbar, type ToolbarProps, TypeToken, type Unavailable, type UsePagedResourceResult, type UseResourceResult, VisuallyHidden, type VisuallyHiddenProps, useAnnounce, useConsoleUi, useEscapeToClose, useFocusRescue, usePagedResource, usePendingPress, useResource };
|