@qualtrics/ui-react 2.31.0 → 2.32.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +78 -13
- package/dist/__shared/cjs/{index-434a3b72.js → index-2694aefb.js} +297 -223
- package/dist/__shared/cjs/{index-c13fc74c.js → index-b8635002.js} +39 -4
- package/dist/components/Accordion/Accordion2.js +3 -3
- package/dist/components/Banner/Banner.css.js +12 -13
- package/dist/components/Banner/Banner.css.ts.vanilla.js +3 -3
- package/dist/components/Banner/Banner.js +2 -3
- package/dist/components/Button/Button.js +3 -3
- package/dist/components/ButtonGroup/ButtonGroup2.js +3 -3
- package/dist/components/Checkbox/Checkbox2.js +3 -3
- package/dist/components/ColorPicker/ColorPicker2.js +3 -3
- package/dist/components/Combobox/Combobox.js +0 -1
- package/dist/components/Combobox/Combobox2.js +3 -3
- package/dist/components/ConfigPane/ConfigPane2.js +3 -3
- package/dist/components/Divider/Divider2.js +3 -3
- package/dist/components/Dropdown/Dropdown.js +0 -2
- package/dist/components/Dropdown/Dropdown2.js +3 -3
- package/dist/components/Dropdown/DropdownButton.js +2 -3
- package/dist/components/FilePicker/FilePicker2.js +3 -3
- package/dist/components/FormField/Caption.js +3 -3
- package/dist/components/FormField/FormField2.js +3 -3
- package/dist/components/FullScreenTakeover/FullScreenTakeover2.js +3 -3
- package/dist/components/Icon/IconTypes.js +9 -0
- package/dist/components/IconButton/IconButton.js +0 -1
- package/dist/components/IconButton/IconButton2.js +3 -3
- package/dist/components/InlineInput/InlineInput2.js +3 -3
- package/dist/components/Input/Input2.js +3 -3
- package/dist/components/InputGroup/InputGroup2.js +3 -3
- package/dist/components/Label/Label2.js +3 -3
- package/dist/components/Link/Link2.js +3 -3
- package/dist/components/LoadingSpinner/LoadingSpinner2.js +3 -3
- package/dist/components/LogicEditor/LogicEditor2.js +3 -3
- package/dist/components/Modal/Modal.js +1 -1
- package/dist/components/Modal/Modal2.js +3 -3
- package/dist/components/NewMenu/BaseMenu.js +13 -7
- package/dist/components/NewMenu/NewMenu.js +3 -3
- package/dist/components/NewMenu/parts/ArrowNav/ArrowNav.js +81 -38
- package/dist/components/NewMenu/parts/MenuItem.js +16 -5
- package/dist/components/NumberStepper/NumberStepper2.js +3 -3
- package/dist/components/PageLayout/PageLayout.js +3 -3
- package/dist/components/Pagination/Pagination2.js +3 -3
- package/dist/components/Popover/Popover2.js +3 -3
- package/dist/components/QuickSearch/QuickSearch2.js +3 -3
- package/dist/components/Radio/Radio2.js +3 -3
- package/dist/components/SearchInput/SearchInput.js +0 -1
- package/dist/components/SearchInput/SearchInput2.js +3 -3
- package/dist/components/SidebarNav/SidebarNav.js +1 -0
- package/dist/components/SidebarNav/SidebarNav2.js +3 -3
- package/dist/components/Slider/Slider2.js +3 -3
- package/dist/components/Switch/Switch2.js +3 -3
- package/dist/components/Table/Table2.js +3 -3
- package/dist/components/Tabs/Tab.js +0 -2
- package/dist/components/Tabs/TabList.js +0 -4
- package/dist/components/Tabs/Tabs2.js +3 -3
- package/dist/components/Tooltip/Tooltip.js +1 -2
- package/dist/components/Tooltip/Tooltip2.js +3 -3
- package/dist/components/deprecated_ColorPicker/ColorPicker2.js +3 -3
- package/dist/components/deprecated_NumberStepper/NumberStepper2.js +3 -3
- package/dist/components/deprecated_Tabs/Tabs2.js +3 -3
- package/dist/components/deprecated_Toolbar/Toolbar2.js +3 -3
- package/dist/hooks/useOverlay/useOverlay2.js +3 -3
- package/dist/hooks/useScreenReaderAnnouncement/useScreenReaderAnnouncement2.js +3 -3
- package/dist/icons/Icon.js +3 -3
- package/dist/icons/components/AIEntityIcon.js +6 -0
- package/dist/icons/components/AISparkIcon.js +6 -0
- package/dist/icons/components/ButtonSelectorIcon.js +6 -0
- package/dist/icons/components/DropListSelectorIcon.js +6 -0
- package/dist/icons/components/HeatMapDiscoverIcon.js +6 -0
- package/dist/icons/components/HighlightPenSwatchIcon.js +6 -0
- package/dist/icons/components/HighlightSwatchIcon.js +6 -0
- package/dist/icons/components/MetricWidgetIcon.js +6 -0
- package/dist/icons/components/SearchSelectorIcon.js +6 -0
- package/dist/icons/createIconComponent.js +0 -1
- package/dist/icons/index.d.ts +24 -0
- package/dist/icons/index.es.js +9 -0
- package/dist/icons/index.js +10 -1
- package/dist/index.d.ts +1308 -154
- package/dist/index.es.js +1 -1
- package/dist/index.js +5 -3
- package/dist/next/AdvancedTable/AdvancedTable.js +0 -5
- package/dist/next/AdvancedTable/AdvancedTable2.js +3 -3
- package/dist/next/AdvancedTable/AdvancedTableCell.js +0 -1
- package/dist/next/CollapsibleSearchInput/CollapsibleSearchInput2.js +3 -3
- package/dist/next/Combobox/Combobox2.js +3 -3
- package/dist/next/Combobox/ComboboxFlyout.js +0 -1
- package/dist/next/Combobox/ComboboxInput.js +0 -1
- package/dist/next/Combobox/hooks/useShouldRenderGroupHeader/useShouldRenderGroupHeader.js +0 -1
- package/dist/next/Drawer/Drawer.js +0 -1
- package/dist/next/Drawer/Drawer2.js +3 -3
- package/dist/next/FilterAnchor/FilterAnchor2.js +3 -3
- package/dist/next/Form/FormFields/InputField.js +3 -3
- package/dist/next/Input/Input.js +0 -1
- package/dist/next/Input/Input2.js +3 -3
- package/dist/next/Menu/Hooks/useCSSVariable.js +5 -5
- package/dist/next/Menu/Hooks/useMaskDimensions.js +10 -12
- package/dist/next/Menu/Hooks/usePaneSearch.js +2 -4
- package/dist/next/Menu/Menu.js +21 -8
- package/dist/next/Menu/Menu2.js +3 -3
- package/dist/next/Menu/MenuPane.js +55 -18
- package/dist/next/Menu/PaneChildren.js +6 -3
- package/dist/next/Menu/SubMenu.js +11 -7
- package/dist/next/Menu/constants.js +4 -1
- package/dist/next/PhoneNumberInput/PhoneNumberInput2.js +3 -3
- package/dist/next/Select/Select2.js +3 -3
- package/dist/next/SplitButton/SplitButton.js +2 -2
- package/dist/next/SplitButton/SplitButton2.js +3 -3
- package/dist/next/Stack/StackItem.js +3 -3
- package/dist/next/TimePicker/TimePicker2.js +3 -3
- package/dist/next/ToggleButton/styles.js +3 -3
- package/dist/next/index.d.ts +531 -32
- package/dist/next/index.js +172 -149
- package/dist/utils/Flyout/Flyout2.js +3 -3
- package/dist/utils/Text/Text.js +2 -2
- package/dist/utils/TextOverflowTooltip/TextOverflowTooltip.js +0 -1
- package/dist/utils/constants.js +0 -1
- package/icons/package.json +1 -1
- package/next/package.json +2 -2
- package/package.json +8 -5
package/dist/index.d.ts
CHANGED
|
@@ -6,7 +6,6 @@ import type { ClipboardEvent as ClipboardEvent_2 } from 'react';
|
|
|
6
6
|
import { ComponentPropsWithRef } from 'react';
|
|
7
7
|
import { ComputedPlacement } from '@popperjs/core';
|
|
8
8
|
import { CountryCode } from 'libphonenumber-js';
|
|
9
|
-
import { FocusEventHandler } from 'react';
|
|
10
9
|
import type { FormEvent } from 'react';
|
|
11
10
|
import type { KeyboardEvent as KeyboardEvent_2 } from 'react';
|
|
12
11
|
import type { MouseEvent as MouseEvent_2 } from 'react';
|
|
@@ -24,34 +23,59 @@ export declare const Accordion: React_2.ForwardRefExoticComponent<AccordionProps
|
|
|
24
23
|
export declare const AccordionHeader: React_2.ForwardRefExoticComponent<AccordionHeaderProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
25
24
|
|
|
26
25
|
export declare interface AccordionHeaderProps {
|
|
26
|
+
/** The content to display in the header button */
|
|
27
27
|
children: React_2.ReactNode;
|
|
28
28
|
}
|
|
29
29
|
|
|
30
30
|
export declare const AccordionPanel: React_2.ForwardRefExoticComponent<AccordionPanelProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
31
31
|
|
|
32
32
|
export declare interface AccordionPanelProps {
|
|
33
|
-
|
|
33
|
+
/** The content to display in the panel */
|
|
34
34
|
children: React_2.ReactNode;
|
|
35
|
+
/** Forwarded to `AccordionPanel` `div` for applying styles */
|
|
36
|
+
className?: string;
|
|
35
37
|
}
|
|
36
38
|
|
|
37
39
|
export declare interface AccordionProps {
|
|
40
|
+
/** List of `AccordionSection` components */
|
|
41
|
+
children: React_2.ReactNode;
|
|
42
|
+
/** The heading level assigned to the header of each section */
|
|
38
43
|
headingLevel: 1 | 2 | 3 | 4 | 5 | 6 | null;
|
|
44
|
+
/** Specifies a styling theme
|
|
45
|
+
* @defaultValue 'default'*/
|
|
39
46
|
variant?: 'default' | 'outlined' | 'block';
|
|
47
|
+
/** Allows multiple sections to be open at the same time
|
|
48
|
+
* @defaultValue false */
|
|
40
49
|
isMultiOpen?: boolean;
|
|
50
|
+
/** An array of section ids that should be open by default
|
|
51
|
+
* @defaultValue [] */
|
|
41
52
|
initialOpenSectionIds?: string[];
|
|
53
|
+
/** An array of section ids that are currently open */
|
|
42
54
|
openSectionIds?: string[];
|
|
55
|
+
/** Handler to be called whenever a section opens or closes */
|
|
43
56
|
onOpenSectionIdsChange?: (newOpenSectionIds: string[]) => void;
|
|
57
|
+
/** Added to the containing `div` element and to each
|
|
58
|
+
* `AccordionHeader` and `AccordionPanel` component with a suffix:
|
|
59
|
+
* - `AccordionHeader`: `-section-0-header`
|
|
60
|
+
* - `AccordionPanel`: `-section-0-panel`
|
|
61
|
+
*
|
|
62
|
+
* Note: the number in each `data-testid` will correspond with that section's position in the `Accordion` */
|
|
44
63
|
'data-testid'?: string;
|
|
45
|
-
children: React_2.ReactNode;
|
|
46
64
|
}
|
|
47
65
|
|
|
48
66
|
export declare const AccordionSection: React_2.ForwardRefExoticComponent<AccordionSectionProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
49
67
|
|
|
50
68
|
export declare interface AccordionSectionProps {
|
|
69
|
+
/** The `AccordionHeader` and `AccordionPanel` components */
|
|
70
|
+
children: React_2.ReactNode;
|
|
71
|
+
/** Unique identifier for an `AccordionSection`. Used with `openSectionIds`
|
|
72
|
+
* and `onOpenSectionIdsChange` to manually control `Accordion` state. */
|
|
51
73
|
id?: string;
|
|
74
|
+
/** @internal */
|
|
52
75
|
position?: number;
|
|
76
|
+
/** Disables interaction with the section's header
|
|
77
|
+
* @defaultValue false */
|
|
53
78
|
isDisabled?: boolean;
|
|
54
|
-
children: React_2.ReactNode;
|
|
55
79
|
}
|
|
56
80
|
|
|
57
81
|
export declare const Banner: ({ onClose, icon, status, "data-testid": dataTestId, children, }: BannerProps) => JSX.Element;
|
|
@@ -79,16 +103,21 @@ export declare interface BannerFooterProps {
|
|
|
79
103
|
}
|
|
80
104
|
|
|
81
105
|
export declare interface BannerProps {
|
|
106
|
+
/** The banner parts provided as children. */
|
|
107
|
+
children: React_2.ReactNode;
|
|
82
108
|
/** The function to be called when close button is pressed. Exclude this property to make a non-dismissible banner. */
|
|
83
109
|
onClose?: () => void;
|
|
84
110
|
/** The status of the UI banner. Each status automatically sets a default icon. The `icon` prop is not required. */
|
|
85
111
|
status?: 'info' | 'warn' | 'error' | 'success';
|
|
86
112
|
/** Icon to use in banner.*/
|
|
87
113
|
icon?: IconComponent;
|
|
88
|
-
/**
|
|
114
|
+
/**
|
|
115
|
+
* Added to the containing `div` element and to each `BannerTitle`, `BannerBody`, and `BannerFooter` component with a suffix:
|
|
116
|
+
* - `BannerTitle`: `-title`
|
|
117
|
+
* - `BannerBody`: `-body`
|
|
118
|
+
* - `BannerFooter`: `-footer`
|
|
119
|
+
*/
|
|
89
120
|
'data-testid'?: string;
|
|
90
|
-
/** The banner parts provided as children. */
|
|
91
|
-
children: React_2.ReactNode;
|
|
92
121
|
}
|
|
93
122
|
|
|
94
123
|
export declare const BannerTitle: ({ children }: {
|
|
@@ -128,10 +157,16 @@ export declare const Button: React_2.ForwardRefExoticComponent<ButtonProps & Rea
|
|
|
128
157
|
export declare const ButtonGroup: React_2.ForwardRefExoticComponent<ButtonGroupProps & React_2.RefAttributes<HTMLSpanElement>>;
|
|
129
158
|
|
|
130
159
|
export declare interface ButtonGroupProps extends React_2.AllHTMLAttributes<HTMLSpanElement> {
|
|
160
|
+
/** List of `Button` components or other React nodes. */
|
|
131
161
|
children: React_2.ReactNode;
|
|
132
|
-
|
|
162
|
+
/** Makes the `ButtonGroup` take the width of its parent and makes its children grow to fill the space.
|
|
163
|
+
* @defaultValue false */
|
|
133
164
|
full?: boolean;
|
|
165
|
+
/** Makes the `ButtonGroup` and all of its children smaller.
|
|
166
|
+
* @defaultValue false */
|
|
134
167
|
small?: boolean;
|
|
168
|
+
/** Appended to internal classes on the containing `span` element. */
|
|
169
|
+
className?: string;
|
|
135
170
|
[prop: string]: any;
|
|
136
171
|
}
|
|
137
172
|
|
|
@@ -169,30 +204,67 @@ export declare const Checkbox: React_2.ForwardRefExoticComponent<CheckboxProps &
|
|
|
169
204
|
export declare const CheckboxField: React_2.ForwardRefExoticComponent<CheckboxFieldProps & React_2.RefAttributes<HTMLLabelElement>>;
|
|
170
205
|
|
|
171
206
|
export declare interface CheckboxFieldProps extends Omit<React_2.AllHTMLAttributes<HTMLLabelElement>, 'label' | 'onChange' | 'checked' | 'defaultChecked'> {
|
|
172
|
-
|
|
207
|
+
/** Label to accompany the checkbox. */
|
|
173
208
|
label: React_2.ReactNode;
|
|
209
|
+
/** The state of whether the checkbox is checked or not.
|
|
210
|
+
* Requires use of `onChange` prop. Cannot be used with `defaultChecked`. */
|
|
174
211
|
checked?: CheckboxProps['checked'];
|
|
212
|
+
/** The initial value of an uncontrolled checkbox. Cannot be used with `checked` prop. */
|
|
175
213
|
defaultChecked?: CheckboxProps['defaultChecked'];
|
|
176
|
-
|
|
214
|
+
/** Disables change events on the checkbox and styles it to look as though it cannot be clicked.
|
|
215
|
+
* @defaultValue false */
|
|
177
216
|
disabled?: CheckboxProps['disabled'];
|
|
217
|
+
/** Identifier for the `input` element. Commonly used in forms with a label. */
|
|
218
|
+
id?: CheckboxProps['id'];
|
|
219
|
+
/** Change handler to be fired when the checkbox state changes. */
|
|
220
|
+
onChange?: CheckboxProps['onChange'];
|
|
221
|
+
/** The value of the component. */
|
|
178
222
|
value?: CheckboxProps['value'];
|
|
223
|
+
/** Appended to internal classes on the containing `Label` component. */
|
|
179
224
|
className?: CheckboxProps['className'];
|
|
225
|
+
/** Props forwarded to the `input` element. */
|
|
180
226
|
inputProps?: CheckboxProps['inputProps'];
|
|
227
|
+
/** The id of an element that describes the `Checkbox`. */
|
|
181
228
|
'aria-describedby'?: CheckboxProps['aria-describedby'];
|
|
182
229
|
}
|
|
183
230
|
|
|
184
231
|
export declare interface CheckboxProps extends Omit<React_2.AllHTMLAttributes<HTMLSpanElement>, 'checked' | 'defaultChecked'> {
|
|
185
|
-
|
|
186
|
-
|
|
232
|
+
/** The state of whether the checkbox is checked or not.
|
|
233
|
+
* Requires use of 'onChange' prop. Cannot be used with 'defaultChecked'. */
|
|
187
234
|
checked?: boolean | 'mixed';
|
|
235
|
+
/** The initial value of an uncontrolled checkbox. Cannot be used with 'checked' prop. */
|
|
188
236
|
defaultChecked?: boolean | 'mixed';
|
|
237
|
+
/** Disables change events on the checkbox and styles it to look as though it cannot be clicked.
|
|
238
|
+
* @defaultValue false */
|
|
189
239
|
disabled?: boolean;
|
|
240
|
+
/** Identifier for the input element. Commonly used in forms with a label. */
|
|
241
|
+
id?: string;
|
|
242
|
+
/** Change handler to be fired when the checkbox state changes.
|
|
243
|
+
* The event that triggers the change is passed as the first parameter. */
|
|
190
244
|
onChange?: (event: React_2.ChangeEvent<HTMLInputElement>) => void;
|
|
245
|
+
/** The value of the component. */
|
|
191
246
|
value?: string;
|
|
247
|
+
/** Appended to internal classes on the containing `span` element. */
|
|
248
|
+
className?: string;
|
|
249
|
+
/**
|
|
250
|
+
* Unique name for use with forms.
|
|
251
|
+
*
|
|
252
|
+
* See [Form API](../../form/getting-started) for more information.
|
|
253
|
+
*/
|
|
192
254
|
name?: string;
|
|
255
|
+
/** Provides a label for the `Checkbox` */
|
|
256
|
+
label?: string;
|
|
257
|
+
/** Props forwarded to the `input` element. */
|
|
193
258
|
inputProps?: Omit<ComponentPropsWithRef<'input'>, 'type'>;
|
|
259
|
+
/** Adds an error message directly below the `Checkbox` */
|
|
260
|
+
errorText?: ReactNode;
|
|
261
|
+
/** Adds additional information directly below the `Checkbox` */
|
|
262
|
+
helperText?: ReactNode;
|
|
263
|
+
/** An accessible label for the `Checkbox` that is used by screen readers. */
|
|
194
264
|
'aria-label'?: string;
|
|
265
|
+
/** The id of an element that acts as a label for the `Checkbox`. */
|
|
195
266
|
'aria-labelledby'?: string;
|
|
267
|
+
/** The id of an element that describes the `Checkbox`. */
|
|
196
268
|
'aria-describedby'?: string;
|
|
197
269
|
[prop: string]: any;
|
|
198
270
|
}
|
|
@@ -206,21 +278,80 @@ export declare interface Color {
|
|
|
206
278
|
export declare function ColorPicker({ color: externalColor, onChange, palette, isAlphaEnabled, hideHSVSelector, hideFlyoutInputs, isDisabled, id, buttonRef: externalButtonRef, inputRef: externalInputRef, 'aria-label': ariaLabel, 'aria-labelledby': ariaLabelledBy, 'aria-describedby': ariaDescribedBy, zIndex, 'data-testid': dataTestId, }: ColorPickerProps): JSX.Element;
|
|
207
279
|
|
|
208
280
|
export declare interface ColorPickerProps {
|
|
281
|
+
/** An object containing the current color state.
|
|
282
|
+
* - `hex`: A 6-character hexadecimal color code, prefixed with `#`
|
|
283
|
+
* - `name`: An accessible name for the color
|
|
284
|
+
* - `alpha`: A number between 0 and 100 representing the opacity of the color
|
|
285
|
+
*/
|
|
209
286
|
color: Color;
|
|
287
|
+
/** Handler to be called whenever color changes */
|
|
210
288
|
onChange: (newColor: Color) => void;
|
|
289
|
+
/** A list of pre-configured color objects presented as swatches
|
|
290
|
+
* @defaultValue DEFAULT_COLOR_PALETTE
|
|
291
|
+
*/
|
|
211
292
|
palette?: Color[];
|
|
293
|
+
/** Adds controls for setting color transparency
|
|
294
|
+
* @defaultValue false
|
|
295
|
+
*/
|
|
212
296
|
isAlphaEnabled?: boolean;
|
|
297
|
+
/** Removes HSV selector from the flyout
|
|
298
|
+
* @defaultValue false
|
|
299
|
+
*/
|
|
300
|
+
hideHSVSelector?: boolean;
|
|
301
|
+
/** Removes hex and RGB inputs from the flyout
|
|
302
|
+
* @defaultValue false
|
|
303
|
+
*/
|
|
304
|
+
hideFlyoutInputs?: boolean;
|
|
305
|
+
/** Disables user interactions with the component
|
|
306
|
+
* @defaultValue false
|
|
307
|
+
*/
|
|
213
308
|
isDisabled?: boolean;
|
|
309
|
+
/** Unique identifier for the `ColorPicker`
|
|
310
|
+
* @defaultValue false
|
|
311
|
+
*/
|
|
214
312
|
id?: string;
|
|
313
|
+
/** Ref to be assigned to the `ColorPicker`'s anchor button
|
|
314
|
+
*/
|
|
215
315
|
buttonRef?: React_2.Ref<HTMLButtonElement>;
|
|
316
|
+
/** Ref to be assigned to the `ColorPicker`'s input field
|
|
317
|
+
*/
|
|
216
318
|
inputRef?: React_2.Ref<HTMLInputElement | HTMLTextAreaElement>;
|
|
319
|
+
/** The z-index of the flyout
|
|
320
|
+
* @defaultValue 1000
|
|
321
|
+
*/
|
|
322
|
+
zIndex?: number;
|
|
323
|
+
/** Accessible label for the `ColorPicker`
|
|
324
|
+
*/
|
|
217
325
|
'aria-label'?: string;
|
|
326
|
+
/** Id of the element that serves as the accessible label for the `ColorPicker`
|
|
327
|
+
* @defaultValue false
|
|
328
|
+
*/
|
|
218
329
|
'aria-labelledby'?: string;
|
|
330
|
+
/** Id of the element that serves as the description for the `ColorPicker`
|
|
331
|
+
* @defaultValue false
|
|
332
|
+
*/
|
|
219
333
|
'aria-describedby'?: string;
|
|
220
|
-
|
|
334
|
+
/** Added to the containing `span`, and to main sub-components with the following suffixes
|
|
335
|
+
* - `-anchor-button`: assigned to the top level button that opens the flyout
|
|
336
|
+
* - `-hex-input`: assigned to the top level hex text input
|
|
337
|
+
* - `-flyout`: assigned to the flyout container
|
|
338
|
+
* - `-saturation-grid`: assigned to the saturation slider container
|
|
339
|
+
* - `-saturation-thumb`: assigned to the moveable saturation slider element
|
|
340
|
+
* - `-flyout-color-preview`: assigned to the color swatch in the flyout next to the hue slider
|
|
341
|
+
* - `-hue-rail`: assigned to the hue slider container
|
|
342
|
+
* - `-hue-thumb`: assigned to the moveable hue slider element
|
|
343
|
+
* - `-alpha-rail`: assied to the alpha slider container
|
|
344
|
+
* - `-alpha-thumb`: assigned to the moveable alpha slider element. Only available while `isAlphaEnabled`
|
|
345
|
+
* - `-flyout-hex-input`: assigned to the hex text input inside the flyout
|
|
346
|
+
* - `-R-channel`: assigned to the red channel text input
|
|
347
|
+
* - `-G-channel`: assigned to the green channel text input
|
|
348
|
+
* - `-B-channel`: assigned to the blue channel text input
|
|
349
|
+
* - `-alpha-channel`: assigned to the alpha channel text input. Only available while `isAlphaEnabled`
|
|
350
|
+
* - `-palette`: assigned to the palette container
|
|
351
|
+
* - `-__HEX__-swatch`: assigned to each individual swatch. `__HEX__` should be replaced by
|
|
352
|
+
* the color's 6-character hex with the leading `#` removed.
|
|
353
|
+
*/
|
|
221
354
|
'data-testid'?: string;
|
|
222
|
-
hideHSVSelector?: boolean;
|
|
223
|
-
hideFlyoutInputs?: boolean;
|
|
224
355
|
}
|
|
225
356
|
|
|
226
357
|
export declare const Combobox: React_2.ForwardRefExoticComponent<ComboboxProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
@@ -228,7 +359,9 @@ export declare const Combobox: React_2.ForwardRefExoticComponent<ComboboxProps &
|
|
|
228
359
|
export declare const ComboboxHeader: React_2.ForwardRefExoticComponent<ComboboxHeaderProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
229
360
|
|
|
230
361
|
export declare interface ComboboxHeaderProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
362
|
+
/** The name of the header for grouping options. */
|
|
231
363
|
title: string;
|
|
364
|
+
/** The relevant `ComboboxOption` components for the group. */
|
|
232
365
|
children?: ReactNode;
|
|
233
366
|
[prop: string]: any;
|
|
234
367
|
}
|
|
@@ -236,14 +369,23 @@ export declare interface ComboboxHeaderProps extends React_2.AllHTMLAttributes<H
|
|
|
236
369
|
export declare const ComboboxInput: React_2.ForwardRefExoticComponent<ComboboxInputProps & React_2.RefAttributes<HTMLInputElement>>;
|
|
237
370
|
|
|
238
371
|
export declare interface ComboboxInputProps extends Omit<React_2.AllHTMLAttributes<HTMLInputElement>, 'type'> {
|
|
372
|
+
/** Overrides the `aria-label` prop passed into `Combobox`. */
|
|
373
|
+
'aria-label'?: string;
|
|
374
|
+
/** Overrides the `aria-labelledby` prop passed into `Combobox`. */
|
|
375
|
+
'aria-labelledby'?: string;
|
|
239
376
|
[prop: string]: any;
|
|
240
377
|
}
|
|
241
378
|
|
|
242
379
|
export declare const ComboboxList: React_2.ForwardRefExoticComponent<ComboboxListProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
243
380
|
|
|
244
381
|
export declare interface ComboboxListProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
382
|
+
/** The displayed `ComboboxOption`s and `ComboboxHeader`s in the list. */
|
|
245
383
|
children?: React_2.ReactNode;
|
|
384
|
+
/** Where to prioritize placement of the `ComboboxList` relative to the `ComboboxInput`.
|
|
385
|
+
* @defaultValue 'bottom-start'
|
|
386
|
+
*/
|
|
246
387
|
placement?: ComputedPlacement;
|
|
388
|
+
/** The container element where the `ComboboxList` should be rendered. Overrides the default set by [`UIProvider`](/components/ui-provider). */
|
|
247
389
|
portalTarget?: HTMLElement;
|
|
248
390
|
[prop: string]: any;
|
|
249
391
|
}
|
|
@@ -251,49 +393,111 @@ export declare interface ComboboxListProps extends React_2.AllHTMLAttributes<HTM
|
|
|
251
393
|
export declare const ComboboxOption: React_2.ForwardRefExoticComponent<ComboboxOptionProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
252
394
|
|
|
253
395
|
export declare interface ComboboxOptionProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
396
|
+
/** Used to display non-string options to the user. */
|
|
254
397
|
children?: React_2.ReactNode;
|
|
398
|
+
/** The unique value associated with the option. */
|
|
255
399
|
value: string | number;
|
|
400
|
+
/** The string representation to display the option to the user. */
|
|
256
401
|
label: string;
|
|
402
|
+
/** Handler to be called when the option is selected by a click on the option itself or by a keyboard event on the `ComboboxInput`. */
|
|
257
403
|
onSelect?: React_2.ReactEventHandler<HTMLDivElement>;
|
|
258
404
|
[prop: string]: any;
|
|
259
405
|
}
|
|
260
406
|
|
|
261
407
|
export declare interface ComboboxProps extends Omit<React_2.AllHTMLAttributes<HTMLDivElement>, 'onChange' | 'value' | 'defaultValue'> {
|
|
408
|
+
/** The `ComboboxInput` and `ComboboxList`.
|
|
409
|
+
*/
|
|
262
410
|
children?: React_2.ReactNode;
|
|
263
|
-
|
|
411
|
+
/** The initially selected value of the Combobox.
|
|
412
|
+
* @defaultValue ''
|
|
413
|
+
*/
|
|
264
414
|
defaultValue?: string | number | null;
|
|
415
|
+
/** The selected value of the Combobox. */
|
|
416
|
+
value?: string | number | null;
|
|
417
|
+
/** Handler to be called whenever a new value is selected for the combobox. */
|
|
418
|
+
onChange?: (value: string | number | null) => void;
|
|
419
|
+
/** Disable the combobox input and icon button. */
|
|
265
420
|
disabled?: boolean;
|
|
266
|
-
|
|
421
|
+
/** The valid state of the combobox
|
|
422
|
+
* @defaultValue false
|
|
423
|
+
*/
|
|
267
424
|
isInvalid?: boolean;
|
|
268
|
-
|
|
269
|
-
|
|
425
|
+
/** If false, options/headers will be filtered by a case-insenstitive comparison to the current input value. If true, options/headers will not be filtered.
|
|
426
|
+
* @defaultValue false
|
|
427
|
+
*/
|
|
428
|
+
isFilteringDisabled?: boolean;
|
|
429
|
+
/** Used to control the opened/closed state of the list of options. */
|
|
270
430
|
isOpen?: boolean;
|
|
431
|
+
/** Handler to be called whenever the combobox list is opened/closed. */
|
|
271
432
|
onIsOpenChange?: (isOpen: boolean) => void;
|
|
272
|
-
|
|
273
|
-
|
|
433
|
+
/** If true, an option will automatically be selected when the combobox loses focus if the current input value matches one of the options.
|
|
434
|
+
* @defaultValue true
|
|
435
|
+
*/
|
|
436
|
+
unstable_autoSelect?: boolean;
|
|
437
|
+
/** If true, don't require the text input to match an option when it loses focus. This allows the input to have any value.
|
|
438
|
+
* @defaultValue false
|
|
439
|
+
*/
|
|
440
|
+
unstable_freeForm?: boolean;
|
|
441
|
+
/** Show a loading spinner instead of options. Useful for asynchrously getting options.
|
|
442
|
+
* @defaultValue false
|
|
443
|
+
*/
|
|
444
|
+
unstable_isLoading?: boolean;
|
|
445
|
+
/** If true, highlighting an option using the keyboard will select the option. This prop sets `isFilteringDisabled` to `true`.
|
|
446
|
+
* @defaultValue false
|
|
447
|
+
*/
|
|
274
448
|
unstable_isOptionSelectedOnKeyboardHighlight?: boolean;
|
|
275
|
-
|
|
449
|
+
/** Forwarded to `ComboboxInput` and `ComboboxList`. */
|
|
276
450
|
'aria-label'?: string;
|
|
451
|
+
/** Forwarded to `ComboboxInput` and `ComboboxList`. */
|
|
277
452
|
'aria-labelledby'?: string;
|
|
453
|
+
/** Appended to internal classes on the containing `div` element.
|
|
454
|
+
*/
|
|
455
|
+
className?: string;
|
|
278
456
|
[prop: string]: any;
|
|
279
457
|
}
|
|
280
458
|
|
|
281
459
|
export declare const ConfigPane: React_2.FunctionComponent<ConfigPaneProps>;
|
|
282
460
|
|
|
283
461
|
export declare interface ConfigPaneProps {
|
|
284
|
-
|
|
462
|
+
/** The content of the config pane */
|
|
285
463
|
children?: ReactNode;
|
|
286
|
-
|
|
464
|
+
/** Title for the config pane */
|
|
287
465
|
title?: ReactNode;
|
|
466
|
+
/** Adds controls for setting open state
|
|
467
|
+
* @defaultValue true */
|
|
288
468
|
isOpen?: boolean;
|
|
469
|
+
/** Handler to be called whenever `isOpen` changes */
|
|
289
470
|
onIsOpenChange?: (newIsOpen: boolean) => void;
|
|
471
|
+
/** Hides the button that opens and closes the pane
|
|
472
|
+
* @defaultValue false */
|
|
290
473
|
hideOpenButton?: boolean;
|
|
474
|
+
/** Adds controls for setting pinned state
|
|
475
|
+
* @defaultValue true */
|
|
291
476
|
isPinned?: boolean;
|
|
477
|
+
/** Handler to be called whenever `isPinned` changes */
|
|
292
478
|
onIsPinnedChange?: (newIsPinned: boolean) => void;
|
|
479
|
+
/** Hides the button that pins the pane
|
|
480
|
+
* @defaultValue false */
|
|
293
481
|
hidePinButton?: boolean;
|
|
482
|
+
/** Leaves a little extra white space when the panel is closed.
|
|
483
|
+
* Meant to be used when the panel is placed on the far left side of the view port
|
|
484
|
+
* (i.e. when used without a navigation sidebar)
|
|
485
|
+
* @defaultValue false */
|
|
486
|
+
shouldShowPanelPreview?: boolean;
|
|
487
|
+
/** Id applied to the config pane container aside */
|
|
488
|
+
id?: string;
|
|
489
|
+
/** A string used as the name of the `ConfigPane` for accessibility contexts */
|
|
294
490
|
'aria-label'?: string;
|
|
491
|
+
/** The id of an element that contains the accessible name for the `ConfigPane` */
|
|
295
492
|
'aria-labelledby'?: string;
|
|
493
|
+
/** The id of an element that adds additional information about the `ConfigPane` for accessibility contexts */
|
|
296
494
|
'aria-describedby'?: string;
|
|
495
|
+
/** Added to the containing aside, and to main sub-components with the following suffixes:
|
|
496
|
+
* - `-title`: assigned to the title container
|
|
497
|
+
* - `-pin-unpin-button`: assigned to the pin/unpin button
|
|
498
|
+
* - `-body`: assigned to the body content container
|
|
499
|
+
* - `-expand-collapse-button`: assigned to the expand/collapse button
|
|
500
|
+
*/
|
|
297
501
|
'data-testid'?: string;
|
|
298
502
|
}
|
|
299
503
|
|
|
@@ -403,13 +607,31 @@ export declare interface deprecated_ColorHsl {
|
|
|
403
607
|
export declare const deprecated_ColorPicker: React_2.ForwardRefExoticComponent<deprecated_ColorPickerProps & React_2.RefAttributes<HTMLButtonElement>>;
|
|
404
608
|
|
|
405
609
|
export declare interface deprecated_ColorPickerProps extends Omit<ButtonProps, 'onChange'> {
|
|
610
|
+
/** Added to the [Button](/components/button) component and to the hex sub-component, with its own suffix:
|
|
611
|
+
* Hex input: `-Hex`
|
|
612
|
+
* */
|
|
406
613
|
'data-testid'?: string;
|
|
614
|
+
/** Set a default color for the color picker. See [Color Formats](/deprecated/color-picker/#color-formats) for acceptable formats.
|
|
615
|
+
* @defaultValue '#000000'
|
|
616
|
+
*/
|
|
407
617
|
defaultColor?: string | deprecated_ColorHsb | deprecated_ColorHsl | deprecated_ColorRgb;
|
|
618
|
+
/** The color value for the color picker. Used for controlled component behavior. See [Color Formats](/deprecated/color-picker/#color-formats) for acceptable formats. */
|
|
408
619
|
color?: string | deprecated_ColorHsb | deprecated_ColorHsl | deprecated_ColorRgb;
|
|
620
|
+
/** Appended to internal classes on the [Button](/components/button) component. */
|
|
409
621
|
className?: string;
|
|
622
|
+
/** Adds an alpha slider to the color picker.
|
|
623
|
+
* @defaultValue false
|
|
624
|
+
*/
|
|
410
625
|
enableAlpha?: boolean;
|
|
626
|
+
/** Change handler to be called every time the color changes. */
|
|
411
627
|
onChange?: (color: deprecated_ColorResult, event: Event | MouseEvent_2 | TouchEvent_2 | KeyboardEvent_2 | ChangeEvent) => void;
|
|
628
|
+
/** Customize the swatches to be shown in the color picker.
|
|
629
|
+
* @defaultValue See 'Default Swatches' section above
|
|
630
|
+
*/
|
|
412
631
|
swatches?: string[];
|
|
632
|
+
/** The z-index of the color picker's popover content.
|
|
633
|
+
* @defaultValue 1000
|
|
634
|
+
*/
|
|
413
635
|
zIndex?: number;
|
|
414
636
|
[prop: string]: any;
|
|
415
637
|
}
|
|
@@ -446,8 +668,11 @@ export declare const deprecated_DEFAULT_SWATCH_COLORS: string[];
|
|
|
446
668
|
export declare const deprecated_NumberStepper: React_2.ForwardRefExoticComponent<deprecated_NumberStepperProps & React_2.RefAttributes<HTMLSpanElement>>;
|
|
447
669
|
|
|
448
670
|
export declare interface deprecated_NumberStepperButtonProps extends React_2.AllHTMLAttributes<HTMLButtonElement> {
|
|
671
|
+
/** Will not include the suffix from the NumberStepper component. */
|
|
449
672
|
'data-testid'?: string;
|
|
673
|
+
/** Appended to internal classes on the `button` element. */
|
|
450
674
|
className?: string;
|
|
675
|
+
/** Handler to be called when the button is clicked. */
|
|
451
676
|
onClick?: React_2.MouseEventHandler<HTMLButtonElement>;
|
|
452
677
|
[prop: string]: any;
|
|
453
678
|
}
|
|
@@ -486,34 +711,64 @@ export declare const deprecated_NumberStepperIncrement: React_2.ForwardRefExotic
|
|
|
486
711
|
export declare const deprecated_NumberStepperInput: React_2.ForwardRefExoticComponent<deprecated_NumberStepperInputProps & React_2.RefAttributes<HTMLInputElement>>;
|
|
487
712
|
|
|
488
713
|
export declare interface deprecated_NumberStepperInputProps extends React_2.AllHTMLAttributes<HTMLInputElement> {
|
|
714
|
+
/** Will not include the suffix from the NumberStepper component. */
|
|
489
715
|
'data-testid'?: string;
|
|
490
|
-
|
|
716
|
+
/** Appended to internal classes on the input element. */
|
|
491
717
|
className?: string;
|
|
718
|
+
/** An accessible label for the input to be used by screen readers. This prop overrides the `aria-label` prop in `NumberStepper`. */
|
|
492
719
|
'aria-label'?: string;
|
|
720
|
+
/** The id of an element that acts as a label for the input. This prop overrides the `aria-labelledby` prop in `NumberStepper`. */
|
|
493
721
|
'aria-labelledby'?: string;
|
|
722
|
+
/** The id of an element that describes the input. This prop overrides the `aria-describedby` prop in `NumberStepper`. */
|
|
494
723
|
'aria-describedby'?: string;
|
|
495
|
-
onKeyDown?: (event: React_2.KeyboardEvent<HTMLInputElement>) => void;
|
|
496
|
-
onFocus?: (event: React_2.FocusEvent<HTMLInputElement>) => void;
|
|
497
|
-
onBlur?: (event: React_2.FocusEvent<HTMLInputElement>) => void;
|
|
498
724
|
[prop: string]: any;
|
|
499
725
|
}
|
|
500
726
|
|
|
501
727
|
export declare interface deprecated_NumberStepperProps extends Omit<React_2.AllHTMLAttributes<HTMLSpanElement>, 'onChange'> {
|
|
728
|
+
/** Disables default interaction.
|
|
729
|
+
* @defaultValue false
|
|
730
|
+
*/
|
|
502
731
|
isDisabled?: boolean;
|
|
732
|
+
/** Added to the containing `span` element and to the main sub-components, each with their own suffix:
|
|
733
|
+
* NumberStepperDecrement: `-Decrement`
|
|
734
|
+
* NumberStepperIncrement: `-Increment`
|
|
735
|
+
* NumberStepperInput: `-Input` */
|
|
503
736
|
'data-testid'?: string;
|
|
737
|
+
/** Forwarded to `NumberStepperInput` as an id.
|
|
738
|
+
*/
|
|
504
739
|
inputId?: string;
|
|
740
|
+
/** Initial value of `NumberStepper`.
|
|
741
|
+
* @defaultValue 0
|
|
742
|
+
*/
|
|
505
743
|
defaultValue?: number | '';
|
|
744
|
+
/** Value of NumberStepper. Overrides defaultValue.
|
|
745
|
+
*/
|
|
506
746
|
value?: number | '';
|
|
747
|
+
/** A stepping interval to use when incrementing and decrementing.
|
|
748
|
+
* @defaultValue 1
|
|
749
|
+
*/
|
|
507
750
|
step?: number;
|
|
751
|
+
/** The minimum value to accept. Must be less than or equal to the max property. */
|
|
508
752
|
min?: number;
|
|
753
|
+
/** The maximum value to accept. Must be greater than or equal to the min property. */
|
|
509
754
|
max?: number;
|
|
755
|
+
/** The width of the component. Added to the containing span element.
|
|
756
|
+
* @defaultValue 120
|
|
757
|
+
*/
|
|
510
758
|
width?: number | string;
|
|
759
|
+
/** Appended to internal classes on the containing `span` element. */
|
|
511
760
|
className?: string;
|
|
761
|
+
/** An accessible label for NumberStepper to be used by screen readers. This prop is forwarded to the `NumberStepperInput`. */
|
|
512
762
|
'aria-label'?: string;
|
|
763
|
+
/** The id of an element that acts as a label for NumberStepper. This prop is forwarded to the `NumberStepperInput`. */
|
|
513
764
|
'aria-labelledby'?: string;
|
|
765
|
+
/** The id of an element that describes the NumberStepper. This prop is forwarded to the `NumberStepperInput`. */
|
|
514
766
|
'aria-describedby'?: string;
|
|
767
|
+
/** Appended to internal styles on the containing `span` element. */
|
|
515
768
|
style?: React_2.CSSProperties;
|
|
769
|
+
/** For advanced use cases when needing to access sub-components directly. Must contain `NumberStepperIncrement`, `NumberStepperDecrement`, and `NumberStepperInput` */
|
|
516
770
|
children?: React_2.ReactNode;
|
|
771
|
+
/** Handler to be called when the value changes */
|
|
517
772
|
onChange?: (value: number | '') => void;
|
|
518
773
|
[prop: string]: any;
|
|
519
774
|
}
|
|
@@ -527,10 +782,16 @@ export declare interface deprecated_NumberStepperProps extends Omit<React_2.AllH
|
|
|
527
782
|
export declare const deprecated_Tab: React_2.ForwardRefExoticComponent<deprecated_TabProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
528
783
|
|
|
529
784
|
export declare interface deprecated_TabProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
785
|
+
/** The label to be displayed on the tab control. */
|
|
786
|
+
label?: string;
|
|
787
|
+
/** The contents to be displayed in the tab panel when the tab is selected. */
|
|
530
788
|
children?: React_2.ReactNode;
|
|
789
|
+
/** Identifier of the tab control for the tab panel to direct aria-labelledby to the proper control.
|
|
790
|
+
* When not provided, will default to the key or fallback to the index of the tab in the tab list.
|
|
791
|
+
* @defaultValue key | index */
|
|
531
792
|
id?: string;
|
|
793
|
+
/** Appended to internal classes on the containing div element. */
|
|
532
794
|
className?: string;
|
|
533
|
-
label?: string;
|
|
534
795
|
[prop: string]: any;
|
|
535
796
|
}
|
|
536
797
|
|
|
@@ -543,11 +804,14 @@ export declare interface deprecated_TabProps extends React_2.AllHTMLAttributes<H
|
|
|
543
804
|
export declare const deprecated_Tabs: React_2.ForwardRefExoticComponent<deprecated_TabsProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
544
805
|
|
|
545
806
|
export declare interface deprecated_TabsProps extends Omit<React_2.AllHTMLAttributes<HTMLDivElement>, 'onChange'> {
|
|
807
|
+
/** The key of the tab to be selected. */
|
|
546
808
|
activeKey: string;
|
|
809
|
+
/** The tabs to display. Must only be composed of the Tab component. */
|
|
547
810
|
children: React_2.ReactNode;
|
|
811
|
+
/** Appended to internal classes on the containing div element. */
|
|
548
812
|
className?: string;
|
|
813
|
+
/** Change handler that is called every time a tab is selected. */
|
|
549
814
|
onChange?: (key: string) => any;
|
|
550
|
-
id?: string;
|
|
551
815
|
[prop: string]: any;
|
|
552
816
|
}
|
|
553
817
|
|
|
@@ -568,12 +832,16 @@ export declare const deprecated_Toolbar: React_2.ForwardRefExoticComponent<depre
|
|
|
568
832
|
export declare const deprecated_ToolbarPanel: React_2.FunctionComponent<deprecated_ToolbarPanelProps>;
|
|
569
833
|
|
|
570
834
|
export declare interface deprecated_ToolbarPanelProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
571
|
-
|
|
835
|
+
/** The content for the panel. */
|
|
572
836
|
children: React_2.ReactNode;
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
837
|
+
/** Adds the panel container into the page tab order. This should be set to true when the panel does not contain any tabbable elements.
|
|
838
|
+
* @defaultValue false
|
|
839
|
+
*/
|
|
840
|
+
isContainerInTabOrder?: boolean;
|
|
841
|
+
/** Will not include the suffix from the `Toolbar` component. */
|
|
576
842
|
'data-testid'?: string;
|
|
843
|
+
/** Appended to internal classes on the containing `div` element. */
|
|
844
|
+
className?: string;
|
|
577
845
|
[prop: string]: any;
|
|
578
846
|
}
|
|
579
847
|
|
|
@@ -586,23 +854,48 @@ export declare interface deprecated_ToolbarPanelProps extends React_2.AllHTMLAtt
|
|
|
586
854
|
export declare const deprecated_ToolbarPanels: React_2.ForwardRefExoticComponent<deprecated_ToolbarPanelsProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
587
855
|
|
|
588
856
|
export declare interface deprecated_ToolbarPanelsProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
857
|
+
/** The `ToolbarPanel` components. */
|
|
858
|
+
children: React_2.ReactNode;
|
|
859
|
+
/** Indicates if the `ToolbarPanel`s can be collapsed.
|
|
860
|
+
* @defaultValue true
|
|
861
|
+
*/
|
|
589
862
|
isCollapsible?: boolean;
|
|
590
|
-
|
|
863
|
+
/** The initial collapsed state.
|
|
864
|
+
* @defaultValue false
|
|
865
|
+
*/
|
|
591
866
|
defaultIsCollapsed?: boolean;
|
|
867
|
+
/** The collapsed state. */
|
|
592
868
|
isCollapsed?: boolean;
|
|
869
|
+
/** Handler to be called whenever the panels expand or collapse. */
|
|
593
870
|
onIsCollapsedChange?: (newIsCollapsed: boolean) => void;
|
|
594
|
-
|
|
871
|
+
/** Appended to internal classes on the containing `div` element. */
|
|
872
|
+
className?: string;
|
|
595
873
|
[prop: string]: any;
|
|
596
874
|
}
|
|
597
875
|
|
|
598
876
|
export declare interface deprecated_ToolbarProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
877
|
+
/** The `ToolbarTabs` and `ToolbarPanels` */
|
|
599
878
|
children: React_2.ReactNode;
|
|
879
|
+
/** The index of the initially selected `ToolbarTab`.
|
|
880
|
+
* @defaultValue 0
|
|
881
|
+
*/
|
|
600
882
|
defaultSelectedIndex?: number;
|
|
883
|
+
/** The index of the selected `ToolbarTab`. */
|
|
601
884
|
selectedIndex?: number;
|
|
885
|
+
/** Handler to be called whenever the selected `ToolbarTab` changes.
|
|
886
|
+
*/
|
|
602
887
|
onSelectedIndexChange?: (newSelectedIndex: number) => void;
|
|
603
|
-
|
|
888
|
+
/** A unique id for the toolbar. If no id is passed, a randomly-generated id will be used.*/
|
|
604
889
|
id?: string;
|
|
890
|
+
/** Added to the containing div element and to the following sub-components, each with their own suffix:
|
|
891
|
+
* * `ToolbarTab`: `-tab-<tab index>`
|
|
892
|
+
* * `ToolbarTabs` Expand/Collapse Button: `-tabs-expand-collapse-button`
|
|
893
|
+
* * `ToolbarPanel`: `-panel-<panel index>`
|
|
894
|
+
* * `ToolbarPanels` Expand/Collapse Button: `-panels-expand-collapse-button` */
|
|
605
895
|
'data-testid'?: string;
|
|
896
|
+
/** Appended to internal classes on the containing `div` element.
|
|
897
|
+
*/
|
|
898
|
+
className?: string;
|
|
606
899
|
[prop: string]: any;
|
|
607
900
|
}
|
|
608
901
|
|
|
@@ -615,12 +908,14 @@ export declare interface deprecated_ToolbarProps extends React_2.AllHTMLAttribut
|
|
|
615
908
|
export declare const deprecated_ToolbarTab: React_2.ForwardRefExoticComponent<deprecated_ToolbarTabProps & React_2.RefAttributes<HTMLButtonElement>>;
|
|
616
909
|
|
|
617
910
|
export declare interface deprecated_ToolbarTabProps extends Omit<React_2.AllHTMLAttributes<HTMLButtonElement>, 'aria-disabled' | 'type'> {
|
|
911
|
+
/** The icon to render. See the [Icon](/components/icon) page for available icons.*/
|
|
618
912
|
icon?: IconComponent;
|
|
913
|
+
/** The name of the `ToolbarTab`. The label will be displayed when the `ToolbarTab`s are expanded, and will also be used for screen readers. */
|
|
619
914
|
label: string;
|
|
620
|
-
|
|
621
|
-
'aria-controls'?: string;
|
|
622
|
-
id?: string;
|
|
915
|
+
/** Will not include the suffix from the `Toolbar` component. */
|
|
623
916
|
'data-testid'?: string;
|
|
917
|
+
/** Appended to internal classes on the `button` element. */
|
|
918
|
+
className?: string;
|
|
624
919
|
[prop: string]: any;
|
|
625
920
|
}
|
|
626
921
|
|
|
@@ -633,15 +928,30 @@ export declare interface deprecated_ToolbarTabProps extends Omit<React_2.AllHTML
|
|
|
633
928
|
export declare const deprecated_ToolbarTabs: React_2.ForwardRefExoticComponent<deprecated_ToolbarTabsProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
634
929
|
|
|
635
930
|
export declare interface deprecated_ToolbarTabsProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
931
|
+
/** The `ToolbarTab` components.
|
|
932
|
+
*/
|
|
933
|
+
children: React_2.ReactNode;
|
|
934
|
+
/** Indicates if the `ToolbarTab`s can be collapsed into icons without a label. If any `ToolbarTab` component is not provided with an icon, this prop should be set to false.
|
|
935
|
+
* @defaultValue true
|
|
936
|
+
*/
|
|
636
937
|
isCollapsible?: boolean;
|
|
938
|
+
/** The initial collapsed state.
|
|
939
|
+
* @defaultValue false
|
|
940
|
+
*/
|
|
637
941
|
defaultIsCollapsed?: boolean;
|
|
942
|
+
/** The collapsed state. */
|
|
638
943
|
isCollapsed?: boolean;
|
|
944
|
+
/** Handler to be called whenever the tabs expand or collapse.
|
|
945
|
+
*/
|
|
639
946
|
onIsCollapsedChange?: (newIsCollapsed: boolean) => void;
|
|
640
|
-
|
|
641
|
-
className?: string;
|
|
947
|
+
/** An accessible label for the list of tabs. */
|
|
642
948
|
'aria-label'?: string;
|
|
949
|
+
/** The id of an element that acts as a label for the list of tabs. */
|
|
643
950
|
'aria-labelledby'?: string;
|
|
951
|
+
/** The id of an element that describes the list of tabs. */
|
|
644
952
|
'aria-describedby'?: string;
|
|
953
|
+
/** Appended to internal classes on the containing `div` element. */
|
|
954
|
+
className?: string;
|
|
645
955
|
[prop: string]: any;
|
|
646
956
|
}
|
|
647
957
|
|
|
@@ -657,29 +967,58 @@ export declare const Dropdown: React_2.ForwardRefExoticComponent<DropdownProps &
|
|
|
657
967
|
export declare const DropdownButton: React_2.ForwardRefExoticComponent<DropdownButtonProps & React_2.RefAttributes<HTMLButtonElement>>;
|
|
658
968
|
|
|
659
969
|
export declare interface DropdownButtonProps extends Omit<React_2.AllHTMLAttributes<HTMLButtonElement>, 'label'> {
|
|
970
|
+
/** The component that should render as the dropdown button. */
|
|
660
971
|
children?: React_2.ReactElement & {
|
|
661
972
|
ref?: React_2.Ref<HTMLElement>;
|
|
662
973
|
};
|
|
663
|
-
|
|
974
|
+
/**
|
|
975
|
+
* The text to display when no option is selected.
|
|
976
|
+
* @defaultValue ''
|
|
977
|
+
*/
|
|
978
|
+
defaultLabel?: string | React_2.ReactNode;
|
|
979
|
+
/** The label to display. */
|
|
980
|
+
label?: React_2.ReactNode;
|
|
981
|
+
/**
|
|
982
|
+
* The unique identifier for the button, used for linking accessible labels throughout the component.
|
|
983
|
+
* @defaultValue random
|
|
984
|
+
*/
|
|
985
|
+
id?: string;
|
|
986
|
+
/** @internal */
|
|
664
987
|
disabled?: boolean;
|
|
988
|
+
/** @internal */
|
|
665
989
|
isInvalid?: boolean;
|
|
666
|
-
|
|
667
|
-
label?: string | React_2.ReactNode;
|
|
990
|
+
/** @internal */
|
|
668
991
|
onLabelChange?: (string: any) => void;
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
992
|
+
/**
|
|
993
|
+
* The `id` of the element that acts as a label for the button.
|
|
994
|
+
* Overrides any `aria-labelledby` value received from the top-level
|
|
995
|
+
* `Dropdown` component.
|
|
996
|
+
*/
|
|
673
997
|
'aria-labelledby'?: string;
|
|
998
|
+
/**
|
|
999
|
+
* An accessible label for the dropdown that is used by screen readers.
|
|
1000
|
+
* Overrides any `aria-label` value received from the top-level `Dropdown` component.
|
|
1001
|
+
*/
|
|
674
1002
|
'aria-label'?: string;
|
|
1003
|
+
/**
|
|
1004
|
+
* The `id` of the element that acts as a description for the button.
|
|
1005
|
+
* Overrides any `aria-describedby` value received from the top-level
|
|
1006
|
+
* `Dropdown` component.
|
|
1007
|
+
*/
|
|
675
1008
|
'aria-describedby'?: string;
|
|
1009
|
+
/** Appended to internal classes on the `button` element. */
|
|
1010
|
+
className?: string;
|
|
1011
|
+
/** Appended to the internal `button` element. Overwrites `data-testid` from parent, if present. */
|
|
1012
|
+
'data-testid'?: string;
|
|
676
1013
|
[prop: string]: any;
|
|
677
1014
|
}
|
|
678
1015
|
|
|
679
1016
|
export declare const DropdownHeader: React_2.ForwardRefExoticComponent<DropdownHeaderProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
680
1017
|
|
|
681
1018
|
export declare interface DropdownHeaderProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
1019
|
+
/** The text to display to the user. */
|
|
682
1020
|
title: string;
|
|
1021
|
+
/** The relevant `DropdownOption` components for the group. */
|
|
683
1022
|
children?: React_2.ReactNode;
|
|
684
1023
|
[prop: string]: any;
|
|
685
1024
|
}
|
|
@@ -687,54 +1026,164 @@ export declare interface DropdownHeaderProps extends React_2.AllHTMLAttributes<H
|
|
|
687
1026
|
export declare const DropdownList: React_2.ForwardRefExoticComponent<DropdownListProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
688
1027
|
|
|
689
1028
|
export declare interface DropdownListProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
1029
|
+
/** The displayed `DropdownOption` components. */
|
|
690
1030
|
children?: React_2.ReactNode;
|
|
1031
|
+
/**
|
|
1032
|
+
* Where to prioritize placement of the `DropdownList` relative to the `DropdownButton`.
|
|
1033
|
+
* @defaultValue 'bottom-start'
|
|
1034
|
+
*/
|
|
691
1035
|
placement?: ComputedPlacement;
|
|
1036
|
+
/** Handler to be called when a keyboard key is pressed down. */
|
|
692
1037
|
onKeyDown?: (event: React_2.KeyboardEvent<HTMLDivElement>) => void;
|
|
1038
|
+
/**
|
|
1039
|
+
* The unique identifier for the `DropdownList`, used for linking it to the `DropdownButton`.
|
|
1040
|
+
* @defaultValue random
|
|
1041
|
+
*/
|
|
1042
|
+
id?: string;
|
|
1043
|
+
/**
|
|
1044
|
+
* The container element where the `DropdownList` should be rendered.
|
|
1045
|
+
* Overrides the default set by `UIProvider`.
|
|
1046
|
+
*/
|
|
693
1047
|
portalTarget?: HTMLElement;
|
|
694
|
-
|
|
1048
|
+
/**
|
|
1049
|
+
* The id of the element that acts as a label for the listbox.
|
|
1050
|
+
* Used to override the `DropdownButton` serving as its label.
|
|
1051
|
+
* @defaultValue button id
|
|
1052
|
+
*/
|
|
695
1053
|
'aria-labelledby'?: string;
|
|
1054
|
+
/** Appended to internal classes on the containing `div` element. */
|
|
1055
|
+
className?: string;
|
|
1056
|
+
/** Appended to the internal `div` element. Overwrites `data-testid` from parent, if present. */
|
|
1057
|
+
'data-testid'?: string;
|
|
696
1058
|
[prop: string]: any;
|
|
697
1059
|
}
|
|
698
1060
|
|
|
699
1061
|
export declare const DropdownOption: React_2.ForwardRefExoticComponent<DropdownOptionProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
700
1062
|
|
|
701
1063
|
export declare interface DropdownOptionProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
702
|
-
|
|
1064
|
+
/** The unique value associated with the option. */
|
|
703
1065
|
value: string | number;
|
|
1066
|
+
/** The string representation to display the option to the user. */
|
|
704
1067
|
label: string;
|
|
1068
|
+
/** Used to display non-string options to the user. */
|
|
1069
|
+
children?: React_2.ReactNode;
|
|
1070
|
+
/**
|
|
1071
|
+
* Handler to be called when the option is selected by a click on the option
|
|
1072
|
+
* itself or by a keyboard event on the `DropdownButton`
|
|
1073
|
+
*/
|
|
705
1074
|
onSelect?: ReactEventHandler<HTMLDivElement>;
|
|
1075
|
+
/** @internal */
|
|
706
1076
|
onMouseDown?: React_2.MouseEventHandler<HTMLDivElement>;
|
|
1077
|
+
/** @internal */
|
|
707
1078
|
onMouseEnter?: React_2.MouseEventHandler<HTMLDivElement>;
|
|
1079
|
+
/** @internal */
|
|
708
1080
|
onMouseLeave?: React_2.MouseEventHandler<HTMLDivElement>;
|
|
1081
|
+
/**
|
|
1082
|
+
* When true, disables the option so that it cannot be selected.
|
|
1083
|
+
* @defaultValue false
|
|
1084
|
+
*/
|
|
709
1085
|
disabled?: boolean;
|
|
1086
|
+
/** Appended to internal classes on the containing `div` element. */
|
|
710
1087
|
className?: string;
|
|
711
1088
|
[prop: string]: any;
|
|
712
1089
|
}
|
|
713
1090
|
|
|
714
1091
|
export declare interface DropdownProps extends Omit<React_2.AllHTMLAttributes<HTMLDivElement>, 'value' | 'defaultValue'> {
|
|
715
|
-
|
|
1092
|
+
/** The `DropdownButton` and `DropdownList`. */
|
|
716
1093
|
children: React_2.ReactNode;
|
|
1094
|
+
/** Provides a label for the `Dropdown` */
|
|
717
1095
|
label?: string;
|
|
1096
|
+
/**
|
|
1097
|
+
* Unique name for use with forms.
|
|
1098
|
+
*
|
|
1099
|
+
* See [Form API](../../form/getting-started) for more information.
|
|
1100
|
+
*/
|
|
718
1101
|
name?: string;
|
|
1102
|
+
/** The initially selected value. */
|
|
1103
|
+
defaultValue?: string | number | Array<string | number>;
|
|
1104
|
+
/** The selected value. */
|
|
1105
|
+
value?: string | number | Array<string | number>;
|
|
1106
|
+
/**
|
|
1107
|
+
* Disable the dropdown button.
|
|
1108
|
+
* @defaultValue false
|
|
1109
|
+
*/
|
|
719
1110
|
disabled?: boolean;
|
|
1111
|
+
/**
|
|
1112
|
+
* The validity state.
|
|
1113
|
+
* @defaultValue false
|
|
1114
|
+
*/
|
|
720
1115
|
isInvalid?: boolean;
|
|
721
|
-
|
|
1116
|
+
/**
|
|
1117
|
+
* Whether or not multiple values can be selected.
|
|
1118
|
+
* `value` or `defaultValue` should be passed in as an array of values.
|
|
1119
|
+
* @defaultValue false
|
|
1120
|
+
*/
|
|
722
1121
|
isMultiSelect?: boolean;
|
|
723
|
-
|
|
724
|
-
defaultValue?: string | number | Array<string | number>;
|
|
725
|
-
value?: string | number | Array<string | number>;
|
|
1122
|
+
/** Handler to be called whenever a new value is selected. */
|
|
726
1123
|
onChange?: (value: any) => void;
|
|
727
|
-
|
|
728
|
-
|
|
1124
|
+
/**
|
|
1125
|
+
* Used to control the opened/closed state of the list of options.
|
|
1126
|
+
* @defaultValue false
|
|
1127
|
+
*/
|
|
1128
|
+
isOpen?: boolean;
|
|
1129
|
+
/** Handler to be called whenever the dropdown list is opened/closed. */
|
|
1130
|
+
onIsOpenChange?: (isOpen: boolean) => void;
|
|
1131
|
+
/** Adds an error message directly below `Dropdown` */
|
|
729
1132
|
errorText?: ReactNode;
|
|
1133
|
+
/** Adds additional information directly below `Dropdown` */
|
|
730
1134
|
helperText?: ReactNode;
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
1135
|
+
/**
|
|
1136
|
+
* Determines whether or not to show the search input and allow searching functionality.
|
|
1137
|
+
* Note that only those `DropdownHeader`s with children will appear in the search results.
|
|
1138
|
+
* @defaultValue false
|
|
1139
|
+
*/
|
|
734
1140
|
isSearchable?: boolean;
|
|
1141
|
+
/**
|
|
1142
|
+
* Allows controlling of the search input.
|
|
1143
|
+
* @defaultValue ''
|
|
1144
|
+
*/
|
|
735
1145
|
searchValue?: string;
|
|
1146
|
+
/** Handler to be called whenever the search value is changed. */
|
|
736
1147
|
onSearchValueChange?: (newValue: string) => void;
|
|
1148
|
+
/**
|
|
1149
|
+
* Disables filtering even when `isSearchable` is used.
|
|
1150
|
+
* This is used to wait for async loading of content before applying filter.
|
|
1151
|
+
* @defaultValue false
|
|
1152
|
+
*/
|
|
737
1153
|
isSearchFilteringDisabled?: boolean;
|
|
1154
|
+
/**
|
|
1155
|
+
* The unique identifier used for linking accessibility properties within the component.
|
|
1156
|
+
* Adding this will assign the value to the containing `div` and to main sub-components
|
|
1157
|
+
* with the following suffixes:
|
|
1158
|
+
* - `-button`
|
|
1159
|
+
* - `-list`
|
|
1160
|
+
* @defaultValue random
|
|
1161
|
+
*/
|
|
1162
|
+
id?: string;
|
|
1163
|
+
/**
|
|
1164
|
+
* The id of the element that acts as a label for the `Dropdown`.
|
|
1165
|
+
* The `DropdownButton` uses this value by concatenating it with its
|
|
1166
|
+
* own `id` so its contents are part of the accessible label.
|
|
1167
|
+
*/
|
|
1168
|
+
'aria-labelledby'?: string;
|
|
1169
|
+
/**
|
|
1170
|
+
* An accessible label for the `Dropdown` that is used by screen readers.
|
|
1171
|
+
* The `DropdownButton` uses this value by concatenating it with its own `label`.
|
|
1172
|
+
*/
|
|
1173
|
+
'aria-label'?: string;
|
|
1174
|
+
/**
|
|
1175
|
+
* The id of the element that acts as a description for the `Dropdown`.
|
|
1176
|
+
* This prop is forwarded to the `DropdownButton`.
|
|
1177
|
+
*/
|
|
1178
|
+
'aria-describedby'?: string;
|
|
1179
|
+
/** Appended to internal classes on the containing `div` element. */
|
|
1180
|
+
className?: string;
|
|
1181
|
+
/**
|
|
1182
|
+
* Appended to internal `div` element. Additional test IDs supplied to the following child elements:
|
|
1183
|
+
* - `DropdownButton`: `-button`
|
|
1184
|
+
* - `DropdownList`: `-flyout`
|
|
1185
|
+
* - `DropdownSearch`: `-search`
|
|
1186
|
+
*/
|
|
738
1187
|
'data-testid'?: string;
|
|
739
1188
|
[prop: string]: any;
|
|
740
1189
|
}
|
|
@@ -742,7 +1191,9 @@ export declare interface DropdownProps extends Omit<React_2.AllHTMLAttributes<HT
|
|
|
742
1191
|
export declare const ErrorText: React_2.ForwardRefExoticComponent<ErrorTextProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
743
1192
|
|
|
744
1193
|
export declare interface ErrorTextProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
1194
|
+
/** The contents of the component. */
|
|
745
1195
|
children?: React_2.ReactNode;
|
|
1196
|
+
/** Appended to internal classes on the containing `div` element. */
|
|
746
1197
|
className?: string;
|
|
747
1198
|
[prop: string]: any;
|
|
748
1199
|
}
|
|
@@ -755,26 +1206,39 @@ declare interface fileObject {
|
|
|
755
1206
|
export declare const FilePicker: React_2.ForwardRefExoticComponent<FilePickerProps & React_2.RefAttributes<HTMLInputElement>>;
|
|
756
1207
|
|
|
757
1208
|
export declare interface FilePickerProps extends React_2.AllHTMLAttributes<HTMLInputElement> {
|
|
758
|
-
|
|
1209
|
+
/** Disables the file picker and styles it to appear that it cannot be clicked.
|
|
1210
|
+
* @defaultValue false
|
|
1211
|
+
*/
|
|
759
1212
|
disabled?: boolean;
|
|
1213
|
+
/** An optional value for using a `FilePicker` as a controlled component. Requires use with `onChange`. Setting to `null` will programmatically clear the currently selected files. */
|
|
760
1214
|
files?: FileList | fileObject[] | null;
|
|
1215
|
+
/** Allow selecting multiple files.
|
|
1216
|
+
* @defaultValue false
|
|
1217
|
+
*/
|
|
761
1218
|
multiple?: boolean;
|
|
1219
|
+
/** Handler to be called whenever the selected file(s) change. */
|
|
762
1220
|
onChange?: (event: React_2.ChangeEvent<HTMLInputElement>) => void;
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
'aria-describedby'?: string;
|
|
766
|
-
id?: string;
|
|
1221
|
+
/** Appended to internal classes on the containing `span` element. */
|
|
1222
|
+
className?: string;
|
|
767
1223
|
[prop: string]: any;
|
|
768
1224
|
}
|
|
769
1225
|
|
|
770
1226
|
export declare const FormField: React_2.ForwardRefExoticComponent<FormFieldProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
771
1227
|
|
|
772
1228
|
export declare interface FormFieldProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
773
|
-
|
|
1229
|
+
/** Appended to internal classes on the containing div element. */
|
|
774
1230
|
className?: string;
|
|
1231
|
+
/** An optional error message to display at the end of the FormField. */
|
|
775
1232
|
errorText?: string;
|
|
1233
|
+
/** An optional help message to display near the end of the `FormField` (above the `errorText`). */
|
|
776
1234
|
helperText?: string;
|
|
1235
|
+
/** Adds default helper text and sets form control to Read Only mode. Only supported for `InputField` component.
|
|
1236
|
+
* @defaultValue false
|
|
1237
|
+
*/
|
|
777
1238
|
isReadOnly?: boolean;
|
|
1239
|
+
/** Forwarded to the containing `div` element. If `helperText` and/or `errorText` props are provided, the `data-testid` will also be forwarded to the components that render the text, each with their own suffix:
|
|
1240
|
+
- helperText: `-helper-text`
|
|
1241
|
+
- errorText: `-error-text` */
|
|
778
1242
|
'data-testid'?: string;
|
|
779
1243
|
[prop: string]: any;
|
|
780
1244
|
}
|
|
@@ -782,22 +1246,37 @@ export declare interface FormFieldProps extends React_2.AllHTMLAttributes<HTMLDi
|
|
|
782
1246
|
export declare const FullScreenTakeover: React_2.ForwardRefExoticComponent<FullScreenTakeoverProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
783
1247
|
|
|
784
1248
|
export declare interface FullScreenTakeoverProps {
|
|
785
|
-
|
|
1249
|
+
/** Handler to be called when the user presses the Escape key. */
|
|
786
1250
|
onClose: (event: KeyboardEvent) => void;
|
|
1251
|
+
/** Controls whether or not to display the modal.
|
|
1252
|
+
* @defaultValue false
|
|
1253
|
+
*/
|
|
1254
|
+
isOpen?: boolean;
|
|
1255
|
+
/** Defaults to the dialog. */
|
|
787
1256
|
elementRefToFocusOnOpen?: MutableRefObject<HTMLElement | null>;
|
|
1257
|
+
/** Defaults to the element that had focus at the time the dialog was opened. */
|
|
788
1258
|
elementRefToFocusOnClose?: MutableRefObject<HTMLElement | null>;
|
|
1259
|
+
/** Controls the z-index of the dialog.
|
|
1260
|
+
* @defaultValue 1000 */
|
|
789
1261
|
zIndex?: number;
|
|
1262
|
+
/** Content of the dialog. */
|
|
790
1263
|
children?: React_2.ReactNode;
|
|
1264
|
+
/** aria-labelledby for the dialog. See accessibility section for more information. */
|
|
791
1265
|
'aria-labelledby'?: string;
|
|
1266
|
+
/** aria-label for the dialog. See accessibility section for more information. */
|
|
792
1267
|
'aria-label'?: string;
|
|
1268
|
+
/** aria-describedby for the dialog. See accessibility section for more information. */
|
|
793
1269
|
'aria-describedby'?: string;
|
|
1270
|
+
/** Identifier to target the dialog, typically for testing. */
|
|
794
1271
|
'data-testid'?: string;
|
|
795
1272
|
}
|
|
796
1273
|
|
|
797
1274
|
export declare const HelperText: React_2.ForwardRefExoticComponent<HelperTextProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
798
1275
|
|
|
799
1276
|
export declare interface HelperTextProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
1277
|
+
/** The contents of the component. */
|
|
800
1278
|
children?: React_2.ReactNode;
|
|
1279
|
+
/** Appended to internal classes on the containing `div` element. */
|
|
801
1280
|
className?: string;
|
|
802
1281
|
[prop: string]: any;
|
|
803
1282
|
}
|
|
@@ -813,14 +1292,27 @@ export declare const Icon: React_2.ForwardRefExoticComponent<IconProps & React_2
|
|
|
813
1292
|
export declare const IconButton: React_2.ForwardRefExoticComponent<IconButtonProps & React_2.RefAttributes<HTMLButtonElement>>;
|
|
814
1293
|
|
|
815
1294
|
export declare interface IconButtonProps extends React_2.AllHTMLAttributes<HTMLButtonElement> {
|
|
1295
|
+
/** A single icon to display on the button. */
|
|
816
1296
|
children: React_2.ReactElement;
|
|
1297
|
+
/** Disables click and key input events and styles it to look as though it cannot be clicked.
|
|
1298
|
+
* @defaultValue false */
|
|
817
1299
|
disabled?: boolean;
|
|
818
|
-
|
|
819
|
-
type?: React_2.ButtonHTMLAttributes<HTMLButtonElement>['type'];
|
|
1300
|
+
/** Element(s) or component(s) to be displayed in the tooltip. */
|
|
820
1301
|
tooltipContent?: React_2.ReactNode;
|
|
1302
|
+
/** Should be used with the `tooltipContent` prop. Dictates the position of the tooltip relative to its anchor.
|
|
1303
|
+
* - Must be one of the following: `top`, `right`, `bottom`, or `left`.
|
|
1304
|
+
* - Each placement can optionally have one of the following suffixes: `-start` or `-end`.
|
|
1305
|
+
* @defaultValue 'top' */
|
|
821
1306
|
tooltipPlacement?: ComputedPlacement;
|
|
1307
|
+
/** Type of button element
|
|
1308
|
+
* @defaultValue 'button' */
|
|
1309
|
+
type?: React_2.ButtonHTMLAttributes<HTMLButtonElement>['type'];
|
|
1310
|
+
/** Should be used with the `tooltipContent` prop. If the `Tooltip` acts as a description for the `IconButton`, set the value of this prop to `true`.
|
|
1311
|
+
* @defaultValue false */
|
|
822
1312
|
isTooltipADescription?: boolean;
|
|
1313
|
+
/** Handler to be called when the button is clicked. Use to handle user interaction with the button. */
|
|
823
1314
|
onClick?: React_2.MouseEventHandler<HTMLButtonElement>;
|
|
1315
|
+
/** Handler to be called when a keyboard key is pressed down while button has focus. */
|
|
824
1316
|
onKeyDown?: React_2.KeyboardEventHandler<HTMLButtonElement>;
|
|
825
1317
|
[prop: string]: any;
|
|
826
1318
|
}
|
|
@@ -837,6 +1329,8 @@ export declare const IconTypes: {
|
|
|
837
1329
|
readonly ABC: "ABC";
|
|
838
1330
|
readonly AI: "AI";
|
|
839
1331
|
readonly AIChatbot: "AIChatbot";
|
|
1332
|
+
readonly AIEntity: "AIEntity";
|
|
1333
|
+
readonly AISpark: "AISpark";
|
|
840
1334
|
readonly Accessibility: "Accessibility";
|
|
841
1335
|
readonly Account: "Account";
|
|
842
1336
|
readonly AccountsTable: "AccountsTable";
|
|
@@ -896,6 +1390,7 @@ export declare const IconTypes: {
|
|
|
896
1390
|
readonly Bugs: "Bugs";
|
|
897
1391
|
readonly BusinessImpact: "BusinessImpact";
|
|
898
1392
|
readonly Button: "Button";
|
|
1393
|
+
readonly ButtonSelector: "ButtonSelector";
|
|
899
1394
|
readonly BxLogo: "BxLogo";
|
|
900
1395
|
readonly Calendar: "Calendar";
|
|
901
1396
|
readonly CalendarAdd: "CalendarAdd";
|
|
@@ -980,6 +1475,7 @@ export declare const IconTypes: {
|
|
|
980
1475
|
readonly DragAndDrop: "DragAndDrop";
|
|
981
1476
|
readonly Drilldown: "Drilldown";
|
|
982
1477
|
readonly Drop: "Drop";
|
|
1478
|
+
readonly DropListSelector: "DropListSelector";
|
|
983
1479
|
readonly EXCOVIDReturnToWork: "EXCOVIDReturnToWork";
|
|
984
1480
|
readonly EXCOVIDSolution: "EXCOVIDSolution";
|
|
985
1481
|
readonly EditorGeneric: "EditorGeneric";
|
|
@@ -1054,9 +1550,12 @@ export declare const IconTypes: {
|
|
|
1054
1550
|
readonly Headset: "Headset";
|
|
1055
1551
|
readonly HealthWellness: "HealthWellness";
|
|
1056
1552
|
readonly HeatMap: "HeatMap";
|
|
1553
|
+
readonly HeatMapDiscover: "HeatMapDiscover";
|
|
1057
1554
|
readonly Help: "Help";
|
|
1058
1555
|
readonly HighVolume: "HighVolume";
|
|
1059
1556
|
readonly Highlight: "Highlight";
|
|
1557
|
+
readonly HighlightPenSwatch: "HighlightPenSwatch";
|
|
1558
|
+
readonly HighlightSwatch: "HighlightSwatch";
|
|
1060
1559
|
readonly History: "History";
|
|
1061
1560
|
readonly Home: "Home";
|
|
1062
1561
|
readonly Hotspot: "Hotspot";
|
|
@@ -1105,6 +1604,7 @@ export declare const IconTypes: {
|
|
|
1105
1604
|
readonly Megaphone: "Megaphone";
|
|
1106
1605
|
readonly Merge: "Merge";
|
|
1107
1606
|
readonly Metadata: "Metadata";
|
|
1607
|
+
readonly MetricWidget: "MetricWidget";
|
|
1108
1608
|
readonly Microphone: "Microphone";
|
|
1109
1609
|
readonly MicrophoneMute: "MicrophoneMute";
|
|
1110
1610
|
readonly Minimize: "Minimize";
|
|
@@ -1210,6 +1710,7 @@ export declare const IconTypes: {
|
|
|
1210
1710
|
readonly ScreenCapture: "ScreenCapture";
|
|
1211
1711
|
readonly Search: "Search";
|
|
1212
1712
|
readonly SearchAdd: "SearchAdd";
|
|
1713
|
+
readonly SearchSelector: "SearchSelector";
|
|
1213
1714
|
readonly Segment: "Segment";
|
|
1214
1715
|
readonly SelectColumn: "SelectColumn";
|
|
1215
1716
|
readonly Send: "Send";
|
|
@@ -1338,9 +1839,13 @@ export declare const IconTypes: {
|
|
|
1338
1839
|
export declare const InlineInput: React_2.ForwardRefExoticComponent<InlineInputProps & React_2.RefAttributes<HTMLSpanElement>>;
|
|
1339
1840
|
|
|
1340
1841
|
export declare interface InlineInputProps extends Omit<React_2.AllHTMLAttributes<HTMLSpanElement>, 'onChange'> {
|
|
1842
|
+
/** The initial value for the input. Because `InlineInput` uses a `contentEditable` `span`, it can only be used as an uncontrolled component. */
|
|
1341
1843
|
defaultValue?: string;
|
|
1844
|
+
/** Handler to be called when the input loses focus. */
|
|
1342
1845
|
onBlur?: (event: React_2.FocusEvent<HTMLSpanElement>) => void;
|
|
1846
|
+
/** Handler to be called when the input receives focus. */
|
|
1343
1847
|
onFocus?: (event: React_2.FocusEvent<HTMLSpanElement>) => void;
|
|
1848
|
+
/** Handler to be called whenever the value of the input changes. */
|
|
1344
1849
|
onChange?: (event: (ClipboardEvent_2<HTMLSpanElement> | FormEvent<HTMLSpanElement> | InputEvent) & {
|
|
1345
1850
|
currentTarget: {
|
|
1346
1851
|
value: string;
|
|
@@ -1349,9 +1854,8 @@ export declare interface InlineInputProps extends Omit<React_2.AllHTMLAttributes
|
|
|
1349
1854
|
value: string;
|
|
1350
1855
|
};
|
|
1351
1856
|
}) => void;
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
tabIndex?: number;
|
|
1857
|
+
/** Appended to internal classes on the containing `span` element. */
|
|
1858
|
+
className?: string;
|
|
1355
1859
|
[prop: string]: any;
|
|
1356
1860
|
}
|
|
1357
1861
|
|
|
@@ -1360,22 +1864,32 @@ export declare const Input: React_2.ForwardRefExoticComponent<InputProps & React
|
|
|
1360
1864
|
export declare const InputField: React_2.ForwardRefExoticComponent<InputFieldProps & React_2.RefAttributes<HTMLInputElement | HTMLTextAreaElement>>;
|
|
1361
1865
|
|
|
1362
1866
|
export declare interface InputFieldProps extends Omit<Pick<InputProps, KnownKeys<InputProps>>, 'label'> {
|
|
1363
|
-
label
|
|
1364
|
-
className?: string;
|
|
1365
|
-
style?: React_2.CSSProperties;
|
|
1366
|
-
'data-testid'?: string;
|
|
1867
|
+
/** When supplied, the unique id for the input is applied to the label's `for` attribute. */
|
|
1367
1868
|
id?: string;
|
|
1368
|
-
|
|
1369
|
-
|
|
1370
|
-
|
|
1371
|
-
labelProps?: {
|
|
1869
|
+
/** Props to spread onto the internal Input component.
|
|
1870
|
+
* @defaultValue \{\} */
|
|
1871
|
+
inputProps?: {
|
|
1372
1872
|
className?: string;
|
|
1373
1873
|
[prop: string]: any;
|
|
1374
1874
|
};
|
|
1375
|
-
|
|
1875
|
+
/** Label for the input. */
|
|
1876
|
+
label: React_2.ReactNode;
|
|
1877
|
+
/** Props to spread onto the internal Label component.
|
|
1878
|
+
* @defaultValue \{\} */
|
|
1879
|
+
labelProps?: {
|
|
1376
1880
|
className?: string;
|
|
1377
1881
|
[prop: string]: any;
|
|
1378
1882
|
};
|
|
1883
|
+
/** Appended to internal classes on the containing [Label](/components/label) component. */
|
|
1884
|
+
className?: string;
|
|
1885
|
+
/** Appended to internal styles on the containing [Label](/components/label) component.
|
|
1886
|
+
* @defaultValue \{\} */
|
|
1887
|
+
style?: React_2.CSSProperties;
|
|
1888
|
+
/** Added to the containing [Label](/components/label) component. */
|
|
1889
|
+
'data-testid'?: string;
|
|
1890
|
+
/** Addresses a typescript bug, see commit.
|
|
1891
|
+
* @internal */
|
|
1892
|
+
onChange?: InputProps['onChange'];
|
|
1379
1893
|
[prop: string]: any;
|
|
1380
1894
|
}
|
|
1381
1895
|
|
|
@@ -1384,34 +1898,69 @@ export declare const InputGroup: React_2.ForwardRefExoticComponent<InputGroupPro
|
|
|
1384
1898
|
export declare const InputGroupAddon: React_2.ForwardRefExoticComponent<InputGroupAddonProps & React_2.RefAttributes<HTMLSpanElement>>;
|
|
1385
1899
|
|
|
1386
1900
|
export declare interface InputGroupAddonProps {
|
|
1901
|
+
/** Indicates if the addon should be smaller in size.
|
|
1902
|
+
* @defaultValue false
|
|
1903
|
+
*/
|
|
1904
|
+
small?: boolean;
|
|
1905
|
+
/** Content to be rendered in the add on */
|
|
1387
1906
|
children?: React_2.ReactNode;
|
|
1907
|
+
/** Appended to internal classes on the containing `span` element. */
|
|
1388
1908
|
className?: string;
|
|
1389
|
-
small?: boolean;
|
|
1390
1909
|
[prop: string]: any;
|
|
1391
1910
|
}
|
|
1392
1911
|
|
|
1393
1912
|
export declare interface InputGroupProps {
|
|
1394
|
-
children
|
|
1395
|
-
|
|
1913
|
+
/** Makes `InputGroup` take the width of its parent and makes the Input grow to fill `InputGroup`. `InputGroup` children's `full` property will be overridden.
|
|
1914
|
+
* @defaultValue false
|
|
1915
|
+
*/
|
|
1396
1916
|
full?: boolean;
|
|
1917
|
+
/** Makes `InputGroup` and all of its children smaller. `InputGroup` children's `small` property will be overridden.
|
|
1918
|
+
* @defaultValue false
|
|
1919
|
+
*/
|
|
1397
1920
|
small?: boolean;
|
|
1921
|
+
/** Appended to internal classes on the containing `span` element.
|
|
1922
|
+
*/
|
|
1923
|
+
className?: string;
|
|
1924
|
+
/** Accepts `Input`, `Button`, `SelectMenu` and `InputAddOn` */
|
|
1925
|
+
children: React_2.ReactNode;
|
|
1398
1926
|
[prop: string]: any;
|
|
1399
1927
|
}
|
|
1400
1928
|
|
|
1401
1929
|
export declare interface InputProps extends Omit<React_2.AllHTMLAttributes<HTMLTextAreaElement | HTMLInputElement>, 'rows'> {
|
|
1402
|
-
|
|
1403
|
-
value?: string | number;
|
|
1930
|
+
/** Initial value for an uncontrolled input. */
|
|
1404
1931
|
defaultValue?: string | number;
|
|
1932
|
+
/** Disables the input element and styles it to appear that it cannot be clicked or typed in.
|
|
1933
|
+
* @defaultValue false
|
|
1934
|
+
*/
|
|
1405
1935
|
disabled?: boolean;
|
|
1936
|
+
/** Makes the input take the width of its parent.
|
|
1937
|
+
* @defaultValue false
|
|
1938
|
+
*/
|
|
1406
1939
|
full?: boolean;
|
|
1940
|
+
/** Styles the input to indicate invalid data has been entered.
|
|
1941
|
+
* @defaultValue false
|
|
1942
|
+
*/
|
|
1407
1943
|
invalid?: boolean;
|
|
1944
|
+
/** Uses a textarea element instead of an input element. Enables a user to enter multiple lines of text. */
|
|
1408
1945
|
multiline?: boolean;
|
|
1946
|
+
/** Handler to be called whenever the value of the input changes. */
|
|
1409
1947
|
onChange?: (event: React_2.ChangeEvent<HTMLInputElement | HTMLTextAreaElement>) => void;
|
|
1948
|
+
/** The number of rows to display for a multiline input.
|
|
1949
|
+
* @defaultValue 2
|
|
1950
|
+
*/
|
|
1410
1951
|
rows?: string | number;
|
|
1952
|
+
/** Makes the input smaller.
|
|
1953
|
+
* @defaultValue false
|
|
1954
|
+
*/
|
|
1411
1955
|
small?: boolean;
|
|
1956
|
+
/** Text, number, password, email, tel, or url. The email, tel, and url types all behave the same as a text input, except on mobile where a specialized keyboard may be displayed. This property is ignored if the multiline property is enabled.
|
|
1957
|
+
* @defaultValue 'text'
|
|
1958
|
+
*/
|
|
1412
1959
|
type?: 'text' | 'password' | 'number' | 'email' | 'tel' | 'url';
|
|
1413
|
-
|
|
1414
|
-
|
|
1960
|
+
/** The value for the input. */
|
|
1961
|
+
value?: string | number;
|
|
1962
|
+
/** Appended to internal classes on the `input` or `textarea` element. */
|
|
1963
|
+
className?: string;
|
|
1415
1964
|
[prop: string]: any;
|
|
1416
1965
|
}
|
|
1417
1966
|
|
|
@@ -1424,18 +1973,25 @@ declare type KnownKeys<T> = ValuesOf<KeyToKeyNoIndex<T>>;
|
|
|
1424
1973
|
export declare const Label: React_2.ForwardRefExoticComponent<LabelProps & React_2.RefAttributes<HTMLLabelElement>>;
|
|
1425
1974
|
|
|
1426
1975
|
export declare interface LabelProps extends React_2.AllHTMLAttributes<HTMLLabelElement> {
|
|
1976
|
+
/** The content of the label. The field being labelled may also optionally be added as a child. */
|
|
1427
1977
|
children?: React_2.ReactNode;
|
|
1978
|
+
/** Appended to internal classes on the `label` element. */
|
|
1428
1979
|
className?: string;
|
|
1429
1980
|
[prop: string]: any;
|
|
1430
|
-
htmlFor?: string;
|
|
1431
1981
|
}
|
|
1432
1982
|
|
|
1433
1983
|
export declare const Link: React_2.ForwardRefExoticComponent<LinkProps & React_2.RefAttributes<HTMLAnchorElement>>;
|
|
1434
1984
|
|
|
1435
1985
|
export declare interface LinkProps extends React_2.AllHTMLAttributes<HTMLAnchorElement> {
|
|
1986
|
+
/** The contents of the link */
|
|
1436
1987
|
children: React_2.ReactNode;
|
|
1988
|
+
/** The href that will be applied to the underlying anchor element.
|
|
1989
|
+
* @defaultValue '#' */
|
|
1437
1990
|
href?: string;
|
|
1991
|
+
/** The target that will be applied to the underlying anchor element.
|
|
1992
|
+
* @defaultValue '_self' */
|
|
1438
1993
|
target?: React_2.HTMLAttributeAnchorTarget;
|
|
1994
|
+
/** Appended to the internal classes on the `<a>` element */
|
|
1439
1995
|
className?: string;
|
|
1440
1996
|
[prop: string]: any;
|
|
1441
1997
|
}
|
|
@@ -1443,17 +1999,29 @@ export declare interface LinkProps extends React_2.AllHTMLAttributes<HTMLAnchorE
|
|
|
1443
1999
|
export declare const LoadingSpinner: React_2.ForwardRefExoticComponent<LoadingSpinnerProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
1444
2000
|
|
|
1445
2001
|
export declare interface LoadingSpinnerProps extends Omit<React_2.AllHTMLAttributes<HTMLDivElement>, 'size'> {
|
|
2002
|
+
/** Makes the LoadingSpinner visible.
|
|
2003
|
+
* @defaultValue false */
|
|
2004
|
+
show?: boolean;
|
|
2005
|
+
/** The size of the `LoadingSpinner`. For `LoadingSpinner`s with no child component, a minimum width and height will be applied.
|
|
2006
|
+
* @defaultValue 'medium' */
|
|
2007
|
+
size?: 'xs' | 'small' | 'medium' | 'large';
|
|
2008
|
+
/** Changes the opacity of the `LoadingSpinner`'s children.
|
|
2009
|
+
* @defaultValue 'fade' */
|
|
1446
2010
|
background?: 'hide' | 'fade';
|
|
2011
|
+
/** Changes the `LoadingSpinner` color from black to white.
|
|
2012
|
+
* @defaultValue false */
|
|
2013
|
+
inverted?: boolean;
|
|
2014
|
+
/** When the spinner is showing, pointer events will be disabled on the children, but children can still be navigated by a keyboard user. Add the `disabled` prop to children components as appropriate. */
|
|
1447
2015
|
children?: React_2.ReactNode;
|
|
2016
|
+
/** Appended to internal classes on the containing `div` element. */
|
|
1448
2017
|
className?: string;
|
|
1449
|
-
|
|
1450
|
-
show?: boolean;
|
|
1451
|
-
size?: 'xs' | 'small' | 'medium' | 'large';
|
|
1452
|
-
role?: string;
|
|
2018
|
+
/** Controls the message sent to the screen reader for loading events. Defaults to `'Loading'` if `aria-labelledby` is not set. */
|
|
1453
2019
|
'aria-label'?: string;
|
|
2020
|
+
/** Directs the screen reader to other elements designated for messaging. */
|
|
1454
2021
|
'aria-labelledby'?: string;
|
|
2022
|
+
/** Controls the timing of screen reader messages.
|
|
2023
|
+
* @defaultValue 'polite' */
|
|
1455
2024
|
'aria-live'?: 'off' | 'assertive' | 'polite';
|
|
1456
|
-
'aria-hidden'?: boolean | 'true' | 'false';
|
|
1457
2025
|
[prop: string]: any;
|
|
1458
2026
|
}
|
|
1459
2027
|
|
|
@@ -1474,16 +2042,43 @@ export declare interface LogicEditorConditionTemplateProps {
|
|
|
1474
2042
|
}
|
|
1475
2043
|
|
|
1476
2044
|
export declare interface LogicEditorProps extends Omit<React_2.AllHTMLAttributes<HTMLDivElement>, 'defaultValue' | 'onChange'> {
|
|
1477
|
-
|
|
2045
|
+
/** A functional component representing a condition. The component must be a controlled component with the following properties. Note that the example `Condition Template` provided above represents the condition type and associated value within the `value` property.
|
|
2046
|
+
* - `value`: The value of the condition template.
|
|
2047
|
+
* - `onChange`: Handler to be called when the value of the condition template is updated.
|
|
2048
|
+
* - `firstFocusableElementRef`: This property is only needed if both of the following are true:
|
|
2049
|
+
* - The `LogicEditor`'s `fixedSet` prop is set to `true`.
|
|
2050
|
+
* - The `LogicEditor`'s `firstFocusableElementRef` prop is used.
|
|
2051
|
+
*/
|
|
1478
2052
|
conditionTemplate: (props: LogicEditorConditionTemplateProps) => React_2.ReactElement;
|
|
2053
|
+
/** The default value used for sets. Sets provided via `defaultValue` without a `value` will get the `defaultSetValue`.
|
|
2054
|
+
* @defaultValue 'any'
|
|
2055
|
+
*/
|
|
1479
2056
|
defaultSetValue?: 'any' | 'all';
|
|
2057
|
+
/** The default value of the logic tree structure of the editor. Used to render the passed in conditions and their respective values. */
|
|
1480
2058
|
defaultValue?: LogicEditorSet;
|
|
2059
|
+
/** Fixes the logic editor to a single set. Using this property disables the use of nesting sets.
|
|
2060
|
+
* @defaultValue false
|
|
2061
|
+
*/
|
|
1481
2062
|
fixedSet?: boolean;
|
|
2063
|
+
/** Change handler to be called when the user interacts with the controls of the editor. */
|
|
1482
2064
|
onChange?: (value: LogicEditorSet | LogicEditorCondition) => void;
|
|
2065
|
+
/** Configures the logic editor to be read only. When `true` condition set dropdowns will be read only and control menus for adding and deleting conditions will not be rendered.
|
|
2066
|
+
*
|
|
2067
|
+
* **Note**: Using the `readOnly` property does not affect elements in condition templates. Condition templates should be handled to account for read only state separately.
|
|
2068
|
+
* @defaultValue false
|
|
2069
|
+
*/
|
|
1483
2070
|
readOnly?: boolean;
|
|
2071
|
+
/** The maximum number of allowed nested sets. The outermost set is not considered a nested set and is therefore not counted towards the maximum number.
|
|
2072
|
+
* @defaultValue 2
|
|
2073
|
+
*/
|
|
1484
2074
|
maxNestedSets?: number;
|
|
2075
|
+
/** Limits the number of conditions that can be added to a set. Only use with the `fixedSet` prop. */
|
|
1485
2076
|
maxConditions?: number;
|
|
2077
|
+
/** A `ref` that can be used for programmatically focusing the first focusable element inside the logic editor. If `fixedSet` is enabled, the prop is forwarded to the first condition in the LogicEditor. */
|
|
1486
2078
|
firstFocusableElementRef?: React_2.RefObject<HTMLElement>;
|
|
2079
|
+
/** Appended to internal classes on the containing `div` element. */
|
|
2080
|
+
className?: string;
|
|
2081
|
+
/** Added to the containing `div` element as well as each set dropdown and condition action menu. In order to ensure uniqueness for each test id, each set dropdown is prefixed with `set-dropdown` and each condition action menu is prefixed with `condition-actions`. All test ids begin with the value passed to this prop. Each set dropdown and condition action menu has a suffix containing a `-` separated list of indices where the left-most index is the root element's index and the right-most index is the current element's index. These indices are based on the element's index (position) in it's level in the tree. */
|
|
1487
2082
|
'data-testid'?: string;
|
|
1488
2083
|
[prop: string]: any;
|
|
1489
2084
|
}
|
|
@@ -1498,11 +2093,24 @@ export declare interface LogicEditorSet {
|
|
|
1498
2093
|
export declare const MainContent: React_2.ForwardRefExoticComponent<MainContentProps & React_2.RefAttributes<HTMLElement>>;
|
|
1499
2094
|
|
|
1500
2095
|
export declare interface MainContentProps {
|
|
2096
|
+
/** The main content for your app.
|
|
2097
|
+
*
|
|
2098
|
+
*
|
|
2099
|
+
* Note: if you are rendering a footer (e.g. the Global Wrapper footer)
|
|
2100
|
+
* it should be added here below all of your main content.
|
|
2101
|
+
*/
|
|
1501
2102
|
children?: React_2.ReactNode;
|
|
2103
|
+
/** Class added to the containing `main` */
|
|
1502
2104
|
className?: string;
|
|
2105
|
+
/** Test id added to the containing `main` */
|
|
2106
|
+
'data-testid'?: string;
|
|
2107
|
+
/** Unique id added to the containing `main` */
|
|
1503
2108
|
id?: string;
|
|
2109
|
+
/** Label added to the containing `main` */
|
|
1504
2110
|
'aria-label'?: string;
|
|
2111
|
+
/** Id of the label element added to the containing `main` */
|
|
1505
2112
|
'aria-labelledby'?: string;
|
|
2113
|
+
/** Id of the description element added to the containing `main` */
|
|
1506
2114
|
'aria-describedby'?: string;
|
|
1507
2115
|
}
|
|
1508
2116
|
|
|
@@ -1511,37 +2119,72 @@ export declare const Menu: React_2.ForwardRefExoticComponent<MenuProps & React_2
|
|
|
1511
2119
|
export declare const MenuItem: React_2.ForwardRefExoticComponent<MenuItemProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
1512
2120
|
|
|
1513
2121
|
export declare interface MenuItemProps extends Omit<React_2.AllHTMLAttributes<HTMLDivElement>, 'onSelect'> {
|
|
1514
|
-
|
|
1515
|
-
tabIndex?: number;
|
|
1516
|
-
children?: React_2.ReactNode;
|
|
1517
|
-
className?: string;
|
|
2122
|
+
/** When `true`, disables `MenuItem` so that it cannot be selected */
|
|
1518
2123
|
disabled?: boolean;
|
|
2124
|
+
/** Used in searchable menus when the menu item child is not a string, or when adding hidden search tags. */
|
|
1519
2125
|
label?: string;
|
|
2126
|
+
/** Handler to be called when the menu item is selected via a click or keyboard event. */
|
|
1520
2127
|
onSelect?: (event: React_2.MouseEvent | React_2.KeyboardEvent) => void;
|
|
2128
|
+
/** Value associated with the item. */
|
|
1521
2129
|
value?: number | string;
|
|
1522
|
-
|
|
1523
|
-
|
|
2130
|
+
/** Contents of the menu item. */
|
|
2131
|
+
children?: React_2.ReactNode;
|
|
2132
|
+
/** Appended to internal classes on the containing `div` element. */
|
|
2133
|
+
className?: string;
|
|
1524
2134
|
[prop: string]: any;
|
|
1525
2135
|
}
|
|
1526
2136
|
|
|
1527
2137
|
export declare interface MenuProps extends Omit<React_2.AllHTMLAttributes<HTMLButtonElement | HTMLDivElement>, 'label' | 'onChange'> {
|
|
1528
|
-
|
|
2138
|
+
/** Appended to internal classes on the flyout container element with `role="menu"`. */
|
|
1529
2139
|
flyoutClassName?: string;
|
|
2140
|
+
/** Replaces the default Button anchor.
|
|
2141
|
+
|
|
2142
|
+
If providing a custom component, it must accept the following props: `ref`, `role`, `tabIndex`, `aria-expanded`, `aria-haspopup`, `onClick`, `onKeyDown`. If you provide your own `onClick` or `onKeyDown`, it will be merged with the built-in behavior.
|
|
2143
|
+
|
|
2144
|
+
Native elements like `button`, `div`, or `span` will work by default. */
|
|
1530
2145
|
anchor?: React_2.ReactElement & React_2.RefAttributes<HTMLElement>;
|
|
2146
|
+
/** List of `MenuItem`s. */
|
|
1531
2147
|
children?: React_2.ReactNode;
|
|
2148
|
+
/** Disables the menu so that it cannot be opened.
|
|
2149
|
+
* @defaultValue false
|
|
2150
|
+
*/
|
|
1532
2151
|
disabled?: boolean;
|
|
1533
|
-
|
|
2152
|
+
/** Label to be used on the menu button. */
|
|
1534
2153
|
label?: React_2.ReactNode;
|
|
2154
|
+
/** Maximum height to be applied to the menu item container. This will enable scrolling. */
|
|
1535
2155
|
maxHeight?: string | number;
|
|
2156
|
+
/** Handler to be called when the `isOpen` value changes. */
|
|
1536
2157
|
onIsOpenChange?: (newIsOpen: boolean) => void;
|
|
2158
|
+
/** Indicates if the menu flyout is open.
|
|
2159
|
+
* @defaultValue false
|
|
2160
|
+
*/
|
|
1537
2161
|
isOpen?: boolean;
|
|
2162
|
+
/** Where to prioritize placement of the menu item container.
|
|
2163
|
+
* @defaultValue 'bottom-start'
|
|
2164
|
+
*/
|
|
1538
2165
|
placement?: ComputedPlacement;
|
|
2166
|
+
/** The container element where the Menu flyout should be rendered. Overrides the default set by [UIProvider](/components/ui-provider). */
|
|
1539
2167
|
portalTarget?: HTMLElement;
|
|
2168
|
+
/** Controls whether the menu should be searchable or not.
|
|
2169
|
+
* @defaultValue false
|
|
2170
|
+
*/
|
|
1540
2171
|
searchable?: boolean;
|
|
2172
|
+
/** If `searchable` is `true`, controls whether the menu items are filtered based on the search input's value or not. This prop should be `true` when menu items are asynchronously loaded based on the search input's value.
|
|
2173
|
+
* @defaultValue false
|
|
2174
|
+
*/
|
|
1541
2175
|
isSearchFilteringDisabled?: boolean;
|
|
2176
|
+
/** The value of the search input if `searchable` prop is `true`. */
|
|
1542
2177
|
searchValue?: string;
|
|
2178
|
+
/** Handler to be called when the search input value changes (if `searchable` prop is `true`). */
|
|
1543
2179
|
onSearchValueChange?: (newValue: string) => void;
|
|
2180
|
+
/** The z-index of the menu item container. */
|
|
1544
2181
|
zIndex?: number;
|
|
2182
|
+
/** Controls whether options should be virtualized. Useful for performance in large lists.
|
|
2183
|
+
* @defaultValue false
|
|
2184
|
+
*/
|
|
2185
|
+
isVirtualized?: boolean;
|
|
2186
|
+
/** Appended to internal classes on the `button` element. */
|
|
2187
|
+
className?: string;
|
|
1545
2188
|
[prop: string]: any;
|
|
1546
2189
|
}
|
|
1547
2190
|
|
|
@@ -1552,7 +2195,9 @@ export declare const Modal: React_2.ForwardRefExoticComponent<ModalProps & React
|
|
|
1552
2195
|
export declare const ModalBody: React_2.ForwardRefExoticComponent<ModalBodyProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
1553
2196
|
|
|
1554
2197
|
export declare interface ModalBodyProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
2198
|
+
/** The contents of the modal body. */
|
|
1555
2199
|
children?: React_2.ReactNode;
|
|
2200
|
+
/** Appended to internal classes on the containing `div` element. */
|
|
1556
2201
|
className?: string;
|
|
1557
2202
|
[prop: string]: any;
|
|
1558
2203
|
}
|
|
@@ -1560,7 +2205,9 @@ export declare interface ModalBodyProps extends React_2.AllHTMLAttributes<HTMLDi
|
|
|
1560
2205
|
export declare const ModalFooter: React_2.ForwardRefExoticComponent<ModalFooterProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
1561
2206
|
|
|
1562
2207
|
export declare interface ModalFooterProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
2208
|
+
/** The contents of the modal footer. */
|
|
1563
2209
|
children?: React_2.ReactNode;
|
|
2210
|
+
/** Appended to internal classes on the containing `div` element. */
|
|
1564
2211
|
className?: string;
|
|
1565
2212
|
[prop: string]: any;
|
|
1566
2213
|
}
|
|
@@ -1568,36 +2215,71 @@ export declare interface ModalFooterProps extends React_2.AllHTMLAttributes<HTML
|
|
|
1568
2215
|
export declare const ModalHeader: React_2.ForwardRefExoticComponent<ModalHeaderProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
1569
2216
|
|
|
1570
2217
|
export declare interface ModalHeaderProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
2218
|
+
/** The contents of the modal header. */
|
|
1571
2219
|
children?: React_2.ReactNode;
|
|
2220
|
+
/** Appended to internal classes on the containing `div` element. */
|
|
1572
2221
|
className?: string;
|
|
1573
2222
|
[prop: string]: any;
|
|
1574
2223
|
}
|
|
1575
2224
|
|
|
1576
2225
|
export declare interface ModalProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
2226
|
+
/** The maximum size of the modal. The modal gets smaller as the screen width or height gets smaller. */
|
|
1577
2227
|
maxSize?: 'small' | 'medium' | 'large' | 'xl';
|
|
1578
2228
|
/**
|
|
1579
2229
|
* @deprecated
|
|
1580
|
-
*
|
|
2230
|
+
* @internal
|
|
1581
2231
|
* This prop is no longer unstable; use the `maxSize` prop instead
|
|
1582
2232
|
*/
|
|
1583
2233
|
unstable_maxSize?: 'small' | 'medium' | 'large' | 'xl';
|
|
2234
|
+
/** Sets the Modal width to fill the screen regardless of size, up to the width specified by the maxSize prop.
|
|
2235
|
+
* @defaultValue false
|
|
2236
|
+
*/
|
|
1584
2237
|
isResponsive?: boolean;
|
|
2238
|
+
/** Whether or not to display the modal.
|
|
2239
|
+
* @defaultValue false
|
|
2240
|
+
*/
|
|
1585
2241
|
open?: boolean;
|
|
2242
|
+
/** An element ref to focus when the `Modal` opens. If this prop is not used, either the close icon button or `Modal` container will be focused. */
|
|
1586
2243
|
elementRefToFocusOnOpen?: React_2.RefObject<HTMLElement>;
|
|
2244
|
+
/** If `true`, the `Modal` will not shrink in height to fit the content. This prop only works when `maxSize` is defined.
|
|
2245
|
+
* @defaultValue false
|
|
2246
|
+
*/
|
|
1587
2247
|
unstable_isHeightExpandedToMaxSize?: boolean;
|
|
2248
|
+
/**
|
|
2249
|
+
* @deprecated
|
|
2250
|
+
* @internal
|
|
2251
|
+
* This prop should be replaced with the `onClose` prop. Handler to be called when the user presses the `Escape` key or clicks outside the modal dialog (on the overlay). Should only be used to close the modal if action is not required by the user. */
|
|
1588
2252
|
onDismiss?: (event: React_2.MouseEvent<HTMLDivElement> | React_2.KeyboardEvent<HTMLDivElement>) => void;
|
|
2253
|
+
/** Handler to be called when the user clicks the close icon or presses the Escape key. Should only be used to close the modal if action is not required by the user. */
|
|
1589
2254
|
onClose?: (event: React_2.MouseEvent<HTMLButtonElement> | React_2.KeyboardEvent<HTMLDivElement>) => void;
|
|
2255
|
+
/** An element ref to focus when the `Modal` closes. If this prop is not used, the element that was focused prior to the `Modal` opening will be the element that is focused when the `Modal` closes. */
|
|
1590
2256
|
elementRefToFocusOnClose?: React_2.RefObject<HTMLElement>;
|
|
1591
|
-
|
|
2257
|
+
/** The z-index of the modal.
|
|
2258
|
+
* @defaultValue 1000
|
|
2259
|
+
*/
|
|
1592
2260
|
zIndex?: number;
|
|
2261
|
+
/** The container element where the Modal should be rendered. Overrides the default set by [UIProvider](/components/ui-provider). */
|
|
1593
2262
|
portalTarget?: HTMLElement;
|
|
2263
|
+
/** Disables the mechanism that cycles focus within the modal. If using this prop, custom implementation of this behavior must exist to remain accessible.
|
|
2264
|
+
* @defaultValue false
|
|
2265
|
+
*/
|
|
1594
2266
|
dangerouslyDisableFocusLock?: boolean;
|
|
2267
|
+
/** `ModalHeader`, `ModalBody`, or `ModalFooter` components. */
|
|
2268
|
+
children?: React_2.ReactNode;
|
|
2269
|
+
/** Appended to internal classes on the modal `div` element. */
|
|
2270
|
+
className?: string;
|
|
1595
2271
|
[prop: string]: any;
|
|
1596
2272
|
}
|
|
1597
2273
|
|
|
1598
2274
|
declare interface NamedIconsProps extends React_2.SVGProps<SVGSVGElement> {
|
|
2275
|
+
/**
|
|
2276
|
+
* The size of the icon.
|
|
2277
|
+
* @defaultValue 'medium'
|
|
2278
|
+
*/
|
|
1599
2279
|
size?: 'small' | 'medium' | 'large';
|
|
2280
|
+
/** Appended to internal classes on the `svg` element. */
|
|
1600
2281
|
className?: string;
|
|
2282
|
+
/** Determines if the icon should be ignored by screen readers. */
|
|
1601
2283
|
'aria-hidden'?: boolean | 'true' | 'false';
|
|
1602
2284
|
[prop: string]: any;
|
|
1603
2285
|
}
|
|
@@ -1653,45 +2335,104 @@ export declare interface NumberStepperInputProps extends Omit<React_2.AllHTMLAtt
|
|
|
1653
2335
|
}
|
|
1654
2336
|
|
|
1655
2337
|
export declare interface NumberStepperProps extends Omit<React_2.AllHTMLAttributes<HTMLSpanElement>, 'onChange'> {
|
|
2338
|
+
/** Disables default interaction.
|
|
2339
|
+
* @defaultValue false
|
|
2340
|
+
*/
|
|
1656
2341
|
isDisabled?: boolean;
|
|
2342
|
+
/** Added to the containing `span` element and to the main sub-components, each with their own suffix:
|
|
2343
|
+
* - NumberStepperDecrement: `-Decrement`
|
|
2344
|
+
* - NumberStepperIncrement: `-Increment`
|
|
2345
|
+
* - NumberStepperInput: `-Input`
|
|
2346
|
+
*/
|
|
1657
2347
|
'data-testid'?: string;
|
|
2348
|
+
/** Forwarded to `theNumberStepperInput` as an `id`. */
|
|
1658
2349
|
inputId?: string;
|
|
2350
|
+
/** Initial value of NumberStepper.
|
|
2351
|
+
* @defaultValue 0
|
|
2352
|
+
*/
|
|
1659
2353
|
initialValue?: number;
|
|
2354
|
+
/** Value of NumberStepper. Overwrites `initialValue`. */
|
|
1660
2355
|
value?: number;
|
|
2356
|
+
/** A stepping interval to use when incrementing and decrementing.
|
|
2357
|
+
* @defaultValue 1
|
|
2358
|
+
*/
|
|
1661
2359
|
step?: number;
|
|
2360
|
+
/** The minimum value to accept. Must be less than or equal to the `max` property. */
|
|
1662
2361
|
min?: number;
|
|
2362
|
+
/** The maximum value to accept. Must be greater than or equal to the `min` property. */
|
|
1663
2363
|
max?: number;
|
|
2364
|
+
/** Determines the decimal separator. See `Localization` above for more information.
|
|
2365
|
+
* @defaultValue 'both'
|
|
2366
|
+
*/
|
|
1664
2367
|
decimalSeparator?: 'period' | 'comma' | 'both';
|
|
2368
|
+
/** Determines whether or not decimal numbers are allowed.
|
|
2369
|
+
* @defaultValue true
|
|
2370
|
+
*/
|
|
1665
2371
|
allowDecimalNumbers?: boolean;
|
|
1666
|
-
|
|
2372
|
+
/** An accessible label for NumberStepper to be used by screen readers. This prop is forwarded to the `NumberStepperInput`. */
|
|
1667
2373
|
'aria-label'?: string;
|
|
2374
|
+
/** The id of an element that acts as a label for NumberStepper. This prop is forwarded to the `NumberStepperInput`. */
|
|
1668
2375
|
'aria-labelledby'?: string;
|
|
2376
|
+
/** The id of an element that describes the NumberStepper. This prop is forwarded to the `NumberStepperInput`. */
|
|
1669
2377
|
'aria-describedby'?: string;
|
|
2378
|
+
/** For advanced use cases when needing to access sub-components directly. Must contain NumberStepperIncrement, NumberStepperDecrement, and NumberStepperInput. */
|
|
1670
2379
|
children?: React_2.ReactNode;
|
|
2380
|
+
/** Handler to be called when the value changes. */
|
|
1671
2381
|
onChange?: (value: number) => void;
|
|
2382
|
+
/** Handler to be called when one of the parts of the component gains focus, if no part had focus previously. */
|
|
1672
2383
|
onFocus?: React_2.FocusEventHandler<HTMLSpanElement>;
|
|
2384
|
+
/** Handler to be called when every part of the component has lost focus. */
|
|
1673
2385
|
onBlur?: React_2.FocusEventHandler<HTMLSpanElement>;
|
|
2386
|
+
/** Appended to internal classes on the containing `span` element. */
|
|
2387
|
+
className?: string;
|
|
1674
2388
|
}
|
|
1675
2389
|
|
|
1676
2390
|
export declare const PageContainer: React_2.ForwardRefExoticComponent<PageContainerProps & React_2.RefAttributes<HTMLElement>>;
|
|
1677
2391
|
|
|
1678
2392
|
export declare interface PageContainerProps {
|
|
2393
|
+
/** The sections of your app. Should be some subset of the following:
|
|
2394
|
+
* - `PageHeader`
|
|
2395
|
+
* - [`SidebarNav`](/components/sidebar-nav)
|
|
2396
|
+
* - [`ConfigPane`](/components/config-pane)
|
|
2397
|
+
* - `MainContent`
|
|
2398
|
+
*/
|
|
1679
2399
|
children?: React_2.ReactNode;
|
|
2400
|
+
/** Class added to the containing `section` */
|
|
1680
2401
|
className?: string;
|
|
2402
|
+
/** Test id added to the containing `section` */
|
|
2403
|
+
'data-testid'?: string;
|
|
2404
|
+
/** Unique id added to the containing `section` */
|
|
1681
2405
|
id?: string;
|
|
2406
|
+
/** Label added to the containing `section` */
|
|
1682
2407
|
'aria-label'?: string;
|
|
2408
|
+
/** Id of the label element added to the containing `section` */
|
|
1683
2409
|
'aria-labelledby'?: string;
|
|
2410
|
+
/** Id of the description element added to the containing `section` */
|
|
1684
2411
|
'aria-describedby'?: string;
|
|
1685
2412
|
}
|
|
1686
2413
|
|
|
1687
2414
|
export declare const PageHeader: React_2.ForwardRefExoticComponent<PageHeaderProps & React_2.RefAttributes<HTMLElement>>;
|
|
1688
2415
|
|
|
1689
2416
|
export declare interface PageHeaderProps {
|
|
2417
|
+
/** The header content for your app.
|
|
2418
|
+
*
|
|
2419
|
+
* This is likely where you will render your Global Wrapper header
|
|
2420
|
+
* for a customer-facing page. View the getting started guide linked
|
|
2421
|
+
* in the global wrapper Slack channel (#global-wrapper) for more information
|
|
2422
|
+
* on how to add that to your app
|
|
2423
|
+
*/
|
|
1690
2424
|
children?: React_2.ReactNode;
|
|
2425
|
+
/** Class added to the containing `header` */
|
|
1691
2426
|
className?: string;
|
|
2427
|
+
/** Test id added to the containing `header` */
|
|
2428
|
+
'data-testid'?: string;
|
|
2429
|
+
/** Unique id added to the containing `header` */
|
|
1692
2430
|
id?: string;
|
|
2431
|
+
/** Label added to the containing `header` */
|
|
1693
2432
|
'aria-label'?: string;
|
|
2433
|
+
/** Id of the label element added to the containing `header` */
|
|
1694
2434
|
'aria-labelledby'?: string;
|
|
2435
|
+
/** Id of the description element added to the containing `header` */
|
|
1695
2436
|
'aria-describedby'?: string;
|
|
1696
2437
|
}
|
|
1697
2438
|
|
|
@@ -1702,9 +2443,13 @@ export declare interface PageHeaderProps {
|
|
|
1702
2443
|
export declare const Pagination: React_2.ForwardRefExoticComponent<PaginationProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
1703
2444
|
|
|
1704
2445
|
export declare interface PaginationButtonProps extends Omit<ButtonProps, 'type' | 'kind' | 'full' | 'small'> {
|
|
2446
|
+
/** Will not include the suffix from the `Pagination` component. */
|
|
1705
2447
|
'data-testid'?: string;
|
|
2448
|
+
/** Overrides the built-in logic for disabling the button. */
|
|
1706
2449
|
disabled?: boolean;
|
|
2450
|
+
/** Handler to be called when the button is clicked. */
|
|
1707
2451
|
onClick?: (event: React_2.MouseEvent<HTMLButtonElement>) => void;
|
|
2452
|
+
/** Appended to internal classes on the [Button](/components/button) component. */
|
|
1708
2453
|
className?: string;
|
|
1709
2454
|
[prop: string]: any;
|
|
1710
2455
|
}
|
|
@@ -1722,14 +2467,39 @@ export declare const PaginationNextButton: React_2.ForwardRefExoticComponent<Pag
|
|
|
1722
2467
|
export declare const PaginationPageInput: React_2.ForwardRefExoticComponent<PaginationPageInputProps & React_2.RefAttributes<HTMLInputElement>>;
|
|
1723
2468
|
|
|
1724
2469
|
export declare interface PaginationPageInputProps extends Omit<Pick<InputProps, KnownKeys<InputProps>>, 'onChange'> {
|
|
2470
|
+
/** @internal */
|
|
2471
|
+
value?: InputProps['value'];
|
|
2472
|
+
/** @internal */
|
|
2473
|
+
defaultValue?: InputProps['defaultValue'];
|
|
2474
|
+
/** @internal */
|
|
2475
|
+
disabled?: InputProps['disabled'];
|
|
2476
|
+
/** @internal */
|
|
2477
|
+
full?: InputProps['full'];
|
|
2478
|
+
/** @internal */
|
|
2479
|
+
invalid?: InputProps['invalid'];
|
|
2480
|
+
/** @internal */
|
|
2481
|
+
multiline?: InputProps['multiline'];
|
|
2482
|
+
/** @internal */
|
|
2483
|
+
rows?: InputProps['rows'];
|
|
2484
|
+
/** @internal */
|
|
2485
|
+
small?: InputProps['small'];
|
|
2486
|
+
/** @internal */
|
|
2487
|
+
type?: InputProps['type'];
|
|
2488
|
+
/** @internal */
|
|
2489
|
+
'aria-describedby'?: InputProps['aria-describedby'];
|
|
2490
|
+
/** @internal */
|
|
2491
|
+
readOnly?: InputProps['readOnly'];
|
|
2492
|
+
/** Will not include the suffix from the `Pagination` component. */
|
|
1725
2493
|
'data-testid'?: string;
|
|
1726
|
-
|
|
1727
|
-
'aria-labelledby'?: string;
|
|
1728
|
-
'aria-describedby'?: string;
|
|
2494
|
+
/** Handler to be called when the value changes. */
|
|
1729
2495
|
onChange?: (event: React_2.ChangeEvent<HTMLInputElement>) => void;
|
|
2496
|
+
/** Handler to be called when the input loses focus. */
|
|
1730
2497
|
onBlur?: (event: React_2.FocusEvent<HTMLInputElement>) => void;
|
|
2498
|
+
/** Handler to be called when the input gets focus. */
|
|
1731
2499
|
onFocus?: (event: React_2.FocusEvent<HTMLInputElement>) => void;
|
|
2500
|
+
/** Appended to internal classes on the [Input](/components/input) component. */
|
|
1732
2501
|
className?: string;
|
|
2502
|
+
/** Appended to internal styles on the [Input](/components/input) component. */
|
|
1733
2503
|
style?: React_2.CSSProperties;
|
|
1734
2504
|
[prop: string]: any;
|
|
1735
2505
|
}
|
|
@@ -1741,63 +2511,117 @@ export declare interface PaginationPageInputProps extends Omit<Pick<InputProps,
|
|
|
1741
2511
|
export declare const PaginationPreviousButton: React_2.ForwardRefExoticComponent<PaginationButtonProps & React_2.RefAttributes<HTMLButtonElement>>;
|
|
1742
2512
|
|
|
1743
2513
|
export declare interface PaginationProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
2514
|
+
/** Added to the containing `div` element and to the main sub-components, each with their own suffix:
|
|
2515
|
+
* - PaginationPreviousButton: `-PreviousButton`
|
|
2516
|
+
* - PaginationNextButton: `-NextButton`
|
|
2517
|
+
* - PaginationPageInput: `-PageInput` */
|
|
1744
2518
|
'data-testid'?: string;
|
|
2519
|
+
/** The maximum number of pages to paginate across. When `undefined`, only pagination arrows will be shown. Note that when not using `numPages`, you can provide sub-components and use the `disabled` prop on the buttons to control when they are disabled (See the "Advanced" example above). */
|
|
1745
2520
|
numPages?: number;
|
|
2521
|
+
/** The current page being displayed. The previous button is disabled when `currentPage === 1`. The next button is disabled when `currentPage === numPages`.
|
|
2522
|
+
* @defaultValue 1
|
|
2523
|
+
*/
|
|
1746
2524
|
currentPage?: number;
|
|
2525
|
+
/** Handler to be called when a page is changed by clicking on the next or previous buttons. */
|
|
1747
2526
|
onPageChange?: (event: {
|
|
1748
2527
|
page: number;
|
|
1749
2528
|
}) => void;
|
|
1750
|
-
|
|
1751
|
-
children?: React_2.ReactNode;
|
|
2529
|
+
/** An accessible label for the PaginationPageInput that is used by screen readers. */
|
|
1752
2530
|
'aria-label'?: string;
|
|
2531
|
+
/** The id of an element that acts as a label for the PaginationPageInput. */
|
|
1753
2532
|
'aria-labelledby'?: string;
|
|
2533
|
+
/** The id of an element that describes the PaginationPageInput. */
|
|
1754
2534
|
'aria-describedby'?: string;
|
|
2535
|
+
/** Appended to internal classes on the containing `div` element. */
|
|
2536
|
+
className?: string;
|
|
1755
2537
|
[prop: string]: any;
|
|
1756
2538
|
}
|
|
1757
2539
|
|
|
1758
2540
|
export declare const Popover: React_2.ForwardRefExoticComponent<PopoverProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
1759
2541
|
|
|
1760
2542
|
export declare interface PopoverProps extends Omit<React_2.AllHTMLAttributes<HTMLDivElement>, 'content'> {
|
|
2543
|
+
/** Whether or not to display the popover content.
|
|
2544
|
+
* @defaultValue false
|
|
2545
|
+
*/
|
|
1761
2546
|
show?: boolean;
|
|
2547
|
+
/** Handler to be called when the user presses the Escape key when the Popover is open. It is recommended that the `show` prop is set to `false` when this function is called. If the `show` prop is not set to `false` when this function is called, keyboard users will be stuck inside of the `Popover`, and will not be able to navigate the rest of the page. */
|
|
1762
2548
|
onClose?: (event: React_2.KeyboardEvent<HTMLDivElement>) => void;
|
|
2549
|
+
/** Content of the popover. */
|
|
1763
2550
|
content?: React_2.ReactNode;
|
|
2551
|
+
/** Dictates the position of the popover relative to its anchor.
|
|
2552
|
+
* @defaultValue 'top'
|
|
2553
|
+
*/
|
|
1764
2554
|
placement?: ComputedPlacement;
|
|
2555
|
+
/** Element or component to which the popover should be anchored. */
|
|
1765
2556
|
children: React_2.ReactElement & React_2.RefAttributes<HTMLElement>;
|
|
2557
|
+
/** The z-index of the popover content.
|
|
2558
|
+
* @defaultValue 1000
|
|
2559
|
+
*/
|
|
1766
2560
|
zIndex?: number;
|
|
2561
|
+
/** Appended to internal classes on the containing div element. */
|
|
1767
2562
|
className?: string;
|
|
2563
|
+
/** The container element where the Popover should be rendered. Overrides the default set by [UIProvider](/components/ui-provider). */
|
|
1768
2564
|
portalTarget?: HTMLElement;
|
|
2565
|
+
/** If `true`, removes the arrow that points to the anchor element when the popover is open.
|
|
2566
|
+
* @defaultValue false
|
|
2567
|
+
*/
|
|
1769
2568
|
isArrowRemoved?: boolean;
|
|
2569
|
+
/** Handler to be called when the user clicks outside the popover container or anchor. */
|
|
1770
2570
|
onClickOutside?: (event: MouseEvent) => void;
|
|
1771
|
-
onClick?: (event: React_2.MouseEvent<HTMLDivElement>) => void;
|
|
1772
|
-
onKeyDown?: (event: React_2.KeyboardEvent<HTMLDivElement>) => void;
|
|
1773
|
-
style?: React_2.CSSProperties;
|
|
1774
|
-
id?: string;
|
|
1775
2571
|
[prop: string]: any;
|
|
1776
2572
|
}
|
|
1777
2573
|
|
|
1778
2574
|
export declare const PortalTargetProvider: ({ target, children, }: PortalTargetProviderProps) => JSX.Element;
|
|
1779
2575
|
|
|
1780
2576
|
export declare interface PortalTargetProviderProps {
|
|
2577
|
+
/** The DOM node that will act as the portal target. */
|
|
1781
2578
|
target?: HTMLElement | null;
|
|
2579
|
+
/** Code that requires portalling. */
|
|
1782
2580
|
children?: ReactNode;
|
|
1783
2581
|
}
|
|
1784
2582
|
|
|
1785
2583
|
export declare const QuickSearch: React_2.ForwardRefExoticComponent<QuickSearchProps & React_2.RefAttributes<HTMLInputElement>>;
|
|
1786
2584
|
|
|
1787
2585
|
export declare interface QuickSearchProps extends Omit<React_2.AllHTMLAttributes<HTMLInputElement>, 'onChange' | 'onSelect'> {
|
|
2586
|
+
/** Maximum height to be applied to the menu item container. This will enable scrolling. */
|
|
1788
2587
|
maxHeight?: string | number;
|
|
2588
|
+
/** A function that is called when a suggestion is selected. */
|
|
1789
2589
|
onSelect?: (item: string | {
|
|
1790
2590
|
label: React_2.ReactNode;
|
|
1791
2591
|
value: any;
|
|
1792
2592
|
}) => void;
|
|
2593
|
+
/** Where to prioritize placement of the menu item container.
|
|
2594
|
+
* @defaultValue 'bottom-start'
|
|
2595
|
+
*/
|
|
1793
2596
|
placement?: ComputedPlacement;
|
|
2597
|
+
/** The container element where the QuickSearch flyout should be rendered. Overrides the default set by [UIProvider](/components/ui-provider). */
|
|
1794
2598
|
portalTarget?: HTMLElement;
|
|
2599
|
+
/** The z-index of the menu item container.
|
|
2600
|
+
* @defaultValue 1000
|
|
2601
|
+
*/
|
|
1795
2602
|
zIndex?: number;
|
|
2603
|
+
/** When set to true, the width of the flyout will automatically match the width of the anchor Input.
|
|
2604
|
+
* @defaultValue false
|
|
2605
|
+
*/
|
|
1796
2606
|
isFlyoutFullWidth?: boolean;
|
|
2607
|
+
/** Time to wait in ms since the last input change before calling onSearch. In other words, 'search after I stop typing'.
|
|
2608
|
+
* @defaultValue 0
|
|
2609
|
+
*/
|
|
1797
2610
|
debouncePeriod?: number;
|
|
2611
|
+
/** The initial value for the uncontrolled Input of the QuickSearch component. Cannot use with 'value' prop.
|
|
2612
|
+
* @defaultValue ''
|
|
2613
|
+
*/
|
|
1798
2614
|
defaultValue?: string;
|
|
2615
|
+
/** The minimum number of characters required before onSearch is called automatically.
|
|
2616
|
+
* @defaultValue 1
|
|
2617
|
+
*/
|
|
1799
2618
|
minChars?: number;
|
|
2619
|
+
/** Handler to be called whenever the value of the input changes. */
|
|
1800
2620
|
onChange?: (event: React_2.ChangeEvent<HTMLInputElement>) => void;
|
|
2621
|
+
/** A search function to be called when the input changes, passing the input value as a parameter. It must return an array of strings or objects, optionally wrapped in a Promise. If returning an array of objects, each object should have a `label` and `value` property. The `label` is rendered in the menu and the item is passed as a parameter by `onSelect`.
|
|
2622
|
+
*
|
|
2623
|
+
* If the provided function returns a promise, the most recent searches will take precedence, even if the promises resolve out of order.
|
|
2624
|
+
* */
|
|
1801
2625
|
onSearch: (query: string) => string[] | {
|
|
1802
2626
|
label: React_2.ReactNode;
|
|
1803
2627
|
value: any;
|
|
@@ -1805,7 +2629,11 @@ export declare interface QuickSearchProps extends Omit<React_2.AllHTMLAttributes
|
|
|
1805
2629
|
label: React_2.ReactNode;
|
|
1806
2630
|
value: any;
|
|
1807
2631
|
}[]>;
|
|
2632
|
+
/** Time to wait in ms since onSearch was last called before calling onSearch again. In other words, 'don't search faster than once every X ms, even if I'm typing faster than that'.
|
|
2633
|
+
* @defaultValue 0
|
|
2634
|
+
*/
|
|
1808
2635
|
throttlePeriod?: number;
|
|
2636
|
+
/** The current value for the controlled Input of the QuickSearch component. Must be used with onChange. */
|
|
1809
2637
|
value?: string;
|
|
1810
2638
|
[prop: string]: any;
|
|
1811
2639
|
}
|
|
@@ -1815,40 +2643,77 @@ export declare const Radio: React_2.ForwardRefExoticComponent<RadioProps & React
|
|
|
1815
2643
|
export declare const RadioGroup: React_2.ForwardRefExoticComponent<RadioGroupProps & React_2.RefAttributes<HTMLFieldSetElement>>;
|
|
1816
2644
|
|
|
1817
2645
|
export declare interface RadioGroupProps extends Omit<React_2.AllHTMLAttributes<HTMLFieldSetElement>, 'onChange'> {
|
|
1818
|
-
|
|
2646
|
+
/** Label to display for `RadioGroup`. */
|
|
1819
2647
|
label?: string;
|
|
2648
|
+
/**
|
|
2649
|
+
* Unique name for use with forms.
|
|
2650
|
+
*
|
|
2651
|
+
* See [Form API](../../form/getting-started) for more information.
|
|
2652
|
+
*/
|
|
1820
2653
|
name?: string;
|
|
2654
|
+
/** Initial value of the selected radio button for an uncontrolled radio group (cannot use with `value`). */
|
|
1821
2655
|
defaultValue?: string;
|
|
2656
|
+
/** The value of the selected radio button. Requires use of `onChange`. Cannot use with `defaultValue`. */
|
|
1822
2657
|
value?: string;
|
|
2658
|
+
/** Change handler to be fired when the checkbox state changes. */
|
|
1823
2659
|
onChange?: (event: React_2.ChangeEvent<HTMLInputElement>) => void;
|
|
1824
|
-
|
|
1825
|
-
|
|
2660
|
+
/** The radio buttons to be included in the group. */
|
|
2661
|
+
children: React_2.ReactNode;
|
|
2662
|
+
/** Appended to internal classes on the containing `fieldset` element. */
|
|
2663
|
+
className?: string;
|
|
2664
|
+
/** Adds an error message directly below `RadioGroup` */
|
|
1826
2665
|
errorText?: ReactNode;
|
|
1827
|
-
|
|
2666
|
+
/** Adds additional information directly below `RadioGroup` */
|
|
2667
|
+
helperText?: ReactNode;
|
|
1828
2668
|
[prop: string]: any;
|
|
1829
2669
|
}
|
|
1830
2670
|
|
|
1831
2671
|
export declare const RadioOption: React_2.ForwardRefExoticComponent<RadioOptionProps & React_2.RefAttributes<HTMLLabelElement>>;
|
|
1832
2672
|
|
|
1833
2673
|
export declare interface RadioOptionProps extends Omit<React_2.AllHTMLAttributes<HTMLLabelElement>, 'label'> {
|
|
2674
|
+
/** Value passed to the input element value attribute. */
|
|
1834
2675
|
value: string;
|
|
2676
|
+
/** Label to accompany the radio component */
|
|
1835
2677
|
label: React_2.ReactNode;
|
|
1836
|
-
|
|
1837
|
-
|
|
2678
|
+
/** Disables change events on the radio button and styles it to look as though it cannot be clicked.
|
|
2679
|
+
* @defaultValue false
|
|
2680
|
+
*/
|
|
1838
2681
|
disabled?: boolean;
|
|
2682
|
+
/** Props forwarded to the `input` element. */
|
|
1839
2683
|
inputProps?: Omit<React_2.AllHTMLAttributes<HTMLInputElement>, 'type'>;
|
|
2684
|
+
/** Appended to internal classes on the containing [Label](/components/label) element. */
|
|
2685
|
+
className?: string;
|
|
2686
|
+
/** The id of an element that describes the Radio. */
|
|
1840
2687
|
'aria-describedby'?: string;
|
|
1841
2688
|
[prop: string]: any;
|
|
1842
2689
|
}
|
|
1843
2690
|
|
|
1844
2691
|
export declare interface RadioProps extends React_2.AllHTMLAttributes<HTMLSpanElement> {
|
|
1845
|
-
|
|
1846
|
-
|
|
2692
|
+
/** Disables change events on the radio button and styles it to look as though it cannot be clicked.
|
|
2693
|
+
* @defaultValue false
|
|
2694
|
+
*/
|
|
1847
2695
|
disabled?: boolean;
|
|
2696
|
+
/** Value passed to the input element value attribute. */
|
|
1848
2697
|
value: string;
|
|
2698
|
+
/** Change handler to be called when the radio state changes. Invalid if used with a child of `RadioGroup`. */
|
|
2699
|
+
onChange?: React_2.FormEventHandler<HTMLSpanElement> | undefined;
|
|
2700
|
+
/** Checked state of an controlled radio, likely used with `onChange`. Invalid if used with a child of `RadioGroup`.
|
|
2701
|
+
* @defaultValue false
|
|
2702
|
+
*/
|
|
2703
|
+
checked?: boolean | undefined;
|
|
2704
|
+
/** Initial checked state of an uncontrolled radio (cannot use with `checked` prop). Invalid if used with a child of `RadioGroup`.
|
|
2705
|
+
* @defaultValue false
|
|
2706
|
+
*/
|
|
2707
|
+
defaultChecked?: boolean | undefined;
|
|
2708
|
+
/** Props forwarded to the `input` element. */
|
|
1849
2709
|
inputProps?: Omit<React_2.AllHTMLAttributes<HTMLInputElement>, 'type'>;
|
|
2710
|
+
/** Appended to internal classes on the containing `span` element. */
|
|
2711
|
+
className?: string;
|
|
2712
|
+
/** An accessible label for the Radio that is used by screen readers. */
|
|
1850
2713
|
'aria-label'?: string;
|
|
2714
|
+
/** The id of an element that acts as a label for the Radio. */
|
|
1851
2715
|
'aria-labelledby'?: string;
|
|
2716
|
+
/** The id of an element that describes the Radio. */
|
|
1852
2717
|
'aria-describedby'?: string;
|
|
1853
2718
|
[prop: string]: any;
|
|
1854
2719
|
}
|
|
@@ -1856,18 +2721,39 @@ export declare interface RadioProps extends React_2.AllHTMLAttributes<HTMLSpanEl
|
|
|
1856
2721
|
export declare const RangeSlider: React_2.ForwardRefExoticComponent<RangeSliderProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
1857
2722
|
|
|
1858
2723
|
export declare interface RangeSliderProps extends Omit<React_2.AllHTMLAttributes<HTMLDivElement>, 'onChange'> {
|
|
2724
|
+
/** Array of two numbers for the initial values of an uncontrolled RangeSlider (cannot use with 'value' prop). */
|
|
1859
2725
|
defaultValues?: number[];
|
|
2726
|
+
/** A function called with a number value that returns a custom string representation for the slider button tooltip. Useful for localization. */
|
|
1860
2727
|
formatter?: (value: number) => string;
|
|
2728
|
+
/** The maximum value for the RangeSlider.
|
|
2729
|
+
* @defaultValue 100
|
|
2730
|
+
*/
|
|
1861
2731
|
max?: number;
|
|
2732
|
+
/** The minimum value for the RangeSlider.
|
|
2733
|
+
* @defaultValue 0
|
|
2734
|
+
*/
|
|
1862
2735
|
min?: number;
|
|
2736
|
+
/** Handler to be called whenever the value of the RangeSlider changes. */
|
|
1863
2737
|
onChange?: (values: number[]) => void;
|
|
2738
|
+
/** The amount the Slider increments by.
|
|
2739
|
+
* @defaultValue 1
|
|
2740
|
+
*/
|
|
1864
2741
|
step?: number;
|
|
2742
|
+
/** Array of two numbers for the values of the RangeSlider. Requires use of 'onChange' prop. Cannot use with 'defaultValue' prop. */
|
|
1865
2743
|
values?: number[];
|
|
2744
|
+
/** Appended to internal classes on the containing `div` element. */
|
|
2745
|
+
className?: string;
|
|
2746
|
+
/** An accessible label for the minimum Slider thumb that is used by screen readers. */
|
|
1866
2747
|
minAriaLabel?: string;
|
|
2748
|
+
/** An accessible label for the maximum Slider thumb that is used by screen readers. */
|
|
1867
2749
|
maxAriaLabel?: string;
|
|
2750
|
+
/** The id of an element that acts as a label for the minimum Slider thumb. */
|
|
1868
2751
|
minAriaLabelledBy?: string;
|
|
2752
|
+
/** The id of an element that acts as a label for the maximum Slider thumb. */
|
|
1869
2753
|
maxAriaLabelledBy?: string;
|
|
2754
|
+
/** The id of an element that describes the minimum Slider thumb. */
|
|
1870
2755
|
minAriaDescribedBy?: string;
|
|
2756
|
+
/** The id of an element that describes the maximum Slider thumb. */
|
|
1871
2757
|
maxAriaDescribedBy?: string;
|
|
1872
2758
|
[prop: string]: any;
|
|
1873
2759
|
}
|
|
@@ -1877,34 +2763,125 @@ declare type RenderFunction<T> = (props: T & RefAttributes<HTMLAnchorElement>) =
|
|
|
1877
2763
|
export declare const SearchInput: React_2.ForwardRefExoticComponent<SearchInputProps & React_2.RefAttributes<HTMLInputElement>>;
|
|
1878
2764
|
|
|
1879
2765
|
export declare interface SearchInputProps {
|
|
2766
|
+
/** The initial value for an uncontrolled input.
|
|
2767
|
+
* @defaultValue ''
|
|
2768
|
+
*/
|
|
1880
2769
|
defaultValue?: string;
|
|
2770
|
+
/** The value for the input. */
|
|
1881
2771
|
value?: string;
|
|
2772
|
+
/** Handler to be called when the value of the input changes. */
|
|
1882
2773
|
onChange?: (value: string) => void;
|
|
1883
|
-
|
|
2774
|
+
/** A custom placeholder for the search input. Useful for overriding the `searchText` translation passed in through `UIProvider`. */
|
|
1884
2775
|
placeholder?: string;
|
|
2776
|
+
/** Disables the input element and adds disabled styling.
|
|
2777
|
+
* @defaultValue false
|
|
2778
|
+
*/
|
|
2779
|
+
isDisabled?: boolean;
|
|
2780
|
+
/** Handler to be called when a key is pressed down. */
|
|
2781
|
+
onKeyDown?: (event: React_2.KeyboardEvent<HTMLInputElement>) => void;
|
|
2782
|
+
/** Provided to the `input` element. */
|
|
2783
|
+
'data-testid'?: string;
|
|
2784
|
+
/**
|
|
2785
|
+
* Forwarded to the [`Input`](/components/input) component.
|
|
2786
|
+
*/
|
|
1885
2787
|
'aria-label'?: string;
|
|
2788
|
+
/**
|
|
2789
|
+
* Forwarded to the [`Input`](/components/input) component.
|
|
2790
|
+
*/
|
|
1886
2791
|
'aria-labelledby'?: string;
|
|
2792
|
+
/**
|
|
2793
|
+
* Forwarded to the [`Input`](/components/input) component.
|
|
2794
|
+
*/
|
|
1887
2795
|
'aria-describedby'?: string;
|
|
1888
|
-
|
|
2796
|
+
/**
|
|
2797
|
+
* Forwarded to the [`Input`](/components/input) component.
|
|
2798
|
+
*/
|
|
1889
2799
|
onFocus?: (event: React_2.FocusEvent<HTMLInputElement>) => void;
|
|
2800
|
+
/**
|
|
2801
|
+
* Forwarded to the [`Input`](/components/input) component.
|
|
2802
|
+
*/
|
|
1890
2803
|
onBlur?: (event: React_2.FocusEvent<HTMLInputElement>) => void;
|
|
2804
|
+
/** Appended to internal classes on the containing `span` element. */
|
|
1891
2805
|
className?: string;
|
|
2806
|
+
/** Appended to internal classes on the containing `span` element. */
|
|
1892
2807
|
style?: React_2.CSSProperties;
|
|
2808
|
+
/** An id for the `input` element. */
|
|
1893
2809
|
id?: string;
|
|
1894
|
-
'data-testid'?: string;
|
|
1895
2810
|
}
|
|
1896
2811
|
|
|
1897
2812
|
export declare const SelectMenu: React_2.ForwardRefExoticComponent<SelectMenuProps & React_2.RefAttributes<HTMLElement>>;
|
|
1898
2813
|
|
|
1899
2814
|
export declare interface SelectMenuProps extends Omit<MenuProps, 'defaultValue'> {
|
|
2815
|
+
/** The container element where the Select flyout should be rendered. Overrides the default set by [UIProvider](/components/ui-provider). */
|
|
2816
|
+
portalTarget?: MenuProps['portalTarget'];
|
|
2817
|
+
/** Appended to internal classes on the flyout container element with `role="menu"`. */
|
|
2818
|
+
flyoutClassName?: MenuProps['flyoutClassName'];
|
|
2819
|
+
/** Replaces the default Button anchor.
|
|
2820
|
+
*
|
|
2821
|
+
* If providing a custom component, it must accept the following props: `ref`, `role`, `tabIndex`, `aria-expanded`, `aria-haspopup`, `onClick`, `onKeyDown`. If you provide your own `onClick` or `onKeyDown`, it will be merged with the built-in behavior.
|
|
2822
|
+
*
|
|
2823
|
+
* Native elements like `button`, `div`, or `span` will work by default. */
|
|
2824
|
+
anchor?: MenuProps['anchor'];
|
|
2825
|
+
/** The z-index of the menu item container.
|
|
2826
|
+
* @defaultValue 1000
|
|
2827
|
+
*/
|
|
2828
|
+
zIndex?: MenuProps['zIndex'];
|
|
2829
|
+
/** Handler to be called when the search input value changes (if the `searchable` prop is set to `true`). */
|
|
2830
|
+
onSearchValueChange?: MenuProps['onSearchValueChange'];
|
|
2831
|
+
/** The value of the search input if the `searchable` prop is set to `true`.
|
|
2832
|
+
* @defaultValue ''
|
|
2833
|
+
*/
|
|
2834
|
+
searchValue?: MenuProps['searchValue'];
|
|
2835
|
+
/** If `searchable` is `true`, controls whether the menu items are filtered based on the search input's value or not. This prop should be `true` when menu items are asynchronously loaded based on the search input's value.
|
|
2836
|
+
* @defaultValue false
|
|
2837
|
+
*/
|
|
2838
|
+
isSearchFilteringDisabled?: MenuProps['isSearchFilteringDisabled'];
|
|
2839
|
+
/** Controls whether the menu should be searchable or not.
|
|
2840
|
+
* @defaultValue false
|
|
2841
|
+
*/
|
|
2842
|
+
searchable?: MenuProps['searchable'];
|
|
2843
|
+
/** Where to prioritize placement of the menu item container. Available options are `top-start`, `top`, `top-end`, `right-start`, `right`, `right-end`, `bottom-end`, `bottom`, `bottom-start`, `left-end`, `left`, `left-start`.
|
|
2844
|
+
* @defaultValue 'bottom-start'
|
|
2845
|
+
*/
|
|
2846
|
+
placement?: MenuProps['placement'];
|
|
2847
|
+
/** Maximum height to be applied to the menu item container. This will enable scrolling. */
|
|
2848
|
+
maxHeight?: MenuProps['maxHeight'];
|
|
2849
|
+
/** Disables the menu so that it cannot be opened. */
|
|
2850
|
+
disabled?: MenuProps['disabled'];
|
|
2851
|
+
/** Can be used to control/override the SelectMenu button label. Also used as the label for sub menu items. */
|
|
2852
|
+
label?: MenuProps['label'];
|
|
2853
|
+
/** Handler to be called when the `isOpen` value changes. */
|
|
2854
|
+
onIsOpenChange?: MenuProps['onIsOpenChange'];
|
|
2855
|
+
/** Indicates if the select menu flyout is open.
|
|
2856
|
+
* @defaultValue false
|
|
2857
|
+
*/
|
|
2858
|
+
isOpen?: MenuProps['isOpen'];
|
|
2859
|
+
/** Handler to be called when a menu item is selected. */
|
|
1900
2860
|
onChange?: (value: string | number | string[] | number[]) => void;
|
|
1901
|
-
|
|
1902
|
-
'aria-labelledby'?: string;
|
|
2861
|
+
/** Default label to be used on the SelectMenu button when no item is selected. Note that this has no effect on sub menus, prefer the `label` property instead. */
|
|
1903
2862
|
defaultLabel?: React_2.ReactNode;
|
|
2863
|
+
/** The value of the initially selected menu item. */
|
|
1904
2864
|
defaultValue?: number | number[] | string | string[];
|
|
2865
|
+
/**
|
|
2866
|
+
* @deprecated
|
|
2867
|
+
* @internal
|
|
2868
|
+
* This prop is no longer unstable; use the `isMultiSelect` prop instead
|
|
2869
|
+
*/
|
|
1905
2870
|
unstable_isMultiSelect?: boolean;
|
|
2871
|
+
/** Controls whether the menu and submenus allow multiple items to be selected.
|
|
2872
|
+
* @defaultValue false
|
|
2873
|
+
*/
|
|
1906
2874
|
isMultiSelect?: boolean;
|
|
2875
|
+
/** Controls whether options should be virtualized. Useful for performance in large lists.
|
|
2876
|
+
* @defaultValue false
|
|
2877
|
+
*/
|
|
2878
|
+
isVirtualized?: boolean;
|
|
2879
|
+
/** List of menu item elements. */
|
|
1907
2880
|
children?: React_2.ReactNode;
|
|
2881
|
+
/** An accessible label for `SelectMenu` that is used by screen readers. Internally this value is concatenated with the button contents (if a string). */
|
|
2882
|
+
'aria-label'?: string;
|
|
2883
|
+
/** The id of the element that acts as a label for `SelectMenu`. Internally this value is concatenated with its own id so the button contents are part of the accessible label. */
|
|
2884
|
+
'aria-labelledby'?: string;
|
|
1908
2885
|
}
|
|
1909
2886
|
|
|
1910
2887
|
export declare const SidebarNav: React_2.ForwardRefExoticComponent<SidebarNavProps & React_2.RefAttributes<HTMLElement>>;
|
|
@@ -1912,36 +2889,87 @@ export declare const SidebarNav: React_2.ForwardRefExoticComponent<SidebarNavPro
|
|
|
1912
2889
|
export declare const SidebarNavLink: React_2.ForwardRefExoticComponent<SidebarNavLinkProps & React_2.RefAttributes<HTMLAnchorElement>>;
|
|
1913
2890
|
|
|
1914
2891
|
export declare interface SidebarNavLinkProps {
|
|
2892
|
+
/** The icon to render. See the [Icon](/components/icon) page for available icons. */
|
|
1915
2893
|
icon?: React_2.ForwardRefExoticComponent<NamedIconsProps & React_2.RefAttributes<SVGSVGElement>>;
|
|
2894
|
+
/** Label for the link */
|
|
1916
2895
|
label?: string;
|
|
2896
|
+
/** Destination for the link */
|
|
1917
2897
|
to: string;
|
|
2898
|
+
/** Added to the containing `a`, and to main sub-components with the following suffixes:
|
|
2899
|
+
* - `-link-icon`: assigned to the icon
|
|
2900
|
+
* - `-link-label`: assigned to the label */
|
|
1918
2901
|
'data-testid'?: string;
|
|
1919
2902
|
}
|
|
1920
2903
|
|
|
1921
2904
|
export declare interface SidebarNavProps {
|
|
2905
|
+
/** The links in the nav bar */
|
|
1922
2906
|
children?: React_2.ReactNode;
|
|
2907
|
+
/** Whether to allow expanding and collapsing of the labels
|
|
2908
|
+
* @defaultValue true
|
|
2909
|
+
*/
|
|
1923
2910
|
isCollapsible?: boolean;
|
|
2911
|
+
/** Adds controls for setting collapsed state
|
|
2912
|
+
* @defaultValue false
|
|
2913
|
+
*/
|
|
1924
2914
|
isCollapsed?: boolean;
|
|
2915
|
+
/** Handler to be called whenever `isCollapsed` changes */
|
|
1925
2916
|
onIsCollapsedChange?: (newIsCollapsed: boolean) => void;
|
|
2917
|
+
/** Component for rendering a smart link from your routing framework (e.g. `NavLink` from `react-router-dom`).
|
|
2918
|
+
* **Signature:** `(props: object) => node`
|
|
2919
|
+
* - `props`: The props for the `NavLink`
|
|
2920
|
+
* - `className`: `Function`
|
|
2921
|
+
* - Function that takes in the active state and returns the correct `className`
|
|
2922
|
+
* - **Signature**: `(activeState: boolean | { isActive: boolean }) => string`
|
|
2923
|
+
* - `activeState`: The active state either as a boolean or as a prop object
|
|
2924
|
+
* - `to`: `string`
|
|
2925
|
+
* - Destination for link
|
|
2926
|
+
* - `aria-label`: `string`
|
|
2927
|
+
* - Accessible label for link
|
|
2928
|
+
* - `data-testid`: `string`
|
|
2929
|
+
* - Test id for link*/
|
|
1926
2930
|
NavLink: NavLink;
|
|
2931
|
+
/** Added to the containing `div`, and to main sub-components with the following suffixes:
|
|
2932
|
+
* - `-navigation`: assigned to the navigation container
|
|
2933
|
+
* - `-expand-collapse-button`: assigned to the expand/collapse button */
|
|
2934
|
+
'data-testid'?: string;
|
|
2935
|
+
/** Passed to the `nav` element */
|
|
1927
2936
|
'aria-label'?: string;
|
|
2937
|
+
/** Passed to the `nav` element */
|
|
1928
2938
|
'aria-labelledby'?: string;
|
|
2939
|
+
/** Passed to the `nav` element */
|
|
1929
2940
|
'aria-describedby'?: string;
|
|
1930
|
-
'data-testid'?: string;
|
|
1931
2941
|
}
|
|
1932
2942
|
|
|
1933
2943
|
export declare const Slider: React_2.ForwardRefExoticComponent<SliderProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
1934
2944
|
|
|
1935
2945
|
export declare interface SliderProps extends Omit<React_2.AllHTMLAttributes<HTMLDivElement>, 'onChange'> {
|
|
2946
|
+
/** Initial value for an uncontrolled Slider (cannot use with 'value' prop). */
|
|
1936
2947
|
defaultValue?: number;
|
|
2948
|
+
/** A function called with a number value that returns a custom string representation for the slider button tooltip. Useful for localization. */
|
|
1937
2949
|
formatter?: (value: number) => string;
|
|
2950
|
+
/** The maximum value for the Slider.
|
|
2951
|
+
* @defaultValue 100
|
|
2952
|
+
*/
|
|
1938
2953
|
max?: number;
|
|
2954
|
+
/** The minimum value for the Slider.
|
|
2955
|
+
* @defaultValue 0
|
|
2956
|
+
*/
|
|
1939
2957
|
min?: number;
|
|
2958
|
+
/** Handler to be called whenever the value of the Slider changes. */
|
|
1940
2959
|
onChange?: (value: number) => void;
|
|
2960
|
+
/** The amount the Slider increments by.
|
|
2961
|
+
* @defaultValue 1
|
|
2962
|
+
*/
|
|
1941
2963
|
step?: number;
|
|
2964
|
+
/** The value for the Slider. Requires use of 'onChange' prop. Cannot use with 'defaultValue' prop. */
|
|
1942
2965
|
value?: number;
|
|
2966
|
+
/** Appended to internal classes on the containing `div` element. */
|
|
2967
|
+
className?: string;
|
|
2968
|
+
/** An accessible label for the Slider that is used by screen readers. */
|
|
1943
2969
|
'aria-label'?: string;
|
|
2970
|
+
/** The id of an element that acts as a label for the Slider. */
|
|
1944
2971
|
'aria-labelledby'?: string;
|
|
2972
|
+
/** The id of an element that describes the Slider. */
|
|
1945
2973
|
'aria-describedby'?: string;
|
|
1946
2974
|
[prop: string]: any;
|
|
1947
2975
|
}
|
|
@@ -1951,31 +2979,65 @@ export declare const Switch: React_2.ForwardRefExoticComponent<SwitchProps & Rea
|
|
|
1951
2979
|
export declare const SwitchField: React_2.ForwardRefExoticComponent<SwitchFieldProps & React_2.RefAttributes<HTMLLabelElement>>;
|
|
1952
2980
|
|
|
1953
2981
|
export declare interface SwitchFieldProps extends Omit<React_2.AllHTMLAttributes<HTMLLabelElement>, 'label' | 'onChange'> {
|
|
1954
|
-
id?: string;
|
|
1955
|
-
label: React_2.ReactNode;
|
|
1956
|
-
className?: string;
|
|
1957
2982
|
checked?: boolean;
|
|
2983
|
+
/** The initial value of an uncontrolled switch. Cannot be used with 'checked' prop. */
|
|
1958
2984
|
defaultChecked?: boolean;
|
|
2985
|
+
/** Disables interactivity with the switch.
|
|
2986
|
+
* @defaultValue false
|
|
2987
|
+
*/
|
|
1959
2988
|
disabled?: boolean;
|
|
2989
|
+
/** Label positioned to the right of the switch. */
|
|
2990
|
+
label: React_2.ReactNode;
|
|
2991
|
+
/** Change handler to be called when the switch state changes. The value and state of the switch can be retrieved via `event.target.value` and `event.target.checked`. */
|
|
1960
2992
|
onChange?: (event: React_2.ChangeEvent<HTMLInputElement>) => void;
|
|
2993
|
+
/** The value of the component. */
|
|
1961
2994
|
value?: string;
|
|
2995
|
+
/** Props forwarded to the `input` element. */
|
|
1962
2996
|
inputProps?: Omit<React_2.AllHTMLAttributes<HTMLInputElement>, 'type' | 'role'>;
|
|
2997
|
+
/** Identifier for the input element. Commonly used in forms with a label.
|
|
2998
|
+
* @defaultValue ''
|
|
2999
|
+
*/
|
|
3000
|
+
id?: string;
|
|
3001
|
+
/** Appended to internal classes on the containing [`Label`](/components/label) component. */
|
|
3002
|
+
className?: string;
|
|
3003
|
+
/** The state of whether the switch is on or off.
|
|
3004
|
+
* @defaultValue false
|
|
3005
|
+
*/
|
|
3006
|
+
/** The id of an element that describes the Switch. */
|
|
1963
3007
|
'aria-describedby'?: string;
|
|
1964
3008
|
[prop: string]: any;
|
|
1965
3009
|
}
|
|
1966
3010
|
|
|
1967
3011
|
export declare interface SwitchProps extends React_2.AllHTMLAttributes<HTMLSpanElement> {
|
|
1968
|
-
|
|
1969
|
-
|
|
3012
|
+
/** The state of whether the switch is on or off.
|
|
3013
|
+
* @defaultValue false
|
|
3014
|
+
*/
|
|
1970
3015
|
checked?: boolean;
|
|
3016
|
+
/** The initial value of an uncontrolled switch. Cannot be used with 'checked' prop. */
|
|
1971
3017
|
defaultChecked?: boolean;
|
|
3018
|
+
/** Disables interactivity with the switch.
|
|
3019
|
+
* @defaultValue false
|
|
3020
|
+
*/
|
|
1972
3021
|
disabled?: boolean;
|
|
3022
|
+
/** Change handler to be called when the switch state changes. The value and state of the switch can be retrieved via `event.target.value` and `event.target.checked`. */
|
|
1973
3023
|
onChange?: (event: React_2.ChangeEvent<HTMLInputElement>) => void;
|
|
3024
|
+
/** The value of the component. */
|
|
1974
3025
|
value?: string;
|
|
3026
|
+
/** Props forwarded to the `input` element. */
|
|
1975
3027
|
inputProps?: Omit<React_2.AllHTMLAttributes<HTMLInputElement>, 'type' | 'role'>;
|
|
3028
|
+
/** Identifier for the input element. Commonly used in forms with a label.
|
|
3029
|
+
* @defaultValue ''
|
|
3030
|
+
*/
|
|
3031
|
+
id?: string;
|
|
3032
|
+
/** Appended to internal classes on the containing `span` element. */
|
|
3033
|
+
className?: string;
|
|
3034
|
+
/** An accessible label for the Switch that is used by screen readers. */
|
|
1976
3035
|
'aria-label'?: string;
|
|
3036
|
+
/** The id of an element that acts as a label for the Switch. */
|
|
1977
3037
|
'aria-labelledby'?: string;
|
|
3038
|
+
/** The id of an element that describes the Switch. */
|
|
1978
3039
|
'aria-describedby'?: string;
|
|
3040
|
+
/** Forwarded to the `input` element. */
|
|
1979
3041
|
tabIndex?: number;
|
|
1980
3042
|
[prop: string]: any;
|
|
1981
3043
|
}
|
|
@@ -1987,7 +3049,9 @@ export declare const Table: React_2.ForwardRefExoticComponent<TableProps & React
|
|
|
1987
3049
|
export declare const TableBody: React_2.ForwardRefExoticComponent<TableBodyProps & React_2.RefAttributes<HTMLTableSectionElement>>;
|
|
1988
3050
|
|
|
1989
3051
|
export declare interface TableBodyProps extends React_2.AllHTMLAttributes<HTMLTableSectionElement> {
|
|
3052
|
+
/** Contents of the component. */
|
|
1990
3053
|
children?: React_2.ReactNode;
|
|
3054
|
+
/** Appended to internal classes on the `tbody `element. */
|
|
1991
3055
|
className?: string;
|
|
1992
3056
|
[prop: string]: any;
|
|
1993
3057
|
}
|
|
@@ -1995,7 +3059,9 @@ export declare interface TableBodyProps extends React_2.AllHTMLAttributes<HTMLTa
|
|
|
1995
3059
|
export declare const TableCell: React_2.ForwardRefExoticComponent<TableCellProps & React_2.RefAttributes<HTMLTableCellElement>>;
|
|
1996
3060
|
|
|
1997
3061
|
export declare interface TableCellProps extends React_2.AllHTMLAttributes<HTMLTableCellElement> {
|
|
3062
|
+
/** Contents of the component. */
|
|
1998
3063
|
children?: React_2.ReactNode;
|
|
3064
|
+
/** Appended to internal classes on the `td` element. */
|
|
1999
3065
|
className?: string;
|
|
2000
3066
|
[prop: string]: any;
|
|
2001
3067
|
}
|
|
@@ -2005,19 +3071,25 @@ export declare const TableHead: React_2.ForwardRefExoticComponent<TableHeadProps
|
|
|
2005
3071
|
export declare const TableHeaderCell: React_2.ForwardRefExoticComponent<TableHeaderCellProps & React_2.RefAttributes<HTMLTableCellElement>>;
|
|
2006
3072
|
|
|
2007
3073
|
export declare interface TableHeaderCellProps extends React_2.AllHTMLAttributes<HTMLTableCellElement> {
|
|
3074
|
+
/** Contents of the component. */
|
|
2008
3075
|
children?: React_2.ReactNode;
|
|
3076
|
+
/** Appended to internal classes on the `th` element. */
|
|
2009
3077
|
className?: string;
|
|
2010
3078
|
[prop: string]: any;
|
|
2011
3079
|
}
|
|
2012
3080
|
|
|
2013
3081
|
export declare interface TableHeadProps extends React_2.AllHTMLAttributes<HTMLTableSectionElement> {
|
|
3082
|
+
/** Contents of the component. */
|
|
2014
3083
|
children?: React_2.ReactNode;
|
|
3084
|
+
/** Appended to internal classes on the `thead` element. */
|
|
2015
3085
|
className?: string;
|
|
2016
3086
|
[prop: string]: any;
|
|
2017
3087
|
}
|
|
2018
3088
|
|
|
2019
3089
|
export declare interface TableProps extends React_2.AllHTMLAttributes<HTMLTableElement> {
|
|
3090
|
+
/** Contents of the component. */
|
|
2020
3091
|
children?: React_2.ReactNode;
|
|
3092
|
+
/** Appended to internal classes on the `table` element. */
|
|
2021
3093
|
className?: string;
|
|
2022
3094
|
[prop: string]: any;
|
|
2023
3095
|
}
|
|
@@ -2025,7 +3097,9 @@ export declare interface TableProps extends React_2.AllHTMLAttributes<HTMLTableE
|
|
|
2025
3097
|
export declare const TableRow: React_2.ForwardRefExoticComponent<TableRowProps & React_2.RefAttributes<HTMLTableRowElement>>;
|
|
2026
3098
|
|
|
2027
3099
|
export declare interface TableRowProps extends React_2.AllHTMLAttributes<HTMLTableRowElement> {
|
|
3100
|
+
/** Contents of the component. */
|
|
2028
3101
|
children?: React_2.ReactNode;
|
|
3102
|
+
/** Appended to internal classes on the `tr` element. */
|
|
2029
3103
|
className?: string;
|
|
2030
3104
|
[prop: string]: any;
|
|
2031
3105
|
}
|
|
@@ -2033,76 +3107,156 @@ export declare interface TableRowProps extends React_2.AllHTMLAttributes<HTMLTab
|
|
|
2033
3107
|
export declare const TabList: React_2.ForwardRefExoticComponent<TabListProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
2034
3108
|
|
|
2035
3109
|
export declare interface TabListProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
2036
|
-
|
|
2037
|
-
|
|
3110
|
+
/** `Tab` components. The order of the `Tab` components controls the order they
|
|
3111
|
+
* appear and will display the corresponding `TabPanel` in the same child position
|
|
3112
|
+
* in a `TabPanels` component when clicked. Any other type of children besides `Tab`
|
|
3113
|
+
* will have undefined behavior.
|
|
3114
|
+
*/
|
|
2038
3115
|
children: React_2.ReactNode;
|
|
2039
|
-
|
|
3116
|
+
/** Class to add to the containing `div` */
|
|
2040
3117
|
className?: string;
|
|
3118
|
+
/** Causes the tab list to stretch to fill all of the horizontal space of its container. */
|
|
3119
|
+
isFullWidth?: boolean;
|
|
2041
3120
|
}
|
|
2042
3121
|
|
|
2043
3122
|
export declare const TabPanel: React_2.ForwardRefExoticComponent<TabPanelProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
2044
3123
|
|
|
2045
3124
|
export declare interface TabPanelProps extends React_2.AllHTMLAttributes<HTMLDivElement> {
|
|
3125
|
+
/** Optional value, normally set by the containing context.
|
|
3126
|
+
* @internal
|
|
3127
|
+
*/
|
|
2046
3128
|
value?: number;
|
|
3129
|
+
/** The contents of the tab panel. */
|
|
2047
3130
|
children: React_2.ReactNode;
|
|
3131
|
+
/** Class to add to the containing `div` */
|
|
2048
3132
|
className?: string;
|
|
2049
3133
|
}
|
|
2050
3134
|
|
|
2051
3135
|
export declare const TabPanels: React_3.FunctionComponent<TabPanelsProps>;
|
|
2052
3136
|
|
|
2053
3137
|
export declare interface TabPanelsProps {
|
|
3138
|
+
/**
|
|
3139
|
+
* `TabPanel` components. The order of the `TabPanel` components
|
|
3140
|
+
* controls the order they appear and will be displayed by the
|
|
3141
|
+
* corresponding `Tab` in the same child position in a `TabList`
|
|
3142
|
+
* component when clicked. Any other type of children besides
|
|
3143
|
+
* `TabPanel` will have undefined behavior.
|
|
3144
|
+
*/
|
|
2054
3145
|
children: React_3.ReactNode;
|
|
2055
3146
|
}
|
|
2056
3147
|
|
|
2057
3148
|
export declare interface TabProps extends Omit<ButtonHTMLAttributes<HTMLButtonElement>, 'value'> {
|
|
2058
|
-
|
|
3149
|
+
/** The label node for a `Tab`. It's possible to pass arbitrary children to a `Tab`,
|
|
3150
|
+
* but if no text content is supplied, an `aria-label` attribute should be passed to the
|
|
3151
|
+
* Tab component for screen reader accessibility.
|
|
3152
|
+
*/
|
|
3153
|
+
children?: ReactNode;
|
|
3154
|
+
/** Class to add to the containing `div` */
|
|
2059
3155
|
className?: string;
|
|
3156
|
+
/** Value is optional, but it will always be passed in by the TabList component when the tabs are cloned
|
|
3157
|
+
* @internal
|
|
3158
|
+
*/
|
|
2060
3159
|
value?: number;
|
|
2061
|
-
children?: ReactNode;
|
|
2062
3160
|
}
|
|
2063
3161
|
|
|
2064
3162
|
export declare const Tabs: React_2.ForwardRefExoticComponent<TabsProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
2065
3163
|
|
|
2066
3164
|
export declare interface TabsProps extends Omit<React_2.AllHTMLAttributes<HTMLDivElement>, 'onChange'> {
|
|
3165
|
+
/** The 0-indexed tab and associated tab panel that is currently selected. Only use this prop if controlling the component directly. */
|
|
2067
3166
|
activeTab?: number;
|
|
3167
|
+
/** The 0-indexed tab and associated tab panel that will be selected whent the component first renders.
|
|
3168
|
+
* @defaultValue 0
|
|
3169
|
+
*/
|
|
2068
3170
|
initialActiveTab?: number;
|
|
2069
|
-
|
|
2070
|
-
|
|
3171
|
+
/** TabList and TabPanel Components. Any other type of children besides TabList and TabPanel passed to the tabs component will have undefined behavior. */
|
|
3172
|
+
children?: ReactNode;
|
|
3173
|
+
/**
|
|
3174
|
+
* Added to the containing `div` element and to each `TabList`, `Tab`, and `TabPanel` component with a suffix:
|
|
3175
|
+
* - `TabList`: `-tablist`
|
|
3176
|
+
* - `Tab`: `-tab-0`
|
|
3177
|
+
* - `TabPanel`: `-tabpanel-0`
|
|
3178
|
+
*
|
|
3179
|
+
* Note: the number in each `id` will correspond with that section's position in the `TabList` or `TabPanels` components.
|
|
3180
|
+
*/
|
|
2071
3181
|
id?: string;
|
|
3182
|
+
/**
|
|
3183
|
+
* Added to the containing `div` element and to each `TabList`, `Tab`, and `TabPanel` component with a suffix:
|
|
3184
|
+
* - `TabList`: `-tablist`
|
|
3185
|
+
* - `Tab`: `-tab-0`
|
|
3186
|
+
* - `TabPanel`: `-tabpanel-0`
|
|
3187
|
+
*
|
|
3188
|
+
* Note: the number in each `data-testid` will correspond with that section's position in the `TabList` or `TabPanels` components.
|
|
3189
|
+
*/
|
|
3190
|
+
'data-testid'?: string;
|
|
3191
|
+
/** Class to add to the containing `div` */
|
|
3192
|
+
className?: string;
|
|
3193
|
+
/** Handler to be called whenever the selected `Tab` changes
|
|
3194
|
+
* @param tab - The updated `activeTab` value
|
|
3195
|
+
* @returns
|
|
3196
|
+
*/
|
|
2072
3197
|
onChange?: (tab: number) => void;
|
|
2073
|
-
children?: ReactNode;
|
|
2074
3198
|
}
|
|
2075
3199
|
|
|
2076
3200
|
export declare const Tooltip: React_2.ForwardRefExoticComponent<TooltipProps & React_2.RefAttributes<HTMLDivElement>>;
|
|
2077
3201
|
|
|
2078
3202
|
export declare interface TooltipProps extends Omit<React_2.AllHTMLAttributes<HTMLDivElement>, 'content'> {
|
|
2079
|
-
|
|
2080
|
-
unstable_contentKey?: string;
|
|
2081
|
-
placement?: ComputedPlacement;
|
|
3203
|
+
/** Element or component to which the tooltip should be anchored, which must accept a ref. */
|
|
2082
3204
|
children: React_2.ReactElement & React_2.RefAttributes<HTMLElement>;
|
|
2083
|
-
|
|
3205
|
+
/** Element(s) or component(s) to be displayed in the tooltip. */
|
|
3206
|
+
content?: React_2.ReactNode;
|
|
3207
|
+
/** Number of milliseconds to wait before displaying the tooltip.
|
|
3208
|
+
* @defaultValue 0
|
|
3209
|
+
*/
|
|
2084
3210
|
delayMs?: number;
|
|
2085
|
-
|
|
2086
|
-
|
|
2087
|
-
|
|
3211
|
+
/** Disables the tooltip from displaying.
|
|
3212
|
+
* @defaultValue false
|
|
3213
|
+
*/
|
|
3214
|
+
disabled?: boolean;
|
|
3215
|
+
/** Dictates the position of the tooltip relative to its anchor.
|
|
3216
|
+
* @defaultValue 'top'
|
|
3217
|
+
*/
|
|
3218
|
+
placement?: ComputedPlacement;
|
|
3219
|
+
/** If true, removes the arrow from the tooltip.
|
|
3220
|
+
* @defaultValue false
|
|
3221
|
+
*/
|
|
2088
3222
|
isArrowRemoved?: boolean;
|
|
2089
|
-
|
|
2090
|
-
|
|
3223
|
+
/** Themes the tooltip to a light color.
|
|
3224
|
+
* @defaultValue false
|
|
3225
|
+
*/
|
|
2091
3226
|
lightTheme?: boolean;
|
|
3227
|
+
/** The z-index of the tooltip content.
|
|
3228
|
+
* @defaultValue 1000
|
|
3229
|
+
*/
|
|
3230
|
+
zIndex?: number;
|
|
3231
|
+
/** Show the tooltip when a focusable descendant of the anchor element is focused via keyboard control
|
|
3232
|
+
* @defaultValue false
|
|
3233
|
+
*/
|
|
3234
|
+
showOnDescendantFocus?: boolean;
|
|
3235
|
+
/** The container element where the Tooltip should be rendered. Overrides the default set by UIProvider */
|
|
3236
|
+
portalTarget?: HTMLElement;
|
|
3237
|
+
/** Appended to internal classes on the containing `div` element. */
|
|
3238
|
+
className?: string;
|
|
3239
|
+
/** Controls visibility of tooltip, overrides default behavior. If you intend to use this prop, see the accessibility section for further instruction. */
|
|
2092
3240
|
show?: boolean;
|
|
3241
|
+
/** Handler to be called when the user's interaction triggers a change in visibility. */
|
|
2093
3242
|
onShowChange?: (show: boolean) => void;
|
|
2094
|
-
|
|
2095
|
-
|
|
3243
|
+
/**
|
|
3244
|
+
* @internal
|
|
3245
|
+
*/
|
|
3246
|
+
unstable_contentKey?: string;
|
|
2096
3247
|
[prop: string]: any;
|
|
2097
3248
|
}
|
|
2098
3249
|
|
|
2099
3250
|
export declare const UIProvider: React_2.FunctionComponent<UIProviderProps>;
|
|
2100
3251
|
|
|
2101
3252
|
export declare interface UIProviderProps {
|
|
3253
|
+
/** Container element into which Portal content from Dropdown, Menu, Combobox, etc should be rendered */
|
|
2102
3254
|
portalTarget?: HTMLElement;
|
|
3255
|
+
/** Config with translated messages to be used for components that require them. See the [Localization Guide](/guides/localization) for more info on configuration. */
|
|
2103
3256
|
config?: {
|
|
2104
3257
|
localizedText?: LocalizedText;
|
|
2105
3258
|
};
|
|
3259
|
+
/** Your app */
|
|
2106
3260
|
children?: ReactNode;
|
|
2107
3261
|
}
|
|
2108
3262
|
|