@workday/canvas-kit-react 7.1.2 → 7.1.3
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/action-bar/lib/ActionBarList.tsx +2 -9
- package/dist/commonjs/action-bar/lib/ActionBarList.d.ts +0 -58
- package/dist/commonjs/action-bar/lib/ActionBarList.d.ts.map +1 -1
- package/dist/commonjs/action-bar/lib/ActionBarList.js +2 -3
- package/dist/es6/action-bar/lib/ActionBarList.d.ts +0 -58
- package/dist/es6/action-bar/lib/ActionBarList.d.ts.map +1 -1
- package/dist/es6/action-bar/lib/ActionBarList.js +3 -4
- package/package.json +5 -5
|
@@ -2,18 +2,13 @@ import * as React from 'react';
|
|
|
2
2
|
|
|
3
3
|
import {commonColors, colors, space} from '@workday/canvas-kit-react/tokens';
|
|
4
4
|
import {
|
|
5
|
-
composeHooks,
|
|
6
5
|
createSubcomponent,
|
|
7
6
|
ExtractProps,
|
|
8
7
|
styled,
|
|
9
8
|
StyledType,
|
|
10
9
|
} from '@workday/canvas-kit-react/common';
|
|
11
10
|
import {HStack} from '@workday/canvas-kit-react/layout';
|
|
12
|
-
import {
|
|
13
|
-
useOverflowListMeasure,
|
|
14
|
-
useListRenderItems,
|
|
15
|
-
useListResetCursorOnBlur,
|
|
16
|
-
} from '@workday/canvas-kit-react/collection';
|
|
11
|
+
import {useOverflowListMeasure, useListRenderItems} from '@workday/canvas-kit-react/collection';
|
|
17
12
|
|
|
18
13
|
import {useActionBarModel} from './useActionBarModel';
|
|
19
14
|
import {ActionBar} from './ActionBar';
|
|
@@ -42,12 +37,10 @@ const ResponsiveHStack = styled(HStack)<ActionBarListProps & StyledType>(({theme
|
|
|
42
37
|
},
|
|
43
38
|
}));
|
|
44
39
|
|
|
45
|
-
export const useActionBarList = composeHooks(useOverflowListMeasure, useListResetCursorOnBlur);
|
|
46
|
-
|
|
47
40
|
export const ActionBarList = createSubcomponent('div')({
|
|
48
41
|
displayName: 'ActionBar.List',
|
|
49
42
|
modelHook: useActionBarModel,
|
|
50
|
-
elemPropsHook:
|
|
43
|
+
elemPropsHook: useOverflowListMeasure,
|
|
51
44
|
})<ActionBarListProps>(({children, ...elemProps}, Element, model) => {
|
|
52
45
|
return (
|
|
53
46
|
<ResponsiveHStack
|
|
@@ -13,64 +13,6 @@ export interface ActionBarListProps<T = unknown> extends Partial<ExtractProps<ty
|
|
|
13
13
|
*/
|
|
14
14
|
children: ((item: T) => React.ReactNode) | React.ReactNode;
|
|
15
15
|
}
|
|
16
|
-
export declare const useActionBarList: <P extends {}, R>(model: {
|
|
17
|
-
state: {
|
|
18
|
-
selectedIds: import("../../collection/lib/useSelectionListModel").SelectedIds;
|
|
19
|
-
unselectedIds: string[];
|
|
20
|
-
cursorId: string;
|
|
21
|
-
columnCount: number;
|
|
22
|
-
UNSTABLE_virtual: {
|
|
23
|
-
virtualItems: import("../../collection/lib/react-virtual").VirtualItem[];
|
|
24
|
-
totalSize: number;
|
|
25
|
-
scrollToOffset: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToOffsetOptions | undefined) => void;
|
|
26
|
-
scrollToIndex: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToIndexOptions | undefined) => void;
|
|
27
|
-
measure: () => void;
|
|
28
|
-
};
|
|
29
|
-
UNSTABLE_defaultItemHeight: number;
|
|
30
|
-
containerRef: React.RefObject<HTMLDivElement>;
|
|
31
|
-
id: string;
|
|
32
|
-
orientation: import("../../collection/lib/useBaseListModel").Orientation;
|
|
33
|
-
indexRef: React.MutableRefObject<number>;
|
|
34
|
-
nonInteractiveIds: string[];
|
|
35
|
-
isVirtualized: boolean;
|
|
36
|
-
items: import("../../collection").Item<any>[];
|
|
37
|
-
};
|
|
38
|
-
events: {
|
|
39
|
-
select(data: {
|
|
40
|
-
id: string;
|
|
41
|
-
}): void;
|
|
42
|
-
selectAll(): void;
|
|
43
|
-
unselectAll(): void;
|
|
44
|
-
registerItem(data: {
|
|
45
|
-
item: any;
|
|
46
|
-
textValue: string;
|
|
47
|
-
}): void;
|
|
48
|
-
goTo(data: {
|
|
49
|
-
id: string;
|
|
50
|
-
}): void;
|
|
51
|
-
goToNext(): void;
|
|
52
|
-
goToPrevious(): void;
|
|
53
|
-
goToPreviousRow(): void;
|
|
54
|
-
goToNextRow(): void;
|
|
55
|
-
goToFirst(): void;
|
|
56
|
-
goToLast(): void;
|
|
57
|
-
goToFirstOfRow(): void;
|
|
58
|
-
goToLastOfRow(): void;
|
|
59
|
-
goToNextPage(): void;
|
|
60
|
-
goToPreviousPage(): void;
|
|
61
|
-
unregisterItem(data: {
|
|
62
|
-
id: string;
|
|
63
|
-
}): void;
|
|
64
|
-
updateItemHeight(data: {
|
|
65
|
-
value: number;
|
|
66
|
-
}): void;
|
|
67
|
-
};
|
|
68
|
-
selection: import("../../collection/lib/useSelectionListModel").SelectionManager;
|
|
69
|
-
navigation: import("../../collection/lib/useCursorListModel").NavigationManager;
|
|
70
|
-
getId: (item: any) => string;
|
|
71
|
-
}, elemProps?: P | undefined, ref?: ((instance: R | null) => void) | React.RefObject<R> | null | undefined) => {} & P & (R extends HTMLOrSVGElement ? {
|
|
72
|
-
ref: React.Ref<R>;
|
|
73
|
-
} : {});
|
|
74
16
|
export declare const ActionBarList: import("../../common").ElementComponentM<"div", ActionBarListProps<unknown>, {
|
|
75
17
|
state: {
|
|
76
18
|
hiddenIds: string[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ActionBarList.d.ts","sourceRoot":"","sources":["../../../../action-bar/lib/ActionBarList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B,OAAO,
|
|
1
|
+
{"version":3,"file":"ActionBarList.d.ts","sourceRoot":"","sources":["../../../../action-bar/lib/ActionBarList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B,OAAO,EAEL,YAAY,EAGb,MAAM,kCAAkC,CAAC;AAC1C,OAAO,EAAC,MAAM,EAAC,MAAM,kCAAkC,CAAC;AAOxD,MAAM,WAAW,kBAAkB,CAAC,CAAC,GAAG,OAAO,CAC7C,SAAQ,OAAO,CAAC,YAAY,CAAC,OAAO,MAAM,EAAE,KAAK,CAAC,CAAC;IACnD;;;;;;;;OAQG;IACH,QAAQ,EAAE,CAAC,CAAC,IAAI,EAAE,CAAC,KAAK,KAAK,CAAC,SAAS,CAAC,GAAG,KAAK,CAAC,SAAS,CAAC;CAC5D;AAWD,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAuBxB,CAAC"}
|
|
@@ -41,7 +41,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
41
41
|
return t;
|
|
42
42
|
};
|
|
43
43
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
44
|
-
exports.ActionBarList =
|
|
44
|
+
exports.ActionBarList = void 0;
|
|
45
45
|
var React = __importStar(require("react"));
|
|
46
46
|
var tokens_1 = require("@workday/canvas-kit-react/tokens");
|
|
47
47
|
var common_1 = require("@workday/canvas-kit-react/common");
|
|
@@ -61,11 +61,10 @@ var ResponsiveHStack = common_1.styled(layout_1.HStack)(function (_a) {
|
|
|
61
61
|
},
|
|
62
62
|
_b);
|
|
63
63
|
});
|
|
64
|
-
exports.useActionBarList = common_1.composeHooks(collection_1.useOverflowListMeasure, collection_1.useListResetCursorOnBlur);
|
|
65
64
|
exports.ActionBarList = common_1.createSubcomponent('div')({
|
|
66
65
|
displayName: 'ActionBar.List',
|
|
67
66
|
modelHook: useActionBarModel_1.useActionBarModel,
|
|
68
|
-
elemPropsHook:
|
|
67
|
+
elemPropsHook: collection_1.useOverflowListMeasure,
|
|
69
68
|
})(function (_a, Element, model) {
|
|
70
69
|
var children = _a.children, elemProps = __rest(_a, ["children"]);
|
|
71
70
|
return (React.createElement(ResponsiveHStack, __assign({ as: Element, spacing: "s", depth: 1, background: tokens_1.commonColors.background, borderTop: "solid 1px " + tokens_1.colors.soap400, padding: tokens_1.space.s + " " + tokens_1.space.xl + " ", position: "fixed", bottom: 0, left: 0, right: 0 }, elemProps),
|
|
@@ -13,64 +13,6 @@ export interface ActionBarListProps<T = unknown> extends Partial<ExtractProps<ty
|
|
|
13
13
|
*/
|
|
14
14
|
children: ((item: T) => React.ReactNode) | React.ReactNode;
|
|
15
15
|
}
|
|
16
|
-
export declare const useActionBarList: <P extends {}, R>(model: {
|
|
17
|
-
state: {
|
|
18
|
-
selectedIds: import("../../collection/lib/useSelectionListModel").SelectedIds;
|
|
19
|
-
unselectedIds: string[];
|
|
20
|
-
cursorId: string;
|
|
21
|
-
columnCount: number;
|
|
22
|
-
UNSTABLE_virtual: {
|
|
23
|
-
virtualItems: import("../../collection/lib/react-virtual").VirtualItem[];
|
|
24
|
-
totalSize: number;
|
|
25
|
-
scrollToOffset: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToOffsetOptions | undefined) => void;
|
|
26
|
-
scrollToIndex: (index: number, options?: import("../../collection/lib/react-virtual").ScrollToIndexOptions | undefined) => void;
|
|
27
|
-
measure: () => void;
|
|
28
|
-
};
|
|
29
|
-
UNSTABLE_defaultItemHeight: number;
|
|
30
|
-
containerRef: React.RefObject<HTMLDivElement>;
|
|
31
|
-
id: string;
|
|
32
|
-
orientation: import("../../collection/lib/useBaseListModel").Orientation;
|
|
33
|
-
indexRef: React.MutableRefObject<number>;
|
|
34
|
-
nonInteractiveIds: string[];
|
|
35
|
-
isVirtualized: boolean;
|
|
36
|
-
items: import("../../collection").Item<any>[];
|
|
37
|
-
};
|
|
38
|
-
events: {
|
|
39
|
-
select(data: {
|
|
40
|
-
id: string;
|
|
41
|
-
}): void;
|
|
42
|
-
selectAll(): void;
|
|
43
|
-
unselectAll(): void;
|
|
44
|
-
registerItem(data: {
|
|
45
|
-
item: any;
|
|
46
|
-
textValue: string;
|
|
47
|
-
}): void;
|
|
48
|
-
goTo(data: {
|
|
49
|
-
id: string;
|
|
50
|
-
}): void;
|
|
51
|
-
goToNext(): void;
|
|
52
|
-
goToPrevious(): void;
|
|
53
|
-
goToPreviousRow(): void;
|
|
54
|
-
goToNextRow(): void;
|
|
55
|
-
goToFirst(): void;
|
|
56
|
-
goToLast(): void;
|
|
57
|
-
goToFirstOfRow(): void;
|
|
58
|
-
goToLastOfRow(): void;
|
|
59
|
-
goToNextPage(): void;
|
|
60
|
-
goToPreviousPage(): void;
|
|
61
|
-
unregisterItem(data: {
|
|
62
|
-
id: string;
|
|
63
|
-
}): void;
|
|
64
|
-
updateItemHeight(data: {
|
|
65
|
-
value: number;
|
|
66
|
-
}): void;
|
|
67
|
-
};
|
|
68
|
-
selection: import("../../collection/lib/useSelectionListModel").SelectionManager;
|
|
69
|
-
navigation: import("../../collection/lib/useCursorListModel").NavigationManager;
|
|
70
|
-
getId: (item: any) => string;
|
|
71
|
-
}, elemProps?: P | undefined, ref?: ((instance: R | null) => void) | React.RefObject<R> | null | undefined) => {} & P & (R extends HTMLOrSVGElement ? {
|
|
72
|
-
ref: React.Ref<R>;
|
|
73
|
-
} : {});
|
|
74
16
|
export declare const ActionBarList: import("../../common").ElementComponentM<"div", ActionBarListProps<unknown>, {
|
|
75
17
|
state: {
|
|
76
18
|
hiddenIds: string[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ActionBarList.d.ts","sourceRoot":"","sources":["../../../../action-bar/lib/ActionBarList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B,OAAO,
|
|
1
|
+
{"version":3,"file":"ActionBarList.d.ts","sourceRoot":"","sources":["../../../../action-bar/lib/ActionBarList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B,OAAO,EAEL,YAAY,EAGb,MAAM,kCAAkC,CAAC;AAC1C,OAAO,EAAC,MAAM,EAAC,MAAM,kCAAkC,CAAC;AAOxD,MAAM,WAAW,kBAAkB,CAAC,CAAC,GAAG,OAAO,CAC7C,SAAQ,OAAO,CAAC,YAAY,CAAC,OAAO,MAAM,EAAE,KAAK,CAAC,CAAC;IACnD;;;;;;;;OAQG;IACH,QAAQ,EAAE,CAAC,CAAC,IAAI,EAAE,CAAC,KAAK,KAAK,CAAC,SAAS,CAAC,GAAG,KAAK,CAAC,SAAS,CAAC;CAC5D;AAWD,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAuBxB,CAAC"}
|
|
@@ -22,9 +22,9 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
|
22
22
|
};
|
|
23
23
|
import * as React from 'react';
|
|
24
24
|
import { commonColors, colors, space } from '@workday/canvas-kit-react/tokens';
|
|
25
|
-
import {
|
|
25
|
+
import { createSubcomponent, styled, } from '@workday/canvas-kit-react/common';
|
|
26
26
|
import { HStack } from '@workday/canvas-kit-react/layout';
|
|
27
|
-
import { useOverflowListMeasure, useListRenderItems
|
|
27
|
+
import { useOverflowListMeasure, useListRenderItems } from '@workday/canvas-kit-react/collection';
|
|
28
28
|
import { useActionBarModel } from './useActionBarModel';
|
|
29
29
|
import { ActionBar } from './ActionBar';
|
|
30
30
|
var ResponsiveHStack = styled(HStack)(function (_a) {
|
|
@@ -39,11 +39,10 @@ var ResponsiveHStack = styled(HStack)(function (_a) {
|
|
|
39
39
|
},
|
|
40
40
|
_b);
|
|
41
41
|
});
|
|
42
|
-
export var useActionBarList = composeHooks(useOverflowListMeasure, useListResetCursorOnBlur);
|
|
43
42
|
export var ActionBarList = createSubcomponent('div')({
|
|
44
43
|
displayName: 'ActionBar.List',
|
|
45
44
|
modelHook: useActionBarModel,
|
|
46
|
-
elemPropsHook:
|
|
45
|
+
elemPropsHook: useOverflowListMeasure,
|
|
47
46
|
})(function (_a, Element, model) {
|
|
48
47
|
var children = _a.children, elemProps = __rest(_a, ["children"]);
|
|
49
48
|
return (React.createElement(ResponsiveHStack, __assign({ as: Element, spacing: "s", depth: 1, background: commonColors.background, borderTop: "solid 1px " + colors.soap400, padding: space.s + " " + space.xl + " ", position: "fixed", bottom: 0, left: 0, right: 0 }, elemProps),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@workday/canvas-kit-react",
|
|
3
|
-
"version": "7.1.
|
|
3
|
+
"version": "7.1.3",
|
|
4
4
|
"description": "The parent module that contains all Workday Canvas Kit React components",
|
|
5
5
|
"author": "Workday, Inc. (https://www.workday.com)",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -49,9 +49,9 @@
|
|
|
49
49
|
"@emotion/styled": "^11.6.0",
|
|
50
50
|
"@popperjs/core": "^2.5.4",
|
|
51
51
|
"@workday/canvas-colors-web": "^2.0.0",
|
|
52
|
-
"@workday/canvas-kit-labs-react": "^7.1.
|
|
53
|
-
"@workday/canvas-kit-popup-stack": "^7.1.
|
|
54
|
-
"@workday/canvas-kit-preview-react": "^7.1.
|
|
52
|
+
"@workday/canvas-kit-labs-react": "^7.1.3",
|
|
53
|
+
"@workday/canvas-kit-popup-stack": "^7.1.3",
|
|
54
|
+
"@workday/canvas-kit-preview-react": "^7.1.3",
|
|
55
55
|
"@workday/canvas-system-icons-web": "^3.0.0",
|
|
56
56
|
"@workday/design-assets-types": "^0.2.8",
|
|
57
57
|
"chroma-js": "^2.1.0",
|
|
@@ -70,5 +70,5 @@
|
|
|
70
70
|
"@workday/canvas-accent-icons-web": "^3.0.0",
|
|
71
71
|
"@workday/canvas-applet-icons-web": "^2.0.0"
|
|
72
72
|
},
|
|
73
|
-
"gitHead": "
|
|
73
|
+
"gitHead": "d699857a699ccef971df1ac044f0c5fee358cce2"
|
|
74
74
|
}
|