@fluentui/react-text 9.0.0-nightly.d730088d7f.0 → 9.0.0-rc.10

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 (288) hide show
  1. package/CHANGELOG.json +511 -18
  2. package/CHANGELOG.md +195 -53
  3. package/MIGRATION.md +153 -103
  4. package/README.md +4 -4
  5. package/dist/index.d.ts +188 -0
  6. package/{lib → dist}/tsdoc-metadata.json +0 -0
  7. package/lib/Body1.js +2 -0
  8. package/lib/Body1.js.map +1 -0
  9. package/lib/Caption1.js +2 -0
  10. package/lib/Caption1.js.map +1 -0
  11. package/lib/Caption2.js +2 -0
  12. package/lib/Caption2.js.map +1 -0
  13. package/lib/Display.js.map +1 -1
  14. package/lib/LargeTitle.js.map +1 -1
  15. package/lib/Subtitle1.js +2 -0
  16. package/lib/Subtitle1.js.map +1 -0
  17. package/lib/Subtitle2.js +2 -0
  18. package/lib/Subtitle2.js.map +1 -0
  19. package/lib/Text.js.map +1 -1
  20. package/lib/Title1.js.map +1 -1
  21. package/lib/Title2.js.map +1 -1
  22. package/lib/Title3.js.map +1 -1
  23. package/lib/components/Body1/Body1.js +31 -0
  24. package/lib/components/Body1/Body1.js.map +1 -0
  25. package/lib/components/Body1/index.js +2 -0
  26. package/lib/components/Body1/index.js.map +1 -0
  27. package/lib/components/Caption1/Caption1.js +31 -0
  28. package/lib/components/Caption1/Caption1.js.map +1 -0
  29. package/lib/components/Caption1/index.js +2 -0
  30. package/lib/components/Caption1/index.js.map +1 -0
  31. package/lib/components/Caption2/Caption2.js +31 -0
  32. package/lib/components/Caption2/Caption2.js.map +1 -0
  33. package/lib/components/Caption2/index.js +2 -0
  34. package/lib/components/Caption2/index.js.map +1 -0
  35. package/lib/components/Display/Display.js +12 -8
  36. package/lib/components/Display/Display.js.map +1 -1
  37. package/lib/components/Display/index.js.map +1 -1
  38. package/lib/components/LargeTitle/LargeTitle.js +12 -8
  39. package/lib/components/LargeTitle/LargeTitle.js.map +1 -1
  40. package/lib/components/LargeTitle/index.js.map +1 -1
  41. package/lib/components/Subtitle1/Subtitle1.js +31 -0
  42. package/lib/components/Subtitle1/Subtitle1.js.map +1 -0
  43. package/lib/components/Subtitle1/index.js +2 -0
  44. package/lib/components/Subtitle1/index.js.map +1 -0
  45. package/lib/components/Subtitle2/Subtitle2.js +31 -0
  46. package/lib/components/Subtitle2/Subtitle2.js.map +1 -0
  47. package/lib/components/Subtitle2/index.js +2 -0
  48. package/lib/components/Subtitle2/index.js.map +1 -0
  49. package/lib/components/Text/Text.js +7 -7
  50. package/lib/components/Text/Text.js.map +1 -1
  51. package/lib/components/Text/Text.types.js.map +1 -1
  52. package/lib/components/Text/index.js.map +1 -1
  53. package/lib/components/Text/renderText.js +7 -7
  54. package/lib/components/Text/renderText.js.map +1 -1
  55. package/lib/components/Text/useText.js +28 -27
  56. package/lib/components/Text/useText.js.map +1 -1
  57. package/lib/components/Text/useTextStyles.js +17 -11
  58. package/lib/components/Text/useTextStyles.js.map +1 -1
  59. package/lib/components/Title1/Title1.js +12 -8
  60. package/lib/components/Title1/Title1.js.map +1 -1
  61. package/lib/components/Title1/index.js.map +1 -1
  62. package/lib/components/Title2/Title2.js +12 -8
  63. package/lib/components/Title2/Title2.js.map +1 -1
  64. package/lib/components/Title2/index.js.map +1 -1
  65. package/lib/components/Title3/Title3.js +12 -8
  66. package/lib/components/Title3/Title3.js.map +1 -1
  67. package/lib/components/Title3/index.js.map +1 -1
  68. package/lib/components/wrapper.js +13 -10
  69. package/lib/components/wrapper.js.map +1 -1
  70. package/lib/index.js +11 -10
  71. package/lib/index.js.map +1 -1
  72. package/lib-commonjs/Body1.js +10 -0
  73. package/lib-commonjs/Body1.js.map +1 -0
  74. package/lib-commonjs/Caption1.js +10 -0
  75. package/lib-commonjs/Caption1.js.map +1 -0
  76. package/lib-commonjs/Caption2.js +10 -0
  77. package/lib-commonjs/Caption2.js.map +1 -0
  78. package/lib-commonjs/Display.js +1 -1
  79. package/lib-commonjs/Display.js.map +1 -1
  80. package/lib-commonjs/LargeTitle.js +1 -1
  81. package/lib-commonjs/LargeTitle.js.map +1 -1
  82. package/lib-commonjs/Subtitle1.js +10 -0
  83. package/lib-commonjs/Subtitle1.js.map +1 -0
  84. package/lib-commonjs/Subtitle2.js +10 -0
  85. package/lib-commonjs/Subtitle2.js.map +1 -0
  86. package/lib-commonjs/Text.js +1 -1
  87. package/lib-commonjs/Text.js.map +1 -1
  88. package/lib-commonjs/Title1.js +1 -1
  89. package/lib-commonjs/Title1.js.map +1 -1
  90. package/lib-commonjs/Title2.js +1 -1
  91. package/lib-commonjs/Title2.js.map +1 -1
  92. package/lib-commonjs/Title3.js +1 -1
  93. package/lib-commonjs/Title3.js.map +1 -1
  94. package/lib-commonjs/components/Body1/Body1.js +41 -0
  95. package/lib-commonjs/components/Body1/Body1.js.map +1 -0
  96. package/lib-commonjs/components/Body1/index.js +10 -0
  97. package/lib-commonjs/components/Body1/index.js.map +1 -0
  98. package/lib-commonjs/components/Caption1/Caption1.js +41 -0
  99. package/lib-commonjs/components/Caption1/Caption1.js.map +1 -0
  100. package/lib-commonjs/components/Caption1/index.js +10 -0
  101. package/lib-commonjs/components/Caption1/index.js.map +1 -0
  102. package/lib-commonjs/components/Caption2/Caption2.js +41 -0
  103. package/lib-commonjs/components/Caption2/Caption2.js.map +1 -0
  104. package/lib-commonjs/components/Caption2/index.js +10 -0
  105. package/lib-commonjs/components/Caption2/index.js.map +1 -0
  106. package/lib-commonjs/components/Display/Display.js +20 -9
  107. package/lib-commonjs/components/Display/Display.js.map +1 -1
  108. package/lib-commonjs/components/Display/index.js +1 -1
  109. package/lib-commonjs/components/Display/index.js.map +1 -1
  110. package/lib-commonjs/components/LargeTitle/LargeTitle.js +20 -9
  111. package/lib-commonjs/components/LargeTitle/LargeTitle.js.map +1 -1
  112. package/lib-commonjs/components/LargeTitle/index.js +1 -1
  113. package/lib-commonjs/components/LargeTitle/index.js.map +1 -1
  114. package/lib-commonjs/components/Subtitle1/Subtitle1.js +41 -0
  115. package/lib-commonjs/components/Subtitle1/Subtitle1.js.map +1 -0
  116. package/lib-commonjs/components/Subtitle1/index.js +10 -0
  117. package/lib-commonjs/components/Subtitle1/index.js.map +1 -0
  118. package/lib-commonjs/components/Subtitle2/Subtitle2.js +41 -0
  119. package/lib-commonjs/components/Subtitle2/Subtitle2.js.map +1 -0
  120. package/lib-commonjs/components/Subtitle2/index.js +10 -0
  121. package/lib-commonjs/components/Subtitle2/index.js.map +1 -0
  122. package/lib-commonjs/components/Text/Text.js +8 -8
  123. package/lib-commonjs/components/Text/Text.js.map +1 -1
  124. package/lib-commonjs/components/Text/Text.types.js.map +1 -1
  125. package/lib-commonjs/components/Text/index.js +1 -1
  126. package/lib-commonjs/components/Text/index.js.map +1 -1
  127. package/lib-commonjs/components/Text/renderText.js +11 -12
  128. package/lib-commonjs/components/Text/renderText.js.map +1 -1
  129. package/lib-commonjs/components/Text/useText.js +31 -31
  130. package/lib-commonjs/components/Text/useText.js.map +1 -1
  131. package/lib-commonjs/components/Text/useTextStyles.js +21 -14
  132. package/lib-commonjs/components/Text/useTextStyles.js.map +1 -1
  133. package/lib-commonjs/components/Title1/Title1.js +20 -9
  134. package/lib-commonjs/components/Title1/Title1.js.map +1 -1
  135. package/lib-commonjs/components/Title1/index.js +1 -1
  136. package/lib-commonjs/components/Title1/index.js.map +1 -1
  137. package/lib-commonjs/components/Title2/Title2.js +20 -9
  138. package/lib-commonjs/components/Title2/Title2.js.map +1 -1
  139. package/lib-commonjs/components/Title2/index.js +1 -1
  140. package/lib-commonjs/components/Title2/index.js.map +1 -1
  141. package/lib-commonjs/components/Title3/Title3.js +20 -9
  142. package/lib-commonjs/components/Title3/Title3.js.map +1 -1
  143. package/lib-commonjs/components/Title3/index.js +1 -1
  144. package/lib-commonjs/components/Title3/index.js.map +1 -1
  145. package/lib-commonjs/components/wrapper.js +14 -11
  146. package/lib-commonjs/components/wrapper.js.map +1 -1
  147. package/lib-commonjs/index.js +173 -11
  148. package/lib-commonjs/index.js.map +1 -1
  149. package/package.json +18 -22
  150. package/dist/react-text.d.ts +0 -163
  151. package/lib/Body.d.ts +0 -1
  152. package/lib/Body.js +0 -2
  153. package/lib/Body.js.map +0 -1
  154. package/lib/Caption.d.ts +0 -1
  155. package/lib/Caption.js +0 -2
  156. package/lib/Caption.js.map +0 -1
  157. package/lib/Display.d.ts +0 -1
  158. package/lib/Headline.d.ts +0 -1
  159. package/lib/Headline.js +0 -2
  160. package/lib/Headline.js.map +0 -1
  161. package/lib/LargeTitle.d.ts +0 -1
  162. package/lib/Subheadline.d.ts +0 -1
  163. package/lib/Subheadline.js +0 -2
  164. package/lib/Subheadline.js.map +0 -1
  165. package/lib/Text.d.ts +0 -1
  166. package/lib/Title1.d.ts +0 -1
  167. package/lib/Title2.d.ts +0 -1
  168. package/lib/Title3.d.ts +0 -1
  169. package/lib/common/isConformant.d.ts +0 -4
  170. package/lib/common/isConformant.js +0 -16
  171. package/lib/common/isConformant.js.map +0 -1
  172. package/lib/components/Body/Body.d.ts +0 -6
  173. package/lib/components/Body/Body.js +0 -27
  174. package/lib/components/Body/Body.js.map +0 -1
  175. package/lib/components/Body/index.d.ts +0 -1
  176. package/lib/components/Body/index.js +0 -2
  177. package/lib/components/Body/index.js.map +0 -1
  178. package/lib/components/Caption/Caption.d.ts +0 -6
  179. package/lib/components/Caption/Caption.js +0 -27
  180. package/lib/components/Caption/Caption.js.map +0 -1
  181. package/lib/components/Caption/index.d.ts +0 -1
  182. package/lib/components/Caption/index.js +0 -2
  183. package/lib/components/Caption/index.js.map +0 -1
  184. package/lib/components/Display/Display.d.ts +0 -6
  185. package/lib/components/Display/index.d.ts +0 -1
  186. package/lib/components/Headline/Headline.d.ts +0 -6
  187. package/lib/components/Headline/Headline.js +0 -27
  188. package/lib/components/Headline/Headline.js.map +0 -1
  189. package/lib/components/Headline/index.d.ts +0 -1
  190. package/lib/components/Headline/index.js +0 -2
  191. package/lib/components/Headline/index.js.map +0 -1
  192. package/lib/components/LargeTitle/LargeTitle.d.ts +0 -6
  193. package/lib/components/LargeTitle/index.d.ts +0 -1
  194. package/lib/components/Subheadline/Subheadline.d.ts +0 -6
  195. package/lib/components/Subheadline/Subheadline.js +0 -27
  196. package/lib/components/Subheadline/Subheadline.js.map +0 -1
  197. package/lib/components/Subheadline/index.d.ts +0 -1
  198. package/lib/components/Subheadline/index.js +0 -2
  199. package/lib/components/Subheadline/index.js.map +0 -1
  200. package/lib/components/Text/Text.d.ts +0 -6
  201. package/lib/components/Text/Text.types.d.ts +0 -77
  202. package/lib/components/Text/index.d.ts +0 -5
  203. package/lib/components/Text/renderText.d.ts +0 -5
  204. package/lib/components/Text/useText.d.ts +0 -12
  205. package/lib/components/Text/useTextStyles.d.ts +0 -5
  206. package/lib/components/Title1/Title1.d.ts +0 -6
  207. package/lib/components/Title1/index.d.ts +0 -1
  208. package/lib/components/Title2/Title2.d.ts +0 -6
  209. package/lib/components/Title2/index.d.ts +0 -1
  210. package/lib/components/Title3/Title3.d.ts +0 -6
  211. package/lib/components/Title3/index.d.ts +0 -1
  212. package/lib/components/wrapper.d.ts +0 -7
  213. package/lib/index.d.ts +0 -10
  214. package/lib/typographyStyles/index.d.ts +0 -2
  215. package/lib/typographyStyles/index.js +0 -3
  216. package/lib/typographyStyles/index.js.map +0 -1
  217. package/lib/typographyStyles/typographyStyles.d.ts +0 -14
  218. package/lib/typographyStyles/typographyStyles.js +0 -76
  219. package/lib/typographyStyles/typographyStyles.js.map +0 -1
  220. package/lib-commonjs/Body.d.ts +0 -1
  221. package/lib-commonjs/Body.js +0 -10
  222. package/lib-commonjs/Body.js.map +0 -1
  223. package/lib-commonjs/Caption.d.ts +0 -1
  224. package/lib-commonjs/Caption.js +0 -10
  225. package/lib-commonjs/Caption.js.map +0 -1
  226. package/lib-commonjs/Display.d.ts +0 -1
  227. package/lib-commonjs/Headline.d.ts +0 -1
  228. package/lib-commonjs/Headline.js +0 -10
  229. package/lib-commonjs/Headline.js.map +0 -1
  230. package/lib-commonjs/LargeTitle.d.ts +0 -1
  231. package/lib-commonjs/Subheadline.d.ts +0 -1
  232. package/lib-commonjs/Subheadline.js +0 -10
  233. package/lib-commonjs/Subheadline.js.map +0 -1
  234. package/lib-commonjs/Text.d.ts +0 -1
  235. package/lib-commonjs/Title1.d.ts +0 -1
  236. package/lib-commonjs/Title2.d.ts +0 -1
  237. package/lib-commonjs/Title3.d.ts +0 -1
  238. package/lib-commonjs/common/isConformant.d.ts +0 -4
  239. package/lib-commonjs/common/isConformant.js +0 -27
  240. package/lib-commonjs/common/isConformant.js.map +0 -1
  241. package/lib-commonjs/components/Body/Body.d.ts +0 -6
  242. package/lib-commonjs/components/Body/Body.js +0 -30
  243. package/lib-commonjs/components/Body/Body.js.map +0 -1
  244. package/lib-commonjs/components/Body/index.d.ts +0 -1
  245. package/lib-commonjs/components/Body/index.js +0 -10
  246. package/lib-commonjs/components/Body/index.js.map +0 -1
  247. package/lib-commonjs/components/Caption/Caption.d.ts +0 -6
  248. package/lib-commonjs/components/Caption/Caption.js +0 -30
  249. package/lib-commonjs/components/Caption/Caption.js.map +0 -1
  250. package/lib-commonjs/components/Caption/index.d.ts +0 -1
  251. package/lib-commonjs/components/Caption/index.js +0 -10
  252. package/lib-commonjs/components/Caption/index.js.map +0 -1
  253. package/lib-commonjs/components/Display/Display.d.ts +0 -6
  254. package/lib-commonjs/components/Display/index.d.ts +0 -1
  255. package/lib-commonjs/components/Headline/Headline.d.ts +0 -6
  256. package/lib-commonjs/components/Headline/Headline.js +0 -30
  257. package/lib-commonjs/components/Headline/Headline.js.map +0 -1
  258. package/lib-commonjs/components/Headline/index.d.ts +0 -1
  259. package/lib-commonjs/components/Headline/index.js +0 -10
  260. package/lib-commonjs/components/Headline/index.js.map +0 -1
  261. package/lib-commonjs/components/LargeTitle/LargeTitle.d.ts +0 -6
  262. package/lib-commonjs/components/LargeTitle/index.d.ts +0 -1
  263. package/lib-commonjs/components/Subheadline/Subheadline.d.ts +0 -6
  264. package/lib-commonjs/components/Subheadline/Subheadline.js +0 -30
  265. package/lib-commonjs/components/Subheadline/Subheadline.js.map +0 -1
  266. package/lib-commonjs/components/Subheadline/index.d.ts +0 -1
  267. package/lib-commonjs/components/Subheadline/index.js +0 -10
  268. package/lib-commonjs/components/Subheadline/index.js.map +0 -1
  269. package/lib-commonjs/components/Text/Text.d.ts +0 -6
  270. package/lib-commonjs/components/Text/Text.types.d.ts +0 -77
  271. package/lib-commonjs/components/Text/index.d.ts +0 -5
  272. package/lib-commonjs/components/Text/renderText.d.ts +0 -5
  273. package/lib-commonjs/components/Text/useText.d.ts +0 -12
  274. package/lib-commonjs/components/Text/useTextStyles.d.ts +0 -5
  275. package/lib-commonjs/components/Title1/Title1.d.ts +0 -6
  276. package/lib-commonjs/components/Title1/index.d.ts +0 -1
  277. package/lib-commonjs/components/Title2/Title2.d.ts +0 -6
  278. package/lib-commonjs/components/Title2/index.d.ts +0 -1
  279. package/lib-commonjs/components/Title3/Title3.d.ts +0 -6
  280. package/lib-commonjs/components/Title3/index.d.ts +0 -1
  281. package/lib-commonjs/components/wrapper.d.ts +0 -7
  282. package/lib-commonjs/index.d.ts +0 -10
  283. package/lib-commonjs/typographyStyles/index.d.ts +0 -2
  284. package/lib-commonjs/typographyStyles/index.js +0 -11
  285. package/lib-commonjs/typographyStyles/index.js.map +0 -1
  286. package/lib-commonjs/typographyStyles/typographyStyles.d.ts +0 -14
  287. package/lib-commonjs/typographyStyles/typographyStyles.js +0 -109
  288. package/lib-commonjs/typographyStyles/typographyStyles.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"Text.types.js","sourceRoot":"","sources":["../../../src/components/Text/Text.types.ts"],"names":[],"mappings":""}
1
+ {"version":3,"file":"Text.types.js","sourceRoot":"../src/","sources":["components/Text/Text.types.ts"],"names":[],"mappings":"","sourcesContent":["import type { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';\n\n/**\n * Text slots\n */\nexport type TextSlots = {\n root: Slot<'span', 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'p' | 'pre'>;\n};\n\n/**\n * Text Props\n */\nexport type TextProps = ComponentProps<TextSlots> & {\n /**\n * Aligns text based on the parent container.\n *\n * @default start\n */\n align?: 'start' | 'center' | 'end' | 'justify';\n\n /**\n * Applies a block display for the content.\n *\n * @default false\n */\n block?: boolean;\n\n /**\n * Applies the font family to the content.\n *\n * @default base\n */\n font?: 'base' | 'monospace' | 'numeric';\n\n /**\n * Applies the italic font style to the content.\n *\n * @default false\n */\n italic?: boolean;\n\n /**\n * Applies font size and line height based on the theme tokens.\n *\n * @default 300\n */\n size?: 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900 | 1000;\n\n /**\n * Applies the strikethrough text decoration to the content.\n *\n * @default false\n */\n strikethrough?: boolean;\n\n /**\n * Truncate overflowing text for block displays.\n *\n * @default false\n */\n\n truncate?: boolean;\n\n /**\n * Applies the underline text decoration to the content.\n *\n * @default false\n */\n underline?: boolean;\n\n /**\n * Applies font weight to the content.\n *\n * @default regular\n */\n weight?: 'regular' | 'medium' | 'semibold';\n\n /**\n * Wraps the text content on white spaces.\n *\n * @default true\n */\n wrap?: boolean;\n};\n\n/**\n * State used in rendering Text\n */\nexport type TextState = ComponentState<TextSlots> &\n Required<\n Pick<\n TextProps,\n 'align' | 'block' | 'font' | 'italic' | 'size' | 'strikethrough' | 'truncate' | 'underline' | 'weight' | 'wrap'\n >\n >;\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/Text/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC;AACvB,cAAc,cAAc,CAAC;AAC7B,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,iBAAiB,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"../src/","sources":["components/Text/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC;AACvB,cAAc,cAAc,CAAC;AAC7B,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,iBAAiB,CAAC","sourcesContent":["export * from './Text';\nexport * from './Text.types';\nexport * from './renderText';\nexport * from './useText';\nexport * from './useTextStyles';\n"]}
@@ -1,15 +1,15 @@
1
- import { __assign } from "tslib";
2
1
  import * as React from 'react';
3
2
  import { getSlots } from '@fluentui/react-utilities';
4
3
  /**
5
4
  * Render the final JSX of Text
6
5
  */
7
6
 
8
- export var renderText = function (state) {
9
- var _a = getSlots(state),
10
- slots = _a.slots,
11
- slotProps = _a.slotProps;
12
-
13
- return /*#__PURE__*/React.createElement(slots.root, __assign({}, slotProps.root));
7
+ export const renderText_unstable = state => {
8
+ const {
9
+ slots,
10
+ slotProps
11
+ } = getSlots(state);
12
+ return /*#__PURE__*/React.createElement(slots.root, { ...slotProps.root
13
+ });
14
14
  };
15
15
  //# sourceMappingURL=renderText.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/components/Text/renderText.tsx"],"names":[],"mappings":";AAAA,OAAO,KAAK,KAAZ,MAAuB,OAAvB;AACA,SAAS,QAAT,QAAyB,2BAAzB;AAGA;;AAEG;;AACH,OAAO,IAAM,UAAU,GAAG,UAAC,KAAD,EAAiB;AACnC,MAAA,EAAA,GAAuB,QAAQ,CAAY,KAAZ,CAA/B;AAAA,MAAE,KAAK,GAAA,EAAA,CAAA,KAAP;AAAA,MAAS,SAAS,GAAA,EAAA,CAAA,SAAlB;;AAEN,sBAAO,KAAA,CAAA,aAAA,CAAC,KAAK,CAAC,IAAP,EAAW,QAAA,CAAA,EAAA,EAAK,SAAS,CAAC,IAAf,CAAX,CAAP;AACD,CAJM","sourceRoot":""}
1
+ {"version":3,"sources":["components/Text/renderText.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAZ,MAAuB,OAAvB;AACA,SAAS,QAAT,QAAyB,2BAAzB;AAGA;;AAEG;;AACH,OAAO,MAAM,mBAAmB,GAAI,KAAD,IAAqB;AACtD,QAAM;AAAE,IAAA,KAAF;AAAS,IAAA;AAAT,MAAuB,QAAQ,CAAY,KAAZ,CAArC;AAEA,sBAAO,KAAA,CAAA,aAAA,CAAC,KAAK,CAAC,IAAP,EAAW,EAAA,GAAK,SAAS,CAAC;AAAf,GAAX,CAAP;AACD,CAJM","sourcesContent":["import * as React from 'react';\nimport { getSlots } from '@fluentui/react-utilities';\nimport type { TextSlots, TextState } from './Text.types';\n\n/**\n * Render the final JSX of Text\n */\nexport const renderText_unstable = (state: TextState) => {\n const { slots, slotProps } = getSlots<TextSlots>(state);\n\n return <slots.root {...slotProps.root} />;\n};\n"],"sourceRoot":"../src/"}
@@ -1,48 +1,49 @@
1
- import { __assign } from "tslib";
2
1
  import { getNativeElementProps } from '@fluentui/react-utilities';
3
2
  /**
4
3
  * Create the state required to render Text.
5
4
  *
6
- * The returned state can be modified with hooks such as useTextStyles,
7
- * before being passed to renderText.
5
+ * The returned state can be modified with hooks such as useTextStyles_unstable,
6
+ * before being passed to renderText_unstable.
8
7
  *
9
8
  * @param props - props from this instance of Text
10
9
  * @param ref - reference to root HTMLElement of Text
11
10
  */
12
11
 
13
- export var useText = function (props, ref) {
12
+ export const useText_unstable = (props, ref) => {
14
13
  var _a;
15
14
 
16
- var wrap = props.wrap,
17
- truncate = props.truncate,
18
- block = props.block,
19
- italic = props.italic,
20
- underline = props.underline,
21
- strikethrough = props.strikethrough,
22
- size = props.size,
23
- font = props.font,
24
- weight = props.weight,
25
- align = props.align;
26
- var as = (_a = props.as) !== null && _a !== void 0 ? _a : 'span';
27
- var state = {
28
- wrap: wrap !== null && wrap !== void 0 ? wrap : true,
29
- truncate: truncate !== null && truncate !== void 0 ? truncate : false,
15
+ const {
16
+ wrap,
17
+ truncate,
18
+ block,
19
+ italic,
20
+ underline,
21
+ strikethrough,
22
+ size,
23
+ font,
24
+ weight,
25
+ align
26
+ } = props;
27
+ const as = (_a = props.as) !== null && _a !== void 0 ? _a : 'span';
28
+ const state = {
29
+ align: align !== null && align !== void 0 ? align : 'start',
30
30
  block: block !== null && block !== void 0 ? block : false,
31
+ font: font !== null && font !== void 0 ? font : 'base',
31
32
  italic: italic !== null && italic !== void 0 ? italic : false,
32
- underline: underline !== null && underline !== void 0 ? underline : false,
33
- strikethrough: strikethrough !== null && strikethrough !== void 0 ? strikethrough : false,
34
33
  size: size !== null && size !== void 0 ? size : 300,
35
- font: font !== null && font !== void 0 ? font : 'base',
34
+ strikethrough: strikethrough !== null && strikethrough !== void 0 ? strikethrough : false,
35
+ truncate: truncate !== null && truncate !== void 0 ? truncate : false,
36
+ underline: underline !== null && underline !== void 0 ? underline : false,
36
37
  weight: weight !== null && weight !== void 0 ? weight : 'regular',
37
- align: align !== null && align !== void 0 ? align : 'start',
38
+ wrap: wrap !== null && wrap !== void 0 ? wrap : true,
38
39
  components: {
39
40
  root: 'span'
40
41
  },
41
- root: getNativeElementProps(as, __assign(__assign({
42
- ref: ref
43
- }, props), {
44
- as: as
45
- }))
42
+ root: getNativeElementProps(as, {
43
+ ref,
44
+ ...props,
45
+ as
46
+ })
46
47
  };
47
48
  return state;
48
49
  };
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/components/Text/useText.ts"],"names":[],"mappings":";AACA,SAAS,qBAAT,QAAsC,2BAAtC;AAGA;;;;;;;;AAQG;;AACH,OAAO,IAAM,OAAO,GAAG,UAAC,KAAD,EAAmB,GAAnB,EAA8C;;;AAC3D,MAAA,IAAI,GAAmF,KAAK,CAAxF,IAAJ;AAAA,MAAM,QAAQ,GAAyE,KAAK,CAA9E,QAAd;AAAA,MAAgB,KAAK,GAAkE,KAAK,CAAvE,KAArB;AAAA,MAAuB,MAAM,GAA0D,KAAK,CAA/D,MAA7B;AAAA,MAA+B,SAAS,GAA+C,KAAK,CAApD,SAAxC;AAAA,MAA0C,aAAa,GAAgC,KAAK,CAArC,aAAvD;AAAA,MAAyD,IAAI,GAA0B,KAAK,CAA/B,IAA7D;AAAA,MAA+D,IAAI,GAAoB,K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A,MAAA,GAAU,KAJK;AAKvB,IAAA,IAAI,EAAE,IAAI,KAAA,IAAJ,IAAA,IAAI,KAAA,KAAA,CAAJ,GAAA,IAAA,GAAQ,GALS;AAMvB,IAAA,aAAa,EAAE,aAAa,KAAA,IAAb,IAAA,aAAa,KAAA,KAAA,CAAb,GAAA,aAAA,GAAiB,KANT;AAOvB,IAAA,QAAQ,EAAE,QAAQ,KAAA,IAAR,IAAA,QAAQ,KAAA,KAAA,CAAR,GAAA,QAAA,GAAY,KAPC;AAQvB,IAAA,SAAS,EAAE,SAAS,KAAA,IAAT,IAAA,SAAS,KAAA,KAAA,CAAT,GAAA,SAAA,GAAa,KARD;AASvB,IAAA,MAAM,EAAE,MAAM,KAAA,IAAN,IAAA,MAAM,KAAA,KAAA,CAAN,GAAA,MAAA,GAAU,SATK;AAUvB,IAAA,IAAI,EAAE,IAAI,KAAA,IAAJ,IAAA,IAAI,KAAA,KAAA,CAAJ,GAAA,IAAA,GAAQ,IAVS;AAYvB,IAAA,UAAU,EAAE;AAAE,MAAA,IAAI,EAAE;AAAR,KAZW;AAcvB,IAAA,IAAI,EAAE,qBAAqB,CAAC,EAAD,EAAK;AAC9B,MAAA,GAD8B;AAE9B,SAAG,KAF2B;AAG9B,MAAA;AAH8B,KAAL;AAdJ,GAAzB;AAqBA,SAAO,KAAP;AACD,CA1BM","sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps } from '@fluentui/react-utilities';\nimport type { TextProps, TextState } from './Text.types';\n\n/**\n * Create the state required to render Text.\n *\n * The returned state can be modified with hooks such as useTextStyles_unstable,\n * before being passed to renderText_unstable.\n *\n * @param props - props from this instance of Text\n * @param ref - reference to root HTMLElement of Text\n */\nexport const useText_unstable = (props: TextProps, ref: React.Ref<HTMLElement>): TextState => {\n const { wrap, truncate, block, italic, underline, strikethrough, size, font, weight, align } = props;\n const as = props.as ?? 'span';\n\n const state: TextState = {\n align: align ?? 'start',\n block: block ?? false,\n font: font ?? 'base',\n italic: italic ?? false,\n size: size ?? 300,\n strikethrough: strikethrough ?? false,\n truncate: truncate ?? false,\n underline: underline ?? false,\n weight: weight ?? 'regular',\n wrap: wrap ?? true,\n\n components: { root: 'span' },\n\n root: getNativeElementProps(as, {\n ref,\n ...props,\n as,\n }),\n };\n\n return state;\n};\n"],"sourceRoot":"../src/"}
@@ -1,9 +1,13 @@
1
- import { __styles, mergeClasses } from '@fluentui/react-make-styles';
1
+ import { __styles, mergeClasses, shorthands } from '@griffel/react';
2
+ import { tokens } from '@fluentui/react-theme';
3
+ export const textClassNames = {
4
+ root: 'fui-Text'
5
+ };
2
6
  /**
3
7
  * Styles for the root slot
4
8
  */
5
9
 
6
- var useStyles = /*#__PURE__*/__styles({
10
+ const useStyles = /*#__PURE__*/__styles({
7
11
  "root": {
8
12
  "Bahqtrf": "fk6fouc",
9
13
  "Be2twd7": "fkhj508",
@@ -12,12 +16,14 @@ var useStyles = /*#__PURE__*/__styles({
12
16
  "fsow6f": "fpgzoln",
13
17
  "mc9l5x": "f1w7gpdv",
14
18
  "Huce71": "f6juhto",
15
- "Bpg54ce": "f1gl81tg",
19
+ "B68tc82": "f1mtd64y",
20
+ "Bmxbyg5": "f1y7q3j9",
16
21
  "ygn44y": "f2jf649"
17
22
  },
18
23
  "nowrap": {
19
24
  "Huce71": "fz5stix",
20
- "Bpg54ce": "f1a3p1vp"
25
+ "B68tc82": "f1p9o1ba",
26
+ "Bmxbyg5": "f1sil6mw"
21
27
  },
22
28
  "truncate": {
23
29
  "ygn44y": "f1cmbuwj"
@@ -29,13 +35,13 @@ var useStyles = /*#__PURE__*/__styles({
29
35
  "B80ckks": "f1j4dglz"
30
36
  },
31
37
  "underline": {
32
- "dwov6y": "fctto54"
38
+ "w71qe1": "f13mvf36"
33
39
  },
34
40
  "strikethrough": {
35
- "dwov6y": "f1y2xhd0"
41
+ "w71qe1": "fv5q2k7"
36
42
  },
37
43
  "strikethroughUnderline": {
38
- "dwov6y": "f13legbo"
44
+ "w71qe1": "f1drk4o6"
39
45
  },
40
46
  "base100": {
41
47
  "Be2twd7": "f13mqy1h",
@@ -95,16 +101,16 @@ var useStyles = /*#__PURE__*/__styles({
95
101
  "fsow6f": "f1j59e10"
96
102
  }
97
103
  }, {
98
- "d": [".fk6fouc{font-family:var(--fontFamilyBase);}", ".fkhj508{font-size:var(--fontSizeBase300);}", ".f1i3iumi{line-height:var(--lineHeightBase300);}", ".figsok6{font-weight:var(--fontWeightRegular);}", ".fpgzoln{text-align:start;}", ".f1w7gpdv{display:inline;}", ".f6juhto{white-space:normal;}", ".f1gl81tg{overflow:visible;}", ".f2jf649{text-overflow:clip;}", ".fz5stix{white-space:nowrap;}", ".f1a3p1vp{overflow:hidden;}", ".f1cmbuwj{text-overflow:ellipsis;}", ".ftgm304{display:block;}", ".f1j4dglz{font-style:italic;}", ".fctto54{-webkit-text-decoration:underline;text-decoration:underline;}", ".f1y2xhd0{-webkit-text-decoration:line-through;text-decoration:line-through;}", ".f13legbo{-webkit-text-decoration:line-through underline;text-decoration:line-through underline;}", ".f13mqy1h{font-size:var(--fontSizeBase100);}", ".fcpl73t{line-height:var(--lineHeightBase100);}", ".fy9rknc{font-size:var(--fontSizeBase200);}", ".fwrc4pm{line-height:var(--lineHeightBase200);}", ".fod5ikn{font-size:var(--fontSizeBase400);}", ".faaz57k{line-height:var(--lineHeightBase400);}", ".f1pp30po{font-size:var(--fontSizeBase500);}", ".f106mvju{line-height:var(--lineHeightBase500);}", ".f1x0m3f5{font-size:var(--fontSizeBase600);}", ".fb86gi6{line-height:var(--lineHeightBase600);}", ".fojgt09{font-size:var(--fontSizeHero700);}", ".fcen8rp{line-height:var(--lineHeightHero700);}", ".fccw675{font-size:var(--fontSizeHero800);}", ".f1ebx5kk{line-height:var(--lineHeightHero800);}", ".f15afnhw{font-size:var(--fontSizeHero900);}", ".fr3w3wp{line-height:var(--lineHeightHero900);}", ".fpyltcb{font-size:var(--fontSizeHero1000);}", ".f1ivgwrt{line-height:var(--lineHeightHero1000);}", ".f1fedwem{font-family:var(--fontFamilyMonospace);}", ".f1uq0ln5{font-family:var(--fontFamilyNumeric);}", ".fdj6btp{font-weight:var(--fontWeightMedium);}", ".fl43uef{font-weight:var(--fontWeightSemibold);}", ".f17mccla{text-align:center;}", ".f12ymhq5{text-align:end;}", ".f1j59e10{text-align:justify;}"]
104
+ "d": [".fk6fouc{font-family:var(--fontFamilyBase);}", ".fkhj508{font-size:var(--fontSizeBase300);}", ".f1i3iumi{line-height:var(--lineHeightBase300);}", ".figsok6{font-weight:var(--fontWeightRegular);}", ".fpgzoln{text-align:start;}", ".f1w7gpdv{display:inline;}", ".f6juhto{white-space:normal;}", ".f1mtd64y{overflow-x:visible;}", ".f1y7q3j9{overflow-y:visible;}", ".f2jf649{text-overflow:clip;}", ".fz5stix{white-space:nowrap;}", ".f1p9o1ba{overflow-x:hidden;}", ".f1sil6mw{overflow-y:hidden;}", ".f1cmbuwj{text-overflow:ellipsis;}", ".ftgm304{display:block;}", ".f1j4dglz{font-style:italic;}", ".f13mvf36{text-decoration-line:underline;}", ".fv5q2k7{text-decoration-line:line-through;}", ".f1drk4o6{text-decoration-line:line-through underline;}", ".f13mqy1h{font-size:var(--fontSizeBase100);}", ".fcpl73t{line-height:var(--lineHeightBase100);}", ".fy9rknc{font-size:var(--fontSizeBase200);}", ".fwrc4pm{line-height:var(--lineHeightBase200);}", ".fod5ikn{font-size:var(--fontSizeBase400);}", ".faaz57k{line-height:var(--lineHeightBase400);}", ".f1pp30po{font-size:var(--fontSizeBase500);}", ".f106mvju{line-height:var(--lineHeightBase500);}", ".f1x0m3f5{font-size:var(--fontSizeBase600);}", ".fb86gi6{line-height:var(--lineHeightBase600);}", ".fojgt09{font-size:var(--fontSizeHero700);}", ".fcen8rp{line-height:var(--lineHeightHero700);}", ".fccw675{font-size:var(--fontSizeHero800);}", ".f1ebx5kk{line-height:var(--lineHeightHero800);}", ".f15afnhw{font-size:var(--fontSizeHero900);}", ".fr3w3wp{line-height:var(--lineHeightHero900);}", ".fpyltcb{font-size:var(--fontSizeHero1000);}", ".f1ivgwrt{line-height:var(--lineHeightHero1000);}", ".f1fedwem{font-family:var(--fontFamilyMonospace);}", ".f1uq0ln5{font-family:var(--fontFamilyNumeric);}", ".fdj6btp{font-weight:var(--fontWeightMedium);}", ".fl43uef{font-weight:var(--fontWeightSemibold);}", ".f17mccla{text-align:center;}", ".f12ymhq5{text-align:end;}", ".f1j59e10{text-align:justify;}"]
99
105
  });
100
106
  /**
101
107
  * Apply styling to the Text slots based on the state
102
108
  */
103
109
 
104
110
 
105
- export var useTextStyles = function (state) {
106
- var styles = useStyles();
107
- state.root.className = mergeClasses(styles.root, state.wrap === false && styles.nowrap, state.truncate && styles.truncate, state.block && styles.block, state.italic && styles.italic, state.underline && styles.underline, state.strikethrough && styles.strikethrough, state.underline && state.strikethrough && styles.strikethroughUnderline, state.size === 100 && styles.base100, state.size === 200 && styles.base200, state.size === 400 && styles.base400, state.size === 500 && styles.base500, state.size === 600 && styles.base600, state.size === 700 && styles.hero700, state.size === 800 && styles.hero800, state.size === 900 && styles.hero900, state.size === 1000 && styles.hero1000, state.font === 'monospace' && styles.monospace, state.font === 'numeric' && styles.numeric, state.weight === 'medium' && styles.weightMedium, state.weight === 'semibold' && styles.weightSemibold, state.align === 'center' && styles.alignCenter, state.align === 'end' && styles.alignEnd, state.align === 'justify' && styles.alignJustify, state.root.className);
111
+ export const useTextStyles_unstable = state => {
112
+ const styles = useStyles();
113
+ state.root.className = mergeClasses(textClassNames.root, styles.root, state.wrap === false && styles.nowrap, state.truncate && styles.truncate, state.block && styles.block, state.italic && styles.italic, state.underline && styles.underline, state.strikethrough && styles.strikethrough, state.underline && state.strikethrough && styles.strikethroughUnderline, state.size === 100 && styles.base100, state.size === 200 && styles.base200, state.size === 400 && styles.base400, state.size === 500 && styles.base500, state.size === 600 && styles.base600, state.size === 700 && styles.hero700, state.size === 800 && styles.hero800, state.size === 900 && styles.hero900, state.size === 1000 && styles.hero1000, state.font === 'monospace' && styles.monospace, state.font === 'numeric' && styles.numeric, state.weight === 'medium' && styles.weightMedium, state.weight === 'semibold' && styles.weightSemibold, state.align === 'center' && styles.alignCenter, state.align === 'end' && styles.alignEnd, state.align === 'justify' && styles.alignJustify, state.root.className);
108
114
  return state;
109
115
  };
110
116
  //# sourceMappingURL=useTextStyles.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/components/Text/useTextStyles.ts"],"names":[],"mappings":"AAAA,mBAAqB,YAArB,QAAyC,6BAAzC;AAGA;;AAEG;;AACH,IAAM,SAAS,gBAAG;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAAlB;AA6FA;;AAEG;;;AACH,OAAO,IAAM,aAAa,GAAG,UAAC,KAAD,EAAiB;AAC5C,MAAM,MAAM,GAAG,SAAS,EAAxB;AAEA,EAAA,KAAK,CAAC,IAAN,CAAW,SAAX,GAAuB,YAAY,CACjC,MAAM,CAAC,IAD0B,EAEjC,KAAK,CAAC,IAAN,KAAe,KAAf,IAAwB,MAAM,CAAC,MAFE,EAGjC,KAAK,CAAC,QAAN,IAAkB,MAAM,CAAC,QAHQ,EAIjC,KAAK,CAAC,KAA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K,CAAC,KAAN,KAAgB,KAAhB,IAAyB,MAAM,CAAC,QAxBC,EAyBjC,KAAK,CAAC,KAAN,KAAgB,SAAhB,IAA6B,MAAM,CAAC,YAzBH,EA0BjC,KAAK,CAAC,IAAN,CAAW,SA1BsB,CAAnC;AA6BA,SAAO,KAAP;AACD,CAjCM","sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport { tokens } from '@fluentui/react-theme';\nimport type { TextSlots, TextState } from './Text.types';\nimport { SlotClassNames } from '@fluentui/react-utilities';\n\nexport const textClassNames: SlotClassNames<TextSlots> = {\n root: 'fui-Text',\n};\n\n/**\n * Styles for the root slot\n */\nconst useStyles = makeStyles({\n root: {\n fontFamily: tokens.fontFamilyBase,\n fontSize: tokens.fontSizeBase300,\n lineHeight: tokens.lineHeightBase300,\n fontWeight: tokens.fontWeightRegular,\n textAlign: 'start',\n display: 'inline',\n whiteSpace: 'normal',\n ...shorthands.overflow('visible'),\n textOverflow: 'clip',\n },\n nowrap: {\n whiteSpace: 'nowrap',\n ...shorthands.overflow('hidden'),\n },\n truncate: {\n textOverflow: 'ellipsis',\n },\n block: {\n display: 'block',\n },\n italic: {\n fontStyle: 'italic',\n },\n underline: {\n textDecorationLine: 'underline',\n },\n strikethrough: {\n textDecorationLine: 'line-through',\n },\n strikethroughUnderline: {\n textDecorationLine: 'line-through underline',\n },\n base100: {\n fontSize: tokens.fontSizeBase100,\n lineHeight: tokens.lineHeightBase100,\n },\n base200: {\n fontSize: tokens.fontSizeBase200,\n lineHeight: tokens.lineHeightBase200,\n },\n base400: {\n fontSize: tokens.fontSizeBase400,\n lineHeight: tokens.lineHeightBase400,\n },\n base500: {\n fontSize: tokens.fontSizeBase500,\n lineHeight: tokens.lineHeightBase500,\n },\n base600: {\n fontSize: tokens.fontSizeBase600,\n lineHeight: tokens.lineHeightBase600,\n },\n hero700: {\n fontSize: tokens.fontSizeHero700,\n lineHeight: tokens.lineHeightHero700,\n },\n hero800: {\n fontSize: tokens.fontSizeHero800,\n lineHeight: tokens.lineHeightHero800,\n },\n hero900: {\n fontSize: tokens.fontSizeHero900,\n lineHeight: tokens.lineHeightHero900,\n },\n hero1000: {\n fontSize: tokens.fontSizeHero1000,\n lineHeight: tokens.lineHeightHero1000,\n },\n monospace: {\n fontFamily: tokens.fontFamilyMonospace,\n },\n numeric: {\n fontFamily: tokens.fontFamilyNumeric,\n },\n weightMedium: {\n fontWeight: tokens.fontWeightMedium,\n },\n weightSemibold: {\n fontWeight: tokens.fontWeightSemibold,\n },\n alignCenter: {\n textAlign: 'center',\n },\n alignEnd: {\n textAlign: 'end',\n },\n alignJustify: {\n textAlign: 'justify',\n },\n});\n\n/**\n * Apply styling to the Text slots based on the state\n */\nexport const useTextStyles_unstable = (state: TextState): TextState => {\n const styles = useStyles();\n\n state.root.className = mergeClasses(\n textClassNames.root,\n styles.root,\n state.wrap === false && styles.nowrap,\n state.truncate && styles.truncate,\n state.block && styles.block,\n state.italic && styles.italic,\n state.underline && styles.underline,\n state.strikethrough && styles.strikethrough,\n state.underline && state.strikethrough && styles.strikethroughUnderline,\n state.size === 100 && styles.base100,\n state.size === 200 && styles.base200,\n state.size === 400 && styles.base400,\n state.size === 500 && styles.base500,\n state.size === 600 && styles.base600,\n state.size === 700 && styles.hero700,\n state.size === 800 && styles.hero800,\n state.size === 900 && styles.hero900,\n state.size === 1000 && styles.hero1000,\n state.font === 'monospace' && styles.monospace,\n state.font === 'numeric' && styles.numeric,\n state.weight === 'medium' && styles.weightMedium,\n state.weight === 'semibold' && styles.weightSemibold,\n state.align === 'center' && styles.alignCenter,\n state.align === 'end' && styles.alignEnd,\n state.align === 'justify' && styles.alignJustify,\n state.root.className,\n );\n\n return state;\n};\n"],"sourceRoot":"../src/"}
@@ -1,27 +1,31 @@
1
- import { __styles } from '@fluentui/react-make-styles';
2
- import { typographyStyles } from '../../typographyStyles/index';
1
+ import { __styles } from '@griffel/react';
3
2
  import { createWrapper } from '../wrapper';
3
+ import { typographyStyles } from '@fluentui/react-theme';
4
+ export const title1ClassNames = {
5
+ root: 'fui-Title1'
6
+ };
4
7
  /**
5
8
  * Styles for the root slot
6
9
  */
7
10
 
8
- var useStyles = /*#__PURE__*/__styles({
11
+ const useStyles = /*#__PURE__*/__styles({
9
12
  "root": {
10
13
  "Bahqtrf": "fk6fouc",
11
14
  "Be2twd7": "fccw675",
12
- "Bg96gwp": "f1ebx5kk",
13
- "Bhrd7zp": "fl43uef"
15
+ "Bhrd7zp": "fl43uef",
16
+ "Bg96gwp": "f1ebx5kk"
14
17
  }
15
18
  }, {
16
- "d": [".fk6fouc{font-family:var(--fontFamilyBase);}", ".fccw675{font-size:var(--fontSizeHero800);}", ".f1ebx5kk{line-height:var(--lineHeightHero800);}", ".fl43uef{font-weight:var(--fontWeightSemibold);}"]
19
+ "d": [".fk6fouc{font-family:var(--fontFamilyBase);}", ".fccw675{font-size:var(--fontSizeHero800);}", ".fl43uef{font-weight:var(--fontWeightSemibold);}", ".f1ebx5kk{line-height:var(--lineHeightHero800);}"]
17
20
  });
18
21
  /**
19
22
  * Text wrapper component for the Title 1 typography variant
20
23
  */
21
24
 
22
25
 
23
- export var Title1 = /*#__PURE__*/createWrapper({
24
- useStyles: useStyles,
26
+ export const Title1 = /*#__PURE__*/createWrapper({
27
+ useStyles,
28
+ className: title1ClassNames.root,
25
29
  displayName: 'Title1'
26
30
  });
27
31
  //# sourceMappingURL=Title1.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/components/Title1/Title1.tsx"],"names":[],"mappings":"AACA,yBAA2B,6BAA3B;AACA,SAAS,gBAAT,QAAiC,8BAAjC;AACA,SAAS,aAAT,QAAgD,YAAhD;AAEA;;AAEG;;AACH,IAAM,SAAS,gBAAG;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAAlB;AAIA;;AAEG;;;AACH,OAAO,IAAM,MAAM,gBAAwC,aAAa,CAAC;AAAE,EAAA,SAAS,EAAA,SAAX;AAAa,EAAA,WAAW,EAAE;AAA1B,CAAD,CAAjE","sourceRoot":""}
1
+ {"version":3,"sources":["components/Title1/Title1.tsx"],"names":[],"mappings":"AACA,yBAA2B,gBAA3B;AACA,SAAS,aAAT,QAAgD,YAAhD;AAGA,SAAS,gBAAT,QAAiC,uBAAjC;AAEA,OAAO,MAAM,gBAAgB,GAA8B;AACzD,EAAA,IAAI,EAAE;AADmD,CAApD;AAIP;;AAEG;;AACH,MAAM,SAAS,gBAAG;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAAlB;AAIA;;AAEG;;;AACH,OAAO,MAAM,MAAM,gBAAwC,aAAa,CAAC;AACvE,EAAA,SADuE;AAEvE,EAAA,SAAS,EAAE,gBAAgB,CAAC,IAF2C;AAGvE,EAAA,WAAW,EAAE;AAH0D,CAAD,CAAjE","sourcesContent":["import type { FunctionComponent } from 'react';\nimport { makeStyles } from '@griffel/react';\nimport { createWrapper, TextWrapperProps } from '../wrapper';\nimport { SlotClassNames } from '@fluentui/react-utilities';\nimport { TextSlots } from '../Text/Text.types';\nimport { typographyStyles } from '@fluentui/react-theme';\n\nexport const title1ClassNames: SlotClassNames<TextSlots> = {\n root: 'fui-Title1',\n};\n\n/**\n * Styles for the root slot\n */\nconst useStyles = makeStyles({\n root: typographyStyles.title1,\n});\n\n/**\n * Text wrapper component for the Title 1 typography variant\n */\nexport const Title1: FunctionComponent<TextWrapperProps> = createWrapper({\n useStyles,\n className: title1ClassNames.root,\n displayName: 'Title1',\n});\n"],"sourceRoot":"../src/"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/Title1/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"../src/","sources":["components/Title1/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC","sourcesContent":["export * from './Title1';\n"]}
@@ -1,27 +1,31 @@
1
- import { __styles } from '@fluentui/react-make-styles';
2
- import { typographyStyles } from '../../typographyStyles/index';
1
+ import { __styles } from '@griffel/react';
3
2
  import { createWrapper } from '../wrapper';
3
+ import { typographyStyles } from '@fluentui/react-theme';
4
+ export const title2ClassNames = {
5
+ root: 'fui-Title2'
6
+ };
4
7
  /**
5
8
  * Styles for the root slot
6
9
  */
7
10
 
8
- var useStyles = /*#__PURE__*/__styles({
11
+ const useStyles = /*#__PURE__*/__styles({
9
12
  "root": {
10
13
  "Bahqtrf": "fk6fouc",
11
14
  "Be2twd7": "fojgt09",
12
- "Bg96gwp": "fcen8rp",
13
- "Bhrd7zp": "fl43uef"
15
+ "Bhrd7zp": "fl43uef",
16
+ "Bg96gwp": "fcen8rp"
14
17
  }
15
18
  }, {
16
- "d": [".fk6fouc{font-family:var(--fontFamilyBase);}", ".fojgt09{font-size:var(--fontSizeHero700);}", ".fcen8rp{line-height:var(--lineHeightHero700);}", ".fl43uef{font-weight:var(--fontWeightSemibold);}"]
19
+ "d": [".fk6fouc{font-family:var(--fontFamilyBase);}", ".fojgt09{font-size:var(--fontSizeHero700);}", ".fl43uef{font-weight:var(--fontWeightSemibold);}", ".fcen8rp{line-height:var(--lineHeightHero700);}"]
17
20
  });
18
21
  /**
19
22
  * Text wrapper component for the Title 2 typography variant
20
23
  */
21
24
 
22
25
 
23
- export var Title2 = /*#__PURE__*/createWrapper({
24
- useStyles: useStyles,
26
+ export const Title2 = /*#__PURE__*/createWrapper({
27
+ useStyles,
28
+ className: title2ClassNames.root,
25
29
  displayName: 'Title2'
26
30
  });
27
31
  //# sourceMappingURL=Title2.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/components/Title2/Title2.tsx"],"names":[],"mappings":"AACA,yBAA2B,6BAA3B;AACA,SAAS,gBAAT,QAAiC,8BAAjC;AACA,SAAS,aAAT,QAAgD,YAAhD;AAEA;;AAEG;;AACH,IAAM,SAAS,gBAAG;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAAlB;AAIA;;AAEG;;;AACH,OAAO,IAAM,MAAM,gBAAwC,aAAa,CAAC;AAAE,EAAA,SAAS,EAAA,SAAX;AAAa,EAAA,WAAW,EAAE;AAA1B,CAAD,CAAjE","sourceRoot":""}
1
+ {"version":3,"sources":["components/Title2/Title2.tsx"],"names":[],"mappings":"AACA,yBAA2B,gBAA3B;AACA,SAAS,aAAT,QAAgD,YAAhD;AAGA,SAAS,gBAAT,QAAiC,uBAAjC;AAEA,OAAO,MAAM,gBAAgB,GAA8B;AACzD,EAAA,IAAI,EAAE;AADmD,CAApD;AAIP;;AAEG;;AACH,MAAM,SAAS,gBAAG;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAAlB;AAIA;;AAEG;;;AACH,OAAO,MAAM,MAAM,gBAAwC,aAAa,CAAC;AACvE,EAAA,SADuE;AAEvE,EAAA,SAAS,EAAE,gBAAgB,CAAC,IAF2C;AAGvE,EAAA,WAAW,EAAE;AAH0D,CAAD,CAAjE","sourcesContent":["import type { FunctionComponent } from 'react';\nimport { makeStyles } from '@griffel/react';\nimport { createWrapper, TextWrapperProps } from '../wrapper';\nimport { SlotClassNames } from '@fluentui/react-utilities';\nimport { TextSlots } from '../Text/Text.types';\nimport { typographyStyles } from '@fluentui/react-theme';\n\nexport const title2ClassNames: SlotClassNames<TextSlots> = {\n root: 'fui-Title2',\n};\n\n/**\n * Styles for the root slot\n */\nconst useStyles = makeStyles({\n root: typographyStyles.title2,\n});\n\n/**\n * Text wrapper component for the Title 2 typography variant\n */\nexport const Title2: FunctionComponent<TextWrapperProps> = createWrapper({\n useStyles,\n className: title2ClassNames.root,\n displayName: 'Title2',\n});\n"],"sourceRoot":"../src/"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/Title2/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"../src/","sources":["components/Title2/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC","sourcesContent":["export * from './Title2';\n"]}
@@ -1,27 +1,31 @@
1
- import { __styles } from '@fluentui/react-make-styles';
2
- import { typographyStyles } from '../../typographyStyles/index';
1
+ import { __styles } from '@griffel/react';
3
2
  import { createWrapper } from '../wrapper';
3
+ import { typographyStyles } from '@fluentui/react-theme';
4
+ export const title3ClassNames = {
5
+ root: 'fui-Title3'
6
+ };
4
7
  /**
5
8
  * Styles for the root slot
6
9
  */
7
10
 
8
- var useStyles = /*#__PURE__*/__styles({
11
+ const useStyles = /*#__PURE__*/__styles({
9
12
  "root": {
10
13
  "Bahqtrf": "fk6fouc",
11
14
  "Be2twd7": "f1x0m3f5",
12
- "Bg96gwp": "fb86gi6",
13
- "Bhrd7zp": "fl43uef"
15
+ "Bhrd7zp": "fl43uef",
16
+ "Bg96gwp": "fb86gi6"
14
17
  }
15
18
  }, {
16
- "d": [".fk6fouc{font-family:var(--fontFamilyBase);}", ".f1x0m3f5{font-size:var(--fontSizeBase600);}", ".fb86gi6{line-height:var(--lineHeightBase600);}", ".fl43uef{font-weight:var(--fontWeightSemibold);}"]
19
+ "d": [".fk6fouc{font-family:var(--fontFamilyBase);}", ".f1x0m3f5{font-size:var(--fontSizeBase600);}", ".fl43uef{font-weight:var(--fontWeightSemibold);}", ".fb86gi6{line-height:var(--lineHeightBase600);}"]
17
20
  });
18
21
  /**
19
22
  * Text wrapper component for the Title 3 typography variant
20
23
  */
21
24
 
22
25
 
23
- export var Title3 = /*#__PURE__*/createWrapper({
24
- useStyles: useStyles,
26
+ export const Title3 = /*#__PURE__*/createWrapper({
27
+ useStyles,
28
+ className: title3ClassNames.root,
25
29
  displayName: 'Title3'
26
30
  });
27
31
  //# sourceMappingURL=Title3.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/components/Title3/Title3.tsx"],"names":[],"mappings":"AACA,yBAA2B,6BAA3B;AACA,SAAS,gBAAT,QAAiC,8BAAjC;AACA,SAAS,aAAT,QAAgD,YAAhD;AAEA;;AAEG;;AACH,IAAM,SAAS,gBAAG;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAAlB;AAIA;;AAEG;;;AACH,OAAO,IAAM,MAAM,gBAAwC,aAAa,CAAC;AAAE,EAAA,SAAS,EAAA,SAAX;AAAa,EAAA,WAAW,EAAE;AAA1B,CAAD,CAAjE","sourceRoot":""}
1
+ {"version":3,"sources":["components/Title3/Title3.tsx"],"names":[],"mappings":"AACA,yBAA2B,gBAA3B;AACA,SAAS,aAAT,QAAgD,YAAhD;AAGA,SAAS,gBAAT,QAAiC,uBAAjC;AAEA,OAAO,MAAM,gBAAgB,GAA8B;AACzD,EAAA,IAAI,EAAE;AADmD,CAApD;AAIP;;AAEG;;AACH,MAAM,SAAS,gBAAG;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAAlB;AAIA;;AAEG;;;AACH,OAAO,MAAM,MAAM,gBAAwC,aAAa,CAAC;AACvE,EAAA,SADuE;AAEvE,EAAA,SAAS,EAAE,gBAAgB,CAAC,IAF2C;AAGvE,EAAA,WAAW,EAAE;AAH0D,CAAD,CAAjE","sourcesContent":["import type { FunctionComponent } from 'react';\nimport { makeStyles } from '@griffel/react';\nimport { createWrapper, TextWrapperProps } from '../wrapper';\nimport { SlotClassNames } from '@fluentui/react-utilities';\nimport { TextSlots } from '../Text/Text.types';\nimport { typographyStyles } from '@fluentui/react-theme';\n\nexport const title3ClassNames: SlotClassNames<TextSlots> = {\n root: 'fui-Title3',\n};\n\n/**\n * Styles for the root slot\n */\nconst useStyles = makeStyles({\n root: typographyStyles.title3,\n});\n\n/**\n * Text wrapper component for the Title 3 typography variant\n */\nexport const Title3: FunctionComponent<TextWrapperProps> = createWrapper({\n useStyles,\n className: title3ClassNames.root,\n displayName: 'Title3',\n});\n"],"sourceRoot":"../src/"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/Title3/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"../src/","sources":["components/Title3/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC","sourcesContent":["export * from './Title3';\n"]}
@@ -1,15 +1,18 @@
1
1
  import * as React from 'react';
2
- import { mergeClasses } from '@fluentui/react-make-styles';
3
- import { renderText, useText, useTextStyles } from '../Text';
2
+ import { mergeClasses } from '@griffel/react';
3
+ import { renderText_unstable, useText_unstable, useTextStyles_unstable } from '../Text';
4
4
  export function createWrapper(options) {
5
- var useStyles = options.useStyles,
6
- displayName = options.displayName;
7
- var Wrapper = /*#__PURE__*/React.forwardRef(function (props, ref) {
8
- var styles = useStyles();
9
- var state = useText(props, ref);
10
- useTextStyles(state);
11
- state.root.className = mergeClasses(state.root.className, styles.root, props.className);
12
- return renderText(state);
5
+ const {
6
+ useStyles,
7
+ className,
8
+ displayName
9
+ } = options;
10
+ const Wrapper = /*#__PURE__*/React.forwardRef((props, ref) => {
11
+ const styles = useStyles();
12
+ const state = useText_unstable(props, ref);
13
+ useTextStyles_unstable(state);
14
+ state.root.className = mergeClasses(className, state.root.className, styles.root, props.className);
15
+ return renderText_unstable(state);
13
16
  });
14
17
  Wrapper.displayName = displayName;
15
18
  return Wrapper;
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/components/wrapper.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAZ,MAAuB,OAAvB;AACA,SAAS,YAAT,QAA6B,6BAA7B;AACA,SAAS,UAAT,EAAqB,OAArB,EAA8B,aAA9B,QAAmD,SAAnD;AAMA,OAAM,SAAU,aAAV,CAAwB,OAAxB,EAGL;AACS,MAAA,SAAS,GAAkB,OAAO,CAAzB,SAAT;AAAA,MAAW,WAAW,GAAK,OAAO,CAAZ,WAAtB;AACR,MAAM,OAAO,gBAA0C,KAAK,CAAC,UAAN,CAAiB,UAAC,KAAD,EAAQ,GAAR,EAAW;AAC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;AACD","sourcesContent":["import * as React from 'react';\nimport { mergeClasses } from '@griffel/react';\nimport { renderText_unstable, useText_unstable, useTextStyles_unstable } from '../Text';\nimport type { TextProps } from '../Text';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\n\nexport type TextWrapperProps = Omit<TextProps, 'font' | 'size'>;\n\nexport function createWrapper(options: {\n className: string;\n displayName: string;\n useStyles: () => Record<'root', string>;\n}): React.FunctionComponent<TextWrapperProps> {\n const { useStyles, className, displayName } = options;\n const Wrapper: ForwardRefComponent<TextWrapperProps> = React.forwardRef((props, ref) => {\n const styles = useStyles();\n const state = useText_unstable(props as TextProps, ref);\n\n useTextStyles_unstable(state);\n\n state.root.className = mergeClasses(className, state.root.className, styles.root, props.className);\n\n return renderText_unstable(state);\n });\n Wrapper.displayName = displayName;\n\n return Wrapper;\n}\n"],"sourceRoot":"../src/"}
package/lib/index.js CHANGED
@@ -1,11 +1,12 @@
1
- export * from './Text';
2
- export * from './Display';
3
- export * from './LargeTitle';
4
- export * from './Title1';
5
- export * from './Title2';
6
- export * from './Title3';
7
- export * from './Headline';
8
- export * from './Subheadline';
9
- export * from './Body';
10
- export * from './Caption';
1
+ export { Text, renderText_unstable, textClassNames, useTextStyles_unstable, useText_unstable } from './Text';
2
+ export { Display, displayClassNames } from './Display';
3
+ export { LargeTitle, largeTitleClassNames } from './LargeTitle';
4
+ export { Title1, title1ClassNames } from './Title1';
5
+ export { Title2, title2ClassNames } from './Title2';
6
+ export { Title3, title3ClassNames } from './Title3';
7
+ export { Subtitle1, subtitle1ClassNames } from './Subtitle1';
8
+ export { Subtitle2, subtitle2ClassNames } from './Subtitle2';
9
+ export { Body1, body1ClassNames } from './Body1';
10
+ export { Caption1, caption1ClassNames } from './Caption1';
11
+ export { Caption2, caption2ClassNames } from './Caption2';
11
12
  //# sourceMappingURL=index.js.map
package/lib/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC;AACvB,cAAc,WAAW,CAAC;AAC1B,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,eAAe,CAAC;AAC9B,cAAc,QAAQ,CAAC;AACvB,cAAc,WAAW,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"../src/","sources":["index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,mBAAmB,EAAE,cAAc,EAAE,sBAAsB,EAAE,gBAAgB,EAAE,MAAM,QAAQ,CAAC;AAE7G,OAAO,EAAE,OAAO,EAAE,iBAAiB,EAAE,MAAM,WAAW,CAAC;AACvD,OAAO,EAAE,UAAU,EAAE,oBAAoB,EAAE,MAAM,cAAc,CAAC;AAChE,OAAO,EAAE,MAAM,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AACpD,OAAO,EAAE,MAAM,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AACpD,OAAO,EAAE,MAAM,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AACpD,OAAO,EAAE,SAAS,EAAE,mBAAmB,EAAE,MAAM,aAAa,CAAC;AAC7D,OAAO,EAAE,SAAS,EAAE,mBAAmB,EAAE,MAAM,aAAa,CAAC;AAC7D,OAAO,EAAE,KAAK,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AACjD,OAAO,EAAE,QAAQ,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAC1D,OAAO,EAAE,QAAQ,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC","sourcesContent":["export { Text, renderText_unstable, textClassNames, useTextStyles_unstable, useText_unstable } from './Text';\nexport type { TextProps, TextSlots, TextState } from './Text';\nexport { Display, displayClassNames } from './Display';\nexport { LargeTitle, largeTitleClassNames } from './LargeTitle';\nexport { Title1, title1ClassNames } from './Title1';\nexport { Title2, title2ClassNames } from './Title2';\nexport { Title3, title3ClassNames } from './Title3';\nexport { Subtitle1, subtitle1ClassNames } from './Subtitle1';\nexport { Subtitle2, subtitle2ClassNames } from './Subtitle2';\nexport { Body1, body1ClassNames } from './Body1';\nexport { Caption1, caption1ClassNames } from './Caption1';\nexport { Caption2, caption2ClassNames } from './Caption2';\n"]}
@@ -0,0 +1,10 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+
7
+ const tslib_1 = /*#__PURE__*/require("tslib");
8
+
9
+ tslib_1.__exportStar(require("./components/Body1/index"), exports);
10
+ //# sourceMappingURL=Body1.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["Body1.ts"],"names":[],"mappings":";;;;;;;;AAAA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,0BAAA,CAAA,EAAA,OAAA","sourcesContent":["export * from './components/Body1/index';\n"],"sourceRoot":"../src/"}
@@ -0,0 +1,10 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+
7
+ const tslib_1 = /*#__PURE__*/require("tslib");
8
+
9
+ tslib_1.__exportStar(require("./components/Caption1/index"), exports);
10
+ //# sourceMappingURL=Caption1.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["Caption1.ts"],"names":[],"mappings":";;;;;;;;AAAA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,6BAAA,CAAA,EAAA,OAAA","sourcesContent":["export * from './components/Caption1/index';\n"],"sourceRoot":"../src/"}
@@ -0,0 +1,10 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+
7
+ const tslib_1 = /*#__PURE__*/require("tslib");
8
+
9
+ tslib_1.__exportStar(require("./components/Caption2/index"), exports);
10
+ //# sourceMappingURL=Caption2.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["Caption2.ts"],"names":[],"mappings":";;;;;;;;AAAA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,6BAAA,CAAA,EAAA,OAAA","sourcesContent":["export * from './components/Caption2/index';\n"],"sourceRoot":"../src/"}
@@ -4,7 +4,7 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
 
7
- var tslib_1 = /*#__PURE__*/require("tslib");
7
+ const tslib_1 = /*#__PURE__*/require("tslib");
8
8
 
9
9
  tslib_1.__exportStar(require("./components/Display/index"), exports);
10
10
  //# sourceMappingURL=Display.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/Display.ts"],"names":[],"mappings":";;;;;;;;AAAA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,4BAAA,CAAA,EAAA,OAAA","sourceRoot":""}
1
+ {"version":3,"sources":["Display.ts"],"names":[],"mappings":";;;;;;;;AAAA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,4BAAA,CAAA,EAAA,OAAA","sourcesContent":["export * from './components/Display/index';\n"],"sourceRoot":"../src/"}
@@ -4,7 +4,7 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
 
7
- var tslib_1 = /*#__PURE__*/require("tslib");
7
+ const tslib_1 = /*#__PURE__*/require("tslib");
8
8
 
9
9
  tslib_1.__exportStar(require("./components/LargeTitle/index"), exports);
10
10
  //# sourceMappingURL=LargeTitle.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/LargeTitle.ts"],"names":[],"mappings":";;;;;;;;AAAA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,+BAAA,CAAA,EAAA,OAAA","sourceRoot":""}
1
+ {"version":3,"sources":["LargeTitle.ts"],"names":[],"mappings":";;;;;;;;AAAA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,+BAAA,CAAA,EAAA,OAAA","sourcesContent":["export * from './components/LargeTitle/index';\n"],"sourceRoot":"../src/"}
@@ -0,0 +1,10 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+
7
+ const tslib_1 = /*#__PURE__*/require("tslib");
8
+
9
+ tslib_1.__exportStar(require("./components/Subtitle1/index"), exports);
10
+ //# sourceMappingURL=Subtitle1.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["Subtitle1.ts"],"names":[],"mappings":";;;;;;;;AAAA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,8BAAA,CAAA,EAAA,OAAA","sourcesContent":["export * from './components/Subtitle1/index';\n"],"sourceRoot":"../src/"}
@@ -0,0 +1,10 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+
7
+ const tslib_1 = /*#__PURE__*/require("tslib");
8
+
9
+ tslib_1.__exportStar(require("./components/Subtitle2/index"), exports);
10
+ //# sourceMappingURL=Subtitle2.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["Subtitle2.ts"],"names":[],"mappings":";;;;;;;;AAAA,OAAA,CAAA,YAAA,CAAA,OAAA,CAAA,8BAAA,CAAA,EAAA,OAAA","sourcesContent":["export * from './components/Subtitle2/index';\n"],"sourceRoot":"../src/"}
@@ -4,7 +4,7 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
 
7
- var tslib_1 = /*#__PURE__*/require("tslib");
7
+ const tslib_1 = /*#__PURE__*/require("tslib");
8
8
 
9
9
  tslib_1.__exportStar(require("./components/Text/index"), exports);
10
10
  //# sourceMappingURL=Text.js.map