@workday/canvas-kit-mcp 13.2.41

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.
@@ -0,0 +1,516 @@
1
+ # Canvas Kit 13.0 Upgrade Guide
2
+
3
+ This guide contains an overview of the changes in Canvas Kit v13. Please
4
+ [reach out](https://github.com/Workday/canvas-kit/issues/new?labels=bug&template=bug.md) if you have
5
+ any questions. For common upgrade issues, please see the [Troubleshooting](#troubleshooting) section
6
+ at the end of this guide.
7
+
8
+ ## Why You Should Upgrade
9
+
10
+ We're really excited about the updates in Canvas Kit v13! In this release, we:
11
+
12
+ - refactored components to use our Canvas tokens and styling API
13
+ - made several accessibilty improvements
14
+ - updated our brand logos
15
+ - improved our infrastructure
16
+
17
+ ### Refactored Components to Use Our Styling API
18
+
19
+ We've continued refactoring our components to use our new styling API and new Canvas tokens. This
20
+ allows us to provide a more consistent styling experience across our components.
21
+
22
+ ### Updated Brand Logos
23
+
24
+ As part of Workday's brand refresh, we've updated our Workday logos to align with our new brand
25
+ design.
26
+
27
+ ### Improved Support for ES Modules
28
+
29
+ We've updated the `jsx` flag in our `tsconfig` to `react-jsx` to provide better support for newer
30
+ technologies including `Vite`. As part of this change, we've also updated our `react` peer
31
+ dependencies to a minimum version of `17.0.0`.
32
+
33
+ ## Table of Contents
34
+
35
+ - [Codemod](#codemod)
36
+ - [Instructions](#instructions)
37
+ - [Component Updates](#component-updates)
38
+ - [Styling API and CSS Tokens](#styling-api-and-canvas-tokens-)
39
+ - [Avatar](#avatar-)
40
+ - [Expandable](#expandable-)
41
+ - [External Hyperlink](#external-hyperlink-)
42
+ - [Form Field and Form Field Group](#form-field-and-form-field-group-)
43
+ - [Pill (Preview)](#pill-preview-)
44
+ - [SidePanel (Preview)](#side-panel-preview-)
45
+ - [Tabs](#tabs-)
46
+ - [Brand Refresh](#brand-refresh)
47
+ - [Logo Updates](#logo-updates-)
48
+ - [Infrastructure](#infrastructure)
49
+ - [Supporting react-jsx](#supporting-react-jsx-)
50
+ - [Troubleshooting](#troubleshooting)
51
+ - [Contributors](#contributors)
52
+ - [Glossary](#glossary)
53
+ - [Main](#main)
54
+ - [Preview](#preview)
55
+ - [Labs](#labs)
56
+
57
+ ## Codemod
58
+
59
+ We've provided a [codemod](https://github.com/Workday/canvas-kit/tree/master/modules/codemod) to
60
+ automatically update your code to work with most of the breaking changes in v13. **Breaking changes
61
+ handled by the codemod are marked with 🤖 in the Upgrade Guide.**
62
+
63
+ ### Instructions
64
+
65
+ The easiest way to run our codemod is to use `npx` in your terminal.```sh
66
+ npx @workday/canvas-kit-codemod v13 [path]
67
+ ```
68
+
69
+ Be sure to provide specific directories that need to be updated via the `[path]` argument. This
70
+ decreases the amount of AST the codemod needs to traverse and reduces the chances of the script
71
+ having an error. For example, if your source code lives in `src/`, use `src/` as your `[path]`. Or,
72
+ if you have a monorepo with three packages using Canvas Kit, provide those specific packages as your
73
+ `[path]`.
74
+
75
+ Alternatively, if you're unable to run the codemod successfully using `npx`, you can install the
76
+ codemod package as a dev dependency, run it with `yarn`, and then remove the package after you're
77
+ finished.
78
+
79
+ ```sh
80
+ yarn add @workday/canvas-kit-codemod --dev
81
+ yarn canvas-kit-codemod v13 [path]
82
+ yarn remove @workday/canvas-kit-codemod
83
+ ```
84
+
85
+ Having trouble running our codemods? View our
86
+ [docs](https://workday.github.io/canvas-kit/?path=/docs/guides-codemods--docs) for more information!
87
+
88
+ ## Component Updates
89
+
90
+ ### Styling API and Canvas Tokens 💅
91
+
92
+ Several components have been refactored to use our
93
+ [Canvas tokens](https://workday.github.io/canvas-tokens/?path=/docs/docs-getting-started--docs) and
94
+ [styling API](https://workday.github.io/canvas-kit/?path=/docs/styling-basics--docs#createstyles-api).
95
+ The React interface **has not changed**, but Canvas Tokens are now used for dynamic properties.
96
+
97
+ > **Note:** These components also support our `cs` prop for styling. Learn more about styling with
98
+ > `cs` in our
99
+ > [documentation](https://workday.github.io/canvas-kit/?path=/docs/styling-basics--docs#cs-prop).
100
+
101
+ The following components have been updated:
102
+
103
+ - `ActionBar` [#3205](https://github.com/Workday/canvas-kit/pull/3205)
104
+ - `Banner` [#3210](https://github.com/Workday/canvas-kit/pull/3210)
105
+ - `Expandable` [#3128](https://github.com/Workday/canvas-kit/pull/3128 )
106
+ - `ExternalHyperlink` [#3101](https://github.com/Workday/canvas-kit/pull/3101)
107
+ - `LoadingSparkles` [#3120](https://github.com/Workday/canvas-kit/pull/3120)
108
+ - `Menu` [#3114](https://github.com/Workday/canvas-kit/pull/3114)
109
+ - `Pill` [#3140](https://github.com/Workday/canvas-kit/pull/3104)
110
+ - `Select` [#3240](https://github.com/Workday/canvas-kit/pull/3240)
111
+ - `SidePanel (Preview)` [#3123](https://github.com/Workday/canvas-kit/pull/3123)
112
+ - `Skeleton` [#3088](https://github.com/Workday/canvas-kit/pull/3088)
113
+ - `Tabs` [#3119](https://github.com/Workday/canvas-kit/pull/3119)
114
+ - `Tooltip` [#3164](https://github.com/Workday/canvas-kit/pull/3164)
115
+
116
+ ### Avatar 🚨
117
+
118
+ **PR:** [#3231](https://github.com/Workday/canvas-kit/pull/3231)
119
+
120
+ The following change has been made to `Avatar` to ensure proper accessibility.
121
+
122
+ - The `altText` prop no longer has a default value of `"Avatar"` for better internalization. This
123
+ default phrase caused some to accidentally omit translations which caused translation issues.
124
+
125
+ > **Note:** This change also impacts `Pill.Avatar` and `Expandable.Avatar`. You must provide a value
126
+ > to `altText` to ensure proper accessibility. Our examples have been updated to reflect this
127
+ > change.
128
+
129
+ **Before in v12**
130
+
131
+ ```tsx
132
+ // Avatar component always had a default altText of "Avatar"
133
+ <Avatar as="div" />
134
+ ```
135
+
136
+ **After in v13**
137
+
138
+ ```tsx
139
+ // You must provide alt text to the `altText` prop. Please choose a apt description based on your `Avatar`'s usage.
140
+ <Avatar altText="User profile avatar" as="div" />
141
+ ```
142
+
143
+ ### Expandable ⚡️
144
+
145
+ **PR:** [#3217](https://github.com/Workday/canvas-kit/pull/3217)
146
+
147
+ We've promoted `Expandable` from [Labs](#labs) to [Main](#main).
148
+
149
+ **Before in v12**
150
+
151
+ ```tsx
152
+ import {Expandable} from '@workday/canvas-kit-labs-react/expandable';
153
+ ```
154
+
155
+ **After in v13**
156
+
157
+ ```tsx
158
+ import {Expandable} from '@workday/canvas-kit-react/expandable';
159
+ ```
160
+
161
+ > 🤖 The codemod will handle the change of imports as shown above.
162
+
163
+ ### External Hyperlink 🚨
164
+
165
+ **PR:** [#3101](https://github.com/Workday/canvas-kit/pull/3101)
166
+
167
+ The following change has been made to `ExternalHyperlink` to ensure proper accessibility.
168
+
169
+ - The `iconLabel` prop no longer has a default value of `"Opens link in new window"`. This default
170
+ phrase caused some to accidentally omit translations which caused translation issues.
171
+
172
+ > **Note:** While the prop is not required, you _must_ provide an `iconLabel` for `<ExternalHyperlink />` to ensure proper
173
+ > accessibility. Our examples have been updated to reflect this change.
174
+
175
+ **Before in v12**
176
+
177
+ ```tsx
178
+ <ExternalHyperlink href="https://workday.com">External Hyperlink</ExternalHyperlink>
179
+ ```
180
+
181
+ **After in v13**
182
+
183
+ ```tsx
184
+ <ExternalHyperlink href="https://workday.com" iconLabel="Navigate to Workday">
185
+ External Hyperlink
186
+ </ExternalHyperlink>
187
+ ```
188
+
189
+ ### Form Field and Form Field Group 🚨
190
+
191
+ **PR:** [#3254](https://github.com/Workday/canvas-kit/pull/3254)
192
+
193
+ The `orientation` prop on the `FormField` component no longer accepts the deprecrated `horizontal`
194
+ value. You must update your code to use `horizontalStart`. Our v12 release included a codemod to
195
+ update `horizontal` to `horizontalStart`, but we kept the prop backwards-compatible. In v13, we
196
+ dropped `horizontal` as a value, and it now requires an update.
197
+
198
+ **Before in v12**
199
+
200
+ ```tsx
201
+ <FormField orientation="horizontal">
202
+ <FormField.Label>Label</FormField.Label>
203
+ <FormField.Field>
204
+ <FormField.Input as={TextInput} />
205
+ <FormField.Field>
206
+ </FormField>
207
+ ```
208
+
209
+ **After in v13**
210
+
211
+ ```tsx
212
+ <FormField orientation="horizontalStart">
213
+ <FormField.Label>Label</FormField.Label>
214
+ <FormField.Field>
215
+ <FormField.Input as={TextInput} />
216
+ <FormField.Field>
217
+ </FormField>
218
+ ```
219
+
220
+ ### Pill (Preview) 🚨
221
+
222
+ **PR:** [#3104](https://github.com/Workday/canvas-kit/pull/3104)
223
+
224
+ A few changes have been made to `Pill` to ensure proper accessibility and styling.
225
+
226
+ - The border color on hover has been updated from `licorice400` to
227
+ `system.color.border.input.strong` (`licorice500`) to match our design specs.
228
+ - We've removed extra elements and now use
229
+ [flex box](https://developer.mozilla.org/en-US/docs/Learn_web_development/Core/CSS_layout/Flexbox)
230
+ to ensure only the label receives text overflow styles when needed.
231
+ - Setting `maxWidth` on the parent `Pill` component now styles the child elements correctly. Before
232
+ v13, `maxWidth` wasn't calculating the width of all its elements and wasn't a true pixel value.
233
+
234
+ #### Breaking Changes
235
+
236
+ - `maxWidth` has been removed from the `usePillModel`. This config was used to style subcomponents.
237
+ With the refactor to use `data-part` and
238
+ [stencils](https://workday.github.io/canvas-kit/?path=/docs/styling-basics--docs#create-stencil),
239
+ it is no longer needed on the model. You can still apply `maxWidth` on the parent `Pill` component
240
+ and the child elements will be styled accordingly.
241
+ - `Pill.Icon`'s no longer has a default value of `"add"` for the `aria-label`. You _must_ provide an
242
+ `aria-label` for `Pill.Icon` to ensure proper accessibility. Our examples have been updated to
243
+ reflect this change.
244
+ - `Pill.IconButton` no longer has a default `aria-label="remove"`. You _must_ provide an
245
+ `aria-label` for `Pill.IconButton` to ensure proper accessibility. Our examples have been updated
246
+ to reflect this change.
247
+ - `Pill.Label` is a _required_ element when using other subcomponents such as `Pill.Icon` to ensure
248
+ that the label truncates correctly.
249
+
250
+ **Before in v12**
251
+
252
+ ```tsx
253
+ import {Pill, usePillModel} from '@workday/canvas-kit-preview-react/pill';
254
+
255
+ const model = usePillModel({
256
+ maxWidth: 200,
257
+ });
258
+
259
+ <Pill model={model}>
260
+ <Pill.Icon />
261
+ Shoes
262
+ </Pill>;
263
+ ```
264
+
265
+ **After in v13**
266
+
267
+ ```tsx
268
+ import {Pill} from '@workday/canvas-kit-preview-react/pill';
269
+
270
+ <Pill maxWidth={200}>
271
+ <Pill.Icon aria-label='Add Shoes' />
272
+ <Pill.Label>Shoes</Pill.Label>
273
+ </Pill>
274
+
275
+ <Pill maxWidth={200}>
276
+ <Pill.Label>Shirts</Pill.Label>
277
+ <Pill.IconButton aria-label='Remove Shirts' />
278
+ </Pill>
279
+ ```
280
+
281
+ > 🤖 The codemod will handle the change adding `Pill.Label` if `Pill.Icon` or `Pill.IconButton` is
282
+ > being used.
283
+
284
+ ### Side Panel (Preview) 🚨
285
+
286
+ **PR:** [#3258](https://github.com/Workday/canvas-kit/pull/3258)
287
+
288
+ When we supported IE 11 we needed to use [CSS Animation](https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_animations/Using_CSS_animations) to support animation events. Since we dropped support for IE11, we can now use [CSS Transitions](https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_transitions/Using_CSS_transitions) to animate the `width` of the `SidePanel` when it's expanding or collapsing.
289
+ As part of this change, we also removed the `onAnimationStart` prop. Since moving to transitions, React doesn't support `onTransitionStart`, therefore the prop is no longer needed.
290
+
291
+ ### Tabs 💅
292
+
293
+ **PR:** [#3119](https://github.com/Workday/canvas-kit/pull/3119)
294
+
295
+ - The `disabled` icon color has been updated to use `system.color.fg.disabled`. This darker icon
296
+ color provides better contrast.
297
+
298
+ > **Note:** There should be no developer impact, and the visual changes are safe to accept.
299
+
300
+ ## Brand Refresh ⚡️
301
+
302
+ We've also updated our logos to align with Workday's brand refresh.
303
+
304
+ ### Logo Updates
305
+
306
+ We've removed the outdated Dub logos in Main and promoted the new logos that were previously in our
307
+ Preview package to Main as part of the brand refresh.
308
+
309
+ | Old Logo Name | New Logo Name |
310
+ | --------------- | ------------------ |
311
+ | `dubLogoBlue` | `dubLogoPrimary` |
312
+ | `dubLogoWhite` | `dubLogoReversed` |
313
+ | `wdayLogoBlue` | `wdayLogoPrimary` |
314
+ | `wdayLogoWhite` | `wdayLogoReversed` |
315
+
316
+ **Before in v12**
317
+
318
+ ```tsx
319
+ // Importing from Main common
320
+ import {dubLogoBlue} from "@workday/canvas-kit-react/common"
321
+
322
+ <div dangerouslySetInnerHTML={__html: dubLogoBlue} />
323
+
324
+ // Importing from Preview common
325
+ import {dubLogoPrimary} from "@workday/canvas-kit-preview-react/common"
326
+
327
+ <div dangerouslySetInnerHTML={__html: dubLogoPrimary} />
328
+ ```
329
+
330
+ **After in v13**
331
+
332
+ ```tsx
333
+ // New logos have been promoted to Main common AND renamed
334
+ import {dubLogoPrimary} from "@workday/canvas-kit-preview-react/common"
335
+
336
+ <div dangerouslySetInnerHTML={__html: dubLogoPrimary} />
337
+ ```
338
+
339
+ > 🤖 The codemod will handle the renaming all the imports and updating the import path.
340
+
341
+ ## Infrastructure
342
+
343
+ We've also made some updates to our dependencies and infrastructure.
344
+
345
+ ### Supporting `react-jsx` 🚨
346
+
347
+ We've updated the `jsx` flag in our `tsconfig` to `react-jsx`. As part of this change, we've also
348
+ updated our peer dependencies for our packages to a minimum version of `react@17.0.0`. This change
349
+ is to provide support for modern technologies like `vite` and ES modules.
350
+
351
+ #### Breaking Changes
352
+
353
+ If you're using `react@16.x.x`, you'll need to upgrade to `react@17.x.x` to use Canvas Kit v13.
354
+
355
+ **Note:** Because of this update, you may have issues with how your code is transpiles. In that
356
+ case, you will likely also need to update the way `jsx` transpiles. To do this you'll need to set
357
+ the `runtime` config to `automatic` in your Babel config presets. This feature is enabled through
358
+ the `@babel/preset-react` preset and handles importing functions which JSX transpiles. Make sure you
359
+ have this dev dependency installed before proceeding: `yarn add -D @babel/preset-react`. For more
360
+ information on setting an automatic runtime for React, please
361
+ [review Babel's documentation](https://babeljs.io/docs/babel-preset-react#react-automatic-runtime).
362
+
363
+ Here's an example Babel config. Your configuration may vary based on your application setup.
364
+
365
+ ```json
366
+ // babel.config.json
367
+ {
368
+ "presets": [
369
+ [
370
+ "@babel/preset-react",
371
+ {
372
+ "runtime": "automatic"
373
+ }
374
+ ]
375
+ ]
376
+ }
377
+ ```
378
+
379
+ ## Troubleshooting
380
+
381
+ - When upgrading to the latest major version of Canvas Kit, all related Canvas Kit packages should
382
+ be updated at the same time:
383
+ - `"@workday/canvas-kit-react": "^12.5.6"` -> `"@workday/canvas-kit-react": "^13.0.0"`
384
+ - `"@workday/canvas-kit-styling": "^12.5.6"` -> `"@workday/canvas-kit-styling": "^13.0.0"`
385
+ - `"@workday/canvas-kit-preview-react": "^12.5.6"` ->
386
+ `"@workday/canvas-kit-preview-react": "^13.0.0"`
387
+ - `"@workday/canvas-kit-labs-react": "^12.5.6"` -> `"@workday/canvas-kit-labs-react": "^13.0.0"`
388
+ - Our components rely on the `@workday/canvas-tokens-web` package which provides our CSS variables
389
+ and ensures the correct styling of our components. Make sure to upgrade to the latest version of
390
+ Canvas Tokens Web and install it correctly. For more information,
391
+ [view our docs](https://workday.github.io/canvas-tokens/?path=/docs/docs-getting-started--docs).
392
+
393
+ ## Contributors
394
+
395
+ This release was made possible by the following contributors:
396
+ - [@williamjstanton](https://github.com/williamjstanton)
397
+ - [@NehaAhujaa](https://github.com/NehaAhujaa)
398
+ - [@JaredMaione](https://github.com/JaredMaione)
399
+ - [@thunguyen19](https://github.com/thunguyen19)
400
+
401
+ ## Glossary
402
+
403
+ Below is a glossary of common terms we use in this upgrade guide.
404
+
405
+ ### Main
406
+
407
+ Our Main package of Canvas Kit (`@workday/canvas-kit-react`) provides components and utilities that
408
+ have undergone a full design and a11y review and is approved for use in product.
409
+
410
+ Breaking changes to code in Main will only occur during major version updates and will always be
411
+ communicated in advance and accompanied by migration strategies.
412
+
413
+ ---
414
+
415
+ ### Preview
416
+
417
+ Our Preview package of Canvas Kit (`@workday/canvas-kit-preview-react`) provides components and
418
+ utilities that have undergone a full design and a11y review and are approved for use in product. But
419
+ it may not be up to the high code standards upheld in the [Main](#main) package. Preview is
420
+ analagous to code in beta.
421
+
422
+ Breaking changes are unlikely, but possible, and can be deployed to Preview at any time without
423
+ triggering a major version update. Though we will communicate those changes in advance and provide
424
+ migration strategies.
425
+
426
+ Generally speaking, our goal is to eventually promote code from Preview to [Main](#main).
427
+ Occasionally, a component with the same name will exist in both [Main](#main) and Preview (for
428
+ example, see Segmented Control which is currently in
429
+ [Preview](/components/buttons/segmented-control/) and
430
+ [Main](https://d2krrudi3mmzzw.cloudfront.net/v8/?path=/docs/components-buttons-segmented-control--basic)).
431
+ In these cases, Preview serves as a staging ground for an improved version of the component with a
432
+ different API. The component in [Main](#main) will eventually be replaced with the one in Preview.
433
+
434
+ ---
435
+
436
+ ### Labs
437
+
438
+ Our Labs package of Canvas Kit (`@workday/canvas-kit-labs-react`) provides components and utilities
439
+ that have **not** undergone a full design and a11y review. Labs serves as an incubator space for new
440
+ and experimental code and is analagous to code in alpha.
441
+
442
+ Breaking changes can be deployed to Labs at any time without triggering a major version update and
443
+ may not be subject to the same rigor in communcation and migration strategies reserved for breaking
444
+ changes in [Preview](#preview) and [Main](#main).
445
+
446
+ ---
447
+
448
+ ## Codemod Reference
449
+
450
+ # What is a Codemod?
451
+
452
+ A codemod is a script that makes programmatic transformations on your codebase by traversing the
453
+ [AST](https://www.codeshiftcommunity.com/docs/understanding-asts), identifying patterns, and making
454
+ prescribed changes. This greatly decreases opportunities for error and reduces the number of manual
455
+ updates, which allows you to focus on changes that need your attention. **We highly recommend you
456
+ use the codemod for these reasons.**
457
+
458
+ If you're new to running codemods or if it's been a minute since you've used one, there are a few
459
+ things you'll want to keep in mind.
460
+
461
+ - Our codemods are meant to be run sequentially. For example, if you're using v8 of Canvas Kit,
462
+ you'll need to run the v9 codemod before you run v10 and so on.
463
+ - The codemod will update your code to be compatible with the specified version, but it will **not**
464
+ remove outdated dependencies or upgrade dependencies to the latest version. You'll need to upgrade
465
+ dependencies on your own.
466
+ - We recommend upgrading dependencies before running the codemod.
467
+ - Always review your `package.json` files to make sure your dependency versions look correct.
468
+ - The codemod will not handle every breaking change in v13. You will likely need to make some manual
469
+ changes to be compatible. Use our Upgrade Guide as a checklist.
470
+ - Codemods are not bulletproof.
471
+ - Conduct a thorough PR and QA review of all changes to ensure no regressions were introduced.
472
+ - As a safety precaution, we recommend committing the changes from the codemod as a single
473
+ isolated commit (separate from other changes) so you can roll back more easily if necessary.
474
+
475
+ We're here to help! Automatic changes to your codebase can feel scary. You can always reach out to
476
+ our team. We'd be very happy to walk you through the process to set you up for success.
477
+
478
+ ## Running a Codemod
479
+
480
+ ### Instructions
481
+
482
+ The easiest way to run our codemod is to use `npx` in your terminal.```sh
483
+ npx @workday/canvas-kit-codemod v${canvasKitMajorVersionNumber} [path]
484
+ ```
485
+
486
+ Be sure to provide specific directories that need to be updated via the `[path]` argument. This
487
+ decreases the amount of AST the codemod needs to traverse and reduces the chances of the script
488
+ having an error. For example, if your source code lives in `src/`, use `src/` as your `[path]`. Or,
489
+ if you have a monorepo with three packages using Canvas Kit, provide those specific packages as your
490
+ `[path]`.
491
+
492
+ Alternatively, if you're unable to run the codemod successfully using `npx`, you can install the
493
+ codemod package as a dev dependency, run it with `yarn`, and then remove the package after you're
494
+ finished.
495
+
496
+ ```sh
497
+ yarn add @workday/canvas-kit-codemod --dev
498
+ yarn canvas-kit-codemod v${canvasKitMajorVersion} [path]
499
+ yarn remove @workday/canvas-kit-codemod
500
+ ```
501
+
502
+ > **Note**: The codemod only works on `.js`, `.jsx`, `.ts`, and `.tsx` files. You'll need to
503
+ > manually edit other file types (`.json`, `.mdx`, `.md`, etc.). You may need to run your linter
504
+ > after executing the codemod, as its resulting formatting (spacing, quotes, etc.) may not match
505
+ > your project conventions.
506
+
507
+ ## Codemod Transformations for v13
508
+
509
+ The following automated transformations are available for upgrading to v13:
510
+
511
+ - **Add Pill Label**: addPillLabel
512
+ - **Promote Expandable**: promoteExpandable
513
+ - **Rename Dub Logos Imports**: renameDubLogosImports
514
+ - **Rename Dub Logos References**: renameDubLogosReferences
515
+
516
+ Run the codemod with: `npx @workday/canvas-kit-codemod v13 [path]`
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env node
2
+ export declare function main(): Promise<void>;
3
+ //# sourceMappingURL=cli.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../../../lib/cli.ts"],"names":[],"mappings":";AAKA,wBAAsB,IAAI,kBAGzB"}
@@ -0,0 +1,3 @@
1
+ import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
2
+ export declare function getServer(): McpServer;
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../lib/index.ts"],"names":[],"mappings":"AAMA,OAAO,EAAC,SAAS,EAAC,MAAM,yCAAyC,CAAC;AAKlE,wBAAgB,SAAS,cA6HxB"}
package/package.json ADDED
@@ -0,0 +1,57 @@
1
+ {
2
+ "name": "@workday/canvas-kit-mcp",
3
+ "version": "13.2.41",
4
+ "description": "MCP package for Canvas Kit",
5
+ "author": "Workday, Inc. (https://www.workday.com)",
6
+ "license": "Apache-2.0",
7
+ "type": "module",
8
+ "sideEffects": false,
9
+ "repository": {
10
+ "type": "git",
11
+ "url": "https://github.com/workday/canvas-kit.git",
12
+ "directory": "modules/mcp"
13
+ },
14
+ "bin": {
15
+ "canvas-kit-mcp": "./dist/cli.js"
16
+ },
17
+ "exports": {
18
+ ".": {
19
+ "types": "./dist/types/index.d.ts",
20
+ "default": "./dist/index.js"
21
+ },
22
+ "./lib": {
23
+ "types": "./dist/types/index.d.ts",
24
+ "default": "./dist/index.js"
25
+ }
26
+ },
27
+ "main": "./dist/index.js",
28
+ "types": "./dist/types/index.d.ts",
29
+ "files": [
30
+ "dist"
31
+ ],
32
+ "scripts": {
33
+ "build:copy": "tsx ./build/index.ts",
34
+ "build:types": "tsc --project tsconfig.build.json -d true --declarationDir dist/types --emitDeclarationOnly --pretty",
35
+ "build:mcp": "esbuild lib/index.ts --bundle --platform=node --outfile=dist/index.js --format=esm --sourcemap && esbuild lib/cli.ts --bundle --platform=node --outfile=dist/cli.js --format=esm --sourcemap",
36
+ "build": "npm-run-all build:copy build:types build:mcp",
37
+ "clean": "rimraf dist && rimraf .build-info && mkdirp dist"
38
+ },
39
+ "keywords": [
40
+ "canvas",
41
+ "canvas-kit",
42
+ "workday",
43
+ "mcp"
44
+ ],
45
+ "dependencies": {
46
+ "@modelcontextprotocol/sdk": "^1.20.2"
47
+ },
48
+ "devDependencies": {
49
+ "@types/node": "^14.0.0",
50
+ "esbuild": "^0.25.11",
51
+ "mkdirp": "^1.0.3",
52
+ "rimraf": "^5.0.0",
53
+ "tsx": "^4.7.0",
54
+ "typescript": "5.0"
55
+ },
56
+ "gitHead": "45cc5255aa2e83d7f1257ebca7b87ee0abb96689"
57
+ }