@splunk/react-ui 4.41.0 → 4.43.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/ButtonGroup.js +1 -3
- package/CHANGELOG.md +47 -0
- package/Code.js +611 -426
- package/ComboBox.js +25 -32
- package/Date.js +21 -26
- package/Dropdown.js +33 -32
- package/JSONTree.js +30 -24
- package/Layer.js +115 -97
- package/Link.js +19 -21
- package/MIGRATION.mdx +48 -53
- package/Menu.js +7 -2
- package/MessageBar.js +54 -56
- package/Multiselect.js +1051 -1035
- package/Number.js +424 -395
- package/Paginator.js +269 -251
- package/Popover.js +595 -526
- package/RadioList.js +44 -43
- package/Resize.js +61 -61
- package/ResultsMenu.d.ts +2 -0
- package/ResultsMenu.js +4 -4
- package/Scroll.js +482 -475
- package/Search.js +56 -65
- package/Select.js +532 -513
- package/TabBar.js +4 -0
- package/Table.js +1519 -1437
- package/Text.js +29 -17
- package/TextArea.js +37 -37
- package/Tooltip.js +300 -207
- package/TransitionOpen.js +16 -14
- package/Tree.js +20 -14
- package/package.json +7 -7
- package/types/src/Button/Button.d.ts +1 -0
- package/types/src/ButtonGroup/ButtonGroup.d.ts +0 -4
- package/types/src/Code/Code.d.ts +1 -1
- package/types/src/ComboBox/ComboBox.d.ts +6 -3
- package/types/src/Date/Date.d.ts +0 -1
- package/types/src/Dropdown/Dropdown.d.ts +2 -1
- package/types/src/Dropdown/docs/examples/TooltipButtonToggle.d.ts +2 -0
- package/types/src/Layer/Layer.d.ts +2 -1
- package/types/src/Link/Link.d.ts +0 -2
- package/types/src/Multiselect/Multiselect.d.ts +2 -0
- package/types/src/Number/Number.d.ts +11 -10
- package/types/src/Number/utils.d.ts +29 -0
- package/types/src/Paginator/Paginator.d.ts +15 -2
- package/types/src/Paginator/docs/examples/CustomPages.d.ts +2 -0
- package/types/src/Popover/Popover.d.ts +18 -12
- package/types/src/Popover/PopoverMenuContext.d.ts +6 -0
- package/types/src/Popover/PopoverProvider.d.ts +23 -0
- package/types/src/Popover/index.d.ts +2 -1
- package/types/src/RadioList/RadioList.d.ts +1 -1
- package/types/src/Resize/Resize.d.ts +0 -11
- package/types/src/Scroll/Inner.d.ts +17 -19
- package/types/src/Select/SelectBase.d.ts +7 -5
- package/types/src/Select/docs/examples/Appearance.d.ts +1 -11
- package/types/src/Select/docs/examples/Basic.d.ts +1 -9
- package/types/src/Select/docs/examples/Children.d.ts +1 -9
- package/types/src/Select/docs/examples/Descriptions.d.ts +1 -9
- package/types/src/Select/docs/examples/Fetching.d.ts +1 -22
- package/types/src/Select/docs/examples/Filter.d.ts +1 -9
- package/types/src/Select/docs/examples/Headings.d.ts +1 -9
- package/types/src/Select/docs/examples/LoadMoreOnScrollBottom.d.ts +1 -24
- package/types/src/Select/docs/examples/Prefix.d.ts +1 -9
- package/types/src/Select/docs/examples/Truncate.d.ts +1 -9
- package/types/src/Table/ExpandButton.d.ts +8 -0
- package/types/src/Table/HeadDropdownCell.d.ts +2 -0
- package/types/src/Table/HeadInner.d.ts +5 -1
- package/types/src/Table/Row.d.ts +8 -2
- package/types/src/Table/docs/examples/Click.d.ts +2 -16
- package/types/src/Table/docs/examples/ClickRows.d.ts +2 -16
- package/types/src/Table/docs/examples/Complex.d.ts +2 -50
- package/types/src/Table/docs/examples/FilterColumnValues.d.ts +1 -13
- package/types/src/Table/docs/examples/HeadDropdownCell.d.ts +1 -17
- package/types/src/Table/docs/examples/ReorderColumns.d.ts +2 -21
- package/types/src/Table/docs/examples/ReorderRows.d.ts +2 -21
- package/types/src/Table/docs/examples/Resizable.d.ts +2 -23
- package/types/src/Table/docs/examples/ResizableFill.d.ts +2 -23
- package/types/src/Table/docs/examples/RowActions.d.ts +2 -39
- package/types/src/Table/docs/examples/Selectable.d.ts +2 -18
- package/types/src/Table/docs/examples/SortableColumns.d.ts +1 -11
- package/types/src/Tooltip/Tooltip.d.ts +38 -5
- package/types/src/Tooltip/docs/examples/CustomProps.d.ts +2 -0
- package/types/src/Tooltip/docs/examples/Toggletip.d.ts +2 -0
- package/types/src/useControlled/useControlled.d.ts +5 -4
- package/useControlled.js +37 -15
- package/usePrevious.js +62 -30
- package/useResizeObserver.js +122 -90
- package/useRovingFocus.js +5 -4
- package/types/src/Dropdown/docs/examples/OtherToggles.d.ts +0 -2
- package/types/src/Popover/PopoverContext.d.ts +0 -6
- package/types/src/Table/icons/ExpansionRow.d.ts +0 -6
- package/types/src/Tooltip/docs/examples/CustomContent.d.ts +0 -2
|
@@ -9,6 +9,7 @@ interface HeadInnerPropsBase {
|
|
|
9
9
|
align?: 'left' | 'center' | 'right';
|
|
10
10
|
clickable?: boolean;
|
|
11
11
|
columnId?: any;
|
|
12
|
+
elementRef?: React.Ref<HTMLButtonElement | HTMLDivElement>;
|
|
12
13
|
focusWithin?: boolean;
|
|
13
14
|
hasActionsHead?: boolean;
|
|
14
15
|
id?: string;
|
|
@@ -23,14 +24,16 @@ interface HeadInnerPropsBase {
|
|
|
23
24
|
sortDir?: 'none' | 'asc' | 'desc';
|
|
24
25
|
truncate?: boolean;
|
|
25
26
|
width?: number | 'auto';
|
|
27
|
+
variant?: 'toggleAll' | 'info' | 'actions';
|
|
26
28
|
}
|
|
27
29
|
type HeadInnerProps = ComponentProps<HeadInnerPropsBase, 'span'>;
|
|
28
|
-
declare function HeadInner({ index, clickable, columnId, focusWithin, id, width: widthProp, onDragEnd, onAutosizeColumn, align, label, hasActionsHead, isMenu, onDragStart, onRequestResize, resizable, sortDir, truncate, ...otherProps }: HeadInnerProps): JSX.Element;
|
|
30
|
+
declare function HeadInner({ index, clickable, columnId, elementRef, focusWithin, id, width: widthProp, onDragEnd, onAutosizeColumn, align, label, hasActionsHead, isMenu, onDragStart, onRequestResize, resizable, sortDir, truncate, variant, ...otherProps }: HeadInnerProps): JSX.Element;
|
|
29
31
|
declare namespace HeadInner {
|
|
30
32
|
var propTypes: {
|
|
31
33
|
align: PropTypes.Requireable<string>;
|
|
32
34
|
clickable: PropTypes.Requireable<boolean>;
|
|
33
35
|
columnId: PropTypes.Requireable<any>;
|
|
36
|
+
elementRef: PropTypes.Requireable<object>;
|
|
34
37
|
focusWithin: PropTypes.Requireable<boolean>;
|
|
35
38
|
hasActionsHead: PropTypes.Requireable<boolean>;
|
|
36
39
|
id: PropTypes.Requireable<string>;
|
|
@@ -45,6 +48,7 @@ declare namespace HeadInner {
|
|
|
45
48
|
sortDir: PropTypes.Requireable<string>;
|
|
46
49
|
truncate: PropTypes.Requireable<boolean>;
|
|
47
50
|
width: PropTypes.Requireable<NonNullable<string | number | null | undefined>>;
|
|
51
|
+
variant: PropTypes.Requireable<string>;
|
|
48
52
|
};
|
|
49
53
|
}
|
|
50
54
|
export default HeadInner;
|
package/types/src/Table/Row.d.ts
CHANGED
|
@@ -9,9 +9,9 @@ type RowActionSecondaryClickHandler = (event: React.MouseEvent, data?: any) => v
|
|
|
9
9
|
/** @public */
|
|
10
10
|
type RowClickHandler = (event: React.MouseEvent<HTMLTableRowElement> | React.KeyboardEvent<HTMLTableRowElement>, data?: any) => void;
|
|
11
11
|
type RowRequestMoveRowHandler = TableRequestMoveRowHandler;
|
|
12
|
-
type RowExpansionHandler = (event: React.MouseEvent<
|
|
12
|
+
type RowExpansionHandler = (event: React.MouseEvent<HTMLButtonElement> | React.KeyboardEvent<HTMLButtonElement>, data?: any) => void;
|
|
13
13
|
/** @public */
|
|
14
|
-
type RowRequestExpansionHandler = (event: React.MouseEvent<
|
|
14
|
+
type RowRequestExpansionHandler = (event: React.MouseEvent<HTMLButtonElement> | React.KeyboardEvent<HTMLButtonElement>, data?: any) => void;
|
|
15
15
|
/** @public */
|
|
16
16
|
type RowRequestToggleHandler = (event: React.MouseEvent<HTMLButtonElement | HTMLAnchorElement>, data?: any) => void;
|
|
17
17
|
interface RowPropsBase {
|
|
@@ -49,6 +49,10 @@ interface RowPropsBase {
|
|
|
49
49
|
* Allows row expansion to be controlled programmatically if the `rowExpansion` prop is set to `controlled` in `Table`.
|
|
50
50
|
*/
|
|
51
51
|
expanded?: boolean;
|
|
52
|
+
/**
|
|
53
|
+
* @private. Identifies the unique id (or ids) for an expanded row (or rows). In expandable rows `ExpansionRowIcon` uses `expansionRowId` for accessibility aria attributes.
|
|
54
|
+
*/
|
|
55
|
+
expansionRowIds?: string;
|
|
52
56
|
/**
|
|
53
57
|
* An optional row that is displayed when this row is expanded, or an array of rows.
|
|
54
58
|
*/
|
|
@@ -109,6 +113,8 @@ declare namespace RowBase {
|
|
|
109
113
|
/** @private. */
|
|
110
114
|
expandable: PropTypes.Requireable<boolean>;
|
|
111
115
|
expanded: PropTypes.Requireable<boolean>;
|
|
116
|
+
/** @private. Identifies the unique id (or ids) for an expanded row (or rows). In expandable rows `ExpansionRowIcon` uses `expansionRowId` for accessibility aria attributes. */
|
|
117
|
+
expansionRowIds: PropTypes.Requireable<string>;
|
|
112
118
|
expansionRow: PropTypes.Requireable<NonNullable<PropTypes.ReactElementLike | (PropTypes.ReactElementLike | null | undefined)[] | null | undefined>>;
|
|
113
119
|
/** @private. Indicates whether the table has an actions column. */
|
|
114
120
|
actions: PropTypes.Requireable<boolean>;
|
|
@@ -1,16 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
interface Row {
|
|
4
|
-
email: string;
|
|
5
|
-
name: string;
|
|
6
|
-
}
|
|
7
|
-
interface ExampleState {
|
|
8
|
-
clickedRow?: string;
|
|
9
|
-
data: Row[];
|
|
10
|
-
}
|
|
11
|
-
export default class Click extends Component<{}, ExampleState> {
|
|
12
|
-
constructor(props: {});
|
|
13
|
-
handlerClick: CellClickHandler;
|
|
14
|
-
render(): JSX.Element;
|
|
15
|
-
}
|
|
16
|
-
export {};
|
|
1
|
+
declare function Click(): JSX.Element;
|
|
2
|
+
export default Click;
|
|
@@ -1,16 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
interface Row {
|
|
4
|
-
email: string;
|
|
5
|
-
name: string;
|
|
6
|
-
}
|
|
7
|
-
interface ExampleState {
|
|
8
|
-
clickedRow?: string;
|
|
9
|
-
data: Row[];
|
|
10
|
-
}
|
|
11
|
-
export default class ClickRows extends Component<{}, ExampleState> {
|
|
12
|
-
constructor(props: {});
|
|
13
|
-
handleClick: RowClickHandler;
|
|
14
|
-
render(): JSX.Element;
|
|
15
|
-
}
|
|
16
|
-
export {};
|
|
1
|
+
declare function ClickRows(): JSX.Element;
|
|
2
|
+
export default ClickRows;
|
|
@@ -1,50 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
interface Row {
|
|
4
|
-
age: number;
|
|
5
|
-
birthState: string;
|
|
6
|
-
disabled: boolean;
|
|
7
|
-
email: string;
|
|
8
|
-
name: string;
|
|
9
|
-
selected: boolean;
|
|
10
|
-
status: string;
|
|
11
|
-
}
|
|
12
|
-
interface Header {
|
|
13
|
-
align: 'left' | 'center' | 'right';
|
|
14
|
-
key: 'age' | 'birthState' | 'email' | 'name' | 'status';
|
|
15
|
-
label: string;
|
|
16
|
-
minWidth: number;
|
|
17
|
-
visible: boolean;
|
|
18
|
-
width: number;
|
|
19
|
-
}
|
|
20
|
-
interface ExampleState {
|
|
21
|
-
data: Row[];
|
|
22
|
-
headers: Header[];
|
|
23
|
-
primaryAction?: string;
|
|
24
|
-
primaryActionRowData?: string;
|
|
25
|
-
secondaryAction?: string;
|
|
26
|
-
secondaryActionRowData?: string;
|
|
27
|
-
sortDir: 'asc' | 'desc';
|
|
28
|
-
sortKey: 'age' | 'birthState' | 'email' | 'name' | 'status';
|
|
29
|
-
activeRow?: string;
|
|
30
|
-
activeRowData?: string;
|
|
31
|
-
}
|
|
32
|
-
export default class Complex extends Component<{}, ExampleState> {
|
|
33
|
-
constructor(props: {});
|
|
34
|
-
handleRequestMoveColumn: TableRequestMoveColumnHandler;
|
|
35
|
-
handleSort: HeadCellSortHandler;
|
|
36
|
-
handleResizeColumn: TableRequestResizeColumnHandler;
|
|
37
|
-
handleToggle: RowRequestToggleHandler;
|
|
38
|
-
handleToggleAll: () => void;
|
|
39
|
-
handleRowClick: RowClickHandler;
|
|
40
|
-
handleShowHide: (e: React.MouseEvent, { label }: {
|
|
41
|
-
label: string;
|
|
42
|
-
}) => void;
|
|
43
|
-
handleEditActionClick: RowActionPrimaryClickHandler;
|
|
44
|
-
handleSaveActionClick: RowActionSecondaryClickHandler;
|
|
45
|
-
handleAddActionClick: RowActionSecondaryClickHandler;
|
|
46
|
-
handleDeleteActionClick: RowActionSecondaryClickHandler;
|
|
47
|
-
rowSelectionState(data: Row[]): "none" | "all" | "some";
|
|
48
|
-
render(): JSX.Element;
|
|
49
|
-
}
|
|
50
|
-
export {};
|
|
1
|
+
declare function Complex(): JSX.Element;
|
|
2
|
+
export default Complex;
|
|
@@ -1,14 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
declare const kindValues: readonly ["Amazon S3", "Index", "Indexer", "Lookup", "View"];
|
|
3
|
-
type Kind = typeof kindValues[number];
|
|
4
|
-
interface ExampleState {
|
|
5
|
-
filter?: Kind[];
|
|
6
|
-
}
|
|
7
|
-
declare class FilterableTable extends Component<{}, ExampleState> {
|
|
8
|
-
constructor(props: {});
|
|
9
|
-
toggleFilterValue: (e: React.MouseEvent, { filterValue }: {
|
|
10
|
-
filterValue: Kind;
|
|
11
|
-
}) => void;
|
|
12
|
-
render(): JSX.Element;
|
|
13
|
-
}
|
|
1
|
+
declare function FilterableTable(): JSX.Element;
|
|
14
2
|
export default FilterableTable;
|
|
@@ -1,18 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
interface Column {
|
|
3
|
-
align: 'left' | 'right';
|
|
4
|
-
label: string;
|
|
5
|
-
sortKey: 'email' | 'name';
|
|
6
|
-
}
|
|
7
|
-
interface ExampleState {
|
|
8
|
-
columns: Column[];
|
|
9
|
-
sortDir: 'asc' | 'desc';
|
|
10
|
-
sortKey: 'email' | 'name';
|
|
11
|
-
}
|
|
12
|
-
declare class HeadDropdownCell extends Component<{}, ExampleState> {
|
|
13
|
-
constructor(props: {});
|
|
14
|
-
handleSort: (e: React.MouseEvent, { sortKey, sortDir }: Pick<ExampleState, 'sortKey' | 'sortDir'>) => void;
|
|
15
|
-
handleAlign: (e: React.MouseEvent, { sortKey, align }: Pick<ExampleState, 'sortKey'> & Pick<Column, 'align'>) => void;
|
|
16
|
-
render(): JSX.Element;
|
|
17
|
-
}
|
|
1
|
+
declare function HeadDropdownCell(): JSX.Element;
|
|
18
2
|
export default HeadDropdownCell;
|
|
@@ -1,21 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
interface Row {
|
|
4
|
-
age: number;
|
|
5
|
-
email: string;
|
|
6
|
-
name: string;
|
|
7
|
-
}
|
|
8
|
-
interface Header {
|
|
9
|
-
key: 'age' | 'email' | 'name';
|
|
10
|
-
label: string;
|
|
11
|
-
}
|
|
12
|
-
interface ExampleState {
|
|
13
|
-
data: Row[];
|
|
14
|
-
headers: Header[];
|
|
15
|
-
}
|
|
16
|
-
export default class ReorderColumns extends Component<{}, ExampleState> {
|
|
17
|
-
constructor(props: {});
|
|
18
|
-
handleRequestMoveColumn: TableRequestMoveColumnHandler;
|
|
19
|
-
render(): JSX.Element;
|
|
20
|
-
}
|
|
21
|
-
export {};
|
|
1
|
+
declare function ReorderColumns(): JSX.Element;
|
|
2
|
+
export default ReorderColumns;
|
|
@@ -1,21 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
interface Row {
|
|
4
|
-
age: number;
|
|
5
|
-
email: string;
|
|
6
|
-
name: string;
|
|
7
|
-
}
|
|
8
|
-
interface Header {
|
|
9
|
-
key: 'age' | 'email' | 'name';
|
|
10
|
-
label: string;
|
|
11
|
-
}
|
|
12
|
-
interface ExampleState {
|
|
13
|
-
data: Row[];
|
|
14
|
-
headers: Header[];
|
|
15
|
-
}
|
|
16
|
-
export default class ReorderRows extends Component<{}, ExampleState> {
|
|
17
|
-
constructor(props: {});
|
|
18
|
-
handleRequestMoveRow: TableRequestMoveRowHandler;
|
|
19
|
-
render(): JSX.Element;
|
|
20
|
-
}
|
|
21
|
-
export {};
|
|
1
|
+
declare function ReorderRows(): JSX.Element;
|
|
2
|
+
export default ReorderRows;
|
|
@@ -1,23 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
interface Row {
|
|
4
|
-
age: number;
|
|
5
|
-
email: string;
|
|
6
|
-
name: string;
|
|
7
|
-
}
|
|
8
|
-
interface Header {
|
|
9
|
-
key: 'age' | 'email' | 'name';
|
|
10
|
-
label: string;
|
|
11
|
-
minWidth: number;
|
|
12
|
-
width: number;
|
|
13
|
-
}
|
|
14
|
-
interface ExampleState {
|
|
15
|
-
data: Row[];
|
|
16
|
-
headers: Header[];
|
|
17
|
-
}
|
|
18
|
-
export default class Resizable extends Component<{}, ExampleState> {
|
|
19
|
-
constructor(props: {});
|
|
20
|
-
handleResizeColumn: TableRequestResizeColumnHandler;
|
|
21
|
-
render(): JSX.Element;
|
|
22
|
-
}
|
|
23
|
-
export {};
|
|
1
|
+
declare function Resizable(): JSX.Element;
|
|
2
|
+
export default Resizable;
|
|
@@ -1,23 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
interface Row {
|
|
4
|
-
age: number;
|
|
5
|
-
email: string;
|
|
6
|
-
name: string;
|
|
7
|
-
}
|
|
8
|
-
interface Header {
|
|
9
|
-
key: 'age' | 'email' | 'name';
|
|
10
|
-
label: string;
|
|
11
|
-
minWidth: number;
|
|
12
|
-
width: number | 'auto';
|
|
13
|
-
}
|
|
14
|
-
interface ExampleState {
|
|
15
|
-
data: Row[];
|
|
16
|
-
headers: Header[];
|
|
17
|
-
}
|
|
18
|
-
export default class Resizable extends Component<{}, ExampleState> {
|
|
19
|
-
constructor(props: {});
|
|
20
|
-
handleResizeColumn: TableRequestResizeColumnHandler;
|
|
21
|
-
render(): JSX.Element;
|
|
22
|
-
}
|
|
23
|
-
export {};
|
|
1
|
+
declare function ResizableFill(): JSX.Element;
|
|
2
|
+
export default ResizableFill;
|
|
@@ -1,39 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
interface Row {
|
|
4
|
-
age: number;
|
|
5
|
-
country: string;
|
|
6
|
-
email: string;
|
|
7
|
-
favoriteColor: string;
|
|
8
|
-
favoriteDay: string;
|
|
9
|
-
industry: string;
|
|
10
|
-
name: string;
|
|
11
|
-
occupation: string;
|
|
12
|
-
state: string;
|
|
13
|
-
}
|
|
14
|
-
interface Column {
|
|
15
|
-
label: string;
|
|
16
|
-
name: keyof Row;
|
|
17
|
-
visible: boolean;
|
|
18
|
-
}
|
|
19
|
-
interface ExampleState {
|
|
20
|
-
columns: Column[];
|
|
21
|
-
data: Row[];
|
|
22
|
-
primaryAction?: string;
|
|
23
|
-
primaryActionRowData?: string;
|
|
24
|
-
secondaryAction?: string;
|
|
25
|
-
secondaryActionRowData?: string;
|
|
26
|
-
}
|
|
27
|
-
export default class TableAction extends Component<{}, ExampleState> {
|
|
28
|
-
constructor(props: {});
|
|
29
|
-
handleRowClick: () => void;
|
|
30
|
-
handleShowHide: (e: React.MouseEvent, { name }: {
|
|
31
|
-
name: string;
|
|
32
|
-
}) => void;
|
|
33
|
-
handleEditActionClick: RowActionPrimaryClickHandler;
|
|
34
|
-
handleSaveActionClick: RowActionSecondaryClickHandler;
|
|
35
|
-
handleAddActionClick: RowActionSecondaryClickHandler;
|
|
36
|
-
handleDeleteActionClick: RowActionSecondaryClickHandler;
|
|
37
|
-
render(): JSX.Element;
|
|
38
|
-
}
|
|
39
|
-
export {};
|
|
1
|
+
declare function RowAction(): JSX.Element;
|
|
2
|
+
export default RowAction;
|
|
@@ -1,18 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
interface Row {
|
|
4
|
-
email: string;
|
|
5
|
-
name: string;
|
|
6
|
-
selected: boolean;
|
|
7
|
-
}
|
|
8
|
-
interface ExampleState {
|
|
9
|
-
data: Row[];
|
|
10
|
-
}
|
|
11
|
-
export default class Selectable extends Component<{}, ExampleState> {
|
|
12
|
-
constructor(props: {});
|
|
13
|
-
handleToggle: RowRequestToggleHandler;
|
|
14
|
-
handleToggleAll: () => void;
|
|
15
|
-
rowSelectionState(data: Row[]): "none" | "all" | "some";
|
|
16
|
-
render(): JSX.Element;
|
|
17
|
-
}
|
|
18
|
-
export {};
|
|
1
|
+
declare function Selectable(): JSX.Element;
|
|
2
|
+
export default Selectable;
|
|
@@ -1,12 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
import { HeadCellSortHandler } from '@splunk/react-ui/Table';
|
|
3
|
-
interface ExampleState {
|
|
4
|
-
sortDir: 'asc' | 'desc';
|
|
5
|
-
sortKey: 'email' | 'name';
|
|
6
|
-
}
|
|
7
|
-
declare class SortableColumns extends Component<{}, ExampleState> {
|
|
8
|
-
constructor(props: {});
|
|
9
|
-
handleSort: HeadCellSortHandler;
|
|
10
|
-
render(): JSX.Element;
|
|
11
|
-
}
|
|
1
|
+
declare function SortableColumns(): JSX.Element;
|
|
12
2
|
export default SortableColumns;
|
|
@@ -14,6 +14,17 @@ type TooltipRequestCloseHandler = (event: React.FocusEvent<HTMLSpanElement> | Re
|
|
|
14
14
|
type TooltipRequestOpenHandler = (event: React.FocusEvent<HTMLSpanElement> | MouseEvent, data: {
|
|
15
15
|
reason: openReasons;
|
|
16
16
|
}) => void;
|
|
17
|
+
interface AnchorProps {
|
|
18
|
+
onFocus: React.FocusEventHandler<HTMLElement>;
|
|
19
|
+
onBlur: React.FocusEventHandler<HTMLElement>;
|
|
20
|
+
onClick: React.MouseEventHandler<HTMLElement>;
|
|
21
|
+
elementRef: React.Ref<never>;
|
|
22
|
+
['data-test']: 'toggle';
|
|
23
|
+
describedBy?: string;
|
|
24
|
+
['aria-describedby']?: string;
|
|
25
|
+
labelledBy?: string;
|
|
26
|
+
['aria-labelledby']?: string;
|
|
27
|
+
}
|
|
17
28
|
interface TooltipPropsBase {
|
|
18
29
|
/** @private */
|
|
19
30
|
appearance?: 'normal' | 'inverted' | 'none';
|
|
@@ -42,7 +53,7 @@ interface TooltipPropsBase {
|
|
|
42
53
|
* By default, tooltips are a description for their control and use `aria-describedby`.
|
|
43
54
|
* Set `contentRelationship` to `label` when the Tooltip's content is a primary label for the control.
|
|
44
55
|
*/
|
|
45
|
-
contentRelationship?: '
|
|
56
|
+
contentRelationship?: 'description' | 'label';
|
|
46
57
|
/**
|
|
47
58
|
* Milliseconds to wait before the tooltip closes.
|
|
48
59
|
*/
|
|
@@ -59,7 +70,7 @@ interface TooltipPropsBase {
|
|
|
59
70
|
/**
|
|
60
71
|
* A React ref which is set to the DOM element when the component mounts and null when it unmounts.
|
|
61
72
|
*/
|
|
62
|
-
elementRef?: React.Ref<
|
|
73
|
+
elementRef?: React.Ref<HTMLElement>;
|
|
63
74
|
/**
|
|
64
75
|
* Set inline to `false` when adding a tooltip to a block element.
|
|
65
76
|
*/
|
|
@@ -85,11 +96,31 @@ interface TooltipPropsBase {
|
|
|
85
96
|
* The onRequestClose and onRequestOpen callbacks are usually used.
|
|
86
97
|
*/
|
|
87
98
|
open?: boolean;
|
|
99
|
+
/**
|
|
100
|
+
* A function for rendering the element that the tooltip is bound to. If both `renderAnchor` and
|
|
101
|
+
* `children` are passed, `children` will be ignored. The function gets as input props object
|
|
102
|
+
* for the anchor, which contains the necessary event listeners and aria attributes. By default
|
|
103
|
+
* or if `contentRelationship` is passed as `description`, the props object contains keys
|
|
104
|
+
* `aria-describedby` and `describedBy`, but if `contentRelationship` is passed as `label`,
|
|
105
|
+
* `aria-labelledby` and `labelledBy` will be passed instead.
|
|
106
|
+
*
|
|
107
|
+
* @param {object} props
|
|
108
|
+
* @param {function} props.onFocus
|
|
109
|
+
* @param {function} props.onBlur
|
|
110
|
+
* @param {function} props.onClick
|
|
111
|
+
* @param {string} props['aria-describedby']
|
|
112
|
+
* @param {string} props.describedBy
|
|
113
|
+
* @param {string} props['aria-labelledby']
|
|
114
|
+
* @param {string} props.labelledBy
|
|
115
|
+
* @param {"toggle"} props.['data-test']
|
|
116
|
+
* @param {function} props.elementRef
|
|
117
|
+
*/
|
|
118
|
+
renderAnchor?: (props: AnchorProps) => React.ReactNode;
|
|
88
119
|
/** @private */
|
|
89
120
|
splunkTheme: AnyTheme;
|
|
90
121
|
}
|
|
91
|
-
declare const defaultProps: Required<Pick<TooltipPropsBase, 'closeDelay' | 'closeWhen' | 'contentRelationship' | 'defaultPlacement' | 'inline' | 'openDelay'>>;
|
|
92
122
|
type TooltipProps = ClassComponentProps<TooltipPropsBase, typeof defaultProps, 'span'>;
|
|
123
|
+
declare const defaultProps: Required<Pick<TooltipPropsBase, 'closeDelay' | 'closeWhen' | 'defaultPlacement' | 'inline' | 'openDelay'>>;
|
|
93
124
|
interface TooltipState {
|
|
94
125
|
open: boolean;
|
|
95
126
|
anchorEl: HTMLSpanElement | null;
|
|
@@ -107,7 +138,7 @@ declare class Tooltip extends Component<TooltipProps, TooltipState> {
|
|
|
107
138
|
private popoverId;
|
|
108
139
|
private timeout?;
|
|
109
140
|
static propTypes: React.WeakValidationMap<TooltipProps>;
|
|
110
|
-
static defaultProps: Required<Pick<TooltipPropsBase, "inline" | "defaultPlacement" | "closeDelay" | "closeWhen" | "
|
|
141
|
+
static defaultProps: Required<Pick<TooltipPropsBase, "inline" | "defaultPlacement" | "closeDelay" | "closeWhen" | "openDelay">>;
|
|
111
142
|
constructor(props: Readonly<TooltipProps>);
|
|
112
143
|
componentDidUpdate(): void;
|
|
113
144
|
componentWillUnmount(): void;
|
|
@@ -131,9 +162,11 @@ declare class Tooltip extends Component<TooltipProps, TooltipState> {
|
|
|
131
162
|
private handleRequestOpen;
|
|
132
163
|
private isControlled;
|
|
133
164
|
private isOpen;
|
|
165
|
+
private handleRenderPropAnchorMount;
|
|
166
|
+
private createAnchor;
|
|
134
167
|
render(): JSX.Element;
|
|
135
168
|
}
|
|
136
|
-
declare const TooltipWithTheme: React.ForwardRefExoticComponent<Omit<Pick<Pick<TooltipProps, "slot" | "style" | "title" | "onChange" | "onPause" | "className" | "color" | "id" | "lang" | "role" | "tabIndex" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "placeholder" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | keyof TooltipPropsBase> & Pick<PropTypes.InferProps<React.WeakValidationMap<TooltipProps>>, "inlist"> & Pick<TooltipProps, never>, "slot" | "style" | "title" | "children" | "elementRef" | "onChange" | "onPause" | "className" | "color" | "id" | "lang" | "role" | "tabIndex" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "placeholder" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "open" | "content" | "appearance" | "onRequestClose" | "splunkTheme" | "onRequestOpen"> & Partial<Pick<Pick<TooltipProps, "slot" | "style" | "title" | "onChange" | "onPause" | "className" | "color" | "id" | "lang" | "role" | "tabIndex" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "placeholder" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | keyof TooltipPropsBase> & Pick<PropTypes.InferProps<React.WeakValidationMap<TooltipProps>>, "inlist"> & Pick<TooltipProps, never>, "inline" | "defaultPlacement" | "closeDelay" | "closeWhen" | "contentRelationship" | "openDelay">> & Partial<Pick<Required<Pick<TooltipPropsBase, "inline" | "defaultPlacement" | "closeDelay" | "closeWhen" | "contentRelationship" | "openDelay">>, never>> & {
|
|
169
|
+
declare const TooltipWithTheme: React.ForwardRefExoticComponent<Omit<Pick<Pick<TooltipProps, "slot" | "style" | "title" | "onChange" | "onPause" | "className" | "color" | "id" | "lang" | "role" | "tabIndex" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "placeholder" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | keyof TooltipPropsBase> & Pick<PropTypes.InferProps<React.WeakValidationMap<TooltipProps>>, "inlist"> & Pick<TooltipProps, never>, "slot" | "style" | "title" | "children" | "elementRef" | "onChange" | "onPause" | "className" | "color" | "id" | "lang" | "role" | "tabIndex" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "placeholder" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "open" | "content" | "appearance" | "onRequestClose" | "splunkTheme" | "onRequestOpen" | "contentRelationship" | "renderAnchor"> & Partial<Pick<Pick<TooltipProps, "slot" | "style" | "title" | "onChange" | "onPause" | "className" | "color" | "id" | "lang" | "role" | "tabIndex" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "placeholder" | "spellCheck" | "translate" | "radioGroup" | "about" | "datatype" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | keyof TooltipPropsBase> & Pick<PropTypes.InferProps<React.WeakValidationMap<TooltipProps>>, "inlist"> & Pick<TooltipProps, never>, "inline" | "defaultPlacement" | "closeDelay" | "closeWhen" | "openDelay">> & Partial<Pick<Required<Pick<TooltipPropsBase, "inline" | "defaultPlacement" | "closeDelay" | "closeWhen" | "openDelay">>, never>> & {
|
|
137
170
|
ref?: React.Ref<Tooltip> | undefined;
|
|
138
171
|
}, "splunkTheme">>;
|
|
139
172
|
export default TooltipWithTheme;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { MutableRefObject } from 'react';
|
|
2
|
-
interface DefaultValueProps
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
interface DefaultValueProps {
|
|
3
|
+
componentProps: {
|
|
4
|
+
[key: string]: any;
|
|
5
|
+
};
|
|
5
6
|
componentName?: string;
|
|
6
7
|
defaultValuePropName?: string;
|
|
7
8
|
valuePropName?: string;
|
|
@@ -16,6 +17,6 @@ interface DefaultValueProps<T> {
|
|
|
16
17
|
*
|
|
17
18
|
* Return the controlled state of the component.
|
|
18
19
|
*/
|
|
19
|
-
declare function useControlled
|
|
20
|
+
declare function useControlled({ componentProps, componentName, defaultValuePropName, valuePropName, }: DefaultValueProps): MutableRefObject<boolean>['current'];
|
|
20
21
|
export default useControlled;
|
|
21
22
|
export { DefaultValueProps };
|