@workday/canvas-kit-preview-react 15.0.0-alpha.0056-next.0 → 15.0.0-alpha.0064-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/dist/commonjs/avatar/lib/Avatar.js +13 -13
- package/dist/commonjs/avatar/lib/AvatarImage.js +1 -1
- package/dist/commonjs/avatar/lib/AvatarName.js +1 -1
- package/dist/commonjs/avatar/lib/BaseAvatar.js +12 -12
- package/dist/commonjs/color-picker/lib/ColorPicker.js +1 -1
- package/dist/commonjs/color-picker/lib/parts/ColorReset.js +1 -1
- package/dist/commonjs/color-picker/lib/parts/SwatchBook.js +1 -1
- package/dist/commonjs/divider/lib/Divider.js +1 -1
- package/dist/commonjs/loading-sparkles/lib/LoadingSparkles.js +2 -2
- package/dist/commonjs/multi-select/lib/MultiSelectInput.js +3 -3
- package/dist/commonjs/pill/lib/Pill.js +3 -3
- package/dist/commonjs/pill/lib/PillAvatar.js +1 -1
- package/dist/commonjs/pill/lib/PillCount.js +1 -1
- package/dist/commonjs/pill/lib/PillIcon.js +1 -1
- package/dist/commonjs/pill/lib/PillIconButton.js +1 -1
- package/dist/commonjs/pill/lib/PillLabel.js +1 -1
- package/dist/commonjs/radio/lib/RadioGroup.js +3 -3
- package/dist/commonjs/radio/lib/RadioLabel.js +1 -1
- package/dist/commonjs/radio/lib/RadioText.js +4 -4
- package/dist/commonjs/radio/lib/StyledRadioButton.js +5 -5
- package/dist/commonjs/side-panel/lib/SidePanel.d.ts +15 -0
- package/dist/commonjs/side-panel/lib/SidePanel.d.ts.map +1 -1
- package/dist/commonjs/side-panel/lib/SidePanel.js +14 -8
- package/dist/commonjs/side-panel/lib/SidePanelToggleButton.js +11 -11
- package/dist/commonjs/side-panel/lib/hooks.d.ts +9 -0
- package/dist/commonjs/side-panel/lib/hooks.d.ts.map +1 -1
- package/dist/commonjs/side-panel/lib/hooks.js +1 -0
- package/dist/commonjs/status-indicator/lib/StatusIndicator.js +15 -15
- package/dist/commonjs/status-indicator/lib/StatusIndicatorLabel.js +1 -1
- package/dist/commonjs/version/lib/version.js +1 -1
- package/dist/es6/avatar/lib/Avatar.js +13 -13
- package/dist/es6/avatar/lib/AvatarImage.js +1 -1
- package/dist/es6/avatar/lib/AvatarName.js +1 -1
- package/dist/es6/avatar/lib/BaseAvatar.js +12 -12
- package/dist/es6/color-picker/lib/ColorPicker.js +1 -1
- package/dist/es6/color-picker/lib/parts/ColorReset.js +1 -1
- package/dist/es6/color-picker/lib/parts/SwatchBook.js +1 -1
- package/dist/es6/divider/lib/Divider.js +1 -1
- package/dist/es6/loading-sparkles/lib/LoadingSparkles.js +2 -2
- package/dist/es6/multi-select/lib/MultiSelectInput.js +3 -3
- package/dist/es6/pill/lib/Pill.js +3 -3
- package/dist/es6/pill/lib/PillAvatar.js +1 -1
- package/dist/es6/pill/lib/PillCount.js +1 -1
- package/dist/es6/pill/lib/PillIcon.js +1 -1
- package/dist/es6/pill/lib/PillIconButton.js +1 -1
- package/dist/es6/pill/lib/PillLabel.js +1 -1
- package/dist/es6/radio/lib/RadioGroup.js +3 -3
- package/dist/es6/radio/lib/RadioLabel.js +1 -1
- package/dist/es6/radio/lib/RadioText.js +4 -4
- package/dist/es6/radio/lib/StyledRadioButton.js +5 -5
- package/dist/es6/side-panel/lib/SidePanel.d.ts +15 -0
- package/dist/es6/side-panel/lib/SidePanel.d.ts.map +1 -1
- package/dist/es6/side-panel/lib/SidePanel.js +14 -8
- package/dist/es6/side-panel/lib/SidePanelToggleButton.js +11 -11
- package/dist/es6/side-panel/lib/hooks.d.ts +9 -0
- package/dist/es6/side-panel/lib/hooks.d.ts.map +1 -1
- package/dist/es6/side-panel/lib/hooks.js +1 -0
- package/dist/es6/status-indicator/lib/StatusIndicator.js +15 -15
- package/dist/es6/status-indicator/lib/StatusIndicatorLabel.js +1 -1
- package/dist/es6/version/lib/version.js +1 -1
- package/package.json +4 -4
- package/side-panel/lib/SidePanel.tsx +15 -0
- package/side-panel/lib/hooks.ts +9 -0
|
@@ -5,27 +5,33 @@ import { createStencil, handleCsProp, px2rem } from '@workday/canvas-kit-styling
|
|
|
5
5
|
import { system } from '@workday/canvas-tokens-web';
|
|
6
6
|
import { SidePanelContext } from './hooks';
|
|
7
7
|
import { SidePanelToggleButton } from './SidePanelToggleButton';
|
|
8
|
+
/**
|
|
9
|
+
* @deprecated ⚠️ `panelStencil` in Preview has been deprecated and will be removed in a future major version. Please use [`SidePanel` in Labs](https://workday.github.io/canvas-kit/?path=/docs/labs-side-panel--docs) instead.
|
|
10
|
+
*/
|
|
8
11
|
export const panelStencil = createStencil({
|
|
9
12
|
vars: {
|
|
10
13
|
expandedWidth: '',
|
|
11
14
|
collapsedWidth: '',
|
|
12
15
|
},
|
|
13
|
-
base: { name: "
|
|
16
|
+
base: { name: "3wk1rr", styles: "box-sizing:border-box;overflow:hidden;position:relative;height:100%;outline:0.0625rem solid transparent;transition:width ease-out 200ms, max-width ease-out 200ms;" },
|
|
14
17
|
modifiers: {
|
|
15
18
|
variant: {
|
|
16
|
-
alternate: { name: "
|
|
17
|
-
standard: { name: "
|
|
19
|
+
alternate: { name: "52tip", styles: "background-color:var(--cnvs-sys-color-bg-default);box-shadow:var(--cnvs-sys-depth-5);" },
|
|
20
|
+
standard: { name: "1xp297", styles: "background-color:var(--cnvs-sys-color-bg-alt-softer);" }
|
|
18
21
|
},
|
|
19
22
|
expanded: {
|
|
20
|
-
true: { name: "
|
|
21
|
-
false: { name: "
|
|
23
|
+
true: { name: "248qlf", styles: "width:var(--expandedWidth-panel-8771e1);max-width:var(--expandedWidth-panel-8771e1);" },
|
|
24
|
+
false: { name: "s8a9", styles: "width:var(--collapsedWidth-panel-8771e1);max-width:var(--collapsedWidth-panel-8771e1);" }
|
|
22
25
|
},
|
|
23
26
|
touched: {
|
|
24
|
-
true: { name: "
|
|
25
|
-
false: { name: "
|
|
27
|
+
true: { name: "dc6fy", styles: "" },
|
|
28
|
+
false: { name: "44byep", styles: "animation:none;" }
|
|
26
29
|
}
|
|
27
30
|
}
|
|
28
|
-
}, "panel-
|
|
31
|
+
}, "panel-8771e1");
|
|
32
|
+
/**
|
|
33
|
+
* @deprecated ⚠️ `SidePanel` in Preview has been deprecated and will be removed in a future major version. Please use [`SidePanel` in Labs](https://workday.github.io/canvas-kit/?path=/docs/labs-side-panel--docs) instead.
|
|
34
|
+
*/
|
|
29
35
|
export const SidePanel = createComponent('section')({
|
|
30
36
|
displayName: 'SidePanel',
|
|
31
37
|
Component({ children, collapsedWidth = 64, expanded = true, expandedWidth = 320, onAnimationEnd, onExpandedChange, onStateTransition, origin = 'left', variant = 'standard', touched, ...elemProps }, ref, Element) {
|
|
@@ -8,35 +8,35 @@ import { SidePanelContext } from './hooks';
|
|
|
8
8
|
import { createStencil, handleCsProp } from '@workday/canvas-kit-styling';
|
|
9
9
|
import { system } from '@workday/canvas-tokens-web';
|
|
10
10
|
export const sidePanelToggleButtonStencil = createStencil({
|
|
11
|
-
base: { name: "
|
|
11
|
+
base: { name: "3pqj4r", styles: "box-sizing:border-box;position:absolute;top:var(--cnvs-sys-space-x6);width:var(--cnvs-sys-space-x8);inset-inline-end:var(--cnvs-sys-space-x4);" },
|
|
12
12
|
modifiers: {
|
|
13
13
|
state: {
|
|
14
|
-
collapsing: { name: "
|
|
15
|
-
collapsed: { name: "
|
|
16
|
-
expanded: { name: "
|
|
17
|
-
expanding: { name: "
|
|
14
|
+
collapsing: { name: "47ocnw", styles: "margin:0;transform:scaleX(1);:dir(rtl){transform:scaleX(-1);}" },
|
|
15
|
+
collapsed: { name: "197nbg", styles: "margin:auto;inset-inline-start:0;inset-inline-end:0;transform:scaleX(1);:dir(rtl){transform:scaleX(-1);}" },
|
|
16
|
+
expanded: { name: "of5qn", styles: "margin:0;transform:scaleX(-1);:dir(rtl){transform:scaleX(1);}" },
|
|
17
|
+
expanding: { name: "1wz9uy", styles: "margin:0;transform:scaleX(-1);:dir(rtl){transform:scaleX(1);}" }
|
|
18
18
|
},
|
|
19
19
|
origin: {
|
|
20
|
-
left: { name: "
|
|
21
|
-
right: { name: "
|
|
20
|
+
left: { name: "351l2q", styles: "" },
|
|
21
|
+
right: { name: "26noow", styles: "" }
|
|
22
22
|
}
|
|
23
23
|
},
|
|
24
24
|
compound: [
|
|
25
25
|
{
|
|
26
26
|
modifiers: { state: 'collapsed', origin: 'right' },
|
|
27
|
-
styles: { name: "
|
|
27
|
+
styles: { name: "te8m9", styles: "transform:scaleX(-1);" }
|
|
28
28
|
},
|
|
29
29
|
{
|
|
30
30
|
modifiers: { state: 'collapsing', origin: 'right' },
|
|
31
|
-
styles: { name: "
|
|
31
|
+
styles: { name: "1s2s05", styles: "transform:scaleX(-1);inset-inline-start:var(--cnvs-sys-space-x4);" }
|
|
32
32
|
},
|
|
33
33
|
{
|
|
34
34
|
modifiers: { state: 'expanded', origin: 'right' },
|
|
35
|
-
styles: { name: "
|
|
35
|
+
styles: { name: "4h0ab", styles: "transform:scaleX(1);inset-inline-start:var(--cnvs-sys-space-x4);" }
|
|
36
36
|
},
|
|
37
37
|
{
|
|
38
38
|
modifiers: { state: 'expanding', origin: 'right' },
|
|
39
|
-
styles: { name: "
|
|
39
|
+
styles: { name: "sx6q9", styles: "transform:scaleX(1);inset-inline-start:var(--cnvs-sys-space-x4);" }
|
|
40
40
|
}
|
|
41
41
|
]
|
|
42
42
|
}, "side-panel-toggle-button-da8098");
|
|
@@ -6,6 +6,7 @@ export declare const SidePanelContext: React.Context<{
|
|
|
6
6
|
}>;
|
|
7
7
|
/**
|
|
8
8
|
* The optional config options for the `useSidePanel` hook
|
|
9
|
+
* @deprecated ⚠️ `UseSidePanelProps` in Preview has been deprecated and will be removed in a future major version. Please use [`SidePanel` in Labs](https://workday.github.io/canvas-kit/?path=/docs/labs-side-panel--docs) instead.
|
|
9
10
|
*/
|
|
10
11
|
export interface UseSidePanelProps {
|
|
11
12
|
/**
|
|
@@ -26,6 +27,7 @@ export interface UseSidePanelProps {
|
|
|
26
27
|
}
|
|
27
28
|
/**
|
|
28
29
|
* The `panelProps` provided by the `useSidePanel` hook
|
|
30
|
+
* @deprecated ⚠️ `PanelProps` in Preview has been deprecated and will be removed in a future major version. Please use [`SidePanel` in Labs](https://workday.github.io/canvas-kit/?path=/docs/labs-side-panel--docs) instead.
|
|
29
31
|
*/
|
|
30
32
|
export interface PanelProps {
|
|
31
33
|
/**
|
|
@@ -48,6 +50,9 @@ export interface PanelProps {
|
|
|
48
50
|
*/
|
|
49
51
|
touched: boolean;
|
|
50
52
|
}
|
|
53
|
+
/**
|
|
54
|
+
* @deprecated ⚠️ `LabelProps` in Preview has been deprecated and will be removed in a future major version. Please use [`SidePanel` in Labs](https://workday.github.io/canvas-kit/?path=/docs/labs-side-panel--docs) instead.
|
|
55
|
+
*/
|
|
51
56
|
export interface LabelProps {
|
|
52
57
|
/**
|
|
53
58
|
* the accessible `id`
|
|
@@ -55,6 +60,9 @@ export interface LabelProps {
|
|
|
55
60
|
*/
|
|
56
61
|
id: string;
|
|
57
62
|
}
|
|
63
|
+
/**
|
|
64
|
+
* @deprecated ⚠️ `ControlProps` in Preview has been deprecated and will be removed in a future major version. Please use [`SidePanel` in Labs](https://workday.github.io/canvas-kit/?path=/docs/labs-side-panel--docs) instead.
|
|
65
|
+
*/
|
|
58
66
|
export interface ControlProps {
|
|
59
67
|
/**
|
|
60
68
|
* the accessible `id` that connects the panel to this control
|
|
@@ -90,6 +98,7 @@ export interface ControlProps {
|
|
|
90
98
|
* labelId: 'custom-label-id',
|
|
91
99
|
* });
|
|
92
100
|
* ```
|
|
101
|
+
* @deprecated ⚠️ `useSidePanel` in Preview has been deprecated and will be removed in a future major version. Please use [`SidePanel` in Labs](https://workday.github.io/canvas-kit/?path=/docs/labs-side-panel--docs) instead.
|
|
93
102
|
*/
|
|
94
103
|
export declare const useSidePanel: (config?: UseSidePanelProps) => {
|
|
95
104
|
expanded: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"hooks.d.ts","sourceRoot":"","sources":["../../../../side-panel/lib/hooks.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,eAAO,MAAM,gBAAgB;;;;EAI3B,CAAC;AAGH
|
|
1
|
+
{"version":3,"file":"hooks.d.ts","sourceRoot":"","sources":["../../../../side-panel/lib/hooks.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,eAAO,MAAM,gBAAgB;;;;EAI3B,CAAC;AAGH;;;GAGG;AACH,MAAM,WAAW,iBAAiB;IAChC;;;OAGG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED;;;GAGG;AACH,MAAM,WAAW,UAAU;IACzB;;OAEG;IACH,QAAQ,EAAE,OAAO,CAAC;IAClB;;;OAGG;IACH,EAAE,EAAE,MAAM,CAAC;IACX;;;OAGG;IACH,iBAAiB,EAAE,MAAM,CAAC;IAC1B;;;OAGG;IACH,OAAO,EAAE,OAAO,CAAC;CAClB;AAED;;GAEG;AACH,MAAM,WAAW,UAAU;IACzB;;;OAGG;IACH,EAAE,EAAE,MAAM,CAAC;CACZ;AAED;;GAEG;AACH,MAAM,WAAW,YAAY;IAC3B;;;OAGG;IACH,eAAe,EAAE,MAAM,CAAC;IACxB;;;OAGG;IACH,eAAe,EAAE,OAAO,CAAC;IACzB;;;OAGG;IACH,iBAAiB,EAAE,MAAM,CAAC;IAC1B;;OAEG;IACH,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AAED;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,YAAY,YAAa,iBAAiB;;oCA2BR,OAAO;;;;CA8BrD,CAAC"}
|
|
@@ -19,6 +19,7 @@ import { useUniqueId } from '@workday/canvas-kit-react/common';
|
|
|
19
19
|
* labelId: 'custom-label-id',
|
|
20
20
|
* });
|
|
21
21
|
* ```
|
|
22
|
+
* @deprecated ⚠️ `useSidePanel` in Preview has been deprecated and will be removed in a future major version. Please use [`SidePanel` in Labs](https://workday.github.io/canvas-kit/?path=/docs/labs-side-panel--docs) instead.
|
|
22
23
|
*/
|
|
23
24
|
export const useSidePanel = (config) => {
|
|
24
25
|
const [touched, setTouched] = React.useState(false);
|
|
@@ -15,7 +15,7 @@ const deprecatedVariantsMap = {
|
|
|
15
15
|
gray: 'neutral',
|
|
16
16
|
};
|
|
17
17
|
const statusIndicatorStencil = createStencil({
|
|
18
|
-
base: { name: "
|
|
18
|
+
base: { name: "3u1uei", styles: "box-sizing:border-box;display:inline-flex;gap:var(--cnvs-sys-space-x1);max-width:12.5rem;align-items:center;border-radius:var(--cnvs-sys-shape-round);height:1.25rem;padding:var(--cnvs-sys-space-zero) var(--cnvs-sys-space-x2);outline:0.0625rem solid transparent;--color-system-icon-3a4847:currentColor;" },
|
|
19
19
|
modifiers: {
|
|
20
20
|
/**
|
|
21
21
|
* Defines the color of the `StatusIndicator`.
|
|
@@ -30,13 +30,13 @@ const statusIndicatorStencil = createStencil({
|
|
|
30
30
|
* @default 'neutral'
|
|
31
31
|
*/
|
|
32
32
|
variant: {
|
|
33
|
-
info: { name: "
|
|
34
|
-
positive: { name: "
|
|
35
|
-
caution: { name: "
|
|
36
|
-
critical: { name: "
|
|
37
|
-
neutral: { name: "
|
|
38
|
-
ai: { name: "
|
|
39
|
-
transparent: { name: "
|
|
33
|
+
info: { name: "2tlm1a", styles: "color:var(--cnvs-sys-color-fg-info-strong);background-color:var(--cnvs-sys-color-bg-info-softer);" },
|
|
34
|
+
positive: { name: "zz7mo", styles: "color:var(--cnvs-sys-color-fg-positive-strong);background-color:var(--cnvs-sys-color-fg-positive-softer);" },
|
|
35
|
+
caution: { name: "3ypedd", styles: "color:var(--cnvs-sys-color-fg-caution-soft);background-color:var(--cnvs-sys-color-bg-caution-softer);" },
|
|
36
|
+
critical: { name: "3nmkej", styles: "color:var(--cnvs-sys-color-fg-critical-strong);background-color:var(--cnvs-sys-color-bg-critical-softer);" },
|
|
37
|
+
neutral: { name: "4dz17l", styles: "color:var(--cnvs-sys-color-fg-muted-strong);background-color:var(--cnvs-sys-color-bg-alt-default);" },
|
|
38
|
+
ai: { name: "3di9hq", styles: "color:var(--cnvs-sys-color-fg-ai);background-color:var(--cnvs-sys-color-bg-ai-default);" },
|
|
39
|
+
transparent: { name: "3hsm6q", styles: "color:var(--cnvs-sys-color-fg-inverse);background-color:var(--cnvs-sys-color-bg-translucent);" }
|
|
40
40
|
},
|
|
41
41
|
/**
|
|
42
42
|
* Defines the emphasis of the `StatusIndicator`. `low` should be used in almost all cases.
|
|
@@ -49,8 +49,8 @@ const statusIndicatorStencil = createStencil({
|
|
|
49
49
|
*
|
|
50
50
|
*/
|
|
51
51
|
emphasis: {
|
|
52
|
-
low: { name: "
|
|
53
|
-
high: { name: "
|
|
52
|
+
low: { name: "2dr78", styles: "" },
|
|
53
|
+
high: { name: "4186r6", styles: "" }
|
|
54
54
|
}
|
|
55
55
|
},
|
|
56
56
|
compound: [
|
|
@@ -59,35 +59,35 @@ const statusIndicatorStencil = createStencil({
|
|
|
59
59
|
variant: 'info',
|
|
60
60
|
emphasis: 'high',
|
|
61
61
|
},
|
|
62
|
-
styles: { name: "
|
|
62
|
+
styles: { name: "14x7g4", styles: "background-color:var(--cnvs-sys-color-bg-info-default);color:var(--cnvs-sys-color-fg-inverse);" }
|
|
63
63
|
},
|
|
64
64
|
{
|
|
65
65
|
modifiers: {
|
|
66
66
|
variant: 'positive',
|
|
67
67
|
emphasis: 'high',
|
|
68
68
|
},
|
|
69
|
-
styles: { name: "
|
|
69
|
+
styles: { name: "4e0x9s", styles: "background-color:var(--cnvs-sys-color-bg-positive-default);color:var(--cnvs-sys-color-fg-inverse);" }
|
|
70
70
|
},
|
|
71
71
|
{
|
|
72
72
|
modifiers: {
|
|
73
73
|
variant: 'caution',
|
|
74
74
|
emphasis: 'high',
|
|
75
75
|
},
|
|
76
|
-
styles: { name: "
|
|
76
|
+
styles: { name: "1qaivm", styles: "background-color:var(--cnvs-sys-color-bg-caution-default);color:var(--cnvs-sys-color-fg-caution-strong);" }
|
|
77
77
|
},
|
|
78
78
|
{
|
|
79
79
|
modifiers: {
|
|
80
80
|
variant: 'critical',
|
|
81
81
|
emphasis: 'high',
|
|
82
82
|
},
|
|
83
|
-
styles: { name: "
|
|
83
|
+
styles: { name: "1rfquo", styles: "background-color:var(--cnvs-sys-color-bg-critical-default);color:var(--cnvs-sys-color-fg-inverse);" }
|
|
84
84
|
},
|
|
85
85
|
{
|
|
86
86
|
modifiers: {
|
|
87
87
|
variant: 'neutral',
|
|
88
88
|
emphasis: 'high',
|
|
89
89
|
},
|
|
90
|
-
styles: { name: "
|
|
90
|
+
styles: { name: "2bfcn8", styles: "background-color:var(--cnvs-sys-color-bg-muted-default);color:var(--cnvs-sys-color-fg-inverse);" }
|
|
91
91
|
}
|
|
92
92
|
],
|
|
93
93
|
defaultModifiers: {
|
|
@@ -6,7 +6,7 @@ import { mergeStyles } from '@workday/canvas-kit-react/layout';
|
|
|
6
6
|
import { system } from '@workday/canvas-tokens-web';
|
|
7
7
|
const statusIndicatorLabelStencil = createStencil({
|
|
8
8
|
extends: textStencil,
|
|
9
|
-
base: { name: "
|
|
9
|
+
base: { name: "3bwvyy", styles: "box-sizing:border-box;font-weight:var(--cnvs-sys-font-weight-bold);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;text-transform:capitalize;color:inherit;" },
|
|
10
10
|
defaultModifiers: { typeLevel: 'subtext.large' }
|
|
11
11
|
}, "status-indicator-label-63258e");
|
|
12
12
|
export const StatusIndicatorLabel = createComponent('span')({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export const version = '14.
|
|
1
|
+
export const version = '14.2.0';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@workday/canvas-kit-preview-react",
|
|
3
|
-
"version": "15.0.0-alpha.
|
|
3
|
+
"version": "15.0.0-alpha.0064-next.0",
|
|
4
4
|
"description": "Canvas Kit Preview is made up of components that have the full design and a11y review, are part of the DS ecosystem and are approved for use in product. The API's could be subject to change, but not without strong communication and migration strategies.",
|
|
5
5
|
"author": "Workday, Inc. (https://www.workday.com)",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -48,8 +48,8 @@
|
|
|
48
48
|
"dependencies": {
|
|
49
49
|
"@emotion/react": "^11.7.1",
|
|
50
50
|
"@emotion/styled": "^11.6.0",
|
|
51
|
-
"@workday/canvas-kit-react": "^15.0.0-alpha.
|
|
52
|
-
"@workday/canvas-kit-styling": "^15.0.0-alpha.
|
|
51
|
+
"@workday/canvas-kit-react": "^15.0.0-alpha.0064-next.0",
|
|
52
|
+
"@workday/canvas-kit-styling": "^15.0.0-alpha.0064-next.0",
|
|
53
53
|
"@workday/canvas-system-icons-web": "^3.0.36",
|
|
54
54
|
"@workday/canvas-tokens-web": "4.0.0-alpha.3",
|
|
55
55
|
"@workday/design-assets-types": "^0.2.10"
|
|
@@ -60,5 +60,5 @@
|
|
|
60
60
|
"react-hook-form": "7.36.1",
|
|
61
61
|
"yup": "^0.32.11"
|
|
62
62
|
},
|
|
63
|
-
"gitHead": "
|
|
63
|
+
"gitHead": "74d356998c8a3fe27e6a54ef1db7128320b4b2ed"
|
|
64
64
|
}
|
|
@@ -5,9 +5,18 @@ import {system} from '@workday/canvas-tokens-web';
|
|
|
5
5
|
import {SidePanelContext} from './hooks';
|
|
6
6
|
import {SidePanelToggleButton} from './SidePanelToggleButton';
|
|
7
7
|
|
|
8
|
+
/**
|
|
9
|
+
* @deprecated ⚠️ `SidePanelVariant` in Preview has been deprecated and will be removed in a future major version. Please use [`SidePanel` in Labs](https://workday.github.io/canvas-kit/?path=/docs/labs-side-panel--docs) instead.
|
|
10
|
+
*/
|
|
8
11
|
export type SidePanelVariant = 'standard' | 'alternate';
|
|
12
|
+
/**
|
|
13
|
+
* @deprecated ⚠️ `SidePanelTransitionStates` in Preview has been deprecated and will be removed in a future major version. Please use [`SidePanel` in Labs](https://workday.github.io/canvas-kit/?path=/docs/labs-side-panel--docs) instead.
|
|
14
|
+
*/
|
|
9
15
|
export type SidePanelTransitionStates = 'collapsed' | 'collapsing' | 'expanded' | 'expanding';
|
|
10
16
|
|
|
17
|
+
/**
|
|
18
|
+
* @deprecated ⚠️ `SidePanelProps` in Preview has been deprecated and will be removed in a future major version. Please use [`SidePanel` in Labs](https://workday.github.io/canvas-kit/?path=/docs/labs-side-panel--docs) instead.
|
|
19
|
+
*/
|
|
11
20
|
export interface SidePanelProps {
|
|
12
21
|
/**
|
|
13
22
|
* The width of the component (in `px` if it's a `number`) when it is collapsed.
|
|
@@ -62,6 +71,9 @@ export interface SidePanelProps {
|
|
|
62
71
|
onAnimationEnd?: React.TransitionEvent<HTMLElement>;
|
|
63
72
|
}
|
|
64
73
|
|
|
74
|
+
/**
|
|
75
|
+
* @deprecated ⚠️ `panelStencil` in Preview has been deprecated and will be removed in a future major version. Please use [`SidePanel` in Labs](https://workday.github.io/canvas-kit/?path=/docs/labs-side-panel--docs) instead.
|
|
76
|
+
*/
|
|
65
77
|
export const panelStencil = createStencil({
|
|
66
78
|
vars: {
|
|
67
79
|
expandedWidth: '',
|
|
@@ -103,6 +115,9 @@ export const panelStencil = createStencil({
|
|
|
103
115
|
},
|
|
104
116
|
});
|
|
105
117
|
|
|
118
|
+
/**
|
|
119
|
+
* @deprecated ⚠️ `SidePanel` in Preview has been deprecated and will be removed in a future major version. Please use [`SidePanel` in Labs](https://workday.github.io/canvas-kit/?path=/docs/labs-side-panel--docs) instead.
|
|
120
|
+
*/
|
|
106
121
|
export const SidePanel = createComponent('section')({
|
|
107
122
|
displayName: 'SidePanel',
|
|
108
123
|
Component(
|
package/side-panel/lib/hooks.ts
CHANGED
|
@@ -9,6 +9,7 @@ export const SidePanelContext = React.createContext({
|
|
|
9
9
|
import {useUniqueId} from '@workday/canvas-kit-react/common';
|
|
10
10
|
/**
|
|
11
11
|
* The optional config options for the `useSidePanel` hook
|
|
12
|
+
* @deprecated ⚠️ `UseSidePanelProps` in Preview has been deprecated and will be removed in a future major version. Please use [`SidePanel` in Labs](https://workday.github.io/canvas-kit/?path=/docs/labs-side-panel--docs) instead.
|
|
12
13
|
*/
|
|
13
14
|
export interface UseSidePanelProps {
|
|
14
15
|
/**
|
|
@@ -30,6 +31,7 @@ export interface UseSidePanelProps {
|
|
|
30
31
|
|
|
31
32
|
/**
|
|
32
33
|
* The `panelProps` provided by the `useSidePanel` hook
|
|
34
|
+
* @deprecated ⚠️ `PanelProps` in Preview has been deprecated and will be removed in a future major version. Please use [`SidePanel` in Labs](https://workday.github.io/canvas-kit/?path=/docs/labs-side-panel--docs) instead.
|
|
33
35
|
*/
|
|
34
36
|
export interface PanelProps {
|
|
35
37
|
/**
|
|
@@ -53,6 +55,9 @@ export interface PanelProps {
|
|
|
53
55
|
touched: boolean;
|
|
54
56
|
}
|
|
55
57
|
|
|
58
|
+
/**
|
|
59
|
+
* @deprecated ⚠️ `LabelProps` in Preview has been deprecated and will be removed in a future major version. Please use [`SidePanel` in Labs](https://workday.github.io/canvas-kit/?path=/docs/labs-side-panel--docs) instead.
|
|
60
|
+
*/
|
|
56
61
|
export interface LabelProps {
|
|
57
62
|
/**
|
|
58
63
|
* the accessible `id`
|
|
@@ -61,6 +66,9 @@ export interface LabelProps {
|
|
|
61
66
|
id: string;
|
|
62
67
|
}
|
|
63
68
|
|
|
69
|
+
/**
|
|
70
|
+
* @deprecated ⚠️ `ControlProps` in Preview has been deprecated and will be removed in a future major version. Please use [`SidePanel` in Labs](https://workday.github.io/canvas-kit/?path=/docs/labs-side-panel--docs) instead.
|
|
71
|
+
*/
|
|
64
72
|
export interface ControlProps {
|
|
65
73
|
/**
|
|
66
74
|
* the accessible `id` that connects the panel to this control
|
|
@@ -97,6 +105,7 @@ export interface ControlProps {
|
|
|
97
105
|
* labelId: 'custom-label-id',
|
|
98
106
|
* });
|
|
99
107
|
* ```
|
|
108
|
+
* @deprecated ⚠️ `useSidePanel` in Preview has been deprecated and will be removed in a future major version. Please use [`SidePanel` in Labs](https://workday.github.io/canvas-kit/?path=/docs/labs-side-panel--docs) instead.
|
|
100
109
|
*/
|
|
101
110
|
export const useSidePanel = (config?: UseSidePanelProps) => {
|
|
102
111
|
const [touched, setTouched] = React.useState(false);
|