@workday/canvas-kit-react 11.0.0-alpha.716-next.0 → 11.0.0-alpha.718-next.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/collection/lib/ListBox.tsx +50 -19
- package/combobox/lib/ComboboxMenuItem.tsx +24 -6
- package/combobox/lib/ComboboxMenuList.tsx +11 -10
- package/dist/commonjs/collection/lib/ListBox.d.ts.map +1 -1
- package/dist/commonjs/collection/lib/ListBox.js +18 -5
- package/dist/commonjs/combobox/lib/Combobox.d.ts +77 -5
- package/dist/commonjs/combobox/lib/Combobox.d.ts.map +1 -1
- package/dist/commonjs/combobox/lib/ComboboxMenu.d.ts +77 -5
- package/dist/commonjs/combobox/lib/ComboboxMenu.d.ts.map +1 -1
- package/dist/commonjs/combobox/lib/ComboboxMenuItem.d.ts +157 -7
- package/dist/commonjs/combobox/lib/ComboboxMenuItem.d.ts.map +1 -1
- package/dist/commonjs/combobox/lib/ComboboxMenuItem.js +17 -3
- package/dist/commonjs/combobox/lib/ComboboxMenuList.d.ts +0 -1
- package/dist/commonjs/combobox/lib/ComboboxMenuList.d.ts.map +1 -1
- package/dist/commonjs/combobox/lib/ComboboxMenuList.js +8 -3
- package/dist/commonjs/menu/index.d.ts +1 -1
- package/dist/commonjs/menu/index.d.ts.map +1 -1
- package/dist/commonjs/menu/index.js +2 -1
- package/dist/commonjs/menu/lib/MenuCard.d.ts +9 -0
- package/dist/commonjs/menu/lib/MenuCard.d.ts.map +1 -1
- package/dist/commonjs/menu/lib/MenuCard.js +18 -21
- package/dist/commonjs/menu/lib/MenuList.d.ts +10 -0
- package/dist/commonjs/menu/lib/MenuList.d.ts.map +1 -1
- package/dist/commonjs/menu/lib/MenuList.js +14 -3
- package/dist/commonjs/select/lib/Select.d.ts +437 -13
- package/dist/commonjs/select/lib/Select.d.ts.map +1 -1
- package/dist/commonjs/select/lib/Select.js +21 -12
- package/dist/es6/collection/lib/ListBox.d.ts.map +1 -1
- package/dist/es6/collection/lib/ListBox.js +19 -6
- package/dist/es6/combobox/lib/Combobox.d.ts +77 -5
- package/dist/es6/combobox/lib/Combobox.d.ts.map +1 -1
- package/dist/es6/combobox/lib/ComboboxMenu.d.ts +77 -5
- package/dist/es6/combobox/lib/ComboboxMenu.d.ts.map +1 -1
- package/dist/es6/combobox/lib/ComboboxMenuItem.d.ts +157 -7
- package/dist/es6/combobox/lib/ComboboxMenuItem.d.ts.map +1 -1
- package/dist/es6/combobox/lib/ComboboxMenuItem.js +17 -3
- package/dist/es6/combobox/lib/ComboboxMenuList.d.ts +0 -1
- package/dist/es6/combobox/lib/ComboboxMenuList.d.ts.map +1 -1
- package/dist/es6/combobox/lib/ComboboxMenuList.js +9 -4
- package/dist/es6/menu/index.d.ts +1 -1
- package/dist/es6/menu/index.d.ts.map +1 -1
- package/dist/es6/menu/index.js +1 -1
- package/dist/es6/menu/lib/MenuCard.d.ts +9 -0
- package/dist/es6/menu/lib/MenuCard.d.ts.map +1 -1
- package/dist/es6/menu/lib/MenuCard.js +18 -21
- package/dist/es6/menu/lib/MenuList.d.ts +10 -0
- package/dist/es6/menu/lib/MenuList.d.ts.map +1 -1
- package/dist/es6/menu/lib/MenuList.js +13 -2
- package/dist/es6/select/lib/Select.d.ts +437 -13
- package/dist/es6/select/lib/Select.d.ts.map +1 -1
- package/dist/es6/select/lib/Select.js +21 -12
- package/menu/index.ts +1 -1
- package/menu/lib/MenuCard.tsx +37 -32
- package/menu/lib/MenuList.tsx +24 -8
- package/package.json +4 -4
- package/select/lib/Select.tsx +45 -31
|
@@ -5,7 +5,9 @@ import {
|
|
|
5
5
|
createSubcomponent,
|
|
6
6
|
ExtractProps,
|
|
7
7
|
} from '@workday/canvas-kit-react/common';
|
|
8
|
-
import {Box, Flex} from '@workday/canvas-kit-react/layout';
|
|
8
|
+
import {Box, Flex, mergeStyles} from '@workday/canvas-kit-react/layout';
|
|
9
|
+
import {createStencil} from '@workday/canvas-kit-styling';
|
|
10
|
+
import {system} from '@workday/canvas-tokens-web';
|
|
9
11
|
|
|
10
12
|
import {useListModel} from './useListModel';
|
|
11
13
|
import {useListRenderItems} from './useListRenderItem';
|
|
@@ -32,6 +34,30 @@ export const useListBox = createElemPropsHook(useListModel)(model => {
|
|
|
32
34
|
};
|
|
33
35
|
});
|
|
34
36
|
|
|
37
|
+
const listBoxContainerStencil = createStencil({
|
|
38
|
+
base: {
|
|
39
|
+
boxSizing: 'border-box',
|
|
40
|
+
},
|
|
41
|
+
modifiers: {
|
|
42
|
+
orientation: {
|
|
43
|
+
vertical: {
|
|
44
|
+
overflowY: 'auto',
|
|
45
|
+
},
|
|
46
|
+
horizontal: {
|
|
47
|
+
overflowY: undefined,
|
|
48
|
+
},
|
|
49
|
+
},
|
|
50
|
+
},
|
|
51
|
+
});
|
|
52
|
+
|
|
53
|
+
const listBoxStencil = createStencil({
|
|
54
|
+
base: {
|
|
55
|
+
flexDirection: 'column',
|
|
56
|
+
marginTop: system.space.zero,
|
|
57
|
+
marginBottom: system.space.zero,
|
|
58
|
+
},
|
|
59
|
+
});
|
|
60
|
+
|
|
35
61
|
/**
|
|
36
62
|
* The `ListBox` component that offers vertical rendering of a collection in the form of a
|
|
37
63
|
* 2-dimension list. It supports virtualization, rendering only visible items in the DOM while also
|
|
@@ -65,21 +91,26 @@ export const ListBox = createContainer('ul')({
|
|
|
65
91
|
*/
|
|
66
92
|
Item: ListBoxItem,
|
|
67
93
|
},
|
|
68
|
-
})<ListBoxProps>(
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
}
|
|
94
|
+
})<ListBoxProps>(
|
|
95
|
+
(
|
|
96
|
+
{height, maxHeight, marginY, marginBottom, overflowY, marginTop, ...elemProps},
|
|
97
|
+
Element,
|
|
98
|
+
model
|
|
99
|
+
) => {
|
|
100
|
+
// We're removing `marginY, marginBottom, overflowY, marginTo` from elemProps and applying them to the container as to not interfere with the virtualization size. We set
|
|
101
|
+
// the `marginY` on the Flex to `0` to avoid inaccurate scrollbars
|
|
102
|
+
return (
|
|
103
|
+
<div
|
|
104
|
+
ref={model.state.containerRef}
|
|
105
|
+
{...mergeStyles(
|
|
106
|
+
{maxHeight, marginBottom: marginY, marginTop: marginY},
|
|
107
|
+
listBoxContainerStencil({orientation: model.state.orientation})
|
|
108
|
+
)}
|
|
109
|
+
>
|
|
110
|
+
<Flex as={Element} {...mergeStyles(elemProps, listBoxStencil())}>
|
|
111
|
+
{useListRenderItems(model, elemProps.children)}
|
|
112
|
+
</Flex>
|
|
113
|
+
</div>
|
|
114
|
+
);
|
|
115
|
+
}
|
|
116
|
+
);
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
composeHooks,
|
|
5
5
|
createElemPropsHook,
|
|
6
6
|
createSubcomponent,
|
|
7
|
-
|
|
7
|
+
ExtractProps,
|
|
8
8
|
} from '@workday/canvas-kit-react/common';
|
|
9
9
|
import {StyledMenuItem, useMenuModel} from '@workday/canvas-kit-react/menu';
|
|
10
10
|
import {SystemIcon} from '@workday/canvas-kit-react/icon';
|
|
@@ -15,10 +15,11 @@ import {
|
|
|
15
15
|
import {OverflowTooltip} from '@workday/canvas-kit-react/tooltip';
|
|
16
16
|
|
|
17
17
|
import {useComboboxModel} from './hooks/useComboboxModel';
|
|
18
|
+
import {createStencil} from '@workday/canvas-kit-styling';
|
|
19
|
+
import {system} from '@workday/canvas-tokens-web';
|
|
20
|
+
import {mergeStyles} from '@workday/canvas-kit-react/layout';
|
|
18
21
|
|
|
19
|
-
export interface ComboboxMenuItemProps {
|
|
20
|
-
children: React.ReactNode;
|
|
21
|
-
}
|
|
22
|
+
export interface ComboboxMenuItemProps extends ExtractProps<typeof StyledMenuItem, never> {}
|
|
22
23
|
|
|
23
24
|
/**
|
|
24
25
|
* This hook sets up accessibility and behavior of a {@link ComboboxMenuItem Combobox.Menu.Item}
|
|
@@ -57,17 +58,34 @@ export const useComboboxMenuItem = composeHooks(
|
|
|
57
58
|
useListItemRegister,
|
|
58
59
|
useListItemAllowChildStrings
|
|
59
60
|
);
|
|
61
|
+
const comboboxMenuItemIconStencil = createStencil({
|
|
62
|
+
base: {
|
|
63
|
+
alignSelf: 'start',
|
|
64
|
+
},
|
|
65
|
+
});
|
|
66
|
+
|
|
67
|
+
export const ComboboxMenuItemIcon = createSubcomponent('span')({
|
|
68
|
+
modelHook: useComboboxModel,
|
|
69
|
+
})<ExtractProps<typeof SystemIcon>>((elemProps, Element) => {
|
|
70
|
+
return <SystemIcon as={Element} {...mergeStyles(elemProps, comboboxMenuItemIconStencil())} />;
|
|
71
|
+
});
|
|
72
|
+
|
|
73
|
+
const comboboxMenuItemStencil = createStencil({
|
|
74
|
+
base: {
|
|
75
|
+
minHeight: system.space.x10,
|
|
76
|
+
},
|
|
77
|
+
});
|
|
60
78
|
|
|
61
79
|
export const ComboboxMenuItem = createSubcomponent('li')({
|
|
62
80
|
modelHook: useComboboxModel,
|
|
63
81
|
elemPropsHook: useComboboxMenuItem,
|
|
64
82
|
subComponents: {
|
|
65
|
-
Icon:
|
|
83
|
+
Icon: ComboboxMenuItemIcon,
|
|
66
84
|
},
|
|
67
85
|
})<ComboboxMenuItemProps>(({children, ...elemProps}, Element) => {
|
|
68
86
|
return (
|
|
69
87
|
<OverflowTooltip placement="left">
|
|
70
|
-
<StyledMenuItem
|
|
88
|
+
<StyledMenuItem as={Element} {...mergeStyles(elemProps, comboboxMenuItemStencil())}>
|
|
71
89
|
{children}
|
|
72
90
|
</StyledMenuItem>
|
|
73
91
|
</OverflowTooltip>
|
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
|
|
3
|
-
import {commonColors} from '@workday/canvas-kit-react/tokens';
|
|
4
3
|
import {createElemPropsHook, createSubcomponent} from '@workday/canvas-kit-react/common';
|
|
5
|
-
import {useMenuModel} from '@workday/canvas-kit-react/menu';
|
|
4
|
+
import {useMenuModel, menuListStencil} from '@workday/canvas-kit-react/menu';
|
|
6
5
|
import {ListBox, ListBoxProps} from '@workday/canvas-kit-react/collection';
|
|
6
|
+
import {system} from '@workday/canvas-tokens-web';
|
|
7
7
|
|
|
8
8
|
import {useComboboxModel} from './hooks/useComboboxModel';
|
|
9
|
+
import {createStencil, cssVar} from '@workday/canvas-kit-styling';
|
|
10
|
+
import {mergeStyles} from '@workday/canvas-kit-react/layout';
|
|
9
11
|
|
|
10
12
|
export interface ComboboxMenuListProps<T = any> extends ListBoxProps<T> {}
|
|
11
13
|
|
|
@@ -19,10 +21,14 @@ export const useComboboxMenuList = createElemPropsHook(useMenuModel)(model => {
|
|
|
19
21
|
role: 'listbox',
|
|
20
22
|
'aria-labelledby': model.state.id,
|
|
21
23
|
id: `${model.state.id}-list`,
|
|
22
|
-
flexDirection: model.state.orientation === 'vertical' ? 'column' : 'row',
|
|
23
24
|
} as const;
|
|
24
25
|
});
|
|
25
26
|
|
|
27
|
+
const comoboxMenuListStencil = createStencil({
|
|
28
|
+
base: {},
|
|
29
|
+
extends: menuListStencil,
|
|
30
|
+
});
|
|
31
|
+
|
|
26
32
|
export const ComboboxMenuList = createSubcomponent('ul')({
|
|
27
33
|
modelHook: useComboboxModel,
|
|
28
34
|
elemPropsHook: useComboboxMenuList,
|
|
@@ -31,13 +37,8 @@ export const ComboboxMenuList = createSubcomponent('ul')({
|
|
|
31
37
|
<ListBox
|
|
32
38
|
as={Element}
|
|
33
39
|
model={model}
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
padding="zero"
|
|
37
|
-
marginY="xxs"
|
|
38
|
-
gap="zero"
|
|
39
|
-
overflowY="auto"
|
|
40
|
-
{...elemProps}
|
|
40
|
+
marginY={cssVar(system.space.x2)}
|
|
41
|
+
{...mergeStyles(elemProps, comoboxMenuListStencil({orientation: model.state.orientation}))}
|
|
41
42
|
>
|
|
42
43
|
{children}
|
|
43
44
|
</ListBox>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ListBox.d.ts","sourceRoot":"","sources":["../../../../collection/lib/ListBox.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAIL,YAAY,EACb,MAAM,kCAAkC,CAAC;AAC1C,OAAO,EAAM,IAAI,
|
|
1
|
+
{"version":3,"file":"ListBox.d.ts","sourceRoot":"","sources":["../../../../collection/lib/ListBox.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAIL,YAAY,EACb,MAAM,kCAAkC,CAAC;AAC1C,OAAO,EAAM,IAAI,EAAc,MAAM,kCAAkC,CAAC;AAQxE,MAAM,WAAW,YAAY,CAAC,CAAC,GAAG,GAAG,CAAE,SAAQ,IAAI,CAAC,YAAY,CAAC,OAAO,IAAI,EAAE,KAAK,CAAC,EAAE,UAAU,CAAC;IAC/F,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,GAAG,CAAC,CAAC,IAAI,EAAE,CAAC,EAAE,KAAK,EAAE,MAAM,KAAK,KAAK,CAAC,SAAS,CAAC,CAAC;CAC5E;AAED,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAMtB,CAAC;AAEH,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAOrB,CAAC;AA0BH;;;;;;;;;;;;;;;;GAgBG;AACH,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAKhB;;;;;;;;OAQG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAyBN,CAAC"}
|
|
@@ -7,6 +7,8 @@ exports.ListBox = exports.useListBox = exports.ListBoxItem = void 0;
|
|
|
7
7
|
const react_1 = __importDefault(require("react"));
|
|
8
8
|
const common_1 = require("@workday/canvas-kit-react/common");
|
|
9
9
|
const layout_1 = require("@workday/canvas-kit-react/layout");
|
|
10
|
+
const canvas_kit_styling_1 = require("@workday/canvas-kit-styling");
|
|
11
|
+
const canvas_tokens_web_1 = require("@workday/canvas-tokens-web");
|
|
10
12
|
const useListModel_1 = require("./useListModel");
|
|
11
13
|
const useListRenderItem_1 = require("./useListRenderItem");
|
|
12
14
|
const useListItemRegister_1 = require("./useListItemRegister");
|
|
@@ -25,6 +27,18 @@ exports.useListBox = common_1.createElemPropsHook(useListModel_1.useListModel)(m
|
|
|
25
27
|
},
|
|
26
28
|
};
|
|
27
29
|
});
|
|
30
|
+
const listBoxContainerStencil = canvas_kit_styling_1.createStencil({
|
|
31
|
+
base: { name: "roynbj", styles: "box-sizing:border-box;" },
|
|
32
|
+
modifiers: {
|
|
33
|
+
modifiers: {
|
|
34
|
+
vertical: { name: "13v3rg8", styles: "overflow-y:auto;" },
|
|
35
|
+
horizontal: { name: "mru7yp", styles: "overflow-y:undefined;" }
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
}, "list-box-container");
|
|
39
|
+
const listBoxStencil = canvas_kit_styling_1.createStencil({
|
|
40
|
+
base: { name: "1rhzmpl", styles: "flex-direction:column;margin-top:var(--cnvs-sys-space-zero, 0);margin-bottom:var(--cnvs-sys-space-zero, 0);" }
|
|
41
|
+
}, "list-box");
|
|
28
42
|
/**
|
|
29
43
|
* The `ListBox` component that offers vertical rendering of a collection in the form of a
|
|
30
44
|
* 2-dimension list. It supports virtualization, rendering only visible items in the DOM while also
|
|
@@ -58,10 +72,9 @@ exports.ListBox = common_1.createContainer('ul')({
|
|
|
58
72
|
*/
|
|
59
73
|
Item: exports.ListBoxItem,
|
|
60
74
|
},
|
|
61
|
-
})(({ height, maxHeight, marginY, ...elemProps }, Element, model) => {
|
|
62
|
-
// We're
|
|
75
|
+
})(({ height, maxHeight, marginY, marginBottom, overflowY, marginTop, ...elemProps }, Element, model) => {
|
|
76
|
+
// We're removing `marginY, marginBottom, overflowY, marginTo` from elemProps and applying them to the container as to not interfere with the virtualization size. We set
|
|
63
77
|
// the `marginY` on the Flex to `0` to avoid inaccurate scrollbars
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
react_1.default.createElement(layout_1.Flex, Object.assign({ as: Element, flexDirection: "column" }, elemProps, { marginY: 0 }), useListRenderItem_1.useListRenderItems(model, elemProps.children))));
|
|
78
|
+
return (react_1.default.createElement("div", Object.assign({ ref: model.state.containerRef }, layout_1.mergeStyles({ maxHeight, marginBottom: marginY, marginTop: marginY }, listBoxContainerStencil({ orientation: model.state.orientation }))),
|
|
79
|
+
react_1.default.createElement(layout_1.Flex, Object.assign({ as: Element }, layout_1.mergeStyles(elemProps, listBoxStencil())), useListRenderItem_1.useListRenderItems(model, elemProps.children))));
|
|
67
80
|
});
|
|
@@ -1992,11 +1992,83 @@ export declare const Combobox: import("@workday/canvas-kit-react/common").Compon
|
|
|
1992
1992
|
navigation: import("../../collection/lib/useCursorListModel").NavigationManager;
|
|
1993
1993
|
getId: (item: any) => string;
|
|
1994
1994
|
}> & {
|
|
1995
|
-
Icon: import("@
|
|
1996
|
-
|
|
1997
|
-
|
|
1998
|
-
|
|
1999
|
-
|
|
1995
|
+
Icon: import("@workday/canvas-kit-react/common").ElementComponentM<"span", import("../..").SystemIconProps & React.HTMLAttributes<HTMLSpanElement>, {
|
|
1996
|
+
state: {
|
|
1997
|
+
stackRef: React.RefObject<HTMLDivElement>;
|
|
1998
|
+
targetRef: React.RefObject<HTMLButtonElement>;
|
|
1999
|
+
initialFocusRef: React.RefObject<any> | undefined;
|
|
2000
|
+
returnFocusRef: React.RefObject<any> | undefined;
|
|
2001
|
+
placement: import("@popperjs/core").Placement;
|
|
2002
|
+
id: string;
|
|
2003
|
+
visibility: "hidden" | "visible";
|
|
2004
|
+
selectedIds: string[] | "all";
|
|
2005
|
+
unselectedIds: string[];
|
|
2006
|
+
cursorId: string;
|
|
2007
|
+
columnCount: number;
|
|
2008
|
+
pageSizeRef: React.MutableRefObject<number>;
|
|
2009
|
+
cursorIndexRef: {
|
|
2010
|
+
readonly current: number;
|
|
2011
|
+
};
|
|
2012
|
+
UNSTABLE_virtual: {
|
|
2013
|
+
virtualItems: import("../../collection/lib/react-virtual").VirtualItem[];
|
|
2014
|
+
totalSize: number;
|
|
2015
|
+
scrollToOffset: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToOffsetOptions | undefined) => void;
|
|
2016
|
+
scrollToIndex: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToIndexOptions | undefined) => void;
|
|
2017
|
+
measure: () => void;
|
|
2018
|
+
};
|
|
2019
|
+
UNSTABLE_defaultItemHeight: number;
|
|
2020
|
+
containerRef: React.RefObject<HTMLDivElement>;
|
|
2021
|
+
orientation: "horizontal" | "vertical";
|
|
2022
|
+
indexRef: React.MutableRefObject<number>;
|
|
2023
|
+
nonInteractiveIds: string[];
|
|
2024
|
+
isVirtualized: boolean;
|
|
2025
|
+
items: import("../..").Item<any>[];
|
|
2026
|
+
mode: "multiple" | "single";
|
|
2027
|
+
value: string | undefined;
|
|
2028
|
+
inputRef: React.RefObject<HTMLInputElement>;
|
|
2029
|
+
width: number;
|
|
2030
|
+
};
|
|
2031
|
+
events: {
|
|
2032
|
+
setWidth(width: number): void;
|
|
2033
|
+
updatePlacement(data: {
|
|
2034
|
+
placement: import("@popperjs/core").Placement;
|
|
2035
|
+
}): void;
|
|
2036
|
+
show(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
|
|
2037
|
+
hide(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
|
|
2038
|
+
select(data: {
|
|
2039
|
+
id: string;
|
|
2040
|
+
}): void;
|
|
2041
|
+
selectAll(): void;
|
|
2042
|
+
unselectAll(): void;
|
|
2043
|
+
goTo(data: {
|
|
2044
|
+
id: string;
|
|
2045
|
+
}): void;
|
|
2046
|
+
goToNext(): void;
|
|
2047
|
+
goToPrevious(): void;
|
|
2048
|
+
goToPreviousRow(): void;
|
|
2049
|
+
goToNextRow(): void;
|
|
2050
|
+
goToFirst(): void;
|
|
2051
|
+
goToLast(): void;
|
|
2052
|
+
goToFirstOfRow(): void;
|
|
2053
|
+
goToLastOfRow(): void;
|
|
2054
|
+
goToNextPage(): void;
|
|
2055
|
+
goToPreviousPage(): void;
|
|
2056
|
+
registerItem(data: {
|
|
2057
|
+
item: any;
|
|
2058
|
+
textValue: string;
|
|
2059
|
+
}): void;
|
|
2060
|
+
unregisterItem(data: {
|
|
2061
|
+
id: string;
|
|
2062
|
+
}): void;
|
|
2063
|
+
updateItemHeight(data: {
|
|
2064
|
+
value: number;
|
|
2065
|
+
}): void;
|
|
2066
|
+
};
|
|
2067
|
+
onChange: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
2068
|
+
selection: import("../../collection/lib/useSelectionListModel").SelectionManager;
|
|
2069
|
+
navigation: import("../../collection/lib/useCursorListModel").NavigationManager;
|
|
2070
|
+
getId: (item: any) => string;
|
|
2071
|
+
}>;
|
|
2000
2072
|
};
|
|
2001
2073
|
Card: import("@workday/canvas-kit-react/common").ElementComponentM<"div", import("./ComboboxCard").ComboboxCardProps, {
|
|
2002
2074
|
state: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Combobox.d.ts","sourceRoot":"","sources":["../../../../combobox/lib/Combobox.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAO1B,MAAM,WAAW,aAAa;IAC5B;;OAEG;IACH,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B;AAED,eAAO,MAAM,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAIjB;;;OAGG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAEH;;;OAGG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAKL,CAAC"}
|
|
@@ -341,11 +341,83 @@ export declare const ComboboxMenu: import("@workday/canvas-kit-react/common").El
|
|
|
341
341
|
navigation: import("../../collection/lib/useCursorListModel").NavigationManager;
|
|
342
342
|
getId: (item: any) => string;
|
|
343
343
|
}> & {
|
|
344
|
-
Icon: import("@
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
344
|
+
Icon: import("@workday/canvas-kit-react/common").ElementComponentM<"span", import("../..").SystemIconProps & React.HTMLAttributes<HTMLSpanElement>, {
|
|
345
|
+
state: {
|
|
346
|
+
stackRef: React.RefObject<HTMLDivElement>;
|
|
347
|
+
targetRef: React.RefObject<HTMLButtonElement>;
|
|
348
|
+
initialFocusRef: React.RefObject<any> | undefined;
|
|
349
|
+
returnFocusRef: React.RefObject<any> | undefined;
|
|
350
|
+
placement: import("@popperjs/core").Placement;
|
|
351
|
+
id: string;
|
|
352
|
+
visibility: "hidden" | "visible";
|
|
353
|
+
selectedIds: string[] | "all";
|
|
354
|
+
unselectedIds: string[];
|
|
355
|
+
cursorId: string;
|
|
356
|
+
columnCount: number;
|
|
357
|
+
pageSizeRef: React.MutableRefObject<number>;
|
|
358
|
+
cursorIndexRef: {
|
|
359
|
+
readonly current: number;
|
|
360
|
+
};
|
|
361
|
+
UNSTABLE_virtual: {
|
|
362
|
+
virtualItems: import("../../collection/lib/react-virtual").VirtualItem[];
|
|
363
|
+
totalSize: number;
|
|
364
|
+
scrollToOffset: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToOffsetOptions | undefined) => void;
|
|
365
|
+
scrollToIndex: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToIndexOptions | undefined) => void;
|
|
366
|
+
measure: () => void;
|
|
367
|
+
};
|
|
368
|
+
UNSTABLE_defaultItemHeight: number;
|
|
369
|
+
containerRef: React.RefObject<HTMLDivElement>;
|
|
370
|
+
orientation: "horizontal" | "vertical";
|
|
371
|
+
indexRef: React.MutableRefObject<number>;
|
|
372
|
+
nonInteractiveIds: string[];
|
|
373
|
+
isVirtualized: boolean;
|
|
374
|
+
items: import("../..").Item<any>[];
|
|
375
|
+
mode: "multiple" | "single";
|
|
376
|
+
value: string | undefined;
|
|
377
|
+
inputRef: React.RefObject<HTMLInputElement>;
|
|
378
|
+
width: number;
|
|
379
|
+
};
|
|
380
|
+
events: {
|
|
381
|
+
setWidth(width: number): void;
|
|
382
|
+
updatePlacement(data: {
|
|
383
|
+
placement: import("@popperjs/core").Placement;
|
|
384
|
+
}): void;
|
|
385
|
+
show(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
|
|
386
|
+
hide(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
|
|
387
|
+
select(data: {
|
|
388
|
+
id: string;
|
|
389
|
+
}): void;
|
|
390
|
+
selectAll(): void;
|
|
391
|
+
unselectAll(): void;
|
|
392
|
+
goTo(data: {
|
|
393
|
+
id: string;
|
|
394
|
+
}): void;
|
|
395
|
+
goToNext(): void;
|
|
396
|
+
goToPrevious(): void;
|
|
397
|
+
goToPreviousRow(): void;
|
|
398
|
+
goToNextRow(): void;
|
|
399
|
+
goToFirst(): void;
|
|
400
|
+
goToLast(): void;
|
|
401
|
+
goToFirstOfRow(): void;
|
|
402
|
+
goToLastOfRow(): void;
|
|
403
|
+
goToNextPage(): void;
|
|
404
|
+
goToPreviousPage(): void;
|
|
405
|
+
registerItem(data: {
|
|
406
|
+
item: any;
|
|
407
|
+
textValue: string;
|
|
408
|
+
}): void;
|
|
409
|
+
unregisterItem(data: {
|
|
410
|
+
id: string;
|
|
411
|
+
}): void;
|
|
412
|
+
updateItemHeight(data: {
|
|
413
|
+
value: number;
|
|
414
|
+
}): void;
|
|
415
|
+
};
|
|
416
|
+
onChange: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
417
|
+
selection: import("../../collection/lib/useSelectionListModel").SelectionManager;
|
|
418
|
+
navigation: import("../../collection/lib/useCursorListModel").NavigationManager;
|
|
419
|
+
getId: (item: any) => string;
|
|
420
|
+
}>;
|
|
349
421
|
};
|
|
350
422
|
/**
|
|
351
423
|
* `Combobox.Menu.Card` is a non-semantic element used to give the dropdown menu its distinct visual
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ComboboxMenu.d.ts","sourceRoot":"","sources":["../../../../combobox/lib/ComboboxMenu.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAW1B,MAAM,WAAW,iBAAiB;IAChC;;OAEG;IACH,QAAQ,E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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAML,CAAC"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
import { ExtractProps } from '@workday/canvas-kit-react/common';
|
|
3
|
+
import { StyledMenuItem } from '@workday/canvas-kit-react/menu';
|
|
4
|
+
export interface ComboboxMenuItemProps extends ExtractProps<typeof StyledMenuItem, never> {
|
|
4
5
|
}
|
|
5
6
|
/**
|
|
6
7
|
* This hook sets up accessibility and behavior of a {@link ComboboxMenuItem Combobox.Menu.Item}
|
|
@@ -98,6 +99,83 @@ export declare const useComboboxMenuItem: import("@workday/canvas-kit-react/comm
|
|
|
98
99
|
} & {
|
|
99
100
|
'data-id'?: string | undefined;
|
|
100
101
|
}>;
|
|
102
|
+
export declare const ComboboxMenuItemIcon: import("@workday/canvas-kit-react/common").ElementComponentM<"span", import("@workday/canvas-kit-react/icon").SystemIconProps & React.HTMLAttributes<HTMLSpanElement>, {
|
|
103
|
+
state: {
|
|
104
|
+
stackRef: React.RefObject<HTMLDivElement>;
|
|
105
|
+
targetRef: React.RefObject<HTMLButtonElement>;
|
|
106
|
+
initialFocusRef: React.RefObject<any> | undefined;
|
|
107
|
+
returnFocusRef: React.RefObject<any> | undefined;
|
|
108
|
+
placement: import("@popperjs/core").Placement;
|
|
109
|
+
id: string;
|
|
110
|
+
visibility: "hidden" | "visible";
|
|
111
|
+
selectedIds: string[] | "all";
|
|
112
|
+
unselectedIds: string[];
|
|
113
|
+
cursorId: string;
|
|
114
|
+
columnCount: number;
|
|
115
|
+
pageSizeRef: React.MutableRefObject<number>;
|
|
116
|
+
cursorIndexRef: {
|
|
117
|
+
readonly current: number;
|
|
118
|
+
};
|
|
119
|
+
UNSTABLE_virtual: {
|
|
120
|
+
virtualItems: import("../../collection/lib/react-virtual").VirtualItem[];
|
|
121
|
+
totalSize: number;
|
|
122
|
+
scrollToOffset: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToOffsetOptions | undefined) => void;
|
|
123
|
+
scrollToIndex: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToIndexOptions | undefined) => void;
|
|
124
|
+
measure: () => void;
|
|
125
|
+
};
|
|
126
|
+
UNSTABLE_defaultItemHeight: number;
|
|
127
|
+
containerRef: React.RefObject<HTMLDivElement>;
|
|
128
|
+
orientation: "horizontal" | "vertical";
|
|
129
|
+
indexRef: React.MutableRefObject<number>;
|
|
130
|
+
nonInteractiveIds: string[];
|
|
131
|
+
isVirtualized: boolean;
|
|
132
|
+
items: import("@workday/canvas-kit-react/collection").Item<any>[];
|
|
133
|
+
mode: "multiple" | "single";
|
|
134
|
+
value: string | undefined;
|
|
135
|
+
inputRef: React.RefObject<HTMLInputElement>;
|
|
136
|
+
width: number;
|
|
137
|
+
};
|
|
138
|
+
events: {
|
|
139
|
+
setWidth(width: number): void;
|
|
140
|
+
updatePlacement(data: {
|
|
141
|
+
placement: import("@popperjs/core").Placement;
|
|
142
|
+
}): void;
|
|
143
|
+
show(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
|
|
144
|
+
hide(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
|
|
145
|
+
select(data: {
|
|
146
|
+
id: string;
|
|
147
|
+
}): void;
|
|
148
|
+
selectAll(): void;
|
|
149
|
+
unselectAll(): void;
|
|
150
|
+
goTo(data: {
|
|
151
|
+
id: string;
|
|
152
|
+
}): void;
|
|
153
|
+
goToNext(): void;
|
|
154
|
+
goToPrevious(): void;
|
|
155
|
+
goToPreviousRow(): void;
|
|
156
|
+
goToNextRow(): void;
|
|
157
|
+
goToFirst(): void;
|
|
158
|
+
goToLast(): void;
|
|
159
|
+
goToFirstOfRow(): void;
|
|
160
|
+
goToLastOfRow(): void;
|
|
161
|
+
goToNextPage(): void;
|
|
162
|
+
goToPreviousPage(): void;
|
|
163
|
+
registerItem(data: {
|
|
164
|
+
item: any;
|
|
165
|
+
textValue: string;
|
|
166
|
+
}): void;
|
|
167
|
+
unregisterItem(data: {
|
|
168
|
+
id: string;
|
|
169
|
+
}): void;
|
|
170
|
+
updateItemHeight(data: {
|
|
171
|
+
value: number;
|
|
172
|
+
}): void;
|
|
173
|
+
};
|
|
174
|
+
onChange: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
175
|
+
selection: import("../../collection/lib/useSelectionListModel").SelectionManager;
|
|
176
|
+
navigation: import("../../collection/lib/useCursorListModel").NavigationManager;
|
|
177
|
+
getId: (item: any) => string;
|
|
178
|
+
}>;
|
|
101
179
|
export declare const ComboboxMenuItem: import("@workday/canvas-kit-react/common").ElementComponentM<"li", ComboboxMenuItemProps, {
|
|
102
180
|
state: {
|
|
103
181
|
stackRef: React.RefObject<HTMLDivElement>;
|
|
@@ -175,10 +253,82 @@ export declare const ComboboxMenuItem: import("@workday/canvas-kit-react/common"
|
|
|
175
253
|
navigation: import("../../collection/lib/useCursorListModel").NavigationManager;
|
|
176
254
|
getId: (item: any) => string;
|
|
177
255
|
}> & {
|
|
178
|
-
Icon: import("@
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
256
|
+
Icon: import("@workday/canvas-kit-react/common").ElementComponentM<"span", import("@workday/canvas-kit-react/icon").SystemIconProps & React.HTMLAttributes<HTMLSpanElement>, {
|
|
257
|
+
state: {
|
|
258
|
+
stackRef: React.RefObject<HTMLDivElement>;
|
|
259
|
+
targetRef: React.RefObject<HTMLButtonElement>;
|
|
260
|
+
initialFocusRef: React.RefObject<any> | undefined;
|
|
261
|
+
returnFocusRef: React.RefObject<any> | undefined;
|
|
262
|
+
placement: import("@popperjs/core").Placement;
|
|
263
|
+
id: string;
|
|
264
|
+
visibility: "hidden" | "visible";
|
|
265
|
+
selectedIds: string[] | "all";
|
|
266
|
+
unselectedIds: string[];
|
|
267
|
+
cursorId: string;
|
|
268
|
+
columnCount: number;
|
|
269
|
+
pageSizeRef: React.MutableRefObject<number>;
|
|
270
|
+
cursorIndexRef: {
|
|
271
|
+
readonly current: number;
|
|
272
|
+
};
|
|
273
|
+
UNSTABLE_virtual: {
|
|
274
|
+
virtualItems: import("../../collection/lib/react-virtual").VirtualItem[];
|
|
275
|
+
totalSize: number;
|
|
276
|
+
scrollToOffset: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToOffsetOptions | undefined) => void;
|
|
277
|
+
scrollToIndex: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToIndexOptions | undefined) => void;
|
|
278
|
+
measure: () => void;
|
|
279
|
+
};
|
|
280
|
+
UNSTABLE_defaultItemHeight: number;
|
|
281
|
+
containerRef: React.RefObject<HTMLDivElement>;
|
|
282
|
+
orientation: "horizontal" | "vertical";
|
|
283
|
+
indexRef: React.MutableRefObject<number>;
|
|
284
|
+
nonInteractiveIds: string[];
|
|
285
|
+
isVirtualized: boolean;
|
|
286
|
+
items: import("@workday/canvas-kit-react/collection").Item<any>[];
|
|
287
|
+
mode: "multiple" | "single";
|
|
288
|
+
value: string | undefined;
|
|
289
|
+
inputRef: React.RefObject<HTMLInputElement>;
|
|
290
|
+
width: number;
|
|
291
|
+
};
|
|
292
|
+
events: {
|
|
293
|
+
setWidth(width: number): void;
|
|
294
|
+
updatePlacement(data: {
|
|
295
|
+
placement: import("@popperjs/core").Placement;
|
|
296
|
+
}): void;
|
|
297
|
+
show(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
|
|
298
|
+
hide(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
|
|
299
|
+
select(data: {
|
|
300
|
+
id: string;
|
|
301
|
+
}): void;
|
|
302
|
+
selectAll(): void;
|
|
303
|
+
unselectAll(): void;
|
|
304
|
+
goTo(data: {
|
|
305
|
+
id: string;
|
|
306
|
+
}): void;
|
|
307
|
+
goToNext(): void;
|
|
308
|
+
goToPrevious(): void;
|
|
309
|
+
goToPreviousRow(): void;
|
|
310
|
+
goToNextRow(): void;
|
|
311
|
+
goToFirst(): void;
|
|
312
|
+
goToLast(): void;
|
|
313
|
+
goToFirstOfRow(): void;
|
|
314
|
+
goToLastOfRow(): void;
|
|
315
|
+
goToNextPage(): void;
|
|
316
|
+
goToPreviousPage(): void;
|
|
317
|
+
registerItem(data: {
|
|
318
|
+
item: any;
|
|
319
|
+
textValue: string;
|
|
320
|
+
}): void;
|
|
321
|
+
unregisterItem(data: {
|
|
322
|
+
id: string;
|
|
323
|
+
}): void;
|
|
324
|
+
updateItemHeight(data: {
|
|
325
|
+
value: number;
|
|
326
|
+
}): void;
|
|
327
|
+
};
|
|
328
|
+
onChange: (event: React.ChangeEvent<HTMLInputElement>) => void;
|
|
329
|
+
selection: import("../../collection/lib/useSelectionListModel").SelectionManager;
|
|
330
|
+
navigation: import("../../collection/lib/useCursorListModel").NavigationManager;
|
|
331
|
+
getId: (item: any) => string;
|
|
332
|
+
}>;
|
|
183
333
|
};
|
|
184
334
|
//# sourceMappingURL=ComboboxMenuItem.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ComboboxMenuItem.d.ts","sourceRoot":"","sources":["../../../../combobox/lib/ComboboxMenuItem.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"ComboboxMenuItem.d.ts","sourceRoot":"","sources":["../../../../combobox/lib/ComboboxMenuItem.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAIL,YAAY,EACb,MAAM,kCAAkC,CAAC;AAC1C,OAAO,EAAC,cAAc,EAAe,MAAM,gCAAgC,CAAC;AAa5E,MAAM,WAAW,qBAAsB,SAAQ,YAAY,CAAC,OAAO,cAAc,EAAE,KAAK,CAAC;CAAG;AAE5F;;;;;;GAMG;AACH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kCAIA,gBAAgB,CAAC,WAAW,CAAC;;;;;;;;;;;;;;EAyB5D,CAAC;AAOF,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAI/B,CAAC;AAQH,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAc3B,CAAC"}
|