@fluentui/react-spinner 9.3.10 → 9.3.11
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.json +58 -1
- package/CHANGELOG.md +18 -2
- package/lib/components/Spinner/Spinner.js.map +1 -1
- package/lib/components/Spinner/renderSpinner.js +9 -3
- package/lib/components/Spinner/renderSpinner.js.map +1 -1
- package/lib/components/Spinner/useSpinner.js +3 -3
- package/lib/components/Spinner/useSpinner.js.map +1 -1
- package/lib/components/Spinner/useSpinnerStyles.styles.js +2 -2
- package/lib/components/Spinner/useSpinnerStyles.styles.js.map +1 -1
- package/lib/contexts/SpinnerContext.js.map +1 -1
- package/lib-commonjs/Spinner.js +2 -2
- package/lib-commonjs/Spinner.js.map +1 -1
- package/lib-commonjs/components/Spinner/DefaultSvg.js +5 -3
- package/lib-commonjs/components/Spinner/DefaultSvg.js.map +1 -1
- package/lib-commonjs/components/Spinner/Spinner.js +9 -7
- package/lib-commonjs/components/Spinner/Spinner.js.map +1 -1
- package/lib-commonjs/components/Spinner/index.js +6 -6
- package/lib-commonjs/components/Spinner/index.js.map +1 -1
- package/lib-commonjs/components/Spinner/renderSpinner.js +15 -7
- package/lib-commonjs/components/Spinner/renderSpinner.js.map +1 -1
- package/lib-commonjs/components/Spinner/useSpinner.js +20 -18
- package/lib-commonjs/components/Spinner/useSpinner.js.map +1 -1
- package/lib-commonjs/components/Spinner/useSpinnerStyles.styles.js +13 -9
- package/lib-commonjs/components/Spinner/useSpinnerStyles.styles.js.map +1 -1
- package/lib-commonjs/contexts/SpinnerContext.js +8 -4
- package/lib-commonjs/contexts/SpinnerContext.js.map +1 -1
- package/lib-commonjs/contexts/index.js +2 -2
- package/lib-commonjs/contexts/index.js.map +1 -1
- package/lib-commonjs/index.js +22 -8
- package/lib-commonjs/index.js.map +1 -1
- package/package.json +11 -11
package/CHANGELOG.json
CHANGED
|
@@ -2,7 +2,64 @@
|
|
|
2
2
|
"name": "@fluentui/react-spinner",
|
|
3
3
|
"entries": [
|
|
4
4
|
{
|
|
5
|
-
"date": "Tue,
|
|
5
|
+
"date": "Tue, 05 Sep 2023 13:23:09 GMT",
|
|
6
|
+
"tag": "@fluentui/react-spinner_v9.3.11",
|
|
7
|
+
"version": "9.3.11",
|
|
8
|
+
"comments": {
|
|
9
|
+
"patch": [
|
|
10
|
+
{
|
|
11
|
+
"author": "ololubek@microsoft.com",
|
|
12
|
+
"package": "@fluentui/react-spinner",
|
|
13
|
+
"commit": "919250fb37df5bf10a22d99a927f15c272522e10",
|
|
14
|
+
"comment": "feat: Update Spinner appearance token to colorBrandStroke2Contrast"
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
"author": "bernardo.sunderhus@gmail.com",
|
|
18
|
+
"package": "@fluentui/react-spinner",
|
|
19
|
+
"commit": "eea6d93a62249ba4fba3347fb291c67ee1a3fb24",
|
|
20
|
+
"comment": "chore: migrate package to use JSX importSource"
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
"author": "bernardo.sunderhus@gmail.com",
|
|
24
|
+
"package": "@fluentui/react-spinner",
|
|
25
|
+
"commit": "b93c2ac22355b6cb6f33dd509c6cd9c21f4fffc8",
|
|
26
|
+
"comment": "bumps @swc/helpers version to 0.5.1"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"author": "beachball",
|
|
30
|
+
"package": "@fluentui/react-spinner",
|
|
31
|
+
"comment": "Bump @fluentui/react-jsx-runtime to v9.0.4",
|
|
32
|
+
"commit": "0bf811dbcaaa6b78743537d142fe4d348b457045"
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"author": "beachball",
|
|
36
|
+
"package": "@fluentui/react-spinner",
|
|
37
|
+
"comment": "Bump @fluentui/react-label to v9.1.31",
|
|
38
|
+
"commit": "0bf811dbcaaa6b78743537d142fe4d348b457045"
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
"author": "beachball",
|
|
42
|
+
"package": "@fluentui/react-spinner",
|
|
43
|
+
"comment": "Bump @fluentui/react-shared-contexts to v9.7.3",
|
|
44
|
+
"commit": "0bf811dbcaaa6b78743537d142fe4d348b457045"
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
"author": "beachball",
|
|
48
|
+
"package": "@fluentui/react-spinner",
|
|
49
|
+
"comment": "Bump @fluentui/react-theme to v9.1.12",
|
|
50
|
+
"commit": "0bf811dbcaaa6b78743537d142fe4d348b457045"
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
"author": "beachball",
|
|
54
|
+
"package": "@fluentui/react-spinner",
|
|
55
|
+
"comment": "Bump @fluentui/react-utilities to v9.13.1",
|
|
56
|
+
"commit": "0bf811dbcaaa6b78743537d142fe4d348b457045"
|
|
57
|
+
}
|
|
58
|
+
]
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
"date": "Tue, 29 Aug 2023 12:57:36 GMT",
|
|
6
63
|
"tag": "@fluentui/react-spinner_v9.3.10",
|
|
7
64
|
"version": "9.3.10",
|
|
8
65
|
"comments": {
|
package/CHANGELOG.md
CHANGED
|
@@ -1,12 +1,28 @@
|
|
|
1
1
|
# Change Log - @fluentui/react-spinner
|
|
2
2
|
|
|
3
|
-
This log was last generated on Tue,
|
|
3
|
+
This log was last generated on Tue, 05 Sep 2023 13:23:09 GMT and should not be manually modified.
|
|
4
4
|
|
|
5
5
|
<!-- Start content -->
|
|
6
6
|
|
|
7
|
+
## [9.3.11](https://github.com/microsoft/fluentui/tree/@fluentui/react-spinner_v9.3.11)
|
|
8
|
+
|
|
9
|
+
Tue, 05 Sep 2023 13:23:09 GMT
|
|
10
|
+
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-spinner_v9.3.10..@fluentui/react-spinner_v9.3.11)
|
|
11
|
+
|
|
12
|
+
### Patches
|
|
13
|
+
|
|
14
|
+
- feat: Update Spinner appearance token to colorBrandStroke2Contrast ([PR #29008](https://github.com/microsoft/fluentui/pull/29008) by ololubek@microsoft.com)
|
|
15
|
+
- chore: migrate package to use JSX importSource ([PR #28959](https://github.com/microsoft/fluentui/pull/28959) by bernardo.sunderhus@gmail.com)
|
|
16
|
+
- bumps @swc/helpers version to 0.5.1 ([PR #28989](https://github.com/microsoft/fluentui/pull/28989) by bernardo.sunderhus@gmail.com)
|
|
17
|
+
- Bump @fluentui/react-jsx-runtime to v9.0.4 ([PR #27840](https://github.com/microsoft/fluentui/pull/27840) by beachball)
|
|
18
|
+
- Bump @fluentui/react-label to v9.1.31 ([PR #27840](https://github.com/microsoft/fluentui/pull/27840) by beachball)
|
|
19
|
+
- Bump @fluentui/react-shared-contexts to v9.7.3 ([PR #27840](https://github.com/microsoft/fluentui/pull/27840) by beachball)
|
|
20
|
+
- Bump @fluentui/react-theme to v9.1.12 ([PR #27840](https://github.com/microsoft/fluentui/pull/27840) by beachball)
|
|
21
|
+
- Bump @fluentui/react-utilities to v9.13.1 ([PR #27840](https://github.com/microsoft/fluentui/pull/27840) by beachball)
|
|
22
|
+
|
|
7
23
|
## [9.3.10](https://github.com/microsoft/fluentui/tree/@fluentui/react-spinner_v9.3.10)
|
|
8
24
|
|
|
9
|
-
Tue, 29 Aug 2023 12:
|
|
25
|
+
Tue, 29 Aug 2023 12:57:36 GMT
|
|
10
26
|
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-spinner_v9.3.9..@fluentui/react-spinner_v9.3.10)
|
|
11
27
|
|
|
12
28
|
### Patches
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["Spinner.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useSpinner_unstable } from './useSpinner';\nimport { renderSpinner_unstable } from './renderSpinner';\nimport { useSpinnerStyles_unstable } from './useSpinnerStyles.styles';\nimport type { SpinnerProps } from './Spinner.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\nimport { useCustomStyleHook_unstable } from '@fluentui/react-shared-contexts';\n\n/**\n * Converged Spinner component for the fluentui repo\n */\nexport const Spinner: ForwardRefComponent<SpinnerProps> = React.forwardRef((props, ref) => {\n const state = useSpinner_unstable(props, ref);\n\n useSpinnerStyles_unstable(state);\n\n useCustomStyleHook_unstable('useSpinnerStyles_unstable')(state);\n\n return renderSpinner_unstable(state);\n});\n\nSpinner.displayName = 'Spinner';\n"],"names":["React","useSpinner_unstable","renderSpinner_unstable","useSpinnerStyles_unstable","useCustomStyleHook_unstable","Spinner","forwardRef","props","ref","state","displayName"],"mappings":"AAAA,YAAYA,WAAW,QAAQ;AAC/B,SAASC,mBAAmB,QAAQ,eAAe;AACnD,SAASC,sBAAsB,QAAQ,kBAAkB;AACzD,SAASC,yBAAyB,QAAQ,4BAA4B;AAGtE,SAASC,2BAA2B,QAAQ,kCAAkC;AAE9E;;CAEC,GACD,OAAO,MAAMC,wBAA6CL,MAAMM,UAAU,CAAC,CAACC,OAAOC
|
|
1
|
+
{"version":3,"sources":["Spinner.tsx"],"sourcesContent":["import * as React from 'react';\nimport { useSpinner_unstable } from './useSpinner';\nimport { renderSpinner_unstable } from './renderSpinner';\nimport { useSpinnerStyles_unstable } from './useSpinnerStyles.styles';\nimport type { SpinnerProps } from './Spinner.types';\nimport type { ForwardRefComponent } from '@fluentui/react-utilities';\nimport { useCustomStyleHook_unstable } from '@fluentui/react-shared-contexts';\n\n/**\n * Converged Spinner component for the fluentui repo\n */\nexport const Spinner: ForwardRefComponent<SpinnerProps> = React.forwardRef((props, ref) => {\n const state = useSpinner_unstable(props, ref);\n\n useSpinnerStyles_unstable(state);\n\n useCustomStyleHook_unstable('useSpinnerStyles_unstable')(state);\n\n return renderSpinner_unstable(state);\n});\n\nSpinner.displayName = 'Spinner';\n"],"names":["React","useSpinner_unstable","renderSpinner_unstable","useSpinnerStyles_unstable","useCustomStyleHook_unstable","Spinner","forwardRef","props","ref","state","displayName"],"mappings":"AAAA,YAAYA,WAAW,QAAQ;AAC/B,SAASC,mBAAmB,QAAQ,eAAe;AACnD,SAASC,sBAAsB,QAAQ,kBAAkB;AACzD,SAASC,yBAAyB,QAAQ,4BAA4B;AAGtE,SAASC,2BAA2B,QAAQ,kCAAkC;AAE9E;;CAEC,GACD,OAAO,MAAMC,wBAA6CL,MAAMM,UAAU,CAAC,CAACC,OAAOC;IACjF,MAAMC,QAAQR,oBAAoBM,OAAOC;IAEzCL,0BAA0BM;IAE1BL,4BAA4B,6BAA6BK;IAEzD,OAAOP,uBAAuBO;AAChC,GAAG;AAEHJ,QAAQK,WAAW,GAAG"}
|
|
@@ -1,9 +1,15 @@
|
|
|
1
|
-
/** @jsxRuntime
|
|
1
|
+
/** @jsxRuntime automatic */ /** @jsxImportSource @fluentui/react-jsx-runtime */ import { jsx as _jsx, jsxs as _jsxs } from "@fluentui/react-jsx-runtime/jsx-runtime";
|
|
2
2
|
import { assertSlots } from '@fluentui/react-utilities';
|
|
3
3
|
/**
|
|
4
4
|
* Render the final JSX of Spinner
|
|
5
5
|
*/ export const renderSpinner_unstable = (state)=>{
|
|
6
6
|
assertSlots(state);
|
|
7
|
-
const { labelPosition
|
|
8
|
-
return /*#__PURE__*/
|
|
7
|
+
const { labelPosition, shouldRenderSpinner } = state;
|
|
8
|
+
return /*#__PURE__*/ _jsxs(state.root, {
|
|
9
|
+
children: [
|
|
10
|
+
state.label && shouldRenderSpinner && (labelPosition === 'above' || labelPosition === 'before') && /*#__PURE__*/ _jsx(state.label, {}),
|
|
11
|
+
state.spinner && shouldRenderSpinner && /*#__PURE__*/ _jsx(state.spinner, {}),
|
|
12
|
+
state.label && shouldRenderSpinner && (labelPosition === 'below' || labelPosition === 'after') && /*#__PURE__*/ _jsx(state.label, {})
|
|
13
|
+
]
|
|
14
|
+
});
|
|
9
15
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["renderSpinner.tsx"],"sourcesContent":["/** @jsxRuntime
|
|
1
|
+
{"version":3,"sources":["renderSpinner.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { assertSlots } from '@fluentui/react-utilities';\nimport type { SpinnerState, SpinnerSlots } from './Spinner.types';\n\n/**\n * Render the final JSX of Spinner\n */\nexport const renderSpinner_unstable = (state: SpinnerState) => {\n assertSlots<SpinnerSlots>(state);\n const { labelPosition, shouldRenderSpinner } = state;\n return (\n <state.root>\n {state.label && shouldRenderSpinner && (labelPosition === 'above' || labelPosition === 'before') && (\n <state.label />\n )}\n\n {state.spinner && shouldRenderSpinner && <state.spinner />}\n {state.label && shouldRenderSpinner && (labelPosition === 'below' || labelPosition === 'after') && (\n <state.label />\n )}\n </state.root>\n );\n};\n"],"names":["assertSlots","renderSpinner_unstable","state","labelPosition","shouldRenderSpinner","root","label","spinner"],"mappings":"AAAA,0BAA0B,GAC1B,iDAAiD;AAEjD,SAASA,WAAW,QAAQ,4BAA4B;AAGxD;;CAEC,GACD,OAAO,MAAMC,yBAAyB,CAACC;IACrCF,YAA0BE;IAC1B,MAAM,EAAEC,aAAa,EAAEC,mBAAmB,EAAE,GAAGF;IAC/C,qBACE,MAACA,MAAMG,IAAI;;YACRH,MAAMI,KAAK,IAAIF,uBAAwBD,CAAAA,kBAAkB,WAAWA,kBAAkB,QAAO,mBAC5F,KAACD,MAAMI,KAAK;YAGbJ,MAAMK,OAAO,IAAIH,qCAAuB,KAACF,MAAMK,OAAO;YACtDL,MAAMI,KAAK,IAAIF,uBAAwBD,CAAAA,kBAAkB,WAAWA,kBAAkB,OAAM,mBAC3F,KAACD,MAAMI,KAAK;;;AAIpB,EAAE"}
|
|
@@ -13,10 +13,10 @@ import { useSpinnerContext } from '../../contexts/SpinnerContext';
|
|
|
13
13
|
* @param ref - reference to root HTMLElement of Spinner
|
|
14
14
|
*/ export const useSpinner_unstable = (props, ref)=>{
|
|
15
15
|
// Props
|
|
16
|
-
const { size: contextSize
|
|
17
|
-
const { appearance ='primary'
|
|
16
|
+
const { size: contextSize } = useSpinnerContext();
|
|
17
|
+
const { appearance = 'primary', labelPosition = 'after', size = contextSize !== null && contextSize !== void 0 ? contextSize : 'medium', delay = 0 } = props;
|
|
18
18
|
const baseId = useId('spinner');
|
|
19
|
-
const { role ='progressbar'
|
|
19
|
+
const { role = 'progressbar', tabIndex, ...rest } = props;
|
|
20
20
|
const nativeRoot = slot.always(getNativeElementProps('div', {
|
|
21
21
|
ref,
|
|
22
22
|
role,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["useSpinner.tsx"],"sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps, useId, useTimeout, slot } from '@fluentui/react-utilities';\nimport type { SpinnerProps, SpinnerState } from './Spinner.types';\nimport { Label } from '@fluentui/react-label';\nimport { DefaultSvg } from './DefaultSvg';\nimport { useSpinnerContext } from '../../contexts/SpinnerContext';\n\n/**\n * Create the state required to render Spinner.\n *\n * The returned state can be modified with hooks such as useSpinnerStyles_unstable,\n * before being passed to renderSpinner_unstable.\n *\n * @param props - props from this instance of Spinner\n * @param ref - reference to root HTMLElement of Spinner\n */\nexport const useSpinner_unstable = (props: SpinnerProps, ref: React.Ref<HTMLElement>): SpinnerState => {\n // Props\n const { size: contextSize } = useSpinnerContext();\n const { appearance = 'primary', labelPosition = 'after', size = contextSize ?? 'medium', delay = 0 } = props;\n const baseId = useId('spinner');\n\n const { role = 'progressbar', tabIndex, ...rest } = props;\n const nativeRoot = slot.always(getNativeElementProps('div', { ref, role, ...rest }, ['size']), {\n elementType: 'div',\n });\n const [isVisible, setIsVisible] = React.useState(true);\n const [setDelayTimeout, clearDelayTimeout] = useTimeout();\n React.useEffect(() => {\n if (delay <= 0) {\n return;\n }\n setIsVisible(false);\n setDelayTimeout(() => {\n setIsVisible(true);\n }, delay);\n return () => {\n clearDelayTimeout();\n };\n }, [setDelayTimeout, clearDelayTimeout, delay]);\n const labelShorthand = slot.optional(props.label, {\n defaultProps: { id: baseId },\n renderByDefault: false,\n elementType: Label,\n });\n const spinnerShortHand = slot.optional(props.spinner, {\n renderByDefault: true,\n defaultProps: { children: <DefaultSvg />, tabIndex },\n elementType: 'span',\n });\n if (labelShorthand && nativeRoot && !nativeRoot['aria-labelledby']) {\n nativeRoot['aria-labelledby'] = labelShorthand.id;\n }\n const state: SpinnerState = {\n appearance,\n delay,\n labelPosition,\n size,\n shouldRenderSpinner: isVisible,\n components: { root: 'div', spinner: 'span', label: Label },\n root: nativeRoot,\n spinner: spinnerShortHand,\n label: labelShorthand,\n };\n return state;\n};\n"],"names":["React","getNativeElementProps","useId","useTimeout","slot","Label","DefaultSvg","useSpinnerContext","useSpinner_unstable","props","ref","size","contextSize","appearance","labelPosition","delay","baseId","role","tabIndex","rest","nativeRoot","always","elementType","isVisible","setIsVisible","useState","setDelayTimeout","clearDelayTimeout","useEffect","labelShorthand","optional","label","defaultProps","id","renderByDefault","spinnerShortHand","spinner","children","state","shouldRenderSpinner","components","root"],"mappings":"AAAA,YAAYA,WAAW,QAAQ;AAC/B,SAASC,qBAAqB,EAAEC,KAAK,EAAEC,UAAU,EAAEC,IAAI,QAAQ,4BAA4B;AAE3F,SAASC,KAAK,QAAQ,wBAAwB;AAC9C,SAASC,UAAU,QAAQ,eAAe;AAC1C,SAASC,iBAAiB,QAAQ,gCAAgC;AAElE;;;;;;;;CAQC,GACD,OAAO,MAAMC,sBAAsB,CAACC,OAAqBC
|
|
1
|
+
{"version":3,"sources":["useSpinner.tsx"],"sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps, useId, useTimeout, slot } from '@fluentui/react-utilities';\nimport type { SpinnerProps, SpinnerState } from './Spinner.types';\nimport { Label } from '@fluentui/react-label';\nimport { DefaultSvg } from './DefaultSvg';\nimport { useSpinnerContext } from '../../contexts/SpinnerContext';\n\n/**\n * Create the state required to render Spinner.\n *\n * The returned state can be modified with hooks such as useSpinnerStyles_unstable,\n * before being passed to renderSpinner_unstable.\n *\n * @param props - props from this instance of Spinner\n * @param ref - reference to root HTMLElement of Spinner\n */\nexport const useSpinner_unstable = (props: SpinnerProps, ref: React.Ref<HTMLElement>): SpinnerState => {\n // Props\n const { size: contextSize } = useSpinnerContext();\n const { appearance = 'primary', labelPosition = 'after', size = contextSize ?? 'medium', delay = 0 } = props;\n const baseId = useId('spinner');\n\n const { role = 'progressbar', tabIndex, ...rest } = props;\n const nativeRoot = slot.always(getNativeElementProps('div', { ref, role, ...rest }, ['size']), {\n elementType: 'div',\n });\n const [isVisible, setIsVisible] = React.useState(true);\n const [setDelayTimeout, clearDelayTimeout] = useTimeout();\n React.useEffect(() => {\n if (delay <= 0) {\n return;\n }\n setIsVisible(false);\n setDelayTimeout(() => {\n setIsVisible(true);\n }, delay);\n return () => {\n clearDelayTimeout();\n };\n }, [setDelayTimeout, clearDelayTimeout, delay]);\n const labelShorthand = slot.optional(props.label, {\n defaultProps: { id: baseId },\n renderByDefault: false,\n elementType: Label,\n });\n const spinnerShortHand = slot.optional(props.spinner, {\n renderByDefault: true,\n defaultProps: { children: <DefaultSvg />, tabIndex },\n elementType: 'span',\n });\n if (labelShorthand && nativeRoot && !nativeRoot['aria-labelledby']) {\n nativeRoot['aria-labelledby'] = labelShorthand.id;\n }\n const state: SpinnerState = {\n appearance,\n delay,\n labelPosition,\n size,\n shouldRenderSpinner: isVisible,\n components: { root: 'div', spinner: 'span', label: Label },\n root: nativeRoot,\n spinner: spinnerShortHand,\n label: labelShorthand,\n };\n return state;\n};\n"],"names":["React","getNativeElementProps","useId","useTimeout","slot","Label","DefaultSvg","useSpinnerContext","useSpinner_unstable","props","ref","size","contextSize","appearance","labelPosition","delay","baseId","role","tabIndex","rest","nativeRoot","always","elementType","isVisible","setIsVisible","useState","setDelayTimeout","clearDelayTimeout","useEffect","labelShorthand","optional","label","defaultProps","id","renderByDefault","spinnerShortHand","spinner","children","state","shouldRenderSpinner","components","root"],"mappings":"AAAA,YAAYA,WAAW,QAAQ;AAC/B,SAASC,qBAAqB,EAAEC,KAAK,EAAEC,UAAU,EAAEC,IAAI,QAAQ,4BAA4B;AAE3F,SAASC,KAAK,QAAQ,wBAAwB;AAC9C,SAAS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D;IACA,MAAMK,QAAsB;QAC1BzB;QACAE;QACAD;QACAH;QACA4B,qBAAqBhB;QACrBiB,YAAY;YAAEC,MAAM;YAAOL,SAAS;YAAQL,OAAO1B;QAAM;QACzDoC,MAAMrB;QACNgB,SAASD;QACTJ,OAAOF;IACT;IACA,OAAOS;AACT,EAAE"}
|
|
@@ -166,11 +166,11 @@ const useTrackStyles = /*#__PURE__*/__styles({
|
|
|
166
166
|
Bo2mdfu: "f1eseayc",
|
|
167
167
|
E10nrc: "folzdkc",
|
|
168
168
|
Bwl7w15: "fhlfkde",
|
|
169
|
-
Bksq7rz: "
|
|
169
|
+
Bksq7rz: "f13qeqtg",
|
|
170
170
|
y14cdu: "flglbw1"
|
|
171
171
|
}
|
|
172
172
|
}, {
|
|
173
|
-
d: [".f1jvpmnu>svg>circle.fui-Spinner__Tail{stroke:var(--colorNeutralStrokeOnBrand2);}", ".fq8a5sv>svg>circle.fui-Spinner__Tail{animation-name:f1v1ql0f;}", ".f1b4lwqj>svg>circle.fui-Spinner__Tail{animation-duration:1.5s;}", ".f1najlst>svg>circle.fui-Spinner__Tail{animation-iteration-count:infinite;}", ".fjxod4>svg>circle.fui-Spinner__Tail{animation-timing-function:var(--curveEasyEase);}", ".fu3xdw0>svg>circle.fui-Spinner__Tail{stroke-linecap:round;}", ".f1ttdh6v>svg>circle.fui-Spinner__Tail{transform:rotate(-90deg);}", ".fmyjox0>svg>circle.fui-Spinner__Tail{transform:rotate(90deg);}", ".f1eseayc>svg>circle.fui-Spinner__Tail{transform-origin:50% 50%;}", ".f1esql28>svg>circle.fui-Spinner__Track{stroke:rgba(255, 255, 255, 0.2);}", ".f11ditju>svg>circle.fui-Spinner__Tail{stroke:var(--colorBrandStroke1);}", ".
|
|
173
|
+
d: [".f1jvpmnu>svg>circle.fui-Spinner__Tail{stroke:var(--colorNeutralStrokeOnBrand2);}", ".fq8a5sv>svg>circle.fui-Spinner__Tail{animation-name:f1v1ql0f;}", ".f1b4lwqj>svg>circle.fui-Spinner__Tail{animation-duration:1.5s;}", ".f1najlst>svg>circle.fui-Spinner__Tail{animation-iteration-count:infinite;}", ".fjxod4>svg>circle.fui-Spinner__Tail{animation-timing-function:var(--curveEasyEase);}", ".fu3xdw0>svg>circle.fui-Spinner__Tail{stroke-linecap:round;}", ".f1ttdh6v>svg>circle.fui-Spinner__Tail{transform:rotate(-90deg);}", ".fmyjox0>svg>circle.fui-Spinner__Tail{transform:rotate(90deg);}", ".f1eseayc>svg>circle.fui-Spinner__Tail{transform-origin:50% 50%;}", ".f1esql28>svg>circle.fui-Spinner__Track{stroke:rgba(255, 255, 255, 0.2);}", ".f11ditju>svg>circle.fui-Spinner__Tail{stroke:var(--colorBrandStroke1);}", ".f13qeqtg>svg>circle.fui-Spinner__Track{stroke:var(--colorBrandStroke2Contrast);}"],
|
|
174
174
|
k: ["@keyframes f1v1ql0f{0%{stroke-dasharray:1,150;stroke-dashoffset:0;}50%{stroke-dasharray:90,150;stroke-dashoffset:-35;}100%{stroke-dasharray:90,150;stroke-dashoffset:-124;}}"],
|
|
175
175
|
m: [["@media screen and (prefers-reduced-motion: reduce){.folzdkc>svg>circle.fui-Spinner__Tail{animation-duration:0.01ms;}}", {
|
|
176
176
|
m: "screen and (prefers-reduced-motion: reduce)"
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["__styles","mergeClasses","shorthands","tokens","typographyStyles","spinnerClassNames","root","spinner","label","rValues","extraTiny","tiny","extraSmall","small","medium","large","extraLarge","huge","spinnnerSizes","spinnerAnimation","container","animationDuration","animationIterationCount","animationTimingFunction","backgroundColor","useRootStyles","mc9l5x","Bt984gj","Brf1p80","Bg96gwp","i8kkvl","Belr9w4","horizontal","Beiy3e4","vertical","d","useLoaderStyles","spinnerSVG","B3aqqti","Brovlpu","Bxa1mx5","Bwaue66","fyp1ls","ag6ruv","osj692","aq5vjd","tlu9e1","J3u96z","d32isg","Bsvqbuc","b3s3i5","Bah9ito","ut6tcf","B7p06xz","B807ibg","f","k","m","useTrackStyles","inverted","gwg7kz","Bvrehnu","Bidp6o","cq3kgi","Btwiser","B8001xd","Bdordwa","Bo2mdfu","E10nrc","Bwl7w15","Bksq7rz","primary","B8k2rxp","y14cdu","useLabelStyles","sj55zd","Bahqtrf","Be2twd7","Bhrd7zp","useSpinnerStyles_unstable","state","labelPosition","size","appearance","rootStyles","spinnerStyles","labelStyles","trackStyles","className"],"sources":["useSpinnerStyles.styles.js"],"sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport { tokens, typographyStyles } from '@fluentui/react-theme';\nexport const spinnerClassNames = {\n root: 'fui-Spinner',\n spinner: 'fui-Spinner__spinner',\n label: 'fui-Spinner__label'\n};\n/*\n * TODO: Update with proper tokens when added\n * Radii for the Spinner circles\n */ const rValues = {\n extraTiny: '7px',\n tiny: '9px',\n extraSmall: '11px',\n small: '13px',\n medium: '14.5px',\n large: '16.5px',\n extraLarge: '18.5px',\n huge: '20px'\n};\n/*\n * TODO: Update with proper tokens when added\n * Sizes for the Spinner\n */ const spinnnerSizes = {\n extraTiny: '16px',\n tiny: '20px',\n extraSmall: '24px',\n small: '28px',\n medium: '32px',\n large: '36px',\n extraLarge: '40px',\n huge: '44px'\n};\n/*\n * TODO: Update with proper tokens when added\n * Animation for Spinner\n */ const spinnerAnimation = {\n container: {\n animationDuration: '3s',\n animationIterationCount: 'infinite',\n animationTimingFunction: 'linear',\n backgroundColor: 'transparent'\n }\n};\n/**\n * Styles for the root slot\n */ const useRootStyles = makeStyles({\n root: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n lineHeight: '0',\n ...shorthands.gap('8px')\n },\n horizontal: {\n flexDirection: 'row'\n },\n vertical: {\n flexDirection: 'column'\n }\n});\nconst useLoaderStyles = makeStyles({\n // global SVG class\n spinnerSVG: {\n ':focus': {\n ...shorthands.outline('3px', 'solid', 'transparent')\n },\n ['& > svg']: {\n animationName: {\n '0%': {\n transform: 'rotate(0deg)'\n },\n '100%': {\n transform: 'rotate(360deg)'\n }\n },\n ...spinnerAnimation.container,\n '@media screen and (prefers-reduced-motion: reduce)': {\n animationDuration: '0.01ms',\n animationIterationCount: '1'\n }\n },\n ['& > svg > circle']: {\n cx: '50%',\n cy: '50%',\n fill: 'none'\n }\n },\n 'extra-tiny': {\n ['& > svg']: {\n height: spinnnerSizes.extraTiny,\n width: spinnnerSizes.extraTiny\n },\n ['& > svg > circle']: {\n strokeWidth: tokens.strokeWidthThick,\n r: rValues.extraTiny\n }\n },\n tiny: {\n ['& > svg']: {\n height: spinnnerSizes.tiny,\n width: spinnnerSizes.tiny\n },\n ['& > svg > circle']: {\n strokeWidth: tokens.strokeWidthThick,\n r: rValues.tiny\n }\n },\n 'extra-small': {\n ['& > svg']: {\n height: spinnnerSizes.extraSmall,\n width: spinnnerSizes.extraSmall\n },\n ['& > svg > circle']: {\n strokeWidth: tokens.strokeWidthThick,\n r: rValues.extraSmall\n }\n },\n small: {\n ['& > svg']: {\n height: spinnnerSizes.small,\n width: spinnnerSizes.small\n },\n ['& > svg > circle']: {\n strokeWidth: tokens.strokeWidthThick,\n r: rValues.small\n }\n },\n medium: {\n ['& > svg']: {\n height: spinnnerSizes.medium,\n width: spinnnerSizes.medium\n },\n ['& > svg > circle']: {\n strokeWidth: tokens.strokeWidthThicker,\n r: rValues.medium\n }\n },\n large: {\n ['& > svg']: {\n height: spinnnerSizes.large,\n width: spinnnerSizes.large\n },\n ['& > svg > circle']: {\n strokeWidth: tokens.strokeWidthThicker,\n r: rValues.large\n }\n },\n 'extra-large': {\n ['& > svg']: {\n height: spinnnerSizes.extraLarge,\n width: spinnnerSizes.extraLarge\n },\n ['& > svg > circle']: {\n strokeWidth: tokens.strokeWidthThicker,\n r: rValues.extraLarge\n }\n },\n huge: {\n ['& > svg']: {\n height: spinnnerSizes.huge,\n width: spinnnerSizes.huge\n },\n ['& > svg > circle']: {\n strokeWidth: tokens.strokeWidthThickest,\n r: rValues.huge\n }\n }\n});\nconst useTrackStyles = makeStyles({\n inverted: {\n ['& > svg > circle.fui-Spinner__Tail']: {\n stroke: tokens.colorNeutralStrokeOnBrand2,\n animationName: {\n '0%': {\n strokeDasharray: '1,150',\n strokeDashoffset: '0'\n },\n '50%': {\n strokeDasharray: '90,150',\n strokeDashoffset: '-35'\n },\n '100%': {\n strokeDasharray: '90,150',\n strokeDashoffset: '-124'\n }\n },\n animationDuration: '1.5s',\n animationIterationCount: 'infinite',\n animationTimingFunction: tokens.curveEasyEase,\n strokeLinecap: 'round',\n transform: 'rotate(-90deg)',\n transformOrigin: '50% 50%',\n '@media screen and (prefers-reduced-motion: reduce)': {\n animationDuration: '0.01ms',\n animationIterationCount: '1'\n }\n },\n ['& > svg > circle.fui-Spinner__Track']: {\n stroke: 'rgba(255, 255, 255, 0.2)'\n }\n },\n primary: {\n ['& > svg > circle.fui-Spinner__Tail']: {\n stroke: tokens.colorBrandStroke1,\n '@media screen and (forced-colors: active)': {\n stroke: tokens.colorNeutralStrokeOnBrand2\n },\n animationName: {\n '0%': {\n strokeDasharray: '1,150',\n strokeDashoffset: '0'\n },\n '50%': {\n strokeDasharray: '90,150',\n strokeDashoffset: '-35'\n },\n '100%': {\n strokeDasharray: '90,150',\n strokeDashoffset: '-124'\n }\n },\n animationDuration: '1.5s',\n animationIterationCount: 'infinite',\n animationTimingFunction: tokens.curveEasyEase,\n strokeLinecap: 'round',\n transform: 'rotate(-90deg)',\n transformOrigin: '50% 50%',\n '@media screen and (prefers-reduced-motion: reduce)': {\n animationDuration: '0.01ms',\n animationIterationCount: '1'\n }\n },\n ['& > svg > circle.fui-Spinner__Track']: {\n stroke: tokens.colorBrandStroke2,\n '@media screen and (forced-colors: active)': {\n stroke: tokens.colorNeutralBackgroundInverted\n }\n }\n }\n});\nconst useLabelStyles = makeStyles({\n // style for label\n inverted: {\n color: 'rgba(255, 255, 255, 1)'\n },\n primary: {},\n 'extra-tiny': {\n ...typographyStyles.body1\n },\n tiny: {\n ...typographyStyles.body1\n },\n 'extra-small': {\n ...typographyStyles.body1\n },\n small: {\n ...typographyStyles.body1\n },\n medium: {\n ...typographyStyles.subtitle2\n },\n large: {\n ...typographyStyles.subtitle2\n },\n 'extra-large': {\n ...typographyStyles.subtitle2\n },\n huge: {\n ...typographyStyles.subtitle1\n }\n});\n/**\n * Apply styling to the Spinner slots based on the state\n */ export const useSpinnerStyles_unstable = (state)=>{\n const { labelPosition , size , appearance ='primary' } = state;\n const rootStyles = useRootStyles();\n const spinnerStyles = useLoaderStyles();\n const labelStyles = useLabelStyles();\n const trackStyles = useTrackStyles();\n state.root.className = mergeClasses(spinnerClassNames.root, rootStyles.root, (labelPosition === 'above' || labelPosition === 'below') && rootStyles.vertical, (labelPosition === 'before' || labelPosition === 'after') && rootStyles.horizontal, state.root.className);\n if (state.spinner) {\n state.spinner.className = mergeClasses(spinnerClassNames.spinner, spinnerStyles.spinnerSVG, spinnerStyles[size], trackStyles[appearance], state.spinner.className);\n }\n if (state.label) {\n state.label.className = mergeClasses(spinnerClassNames.label, labelStyles[size], labelStyles[appearance], state.label.className);\n }\n return state;\n};\n"],"mappings":"AAAA,SAAAA,QAAA,EAAqBC,YAAY,EAAEC,UAAU,QAAQ,gBAAgB;AACrE,SAASC,MAAM,EAAEC,gBAAgB,QAAQ,uBAAuB;AAChE,OAAO,MAAMC,iBAAiB,GAAG;EAC7BC,IAAI,EAAE,aAAa;EACnBC,OAAO,EAAE,sBAAsB;EAC/BC,KAAK,EAAE;AACX,CAAC;AACD;AACA;AACA;AACA;AAAI,MAAMC,OAAO,GAAG;EAChBC,SAAS,EAAE,KAAK;EAChBC,IAAI,EAAE,KAAK;EACXC,UAAU,EAAE,MAAM;EAClBC,KAAK,EAAE,MAAM;EACbC,MAAM,EAAE,QAAQ;EAChBC,KAAK,EAAE,QAAQ;EACfC,UAAU,EAAE,QAAQ;EACpBC,IAAI,EAAE;AACV,CAAC;AACD;AACA;AACA;AACA;AAAI,MAAMC,aAAa,GAAG;EACtBR,SAAS,EAAE,MAAM;EACjBC,I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AAK,CAACxE,KAAK,EAAE;IACbwE,KAAK,CAACxE,KAAK,CAACgF,SAAS,GAAGvF,YAAY,CAACI,iBAAiB,CAACG,KAAK,EAAE8E,WAAW,CAACJ,IAAI,CAAC,EAAEI,WAAW,CAACH,UAAU,CAAC,EAAEH,KAAK,CAACxE,KAAK,CAACgF,SAAS,CAAC;EACpI;EACA,OAAOR,KAAK;AAChB,CAAC"}
|
|
1
|
+
{"version":3,"names":["__styles","mergeClasses","shorthands","tokens","typographyStyles","spinnerClassNames","root","spinner","label","rValues","extraTiny","tiny","extraSmall","small","medium","large","extraLarge","huge","spinnnerSizes","spinnerAnimation","container","animationDuration","animationIterationCount","animationTimingFunction","backgroundColor","useRootStyles","mc9l5x","Bt984gj","Brf1p80","Bg96gwp","i8kkvl","Belr9w4","horizontal","Beiy3e4","vertical","d","useLoaderStyles","spinnerSVG","B3aqqti","Brovlpu","Bxa1mx5","Bwaue66","fyp1ls","ag6ruv","osj692","aq5vjd","tlu9e1","J3u96z","d32isg","Bsvqbuc","b3s3i5","Bah9ito","ut6tcf","B7p06xz","B807ibg","f","k","m","useTrackStyles","inverted","gwg7kz","Bvrehnu","Bidp6o","cq3kgi","Btwiser","B8001xd","Bdordwa","Bo2mdfu","E10nrc","Bwl7w15","Bksq7rz","primary","B8k2rxp","y14cdu","useLabelStyles","sj55zd","Bahqtrf","Be2twd7","Bhrd7zp","useSpinnerStyles_unstable","state","labelPosition","size","appearance","rootStyles","spinnerStyles","labelStyles","trackStyles","className"],"sources":["useSpinnerStyles.styles.js"],"sourcesContent":["import { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport { tokens, typographyStyles } from '@fluentui/react-theme';\nexport const spinnerClassNames = {\n root: 'fui-Spinner',\n spinner: 'fui-Spinner__spinner',\n label: 'fui-Spinner__label'\n};\n/*\n * TODO: Update with proper tokens when added\n * Radii for the Spinner circles\n */ const rValues = {\n extraTiny: '7px',\n tiny: '9px',\n extraSmall: '11px',\n small: '13px',\n medium: '14.5px',\n large: '16.5px',\n extraLarge: '18.5px',\n huge: '20px'\n};\n/*\n * TODO: Update with proper tokens when added\n * Sizes for the Spinner\n */ const spinnnerSizes = {\n extraTiny: '16px',\n tiny: '20px',\n extraSmall: '24px',\n small: '28px',\n medium: '32px',\n large: '36px',\n extraLarge: '40px',\n huge: '44px'\n};\n/*\n * TODO: Update with proper tokens when added\n * Animation for Spinner\n */ const spinnerAnimation = {\n container: {\n animationDuration: '3s',\n animationIterationCount: 'infinite',\n animationTimingFunction: 'linear',\n backgroundColor: 'transparent'\n }\n};\n/**\n * Styles for the root slot\n */ const useRootStyles = makeStyles({\n root: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n lineHeight: '0',\n ...shorthands.gap('8px')\n },\n horizontal: {\n flexDirection: 'row'\n },\n vertical: {\n flexDirection: 'column'\n }\n});\nconst useLoaderStyles = makeStyles({\n // global SVG class\n spinnerSVG: {\n ':focus': {\n ...shorthands.outline('3px', 'solid', 'transparent')\n },\n ['& > svg']: {\n animationName: {\n '0%': {\n transform: 'rotate(0deg)'\n },\n '100%': {\n transform: 'rotate(360deg)'\n }\n },\n ...spinnerAnimation.container,\n '@media screen and (prefers-reduced-motion: reduce)': {\n animationDuration: '0.01ms',\n animationIterationCount: '1'\n }\n },\n ['& > svg > circle']: {\n cx: '50%',\n cy: '50%',\n fill: 'none'\n }\n },\n 'extra-tiny': {\n ['& > svg']: {\n height: spinnnerSizes.extraTiny,\n width: spinnnerSizes.extraTiny\n },\n ['& > svg > circle']: {\n strokeWidth: tokens.strokeWidthThick,\n r: rValues.extraTiny\n }\n },\n tiny: {\n ['& > svg']: {\n height: spinnnerSizes.tiny,\n width: spinnnerSizes.tiny\n },\n ['& > svg > circle']: {\n strokeWidth: tokens.strokeWidthThick,\n r: rValues.tiny\n }\n },\n 'extra-small': {\n ['& > svg']: {\n height: spinnnerSizes.extraSmall,\n width: spinnnerSizes.extraSmall\n },\n ['& > svg > circle']: {\n strokeWidth: tokens.strokeWidthThick,\n r: rValues.extraSmall\n }\n },\n small: {\n ['& > svg']: {\n height: spinnnerSizes.small,\n width: spinnnerSizes.small\n },\n ['& > svg > circle']: {\n strokeWidth: tokens.strokeWidthThick,\n r: rValues.small\n }\n },\n medium: {\n ['& > svg']: {\n height: spinnnerSizes.medium,\n width: spinnnerSizes.medium\n },\n ['& > svg > circle']: {\n strokeWidth: tokens.strokeWidthThicker,\n r: rValues.medium\n }\n },\n large: {\n ['& > svg']: {\n height: spinnnerSizes.large,\n width: spinnnerSizes.large\n },\n ['& > svg > circle']: {\n strokeWidth: tokens.strokeWidthThicker,\n r: rValues.large\n }\n },\n 'extra-large': {\n ['& > svg']: {\n height: spinnnerSizes.extraLarge,\n width: spinnnerSizes.extraLarge\n },\n ['& > svg > circle']: {\n strokeWidth: tokens.strokeWidthThicker,\n r: rValues.extraLarge\n }\n },\n huge: {\n ['& > svg']: {\n height: spinnnerSizes.huge,\n width: spinnnerSizes.huge\n },\n ['& > svg > circle']: {\n strokeWidth: tokens.strokeWidthThickest,\n r: rValues.huge\n }\n }\n});\nconst useTrackStyles = makeStyles({\n inverted: {\n ['& > svg > circle.fui-Spinner__Tail']: {\n stroke: tokens.colorNeutralStrokeOnBrand2,\n animationName: {\n '0%': {\n strokeDasharray: '1,150',\n strokeDashoffset: '0'\n },\n '50%': {\n strokeDasharray: '90,150',\n strokeDashoffset: '-35'\n },\n '100%': {\n strokeDasharray: '90,150',\n strokeDashoffset: '-124'\n }\n },\n animationDuration: '1.5s',\n animationIterationCount: 'infinite',\n animationTimingFunction: tokens.curveEasyEase,\n strokeLinecap: 'round',\n transform: 'rotate(-90deg)',\n transformOrigin: '50% 50%',\n '@media screen and (prefers-reduced-motion: reduce)': {\n animationDuration: '0.01ms',\n animationIterationCount: '1'\n }\n },\n ['& > svg > circle.fui-Spinner__Track']: {\n stroke: 'rgba(255, 255, 255, 0.2)'\n }\n },\n primary: {\n ['& > svg > circle.fui-Spinner__Tail']: {\n stroke: tokens.colorBrandStroke1,\n '@media screen and (forced-colors: active)': {\n stroke: tokens.colorNeutralStrokeOnBrand2\n },\n animationName: {\n '0%': {\n strokeDasharray: '1,150',\n strokeDashoffset: '0'\n },\n '50%': {\n strokeDasharray: '90,150',\n strokeDashoffset: '-35'\n },\n '100%': {\n strokeDasharray: '90,150',\n strokeDashoffset: '-124'\n }\n },\n animationDuration: '1.5s',\n animationIterationCount: 'infinite',\n animationTimingFunction: tokens.curveEasyEase,\n strokeLinecap: 'round',\n transform: 'rotate(-90deg)',\n transformOrigin: '50% 50%',\n '@media screen and (prefers-reduced-motion: reduce)': {\n animationDuration: '0.01ms',\n animationIterationCount: '1'\n }\n },\n ['& > svg > circle.fui-Spinner__Track']: {\n stroke: tokens.colorBrandStroke2Contrast,\n '@media screen and (forced-colors: active)': {\n stroke: tokens.colorNeutralBackgroundInverted\n }\n }\n }\n});\nconst useLabelStyles = makeStyles({\n // style for label\n inverted: {\n color: 'rgba(255, 255, 255, 1)'\n },\n primary: {},\n 'extra-tiny': {\n ...typographyStyles.body1\n },\n tiny: {\n ...typographyStyles.body1\n },\n 'extra-small': {\n ...typographyStyles.body1\n },\n small: {\n ...typographyStyles.body1\n },\n medium: {\n ...typographyStyles.subtitle2\n },\n large: {\n ...typographyStyles.subtitle2\n },\n 'extra-large': {\n ...typographyStyles.subtitle2\n },\n huge: {\n ...typographyStyles.subtitle1\n }\n});\n/**\n * Apply styling to the Spinner slots based on the state\n */ export const useSpinnerStyles_unstable = (state)=>{\n const { labelPosition, size, appearance = 'primary' } = state;\n const rootStyles = useRootStyles();\n const spinnerStyles = useLoaderStyles();\n const labelStyles = useLabelStyles();\n const trackStyles = useTrackStyles();\n state.root.className = mergeClasses(spinnerClassNames.root, rootStyles.root, (labelPosition === 'above' || labelPosition === 'below') && rootStyles.vertical, (labelPosition === 'before' || labelPosition === 'after') && rootStyles.horizontal, state.root.className);\n if (state.spinner) {\n state.spinner.className = mergeClasses(spinnerClassNames.spinner, spinnerStyles.spinnerSVG, spinnerStyles[size], trackStyles[appearance], state.spinner.className);\n }\n if (state.label) {\n state.label.className = mergeClasses(spinnerClassNames.label, labelStyles[size], labelStyles[appearance], state.label.className);\n }\n return state;\n};\n"],"mappings":"AAAA,SAAAA,QAAA,EAAqBC,YAAY,EAAEC,UAAU,QAAQ,gBAAgB;AACrE,SAASC,MAAM,EAAEC,gBAAgB,QAAQ,uBAAuB;AAChE,OAAO,MAAMC,iBAAiB,GAAG;EAC7BC,IAAI,EAAE,aAAa;EACnBC,OAAO,EAAE,sBAAsB;EAC/BC,KAAK,EAAE;AACX,CAAC;AACD;AACA;AACA;AACA;AAAI,MAAMC,OAAO,GAAG;EAChBC,SAAS,EAAE,KAAK;EAChBC,IAAI,EAAE,KAAK;EACXC,UAAU,EAAE,MAAM;EAClBC,KAAK,EAAE,MAAM;EACbC,MAAM,EAAE,QAAQ;EAChBC,KAAK,EAAE,QAAQ;EACfC,UAAU,EAAE,QAAQ;EACpBC,IAAI,EAAE;AACV,CAAC;AACD;AACA;AACA;AACA;AAAI,MAAMC,aAAa,GAAG;EACtBR,SAAS,EAAE,MAAM;EACjBC,IAAI,EAAE,MAAM;EACZC,UAAU,EAAE,MAAM;EAClBC,KAAK,EAAE,MAAM;EACbC,MAAM,EAAE,MAAM;EACdC,KAAK,EAAE,MAAM;EACbC,UAAU,EAAE,MAAM;EAClBC,IAAI,EAAE;AACV,CAAC;AACD;AACA;AACA;AACA;AAAI,MAAME,gBAAgB,GAAG;EACzBC,SAAS,EAAE;IACPC,iBAAiB,EAAE,IAAI;IACvBC,uBAAuB,EAAE,UAAU;IACnCC,uBAAuB,EAAE,QAAQ;IACjCC,eAAe,EAAE;EACrB;AACJ,CAAC;AACD;AACA;AACA;AAAI,MAAMC,aAAa,gBAAGzB,QAAA;EAAAM,IAAA;IAAAoB,MAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,OAAA;IAAAC,MAAA;IAAAC,OAAA;EAAA;EAAAC,UAAA;IAAAC,OAAA;EAAA;EAAAC,QAA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AAW,GAAGZ,cAAc,CAAC,CAAC;EACpC,MAAMa,WAAW,GAAG7B,cAAc,CAAC,CAAC;EACpCsB,KAAK,CAAC1E,IAAI,CAACkF,SAAS,GAAGvF,YAAY,CAACI,iBAAiB,CAACC,IAAI,EAAE8E,UAAU,CAAC9E,IAAI,EAAE,CAAC2E,aAAa,KAAK,OAAO,IAAIA,aAAa,KAAK,OAAO,KAAKG,UAAU,CAAClD,QAAQ,EAAE,CAAC+C,aAAa,KAAK,QAAQ,IAAIA,aAAa,KAAK,OAAO,KAAKG,UAAU,CAACpD,UAAU,EAAEgD,KAAK,CAAC1E,IAAI,CAACkF,SAAS,CAAC;EACvQ,IAAIR,KAAK,CAACzE,OAAO,EAAE;IACfyE,KAAK,CAACzE,OAAO,CAACiF,SAAS,GAAGvF,YAAY,CAACI,iBAAiB,CAACE,OAAO,EAAE8E,aAAa,CAAChD,UAAU,EAAEgD,aAAa,CAACH,IAAI,CAAC,EAAEK,WAAW,CAACJ,UAAU,CAAC,EAAEH,KAAK,CAACzE,OAAO,CAACiF,SAAS,CAAC;EACtK;EACA,IAAIR,KAAK,CAACxE,KAAK,EAAE;IACbwE,KAAK,CAACxE,KAAK,CAACgF,SAAS,GAAGvF,YAAY,CAACI,iBAAiB,CAACG,KAAK,EAAE8E,WAAW,CAACJ,IAAI,CAAC,EAAEI,WAAW,CAACH,UAAU,CAAC,EAAEH,KAAK,CAACxE,KAAK,CAACgF,SAAS,CAAC;EACpI;EACA,OAAOR,KAAK;AAChB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["SpinnerContext.ts"],"sourcesContent":["import * as React from 'react';\nimport { SpinnerProps } from '../components/Spinner/Spinner.types';\n\nconst SpinnerContext = React.createContext<SpinnerContextValue | undefined>(undefined);\n\n/**\n * @internal\n */\nexport type SpinnerContextValue = Pick<SpinnerProps, 'size'>;\n\nconst SpinnerContextDefaultValue: SpinnerContextValue = {};\n\n/**\n * @internal\n */\nexport const SpinnerContextProvider = SpinnerContext.Provider;\n\n/**\n * @internal\n */\nexport const useSpinnerContext = () => React.useContext(SpinnerContext) ?? SpinnerContextDefaultValue;\n"],"names":["React","SpinnerContext","createContext","undefined","SpinnerContextDefaultValue","SpinnerContextProvider","Provider","useSpinnerContext","useContext"],"mappings":"AAAA,YAAYA,WAAW,QAAQ;AAG/B,MAAMC,iBAAiBD,MAAME,aAAa,CAAkCC;AAO5E,MAAMC,6BAAkD,CAAC;AAEzD;;CAEC,GACD,OAAO,MAAMC,yBAAyBJ,eAAeK,QAAQ,CAAC;IAKvBN;AAHvC;;CAEC,GACD,OAAO,MAAMO,oBAAoB,IAAMP,CAAAA,oBAAAA,MAAMQ,UAAU,CAACP,6BAAjBD,+BAAAA,oBAAoCI,
|
|
1
|
+
{"version":3,"sources":["SpinnerContext.ts"],"sourcesContent":["import * as React from 'react';\nimport { SpinnerProps } from '../components/Spinner/Spinner.types';\n\nconst SpinnerContext = React.createContext<SpinnerContextValue | undefined>(undefined);\n\n/**\n * @internal\n */\nexport type SpinnerContextValue = Pick<SpinnerProps, 'size'>;\n\nconst SpinnerContextDefaultValue: SpinnerContextValue = {};\n\n/**\n * @internal\n */\nexport const SpinnerContextProvider = SpinnerContext.Provider;\n\n/**\n * @internal\n */\nexport const useSpinnerContext = () => React.useContext(SpinnerContext) ?? SpinnerContextDefaultValue;\n"],"names":["React","SpinnerContext","createContext","undefined","SpinnerContextDefaultValue","SpinnerContextProvider","Provider","useSpinnerContext","useContext"],"mappings":"AAAA,YAAYA,WAAW,QAAQ;AAG/B,MAAMC,iBAAiBD,MAAME,aAAa,CAAkCC;AAO5E,MAAMC,6BAAkD,CAAC;AAEzD;;CAEC,GACD,OAAO,MAAMC,yBAAyBJ,eAAeK,QAAQ,CAAC;IAKvBN;AAHvC;;CAEC,GACD,OAAO,MAAMO,oBAAoB,IAAMP,CAAAA,oBAAAA,MAAMQ,UAAU,CAACP,6BAAjBD,+BAAAA,oBAAoCI,2BAA2B"}
|
package/lib-commonjs/Spinner.js
CHANGED
|
@@ -2,5 +2,5 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", {
|
|
3
3
|
value: true
|
|
4
4
|
});
|
|
5
|
-
const
|
|
6
|
-
|
|
5
|
+
const _export_star = require("@swc/helpers/_/_export_star");
|
|
6
|
+
_export_star._(require("./components/Spinner/index"), exports);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["Spinner.js"],"sourcesContent":["export * from './components/Spinner/index';\n"],"names":[],"mappings":";;;;;
|
|
1
|
+
{"version":3,"sources":["Spinner.js"],"sourcesContent":["export * from './components/Spinner/index';\n"],"names":[],"mappings":";;;;;uBAAc"}
|
|
@@ -4,10 +4,12 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
});
|
|
5
5
|
Object.defineProperty(exports, "DefaultSvg", {
|
|
6
6
|
enumerable: true,
|
|
7
|
-
get: ()
|
|
7
|
+
get: function() {
|
|
8
|
+
return DefaultSvg;
|
|
9
|
+
}
|
|
8
10
|
});
|
|
9
|
-
const
|
|
10
|
-
const _react = /*#__PURE__*/
|
|
11
|
+
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
|
12
|
+
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
|
11
13
|
const DefaultSvg = ()=>/*#__PURE__*/ _react.createElement("svg", {
|
|
12
14
|
className: "fui-Spinner__Progressbar"
|
|
13
15
|
}, /*#__PURE__*/ _react.createElement("circle", {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["DefaultSvg.js"],"sourcesContent":["import * as React from 'react';\nexport const DefaultSvg = ()=>/*#__PURE__*/ React.createElement(\"svg\", {\n className: \"fui-Spinner__Progressbar\"\n }, /*#__PURE__*/ React.createElement(\"circle\", {\n className: \"fui-Spinner__Track\"\n }), /*#__PURE__*/ React.createElement(\"circle\", {\n className: \"fui-Spinner__Tail\"\n }));\n"],"names":["DefaultSvg","React","createElement","className"],"mappings":";;;;+BACaA
|
|
1
|
+
{"version":3,"sources":["DefaultSvg.js"],"sourcesContent":["import * as React from 'react';\nexport const DefaultSvg = ()=>/*#__PURE__*/ React.createElement(\"svg\", {\n className: \"fui-Spinner__Progressbar\"\n }, /*#__PURE__*/ React.createElement(\"circle\", {\n className: \"fui-Spinner__Track\"\n }), /*#__PURE__*/ React.createElement(\"circle\", {\n className: \"fui-Spinner__Tail\"\n }));\n"],"names":["DefaultSvg","React","createElement","className"],"mappings":";;;;+BACaA;;;eAAAA;;;;iEADU;AAChB,MAAMA,aAAa,IAAI,WAAW,GAAGC,OAAMC,aAAa,CAAC,OAAO;QAC/DC,WAAW;IACf,GAAG,WAAW,GAAGF,OAAMC,aAAa,CAAC,UAAU;QAC3CC,WAAW;IACf,IAAI,WAAW,GAAGF,OAAMC,aAAa,CAAC,UAAU;QAC5CC,WAAW;IACf"}
|
|
@@ -4,18 +4,20 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
});
|
|
5
5
|
Object.defineProperty(exports, "Spinner", {
|
|
6
6
|
enumerable: true,
|
|
7
|
-
get: ()
|
|
7
|
+
get: function() {
|
|
8
|
+
return Spinner;
|
|
9
|
+
}
|
|
8
10
|
});
|
|
9
|
-
const
|
|
10
|
-
const _react = /*#__PURE__*/
|
|
11
|
+
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
|
12
|
+
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
|
11
13
|
const _useSpinner = require("./useSpinner");
|
|
12
14
|
const _renderSpinner = require("./renderSpinner");
|
|
13
|
-
const
|
|
14
|
-
const
|
|
15
|
+
const _useSpinnerStylesstyles = require("./useSpinnerStyles.styles");
|
|
16
|
+
const _reactsharedcontexts = require("@fluentui/react-shared-contexts");
|
|
15
17
|
const Spinner = /*#__PURE__*/ _react.forwardRef((props, ref)=>{
|
|
16
18
|
const state = (0, _useSpinner.useSpinner_unstable)(props, ref);
|
|
17
|
-
(0,
|
|
18
|
-
(0,
|
|
19
|
+
(0, _useSpinnerStylesstyles.useSpinnerStyles_unstable)(state);
|
|
20
|
+
(0, _reactsharedcontexts.useCustomStyleHook_unstable)('useSpinnerStyles_unstable')(state);
|
|
19
21
|
return (0, _renderSpinner.renderSpinner_unstable)(state);
|
|
20
22
|
});
|
|
21
23
|
Spinner.displayName = 'Spinner';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["Spinner.js"],"sourcesContent":["import * as React from 'react';\nimport { useSpinner_unstable } from './useSpinner';\nimport { renderSpinner_unstable } from './renderSpinner';\nimport { useSpinnerStyles_unstable } from './useSpinnerStyles.styles';\nimport { useCustomStyleHook_unstable } from '@fluentui/react-shared-contexts';\n/**\n * Converged Spinner component for the fluentui repo\n */ export const Spinner = /*#__PURE__*/ React.forwardRef((props, ref)=>{\n const state = useSpinner_unstable(props, ref);\n useSpinnerStyles_unstable(state);\n useCustomStyleHook_unstable('useSpinnerStyles_unstable')(state);\n return renderSpinner_unstable(state);\n});\nSpinner.displayName = 'Spinner';\n"],"names":["Spinner","React","forwardRef","props","ref","state","useSpinner_unstable","useSpinnerStyles_unstable","useCustomStyleHook_unstable","renderSpinner_unstable","displayName"],"mappings":";;;;+BAOiBA
|
|
1
|
+
{"version":3,"sources":["Spinner.js"],"sourcesContent":["import * as React from 'react';\nimport { useSpinner_unstable } from './useSpinner';\nimport { renderSpinner_unstable } from './renderSpinner';\nimport { useSpinnerStyles_unstable } from './useSpinnerStyles.styles';\nimport { useCustomStyleHook_unstable } from '@fluentui/react-shared-contexts';\n/**\n * Converged Spinner component for the fluentui repo\n */ export const Spinner = /*#__PURE__*/ React.forwardRef((props, ref)=>{\n const state = useSpinner_unstable(props, ref);\n useSpinnerStyles_unstable(state);\n useCustomStyleHook_unstable('useSpinnerStyles_unstable')(state);\n return renderSpinner_unstable(state);\n});\nSpinner.displayName = 'Spinner';\n"],"names":["Spinner","React","forwardRef","props","ref","state","useSpinner_unstable","useSpinnerStyles_unstable","useCustomStyleHook_unstable","renderSpinner_unstable","displayName"],"mappings":";;;;+BAOiBA;;;eAAAA;;;;iEAPM;4BACa;+BACG;wCACG;qCACE;AAGjC,MAAMA,UAAU,WAAW,GAAGC,OAAMC,UAAU,CAAC,CAACC,OAAOC;IAC9D,MAAMC,QAAQC,IAAAA,+BAAmB,EAACH,OAAOC;IACzCG,IAAAA,iDAAyB,EAACF;IAC1BG,IAAAA,gDAA2B,EAAC,6BAA6BH;IACzD,OAAOI,IAAAA,qCAAsB,EAACJ;AAClC;AACAL,QAAQU,WAAW,GAAG"}
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", {
|
|
3
3
|
value: true
|
|
4
4
|
});
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
5
|
+
const _export_star = require("@swc/helpers/_/_export_star");
|
|
6
|
+
_export_star._(require("./Spinner"), exports);
|
|
7
|
+
_export_star._(require("./Spinner.types"), exports);
|
|
8
|
+
_export_star._(require("./renderSpinner"), exports);
|
|
9
|
+
_export_star._(require("./useSpinner"), exports);
|
|
10
|
+
_export_star._(require("./useSpinnerStyles.styles"), exports);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["index.js"],"sourcesContent":["export * from './Spinner';\nexport * from './Spinner.types';\nexport * from './renderSpinner';\nexport * from './useSpinner';\nexport * from './useSpinnerStyles.styles';\n"],"names":[],"mappings":";;;;;
|
|
1
|
+
{"version":3,"sources":["index.js"],"sourcesContent":["export * from './Spinner';\nexport * from './Spinner.types';\nexport * from './renderSpinner';\nexport * from './useSpinner';\nexport * from './useSpinnerStyles.styles';\n"],"names":[],"mappings":";;;;;uBAAc;uBACA;uBACA;uBACA;uBACA"}
|
|
@@ -1,15 +1,23 @@
|
|
|
1
|
-
/** @jsxRuntime
|
|
1
|
+
/** @jsxRuntime automatic */ /** @jsxImportSource @fluentui/react-jsx-runtime */ "use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", {
|
|
3
3
|
value: true
|
|
4
4
|
});
|
|
5
5
|
Object.defineProperty(exports, "renderSpinner_unstable", {
|
|
6
6
|
enumerable: true,
|
|
7
|
-
get: ()
|
|
7
|
+
get: function() {
|
|
8
|
+
return renderSpinner_unstable;
|
|
9
|
+
}
|
|
8
10
|
});
|
|
9
|
-
const
|
|
10
|
-
const
|
|
11
|
+
const _jsxruntime = require("@fluentui/react-jsx-runtime/jsx-runtime");
|
|
12
|
+
const _reactutilities = require("@fluentui/react-utilities");
|
|
11
13
|
const renderSpinner_unstable = (state)=>{
|
|
12
|
-
(0,
|
|
13
|
-
const { labelPosition
|
|
14
|
-
return /*#__PURE__*/ (0,
|
|
14
|
+
(0, _reactutilities.assertSlots)(state);
|
|
15
|
+
const { labelPosition, shouldRenderSpinner } = state;
|
|
16
|
+
return /*#__PURE__*/ (0, _jsxruntime.jsxs)(state.root, {
|
|
17
|
+
children: [
|
|
18
|
+
state.label && shouldRenderSpinner && (labelPosition === 'above' || labelPosition === 'before') && /*#__PURE__*/ (0, _jsxruntime.jsx)(state.label, {}),
|
|
19
|
+
state.spinner && shouldRenderSpinner && /*#__PURE__*/ (0, _jsxruntime.jsx)(state.spinner, {}),
|
|
20
|
+
state.label && shouldRenderSpinner && (labelPosition === 'below' || labelPosition === 'after') && /*#__PURE__*/ (0, _jsxruntime.jsx)(state.label, {})
|
|
21
|
+
]
|
|
22
|
+
});
|
|
15
23
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["renderSpinner.js"],"sourcesContent":["/** @jsxRuntime
|
|
1
|
+
{"version":3,"sources":["renderSpinner.js"],"sourcesContent":["/** @jsxRuntime automatic */ /** @jsxImportSource @fluentui/react-jsx-runtime */ import { jsx as _jsx, jsxs as _jsxs } from \"@fluentui/react-jsx-runtime/jsx-runtime\";\nimport { assertSlots } from '@fluentui/react-utilities';\n/**\n * Render the final JSX of Spinner\n */ export const renderSpinner_unstable = (state)=>{\n assertSlots(state);\n const { labelPosition, shouldRenderSpinner } = state;\n return /*#__PURE__*/ _jsxs(state.root, {\n children: [\n state.label && shouldRenderSpinner && (labelPosition === 'above' || labelPosition === 'before') && /*#__PURE__*/ _jsx(state.label, {}),\n state.spinner && shouldRenderSpinner && /*#__PURE__*/ _jsx(state.spinner, {}),\n state.label && shouldRenderSpinner && (labelPosition === 'below' || labelPosition === 'after') && /*#__PURE__*/ _jsx(state.label, {})\n ]\n });\n};\n"],"names":["renderSpinner_unstable","state","assertSlots","labelPosition","shouldRenderSpinner","_jsxs","root","children","label","_jsx","spinner"],"mappings":"AAAA,0BAA0B,GAAG,iDAAiD;;;;+BAI7DA;;;eAAAA;;;4BAJ2G;gCAChG;AAGjB,MAAMA,yBAAyB,CAACC;IACvCC,IAAAA,2BAAW,EAACD;IACZ,MAAM,EAAEE,aAAa,EAAEC,mBAAmB,EAAE,GAAGH;IAC/C,OAAO,WAAW,GAAGI,IAAAA,gBAAK,EAACJ,MAAMK,IAAI,EAAE;QACnCC,UAAU;YACNN,MAAMO,KAAK,IAAIJ,uBAAwBD,CAAAA,kBAAkB,WAAWA,kBAAkB,QAAO,KAAM,WAAW,GAAGM,IAAAA,eAAI,EAACR,MAAMO,KAAK,EAAE,CAAC;YACpIP,MAAMS,OAAO,IAAIN,uBAAuB,WAAW,GAAGK,IAAAA,eAAI,EAACR,MAAMS,OAAO,EAAE,CAAC;YAC3ET,MAAMO,KAAK,IAAIJ,uBAAwBD,CAAAA,kBAAkB,WAAWA,kBAAkB,OAAM,KAAM,WAAW,GAAGM,IAAAA,eAAI,EAACR,MAAMO,KAAK,EAAE,CAAC;SACtI;IACL;AACJ"}
|
|
@@ -4,21 +4,23 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
});
|
|
5
5
|
Object.defineProperty(exports, "useSpinner_unstable", {
|
|
6
6
|
enumerable: true,
|
|
7
|
-
get: ()
|
|
7
|
+
get: function() {
|
|
8
|
+
return useSpinner_unstable;
|
|
9
|
+
}
|
|
8
10
|
});
|
|
9
|
-
const
|
|
10
|
-
const _react = /*#__PURE__*/
|
|
11
|
-
const
|
|
12
|
-
const
|
|
13
|
-
const
|
|
14
|
-
const
|
|
11
|
+
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
|
12
|
+
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
|
13
|
+
const _reactutilities = require("@fluentui/react-utilities");
|
|
14
|
+
const _reactlabel = require("@fluentui/react-label");
|
|
15
|
+
const _DefaultSvg = require("./DefaultSvg");
|
|
16
|
+
const _SpinnerContext = require("../../contexts/SpinnerContext");
|
|
15
17
|
const useSpinner_unstable = (props, ref)=>{
|
|
16
18
|
// Props
|
|
17
|
-
const { size: contextSize
|
|
18
|
-
const { appearance ='primary'
|
|
19
|
-
const baseId = (0,
|
|
20
|
-
const { role ='progressbar'
|
|
21
|
-
const nativeRoot =
|
|
19
|
+
const { size: contextSize } = (0, _SpinnerContext.useSpinnerContext)();
|
|
20
|
+
const { appearance = 'primary', labelPosition = 'after', size = contextSize !== null && contextSize !== void 0 ? contextSize : 'medium', delay = 0 } = props;
|
|
21
|
+
const baseId = (0, _reactutilities.useId)('spinner');
|
|
22
|
+
const { role = 'progressbar', tabIndex, ...rest } = props;
|
|
23
|
+
const nativeRoot = _reactutilities.slot.always((0, _reactutilities.getNativeElementProps)('div', {
|
|
22
24
|
ref,
|
|
23
25
|
role,
|
|
24
26
|
...rest
|
|
@@ -28,7 +30,7 @@ const useSpinner_unstable = (props, ref)=>{
|
|
|
28
30
|
elementType: 'div'
|
|
29
31
|
});
|
|
30
32
|
const [isVisible, setIsVisible] = _react.useState(true);
|
|
31
|
-
const [setDelayTimeout, clearDelayTimeout] = (0,
|
|
33
|
+
const [setDelayTimeout, clearDelayTimeout] = (0, _reactutilities.useTimeout)();
|
|
32
34
|
_react.useEffect(()=>{
|
|
33
35
|
if (delay <= 0) {
|
|
34
36
|
return;
|
|
@@ -45,17 +47,17 @@ const useSpinner_unstable = (props, ref)=>{
|
|
|
45
47
|
clearDelayTimeout,
|
|
46
48
|
delay
|
|
47
49
|
]);
|
|
48
|
-
const labelShorthand =
|
|
50
|
+
const labelShorthand = _reactutilities.slot.optional(props.label, {
|
|
49
51
|
defaultProps: {
|
|
50
52
|
id: baseId
|
|
51
53
|
},
|
|
52
54
|
renderByDefault: false,
|
|
53
|
-
elementType:
|
|
55
|
+
elementType: _reactlabel.Label
|
|
54
56
|
});
|
|
55
|
-
const spinnerShortHand =
|
|
57
|
+
const spinnerShortHand = _reactutilities.slot.optional(props.spinner, {
|
|
56
58
|
renderByDefault: true,
|
|
57
59
|
defaultProps: {
|
|
58
|
-
children: /*#__PURE__*/ _react.createElement(
|
|
60
|
+
children: /*#__PURE__*/ _react.createElement(_DefaultSvg.DefaultSvg, null),
|
|
59
61
|
tabIndex
|
|
60
62
|
},
|
|
61
63
|
elementType: 'span'
|
|
@@ -72,7 +74,7 @@ const useSpinner_unstable = (props, ref)=>{
|
|
|
72
74
|
components: {
|
|
73
75
|
root: 'div',
|
|
74
76
|
spinner: 'span',
|
|
75
|
-
label:
|
|
77
|
+
label: _reactlabel.Label
|
|
76
78
|
},
|
|
77
79
|
root: nativeRoot,
|
|
78
80
|
spinner: spinnerShortHand,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["useSpinner.js"],"sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps, useId, useTimeout, slot } from '@fluentui/react-utilities';\nimport { Label } from '@fluentui/react-label';\nimport { DefaultSvg } from './DefaultSvg';\nimport { useSpinnerContext } from '../../contexts/SpinnerContext';\n/**\n * Create the state required to render Spinner.\n *\n * The returned state can be modified with hooks such as useSpinnerStyles_unstable,\n * before being passed to renderSpinner_unstable.\n *\n * @param props - props from this instance of Spinner\n * @param ref - reference to root HTMLElement of Spinner\n */ export const useSpinner_unstable = (props, ref)=>{\n // Props\n const { size: contextSize
|
|
1
|
+
{"version":3,"sources":["useSpinner.js"],"sourcesContent":["import * as React from 'react';\nimport { getNativeElementProps, useId, useTimeout, slot } from '@fluentui/react-utilities';\nimport { Label } from '@fluentui/react-label';\nimport { DefaultSvg } from './DefaultSvg';\nimport { useSpinnerContext } from '../../contexts/SpinnerContext';\n/**\n * Create the state required to render Spinner.\n *\n * The returned state can be modified with hooks such as useSpinnerStyles_unstable,\n * before being passed to renderSpinner_unstable.\n *\n * @param props - props from this instance of Spinner\n * @param ref - reference to root HTMLElement of Spinner\n */ export const useSpinner_unstable = (props, ref)=>{\n // Props\n const { size: contextSize } = useSpinnerContext();\n const { appearance = 'primary', labelPosition = 'after', size = contextSize !== null && contextSize !== void 0 ? contextSize : 'medium', delay = 0 } = props;\n const baseId = useId('spinner');\n const { role = 'progressbar', tabIndex, ...rest } = props;\n const nativeRoot = slot.always(getNativeElementProps('div', {\n ref,\n role,\n ...rest\n }, [\n 'size'\n ]), {\n elementType: 'div'\n });\n const [isVisible, setIsVisible] = React.useState(true);\n const [setDelayTimeout, clearDelayTimeout] = useTimeout();\n React.useEffect(()=>{\n if (delay <= 0) {\n return;\n }\n setIsVisible(false);\n setDelayTimeout(()=>{\n setIsVisible(true);\n }, delay);\n return ()=>{\n clearDelayTimeout();\n };\n }, [\n setDelayTimeout,\n clearDelayTimeout,\n delay\n ]);\n const labelShorthand = slot.optional(props.label, {\n defaultProps: {\n id: baseId\n },\n renderByDefault: false,\n elementType: Label\n });\n const spinnerShortHand = slot.optional(props.spinner, {\n renderByDefault: true,\n defaultProps: {\n children: /*#__PURE__*/ React.createElement(DefaultSvg, null),\n tabIndex\n },\n elementType: 'span'\n });\n if (labelShorthand && nativeRoot && !nativeRoot['aria-labelledby']) {\n nativeRoot['aria-labelledby'] = labelShorthand.id;\n }\n const state = {\n appearance,\n delay,\n labelPosition,\n size,\n shouldRenderSpinner: isVisible,\n components: {\n root: 'div',\n spinner: 'span',\n label: Label\n },\n root: nativeRoot,\n spinner: spinnerShortHand,\n label: labelShorthand\n };\n return state;\n};\n"],"names":["useSpinner_unstable","props","ref","size","contextSize","useSpinnerContext","appearance","labelPosition","delay","baseId","useId","role","tabIndex","rest","nativeRoot","slot","always","getNativeElementProps","elementType","isVisible","setIsVisible","React","useState","setDelayTimeout","clearDelayTimeout","useTimeout","useEffect","labelShorthand","optional","label","defaultProps","id","renderByDefault","Label","spinnerShortHand","spinner","children","createElement","DefaultSvg","state","shouldRenderSpinner","components","root"],"mappings":";;;;+BAaiBA;;;eAAAA;;;;iEAbM;gCACwC;4BACzC;4BACK;gCACO;AASvB,MAAMA,sBAAsB,CAACC,OAAOC;IAC3C,QAAQ;IACR,MAAM,EAAEC,MAAMC,WAAW,EAAE,GAAGC,IAAAA,iCAAiB;IAC/C,MAAM,EAAEC,aAAa,SAAS,EAAEC,gBAAgB,OAAO,EAAEJ,OAAOC,gBAAgB,QAAQA,gBAAgB,KAAK,IAAIA,cAAc,QAAQ,EAAEI,QAAQ,CAAC,EAAE,GAAGP;IACvJ,MAAMQ,SAASC,IAAAA,qBAAK,EAAC;IACrB,MAAM,EAAEC,OAAO,aAAa,EAAEC,QAAQ,EAAE,GAAGC,MAAM,GAAGZ;IACpD,MAAMa,aAAaC,oBAAI,CAACC,MAAM,CAACC,IAAAA,qCAAqB,EAAC,OAAO;QACxDf;QACAS;QACA,GAAGE,IAAI;IACX,GAAG;QACC;KACH,GAAG;QACAK,aAAa;IACjB;IACA,MAAM,CAACC,WAAWC,aAAa,GAAGC,OAAMC,QAAQ,CAAC;IACjD,MAAM,CAACC,iBAAiBC,kBAAkB,GAAGC,IAAAA,0BAAU;IACvDJ,OAAMK,SAAS,CAAC;QACZ,IAAIlB,SAAS,GAAG;YACZ;QACJ;QACAY,aAAa;QACbG,gBAAgB;YACZH,aAAa;QACjB,GAAGZ;QACH,OAAO;YACHgB;QACJ;IACJ,GAAG;QACCD;QACAC;QACAhB;KACH;IACD,MAAMmB,iBAAiBZ,oBAAI,CAACa,QAAQ,CAAC3B,MAAM4B,KAAK,EAAE;QAC9CC,cAAc;YACVC,IAAItB;QACR;QACAuB,iBAAiB;QACjBd,aAAae,iBAAK;IACtB;IACA,MAAMC,mBAAmBnB,oBAAI,CAACa,QAAQ,CAAC3B,MAAMkC,OAAO,EAAE;QAClDH,iBAAiB;QACjBF,cAAc;YACVM,UAAU,WAAW,GAAGf,OAAMgB,aAAa,CAACC,sBAAU,EAAE;YACxD1B;QACJ;QACAM,aAAa;IACjB;IACA,IAAIS,kBAAkBb,cAAc,CAACA,UAAU,CAAC,kBAAkB,EAAE;QAChEA,UAAU,CAAC,kBAAkB,GAAGa,eAAeI,EAAE;IACrD;IACA,MAAMQ,QAAQ;QACVjC;QACAE;QACAD;QACAJ;QACAqC,qBAAqBrB;QACrBsB,YAAY;YACRC,MAAM;YACNP,SAAS;YACTN,OAAOI,iBAAK;QAChB;QACAS,MAAM5B;QACNqB,SAASD;QACTL,OAAOF;IACX;IACA,OAAOY;AACX"}
|
|
@@ -9,8 +9,12 @@ function _export(target, all) {
|
|
|
9
9
|
});
|
|
10
10
|
}
|
|
11
11
|
_export(exports, {
|
|
12
|
-
spinnerClassNames: ()
|
|
13
|
-
|
|
12
|
+
spinnerClassNames: function() {
|
|
13
|
+
return spinnerClassNames;
|
|
14
|
+
},
|
|
15
|
+
useSpinnerStyles_unstable: function() {
|
|
16
|
+
return useSpinnerStyles_unstable;
|
|
17
|
+
}
|
|
14
18
|
});
|
|
15
19
|
const _react = require("@griffel/react");
|
|
16
20
|
const spinnerClassNames = {
|
|
@@ -57,7 +61,7 @@ const spinnerClassNames = {
|
|
|
57
61
|
};
|
|
58
62
|
/**
|
|
59
63
|
* Styles for the root slot
|
|
60
|
-
*/ const useRootStyles = /*#__PURE__*/ (0, _react
|
|
64
|
+
*/ const useRootStyles = /*#__PURE__*/ (0, _react.__styles)({
|
|
61
65
|
root: {
|
|
62
66
|
mc9l5x: "f22iagw",
|
|
63
67
|
Bt984gj: "f122n59",
|
|
@@ -84,7 +88,7 @@ const spinnerClassNames = {
|
|
|
84
88
|
".f1vx9l62{flex-direction:column;}"
|
|
85
89
|
]
|
|
86
90
|
});
|
|
87
|
-
const useLoaderStyles = /*#__PURE__*/ (0, _react
|
|
91
|
+
const useLoaderStyles = /*#__PURE__*/ (0, _react.__styles)({
|
|
88
92
|
spinnerSVG: {
|
|
89
93
|
B3aqqti: "f1or16p5",
|
|
90
94
|
Brovlpu: "f1grzc83",
|
|
@@ -214,7 +218,7 @@ const useLoaderStyles = /*#__PURE__*/ (0, _react["__styles"])({
|
|
|
214
218
|
]
|
|
215
219
|
]
|
|
216
220
|
});
|
|
217
|
-
const useTrackStyles = /*#__PURE__*/ (0, _react
|
|
221
|
+
const useTrackStyles = /*#__PURE__*/ (0, _react.__styles)({
|
|
218
222
|
inverted: {
|
|
219
223
|
gwg7kz: "f1jvpmnu",
|
|
220
224
|
Bvrehnu: "fq8a5sv",
|
|
@@ -246,7 +250,7 @@ const useTrackStyles = /*#__PURE__*/ (0, _react["__styles"])({
|
|
|
246
250
|
Bo2mdfu: "f1eseayc",
|
|
247
251
|
E10nrc: "folzdkc",
|
|
248
252
|
Bwl7w15: "fhlfkde",
|
|
249
|
-
Bksq7rz: "
|
|
253
|
+
Bksq7rz: "f13qeqtg",
|
|
250
254
|
y14cdu: "flglbw1"
|
|
251
255
|
}
|
|
252
256
|
}, {
|
|
@@ -262,7 +266,7 @@ const useTrackStyles = /*#__PURE__*/ (0, _react["__styles"])({
|
|
|
262
266
|
".f1eseayc>svg>circle.fui-Spinner__Tail{transform-origin:50% 50%;}",
|
|
263
267
|
".f1esql28>svg>circle.fui-Spinner__Track{stroke:rgba(255, 255, 255, 0.2);}",
|
|
264
268
|
".f11ditju>svg>circle.fui-Spinner__Tail{stroke:var(--colorBrandStroke1);}",
|
|
265
|
-
".
|
|
269
|
+
".f13qeqtg>svg>circle.fui-Spinner__Track{stroke:var(--colorBrandStroke2Contrast);}"
|
|
266
270
|
],
|
|
267
271
|
k: [
|
|
268
272
|
"@keyframes f1v1ql0f{0%{stroke-dasharray:1,150;stroke-dashoffset:0;}50%{stroke-dasharray:90,150;stroke-dashoffset:-35;}100%{stroke-dasharray:90,150;stroke-dashoffset:-124;}}"
|
|
@@ -294,7 +298,7 @@ const useTrackStyles = /*#__PURE__*/ (0, _react["__styles"])({
|
|
|
294
298
|
]
|
|
295
299
|
]
|
|
296
300
|
});
|
|
297
|
-
const useLabelStyles = /*#__PURE__*/ (0, _react
|
|
301
|
+
const useLabelStyles = /*#__PURE__*/ (0, _react.__styles)({
|
|
298
302
|
inverted: {
|
|
299
303
|
sj55zd: "f15aqcq"
|
|
300
304
|
},
|
|
@@ -362,7 +366,7 @@ const useLabelStyles = /*#__PURE__*/ (0, _react["__styles"])({
|
|
|
362
366
|
]
|
|
363
367
|
});
|
|
364
368
|
const useSpinnerStyles_unstable = (state)=>{
|
|
365
|
-
const { labelPosition
|
|
369
|
+
const { labelPosition, size, appearance = 'primary' } = state;
|
|
366
370
|
const rootStyles = useRootStyles();
|
|
367
371
|
const spinnerStyles = useLoaderStyles();
|
|
368
372
|
const labelStyles = useLabelStyles();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["useSpinnerStyles.styles.js"],"sourcesContent":["import { __styles, mergeClasses, shorthands } from '@griffel/react';\nimport { tokens, typographyStyles } from '@fluentui/react-theme';\nexport const spinnerClassNames = {\n root: 'fui-Spinner',\n spinner: 'fui-Spinner__spinner',\n label: 'fui-Spinner__label'\n};\n/*\n * TODO: Update with proper tokens when added\n * Radii for the Spinner circles\n */\nconst rValues = {\n extraTiny: '7px',\n tiny: '9px',\n extraSmall: '11px',\n small: '13px',\n medium: '14.5px',\n large: '16.5px',\n extraLarge: '18.5px',\n huge: '20px'\n};\n/*\n * TODO: Update with proper tokens when added\n * Sizes for the Spinner\n */\nconst spinnnerSizes = {\n extraTiny: '16px',\n tiny: '20px',\n extraSmall: '24px',\n small: '28px',\n medium: '32px',\n large: '36px',\n extraLarge: '40px',\n huge: '44px'\n};\n/*\n * TODO: Update with proper tokens when added\n * Animation for Spinner\n */\nconst spinnerAnimation = {\n container: {\n animationDuration: '3s',\n animationIterationCount: 'infinite',\n animationTimingFunction: 'linear',\n backgroundColor: 'transparent'\n }\n};\n/**\n * Styles for the root slot\n */\nconst useRootStyles = /*#__PURE__*/__styles({\n root: {\n mc9l5x: \"f22iagw\",\n Bt984gj: \"f122n59\",\n Brf1p80: \"f4d9j23\",\n Bg96gwp: \"fez10in\",\n i8kkvl: \"f4px1ci\",\n Belr9w4: \"fn67r4l\"\n },\n horizontal: {\n Beiy3e4: \"f1063pyq\"\n },\n vertical: {\n Beiy3e4: \"f1vx9l62\"\n }\n}, {\n d: [\".f22iagw{display:flex;}\", \".f122n59{align-items:center;}\", \".f4d9j23{justify-content:center;}\", \".fez10in{line-height:0;}\", \".f4px1ci{column-gap:8px;}\", \".fn67r4l{row-gap:8px;}\", \".f1063pyq{flex-direction:row;}\", \".f1vx9l62{flex-direction:column;}\"]\n});\nconst useLoaderStyles = /*#__PURE__*/__styles({\n spinnerSVG: {\n B3aqqti: \"f1or16p5\",\n Brovlpu: \"f1grzc83\",\n Bxa1mx5: \"f19shzzi\",\n Bwaue66: [\"f5tbecn\", \"f15qb8s7\"],\n fyp1ls: \"fn4mtlg\",\n ag6ruv: \"f1y80fxs\",\n osj692: \"f1r2crtq\",\n aq5vjd: \"f1wsi8sr\",\n tlu9e1: \"f1bkm2qd\",\n J3u96z: \"f1urqz7h\",\n d32isg: \"f1da2vov\",\n Bsvqbuc: \"f11rfva0\",\n b3s3i5: \"f1exc66\"\n },\n \"extra-tiny\": {\n Bah9ito: \"f1x2gjcb\",\n ut6tcf: \"f1vjiaua\",\n B7p06xz: \"fv1u54w\",\n B807ibg: \"f1oebb0s\"\n },\n tiny: {\n Bah9ito: \"f1j4wmu2\",\n ut6tcf: \"f1vppzuq\",\n B7p06xz: \"fv1u54w\",\n B807ibg: \"fngtx1d\"\n },\n \"extra-small\": {\n Bah9ito: \"fmpqlna\",\n ut6tcf: \"f15z5jzu\",\n B7p06xz: \"fv1u54w\",\n B807ibg: \"fadawes\"\n },\n small: {\n Bah9ito: \"fo52gbo\",\n ut6tcf: \"f1b41i3v\",\n B7p06xz: \"fv1u54w\",\n B807ibg: \"f1xqyyrl\"\n },\n medium: {\n Bah9ito: \"f1aiqagr\",\n ut6tcf: \"f1wtx80b\",\n B7p06xz: \"f1flujpd\",\n B807ibg: \"f1u06hy7\"\n },\n large: {\n Bah9ito: \"f1trdq7b\",\n ut6tcf: \"f9e0mc5\",\n B7p06xz: \"f1flujpd\",\n B807ibg: \"f13pmvhl\"\n },\n \"extra-large\": {\n Bah9ito: \"f89rf2a\",\n ut6tcf: \"f1w2xg3q\",\n B7p06xz: \"f1flujpd\",\n B807ibg: \"fmn74v6\"\n },\n huge: {\n Bah9ito: \"f1rx7k5y\",\n ut6tcf: \"f1vtyt49\",\n B7p06xz: \"f1owbg48\",\n B807ibg: \"f1fr1izd\"\n }\n}, {\n f: [\".f1or16p5:focus{outline-width:3px;}\", \".f1grzc83:focus{outline-style:solid;}\", \".f19shzzi:focus{outline-color:transparent;}\"],\n k: [\"@keyframes fb7n1on{0%{transform:rotate(0deg);}100%{transform:rotate(360deg);}}\", \"@keyframes f1gx3jof{0%{transform:rotate(0deg);}100%{transform:rotate(-360deg);}}\"],\n d: [\".f5tbecn>svg{animation-name:fb7n1on;}\", \".f15qb8s7>svg{animation-name:f1gx3jof;}\", \".fn4mtlg>svg{animation-duration:3s;}\", \".f1y80fxs>svg{animation-iteration-count:infinite;}\", \".f1r2crtq>svg{animation-timing-function:linear;}\", \".f1wsi8sr>svg{background-color:transparent;}\", \".f1da2vov>svg>circle{cx:50%;}\", \".f11rfva0>svg>circle{cy:50%;}\", \".f1exc66>svg>circle{fill:none;}\", \".f1x2gjcb>svg{height:16px;}\", \".f1vjiaua>svg{width:16px;}\", \".fv1u54w>svg>circle{stroke-width:var(--strokeWidthThick);}\", \".f1oebb0s>svg>circle{r:7px;}\", \".f1j4wmu2>svg{height:20px;}\", \".f1vppzuq>svg{width:20px;}\", \".fngtx1d>svg>circle{r:9px;}\", \".fmpqlna>svg{height:24px;}\", \".f15z5jzu>svg{width:24px;}\", \".fadawes>svg>circle{r:11px;}\", \".fo52gbo>svg{height:28px;}\", \".f1b41i3v>svg{width:28px;}\", \".f1xqyyrl>svg>circle{r:13px;}\", \".f1aiqagr>svg{height:32px;}\", \".f1wtx80b>svg{width:32px;}\", \".f1flujpd>svg>circle{stroke-width:var(--strokeWidthThicker);}\", \".f1u06hy7>svg>circle{r:14.5px;}\", \".f1trdq7b>svg{height:36px;}\", \".f9e0mc5>svg{width:36px;}\", \".f13pmvhl>svg>circle{r:16.5px;}\", \".f89rf2a>svg{height:40px;}\", \".f1w2xg3q>svg{width:40px;}\", \".fmn74v6>svg>circle{r:18.5px;}\", \".f1rx7k5y>svg{height:44px;}\", \".f1vtyt49>svg{width:44px;}\", \".f1owbg48>svg>circle{stroke-width:var(--strokeWidthThickest);}\", \".f1fr1izd>svg>circle{r:20px;}\"],\n m: [[\"@media screen and (prefers-reduced-motion: reduce){.f1bkm2qd>svg{animation-duration:0.01ms;}}\", {\n m: \"screen and (prefers-reduced-motion: reduce)\"\n }], [\"@media screen and (prefers-reduced-motion: reduce){.f1urqz7h>svg{animation-iteration-count:1;}}\", {\n m: \"screen and (prefers-reduced-motion: reduce)\"\n }]]\n});\nconst useTrackStyles = /*#__PURE__*/__styles({\n inverted: {\n gwg7kz: \"f1jvpmnu\",\n Bvrehnu: \"fq8a5sv\",\n Bidp6o: \"f1b4lwqj\",\n cq3kgi: \"f1najlst\",\n Btwiser: \"fjxod4\",\n B8001xd: \"fu3xdw0\",\n Bdordwa: [\"f1ttdh6v\", \"fmyjox0\"],\n Bo2mdfu: \"f1eseayc\",\n E10nrc: \"folzdkc\",\n Bwl7w15: \"fhlfkde\",\n Bksq7rz: \"f1esql28\"\n },\n primary: {\n gwg7kz: \"f11ditju\",\n B8k2rxp: \"f1m9nikz\",\n Bvrehnu: \"fq8a5sv\",\n Bidp6o: \"f1b4lwqj\",\n cq3kgi: \"f1najlst\",\n Btwiser: \"fjxod4\",\n B8001xd: \"fu3xdw0\",\n Bdordwa: [\"f1ttdh6v\", \"fmyjox0\"],\n Bo2mdfu: \"f1eseayc\",\n E10nrc: \"folzdkc\",\n Bwl7w15: \"fhlfkde\",\n Bksq7rz: \"f61h2gu\",\n y14cdu: \"flglbw1\"\n }\n}, {\n d: [\".f1jvpmnu>svg>circle.fui-Spinner__Tail{stroke:var(--colorNeutralStrokeOnBrand2);}\", \".fq8a5sv>svg>circle.fui-Spinner__Tail{animation-name:f1v1ql0f;}\", \".f1b4lwqj>svg>circle.fui-Spinner__Tail{animation-duration:1.5s;}\", \".f1najlst>svg>circle.fui-Spinner__Tail{animation-iteration-count:infinite;}\", \".fjxod4>svg>circle.fui-Spinner__Tail{animation-timing-function:var(--curveEasyEase);}\", \".fu3xdw0>svg>circle.fui-Spinner__Tail{stroke-linecap:round;}\", \".f1ttdh6v>svg>circle.fui-Spinner__Tail{transform:rotate(-90deg);}\", \".fmyjox0>svg>circle.fui-Spinner__Tail{transform:rotate(90deg);}\", \".f1eseayc>svg>circle.fui-Spinner__Tail{transform-origin:50% 50%;}\", \".f1esql28>svg>circle.fui-Spinner__Track{stroke:rgba(255, 255, 255, 0.2);}\", \".f11ditju>svg>circle.fui-Spinner__Tail{stroke:var(--colorBrandStroke1);}\", \".f61h2gu>svg>circle.fui-Spinner__Track{stroke:var(--colorBrandStroke2);}\"],\n k: [\"@keyframes f1v1ql0f{0%{stroke-dasharray:1,150;stroke-dashoffset:0;}50%{stroke-dasharray:90,150;stroke-dashoffset:-35;}100%{stroke-dasharray:90,150;stroke-dashoffset:-124;}}\"],\n m: [[\"@media screen and (prefers-reduced-motion: reduce){.folzdkc>svg>circle.fui-Spinner__Tail{animation-duration:0.01ms;}}\", {\n m: \"screen and (prefers-reduced-motion: reduce)\"\n }], [\"@media screen and (prefers-reduced-motion: reduce){.fhlfkde>svg>circle.fui-Spinner__Tail{animation-iteration-count:1;}}\", {\n m: \"screen and (prefers-reduced-motion: reduce)\"\n }], [\"@media screen and (forced-colors: active){.f1m9nikz>svg>circle.fui-Spinner__Tail{stroke:var(--colorNeutralStrokeOnBrand2);}}\", {\n m: \"screen and (forced-colors: active)\"\n }], [\"@media screen and (forced-colors: active){.flglbw1>svg>circle.fui-Spinner__Track{stroke:var(--colorNeutralBackgroundInverted);}}\", {\n m: \"screen and (forced-colors: active)\"\n }]]\n});\nconst useLabelStyles = /*#__PURE__*/__styles({\n inverted: {\n sj55zd: \"f15aqcq\"\n },\n primary: {},\n \"extra-tiny\": {\n Bahqtrf: \"fk6fouc\",\n Be2twd7: \"fkhj508\",\n Bhrd7zp: \"figsok6\",\n Bg96gwp: \"f1i3iumi\"\n },\n tiny: {\n Bahqtrf: \"fk6fouc\",\n Be2twd7: \"fkhj508\",\n Bhrd7zp: \"figsok6\",\n Bg96gwp: \"f1i3iumi\"\n },\n \"extra-small\": {\n Bahqtrf: \"fk6fouc\",\n Be2twd7: \"fkhj508\",\n Bhrd7zp: \"figsok6\",\n Bg96gwp: \"f1i3iumi\"\n },\n small: {\n Bahqtrf: \"fk6fouc\",\n Be2twd7: \"fkhj508\",\n Bhrd7zp: \"figsok6\",\n Bg96gwp: \"f1i3iumi\"\n },\n medium: {\n Bahqtrf: \"fk6fouc\",\n Be2twd7: \"fod5ikn\",\n Bhrd7zp: \"fl43uef\",\n Bg96gwp: \"faaz57k\"\n },\n large: {\n Bahqtrf: \"fk6fouc\",\n Be2twd7: \"fod5ikn\",\n Bhrd7zp: \"fl43uef\",\n Bg96gwp: \"faaz57k\"\n },\n \"extra-large\": {\n Bahqtrf: \"fk6fouc\",\n Be2twd7: \"fod5ikn\",\n Bhrd7zp: \"fl43uef\",\n Bg96gwp: \"faaz57k\"\n },\n huge: {\n Bahqtrf: \"fk6fouc\",\n Be2twd7: \"f1pp30po\",\n Bhrd7zp: \"fl43uef\",\n Bg96gwp: \"f106mvju\"\n }\n}, {\n d: [\".f15aqcq{color:rgba(255, 255, 255, 1);}\", \".fk6fouc{font-family:var(--fontFamilyBase);}\", \".fkhj508{font-size:var(--fontSizeBase300);}\", \".figsok6{font-weight:var(--fontWeightRegular);}\", \".f1i3iumi{line-height:var(--lineHeightBase300);}\", \".fod5ikn{font-size:var(--fontSizeBase400);}\", \".fl43uef{font-weight:var(--fontWeightSemibold);}\", \".faaz57k{line-height:var(--lineHeightBase400);}\", \".f1pp30po{font-size:var(--fontSizeBase500);}\", \".f106mvju{line-height:var(--lineHeightBase500);}\"]\n});\n/**\n * Apply styling to the Spinner slots based on the state\n */\nexport const useSpinnerStyles_unstable = state => {\n const {\n labelPosition,\n size,\n appearance = 'primary'\n } = state;\n const rootStyles = useRootStyles();\n const spinnerStyles = useLoaderStyles();\n const labelStyles = useLabelStyles();\n const trackStyles = useTrackStyles();\n state.root.className = mergeClasses(spinnerClassNames.root, rootStyles.root, (labelPosition === 'above' || labelPosition === 'below') && rootStyles.vertical, (labelPosition === 'before' || labelPosition === 'after') && rootStyles.horizontal, state.root.className);\n if (state.spinner) {\n state.spinner.className = mergeClasses(spinnerClassNames.spinner, spinnerStyles.spinnerSVG, spinnerStyles[size], trackStyles[appearance], state.spinner.className);\n }\n if (state.label) {\n state.label.className = mergeClasses(spinnerClassNames.label, labelStyles[size], labelStyles[appearance], state.label.className);\n }\n return state;\n};\n//# sourceMappingURL=useSpinnerStyles.styles.js.map"],"names":["spinnerClassNames","useSpinnerStyles_unstable","root","spinner","label","rValues","extraTiny","tiny","extraSmall","small","medium","large","extraLarge","huge","spinnnerSizes","spinnerAnimation","container","animationDuration","animationIterationCount","animationTimingFunction","backgroundColor","useRootStyles","__styles","mc9l5x","Bt984gj","Brf1p80","Bg96gwp","i8kkvl","Belr9w4","horizontal","Beiy3e4","vertical","d","useLoaderStyles","spinnerSVG","B3aqqti","Brovlpu","Bxa1mx5","Bwaue66","fyp1ls","ag6ruv","osj692","aq5vjd","tlu9e1","J3u96z","d32isg","Bsvqbuc","b3s3i5","Bah9ito","ut6tcf","B7p06xz","B807ibg","f","k","m","useTrackStyles","inverted","gwg7kz","Bvrehnu","Bidp6o","cq3kgi","Btwiser","B8001xd","Bdordwa","Bo2mdfu","E10nrc","Bwl7w15","Bksq7rz","primary","B8k2rxp","y14cdu","useLabelStyles","sj55zd","Bahqtrf","Be2twd7","Bhrd7zp","state","labelPosition","size","appearance","rootStyles","spinnerStyles","labelStyles","trackStyles","className","mergeClasses"],"mappings":";;;;;;;;;;;IAEaA,iBAAiB,MAAjBA;IAiPAC,yBAAyB,MAAzBA;;uBAnPsC;AAE5C,MAAMD,oBAAoB;IAC/BE,MAAM;IACNC,SAAS;IACTC,OAAO;AACT;AACA;;;CAGC,GACD,MAAMC,UAAU;IACdC,WAAW;IACXC,MAAM;IACNC,YAAY;IACZC,OAAO;IACPC,QAAQ;IACRC,OAAO;IACPC,YAAY;IACZC,MAAM;AACR;AACA;;;CAGC,GACD,MAAMC,gBAAgB;IACpBR,WAAW;IACXC,MAAM;IACNC,YAAY;IACZC,OAAO;IACPC,QAAQ;IACRC,OAAO;IACPC,YAAY;IACZC,MAAM;AACR;AACA;;;CAGC,GACD,MAAME,mBAAmB;IACvBC,WAAW;QACTC,mBAAmB;QACnBC,yBAAyB;QACzBC,yBAAyB;QACzBC,iBAAiB;IACnB;AACF;AACA;;CAEC,GACD,MAAMC,gBAAgB,WAAW,GAAEC,IAAAA,kBAAQ,EAAC;IAC1CpB,MAAM;QACJqB,QAAQ;QACRC,SAAS;QACTC,SAAS;QACTC,SAAS;QACTC,QAAQ;QACRC,SAAS;IACX;IACAC,YAAY;QACVC,SAAS;IACX;IACAC,UAAU;QACRD,SAAS;IACX;AACF,GAAG;IACDE,GAAG;QAAC;QAA2B;QAAiC;QAAqC;QAA4B;QAA6B;QAA0B;QAAkC;KAAoC;AAChQ;AACA,MAAMC,kBAAkB,WAAW,GAAEX,IAAAA,kBAAQ,EAAC;IAC5CY,YAAY;QACVC,SAAS;QACTC,SAAS;QACTC,SAAS;QACTC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sources":["useSpinnerStyles.styles.js"],"sourcesContent":["import { __styles, mergeClasses, shorthands } from '@griffel/react';\nimport { tokens, typographyStyles } from '@fluentui/react-theme';\nexport const spinnerClassNames = {\n root: 'fui-Spinner',\n spinner: 'fui-Spinner__spinner',\n label: 'fui-Spinner__label'\n};\n/*\n * TODO: Update with proper tokens when added\n * Radii for the Spinner circles\n */\nconst rValues = {\n extraTiny: '7px',\n tiny: '9px',\n extraSmall: '11px',\n small: '13px',\n medium: '14.5px',\n large: '16.5px',\n extraLarge: '18.5px',\n huge: '20px'\n};\n/*\n * TODO: Update with proper tokens when added\n * Sizes for the Spinner\n */\nconst spinnnerSizes = {\n extraTiny: '16px',\n tiny: '20px',\n extraSmall: '24px',\n small: '28px',\n medium: '32px',\n large: '36px',\n extraLarge: '40px',\n huge: '44px'\n};\n/*\n * TODO: Update with proper tokens when added\n * Animation for Spinner\n */\nconst spinnerAnimation = {\n container: {\n animationDuration: '3s',\n animationIterationCount: 'infinite',\n animationTimingFunction: 'linear',\n backgroundColor: 'transparent'\n }\n};\n/**\n * Styles for the root slot\n */\nconst useRootStyles = /*#__PURE__*/__styles({\n root: {\n mc9l5x: \"f22iagw\",\n Bt984gj: \"f122n59\",\n Brf1p80: \"f4d9j23\",\n Bg96gwp: \"fez10in\",\n i8kkvl: \"f4px1ci\",\n Belr9w4: \"fn67r4l\"\n },\n horizontal: {\n Beiy3e4: \"f1063pyq\"\n },\n vertical: {\n Beiy3e4: \"f1vx9l62\"\n }\n}, {\n d: [\".f22iagw{display:flex;}\", \".f122n59{align-items:center;}\", \".f4d9j23{justify-content:center;}\", \".fez10in{line-height:0;}\", \".f4px1ci{column-gap:8px;}\", \".fn67r4l{row-gap:8px;}\", \".f1063pyq{flex-direction:row;}\", \".f1vx9l62{flex-direction:column;}\"]\n});\nconst useLoaderStyles = /*#__PURE__*/__styles({\n spinnerSVG: {\n B3aqqti: \"f1or16p5\",\n Brovlpu: \"f1grzc83\",\n Bxa1mx5: \"f19shzzi\",\n Bwaue66: [\"f5tbecn\", \"f15qb8s7\"],\n fyp1ls: \"fn4mtlg\",\n ag6ruv: \"f1y80fxs\",\n osj692: \"f1r2crtq\",\n aq5vjd: \"f1wsi8sr\",\n tlu9e1: \"f1bkm2qd\",\n J3u96z: \"f1urqz7h\",\n d32isg: \"f1da2vov\",\n Bsvqbuc: \"f11rfva0\",\n b3s3i5: \"f1exc66\"\n },\n \"extra-tiny\": {\n Bah9ito: \"f1x2gjcb\",\n ut6tcf: \"f1vjiaua\",\n B7p06xz: \"fv1u54w\",\n B807ibg: \"f1oebb0s\"\n },\n tiny: {\n Bah9ito: \"f1j4wmu2\",\n ut6tcf: \"f1vppzuq\",\n B7p06xz: \"fv1u54w\",\n B807ibg: \"fngtx1d\"\n },\n \"extra-small\": {\n Bah9ito: \"fmpqlna\",\n ut6tcf: \"f15z5jzu\",\n B7p06xz: \"fv1u54w\",\n B807ibg: \"fadawes\"\n },\n small: {\n Bah9ito: \"fo52gbo\",\n ut6tcf: \"f1b41i3v\",\n B7p06xz: \"fv1u54w\",\n B807ibg: \"f1xqyyrl\"\n },\n medium: {\n Bah9ito: \"f1aiqagr\",\n ut6tcf: \"f1wtx80b\",\n B7p06xz: \"f1flujpd\",\n B807ibg: \"f1u06hy7\"\n },\n large: {\n Bah9ito: \"f1trdq7b\",\n ut6tcf: \"f9e0mc5\",\n B7p06xz: \"f1flujpd\",\n B807ibg: \"f13pmvhl\"\n },\n \"extra-large\": {\n Bah9ito: \"f89rf2a\",\n ut6tcf: \"f1w2xg3q\",\n B7p06xz: \"f1flujpd\",\n B807ibg: \"fmn74v6\"\n },\n huge: {\n Bah9ito: \"f1rx7k5y\",\n ut6tcf: \"f1vtyt49\",\n B7p06xz: \"f1owbg48\",\n B807ibg: \"f1fr1izd\"\n }\n}, {\n f: [\".f1or16p5:focus{outline-width:3px;}\", \".f1grzc83:focus{outline-style:solid;}\", \".f19shzzi:focus{outline-color:transparent;}\"],\n k: [\"@keyframes fb7n1on{0%{transform:rotate(0deg);}100%{transform:rotate(360deg);}}\", \"@keyframes f1gx3jof{0%{transform:rotate(0deg);}100%{transform:rotate(-360deg);}}\"],\n d: [\".f5tbecn>svg{animation-name:fb7n1on;}\", \".f15qb8s7>svg{animation-name:f1gx3jof;}\", \".fn4mtlg>svg{animation-duration:3s;}\", \".f1y80fxs>svg{animation-iteration-count:infinite;}\", \".f1r2crtq>svg{animation-timing-function:linear;}\", \".f1wsi8sr>svg{background-color:transparent;}\", \".f1da2vov>svg>circle{cx:50%;}\", \".f11rfva0>svg>circle{cy:50%;}\", \".f1exc66>svg>circle{fill:none;}\", \".f1x2gjcb>svg{height:16px;}\", \".f1vjiaua>svg{width:16px;}\", \".fv1u54w>svg>circle{stroke-width:var(--strokeWidthThick);}\", \".f1oebb0s>svg>circle{r:7px;}\", \".f1j4wmu2>svg{height:20px;}\", \".f1vppzuq>svg{width:20px;}\", \".fngtx1d>svg>circle{r:9px;}\", \".fmpqlna>svg{height:24px;}\", \".f15z5jzu>svg{width:24px;}\", \".fadawes>svg>circle{r:11px;}\", \".fo52gbo>svg{height:28px;}\", \".f1b41i3v>svg{width:28px;}\", \".f1xqyyrl>svg>circle{r:13px;}\", \".f1aiqagr>svg{height:32px;}\", \".f1wtx80b>svg{width:32px;}\", \".f1flujpd>svg>circle{stroke-width:var(--strokeWidthThicker);}\", \".f1u06hy7>svg>circle{r:14.5px;}\", \".f1trdq7b>svg{height:36px;}\", \".f9e0mc5>svg{width:36px;}\", \".f13pmvhl>svg>circle{r:16.5px;}\", \".f89rf2a>svg{height:40px;}\", \".f1w2xg3q>svg{width:40px;}\", \".fmn74v6>svg>circle{r:18.5px;}\", \".f1rx7k5y>svg{height:44px;}\", \".f1vtyt49>svg{width:44px;}\", \".f1owbg48>svg>circle{stroke-width:var(--strokeWidthThickest);}\", \".f1fr1izd>svg>circle{r:20px;}\"],\n m: [[\"@media screen and (prefers-reduced-motion: reduce){.f1bkm2qd>svg{animation-duration:0.01ms;}}\", {\n m: \"screen and (prefers-reduced-motion: reduce)\"\n }], [\"@media screen and (prefers-reduced-motion: reduce){.f1urqz7h>svg{animation-iteration-count:1;}}\", {\n m: \"screen and (prefers-reduced-motion: reduce)\"\n }]]\n});\nconst useTrackStyles = /*#__PURE__*/__styles({\n inverted: {\n gwg7kz: \"f1jvpmnu\",\n Bvrehnu: \"fq8a5sv\",\n Bidp6o: \"f1b4lwqj\",\n cq3kgi: \"f1najlst\",\n Btwiser: \"fjxod4\",\n B8001xd: \"fu3xdw0\",\n Bdordwa: [\"f1ttdh6v\", \"fmyjox0\"],\n Bo2mdfu: \"f1eseayc\",\n E10nrc: \"folzdkc\",\n Bwl7w15: \"fhlfkde\",\n Bksq7rz: \"f1esql28\"\n },\n primary: {\n gwg7kz: \"f11ditju\",\n B8k2rxp: \"f1m9nikz\",\n Bvrehnu: \"fq8a5sv\",\n Bidp6o: \"f1b4lwqj\",\n cq3kgi: \"f1najlst\",\n Btwiser: \"fjxod4\",\n B8001xd: \"fu3xdw0\",\n Bdordwa: [\"f1ttdh6v\", \"fmyjox0\"],\n Bo2mdfu: \"f1eseayc\",\n E10nrc: \"folzdkc\",\n Bwl7w15: \"fhlfkde\",\n Bksq7rz: \"f13qeqtg\",\n y14cdu: \"flglbw1\"\n }\n}, {\n d: [\".f1jvpmnu>svg>circle.fui-Spinner__Tail{stroke:var(--colorNeutralStrokeOnBrand2);}\", \".fq8a5sv>svg>circle.fui-Spinner__Tail{animation-name:f1v1ql0f;}\", \".f1b4lwqj>svg>circle.fui-Spinner__Tail{animation-duration:1.5s;}\", \".f1najlst>svg>circle.fui-Spinner__Tail{animation-iteration-count:infinite;}\", \".fjxod4>svg>circle.fui-Spinner__Tail{animation-timing-function:var(--curveEasyEase);}\", \".fu3xdw0>svg>circle.fui-Spinner__Tail{stroke-linecap:round;}\", \".f1ttdh6v>svg>circle.fui-Spinner__Tail{transform:rotate(-90deg);}\", \".fmyjox0>svg>circle.fui-Spinner__Tail{transform:rotate(90deg);}\", \".f1eseayc>svg>circle.fui-Spinner__Tail{transform-origin:50% 50%;}\", \".f1esql28>svg>circle.fui-Spinner__Track{stroke:rgba(255, 255, 255, 0.2);}\", \".f11ditju>svg>circle.fui-Spinner__Tail{stroke:var(--colorBrandStroke1);}\", \".f13qeqtg>svg>circle.fui-Spinner__Track{stroke:var(--colorBrandStroke2Contrast);}\"],\n k: [\"@keyframes f1v1ql0f{0%{stroke-dasharray:1,150;stroke-dashoffset:0;}50%{stroke-dasharray:90,150;stroke-dashoffset:-35;}100%{stroke-dasharray:90,150;stroke-dashoffset:-124;}}\"],\n m: [[\"@media screen and (prefers-reduced-motion: reduce){.folzdkc>svg>circle.fui-Spinner__Tail{animation-duration:0.01ms;}}\", {\n m: \"screen and (prefers-reduced-motion: reduce)\"\n }], [\"@media screen and (prefers-reduced-motion: reduce){.fhlfkde>svg>circle.fui-Spinner__Tail{animation-iteration-count:1;}}\", {\n m: \"screen and (prefers-reduced-motion: reduce)\"\n }], [\"@media screen and (forced-colors: active){.f1m9nikz>svg>circle.fui-Spinner__Tail{stroke:var(--colorNeutralStrokeOnBrand2);}}\", {\n m: \"screen and (forced-colors: active)\"\n }], [\"@media screen and (forced-colors: active){.flglbw1>svg>circle.fui-Spinner__Track{stroke:var(--colorNeutralBackgroundInverted);}}\", {\n m: \"screen and (forced-colors: active)\"\n }]]\n});\nconst useLabelStyles = /*#__PURE__*/__styles({\n inverted: {\n sj55zd: \"f15aqcq\"\n },\n primary: {},\n \"extra-tiny\": {\n Bahqtrf: \"fk6fouc\",\n Be2twd7: \"fkhj508\",\n Bhrd7zp: \"figsok6\",\n Bg96gwp: \"f1i3iumi\"\n },\n tiny: {\n Bahqtrf: \"fk6fouc\",\n Be2twd7: \"fkhj508\",\n Bhrd7zp: \"figsok6\",\n Bg96gwp: \"f1i3iumi\"\n },\n \"extra-small\": {\n Bahqtrf: \"fk6fouc\",\n Be2twd7: \"fkhj508\",\n Bhrd7zp: \"figsok6\",\n Bg96gwp: \"f1i3iumi\"\n },\n small: {\n Bahqtrf: \"fk6fouc\",\n Be2twd7: \"fkhj508\",\n Bhrd7zp: \"figsok6\",\n Bg96gwp: \"f1i3iumi\"\n },\n medium: {\n Bahqtrf: \"fk6fouc\",\n Be2twd7: \"fod5ikn\",\n Bhrd7zp: \"fl43uef\",\n Bg96gwp: \"faaz57k\"\n },\n large: {\n Bahqtrf: \"fk6fouc\",\n Be2twd7: \"fod5ikn\",\n Bhrd7zp: \"fl43uef\",\n Bg96gwp: \"faaz57k\"\n },\n \"extra-large\": {\n Bahqtrf: \"fk6fouc\",\n Be2twd7: \"fod5ikn\",\n Bhrd7zp: \"fl43uef\",\n Bg96gwp: \"faaz57k\"\n },\n huge: {\n Bahqtrf: \"fk6fouc\",\n Be2twd7: \"f1pp30po\",\n Bhrd7zp: \"fl43uef\",\n Bg96gwp: \"f106mvju\"\n }\n}, {\n d: [\".f15aqcq{color:rgba(255, 255, 255, 1);}\", \".fk6fouc{font-family:var(--fontFamilyBase);}\", \".fkhj508{font-size:var(--fontSizeBase300);}\", \".figsok6{font-weight:var(--fontWeightRegular);}\", \".f1i3iumi{line-height:var(--lineHeightBase300);}\", \".fod5ikn{font-size:var(--fontSizeBase400);}\", \".fl43uef{font-weight:var(--fontWeightSemibold);}\", \".faaz57k{line-height:var(--lineHeightBase400);}\", \".f1pp30po{font-size:var(--fontSizeBase500);}\", \".f106mvju{line-height:var(--lineHeightBase500);}\"]\n});\n/**\n * Apply styling to the Spinner slots based on the state\n */\nexport const useSpinnerStyles_unstable = state => {\n const {\n labelPosition,\n size,\n appearance = 'primary'\n } = state;\n const rootStyles = useRootStyles();\n const spinnerStyles = useLoaderStyles();\n const labelStyles = useLabelStyles();\n const trackStyles = useTrackStyles();\n state.root.className = mergeClasses(spinnerClassNames.root, rootStyles.root, (labelPosition === 'above' || labelPosition === 'below') && rootStyles.vertical, (labelPosition === 'before' || labelPosition === 'after') && rootStyles.horizontal, state.root.className);\n if (state.spinner) {\n state.spinner.className = mergeClasses(spinnerClassNames.spinner, spinnerStyles.spinnerSVG, spinnerStyles[size], trackStyles[appearance], state.spinner.className);\n }\n if (state.label) {\n state.label.className = mergeClasses(spinnerClassNames.label, labelStyles[size], labelStyles[appearance], state.label.className);\n }\n return state;\n};\n//# sourceMappingURL=useSpinnerStyles.styles.js.map"],"names":["spinnerClassNames","useSpinnerStyles_unstable","root","spinner","label","rValues","extraTiny","tiny","extraSmall","small","medium","large","extraLarge","huge","spinnnerSizes","spinnerAnimation","container","animationDuration","animationIterationCount","animationTimingFunction","backgroundColor","useRootStyles","__styles","mc9l5x","Bt984gj","Brf1p80","Bg96gwp","i8kkvl","Belr9w4","horizontal","Beiy3e4","vertical","d","useLoaderStyles","spinnerSVG","B3aqqti","Brovlpu","Bxa1mx5","Bwaue66","fyp1ls","ag6ruv","osj692","aq5vjd","tlu9e1","J3u96z","d32isg","Bsvqbuc","b3s3i5","Bah9ito","ut6tcf","B7p06xz","B807ibg","f","k","m","useTrackStyles","inverted","gwg7kz","Bvrehnu","Bidp6o","cq3kgi","Btwiser","B8001xd","Bdordwa","Bo2mdfu","E10nrc","Bwl7w15","Bksq7rz","primary","B8k2rxp","y14cdu","useLabelStyles","sj55zd","Bahqtrf","Be2twd7","Bhrd7zp","state","labelPosition","size","appearance","rootStyles","spinnerStyles","labelStyles","trackStyles","className","mergeClasses"],"mappings":";;;;;;;;;;;IAEaA,iBAAiB;eAAjBA;;IAiPAC,yBAAyB;eAAzBA;;;uBAnPsC;AAE5C,MAAMD,oBAAoB;IAC/BE,MAAM;IACNC,SAAS;IACTC,OAAO;AACT;AACA;;;CAGC,GACD,MAAMC,UAAU;IACdC,WAAW;IACXC,MAAM;IACNC,YAAY;IACZC,OAAO;IACPC,QAAQ;IACRC,OAAO;IACPC,YAAY;IACZC,MAAM;AACR;AACA;;;CAGC,GACD,MAAMC,gBAAgB;IACpBR,WAAW;IACXC,MAAM;IACNC,YAAY;IACZC,OAAO;IACPC,QAAQ;IACRC,OAAO;IACPC,YAAY;IACZC,MAAM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,EAAE+C,MAAM1E,IAAI,CAACkF,SAAS;IACtQ,IAAIR,MAAMzE,OAAO,EAAE;QACjByE,MAAMzE,OAAO,CAACiF,SAAS,GAAGC,IAAAA,mBAAY,EAACrF,kBAAkBG,OAAO,EAAE8E,cAAc/C,UAAU,EAAE+C,aAAa,CAACH,KAAK,EAAEK,WAAW,CAACJ,WAAW,EAAEH,MAAMzE,OAAO,CAACiF,SAAS;IACnK;IACA,IAAIR,MAAMxE,KAAK,EAAE;QACfwE,MAAMxE,KAAK,CAACgF,SAAS,GAAGC,IAAAA,mBAAY,EAACrF,kBAAkBI,KAAK,EAAE8E,WAAW,CAACJ,KAAK,EAAEI,WAAW,CAACH,WAAW,EAAEH,MAAMxE,KAAK,CAACgF,SAAS;IACjI;IACA,OAAOR;AACT,GACA,mDAAmD"}
|
|
@@ -9,11 +9,15 @@ function _export(target, all) {
|
|
|
9
9
|
});
|
|
10
10
|
}
|
|
11
11
|
_export(exports, {
|
|
12
|
-
SpinnerContextProvider: ()
|
|
13
|
-
|
|
12
|
+
SpinnerContextProvider: function() {
|
|
13
|
+
return SpinnerContextProvider;
|
|
14
|
+
},
|
|
15
|
+
useSpinnerContext: function() {
|
|
16
|
+
return useSpinnerContext;
|
|
17
|
+
}
|
|
14
18
|
});
|
|
15
|
-
const
|
|
16
|
-
const _react = /*#__PURE__*/
|
|
19
|
+
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
|
20
|
+
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
|
17
21
|
const SpinnerContext = /*#__PURE__*/ _react.createContext(undefined);
|
|
18
22
|
const SpinnerContextDefaultValue = {};
|
|
19
23
|
const SpinnerContextProvider = SpinnerContext.Provider;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["SpinnerContext.js"],"sourcesContent":["import * as React from 'react';\nconst SpinnerContext = React.createContext(undefined);\nconst SpinnerContextDefaultValue = {};\n/**\n * @internal\n */ export const SpinnerContextProvider = SpinnerContext.Provider;\nvar _React_useContext;\n/**\n * @internal\n */ export const useSpinnerContext = ()=>(_React_useContext = React.useContext(SpinnerContext)) !== null && _React_useContext !== void 0 ? _React_useContext : SpinnerContextDefaultValue;\n"],"names":["SpinnerContextProvider","useSpinnerContext","SpinnerContext","React","createContext","undefined","SpinnerContextDefaultValue","Provider","_React_useContext","useContext"],"mappings":";;;;;;;;;;;IAKiBA,sBAAsB
|
|
1
|
+
{"version":3,"sources":["SpinnerContext.js"],"sourcesContent":["import * as React from 'react';\nconst SpinnerContext = React.createContext(undefined);\nconst SpinnerContextDefaultValue = {};\n/**\n * @internal\n */ export const SpinnerContextProvider = SpinnerContext.Provider;\nvar _React_useContext;\n/**\n * @internal\n */ export const useSpinnerContext = ()=>(_React_useContext = React.useContext(SpinnerContext)) !== null && _React_useContext !== void 0 ? _React_useContext : SpinnerContextDefaultValue;\n"],"names":["SpinnerContextProvider","useSpinnerContext","SpinnerContext","React","createContext","undefined","SpinnerContextDefaultValue","Provider","_React_useContext","useContext"],"mappings":";;;;;;;;;;;IAKiBA,sBAAsB;eAAtBA;;IAIAC,iBAAiB;eAAjBA;;;;iEATM;AACvB,MAAMC,+BAAiBC,OAAMC,aAAa,CAACC;AAC3C,MAAMC,6BAA6B,CAAC;AAGzB,MAAMN,yBAAyBE,eAAeK,QAAQ;AACjE,IAAIC;AAGO,MAAMP,oBAAoB,IAAI,AAACO,CAAAA,oBAAoBL,OAAMM,UAAU,CAACP,eAAc,MAAO,QAAQM,sBAAsB,KAAK,IAAIA,oBAAoBF"}
|
|
@@ -2,5 +2,5 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", {
|
|
3
3
|
value: true
|
|
4
4
|
});
|
|
5
|
-
const
|
|
6
|
-
|
|
5
|
+
const _export_star = require("@swc/helpers/_/_export_star");
|
|
6
|
+
_export_star._(require("./SpinnerContext"), exports);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["index.js"],"sourcesContent":["export * from './SpinnerContext';\n"],"names":[],"mappings":";;;;;
|
|
1
|
+
{"version":3,"sources":["index.js"],"sourcesContent":["export * from './SpinnerContext';\n"],"names":[],"mappings":";;;;;uBAAc"}
|
package/lib-commonjs/index.js
CHANGED
|
@@ -9,13 +9,27 @@ function _export(target, all) {
|
|
|
9
9
|
});
|
|
10
10
|
}
|
|
11
11
|
_export(exports, {
|
|
12
|
-
Spinner: ()
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
12
|
+
Spinner: function() {
|
|
13
|
+
return _Spinner.Spinner;
|
|
14
|
+
},
|
|
15
|
+
spinnerClassNames: function() {
|
|
16
|
+
return _Spinner.spinnerClassNames;
|
|
17
|
+
},
|
|
18
|
+
renderSpinner_unstable: function() {
|
|
19
|
+
return _Spinner.renderSpinner_unstable;
|
|
20
|
+
},
|
|
21
|
+
useSpinner_unstable: function() {
|
|
22
|
+
return _Spinner.useSpinner_unstable;
|
|
23
|
+
},
|
|
24
|
+
useSpinnerStyles_unstable: function() {
|
|
25
|
+
return _Spinner.useSpinnerStyles_unstable;
|
|
26
|
+
},
|
|
27
|
+
SpinnerContextProvider: function() {
|
|
28
|
+
return _index.SpinnerContextProvider;
|
|
29
|
+
},
|
|
30
|
+
useSpinnerContext: function() {
|
|
31
|
+
return _index.useSpinnerContext;
|
|
32
|
+
}
|
|
19
33
|
});
|
|
20
|
-
const
|
|
34
|
+
const _Spinner = require("./Spinner");
|
|
21
35
|
const _index = require("./contexts/index");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["index.js"],"sourcesContent":["export { Spinner, spinnerClassNames, renderSpinner_unstable, useSpinner_unstable, useSpinnerStyles_unstable } from './Spinner';\nexport { SpinnerContextProvider, useSpinnerContext } from './contexts/index';\n"],"names":["Spinner","spinnerClassNames","renderSpinner_unstable","useSpinner_unstable","useSpinnerStyles_unstable","SpinnerContextProvider","useSpinnerContext"],"mappings":";;;;;;;;;;;IAASA,OAAO,
|
|
1
|
+
{"version":3,"sources":["index.js"],"sourcesContent":["export { Spinner, spinnerClassNames, renderSpinner_unstable, useSpinner_unstable, useSpinnerStyles_unstable } from './Spinner';\nexport { SpinnerContextProvider, useSpinnerContext } from './contexts/index';\n"],"names":["Spinner","spinnerClassNames","renderSpinner_unstable","useSpinner_unstable","useSpinnerStyles_unstable","SpinnerContextProvider","useSpinnerContext"],"mappings":";;;;;;;;;;;IAASA,OAAO;eAAPA,gBAAO;;IAAEC,iBAAiB;eAAjBA,0BAAiB;;IAAEC,sBAAsB;eAAtBA,+BAAsB;;IAAEC,mBAAmB;eAAnBA,4BAAmB;;IAAEC,yBAAyB;eAAzBA,kCAAyB;;IAClGC,sBAAsB;eAAtBA,6BAAsB;;IAAEC,iBAAiB;eAAjBA,wBAAiB;;;yBADiE;uBACzD"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluentui/react-spinner",
|
|
3
|
-
"version": "9.3.
|
|
3
|
+
"version": "9.3.11",
|
|
4
4
|
"description": "Spinner component for Fluent UI React",
|
|
5
5
|
"main": "lib-commonjs/index.js",
|
|
6
6
|
"module": "lib/index.js",
|
|
@@ -33,19 +33,19 @@
|
|
|
33
33
|
"@fluentui/scripts-tasks": "*"
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
|
-
"@fluentui/react-jsx-runtime": "^9.0.
|
|
37
|
-
"@fluentui/react-label": "^9.1.
|
|
38
|
-
"@fluentui/react-shared-contexts": "^9.7.
|
|
39
|
-
"@fluentui/react-theme": "^9.1.
|
|
40
|
-
"@fluentui/react-utilities": "^9.13.
|
|
36
|
+
"@fluentui/react-jsx-runtime": "^9.0.4",
|
|
37
|
+
"@fluentui/react-label": "^9.1.31",
|
|
38
|
+
"@fluentui/react-shared-contexts": "^9.7.3",
|
|
39
|
+
"@fluentui/react-theme": "^9.1.12",
|
|
40
|
+
"@fluentui/react-utilities": "^9.13.1",
|
|
41
41
|
"@griffel/react": "^1.5.14",
|
|
42
|
-
"@swc/helpers": "^0.
|
|
42
|
+
"@swc/helpers": "^0.5.1"
|
|
43
43
|
},
|
|
44
44
|
"peerDependencies": {
|
|
45
|
-
"@types/react": ">=16.
|
|
46
|
-
"@types/react-dom": ">=16.
|
|
47
|
-
"react": ">=16.
|
|
48
|
-
"react-dom": ">=16.
|
|
45
|
+
"@types/react": ">=16.14.0 <19.0.0",
|
|
46
|
+
"@types/react-dom": ">=16.14.0 <19.0.0",
|
|
47
|
+
"react": ">=16.14.0 <19.0.0",
|
|
48
|
+
"react-dom": ">=16.14.0 <19.0.0"
|
|
49
49
|
},
|
|
50
50
|
"beachball": {
|
|
51
51
|
"disallowedChangeTypes": [
|