@fluentui/react-text 9.6.4 → 9.6.6
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.
- package/CHANGELOG.md +31 -5
- package/dist/index.d.ts +2 -1
- package/lib/components/Text/Text.js +1 -0
- package/lib/components/Text/Text.js.map +1 -1
- package/lib/components/Text/renderText.js.map +1 -1
- package/lib/components/Text/useTextStyles.styles.js +2 -0
- package/lib/components/Text/useTextStyles.styles.js.map +1 -1
- package/lib/components/Text/useTextStyles.styles.raw.js +1 -0
- package/lib/components/Text/useTextStyles.styles.raw.js.map +1 -1
- package/lib/components/presets/createPreset.js +1 -0
- package/lib/components/presets/createPreset.js.map +1 -1
- package/lib-commonjs/components/Text/Text.js +1 -0
- package/lib-commonjs/components/Text/Text.js.map +1 -1
- package/lib-commonjs/components/Text/renderText.js.map +1 -1
- package/lib-commonjs/components/Text/useTextStyles.styles.js +1 -0
- package/lib-commonjs/components/Text/useTextStyles.styles.js.map +1 -1
- package/lib-commonjs/components/Text/useTextStyles.styles.raw.js +1 -0
- package/lib-commonjs/components/Text/useTextStyles.styles.raw.js.map +1 -1
- package/lib-commonjs/components/presets/createPreset.js +1 -0
- package/lib-commonjs/components/presets/createPreset.js.map +1 -1
- package/package.json +8 -8
package/CHANGELOG.md
CHANGED
@@ -1,19 +1,45 @@
|
|
1
1
|
# Change Log - @fluentui/react-text
|
2
2
|
|
3
|
-
This log was last generated on Thu,
|
3
|
+
This log was last generated on Thu, 02 Oct 2025 15:07:27 GMT and should not be manually modified.
|
4
4
|
|
5
5
|
<!-- Start content -->
|
6
6
|
|
7
|
+
## [9.6.6](https://github.com/microsoft/fluentui/tree/@fluentui/react-text_v9.6.6)
|
8
|
+
|
9
|
+
Thu, 02 Oct 2025 15:07:27 GMT
|
10
|
+
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-text_v9.6.5..@fluentui/react-text_v9.6.6)
|
11
|
+
|
12
|
+
### Patches
|
13
|
+
|
14
|
+
- feat: enforce usage of use client directive for files with client-only features ([PR #35173](https://github.com/microsoft/fluentui/pull/35173) by dmytrokirpa@microsoft.com)
|
15
|
+
- Bump @fluentui/react-shared-contexts to v9.25.2 ([PR #35133](https://github.com/microsoft/fluentui/pull/35133) by beachball)
|
16
|
+
- Bump @fluentui/react-utilities to v9.25.0 ([PR #35133](https://github.com/microsoft/fluentui/pull/35133) by beachball)
|
17
|
+
- Bump @fluentui/react-jsx-runtime to v9.2.1 ([PR #35133](https://github.com/microsoft/fluentui/pull/35133) by beachball)
|
18
|
+
|
19
|
+
## [9.6.5](https://github.com/microsoft/fluentui/tree/@fluentui/react-text_v9.6.5)
|
20
|
+
|
21
|
+
Mon, 08 Sep 2025 12:50:46 GMT
|
22
|
+
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-text_v9.6.4..@fluentui/react-text_v9.6.5)
|
23
|
+
|
24
|
+
### Patches
|
25
|
+
|
26
|
+
- chore: enforce explicit module boundary types ([PR #35080](https://github.com/microsoft/fluentui/pull/35080) by dmytrokirpa@microsoft.com)
|
27
|
+
- chore: extend peer dependencies versions to support React 19 ([PR #35145](https://github.com/microsoft/fluentui/pull/35145) by dmytrokirpa@microsoft.com)
|
28
|
+
- fix: react 19 type issues ([PR #34864](https://github.com/microsoft/fluentui/pull/34864) by dmytrokirpa@microsoft.com)
|
29
|
+
- Bump @fluentui/react-shared-contexts to v9.25.1 ([commit](https://github.com/microsoft/fluentui/commit/17af11b3c9f4cac2beeaf4342a81c1f08e95fd29) by beachball)
|
30
|
+
- Bump @fluentui/react-utilities to v9.24.1 ([commit](https://github.com/microsoft/fluentui/commit/17af11b3c9f4cac2beeaf4342a81c1f08e95fd29) by beachball)
|
31
|
+
- Bump @fluentui/react-jsx-runtime to v9.2.0 ([commit](https://github.com/microsoft/fluentui/commit/17af11b3c9f4cac2beeaf4342a81c1f08e95fd29) by beachball)
|
32
|
+
|
7
33
|
## [9.6.4](https://github.com/microsoft/fluentui/tree/@fluentui/react-text_v9.6.4)
|
8
34
|
|
9
|
-
Thu, 21 Aug 2025 12:
|
35
|
+
Thu, 21 Aug 2025 12:25:39 GMT
|
10
36
|
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-text_v9.6.3..@fluentui/react-text_v9.6.4)
|
11
37
|
|
12
38
|
### Patches
|
13
39
|
|
14
|
-
- Bump @fluentui/react-shared-contexts to v9.25.0 ([
|
15
|
-
- Bump @fluentui/react-utilities to v9.24.0 ([
|
16
|
-
- Bump @fluentui/react-jsx-runtime to v9.1.6 ([
|
40
|
+
- Bump @fluentui/react-shared-contexts to v9.25.0 ([commit](https://github.com/microsoft/fluentui/commit/884c695de4f736774c224fa33b2e410bf42752b0) by beachball)
|
41
|
+
- Bump @fluentui/react-utilities to v9.24.0 ([commit](https://github.com/microsoft/fluentui/commit/884c695de4f736774c224fa33b2e410bf42752b0) by beachball)
|
42
|
+
- Bump @fluentui/react-jsx-runtime to v9.1.6 ([commit](https://github.com/microsoft/fluentui/commit/884c695de4f736774c224fa33b2e410bf42752b0) by beachball)
|
17
43
|
|
18
44
|
## [9.6.3](https://github.com/microsoft/fluentui/tree/@fluentui/react-text_v9.6.3)
|
19
45
|
|
package/dist/index.d.ts
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
import type { ComponentProps } from '@fluentui/react-utilities';
|
2
2
|
import type { ComponentState } from '@fluentui/react-utilities';
|
3
3
|
import type { ForwardRefComponent } from '@fluentui/react-utilities';
|
4
|
+
import type { JSXElement } from '@fluentui/react-utilities';
|
4
5
|
import * as React_2 from 'react';
|
5
6
|
import type { Slot } from '@fluentui/react-utilities';
|
6
7
|
import { SlotClassNames } from '@fluentui/react-utilities';
|
@@ -85,7 +86,7 @@ export declare const largeTitleClassNames: SlotClassNames<TextSlots>;
|
|
85
86
|
/**
|
86
87
|
* Render the final JSX of Text
|
87
88
|
*/
|
88
|
-
export declare const renderText_unstable: (state: TextState) =>
|
89
|
+
export declare const renderText_unstable: (state: TextState) => JSXElement;
|
89
90
|
|
90
91
|
/**
|
91
92
|
* Text preset component for the Subtitle1 typography variant
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/components/Text/Text.tsx"],"sourcesContent":["
|
1
|
+
{"version":3,"sources":["../src/components/Text/Text.tsx"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { useText_unstable } from './useText';\nimport { renderText_unstable } from './renderText';\nimport { useTextStyles_unstable } from './useTextStyles.styles';\nimport type { TextProps } from './Text.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\nimport { useCustomStyleHook_unstable } from '@fluentui/react-shared-contexts';\n\n/**\n * Typography and styling abstraction component used to ensure consistency of text.\n */\nexport const Text: ForwardRefComponent<TextProps> = React.forwardRef((props, ref) => {\n const state = useText_unstable(props, ref);\n\n useTextStyles_unstable(state);\n\n useCustomStyleHook_unstable('useTextStyles_unstable')(state);\n\n return renderText_unstable(state);\n // Work around some small mismatches in inferred types which don't matter in practice\n}) as ForwardRefComponent<TextProps>;\n\nText.displayName = 'Text';\n"],"names":["React","useText_unstable","renderText_unstable","useTextStyles_unstable","useCustomStyleHook_unstable","Text","forwardRef","props","ref","state","displayName"],"mappings":"AAAA;AAEA,YAAYA,WAAW,QAAQ;AAC/B,SAASC,gBAAgB,QAAQ,YAAY;AAC7C,SAASC,mBAAmB,QAAQ,eAAe;AACnD,SAASC,sBAAsB,QAAQ,yBAAyB;AAGhE,SAASC,2BAA2B,QAAQ,kCAAkC;AAE9E;;CAEC,GACD,OAAO,MAAMC,qBAAuCL,MAAMM,UAAU,CAAC,CAACC,OAAOC;IAC3E,MAAMC,QAAQR,iBAAiBM,OAAOC;IAEtCL,uBAAuBM;IAEvBL,4BAA4B,0BAA0BK;IAEtD,OAAOP,oBAAoBO;AAC3B,qFAAqF;AACvF,GAAqC;AAErCJ,KAAKK,WAAW,GAAG"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/components/Text/renderText.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { assertSlots } 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 assertSlots<TextSlots>(state);\n\n return <state.root />;\n};\n"],"names":["assertSlots","renderText_unstable","state","root"],"mappings":"AAAA,0BAA0B,GAC1B,iDAAiD;AAEjD,SAASA,WAAW,QAAQ,4BAA4B;
|
1
|
+
{"version":3,"sources":["../src/components/Text/renderText.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { assertSlots } from '@fluentui/react-utilities';\nimport type { JSXElement } 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): JSXElement => {\n assertSlots<TextSlots>(state);\n\n return <state.root />;\n};\n"],"names":["assertSlots","renderText_unstable","state","root"],"mappings":"AAAA,0BAA0B,GAC1B,iDAAiD;AAEjD,SAASA,WAAW,QAAQ,4BAA4B;AAIxD;;CAEC,GACD,OAAO,MAAMC,sBAAsB,CAACC;IAClCF,YAAuBE;IAEvB,qBAAO,KAACA,MAAMC,IAAI;AACpB,EAAE"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["__styles","mergeClasses","tokens","textClassNames","root","useStyles","Bahqtrf","Be2twd7","Bg96gwp","Bhrd7zp","fsow6f","mc9l5x","Huce71","B68tc82","Bmxbyg5","Bpg54ce","ygn44y","nowrap","truncate","block","italic","B80ckks","underline","w71qe1","strikethrough","strikethroughUnderline","base100","base200","base400","base500","base600","hero700","hero800","hero900","hero1000","monospace","numeric","weightMedium","weightSemibold","weightBold","alignCenter","alignEnd","alignJustify","d","p","useTextStyles_unstable","state","styles","className","wrap","size","font","weight","align"],"sources":["useTextStyles.styles.js"],"sourcesContent":["
|
1
|
+
{"version":3,"names":["__styles","mergeClasses","tokens","textClassNames","root","useStyles","Bahqtrf","Be2twd7","Bg96gwp","Bhrd7zp","fsow6f","mc9l5x","Huce71","B68tc82","Bmxbyg5","Bpg54ce","ygn44y","nowrap","truncate","block","italic","B80ckks","underline","w71qe1","strikethrough","strikethroughUnderline","base100","base200","base400","base500","base600","hero700","hero800","hero900","hero1000","monospace","numeric","weightMedium","weightSemibold","weightBold","alignCenter","alignEnd","alignJustify","d","p","useTextStyles_unstable","state","styles","className","wrap","size","font","weight","align"],"sources":["useTextStyles.styles.js"],"sourcesContent":["'use client';\nimport { makeStyles, mergeClasses } from '@griffel/react';\nimport { tokens } from '@fluentui/react-theme';\nexport const textClassNames = {\n root: 'fui-Text'\n};\n/**\n * Styles for the root slot\n */ const 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 overflow: 'visible',\n textOverflow: 'clip'\n },\n nowrap: {\n whiteSpace: 'nowrap',\n 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 weightBold: {\n fontWeight: tokens.fontWeightBold\n },\n alignCenter: {\n textAlign: 'center'\n },\n alignEnd: {\n textAlign: 'end'\n },\n alignJustify: {\n textAlign: 'justify'\n }\n});\n/**\n * Apply styling to the Text slots based on the state\n */ export const useTextStyles_unstable = (state)=>{\n 'use no memo';\n const styles = useStyles();\n 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.weight === 'bold' && styles.weightBold, state.align === 'center' && styles.alignCenter, state.align === 'end' && styles.alignEnd, state.align === 'justify' && styles.alignJustify, state.root.className);\n return state;\n};\n"],"mappings":"AAAA,YAAY;;AACZ,SAAAA,QAAA,EAAqBC,YAAY,QAAQ,gBAAgB;AACzD,SAASC,MAAM,QAAQ,uBAAuB;AAC9C,OAAO,MAAMC,cAAc,GAAG;EAC1BC,IAAI,EAAE;AACV,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Ea,KAAK,CAACI,IAAI,KAAK,IAAI,IAAIH,MAAM,CAACb,QAAQ,EAAEY,KAAK,CAACK,IAAI,KAAK,WAAW,IAAIJ,MAAM,CAACZ,SAAS,EAAEW,KAAK,CAACK,IAAI,KAAK,SAAS,IAAIJ,MAAM,CAACX,OAAO,EAAEU,KAAK,CAACM,MAAM,KAAK,QAAQ,IAAIL,MAAM,CAACV,YAAY,EAAES,KAAK,CAACM,MAAM,KAAK,UAAU,IAAIL,MAAM,CAACT,cAAc,EAAEQ,KAAK,CAACM,MAAM,KAAK,MAAM,IAAIL,MAAM,CAACR,UAAU,EAAEO,KAAK,CAACO,KAAK,KAAK,QAAQ,IAAIN,MAAM,CAACP,WAAW,EAAEM,KAAK,CAACO,KAAK,KAAK,KAAK,IAAIN,MAAM,CAACN,QAAQ,EAAEK,KAAK,CAACO,KAAK,KAAK,SAAS,IAAIN,MAAM,CAACL,YAAY,EAAEI,KAAK,CAAC1C,IAAI,CAAC4C,SAAS,CAAC;EACllC,OAAOF,KAAK;AAChB,CAAC","ignoreList":[]}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/components/Text/useTextStyles.styles.ts"],"sourcesContent":["
|
1
|
+
{"version":3,"sources":["../src/components/Text/useTextStyles.styles.ts"],"sourcesContent":["'use client';\n\nimport { makeStyles, mergeClasses } 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 overflow: 'visible',\n textOverflow: 'clip',\n },\n nowrap: {\n whiteSpace: 'nowrap',\n 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 weightBold: {\n fontWeight: tokens.fontWeightBold,\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 'use no memo';\n\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.weight === 'bold' && styles.weightBold,\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"],"names":["makeStyles","mergeClasses","tokens","textClassNames","root","useStyles","fontFamily","fontFamilyBase","fontSize","fontSizeBase300","lineHeight","lineHeightBase300","fontWeight","fontWeightRegular","textAlign","display","whiteSpace","overflow","textOverflow","nowrap","truncate","block","italic","fontStyle","underline","textDecorationLine","strikethrough","strikethroughUnderline","base100","fontSizeBase100","lineHeightBase100","base200","fontSizeBase200","lineHeightBase200","base400","fontSizeBase400","lineHeightBase400","base500","fontSizeBase500","lineHeightBase500","base600","fontSizeBase600","lineHeightBase600","hero700","fontSizeHero700","lineHeightHero700","hero800","fontSizeHero800","lineHeightHero800","hero900","fontSizeHero900","lineHeightHero900","hero1000","fontSizeHero1000","lineHeightHero1000","monospace","fontFamilyMonospace","numeric","fontFamilyNumeric","weightMedium","fontWeightMedium","weightSemibold","fontWeightSemibold","weightBold","fontWeightBold","alignCenter","alignEnd","alignJustify","useTextStyles_unstable","state","styles","className","wrap","size","font","weight","align"],"mappings":"AAAA;AAEA,SAASA,UAAU,EAAEC,YAAY,QAAQ,iBAAiB;AAC1D,SAASC,MAAM,QAAQ,wBAAwB;AAI/C,OAAO,MAAMC,iBAA4C;IACvDC,MAAM;AACR,EAAE;AAEF;;CAEC,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AAOlB,QAAQ,EACtCiB,MAAMK,IAAI,KAAK,eAAeJ,OAAOf,SAAS,EAC9Cc,MAAMK,IAAI,KAAK,aAAaJ,OAAOb,OAAO,EAC1CY,MAAMM,MAAM,KAAK,YAAYL,OAAOX,YAAY,EAChDU,MAAMM,MAAM,KAAK,cAAcL,OAAOT,cAAc,EACpDQ,MAAMM,MAAM,KAAK,UAAUL,OAAOP,UAAU,EAC5CM,MAAMO,KAAK,KAAK,YAAYN,OAAOL,WAAW,EAC9CI,MAAMO,KAAK,KAAK,SAASN,OAAOJ,QAAQ,EACxCG,MAAMO,KAAK,KAAK,aAAaN,OAAOH,YAAY,EAChDE,MAAMjE,IAAI,CAACmE,SAAS;IAGtB,OAAOF;AACT,EAAE"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/components/presets/createPreset.ts"],"sourcesContent":["
|
1
|
+
{"version":3,"sources":["../src/components/presets/createPreset.ts"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { mergeClasses } from '@griffel/react';\nimport { renderText_unstable, useText_unstable, useTextStyles_unstable } from '../Text';\nimport type { TextProps, TextPresetProps } from '../Text';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\n\nexport function createPreset(options: {\n className: string;\n displayName: string;\n useStyles: () => Record<'root', string>;\n}): React.FunctionComponent<TextPresetProps> {\n const { useStyles, className, displayName } = options;\n const Wrapper: ForwardRefComponent<TextPresetProps> = React.forwardRef((props, ref) => {\n 'use no memo';\n\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"],"names":["React","mergeClasses","renderText_unstable","useText_unstable","useTextStyles_unstable","createPreset","options","useStyles","className","displayName","Wrapper","forwardRef","props","ref","styles","state","root"],"mappings":"AAAA;AAEA,YAAYA,WAAW,QAAQ;AAC/B,SAASC,YAAY,QAAQ,iBAAiB;AAC9C,SAASC,mBAAmB,EAAEC,gBAAgB,EAAEC,sBAAsB,QAAQ,UAAU;AAIxF,OAAO,SAASC,aAAaC,OAI5B;IACC,MAAM,EAAEC,SAAS,EAAEC,SAAS,EAAEC,WAAW,EAAE,GAAGH;IAC9C,MAAMI,UAAgDV,MAAMW,UAAU,CAAC,CAACC,OAAOC;QAC7E;QAEA,MAAMC,SAASP;QACf,MAAMQ,QAAQZ,iBAAiBS,OAAoBC;QAEnDT,uBAAuBW;QAEvBA,MAAMC,IAAI,CAACR,SAAS,GAAGP,aAAaO,WAAWO,MAAMC,IAAI,CAACR,SAAS,EAAEM,OAAOE,IAAI,EAAEJ,MAAMJ,SAAS;QAEjG,OAAON,oBAAoBa;IAC7B;IACAL,QAAQD,WAAW,GAAGA;IAEtB,OAAOC;AACT"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/components/Text/Text.tsx"],"sourcesContent":["
|
1
|
+
{"version":3,"sources":["../src/components/Text/Text.tsx"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { useText_unstable } from './useText';\nimport { renderText_unstable } from './renderText';\nimport { useTextStyles_unstable } from './useTextStyles.styles';\nimport type { TextProps } from './Text.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\nimport { useCustomStyleHook_unstable } from '@fluentui/react-shared-contexts';\n\n/**\n * Typography and styling abstraction component used to ensure consistency of text.\n */\nexport const Text: ForwardRefComponent<TextProps> = React.forwardRef((props, ref) => {\n const state = useText_unstable(props, ref);\n\n useTextStyles_unstable(state);\n\n useCustomStyleHook_unstable('useTextStyles_unstable')(state);\n\n return renderText_unstable(state);\n // Work around some small mismatches in inferred types which don't matter in practice\n}) as ForwardRefComponent<TextProps>;\n\nText.displayName = 'Text';\n"],"names":["React","useText_unstable","renderText_unstable","useTextStyles_unstable","useCustomStyleHook_unstable","Text","forwardRef","props","ref","state","displayName"],"mappings":"AAAA;;;;;;;;;;;;iEAEuB,QAAQ;yBACE,YAAY;4BACT,eAAe;qCACZ,yBAAyB;qCAGpB,kCAAkC;AAKvE,MAAMK,OAAAA,WAAAA,GAAuCL,OAAMM,UAAU,CAAC,CAACC,OAAOC;IAC3E,MAAMC,YAAQR,yBAAAA,EAAiBM,OAAOC;QAEtCL,2CAAAA,EAAuBM;QAEvBL,gDAAAA,EAA4B,0BAA0BK;IAEtD,WAAOP,+BAAAA,EAAoBO;AAC3B,qFAAqF;AACvF,GAAqC;AAErCJ,KAAKK,WAAW,GAAG"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/components/Text/renderText.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { assertSlots } 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 assertSlots<TextSlots>(state);\n\n return <state.root />;\n};\n"],"names":["assertSlots","renderText_unstable","state","root"],"mappings":";;;;;;;;;;4BACA,gDAAiD;gCAErB,4BAA4B;
|
1
|
+
{"version":3,"sources":["../src/components/Text/renderText.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { assertSlots } from '@fluentui/react-utilities';\nimport type { JSXElement } 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): JSXElement => {\n assertSlots<TextSlots>(state);\n\n return <state.root />;\n};\n"],"names":["assertSlots","renderText_unstable","state","root"],"mappings":";;;;;;;;;;4BACA,gDAAiD;gCAErB,4BAA4B;AAOjD,MAAMC,sBAAsB,CAACC;QAClCF,2BAAAA,EAAuBE;IAEvB,OAAA,WAAA,OAAO,eAAA,EAACA,MAAMC,IAAI,EAAA,CAAA;AACpB,EAAE"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["useTextStyles.styles.js"],"sourcesContent":["
|
1
|
+
{"version":3,"sources":["useTextStyles.styles.js"],"sourcesContent":["'use client';\nimport { makeStyles, mergeClasses } from '@griffel/react';\nimport { tokens } from '@fluentui/react-theme';\nexport const textClassNames = {\n root: 'fui-Text'\n};\n/**\n * Styles for the root slot\n */ const 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 overflow: 'visible',\n textOverflow: 'clip'\n },\n nowrap: {\n whiteSpace: 'nowrap',\n 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 weightBold: {\n fontWeight: tokens.fontWeightBold\n },\n alignCenter: {\n textAlign: 'center'\n },\n alignEnd: {\n textAlign: 'end'\n },\n alignJustify: {\n textAlign: 'justify'\n }\n});\n/**\n * Apply styling to the Text slots based on the state\n */ export const useTextStyles_unstable = (state)=>{\n 'use no memo';\n const styles = useStyles();\n 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.weight === 'bold' && styles.weightBold, state.align === 'center' && styles.alignCenter, state.align === 'end' && styles.alignEnd, state.align === 'justify' && styles.alignJustify, state.root.className);\n return state;\n};\n"],"names":["__styles","mergeClasses","tokens","textClassNames","root","useStyles","Bahqtrf","Be2twd7","Bg96gwp","Bhrd7zp","fsow6f","mc9l5x","Huce71","B68tc82","Bmxbyg5","Bpg54ce","ygn44y","nowrap","truncate","block","italic","B80ckks","underline","w71qe1","strikethrough","strikethroughUnderline","base100","base200","base400","base500","base600","hero700","hero800","hero900","hero1000","monospace","numeric","weightMedium","weightSemibold","weightBold","alignCenter","alignEnd","alignJustify","d","p","useTextStyles_unstable","state","styles","className","wrap","size","font","weight","align"],"mappings":"AAAA,YAAY;;;;;;;;;;;;IAGCG,cAAc;;;IAsGV0C,sBAAsB;;;;uBAxGE,gBAAgB;AAElD,uBAAuB;IA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CAACO,KAAK,KAAK,KAAK,IAAIN,MAAM,CAACN,QAAQ,EAAEK,KAAK,CAACO,KAAK,KAAK,SAAS,IAAIN,MAAM,CAACL,YAAY,EAAEI,KAAK,CAAC1C,IAAI,CAAC4C,SAAS,CAAC;IACllC,OAAOF,KAAK;AAChB,CAAC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/components/Text/useTextStyles.styles.ts"],"sourcesContent":["
|
1
|
+
{"version":3,"sources":["../src/components/Text/useTextStyles.styles.ts"],"sourcesContent":["'use client';\n\nimport { makeStyles, mergeClasses } 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 overflow: 'visible',\n textOverflow: 'clip',\n },\n nowrap: {\n whiteSpace: 'nowrap',\n 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 weightBold: {\n fontWeight: tokens.fontWeightBold,\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 'use no memo';\n\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.weight === 'bold' && styles.weightBold,\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"],"names":["makeStyles","mergeClasses","tokens","textClassNames","root","useStyles","fontFamily","fontFamilyBase","fontSize","fontSizeBase300","lineHeight","lineHeightBase300","fontWeight","fontWeightRegular","textAlign","display","whiteSpace","overflow","textOverflow","nowrap","truncate","block","italic","fontStyle","underline","textDecorationLine","strikethrough","strikethroughUnderline","base100","fontSizeBase100","lineHeightBase100","base200","fontSizeBase200","lineHeightBase200","base400","fontSizeBase400","lineHeightBase400","base500","fontSizeBase500","lineHeightBase500","base600","fontSizeBase600","lineHeightBase600","hero700","fontSizeHero700","lineHeightHero700","hero800","fontSizeHero800","lineHeightHero800","hero900","fontSizeHero900","lineHeightHero900","hero1000","fontSizeHero1000","lineHeightHero1000","monospace","fontFamilyMonospace","numeric","fontFamilyNumeric","weightMedium","fontWeightMedium","weightSemibold","fontWeightSemibold","weightBold","fontWeightBold","alignCenter","alignEnd","alignJustify","useTextStyles_unstable","state","styles","className","wrap","size","font","weight","align"],"mappings":"AAAA;;;;;;;;;;;;IAOaG,cAAAA;;;0BA0GAiE;eAAAA;;;uBA/G4B,iBAAiB;4BACnC,wBAAwB;AAIxC,uBAAkD;IACvDhE,MAAM;AACR,EAAE;AAEF;;CAEC,GACD,MAAMC,gBAAYL,iBAAAA,EAAW;IAC3BI,MAAM;QACJE,YAAYJ,kBAAAA,CAAOK,cAAc;QACjCC,UAAUN,kBAAAA,CAAOO,eAAe;QAChCC,YAAYR,kBAAAA,CAAOS,iBAAiB;QACpCC,YAAYV,kBAAAA,CAAOW,iBAAiB;QACpCC,WAAW;QACXC,SAAS;QACTC,YAAY;QACZC,UAAU;QACVC,cAAc;IAChB;IACAC,QAAQ;QACNH,YAAY;QACZC,UAAU;IACZ;IACAG,UAAU;QACRF,cAAc;IAChB;IACAG,OAAO;QACLN,SAAS;IACX;IACAO,QAAQ;QACNC,WAAW;IACb;IACAC,WAAW;QACTC,oBAAoB;IACtB;IACAC,eAAe;QACbD,oBAAoB;IACtB;IACAE,wBAA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AU,EAC5CM,MAAMO,KAAK,KAAK,YAAYN,OAAOL,WAAW,EAC9CI,MAAMO,KAAK,KAAK,SAASN,OAAOJ,QAAQ,EACxCG,MAAMO,KAAK,KAAK,aAAaN,OAAOH,YAAY,EAChDE,MAAMjE,IAAI,CAACmE,SAAS;IAGtB,OAAOF;AACT,EAAE"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["../src/components/presets/createPreset.ts"],"sourcesContent":["
|
1
|
+
{"version":3,"sources":["../src/components/presets/createPreset.ts"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { mergeClasses } from '@griffel/react';\nimport { renderText_unstable, useText_unstable, useTextStyles_unstable } from '../Text';\nimport type { TextProps, TextPresetProps } from '../Text';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\n\nexport function createPreset(options: {\n className: string;\n displayName: string;\n useStyles: () => Record<'root', string>;\n}): React.FunctionComponent<TextPresetProps> {\n const { useStyles, className, displayName } = options;\n const Wrapper: ForwardRefComponent<TextPresetProps> = React.forwardRef((props, ref) => {\n 'use no memo';\n\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"],"names":["React","mergeClasses","renderText_unstable","useText_unstable","useTextStyles_unstable","createPreset","options","useStyles","className","displayName","Wrapper","forwardRef","props","ref","styles","state","root"],"mappings":"AAAA;;;;;+BAQgBK;;;;;;;iEANO,QAAQ;wBACF,iBAAiB;sBACgC,UAAU;AAIjF,sBAAsBC,OAI5B;IACC,MAAM,EAAEC,SAAS,EAAEC,SAAS,EAAEC,WAAW,EAAE,GAAGH;IAC9C,MAAMI,wBAAgDV,OAAMW,UAAU,CAAC,CAACC,OAAOC;QAC7E;QAEA,MAAMC,SAASP;QACf,MAAMQ,YAAQZ,sBAAAA,EAAiBS,OAAoBC;QAEnDT,gCAAAA,EAAuBW;QAEvBA,MAAMC,IAAI,CAACR,SAAS,OAAGP,oBAAAA,EAAaO,WAAWO,MAAMC,IAAI,CAACR,SAAS,EAAEM,OAAOE,IAAI,EAAEJ,MAAMJ,SAAS;QAEjG,WAAON,yBAAAA,EAAoBa;IAC7B;IACAL,QAAQD,WAAW,GAAGA;IAEtB,OAAOC;AACT"}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@fluentui/react-text",
|
3
|
-
"version": "9.6.
|
3
|
+
"version": "9.6.6",
|
4
4
|
"description": "Text is a typography and styling abstraction component that can be used to ensure the consistency of all text across your application.",
|
5
5
|
"main": "lib-commonjs/index.js",
|
6
6
|
"module": "lib/index.js",
|
@@ -18,18 +18,18 @@
|
|
18
18
|
"@fluentui/scripts-api-extractor": "*"
|
19
19
|
},
|
20
20
|
"dependencies": {
|
21
|
-
"@fluentui/react-shared-contexts": "^9.25.
|
21
|
+
"@fluentui/react-shared-contexts": "^9.25.2",
|
22
22
|
"@fluentui/react-theme": "^9.2.0",
|
23
|
-
"@fluentui/react-utilities": "^9.
|
24
|
-
"@fluentui/react-jsx-runtime": "^9.1
|
23
|
+
"@fluentui/react-utilities": "^9.25.0",
|
24
|
+
"@fluentui/react-jsx-runtime": "^9.2.1",
|
25
25
|
"@griffel/react": "^1.5.22",
|
26
26
|
"@swc/helpers": "^0.5.1"
|
27
27
|
},
|
28
28
|
"peerDependencies": {
|
29
|
-
"@types/react": ">=16.14.0 <
|
30
|
-
"@types/react-dom": ">=16.9.0 <
|
31
|
-
"react": ">=16.14.0 <
|
32
|
-
"react-dom": ">=16.14.0 <
|
29
|
+
"@types/react": ">=16.14.0 <20.0.0",
|
30
|
+
"@types/react-dom": ">=16.9.0 <20.0.0",
|
31
|
+
"react": ">=16.14.0 <20.0.0",
|
32
|
+
"react-dom": ">=16.14.0 <20.0.0"
|
33
33
|
},
|
34
34
|
"beachball": {
|
35
35
|
"disallowedChangeTypes": [
|