@workday/canvas-kit-docs 13.0.0-alpha.998-next.0 → 13.0.1

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 (296) 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 +53 -28
  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 +6 -6
  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 +270155 -169429
  22. package/dist/es6/lib/stackblitzFiles/.eslintrc.cjs.txt +15 -0
  23. package/dist/es6/lib/stackblitzFiles/App.d.ts +2 -0
  24. package/dist/es6/lib/stackblitzFiles/App.d.ts.map +1 -0
  25. package/dist/es6/lib/stackblitzFiles/App.js +17 -0
  26. package/dist/es6/lib/stackblitzFiles/App.tsx +33 -0
  27. package/dist/es6/lib/stackblitzFiles/Demo.d.ts +2 -0
  28. package/dist/es6/lib/stackblitzFiles/Demo.d.ts.map +1 -0
  29. package/dist/es6/lib/stackblitzFiles/Demo.js +2 -0
  30. package/dist/es6/lib/stackblitzFiles/Demo.tsx +1 -0
  31. package/dist/es6/lib/stackblitzFiles/index.html +13 -0
  32. package/dist/es6/lib/stackblitzFiles/main.d.ts +4 -0
  33. package/dist/es6/lib/stackblitzFiles/main.d.ts.map +1 -0
  34. package/dist/es6/lib/stackblitzFiles/main.js +25 -0
  35. package/dist/es6/lib/stackblitzFiles/main.tsx +27 -0
  36. package/dist/es6/lib/stackblitzFiles/packageJSONFile.d.ts +2 -0
  37. package/dist/es6/lib/stackblitzFiles/packageJSONFile.d.ts.map +1 -0
  38. package/dist/es6/lib/stackblitzFiles/packageJSONFile.js +42 -0
  39. package/dist/es6/lib/stackblitzFiles/packageJSONFile.ts +42 -0
  40. package/dist/es6/lib/stackblitzFiles/tsconfig.json +26 -0
  41. package/dist/es6/lib/stackblitzFiles/tsconfig.node.json +12 -0
  42. package/dist/es6/lib/stackblitzFiles/vite-env.d.ts +1 -0
  43. package/dist/es6/lib/stackblitzFiles/vite.config.d.ts +4 -0
  44. package/dist/es6/lib/stackblitzFiles/vite.config.d.ts.map +1 -0
  45. package/dist/es6/lib/stackblitzFiles/vite.config.js +7 -0
  46. package/dist/es6/lib/stackblitzFiles/vite.config.ts +10 -0
  47. package/dist/es6/lib/widgetUtils.d.ts +5 -5
  48. package/dist/es6/lib/widgetUtils.d.ts.map +1 -1
  49. package/dist/es6/lib/widgetUtils.js +25 -54
  50. package/dist/es6/lib/widgets/array.js +2 -4
  51. package/dist/es6/lib/widgets/callExpression.js +2 -14
  52. package/dist/es6/lib/widgets/canvasColor.js +2 -2
  53. package/dist/es6/lib/widgets/component.js +2 -4
  54. package/dist/es6/lib/widgets/conditional.js +2 -12
  55. package/dist/es6/lib/widgets/enhancedComponent.js +15 -67
  56. package/dist/es6/lib/widgets/external.js +2 -4
  57. package/dist/es6/lib/widgets/function.js +7 -26
  58. package/dist/es6/lib/widgets/intersection.js +2 -3
  59. package/dist/es6/lib/widgets/model.js +3 -19
  60. package/dist/es6/lib/widgets/object.js +2 -2
  61. package/dist/es6/lib/widgets/parenthesis.js +2 -5
  62. package/dist/es6/lib/widgets/primitives.js +9 -27
  63. package/dist/es6/lib/widgets/qualifiedName.js +2 -5
  64. package/dist/es6/lib/widgets/symbol.js +2 -2
  65. package/dist/es6/lib/widgets/tuple.js +2 -5
  66. package/dist/es6/lib/widgets/typeParameter.js +2 -13
  67. package/dist/es6/lib/widgets/union.js +4 -10
  68. package/dist/es6/mdx/installBlock.d.ts +1 -2
  69. package/dist/es6/mdx/installBlock.d.ts.map +1 -1
  70. package/dist/es6/mdx/installBlock.js +2 -6
  71. package/dist/es6/mdx/style-props/examples/Background.d.ts +1 -2
  72. package/dist/es6/mdx/style-props/examples/Background.d.ts.map +1 -1
  73. package/dist/es6/mdx/style-props/examples/Background.js +2 -5
  74. package/dist/es6/mdx/style-props/examples/Border.d.ts +1 -2
  75. package/dist/es6/mdx/style-props/examples/Border.d.ts.map +1 -1
  76. package/dist/es6/mdx/style-props/examples/Border.js +2 -5
  77. package/dist/es6/mdx/style-props/examples/Color.d.ts +1 -2
  78. package/dist/es6/mdx/style-props/examples/Color.d.ts.map +1 -1
  79. package/dist/es6/mdx/style-props/examples/Color.js +2 -5
  80. package/dist/es6/mdx/style-props/examples/Depth.d.ts +1 -2
  81. package/dist/es6/mdx/style-props/examples/Depth.d.ts.map +1 -1
  82. package/dist/es6/mdx/style-props/examples/Depth.js +2 -5
  83. package/dist/es6/mdx/style-props/examples/Flex.d.ts +1 -2
  84. package/dist/es6/mdx/style-props/examples/Flex.d.ts.map +1 -1
  85. package/dist/es6/mdx/style-props/examples/Flex.js +2 -14
  86. package/dist/es6/mdx/style-props/examples/FlexItem.d.ts +1 -2
  87. package/dist/es6/mdx/style-props/examples/FlexItem.d.ts.map +1 -1
  88. package/dist/es6/mdx/style-props/examples/FlexItem.js +2 -13
  89. package/dist/es6/mdx/style-props/examples/Grid.d.ts +1 -2
  90. package/dist/es6/mdx/style-props/examples/Grid.d.ts.map +1 -1
  91. package/dist/es6/mdx/style-props/examples/Grid.js +2 -6
  92. package/dist/es6/mdx/style-props/examples/GridItem.d.ts +1 -2
  93. package/dist/es6/mdx/style-props/examples/GridItem.d.ts.map +1 -1
  94. package/dist/es6/mdx/style-props/examples/GridItem.js +2 -6
  95. package/dist/es6/mdx/style-props/examples/Layout.d.ts +1 -2
  96. package/dist/es6/mdx/style-props/examples/Layout.d.ts.map +1 -1
  97. package/dist/es6/mdx/style-props/examples/Layout.js +2 -5
  98. package/dist/es6/mdx/style-props/examples/Other.d.ts +1 -2
  99. package/dist/es6/mdx/style-props/examples/Other.d.ts.map +1 -1
  100. package/dist/es6/mdx/style-props/examples/Other.js +2 -5
  101. package/dist/es6/mdx/style-props/examples/Position.d.ts +1 -2
  102. package/dist/es6/mdx/style-props/examples/Position.d.ts.map +1 -1
  103. package/dist/es6/mdx/style-props/examples/Position.js +2 -5
  104. package/dist/es6/mdx/style-props/examples/Space.d.ts +1 -2
  105. package/dist/es6/mdx/style-props/examples/Space.d.ts.map +1 -1
  106. package/dist/es6/mdx/style-props/examples/Space.js +2 -8
  107. package/dist/es6/mdx/style-props/examples/Text.d.ts +1 -2
  108. package/dist/es6/mdx/style-props/examples/Text.d.ts.map +1 -1
  109. package/dist/es6/mdx/style-props/examples/Text.js +2 -5
  110. package/dist/es6/mdx/versionsTable.d.ts +1 -2
  111. package/dist/es6/mdx/versionsTable.d.ts.map +1 -1
  112. package/dist/es6/mdx/versionsTable.js +23 -49
  113. package/dist/es6/mdx/welcomePage.d.ts +1 -2
  114. package/dist/es6/mdx/welcomePage.d.ts.map +1 -1
  115. package/dist/es6/mdx/welcomePage.js +37 -49
  116. package/dist/mdx/12.0-UPGRADE-GUIDE.mdx +1 -1
  117. package/dist/mdx/13.0-UPGRADE-GUIDE.mdx +454 -0
  118. package/dist/mdx/CODEMODS.mdx +58 -0
  119. package/dist/mdx/CONTRIBUTING.mdx +8 -0
  120. package/dist/mdx/TESTING.mdx +34 -0
  121. package/dist/mdx/preview-react/_examples/mdx/{Forms.mdx → FormLibraryExample.mdx} +0 -2
  122. package/dist/mdx/preview-react/{InformationHighlight → information-highlight}/examples/Basic.tsx +1 -1
  123. package/dist/mdx/preview-react/{InformationHighlight → information-highlight}/examples/Body.tsx +1 -1
  124. package/dist/mdx/preview-react/{InformationHighlight → information-highlight}/examples/Caution.tsx +1 -2
  125. package/dist/mdx/preview-react/{InformationHighlight → information-highlight}/examples/Critical.tsx +5 -12
  126. package/dist/mdx/preview-react/{InformationHighlight → information-highlight}/examples/CustomIconCritical.tsx +1 -1
  127. package/dist/mdx/preview-react/{InformationHighlight → information-highlight}/examples/Heading.tsx +1 -1
  128. package/dist/mdx/preview-react/information-highlight/examples/Informational.tsx +55 -0
  129. package/dist/mdx/preview-react/{InformationHighlight → information-highlight}/examples/RTL.tsx +1 -1
  130. package/dist/mdx/preview-react/loading-sparkles/examples/Basic.tsx +2 -2
  131. package/dist/mdx/preview-react/multi-select/examples/Basic.tsx +1 -1
  132. package/dist/mdx/preview-react/multi-select/examples/Complex.tsx +1 -1
  133. package/dist/mdx/preview-react/multi-select/examples/Controlled.tsx +1 -1
  134. package/dist/mdx/preview-react/multi-select/examples/Icons.tsx +1 -1
  135. package/dist/mdx/preview-react/multi-select/examples/Searching.tsx +1 -1
  136. package/dist/mdx/preview-react/pill/Pill.mdx +18 -9
  137. package/dist/mdx/preview-react/pill/examples/Basic.tsx +14 -8
  138. package/dist/mdx/preview-react/pill/examples/CustomStyles.tsx +45 -0
  139. package/dist/mdx/preview-react/pill/examples/WithAvatar.tsx +16 -10
  140. package/dist/mdx/preview-react/pill/examples/WithCount.tsx +12 -6
  141. package/dist/mdx/preview-react/pill/examples/WithList.tsx +15 -5
  142. package/dist/mdx/preview-react/pill/examples/WithReadOnly.tsx +8 -5
  143. package/dist/mdx/preview-react/pill/examples/WithRemovable.tsx +23 -11
  144. package/dist/mdx/preview-react/segmented-control/examples/Disabled.tsx +0 -1
  145. package/dist/mdx/preview-react/segmented-control/examples/RTL.tsx +0 -1
  146. package/dist/mdx/preview-react/segmented-control/examples/Vertical.tsx +0 -1
  147. package/dist/mdx/preview-react/select/examples/Left Label/DefaultWithCustomOptionsLeft.tsx +1 -1
  148. package/dist/mdx/preview-react/select/examples/Left Label/DefaultWithSimpleOptionsLeft.tsx +1 -1
  149. package/dist/mdx/preview-react/select/examples/Top Label/Alert.tsx +0 -2
  150. package/dist/mdx/preview-react/select/examples/Top Label/Default.tsx +0 -2
  151. package/dist/mdx/preview-react/select/examples/Top Label/DefaultWithCustomOptions.tsx +0 -2
  152. package/dist/mdx/preview-react/select/examples/Top Label/DefaultWithSimpleOptions.tsx +0 -2
  153. package/dist/mdx/preview-react/select/examples/Top Label/Disabled.tsx +0 -2
  154. package/dist/mdx/preview-react/select/examples/Top Label/Error.tsx +0 -2
  155. package/dist/mdx/preview-react/select/examples/Top Label/Grow.tsx +0 -2
  156. package/dist/mdx/preview-react/select/examples/Top Label/Scrollable.tsx +0 -2
  157. package/dist/mdx/preview-react/select/examples/storiesData.tsx +0 -1
  158. package/dist/mdx/preview-react/side-panel/SidePanel.mdx +28 -3
  159. package/dist/mdx/preview-react/side-panel/examples/AlwaysOpen.tsx +36 -17
  160. package/dist/mdx/preview-react/side-panel/examples/Basic.tsx +40 -34
  161. package/dist/mdx/preview-react/side-panel/examples/ExternalControl.tsx +47 -23
  162. package/dist/mdx/preview-react/side-panel/examples/HiddenName.tsx +24 -5
  163. package/dist/mdx/preview-react/side-panel/examples/OnExpandedChange.tsx +22 -6
  164. package/dist/mdx/preview-react/side-panel/examples/OnStateTransition.tsx +24 -9
  165. package/dist/mdx/preview-react/side-panel/examples/RightOrigin.tsx +39 -40
  166. package/dist/mdx/preview-react/side-panel/examples/Variant.tsx +36 -36
  167. package/dist/mdx/preview-react/text-area/examples/Alert.tsx +1 -4
  168. package/dist/mdx/preview-react/text-input/examples/Alert.tsx +1 -4
  169. package/dist/mdx/preview-react/text-input/examples/ThemedAlert.tsx +1 -4
  170. package/dist/mdx/react/_examples/Tooltips.mdx +15 -0
  171. package/dist/mdx/react/_examples/examples/Tooltips/ListOfUploadedFiles.tsx +38 -0
  172. package/dist/mdx/react/_examples/mdx/SidePanel.mdx +18 -1
  173. package/dist/mdx/react/_examples/mdx/examples/GlobalHeader.tsx +1 -1
  174. package/dist/mdx/react/_examples/mdx/examples/SidePanelWithNavigation.tsx +154 -116
  175. package/dist/mdx/react/_examples/mdx/examples/SidePanelWithOverlay.tsx +33 -15
  176. package/dist/mdx/react/_examples/mdx/examples/Table/WithSelectableRows.tsx +1 -1
  177. package/dist/mdx/react/action-bar/examples/Basic.tsx +0 -1
  178. package/dist/mdx/react/action-bar/examples/DeleteAction.tsx +0 -2
  179. package/dist/mdx/react/action-bar/examples/Icons.tsx +0 -2
  180. package/dist/mdx/react/avatar/avatar/examples/Basic.tsx +2 -3
  181. package/dist/mdx/react/avatar/avatar/examples/Button.tsx +3 -4
  182. package/dist/mdx/react/avatar/avatar/examples/CustomStyles.tsx +2 -3
  183. package/dist/mdx/react/avatar/avatar/examples/Image.tsx +7 -8
  184. package/dist/mdx/react/avatar/avatar/examples/LazyLoad.tsx +7 -2
  185. package/dist/mdx/react/avatar/avatar/examples/ObjectFit.tsx +9 -4
  186. package/dist/mdx/react/avatar/avatar/examples/Size.tsx +10 -11
  187. package/dist/mdx/react/avatar/avatar/examples/Variant.tsx +2 -3
  188. package/dist/mdx/react/banner/examples/Error.tsx +0 -2
  189. package/dist/mdx/react/banner/examples/Sticky.tsx +0 -1
  190. package/dist/mdx/react/banner/examples/StickyAnimation.tsx +42 -26
  191. package/dist/mdx/react/breadcrumbs/examples/Basic.tsx +0 -1
  192. package/dist/mdx/react/button/button/Button.mdx +5 -1
  193. package/dist/mdx/react/button/button/examples/CustomStyles.tsx +1 -3
  194. package/dist/mdx/react/button/button/examples/Delete.tsx +0 -2
  195. package/dist/mdx/react/button/button/examples/ExternalHyperlink.tsx +3 -3
  196. package/dist/mdx/react/button/button/examples/ExternalHyperlinkInverse.tsx +5 -1
  197. package/dist/mdx/react/button/button/examples/Hyperlink.tsx +0 -2
  198. package/dist/mdx/react/button/button/examples/Primary.tsx +0 -2
  199. package/dist/mdx/react/button/button/examples/ThemeOverrides.tsx +14 -17
  200. package/dist/mdx/react/collection/mdx/examples/MultiSelection.tsx +2 -1
  201. package/dist/mdx/react/collection/mdx/examples/Selection.tsx +2 -1
  202. package/dist/mdx/react/color-picker/color-preview/examples/Basic.tsx +0 -1
  203. package/dist/mdx/react/dialog/examples/DialogWithFallbackPlacements.tsx +0 -1
  204. package/dist/mdx/{labs-react → react}/expandable/Expandable.mdx +2 -2
  205. package/dist/mdx/{labs-react → react}/expandable/examples/Avatar.tsx +5 -7
  206. package/dist/mdx/{labs-react → react}/expandable/examples/Depth.tsx +1 -4
  207. package/dist/mdx/{labs-react → react}/expandable/examples/EndIcon.tsx +1 -3
  208. package/dist/mdx/{labs-react → react}/expandable/examples/HoistedModel.tsx +1 -1
  209. package/dist/mdx/{labs-react → react}/expandable/examples/LongTitle.tsx +2 -4
  210. package/dist/mdx/{labs-react → react}/expandable/examples/RTL.tsx +1 -3
  211. package/dist/mdx/{labs-react → react}/expandable/examples/StartIcon.tsx +1 -3
  212. package/dist/mdx/react/menu/Menu.mdx +34 -0
  213. package/dist/mdx/react/menu/examples/Grouping.tsx +32 -0
  214. package/dist/mdx/react/menu/examples/Icons.tsx +1 -1
  215. package/dist/mdx/react/menu/examples/Nested.tsx +49 -0
  216. package/dist/mdx/react/menu/examples/NestedDynamic.tsx +105 -0
  217. package/dist/mdx/react/modal/examples/Basic.tsx +0 -2
  218. package/dist/mdx/react/modal/examples/IframeTest.tsx +0 -1
  219. package/dist/mdx/react/modal/examples/ModalWithPopup.tsx +0 -1
  220. package/dist/mdx/react/modal/examples/StackedModals.tsx +0 -1
  221. package/dist/mdx/react/pagination/examples/CustomRange.tsx +0 -1
  222. package/dist/mdx/react/pagination/examples/GoToForm.tsx +0 -1
  223. package/dist/mdx/react/pagination/examples/JumpControls.tsx +0 -1
  224. package/dist/mdx/react/popup/examples/Basic.tsx +0 -2
  225. package/dist/mdx/react/popup/examples/CloseOnTargetHiddenTest.tsx +0 -1
  226. package/dist/mdx/react/popup/examples/ComboboxWithinPopup.tsx +0 -1
  227. package/dist/mdx/react/popup/examples/MultiplePopups.tsx +0 -2
  228. package/dist/mdx/react/popup/examples/PopupWithFallbackPlacements.tsx +0 -1
  229. package/dist/mdx/react/popup/examples/PopupWithNonHidablePopup.tsx +0 -1
  230. package/dist/mdx/react/popup/examples/ReturnFocusTest.tsx +8 -6
  231. package/dist/mdx/react/popup/examples/TooltipReturnFocus.tsx +0 -1
  232. package/dist/mdx/react/select/examples/Basic.tsx +1 -0
  233. package/dist/mdx/react/select/examples/MenuHeight.tsx +0 -1
  234. package/dist/mdx/react/table/Table.mdx +14 -1
  235. package/dist/mdx/react/table/examples/BaseHtmlTable.tsx +46 -0
  236. package/dist/mdx/react/tabs/examples/Basic.tsx +0 -1
  237. package/dist/mdx/react/tabs/examples/DisabledTab.tsx +0 -1
  238. package/dist/mdx/react/tabs/examples/DynamicTabs.tsx +3 -2
  239. package/dist/mdx/react/tabs/examples/NamedTabs.tsx +0 -1
  240. package/dist/mdx/react/tabs/examples/RightToLeft.tsx +0 -1
  241. package/dist/mdx/react/text-input/examples/Basic.tsx +0 -3
  242. package/dist/mdx/react/toast/examples/Basic.tsx +0 -2
  243. package/dist/mdx/react/toast/examples/ToastAlert.tsx +0 -2
  244. package/dist/mdx/react/toast/examples/ToastDialog.tsx +0 -2
  245. package/dist/mdx/react/tokens/Tokens.mdx +1 -1
  246. package/dist/mdx/react/tooltip/Tooltip.mdx +31 -1
  247. package/dist/mdx/react/tooltip/examples/Default.tsx +0 -2
  248. package/dist/mdx/react/tooltip/examples/DescribeType.tsx +0 -2
  249. package/dist/mdx/react/tooltip/examples/DescriptionType.tsx +20 -0
  250. package/dist/mdx/react/tooltip/examples/Muted.tsx +0 -2
  251. package/dist/mdx/react/tooltip/examples/Placements.tsx +14 -11
  252. package/dist/mdx/style-props/examples/Background.tsx +2 -3
  253. package/dist/mdx/style-props/examples/Border.tsx +2 -3
  254. package/dist/mdx/style-props/examples/Color.tsx +2 -3
  255. package/dist/mdx/style-props/examples/Depth.tsx +2 -3
  256. package/dist/mdx/style-props/examples/Flex.tsx +0 -1
  257. package/dist/mdx/style-props/examples/FlexItem.tsx +0 -1
  258. package/dist/mdx/style-props/examples/Grid.tsx +0 -1
  259. package/dist/mdx/style-props/examples/GridItem.tsx +0 -1
  260. package/dist/mdx/style-props/examples/Layout.tsx +0 -1
  261. package/dist/mdx/style-props/examples/Other.tsx +0 -1
  262. package/dist/mdx/style-props/examples/Position.tsx +2 -3
  263. package/dist/mdx/style-props/examples/Space.tsx +2 -3
  264. package/dist/mdx/style-props/examples/Text.tsx +0 -1
  265. package/lib/ExampleCodeBlock.tsx +57 -19
  266. package/lib/MDXElements.tsx +3 -3
  267. package/lib/StylePropsTable.tsx +1 -2
  268. package/lib/Table.tsx +0 -1
  269. package/lib/stackblitzFiles/.eslintrc.cjs.txt +15 -0
  270. package/lib/stackblitzFiles/App.tsx +33 -0
  271. package/lib/stackblitzFiles/Demo.tsx +1 -0
  272. package/lib/stackblitzFiles/index.html +13 -0
  273. package/lib/stackblitzFiles/main.tsx +27 -0
  274. package/lib/stackblitzFiles/packageJSONFile.ts +42 -0
  275. package/lib/stackblitzFiles/tsconfig.json +26 -0
  276. package/lib/stackblitzFiles/tsconfig.node.json +12 -0
  277. package/lib/stackblitzFiles/types/custom-imports.d.ts +13 -0
  278. package/lib/stackblitzFiles/vite-env.d.ts +1 -0
  279. package/lib/stackblitzFiles/vite.config.ts +10 -0
  280. package/lib/widgets/array.tsx +0 -2
  281. package/lib/widgets/canvasColor.tsx +0 -2
  282. package/lib/widgets/component.tsx +0 -2
  283. package/lib/widgets/conditional.tsx +0 -2
  284. package/lib/widgets/enhancedComponent.tsx +1 -1
  285. package/lib/widgets/external.tsx +3 -2
  286. package/lib/widgets/model.tsx +0 -2
  287. package/lib/widgets/parenthesis.tsx +0 -2
  288. package/lib/widgets/primitives.tsx +1 -5
  289. package/lib/widgets/qualifiedName.tsx +0 -2
  290. package/lib/widgets/symbol.tsx +0 -2
  291. package/lib/widgets/tuple.tsx +0 -2
  292. package/lib/widgets/typeParameter.tsx +0 -2
  293. package/package.json +8 -7
  294. package/dist/mdx/preview-react/InformationHighlight/examples/Informational.tsx +0 -27
  295. /package/dist/mdx/preview-react/{InformationHighlight → information-highlight}/InformationHighlight.mdx +0 -0
  296. /package/dist/mdx/{labs-react → react}/expandable/examples/test-avatar.png +0 -0
@@ -1,3 +1,2 @@
1
- import React from 'react';
2
- export declare const ExampleCodeBlock: ({ code }: any) => React.JSX.Element;
1
+ export declare const ExampleCodeBlock: ({ code }: any) => import("react/jsx-runtime").JSX.Element;
3
2
  //# sourceMappingURL=ExampleCodeBlock.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ExampleCodeBlock.d.ts","sourceRoot":"","sources":["../../../lib/ExampleCodeBlock.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAqD1B,eAAO,MAAM,gBAAgB,aAAY,GAAG,sBAgF3C,CAAC"}
1
+ {"version":3,"file":"ExampleCodeBlock.d.ts","sourceRoot":"","sources":["../../../lib/ExampleCodeBlock.tsx"],"names":[],"mappings":"AAiEA,eAAO,MAAM,gBAAgB,aAAY,GAAG,4CA0G3C,CAAC"}
@@ -1,3 +1,4 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
1
2
  import React from 'react';
2
3
  import { Prism as SyntaxHighlighter } from 'react-syntax-highlighter';
3
4
  import { TertiaryButton } from '@workday/canvas-kit-react/button';
@@ -6,7 +7,17 @@ import { calc, createStencil, cssVar, px2rem } from '@workday/canvas-kit-styling
6
7
  import { system } from '@workday/canvas-tokens-web';
7
8
  import { vscDarkPlus } from 'react-syntax-highlighter/dist/cjs/styles/prism';
8
9
  import { checkCircleIcon, copyIcon } from '@workday/canvas-system-icons-web';
9
- import { Tooltip } from '@workday/canvas-kit-react';
10
+ import { Tooltip } from '@workday/canvas-kit-react/tooltip';
11
+ import sdk from '@stackblitz/sdk';
12
+ import tsconfigFile from '!!raw-loader!./stackblitzFiles/tsconfig.json';
13
+ import { packageJSONFile } from './stackblitzFiles/packageJSONFile';
14
+ import indexHTMLFile from '!!raw-loader!./stackblitzFiles/index.html';
15
+ import mainFile from '!!raw-loader!./stackblitzFiles/main.tsx';
16
+ import viteConfigFile from '!!raw-loader!./stackblitzFiles/vite.config.ts';
17
+ import eslintrc from '!!raw-loader!./stackblitzFiles/.eslintrc.cjs.txt';
18
+ import tsconfigNodeFile from '!!raw-loader!./stackblitzFiles/tsconfig.node.json';
19
+ import appFile from '!!raw-loader!./stackblitzFiles/App.tsx';
20
+ import viteEnvFile from '!!raw-loader!./stackblitzFiles/vite-env.d.ts';
10
21
  const cardStencil = createStencil({
11
22
  base: {
12
23
  '[data-part="example-block"]': {
@@ -19,10 +30,12 @@ const cardStencil = createStencil({
19
30
  boxShadow: system.depth[1],
20
31
  borderRadius: system.shape.x1,
21
32
  },
22
- '[data-part="code-toggle-btn"]': {
33
+ '[data-part="code-toggle-stackblitz-btn-container"]': {
23
34
  position: 'absolute',
24
35
  right: calc.negate(px2rem(1)),
25
36
  bottom: calc.negate(px2rem(1)),
37
+ display: 'flex',
38
+ gap: system.space.x2,
26
39
  },
27
40
  '[data-part="copy-btn"]': {
28
41
  position: 'absolute',
@@ -64,30 +77,42 @@ export const ExampleCodeBlock = ({ code }) => {
64
77
  // @ts-ignore
65
78
  navigator.clipboard.writeText(textInput.current.textContent);
66
79
  };
67
- // React.useEffect(() => {
68
- // if (copied) {
69
- // const copyCodeTimeout = setTimeout(() => {
70
- // setCopied(false);
71
- // }, 2000);
72
- // return () => {
73
- // clearTimeout(copyCodeTimeout);
74
- // };
75
- // }
76
- // }, [copied]);
77
- return (React.createElement("div", { ...cardStencil({ opened: isCodeDisplayed }) },
78
- React.createElement(Card, { "data-part": "example-block", className: "sb-unstyled" },
79
- React.createElement(Card.Body, null,
80
- React.createElement(code),
81
- code && (React.createElement(TertiaryButton, { size: "extraSmall", onClick: () => setCodeDisplayed(!isCodeDisplayed), "data-part": "code-toggle-btn" }, !isCodeDisplayed ? 'Show Code' : 'Hide Code')))),
82
- React.createElement(Card, { "data-part": "code-block", padding: 0 },
83
- React.createElement(Card.Body, { cs: { position: 'relative' } },
84
- code && (React.createElement("div", { ref: textInput },
85
- React.createElement(SyntaxHighlighter, { className: "sb-unstyled", language: "jsx", style: vscDarkPlus, customStyle: {
86
- fontSize: cssVar(system.fontSize.subtext.large),
87
- lineHeight: cssVar(system.lineHeight.subtext.large),
88
- margin: '0',
89
- padding: `${cssVar(system.space.x8)} ${cssVar(system.space.x10)}`,
90
- }, children: code.__RAW__ }))),
91
- React.createElement(Tooltip, { title: copied ? 'Copied!' : 'Copy Source Code' },
92
- React.createElement(TertiaryButton, { "aria-label": "Copy Code", size: "large", "data-part": "copy-btn", variant: "inverse", iconPosition: "end", icon: copied ? checkCircleIcon : copyIcon, onClick: onCopy }))))));
80
+ /**
81
+ * `code` returns our examples. We need to rewrite them so that they export `Demo`.
82
+ */
83
+ const handleExampleRewrite = (code) => {
84
+ return code
85
+ .replace(/\bexport\s+const\s+(\w+)\s*=/, `export const Demo =`)
86
+ .replace(/export default/, 'export const Demo =');
87
+ };
88
+ const openProjectInStackblitz = () => {
89
+ sdk.openProject({
90
+ files: {
91
+ 'src/Demo.tsx': handleExampleRewrite(code.__RAW__),
92
+ 'src/vite-env-d.ts': viteEnvFile,
93
+ 'src/App.tsx': appFile,
94
+ 'tsconfig.node.json': tsconfigNodeFile,
95
+ '.eslintrc.js': eslintrc,
96
+ 'vite.config.ts': viteConfigFile,
97
+ 'src/main.tsx': mainFile,
98
+ 'index.html': indexHTMLFile,
99
+ 'tsconfig.json': tsconfigFile,
100
+ 'package.json': packageJSONFile,
101
+ },
102
+ template: 'node',
103
+ title: `Demo`,
104
+ description: `This is a Canvas Kit Demo. Edit and play around!`,
105
+ },
106
+ // Options
107
+ {
108
+ newWindow: true,
109
+ openFile: 'src/Demo.tsx',
110
+ });
111
+ };
112
+ return (_jsxs("div", { ...cardStencil({ opened: isCodeDisplayed }), children: [_jsx(Card, { "data-part": "example-block", className: "sb-unstyled", children: _jsxs(Card.Body, { children: [React.createElement(code), code && (_jsxs("div", { "data-part": "code-toggle-stackblitz-btn-container", children: [_jsx(TertiaryButton, { size: "extraSmall", onClick: () => openProjectInStackblitz(), children: "\u26A1\uFE0F Edit in Stackblitz" }), _jsx(TertiaryButton, { size: "extraSmall", onClick: () => setCodeDisplayed(!isCodeDisplayed), children: !isCodeDisplayed ? 'Show Code' : 'Hide Code' })] }))] }) }), _jsx(Card, { "data-part": "code-block", padding: 0, children: _jsxs(Card.Body, { cs: { position: 'relative' }, children: [code && (_jsx("div", { ref: textInput, children: _jsx(SyntaxHighlighter, { className: "sb-unstyled", language: "jsx", style: vscDarkPlus, customStyle: {
113
+ fontSize: cssVar(system.fontSize.subtext.large),
114
+ lineHeight: cssVar(system.lineHeight.subtext.large),
115
+ margin: '0',
116
+ padding: `${cssVar(system.space.x8)} ${cssVar(system.space.x10)}`,
117
+ }, children: code.__RAW__ }) })), _jsx(Tooltip, { title: copied ? 'Copied!' : 'Copy Source Code', children: _jsx(TertiaryButton, { "aria-label": "Copy Code", size: "large", "data-part": "copy-btn", variant: "inverse", iconPosition: "end", icon: copied ? checkCircleIcon : copyIcon, onClick: onCopy }) })] }) })] }));
93
118
  };
@@ -1,4 +1,3 @@
1
- import React from 'react';
2
1
  /**
3
2
  * Special component that taps into @mdx-js/react components that are used by both Storybook and the
4
3
  * Canvas Site. This means our docs can use the same components used in our MDX files without
@@ -10,5 +9,5 @@ export declare const MDX: import("@workday/canvas-kit-react").ElementComponent<"
10
9
  */
11
10
  export declare const MdxJSToJSX: (props: {
12
11
  children: string;
13
- }) => React.JSX.Element;
12
+ }) => import("react/jsx-runtime").JSX.Element;
14
13
  //# sourceMappingURL=MDXElements.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"MDXElements.d.ts","sourceRoot":"","sources":["../../../lib/MDXElements.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAM1B;;;;GAIG;AACH,eAAO,MAAM,GAAG,sEAMd,CAAC;AAwDH;;GAEG;AACH,eAAO,MAAM,UAAU,UAAW;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAC,sBAQnD,CAAC"}
1
+ {"version":3,"file":"MDXElements.d.ts","sourceRoot":"","sources":["../../../lib/MDXElements.tsx"],"names":[],"mappings":"AAQA;;;;GAIG;AACH,eAAO,MAAM,GAAG,sEAMd,CAAC;AAwDH;;GAEG;AACH,eAAO,MAAM,UAAU,UAAW;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAC,4CAQnD,CAAC"}
@@ -1,3 +1,4 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
1
2
  //@ts-ignore
2
3
  import { useMDXComponents } from '@mdx-js/react';
3
4
  import React from 'react';
@@ -21,14 +22,13 @@ export const MDX = createComponent('div')({
21
22
  */
22
23
  const Button = (props) => {
23
24
  const components = useMDXComponents();
24
- if (props['data-symbol'] !== undefined) {
25
- return (React.createElement("code", null,
26
- React.createElement(SymbolDialog, { value: {
25
+ if (props['data-symbol'] !== undefined && props.children) {
26
+ return (_jsx("code", { children: _jsx(SymbolDialog, { value: {
27
27
  kind: 'symbol',
28
28
  name: props.children[0],
29
29
  displayName: props['data-symbol'],
30
30
  value: props.children[0],
31
- } })));
31
+ } }) }));
32
32
  }
33
33
  return React.createElement(components['button'] || 'button', props, props.children);
34
34
  };
@@ -37,7 +37,7 @@ const Button = (props) => {
37
37
  * processing. This allows us to convert {@link SymbolName Link Text} to a `<SymbolDialog>`!
38
38
  */
39
39
  function convertLinkToSymbolLinks(input) {
40
- return input.replace(/{@link ([a-z0-9.]+)( [a-z0-9.]+)?}/gi, (substr, symbol, text = '') => `<button href="#" data-symbol="${text.trim()}" class="token symbol">${symbol}</button>`);
40
+ return input.replace(/{@link ([a-z0-9.]+)( [a-z0-9.]+)?}/gi, (_substr, symbol, text = '') => `<button data-symbol="${text.trim()}" className="token symbol">${symbol}</button>`);
41
41
  }
42
42
  /**
43
43
  * Replace all heading levels in the JSDoc to start at the same heading level as `startingLevel`.
@@ -57,5 +57,5 @@ function rewriteHeadingLevels(input, startingLevel) {
57
57
  export const MdxJSToJSX = (props) => {
58
58
  const components = useMDXComponents();
59
59
  const headingLevel = React.useContext(HeadingLevelContext);
60
- return (React.createElement(MarkdownToJSX, { options: { overrides: { ...components, button: Button }, forceBlock: true } }, rewriteHeadingLevels(convertLinkToSymbolLinks(props.children), headingLevel)));
60
+ return (_jsx(MarkdownToJSX, { options: { overrides: { ...components, button: Button }, forceBlock: true }, children: rewriteHeadingLevels(convertLinkToSymbolLinks(props.children), headingLevel) }));
61
61
  };
@@ -16,5 +16,5 @@ export interface MoreTooltipProps extends React.HTMLAttributes<HTMLDivElement> {
16
16
  */
17
17
  placement?: Placement;
18
18
  }
19
- export declare const MoreTooltip: ({ placement, children, title, ...elemProps }: MoreTooltipProps) => React.JSX.Element;
19
+ export declare const MoreTooltip: ({ placement, children, title, ...elemProps }: MoreTooltipProps) => import("react/jsx-runtime").JSX.Element;
20
20
  //# sourceMappingURL=MoreTooltip.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"MoreTooltip.d.ts","sourceRoot":"","sources":["../../../lib/MoreTooltip.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,EAA4B,SAAS,EAAS,MAAM,iCAAiC,CAAC;AAS7F,MAAM,WAAW,gBAAiB,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IAC5E;;;;;;;OAOG;IACH,QAAQ,EAAE,KAAK,CAAC,YAAY,CAAC;IAC7B;;;OAGG;IACH,SAAS,CAAC,EAAE,SAAS,CAAC;CACvB;AA0BD,eAAO,MAAM,WAAW,iDAKrB,gBAAgB,sBAwClB,CAAC"}
1
+ {"version":3,"file":"MoreTooltip.d.ts","sourceRoot":"","sources":["../../../lib/MoreTooltip.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,EAA4B,SAAS,EAAS,MAAM,iCAAiC,CAAC;AAS7F,MAAM,WAAW,gBAAiB,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IAC5E;;;;;;;OAOG;IACH,QAAQ,EAAE,KAAK,CAAC,YAAY,CAAC;IAC7B;;;OAGG;IACH,SAAS,CAAC,EAAE,SAAS,CAAC;CACvB;AA0BD,eAAO,MAAM,WAAW,iDAKrB,gBAAgB,4CAwClB,CAAC"}
@@ -1,3 +1,4 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
1
2
  import * as React from 'react';
2
3
  import { getTransformFromPlacement, Popper } from '@workday/canvas-kit-react/popup';
3
4
  import { mergeCallback } from '@workday/canvas-kit-react/common';
@@ -41,16 +42,14 @@ export const MoreTooltip = ({ placement = 'top', children, title, ...elemProps }
41
42
  targetProps.onFocus(event);
42
43
  }
43
44
  };
44
- return (React.createElement(React.Fragment, null,
45
- React.cloneElement(children, {
46
- ...targetProps,
47
- onMouseEnter,
48
- onFocus,
49
- 'aria-label': undefined,
50
- ...mergeCallbacks({ ...targetProps, onMouseEnter, onFocus }, children.props),
51
- }),
52
- React.createElement(Popper, { placement: placement, ...popperProps }, ({ placement }) => {
53
- const transformOrigin = getTransformFromPlacement(placement);
54
- return (React.createElement(TooltipContainer, { transformOrigin: transformOrigin, ...tooltipProps, ...elemProps }, titleText));
55
- })));
45
+ return (_jsxs(React.Fragment, { children: [React.cloneElement(children, {
46
+ ...targetProps,
47
+ onMouseEnter,
48
+ onFocus,
49
+ 'aria-label': undefined,
50
+ ...mergeCallbacks({ ...targetProps, onMouseEnter, onFocus }, children.props),
51
+ }), _jsx(Popper, { placement: placement, ...popperProps, children: ({ placement }) => {
52
+ const transformOrigin = getTransformFromPlacement(placement);
53
+ return (_jsx(TooltipContainer, { transformOrigin: transformOrigin, ...tooltipProps, ...elemProps, children: titleText }));
54
+ } })] }));
56
55
  };
@@ -1,7 +1,6 @@
1
- import React from 'react';
2
1
  export interface SpecificationsProps {
3
2
  file: string;
4
3
  name?: string;
5
4
  }
6
- export declare const Specifications: ({ file, name }: SpecificationsProps) => React.JSX.Element | null;
5
+ export declare const Specifications: ({ file, name }: SpecificationsProps) => import("react/jsx-runtime").JSX.Element | null;
7
6
  //# sourceMappingURL=Specifications.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Specifications.d.ts","sourceRoot":"","sources":["../../../lib/Specifications.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAQ1B,MAAM,WAAW,mBAAmB;IAClC,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AA8CD,eAAO,MAAM,cAAc,mBAAkB,mBAAmB,6BAqF/D,CAAC"}
1
+ {"version":3,"file":"Specifications.d.ts","sourceRoot":"","sources":["../../../lib/Specifications.tsx"],"names":[],"mappings":"AASA,MAAM,WAAW,mBAAmB;IAClC,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AA8CD,eAAO,MAAM,cAAc,mBAAkB,mBAAmB,mDAqF/D,CAAC"}
@@ -1,3 +1,4 @@
1
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
1
2
  /* eslint-disable no-param-reassign */
2
3
  import React from 'react';
3
4
  import { toId } from '@storybook/csf';
@@ -56,25 +57,7 @@ export const Specifications = ({ file, name }) => {
56
57
  return input;
57
58
  }
58
59
  const [, first, kind, name, last] = matches;
59
- return (React.createElement(React.Fragment, null,
60
- first.replace(/given /i, ''),
61
- React.createElement(Hyperlink, { href: `${storybookBaseUrl}?path=/story/${toId(kind, name.replace('DefaultStory', 'Default Story'))}` }, name.replace('DefaultStory', 'Default')),
62
- last));
60
+ return (_jsxs(_Fragment, { children: [first.replace(/given /i, ''), _jsx(Hyperlink, { href: `${storybookBaseUrl}?path=/story/${toId(kind, name.replace('DefaultStory', 'Default Story'))}`, children: name.replace('DefaultStory', 'Default') }), last] }));
63
61
  };
64
- return block.type === 'describe' ? (React.createElement(React.Fragment, null,
65
- React.createElement(Table, null,
66
- React.createElement(Table.Head, null,
67
- React.createElement(Table.Row, null,
68
- React.createElement(Table.Header, null, "Given"),
69
- React.createElement(Table.Header, null, "When"),
70
- React.createElement(Table.Header, null, "Then"))),
71
- React.createElement(Table.Body, null, block.children.reduce(createTableRows, []).map((row, index) => (React.createElement(Table.Row, { key: index },
72
- React.createElement(Table.Cell, null, renderGiven(row.given[0])),
73
- React.createElement(Table.Cell, null,
74
- React.createElement("ul", null, row.when.map((item, index) => (React.createElement("li", { key: index }, (index !== 0 ? 'AND THEN ' : '') + item.replace(/[tw]hen /i, '')))))),
75
- React.createElement(Table.Cell, null,
76
- React.createElement("ul", null, row.then.map((item, index) => (React.createElement("li", { key: index }, (item.indexOf('should') === 0 ? 'it ' : '') + item)))))))))),
77
- "Source:",
78
- ' ',
79
- React.createElement(Hyperlink, { href: `${githubUrl}blob/${githubBranch}/cypress/integration/${file}` }, file))) : null;
62
+ return block.type === 'describe' ? (_jsxs(_Fragment, { children: [_jsxs(Table, { children: [_jsx(Table.Head, { children: _jsxs(Table.Row, { children: [_jsx(Table.Header, { children: "Given" }), _jsx(Table.Header, { children: "When" }), _jsx(Table.Header, { children: "Then" })] }) }), _jsx(Table.Body, { children: block.children.reduce(createTableRows, []).map((row, index) => (_jsxs(Table.Row, { children: [_jsx(Table.Cell, { children: renderGiven(row.given[0]) }), _jsx(Table.Cell, { children: _jsx("ul", { children: row.when.map((item, index) => (_jsx("li", { children: (index !== 0 ? 'AND THEN ' : '') + item.replace(/[tw]hen /i, '') }, index))) }) }), _jsx(Table.Cell, { children: _jsx("ul", { children: row.then.map((item, index) => (_jsx("li", { children: (item.indexOf('should') === 0 ? 'it ' : '') + item }, index))) }) })] }, index))) })] }), "Source:", ' ', _jsx(Hyperlink, { href: `${githubUrl}blob/${githubBranch}/cypress/integration/${file}`, children: file })] })) : null;
80
63
  };
@@ -1,4 +1,3 @@
1
- import React from 'react';
2
1
  type StyleProp = {
3
2
  name: string;
4
3
  properties: string[];
@@ -7,6 +6,6 @@ type StyleProp = {
7
6
  interface StylePropsTableProps {
8
7
  styleProps?: StyleProp[];
9
8
  }
10
- export declare const StylePropsTable: ({ styleProps }: StylePropsTableProps) => React.JSX.Element;
9
+ export declare const StylePropsTable: ({ styleProps }: StylePropsTableProps) => import("react/jsx-runtime").JSX.Element;
11
10
  export {};
12
11
  //# sourceMappingURL=StylePropsTable.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"StylePropsTable.d.ts","sourceRoot":"","sources":["../../../lib/StylePropsTable.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAK1B,KAAK,SAAS,GAAG;IACf,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,EAAE,MAAM,EAAE,CAAC;IACrB,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF,UAAU,oBAAoB;IAC5B,UAAU,CAAC,EAAE,SAAS,EAAE,CAAC;CAC1B;AAMD,eAAO,MAAM,eAAe,mBAAuB,oBAAoB,sBAoCtE,CAAC"}
1
+ {"version":3,"file":"StylePropsTable.d.ts","sourceRoot":"","sources":["../../../lib/StylePropsTable.tsx"],"names":[],"mappings":"AAIA,KAAK,SAAS,GAAG;IACf,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,EAAE,MAAM,EAAE,CAAC;IACrB,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF,UAAU,oBAAoB;IAC5B,UAAU,CAAC,EAAE,SAAS,EAAE,CAAC;CAC1B;AAMD,eAAO,MAAM,eAAe,mBAAuB,oBAAoB,4CAoCtE,CAAC"}
@@ -1,4 +1,4 @@
1
- import React from 'react';
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { Box } from '@workday/canvas-kit-react/layout';
3
3
  import { ExternalHyperlink } from '@workday/canvas-kit-react';
4
4
  import { Table } from './Table';
@@ -7,19 +7,9 @@ const camelToKebabCase = (name) => {
7
7
  };
8
8
  export const StylePropsTable = ({ styleProps = [] }) => {
9
9
  const sortedStyleProps = styleProps.sort((a, b) => a.name.localeCompare(b.name));
10
- return (React.createElement(Table, null,
11
- React.createElement(Table.Head, null,
12
- React.createElement(Table.Row, null,
13
- React.createElement(Table.Header, null, "Prop"),
14
- React.createElement(Table.Header, null, "CSS Properties"),
15
- React.createElement(Table.Header, null, "System"))),
16
- React.createElement(Table.Body, null, sortedStyleProps.map((styleProp, index) => (React.createElement(Table.Row, { key: index },
17
- React.createElement(Table.Data, { fontFamily: "monospace" }, styleProp.name),
18
- React.createElement(Table.Data, null, styleProp.properties.map((property, i) => {
19
- const formattedName = camelToKebabCase(property);
20
- const mdnUrl = `https://developer.mozilla.org/en-US/docs/Web/CSS/${formattedName}`;
21
- return (React.createElement(Box, { display: "inline-block", marginInlineEnd: "xxxs" },
22
- React.createElement(ExternalHyperlink, { href: mdnUrl, key: i }, formattedName)));
23
- })),
24
- React.createElement(Table.Data, { fontFamily: "monospace" }, styleProp.system === 'none' ? '---' : styleProp.system)))))));
10
+ return (_jsxs(Table, { children: [_jsx(Table.Head, { children: _jsxs(Table.Row, { children: [_jsx(Table.Header, { children: "Prop" }), _jsx(Table.Header, { children: "CSS Properties" }), _jsx(Table.Header, { children: "System" })] }) }), _jsx(Table.Body, { children: sortedStyleProps.map((styleProp, index) => (_jsxs(Table.Row, { children: [_jsx(Table.Data, { fontFamily: "monospace", children: styleProp.name }), _jsx(Table.Data, { children: styleProp.properties.map((property, i) => {
11
+ const formattedName = camelToKebabCase(property);
12
+ const mdnUrl = `https://developer.mozilla.org/en-US/docs/Web/CSS/${formattedName}`;
13
+ return (_jsx(Box, { display: "inline-block", marginInlineEnd: "xxxs", children: _jsx(ExternalHyperlink, { href: mdnUrl, iconLabel: "Open link in new window", children: formattedName }, i) }));
14
+ }) }), _jsx(Table.Data, { fontFamily: "monospace", children: styleProp.system === 'none' ? '---' : styleProp.system })] }, index))) })] }));
25
15
  };
@@ -1 +1 @@
1
- {"version":3,"file":"Table.d.ts","sourceRoot":"","sources":["../../../lib/Table.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAO,SAAS,EAAC,MAAM,gCAAgC,CAAC;AA+D/D,eAAO,MAAM,KAAK;;;;;;CAqBhB,CAAC"}
1
+ {"version":3,"file":"Table.d.ts","sourceRoot":"","sources":["../../../lib/Table.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAO,SAAS,EAAC,MAAM,gCAAgC,CAAC;AA+D/D,eAAO,MAAM,KAAK;;;;;;CAqBhB,CAAC"}
@@ -1,4 +1,4 @@
1
- import React from 'react';
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { createComponent } from '@workday/canvas-kit-react/common';
3
3
  import { Box } from '@workday/canvas-kit-react/layout';
4
4
  import { Text } from '@workday/canvas-kit-react/text';
@@ -6,22 +6,22 @@ import styled from '@emotion/styled';
6
6
  import { type } from '@workday/canvas-kit-react/tokens';
7
7
  const TableHead = createComponent('thead')({
8
8
  Component: (props, ref, Element) => {
9
- return React.createElement(Box, { as: Element, ref: ref, ...props });
9
+ return _jsx(Box, { as: Element, ref: ref, ...props });
10
10
  },
11
11
  });
12
12
  const TableBody = createComponent('tbody')({
13
13
  Component: (props, ref, Element) => {
14
- return React.createElement(Box, { as: Element, ref: ref, ...props });
14
+ return _jsx(Box, { as: Element, ref: ref, ...props });
15
15
  },
16
16
  });
17
17
  const TableRow = createComponent('tr')({
18
18
  Component: (props, ref, Element) => {
19
- return (React.createElement(Box, { as: Element, ref: ref, borderBottom: "solid 1px", borderBottomColor: "soap400", ...props }));
19
+ return (_jsx(Box, { as: Element, ref: ref, borderBottom: "solid 1px", borderBottomColor: "soap400", ...props }));
20
20
  },
21
21
  });
22
22
  const TableHeader = createComponent('th')({
23
23
  Component: (props, ref, Element) => {
24
- return (React.createElement(Text, { as: Element, ref: ref, fontWeight: "medium", paddingX: "xxs", paddingY: "s", textAlign: "start", typeLevel: "subtext.large", ...props }));
24
+ return (_jsx(Text, { as: Element, ref: ref, fontWeight: "medium", paddingX: "xxs", paddingY: "s", textAlign: "start", typeLevel: "subtext.large", ...props }));
25
25
  },
26
26
  });
27
27
  const StyledText = styled(Text)({
@@ -31,13 +31,13 @@ const StyledText = styled(Text)({
31
31
  });
32
32
  const TableData = createComponent('td')({
33
33
  Component: (props, ref, Element) => {
34
- return (React.createElement(StyledText, { as: Element, ref: ref, paddingX: "xxs", paddingY: "s", textAlign: "start", typeLevel: "subtext.large", ...props }));
34
+ return (_jsx(StyledText, { as: Element, ref: ref, paddingX: "xxs", paddingY: "s", textAlign: "start", typeLevel: "subtext.large", ...props }));
35
35
  },
36
36
  });
37
37
  export const Table = createComponent('table')({
38
38
  displayName: 'Table',
39
39
  Component: (props, ref, Element) => {
40
- return (React.createElement(Box, { as: Element, ref: ref, borderCollapse: "collapse", width: "100%", ...props, marginBottom: "s" }));
40
+ return (_jsx(Box, { as: Element, ref: ref, borderCollapse: "collapse", width: "100%", ...props, marginBottom: "s" }));
41
41
  },
42
42
  subComponents: {
43
43
  Head: TableHead,
@@ -12,13 +12,13 @@ export interface ValueProps<T extends {
12
12
  }
13
13
  export declare const Value: <T extends {
14
14
  kind: string;
15
- } = types.Value>(props: ValueProps<T>) => React.JSX.Element;
15
+ } = types.Value>(props: ValueProps<T>) => import("react/jsx-runtime").JSX.Element;
16
16
  export declare const PropertiesInline: ({ properties }: {
17
17
  properties: types.ObjectProperty[];
18
- }) => React.JSX.Element;
18
+ }) => import("react/jsx-runtime").JSX.Element;
19
19
  export declare const PropertiesTable: ({ properties, showDefault, showRequired, }: {
20
20
  properties: types.ObjectProperty[];
21
21
  showDefault?: boolean | undefined;
22
22
  showRequired?: boolean | undefined;
23
- }) => React.JSX.Element;
23
+ }) => import("react/jsx-runtime").JSX.Element;
24
24
  //# sourceMappingURL=Value.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Value.d.ts","sourceRoot":"","sources":["../../../lib/Value.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAK1B,OAAO,KAAK,KAAK,MAAM,oBAAoB,CAAC;AAS5C,wBAAgB,cAAc,CAAC,CAAC,SAAS;IAAC,IAAI,EAAE,MAAM,CAAA;CAAC,EACrD,GAAG,EAAE,CAAC,CAAC,MAAM,CAAC,EACd,MAAM,EAAE,KAAK,CAAC,EAAE,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,GAC9B,IAAI,CAGN;AAED,MAAM,WAAW,UAAU,CAAC,CAAC,SAAS;IAAC,IAAI,EAAE,MAAM,CAAA;CAAC,GAAG,KAAK,CAAC,KAAK;IAChE,KAAK,EAAE,CAAC,CAAC;IACT,GAAG,CAAC,EAAE,KAAK,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC;IAC9B,IAAI,CAAC,EAAE,GAAG,CAAC;CACZ;AAED,eAAO,MAAM,KAAK;UAAqB,MAAM;2DAW5C,CAAC;AAEF,eAAO,MAAM,gBAAgB;gBAA+B,MAAM,cAAc,EAAE;uBAgDjF,CAAC;AAgEF,eAAO,MAAM,eAAe;gBAKd,MAAM,cAAc,EAAE;;;uBAyBnC,CAAC"}
1
+ {"version":3,"file":"Value.d.ts","sourceRoot":"","sources":["../../../lib/Value.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAK1B,OAAO,KAAK,KAAK,MAAM,oBAAoB,CAAC;AAS5C,wBAAgB,cAAc,CAAC,CAAC,SAAS;IAAC,IAAI,EAAE,MAAM,CAAA;CAAC,EACrD,GAAG,EAAE,CAAC,CAAC,MAAM,CAAC,EACd,MAAM,EAAE,KAAK,CAAC,EAAE,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,GAC9B,IAAI,CAGN;AAED,MAAM,WAAW,UAAU,CAAC,CAAC,SAAS;IAAC,IAAI,EAAE,MAAM,CAAA;CAAC,GAAG,KAAK,CAAC,KAAK;IAChE,KAAK,EAAE,CAAC,CAAC;IACT,GAAG,CAAC,EAAE,KAAK,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC;IAC9B,IAAI,CAAC,EAAE,GAAG,CAAC;CACZ;AAED,eAAO,MAAM,KAAK;UAAqB,MAAM;iFAW5C,CAAC;AAEF,eAAO,MAAM,gBAAgB;gBAA+B,MAAM,cAAc,EAAE;6CAgDjF,CAAC;AAgEF,eAAO,MAAM,eAAe;gBAKd,MAAM,cAAc,EAAE;;;6CAyBnC,CAAC"}
@@ -1,3 +1,4 @@
1
+ import { jsxs as _jsxs, jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
1
2
  import React from 'react';
2
3
  import { Tooltip } from '@workday/canvas-kit-react/tooltip';
3
4
  import { Text } from '@workday/canvas-kit-react/text';
@@ -16,37 +17,21 @@ export const Value = (props) => {
16
17
  if (widgets[props.value.kind]) {
17
18
  return React.createElement(widgets[props.value.kind], props);
18
19
  }
19
- return (React.createElement("span", { className: "token unknown", style: { whiteSpace: 'pre-wrap' } },
20
- "unknown ",
21
- JSON.stringify(props.value, null, ' ').replace(/\n/g, '\n' + indent(level))));
20
+ return (_jsxs("span", { className: "token unknown", style: { whiteSpace: 'pre-wrap' }, children: ["unknown ", JSON.stringify(props.value, null, ' ').replace(/\n/g, '\n' + indent(level))] }));
22
21
  };
23
22
  export const PropertiesInline = ({ properties }) => {
24
23
  if (properties.length === 0) {
25
- return React.createElement("span", { className: "token punctuation" }, "{}");
24
+ return _jsx("span", { className: "token punctuation", children: "{}" });
26
25
  }
27
26
  const level = React.useContext(IndentLevelContext);
28
- return (React.createElement(React.Fragment, null,
29
- React.createElement("span", { className: "token punctuation" }, "{"),
30
- properties.map((p, index) => {
31
- return (React.createElement(React.Fragment, { key: index },
32
- React.createElement("br", null),
33
- indent(level + 1),
34
- p.description || p.tags.deprecated ? (React.createElement(DescriptionTooltip, { type: "describe", style: { maxWidth: '50em' }, title: React.createElement(MdxJSToJSX, null, p.description || p.tags.deprecated) },
35
- React.createElement("span", { className: "token property", style: {
36
- cursor: 'pointer',
37
- textDecoration: p.tags.deprecated ? 'line-through' : 'underline',
38
- textDecorationStyle: 'dotted',
39
- color: p.tags.deprecated ? colors.cinnamon600 : colors.plum600,
40
- } }, p.name))) : (React.createElement("span", { className: "token property" }, p.name)),
41
- React.createElement("span", { className: "token punctuation" }, ":"),
42
- "\u00A0",
43
- React.createElement(IndentLevelContext.Provider, { value: level + 1 },
44
- React.createElement(Value, { value: p.type })),
45
- React.createElement("span", { className: "token punctuation" }, ";")));
46
- }),
47
- React.createElement("br", null),
48
- indent(level),
49
- React.createElement("span", { className: "token punctuation" }, "}")));
27
+ return (_jsxs(_Fragment, { children: [_jsx("span", { className: "token punctuation", children: "{" }), properties.map((p, index) => {
28
+ return (_jsxs(React.Fragment, { children: [_jsx("br", {}), indent(level + 1), p.description || p.tags.deprecated ? (_jsx(DescriptionTooltip, { type: "describe", style: { maxWidth: '50em' }, title: _jsx(MdxJSToJSX, { children: p.description || p.tags.deprecated }), children: _jsx("span", { className: "token property", style: {
29
+ cursor: 'pointer',
30
+ textDecoration: p.tags.deprecated ? 'line-through' : 'underline',
31
+ textDecorationStyle: 'dotted',
32
+ color: p.tags.deprecated ? colors.cinnamon600 : colors.plum600,
33
+ }, children: p.name }) })) : (_jsx("span", { className: "token property", children: p.name })), _jsx("span", { className: "token punctuation", children: ":" }), "\u00A0", _jsx(IndentLevelContext.Provider, { value: level + 1, children: _jsx(Value, { value: p.type }) }), _jsx("span", { className: "token punctuation", children: ";" })] }, index));
34
+ }), _jsx("br", {}), indent(level), _jsx("span", { className: "token punctuation", children: "}" })] }));
50
35
  };
51
36
  function getTableRows(properties, showDefault = true, showRequired = false, level, index) {
52
37
  return properties.flatMap((property, i) => {
@@ -55,37 +40,17 @@ function getTableRows(properties, showDefault = true, showRequired = false, leve
55
40
  return [];
56
41
  }
57
42
  const title = (_b = (_a = property.declarations) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.filePath;
58
- const propName = (React.createElement(Text, { as: "code", whiteSpace: 'nowrap !important' },
59
- indent(level),
60
- level > 0 && '\u2514\u00A0',
61
- property.name,
62
- showRequired && property.required ? React.createElement(Text, { color: "chiliMango600" }, "*") : ''));
43
+ const propName = (_jsxs(Text, { as: "code", whiteSpace: 'nowrap !important', children: [indent(level), level > 0 && '\u2514\u00A0', property.name, showRequired && property.required ? _jsx(Text, { color: "chiliMango600", children: "*" }) : ''] }));
63
44
  return [
64
- React.createElement(Table.Row, { key: index + i },
65
- React.createElement(Table.Data, { color: "plum600" }, title ? (React.createElement(Tooltip, { type: "describe", title: title }, propName)) : (propName)),
66
- React.createElement(Table.Data, null,
67
- React.createElement("code", null, React.createElement(RenderContext.Provider, { value: "inline" },
68
- React.createElement(Value, { value: property.type })))),
69
- React.createElement(Table.Data, null,
70
- React.createElement(MdxJSToJSX, null, property.description || '')),
71
- showDefault ? (React.createElement(Table.Data, null, property.defaultValue ? (property.defaultValue.kind === 'primitive' &&
72
- property.defaultValue.value === 'undefined' ? null : (React.createElement("code", null,
73
- React.createElement(Value, { value: property.defaultValue })))) : null)) : null),
45
+ _jsxs(Table.Row, { children: [_jsx(Table.Data, { color: "plum600", children: title ? (_jsx(Tooltip, { type: "describe", title: title, children: propName })) : (propName) }), _jsx(Table.Data, { children: _jsx("code", { children: _jsx(RenderContext.Provider, { value: "inline", children: _jsx(Value, { value: property.type }) }) }) }), _jsx(Table.Data, { children: _jsx(MdxJSToJSX, { children: property.description || '' }) }), showDefault ? (_jsx(Table.Data, { children: property.defaultValue ? (property.defaultValue.kind === 'primitive' &&
46
+ property.defaultValue.value === 'undefined' ? null : (_jsx("code", { children: _jsx(Value, { value: property.defaultValue }) }))) : null })) : null] }, index + i),
74
47
  ];
75
48
  });
76
49
  }
77
50
  export const PropertiesTable = ({ properties, showDefault = true, showRequired = false, }) => {
78
51
  if (properties.length === 0) {
79
- return React.createElement("span", { className: "token punctuation" }, "{}");
52
+ return _jsx("span", { className: "token punctuation", children: "{}" });
80
53
  }
81
54
  const tableBody = getTableRows(properties, showDefault, showRequired, 0, 0);
82
- return (React.createElement(IndentLevelContext.Provider, { value: 0 },
83
- React.createElement(Table, null,
84
- React.createElement(Table.Head, null,
85
- React.createElement(Table.Row, null,
86
- React.createElement(Table.Header, null, "Name"),
87
- React.createElement(Table.Header, null, "Type"),
88
- React.createElement(Table.Header, null, "Description"),
89
- showDefault ? React.createElement(Table.Header, null, "Default") : null)),
90
- React.createElement(Table.Body, null, tableBody))));
55
+ return (_jsx(IndentLevelContext.Provider, { value: 0, children: _jsxs(Table, { children: [_jsx(Table.Head, { children: _jsxs(Table.Row, { children: [_jsx(Table.Header, { children: "Name" }), _jsx(Table.Header, { children: "Type" }), _jsx(Table.Header, { children: "Description" }), showDefault ? _jsx(Table.Header, { children: "Default" }) : null] }) }), _jsx(Table.Body, { children: tableBody })] }) }));
91
56
  };