@workday/canvas-kit-react 8.0.0-alpha.144-next.0 → 8.0.0-alpha.151-next.3

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 (178) hide show
  1. package/banner/lib/Banner.tsx +3 -6
  2. package/card/lib/CardBody.tsx +3 -6
  3. package/card/lib/CardHeading.tsx +13 -10
  4. package/checkbox/index.ts +0 -1
  5. package/checkbox/lib/Checkbox.tsx +9 -24
  6. package/color-picker/index.ts +0 -1
  7. package/dist/commonjs/banner/lib/Banner.d.ts.map +1 -1
  8. package/dist/commonjs/banner/lib/Banner.js +2 -4
  9. package/dist/commonjs/card/lib/Card.d.ts +1 -1
  10. package/dist/commonjs/card/lib/CardBody.d.ts +1 -1
  11. package/dist/commonjs/card/lib/CardBody.d.ts.map +1 -1
  12. package/dist/commonjs/card/lib/CardBody.js +1 -6
  13. package/dist/commonjs/card/lib/CardHeading.d.ts.map +1 -1
  14. package/dist/commonjs/card/lib/CardHeading.js +2 -10
  15. package/dist/commonjs/checkbox/index.d.ts.map +1 -1
  16. package/dist/commonjs/checkbox/lib/Checkbox.d.ts.map +1 -1
  17. package/dist/commonjs/checkbox/lib/Checkbox.js +2 -13
  18. package/dist/commonjs/color-picker/index.d.ts.map +1 -1
  19. package/dist/commonjs/dialog/lib/Dialog.d.ts +1 -1
  20. package/dist/commonjs/form-field/index.d.ts.map +1 -1
  21. package/dist/commonjs/form-field/lib/Hint.d.ts.map +1 -1
  22. package/dist/commonjs/form-field/lib/Hint.js +5 -13
  23. package/dist/commonjs/index.d.ts +1 -0
  24. package/dist/commonjs/index.d.ts.map +1 -1
  25. package/dist/commonjs/index.js +1 -0
  26. package/dist/commonjs/layout/index.d.ts +4 -0
  27. package/dist/commonjs/layout/index.d.ts.map +1 -1
  28. package/dist/commonjs/layout/index.js +3 -0
  29. package/dist/commonjs/layout/lib/Box.d.ts +4 -2
  30. package/dist/commonjs/layout/lib/Box.d.ts.map +1 -1
  31. package/dist/commonjs/layout/lib/Box.js +27 -3
  32. package/dist/commonjs/layout/lib/Flex.d.ts +1 -1
  33. package/dist/commonjs/layout/lib/Flex.d.ts.map +1 -1
  34. package/dist/commonjs/layout/lib/Grid.d.ts +52 -0
  35. package/dist/commonjs/layout/lib/Grid.d.ts.map +1 -0
  36. package/dist/commonjs/layout/lib/Grid.js +117 -0
  37. package/dist/commonjs/layout/lib/Stack.d.ts +4 -4
  38. package/dist/commonjs/layout/lib/Stack.js +4 -4
  39. package/dist/commonjs/layout/lib/utils/color.d.ts.map +1 -1
  40. package/dist/commonjs/layout/lib/utils/color.js +1 -0
  41. package/dist/commonjs/layout/lib/utils/font.d.ts +29 -0
  42. package/dist/commonjs/layout/lib/utils/font.d.ts.map +1 -0
  43. package/dist/commonjs/layout/lib/utils/font.js +57 -0
  44. package/dist/commonjs/layout/lib/utils/grid.d.ts +58 -0
  45. package/dist/commonjs/layout/lib/utils/grid.d.ts.map +1 -0
  46. package/dist/commonjs/layout/lib/utils/grid.js +49 -0
  47. package/dist/commonjs/layout/lib/utils/gridItem.d.ts +39 -0
  48. package/dist/commonjs/layout/lib/utils/gridItem.d.ts.map +1 -0
  49. package/dist/commonjs/layout/lib/utils/gridItem.js +43 -0
  50. package/dist/commonjs/layout/lib/utils/text.d.ts +35 -0
  51. package/dist/commonjs/layout/lib/utils/text.d.ts.map +1 -0
  52. package/dist/commonjs/layout/lib/utils/text.js +48 -0
  53. package/dist/commonjs/modal/lib/Modal.d.ts +1 -1
  54. package/dist/commonjs/pagination/lib/Pagination/AdditionalDetails.d.ts.map +1 -1
  55. package/dist/commonjs/pagination/lib/Pagination/AdditionalDetails.js +5 -4
  56. package/dist/commonjs/pagination/lib/Pagination/GoTo/Label.d.ts.map +1 -1
  57. package/dist/commonjs/pagination/lib/Pagination/GoTo/Label.js +2 -4
  58. package/dist/commonjs/popup/lib/Popup.d.ts +1 -1
  59. package/dist/commonjs/popup/lib/PopupBody.d.ts +1 -1
  60. package/dist/commonjs/popup/lib/PopupCard.d.ts.map +1 -1
  61. package/dist/commonjs/popup/lib/PopupCard.js +2 -2
  62. package/dist/commonjs/radio/lib/Radio.d.ts.map +1 -1
  63. package/dist/commonjs/radio/lib/Radio.js +2 -13
  64. package/dist/commonjs/side-panel/lib/SidePanel.d.ts.map +1 -1
  65. package/dist/commonjs/side-panel/lib/SidePanel.js +2 -2
  66. package/dist/commonjs/tabs/lib/TabsItem.d.ts +1 -1
  67. package/dist/commonjs/text/index.d.ts +4 -0
  68. package/dist/commonjs/text/index.d.ts.map +1 -0
  69. package/dist/commonjs/text/index.js +15 -0
  70. package/dist/commonjs/text/lib/LabelText.d.ts +8 -0
  71. package/dist/commonjs/text/lib/LabelText.d.ts.map +1 -0
  72. package/dist/commonjs/text/lib/LabelText.js +51 -0
  73. package/dist/commonjs/text/lib/Text.d.ts +14 -0
  74. package/dist/commonjs/text/lib/Text.d.ts.map +1 -0
  75. package/dist/commonjs/text/lib/Text.js +90 -0
  76. package/dist/commonjs/text/lib/TypeLevelComponents.d.ts +13 -0
  77. package/dist/commonjs/text/lib/TypeLevelComponents.d.ts.map +1 -0
  78. package/dist/commonjs/text/lib/TypeLevelComponents.js +79 -0
  79. package/dist/commonjs/text-input/index.d.ts.map +1 -1
  80. package/dist/es6/banner/lib/Banner.d.ts.map +1 -1
  81. package/dist/es6/banner/lib/Banner.js +2 -4
  82. package/dist/es6/card/lib/Card.d.ts +1 -1
  83. package/dist/es6/card/lib/CardBody.d.ts +1 -1
  84. package/dist/es6/card/lib/CardBody.d.ts.map +1 -1
  85. package/dist/es6/card/lib/CardBody.js +1 -3
  86. package/dist/es6/card/lib/CardHeading.d.ts.map +1 -1
  87. package/dist/es6/card/lib/CardHeading.js +2 -7
  88. package/dist/es6/checkbox/index.d.ts.map +1 -1
  89. package/dist/es6/checkbox/lib/Checkbox.d.ts.map +1 -1
  90. package/dist/es6/checkbox/lib/Checkbox.js +3 -14
  91. package/dist/es6/color-picker/index.d.ts.map +1 -1
  92. package/dist/es6/dialog/lib/Dialog.d.ts +1 -1
  93. package/dist/es6/form-field/index.d.ts.map +1 -1
  94. package/dist/es6/form-field/lib/Hint.d.ts.map +1 -1
  95. package/dist/es6/form-field/lib/Hint.js +6 -14
  96. package/dist/es6/index.d.ts +1 -0
  97. package/dist/es6/index.d.ts.map +1 -1
  98. package/dist/es6/index.js +1 -0
  99. package/dist/es6/layout/index.d.ts +4 -0
  100. package/dist/es6/layout/index.d.ts.map +1 -1
  101. package/dist/es6/layout/index.js +3 -0
  102. package/dist/es6/layout/lib/Box.d.ts +4 -2
  103. package/dist/es6/layout/lib/Box.d.ts.map +1 -1
  104. package/dist/es6/layout/lib/Box.js +27 -3
  105. package/dist/es6/layout/lib/Flex.d.ts +1 -1
  106. package/dist/es6/layout/lib/Flex.d.ts.map +1 -1
  107. package/dist/es6/layout/lib/Grid.d.ts +52 -0
  108. package/dist/es6/layout/lib/Grid.d.ts.map +1 -0
  109. package/dist/es6/layout/lib/Grid.js +92 -0
  110. package/dist/es6/layout/lib/Stack.d.ts +4 -4
  111. package/dist/es6/layout/lib/Stack.js +4 -4
  112. package/dist/es6/layout/lib/utils/color.d.ts.map +1 -1
  113. package/dist/es6/layout/lib/utils/color.js +2 -1
  114. package/dist/es6/layout/lib/utils/font.d.ts +29 -0
  115. package/dist/es6/layout/lib/utils/font.d.ts.map +1 -0
  116. package/dist/es6/layout/lib/utils/font.js +53 -0
  117. package/dist/es6/layout/lib/utils/grid.d.ts +58 -0
  118. package/dist/es6/layout/lib/utils/grid.d.ts.map +1 -0
  119. package/dist/es6/layout/lib/utils/grid.js +45 -0
  120. package/dist/es6/layout/lib/utils/gridItem.d.ts +39 -0
  121. package/dist/es6/layout/lib/utils/gridItem.d.ts.map +1 -0
  122. package/dist/es6/layout/lib/utils/gridItem.js +39 -0
  123. package/dist/es6/layout/lib/utils/text.d.ts +35 -0
  124. package/dist/es6/layout/lib/utils/text.d.ts.map +1 -0
  125. package/dist/es6/layout/lib/utils/text.js +44 -0
  126. package/dist/es6/modal/lib/Modal.d.ts +1 -1
  127. package/dist/es6/pagination/lib/Pagination/AdditionalDetails.d.ts.map +1 -1
  128. package/dist/es6/pagination/lib/Pagination/AdditionalDetails.js +6 -5
  129. package/dist/es6/pagination/lib/Pagination/GoTo/Label.d.ts.map +1 -1
  130. package/dist/es6/pagination/lib/Pagination/GoTo/Label.js +2 -4
  131. package/dist/es6/popup/lib/Popup.d.ts +1 -1
  132. package/dist/es6/popup/lib/PopupBody.d.ts +1 -1
  133. package/dist/es6/popup/lib/PopupCard.d.ts.map +1 -1
  134. package/dist/es6/popup/lib/PopupCard.js +2 -2
  135. package/dist/es6/radio/lib/Radio.d.ts.map +1 -1
  136. package/dist/es6/radio/lib/Radio.js +3 -14
  137. package/dist/es6/side-panel/lib/SidePanel.d.ts.map +1 -1
  138. package/dist/es6/side-panel/lib/SidePanel.js +3 -3
  139. package/dist/es6/tabs/lib/TabsItem.d.ts +1 -1
  140. package/dist/es6/text/index.d.ts +4 -0
  141. package/dist/es6/text/index.d.ts.map +1 -0
  142. package/dist/es6/text/index.js +3 -0
  143. package/dist/es6/text/lib/LabelText.d.ts +8 -0
  144. package/dist/es6/text/lib/LabelText.d.ts.map +1 -0
  145. package/dist/es6/text/lib/LabelText.js +29 -0
  146. package/dist/es6/text/lib/Text.d.ts +14 -0
  147. package/dist/es6/text/lib/Text.d.ts.map +1 -0
  148. package/dist/es6/text/lib/Text.js +68 -0
  149. package/dist/es6/text/lib/TypeLevelComponents.d.ts +13 -0
  150. package/dist/es6/text/lib/TypeLevelComponents.d.ts.map +1 -0
  151. package/dist/es6/text/lib/TypeLevelComponents.js +57 -0
  152. package/dist/es6/text-input/index.d.ts.map +1 -1
  153. package/form-field/index.ts +0 -1
  154. package/form-field/lib/Hint.tsx +8 -19
  155. package/index.ts +1 -0
  156. package/layout/index.ts +4 -0
  157. package/layout/lib/Box.tsx +34 -4
  158. package/layout/lib/Grid.tsx +88 -0
  159. package/layout/lib/Stack.tsx +4 -4
  160. package/layout/lib/utils/color.ts +7 -2
  161. package/layout/lib/utils/font.ts +67 -0
  162. package/layout/lib/utils/grid.ts +93 -0
  163. package/layout/lib/utils/gridItem.ts +68 -0
  164. package/layout/lib/utils/text.ts +57 -0
  165. package/package.json +5 -5
  166. package/pagination/lib/Pagination/AdditionalDetails.tsx +7 -8
  167. package/pagination/lib/Pagination/GoTo/Label.tsx +3 -11
  168. package/popup/lib/PopupCard.tsx +2 -1
  169. package/radio/lib/Radio.tsx +9 -24
  170. package/side-panel/lib/SidePanel.tsx +7 -7
  171. package/text/LICENSE +52 -0
  172. package/text/README.md +5 -0
  173. package/text/index.ts +3 -0
  174. package/text/lib/LabelText.tsx +25 -0
  175. package/text/lib/Text.tsx +66 -0
  176. package/text/lib/TypeLevelComponents.tsx +43 -0
  177. package/text/package.json +6 -0
  178. package/text-input/index.ts +0 -1
@@ -0,0 +1,58 @@
1
+ import { Property } from 'csstype';
2
+ /** style props to for grid container properties */
3
+ export declare type GridStyleProps = {
4
+ /** sets `align-items` property */
5
+ alignItems?: Property.AlignItems;
6
+ /** sets `align-content` property */
7
+ alignContent?: Property.AlignContent;
8
+ /**
9
+ * sets `display` property
10
+ * @default 'grid'
11
+ * */
12
+ display?: 'grid' | 'inline-grid';
13
+ /** sets `justify-items` property */
14
+ justifyItems?: Property.JustifyItems;
15
+ /** sets `justify-content` property */
16
+ justifyContent?: Property.JustifyContent;
17
+ /** sets `grid-template` property */
18
+ gridTemplate?: Property.GridTemplate;
19
+ /** sets `grid-template-area` property */
20
+ gridTemplateAreas?: Property.GridTemplateAreas;
21
+ /** sets `grid-template-columns` property */
22
+ gridTemplateColumns?: Property.GridTemplateColumns;
23
+ /** sets `grid-template-rows` property */
24
+ gridTemplateRows?: Property.GridTemplateRows;
25
+ /** sets `gap` property */
26
+ gridGap?: Property.GridGap;
27
+ /** sets `column-gap` property */
28
+ gridColumnGap?: Property.GridColumnGap;
29
+ /** sets `row-gap` property */
30
+ gridRowGap?: Property.GridRowGap;
31
+ /** sets `place-items` property */
32
+ gridPlaceItems?: Property.PlaceItems;
33
+ /** sets `grid-auto-columns` property */
34
+ gridAutoColumns?: Property.GridAutoColumns;
35
+ /** sets `grid-auto-rows` property */
36
+ gridAutoRows?: Property.GridAutoRows;
37
+ /** sets `grid-area` property */
38
+ gridArea?: Property.GridArea;
39
+ /** sets `grid-auto-flow` property */
40
+ gridAutoFlow?: Property.GridAutoFlow;
41
+ /** sets `grid` property */
42
+ grid?: Property.Grid;
43
+ };
44
+ /**
45
+ * A style prop function that takes component props and returns grid styles.
46
+ * If no `GridStyleProps` are found, it returns an empty object.
47
+ *
48
+ * @example
49
+ * // You'll most likely use `grid` with low-level, styled components
50
+ * const GridExample = () => (
51
+ * <Grid gridAutoFlow="row" justifyContent="center" alignItems="center">
52
+ * Hello, Grid!
53
+ * </Grid>
54
+ * );
55
+ *
56
+ */
57
+ export declare function grid<P extends GridStyleProps>(props: P): {};
58
+ //# sourceMappingURL=grid.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"grid.d.ts","sourceRoot":"","sources":["../../../../../layout/lib/utils/grid.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,QAAQ,EAAC,MAAM,SAAS,CAAC;AAEjC,mDAAmD;AACnD,oBAAY,cAAc,GAAG;IAC3B,kCAAkC;IAClC,UAAU,CAAC,EAAE,QAAQ,CAAC,UAAU,CAAC;IACjC,oCAAoC;IACpC,YAAY,CAAC,EAAE,QAAQ,CAAC,YAAY,CAAC;IACrC;;;SAGK;IACL,OAAO,CAAC,EAAE,MAAM,GAAG,aAAa,CAAC;IACjC,oCAAoC;IACpC,YAAY,CAAC,EAAE,QAAQ,CAAC,YAAY,CAAC;IACrC,sCAAsC;IACtC,cAAc,CAAC,EAAE,QAAQ,CAAC,cAAc,CAAC;IAGzC,oCAAoC;IACpC,YAAY,CAAC,EAAE,QAAQ,CAAC,YAAY,CAAC;IACrC,yCAAyC;IACzC,iBAAiB,CAAC,EAAE,QAAQ,CAAC,iBAAiB,CAAC;IAC/C,4CAA4C;IAC5C,mBAAmB,CAAC,EAAE,QAAQ,CAAC,mBAAmB,CAAC;IACnD,yCAAyC;IACzC,gBAAgB,CAAC,EAAE,QAAQ,CAAC,gBAAgB,CAAC;IAC7C,0BAA0B;IAC1B,OAAO,CAAC,EAAE,QAAQ,CAAC,OAAO,CAAC;IAC3B,iCAAiC;IACjC,aAAa,CAAC,EAAE,QAAQ,CAAC,aAAa,CAAC;IACvC,8BAA8B;IAC9B,UAAU,CAAC,EAAE,QAAQ,CAAC,UAAU,CAAC;IACjC,kCAAkC;IAClC,cAAc,CAAC,EAAE,QAAQ,CAAC,UAAU,CAAC;IACrC,wCAAwC;IACxC,eAAe,CAAC,EAAE,QAAQ,CAAC,eAAe,CAAC;IAC3C,qCAAqC;IACrC,YAAY,CAAC,EAAE,QAAQ,CAAC,YAAY,CAAC;IACrC,gCAAgC;IAChC,QAAQ,CAAC,EAAE,QAAQ,CAAC,QAAQ,CAAC;IAC7B,qCAAqC;IACrC,YAAY,CAAC,EAAE,QAAQ,CAAC,YAAY,CAAC;IACrC,2BAA2B;IAC3B,IAAI,CAAC,EAAE,QAAQ,CAAC,IAAI,CAAC;CACtB,CAAC;AAuBF;;;;;;;;;;;;GAYG;AACH,wBAAgB,IAAI,CAAC,CAAC,SAAS,cAAc,EAAE,KAAK,EAAE,CAAC,MAWtD"}
@@ -0,0 +1,45 @@
1
+ var gridProps = {
2
+ alignContent: 'alignContent',
3
+ alignItems: 'alignItems',
4
+ display: 'display',
5
+ justifyContent: 'justifyContent',
6
+ justifyItems: 'justifyItems',
7
+ gridTemplateAreas: 'gridTemplateAreas',
8
+ gridTemplate: 'gridTemplate',
9
+ gridTemplateColumns: 'gridTemplateColumns',
10
+ gridTemplateRows: 'gridTemplateRows',
11
+ gridGap: 'gridGap',
12
+ gridColumnGap: 'gridColumnGap',
13
+ gridRowGap: 'gridRowGap',
14
+ gridPlaceItems: 'gridPlaceItems',
15
+ gridAutoColumns: 'gridAutoColumns',
16
+ gridAutoRows: 'gridAutoRows',
17
+ gridAutoFlow: 'gridAutoFlow',
18
+ gridArea: 'gridArea',
19
+ grid: 'grid',
20
+ };
21
+ /**
22
+ * A style prop function that takes component props and returns grid styles.
23
+ * If no `GridStyleProps` are found, it returns an empty object.
24
+ *
25
+ * @example
26
+ * // You'll most likely use `grid` with low-level, styled components
27
+ * const GridExample = () => (
28
+ * <Grid gridAutoFlow="row" justifyContent="center" alignItems="center">
29
+ * Hello, Grid!
30
+ * </Grid>
31
+ * );
32
+ *
33
+ */
34
+ export function grid(props) {
35
+ var styles = {};
36
+ for (var key in props) {
37
+ if (key in gridProps) {
38
+ var attr = gridProps[key];
39
+ var value = props[key];
40
+ // @ts-ignore TS doesn't like adding a potentially unknown key to an object, but because we own this object, it's fine.
41
+ styles[attr] = value;
42
+ }
43
+ }
44
+ return styles;
45
+ }
@@ -0,0 +1,39 @@
1
+ import { Property } from 'csstype';
2
+ /** style props to for grid item properties */
3
+ export declare type GridItemStyleProps = {
4
+ /** sets `grid-column-start` property */
5
+ gridColumnStart?: Property.GridColumnStart;
6
+ /** sets `grid-column-end` property */
7
+ gridColumnEnd?: Property.GridColumnEnd;
8
+ /** sets `grid-row-start` property */
9
+ gridRowStart?: Property.GridRowStart;
10
+ /** sets `grid-row-end` property */
11
+ gridRowEnd?: Property.GridRowEnd;
12
+ /** sets `grid-column` property */
13
+ gridColumn?: Property.GridColumn;
14
+ /** sets `grid-row` property */
15
+ gridRow?: Property.GridRow;
16
+ /** sets `grid-area` property */
17
+ gridArea?: Property.GridArea;
18
+ /** sets `justify-self` property */
19
+ justifySelf?: Property.JustifySelf;
20
+ /** sets `align-self` property */
21
+ alignSelf?: Property.AlignSelf;
22
+ /** sets `place-self` property */
23
+ placeSelf?: Property.PlaceSelf;
24
+ };
25
+ /**
26
+ * A style prop function that takes component props and returns grid styles.
27
+ * If no `GridItemStyleProps` are found, it returns an empty object.
28
+ *
29
+ * @example
30
+ * // You'll most likely use `grid item` with low-level, styled components
31
+ * const GridItemExample = () => (
32
+ * <Grid.Item gridRowStart="1" justifySelf="center" gridArea="Card">
33
+ * Hello, Grid Item!
34
+ * </Grid.Item>
35
+ * );
36
+ *
37
+ */
38
+ export declare function gridItem<P extends GridItemStyleProps>(props: P): {};
39
+ //# sourceMappingURL=gridItem.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"gridItem.d.ts","sourceRoot":"","sources":["../../../../../layout/lib/utils/gridItem.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,QAAQ,EAAC,MAAM,SAAS,CAAC;AAEjC,8CAA8C;AAC9C,oBAAY,kBAAkB,GAAG;IAE/B,wCAAwC;IACxC,eAAe,CAAC,EAAE,QAAQ,CAAC,eAAe,CAAC;IAC3C,sCAAsC;IACtC,aAAa,CAAC,EAAE,QAAQ,CAAC,aAAa,CAAC;IACvC,qCAAqC;IACrC,YAAY,CAAC,EAAE,QAAQ,CAAC,YAAY,CAAC;IACrC,mCAAmC;IACnC,UAAU,CAAC,EAAE,QAAQ,CAAC,UAAU,CAAC;IACjC,kCAAkC;IAClC,UAAU,CAAC,EAAE,QAAQ,CAAC,UAAU,CAAC;IACjC,+BAA+B;IAC/B,OAAO,CAAC,EAAE,QAAQ,CAAC,OAAO,CAAC;IAC3B,gCAAgC;IAChC,QAAQ,CAAC,EAAE,QAAQ,CAAC,QAAQ,CAAC;IAC7B,mCAAmC;IACnC,WAAW,CAAC,EAAE,QAAQ,CAAC,WAAW,CAAC;IACnC,iCAAiC;IACjC,SAAS,CAAC,EAAE,QAAQ,CAAC,SAAS,CAAC;IAC/B,iCAAiC;IACjC,SAAS,CAAC,EAAE,QAAQ,CAAC,SAAS,CAAC;CAChC,CAAC;AAiBF;;;;;;;;;;;;GAYG;AAEH,wBAAgB,QAAQ,CAAC,CAAC,SAAS,kBAAkB,EAAE,KAAK,EAAE,CAAC,MAW9D"}
@@ -0,0 +1,39 @@
1
+ /** style props to for grid item properties */
2
+ var gridItemProps = {
3
+ //Child Props
4
+ gridColumnStart: 'gridColumnStart',
5
+ gridColumnEnd: 'gridColumnEnd',
6
+ gridRowStart: 'gridRowStart',
7
+ gridRowEnd: 'gridRowEnd',
8
+ gridColumn: 'gridColumn',
9
+ gridRow: 'gridRow',
10
+ gridArea: 'gridArea',
11
+ justifySelf: 'justifySelf',
12
+ alignSelf: 'alignSelf',
13
+ placeSelf: 'placeSelf',
14
+ };
15
+ /**
16
+ * A style prop function that takes component props and returns grid styles.
17
+ * If no `GridItemStyleProps` are found, it returns an empty object.
18
+ *
19
+ * @example
20
+ * // You'll most likely use `grid item` with low-level, styled components
21
+ * const GridItemExample = () => (
22
+ * <Grid.Item gridRowStart="1" justifySelf="center" gridArea="Card">
23
+ * Hello, Grid Item!
24
+ * </Grid.Item>
25
+ * );
26
+ *
27
+ */
28
+ export function gridItem(props) {
29
+ var styles = {};
30
+ for (var key in props) {
31
+ if (key in gridItemProps) {
32
+ var attr = gridItemProps[key];
33
+ var value = props[key];
34
+ // @ts-ignore TS doesn't like adding a potentially unknown key to an object, but because we own this object, it's fine.
35
+ styles[attr] = value;
36
+ }
37
+ }
38
+ return styles;
39
+ }
@@ -0,0 +1,35 @@
1
+ import { Property } from 'csstype';
2
+ /** style props to for text properties */
3
+ export declare type TextStyleProps = {
4
+ /** sets `line-height` property */
5
+ lineHeight?: Property.LineHeight;
6
+ /** sets `letter-spacing` property */
7
+ letterSpacing?: Property.LetterSpacing;
8
+ /** sets `text-align` property */
9
+ textAlign?: Property.TextAlign;
10
+ /** sets `text-decoration` property */
11
+ textDecoration?: Property.TextDecoration;
12
+ /** sets `text-overflow` property */
13
+ textOverflow?: Property.TextOverflow;
14
+ /** sets `text-transform` property */
15
+ textTransform?: Property.TextTransform;
16
+ /** sets `text-shadow` property */
17
+ textShadow?: Property.TextShadow;
18
+ /** sets `white-space` property */
19
+ whiteSpace?: Property.WhiteSpace;
20
+ /** sets `word-break` property */
21
+ wordBreak?: Property.WordBreak;
22
+ };
23
+ /**
24
+ * A style prop function that takes components props and returns text styles.
25
+ * If no `TextStyleProps` are found, it returns an empty object.
26
+ *
27
+ * @example
28
+ * // You'll most likely use `text-align` with low-level, styled components
29
+ * const BoxExample = () => (
30
+ * <Box textAlign="center">Hello, alignment!</Box>
31
+ * );
32
+ *
33
+ */
34
+ export declare function text<P extends TextStyleProps>(props: P): {};
35
+ //# sourceMappingURL=text.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"text.d.ts","sourceRoot":"","sources":["../../../../../layout/lib/utils/text.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,QAAQ,EAAC,MAAM,SAAS,CAAC;AAEjC,yCAAyC;AACzC,oBAAY,cAAc,GAAG;IAC3B,kCAAkC;IAClC,UAAU,CAAC,EAAE,QAAQ,CAAC,UAAU,CAAC;IACjC,qCAAqC;IACrC,aAAa,CAAC,EAAE,QAAQ,CAAC,aAAa,CAAC;IACvC,iCAAiC;IACjC,SAAS,CAAC,EAAE,QAAQ,CAAC,SAAS,CAAC;IAC/B,sCAAsC;IACtC,cAAc,CAAC,EAAE,QAAQ,CAAC,cAAc,CAAC;IACzC,oCAAoC;IACpC,YAAY,CAAC,EAAE,QAAQ,CAAC,YAAY,CAAC;IACrC,qCAAqC;IACrC,aAAa,CAAC,EAAE,QAAQ,CAAC,aAAa,CAAC;IACvC,kCAAkC;IAClC,UAAU,CAAC,EAAE,QAAQ,CAAC,UAAU,CAAC;IACjC,kCAAkC;IAClC,UAAU,CAAC,EAAE,QAAQ,CAAC,UAAU,CAAC;IACjC,iCAAiC;IACjC,SAAS,CAAC,EAAE,QAAQ,CAAC,SAAS,CAAC;CAChC,CAAC;AAcF;;;;;;;;;;GAUG;AACH,wBAAgB,IAAI,CAAC,CAAC,SAAS,cAAc,EAAE,KAAK,EAAE,CAAC,MAStD"}
@@ -0,0 +1,44 @@
1
+ var __assign = (this && this.__assign) || function () {
2
+ __assign = Object.assign || function(t) {
3
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
4
+ s = arguments[i];
5
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
6
+ t[p] = s[p];
7
+ }
8
+ return t;
9
+ };
10
+ return __assign.apply(this, arguments);
11
+ };
12
+ var textProps = [
13
+ 'lineHeight',
14
+ 'letterSpacing',
15
+ 'textAlign',
16
+ 'textDecoration',
17
+ 'textOverflow',
18
+ 'textTransform',
19
+ 'textShadow',
20
+ 'whiteSpace',
21
+ 'wordBreak',
22
+ ];
23
+ /**
24
+ * A style prop function that takes components props and returns text styles.
25
+ * If no `TextStyleProps` are found, it returns an empty object.
26
+ *
27
+ * @example
28
+ * // You'll most likely use `text-align` with low-level, styled components
29
+ * const BoxExample = () => (
30
+ * <Box textAlign="center">Hello, alignment!</Box>
31
+ * );
32
+ *
33
+ */
34
+ export function text(props) {
35
+ var _a;
36
+ var styles = {};
37
+ for (var key in props) {
38
+ if (textProps.includes(key)) {
39
+ var value = props[key];
40
+ styles = __assign(__assign({}, styles), (_a = {}, _a[key] = value, _a));
41
+ }
42
+ }
43
+ return styles;
44
+ }
@@ -99,7 +99,7 @@ export declare const Modal: import("../../common").ComponentM<import("../../dial
99
99
  hide(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
100
100
  };
101
101
  }> & {
102
- Body: import("../../common").ElementComponentM<"div", import("../..").BorderShorthandStyleProps & import("../..").BorderColorStyleProps & import("../..").BorderRadiusStyleProps & import("../..").BorderLineStyleProps & import("../..").BorderWidthStyleProps & import("../..").BorderLogicalStyleProps & import("../..").ColorStyleProps & import("../..").DepthStyleProps & import("../..").FlexItemStyleProps & import("../..").LayoutStyleProps & import("../../layout/lib/utils/other").OtherStyleProps & import("../..").PositionStandardProps & import("../..").PositionLogicalProps & import("../../layout/lib/utils/space").SpaceStandardProps & import("../../layout/lib/utils/space").SpaceLogicalProps & React.HTMLAttributes<HTMLDivElement>, {
102
+ Body: import("../../common").ElementComponentM<"div", import("../..").BorderShorthandStyleProps & import("../..").BorderColorStyleProps & import("../..").BorderRadiusStyleProps & import("../..").BorderLineStyleProps & import("../..").BorderWidthStyleProps & import("../..").BorderLogicalStyleProps & import("../..").ColorStyleProps & import("../..").DepthStyleProps & import("../..").FlexItemStyleProps & import("../..").FontStyleProps & import("../..").LayoutStyleProps & import("../../layout/lib/utils/other").OtherStyleProps & import("../..").PositionStandardProps & import("../..").PositionLogicalProps & import("../../layout/lib/utils/space").SpaceStandardProps & import("../../layout/lib/utils/space").SpaceLogicalProps & import("../..").TextStyleProps & React.HTMLAttributes<HTMLDivElement>, {
103
103
  state: {
104
104
  stackRef: React.RefObject<HTMLDivElement>;
105
105
  targetRef: React.RefObject<HTMLButtonElement>;
@@ -1 +1 @@
1
- {"version":3,"file":"AdditionalDetails.d.ts","sourceRoot":"","sources":["../../../../../pagination/lib/Pagination/AdditionalDetails.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B,OAAO,EAAC,eAAe,EAAC,MAAM,SAAS,CAAC;AACxC,OAAO,EAAO,SAAS,EAAC,MAAM,kCAAkC,CAAC;AAGjE,MAAM,WAAW,sBAAuB,SAAQ,IAAI,CAAC,SAAS,EAAE,UAAU,CAAC;IACzE,QAAQ,EAAE,CAAC,KAAK,EAAE,eAAe,KAAK,KAAK,CAAC,SAAS,GAAG,KAAK,CAAC,SAAS,CAAC;IACxE,KAAK,EAAE,eAAe,CAAC;IACvB,4BAA4B,CAAC,EAAE,OAAO,CAAC;IACvC,iBAAiB,CAAC,EAAE,OAAO,CAAC;CAC7B;AAuBD,eAAO,MAAM,iBAAiB,oEAK3B,sBAAsB,gBAQxB,CAAC"}
1
+ {"version":3,"file":"AdditionalDetails.d.ts","sourceRoot":"","sources":["../../../../../pagination/lib/Pagination/AdditionalDetails.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B,OAAO,EAAC,eAAe,EAAC,MAAM,SAAS,CAAC;AACxC,OAAO,EAAO,SAAS,EAAC,MAAM,kCAAkC,CAAC;AAGjE,MAAM,WAAW,sBAAuB,SAAQ,IAAI,CAAC,SAAS,EAAE,UAAU,CAAC;IACzE,QAAQ,EAAE,CAAC,KAAK,EAAE,eAAe,KAAK,KAAK,CAAC,SAAS,GAAG,KAAK,CAAC,SAAS,CAAC;IACxE,KAAK,EAAE,eAAe,CAAC;IACvB,4BAA4B,CAAC,EAAE,OAAO,CAAC;IACvC,iBAAiB,CAAC,EAAE,OAAO,CAAC;CAC7B;AAiBD,eAAO,MAAM,iBAAiB,oEAK3B,sBAAsB,gBAaxB,CAAC"}
@@ -21,22 +21,23 @@ var __rest = (this && this.__rest) || function (s, e) {
21
21
  return t;
22
22
  };
23
23
  import * as React from 'react';
24
- import { type, typeColors, space } from '@workday/canvas-kit-react/tokens';
24
+ import { type, space, typeColors } from '@workday/canvas-kit-react/tokens';
25
25
  import { accessibleHide, styled } from '@workday/canvas-kit-react/common';
26
26
  import { Flex } from '@workday/canvas-kit-react/layout';
27
27
  import { useLiveRegion } from './common/useLiveRegion';
28
28
  var StyledAdditionalDetails = styled(Flex)(function (_a) {
29
29
  var shouldHideDetails = _a.shouldHideDetails;
30
- var styles = __assign(__assign({}, type.levels.subtext.medium), { color: typeColors.hint });
31
30
  if (shouldHideDetails) {
32
- return __assign(__assign(__assign({}, styles), accessibleHide), { marginTop: space.zero });
31
+ return __assign(__assign({}, accessibleHide), { marginTop: space.zero });
33
32
  }
34
33
  else {
35
- return __assign(__assign({}, styles), { marginTop: space.xs });
34
+ return {
35
+ marginTop: space.xs,
36
+ };
36
37
  }
37
38
  });
38
39
  export var AdditionalDetails = function (_a) {
39
40
  var model = _a.model, children = _a.children, shouldAnnounceToScreenReader = _a.shouldAnnounceToScreenReader, elemProps = __rest(_a, ["model", "children", "shouldAnnounceToScreenReader"]);
40
41
  var liveRegionProps = useLiveRegion({ shouldAnnounceToScreenReader: shouldAnnounceToScreenReader });
41
- return (React.createElement(StyledAdditionalDetails, __assign({}, liveRegionProps, elemProps), typeof children === 'function' ? children(model) : children));
42
+ return (React.createElement(StyledAdditionalDetails, __assign({}, type.levels.subtext.medium, { color: typeColors.hint }, liveRegionProps, elemProps), typeof children === 'function' ? children(model) : children));
42
43
  };
@@ -1 +1 @@
1
- {"version":3,"file":"Label.d.ts","sourceRoot":"","sources":["../../../../../../pagination/lib/Pagination/GoTo/Label.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B,OAAO,EAAC,eAAe,EAAC,MAAM,UAAU,CAAC;AAGzC,MAAM,WAAW,cACf,SAAQ,IAAI,CAAC,KAAK,CAAC,mBAAmB,CAAC,gBAAgB,CAAC,EAAE,UAAU,CAAC;IACrE,KAAK,EAAE,eAAe,CAAC;IACvB;;OAEG;IACH,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,eAAe,KAAK,KAAK,CAAC,SAAS,GAAG,KAAK,CAAC,SAAS,CAAC;CAC1E;AAQD,eAAO,MAAM,SAAS,sCAAqC,cAAc,gBAMxE,CAAC"}
1
+ {"version":3,"file":"Label.d.ts","sourceRoot":"","sources":["../../../../../../pagination/lib/Pagination/GoTo/Label.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAC,eAAe,EAAC,MAAM,UAAU,CAAC;AAGzC,MAAM,WAAW,cACf,SAAQ,IAAI,CAAC,KAAK,CAAC,mBAAmB,CAAC,gBAAgB,CAAC,EAAE,UAAU,CAAC;IACrE,KAAK,EAAE,eAAe,CAAC;IACvB;;OAEG;IACH,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,eAAe,KAAK,KAAK,CAAC,SAAS,GAAG,KAAK,CAAC,SAAS,CAAC;CAC1E;AAED,eAAO,MAAM,SAAS,sCAAqC,cAAc,gBAMxE,CAAC"}
@@ -21,10 +21,8 @@ var __rest = (this && this.__rest) || function (s, e) {
21
21
  return t;
22
22
  };
23
23
  import * as React from 'react';
24
- import { type, typeColors } from '@workday/canvas-kit-react/tokens';
25
- import { styled } from '@workday/canvas-kit-react/common';
26
- var StyledLabel = styled('label')(__assign(__assign({}, type.levels.subtext.medium), { color: typeColors.hint, whiteSpace: 'nowrap' }));
24
+ import { LabelText } from '@workday/canvas-kit-react/text';
27
25
  export var GoToLabel = function (_a) {
28
26
  var model = _a.model, children = _a.children, elemProps = __rest(_a, ["model", "children"]);
29
- return (React.createElement(StyledLabel, __assign({}, elemProps), typeof children === 'function' ? children(model) : children));
27
+ return (React.createElement(LabelText, __assign({ typeLevel: "subtext.medium", variant: "hint", whiteSpace: "nowrap" }, elemProps), typeof children === 'function' ? children(model) : children));
30
28
  };
@@ -106,7 +106,7 @@ export declare const Popup: import("../../common").ComponentM<PopupProps & Parti
106
106
  hide(event?: Event | React.SyntheticEvent<Element, Event> | undefined): void;
107
107
  };
108
108
  }>;
109
- Body: import("../../common").ElementComponentM<"div", import("../..").BorderShorthandStyleProps & import("../..").BorderColorStyleProps & import("../..").BorderRadiusStyleProps & import("../..").BorderLineStyleProps & import("../..").BorderWidthStyleProps & import("../..").BorderLogicalStyleProps & import("../..").ColorStyleProps & import("../..").DepthStyleProps & import("../..").FlexItemStyleProps & import("../..").LayoutStyleProps & import("../../layout/lib/utils/other").OtherStyleProps & import("../..").PositionStandardProps & import("../..").PositionLogicalProps & import("../../layout/lib/utils/space").SpaceStandardProps & import("../../layout/lib/utils/space").SpaceLogicalProps & React.HTMLAttributes<HTMLDivElement>, {
109
+ Body: import("../../common").ElementComponentM<"div", import("../..").BorderShorthandStyleProps & import("../..").BorderColorStyleProps & import("../..").BorderRadiusStyleProps & import("../..").BorderLineStyleProps & import("../..").BorderWidthStyleProps & import("../..").BorderLogicalStyleProps & import("../..").ColorStyleProps & import("../..").DepthStyleProps & import("../..").FlexItemStyleProps & import("../..").FontStyleProps & import("../..").LayoutStyleProps & import("../../layout/lib/utils/other").OtherStyleProps & import("../..").PositionStandardProps & import("../..").PositionLogicalProps & import("../../layout/lib/utils/space").SpaceStandardProps & import("../../layout/lib/utils/space").SpaceLogicalProps & import("../..").TextStyleProps & React.HTMLAttributes<HTMLDivElement>, {
110
110
  state: {
111
111
  stackRef: React.RefObject<HTMLDivElement>;
112
112
  targetRef: React.RefObject<HTMLButtonElement>;
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- export declare const PopupBody: import("../../common").ElementComponentM<"div", import("../..").BorderShorthandStyleProps & import("../..").BorderColorStyleProps & import("../..").BorderRadiusStyleProps & import("../..").BorderLineStyleProps & import("../..").BorderWidthStyleProps & import("../..").BorderLogicalStyleProps & import("../..").ColorStyleProps & import("../..").DepthStyleProps & import("../..").FlexItemStyleProps & import("../..").LayoutStyleProps & import("../../layout/lib/utils/other").OtherStyleProps & import("../..").PositionStandardProps & import("../..").PositionLogicalProps & import("../../layout/lib/utils/space").SpaceStandardProps & import("../../layout/lib/utils/space").SpaceLogicalProps & React.HTMLAttributes<HTMLDivElement>, {
2
+ export declare const PopupBody: import("../../common").ElementComponentM<"div", import("../..").BorderShorthandStyleProps & import("../..").BorderColorStyleProps & import("../..").BorderRadiusStyleProps & import("../..").BorderLineStyleProps & import("../..").BorderWidthStyleProps & import("../..").BorderLogicalStyleProps & import("../..").ColorStyleProps & import("../..").DepthStyleProps & import("../..").FlexItemStyleProps & import("../..").FontStyleProps & import("../..").LayoutStyleProps & import("../../layout/lib/utils/other").OtherStyleProps & import("../..").PositionStandardProps & import("../..").PositionLogicalProps & import("../../layout/lib/utils/space").SpaceStandardProps & import("../../layout/lib/utils/space").SpaceLogicalProps & import("../..").TextStyleProps & React.HTMLAttributes<HTMLDivElement>, {
3
3
  state: {
4
4
  stackRef: React.RefObject<HTMLDivElement>;
5
5
  targetRef: React.RefObject<HTMLButtonElement>;
@@ -1 +1 @@
1
- {"version":3,"file":"PopupCard.d.ts","sourceRoot":"","sources":["../../../../popup/lib/PopupCard.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B,OAAO,EAAC,IAAI,EAAC,MAAM,gCAAgC,CAAC;AAEpD,OAAO,EAKL,YAAY,EAGb,MAAM,kCAAkC,CAAC;AAC1C,OAAO,EAAQ,eAAe,EAAC,MAAM,kCAAkC,CAAC;AAKxE,MAAM,WAAW,cAAe,SAAQ,YAAY,CAAC,OAAO,IAAI,EAAE,KAAK,CAAC,EAAE,OAAO,CAAC,eAAe,CAAC;IAChG,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAC5B;AAmCD,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;EAgCpB,CAAC"}
1
+ {"version":3,"file":"PopupCard.d.ts","sourceRoot":"","sources":["../../../../popup/lib/PopupCard.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAG/B,OAAO,EAAC,IAAI,EAAC,MAAM,gCAAgC,CAAC;AAEpD,OAAO,EAKL,YAAY,EAGb,MAAM,kCAAkC,CAAC;AAC1C,OAAO,EAAQ,eAAe,EAAC,MAAM,kCAAkC,CAAC;AAKxE,MAAM,WAAW,cAAe,SAAQ,YAAY,CAAC,OAAO,IAAI,EAAE,KAAK,CAAC,EAAE,OAAO,CAAC,eAAe,CAAC;IAChG,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAC5B;AAmCD,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;EAiCpB,CAAC"}
@@ -36,7 +36,7 @@ var popupAnimation = function (transformOrigin) {
36
36
  var translate = getTranslateFromOrigin(transformOrigin, space.xxs);
37
37
  return keyframes(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n 0% {\n opacity: 0;\n transform: translate(", "px, ", "px);\n }\n 100% {\n opacity: 1;\n transform: translate(0);\n }\n "], ["\n 0% {\n opacity: 0;\n transform: translate(", "px, ", "px);\n }\n 100% {\n opacity: 1;\n transform: translate(0);\n }\n "])), translate.x, translate.y);
38
38
  };
39
- var StyledPopupCard = styled(Card)(type.levels.subtext.large, function (_a) {
39
+ var StyledPopupCard = styled(Card)(function (_a) {
40
40
  var transformOrigin = _a.transformOrigin;
41
41
  if (transformOrigin == null) {
42
42
  return {};
@@ -64,6 +64,6 @@ export var PopupCard = createSubcomponent('div')({
64
64
  // As is a Stack that will render an element of `Element`
65
65
  var As = useConstant(function () { return Stack.as(Element); });
66
66
  return (React.createElement(StyledPopupCard, __assign({ as: As, transformOrigin: transformOrigin, position: "relative", padding: "l", depth: 5, maxWidth: "calc(100vw - " + space.l + ")", spacing: 0, flexDirection: "column", minHeight: 0, maxHeight: "calc(100vh - " + (elemProps.margin ? space[elemProps.margin] || elemProps.margin : space.xl) + " * 2)", overflowY: "auto" // force IE11 to limit the flex size of the card. Without this, the body isn't allowed to overflow properly: https://github.com/philipwalton/flexbugs/issues/216#issuecomment-453053557
67
- }, elemProps), children));
67
+ }, type.levels.subtext.large, elemProps), children));
68
68
  });
69
69
  var templateObject_1;
@@ -1 +1 @@
1
- {"version":3,"file":"Radio.d.ts","sourceRoot":"","sources":["../../../../radio/lib/Radio.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAML,SAAS,EAEV,MAAM,kCAAkC,CAAC;AAS1C,MAAM,WAAW,UAAW,SAAQ,SAAS;IAC3C;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB;;;OAGG;IACH,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ;;;OAGG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,QAAQ,CAAC,EAAE,CAAC,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC,gBAAgB,CAAC,KAAK,IAAI,CAAC;IAC5D;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,SAAS,GAAG,SAAS,CAAC;CACjC;AAkPD,eAAO,MAAM,KAAK,8DAgDhB,CAAC"}
1
+ {"version":3,"file":"Radio.d.ts","sourceRoot":"","sources":["../../../../radio/lib/Radio.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAML,SAAS,EAEV,MAAM,kCAAkC,CAAC;AAI1C,MAAM,WAAW,UAAW,SAAQ,SAAS;IAC3C;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB;;;OAGG;IACH,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ;;;OAGG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,QAAQ,CAAC,EAAE,CAAC,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC,gBAAgB,CAAC,KAAK,IAAI,CAAC;IAC5D;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,SAAS,GAAG,SAAS,CAAC;CACjC;AAmOD,eAAO,MAAM,KAAK,8DAqDhB,CAAC"}
@@ -22,7 +22,8 @@ var __rest = (this && this.__rest) || function (s, e) {
22
22
  };
23
23
  import * as React from 'react';
24
24
  import { createComponent, focusRing, mouseFocusBehavior, styled, useUniqueId, } from '@workday/canvas-kit-react/common';
25
- import { canvas, borderRadius, colors, inputColors, spaceNumbers, } from '@workday/canvas-kit-react/tokens';
25
+ import { borderRadius, colors, inputColors, spaceNumbers } from '@workday/canvas-kit-react/tokens';
26
+ import { LabelText } from '@workday/canvas-kit-react/text';
26
27
  var radioBorderRadius = 9;
27
28
  var radioDot = 8;
28
29
  var radioHeight = 18;
@@ -201,18 +202,6 @@ var RadioCheck = styled('div')({
201
202
  transform: checked ? 'scale(1)' : 'scale(0.5)',
202
203
  });
203
204
  });
204
- var RadioLabel = styled('label')(__assign(__assign({}, canvas.type.levels.subtext.large), { paddingLeft: radioLabelDistance }), function (_a) {
205
- var variant = _a.variant;
206
- return (variant === 'inverse' ? { color: colors.frenchVanilla100 } : undefined);
207
- }, function (_a) {
208
- var disabled = _a.disabled, variant = _a.variant;
209
- return disabled
210
- ? {
211
- color: variant === 'inverse' ? colors.frenchVanilla100 : inputColors.disabled.text,
212
- opacity: variant === 'inverse' ? '.4' : '1',
213
- }
214
- : { cursor: 'pointer' };
215
- });
216
205
  export var Radio = createComponent('input')({
217
206
  displayName: 'Radio',
218
207
  Component: function (_a, ref, Element) {
@@ -224,6 +213,6 @@ export var Radio = createComponent('input')({
224
213
  React.createElement(RadioRipple, { variant: variant }),
225
214
  React.createElement(RadioBackground, { checked: checked, disabled: disabled, variant: variant },
226
215
  React.createElement(RadioCheck, { checked: checked, variant: variant }))),
227
- label && (React.createElement(RadioLabel, { htmlFor: inputId, disabled: disabled, variant: variant }, label))));
216
+ label && (React.createElement(LabelText, { paddingLeft: radioLabelDistance, htmlFor: inputId, disabled: disabled, variant: variant }, label))));
228
217
  },
229
218
  });
@@ -1 +1 @@
1
- {"version":3,"file":"SidePanel.d.ts","sourceRoot":"","sources":["../../../../side-panel/lib/SidePanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAK/B,OAAO,EAAsB,iBAAiB,EAAC,MAAM,kCAAkC,CAAC;AAIxF,MAAM,WAAW,cAAe,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IAC1E;;;OAGG;IACH,IAAI,EAAE,OAAO,CAAC;IACd;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,IAAI,CAAC;IAC3B;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,GAAG,KAAK,CAAC,SAAS,CAAC;IAClC;;;OAGG;IACH,aAAa,CAAC,EAAE,sBAAsB,CAAC;IACvC;;OAEG;IACH,kBAAkB,CAAC,EAAE,CAAC,eAAe,EAAE,OAAO,KAAK,IAAI,CAAC;IACxD;;OAEG;IACH,OAAO,CAAC,EAAE,iBAAiB,CAAC;IAC5B;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;OAGG;IACH,eAAe,CAAC,EAAE,wBAAwB,CAAC;IAC3C;;;OAGG;IACH,wBAAwB,CAAC,EAAE,MAAM,CAAC;IAClC;;;OAGG;IACH,uBAAuB,CAAC,EAAE,MAAM,CAAC;CAClC;AAED,MAAM,WAAW,cAAc;IAC7B,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,oBAAY,sBAAsB;IAChC,IAAI,IAAA;IACJ,KAAK,IAAA;CACN;AAED,oBAAY,wBAAwB;IAClC,KAAK,IAAA;IACL,WAAW,IAAA;IACX,IAAI,IAAA;CACL;AA6FD,qBAAa,SAAU,SAAQ,KAAK,CAAC,SAAS,CAAC,cAAc,EAAE,cAAc,CAAC;IAC5E,MAAM,CAAC,aAAa,gCAA0B;IAC9C,MAAM,CAAC,eAAe,kCAA4B;gBAEtC,KAAK,EAAE,cAAc;IAKjC,KAAK;;MAEH;IAEK,iBAAiB;IAGjB,oBAAoB;IAIpB,MAAM;IA4Cb,OAAO,CAAC,YAAY,CAWlB;IAEF,OAAO,CAAC,aAAa,CAInB;IAEF,OAAO,CAAC,qBAAqB,CAS3B;CACH"}
1
+ {"version":3,"file":"SidePanel.d.ts","sourceRoot":"","sources":["../../../../side-panel/lib/SidePanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAK/B,OAAO,EAAgB,iBAAiB,EAAC,MAAM,kCAAkC,CAAC;AAKlF,MAAM,WAAW,cAAe,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IAC1E;;;OAGG;IACH,IAAI,EAAE,OAAO,CAAC;IACd;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,IAAI,CAAC;IAC3B;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,GAAG,KAAK,CAAC,SAAS,CAAC;IAClC;;;OAGG;IACH,aAAa,CAAC,EAAE,sBAAsB,CAAC;IACvC;;OAEG;IACH,kBAAkB,CAAC,EAAE,CAAC,eAAe,EAAE,OAAO,KAAK,IAAI,CAAC;IACxD;;OAEG;IACH,OAAO,CAAC,EAAE,iBAAiB,CAAC;IAC5B;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;OAGG;IACH,eAAe,CAAC,EAAE,wBAAwB,CAAC;IAC3C;;;OAGG;IACH,wBAAwB,CAAC,EAAE,MAAM,CAAC;IAClC;;;OAGG;IACH,uBAAuB,CAAC,EAAE,MAAM,CAAC;CAClC;AAED,MAAM,WAAW,cAAc;IAC7B,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,oBAAY,sBAAsB;IAChC,IAAI,IAAA;IACJ,KAAK,IAAA;CACN;AAED,oBAAY,wBAAwB;IAClC,KAAK,IAAA;IACL,WAAW,IAAA;IACX,IAAI,IAAA;CACL;AAwFD,qBAAa,SAAU,SAAQ,KAAK,CAAC,SAAS,CAAC,cAAc,EAAE,cAAc,CAAC;IAC5E,MAAM,CAAC,aAAa,gCAA0B;IAC9C,MAAM,CAAC,eAAe,kCAA4B;gBAEtC,KAAK,EAAE,cAAc;IAKjC,KAAK;;MAEH;IAEK,iBAAiB;IAGjB,oBAAoB;IAIpB,MAAM;IAgDb,OAAO,CAAC,YAAY,CAWlB;IAEF,OAAO,CAAC,aAAa,CAInB;IAEF,OAAO,CAAC,qBAAqB,CAS3B;CACH"}
@@ -36,9 +36,10 @@ var __rest = (this && this.__rest) || function (s, e) {
36
36
  import * as React from 'react';
37
37
  import styled from '@emotion/styled';
38
38
  import throttle from 'lodash/throttle';
39
- import { colors, space, type } from '@workday/canvas-kit-react/tokens';
39
+ import { colors, space } from '@workday/canvas-kit-react/tokens';
40
40
  import { TertiaryButton } from '@workday/canvas-kit-react/button';
41
41
  import { chevronLeftIcon, chevronRightIcon } from '@workday/canvas-system-icons-web';
42
+ import { Heading } from '@workday/canvas-kit-react/text';
42
43
  export var SidePanelOpenDirection;
43
44
  (function (SidePanelOpenDirection) {
44
45
  SidePanelOpenDirection[SidePanelOpenDirection["Left"] = 0] = "Left";
@@ -51,7 +52,6 @@ export var SidePanelBackgroundColor;
51
52
  SidePanelBackgroundColor[SidePanelBackgroundColor["Gray"] = 2] = "Gray";
52
53
  })(SidePanelBackgroundColor || (SidePanelBackgroundColor = {}));
53
54
  var closedWidth = space.xxl;
54
- var Header = styled('h2')(__assign(__assign({}, type.levels.heading.small), { marginTop: space.zero }));
55
55
  var SidePanelContainer = styled('div')({
56
56
  overflow: 'hidden',
57
57
  height: '100%',
@@ -176,7 +176,7 @@ var SidePanel = /** @class */ (function (_super) {
176
176
  var _a = this.props, _b = _a.backgroundColor, backgroundColor = _b === void 0 ? SidePanelBackgroundColor.White : _b, _c = _a.openNavigationAriaLabel, openNavigationAriaLabel = _c === void 0 ? 'open navigation' : _c, _d = _a.closeNavigationAriaLabel, closeNavigationAriaLabel = _d === void 0 ? 'close navigation' : _d, _e = _a.openDirection, openDirection = _e === void 0 ? SidePanelOpenDirection.Left : _e, _f = _a.breakpoint, breakpoint = _f === void 0 ? 768 : _f, _g = _a.openWidth, openWidth = _g === void 0 ? 300 : _g, header = _a.header, onToggleClick = _a.onToggleClick, open = _a.open, padding = _a.padding, onBreakpointChange = _a.onBreakpointChange, elemProps = __rest(_a, ["backgroundColor", "openNavigationAriaLabel", "closeNavigationAriaLabel", "openDirection", "breakpoint", "openWidth", "header", "onToggleClick", "open", "padding", "onBreakpointChange"]);
177
177
  return (React.createElement(SidePanelContainer, __assign({ role: "region", padding: padding, openDirection: openDirection, openWidth: openWidth, backgroundColor: backgroundColor, open: open }, elemProps),
178
178
  React.createElement(ChildrenContainer, { open: open, openWidth: openWidth },
179
- header && open ? React.createElement(Header, null, header) : null,
179
+ header && open ? (React.createElement(Heading, { as: "h2", size: "small", marginTop: "zero" }, header)) : null,
180
180
  this.props.children),
181
181
  React.createElement(SidePanelFooter, { openWidth: openWidth, open: open }, onToggleClick && (React.createElement(ToggleButton, { openDirection: openDirection, "aria-label": open ? closeNavigationAriaLabel : openNavigationAriaLabel, onClick: this.onToggleClick, icon: this.toggleButtonDirection(open, openDirection) })))));
182
182
  };
@@ -53,7 +53,7 @@ export interface TabsItemProps extends ExtractProps<typeof Box, never>, Partial<
53
53
  */
54
54
  tabIndex?: number;
55
55
  }
56
- export declare const StyledTabItem: import("@emotion/styled").StyledComponent<import("../../layout").BorderShorthandStyleProps & import("../../layout").BorderColorStyleProps & import("../../layout").BorderRadiusStyleProps & import("../../layout").BorderLineStyleProps & import("../../layout").BorderWidthStyleProps & import("../../layout").BorderLogicalStyleProps & import("../../layout").ColorStyleProps & import("../../layout").DepthStyleProps & import("../../layout").FlexItemStyleProps & import("../../layout").LayoutStyleProps & import("../../layout/lib/utils/other").OtherStyleProps & import("../../layout").PositionStandardProps & import("../../layout").PositionLogicalProps & import("../../layout/lib/utils/space").SpaceStandardProps & import("../../layout/lib/utils/space").SpaceLogicalProps & Pick<React.DetailedHTMLProps<React.ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "name" | "style" | "ref" | "form" | "slot" | "title" | "dir" | "value" | "children" | "hidden" | "type" | "disabled" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "draggable" | "id" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "key" | "autoFocus" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget"> & {
56
+ export declare const StyledTabItem: import("@emotion/styled").StyledComponent<import("../../layout").BorderShorthandStyleProps & import("../../layout").BorderColorStyleProps & import("../../layout").BorderRadiusStyleProps & import("../../layout").BorderLineStyleProps & import("../../layout").BorderWidthStyleProps & import("../../layout").BorderLogicalStyleProps & import("../../layout").ColorStyleProps & import("../../layout").DepthStyleProps & import("../../layout").FlexItemStyleProps & import("../../layout").FontStyleProps & import("../../layout").LayoutStyleProps & import("../../layout/lib/utils/other").OtherStyleProps & import("../../layout").PositionStandardProps & import("../../layout").PositionLogicalProps & import("../../layout/lib/utils/space").SpaceStandardProps & import("../../layout/lib/utils/space").SpaceLogicalProps & import("../../layout").TextStyleProps & Pick<React.DetailedHTMLProps<React.ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "name" | "style" | "ref" | "form" | "slot" | "title" | "dir" | "value" | "children" | "hidden" | "type" | "disabled" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "draggable" | "id" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "key" | "autoFocus" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget"> & {
57
57
  ref?: ((instance: HTMLButtonElement | null) => void) | React.RefObject<HTMLButtonElement> | null | undefined;
58
58
  } & {
59
59
  theme?: import("@emotion/react").Theme | undefined;
@@ -0,0 +1,4 @@
1
+ export * from './lib/Text';
2
+ export * from './lib/TypeLevelComponents';
3
+ export * from './lib/LabelText';
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../text/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAC;AAC3B,cAAc,2BAA2B,CAAC;AAC1C,cAAc,iBAAiB,CAAC"}
@@ -0,0 +1,3 @@
1
+ export * from './lib/Text';
2
+ export * from './lib/TypeLevelComponents';
3
+ export * from './lib/LabelText';
@@ -0,0 +1,8 @@
1
+ import { Property } from 'csstype';
2
+ import { TextProps } from '@workday/canvas-kit-react/text';
3
+ export interface TypeLabelProps extends TextProps {
4
+ cursor?: Property.Cursor;
5
+ disabled?: boolean;
6
+ }
7
+ export declare const LabelText: import("../../common").ElementComponent<"label", TypeLabelProps>;
8
+ //# sourceMappingURL=LabelText.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LabelText.d.ts","sourceRoot":"","sources":["../../../../text/lib/LabelText.tsx"],"names":[],"mappings":"AACA,OAAO,EAAC,QAAQ,EAAC,MAAM,SAAS,CAAC;AAEjC,OAAO,EAAO,SAAS,EAAC,MAAM,gCAAgC,CAAC;AAG/D,MAAM,WAAW,cAAe,SAAQ,SAAS;IAC/C,MAAM,CAAC,EAAE,QAAQ,CAAC,MAAM,CAAC;IACzB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAUD,eAAO,MAAM,SAAS,kEAKpB,CAAC"}
@@ -0,0 +1,29 @@
1
+ var __assign = (this && this.__assign) || function () {
2
+ __assign = Object.assign || function(t) {
3
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
4
+ s = arguments[i];
5
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
6
+ t[p] = s[p];
7
+ }
8
+ return t;
9
+ };
10
+ return __assign.apply(this, arguments);
11
+ };
12
+ import * as React from 'react';
13
+ import { createComponent, styled } from '@workday/canvas-kit-react/common';
14
+ import { Text } from '@workday/canvas-kit-react/text';
15
+ import { inputColors } from '@workday/canvas-kit-react/tokens';
16
+ var StyledLabel = styled(Text.as('label'))(function (_a) {
17
+ var cursor = _a.cursor, disabled = _a.disabled, variant = _a.variant;
18
+ return ({
19
+ color: disabled && variant !== 'inverse' ? inputColors.disabled.text : undefined,
20
+ cursor: cursor && !disabled ? cursor : 'default',
21
+ opacity: disabled && variant === 'inverse' ? '.4' : '1',
22
+ });
23
+ });
24
+ export var LabelText = createComponent('label')({
25
+ displayName: 'Label',
26
+ Component: function (elemProps, ref, Element) {
27
+ return React.createElement(StyledLabel, __assign({ ref: ref, as: Element, typeLevel: "subtext.large" }, elemProps));
28
+ },
29
+ });
@@ -0,0 +1,14 @@
1
+ import { CanvasTypeHierarchy, CanvasTypeVariants } from '@workday/canvas-kit-react/tokens';
2
+ import { BoxProps } from '@workday/canvas-kit-react/layout';
3
+ export interface TextProps extends BoxProps {
4
+ /**
5
+ * Type token as string with level and size separated by dot.
6
+ */
7
+ typeLevel?: `${keyof CanvasTypeHierarchy}.${'large' | 'medium' | 'small'}`;
8
+ /**
9
+ * Type variant token names: `error`, `hint` or `inverse`.
10
+ */
11
+ variant?: keyof CanvasTypeVariants;
12
+ }
13
+ export declare const Text: import("../../common").ElementComponent<"span", TextProps>;
14
+ //# sourceMappingURL=Text.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Text.d.ts","sourceRoot":"","sources":["../../../../text/lib/Text.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAO,mBAAmB,EAAE,kBAAkB,EAAC,MAAM,kCAAkC,CAAC;AAC/F,OAAO,EAAM,QAAQ,EAAC,MAAM,kCAAkC,CAAC;AAE/D,MAAM,WAAW,SAAU,SAAQ,QAAQ;IACzC;;OAEG;IACF,SAAS,CAAC,EAAE,GAAG,MAAM,mBAAmB,IAAI,OAAO,GAAC,QAAQ,GAAC,OAAO,EAAE,CAAC;IACxE;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,kBAAkB,CAAC;CACpC;AA2CD,eAAO,MAAM,IAAI,4DAOf,CAAC"}