@carbon/react 1.85.0 → 1.86.0-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.playwright/INTERNAL_AVT_REPORT_DO_NOT_USE.json +797 -797
- package/es/components/AILabel/index.js +1 -1
- package/es/components/Accordion/AccordionItem.d.ts +1 -1
- package/es/components/Accordion/AccordionItem.js +1 -1
- package/es/components/Checkbox/Checkbox.js +1 -1
- package/es/components/CheckboxGroup/CheckboxGroup.js +1 -1
- package/es/components/CodeSnippet/CodeSnippet.d.ts +2 -2
- package/es/components/CodeSnippet/CodeSnippet.js +1 -1
- package/es/components/ComboBox/ComboBox.js +1 -1
- package/es/components/ComposedModal/ComposedModal.js +1 -1
- package/es/components/ContentSwitcher/ContentSwitcher.d.ts +1 -1
- package/es/components/ContentSwitcher/ContentSwitcher.js +1 -1
- package/es/components/DataTable/DataTable.d.ts +230 -170
- package/es/components/DataTable/DataTable.js +508 -519
- package/es/components/DataTable/TableContainer.d.ts +9 -1
- package/es/components/DataTable/TableContainer.js +7 -1
- package/es/components/DataTable/TableExpandHeader.d.ts +1 -1
- package/es/components/DataTable/TableExpandHeader.js +1 -1
- package/es/components/DataTable/TableSelectAll.d.ts +2 -2
- package/es/components/DataTable/TableSelectAll.js +1 -1
- package/es/components/DataTable/TableSelectRow.d.ts +2 -2
- package/es/components/DataTable/TableSelectRow.js +1 -1
- package/es/components/DataTable/TableToolbar.d.ts +1 -1
- package/es/components/DataTable/TableToolbar.js +1 -1
- package/es/components/DataTable/TableToolbarMenu.d.ts +2 -18
- package/es/components/DataTable/TableToolbarMenu.js +0 -1
- package/es/components/DataTable/index.d.ts +1 -1
- package/es/components/DataTable/state/getDerivedStateFromProps.js +5 -1
- package/es/components/DatePicker/DatePicker.js +1 -1
- package/es/components/DatePickerInput/DatePickerInput.js +1 -1
- package/es/components/Dropdown/Dropdown.js +1 -1
- package/es/components/FeatureFlags/index.d.ts +2 -2
- package/es/components/FeatureFlags/index.js +1 -1
- package/es/components/FileUploader/FileUploaderButton.d.ts +1 -1
- package/es/components/FileUploader/FileUploaderButton.js +1 -1
- package/es/components/FileUploader/FileUploaderDropContainer.d.ts +2 -2
- package/es/components/FileUploader/FileUploaderDropContainer.js +1 -1
- package/es/components/FluidTextArea/FluidTextArea.d.ts +1 -1
- package/es/components/FluidTextArea/FluidTextArea.js +1 -1
- package/es/components/InlineCheckbox/InlineCheckbox.js +1 -1
- package/es/components/ListBox/ListBox.js +1 -1
- package/es/components/Loading/Loading.d.ts +1 -1
- package/es/components/Loading/Loading.js +1 -1
- package/es/components/Menu/Menu.js +1 -1
- package/es/components/Modal/Modal.js +1 -1
- package/es/components/MultiSelect/FilterableMultiSelect.js +1 -1
- package/es/components/MultiSelect/MultiSelect.js +1 -1
- package/es/components/Notification/Notification.d.ts +4 -4
- package/es/components/Notification/Notification.js +1 -1
- package/es/components/NumberInput/NumberInput.d.ts +7 -0
- package/es/components/NumberInput/NumberInput.js +80 -25
- package/es/components/OverflowMenu/OverflowMenu.d.ts +2 -6
- package/es/components/OverflowMenu/OverflowMenu.js +1 -1
- package/es/components/Pagination/Pagination.js +22 -5
- package/es/components/RadioButton/RadioButton.js +1 -1
- package/es/components/RadioButtonGroup/RadioButtonGroup.js +1 -1
- package/es/components/RadioTile/RadioTile.js +1 -1
- package/es/components/Search/Search.js +1 -1
- package/es/components/Select/Select.js +1 -1
- package/es/components/Slider/Slider.js +1 -1
- package/es/components/StructuredList/StructuredList.d.ts +5 -5
- package/es/components/StructuredList/StructuredList.js +1 -1
- package/es/components/Tabs/Tabs.d.ts +1 -1
- package/es/components/Tabs/Tabs.js +1 -1
- package/es/components/Tag/DismissibleTag.js +1 -1
- package/es/components/Tag/Tag.js +1 -1
- package/es/components/TextArea/TextArea.js +1 -1
- package/es/components/TextInput/ControlledPasswordInput.js +1 -1
- package/es/components/TextInput/PasswordInput.js +1 -1
- package/es/components/TextInput/TextInput.js +1 -1
- package/es/components/Tile/Tile.js +1 -1
- package/es/components/TileGroup/TileGroup.d.ts +5 -5
- package/es/components/TimePicker/TimePicker.d.ts +8 -0
- package/es/components/TimePicker/TimePicker.js +6 -4
- package/es/components/Tooltip/DefinitionTooltip.d.ts +1 -1
- package/es/components/Tooltip/DefinitionTooltip.js +1 -1
- package/es/components/TreeView/TreeContext.d.ts +19 -0
- package/es/components/TreeView/TreeContext.js +13 -0
- package/es/components/TreeView/TreeNode.d.ts +4 -4
- package/es/components/TreeView/TreeNode.js +56 -108
- package/es/components/TreeView/TreeView.js +42 -79
- package/es/components/UIShell/HeaderMenu.js +1 -1
- package/es/components/UIShell/HeaderMenuItem.d.ts +1 -1
- package/es/components/UIShell/HeaderMenuItem.js +1 -1
- package/es/components/UIShell/HeaderName.d.ts +1 -1
- package/es/components/UIShell/HeaderPanel.js +5 -7
- package/es/components/UIShell/Link.d.ts +2 -2
- package/es/components/UIShell/Link.js +1 -1
- package/es/components/UIShell/Switcher.d.ts +1 -1
- package/es/components/UIShell/Switcher.js +39 -12
- package/es/index.js +1 -1
- package/es/internal/useNoInteractiveChildren.d.ts +25 -0
- package/es/internal/useNoInteractiveChildren.js +39 -32
- package/es/prop-types/deprecate.d.ts +17 -0
- package/es/prop-types/deprecate.js +22 -12
- package/lib/components/AILabel/index.js +2 -2
- package/lib/components/Accordion/AccordionItem.d.ts +1 -1
- package/lib/components/Accordion/AccordionItem.js +1 -1
- package/lib/components/Checkbox/Checkbox.js +1 -1
- package/lib/components/CheckboxGroup/CheckboxGroup.js +1 -1
- package/lib/components/CodeSnippet/CodeSnippet.d.ts +2 -2
- package/lib/components/CodeSnippet/CodeSnippet.js +2 -2
- package/lib/components/ComboBox/ComboBox.js +3 -3
- package/lib/components/ComposedModal/ComposedModal.js +1 -1
- package/lib/components/ContentSwitcher/ContentSwitcher.d.ts +1 -1
- package/lib/components/ContentSwitcher/ContentSwitcher.js +1 -1
- package/lib/components/DataTable/DataTable.d.ts +230 -170
- package/lib/components/DataTable/DataTable.js +507 -518
- package/lib/components/DataTable/TableContainer.d.ts +9 -1
- package/lib/components/DataTable/TableContainer.js +7 -1
- package/lib/components/DataTable/TableExpandHeader.d.ts +1 -1
- package/lib/components/DataTable/TableExpandHeader.js +1 -1
- package/lib/components/DataTable/TableSelectAll.d.ts +2 -2
- package/lib/components/DataTable/TableSelectAll.js +1 -1
- package/lib/components/DataTable/TableSelectRow.d.ts +2 -2
- package/lib/components/DataTable/TableSelectRow.js +1 -1
- package/lib/components/DataTable/TableToolbar.d.ts +1 -1
- package/lib/components/DataTable/TableToolbar.js +1 -1
- package/lib/components/DataTable/TableToolbarMenu.d.ts +2 -18
- package/lib/components/DataTable/TableToolbarMenu.js +0 -1
- package/lib/components/DataTable/index.d.ts +1 -1
- package/lib/components/DataTable/state/getDerivedStateFromProps.js +5 -1
- package/lib/components/DatePicker/DatePicker.js +1 -1
- package/lib/components/DatePickerInput/DatePickerInput.js +1 -1
- package/lib/components/Dropdown/Dropdown.js +3 -3
- package/lib/components/FeatureFlags/index.d.ts +2 -2
- package/lib/components/FeatureFlags/index.js +1 -1
- package/lib/components/FileUploader/FileUploaderButton.d.ts +1 -1
- package/lib/components/FileUploader/FileUploaderButton.js +1 -1
- package/lib/components/FileUploader/FileUploaderDropContainer.d.ts +2 -2
- package/lib/components/FileUploader/FileUploaderDropContainer.js +2 -2
- package/lib/components/FluidTextArea/FluidTextArea.d.ts +1 -1
- package/lib/components/FluidTextArea/FluidTextArea.js +1 -1
- package/lib/components/InlineCheckbox/InlineCheckbox.js +1 -1
- package/lib/components/ListBox/ListBox.js +1 -1
- package/lib/components/Loading/Loading.d.ts +1 -1
- package/lib/components/Loading/Loading.js +1 -1
- package/lib/components/Menu/Menu.js +1 -1
- package/lib/components/Modal/Modal.js +1 -1
- package/lib/components/MultiSelect/FilterableMultiSelect.js +4 -4
- package/lib/components/MultiSelect/MultiSelect.js +2 -2
- package/lib/components/Notification/Notification.d.ts +4 -4
- package/lib/components/Notification/Notification.js +4 -4
- package/lib/components/NumberInput/NumberInput.d.ts +7 -0
- package/lib/components/NumberInput/NumberInput.js +81 -26
- package/lib/components/OverflowMenu/OverflowMenu.d.ts +2 -6
- package/lib/components/OverflowMenu/OverflowMenu.js +2 -2
- package/lib/components/Pagination/Pagination.js +21 -4
- package/lib/components/RadioButton/RadioButton.js +1 -1
- package/lib/components/RadioButtonGroup/RadioButtonGroup.js +1 -1
- package/lib/components/RadioTile/RadioTile.js +2 -2
- package/lib/components/Search/Search.js +1 -1
- package/lib/components/Select/Select.js +2 -2
- package/lib/components/Slider/Slider.js +1 -1
- package/lib/components/StructuredList/StructuredList.d.ts +5 -5
- package/lib/components/StructuredList/StructuredList.js +4 -4
- package/lib/components/Tabs/Tabs.d.ts +1 -1
- package/lib/components/Tabs/Tabs.js +1 -1
- package/lib/components/Tag/DismissibleTag.js +1 -1
- package/lib/components/Tag/Tag.js +4 -4
- package/lib/components/TextArea/TextArea.js +2 -2
- package/lib/components/TextInput/ControlledPasswordInput.js +1 -1
- package/lib/components/TextInput/PasswordInput.js +1 -1
- package/lib/components/TextInput/TextInput.js +2 -2
- package/lib/components/Tile/Tile.js +9 -9
- package/lib/components/TileGroup/TileGroup.d.ts +5 -5
- package/lib/components/TimePicker/TimePicker.d.ts +8 -0
- package/lib/components/TimePicker/TimePicker.js +6 -4
- package/lib/components/Tooltip/DefinitionTooltip.d.ts +1 -1
- package/lib/components/Tooltip/DefinitionTooltip.js +1 -1
- package/lib/components/TreeView/TreeContext.d.ts +19 -0
- package/lib/components/TreeView/TreeContext.js +18 -0
- package/lib/components/TreeView/TreeNode.d.ts +4 -4
- package/lib/components/TreeView/TreeNode.js +55 -107
- package/lib/components/TreeView/TreeView.js +41 -78
- package/lib/components/UIShell/HeaderMenu.js +1 -1
- package/lib/components/UIShell/HeaderMenuItem.d.ts +1 -1
- package/lib/components/UIShell/HeaderMenuItem.js +1 -1
- package/lib/components/UIShell/HeaderName.d.ts +1 -1
- package/lib/components/UIShell/HeaderPanel.js +5 -7
- package/lib/components/UIShell/Link.d.ts +2 -2
- package/lib/components/UIShell/Link.js +1 -1
- package/lib/components/UIShell/Switcher.d.ts +1 -1
- package/lib/components/UIShell/Switcher.js +38 -11
- package/lib/index.js +1 -1
- package/lib/internal/useNoInteractiveChildren.d.ts +25 -0
- package/lib/internal/useNoInteractiveChildren.js +39 -32
- package/lib/prop-types/deprecate.d.ts +17 -0
- package/lib/prop-types/deprecate.js +22 -12
- package/package.json +3 -3
- package/telemetry.yml +15 -14
|
@@ -16,7 +16,7 @@ import { IconButton } from '../IconButton/index.js';
|
|
|
16
16
|
import { mapPopoverAlign } from '../../tools/mapPopoverAlign.js';
|
|
17
17
|
import { Undo } from '@carbon/icons-react';
|
|
18
18
|
import { useId } from '../../internal/useId.js';
|
|
19
|
-
import deprecate from '../../prop-types/deprecate.js';
|
|
19
|
+
import { deprecate } from '../../prop-types/deprecate.js';
|
|
20
20
|
|
|
21
21
|
var _Undo;
|
|
22
22
|
const AILabelContent = /*#__PURE__*/React.forwardRef(function AILabelContent({
|
|
@@ -90,7 +90,7 @@ declare namespace AccordionItem {
|
|
|
90
90
|
* The callback function to render the expand button.
|
|
91
91
|
* Can be a React component class.
|
|
92
92
|
*/
|
|
93
|
-
renderExpando: (props:
|
|
93
|
+
renderExpando: (props: Record<string, any>, propName: string, componentName: string, ...rest: any[]) => any;
|
|
94
94
|
/**
|
|
95
95
|
* The callback function to render the expand button.
|
|
96
96
|
* Can be a React component class.
|
|
@@ -14,7 +14,7 @@ import '../Text/index.js';
|
|
|
14
14
|
import { Escape } from '../../internal/keyboard/keys.js';
|
|
15
15
|
import { match } from '../../internal/keyboard/match.js';
|
|
16
16
|
import { useId } from '../../internal/useId.js';
|
|
17
|
-
import deprecate from '../../prop-types/deprecate.js';
|
|
17
|
+
import { deprecate } from '../../prop-types/deprecate.js';
|
|
18
18
|
import { usePrefix } from '../../internal/usePrefix.js';
|
|
19
19
|
import { AccordionContext } from './AccordionProvider.js';
|
|
20
20
|
import { Text } from '../Text/Text.js';
|
|
@@ -10,7 +10,7 @@ import PropTypes from 'prop-types';
|
|
|
10
10
|
import React, { cloneElement } from 'react';
|
|
11
11
|
import cx from 'classnames';
|
|
12
12
|
import '../Text/index.js';
|
|
13
|
-
import deprecate from '../../prop-types/deprecate.js';
|
|
13
|
+
import { deprecate } from '../../prop-types/deprecate.js';
|
|
14
14
|
import { usePrefix } from '../../internal/usePrefix.js';
|
|
15
15
|
import { WarningFilled, WarningAltFilled } from '@carbon/icons-react';
|
|
16
16
|
import { useId } from '../../internal/useId.js';
|
|
@@ -9,7 +9,7 @@ import { extends as _extends } from '../../_virtual/_rollupPluginBabelHelpers.js
|
|
|
9
9
|
import PropTypes from 'prop-types';
|
|
10
10
|
import React, { cloneElement } from 'react';
|
|
11
11
|
import cx from 'classnames';
|
|
12
|
-
import deprecate from '../../prop-types/deprecate.js';
|
|
12
|
+
import { deprecate } from '../../prop-types/deprecate.js';
|
|
13
13
|
import { usePrefix } from '../../internal/usePrefix.js';
|
|
14
14
|
import { WarningFilled, WarningAltFilled } from '@carbon/icons-react';
|
|
15
15
|
import { useId } from '../../internal/useId.js';
|
|
@@ -120,7 +120,7 @@ declare namespace CodeSnippet {
|
|
|
120
120
|
* Specify a label to be read by screen readers on the containing textbox
|
|
121
121
|
* node
|
|
122
122
|
*/
|
|
123
|
-
ariaLabel: (props:
|
|
123
|
+
ariaLabel: (props: Record<string, any>, propName: string, componentName: string, ...rest: any[]) => any;
|
|
124
124
|
/**
|
|
125
125
|
* **Experimental**: Will attempt to automatically align the tooltip
|
|
126
126
|
*/
|
|
@@ -162,7 +162,7 @@ declare namespace CodeSnippet {
|
|
|
162
162
|
* Specify whether you are using the light variant of the Code Snippet,
|
|
163
163
|
* typically used for inline snippet to display an alternate color
|
|
164
164
|
*/
|
|
165
|
-
light: (props:
|
|
165
|
+
light: (props: Record<string, any>, propName: string, componentName: string, ...rest: any[]) => any;
|
|
166
166
|
/**
|
|
167
167
|
* Specify the maximum number of rows to be shown when in collapsed view
|
|
168
168
|
*/
|
|
@@ -17,7 +17,7 @@ import '../Button/Button.Skeleton.js';
|
|
|
17
17
|
import CopyButton from '../CopyButton/CopyButton.js';
|
|
18
18
|
import { useId } from '../../internal/useId.js';
|
|
19
19
|
import copy from 'copy-to-clipboard';
|
|
20
|
-
import deprecate from '../../prop-types/deprecate.js';
|
|
20
|
+
import { deprecate } from '../../prop-types/deprecate.js';
|
|
21
21
|
import { usePrefix } from '../../internal/usePrefix.js';
|
|
22
22
|
import deprecateValuesWithin from '../../prop-types/deprecateValuesWithin.js';
|
|
23
23
|
import { mapPopoverAlign } from '../../tools/mapPopoverAlign.js';
|
|
@@ -20,7 +20,7 @@ import { Space, Enter, Escape, Home, End } from '../../internal/keyboard/keys.js
|
|
|
20
20
|
import { match } from '../../internal/keyboard/match.js';
|
|
21
21
|
import { useId } from '../../internal/useId.js';
|
|
22
22
|
import mergeRefs from '../../tools/mergeRefs.js';
|
|
23
|
-
import deprecate from '../../prop-types/deprecate.js';
|
|
23
|
+
import { deprecate } from '../../prop-types/deprecate.js';
|
|
24
24
|
import { usePrefix } from '../../internal/usePrefix.js';
|
|
25
25
|
import '../FluidForm/FluidForm.js';
|
|
26
26
|
import { FormContext } from '../FluidForm/FormContext.js';
|
|
@@ -23,7 +23,7 @@ import { Escape, Tab } from '../../internal/keyboard/keys.js';
|
|
|
23
23
|
import { match } from '../../internal/keyboard/match.js';
|
|
24
24
|
import { useFeatureFlag } from '../FeatureFlags/index.js';
|
|
25
25
|
import { composeEventHandlers } from '../../tools/events.js';
|
|
26
|
-
import deprecate from '../../prop-types/deprecate.js';
|
|
26
|
+
import { deprecate } from '../../prop-types/deprecate.js';
|
|
27
27
|
import { unstable__Dialog } from '../Dialog/index.js';
|
|
28
28
|
import { warning } from '../../internal/warning.js';
|
|
29
29
|
import { AILabel } from '../AILabel/index.js';
|
|
@@ -65,7 +65,7 @@ export declare const ContentSwitcher: {
|
|
|
65
65
|
/**
|
|
66
66
|
* `true` to use the light variant.
|
|
67
67
|
*/
|
|
68
|
-
light: (props:
|
|
68
|
+
light: (props: Record<string, any>, propName: string, componentName: string, ...rest: any[]) => any;
|
|
69
69
|
/**
|
|
70
70
|
* `true` to use the low contrast version.
|
|
71
71
|
*/
|
|
@@ -9,7 +9,7 @@ import { extends as _extends } from '../../_virtual/_rollupPluginBabelHelpers.js
|
|
|
9
9
|
import PropTypes from 'prop-types';
|
|
10
10
|
import React, { useContext, useState, useRef, Children, useEffect, isValidElement, cloneElement } from 'react';
|
|
11
11
|
import cx from 'classnames';
|
|
12
|
-
import deprecate from '../../prop-types/deprecate.js';
|
|
12
|
+
import { deprecate } from '../../prop-types/deprecate.js';
|
|
13
13
|
import { LayoutConstraint } from '../Layout/index.js';
|
|
14
14
|
import { composeEventHandlers } from '../../tools/events.js';
|
|
15
15
|
import { ArrowRight, ArrowLeft } from '../../internal/keyboard/keys.js';
|
|
@@ -4,30 +4,9 @@
|
|
|
4
4
|
* This source code is licensed under the Apache-2.0 license found in the
|
|
5
5
|
* LICENSE file in the root directory of this source tree.
|
|
6
6
|
*/
|
|
7
|
-
import
|
|
7
|
+
import PropTypes from 'prop-types';
|
|
8
|
+
import React, { type ChangeEvent, type MouseEvent, type ReactElement, type ReactNode } from 'react';
|
|
8
9
|
import type { DataTableSortState } from './state/sortStates';
|
|
9
|
-
import Table from './Table';
|
|
10
|
-
import TableActionList from './TableActionList';
|
|
11
|
-
import TableBatchAction from './TableBatchAction';
|
|
12
|
-
import TableBatchActions from './TableBatchActions';
|
|
13
|
-
import TableBody from './TableBody';
|
|
14
|
-
import TableCell from './TableCell';
|
|
15
|
-
import TableContainer from './TableContainer';
|
|
16
|
-
import TableDecoratorRow from './TableDecoratorRow';
|
|
17
|
-
import TableExpandHeader from './TableExpandHeader';
|
|
18
|
-
import TableExpandRow from './TableExpandRow';
|
|
19
|
-
import TableExpandedRow from './TableExpandedRow';
|
|
20
|
-
import TableHead from './TableHead';
|
|
21
|
-
import TableHeader from './TableHeader';
|
|
22
|
-
import TableRow from './TableRow';
|
|
23
|
-
import TableSelectAll from './TableSelectAll';
|
|
24
|
-
import TableSelectRow from './TableSelectRow';
|
|
25
|
-
import TableSlugRow from './TableSlugRow';
|
|
26
|
-
import TableToolbar from './TableToolbar';
|
|
27
|
-
import TableToolbarAction from './TableToolbarAction';
|
|
28
|
-
import TableToolbarContent from './TableToolbarContent';
|
|
29
|
-
import TableToolbarSearch from './TableToolbarSearch';
|
|
30
|
-
import TableToolbarMenu from './TableToolbarMenu';
|
|
31
10
|
import { TranslateWithId } from '../../types/common';
|
|
32
11
|
declare const translationKeys: {
|
|
33
12
|
readonly expandRow: "carbon.table.row.expand";
|
|
@@ -213,17 +192,6 @@ export interface DataTableProps<RowType, ColTypes extends any[]> extends Transla
|
|
|
213
192
|
useStaticWidth?: boolean;
|
|
214
193
|
useZebraStyles?: boolean;
|
|
215
194
|
}
|
|
216
|
-
interface DataTableState<ColTypes extends any[]> {
|
|
217
|
-
cellsById: Record<string, DataTableCell<ColTypes>>;
|
|
218
|
-
filterInputValue: string | null;
|
|
219
|
-
initialRowOrder: string[];
|
|
220
|
-
isExpandedAll: boolean;
|
|
221
|
-
rowIds: string[];
|
|
222
|
-
rowsById: Record<string, DataTableRow<ColTypes>>;
|
|
223
|
-
shouldShowBatchActions: boolean;
|
|
224
|
-
sortDirection: DataTableSortState;
|
|
225
|
-
sortHeaderKey: string | null;
|
|
226
|
-
}
|
|
227
195
|
/**
|
|
228
196
|
* Data Tables are used to represent a collection of resources, displaying a
|
|
229
197
|
* subset of their fields in columns, or headers. We prioritize direct updates
|
|
@@ -234,139 +202,231 @@ interface DataTableState<ColTypes extends any[]> {
|
|
|
234
202
|
* and updating the state of the single entity will cascade updates to the
|
|
235
203
|
* consumer.
|
|
236
204
|
*/
|
|
237
|
-
declare
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
205
|
+
export declare const DataTable: {
|
|
206
|
+
<RowType, ColTypes extends any[]>(props: DataTableProps<RowType, ColTypes>): React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | null;
|
|
207
|
+
translationKeys: ("carbon.table.row.expand" | "carbon.table.row.collapse" | "carbon.table.all.expand" | "carbon.table.all.collapse" | "carbon.table.all.select" | "carbon.table.all.unselect" | "carbon.table.row.select" | "carbon.table.row.unselect")[];
|
|
208
|
+
Table: {
|
|
209
|
+
({ className, children, useZebraStyles, size, isSortable, useStaticWidth, stickyHeader, overflowMenuOnHover, experimentalAutoAlign, tabIndex, ...other }: React.PropsWithChildren<import("./Table").TableProps>): import("react/jsx-runtime").JSX.Element;
|
|
210
|
+
propTypes: {
|
|
211
|
+
children: PropTypes.Requireable<PropTypes.ReactNodeLike>;
|
|
212
|
+
className: PropTypes.Requireable<string>;
|
|
213
|
+
experimentalAutoAlign: PropTypes.Requireable<boolean>;
|
|
214
|
+
isSortable: PropTypes.Requireable<boolean>;
|
|
215
|
+
overflowMenuOnHover: PropTypes.Requireable<boolean>;
|
|
216
|
+
size: PropTypes.Requireable<string>;
|
|
217
|
+
stickyHeader: PropTypes.Requireable<boolean>;
|
|
218
|
+
useStaticWidth: PropTypes.Requireable<boolean>;
|
|
219
|
+
useZebraStyles: PropTypes.Requireable<boolean>;
|
|
220
|
+
tabIndex: PropTypes.Requireable<number>;
|
|
221
|
+
};
|
|
222
|
+
};
|
|
223
|
+
TableActionList: (props: React.HTMLAttributes<"div">) => React.ReactElement<any>;
|
|
224
|
+
TableBatchAction: {
|
|
225
|
+
({ renderIcon, iconDescription, ...props }: import("./TableBatchAction").TableBatchActionProps): import("react/jsx-runtime").JSX.Element;
|
|
226
|
+
propTypes: {
|
|
227
|
+
hasIconOnly: PropTypes.Requireable<boolean>;
|
|
228
|
+
iconDescription: (props: any) => Error | undefined;
|
|
229
|
+
renderIcon: PropTypes.Requireable<object>;
|
|
230
|
+
};
|
|
231
|
+
};
|
|
232
|
+
TableBatchActions: import("./TableBatchActions").TableBatchActionsComponent;
|
|
233
|
+
TableBody: {
|
|
234
|
+
({ children, className, ...rest }: import("./TableBody").TableBodyProps): import("react/jsx-runtime").JSX.Element;
|
|
235
|
+
propTypes: {
|
|
236
|
+
'aria-live': PropTypes.Requireable<string>;
|
|
237
|
+
children: PropTypes.Requireable<PropTypes.ReactNodeLike>;
|
|
238
|
+
className: PropTypes.Requireable<string>;
|
|
239
|
+
};
|
|
240
|
+
};
|
|
241
|
+
TableCell: React.ForwardRefExoticComponent<import("./TableCell").TableCellProps & React.RefAttributes<HTMLTableCellElement>>;
|
|
242
|
+
TableContainer: {
|
|
243
|
+
({ aiEnabled, className, children, title, description, stickyHeader, useStaticWidth, ...rest }: import("./TableContainer").TableContainerProps): import("react/jsx-runtime").JSX.Element;
|
|
244
|
+
propTypes: {
|
|
245
|
+
aiEnabled: PropTypes.Requireable<boolean>;
|
|
246
|
+
children: PropTypes.Requireable<PropTypes.ReactNodeLike>;
|
|
247
|
+
className: PropTypes.Requireable<string>;
|
|
248
|
+
description: PropTypes.Requireable<PropTypes.ReactNodeLike>;
|
|
249
|
+
stickyHeader: PropTypes.Requireable<boolean>;
|
|
250
|
+
title: PropTypes.Requireable<PropTypes.ReactNodeLike>;
|
|
251
|
+
useStaticWidth: PropTypes.Requireable<boolean>;
|
|
252
|
+
};
|
|
253
|
+
};
|
|
254
|
+
TableDecoratorRow: {
|
|
255
|
+
({ className, decorator, }: import("./TableDecoratorRow").TableDecoratorRowProps): import("react/jsx-runtime").JSX.Element;
|
|
256
|
+
displayName: string;
|
|
257
|
+
propTypes: {
|
|
258
|
+
className: PropTypes.Requireable<string>;
|
|
259
|
+
decorator: PropTypes.Requireable<PropTypes.ReactNodeLike>;
|
|
260
|
+
};
|
|
261
|
+
};
|
|
262
|
+
TableExpandHeader: {
|
|
263
|
+
({ ["aria-controls"]: ariaControls, ["aria-label"]: ariaLabel, ariaLabel: deprecatedAriaLabel, className: headerClassName, enableExpando, enableToggle, id, isExpanded, onExpand, expandIconDescription, children, ...rest }: import("./TableExpandHeader").TableExpandHeaderProps): import("react/jsx-runtime").JSX.Element;
|
|
264
|
+
propTypes: {
|
|
265
|
+
"aria-controls": PropTypes.Requireable<string>;
|
|
266
|
+
"aria-label": PropTypes.Requireable<string>;
|
|
267
|
+
ariaLabel: PropTypes.Requireable<string>;
|
|
268
|
+
children: PropTypes.Requireable<PropTypes.ReactNodeLike>;
|
|
269
|
+
className: PropTypes.Requireable<string>;
|
|
270
|
+
enableExpando: (props: Record<string, any>, propName: string, componentName: string, ...rest: any[]) => any;
|
|
271
|
+
enableToggle: PropTypes.Requireable<boolean>;
|
|
272
|
+
expandIconDescription: PropTypes.Requireable<string>;
|
|
273
|
+
id: PropTypes.Requireable<string>;
|
|
274
|
+
isExpanded: React.Validator;
|
|
275
|
+
onExpand: PropTypes.Requireable<any>;
|
|
276
|
+
};
|
|
277
|
+
};
|
|
278
|
+
TableExpandRow: React.ForwardRefExoticComponent<import("./TableExpandRow").TableExpandRowProps & React.RefAttributes<HTMLTableCellElement>>;
|
|
279
|
+
TableExpandedRow: {
|
|
280
|
+
({ className: customClassName, children, colSpan, ...rest }: import("./TableExpandedRow").TableExpandedRowProps): import("react/jsx-runtime").JSX.Element;
|
|
281
|
+
propTypes: {
|
|
282
|
+
children: PropTypes.Requireable<PropTypes.ReactNodeLike>;
|
|
283
|
+
className: PropTypes.Requireable<string>;
|
|
284
|
+
colSpan: PropTypes.Validator<number>;
|
|
285
|
+
};
|
|
286
|
+
};
|
|
287
|
+
TableHead: (props: React.HTMLAttributes<"thead">) => React.ReactElement<any>;
|
|
288
|
+
TableHeader: React.ForwardRefExoticComponent<import("./TableHeader").TableHeaderProps & React.RefAttributes<HTMLTableCellElement>>;
|
|
289
|
+
TableRow: React.ForwardRefExoticComponent<import("./TableRow").TableRowProps & React.RefAttributes<HTMLTableCellElement>>;
|
|
290
|
+
TableSelectAll: {
|
|
291
|
+
({ ariaLabel: deprecatedAriaLabel, ["aria-label"]: ariaLabel, checked, id, indeterminate, name, onSelect, disabled, className, }: import("./TableSelectAll").TableSelectAllProps): import("react/jsx-runtime").JSX.Element;
|
|
292
|
+
propTypes: {
|
|
293
|
+
"aria-label": PropTypes.Requireable<string>;
|
|
294
|
+
ariaLabel: (props: Record<string, any>, propName: string, componentName: string, ...rest: any[]) => any;
|
|
295
|
+
checked: PropTypes.Requireable<boolean>;
|
|
296
|
+
className: PropTypes.Requireable<string>;
|
|
297
|
+
disabled: PropTypes.Requireable<boolean>;
|
|
298
|
+
id: PropTypes.Validator<string>;
|
|
299
|
+
indeterminate: PropTypes.Requireable<boolean>;
|
|
300
|
+
name: PropTypes.Validator<string>;
|
|
301
|
+
onSelect: PropTypes.Validator<(...args: any[]) => any>;
|
|
302
|
+
};
|
|
303
|
+
};
|
|
304
|
+
TableSelectRow: {
|
|
305
|
+
({ ariaLabel: deprecatedAriaLabel, ["aria-label"]: ariaLabel, checked, id, name, onSelect, onChange, disabled, radio, className, }: import("./TableSelectRow").TableSelectRowProps): import("react/jsx-runtime").JSX.Element;
|
|
306
|
+
propTypes: {
|
|
307
|
+
"aria-label": PropTypes.Requireable<string>;
|
|
308
|
+
ariaLabel: (props: Record<string, any>, propName: string, componentName: string, ...rest: any[]) => any;
|
|
309
|
+
checked: PropTypes.Requireable<boolean>;
|
|
310
|
+
className: PropTypes.Requireable<string>;
|
|
311
|
+
disabled: PropTypes.Requireable<boolean>;
|
|
312
|
+
id: PropTypes.Validator<string>;
|
|
313
|
+
name: PropTypes.Validator<string>;
|
|
314
|
+
onChange: PropTypes.Requireable<(...args: any[]) => any>;
|
|
315
|
+
onSelect: PropTypes.Validator<(...args: any[]) => any>;
|
|
316
|
+
radio: PropTypes.Requireable<boolean>;
|
|
317
|
+
};
|
|
318
|
+
};
|
|
319
|
+
TableSlugRow: {
|
|
320
|
+
({ className, slug }: import("./TableSlugRow").TableSlugRowProps): import("react/jsx-runtime").JSX.Element;
|
|
321
|
+
displayName: string;
|
|
322
|
+
propTypes: {
|
|
323
|
+
className: PropTypes.Requireable<string>;
|
|
324
|
+
slug: PropTypes.Requireable<PropTypes.ReactNodeLike>;
|
|
325
|
+
};
|
|
326
|
+
};
|
|
327
|
+
TableToolbar: React.FC<import("./TableToolbar").TableToolbarProps>;
|
|
328
|
+
TableToolbarAction: React.ForwardRefExoticComponent<import("./TableToolbarAction").TableToolbarActionProps & React.RefAttributes<HTMLDivElement>>;
|
|
329
|
+
TableToolbarContent: (props: React.HTMLAttributes<"div">) => React.ReactElement<any>;
|
|
330
|
+
TableToolbarSearch: {
|
|
331
|
+
({ className, searchContainerClass, onChange: onChangeProp, onClear, translateWithId: t, placeholder, labelText, expanded: expandedProp, defaultExpanded, defaultValue, disabled, onExpand, persistent, id, onBlur, onFocus, size, tabIndex, ...rest }: import("./TableToolbarSearch").TableToolbarSearchProps): import("react/jsx-runtime").JSX.Element;
|
|
332
|
+
propTypes: {
|
|
333
|
+
children: PropTypes.Requireable<PropTypes.ReactNodeLike>;
|
|
334
|
+
className: PropTypes.Requireable<string>;
|
|
335
|
+
defaultExpanded: PropTypes.Requireable<boolean>;
|
|
336
|
+
defaultValue: PropTypes.Requireable<string>;
|
|
337
|
+
disabled: PropTypes.Requireable<boolean>;
|
|
338
|
+
expanded: PropTypes.Requireable<boolean>;
|
|
339
|
+
id: PropTypes.Requireable<string>;
|
|
340
|
+
labelText: PropTypes.Requireable<string>;
|
|
341
|
+
onBlur: PropTypes.Requireable<(...args: any[]) => any>;
|
|
342
|
+
onChange: PropTypes.Requireable<(...args: any[]) => any>;
|
|
343
|
+
onClear: PropTypes.Requireable<(...args: any[]) => any>;
|
|
344
|
+
onExpand: PropTypes.Requireable<(...args: any[]) => any>;
|
|
345
|
+
onFocus: PropTypes.Requireable<(...args: any[]) => any>;
|
|
346
|
+
persistent: PropTypes.Requireable<boolean>;
|
|
347
|
+
placeholder: PropTypes.Requireable<string>;
|
|
348
|
+
searchContainerClass: PropTypes.Requireable<string>;
|
|
349
|
+
size: PropTypes.Requireable<string>;
|
|
350
|
+
tabIndex: PropTypes.Requireable<NonNullable<string | number | null | undefined>>;
|
|
351
|
+
translateWithId: PropTypes.Requireable<(...args: any[]) => any>;
|
|
352
|
+
};
|
|
353
|
+
};
|
|
354
|
+
TableToolbarMenu: React.FC<import("./TableToolbarMenu").TableToolbarMenuProps>;
|
|
355
|
+
propTypes: {
|
|
356
|
+
/**
|
|
357
|
+
* Experimental property. Allows table to align cell contents to the top if there is text wrapping in the content. Might have performance issues, intended for smaller tables
|
|
358
|
+
*/
|
|
359
|
+
experimentalAutoAlign: PropTypes.Requireable<boolean>;
|
|
360
|
+
/**
|
|
361
|
+
* Optional hook to manually control filtering of the rows from the
|
|
362
|
+
* TableToolbarSearch component
|
|
363
|
+
*/
|
|
364
|
+
filterRows: PropTypes.Requireable<(...args: any[]) => any>;
|
|
365
|
+
/**
|
|
366
|
+
* The `headers` prop represents the order in which the headers should
|
|
367
|
+
* appear in the table. We expect an array of objects to be passed in, where
|
|
368
|
+
* `key` is the name of the key in a row object, and `header` is the name of
|
|
369
|
+
* the header.
|
|
370
|
+
*/
|
|
371
|
+
headers: PropTypes.Validator<(PropTypes.InferProps<{
|
|
372
|
+
key: PropTypes.Validator<string>;
|
|
373
|
+
header: PropTypes.Validator<NonNullable<PropTypes.ReactNodeLike>>;
|
|
374
|
+
}> | null | undefined)[]>;
|
|
375
|
+
/**
|
|
376
|
+
* Specify whether the table should be able to be sorted by its headers
|
|
377
|
+
*/
|
|
378
|
+
isSortable: PropTypes.Requireable<boolean>;
|
|
379
|
+
/**
|
|
380
|
+
* Provide a string for the current locale
|
|
381
|
+
*/
|
|
382
|
+
locale: PropTypes.Requireable<string>;
|
|
383
|
+
/**
|
|
384
|
+
* Specify whether the overflow menu (if it exists) should be shown always, or only on hover
|
|
385
|
+
*/
|
|
386
|
+
overflowMenuOnHover: PropTypes.Requireable<boolean>;
|
|
387
|
+
/**
|
|
388
|
+
* Specify whether the control should be a radio button or inline checkbox
|
|
389
|
+
*/
|
|
390
|
+
radio: PropTypes.Requireable<boolean>;
|
|
391
|
+
/**
|
|
392
|
+
* The `rows` prop is where you provide us with a list of all the rows that
|
|
393
|
+
* you want to render in the table. The only hard requirement is that this
|
|
394
|
+
* is an array of objects, and that each object has a unique `id` field
|
|
395
|
+
* available on it.
|
|
396
|
+
*/
|
|
397
|
+
rows: PropTypes.Validator<(PropTypes.InferProps<{
|
|
398
|
+
id: PropTypes.Validator<string>;
|
|
399
|
+
disabled: PropTypes.Requireable<boolean>;
|
|
400
|
+
isSelected: PropTypes.Requireable<boolean>;
|
|
401
|
+
isExpanded: PropTypes.Requireable<boolean>;
|
|
402
|
+
}> | null | undefined)[]>;
|
|
403
|
+
/**
|
|
404
|
+
* Change the row height of table. Currently supports `xs`, `sm`, `md`, `lg`, and `xl`.
|
|
405
|
+
*/
|
|
406
|
+
size: PropTypes.Requireable<string>;
|
|
407
|
+
/**
|
|
408
|
+
* Optional hook to manually control sorting of the rows.
|
|
409
|
+
*/
|
|
410
|
+
sortRow: PropTypes.Requireable<(...args: any[]) => any>;
|
|
411
|
+
/**
|
|
412
|
+
* Specify whether the header should be sticky.
|
|
413
|
+
* Still experimental: may not work with every combination of table props
|
|
414
|
+
*/
|
|
415
|
+
stickyHeader: PropTypes.Requireable<boolean>;
|
|
416
|
+
/**
|
|
417
|
+
* Optional method that takes in a message id and returns an
|
|
418
|
+
* internationalized string. See `DataTable.translationKeys` for all
|
|
419
|
+
* available message ids.
|
|
420
|
+
*/
|
|
421
|
+
translateWithId: PropTypes.Requireable<(...args: any[]) => any>;
|
|
422
|
+
/**
|
|
423
|
+
* `false` If true, will use a width of 'auto' instead of 100%
|
|
424
|
+
*/
|
|
425
|
+
useStaticWidth: PropTypes.Requireable<boolean>;
|
|
426
|
+
/**
|
|
427
|
+
* `true` to add useZebraStyles striping.
|
|
428
|
+
*/
|
|
429
|
+
useZebraStyles: PropTypes.Requireable<boolean>;
|
|
430
|
+
};
|
|
431
|
+
};
|
|
432
|
+
export {};
|