@workday/canvas-kit-react 7.0.0-alpha.92-next.19 → 7.0.0-alpha.94-next.20
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/collection/index.ts +1 -1
- package/collection/lib/useListItemRegister.tsx +1 -1
- package/collection/lib/useListRenderItem.tsx +1 -1
- package/dist/commonjs/collection/index.d.ts +1 -1
- package/dist/commonjs/collection/index.d.ts.map +1 -1
- package/dist/commonjs/collection/lib/useListItemRegister.d.ts +1 -1
- package/dist/commonjs/collection/lib/useListItemRegister.js +1 -1
- package/dist/commonjs/menu/lib/Menu.d.ts +285 -101
- package/dist/commonjs/menu/lib/Menu.d.ts.map +1 -1
- package/dist/commonjs/menu/lib/Menu.js +2 -2
- package/dist/commonjs/menu/lib/MenuCard.d.ts +2 -2
- package/dist/commonjs/menu/lib/MenuContextTarget.d.ts +1 -1
- package/dist/commonjs/menu/lib/MenuItem.d.ts +2 -2
- package/dist/commonjs/menu/lib/MenuList.d.ts +2 -2
- package/dist/commonjs/menu/lib/MenuPopper.d.ts +1 -1
- package/dist/commonjs/menu/lib/MenuTarget.d.ts +2 -2
- package/dist/commonjs/menu/lib/useMenuModel.d.ts +43 -43
- package/dist/commonjs/tabs/lib/Tabs.d.ts +167 -167
- package/dist/commonjs/tabs/lib/Tabs.js +1 -1
- package/dist/commonjs/tabs/lib/TabsItem.d.ts +4 -4
- package/dist/commonjs/tabs/lib/TabsList.d.ts +5 -5
- package/dist/commonjs/tabs/lib/TabsMenuPopper.d.ts +1 -1
- package/dist/commonjs/tabs/lib/TabsOverflowButton.d.ts +4 -4
- package/dist/commonjs/tabs/lib/TabsOverflowButton.d.ts.map +1 -1
- package/dist/commonjs/tabs/lib/TabsOverflowButton.js +1 -2
- package/dist/commonjs/tabs/lib/TabsPanel.d.ts +7 -6
- package/dist/commonjs/tabs/lib/TabsPanel.d.ts.map +1 -1
- package/dist/commonjs/tabs/lib/TabsPanel.js +10 -10
- package/dist/commonjs/tabs/lib/TabsPanels.d.ts +3 -3
- package/dist/commonjs/tabs/lib/useTabsModel.d.ts +108 -108
- package/dist/es6/collection/index.d.ts +1 -1
- package/dist/es6/collection/index.d.ts.map +1 -1
- package/dist/es6/collection/lib/useListItemRegister.d.ts +1 -1
- package/dist/es6/collection/lib/useListItemRegister.js +1 -1
- package/dist/es6/menu/lib/Menu.d.ts +285 -101
- package/dist/es6/menu/lib/Menu.d.ts.map +1 -1
- package/dist/es6/menu/lib/Menu.js +2 -2
- package/dist/es6/menu/lib/MenuCard.d.ts +2 -2
- package/dist/es6/menu/lib/MenuContextTarget.d.ts +1 -1
- package/dist/es6/menu/lib/MenuItem.d.ts +2 -2
- package/dist/es6/menu/lib/MenuList.d.ts +2 -2
- package/dist/es6/menu/lib/MenuPopper.d.ts +1 -1
- package/dist/es6/menu/lib/MenuTarget.d.ts +2 -2
- package/dist/es6/menu/lib/useMenuModel.d.ts +43 -43
- package/dist/es6/tabs/lib/Tabs.d.ts +167 -167
- package/dist/es6/tabs/lib/Tabs.js +1 -1
- package/dist/es6/tabs/lib/TabsItem.d.ts +4 -4
- package/dist/es6/tabs/lib/TabsList.d.ts +5 -5
- package/dist/es6/tabs/lib/TabsMenuPopper.d.ts +1 -1
- package/dist/es6/tabs/lib/TabsOverflowButton.d.ts +4 -4
- package/dist/es6/tabs/lib/TabsOverflowButton.d.ts.map +1 -1
- package/dist/es6/tabs/lib/TabsOverflowButton.js +1 -2
- package/dist/es6/tabs/lib/TabsPanel.d.ts +7 -6
- package/dist/es6/tabs/lib/TabsPanel.d.ts.map +1 -1
- package/dist/es6/tabs/lib/TabsPanel.js +10 -10
- package/dist/es6/tabs/lib/TabsPanels.d.ts +3 -3
- package/dist/es6/tabs/lib/useTabsModel.d.ts +108 -108
- package/menu/lib/Menu.tsx +2 -2
- package/package.json +5 -5
- package/tabs/lib/Tabs.tsx +1 -1
- package/tabs/lib/TabsList.tsx +1 -1
- package/tabs/lib/TabsOverflowButton.tsx +5 -7
- package/tabs/lib/TabsPanel.tsx +15 -11
|
@@ -31,7 +31,7 @@ exports.Tabs = common_1.createContainer()({
|
|
|
31
31
|
* <Tabs.Menu.Popper>
|
|
32
32
|
* <Tabs.Menu.Card>
|
|
33
33
|
* <Tabs.Menu.List>
|
|
34
|
-
* {(item: MyTabItem) => <Tabs.Menu.Item
|
|
34
|
+
* {(item: MyTabItem) => <Tabs.Menu.Item data-id={item.id}>{item.text}</Tabs.Menu.Item>}
|
|
35
35
|
* </Tabs.Menu.List>
|
|
36
36
|
* </Tabs.Menu.Card>
|
|
37
37
|
* </Tabs.Menu.Popper>
|
|
@@ -76,7 +76,7 @@ export declare const useTabsItem: <P extends {}, R>(model: {
|
|
|
76
76
|
indexRef: React.MutableRefObject<number>;
|
|
77
77
|
nonInteractiveIds: string[];
|
|
78
78
|
isVirtualized: boolean;
|
|
79
|
-
items: import("../../collection
|
|
79
|
+
items: import("../../collection").Item<any>[];
|
|
80
80
|
};
|
|
81
81
|
events: {
|
|
82
82
|
registerItem(data: {
|
|
@@ -112,7 +112,7 @@ export declare const TabsItem: import("../../common").ElementComponentM<"button"
|
|
|
112
112
|
state: {
|
|
113
113
|
getId: (item: any) => string;
|
|
114
114
|
orientation: import("../../collection/lib/useBaseListModel").Orientation;
|
|
115
|
-
panels: import("../../collection
|
|
115
|
+
panels: import("../../collection").Item<any>[];
|
|
116
116
|
panelIndexRef: React.MutableRefObject<number>;
|
|
117
117
|
hiddenIds: string[];
|
|
118
118
|
itemWidthCache: Record<string, number>;
|
|
@@ -135,7 +135,7 @@ export declare const TabsItem: import("../../common").ElementComponentM<"button"
|
|
|
135
135
|
indexRef: React.MutableRefObject<number>;
|
|
136
136
|
nonInteractiveIds: string[];
|
|
137
137
|
isVirtualized: boolean;
|
|
138
|
-
items: import("../../collection
|
|
138
|
+
items: import("../../collection").Item<any>[];
|
|
139
139
|
};
|
|
140
140
|
events: {
|
|
141
141
|
registerPanel: (data: {
|
|
@@ -219,7 +219,7 @@ export declare const TabsItem: import("../../common").ElementComponentM<"button"
|
|
|
219
219
|
indexRef: React.MutableRefObject<number>;
|
|
220
220
|
nonInteractiveIds: string[];
|
|
221
221
|
isVirtualized: boolean;
|
|
222
|
-
items: import("../../collection
|
|
222
|
+
items: import("../../collection").Item<any>[];
|
|
223
223
|
mode: "multiple" | "single";
|
|
224
224
|
};
|
|
225
225
|
events: {
|
|
@@ -8,7 +8,7 @@ export interface TabListProps<T = unknown> extends Partial<ExtractProps<typeof S
|
|
|
8
8
|
*
|
|
9
9
|
* @example
|
|
10
10
|
* <Tabs.List>
|
|
11
|
-
* {(item) => <Tabs.Item
|
|
11
|
+
* {(item) => <Tabs.Item>{item.text}</Tabs.Item>}
|
|
12
12
|
* </Tabs.List>
|
|
13
13
|
*/
|
|
14
14
|
children: ((item: T) => React.ReactNode) | React.ReactNode;
|
|
@@ -34,7 +34,7 @@ export declare const useTabsList: <P extends {}, R>(model: {
|
|
|
34
34
|
indexRef: React.MutableRefObject<number>;
|
|
35
35
|
nonInteractiveIds: string[];
|
|
36
36
|
isVirtualized: boolean;
|
|
37
|
-
items: import("../../collection
|
|
37
|
+
items: import("../../collection").Item<any>[];
|
|
38
38
|
};
|
|
39
39
|
events: {
|
|
40
40
|
select(data: {
|
|
@@ -76,7 +76,7 @@ export declare const TabsList: import("../../common").ElementComponentM<"div", T
|
|
|
76
76
|
state: {
|
|
77
77
|
getId: (item: any) => string;
|
|
78
78
|
orientation: import("../../collection/lib/useBaseListModel").Orientation;
|
|
79
|
-
panels: import("../../collection
|
|
79
|
+
panels: import("../../collection").Item<any>[];
|
|
80
80
|
panelIndexRef: React.MutableRefObject<number>;
|
|
81
81
|
hiddenIds: string[];
|
|
82
82
|
itemWidthCache: Record<string, number>;
|
|
@@ -99,7 +99,7 @@ export declare const TabsList: import("../../common").ElementComponentM<"div", T
|
|
|
99
99
|
indexRef: React.MutableRefObject<number>;
|
|
100
100
|
nonInteractiveIds: string[];
|
|
101
101
|
isVirtualized: boolean;
|
|
102
|
-
items: import("../../collection
|
|
102
|
+
items: import("../../collection").Item<any>[];
|
|
103
103
|
};
|
|
104
104
|
events: {
|
|
105
105
|
registerPanel: (data: {
|
|
@@ -183,7 +183,7 @@ export declare const TabsList: import("../../common").ElementComponentM<"div", T
|
|
|
183
183
|
indexRef: React.MutableRefObject<number>;
|
|
184
184
|
nonInteractiveIds: string[];
|
|
185
185
|
isVirtualized: boolean;
|
|
186
|
-
items: import("../../collection
|
|
186
|
+
items: import("../../collection").Item<any>[];
|
|
187
187
|
mode: "multiple" | "single";
|
|
188
188
|
};
|
|
189
189
|
events: {
|
|
@@ -58,7 +58,7 @@ export declare const TabsMenuPopper: import("../../common").ElementComponentM<"d
|
|
|
58
58
|
indexRef: React.MutableRefObject<number>;
|
|
59
59
|
nonInteractiveIds: string[];
|
|
60
60
|
isVirtualized: boolean;
|
|
61
|
-
items: import("
|
|
61
|
+
items: import("../..").Item<any>[];
|
|
62
62
|
mode: "multiple" | "single";
|
|
63
63
|
};
|
|
64
64
|
events: {
|
|
@@ -29,7 +29,7 @@ export declare const useTabsOverflowButton: <P extends {}, R>(model: {
|
|
|
29
29
|
indexRef: React.MutableRefObject<number>;
|
|
30
30
|
nonInteractiveIds: string[];
|
|
31
31
|
isVirtualized: boolean;
|
|
32
|
-
items: import("../../collection
|
|
32
|
+
items: import("../../collection").Item<any>[];
|
|
33
33
|
};
|
|
34
34
|
events: {
|
|
35
35
|
select(data: {
|
|
@@ -90,7 +90,7 @@ export declare const TabsOverflowButton: import("../../common").ElementComponent
|
|
|
90
90
|
state: {
|
|
91
91
|
getId: (item: any) => string;
|
|
92
92
|
orientation: import("../../collection/lib/useBaseListModel").Orientation;
|
|
93
|
-
panels: import("../../collection
|
|
93
|
+
panels: import("../../collection").Item<any>[];
|
|
94
94
|
panelIndexRef: React.MutableRefObject<number>;
|
|
95
95
|
hiddenIds: string[];
|
|
96
96
|
itemWidthCache: Record<string, number>;
|
|
@@ -113,7 +113,7 @@ export declare const TabsOverflowButton: import("../../common").ElementComponent
|
|
|
113
113
|
indexRef: React.MutableRefObject<number>;
|
|
114
114
|
nonInteractiveIds: string[];
|
|
115
115
|
isVirtualized: boolean;
|
|
116
|
-
items: import("../../collection
|
|
116
|
+
items: import("../../collection").Item<any>[];
|
|
117
117
|
};
|
|
118
118
|
events: {
|
|
119
119
|
registerPanel: (data: {
|
|
@@ -197,7 +197,7 @@ export declare const TabsOverflowButton: import("../../common").ElementComponent
|
|
|
197
197
|
indexRef: React.MutableRefObject<number>;
|
|
198
198
|
nonInteractiveIds: string[];
|
|
199
199
|
isVirtualized: boolean;
|
|
200
|
-
items: import("../../collection
|
|
200
|
+
items: import("../../collection").Item<any>[];
|
|
201
201
|
mode: "multiple" | "single";
|
|
202
202
|
};
|
|
203
203
|
events: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TabsOverflowButton.d.ts","sourceRoot":"","sources":["../../../../tabs/lib/TabsOverflowButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAgB/B,MAAM,WAAW,mBAAmB;IAClC;;OAEG;IACH,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B;AAED,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"TabsOverflowButton.d.ts","sourceRoot":"","sources":["../../../../tabs/lib/TabsOverflowButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAgB/B,MAAM,WAAW,mBAAmB;IAClC;;OAEG;IACH,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B;AAED,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAQjC,CAAC;AAEF,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAW7B,CAAC"}
|
|
@@ -50,8 +50,7 @@ var collection_1 = require("@workday/canvas-kit-react/collection");
|
|
|
50
50
|
var menu_1 = require("@workday/canvas-kit-react/menu");
|
|
51
51
|
var useTabsModel_1 = require("./useTabsModel");
|
|
52
52
|
var TabsItem_1 = require("./TabsItem");
|
|
53
|
-
exports.useTabsOverflowButton = common_1.composeHooks(common_1.createElemPropsHook(useTabsModel_1.useTabsModel)(function (
|
|
54
|
-
if (elemProps === void 0) { elemProps = {}; }
|
|
53
|
+
exports.useTabsOverflowButton = common_1.composeHooks(common_1.createElemPropsHook(useTabsModel_1.useTabsModel)(function () {
|
|
55
54
|
return {
|
|
56
55
|
'aria-haspopup': true,
|
|
57
56
|
};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { ExtractProps } from '@workday/canvas-kit-react/common';
|
|
3
|
+
import { Item } from '@workday/canvas-kit-react/collection';
|
|
3
4
|
import { Box } from '@workday/canvas-kit-react/layout';
|
|
4
5
|
export interface TabPanelProps<T = unknown> extends ExtractProps<typeof Box, never> {
|
|
5
6
|
/**
|
|
@@ -25,7 +26,7 @@ export declare const useTabsPanel: <P extends {}, R>(model: {
|
|
|
25
26
|
state: {
|
|
26
27
|
getId: (item: any) => string;
|
|
27
28
|
orientation: import("../../collection/lib/useBaseListModel").Orientation;
|
|
28
|
-
panels:
|
|
29
|
+
panels: Item<any>[];
|
|
29
30
|
panelIndexRef: React.MutableRefObject<number>;
|
|
30
31
|
hiddenIds: string[];
|
|
31
32
|
itemWidthCache: Record<string, number>;
|
|
@@ -48,7 +49,7 @@ export declare const useTabsPanel: <P extends {}, R>(model: {
|
|
|
48
49
|
indexRef: React.MutableRefObject<number>;
|
|
49
50
|
nonInteractiveIds: string[];
|
|
50
51
|
isVirtualized: boolean;
|
|
51
|
-
items:
|
|
52
|
+
items: Item<any>[];
|
|
52
53
|
};
|
|
53
54
|
events: {
|
|
54
55
|
registerPanel: (data: {
|
|
@@ -132,7 +133,7 @@ export declare const useTabsPanel: <P extends {}, R>(model: {
|
|
|
132
133
|
indexRef: React.MutableRefObject<number>;
|
|
133
134
|
nonInteractiveIds: string[];
|
|
134
135
|
isVirtualized: boolean;
|
|
135
|
-
items:
|
|
136
|
+
items: Item<any>[];
|
|
136
137
|
mode: "multiple" | "single";
|
|
137
138
|
};
|
|
138
139
|
events: {
|
|
@@ -194,7 +195,7 @@ export declare const TabsPanel: import("../../common").ElementComponentM<"div",
|
|
|
194
195
|
state: {
|
|
195
196
|
getId: (item: any) => string;
|
|
196
197
|
orientation: import("../../collection/lib/useBaseListModel").Orientation;
|
|
197
|
-
panels:
|
|
198
|
+
panels: Item<any>[];
|
|
198
199
|
panelIndexRef: React.MutableRefObject<number>;
|
|
199
200
|
hiddenIds: string[];
|
|
200
201
|
itemWidthCache: Record<string, number>;
|
|
@@ -217,7 +218,7 @@ export declare const TabsPanel: import("../../common").ElementComponentM<"div",
|
|
|
217
218
|
indexRef: React.MutableRefObject<number>;
|
|
218
219
|
nonInteractiveIds: string[];
|
|
219
220
|
isVirtualized: boolean;
|
|
220
|
-
items:
|
|
221
|
+
items: Item<any>[];
|
|
221
222
|
};
|
|
222
223
|
events: {
|
|
223
224
|
registerPanel: (data: {
|
|
@@ -301,7 +302,7 @@ export declare const TabsPanel: import("../../common").ElementComponentM<"div",
|
|
|
301
302
|
indexRef: React.MutableRefObject<number>;
|
|
302
303
|
nonInteractiveIds: string[];
|
|
303
304
|
isVirtualized: boolean;
|
|
304
|
-
items:
|
|
305
|
+
items: Item<any>[];
|
|
305
306
|
mode: "multiple" | "single";
|
|
306
307
|
};
|
|
307
308
|
events: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TabsPanel.d.ts","sourceRoot":"","sources":["../../../../tabs/lib/TabsPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAIL,YAAY,EAGb,MAAM,kCAAkC,CAAC;AAC1C,OAAO,EAAC,GAAG,EAAC,MAAM,kCAAkC,CAAC;AAIrD,MAAM,WAAW,aAAa,CAAC,CAAC,GAAG,OAAO,CAAE,SAAQ,YAAY,CAAC,OAAO,GAAG,EAAE,KAAK,CAAC;IACjF;;OAEG;IACH,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B;;;;;OAKG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;;;OAKG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAID,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"TabsPanel.d.ts","sourceRoot":"","sources":["../../../../tabs/lib/TabsPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAIL,YAAY,EAGb,MAAM,kCAAkC,CAAC;AAC1C,OAAO,EAAC,IAAI,EAAC,MAAM,sCAAsC,CAAC;AAC1D,OAAO,EAAC,GAAG,EAAC,MAAM,kCAAkC,CAAC;AAIrD,MAAM,WAAW,aAAa,CAAC,CAAC,GAAG,OAAO,CAAE,SAAQ,YAAY,CAAC,OAAO,GAAG,EAAE,KAAK,CAAC;IACjF;;OAEG;IACH,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B;;;;;OAKG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;;;OAKG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAID,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA2BxB,CAAC;AAEF,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAUpB,CAAC"}
|
|
@@ -33,24 +33,24 @@ var layout_1 = require("@workday/canvas-kit-react/layout");
|
|
|
33
33
|
var useTabsModel_1 = require("./useTabsModel");
|
|
34
34
|
var StyledTabsPanel = styled_1.default(layout_1.Box)(common_1.hideMouseFocus);
|
|
35
35
|
exports.useTabsPanel = common_1.createElemPropsHook(useTabsModel_1.useTabsModel)(function (_a, _, elemProps) {
|
|
36
|
+
var _b;
|
|
36
37
|
var state = _a.state, events = _a.events;
|
|
37
38
|
if (elemProps === void 0) { elemProps = {}; }
|
|
38
|
-
var
|
|
39
|
-
var _b = react_1.default.useState(elemProps['data-id'] || ''), tabName = _b[0], setTabName = _b[1];
|
|
39
|
+
var _c = react_1.default.useState(elemProps['data-id'] || ((_b = elemProps.item) === null || _b === void 0 ? void 0 : _b.id) || ''), localId = _c[0], setLocalId = _c[1];
|
|
40
40
|
common_1.useMountLayout(function () {
|
|
41
|
-
var
|
|
42
|
-
var
|
|
43
|
-
events.registerPanel({ item: { id:
|
|
44
|
-
|
|
41
|
+
var defaultId = state.panelIndexRef.current;
|
|
42
|
+
var itemId = localId || String(defaultId);
|
|
43
|
+
events.registerPanel({ item: { id: itemId }, textValue: '' });
|
|
44
|
+
setLocalId(itemId);
|
|
45
45
|
return function () {
|
|
46
|
-
events.unregisterPanel({ id:
|
|
46
|
+
events.unregisterPanel({ id: itemId });
|
|
47
47
|
};
|
|
48
48
|
});
|
|
49
49
|
return {
|
|
50
50
|
role: 'tabpanel',
|
|
51
|
-
'aria-labelledby': state.id + "-" +
|
|
52
|
-
hidden: !!
|
|
53
|
-
id: "tabpanel-" + state.id + "-" +
|
|
51
|
+
'aria-labelledby': state.id + "-" + localId,
|
|
52
|
+
hidden: !!localId && localId !== state.selectedIds[0],
|
|
53
|
+
id: "tabpanel-" + state.id + "-" + localId,
|
|
54
54
|
tabIndex: 0,
|
|
55
55
|
};
|
|
56
56
|
});
|
|
@@ -9,7 +9,7 @@ export declare const TabsPanels: import("../../common").ElementComponentM<React.
|
|
|
9
9
|
state: {
|
|
10
10
|
getId: (item: any) => string;
|
|
11
11
|
orientation: import("../../collection/lib/useBaseListModel").Orientation;
|
|
12
|
-
panels: import("../../collection
|
|
12
|
+
panels: import("../../collection").Item<any>[];
|
|
13
13
|
panelIndexRef: React.MutableRefObject<number>;
|
|
14
14
|
hiddenIds: string[];
|
|
15
15
|
itemWidthCache: Record<string, number>;
|
|
@@ -32,7 +32,7 @@ export declare const TabsPanels: import("../../common").ElementComponentM<React.
|
|
|
32
32
|
indexRef: React.MutableRefObject<number>;
|
|
33
33
|
nonInteractiveIds: string[];
|
|
34
34
|
isVirtualized: boolean;
|
|
35
|
-
items: import("../../collection
|
|
35
|
+
items: import("../../collection").Item<any>[];
|
|
36
36
|
};
|
|
37
37
|
events: {
|
|
38
38
|
registerPanel: (data: {
|
|
@@ -116,7 +116,7 @@ export declare const TabsPanels: import("../../common").ElementComponentM<React.
|
|
|
116
116
|
indexRef: React.MutableRefObject<number>;
|
|
117
117
|
nonInteractiveIds: string[];
|
|
118
118
|
isVirtualized: boolean;
|
|
119
|
-
items: import("../../collection
|
|
119
|
+
items: import("../../collection").Item<any>[];
|
|
120
120
|
mode: "multiple" | "single";
|
|
121
121
|
};
|
|
122
122
|
events: {
|