@woven-planet/lakefront 5.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 +87 -0
- package/dist/index.cjs.d.ts +2775 -0
- package/dist/index.cjs.js +1 -0
- package/dist/index.esm.d.ts +2775 -0
- package/dist/index.esm.js +1 -0
- package/package.json +125 -0
|
@@ -0,0 +1,2775 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import React from "react";
|
|
3
|
+
import { ComponentPropsWithoutRef, FC, RefAttributes, ReactNode, ElementType, ReactElement, ChangeEvent, Dispatch, MouseEventHandler, SetStateAction, ComponentPropsWithRef, MouseEvent } from "react";
|
|
4
|
+
import { LinkProps } from "react-router-dom";
|
|
5
|
+
import { GetStyles, GroupBase } from "react-select/dist/declarations/src/types";
|
|
6
|
+
import { ParsedQuery } from "query-string";
|
|
7
|
+
import { Column } from "react-table";
|
|
8
|
+
interface AnchorCopyProps {
|
|
9
|
+
/**
|
|
10
|
+
* The button or inner content to render. This defaults to
|
|
11
|
+
* a link icon button.
|
|
12
|
+
*/
|
|
13
|
+
AnchorContent: FC;
|
|
14
|
+
/**
|
|
15
|
+
* The classes to pass to the anchor container.
|
|
16
|
+
*/
|
|
17
|
+
className?: string;
|
|
18
|
+
/**
|
|
19
|
+
* A boolean that defines whether the anchor should be disabled.
|
|
20
|
+
*/
|
|
21
|
+
disabled?: boolean;
|
|
22
|
+
/**
|
|
23
|
+
* The (non-encoded) hash to be appended to the end of the url.
|
|
24
|
+
*/
|
|
25
|
+
hashId?: string;
|
|
26
|
+
/**
|
|
27
|
+
* The action to run on copy success.
|
|
28
|
+
*/
|
|
29
|
+
onCopy?: (scrollToUrl: string) => void;
|
|
30
|
+
/**
|
|
31
|
+
* The title to display next to the anchor button or content.
|
|
32
|
+
*/
|
|
33
|
+
title: string;
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* AnchorCopy Component
|
|
37
|
+
*
|
|
38
|
+
* The AnchorCopy component is meant for creating in page anchor links that
|
|
39
|
+
* can be easily copied on button click. The `hashId` (or `title`
|
|
40
|
+
* if `hashId` is falsy) will be encoded, appended to the current url, and copied
|
|
41
|
+
* to the user's clipboard. `onCopy` can also be provided to perform additional
|
|
42
|
+
* operations on the copied content.
|
|
43
|
+
*/
|
|
44
|
+
declare const AnchorCopy: FC<AnchorCopyProps & Omit<ComponentPropsWithoutRef<"div">, "onCopy">>;
|
|
45
|
+
interface BoundingBoxItemProp {
|
|
46
|
+
name: string;
|
|
47
|
+
items: {
|
|
48
|
+
confidence: number;
|
|
49
|
+
bbox: number[][];
|
|
50
|
+
}[];
|
|
51
|
+
color: string;
|
|
52
|
+
}
|
|
53
|
+
interface BoundingBoxesProps {
|
|
54
|
+
/**
|
|
55
|
+
* The name of the currently active item. When specified, only
|
|
56
|
+
* bounding boxes included in the first item with the matching name will be drawn.
|
|
57
|
+
*/
|
|
58
|
+
activeBBox: string;
|
|
59
|
+
/**
|
|
60
|
+
* A list of bounding box items to draw including the name of the item,
|
|
61
|
+
* the color of the boxes, and a list of bounding boxes to draw.
|
|
62
|
+
*/
|
|
63
|
+
boundingBoxItems: BoundingBoxItemProp[];
|
|
64
|
+
/**
|
|
65
|
+
* The classes to pass to the bounding boxes container.
|
|
66
|
+
*/
|
|
67
|
+
className?: string;
|
|
68
|
+
/**
|
|
69
|
+
* The width of the image.
|
|
70
|
+
*/
|
|
71
|
+
imageWidth: number;
|
|
72
|
+
/**
|
|
73
|
+
* The height of the image.
|
|
74
|
+
*/
|
|
75
|
+
imageHeight: number;
|
|
76
|
+
/**
|
|
77
|
+
* The desired width to display the image. This will likely be observed in the
|
|
78
|
+
* parent component, changing often to allow the image to resize.
|
|
79
|
+
*/
|
|
80
|
+
outputWidth: number;
|
|
81
|
+
/**
|
|
82
|
+
* The desired height to display the image. This will likely be observed in the
|
|
83
|
+
* parent component, changing often to allow the image to resize.
|
|
84
|
+
*/
|
|
85
|
+
outputHeight: number;
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* BoundingBoxes Component
|
|
89
|
+
*
|
|
90
|
+
* The BoundingBoxes component is intended to draw boxes on top of specified areas
|
|
91
|
+
* of an image. This can be used to direct attention to key aspects or items within an image
|
|
92
|
+
* while also maintaining the proper aspect ratio and location offset(s) as the image is resized.
|
|
93
|
+
*/
|
|
94
|
+
declare const BoundingBoxes: FC<BoundingBoxesProps>;
|
|
95
|
+
interface RouteProp {
|
|
96
|
+
/**
|
|
97
|
+
* This is to set the name of the breadcrumb to be displayed.
|
|
98
|
+
*/
|
|
99
|
+
name: string;
|
|
100
|
+
/**
|
|
101
|
+
* This is to set the link of the breadcrumb.
|
|
102
|
+
*/
|
|
103
|
+
url: string;
|
|
104
|
+
}
|
|
105
|
+
interface BreadcrumbProps {
|
|
106
|
+
/**
|
|
107
|
+
* This is to set the routes which includes the name of the breadcrumb that needs to be displayed.
|
|
108
|
+
* You can also set the url for the breadcrumb to navigate to the appropriate link.
|
|
109
|
+
*/
|
|
110
|
+
routes: RouteProp[];
|
|
111
|
+
/**
|
|
112
|
+
* This allows you to pass your own Link connected to your application router.
|
|
113
|
+
* This is most useful for applications using React-router v6 and above.
|
|
114
|
+
*/
|
|
115
|
+
Link?: FC<LinkProps & RefAttributes<HTMLAnchorElement>>;
|
|
116
|
+
}
|
|
117
|
+
/**
|
|
118
|
+
* The Breadcrumb Component is used to render the breadcrumb. The Name of the Breadcrumb is displayed.
|
|
119
|
+
* The url can be used to link to the appropriate link.
|
|
120
|
+
*/
|
|
121
|
+
declare const Breadcrumb: FC<BreadcrumbProps>;
|
|
122
|
+
interface BreadcrumbHeaderProps {
|
|
123
|
+
/**
|
|
124
|
+
* This is to set the routes which includes the name of the breadcrumb that needs to be displayed.
|
|
125
|
+
* You can also set the url for the breadcrumb to navigate to the appropriate link.
|
|
126
|
+
*/
|
|
127
|
+
routes: RouteProp[];
|
|
128
|
+
/**
|
|
129
|
+
* This is to set the Class on the Breadcrumb Header.
|
|
130
|
+
*/
|
|
131
|
+
className?: string;
|
|
132
|
+
/**
|
|
133
|
+
* This is to set the standalone property. If set to true, this will add full width with margin
|
|
134
|
+
* and a bottom border.
|
|
135
|
+
*/
|
|
136
|
+
standalone?: boolean;
|
|
137
|
+
/**
|
|
138
|
+
* If set to true, this will not display any routes.
|
|
139
|
+
*/
|
|
140
|
+
hideRoutes?: boolean;
|
|
141
|
+
/**
|
|
142
|
+
* Children to display as the content.
|
|
143
|
+
*/
|
|
144
|
+
children?: ReactNode;
|
|
145
|
+
/**
|
|
146
|
+
* This allows you to pass your own Link connected to your application router.
|
|
147
|
+
* This is most useful for applications using React-router v6 and above.
|
|
148
|
+
*/
|
|
149
|
+
Link?: FC<LinkProps & RefAttributes<HTMLAnchorElement>>;
|
|
150
|
+
}
|
|
151
|
+
/**
|
|
152
|
+
* Breadcrumb navigation trail component that can be used as a header.
|
|
153
|
+
*
|
|
154
|
+
* Set [standalone] to false if you want to apply your own container styling (with className
|
|
155
|
+
* prop or a wrapper). Set [standalone] to true to add full-width behavior with margins and
|
|
156
|
+
* a bottom border (to function as a standalone header). Defaults to true.
|
|
157
|
+
*/
|
|
158
|
+
declare const BreadcrumbHeader: FC<BreadcrumbHeaderProps>;
|
|
159
|
+
interface ButtonProps {
|
|
160
|
+
/**
|
|
161
|
+
* Determines the style of the button: primary, secondary, or destructive.
|
|
162
|
+
*/
|
|
163
|
+
color?: "primary" | "secondary" | "destructive";
|
|
164
|
+
/**
|
|
165
|
+
* Provides an alternate color theme for use on darker backgrounds.
|
|
166
|
+
*/
|
|
167
|
+
alternate?: boolean;
|
|
168
|
+
/**
|
|
169
|
+
* An emotion prop that allow for changing the type of element. It can be a simple string
|
|
170
|
+
* with an HTML element such as "a", or even a complex component such as a react router Link.
|
|
171
|
+
*/
|
|
172
|
+
as?: ElementType | keyof JSX.IntrinsicElements;
|
|
173
|
+
/**
|
|
174
|
+
* The classes to pass to the button.
|
|
175
|
+
*/
|
|
176
|
+
className?: string;
|
|
177
|
+
}
|
|
178
|
+
type Icon = ReactElement<SVGElement> | boolean | string | undefined;
|
|
179
|
+
interface IconComponentProps {
|
|
180
|
+
/**
|
|
181
|
+
* When strictly true, the default icon for a color type will be inserted at the iconPosition prop's location.
|
|
182
|
+
* Primary and Secondary colors have a plus/add icon, and destructive has a garbage can/delete icon.
|
|
183
|
+
* When a svg, the svg will used as the icon.
|
|
184
|
+
* (Future) When a string, an icon lookup/conversion will be attempted.
|
|
185
|
+
*/
|
|
186
|
+
icon?: Icon;
|
|
187
|
+
/**
|
|
188
|
+
* When provided will display next to icon.
|
|
189
|
+
*/
|
|
190
|
+
children?: ReactNode;
|
|
191
|
+
/**
|
|
192
|
+
* When icon is defined, the position can be specified via the iconPosition prop.
|
|
193
|
+
*/
|
|
194
|
+
iconPosition?: "left" | "right";
|
|
195
|
+
/**
|
|
196
|
+
* Allows text to render under icon button.
|
|
197
|
+
*/
|
|
198
|
+
iconLabel?: string;
|
|
199
|
+
}
|
|
200
|
+
type ButtonComponentProps = ButtonProps & IconComponentProps & ComponentPropsWithoutRef<"button">;
|
|
201
|
+
/**
|
|
202
|
+
* Button Component
|
|
203
|
+
*
|
|
204
|
+
* The Button component takes in native button props along with color, alternate, icon, and iconPosition props.
|
|
205
|
+
* The color prop, which defaults to primary, determines its overall color scheme.
|
|
206
|
+
* The alternate prop inverts the color scheme to look better on dark backgrounds.
|
|
207
|
+
* className will properly apply itself, but the CSS may need to be more specific,
|
|
208
|
+
* such as button.MyClass instead of just .MyClass.
|
|
209
|
+
* The icon prop can be of several types. If it is an svg, that svg will be used. If it
|
|
210
|
+
* is strictly "true", we will apply the default icon based on the provided color. In the future, if it is a string,
|
|
211
|
+
* we will attempt to convert it into an icon. When icon is defined, the position can be specified via the iconPosition prop.
|
|
212
|
+
*/
|
|
213
|
+
declare const Button: FC<ButtonComponentProps>;
|
|
214
|
+
type ButtonProps$0 = ButtonComponentProps;
|
|
215
|
+
interface CardProps {
|
|
216
|
+
/**
|
|
217
|
+
* This will set the cards h1 heading.
|
|
218
|
+
*/
|
|
219
|
+
title: string;
|
|
220
|
+
/**
|
|
221
|
+
* This is the callback that is fired when the top-right arrow button is clicked.
|
|
222
|
+
*/
|
|
223
|
+
onClick?: () => void;
|
|
224
|
+
/**
|
|
225
|
+
* Description of the card's intent.
|
|
226
|
+
*/
|
|
227
|
+
description?: string;
|
|
228
|
+
/**
|
|
229
|
+
* Display content as a child node.
|
|
230
|
+
*/
|
|
231
|
+
children?: ReactNode;
|
|
232
|
+
/**
|
|
233
|
+
* This takes in any ReactNode to be displayed in the main content area of the card.
|
|
234
|
+
*/
|
|
235
|
+
content?: ReactNode;
|
|
236
|
+
/**
|
|
237
|
+
* If the button should or shouldn't be disabled.
|
|
238
|
+
*/
|
|
239
|
+
disabled?: boolean;
|
|
240
|
+
/**
|
|
241
|
+
* This is to set the class of the Card component.
|
|
242
|
+
*/
|
|
243
|
+
className?: string;
|
|
244
|
+
/**
|
|
245
|
+
* This takes in any ReactNode to be displayed in the top right content area of the card.
|
|
246
|
+
*/
|
|
247
|
+
topRightComponent?: ReactNode;
|
|
248
|
+
}
|
|
249
|
+
/**
|
|
250
|
+
* The Card Component is used to render a single Card, or a collection of Cards.
|
|
251
|
+
*/
|
|
252
|
+
declare const Card: FC<CardProps>;
|
|
253
|
+
interface CheckboxProps {
|
|
254
|
+
/**
|
|
255
|
+
* The value to control whether the checkbox should be checked or not.
|
|
256
|
+
*/
|
|
257
|
+
checked?: boolean;
|
|
258
|
+
/**
|
|
259
|
+
* The svg icon to display when checked is true. If left undefined, a check mark will be displayed.
|
|
260
|
+
*/
|
|
261
|
+
checkedIcon?: ReactElement<SVGElement>;
|
|
262
|
+
/**
|
|
263
|
+
* A display state in which it is unknown whether checked should be true or false.
|
|
264
|
+
*/
|
|
265
|
+
indeterminate?: boolean;
|
|
266
|
+
/**
|
|
267
|
+
* The (optional) label for the checkbox.
|
|
268
|
+
*/
|
|
269
|
+
label?: string | ReactElement;
|
|
270
|
+
/**
|
|
271
|
+
* HTML input element disabled prop.
|
|
272
|
+
*/
|
|
273
|
+
disabled?: boolean;
|
|
274
|
+
/**
|
|
275
|
+
* The action that should be run when the checked state changes.
|
|
276
|
+
*/
|
|
277
|
+
onChange?: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
278
|
+
/**
|
|
279
|
+
* The classes to pass to the checkbox.
|
|
280
|
+
*/
|
|
281
|
+
className?: string;
|
|
282
|
+
/**
|
|
283
|
+
* The classes to pass to the checkbox label.
|
|
284
|
+
*/
|
|
285
|
+
labelClassName?: string;
|
|
286
|
+
description?: string;
|
|
287
|
+
}
|
|
288
|
+
/**
|
|
289
|
+
* Checkbox Component
|
|
290
|
+
*
|
|
291
|
+
* The Checkbox component takes in native checkbox props as well as its own CheckboxProps.
|
|
292
|
+
* The `checked` state is not managed in the component and should be received
|
|
293
|
+
* via the `checked` prop from the consuming app.
|
|
294
|
+
*
|
|
295
|
+
*/
|
|
296
|
+
declare const Checkbox: FC<CheckboxProps & ComponentPropsWithoutRef<"input">>;
|
|
297
|
+
interface CheckboxGroupOption {
|
|
298
|
+
value: string;
|
|
299
|
+
label: string | ReactElement;
|
|
300
|
+
color?: string;
|
|
301
|
+
description?: string;
|
|
302
|
+
}
|
|
303
|
+
interface CheckboxGroupProps {
|
|
304
|
+
/**
|
|
305
|
+
* The options that should be displayed in the checkbox group.
|
|
306
|
+
*/
|
|
307
|
+
options: CheckboxGroupOption[];
|
|
308
|
+
/**
|
|
309
|
+
* These are the classes that would be applied to the Checkbox group.
|
|
310
|
+
*/
|
|
311
|
+
className?: string;
|
|
312
|
+
/**
|
|
313
|
+
* The action that should be run when the checked state changes.
|
|
314
|
+
*/
|
|
315
|
+
onHandleChange(items: Set<string>): void;
|
|
316
|
+
/**
|
|
317
|
+
* The name of the Checkbox group.
|
|
318
|
+
*/
|
|
319
|
+
name: string;
|
|
320
|
+
/**
|
|
321
|
+
* The options that are checked when the control loads.
|
|
322
|
+
*/
|
|
323
|
+
selected: Set<string>;
|
|
324
|
+
/**
|
|
325
|
+
* This option is to select or unselect all the checkboxes.
|
|
326
|
+
* Specify the name of the label to be displayed for checkbox.
|
|
327
|
+
*/
|
|
328
|
+
allLabel?: string;
|
|
329
|
+
/**
|
|
330
|
+
* This option is used to set the select all checkbox color.
|
|
331
|
+
*/
|
|
332
|
+
allColor?: string;
|
|
333
|
+
}
|
|
334
|
+
/**
|
|
335
|
+
* The Checkbox Group Component
|
|
336
|
+
*
|
|
337
|
+
* The CheckboxGroup component can be used to provide multiple checkbox options. The user can set default selection on
|
|
338
|
+
* the checkbox group render. The All option is provided to check or uncheck all the options.
|
|
339
|
+
*/
|
|
340
|
+
declare const CheckboxGroup: FC<CheckboxGroupProps>;
|
|
341
|
+
interface CollapsibleProps {
|
|
342
|
+
/**
|
|
343
|
+
* This is the initial display state of the component. When true, the child contents will be displayed.
|
|
344
|
+
* When false, the child contents will be hidden.
|
|
345
|
+
*/
|
|
346
|
+
expanded?: boolean;
|
|
347
|
+
/**
|
|
348
|
+
* This is an action to run when the expand state changes.
|
|
349
|
+
*/
|
|
350
|
+
onChange?: () => void;
|
|
351
|
+
/**
|
|
352
|
+
* This is an event which will trigger when the expand/collapse section is clicked.
|
|
353
|
+
*/
|
|
354
|
+
onClick?: () => void;
|
|
355
|
+
/**
|
|
356
|
+
* Typically a string, this is the content to show at the top left of the component.
|
|
357
|
+
*/
|
|
358
|
+
title?: string | ReactElement;
|
|
359
|
+
/**
|
|
360
|
+
* Typically a string, this is the content to show at the top right of the component.
|
|
361
|
+
*/
|
|
362
|
+
subtitle?: string | ReactElement;
|
|
363
|
+
/**
|
|
364
|
+
* `Default = false` This determines if a horizontal divider should be displayed between the
|
|
365
|
+
* title and the child content.
|
|
366
|
+
*/
|
|
367
|
+
divider?: boolean;
|
|
368
|
+
/**
|
|
369
|
+
* `Default = true` This determines if the expand/collapse icon should be displayed and usable.
|
|
370
|
+
*/
|
|
371
|
+
collapsible?: boolean;
|
|
372
|
+
/**
|
|
373
|
+
* This is to render icon for expand/collapse control.
|
|
374
|
+
*/
|
|
375
|
+
icon?: ReactElement<SVGElement> | boolean | string | undefined;
|
|
376
|
+
/**
|
|
377
|
+
* The classes to pass to the collapsible.
|
|
378
|
+
*/
|
|
379
|
+
className?: string;
|
|
380
|
+
}
|
|
381
|
+
/**
|
|
382
|
+
* Collapsible Component
|
|
383
|
+
*
|
|
384
|
+
* The Collapsible component can be used to make collapsible sections within a document.
|
|
385
|
+
* The component takes in native div props as well as its own CollapsibleProps. The `expanded` prop
|
|
386
|
+
* controls the initial state of the component. Once initialized, the state is managed within this component.
|
|
387
|
+
*
|
|
388
|
+
*/
|
|
389
|
+
declare const Collapsible: FC<CollapsibleProps & Pick<ComponentPropsWithoutRef<"div">, Exclude<keyof ComponentPropsWithoutRef<"div">, keyof CollapsibleProps>>>;
|
|
390
|
+
interface CopyButtonProps {
|
|
391
|
+
/**
|
|
392
|
+
* `Default = "Copy"` The text to display within the button.
|
|
393
|
+
*/
|
|
394
|
+
buttonText?: string;
|
|
395
|
+
/**
|
|
396
|
+
* The classes to pass to the bounding boxes container.
|
|
397
|
+
*/
|
|
398
|
+
className?: string;
|
|
399
|
+
/**
|
|
400
|
+
* A boolean that defines whether the anchor should be disabled.
|
|
401
|
+
*/
|
|
402
|
+
disabled?: boolean;
|
|
403
|
+
/**
|
|
404
|
+
* The action to run on copy success.
|
|
405
|
+
*/
|
|
406
|
+
onCopy?: (scrollToUrl: string) => void;
|
|
407
|
+
/**
|
|
408
|
+
* The value to be copied to the clipboard.
|
|
409
|
+
*/
|
|
410
|
+
valueToCopy: string;
|
|
411
|
+
/**
|
|
412
|
+
* This is to set the iconOnly property. If set to false, the icon and text will appear. If true, only copy icon will render.
|
|
413
|
+
* By default, the IconOnly property is set to false.
|
|
414
|
+
*/
|
|
415
|
+
iconOnly: boolean;
|
|
416
|
+
}
|
|
417
|
+
/**
|
|
418
|
+
* CopyButton Component
|
|
419
|
+
*
|
|
420
|
+
* The CopyButton component is an implementation of the [Button Component](https://woven-planet.github.io/lakefront/?path=/docs/lakefront-button--all-buttons)
|
|
421
|
+
* used specifically for copying provided text to the clipboard. While the default usage should suffice, various aspects can be overridden
|
|
422
|
+
* due to the inheritance of many `ButtonComponentProps`.
|
|
423
|
+
*/
|
|
424
|
+
declare const CopyButton: FC<CopyButtonProps & Omit<ButtonComponentProps, "onCopy">>;
|
|
425
|
+
interface DrawerProps {
|
|
426
|
+
/**
|
|
427
|
+
* Children to display below the containers close button.
|
|
428
|
+
*/
|
|
429
|
+
children?: ReactNode;
|
|
430
|
+
/**
|
|
431
|
+
* This is the initial display state of the component. When true, the drawer will be displayed.
|
|
432
|
+
* When false, the drawer will be hidden.
|
|
433
|
+
*/
|
|
434
|
+
open: boolean;
|
|
435
|
+
/**
|
|
436
|
+
* This is an action to run when the drawer is closed.
|
|
437
|
+
*/
|
|
438
|
+
onClose(): void;
|
|
439
|
+
/**
|
|
440
|
+
* This is the width for the drawer.
|
|
441
|
+
*/
|
|
442
|
+
width?: string | number;
|
|
443
|
+
/**
|
|
444
|
+
* These are the classes that would be applied to drawer.
|
|
445
|
+
*/
|
|
446
|
+
className?: string;
|
|
447
|
+
/**
|
|
448
|
+
* These are the classes for the toolbar.
|
|
449
|
+
*/
|
|
450
|
+
toolbarClasses?: string;
|
|
451
|
+
}
|
|
452
|
+
/**
|
|
453
|
+
* The Drawer Component
|
|
454
|
+
*
|
|
455
|
+
* The Drawer component can be used to open the drawer and show the contents of the drawer.
|
|
456
|
+
* The component takes drawer props. The open prop controls the visibility of the component.
|
|
457
|
+
*
|
|
458
|
+
* Usage: Place this next to a flex container that has flex: 1
|
|
459
|
+
*/
|
|
460
|
+
declare const Drawer: FC<DrawerProps>;
|
|
461
|
+
/**
|
|
462
|
+
* JSONObject is a wrapper for a generic JSON object structure.
|
|
463
|
+
*/
|
|
464
|
+
interface JSONObject {
|
|
465
|
+
[key: string]: any;
|
|
466
|
+
}
|
|
467
|
+
/**
|
|
468
|
+
* This is the structure of a selectable option.
|
|
469
|
+
*/
|
|
470
|
+
interface SelectOption<T> {
|
|
471
|
+
label: string;
|
|
472
|
+
value: T;
|
|
473
|
+
}
|
|
474
|
+
/**
|
|
475
|
+
* This is the structure of Tabs.
|
|
476
|
+
*/
|
|
477
|
+
interface TabDef {
|
|
478
|
+
key: string;
|
|
479
|
+
caption: string;
|
|
480
|
+
}
|
|
481
|
+
type MultiSelectOption = SelectOption<string>;
|
|
482
|
+
interface SelectOption$0 {
|
|
483
|
+
value: string | number | undefined;
|
|
484
|
+
label: string;
|
|
485
|
+
}
|
|
486
|
+
interface SelectProps {
|
|
487
|
+
/**
|
|
488
|
+
* This is to set the options of the dropdown.
|
|
489
|
+
*/
|
|
490
|
+
options: SelectOption$0[];
|
|
491
|
+
/**
|
|
492
|
+
* This is called when an dropdown change event.
|
|
493
|
+
*/
|
|
494
|
+
onChange(event: any): void;
|
|
495
|
+
/**
|
|
496
|
+
* This is called on dropdown blur event.
|
|
497
|
+
*/
|
|
498
|
+
onBlur?(event: any): void;
|
|
499
|
+
/**
|
|
500
|
+
* This is to set the autofocus of the dropdown.
|
|
501
|
+
*/
|
|
502
|
+
autoFocus?: boolean;
|
|
503
|
+
/**
|
|
504
|
+
* This is to set the dropdown class.
|
|
505
|
+
*/
|
|
506
|
+
className?: string;
|
|
507
|
+
/**
|
|
508
|
+
* This is to set the id of the dropdown.
|
|
509
|
+
*/
|
|
510
|
+
id?: string;
|
|
511
|
+
/**
|
|
512
|
+
* This is to enable/disable the dropdown by default.
|
|
513
|
+
*/
|
|
514
|
+
disabled?: boolean;
|
|
515
|
+
/**
|
|
516
|
+
* This is to set the searchable property of the dropdown.
|
|
517
|
+
* If set to true, the user can type the value to search from the available options.
|
|
518
|
+
*/
|
|
519
|
+
isSearchable?: boolean;
|
|
520
|
+
/**
|
|
521
|
+
* This is to specify if multiple options can be selected.
|
|
522
|
+
*/
|
|
523
|
+
isMulti?: boolean;
|
|
524
|
+
/**
|
|
525
|
+
* This is to leave the select menu open upon selection.
|
|
526
|
+
*/
|
|
527
|
+
closeMenuOnSelect?: boolean;
|
|
528
|
+
/**
|
|
529
|
+
* This is to overwrite defaulted styles
|
|
530
|
+
*/
|
|
531
|
+
styles?: Partial<GetStyles<SelectOption$0, true, GroupBase<SelectOption$0>>>;
|
|
532
|
+
/**
|
|
533
|
+
* This is the default text before an option is selected.
|
|
534
|
+
*/
|
|
535
|
+
placeholder?: string;
|
|
536
|
+
value: any[] | string | number;
|
|
537
|
+
}
|
|
538
|
+
/**
|
|
539
|
+
* The select component is used to render a dropdown with options. The user can set a selected option by default.
|
|
540
|
+
* The isSearchable property allows user to find the value from the options available.
|
|
541
|
+
*/
|
|
542
|
+
declare const Select: FC<SelectProps>;
|
|
543
|
+
/**
|
|
544
|
+
* FilterRenderProps are the required props of the renderComponent
|
|
545
|
+
* function of the FilterModule.
|
|
546
|
+
*/
|
|
547
|
+
interface FilterRenderProps<T> {
|
|
548
|
+
name: string;
|
|
549
|
+
value: T;
|
|
550
|
+
update(value: T | null | undefined): void;
|
|
551
|
+
}
|
|
552
|
+
/**
|
|
553
|
+
* FilterPostBody is a map of key/value pairs that's
|
|
554
|
+
* intended to be sent as a JSON post body payload.
|
|
555
|
+
*/
|
|
556
|
+
interface FilterPostBody extends JSONObject {
|
|
557
|
+
}
|
|
558
|
+
/**
|
|
559
|
+
* FilterModule is the minimum expected structure of a filter
|
|
560
|
+
* to be used in the filter system.
|
|
561
|
+
*/
|
|
562
|
+
interface FilterModule<T> {
|
|
563
|
+
/**
|
|
564
|
+
* Text label displayed above the filter input controls.
|
|
565
|
+
*/
|
|
566
|
+
label: string;
|
|
567
|
+
/**
|
|
568
|
+
* Optional paragraph describing the filter (also displayed above the filter input controls).
|
|
569
|
+
*/
|
|
570
|
+
description?: string;
|
|
571
|
+
/**
|
|
572
|
+
* When true, indicates that filter may not be dismissed and must always have a value. defaults to false.
|
|
573
|
+
*/
|
|
574
|
+
required?: boolean;
|
|
575
|
+
/**
|
|
576
|
+
* When true, indicates that UI should not be displayed in left panel for this filter. defaults to false.
|
|
577
|
+
*/
|
|
578
|
+
inputHidden?: boolean;
|
|
579
|
+
/**
|
|
580
|
+
* Gets the number of filter values this filter applies. If not supplied (and filter is not default value),
|
|
581
|
+
* the count will be assumed to be `1`.
|
|
582
|
+
*/
|
|
583
|
+
getFilterCount?(value?: T): number;
|
|
584
|
+
/**
|
|
585
|
+
* Generates filter url query param in API calls (&key=valueString).
|
|
586
|
+
*/
|
|
587
|
+
getApiQueryUrl(key: string, value: T): string;
|
|
588
|
+
/**
|
|
589
|
+
* Generates post body used to apply this filter when used in a POST search request.
|
|
590
|
+
*/
|
|
591
|
+
getApiPostBody(key: string, value: T): FilterPostBody | null | undefined;
|
|
592
|
+
/**
|
|
593
|
+
* Generates the url query param value(s) for saving filter value(s) in the browser address bar (key is automatic).
|
|
594
|
+
* **Note: The output value here can be any valid object
|
|
595
|
+
* of type `Record<string, any>` as it will be stringified in the useFilter hook using the query-string library
|
|
596
|
+
* defaults (https://github.com/sindresorhus/query-string)**.
|
|
597
|
+
*/
|
|
598
|
+
getBrowserQueryUrlValue(value: T): unknown;
|
|
599
|
+
/**
|
|
600
|
+
* Returns filter value that is set when filter is cleared.
|
|
601
|
+
*/
|
|
602
|
+
getDefaultFilterValue(): T | null | undefined;
|
|
603
|
+
/**
|
|
604
|
+
* Returns boolean indicating if the current filter value matches the default value (if true, chip is hidden in the filter bar).
|
|
605
|
+
*/
|
|
606
|
+
isDefaultFilterValue(value: T): boolean;
|
|
607
|
+
/**
|
|
608
|
+
* Generates the string in displayed on this filter's chip in the filter bar.
|
|
609
|
+
*/
|
|
610
|
+
getFilterBarLabel(value: T): string;
|
|
611
|
+
/**
|
|
612
|
+
* Generates the array of labels to be displayed on this filter's section in the filter pane.
|
|
613
|
+
*/
|
|
614
|
+
getFilterSectionLabel(value: T): string | string[];
|
|
615
|
+
/**
|
|
616
|
+
* Parses filter value from browser url query param value(s) and pre-populates the filter value on init.
|
|
617
|
+
*/
|
|
618
|
+
parseInitialFilterValue(browserQueryUrlValue?: string | string[] | null | undefined): T | null | undefined;
|
|
619
|
+
/**
|
|
620
|
+
* Renders the filter input controls in the left filter drawer.
|
|
621
|
+
*/
|
|
622
|
+
renderComponent(input: FilterRenderProps<T>): ReactElement;
|
|
623
|
+
/**
|
|
624
|
+
* Overrides the default FilterSectionHeader for a filter module. Recommended usage is to provide a customized
|
|
625
|
+
* FilterSectionHeader component.
|
|
626
|
+
*/
|
|
627
|
+
renderSectionHeader?(sectionHeaderParams: FilterSectionHeaderProps): ReactElement;
|
|
628
|
+
/**
|
|
629
|
+
* OPTIONAL (support direct JSON input) - extracts/parses the filter value from an API post body.
|
|
630
|
+
* Note: should also delete this filter's key & value from the provided API post body, so that
|
|
631
|
+
* unparsed JSON can be identified and separated into its own pseudo-filter.
|
|
632
|
+
*/
|
|
633
|
+
getFilterValueFromApiPostBody?(key: string, mutableApiPostBody: FilterPostBody | null | undefined): T | null | undefined;
|
|
634
|
+
/**
|
|
635
|
+
* Partially clear a filter when a filter has multiple selected options.
|
|
636
|
+
*/
|
|
637
|
+
clearPartialSingleFilter?(originalValue: T, value: string): T | null | undefined;
|
|
638
|
+
}
|
|
639
|
+
/**
|
|
640
|
+
* FilterSet is the current set of filter names and their
|
|
641
|
+
* associated FilterModule.
|
|
642
|
+
*/
|
|
643
|
+
interface FilterSet {
|
|
644
|
+
[key: string]: FilterModule<any>;
|
|
645
|
+
}
|
|
646
|
+
/**
|
|
647
|
+
* FilterValues is a map of each filter and their current values.
|
|
648
|
+
*/
|
|
649
|
+
interface FilterValues {
|
|
650
|
+
[filterName: string]: any;
|
|
651
|
+
}
|
|
652
|
+
/**
|
|
653
|
+
* FilterHooks is the available values and functions returned from the useFilter hook.
|
|
654
|
+
*/
|
|
655
|
+
interface FilterHooks<T = FilterPostBody> {
|
|
656
|
+
/**
|
|
657
|
+
* The currently available filter set.
|
|
658
|
+
*/
|
|
659
|
+
filters: FilterSet;
|
|
660
|
+
/**
|
|
661
|
+
* The current url state after filters applied.
|
|
662
|
+
*/
|
|
663
|
+
filterUrl: string;
|
|
664
|
+
/**
|
|
665
|
+
* The current post body after filters applied.
|
|
666
|
+
*/
|
|
667
|
+
filterPostBody: T;
|
|
668
|
+
/**
|
|
669
|
+
* The current filter values.
|
|
670
|
+
*/
|
|
671
|
+
filterValues: FilterValues;
|
|
672
|
+
/**
|
|
673
|
+
* The function to update a particular filter.
|
|
674
|
+
*/
|
|
675
|
+
updateFilter(name: string, value: any): void;
|
|
676
|
+
/**
|
|
677
|
+
* The function to reset a particular filter.
|
|
678
|
+
*/
|
|
679
|
+
resetFilter(name: string | string[], value?: any): void;
|
|
680
|
+
/**
|
|
681
|
+
* The function to reset all current filters.
|
|
682
|
+
*/
|
|
683
|
+
resetAllFilters(): void;
|
|
684
|
+
/**
|
|
685
|
+
* The function to determine how filters update the post body.
|
|
686
|
+
*/
|
|
687
|
+
applyApiPostBody(apiPostBody: T): void;
|
|
688
|
+
/**
|
|
689
|
+
* The function sets initial filter preset values.
|
|
690
|
+
*/
|
|
691
|
+
initializePresetValues(presetValues: {
|
|
692
|
+
[key: string]: any;
|
|
693
|
+
}): void;
|
|
694
|
+
}
|
|
695
|
+
/**
|
|
696
|
+
* FilterMap is the mapping of filters as they should
|
|
697
|
+
* be applied to the url and post body.
|
|
698
|
+
*/
|
|
699
|
+
interface FilterMap {
|
|
700
|
+
[key: string]: string;
|
|
701
|
+
}
|
|
702
|
+
interface FilterSectionHeaderProps {
|
|
703
|
+
activeSection?: string;
|
|
704
|
+
filter: FilterModule<any>;
|
|
705
|
+
name: string;
|
|
706
|
+
value: any;
|
|
707
|
+
onClick?: MouseEventHandler<HTMLHeadingElement>;
|
|
708
|
+
resetFilter: (name: string) => void;
|
|
709
|
+
badgeThreshold: number;
|
|
710
|
+
children?: ReactNode;
|
|
711
|
+
}
|
|
712
|
+
/**
|
|
713
|
+
* FilterMode is the list of available states to display
|
|
714
|
+
* the filter UI.
|
|
715
|
+
*/
|
|
716
|
+
declare enum FilterMode {
|
|
717
|
+
FilterUI = "filter",
|
|
718
|
+
JSON = "json"
|
|
719
|
+
}
|
|
720
|
+
/**
|
|
721
|
+
* LocationState is the current state of the location.
|
|
722
|
+
*/
|
|
723
|
+
interface LocationState {
|
|
724
|
+
search: string;
|
|
725
|
+
hash?: string;
|
|
726
|
+
}
|
|
727
|
+
/**
|
|
728
|
+
* Location holds information about the current user location
|
|
729
|
+
* and url state when using the consuming application.
|
|
730
|
+
*/
|
|
731
|
+
interface Location {
|
|
732
|
+
pathname: string;
|
|
733
|
+
search: string;
|
|
734
|
+
state: LocationState;
|
|
735
|
+
hash: string;
|
|
736
|
+
key?: string;
|
|
737
|
+
}
|
|
738
|
+
/**
|
|
739
|
+
* UrlParameters is a map of the current url parameter name and values.
|
|
740
|
+
*/
|
|
741
|
+
interface UrlParameters {
|
|
742
|
+
[key: string]: string[] | string | null;
|
|
743
|
+
}
|
|
744
|
+
/**
|
|
745
|
+
* UpdateHistory is the structure of a history update callback.
|
|
746
|
+
*/
|
|
747
|
+
type UpdateHistory = ({ search, hash }: LocationState) => void;
|
|
748
|
+
/**
|
|
749
|
+
* ContextSwitchMenuValue is the type of possible Context
|
|
750
|
+
* Switch Menu values.
|
|
751
|
+
*/
|
|
752
|
+
type ContextSwitchMenuValue = FilterMode | string;
|
|
753
|
+
/**
|
|
754
|
+
* ContextSwitchMenuProps is the structure of the ContextSwitchMenu
|
|
755
|
+
* component that can be used to toggle Filter component
|
|
756
|
+
* views.
|
|
757
|
+
*/
|
|
758
|
+
interface ContextSwitchMenuProps {
|
|
759
|
+
options: Map<ContextSwitchMenuValue, string>;
|
|
760
|
+
value: ContextSwitchMenuValue;
|
|
761
|
+
onChange?: (filterMode: ContextSwitchMenuValue) => void;
|
|
762
|
+
triggerClassName?: string;
|
|
763
|
+
}
|
|
764
|
+
/**
|
|
765
|
+
* FilterBarProps is the structure of the FilterBar
|
|
766
|
+
* component that can be used to display the applied filters.
|
|
767
|
+
*/
|
|
768
|
+
interface FilterBarProps {
|
|
769
|
+
filters: FilterSet;
|
|
770
|
+
filterValues: FilterValues;
|
|
771
|
+
resetFilter?: (name: string) => void;
|
|
772
|
+
resetAllFilters?: () => void;
|
|
773
|
+
}
|
|
774
|
+
/**
|
|
775
|
+
* FilterJSONConfirmationModalProps is the structure of the
|
|
776
|
+
* FilterJSONConfirmationModal component that can be used to
|
|
777
|
+
* confirm the user has finished making unsaved changes.
|
|
778
|
+
*/
|
|
779
|
+
interface FilterJSONConfirmationModalProps {
|
|
780
|
+
modalVisible: boolean;
|
|
781
|
+
handleModalClose?: () => void;
|
|
782
|
+
onConfirm?: () => void;
|
|
783
|
+
}
|
|
784
|
+
/**
|
|
785
|
+
* FilterJSONInputProps is the structure of the
|
|
786
|
+
* FilterJSONInput component that can be used by
|
|
787
|
+
* the end user to edit the filter JSON parameters and values.
|
|
788
|
+
*/
|
|
789
|
+
interface FilterJSONInputProps {
|
|
790
|
+
filterHooks: FilterHooks;
|
|
791
|
+
onInputModifiedChange?: Dispatch<SetStateAction<boolean>>;
|
|
792
|
+
}
|
|
793
|
+
/**
|
|
794
|
+
* FilterComponentProps is the structure of the expected props
|
|
795
|
+
* to be provided to the primary Filter component.
|
|
796
|
+
*/
|
|
797
|
+
interface FilterComponentProps {
|
|
798
|
+
/**
|
|
799
|
+
* ContextSwitchMenu can be used to toggle Filter component views.
|
|
800
|
+
*/
|
|
801
|
+
ContextSwitchMenu?: FC<ContextSwitchMenuProps>;
|
|
802
|
+
/**
|
|
803
|
+
* FilterBar can be used to display the applied filters.
|
|
804
|
+
*/
|
|
805
|
+
FilterBar?: FC<FilterBarProps>;
|
|
806
|
+
/**
|
|
807
|
+
* FilterJSONConfirmationModal can be used to
|
|
808
|
+
* confirm the user has finished making unsaved changes.
|
|
809
|
+
*/
|
|
810
|
+
FilterJSONConfirmationModal?: FC<FilterJSONConfirmationModalProps>;
|
|
811
|
+
/**
|
|
812
|
+
* FilterJSONInput can be used by
|
|
813
|
+
* the end user to edit the filter JSON parameters and values.
|
|
814
|
+
*/
|
|
815
|
+
FilterJSONInput?: FC<FilterJSONInputProps>;
|
|
816
|
+
/**
|
|
817
|
+
* The children to display at the bottom of the filter container.
|
|
818
|
+
*/
|
|
819
|
+
children?: ReactNode;
|
|
820
|
+
/**
|
|
821
|
+
* Additional query params that can be provided separate from
|
|
822
|
+
* the current filters.
|
|
823
|
+
*/
|
|
824
|
+
additionalQueryParams?: {
|
|
825
|
+
[key: string]: string;
|
|
826
|
+
};
|
|
827
|
+
/**
|
|
828
|
+
* The available values and functions returned from the useFilter hook.
|
|
829
|
+
*/
|
|
830
|
+
filterHooks: FilterHooks;
|
|
831
|
+
/**
|
|
832
|
+
* Controls whether the FilterBar component (if provided)
|
|
833
|
+
* is visible.
|
|
834
|
+
*/
|
|
835
|
+
hideFilterBar?: boolean;
|
|
836
|
+
/**
|
|
837
|
+
* Controls which filter (if any) is expanded by default.
|
|
838
|
+
*/
|
|
839
|
+
initialActiveSection?: string;
|
|
840
|
+
/**
|
|
841
|
+
* Controls whether the filter side panel is expanded or collapsed.
|
|
842
|
+
*/
|
|
843
|
+
isCollapsed?: boolean;
|
|
844
|
+
/**
|
|
845
|
+
* Controls whether the user can add additional filters via a JSON editor.
|
|
846
|
+
*/
|
|
847
|
+
isJSONInputAllowed?: boolean;
|
|
848
|
+
/**
|
|
849
|
+
* The (mutable) location state which gets updated as filters are applied.
|
|
850
|
+
*/
|
|
851
|
+
location: Location;
|
|
852
|
+
/**
|
|
853
|
+
* The callback that runs when the filter pane is collapsed.
|
|
854
|
+
*/
|
|
855
|
+
onToggleCollapsed?(isCollapsed: boolean): void;
|
|
856
|
+
/**
|
|
857
|
+
* This controls how the location/history state is updated
|
|
858
|
+
* as filters change.
|
|
859
|
+
*/
|
|
860
|
+
updateHistory: UpdateHistory;
|
|
861
|
+
/**
|
|
862
|
+
* This is the max number of chips to display before switching to
|
|
863
|
+
* a badge displaying the number of applied filters.
|
|
864
|
+
*/
|
|
865
|
+
badgeThreshold?: number;
|
|
866
|
+
/**
|
|
867
|
+
* The classes to pass to the filter container.
|
|
868
|
+
*/
|
|
869
|
+
className?: string;
|
|
870
|
+
/**
|
|
871
|
+
* This is the mapping for the preset filter dropdown. Each key in this map should match the type of filter passed
|
|
872
|
+
* in the filter set.
|
|
873
|
+
*/
|
|
874
|
+
filterMapping?: {
|
|
875
|
+
[key: string]: any;
|
|
876
|
+
};
|
|
877
|
+
}
|
|
878
|
+
/**
|
|
879
|
+
* FilterContainerProps is the structure of the expected props
|
|
880
|
+
* to be provided to outermost container of the Filter component.
|
|
881
|
+
*/
|
|
882
|
+
interface FilterContainerProps {
|
|
883
|
+
isCollapsed: boolean;
|
|
884
|
+
showJSONInput: boolean;
|
|
885
|
+
hideFilterBar?: boolean;
|
|
886
|
+
}
|
|
887
|
+
/**
|
|
888
|
+
* `AdditionalJSONFilterOptions` is any valid `FilterModule` property
|
|
889
|
+
* meant to override default additional JSON filter behaviour.
|
|
890
|
+
*/
|
|
891
|
+
interface AdditionalJSONFilterOptions extends Partial<FilterModule<JSONObject>> {
|
|
892
|
+
}
|
|
893
|
+
/**
|
|
894
|
+
* `DoubleMultiSelectData` is the definition for each select in the DoubleMultiSelect, such as `firstSelect` and `secondSelect`.
|
|
895
|
+
*/
|
|
896
|
+
interface DoubleMultiSelectData {
|
|
897
|
+
apiField: string;
|
|
898
|
+
label?: string;
|
|
899
|
+
name: string;
|
|
900
|
+
creatable: boolean;
|
|
901
|
+
items: MultiSelectOption[];
|
|
902
|
+
barLabel: string;
|
|
903
|
+
placeholder?: string;
|
|
904
|
+
disableMenu?: boolean;
|
|
905
|
+
}
|
|
906
|
+
/**
|
|
907
|
+
* `DoubleMultiSelectOptions` defines both multi selects in the DoubleMultiSelect component.
|
|
908
|
+
*/
|
|
909
|
+
interface DoubleMultiSelectOptions {
|
|
910
|
+
firstSelect: DoubleMultiSelectData;
|
|
911
|
+
secondSelect: DoubleMultiSelectData;
|
|
912
|
+
}
|
|
913
|
+
/**
|
|
914
|
+
* `DoubleMultiSelectValues` is an object used in the DoubleMultiSelect onChange which contains an array of values
|
|
915
|
+
* stored for each MultiSelect.
|
|
916
|
+
*/
|
|
917
|
+
interface DoubleMultiSelectValues {
|
|
918
|
+
firstSelect: string[];
|
|
919
|
+
secondSelect: string[];
|
|
920
|
+
}
|
|
921
|
+
/**
|
|
922
|
+
* `DoubleMultiSelectFilterProps` defines the props for the DoubleMultiSelectFilter module.
|
|
923
|
+
*/
|
|
924
|
+
interface DoubleMultiSelectFilterProps {
|
|
925
|
+
label: string;
|
|
926
|
+
description?: string;
|
|
927
|
+
selectOptions: DoubleMultiSelectOptions;
|
|
928
|
+
}
|
|
929
|
+
/**
|
|
930
|
+
* `MultiSelectFilterOptions` is any valid `FilterModule` property (excluding description and label)
|
|
931
|
+
* meant to override default multi select filter behaviour.
|
|
932
|
+
*/
|
|
933
|
+
interface DoubleMultiSelectFilterOptions extends Omit<Partial<FilterModule<DoubleMultiSelectValues>>, "label" | "description" | "selectOptions"> {
|
|
934
|
+
}
|
|
935
|
+
/**
|
|
936
|
+
* `ListFilterOverrides` is any valid `FilterModule` property (excluding description and label)
|
|
937
|
+
* meant to override default list filter behaviour.
|
|
938
|
+
*/
|
|
939
|
+
interface ListFilterOverrides extends Omit<Partial<FilterModule<Set<string>>>, "description" | "label"> {
|
|
940
|
+
}
|
|
941
|
+
/**
|
|
942
|
+
* `MultiSelectFilterProps` are the props required to be supplied as the
|
|
943
|
+
* first argument of the MultiSelectFilter component.
|
|
944
|
+
*/
|
|
945
|
+
interface MultiSelectFilterProps {
|
|
946
|
+
options: MultiSelectOption[];
|
|
947
|
+
label: string;
|
|
948
|
+
description?: string;
|
|
949
|
+
initialValue?: any[];
|
|
950
|
+
creatable?: boolean;
|
|
951
|
+
handleCreateItem?: (item: string[]) => void;
|
|
952
|
+
disableMenu?: boolean;
|
|
953
|
+
delimiter?: string;
|
|
954
|
+
}
|
|
955
|
+
/**
|
|
956
|
+
* `MultiSelectFilterOptions` is any valid `FilterModule` property (excluding description and label)
|
|
957
|
+
* meant to override default multi select filter behaviour.
|
|
958
|
+
*/
|
|
959
|
+
interface MultiSelectFilterOptions extends Omit<Partial<FilterModule<string[]>>, "description" | "label"> {
|
|
960
|
+
}
|
|
961
|
+
/**
|
|
962
|
+
* `RadioFilterProps` are the props required to be supplied as the first argument of
|
|
963
|
+
* the RadioFilter component.
|
|
964
|
+
*/
|
|
965
|
+
interface RadioFilterProps {
|
|
966
|
+
initialValue: string;
|
|
967
|
+
defaultValue: string;
|
|
968
|
+
options: {
|
|
969
|
+
label: string;
|
|
970
|
+
value: string;
|
|
971
|
+
}[];
|
|
972
|
+
label: string;
|
|
973
|
+
description?: string;
|
|
974
|
+
}
|
|
975
|
+
/**
|
|
976
|
+
* `RadioFilterOptions` is any valid `FilterModule` property (excluding description and label)
|
|
977
|
+
* meant to override default text filter behaviour.
|
|
978
|
+
*/
|
|
979
|
+
interface RadioFilterOptions extends Omit<Partial<FilterModule<string>>, "description" | "label"> {
|
|
980
|
+
}
|
|
981
|
+
/**
|
|
982
|
+
* `SingleSelectFilterProps` are the props required to be supplied as the
|
|
983
|
+
* first argument of the SingleSelectFilter component.
|
|
984
|
+
*/
|
|
985
|
+
interface SingleSelectFilterProps {
|
|
986
|
+
options: SelectOption$0[];
|
|
987
|
+
label: string;
|
|
988
|
+
description?: string;
|
|
989
|
+
selectPlaceholderLabel?: string;
|
|
990
|
+
filterLabelPrefix?: string;
|
|
991
|
+
initialValue?: string | number;
|
|
992
|
+
required?: boolean;
|
|
993
|
+
}
|
|
994
|
+
/**
|
|
995
|
+
* `SingleSelectFilterOptions` is any valid `FilterModule` property (excluding description, label, and required)
|
|
996
|
+
* meant to override default single select filter behaviour.
|
|
997
|
+
*/
|
|
998
|
+
interface SingleSelectFilterOptions extends Omit<Partial<FilterModule<string>>, "description" | "label" | "required"> {
|
|
999
|
+
}
|
|
1000
|
+
/**
|
|
1001
|
+
* `TextFilterOverrides` is any valid `FilterModule` property (excluding description and label)
|
|
1002
|
+
* meant to override default text filter behaviour.
|
|
1003
|
+
*/
|
|
1004
|
+
interface TextFilterOverrides extends Omit<Partial<FilterModule<string>>, "description" | "label"> {
|
|
1005
|
+
}
|
|
1006
|
+
/**
|
|
1007
|
+
* Filter Component
|
|
1008
|
+
*
|
|
1009
|
+
* The Filter component can be used to display the effects
|
|
1010
|
+
* the `useFilter` hook (or other filter state manager) has on
|
|
1011
|
+
* a given page. Various components can be provided to increase/limit
|
|
1012
|
+
* what changes are displayed.
|
|
1013
|
+
*/
|
|
1014
|
+
declare const Filter: FC<FilterComponentProps>;
|
|
1015
|
+
/**
|
|
1016
|
+
* The useFilter hook is primarily designed to use with the Filter
|
|
1017
|
+
* component, but can be used standalone to maintain filter state.
|
|
1018
|
+
* The state as it applies to the current url and a dynamic api post body
|
|
1019
|
+
* can be updated and/or reset using this hook.
|
|
1020
|
+
*/
|
|
1021
|
+
declare const useFilter: <T extends FilterPostBody>(userFilters: FilterSet, supportJSON: boolean | undefined, location: Location, updateHistory: UpdateHistory) => FilterHooks<T>;
|
|
1022
|
+
/**
|
|
1023
|
+
* Return the filter query string to be appended to API endpoint URL.
|
|
1024
|
+
*/
|
|
1025
|
+
declare const getApiQueryUrl: (filters: FilterSet, filterValues: FilterValues) => string;
|
|
1026
|
+
/**
|
|
1027
|
+
* Return the filter post body to be passed for POST api calls.
|
|
1028
|
+
*/
|
|
1029
|
+
declare const getApiPostBody: <T extends FilterPostBody = {}>(filters: FilterSet, filterValues: FilterValues) => T;
|
|
1030
|
+
/**
|
|
1031
|
+
* Parse filter values from browser url query param values to
|
|
1032
|
+
* pre-populate filter values on init.
|
|
1033
|
+
*/
|
|
1034
|
+
declare const parseInitialFilterValues: (location: Location, filters: FilterSet, presetValues?: {
|
|
1035
|
+
[key: string]: any;
|
|
1036
|
+
} | undefined) => FilterValues;
|
|
1037
|
+
/**
|
|
1038
|
+
* Get current browser query params, optionally excluding the supplied keys.
|
|
1039
|
+
*/
|
|
1040
|
+
declare const getCurrentBrowserQueryParams: (location: Location, excludeKeys?: string[]) => ParsedQuery;
|
|
1041
|
+
/**
|
|
1042
|
+
* Get browser query params to save in browser address bar
|
|
1043
|
+
* using current filter values. **Note: Each filter value can be any valid object
|
|
1044
|
+
* of type `Record<string, any>` as it will be stringified in the useFilter hook using the query-string library
|
|
1045
|
+
* defaults (https://github.com/sindresorhus/query-string)**.
|
|
1046
|
+
*/
|
|
1047
|
+
declare const getFilterBrowserQueryParams: (filters: FilterSet, values: FilterValues) => ParsedQuery;
|
|
1048
|
+
/**
|
|
1049
|
+
* FILTER_MODE_OPTIONS
|
|
1050
|
+
*/
|
|
1051
|
+
declare const FILTER_MODE_OPTIONS: Map<FilterMode, string>;
|
|
1052
|
+
/**
|
|
1053
|
+
* Constant user JSON query parameter.
|
|
1054
|
+
*/
|
|
1055
|
+
declare const USER_JSON_QUERY_PARAM = "userJSON";
|
|
1056
|
+
/**
|
|
1057
|
+
* Returns the default value or fallback value of a requested url parameter.
|
|
1058
|
+
*/
|
|
1059
|
+
declare const getDefaultValue: (urlParams: UrlParameters, key: string, defaultValue: any) => any;
|
|
1060
|
+
/**
|
|
1061
|
+
* Returns the default value of `jsonView` parameter.
|
|
1062
|
+
*/
|
|
1063
|
+
declare const getDefaultJsonViewValue: (urlParams: UrlParameters) => boolean;
|
|
1064
|
+
/**
|
|
1065
|
+
* Gets the count of applied filters.
|
|
1066
|
+
*/
|
|
1067
|
+
declare const getFilterAppliedCount: (filters: FilterSet, filterValues: FilterValues) => number;
|
|
1068
|
+
/**
|
|
1069
|
+
* Given a list (Array or Set) of string, return a query string representation.
|
|
1070
|
+
* Default behavior is that when all items are selected, nothing is returned.
|
|
1071
|
+
*/
|
|
1072
|
+
declare const getUrlFromList: (name: string, list: string[] | Set<string>, count: number, hasInitialValue?: boolean) => string;
|
|
1073
|
+
// compare Set values
|
|
1074
|
+
declare const areSetsEqual: (xs: Set<string>, ys: Set<string>) => boolean;
|
|
1075
|
+
declare const convertToFilterDropdownOptions: (filterMapping?: {
|
|
1076
|
+
[key: string]: any;
|
|
1077
|
+
} | undefined) => SelectOption<string>[];
|
|
1078
|
+
/**
|
|
1079
|
+
* AdditionalJSONFilter Component
|
|
1080
|
+
*
|
|
1081
|
+
* The AdditionalJSONFilter component is a "pseudo" filter used in Filter JSON input to track additional,
|
|
1082
|
+
* user-supplied JSON values which have no equivalent UI filter to represent them.
|
|
1083
|
+
* It acts like any other filter, in that is is able to parse its own value from a query string,
|
|
1084
|
+
* serialize to a query string, and show a filter chip label in the Filter Bar,
|
|
1085
|
+
* but it has (by default) `inputHidden` set to true which causes it to not render any UI in the filter drawer.
|
|
1086
|
+
*
|
|
1087
|
+
* This filter (by default) intentionally does not implement getFilterValueFromApiPostBody, because the useFilter hook
|
|
1088
|
+
* sets this filter's value based on the JSON "leftover" after all the other filters parse their values from JSON.
|
|
1089
|
+
*/
|
|
1090
|
+
declare const AdditionalJSONFilter: (additionalJSONFilterOptions?: AdditionalJSONFilterOptions) => FilterModule<JSONObject>;
|
|
1091
|
+
declare const DoubleMultiSelectFilter: ({ label, description, selectOptions }: DoubleMultiSelectFilterProps, doubleMultiSelectOptions?: DoubleMultiSelectFilterOptions) => FilterModule<DoubleMultiSelectValues>;
|
|
1092
|
+
interface ListFilterOptions {
|
|
1093
|
+
allLabel?: string;
|
|
1094
|
+
initialValue?: string | any[];
|
|
1095
|
+
}
|
|
1096
|
+
/**
|
|
1097
|
+
* ListFilter Component
|
|
1098
|
+
*
|
|
1099
|
+
* The ListFilter component is a checkbox control meant to be used for filtering specific items in a set. While the default
|
|
1100
|
+
* behaviour should suffice, any valid `FilterModule` property (excluding description and label) can
|
|
1101
|
+
* be supplied via the `listFilterOverrides` parameter to change how the filter looks and acts as well as the
|
|
1102
|
+
* `listFilterOptions` to set additional properties related to the list filter itself.
|
|
1103
|
+
*
|
|
1104
|
+
* `label` - The label to display for the text filter component.
|
|
1105
|
+
*
|
|
1106
|
+
* `description` - The description/help text to display above the text filter component.
|
|
1107
|
+
*
|
|
1108
|
+
* `listFilterOptions` - Used to set additional listFilter options such as the allLabel and initialValue.
|
|
1109
|
+
*
|
|
1110
|
+
* `listFilterOverrides` - Any valid `FilterModule` property (excluding description and label)
|
|
1111
|
+
* which will override default text filter behaviour.
|
|
1112
|
+
*/
|
|
1113
|
+
declare const ListFilter: (options: CheckboxGroupOption[], label: string, description?: string, listFilterOptions?: ListFilterOptions, listFilterOverrides?: ListFilterOverrides) => FilterModule<Set<string>>;
|
|
1114
|
+
/**
|
|
1115
|
+
* MultiSelectFilter Component
|
|
1116
|
+
*
|
|
1117
|
+
* The MultiSelectFilter component is a multi select dropdown filter. While the default
|
|
1118
|
+
* behaviour should suffice, any valid `FilterModule` property (excluding description and label) can
|
|
1119
|
+
* be supplied via the `multiSelectFilterOptions` parameter to change how the filter looks and acts.
|
|
1120
|
+
* MultiSelectFilter arguments include:
|
|
1121
|
+
*
|
|
1122
|
+
* `multiSelectFilterProps` - The props required to be supplied as the first argument of
|
|
1123
|
+
* the MultiSelectFilter component. If the *optional* `delimiter` prop is provided, input parsing
|
|
1124
|
+
* will be enabled to allow typing/pasting multiple values seperated by the chosen delimiter.
|
|
1125
|
+
*
|
|
1126
|
+
* `multiSelectFilterOptions` - Any valid `FilterModule` property (excluding description and label)
|
|
1127
|
+
* meant to override default text filter behaviour.
|
|
1128
|
+
*/
|
|
1129
|
+
declare const MultiSelectFilter: ({ options, label, description, initialValue, creatable, disableMenu, handleCreateItem, delimiter }: MultiSelectFilterProps, multiSelectFilterOptions?: MultiSelectFilterOptions) => FilterModule<string[]>;
|
|
1130
|
+
/**
|
|
1131
|
+
* RadioFilter Component
|
|
1132
|
+
*
|
|
1133
|
+
* The RadioFilter component is a filter by use of radio group. While the default
|
|
1134
|
+
* behaviour should suffice, any valid `FilterModule` property (excluding label) can
|
|
1135
|
+
* be supplied via the `radioFilterOptions` parameter to change how the filter looks and acts. RadioFilter
|
|
1136
|
+
* arguments include:
|
|
1137
|
+
*
|
|
1138
|
+
* `radioFilterProps` - The props required to be supplied as the first argument of
|
|
1139
|
+
* the RadioFilter component.
|
|
1140
|
+
*
|
|
1141
|
+
* `radioFilterOptions` - Any valid `FilterModule` property (excluding description and label)
|
|
1142
|
+
* meant to override default text filter behaviour.
|
|
1143
|
+
*/
|
|
1144
|
+
declare const RadioFilter: ({ initialValue, defaultValue, options, label, description }: RadioFilterProps, radioFilterOptions?: RadioFilterOptions) => FilterModule<string | number>;
|
|
1145
|
+
/**
|
|
1146
|
+
* SingleSelectFilter Component
|
|
1147
|
+
*
|
|
1148
|
+
* The SingleSelectFilter component is a single select dropdown filter. While the default
|
|
1149
|
+
* behaviour should suffice, any valid `FilterModule` property (excluding description, label, and required) can
|
|
1150
|
+
* be supplied via the `singleSelectFilterOptions` parameter to change how the filter looks and acts.
|
|
1151
|
+
* SingleSelectFilter arguments include:
|
|
1152
|
+
*
|
|
1153
|
+
* `singleSelectFilterProps` - The props required to be supplied as the first argument of
|
|
1154
|
+
* the SingleSelectFilter component.
|
|
1155
|
+
*
|
|
1156
|
+
* `singleSelectFilterOptions` - Any valid `FilterModule` property (excluding description, label, and required)
|
|
1157
|
+
* meant to override default text filter behaviour.
|
|
1158
|
+
*/
|
|
1159
|
+
declare const SingleSelectFilter: ({ options, label, description, initialValue, selectPlaceholderLabel, filterLabelPrefix, required }: SingleSelectFilterProps, singleSelectFilterOptions?: SingleSelectFilterOptions) => FilterModule<string | number>;
|
|
1160
|
+
interface TextFilterOptions {
|
|
1161
|
+
type?: "text" | "number";
|
|
1162
|
+
}
|
|
1163
|
+
/**
|
|
1164
|
+
* TextFilter Component
|
|
1165
|
+
*
|
|
1166
|
+
* The TextFilter component is a text input control meant to be used as a keyword(s) search. While the default
|
|
1167
|
+
* behaviour should suffice, any valid `FilterModule` property (excluding description and label) can
|
|
1168
|
+
* be supplied via the `textFilterOverrides` parameter to change how the filter looks and acts. TextFilter arguments include:
|
|
1169
|
+
*
|
|
1170
|
+
* `label` - The label to display for the text filter component.
|
|
1171
|
+
*
|
|
1172
|
+
* `description` - The description/help text to display above the text filter component.
|
|
1173
|
+
*
|
|
1174
|
+
* `textFilterOverrides` - Any valid `FilterModule` property (excluding description and label)
|
|
1175
|
+
* which will override default text filter behaviour.
|
|
1176
|
+
*
|
|
1177
|
+
* `textFilterOptions` - Used to set additional textFilter options such as the type of text input.
|
|
1178
|
+
*/
|
|
1179
|
+
declare const TextFilter: (label: string, description?: string, textFilterOverrides?: TextFilterOverrides, textFilterOptions?: TextFilterOptions) => FilterModule<string>;
|
|
1180
|
+
interface MinMax {
|
|
1181
|
+
min?: number;
|
|
1182
|
+
max?: number;
|
|
1183
|
+
}
|
|
1184
|
+
interface MinMaxInputProps {
|
|
1185
|
+
value: MinMax | null;
|
|
1186
|
+
onChange(value: MinMax | null): void;
|
|
1187
|
+
allowNegativeInput: boolean;
|
|
1188
|
+
}
|
|
1189
|
+
declare const MinMaxInput: FC<MinMaxInputProps>;
|
|
1190
|
+
interface DurationFilterProps {
|
|
1191
|
+
label: string;
|
|
1192
|
+
description?: string;
|
|
1193
|
+
}
|
|
1194
|
+
declare const DurationFilter: ({ label, description }: DurationFilterProps) => FilterModule<MinMax>;
|
|
1195
|
+
interface MinMaxFilterProps {
|
|
1196
|
+
label: string;
|
|
1197
|
+
description?: string;
|
|
1198
|
+
unitsOfMeasurement?: string;
|
|
1199
|
+
}
|
|
1200
|
+
declare const MinMaxFilter: ({ label, description, unitsOfMeasurement }: MinMaxFilterProps) => FilterModule<MinMax>;
|
|
1201
|
+
interface HeaderProps {
|
|
1202
|
+
/**
|
|
1203
|
+
* Children to display within header container.
|
|
1204
|
+
*/
|
|
1205
|
+
children?: ReactNode;
|
|
1206
|
+
/**
|
|
1207
|
+
* The classes to pass to the header.
|
|
1208
|
+
*/
|
|
1209
|
+
className?: string;
|
|
1210
|
+
}
|
|
1211
|
+
/**
|
|
1212
|
+
* Header Component
|
|
1213
|
+
*
|
|
1214
|
+
* The Header component is used to render the header.
|
|
1215
|
+
*/
|
|
1216
|
+
declare const Header: FC<HeaderProps>;
|
|
1217
|
+
/**
|
|
1218
|
+
* Icon Component
|
|
1219
|
+
*
|
|
1220
|
+
* The Icon component takes icon and iconPosition.
|
|
1221
|
+
* The icon will be displayed along side any provided children.
|
|
1222
|
+
* The iconPosition, determines if the icon precedes or proceeds the provided children.
|
|
1223
|
+
*
|
|
1224
|
+
*/
|
|
1225
|
+
declare const IconButton: FC<IconComponentProps>;
|
|
1226
|
+
interface InputProps {
|
|
1227
|
+
/**
|
|
1228
|
+
* This shows a label above the input when provided.
|
|
1229
|
+
*/
|
|
1230
|
+
label?: string;
|
|
1231
|
+
/**
|
|
1232
|
+
* If not empty, the input component will be displayed in an error state with the provided error message.
|
|
1233
|
+
*/
|
|
1234
|
+
error?: string;
|
|
1235
|
+
/**
|
|
1236
|
+
* If required is provided, the label of the input component will be displayed with a red asterisk at its end.
|
|
1237
|
+
*/
|
|
1238
|
+
required?: boolean;
|
|
1239
|
+
/**
|
|
1240
|
+
* The classes to pass to the input.
|
|
1241
|
+
*/
|
|
1242
|
+
className?: string;
|
|
1243
|
+
/**
|
|
1244
|
+
* The classes to pass to the input label.
|
|
1245
|
+
*/
|
|
1246
|
+
labelClassName?: string;
|
|
1247
|
+
}
|
|
1248
|
+
/**
|
|
1249
|
+
* Input Component
|
|
1250
|
+
*
|
|
1251
|
+
* The Input component takes in native input props as well as its own InputProps. The state is not managed
|
|
1252
|
+
* in this component and should be handled in the consuming app.
|
|
1253
|
+
*
|
|
1254
|
+
*/
|
|
1255
|
+
declare const Input: FC<InputProps & ComponentPropsWithRef<"input">>;
|
|
1256
|
+
interface ItemGridProps {
|
|
1257
|
+
/**
|
|
1258
|
+
* The children to render inside the grid container.
|
|
1259
|
+
*/
|
|
1260
|
+
children?: ReactNode;
|
|
1261
|
+
/**
|
|
1262
|
+
* This is the max number of columns that populates in a row.
|
|
1263
|
+
*/
|
|
1264
|
+
maxColumns: number;
|
|
1265
|
+
/**
|
|
1266
|
+
* This is to set the minimum width for each column.
|
|
1267
|
+
*/
|
|
1268
|
+
columnWidthMin?: string;
|
|
1269
|
+
/**
|
|
1270
|
+
* This to set the gap between rows and columns.
|
|
1271
|
+
*/
|
|
1272
|
+
gridGap?: {
|
|
1273
|
+
rowGap?: number;
|
|
1274
|
+
columnGap?: number;
|
|
1275
|
+
};
|
|
1276
|
+
/**
|
|
1277
|
+
* This would recalculate the size if set to true.
|
|
1278
|
+
*/
|
|
1279
|
+
shouldRecalculateSize?: boolean;
|
|
1280
|
+
/**
|
|
1281
|
+
* This is to set the inner width.
|
|
1282
|
+
*/
|
|
1283
|
+
innerWidth?: number;
|
|
1284
|
+
/**
|
|
1285
|
+
* The classes to pass to the item grid.
|
|
1286
|
+
*/
|
|
1287
|
+
className?: string;
|
|
1288
|
+
}
|
|
1289
|
+
/**
|
|
1290
|
+
* Item Grid Component
|
|
1291
|
+
*
|
|
1292
|
+
* This component is used to display the items in a grid. The component takes initial props like the maximum columns
|
|
1293
|
+
* that needs to be displayed in each row, sets the minimum width for each column and the grid gap between rows and columns.
|
|
1294
|
+
*/
|
|
1295
|
+
declare const ItemGrid: React.FC<ItemGridProps>;
|
|
1296
|
+
interface ItemResultsProps {
|
|
1297
|
+
/**
|
|
1298
|
+
* The current number of data elements being displayed.
|
|
1299
|
+
*/
|
|
1300
|
+
dataLength: number;
|
|
1301
|
+
/**
|
|
1302
|
+
* The total number of data elements.
|
|
1303
|
+
*/
|
|
1304
|
+
totalItems: number;
|
|
1305
|
+
/**
|
|
1306
|
+
* The classes to pass to the item results.
|
|
1307
|
+
*/
|
|
1308
|
+
className?: string;
|
|
1309
|
+
}
|
|
1310
|
+
declare const ItemResults: React.FC<ItemResultsProps>;
|
|
1311
|
+
interface LoadingProps {
|
|
1312
|
+
/**
|
|
1313
|
+
* Determines if the component should rotate.
|
|
1314
|
+
*/
|
|
1315
|
+
animated?: boolean;
|
|
1316
|
+
/**
|
|
1317
|
+
* The direction of the default animation.
|
|
1318
|
+
*/
|
|
1319
|
+
spinDirection?: "LEFT" | "RIGHT";
|
|
1320
|
+
/**
|
|
1321
|
+
* Label position in relation to the SVG.
|
|
1322
|
+
*/
|
|
1323
|
+
labelPosition?: "BOTTOM" | "RIGHT";
|
|
1324
|
+
/**
|
|
1325
|
+
* The text or element that shows next to the svg.
|
|
1326
|
+
*/
|
|
1327
|
+
label?: string | ReactElement;
|
|
1328
|
+
/**
|
|
1329
|
+
* The height of the loading image.
|
|
1330
|
+
*/
|
|
1331
|
+
height?: number;
|
|
1332
|
+
/**
|
|
1333
|
+
* The width of the loading image.
|
|
1334
|
+
*/
|
|
1335
|
+
width?: number;
|
|
1336
|
+
/**
|
|
1337
|
+
* The SVG image to be shown when loading.
|
|
1338
|
+
*/
|
|
1339
|
+
svg?: ElementType;
|
|
1340
|
+
/**
|
|
1341
|
+
* The icon variant to display if svg isn't provided.
|
|
1342
|
+
*/
|
|
1343
|
+
iconVariant?: string;
|
|
1344
|
+
/**
|
|
1345
|
+
* Additional styles.
|
|
1346
|
+
*/
|
|
1347
|
+
className?: string;
|
|
1348
|
+
}
|
|
1349
|
+
declare const Loading: FC<LoadingProps>;
|
|
1350
|
+
interface ImageTagProps {
|
|
1351
|
+
id: number;
|
|
1352
|
+
name: string;
|
|
1353
|
+
model: string;
|
|
1354
|
+
display_name: string;
|
|
1355
|
+
detector: string;
|
|
1356
|
+
bounding_box: {
|
|
1357
|
+
top_left_x: number;
|
|
1358
|
+
top_left_y: number;
|
|
1359
|
+
bottom_right_x: number;
|
|
1360
|
+
bottom_right_y: number;
|
|
1361
|
+
confidence: number;
|
|
1362
|
+
};
|
|
1363
|
+
items: {
|
|
1364
|
+
confidence: number;
|
|
1365
|
+
bbox: number[][];
|
|
1366
|
+
}[];
|
|
1367
|
+
color: string;
|
|
1368
|
+
}
|
|
1369
|
+
interface MaskableImageProps {
|
|
1370
|
+
/**
|
|
1371
|
+
* The url to set the image source.
|
|
1372
|
+
*/
|
|
1373
|
+
url: string;
|
|
1374
|
+
/**
|
|
1375
|
+
* This is to set the full size dimension of the image.
|
|
1376
|
+
*/
|
|
1377
|
+
fullSizeDimensions: {
|
|
1378
|
+
height: number;
|
|
1379
|
+
width: number;
|
|
1380
|
+
};
|
|
1381
|
+
/**
|
|
1382
|
+
* This is to set the alternate text of the image.
|
|
1383
|
+
*/
|
|
1384
|
+
alt?: string;
|
|
1385
|
+
/**
|
|
1386
|
+
* This will enable or disable the selection of the image when check icon is clicked.
|
|
1387
|
+
*/
|
|
1388
|
+
selectable?: boolean;
|
|
1389
|
+
/**
|
|
1390
|
+
* This will set the selection of the image by default.
|
|
1391
|
+
*/
|
|
1392
|
+
selected?: boolean;
|
|
1393
|
+
/**
|
|
1394
|
+
* This is an event that would be called when the image is selected.
|
|
1395
|
+
*/
|
|
1396
|
+
onSelect?(selected: boolean): void;
|
|
1397
|
+
/**
|
|
1398
|
+
* This is to set the default property that would highlight the image.
|
|
1399
|
+
*/
|
|
1400
|
+
highlighted?: boolean;
|
|
1401
|
+
/**
|
|
1402
|
+
* This is to set the bounding box tags.
|
|
1403
|
+
*/
|
|
1404
|
+
boundingBoxTags?: ImageTagProps[];
|
|
1405
|
+
/**
|
|
1406
|
+
* This will set the show spinner property bey default.
|
|
1407
|
+
*/
|
|
1408
|
+
showSpinner?: boolean;
|
|
1409
|
+
/**
|
|
1410
|
+
* If set to true,This will show spinner when the image is still loading.
|
|
1411
|
+
*/
|
|
1412
|
+
showSpinnerOnLoad?: boolean;
|
|
1413
|
+
/**
|
|
1414
|
+
* This will add the class to the image component.
|
|
1415
|
+
*/
|
|
1416
|
+
className?: string;
|
|
1417
|
+
/**
|
|
1418
|
+
* This will specify the heightToWidthRatio of the image.
|
|
1419
|
+
*/
|
|
1420
|
+
heightToWidthRatio?: number;
|
|
1421
|
+
/**
|
|
1422
|
+
* This is to set the inner width of the image.
|
|
1423
|
+
*/
|
|
1424
|
+
innerWidth?: number;
|
|
1425
|
+
}
|
|
1426
|
+
/**
|
|
1427
|
+
* Maskable Image Component
|
|
1428
|
+
*
|
|
1429
|
+
* This Component is used to render an image. The image can be selected and highlighted. The showSpinnerOnLoad when set
|
|
1430
|
+
* to true will show the loading spinner until the image is loaded.
|
|
1431
|
+
*/
|
|
1432
|
+
declare const MaskableImage: FC<MaskableImageProps>;
|
|
1433
|
+
interface ModalProps {
|
|
1434
|
+
/**
|
|
1435
|
+
* The action to run when close of the modal is triggered
|
|
1436
|
+
* (either by the close button, cancel button, or clicking
|
|
1437
|
+
* an area outside the modal dialog).
|
|
1438
|
+
*/
|
|
1439
|
+
handleClose?: () => void;
|
|
1440
|
+
/**
|
|
1441
|
+
* The action to run when backdrop click is triggered
|
|
1442
|
+
* by clicking on an area outside the modal dialog.
|
|
1443
|
+
*/
|
|
1444
|
+
handleBackdropClick?: () => void;
|
|
1445
|
+
/**
|
|
1446
|
+
* The boolean value to determine if the modal is visible or not.
|
|
1447
|
+
*/
|
|
1448
|
+
isOpen: boolean;
|
|
1449
|
+
/**
|
|
1450
|
+
* The header text to display on the modal.
|
|
1451
|
+
* This defaults to an empty string.
|
|
1452
|
+
*/
|
|
1453
|
+
headerText?: string;
|
|
1454
|
+
/**
|
|
1455
|
+
* The text to display beneath the header text on the modal.
|
|
1456
|
+
* This defaults to an empty string.
|
|
1457
|
+
*/
|
|
1458
|
+
subHeaderText?: string;
|
|
1459
|
+
/**
|
|
1460
|
+
* The boolean value to determine whether the close icon
|
|
1461
|
+
* is visible or not. This defaults to `true`.
|
|
1462
|
+
*/
|
|
1463
|
+
isCloseIconVisible?: boolean;
|
|
1464
|
+
/**
|
|
1465
|
+
* The primary submit/action button on the modal.
|
|
1466
|
+
*/
|
|
1467
|
+
actionButton?: ReactNode;
|
|
1468
|
+
/**
|
|
1469
|
+
* The cancel button text. This defaults to `Cancel`.
|
|
1470
|
+
*/
|
|
1471
|
+
cancelButtonText?: string;
|
|
1472
|
+
/**
|
|
1473
|
+
* Any valid React child.
|
|
1474
|
+
*/
|
|
1475
|
+
children?: ReactNode;
|
|
1476
|
+
/**
|
|
1477
|
+
* The boolean value to determine whether a top divider shows
|
|
1478
|
+
* between the header and the dialog main body.
|
|
1479
|
+
*/
|
|
1480
|
+
showTopDivider?: boolean;
|
|
1481
|
+
/**
|
|
1482
|
+
* The boolean value to determine whether a bottom divider shows
|
|
1483
|
+
* between the dialog main body and the action and cancel buttons.
|
|
1484
|
+
*/
|
|
1485
|
+
showBottomDivider?: boolean;
|
|
1486
|
+
/**
|
|
1487
|
+
* The max-width of the dialog area. This width grows with the size
|
|
1488
|
+
* of the screen. Setting to `false` will disable `maxWidth`.
|
|
1489
|
+
*/
|
|
1490
|
+
dialogWidth?: false | "xs" | "sm" | "md" | "lg" | "xl";
|
|
1491
|
+
/**
|
|
1492
|
+
* This is the id to assign to the appended div when rendering in a portal.
|
|
1493
|
+
* This defaults to `lakefront-portal-container`.
|
|
1494
|
+
*/
|
|
1495
|
+
portalId?: string;
|
|
1496
|
+
/**
|
|
1497
|
+
* When true, the component will mount a div to the body and render the dialog through it.
|
|
1498
|
+
* This is useful when the dialog would be inside a scrollable container or one with "overflow: hidden"
|
|
1499
|
+
* so it doesn't get cut off. Uses IntersectionObserver and needs a polyfill if IE compatibility is needed. This
|
|
1500
|
+
* defaults to `false`.
|
|
1501
|
+
*/
|
|
1502
|
+
renderInPortal?: boolean;
|
|
1503
|
+
/**
|
|
1504
|
+
* The classes to pass to the modal.
|
|
1505
|
+
*/
|
|
1506
|
+
className?: string;
|
|
1507
|
+
}
|
|
1508
|
+
/**
|
|
1509
|
+
* Modal Component
|
|
1510
|
+
*
|
|
1511
|
+
* The Modal component is a UI blocking dialog overlay.
|
|
1512
|
+
* The state is not managed inside this component and visibility (via the `isOpen` prop) needs to be maintained in the
|
|
1513
|
+
* parent component. While the default rendering behavior is often sufficient, the `renderInPortal` prop can be used to
|
|
1514
|
+
* append a div to the body.
|
|
1515
|
+
*
|
|
1516
|
+
*/
|
|
1517
|
+
declare const Modal: FC<ModalProps>;
|
|
1518
|
+
interface ConfirmationModalProps {
|
|
1519
|
+
/**
|
|
1520
|
+
* The boolean value to determine if the modal is visible or not.
|
|
1521
|
+
*/
|
|
1522
|
+
modalVisible: boolean;
|
|
1523
|
+
/**
|
|
1524
|
+
* The title of the modal.
|
|
1525
|
+
*/
|
|
1526
|
+
title?: string;
|
|
1527
|
+
/**
|
|
1528
|
+
* The text or content to display in the main body of the modal.
|
|
1529
|
+
*/
|
|
1530
|
+
message: string | ReactElement;
|
|
1531
|
+
/**
|
|
1532
|
+
* The yes/accept button text. This defaults to `Yes`.
|
|
1533
|
+
*/
|
|
1534
|
+
yes?: string;
|
|
1535
|
+
/**
|
|
1536
|
+
* The no/decline button text. This defaults to `No`.
|
|
1537
|
+
*/
|
|
1538
|
+
no?: string;
|
|
1539
|
+
/**
|
|
1540
|
+
* The action to run when yes/accept action is triggered.
|
|
1541
|
+
*/
|
|
1542
|
+
onYes: () => void;
|
|
1543
|
+
/**
|
|
1544
|
+
* The action to run when no/decline action is triggered.
|
|
1545
|
+
*/
|
|
1546
|
+
onNo: () => void;
|
|
1547
|
+
/**
|
|
1548
|
+
* The classes to pass to the modal.
|
|
1549
|
+
*/
|
|
1550
|
+
className?: string;
|
|
1551
|
+
/**
|
|
1552
|
+
* When true, the component will mount a div to the body and render the dialog through it.
|
|
1553
|
+
* This is useful when the dialog would be inside a scrollable container or one with "overflow: hidden"
|
|
1554
|
+
* so it doesn't get cut off. Uses IntersectionObserver and needs a polyfill if IE compatibility is needed. This
|
|
1555
|
+
* defaults to `false`.
|
|
1556
|
+
*/
|
|
1557
|
+
renderInPortal?: boolean;
|
|
1558
|
+
}
|
|
1559
|
+
/**
|
|
1560
|
+
* Confirmation Modal Component
|
|
1561
|
+
*
|
|
1562
|
+
* The Confirmation modal component is a UI blocking dialog meant to handle yes/no responses.
|
|
1563
|
+
* The state is not managed inside this component and visibility (via the `modalVisible` prop) needs to be maintained in the parent component.
|
|
1564
|
+
* While the default rendering behavior is often sufficient, the `renderInPortal` prop can be used
|
|
1565
|
+
* to append a div to the body.
|
|
1566
|
+
*
|
|
1567
|
+
*/
|
|
1568
|
+
declare const ConfirmationModal: FC<ConfirmationModalProps>;
|
|
1569
|
+
interface ModeSelectorLegendRowProps {
|
|
1570
|
+
label: string;
|
|
1571
|
+
color: string;
|
|
1572
|
+
}
|
|
1573
|
+
interface ModeSelectorProps {
|
|
1574
|
+
/**
|
|
1575
|
+
* The title of the mode selector.
|
|
1576
|
+
*/
|
|
1577
|
+
title?: string;
|
|
1578
|
+
/**
|
|
1579
|
+
* The classes to pass to the mode selector.
|
|
1580
|
+
*/
|
|
1581
|
+
className?: string;
|
|
1582
|
+
/**
|
|
1583
|
+
* The classes to pass to the select drop-down.
|
|
1584
|
+
*/
|
|
1585
|
+
selectClassName?: string;
|
|
1586
|
+
/**
|
|
1587
|
+
* The list of modes to include in the drop-down.
|
|
1588
|
+
*/
|
|
1589
|
+
modes: SelectOption<string>[];
|
|
1590
|
+
/**
|
|
1591
|
+
* The selected mode to display on the drop-down.
|
|
1592
|
+
*/
|
|
1593
|
+
selectedMode: string;
|
|
1594
|
+
/**
|
|
1595
|
+
* The legend symbol colors and labels.
|
|
1596
|
+
*/
|
|
1597
|
+
legend?: ModeSelectorLegendRowProps[];
|
|
1598
|
+
/**
|
|
1599
|
+
* The action to take on the selected mode value.
|
|
1600
|
+
*/
|
|
1601
|
+
onModeSelect: (mode: string) => void;
|
|
1602
|
+
}
|
|
1603
|
+
/**
|
|
1604
|
+
*
|
|
1605
|
+
* ModeSelector Component
|
|
1606
|
+
*
|
|
1607
|
+
* The ModeSelector component is intended to be used as a quick mode/context selection
|
|
1608
|
+
* panel. The state is not managed inside this component (i.e. to be received by the parent).
|
|
1609
|
+
* For this reason, `selectedMode`, `modes`, and `onModeSelect` must be provided.
|
|
1610
|
+
*/
|
|
1611
|
+
declare const ModeSelector: FC<ModeSelectorProps>;
|
|
1612
|
+
interface PageProps {
|
|
1613
|
+
/**
|
|
1614
|
+
* The children to display within the styled page container.
|
|
1615
|
+
*/
|
|
1616
|
+
children?: ReactNode;
|
|
1617
|
+
/**
|
|
1618
|
+
* These are the classes that would be applied to the Page component.
|
|
1619
|
+
*/
|
|
1620
|
+
className?: string;
|
|
1621
|
+
}
|
|
1622
|
+
/**
|
|
1623
|
+
* Page Component
|
|
1624
|
+
*
|
|
1625
|
+
* The Page Component can be used to render other child components.
|
|
1626
|
+
*/
|
|
1627
|
+
declare const Page: FC<PageProps>;
|
|
1628
|
+
/**
|
|
1629
|
+
* This is the structure for Highlights.
|
|
1630
|
+
*/
|
|
1631
|
+
interface HighlightsProp {
|
|
1632
|
+
start: number;
|
|
1633
|
+
end: number;
|
|
1634
|
+
playback: boolean;
|
|
1635
|
+
}
|
|
1636
|
+
interface PlaybackBarProps {
|
|
1637
|
+
/**
|
|
1638
|
+
* This is to display the current duration of the playback component.
|
|
1639
|
+
*/
|
|
1640
|
+
currentDuration: string;
|
|
1641
|
+
/**
|
|
1642
|
+
* This is to display the end duration of the playback component.
|
|
1643
|
+
*/
|
|
1644
|
+
endDuration: string;
|
|
1645
|
+
/**
|
|
1646
|
+
* This is to set the slider position on initial render of the playback component.
|
|
1647
|
+
*/
|
|
1648
|
+
currentSlider: number;
|
|
1649
|
+
/**
|
|
1650
|
+
* This is to set the max value of the playback component.
|
|
1651
|
+
*/
|
|
1652
|
+
maxSlider: number;
|
|
1653
|
+
/**
|
|
1654
|
+
* This function is called when the slider is moved.
|
|
1655
|
+
*/
|
|
1656
|
+
setSlider(index: number): void;
|
|
1657
|
+
/**
|
|
1658
|
+
* This is to highlight a particular section of the playback component in green.
|
|
1659
|
+
*/
|
|
1660
|
+
highlights: HighlightsProp[];
|
|
1661
|
+
/**
|
|
1662
|
+
* The classes to pass to the playback bar.
|
|
1663
|
+
*/
|
|
1664
|
+
className?: string;
|
|
1665
|
+
}
|
|
1666
|
+
/**
|
|
1667
|
+
* The Playback Component renders a slider.
|
|
1668
|
+
* The highlights property is an array and each item in an array has start,end and playback.
|
|
1669
|
+
* The Playback component is highlighted depending on the start and end value.
|
|
1670
|
+
* You can have multiple highlights in one single playback component.
|
|
1671
|
+
* The slider can be moved between the start point and the end point depending upon the playback property.
|
|
1672
|
+
* The playback property determines whether the slider can be moved freely or whether it is constrained to the highlighted areas.
|
|
1673
|
+
*/
|
|
1674
|
+
declare const PlaybackBar: FC<PlaybackBarProps>;
|
|
1675
|
+
interface PortalStyles {
|
|
1676
|
+
className?: string;
|
|
1677
|
+
styles?: Partial<CSSStyleDeclaration>;
|
|
1678
|
+
}
|
|
1679
|
+
interface UsePopoverProps {
|
|
1680
|
+
/**
|
|
1681
|
+
* This is the container where the popover will reside
|
|
1682
|
+
* or must confirm exists (when rendering in a portal).
|
|
1683
|
+
*/
|
|
1684
|
+
popoverContainer: HTMLElement | null;
|
|
1685
|
+
/**
|
|
1686
|
+
* This is the id to assign to the appended div when rendering in a portal.
|
|
1687
|
+
* This defaults to `lakefront-portal-container`.
|
|
1688
|
+
*/
|
|
1689
|
+
portalId?: string;
|
|
1690
|
+
/**
|
|
1691
|
+
* This is the className and styles to apply to the portal. This is useful for setting
|
|
1692
|
+
* styles since the portal will render outside the majority of your css scope.
|
|
1693
|
+
*/
|
|
1694
|
+
portalStyles?: PortalStyles;
|
|
1695
|
+
/**
|
|
1696
|
+
* When true, a div will be appended to the body in order to render the desired content through it.
|
|
1697
|
+
* This is useful when the content would be inside a scrollable container or one with "overflow: hidden"
|
|
1698
|
+
* so it doesn't get cut off. It uses IntersectionObserver and needs a polyfill if IE compatibility is needed. This
|
|
1699
|
+
* defaults to `false`.
|
|
1700
|
+
*/
|
|
1701
|
+
renderInPortal?: boolean;
|
|
1702
|
+
}
|
|
1703
|
+
interface UsePopoverResult {
|
|
1704
|
+
portal: HTMLElement | null;
|
|
1705
|
+
update: number;
|
|
1706
|
+
}
|
|
1707
|
+
declare const usePopover: ({ popoverContainer, portalId, portalStyles, renderInPortal }: UsePopoverProps) => UsePopoverResult;
|
|
1708
|
+
interface PopoverContentProps {
|
|
1709
|
+
/**
|
|
1710
|
+
* This is the (portal/outside) container to render content in. If null,
|
|
1711
|
+
* content will be rendered in the closest parent node.
|
|
1712
|
+
*/
|
|
1713
|
+
portal: HTMLElement | null;
|
|
1714
|
+
/**
|
|
1715
|
+
* When provided, these children will be memoized and render as the content.
|
|
1716
|
+
*/
|
|
1717
|
+
children?: ReactNode;
|
|
1718
|
+
/**
|
|
1719
|
+
* This is an array of dependency values to check when determining
|
|
1720
|
+
* if the memoized content should be recalculated. If none of the values
|
|
1721
|
+
* in the dependency list have changed, the content will appear as it did
|
|
1722
|
+
* in the last render.
|
|
1723
|
+
*/
|
|
1724
|
+
deps: any[];
|
|
1725
|
+
}
|
|
1726
|
+
/**
|
|
1727
|
+
* Popover Content Component
|
|
1728
|
+
*
|
|
1729
|
+
* The PopoverContent component is a support component to the `usePopover` hook.
|
|
1730
|
+
* It is meant to handle the memoization of content to be rendered and logically
|
|
1731
|
+
* switch between rendering content within or outside a portal as needed. Under the hood,
|
|
1732
|
+
* all Lakefront popover components (Modal, Snackbar, et. al) utilize this component. View
|
|
1733
|
+
* the [PopoverContent stories source code](https://github.com/woven-planet/lakefront/blob/main/src/stories/PopoverContent/PopoverContent.stories.tsx)
|
|
1734
|
+
* for a more detailed look on how to implement.
|
|
1735
|
+
*/
|
|
1736
|
+
declare const PopoverContent: FC<PopoverContentProps>;
|
|
1737
|
+
interface ProgressBarProps {
|
|
1738
|
+
/**
|
|
1739
|
+
* This is to set the total of the progress bar.
|
|
1740
|
+
*/
|
|
1741
|
+
total: number;
|
|
1742
|
+
/**
|
|
1743
|
+
* This is to set the width of the progress bar.
|
|
1744
|
+
*/
|
|
1745
|
+
width: number;
|
|
1746
|
+
/**
|
|
1747
|
+
* The data that is passed to the Progress Bar Component to render the bar width of each label depending on the value.
|
|
1748
|
+
*/
|
|
1749
|
+
data: {
|
|
1750
|
+
label: string;
|
|
1751
|
+
value: number;
|
|
1752
|
+
}[];
|
|
1753
|
+
/**
|
|
1754
|
+
* This is to render the background color for each label that is being passed.
|
|
1755
|
+
*/
|
|
1756
|
+
theme: {
|
|
1757
|
+
[key: string]: {
|
|
1758
|
+
bgColor: string;
|
|
1759
|
+
fgColor: string;
|
|
1760
|
+
};
|
|
1761
|
+
};
|
|
1762
|
+
/**
|
|
1763
|
+
* The classes to pass to the progress bar.
|
|
1764
|
+
*/
|
|
1765
|
+
className?: string;
|
|
1766
|
+
}
|
|
1767
|
+
/**
|
|
1768
|
+
* Progress Bar Component
|
|
1769
|
+
*
|
|
1770
|
+
* The Progress Bar Component is used to render the bar. The bar displays each section in a given color and the width
|
|
1771
|
+
* of each section is calculated according to the value provide.
|
|
1772
|
+
*/
|
|
1773
|
+
declare const ProgressBar: React.FC<ProgressBarProps>;
|
|
1774
|
+
interface CircularProgressProps {
|
|
1775
|
+
/**
|
|
1776
|
+
* This is to set the width of the pie chart.
|
|
1777
|
+
*/
|
|
1778
|
+
width: number;
|
|
1779
|
+
/**
|
|
1780
|
+
* This is to set the text that would appear inside the pie chart.
|
|
1781
|
+
*/
|
|
1782
|
+
text?: ReactNode;
|
|
1783
|
+
/**
|
|
1784
|
+
* The data that is passed to the Circular Progress Component to render different arcs for each value provided.
|
|
1785
|
+
*/
|
|
1786
|
+
data: {
|
|
1787
|
+
label: string;
|
|
1788
|
+
value: number;
|
|
1789
|
+
tooltip?: boolean;
|
|
1790
|
+
key?: string;
|
|
1791
|
+
}[];
|
|
1792
|
+
/**
|
|
1793
|
+
* This is to render the background color for each label that is being passed.
|
|
1794
|
+
*/
|
|
1795
|
+
theme: {
|
|
1796
|
+
[key: string]: {
|
|
1797
|
+
bgColor: string;
|
|
1798
|
+
fgColor: string;
|
|
1799
|
+
};
|
|
1800
|
+
};
|
|
1801
|
+
/**
|
|
1802
|
+
* The classes to pass to the circular progress.
|
|
1803
|
+
*/
|
|
1804
|
+
className?: string;
|
|
1805
|
+
}
|
|
1806
|
+
/**
|
|
1807
|
+
* Circular Progress Component
|
|
1808
|
+
*
|
|
1809
|
+
* The Circular Progress component is used to render the arcs depending on the value provided for each label.
|
|
1810
|
+
*/
|
|
1811
|
+
declare const CircularProgress: FC<CircularProgressProps>;
|
|
1812
|
+
interface DeviceProgressBarThreshold {
|
|
1813
|
+
/**
|
|
1814
|
+
* The unique id of the threshold.
|
|
1815
|
+
*/
|
|
1816
|
+
id: string;
|
|
1817
|
+
/**
|
|
1818
|
+
* The percentage at which the threshold exists.
|
|
1819
|
+
* This should be a string percentage (e.g. 10%) to accurately
|
|
1820
|
+
* generate the width of the progress (via css).
|
|
1821
|
+
*/
|
|
1822
|
+
percentage: string;
|
|
1823
|
+
/**
|
|
1824
|
+
* The color of the threshold. This defaults to `lakefrontColors.red` if left undefined.
|
|
1825
|
+
*/
|
|
1826
|
+
color?: string;
|
|
1827
|
+
}
|
|
1828
|
+
interface DeviceProgressProps {
|
|
1829
|
+
/**
|
|
1830
|
+
* This is to set the used space of the device. The type should be a number.
|
|
1831
|
+
*/
|
|
1832
|
+
used: number;
|
|
1833
|
+
/**
|
|
1834
|
+
* This is to set the available space of the device. The type should be a number.
|
|
1835
|
+
*/
|
|
1836
|
+
available: number;
|
|
1837
|
+
/**
|
|
1838
|
+
* This is to set the total space of the device. The type should be a number.
|
|
1839
|
+
*/
|
|
1840
|
+
total: number;
|
|
1841
|
+
/**
|
|
1842
|
+
* This is to set the capacity for the device progress bar.
|
|
1843
|
+
* This should be a string percentage (e.g. 10%) to accurately
|
|
1844
|
+
* generate the width of the progress (via css).
|
|
1845
|
+
*/
|
|
1846
|
+
capacity: string;
|
|
1847
|
+
/**
|
|
1848
|
+
* This is the text to display after the capacity. By default, this value is empty.
|
|
1849
|
+
*/
|
|
1850
|
+
capacitySubText?: string;
|
|
1851
|
+
/**
|
|
1852
|
+
* This is the location, respective to the progress bar, in which to display the capacity text.
|
|
1853
|
+
* The default is "inside" the progress bar.
|
|
1854
|
+
*/
|
|
1855
|
+
capacityLocation?: "below" | "inside";
|
|
1856
|
+
/**
|
|
1857
|
+
* This is to set the background color of the progress bar.
|
|
1858
|
+
*/
|
|
1859
|
+
backgroundColor?: string;
|
|
1860
|
+
/**
|
|
1861
|
+
* These are the classes to apply to the component.
|
|
1862
|
+
*/
|
|
1863
|
+
className?: string;
|
|
1864
|
+
/**
|
|
1865
|
+
* These are optional thresholds to set on the progress bar.
|
|
1866
|
+
*/
|
|
1867
|
+
thresholds?: DeviceProgressBarThreshold[];
|
|
1868
|
+
}
|
|
1869
|
+
/**
|
|
1870
|
+
* Device Progress Component
|
|
1871
|
+
*
|
|
1872
|
+
* The Device Progress Component displays the used space, available space and the total space of the device in the
|
|
1873
|
+
* form of a bar. It also displays the percentage of the device that is full.
|
|
1874
|
+
*
|
|
1875
|
+
*/
|
|
1876
|
+
declare const DeviceProgressBar: FC<DeviceProgressProps>;
|
|
1877
|
+
interface Property {
|
|
1878
|
+
/** This is to set the caption for the PropertyList */
|
|
1879
|
+
caption: string;
|
|
1880
|
+
/** This is to set the caption style that needs to be added to the caption */
|
|
1881
|
+
captionStyles?: string | null;
|
|
1882
|
+
/** This is to set the content for the corresponding caption */
|
|
1883
|
+
content: (data: any) => ReactNode;
|
|
1884
|
+
/** This is to set the style for the content associated to the caption */
|
|
1885
|
+
contentStyles?: string | null;
|
|
1886
|
+
}
|
|
1887
|
+
interface BaseProps {
|
|
1888
|
+
/** This is to set the list of the property- caption, captionStyle, content and contentStyles */
|
|
1889
|
+
attributes: Property[];
|
|
1890
|
+
/** This is to set the external class on the Property List. */
|
|
1891
|
+
className?: string;
|
|
1892
|
+
/** This is to set the data for the content defined in the Property */
|
|
1893
|
+
data: any;
|
|
1894
|
+
}
|
|
1895
|
+
interface PropertyListProps extends BaseProps {
|
|
1896
|
+
/** This is to set the caption width. Set variant as 'variable' to render the caption according to the size of the caption.
|
|
1897
|
+
* The default is set to Fixed. */
|
|
1898
|
+
variant: string;
|
|
1899
|
+
}
|
|
1900
|
+
/** The PropertyList Component is used to display the list of captions and their corresponding data. The default behavior of the caption is fixed but you can choose to
|
|
1901
|
+
* set the variant='Variable'. The custom styles can be applied to the caption and the corresponding content.
|
|
1902
|
+
* For more information please check the implementations below.
|
|
1903
|
+
*/
|
|
1904
|
+
declare const PropertyList: React.FC<PropertyListProps>;
|
|
1905
|
+
declare const PropertyListVariable: React.FC<BaseProps>;
|
|
1906
|
+
interface RadioGroupProps {
|
|
1907
|
+
/**
|
|
1908
|
+
* The name of the radio button group.
|
|
1909
|
+
*/
|
|
1910
|
+
name: string;
|
|
1911
|
+
/**
|
|
1912
|
+
* The options of each radio button within the radio group.
|
|
1913
|
+
* Options include the `label` (appearance), `value` (returned on selection),
|
|
1914
|
+
* and whether the individual option is `disabled`.
|
|
1915
|
+
*/
|
|
1916
|
+
options: {
|
|
1917
|
+
value: string | number;
|
|
1918
|
+
label: string | ReactElement;
|
|
1919
|
+
disabled?: boolean;
|
|
1920
|
+
}[];
|
|
1921
|
+
/**
|
|
1922
|
+
* The value of the selected radio button.
|
|
1923
|
+
*/
|
|
1924
|
+
value: string | number;
|
|
1925
|
+
/**
|
|
1926
|
+
* HTML input element disabled prop.
|
|
1927
|
+
*/
|
|
1928
|
+
disabled?: boolean;
|
|
1929
|
+
/**
|
|
1930
|
+
* The action that should be run when a radio button is selected.
|
|
1931
|
+
*/
|
|
1932
|
+
onChange?: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
1933
|
+
/**
|
|
1934
|
+
* The classes to pass to the radio group.
|
|
1935
|
+
*/
|
|
1936
|
+
className?: string;
|
|
1937
|
+
/**
|
|
1938
|
+
* The classes to pass to the radio group label.
|
|
1939
|
+
*/
|
|
1940
|
+
labelClassName?: string;
|
|
1941
|
+
}
|
|
1942
|
+
/**
|
|
1943
|
+
* RadioGroup Component
|
|
1944
|
+
*
|
|
1945
|
+
* The RadioGroup component takes in native radio button props as well as its own RadioGroupProps.
|
|
1946
|
+
*
|
|
1947
|
+
*/
|
|
1948
|
+
declare const RadioGroup: FC<RadioGroupProps & ComponentPropsWithoutRef<"input">>;
|
|
1949
|
+
interface RefreshToolbarProps {
|
|
1950
|
+
/**
|
|
1951
|
+
* This is called when the refresh button is clicked.
|
|
1952
|
+
*/
|
|
1953
|
+
handleRefresh(): void;
|
|
1954
|
+
/**
|
|
1955
|
+
* This is to set the Refresh toolbar class.
|
|
1956
|
+
*/
|
|
1957
|
+
className?: string;
|
|
1958
|
+
/**
|
|
1959
|
+
* The additional content to display if desired.
|
|
1960
|
+
*/
|
|
1961
|
+
children?: ReactNode;
|
|
1962
|
+
/**
|
|
1963
|
+
* This is to set to false if you want to apply your own container styling (with className prop or a wrapper)
|
|
1964
|
+
*/
|
|
1965
|
+
standalone?: boolean;
|
|
1966
|
+
/**
|
|
1967
|
+
* Set this to true if you want to display the loading image.
|
|
1968
|
+
*/
|
|
1969
|
+
isRefreshing?: boolean;
|
|
1970
|
+
/**
|
|
1971
|
+
* This is to set the last updated text.
|
|
1972
|
+
*/
|
|
1973
|
+
lastUpdated?: string | null;
|
|
1974
|
+
/**
|
|
1975
|
+
* This is to display the loading image label.
|
|
1976
|
+
*/
|
|
1977
|
+
refreshProgressLabel?: string;
|
|
1978
|
+
/**
|
|
1979
|
+
* This is to render right side components.
|
|
1980
|
+
*/
|
|
1981
|
+
rightComp?: ReactNode;
|
|
1982
|
+
/**
|
|
1983
|
+
* This is to set right side text.
|
|
1984
|
+
*/
|
|
1985
|
+
rightSideText?: string;
|
|
1986
|
+
/**
|
|
1987
|
+
* This is to render a custom refresh button.
|
|
1988
|
+
*/
|
|
1989
|
+
refreshButton?: ReactNode;
|
|
1990
|
+
}
|
|
1991
|
+
/**
|
|
1992
|
+
* Refresh toolbar component that can be used as an additional header row.
|
|
1993
|
+
*
|
|
1994
|
+
* Set [standalone] to false if you want to apply your own container styling (with className
|
|
1995
|
+
* prop or a wrapper). Set [standalone] to true to add full-width behavior with margins and
|
|
1996
|
+
* a bottom border (to function as a standalone header). Defaults to true.
|
|
1997
|
+
*/
|
|
1998
|
+
declare const RefreshToolbar: FC<RefreshToolbarProps>;
|
|
1999
|
+
type SelectOverlayStyles = Partial<GetStyles<SelectOption<any>, true, GroupBase<SelectOption<any>>>>;
|
|
2000
|
+
declare const SELECT_OVERLAY_STYLES: SelectOverlayStyles;
|
|
2001
|
+
interface SelectPopoverOption {
|
|
2002
|
+
name: ReactElement | string;
|
|
2003
|
+
value: unknown;
|
|
2004
|
+
key?: string;
|
|
2005
|
+
disabled?: boolean;
|
|
2006
|
+
}
|
|
2007
|
+
interface SelectPopoverProps {
|
|
2008
|
+
/**
|
|
2009
|
+
* Called on click with the value of the option that was clicked.
|
|
2010
|
+
*/
|
|
2011
|
+
handleClick(value: unknown): void;
|
|
2012
|
+
/**
|
|
2013
|
+
* Children to render within popover wrapper.
|
|
2014
|
+
*/
|
|
2015
|
+
children?: ReactNode;
|
|
2016
|
+
/**
|
|
2017
|
+
* Options to be mapped to items in the dropdown.
|
|
2018
|
+
*/
|
|
2019
|
+
options: SelectPopoverOption[];
|
|
2020
|
+
/**
|
|
2021
|
+
* Determines whether the popover is visible. A key can be provided if the name is not unique.
|
|
2022
|
+
*/
|
|
2023
|
+
visible: boolean;
|
|
2024
|
+
/**
|
|
2025
|
+
* This is the id to assign to the appended div when rendering in a portal.
|
|
2026
|
+
* This defaults to `lakefront-portal-container`.
|
|
2027
|
+
*/
|
|
2028
|
+
portalId?: string;
|
|
2029
|
+
/**
|
|
2030
|
+
* When true, the component will mount a div to the body and render the popover through it.
|
|
2031
|
+
* This is useful when the popover would be inside a scrollable container or one with "overflow: hidden"
|
|
2032
|
+
* so it doesn't get cut off. Uses IntersectionObserver and needs a polyfill if IE compatibility is needed.
|
|
2033
|
+
*/
|
|
2034
|
+
renderInPortal?: boolean;
|
|
2035
|
+
/**
|
|
2036
|
+
* The classes to pass to the select popover.
|
|
2037
|
+
*/
|
|
2038
|
+
className?: string;
|
|
2039
|
+
}
|
|
2040
|
+
/**
|
|
2041
|
+
* Select Popover Component
|
|
2042
|
+
*
|
|
2043
|
+
* The Select Popover component is a select-style component that displays like a popover at the bottom of the children.
|
|
2044
|
+
* The state is not managed inside this component and visible needs to be maintained in the parent component.
|
|
2045
|
+
* When used inside a scrollable or "overflow: hidden" element it may get cut off. When this is an issue,
|
|
2046
|
+
* use the "renderInPortal" prop which appends a div to the body and positions the component to the correct coordinates.
|
|
2047
|
+
*
|
|
2048
|
+
*/
|
|
2049
|
+
declare const SelectPopover: FC<SelectPopoverProps>;
|
|
2050
|
+
declare enum MESSAGE_TYPES {
|
|
2051
|
+
INFO = "info",
|
|
2052
|
+
ERROR = "error",
|
|
2053
|
+
SUCCESS = "success"
|
|
2054
|
+
}
|
|
2055
|
+
type SnackbarCloseReason = "timeout";
|
|
2056
|
+
interface SnackbarOrigin {
|
|
2057
|
+
vertical: "top" | "bottom";
|
|
2058
|
+
horizontal: "left" | "center" | "right";
|
|
2059
|
+
}
|
|
2060
|
+
interface SnackbarProps {
|
|
2061
|
+
/**
|
|
2062
|
+
* The action to display. It renders after the message, at the end of the snackbar.
|
|
2063
|
+
*/
|
|
2064
|
+
action?: ReactNode;
|
|
2065
|
+
/**
|
|
2066
|
+
* The anchor of the `Snackbar`.
|
|
2067
|
+
*/
|
|
2068
|
+
anchorOrigin?: SnackbarOrigin;
|
|
2069
|
+
/**
|
|
2070
|
+
* The number of milliseconds to wait before automatically calling the
|
|
2071
|
+
* `onClose` function. `onClose` should then set the state of the `open`
|
|
2072
|
+
* prop to hide the Snackbar. This behavior is disabled by default with
|
|
2073
|
+
* the `null` value. If left undefined will auto hide after 4000ms.
|
|
2074
|
+
*/
|
|
2075
|
+
autoHideDuration?: number | null;
|
|
2076
|
+
/**
|
|
2077
|
+
* The message to display.
|
|
2078
|
+
*/
|
|
2079
|
+
message?: string;
|
|
2080
|
+
/**
|
|
2081
|
+
* Callback fired when the component requests to be closed.
|
|
2082
|
+
* Typically `onClose` is used to set state in the parent component,
|
|
2083
|
+
* which is used to control the `Snackbar` `open` prop.
|
|
2084
|
+
* The `reason` parameter can optionally be used to control the response to `onClose`,
|
|
2085
|
+
* for example ignoring `clickaway`.
|
|
2086
|
+
*
|
|
2087
|
+
* @param {string} reason Can be: `"timeout"` (`autoHideDuration` expired), `"clickaway"`.
|
|
2088
|
+
*/
|
|
2089
|
+
onClose?: (reason: SnackbarCloseReason) => void;
|
|
2090
|
+
/**
|
|
2091
|
+
* If `true`, `Snackbar` is open.
|
|
2092
|
+
*/
|
|
2093
|
+
open?: boolean;
|
|
2094
|
+
/**
|
|
2095
|
+
* Message types used to determine icon color and icon to render.
|
|
2096
|
+
*/
|
|
2097
|
+
type: MESSAGE_TYPES;
|
|
2098
|
+
/**
|
|
2099
|
+
* This is the id to assign to the appended div when rendering in a portal.
|
|
2100
|
+
* This defaults to `lakefront-portal-container`.
|
|
2101
|
+
*/
|
|
2102
|
+
portalId?: string;
|
|
2103
|
+
/**
|
|
2104
|
+
* When true, the component will mount a div to the body and render the popover through it.
|
|
2105
|
+
* This is useful when the popover would be inside a scrollable container or one with "overflow: hidden"
|
|
2106
|
+
* so it doesn't get cut off. Uses IntersectionObserver and needs a polyfill if IE compatibility is needed.
|
|
2107
|
+
*/
|
|
2108
|
+
renderInPortal?: boolean;
|
|
2109
|
+
/**
|
|
2110
|
+
* The classes to pass to the snackbar.
|
|
2111
|
+
*/
|
|
2112
|
+
className?: string;
|
|
2113
|
+
}
|
|
2114
|
+
/**
|
|
2115
|
+
* Snackbar Component
|
|
2116
|
+
*
|
|
2117
|
+
* The Snackbar component is a UI informational overlay.
|
|
2118
|
+
* This can be used to display messages, as well as provide an action with an allocated type that has it's own corresponding icon and styling.
|
|
2119
|
+
* The state is not managed inside this component and visibility (via the `open` prop) needs to be maintained in the parent component.
|
|
2120
|
+
* The `renderInPortal` prop can be used to append a div to the body.
|
|
2121
|
+
*
|
|
2122
|
+
*/
|
|
2123
|
+
declare const Snackbar: FC<SnackbarProps>;
|
|
2124
|
+
declare enum Mode {
|
|
2125
|
+
minmax = "minmax",
|
|
2126
|
+
presets = "presets"
|
|
2127
|
+
}
|
|
2128
|
+
interface VehicleSpeed {
|
|
2129
|
+
min?: number;
|
|
2130
|
+
max?: number;
|
|
2131
|
+
unit: SPEED_UNITS;
|
|
2132
|
+
mode: Mode;
|
|
2133
|
+
preset?: string;
|
|
2134
|
+
}
|
|
2135
|
+
/**
|
|
2136
|
+
* Enumerator for units of speed abbreviations
|
|
2137
|
+
*/
|
|
2138
|
+
declare enum SPEED_UNITS {
|
|
2139
|
+
kilometersPerHour = "kph",
|
|
2140
|
+
milesPerHour = "mph",
|
|
2141
|
+
metersPerSecondSquared = "m/s\u00B2"
|
|
2142
|
+
}
|
|
2143
|
+
interface SpeedInputProps {
|
|
2144
|
+
/**
|
|
2145
|
+
* The value prop is assigned to 'VehicleSpeed', which is made up of a 'min', 'max' for the input values. A 'unit'(SPEED_UNITS) which is currently a toggle between 'kph', 'mph', or 'm/s²'. And 'mode' which uses 'minmax' for both input values.
|
|
2146
|
+
*/
|
|
2147
|
+
value: VehicleSpeed | null;
|
|
2148
|
+
/**
|
|
2149
|
+
* The function that should run when a radio button is selected.
|
|
2150
|
+
*/
|
|
2151
|
+
onChange(speedRange: VehicleSpeed | null): void;
|
|
2152
|
+
/**
|
|
2153
|
+
* Toggle true, to have speed units validated for selected unit.
|
|
2154
|
+
*/
|
|
2155
|
+
unitConversionRequired: boolean;
|
|
2156
|
+
/**
|
|
2157
|
+
* Toggle to accept negative input values or not.
|
|
2158
|
+
*/
|
|
2159
|
+
allowNegativeInput: boolean;
|
|
2160
|
+
/**
|
|
2161
|
+
* We can set our defaultUnits with (kilometersPerHour(kph), milesPerHour(mph), metersPerSecondSquared(m/s²)).
|
|
2162
|
+
* These values determine if the unitConversionRequired needs to validate the conversion or not.
|
|
2163
|
+
*/
|
|
2164
|
+
defaultUnits: SPEED_UNITS;
|
|
2165
|
+
/**
|
|
2166
|
+
* If true, this prop will disable the radio buttons.
|
|
2167
|
+
*/
|
|
2168
|
+
disabled: boolean;
|
|
2169
|
+
}
|
|
2170
|
+
/**
|
|
2171
|
+
*
|
|
2172
|
+
* The SpeedInput component takes in RadioGroup and MinMaxInput to create one component.
|
|
2173
|
+
* This component is used for input values also to toggle between radio buttons to convert input to a range.
|
|
2174
|
+
*
|
|
2175
|
+
*/
|
|
2176
|
+
declare const SpeedInput: FC<SpeedInputProps>;
|
|
2177
|
+
type SpeedInputVehicleSpeed = VehicleSpeed;
|
|
2178
|
+
declare const SpeedInputVehicleSpeedMode: typeof Mode;
|
|
2179
|
+
type StackBannerIcon = ReactElement<SVGElement> | boolean | undefined;
|
|
2180
|
+
interface StackBannerRowProps {
|
|
2181
|
+
/**
|
|
2182
|
+
* A unique string key required for React list item changes.
|
|
2183
|
+
*/
|
|
2184
|
+
key: string;
|
|
2185
|
+
/**
|
|
2186
|
+
* The main content to be displayed in the banner.
|
|
2187
|
+
*/
|
|
2188
|
+
content?: ReactNode;
|
|
2189
|
+
/**
|
|
2190
|
+
* The svg icon to display. If a svg is provided, the svg will be used.
|
|
2191
|
+
* If explicitly true or left undefined, a default flag icon will be displayed.
|
|
2192
|
+
* If explicitly false, no icon will be displayed.
|
|
2193
|
+
*/
|
|
2194
|
+
icon?: StackBannerIcon;
|
|
2195
|
+
/**
|
|
2196
|
+
* The severity of the content that maps to varying background color levels.
|
|
2197
|
+
* If left undefined, the background will be transparent.
|
|
2198
|
+
*/
|
|
2199
|
+
severity?: "normal" | "warning" | "error" | "default";
|
|
2200
|
+
/**
|
|
2201
|
+
* The action to run when the banner is clicked.
|
|
2202
|
+
*/
|
|
2203
|
+
onClick?: (event: MouseEvent<HTMLElement>) => void;
|
|
2204
|
+
/**
|
|
2205
|
+
* The classes to pass to the stack banner row.
|
|
2206
|
+
*/
|
|
2207
|
+
className?: string;
|
|
2208
|
+
}
|
|
2209
|
+
/**
|
|
2210
|
+
* StackBannerRow Component
|
|
2211
|
+
*
|
|
2212
|
+
* The StackBannerRow component takes in content, icon, severity, and onClick props. It is
|
|
2213
|
+
* designed to be used with a StackBanner component, but can be used as a standalone component.
|
|
2214
|
+
*
|
|
2215
|
+
*/
|
|
2216
|
+
declare const StackBannerRow: FC<StackBannerRowProps & Omit<ComponentPropsWithoutRef<"div">, "content">>;
|
|
2217
|
+
interface StackBannerProps {
|
|
2218
|
+
/**
|
|
2219
|
+
* The rows to display in the stack banner.
|
|
2220
|
+
*/
|
|
2221
|
+
rows: StackBannerRowProps[];
|
|
2222
|
+
/**
|
|
2223
|
+
* The classes to pass to the stack banner.
|
|
2224
|
+
*/
|
|
2225
|
+
className?: string;
|
|
2226
|
+
}
|
|
2227
|
+
/**
|
|
2228
|
+
* StackBanner Component
|
|
2229
|
+
*
|
|
2230
|
+
* The StackBanner component is the container for StackBannerRows. As such,
|
|
2231
|
+
* rows are required to display any content.
|
|
2232
|
+
*
|
|
2233
|
+
*/
|
|
2234
|
+
declare const StackBanner: FC<StackBannerProps & ComponentPropsWithoutRef<"div">>;
|
|
2235
|
+
interface StatusCardProps {
|
|
2236
|
+
/**
|
|
2237
|
+
* This is to set the status row.
|
|
2238
|
+
*/
|
|
2239
|
+
statusRow: ReactNode;
|
|
2240
|
+
/**
|
|
2241
|
+
* This is to set the bottom row.
|
|
2242
|
+
*/
|
|
2243
|
+
bottomRow: ReactNode;
|
|
2244
|
+
/**
|
|
2245
|
+
* This is to set an external class.
|
|
2246
|
+
*/
|
|
2247
|
+
className?: string;
|
|
2248
|
+
}
|
|
2249
|
+
/**
|
|
2250
|
+
* Status Card Component is used to render the status and the bottom row.
|
|
2251
|
+
*/
|
|
2252
|
+
declare const StatusCard: FC<StatusCardProps>;
|
|
2253
|
+
interface StatusCellBadgeProps {
|
|
2254
|
+
/**
|
|
2255
|
+
* This is to set the status.
|
|
2256
|
+
*/
|
|
2257
|
+
status: string;
|
|
2258
|
+
/**
|
|
2259
|
+
* This is to set an external class.
|
|
2260
|
+
*/
|
|
2261
|
+
className?: string;
|
|
2262
|
+
}
|
|
2263
|
+
/**
|
|
2264
|
+
* Status Cell Badge Component will display a round bullet colored according to the status and
|
|
2265
|
+
* display the status.
|
|
2266
|
+
*/
|
|
2267
|
+
declare const StatusCellBadge: FC<StatusCellBadgeProps>;
|
|
2268
|
+
declare enum Status {
|
|
2269
|
+
RUNNING = "Running",
|
|
2270
|
+
ENQUEUED = "Enqueued",
|
|
2271
|
+
ERROR = "Error",
|
|
2272
|
+
FAILED = "Failed",
|
|
2273
|
+
NONE = "None"
|
|
2274
|
+
}
|
|
2275
|
+
interface StatusRowProps {
|
|
2276
|
+
/**
|
|
2277
|
+
* The children to display within row.
|
|
2278
|
+
*/
|
|
2279
|
+
children?: ReactNode;
|
|
2280
|
+
/**
|
|
2281
|
+
* This is to set the status.
|
|
2282
|
+
*/
|
|
2283
|
+
status?: Status;
|
|
2284
|
+
/**
|
|
2285
|
+
* This is to set an external classname.
|
|
2286
|
+
*/
|
|
2287
|
+
className?: string;
|
|
2288
|
+
/**
|
|
2289
|
+
* This is to handle the row click event.
|
|
2290
|
+
*/
|
|
2291
|
+
onRowClick?: () => void;
|
|
2292
|
+
}
|
|
2293
|
+
/**
|
|
2294
|
+
* Status Row Component is used to render the row with various colums.
|
|
2295
|
+
*/
|
|
2296
|
+
declare const StatusRow: FC<StatusRowProps>;
|
|
2297
|
+
interface StatusTableHeader {
|
|
2298
|
+
/**
|
|
2299
|
+
* This property is to set the name of the header.
|
|
2300
|
+
*/
|
|
2301
|
+
name: string;
|
|
2302
|
+
/**
|
|
2303
|
+
* This is to set the name of the field.
|
|
2304
|
+
*/
|
|
2305
|
+
field?: string;
|
|
2306
|
+
/**
|
|
2307
|
+
* This is to set whether the field is sortable.
|
|
2308
|
+
*/
|
|
2309
|
+
sortable: boolean;
|
|
2310
|
+
}
|
|
2311
|
+
interface StatusTableProps {
|
|
2312
|
+
/**
|
|
2313
|
+
* The headers to populate the status table. The header should have a display name, field and sortable
|
|
2314
|
+
* set to true or false.
|
|
2315
|
+
*/
|
|
2316
|
+
headers: StatusTableHeader[];
|
|
2317
|
+
/**
|
|
2318
|
+
* The children to render inside the table.
|
|
2319
|
+
*/
|
|
2320
|
+
children?: ReactNode;
|
|
2321
|
+
/**
|
|
2322
|
+
* This is an event that triggers whenever the sorting is clicked.
|
|
2323
|
+
*/
|
|
2324
|
+
handleSort?: (field: string) => void;
|
|
2325
|
+
/**
|
|
2326
|
+
* If set to true, this will render table as Status Table Card. The headers will not be visible.
|
|
2327
|
+
*/
|
|
2328
|
+
cards?: boolean;
|
|
2329
|
+
/**
|
|
2330
|
+
* This is to set an external class.
|
|
2331
|
+
*/
|
|
2332
|
+
className?: string;
|
|
2333
|
+
}
|
|
2334
|
+
/**
|
|
2335
|
+
*
|
|
2336
|
+
* Status Table Component has two variations- 1. Status Table with headers 2. Status Table as a card with no headers.
|
|
2337
|
+
* The handleSort event is triggered whenever the sorting changes on the table.
|
|
2338
|
+
* You can use this to write your own logic to handle sort.
|
|
2339
|
+
* The colors for each row is rendered depending on the status.
|
|
2340
|
+
*/
|
|
2341
|
+
declare const StatusTable: FC<StatusTableProps>;
|
|
2342
|
+
interface SortOptions {
|
|
2343
|
+
orderBy: string | string[];
|
|
2344
|
+
ascending?: boolean;
|
|
2345
|
+
}
|
|
2346
|
+
/**
|
|
2347
|
+
* mapTableFilters was primarily created to mitigate where different
|
|
2348
|
+
* api endpoints can bring back the same data under different key names.
|
|
2349
|
+
* This allows for filtering across tables.
|
|
2350
|
+
*/
|
|
2351
|
+
declare const mapTableFilters: (filterValues: FilterValues, filterMap: FilterMap) => FilterMap;
|
|
2352
|
+
declare const getCompareFormat: (value: any) => number | string;
|
|
2353
|
+
declare const sortByField: <T extends unknown>(ascending: boolean, inboundData: T[], field: string) => T[];
|
|
2354
|
+
declare const filterData: (filters: FilterMap) => <T extends unknown>(inboundData: T[] | null) => T[] | null;
|
|
2355
|
+
declare const sortData: (sortOptions: SortOptions) => <T extends unknown>(inboundData: T[]) => T[];
|
|
2356
|
+
interface StatusTableHooks<T> {
|
|
2357
|
+
data: T[];
|
|
2358
|
+
handleSort(field: string, bidirectional?: boolean): void;
|
|
2359
|
+
}
|
|
2360
|
+
interface StatusTableOptions {
|
|
2361
|
+
filters?: {
|
|
2362
|
+
filterMap: FilterMap;
|
|
2363
|
+
filterValues: FilterValues;
|
|
2364
|
+
};
|
|
2365
|
+
sort?: SortOptions;
|
|
2366
|
+
}
|
|
2367
|
+
declare const useStatusTable: <T extends unknown>(inboundData: T[] | null, { filters: filterOptions, sort: sortOptions }?: StatusTableOptions) => StatusTableHooks<T>;
|
|
2368
|
+
interface GraphProps {
|
|
2369
|
+
/**
|
|
2370
|
+
* Sends data stored with each node from the parsing step on click inside of any drawn node. Use this data to
|
|
2371
|
+
* store the node key for the highlightedKey prop if node highlighting is desired.
|
|
2372
|
+
*/
|
|
2373
|
+
handleSelectedNode(node: any | null, vertex?: number): void;
|
|
2374
|
+
/**
|
|
2375
|
+
* Handle a right-click on any drawn node. This can be used to configure a context menu.
|
|
2376
|
+
*/
|
|
2377
|
+
handleContextClickNode?(key: string, vertex: number, e: MouseEvent<HTMLCanvasElement>, ctx: CanvasRenderingContext2D): void;
|
|
2378
|
+
/**
|
|
2379
|
+
* Action to run when a node context menu is closed.
|
|
2380
|
+
*/
|
|
2381
|
+
handleCloseContextMenu?(): void;
|
|
2382
|
+
/**
|
|
2383
|
+
* This should be the node key from the AWS JSON and if supplied, will highlight that node in the graph.
|
|
2384
|
+
*/
|
|
2385
|
+
highlightedKey: string | null;
|
|
2386
|
+
/**
|
|
2387
|
+
* This is AWS Step Function JSON contained in an object. See the Storybook Canvas for detailed examples of what
|
|
2388
|
+
* should be provided.
|
|
2389
|
+
*/
|
|
2390
|
+
json: any;
|
|
2391
|
+
/**
|
|
2392
|
+
* The classes to pass to the step function graph container.
|
|
2393
|
+
*/
|
|
2394
|
+
className?: string;
|
|
2395
|
+
}
|
|
2396
|
+
/**
|
|
2397
|
+
* Step Function Graph Component
|
|
2398
|
+
*
|
|
2399
|
+
* The Step Function Graph takes AWS Step Function JSON and renders an interactive 2D canvas of how its states connect
|
|
2400
|
+
* together. It can be panned by clicking in empty space and moving the mouse. It also takes a function "handleSelectedNode" that sends back which node has been clicked, so the
|
|
2401
|
+
* the consuming application can use the "highlightedKey" prop to let it know to highlight a node.
|
|
2402
|
+
* This component does not allow cycles, or nodes that connect such that a circular path is formed.
|
|
2403
|
+
*/
|
|
2404
|
+
declare const StepFunctionGraph: FC<GraphProps>;
|
|
2405
|
+
type StepFunctionGraphProps = GraphProps;
|
|
2406
|
+
interface TableSortByOptions {
|
|
2407
|
+
id: string;
|
|
2408
|
+
desc: boolean;
|
|
2409
|
+
}
|
|
2410
|
+
interface TableProps {
|
|
2411
|
+
/**
|
|
2412
|
+
* This is to set the data for the table.
|
|
2413
|
+
*/
|
|
2414
|
+
data: Array<any> | null | undefined;
|
|
2415
|
+
/**
|
|
2416
|
+
* This is to set the columns of the table.
|
|
2417
|
+
*/
|
|
2418
|
+
columns: Array<Column>;
|
|
2419
|
+
/**
|
|
2420
|
+
* This is to set the additional properties on the table like disableSortRemove,
|
|
2421
|
+
* autoResetSortBy, disableMultiSort, etc.
|
|
2422
|
+
*/
|
|
2423
|
+
options?: any;
|
|
2424
|
+
/**
|
|
2425
|
+
* This is to set the row properties.
|
|
2426
|
+
*/
|
|
2427
|
+
rowProps?: object;
|
|
2428
|
+
/**
|
|
2429
|
+
* This is to set the display message when there is no data.
|
|
2430
|
+
*/
|
|
2431
|
+
noDataMessage?: string;
|
|
2432
|
+
/**
|
|
2433
|
+
* This is to set some additional style on the table.
|
|
2434
|
+
*/
|
|
2435
|
+
style?: any;
|
|
2436
|
+
/**
|
|
2437
|
+
* This is to set a class on the table.
|
|
2438
|
+
*/
|
|
2439
|
+
className?: string;
|
|
2440
|
+
/**
|
|
2441
|
+
* This is to set the initial sorting on the table.
|
|
2442
|
+
* When an array of items is provided, the order dictates the priority of sorting. Example: value --> title --> percentage.
|
|
2443
|
+
*/
|
|
2444
|
+
initialSortBy?: {
|
|
2445
|
+
id: string;
|
|
2446
|
+
desc: boolean;
|
|
2447
|
+
}[] | {
|
|
2448
|
+
id: string;
|
|
2449
|
+
desc: boolean;
|
|
2450
|
+
};
|
|
2451
|
+
/**
|
|
2452
|
+
* This event is triggered when the sorting is changed on the table.
|
|
2453
|
+
* The first argument is the sorted column and the second argument is the sortBy array
|
|
2454
|
+
* (for if table is sorted by multiple columns).
|
|
2455
|
+
*/
|
|
2456
|
+
onChangeSort?({ id, desc }: TableSortByOptions, sortedBy?: TableSortByOptions[]): void;
|
|
2457
|
+
/**
|
|
2458
|
+
* This is to set the row sub component on the table.
|
|
2459
|
+
*/
|
|
2460
|
+
renderRowSubComponent?({ row }: {
|
|
2461
|
+
row: any;
|
|
2462
|
+
}): React.ReactNode;
|
|
2463
|
+
/**
|
|
2464
|
+
* This allows displaying the table rows without headers.
|
|
2465
|
+
* This is defaulted to false.
|
|
2466
|
+
*/
|
|
2467
|
+
hideHeaders?: boolean;
|
|
2468
|
+
}
|
|
2469
|
+
/**
|
|
2470
|
+
* The Table Component is used to render table with specified columns and data.
|
|
2471
|
+
* The no data meesage can be set when the data is not present.
|
|
2472
|
+
* You can set initial sorting on the table. OnChangeSort is triggered everytime the sorting is changed on the table.
|
|
2473
|
+
* For more information about react-table please check the link https://react-table.tanstack.com/docs/api/useTable
|
|
2474
|
+
*/
|
|
2475
|
+
declare const Table: React.FC<TableProps>;
|
|
2476
|
+
interface TabProps {
|
|
2477
|
+
/**
|
|
2478
|
+
* This is to set the options which has a key and a caption.
|
|
2479
|
+
*/
|
|
2480
|
+
options: TabDef[];
|
|
2481
|
+
/**
|
|
2482
|
+
* This is to set the selected tab by default.
|
|
2483
|
+
*/
|
|
2484
|
+
value: string;
|
|
2485
|
+
/**
|
|
2486
|
+
* This is an event which is called whenever a tab is clicked.
|
|
2487
|
+
*/
|
|
2488
|
+
onChange(value: string): void;
|
|
2489
|
+
/**
|
|
2490
|
+
* This is to set a class on the tab component.
|
|
2491
|
+
*/
|
|
2492
|
+
className?: string;
|
|
2493
|
+
}
|
|
2494
|
+
/**
|
|
2495
|
+
* The Tab Component is used to render multiple tabs. The onChange event is called whenever the user clicks a different tab.
|
|
2496
|
+
* The value will set the selection of the tab by default.
|
|
2497
|
+
*/
|
|
2498
|
+
declare const Tabs: FC<TabProps>;
|
|
2499
|
+
interface TextAreaProps {
|
|
2500
|
+
/**
|
|
2501
|
+
* This shows a label above the TextArea when provided.
|
|
2502
|
+
*/
|
|
2503
|
+
label?: string;
|
|
2504
|
+
/**
|
|
2505
|
+
* If not empty, the TextArea component will be displayed in an error state with the provided error message.
|
|
2506
|
+
*/
|
|
2507
|
+
error?: string;
|
|
2508
|
+
/**
|
|
2509
|
+
* The classes to pass to the text area.
|
|
2510
|
+
*/
|
|
2511
|
+
className?: string;
|
|
2512
|
+
/**
|
|
2513
|
+
* The classes to pass to the text area label.
|
|
2514
|
+
*/
|
|
2515
|
+
labelClassName?: string;
|
|
2516
|
+
}
|
|
2517
|
+
/**
|
|
2518
|
+
* TextArea Component
|
|
2519
|
+
*
|
|
2520
|
+
* The TextArea component takes in native textarea props as well as its own TextAreaProps. The state is not managed
|
|
2521
|
+
* in this component and should be handled in the consuming app.
|
|
2522
|
+
*
|
|
2523
|
+
*/
|
|
2524
|
+
declare const TextArea: FC<TextAreaProps & ComponentPropsWithRef<"textarea">>;
|
|
2525
|
+
interface ToggleProps<T> {
|
|
2526
|
+
/**
|
|
2527
|
+
* Optional className for styling component.
|
|
2528
|
+
*/
|
|
2529
|
+
className?: string;
|
|
2530
|
+
/**
|
|
2531
|
+
* When true, the switch will no longer toggle.
|
|
2532
|
+
*/
|
|
2533
|
+
disabled?: boolean;
|
|
2534
|
+
/**
|
|
2535
|
+
* Options for the labels and their values. It should only contain two objects.
|
|
2536
|
+
*/
|
|
2537
|
+
options: SelectOption<T>[];
|
|
2538
|
+
/**
|
|
2539
|
+
* This is called whenever the switch toggles with the value of the option.
|
|
2540
|
+
* Clicking the label also toggles the switch.
|
|
2541
|
+
*/
|
|
2542
|
+
onChange: (value: T) => void;
|
|
2543
|
+
/**
|
|
2544
|
+
* Determines which side of the switch the label is rendered.
|
|
2545
|
+
*/
|
|
2546
|
+
position?: "LEFT" | "RIGHT";
|
|
2547
|
+
/**
|
|
2548
|
+
* The currently selected value. This value is passed in from the parent component.
|
|
2549
|
+
*/
|
|
2550
|
+
value: T;
|
|
2551
|
+
}
|
|
2552
|
+
/**
|
|
2553
|
+
* Toggle Component
|
|
2554
|
+
*
|
|
2555
|
+
* The Toggle component is a switch component that displays one of two labels depending on the state of the switch.
|
|
2556
|
+
* It has a position prop to change the layout of the label. State for the value needs to be maintained in a parent
|
|
2557
|
+
* component and passed in as a prop.
|
|
2558
|
+
*/
|
|
2559
|
+
declare const Toggle: <T>({ className, disabled, options, onChange, position, value }: ToggleProps<T>) => JSX.Element | null;
|
|
2560
|
+
interface ListItem {
|
|
2561
|
+
label: string;
|
|
2562
|
+
description: string;
|
|
2563
|
+
value: string;
|
|
2564
|
+
}
|
|
2565
|
+
interface TransferListProps {
|
|
2566
|
+
leftListData: ListItem[];
|
|
2567
|
+
leftListName: string;
|
|
2568
|
+
rightListData: ListItem[];
|
|
2569
|
+
rightListName: string;
|
|
2570
|
+
onListChange: (leftList: ListItem[], rightList: ListItem[]) => void;
|
|
2571
|
+
sort?: boolean;
|
|
2572
|
+
className?: string;
|
|
2573
|
+
}
|
|
2574
|
+
declare const TransferList: FC<TransferListProps>;
|
|
2575
|
+
interface TypeaheadResultItem {
|
|
2576
|
+
label: ReactNode;
|
|
2577
|
+
value: string;
|
|
2578
|
+
}
|
|
2579
|
+
interface TypeaheadSearchResultProps {
|
|
2580
|
+
searchText: string;
|
|
2581
|
+
onResultSelect: (result: TypeaheadResultItem) => void;
|
|
2582
|
+
fetchResults?: (searchText: string) => Promise<TypeaheadResultItem[]>;
|
|
2583
|
+
}
|
|
2584
|
+
interface TypeaheadSearchProps {
|
|
2585
|
+
/**
|
|
2586
|
+
* Whether the search input should be focused on initialization.
|
|
2587
|
+
*/
|
|
2588
|
+
autoFocus?: boolean;
|
|
2589
|
+
/**
|
|
2590
|
+
* The minimum amount of characters a user must enter before a (non-submit triggered)
|
|
2591
|
+
* search will be initiated. `Default = 1`.
|
|
2592
|
+
*/
|
|
2593
|
+
characterMinimum?: number;
|
|
2594
|
+
/**
|
|
2595
|
+
* The callback to render search text and/or asynchronous search results.
|
|
2596
|
+
*/
|
|
2597
|
+
children?: (typeaheadSearchResultProps: TypeaheadSearchResultProps) => ReactNode;
|
|
2598
|
+
/**
|
|
2599
|
+
* The request to retrieve and format results using the search text. This is useful
|
|
2600
|
+
* if the user does not want to supply their own callback render function as children.
|
|
2601
|
+
*/
|
|
2602
|
+
fetchResults?: (searchText: string) => Promise<TypeaheadResultItem[]>;
|
|
2603
|
+
/**
|
|
2604
|
+
* The initial value of the search text input.
|
|
2605
|
+
*/
|
|
2606
|
+
initialSearchText?: string;
|
|
2607
|
+
/**
|
|
2608
|
+
* The time (in `ms`) to delay between keystrokes before updating the search value. `Default = 250ms`.
|
|
2609
|
+
*/
|
|
2610
|
+
inputDebounceMs?: number;
|
|
2611
|
+
/**
|
|
2612
|
+
* The action to run on a selected result.
|
|
2613
|
+
*/
|
|
2614
|
+
onResultSelect?: (result: TypeaheadResultItem) => void;
|
|
2615
|
+
/**
|
|
2616
|
+
* The placeholder text to display when the input is empty.
|
|
2617
|
+
*/
|
|
2618
|
+
placeholder?: string;
|
|
2619
|
+
/**
|
|
2620
|
+
* Where the search results popover should render in relation to the search input.
|
|
2621
|
+
*/
|
|
2622
|
+
placement?: "bottom-start" | "bottom-end";
|
|
2623
|
+
/**
|
|
2624
|
+
* This is the id to assign to the appended div when rendering in a portal.
|
|
2625
|
+
* This defaults to `lakefront-portal-container`.
|
|
2626
|
+
*/
|
|
2627
|
+
portalId?: string;
|
|
2628
|
+
/**
|
|
2629
|
+
* When true, the component will mount a div to the body and render the search results through it.
|
|
2630
|
+
* This is useful when the popover would be inside a scrollable container or one with "overflow: hidden"
|
|
2631
|
+
* so it doesn't get cut off. Uses IntersectionObserver and needs a polyfill if IE compatibility is needed.
|
|
2632
|
+
*/
|
|
2633
|
+
renderInPortal?: boolean;
|
|
2634
|
+
/**
|
|
2635
|
+
* The action to run using the entered search text on submit.
|
|
2636
|
+
*/
|
|
2637
|
+
submitSearch: (searchText: string) => void;
|
|
2638
|
+
/**
|
|
2639
|
+
* The classes to pass to the typeahead search container.
|
|
2640
|
+
*/
|
|
2641
|
+
className?: string;
|
|
2642
|
+
}
|
|
2643
|
+
/**
|
|
2644
|
+
* TypeaheadSearch Component
|
|
2645
|
+
*
|
|
2646
|
+
* The TypeaheadSearch component is a predictive search style input and especially useful
|
|
2647
|
+
* when the result list needs to be fetched asynchronously. The component can be used as
|
|
2648
|
+
* a stand-alone element (with no children) by providing a `fetchResults` function:
|
|
2649
|
+
*
|
|
2650
|
+
* ```jsx
|
|
2651
|
+
* <TypeaheadSearch
|
|
2652
|
+
* autoFocus
|
|
2653
|
+
* fetchResults={fetchResults}
|
|
2654
|
+
* inputDebounceMs={250}
|
|
2655
|
+
* onResultSelect={onResultSelect}
|
|
2656
|
+
* placeholder="Search"
|
|
2657
|
+
* placement="bottom-start"
|
|
2658
|
+
* submitSearch={submitSearch}
|
|
2659
|
+
* />
|
|
2660
|
+
* ```
|
|
2661
|
+
*
|
|
2662
|
+
* If the default functionality needs to be extended to provide custom result rendering or
|
|
2663
|
+
* to control when the result popover should close, the user can provide a render callback
|
|
2664
|
+
* as follows:
|
|
2665
|
+
*
|
|
2666
|
+
* ```jsx
|
|
2667
|
+
* <TypeaheadSearch {...typeaheadSearchProps}>
|
|
2668
|
+
* {(typeaheadSearchResultProps: TypeaheadSearchResultProps) => (
|
|
2669
|
+
* <TypeaheadCustom {...options} />
|
|
2670
|
+
* )}
|
|
2671
|
+
* </TypeaheadSearch>
|
|
2672
|
+
* ```
|
|
2673
|
+
*
|
|
2674
|
+
* ❗ **Note: In order to use the built-in handler to close the popover when selecting a**
|
|
2675
|
+
* **result from the list, you'll need to spread in the props (as shown above).**
|
|
2676
|
+
*/
|
|
2677
|
+
declare const TypeaheadSearch: FC<TypeaheadSearchProps & ComponentPropsWithoutRef<"input">>;
|
|
2678
|
+
declare const LAKEFRONT_COLORS: {
|
|
2679
|
+
white: string;
|
|
2680
|
+
akoya: string;
|
|
2681
|
+
selago: string;
|
|
2682
|
+
mercury: string;
|
|
2683
|
+
pavement: string;
|
|
2684
|
+
dolphin: string;
|
|
2685
|
+
gunpowder: string;
|
|
2686
|
+
storm: string;
|
|
2687
|
+
cinder: string;
|
|
2688
|
+
black: string;
|
|
2689
|
+
grey30: string;
|
|
2690
|
+
doveGrey: string;
|
|
2691
|
+
bombay: string;
|
|
2692
|
+
alto: string;
|
|
2693
|
+
red: string;
|
|
2694
|
+
watermelon: string;
|
|
2695
|
+
orange: string;
|
|
2696
|
+
yellow: string;
|
|
2697
|
+
gold: string;
|
|
2698
|
+
green: string;
|
|
2699
|
+
pastelGreen: string;
|
|
2700
|
+
emerald: string;
|
|
2701
|
+
teal: string;
|
|
2702
|
+
blue: string;
|
|
2703
|
+
lavender: string;
|
|
2704
|
+
havelockBlue: string;
|
|
2705
|
+
calmingBlue: string;
|
|
2706
|
+
sinbad: string;
|
|
2707
|
+
cranberry: string;
|
|
2708
|
+
viking: string;
|
|
2709
|
+
mediumPurple: string;
|
|
2710
|
+
vista: string;
|
|
2711
|
+
saturatedRed: string;
|
|
2712
|
+
saturatedOrange: string;
|
|
2713
|
+
saturatedYellow: string;
|
|
2714
|
+
saturatedBlue: string;
|
|
2715
|
+
saturatedGreen: string;
|
|
2716
|
+
saturatedLavender: string;
|
|
2717
|
+
saturatedTeal: string;
|
|
2718
|
+
arsenic: string;
|
|
2719
|
+
};
|
|
2720
|
+
declare const THEME: {
|
|
2721
|
+
colors: {
|
|
2722
|
+
white: string;
|
|
2723
|
+
akoya: string;
|
|
2724
|
+
selago: string;
|
|
2725
|
+
mercury: string;
|
|
2726
|
+
pavement: string;
|
|
2727
|
+
dolphin: string;
|
|
2728
|
+
gunpowder: string;
|
|
2729
|
+
storm: string;
|
|
2730
|
+
cinder: string;
|
|
2731
|
+
black: string;
|
|
2732
|
+
grey30: string;
|
|
2733
|
+
doveGrey: string;
|
|
2734
|
+
bombay: string;
|
|
2735
|
+
alto: string;
|
|
2736
|
+
red: string;
|
|
2737
|
+
watermelon: string;
|
|
2738
|
+
orange: string;
|
|
2739
|
+
yellow: string;
|
|
2740
|
+
gold: string;
|
|
2741
|
+
green: string;
|
|
2742
|
+
pastelGreen: string;
|
|
2743
|
+
emerald: string;
|
|
2744
|
+
teal: string;
|
|
2745
|
+
blue: string;
|
|
2746
|
+
lavender: string;
|
|
2747
|
+
havelockBlue: string;
|
|
2748
|
+
calmingBlue: string;
|
|
2749
|
+
sinbad: string;
|
|
2750
|
+
cranberry: string;
|
|
2751
|
+
viking: string;
|
|
2752
|
+
mediumPurple: string;
|
|
2753
|
+
vista: string;
|
|
2754
|
+
saturatedRed: string;
|
|
2755
|
+
saturatedOrange: string;
|
|
2756
|
+
saturatedYellow: string;
|
|
2757
|
+
saturatedBlue: string;
|
|
2758
|
+
saturatedGreen: string;
|
|
2759
|
+
saturatedLavender: string;
|
|
2760
|
+
saturatedTeal: string;
|
|
2761
|
+
arsenic: string;
|
|
2762
|
+
};
|
|
2763
|
+
borders: {
|
|
2764
|
+
primary: string;
|
|
2765
|
+
popover: string;
|
|
2766
|
+
};
|
|
2767
|
+
zIndex: {
|
|
2768
|
+
modal: number;
|
|
2769
|
+
popover: number;
|
|
2770
|
+
snackbar: number;
|
|
2771
|
+
};
|
|
2772
|
+
DARKEN_MOST: number;
|
|
2773
|
+
DARKEN_LEAST: number;
|
|
2774
|
+
};
|
|
2775
|
+
export { AnchorCopy, AnchorCopyProps, BoundingBoxes, BoundingBoxesProps, BoundingBoxItemProp, BreadcrumbHeader, BreadcrumbProps, RouteProp, Breadcrumb, BreadcrumbHeaderProps, Button, ButtonProps$0 as ButtonProps, Card, CardProps, Checkbox, CheckboxProps, CheckboxGroup, CheckboxGroupProps, CheckboxGroupOption, Collapsible, CollapsibleProps, CopyButton, CopyButtonProps, Drawer, DrawerProps, Filter, getApiQueryUrl, getApiPostBody, parseInitialFilterValues, getCurrentBrowserQueryParams, getFilterBrowserQueryParams, FILTER_MODE_OPTIONS, USER_JSON_QUERY_PARAM, getDefaultValue, getDefaultJsonViewValue, getFilterAppliedCount, getUrlFromList, areSetsEqual, convertToFilterDropdownOptions, useFilter, FilterRenderProps, FilterPostBody, FilterModule, FilterSet, FilterValues, FilterHooks, FilterMap, FilterSectionHeaderProps, FilterMode, Location, UrlParameters, UpdateHistory, ContextSwitchMenuValue, ContextSwitchMenuProps, FilterBarProps, FilterJSONConfirmationModalProps, FilterJSONInputProps, FilterComponentProps, FilterContainerProps, AdditionalJSONFilterOptions, DoubleMultiSelectData, DoubleMultiSelectOptions, DoubleMultiSelectValues, DoubleMultiSelectFilterProps, DoubleMultiSelectFilterOptions, ListFilterOverrides, MultiSelectFilterProps, MultiSelectFilterOptions, RadioFilterProps, RadioFilterOptions, SingleSelectFilterProps, SingleSelectFilterOptions, TextFilterOverrides, AdditionalJSONFilter, DoubleMultiSelectFilter, ListFilter, MultiSelectFilter, RadioFilter, SingleSelectFilter, TextFilter, DurationFilter, MinMaxFilter, MinMaxInput, Header, IconButton, Input, InputProps, ItemGrid, ItemGridProps, ItemResults, ItemResultsProps, Loading, LoadingProps, MaskableImage, MaskableImageProps, ImageTagProps, Modal, ConfirmationModal, ConfirmationModalProps, ModalProps, ModeSelector, ModeSelectorProps, ModeSelectorLegendRowProps, Page, PageProps, PlaybackBar, PlaybackBarProps, HighlightsProp, usePopover, UsePopoverProps, PortalStyles, PopoverContent, ProgressBar, ProgressBarProps, CircularProgress, CircularProgressProps, DeviceProgressBar, DeviceProgressProps, DeviceProgressBarThreshold, PropertyList, Property, PropertyListProps, PropertyListVariable, RadioGroup, RadioGroupProps, RefreshToolbar, RefreshToolbarProps, Select, SelectProps, SELECT_OVERLAY_STYLES, SelectOverlayStyles, SelectPopover, SelectPopoverProps, SelectPopoverOption, Snackbar, SnackbarProps, MESSAGE_TYPES as SNACKBAR_MESSAGE_TYPES, SpeedInput, SpeedInputProps, SpeedInputVehicleSpeed, SpeedInputVehicleSpeedMode, StackBanner, StackBannerProps, StackBannerRow, StackBannerRowProps, StatusTable, StatusCard, StatusCardProps, StatusCellBadge, StatusCellBadgeProps, StatusRow, StatusRowProps, Status, StatusTableProps, StatusTableHeader, useStatusTable, StatusTableHooks, StatusTableOptions, filterData, getCompareFormat, mapTableFilters, sortData, SortOptions, sortByField, StepFunctionGraph, StepFunctionGraphProps, Table, TableProps, TableSortByOptions, Tabs, TabProps, TextArea, TextAreaProps, Toggle, ToggleProps, TransferList, ListItem, TransferListProps, TypeaheadSearch, TypeaheadSearchResultProps, TypeaheadSearchProps, TypeaheadResultItem, LAKEFRONT_COLORS as colors, THEME as theme, SelectOption, TabDef };
|