@workday/canvas-kit-docs 13.0.0-alpha.1069-next.0 → 13.0.0-alpha.1074-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 (209) hide show
  1. package/dist/es6/lib/ExampleCodeBlock.d.ts +1 -2
  2. package/dist/es6/lib/ExampleCodeBlock.d.ts.map +1 -1
  3. package/dist/es6/lib/ExampleCodeBlock.js +7 -18
  4. package/dist/es6/lib/MDXElements.d.ts +1 -2
  5. package/dist/es6/lib/MDXElements.d.ts.map +1 -1
  6. package/dist/es6/lib/MDXElements.js +4 -4
  7. package/dist/es6/lib/MoreTooltip.d.ts +1 -1
  8. package/dist/es6/lib/MoreTooltip.d.ts.map +1 -1
  9. package/dist/es6/lib/MoreTooltip.js +11 -12
  10. package/dist/es6/lib/Specifications.d.ts +1 -2
  11. package/dist/es6/lib/Specifications.d.ts.map +1 -1
  12. package/dist/es6/lib/Specifications.js +3 -20
  13. package/dist/es6/lib/StylePropsTable.d.ts +1 -2
  14. package/dist/es6/lib/StylePropsTable.d.ts.map +1 -1
  15. package/dist/es6/lib/StylePropsTable.js +6 -16
  16. package/dist/es6/lib/Table.d.ts.map +1 -1
  17. package/dist/es6/lib/Table.js +7 -7
  18. package/dist/es6/lib/Value.d.ts +3 -3
  19. package/dist/es6/lib/Value.d.ts.map +1 -1
  20. package/dist/es6/lib/Value.js +16 -51
  21. package/dist/es6/lib/docs.js +102 -29
  22. package/dist/es6/lib/stackblitzFiles/App.d.ts +1 -2
  23. package/dist/es6/lib/stackblitzFiles/App.d.ts.map +1 -1
  24. package/dist/es6/lib/stackblitzFiles/App.js +2 -5
  25. package/dist/es6/lib/stackblitzFiles/App.tsx +0 -1
  26. package/dist/es6/lib/stackblitzFiles/Demo.d.ts +1 -2
  27. package/dist/es6/lib/stackblitzFiles/Demo.d.ts.map +1 -1
  28. package/dist/es6/lib/stackblitzFiles/Demo.js +2 -2
  29. package/dist/es6/lib/stackblitzFiles/Demo.tsx +0 -2
  30. package/dist/es6/lib/stackblitzFiles/main.d.ts.map +1 -1
  31. package/dist/es6/lib/stackblitzFiles/main.js +2 -2
  32. package/dist/es6/lib/stackblitzFiles/main.tsx +0 -1
  33. package/dist/es6/lib/stackblitzFiles/packageJSONFile.js +5 -5
  34. package/dist/es6/lib/stackblitzFiles/packageJSONFile.ts +5 -5
  35. package/dist/es6/lib/widgetUtils.d.ts +5 -5
  36. package/dist/es6/lib/widgetUtils.d.ts.map +1 -1
  37. package/dist/es6/lib/widgetUtils.js +25 -54
  38. package/dist/es6/lib/widgets/array.js +2 -4
  39. package/dist/es6/lib/widgets/callExpression.js +2 -14
  40. package/dist/es6/lib/widgets/canvasColor.js +2 -2
  41. package/dist/es6/lib/widgets/component.js +2 -4
  42. package/dist/es6/lib/widgets/conditional.js +2 -12
  43. package/dist/es6/lib/widgets/enhancedComponent.js +14 -66
  44. package/dist/es6/lib/widgets/external.js +2 -4
  45. package/dist/es6/lib/widgets/function.js +7 -26
  46. package/dist/es6/lib/widgets/intersection.js +2 -3
  47. package/dist/es6/lib/widgets/model.js +3 -19
  48. package/dist/es6/lib/widgets/object.js +2 -2
  49. package/dist/es6/lib/widgets/parenthesis.js +2 -5
  50. package/dist/es6/lib/widgets/primitives.js +9 -27
  51. package/dist/es6/lib/widgets/qualifiedName.js +2 -5
  52. package/dist/es6/lib/widgets/symbol.js +2 -2
  53. package/dist/es6/lib/widgets/tuple.js +2 -5
  54. package/dist/es6/lib/widgets/typeParameter.js +2 -13
  55. package/dist/es6/lib/widgets/union.js +4 -10
  56. package/dist/es6/mdx/installBlock.d.ts +1 -2
  57. package/dist/es6/mdx/installBlock.d.ts.map +1 -1
  58. package/dist/es6/mdx/installBlock.js +2 -6
  59. package/dist/es6/mdx/style-props/examples/Background.d.ts +1 -2
  60. package/dist/es6/mdx/style-props/examples/Background.d.ts.map +1 -1
  61. package/dist/es6/mdx/style-props/examples/Background.js +2 -5
  62. package/dist/es6/mdx/style-props/examples/Border.d.ts +1 -2
  63. package/dist/es6/mdx/style-props/examples/Border.d.ts.map +1 -1
  64. package/dist/es6/mdx/style-props/examples/Border.js +2 -5
  65. package/dist/es6/mdx/style-props/examples/Color.d.ts +1 -2
  66. package/dist/es6/mdx/style-props/examples/Color.d.ts.map +1 -1
  67. package/dist/es6/mdx/style-props/examples/Color.js +2 -5
  68. package/dist/es6/mdx/style-props/examples/Depth.d.ts +1 -2
  69. package/dist/es6/mdx/style-props/examples/Depth.d.ts.map +1 -1
  70. package/dist/es6/mdx/style-props/examples/Depth.js +2 -5
  71. package/dist/es6/mdx/style-props/examples/Flex.d.ts +1 -2
  72. package/dist/es6/mdx/style-props/examples/Flex.d.ts.map +1 -1
  73. package/dist/es6/mdx/style-props/examples/Flex.js +2 -14
  74. package/dist/es6/mdx/style-props/examples/FlexItem.d.ts +1 -2
  75. package/dist/es6/mdx/style-props/examples/FlexItem.d.ts.map +1 -1
  76. package/dist/es6/mdx/style-props/examples/FlexItem.js +2 -13
  77. package/dist/es6/mdx/style-props/examples/Grid.d.ts +1 -2
  78. package/dist/es6/mdx/style-props/examples/Grid.d.ts.map +1 -1
  79. package/dist/es6/mdx/style-props/examples/Grid.js +2 -6
  80. package/dist/es6/mdx/style-props/examples/GridItem.d.ts +1 -2
  81. package/dist/es6/mdx/style-props/examples/GridItem.d.ts.map +1 -1
  82. package/dist/es6/mdx/style-props/examples/GridItem.js +2 -6
  83. package/dist/es6/mdx/style-props/examples/Layout.d.ts +1 -2
  84. package/dist/es6/mdx/style-props/examples/Layout.d.ts.map +1 -1
  85. package/dist/es6/mdx/style-props/examples/Layout.js +2 -5
  86. package/dist/es6/mdx/style-props/examples/Other.d.ts +1 -2
  87. package/dist/es6/mdx/style-props/examples/Other.d.ts.map +1 -1
  88. package/dist/es6/mdx/style-props/examples/Other.js +2 -5
  89. package/dist/es6/mdx/style-props/examples/Position.d.ts +1 -2
  90. package/dist/es6/mdx/style-props/examples/Position.d.ts.map +1 -1
  91. package/dist/es6/mdx/style-props/examples/Position.js +2 -5
  92. package/dist/es6/mdx/style-props/examples/Space.d.ts +1 -2
  93. package/dist/es6/mdx/style-props/examples/Space.d.ts.map +1 -1
  94. package/dist/es6/mdx/style-props/examples/Space.js +2 -8
  95. package/dist/es6/mdx/style-props/examples/Text.d.ts +1 -2
  96. package/dist/es6/mdx/style-props/examples/Text.d.ts.map +1 -1
  97. package/dist/es6/mdx/style-props/examples/Text.js +2 -5
  98. package/dist/es6/mdx/versionsTable.d.ts +1 -2
  99. package/dist/es6/mdx/versionsTable.d.ts.map +1 -1
  100. package/dist/es6/mdx/versionsTable.js +8 -21
  101. package/dist/es6/mdx/welcomePage.d.ts +1 -2
  102. package/dist/es6/mdx/welcomePage.d.ts.map +1 -1
  103. package/dist/es6/mdx/welcomePage.js +2 -38
  104. package/dist/mdx/13.0-UPGRADE-GUIDE.mdx +16 -0
  105. package/dist/mdx/labs-react/expandable/examples/Avatar.tsx +0 -2
  106. package/dist/mdx/labs-react/expandable/examples/Depth.tsx +0 -2
  107. package/dist/mdx/labs-react/expandable/examples/EndIcon.tsx +0 -2
  108. package/dist/mdx/labs-react/expandable/examples/LongTitle.tsx +0 -2
  109. package/dist/mdx/labs-react/expandable/examples/RTL.tsx +0 -2
  110. package/dist/mdx/labs-react/expandable/examples/StartIcon.tsx +0 -2
  111. package/dist/mdx/preview-react/information-highlight/examples/Caution.tsx +0 -1
  112. package/dist/mdx/preview-react/information-highlight/examples/Critical.tsx +0 -1
  113. package/dist/mdx/preview-react/information-highlight/examples/Informational.tsx +0 -1
  114. package/dist/mdx/preview-react/pill/examples/WithReadOnly.tsx +0 -2
  115. package/dist/mdx/preview-react/segmented-control/examples/Disabled.tsx +0 -1
  116. package/dist/mdx/preview-react/segmented-control/examples/RTL.tsx +0 -1
  117. package/dist/mdx/preview-react/segmented-control/examples/Vertical.tsx +0 -1
  118. package/dist/mdx/preview-react/select/examples/Top Label/Alert.tsx +0 -2
  119. package/dist/mdx/preview-react/select/examples/Top Label/Default.tsx +0 -2
  120. package/dist/mdx/preview-react/select/examples/Top Label/DefaultWithCustomOptions.tsx +0 -2
  121. package/dist/mdx/preview-react/select/examples/Top Label/DefaultWithSimpleOptions.tsx +0 -2
  122. package/dist/mdx/preview-react/select/examples/Top Label/Disabled.tsx +0 -2
  123. package/dist/mdx/preview-react/select/examples/Top Label/Error.tsx +0 -2
  124. package/dist/mdx/preview-react/select/examples/Top Label/Grow.tsx +0 -2
  125. package/dist/mdx/preview-react/select/examples/Top Label/Scrollable.tsx +0 -2
  126. package/dist/mdx/preview-react/select/examples/storiesData.tsx +0 -1
  127. package/dist/mdx/preview-react/text-area/examples/Alert.tsx +1 -4
  128. package/dist/mdx/preview-react/text-input/examples/Alert.tsx +1 -4
  129. package/dist/mdx/preview-react/text-input/examples/ThemedAlert.tsx +1 -4
  130. package/dist/mdx/react/action-bar/examples/Basic.tsx +0 -1
  131. package/dist/mdx/react/action-bar/examples/DeleteAction.tsx +0 -2
  132. package/dist/mdx/react/action-bar/examples/Icons.tsx +0 -2
  133. package/dist/mdx/react/avatar/avatar/examples/Basic.tsx +0 -1
  134. package/dist/mdx/react/avatar/avatar/examples/Button.tsx +0 -1
  135. package/dist/mdx/react/avatar/avatar/examples/CustomStyles.tsx +0 -1
  136. package/dist/mdx/react/avatar/avatar/examples/Image.tsx +0 -1
  137. package/dist/mdx/react/avatar/avatar/examples/LazyLoad.tsx +0 -1
  138. package/dist/mdx/react/avatar/avatar/examples/ObjectFit.tsx +0 -1
  139. package/dist/mdx/react/avatar/avatar/examples/Size.tsx +0 -1
  140. package/dist/mdx/react/avatar/avatar/examples/Variant.tsx +0 -1
  141. package/dist/mdx/react/banner/examples/Error.tsx +0 -2
  142. package/dist/mdx/react/banner/examples/Sticky.tsx +0 -1
  143. package/dist/mdx/react/banner/examples/StickyAnimation.tsx +42 -26
  144. package/dist/mdx/react/breadcrumbs/examples/Basic.tsx +0 -1
  145. package/dist/mdx/react/button/button/examples/Delete.tsx +0 -2
  146. package/dist/mdx/react/button/button/examples/ExternalHyperlink.tsx +0 -2
  147. package/dist/mdx/react/button/button/examples/Hyperlink.tsx +0 -2
  148. package/dist/mdx/react/button/button/examples/Primary.tsx +0 -2
  149. package/dist/mdx/react/color-picker/color-preview/examples/Basic.tsx +0 -1
  150. package/dist/mdx/react/dialog/examples/DialogWithFallbackPlacements.tsx +0 -1
  151. package/dist/mdx/react/modal/examples/Basic.tsx +0 -2
  152. package/dist/mdx/react/modal/examples/IframeTest.tsx +0 -1
  153. package/dist/mdx/react/modal/examples/ModalWithPopup.tsx +0 -1
  154. package/dist/mdx/react/modal/examples/StackedModals.tsx +0 -1
  155. package/dist/mdx/react/pagination/examples/CustomRange.tsx +0 -1
  156. package/dist/mdx/react/pagination/examples/GoToForm.tsx +0 -1
  157. package/dist/mdx/react/pagination/examples/JumpControls.tsx +0 -1
  158. package/dist/mdx/react/popup/examples/Basic.tsx +0 -2
  159. package/dist/mdx/react/popup/examples/CloseOnTargetHiddenTest.tsx +0 -1
  160. package/dist/mdx/react/popup/examples/ComboboxWithinPopup.tsx +0 -1
  161. package/dist/mdx/react/popup/examples/MultiplePopups.tsx +0 -2
  162. package/dist/mdx/react/popup/examples/PopupWithFallbackPlacements.tsx +0 -1
  163. package/dist/mdx/react/popup/examples/PopupWithNonHidablePopup.tsx +0 -1
  164. package/dist/mdx/react/popup/examples/ReturnFocusTest.tsx +0 -2
  165. package/dist/mdx/react/popup/examples/TooltipReturnFocus.tsx +0 -1
  166. package/dist/mdx/react/select/examples/MenuHeight.tsx +0 -1
  167. package/dist/mdx/react/tabs/examples/Basic.tsx +0 -1
  168. package/dist/mdx/react/tabs/examples/DisabledTab.tsx +0 -1
  169. package/dist/mdx/react/tabs/examples/NamedTabs.tsx +0 -1
  170. package/dist/mdx/react/tabs/examples/RightToLeft.tsx +0 -1
  171. package/dist/mdx/react/text-input/examples/Basic.tsx +0 -3
  172. package/dist/mdx/react/toast/examples/Basic.tsx +0 -2
  173. package/dist/mdx/react/toast/examples/ToastAlert.tsx +0 -2
  174. package/dist/mdx/react/toast/examples/ToastDialog.tsx +0 -2
  175. package/dist/mdx/react/tooltip/examples/Default.tsx +0 -2
  176. package/dist/mdx/react/tooltip/examples/DescribeType.tsx +0 -2
  177. package/dist/mdx/react/tooltip/examples/DescriptionType.tsx +0 -2
  178. package/dist/mdx/react/tooltip/examples/Muted.tsx +0 -2
  179. package/dist/mdx/style-props/examples/Background.tsx +0 -1
  180. package/dist/mdx/style-props/examples/Border.tsx +0 -1
  181. package/dist/mdx/style-props/examples/Color.tsx +0 -1
  182. package/dist/mdx/style-props/examples/Depth.tsx +0 -1
  183. package/dist/mdx/style-props/examples/Flex.tsx +0 -1
  184. package/dist/mdx/style-props/examples/FlexItem.tsx +0 -1
  185. package/dist/mdx/style-props/examples/Grid.tsx +0 -1
  186. package/dist/mdx/style-props/examples/GridItem.tsx +0 -1
  187. package/dist/mdx/style-props/examples/Layout.tsx +0 -1
  188. package/dist/mdx/style-props/examples/Other.tsx +0 -1
  189. package/dist/mdx/style-props/examples/Position.tsx +0 -1
  190. package/dist/mdx/style-props/examples/Space.tsx +0 -1
  191. package/dist/mdx/style-props/examples/Text.tsx +0 -1
  192. package/lib/StylePropsTable.tsx +0 -1
  193. package/lib/Table.tsx +0 -1
  194. package/lib/stackblitzFiles/App.tsx +0 -1
  195. package/lib/stackblitzFiles/Demo.tsx +0 -2
  196. package/lib/stackblitzFiles/main.tsx +0 -1
  197. package/lib/widgets/array.tsx +0 -2
  198. package/lib/widgets/canvasColor.tsx +0 -2
  199. package/lib/widgets/component.tsx +0 -2
  200. package/lib/widgets/conditional.tsx +0 -2
  201. package/lib/widgets/external.tsx +0 -1
  202. package/lib/widgets/model.tsx +0 -2
  203. package/lib/widgets/parenthesis.tsx +0 -2
  204. package/lib/widgets/primitives.tsx +1 -5
  205. package/lib/widgets/qualifiedName.tsx +0 -2
  206. package/lib/widgets/symbol.tsx +0 -2
  207. package/lib/widgets/tuple.tsx +0 -2
  208. package/lib/widgets/typeParameter.tsx +0 -2
  209. package/package.json +6 -6
@@ -1,4 +1,3 @@
1
- import * as React from 'react';
2
1
  import {
3
2
  CanvasProvider,
4
3
  ContentDirection,
@@ -1,3 +1,2 @@
1
- import React from 'react';
2
- export declare const Demo: ({}: {}) => React.JSX.Element;
1
+ export declare const Demo: ({}: {}) => import("react/jsx-runtime").JSX.Element;
3
2
  //# sourceMappingURL=Demo.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Demo.d.ts","sourceRoot":"","sources":["../../../../lib/stackblitzFiles/Demo.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,eAAO,MAAM,IAAI,+BAAsB,CAAC"}
1
+ {"version":3,"file":"Demo.d.ts","sourceRoot":"","sources":["../../../../lib/stackblitzFiles/Demo.tsx"],"names":[],"mappings":"AAAA,eAAO,MAAM,IAAI,qDAAsB,CAAC"}
@@ -1,2 +1,2 @@
1
- import React from 'react';
2
- export const Demo = ({}) => React.createElement("div", null);
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ export const Demo = ({}) => _jsx("div", {});
@@ -1,3 +1 @@
1
- import React from 'react';
2
-
3
1
  export const Demo = ({}) => <div></div>;
@@ -1 +1 @@
1
- {"version":3,"file":"main.d.ts","sourceRoot":"","sources":["../../../../lib/stackblitzFiles/main.tsx"],"names":[],"mappings":"AAOA,OAAO,oDAAoD,CAAC;AAC5D,OAAO,qDAAqD,CAAC;AAC7D,OAAO,sDAAsD,CAAC"}
1
+ {"version":3,"file":"main.d.ts","sourceRoot":"","sources":["../../../../lib/stackblitzFiles/main.tsx"],"names":[],"mappings":"AAMA,OAAO,oDAAoD,CAAC;AAC5D,OAAO,qDAAqD,CAAC;AAC7D,OAAO,sDAAsD,CAAC"}
@@ -1,4 +1,4 @@
1
- import * as React from 'react';
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { createRoot } from 'react-dom/client';
3
3
  import { fonts } from '@workday/canvas-kit-react-fonts';
4
4
  import { system } from '@workday/canvas-tokens-web';
@@ -22,4 +22,4 @@ injectGlobal({
22
22
  });
23
23
  const container = document.getElementById('root');
24
24
  const root = createRoot(container);
25
- root.render(React.createElement(App, null));
25
+ root.render(_jsx(App, {}));
@@ -1,4 +1,3 @@
1
- import * as React from 'react';
2
1
  import {createRoot} from 'react-dom/client';
3
2
  import {fonts} from '@workday/canvas-kit-react-fonts';
4
3
  import {system} from '@workday/canvas-tokens-web';
@@ -18,11 +18,11 @@ export const packageJSONFile = `{
18
18
  "@emotion/react": "11.11.4",
19
19
  "@types/react": "18.2.60",
20
20
  "@types/react-dom": "18.2.19",
21
- "@workday/canvas-kit-labs-react": "12.5.1",
22
- "@workday/canvas-kit-preview-react": "12.5.1",
23
- "@workday/canvas-kit-react": "12.5.1",
24
- "@workday/canvas-kit-react-fonts": "^12.5.1",
25
- "@workday/canvas-kit-styling": "12.5.1",
21
+ "@workday/canvas-kit-labs-react": "12.5.4",
22
+ "@workday/canvas-kit-preview-react": "12.5.4",
23
+ "@workday/canvas-kit-react": "12.5.4",
24
+ "@workday/canvas-kit-react-fonts": "^12.5.4",
25
+ "@workday/canvas-kit-styling": "12.5.4",
26
26
  "@workday/canvas-system-icons-web": "3.0.22",
27
27
  "@workday/canvas-tokens-web": "2.0.0"
28
28
  },
@@ -18,11 +18,11 @@ export const packageJSONFile = `{
18
18
  "@emotion/react": "11.11.4",
19
19
  "@types/react": "18.2.60",
20
20
  "@types/react-dom": "18.2.19",
21
- "@workday/canvas-kit-labs-react": "12.5.1",
22
- "@workday/canvas-kit-preview-react": "12.5.1",
23
- "@workday/canvas-kit-react": "12.5.1",
24
- "@workday/canvas-kit-react-fonts": "^12.5.1",
25
- "@workday/canvas-kit-styling": "12.5.1",
21
+ "@workday/canvas-kit-labs-react": "12.5.4",
22
+ "@workday/canvas-kit-preview-react": "12.5.4",
23
+ "@workday/canvas-kit-react": "12.5.4",
24
+ "@workday/canvas-kit-react-fonts": "^12.5.4",
25
+ "@workday/canvas-kit-styling": "12.5.4",
26
26
  "@workday/canvas-system-icons-web": "3.0.22",
27
27
  "@workday/canvas-tokens-web": "2.0.0"
28
28
  },
@@ -27,11 +27,11 @@ interface HeadingProps {
27
27
  * relative heading levels.
28
28
  */
29
29
  export declare const Heading: import("@workday/canvas-kit-react/common").ElementComponent<"h4", HeadingProps>;
30
- export declare function renderTypeParameters(typeParameters?: types.TypeParameter[]): "" | React.JSX.Element;
30
+ export declare function renderTypeParameters(typeParameters?: types.TypeParameter[]): "" | import("react/jsx-runtime").JSX.Element;
31
31
  export interface SymbolDialogProps {
32
32
  value: types.SymbolValue;
33
33
  }
34
- export declare const SymbolDialog: ({ value }: SymbolDialogProps) => React.JSX.Element;
34
+ export declare const SymbolDialog: ({ value }: SymbolDialogProps) => import("react/jsx-runtime").JSX.Element;
35
35
  export declare const useDoc: (criteria: ValueDocProps) => types.ExportedSymbol<types.Value> | undefined;
36
36
  export interface ValueDocProps {
37
37
  name: string;
@@ -41,11 +41,11 @@ export interface ValueDocProps {
41
41
  * Renders the `<Value>` of a exported symbol without any wrapper. This should be used when nesting
42
42
  * inside a `<SymbolDoc>` component.
43
43
  */
44
- export declare const SymbolValue: (props: ValueDocProps) => React.JSX.Element;
44
+ export declare const SymbolValue: (props: ValueDocProps) => import("react/jsx-runtime").JSX.Element;
45
45
  /**
46
46
  * Renders just the description of an exported symbol.
47
47
  */
48
- export declare const SymbolDescription: (props: ValueDocProps) => React.JSX.Element | null;
48
+ export declare const SymbolDescription: (props: ValueDocProps) => import("react/jsx-runtime").JSX.Element | null;
49
49
  export interface SymbolDocProps extends ValueDocProps, StyledType {
50
50
  /**
51
51
  * `SymbolDoc` can support heading levels inside widgets. The `headingStart` determines the
@@ -76,6 +76,6 @@ export interface SymbolDocProps extends ValueDocProps, StyledType {
76
76
  * Renders an exported symbol as a doc object. This will render JSDoc tags, description and setup
77
77
  * rendering contexts for headers.
78
78
  */
79
- export declare const SymbolDoc: ({ name, fileName, headingStart, hideDescription, hideHeading, descriptionOverride, meta, ...elemProps }: SymbolDocProps) => React.JSX.Element;
79
+ export declare const SymbolDoc: ({ name, fileName, headingStart, hideDescription, hideHeading, descriptionOverride, meta, ...elemProps }: SymbolDocProps) => import("react/jsx-runtime").JSX.Element;
80
80
  export {};
81
81
  //# sourceMappingURL=widgetUtils.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"widgetUtils.d.ts","sourceRoot":"","sources":["../../../lib/widgetUtils.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAAkB,UAAU,EAAC,MAAM,kCAAkC,CAAC;AAS7E,OAAO,KAAK,KAAK,MAAM,oBAAoB,CAAC;AAc5C,yFAAyF;AACzF,eAAO,MAAM,aAAa,mCAAmD,CAAC;AAC9E;;;GAGG;AACH,eAAO,MAAM,mBAAmB,uBAAyB,CAAC;AAE1D;;GAEG;AACH,eAAO,MAAM,kBAAkB,uBAAyB,CAAC;AAEzD;;;;GAIG;AACH,wBAAgB,MAAM,CAAC,KAAK,EAAE,MAAM,UAEnC;AAED,wBAAgB,UAAU,CAAC,KAAK,EAAE,MAAM,UAEvC;AAED,UAAU,YAAY;IACpB,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AACD;;;GAGG;AACH,eAAO,MAAM,OAAO,iFAOlB,CAAC;AAEH,wBAAgB,oBAAoB,CAAC,cAAc,CAAC,EAAE,KAAK,CAAC,aAAa,EAAE,0BAiB1E;AAID,MAAM,WAAW,iBAAiB;IAChC,KAAK,EAAE,KAAK,CAAC,WAAW,CAAC;CAC1B;AAED,eAAO,MAAM,YAAY,cAAa,iBAAiB,sBAkItD,CAAC;AAsEF,eAAO,MAAM,MAAM,aAAc,aAAa,kDAK7C,CAAC;AAEF,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED;;;GAGG;AACH,eAAO,MAAM,WAAW,UAAW,aAAa,sBAI/C,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,iBAAiB,UAAW,aAAa,6BAIrD,CAAC;AAEF,MAAM,WAAW,cAAe,SAAQ,aAAa,EAAE,UAAU;IAC/D;;;;OAIG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;;OAGG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB;;;OAGG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B;;;;OAIG;IACH,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;;GAGG;AACH,eAAO,MAAM,SAAS,4GASnB,cAAc,sBAsDhB,CAAC"}
1
+ {"version":3,"file":"widgetUtils.d.ts","sourceRoot":"","sources":["../../../lib/widgetUtils.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAAkB,UAAU,EAAC,MAAM,kCAAkC,CAAC;AAS7E,OAAO,KAAK,KAAK,MAAM,oBAAoB,CAAC;AAc5C,yFAAyF;AACzF,eAAO,MAAM,aAAa,mCAAmD,CAAC;AAC9E;;;GAGG;AACH,eAAO,MAAM,mBAAmB,uBAAyB,CAAC;AAE1D;;GAEG;AACH,eAAO,MAAM,kBAAkB,uBAAyB,CAAC;AAEzD;;;;GAIG;AACH,wBAAgB,MAAM,CAAC,KAAK,EAAE,MAAM,UAEnC;AAED,wBAAgB,UAAU,CAAC,KAAK,EAAE,MAAM,UAEvC;AAED,UAAU,YAAY;IACpB,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AACD;;;GAGG;AACH,eAAO,MAAM,OAAO,iFAOlB,CAAC;AAEH,wBAAgB,oBAAoB,CAAC,cAAc,CAAC,EAAE,KAAK,CAAC,aAAa,EAAE,gDAiB1E;AAID,MAAM,WAAW,iBAAiB;IAChC,KAAK,EAAE,KAAK,CAAC,WAAW,CAAC;CAC1B;AAED,eAAO,MAAM,YAAY,cAAa,iBAAiB,4CAkItD,CAAC;AAsEF,eAAO,MAAM,MAAM,aAAc,aAAa,kDAK7C,CAAC;AAEF,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED;;;GAGG;AACH,eAAO,MAAM,WAAW,UAAW,aAAa,4CAI/C,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,iBAAiB,UAAW,aAAa,mDAIrD,CAAC;AAEF,MAAM,WAAW,cAAe,SAAQ,aAAa,EAAE,UAAU;IAC/D;;;;OAIG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;;OAGG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB;;;OAGG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B;;;;OAIG;IACH,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;;GAGG;AACH,eAAO,MAAM,SAAS,4GASnB,cAAc,4CAsDhB,CAAC"}
@@ -1,3 +1,4 @@
1
+ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
1
2
  import React from 'react';
2
3
  import styled from '@emotion/styled';
3
4
  import { createComponent } from '@workday/canvas-kit-react/common';
@@ -47,18 +48,13 @@ export const Heading = createComponent('h4')({
47
48
  Component({ headingOffset = 0, ...elemProps }) {
48
49
  const headingLevel = React.useContext(HeadingLevelContext);
49
50
  const as = `h${headingLevel + headingOffset}`; // Make Typescript happy
50
- return React.createElement(MDX, { as: as, ...elemProps });
51
+ return _jsx(MDX, { as: as, ...elemProps });
51
52
  },
52
53
  });
53
54
  export function renderTypeParameters(typeParameters) {
54
- return typeParameters && typeParameters.length ? (React.createElement(RenderContext.Provider, { value: "inline" },
55
- React.createElement("span", null, "<"),
56
- typeParameters.map((p, index) => {
57
- return (React.createElement(React.Fragment, { key: index },
58
- index !== 0 && React.createElement("span", { className: "token punctuation" }, ", "),
59
- React.createElement(Value, { value: p })));
60
- }),
61
- React.createElement("span", null, ">"))) : ('');
55
+ return typeParameters && typeParameters.length ? (_jsxs(RenderContext.Provider, { value: "inline", children: [_jsx("span", { children: "<" }), typeParameters.map((p, index) => {
56
+ return (_jsxs(React.Fragment, { children: [index !== 0 && _jsx("span", { className: "token punctuation", children: ", " }), _jsx(Value, { value: p })] }, index));
57
+ }), _jsx("span", { children: ">" })] })) : ('');
62
58
  }
63
59
  const ButtonHyperLink = Hyperlink.as('button');
64
60
  export const SymbolDialog = ({ value }) => {
@@ -89,41 +85,23 @@ export const SymbolDialog = ({ value }) => {
89
85
  };
90
86
  // If we're inside a nested context, we render a Hyperlink. This button will update the dialog instead of rendering a new one.
91
87
  if (nestedContext) {
92
- return (React.createElement(ButtonHyperLink, { style: {
88
+ return (_jsx(ButtonHyperLink, { style: {
93
89
  border: 'none',
94
90
  background: 'transparent',
95
91
  fontSize: 'inherit',
96
92
  fontFamily: 'inherit',
97
- }, onClick: handleTargetClick }, value.displayName || value.name));
93
+ }, onClick: handleTargetClick, children: value.displayName || value.name }));
98
94
  }
99
- return (React.createElement(NestedContext.Provider, { value: true },
100
- React.createElement(Dialog, { model: model },
101
- React.createElement(Dialog.Target, { as: ButtonHyperLink, className: "token symbol", onClick: handleTargetClick, style: {
102
- border: 'none',
103
- background: 'transparent',
104
- fontSize: 'inherit',
105
- fontFamily: 'inherit',
106
- }, "aria-haspopup": "true" }, value.displayName || value.name),
107
- renderTypeParameters(value.typeParameters),
108
- React.createElement(Dialog.Popper, null,
109
- React.createElement(Dialog.Card, { maxHeight: "50vh", maxWidth: "90vh", minWidth: '600px' },
110
- React.createElement(Dialog.CloseIcon, null),
111
- React.createElement(Dialog.Heading, null,
112
- value.name,
113
- " "),
114
- breadcrumbsList.length > 1 && (React.createElement(Breadcrumbs, { "aria-label": "Breadcrumbs" },
115
- React.createElement(Breadcrumbs.List, { paddingX: "xxs" }, breadcrumbsList.map((item, index) => {
116
- return (React.createElement(React.Fragment, null, index === breadcrumbsList.length - 1 ? (React.createElement(Breadcrumbs.CurrentItem, { key: index }, item)) : (React.createElement(Breadcrumbs.Item, { key: index },
117
- React.createElement(Breadcrumbs.Link, { onClick: e => handleBreadcrumbClick(e, index), href: '#' }, item)))));
118
- })))),
119
- React.createElement(Dialog.Body, null,
120
- React.createElement(RenderContext.Provider, { value: "table" },
121
- React.createElement(IndentLevelContext.Provider, { value: 0 }, symbol ? (React.createElement(SymbolDoc, { name: breadcrumbsList.length >= 1
122
- ? breadcrumbsList[breadcrumbsList.length - 1]
123
- : value.name, headingStart: 3, hideHeading: true })) : (React.createElement(React.Fragment, null,
124
- React.createElement("p", null, "Basic type information:"),
125
- React.createElement("pre", null,
126
- React.createElement("code", null, value.name))))))))))));
95
+ return (_jsx(NestedContext.Provider, { value: true, children: _jsxs(Dialog, { model: model, children: [_jsx(Dialog.Target, { as: ButtonHyperLink, className: "token symbol", onClick: handleTargetClick, style: {
96
+ border: 'none',
97
+ background: 'transparent',
98
+ fontSize: 'inherit',
99
+ fontFamily: 'inherit',
100
+ }, "aria-haspopup": "true", children: value.displayName || value.name }), renderTypeParameters(value.typeParameters), _jsx(Dialog.Popper, { children: _jsxs(Dialog.Card, { maxHeight: "50vh", maxWidth: "90vh", minWidth: '600px', children: [_jsx(Dialog.CloseIcon, {}), _jsxs(Dialog.Heading, { children: [value.name, " "] }), breadcrumbsList.length > 1 && (_jsx(Breadcrumbs, { "aria-label": "Breadcrumbs", children: _jsx(Breadcrumbs.List, { paddingX: "xxs", children: breadcrumbsList.map((item, index) => {
101
+ return (_jsx(_Fragment, { children: index === breadcrumbsList.length - 1 ? (_jsx(Breadcrumbs.CurrentItem, { children: item }, index)) : (_jsx(Breadcrumbs.Item, { children: _jsx(Breadcrumbs.Link, { onClick: e => handleBreadcrumbClick(e, index), href: '#', children: item }) }, index)) }));
102
+ }) }) })), _jsx(Dialog.Body, { children: _jsx(RenderContext.Provider, { value: "table", children: _jsx(IndentLevelContext.Provider, { value: 0, children: symbol ? (_jsx(SymbolDoc, { name: breadcrumbsList.length >= 1
103
+ ? breadcrumbsList[breadcrumbsList.length - 1]
104
+ : value.name, headingStart: 3, hideHeading: true })) : (_jsxs(_Fragment, { children: [_jsx("p", { children: "Basic type information:" }), _jsx("pre", { children: _jsx("code", { children: value.name }) })] })) }) }) })] }) })] }) }));
127
105
  };
128
106
  function createColor(color) {
129
107
  return {
@@ -161,15 +139,12 @@ const StyledSymbolDoc = styled('div')({
161
139
  function getSymbolDocChildren(doc, meta, name) {
162
140
  if (!doc) {
163
141
  // We're within a symbol doc context, but there's no information, so we still want to render the basic type information
164
- return (React.createElement(React.Fragment, null,
165
- React.createElement("p", null, "Basic type information:"),
166
- React.createElement("pre", null,
167
- React.createElement("code", null, name))));
142
+ return (_jsxs(_Fragment, { children: [_jsx("p", { children: "Basic type information:" }), _jsx("pre", { children: _jsx("code", { children: name }) })] }));
168
143
  }
169
144
  if (doc && doc.type) {
170
- return React.createElement(Value, { value: doc.type, doc: doc, meta: meta });
145
+ return _jsx(Value, { value: doc.type, doc: doc, meta: meta });
171
146
  }
172
- return React.createElement("div", null, "Not found");
147
+ return _jsx("div", { children: "Not found" });
173
148
  }
174
149
  function findDoc({ name, fileName }) {
175
150
  const doc = (docs || []).find(d => {
@@ -198,7 +173,7 @@ export const SymbolValue = (props) => {
198
173
  */
199
174
  export const SymbolDescription = (props) => {
200
175
  const doc = useDoc(props);
201
- return doc ? React.createElement(MdxJSToJSX, null, doc.description) : null;
176
+ return doc ? _jsx(MdxJSToJSX, { children: doc.description }) : null;
202
177
  };
203
178
  /**
204
179
  * Renders an exported symbol as a doc object. This will render JSDoc tags, description and setup
@@ -232,15 +207,11 @@ export const SymbolDoc = ({ name, fileName, headingStart = 3, hideDescription =
232
207
  'function',
233
208
  'callExpression',
234
209
  ].includes((doc === null || doc === void 0 ? void 0 : doc.type.kind) || 'notFound');
235
- const contents = requiresCodeWrapper ? (React.createElement("code", { style: { display: 'block' } }, children)) : (children);
236
- const symbolDocContents = (React.createElement(StyledSymbolDoc, { ...elemProps },
237
- React.createElement(HeadingLevelContext.Provider, { value: headingStart },
238
- !hideHeading && React.createElement(Heading, { id: `${name.toLowerCase()}-api` }, name),
239
- !hideDescription && doc && (React.createElement(MdxJSToJSX, null, descriptionOverride || doc.description)),
240
- contents)));
241
- return symbolDocBreadcrumb === undefined ? (React.createElement(SymbolDocWrapper, null, symbolDocContents)) : (symbolDocContents);
210
+ const contents = requiresCodeWrapper ? (_jsx("code", { style: { display: 'block' }, children: children })) : (children);
211
+ const symbolDocContents = (_jsx(StyledSymbolDoc, { ...elemProps, children: _jsxs(HeadingLevelContext.Provider, { value: headingStart, children: [!hideHeading && _jsx(Heading, { id: `${name.toLowerCase()}-api`, children: name }), !hideDescription && doc && (_jsx(MdxJSToJSX, { children: descriptionOverride || doc.description })), contents] }) }));
212
+ return symbolDocBreadcrumb === undefined ? (_jsx(SymbolDocWrapper, { children: symbolDocContents })) : (symbolDocContents);
242
213
  };
243
214
  const SymbolDocWrapper = ({ children }) => {
244
215
  const [breadcrumbsList, updateBreadcrumbs] = React.useState([]);
245
- return (React.createElement(SymbolDocBreadcrumbsContext.Provider, { value: { breadcrumbsList, updateBreadcrumbs } }, children));
216
+ return (_jsx(SymbolDocBreadcrumbsContext.Provider, { value: { breadcrumbsList, updateBreadcrumbs }, children: children }));
246
217
  };
@@ -1,8 +1,6 @@
1
- import React from 'react';
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { registerWidget, Value } from '../Value';
3
3
  import { RenderContext } from '../widgetUtils';
4
4
  registerWidget('array', ({ value }) => {
5
- return (React.createElement(RenderContext.Provider, { value: "inline" },
6
- React.createElement(Value, { value: value.value }),
7
- React.createElement("span", { className: "token punctuation" }, "[]")));
5
+ return (_jsxs(RenderContext.Provider, { value: "inline", children: [_jsx(Value, { value: value.value }), _jsx("span", { className: "token punctuation", children: "[]" })] }));
8
6
  });
@@ -1,20 +1,8 @@
1
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
1
2
  import React from 'react';
2
3
  import { registerWidget, Value } from '../Value';
3
4
  import { IndentLevelContext, indent } from '../widgetUtils';
4
5
  registerWidget('callExpression', ({ value }) => {
5
6
  const level = React.useContext(IndentLevelContext);
6
- return (React.createElement(React.Fragment, null,
7
- value.name && React.createElement(Value, { value: value.name }),
8
- React.createElement("span", { className: "token punctuation" }, "("),
9
- React.createElement(React.Fragment, null, value.parameters.map((p, index) => (React.createElement(React.Fragment, { key: index },
10
- index !== 0 && React.createElement("span", { className: "token punctuation" }, ", "),
11
- value.parameters.length > 1 && (React.createElement(React.Fragment, null,
12
- React.createElement("br", null),
13
- indent(level + 1))),
14
- value.parameters.length > 1 ? (React.createElement(IndentLevelContext.Provider, { value: level + 1 },
15
- React.createElement(Value, { value: p }))) : (React.createElement(Value, { value: p })),
16
- index === value.parameters.length - 1 && index > 0 && (React.createElement(React.Fragment, null,
17
- React.createElement("br", null),
18
- indent(level))))))),
19
- React.createElement("span", { className: "token punctuation" }, ")")));
7
+ return (_jsxs(_Fragment, { children: [value.name && _jsx(Value, { value: value.name }), _jsx("span", { className: "token punctuation", children: "(" }), _jsx(_Fragment, { children: value.parameters.map((p, index) => (_jsxs(React.Fragment, { children: [index !== 0 && _jsx("span", { className: "token punctuation", children: ", " }), value.parameters.length > 1 && (_jsxs(_Fragment, { children: [_jsx("br", {}), indent(level + 1)] })), value.parameters.length > 1 ? (_jsx(IndentLevelContext.Provider, { value: level + 1, children: _jsx(Value, { value: p }) })) : (_jsx(Value, { value: p })), index === value.parameters.length - 1 && index > 0 && (_jsxs(_Fragment, { children: [_jsx("br", {}), indent(level)] }))] }, index))) }), _jsx("span", { className: "token punctuation", children: ")" })] }));
20
8
  });
@@ -1,7 +1,7 @@
1
- import React from 'react';
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { colors } from '@workday/canvas-kit-react/tokens';
3
3
  import { ColorPicker } from '@workday/canvas-kit-preview-react/color-picker';
4
4
  import { registerWidget } from '../Value';
5
5
  registerWidget('canvasColor', () => {
6
- return (React.createElement(ColorPicker, { style: { width: 170 }, colorSet: Object.values(colors), onColorChange: () => { } }));
6
+ return (_jsx(ColorPicker, { style: { width: 170 }, colorSet: Object.values(colors), onColorChange: () => { } }));
7
7
  });
@@ -1,9 +1,7 @@
1
- import React from 'react';
1
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { PropertiesTable, registerWidget } from '../Value';
3
3
  import { Heading } from '../widgetUtils';
4
4
  registerWidget('component', ({ value, doc, meta }) => {
5
5
  var _a;
6
- return (React.createElement(React.Fragment, null,
7
- React.createElement(Heading, { id: `${(_a = value.displayName) === null || _a === void 0 ? void 0 : _a.toLowerCase()}-props-api`, headingOffset: 1 }, "Props"),
8
- React.createElement(PropertiesTable, { properties: value.props })));
6
+ return (_jsxs(_Fragment, { children: [_jsx(Heading, { id: `${(_a = value.displayName) === null || _a === void 0 ? void 0 : _a.toLowerCase()}-props-api`, headingOffset: 1, children: "Props" }), _jsx(PropertiesTable, { properties: value.props })] }));
9
7
  });
@@ -1,15 +1,5 @@
1
- import React from 'react';
1
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { registerWidget, Value } from '../Value';
3
3
  registerWidget('conditional', ({ value }) => {
4
- return (React.createElement(React.Fragment, null,
5
- React.createElement(Value, { value: value.check }),
6
- " ",
7
- React.createElement("span", { className: "token keyword" }, "extends"),
8
- ' ',
9
- React.createElement(Value, { value: value.extends }),
10
- " ? ",
11
- React.createElement(Value, { value: value.trueType }),
12
- " :",
13
- ' ',
14
- React.createElement(Value, { value: value.falseType })));
4
+ return (_jsxs(_Fragment, { children: [_jsx(Value, { value: value.check }), " ", _jsx("span", { className: "token keyword", children: "extends" }), ' ', _jsx(Value, { value: value.extends }), " ? ", _jsx(Value, { value: value.trueType }), " :", ' ', _jsx(Value, { value: value.falseType })] }));
15
5
  });
@@ -1,3 +1,4 @@
1
+ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
1
2
  import React from 'react';
2
3
  import { Expandable } from '@workday/canvas-kit-labs-react/expandable';
3
4
  import { defaultJSDoc } from '../../docgen/docParser';
@@ -42,73 +43,20 @@ registerWidget('enhancedComponent', ({ value, doc, meta }) => {
42
43
  // model. If we detect another container, only render the intro and a link to the container
43
44
  // component
44
45
  if (parentComponentName && value.componentType === 'container') {
45
- return (React.createElement(React.Fragment, null,
46
- React.createElement(MDX, { as: "p" },
47
- "This component references the",
48
- ' ',
49
- React.createElement(ParentComponentNameContext.Provider, { value: "" },
50
- React.createElement(ParentComponentJSDocContext.Provider, { value: defaultJSDoc },
51
- React.createElement(SymbolDialog, { value: { kind: 'symbol', name: value.displayName || '' } }))),
52
- ' ',
53
- "component.")));
46
+ return (_jsx(_Fragment, { children: _jsxs(MDX, { as: "p", children: ["This component references the", ' ', _jsx(ParentComponentNameContext.Provider, { value: "", children: _jsx(ParentComponentJSDocContext.Provider, { value: defaultJSDoc, children: _jsx(SymbolDialog, { value: { kind: 'symbol', name: value.displayName || '' } }) }) }), ' ', "component."] }) }));
54
47
  }
55
- return (React.createElement(React.Fragment, null,
56
- value.styleComponent ? (React.createElement(React.Fragment, null,
57
- React.createElement(Heading, { headingOffset: 1, id: parentComponentName
58
- ? `${parentComponentName.toLowerCase()}-layout-component-api`
59
- : `${(_a = value.displayName) === null || _a === void 0 ? void 0 : _a.toLowerCase()}-layout-component-api` }, "Layout Component"),
60
- React.createElement(MDX, { as: "p" },
61
- React.createElement("code", null, value.displayName || parentComponentName),
62
- " supports all props from the",
63
- React.createElement("code", null,
64
- React.createElement(ParentComponentJSDocContext.Provider, { value: defaultJSDoc },
65
- React.createElement(SymbolDialog, { value: value.styleComponent }))),
66
- "layout component."))) : null,
67
- React.createElement(Heading, { headingOffset: 1, id: parentComponentName
68
- ? `${parentComponentName.toLowerCase()}-props-api`
69
- : `${(_b = value.displayName) === null || _b === void 0 ? void 0 : _b.toLowerCase()}-props-api` }, "Props"),
70
- value.baseElement && (React.createElement(ParentComponentJSDocContext.Provider, { value: defaultJSDoc },
71
- React.createElement(MDX, { as: "p" },
72
- "Props extend from ",
73
- React.createElement(Value, { value: value.baseElement }),
74
- ". Changing the ",
75
- React.createElement("code", null, "as"),
76
- " prop will change the element interface."))),
77
- value.componentType === 'container' && value.model ? (React.createElement(MDX, { as: "p" },
78
- "Props extend from ",
79
- React.createElement(SymbolDialog, { value: { kind: 'symbol', name: `${value.model}Config` } }),
80
- ". If a ",
81
- React.createElement("code", null, "model"),
82
- " is passed, props from ",
83
- React.createElement("code", null,
84
- value.model,
85
- "Config"),
86
- " are ignored.")) : null,
87
- Object.keys(groups).map(key => {
88
- return (React.createElement(React.Fragment, { key: key }, key === 'Local' ? (React.createElement(PropertiesTable, { properties: groups[key] })) : (React.createElement(Expandable, null,
89
- React.createElement(Expandable.Target, { headingLevel: "h5" },
90
- React.createElement(Expandable.Title, null, key),
91
- React.createElement(Expandable.Icon, { iconPosition: "end" })),
92
- React.createElement(Expandable.Content, null,
93
- React.createElement(PropertiesTable, { properties: groups[key] }))))));
94
- }),
95
- value.elemPropsHook ? (React.createElement(SymbolDoc, { name: value.elemPropsHook, headingStart: headingLevel + 1 })) : null,
96
- value.subComponents
97
- ? value.subComponents.map((c, i) => {
98
- var _a;
99
- return (React.createElement(React.Fragment, { key: i },
100
- React.createElement(Heading, { id: `${(_a = value.displayName) === null || _a === void 0 ? void 0 : _a.toLowerCase()}.${c.name.toLowerCase()}-api` },
101
- parentComponentName ? parentComponentName : value.displayName,
102
- ".",
103
- c.name),
104
- React.createElement(ParentComponentNameContext.Provider, { value: `${parentComponentName ? parentComponentName : value.displayName}.${c.name}` },
105
- React.createElement(ParentComponentJSDocContext.Provider, { value: c },
106
- React.createElement(SymbolDoc, { name: c.symbol, fileName: c.declarations[c.declarations.length - 1].filePath, hideHeading: true, descriptionOverride: c.description })))));
107
- })
108
- : null,
109
- value.componentType === 'container' && value.model ? (React.createElement(React.Fragment, null,
110
- React.createElement(Heading, { id: `${(_c = value.displayName) === null || _c === void 0 ? void 0 : _c.toLowerCase()}-model-api`, headingOffset: -1 }, "Model"),
111
- React.createElement(SymbolDoc, { name: `use${value.model}` }))) : null));
48
+ return (_jsxs(_Fragment, { children: [value.styleComponent ? (_jsxs(_Fragment, { children: [_jsx(Heading, { headingOffset: 1, id: parentComponentName
49
+ ? `${parentComponentName.toLowerCase()}-layout-component-api`
50
+ : `${(_a = value.displayName) === null || _a === void 0 ? void 0 : _a.toLowerCase()}-layout-component-api`, children: "Layout Component" }), _jsxs(MDX, { as: "p", children: [_jsx("code", { children: value.displayName || parentComponentName }), " supports all props from the", _jsx("code", { children: _jsx(ParentComponentJSDocContext.Provider, { value: defaultJSDoc, children: _jsx(SymbolDialog, { value: value.styleComponent }) }) }), "layout component."] })] })) : null, _jsx(Heading, { headingOffset: 1, id: parentComponentName
51
+ ? `${parentComponentName.toLowerCase()}-props-api`
52
+ : `${(_b = value.displayName) === null || _b === void 0 ? void 0 : _b.toLowerCase()}-props-api`, children: "Props" }), value.baseElement && (_jsx(ParentComponentJSDocContext.Provider, { value: defaultJSDoc, children: _jsxs(MDX, { as: "p", children: ["Props extend from ", _jsx(Value, { value: value.baseElement }), ". Changing the ", _jsx("code", { children: "as" }), " prop will change the element interface."] }) })), value.componentType === 'container' && value.model ? (_jsxs(MDX, { as: "p", children: ["Props extend from ", _jsx(SymbolDialog, { value: { kind: 'symbol', name: `${value.model}Config` } }), ". If a ", _jsx("code", { children: "model" }), " is passed, props from ", _jsxs("code", { children: [value.model, "Config"] }), " are ignored."] })) : null, Object.keys(groups).map(key => {
53
+ return (_jsx(React.Fragment, { children: key === 'Local' ? (_jsx(PropertiesTable, { properties: groups[key] })) : (_jsxs(Expandable, { children: [_jsxs(Expandable.Target, { headingLevel: "h5", children: [_jsx(Expandable.Title, { children: key }), _jsx(Expandable.Icon, { iconPosition: "end" })] }), _jsx(Expandable.Content, { children: _jsx(PropertiesTable, { properties: groups[key] }) })] })) }, key));
54
+ }), value.elemPropsHook ? (_jsx(SymbolDoc, { name: value.elemPropsHook, headingStart: headingLevel + 1 })) : null, value.subComponents
55
+ ? value.subComponents.map((c, i) => {
56
+ var _a;
57
+ return (_jsxs(React.Fragment, { children: [_jsxs(Heading, { id: `${(_a = value.displayName) === null || _a === void 0 ? void 0 : _a.toLowerCase()}.${c.name.toLowerCase()}-api`, children: [parentComponentName ? parentComponentName : value.displayName, ".", c.name] }), _jsx(ParentComponentNameContext.Provider, { value: `${parentComponentName ? parentComponentName : value.displayName}.${c.name}`, children: _jsx(ParentComponentJSDocContext.Provider, { value: c, children: _jsx(SymbolDoc, { name: c.symbol, fileName: c.declarations[c.declarations.length - 1].filePath, hideHeading: true, descriptionOverride: c.description }) }) })] }, i));
58
+ })
59
+ : null, value.componentType === 'container' && value.model ? (_jsxs(_Fragment, { children: [_jsx(Heading, { id: `${(_c = value.displayName) === null || _c === void 0 ? void 0 : _c.toLowerCase()}-model-api`, headingOffset: -1, children: "Model" }), _jsx(SymbolDoc, { name: `use${value.model}` })] })) : null] }));
112
60
  });
113
61
  function groupProps(props) {
114
62
  const categories = { Local: [] };
@@ -1,7 +1,5 @@
1
- import React from 'react';
1
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { ExternalHyperlink } from '@workday/canvas-kit-react/button';
3
3
  import { renderTypeParameters } from '../widgetUtils';
4
4
  import { registerWidget } from '../Value';
5
- registerWidget('external', ({ value }) => (React.createElement(React.Fragment, null,
6
- React.createElement(ExternalHyperlink, { href: value.url, iconLabel: "Open link in new window" }, value.name),
7
- renderTypeParameters(value.typeParameters))));
5
+ registerWidget('external', ({ value }) => (_jsxs(_Fragment, { children: [_jsx(ExternalHyperlink, { href: value.url, iconLabel: "Open link in new window", children: value.name }), renderTypeParameters(value.typeParameters)] })));
@@ -1,3 +1,4 @@
1
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
1
2
  import React from 'react';
2
3
  import { DescriptionTooltip } from '../DescriptionTooltip';
3
4
  import { MdxJSToJSX } from '../MDXElements';
@@ -5,32 +6,12 @@ import { registerWidget, Value } from '../Value';
5
6
  import { RenderContext, IndentLevelContext, indent, renderTypeParameters } from '../widgetUtils';
6
7
  registerWidget('function', ({ value }) => {
7
8
  const level = React.useContext(IndentLevelContext);
8
- return (React.createElement(RenderContext.Provider, { value: "inline" },
9
- value.name && React.createElement(Value, { value: value.name }),
10
- renderTypeParameters(value.typeParameters),
11
- React.createElement("span", { className: "token punctuation" }, "("),
12
- React.createElement(React.Fragment, null, value.parameters.map((p, index) => (React.createElement(React.Fragment, { key: index },
13
- index !== 0 && React.createElement("span", { className: "token punctuation" }, ", "),
14
- value.parameters.length > 1 && (React.createElement(React.Fragment, null,
15
- React.createElement("br", null),
16
- indent(level + 1))),
17
- value.parameters.length > 1 ? (React.createElement(IndentLevelContext.Provider, { value: level + 1 },
18
- React.createElement(Value, { value: p }))) : (React.createElement(Value, { value: p })),
19
- index === value.parameters.length - 1 && index > 0 && (React.createElement(React.Fragment, null,
20
- React.createElement("br", null),
21
- indent(level))))))),
22
- React.createElement("span", { className: "token operator" }, ")\u00A0=>\u00A0"),
23
- React.createElement(Value, { value: value.returnType })));
9
+ return (_jsxs(RenderContext.Provider, { value: "inline", children: [value.name && _jsx(Value, { value: value.name }), renderTypeParameters(value.typeParameters), _jsx("span", { className: "token punctuation", children: "(" }), _jsx(_Fragment, { children: value.parameters.map((p, index) => (_jsxs(React.Fragment, { children: [index !== 0 && _jsx("span", { className: "token punctuation", children: ", " }), value.parameters.length > 1 && (_jsxs(_Fragment, { children: [_jsx("br", {}), indent(level + 1)] })), value.parameters.length > 1 ? (_jsx(IndentLevelContext.Provider, { value: level + 1, children: _jsx(Value, { value: p }) })) : (_jsx(Value, { value: p })), index === value.parameters.length - 1 && index > 0 && (_jsxs(_Fragment, { children: [_jsx("br", {}), indent(level)] }))] }, index))) }), _jsx("span", { className: "token operator", children: ")\u00A0=>\u00A0" }), _jsx(Value, { value: value.returnType })] }));
24
10
  });
25
11
  registerWidget('parameter', ({ value }) => {
26
- return (React.createElement(RenderContext.Provider, { value: "inline" },
27
- value.description ? (React.createElement(DescriptionTooltip, { style: { maxWidth: '50em' }, title: React.createElement(MdxJSToJSX, null, value.description) },
28
- React.createElement("span", { className: "token property", style: {
29
- cursor: 'pointer',
30
- textDecoration: 'underline',
31
- textDecorationStyle: 'dotted',
32
- } }, value.name))) : (React.createElement("span", { className: "token property" }, value.name)),
33
- React.createElement("span", { className: "token punctuation" }, ":"),
34
- "\u00A0",
35
- React.createElement(Value, { value: value.type })));
12
+ return (_jsxs(RenderContext.Provider, { value: "inline", children: [value.description ? (_jsx(DescriptionTooltip, { style: { maxWidth: '50em' }, title: _jsx(MdxJSToJSX, { children: value.description }), children: _jsx("span", { className: "token property", style: {
13
+ cursor: 'pointer',
14
+ textDecoration: 'underline',
15
+ textDecorationStyle: 'dotted',
16
+ }, children: value.name }) })) : (_jsx("span", { className: "token property", children: value.name })), _jsx("span", { className: "token punctuation", children: ":" }), "\u00A0", _jsx(Value, { value: value.type })] }));
36
17
  });
@@ -1,8 +1,7 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
1
2
  import React from 'react';
2
3
  import { registerWidget, Value } from '../Value';
3
4
  import { RenderContext } from '../widgetUtils';
4
5
  registerWidget('intersection', ({ value }) => {
5
- return (React.createElement(RenderContext.Provider, { value: "inline" }, value.value.map((v, i) => (React.createElement(React.Fragment, { key: i },
6
- i !== 0 && React.createElement("span", { className: "token punctuation" }, " & "),
7
- React.createElement(Value, { value: v }))))));
6
+ return (_jsx(RenderContext.Provider, { value: "inline", children: value.value.map((v, i) => (_jsxs(React.Fragment, { children: [i !== 0 && _jsx("span", { className: "token punctuation", children: " & " }), _jsx(Value, { value: v })] }, i))) }));
8
7
  });
@@ -1,25 +1,9 @@
1
- import React from 'react';
1
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { PropertiesTable, registerWidget, Value } from '../Value';
3
3
  import { Heading } from '../widgetUtils';
4
4
  registerWidget('model', ({ value }) => {
5
- return (React.createElement(React.Fragment, null,
6
- React.createElement(Heading, null, "State"),
7
- React.createElement(PropertiesTable, { properties: value.state, showDefault: false }),
8
- React.createElement(Heading, null, "Events"),
9
- React.createElement(PropertiesTable, { properties: value.events, showDefault: false }),
10
- value.modelProperties.length > 0 && (React.createElement(React.Fragment, null,
11
- React.createElement(Heading, null, "Additional Properties"),
12
- React.createElement(PropertiesTable, { properties: value.modelProperties, showDefault: false })))));
5
+ return (_jsxs(_Fragment, { children: [_jsx(Heading, { children: "State" }), _jsx(PropertiesTable, { properties: value.state, showDefault: false }), _jsx(Heading, { children: "Events" }), _jsx(PropertiesTable, { properties: value.events, showDefault: false }), value.modelProperties.length > 0 && (_jsxs(_Fragment, { children: [_jsx(Heading, { children: "Additional Properties" }), _jsx(PropertiesTable, { properties: value.modelProperties, showDefault: false })] }))] }));
13
6
  });
14
7
  registerWidget('modelHook', ({ value, doc }) => {
15
- return (React.createElement("code", null,
16
- React.createElement("span", { className: "token symbol" }, value.name),
17
- ' ',
18
- React.createElement("span", { className: "token punctuation" }, "("),
19
- React.createElement("span", { className: "value symbol" }, "config"),
20
- ":",
21
- ' ',
22
- React.createElement(Value, { value: { kind: 'symbol', name: `${value.name.replace('use', '')}Config` } }),
23
- React.createElement("span", { className: "token punctuation" }, "): "),
24
- React.createElement(Value, { value: { kind: 'symbol', name: `${value.name.replace('use', '')}` } })));
8
+ return (_jsxs("code", { children: [_jsx("span", { className: "token symbol", children: value.name }), ' ', _jsx("span", { className: "token punctuation", children: "(" }), _jsx("span", { className: "value symbol", children: "config" }), ":", ' ', _jsx(Value, { value: { kind: 'symbol', name: `${value.name.replace('use', '')}Config` } }), _jsx("span", { className: "token punctuation", children: "): " }), _jsx(Value, { value: { kind: 'symbol', name: `${value.name.replace('use', '')}` } })] }));
25
9
  });
@@ -1,8 +1,8 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
1
2
  import React from 'react';
2
3
  import { PropertiesInline, PropertiesTable, registerWidget } from '../Value';
3
4
  import { RenderContext } from '../widgetUtils';
4
5
  registerWidget('object', ({ value }) => {
5
6
  const renderContext = React.useContext(RenderContext);
6
- return renderContext === 'inline' ? (React.createElement(PropertiesInline, { properties: value.properties })) : (React.createElement(RenderContext.Provider, { value: "inline" },
7
- React.createElement(PropertiesTable, { properties: value.properties })));
7
+ return renderContext === 'inline' ? (_jsx(PropertiesInline, { properties: value.properties })) : (_jsx(RenderContext.Provider, { value: "inline", children: _jsx(PropertiesTable, { properties: value.properties }) }));
8
8
  });
@@ -1,8 +1,5 @@
1
- import React from 'react';
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { registerWidget, Value } from '../Value';
3
3
  registerWidget('parenthesis', ({ value }) => {
4
- return (React.createElement("span", null,
5
- React.createElement("span", { className: "token punctuation" }, "("),
6
- React.createElement(Value, { value: value.value }),
7
- React.createElement("span", { className: "token punctuation" }, ")")));
4
+ return (_jsxs("span", { children: [_jsx("span", { className: "token punctuation", children: "(" }), _jsx(Value, { value: value.value }), _jsx("span", { className: "token punctuation", children: ")" })] }));
8
5
  });