@workday/canvas-kit-labs-react 14.0.0-alpha.1174-next.0 → 14.0.0-alpha.1180-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.
Files changed (28) hide show
  1. package/ai-assistant-ingress-button/index.ts +2 -2
  2. package/ai-assistant-ingress-button/lib/{AiAssistantIngressButton.tsx → AIAssistantIngressButton.tsx} +32 -20
  3. package/ai-assistant-ingress-button/lib/{AiAssistantIngressIcon.tsx → AIAssistantIngressIcon.tsx} +1 -1
  4. package/dist/commonjs/ai-assistant-ingress-button/index.d.ts +2 -2
  5. package/dist/commonjs/ai-assistant-ingress-button/index.js +2 -2
  6. package/dist/{es6/ai-assistant-ingress-button/lib/AiAssistantIngressButton.d.ts → commonjs/ai-assistant-ingress-button/lib/AIAssistantIngressButton.d.ts} +1851 -16
  7. package/dist/{es6/ai-assistant-ingress-button/lib/AiAssistantIngressButton.d.ts.map → commonjs/ai-assistant-ingress-button/lib/AIAssistantIngressButton.d.ts.map} +1 -1
  8. package/dist/commonjs/ai-assistant-ingress-button/lib/AIAssistantIngressButton.js +57 -0
  9. package/dist/commonjs/ai-assistant-ingress-button/lib/AIAssistantIngressIcon.d.ts +3 -0
  10. package/dist/commonjs/ai-assistant-ingress-button/lib/AIAssistantIngressIcon.d.ts.map +1 -0
  11. package/dist/commonjs/ai-assistant-ingress-button/lib/{AiAssistantIngressIcon.js → AIAssistantIngressIcon.js} +3 -3
  12. package/dist/commonjs/search-form/lib/SearchForm.js +14 -14
  13. package/dist/es6/ai-assistant-ingress-button/index.d.ts +2 -2
  14. package/dist/es6/ai-assistant-ingress-button/index.js +2 -2
  15. package/dist/{commonjs/ai-assistant-ingress-button/lib/AiAssistantIngressButton.d.ts → es6/ai-assistant-ingress-button/lib/AIAssistantIngressButton.d.ts} +1851 -16
  16. package/dist/{commonjs/ai-assistant-ingress-button/lib/AiAssistantIngressButton.d.ts.map → es6/ai-assistant-ingress-button/lib/AIAssistantIngressButton.d.ts.map} +1 -1
  17. package/dist/es6/ai-assistant-ingress-button/lib/AIAssistantIngressButton.js +54 -0
  18. package/dist/es6/ai-assistant-ingress-button/lib/AIAssistantIngressIcon.d.ts +3 -0
  19. package/dist/es6/ai-assistant-ingress-button/lib/AIAssistantIngressIcon.d.ts.map +1 -0
  20. package/dist/es6/ai-assistant-ingress-button/lib/{AiAssistantIngressIcon.js → AIAssistantIngressIcon.js} +1 -1
  21. package/dist/es6/search-form/lib/SearchForm.js +14 -14
  22. package/package.json +4 -4
  23. package/dist/commonjs/ai-assistant-ingress-button/lib/AiAssistantIngressButton.js +0 -57
  24. package/dist/commonjs/ai-assistant-ingress-button/lib/AiAssistantIngressIcon.d.ts +0 -3
  25. package/dist/commonjs/ai-assistant-ingress-button/lib/AiAssistantIngressIcon.d.ts.map +0 -1
  26. package/dist/es6/ai-assistant-ingress-button/lib/AiAssistantIngressButton.js +0 -54
  27. package/dist/es6/ai-assistant-ingress-button/lib/AiAssistantIngressIcon.d.ts +0 -3
  28. package/dist/es6/ai-assistant-ingress-button/lib/AiAssistantIngressIcon.d.ts.map +0 -1
@@ -1,2 +1,2 @@
1
- export * from './lib/AiAssistantIngressButton';
2
- export * from './lib/AiAssistantIngressIcon';
1
+ export * from './lib/AIAssistantIngressButton';
2
+ export * from './lib/AIAssistantIngressIcon';
@@ -1,10 +1,10 @@
1
1
  import {createComponent, focusRing, useUniqueId} from '@workday/canvas-kit-react/common';
2
2
  import {BaseButton, BaseButtonProps, buttonStencil} from '@workday/canvas-kit-react/button';
3
3
  import {createStencil, handleCsProp, calc} from '@workday/canvas-kit-styling';
4
- import {system} from '@workday/canvas-tokens-web';
4
+ import {system, base} from '@workday/canvas-tokens-web';
5
5
  import {systemIconStencil} from '@workday/canvas-kit-react/icon';
6
- import {getAiAssistantIngressIcon} from './AiAssistantIngressIcon';
7
- export interface AiAssistantIngressButtonProps
6
+ import {getAIAssistantIngressIcon} from './AIAssistantIngressIcon';
7
+ export interface AIAssistantIngressButtonProps
8
8
  extends Omit<BaseButtonProps, 'size' | 'colors' | 'icon' | 'iconPosition' | 'shouldMirrorIcon'> {
9
9
  /**
10
10
  * When true, indicates that the assistant side panel is open.
@@ -19,22 +19,22 @@ export interface AiAssistantIngressButtonProps
19
19
  /**
20
20
  * Icon gradient colors
21
21
  */
22
- const illuminateStopColor1 = '#FFA198';
23
- const illuminateStopColor2 = '#FFCAA0';
24
- const illuminateStopColor3 = '#FFCA79';
25
- const illuminateStopColor4 = '#FDCA44';
26
- const illuminateStopColor5 = '#FFB74D';
22
+ const illuminateStopColor1 = base.red200; //'#FFA198'
23
+ const illuminateStopColor2 = base.orange200; //'#FFCAA0'
24
+ const illuminateStopColor3 = base.orange200; //'#FFCA79'
25
+ const illuminateStopColor4 = base.amber200; //'#FDCA44'
26
+ const illuminateStopColor5 = base.amber300; //'#FFB74D';
27
27
 
28
28
  /**
29
29
  * Box shadow glow colors
30
30
  */
31
- const glowEraser = '#FFC2FD';
32
- const glowHighlighter = '#FFF3A8';
33
- const glowLunchBreak = '#FEC10B';
34
- const glowHappyHour = '#FD7E00';
35
- const glowThumbtack = '#FC5B05';
31
+ const glowEraser = base.magenta200; //'#FFC2FD';
32
+ const glowHighlighter = base.amber100; //'#FFF3A8';
33
+ const glowLunchBreak = base.amber300; //'#FEC10B';
34
+ const glowHappyHour = base.orange400; //'#FD7E00';
35
+ const glowThumbtack = base.coral500; //'#FC5B05';
36
36
 
37
- export const aiAssistantIngressButtonStencil = createStencil({
37
+ export const AIAssistantIngressButtonStencil = createStencil({
38
38
  extends: buttonStencil,
39
39
  base: {
40
40
  [buttonStencil.vars.background]: system.color.bg.ai.strongest,
@@ -111,6 +111,10 @@ export const aiAssistantIngressButtonStencil = createStencil({
111
111
  },
112
112
  },
113
113
  },
114
+ '&:is(:focus-visible, .focus):not(:disabled, .disabled)': {
115
+ ...focusRing({width: 2, separation: 0, outerColor: system.color.fg.inverse}),
116
+ border: `2px solid ${system.color.border.ai} `,
117
+ },
114
118
  },
115
119
  },
116
120
  toggled: {
@@ -128,6 +132,10 @@ export const aiAssistantIngressButtonStencil = createStencil({
128
132
  stopColor: system.color.fg.ai,
129
133
  },
130
134
  },
135
+ '> linearGradient > stop': {
136
+ transition: '300ms ease-out',
137
+ stopColor: system.color.fg.ai,
138
+ },
131
139
  '&:is(:focus-visible, .focus):not(:disabled, .disabled)': {
132
140
  ...focusRing({width: 2, separation: 2}),
133
141
  border: `1px solid ${system.color.border.container} `,
@@ -140,7 +148,7 @@ export const aiAssistantIngressButtonStencil = createStencil({
140
148
  },
141
149
  compound: [
142
150
  {
143
- modifiers: {toggled: 'true', variant: 'inverse'},
151
+ modifiers: {toggled: true, variant: 'inverse'},
144
152
  styles: {
145
153
  [buttonStencil.vars.background]: system.color.bg.ai.strongest,
146
154
  '.wd-icon-ai-assistant-ingress-button': {
@@ -152,27 +160,31 @@ export const aiAssistantIngressButtonStencil = createStencil({
152
160
  stopColor: system.color.fg.inverse,
153
161
  },
154
162
  },
163
+ '&:is(:focus-visible, .focus):not(:disabled, .disabled)': {
164
+ ...focusRing({width: 2, separation: 0, outerColor: system.color.fg.inverse}),
165
+ border: 'none',
166
+ },
155
167
  },
156
168
  },
157
169
  ],
158
170
  });
159
171
 
160
- export const AiAssistantIngressButton = createComponent('button')({
161
- displayName: 'AiAssistantIngressButton',
162
- Component: ({toggled, variant, ...elemProps}: AiAssistantIngressButtonProps, ref, Element) => {
172
+ export const AIAssistantIngressButton = createComponent('button')({
173
+ displayName: 'AIAssistantIngressButton',
174
+ Component: ({toggled, variant, ...elemProps}: AIAssistantIngressButtonProps, ref, Element) => {
163
175
  const svgGradientId = useUniqueId();
164
176
  return (
165
177
  <BaseButton
166
178
  ref={ref}
167
179
  as={Element}
168
180
  {...handleCsProp(elemProps, [
169
- aiAssistantIngressButtonStencil({toggled, variant}),
181
+ AIAssistantIngressButtonStencil({toggled, variant}),
170
182
  {
171
183
  [systemIconStencil.vars.color]: `url(#${svgGradientId})`,
172
184
  },
173
185
  ])}
174
186
  >
175
- <BaseButton.Icon size="large" icon={getAiAssistantIngressIcon(svgGradientId)} />
187
+ <BaseButton.Icon size="large" icon={getAIAssistantIngressIcon(svgGradientId)} />
176
188
  </BaseButton>
177
189
  );
178
190
  },
@@ -1,6 +1,6 @@
1
1
  import {CanvasSystemIcon, CanvasIconTypes} from '@workday/design-assets-types';
2
2
 
3
- export const getAiAssistantIngressIcon = (svgId: string): CanvasSystemIcon => {
3
+ export const getAIAssistantIngressIcon = (svgId: string): CanvasSystemIcon => {
4
4
  return {
5
5
  name: 'aiAssistantIngressButton',
6
6
  type: CanvasIconTypes.System,
@@ -1,3 +1,3 @@
1
- export * from './lib/AiAssistantIngressButton';
2
- export * from './lib/AiAssistantIngressIcon';
1
+ export * from './lib/AIAssistantIngressButton';
2
+ export * from './lib/AIAssistantIngressIcon';
3
3
  //# sourceMappingURL=index.d.ts.map
@@ -14,5 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./lib/AiAssistantIngressButton"), exports);
18
- __exportStar(require("./lib/AiAssistantIngressIcon"), exports);
17
+ __exportStar(require("./lib/AIAssistantIngressButton"), exports);
18
+ __exportStar(require("./lib/AIAssistantIngressIcon"), exports);