@fluentui/react-infobutton 9.0.0-beta.5 → 9.0.0-beta.50
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 +1498 -1
- package/CHANGELOG.md +527 -2
- package/dist/index.d.ts +68 -4
- package/lib/InfoButton.js +0 -1
- package/lib/InfoButton.js.map +1 -1
- package/lib/InfoLabel.js +1 -0
- package/lib/InfoLabel.js.map +1 -0
- package/lib/components/InfoButton/DefaultInfoButtonIcons.js +3 -4
- package/lib/components/InfoButton/DefaultInfoButtonIcons.js.map +1 -1
- package/lib/components/InfoButton/InfoButton.js +5 -7
- package/lib/components/InfoButton/InfoButton.js.map +1 -1
- package/lib/components/InfoButton/InfoButton.types.js +1 -2
- package/lib/components/InfoButton/InfoButton.types.js.map +1 -1
- package/lib/components/InfoButton/index.js +1 -2
- package/lib/components/InfoButton/index.js.map +1 -1
- package/lib/components/InfoButton/renderInfoButton.js +5 -16
- package/lib/components/InfoButton/renderInfoButton.js.map +1 -1
- package/lib/components/InfoButton/useInfoButton.js +49 -51
- package/lib/components/InfoButton/useInfoButton.js.map +1 -1
- package/lib/components/InfoButton/useInfoButtonStyles.styles.js +153 -0
- package/lib/components/InfoButton/useInfoButtonStyles.styles.js.map +1 -0
- package/lib/components/InfoLabel/InfoLabel.js +12 -0
- package/lib/components/InfoLabel/InfoLabel.js.map +1 -0
- package/lib/components/InfoLabel/InfoLabel.types.js +1 -0
- package/lib/components/InfoLabel/InfoLabel.types.js.map +1 -0
- package/lib/components/InfoLabel/index.js +5 -0
- package/lib/components/InfoLabel/index.js.map +1 -0
- package/lib/components/InfoLabel/renderInfoLabel.js +8 -0
- package/lib/components/InfoLabel/renderInfoLabel.js.map +1 -0
- package/lib/components/InfoLabel/useInfoLabel.js +77 -0
- package/lib/components/InfoLabel/useInfoLabel.js.map +1 -0
- package/lib/components/InfoLabel/useInfoLabelStyles.styles.js +43 -0
- package/lib/components/InfoLabel/useInfoLabelStyles.styles.js.map +1 -0
- package/lib/index.js +1 -1
- package/lib/index.js.map +1 -1
- package/lib-commonjs/InfoButton.js +3 -5
- package/lib-commonjs/InfoButton.js.map +1 -1
- package/lib-commonjs/InfoLabel.js +6 -0
- package/lib-commonjs/InfoLabel.js.map +1 -0
- package/lib-commonjs/components/InfoButton/DefaultInfoButtonIcons.js +16 -8
- package/lib-commonjs/components/InfoButton/DefaultInfoButtonIcons.js.map +1 -1
- package/lib-commonjs/components/InfoButton/InfoButton.js +15 -16
- package/lib-commonjs/components/InfoButton/InfoButton.js.map +1 -1
- package/lib-commonjs/components/InfoButton/InfoButton.types.js +1 -3
- package/lib-commonjs/components/InfoButton/InfoButton.types.js.map +1 -1
- package/lib-commonjs/components/InfoButton/index.js +7 -9
- package/lib-commonjs/components/InfoButton/index.js.map +1 -1
- package/lib-commonjs/components/InfoButton/renderInfoButton.js +12 -24
- package/lib-commonjs/components/InfoButton/renderInfoButton.js.map +1 -1
- package/lib-commonjs/components/InfoButton/useInfoButton.js +58 -66
- package/lib-commonjs/components/InfoButton/useInfoButton.js.map +1 -1
- package/lib-commonjs/components/InfoButton/useInfoButtonStyles.styles.js +340 -0
- package/lib-commonjs/components/InfoButton/useInfoButtonStyles.styles.js.map +1 -0
- package/lib-commonjs/components/InfoLabel/InfoLabel.js +19 -0
- package/lib-commonjs/components/InfoLabel/InfoLabel.js.map +1 -0
- package/lib-commonjs/components/InfoLabel/InfoLabel.types.js +4 -0
- package/lib-commonjs/components/InfoLabel/InfoLabel.types.js.map +1 -0
- package/lib-commonjs/components/InfoLabel/index.js +10 -0
- package/lib-commonjs/components/InfoLabel/index.js.map +1 -0
- package/lib-commonjs/components/InfoLabel/renderInfoLabel.js +14 -0
- package/lib-commonjs/components/InfoLabel/renderInfoLabel.js.map +1 -0
- package/lib-commonjs/components/InfoLabel/useInfoLabel.js +78 -0
- package/lib-commonjs/components/InfoLabel/useInfoLabel.js.map +1 -0
- package/lib-commonjs/components/InfoLabel/useInfoLabelStyles.styles.js +62 -0
- package/lib-commonjs/components/InfoLabel/useInfoLabelStyles.styles.js.map +1 -0
- package/lib-commonjs/index.js +20 -34
- package/lib-commonjs/index.js.map +1 -1
- package/package.json +18 -13
- package/lib/components/InfoButton/useInfoButtonStyles.js +0 -183
- package/lib/components/InfoButton/useInfoButtonStyles.js.map +0 -1
- package/lib-commonjs/components/InfoButton/useInfoButtonStyles.js +0 -190
- package/lib-commonjs/components/InfoButton/useInfoButtonStyles.js.map +0 -1
package/lib-commonjs/index.js
CHANGED
|
@@ -1,38 +1,24 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
2
|
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
|
|
3
|
+
value: true
|
|
5
4
|
});
|
|
6
|
-
|
|
7
|
-
var
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
5
|
+
function _export(target, all) {
|
|
6
|
+
for(var name in all)Object.defineProperty(target, name, {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: all[name]
|
|
9
|
+
});
|
|
10
|
+
}
|
|
11
|
+
_export(exports, {
|
|
12
|
+
InfoButton: ()=>_infoButton.InfoButton,
|
|
13
|
+
infoButtonClassNames: ()=>_infoButton.infoButtonClassNames,
|
|
14
|
+
renderInfoButton_unstable: ()=>_infoButton.renderInfoButton_unstable,
|
|
15
|
+
useInfoButtonStyles_unstable: ()=>_infoButton.useInfoButtonStyles_unstable,
|
|
16
|
+
useInfoButton_unstable: ()=>_infoButton.useInfoButton_unstable,
|
|
17
|
+
InfoLabel: ()=>_infoLabel.InfoLabel,
|
|
18
|
+
infoLabelClassNames: ()=>_infoLabel.infoLabelClassNames,
|
|
19
|
+
renderInfoLabel_unstable: ()=>_infoLabel.renderInfoLabel_unstable,
|
|
20
|
+
useInfoLabelStyles_unstable: ()=>_infoLabel.useInfoLabelStyles_unstable,
|
|
21
|
+
useInfoLabel_unstable: ()=>_infoLabel.useInfoLabel_unstable
|
|
13
22
|
});
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
get: function () {
|
|
17
|
-
return InfoButton_1.infoButtonClassNames;
|
|
18
|
-
}
|
|
19
|
-
});
|
|
20
|
-
Object.defineProperty(exports, "renderInfoButton_unstable", {
|
|
21
|
-
enumerable: true,
|
|
22
|
-
get: function () {
|
|
23
|
-
return InfoButton_1.renderInfoButton_unstable;
|
|
24
|
-
}
|
|
25
|
-
});
|
|
26
|
-
Object.defineProperty(exports, "useInfoButtonStyles_unstable", {
|
|
27
|
-
enumerable: true,
|
|
28
|
-
get: function () {
|
|
29
|
-
return InfoButton_1.useInfoButtonStyles_unstable;
|
|
30
|
-
}
|
|
31
|
-
});
|
|
32
|
-
Object.defineProperty(exports, "useInfoButton_unstable", {
|
|
33
|
-
enumerable: true,
|
|
34
|
-
get: function () {
|
|
35
|
-
return InfoButton_1.useInfoButton_unstable;
|
|
36
|
-
}
|
|
37
|
-
});
|
|
38
|
-
//# sourceMappingURL=index.js.map
|
|
23
|
+
const _infoButton = require("./InfoButton");
|
|
24
|
+
const _infoLabel = require("./InfoLabel");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"
|
|
1
|
+
{"version":3,"sources":["index.js"],"sourcesContent":["export { InfoButton, infoButtonClassNames, renderInfoButton_unstable, useInfoButtonStyles_unstable, useInfoButton_unstable } from './InfoButton';\nexport { InfoLabel, infoLabelClassNames, renderInfoLabel_unstable, useInfoLabelStyles_unstable, useInfoLabel_unstable } from './InfoLabel';\n"],"names":["InfoButton","infoButtonClassNames","renderInfoButton_unstable","useInfoButtonStyles_unstable","useInfoButton_unstable","InfoLabel","infoLabelClassNames","renderInfoLabel_unstable","useInfoLabelStyles_unstable","useInfoLabel_unstable"],"mappings":";;;;;;;;;;;IAASA,UAAU,MAAVA,sBAAU;IAAEC,oBAAoB,MAApBA,gCAAoB;IAAEC,yBAAyB,MAAzBA,qCAAyB;IAAEC,4BAA4B,MAA5BA,wCAA4B;IAAEC,sBAAsB,MAAtBA,kCAAsB;IACjHC,SAAS,MAATA,oBAAS;IAAEC,mBAAmB,MAAnBA,8BAAmB;IAAEC,wBAAwB,MAAxBA,mCAAwB;IAAEC,2BAA2B,MAA3BA,sCAA2B;IAAEC,qBAAqB,MAArBA,gCAAqB;;4BADa;2BACL"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluentui/react-infobutton",
|
|
3
|
-
"version": "9.0.0-beta.
|
|
3
|
+
"version": "9.0.0-beta.50",
|
|
4
4
|
"description": "React components for building web experiences",
|
|
5
5
|
"main": "lib-commonjs/index.js",
|
|
6
6
|
"module": "lib/index.js",
|
|
@@ -13,31 +13,35 @@
|
|
|
13
13
|
"license": "MIT",
|
|
14
14
|
"scripts": {
|
|
15
15
|
"build": "just-scripts build",
|
|
16
|
-
"bundle-size": "
|
|
16
|
+
"bundle-size": "monosize measure",
|
|
17
17
|
"clean": "just-scripts clean",
|
|
18
18
|
"code-style": "just-scripts code-style",
|
|
19
19
|
"just": "just-scripts",
|
|
20
20
|
"lint": "just-scripts lint",
|
|
21
21
|
"test": "jest --passWithNoTests",
|
|
22
|
-
"generate-api": "
|
|
22
|
+
"generate-api": "just-scripts generate-api",
|
|
23
23
|
"type-check": "tsc -b tsconfig.json",
|
|
24
24
|
"storybook": "start-storybook",
|
|
25
|
-
"start": "yarn storybook"
|
|
25
|
+
"start": "yarn storybook",
|
|
26
|
+
"test-ssr": "test-ssr \"./stories/**/*.stories.tsx\""
|
|
26
27
|
},
|
|
27
28
|
"devDependencies": {
|
|
28
29
|
"@fluentui/eslint-plugin": "*",
|
|
29
30
|
"@fluentui/react-conformance": "*",
|
|
30
|
-
"@fluentui/react-conformance-griffel": "
|
|
31
|
-
"@fluentui/scripts": "*"
|
|
31
|
+
"@fluentui/react-conformance-griffel": "*",
|
|
32
|
+
"@fluentui/scripts-api-extractor": "*",
|
|
33
|
+
"@fluentui/scripts-tasks": "*"
|
|
32
34
|
},
|
|
33
35
|
"dependencies": {
|
|
34
|
-
"@fluentui/react-icons": "^2.0.
|
|
35
|
-
"@fluentui/react-
|
|
36
|
-
"@fluentui/react-
|
|
37
|
-
"@fluentui/react-
|
|
38
|
-
"@fluentui/react-
|
|
39
|
-
"@
|
|
40
|
-
"
|
|
36
|
+
"@fluentui/react-icons": "^2.0.207",
|
|
37
|
+
"@fluentui/react-label": "^9.1.26",
|
|
38
|
+
"@fluentui/react-popover": "^9.7.14",
|
|
39
|
+
"@fluentui/react-tabster": "^9.12.2",
|
|
40
|
+
"@fluentui/react-theme": "^9.1.11",
|
|
41
|
+
"@fluentui/react-utilities": "^9.11.1",
|
|
42
|
+
"@fluentui/react-jsx-runtime": "9.0.0-alpha.16",
|
|
43
|
+
"@griffel/react": "^1.5.14",
|
|
44
|
+
"@swc/helpers": "^0.4.14"
|
|
41
45
|
},
|
|
42
46
|
"peerDependencies": {
|
|
43
47
|
"@types/react": ">=16.8.0 <19.0.0",
|
|
@@ -55,6 +59,7 @@
|
|
|
55
59
|
"exports": {
|
|
56
60
|
".": {
|
|
57
61
|
"types": "./dist/index.d.ts",
|
|
62
|
+
"node": "./lib-commonjs/index.js",
|
|
58
63
|
"import": "./lib/index.js",
|
|
59
64
|
"require": "./lib-commonjs/index.js"
|
|
60
65
|
},
|
|
@@ -1,183 +0,0 @@
|
|
|
1
|
-
import { createCustomFocusIndicatorStyle } from '@fluentui/react-tabster';
|
|
2
|
-
import { iconFilledClassName, iconRegularClassName } from '@fluentui/react-icons';
|
|
3
|
-
import { __styles, mergeClasses, shorthands } from '@griffel/react';
|
|
4
|
-
import { tokens, typographyStyles } from '@fluentui/react-theme';
|
|
5
|
-
export const infoButtonClassNames = {
|
|
6
|
-
root: 'fui-InfoButton',
|
|
7
|
-
// this className won't be used, but it's needed to satisfy the type checker
|
|
8
|
-
popover: 'fui-InfoButton__popover',
|
|
9
|
-
content: 'fui-InfoButton__content'
|
|
10
|
-
};
|
|
11
|
-
/**
|
|
12
|
-
* Styles for the root slot
|
|
13
|
-
*/
|
|
14
|
-
const useButtonStyles = /*#__PURE__*/__styles({
|
|
15
|
-
base: {
|
|
16
|
-
Bt984gj: "f122n59",
|
|
17
|
-
B7ck84d: "f1ewtqcl",
|
|
18
|
-
mc9l5x: "ftuwxu6",
|
|
19
|
-
Brf1p80: "f4d9j23",
|
|
20
|
-
w71qe1: "f1iuv45f",
|
|
21
|
-
ha4doy: "fmrv4ls",
|
|
22
|
-
De3pzq: "f1c21dwh",
|
|
23
|
-
sj55zd: "fkfq4zb",
|
|
24
|
-
B68tc82: "f1p9o1ba",
|
|
25
|
-
Bmxbyg5: "f1sil6mw",
|
|
26
|
-
B4j52fo: "f192inf7",
|
|
27
|
-
Bekrc4i: ["f5tn483", "f1ojsxk5"],
|
|
28
|
-
Bn0qgzm: "f1vxd6vx",
|
|
29
|
-
ibv6hh: ["f1ojsxk5", "f5tn483"],
|
|
30
|
-
icvyot: "fzkkow9",
|
|
31
|
-
vrafjx: ["fcdblym", "fjik90z"],
|
|
32
|
-
oivjwe: "fg706s2",
|
|
33
|
-
wvpqe5: ["fjik90z", "fcdblym"],
|
|
34
|
-
g2u3we: "fghlq4f",
|
|
35
|
-
h3c5rm: ["f1gn591s", "fjscplz"],
|
|
36
|
-
B9xav0g: "fb073pr",
|
|
37
|
-
zhjwy3: ["fjscplz", "f1gn591s"],
|
|
38
|
-
Bbmb7ep: ["f1aa9q02", "f16jpd5f"],
|
|
39
|
-
Beyfa6y: ["f16jpd5f", "f1aa9q02"],
|
|
40
|
-
B7oj6ja: ["f1jar5jt", "fyu767a"],
|
|
41
|
-
Btl43ni: ["fyu767a", "f1jar5jt"],
|
|
42
|
-
B6of3ja: "f1hu3pq6",
|
|
43
|
-
t21cq0: ["f11qmguv", "f1tyq0we"],
|
|
44
|
-
jrapky: "f19f4twv",
|
|
45
|
-
Frg6f3: ["f1tyq0we", "f11qmguv"],
|
|
46
|
-
z8tnut: "f1ywm7hm",
|
|
47
|
-
z189sj: ["f7x41pl", "fruq291"],
|
|
48
|
-
Byoj8tv: "f14wxoun",
|
|
49
|
-
uwmqm3: ["fruq291", "f7x41pl"],
|
|
50
|
-
D0sxk3: "f16u1re",
|
|
51
|
-
t6yez3: "f1rw4040",
|
|
52
|
-
Jwef8y: "fjxutwb",
|
|
53
|
-
Bi91k9c: "f139oj5f",
|
|
54
|
-
Bk3fhr4: "f1jpd6y0",
|
|
55
|
-
Bmfj8id: "fuxngvv",
|
|
56
|
-
iro3zm: "fwiml72",
|
|
57
|
-
B2d53fq: "f1fg1p5m"
|
|
58
|
-
},
|
|
59
|
-
selected: {
|
|
60
|
-
De3pzq: "f1q9pm1r",
|
|
61
|
-
sj55zd: "f1qj7y59",
|
|
62
|
-
D0sxk3: "fgzdkf0",
|
|
63
|
-
t6yez3: "f15q0o9g",
|
|
64
|
-
Bsw6fvg: "f1rirnrt",
|
|
65
|
-
Bjwas2f: "f14pvji2",
|
|
66
|
-
Bn1d65q: ["f1xeojaw", "f1hodmrf"],
|
|
67
|
-
Bxeuatn: "fcbbwn3",
|
|
68
|
-
n51gp8: ["f1hodmrf", "f1xeojaw"],
|
|
69
|
-
Bbusuzp: "f1cg6951"
|
|
70
|
-
},
|
|
71
|
-
highContrast: {
|
|
72
|
-
Bjwas2f: "f14pvji2",
|
|
73
|
-
Bn1d65q: ["f1xeojaw", "f1hodmrf"],
|
|
74
|
-
Bxeuatn: "fcbbwn3",
|
|
75
|
-
n51gp8: ["f1hodmrf", "f1xeojaw"],
|
|
76
|
-
Bbusuzp: "fn0tkbb",
|
|
77
|
-
w76p1f: "f18rpr9v",
|
|
78
|
-
B3sm7at: "f5mt1fw",
|
|
79
|
-
fe9h6n: "f17188ff",
|
|
80
|
-
Bmhq1k7: ["fzyms9j", "f12bfk5t"],
|
|
81
|
-
E428ku: "f1ucftwv",
|
|
82
|
-
Bipfp3: ["f12bfk5t", "fzyms9j"],
|
|
83
|
-
nrfbsj: "f10s0nbj"
|
|
84
|
-
},
|
|
85
|
-
focusIndicator: {
|
|
86
|
-
Brovlpu: "ftqa4ok",
|
|
87
|
-
B486eqv: "f2hkw1w",
|
|
88
|
-
kdpuga: ["f1o2ludy", "f1kjnpwc"],
|
|
89
|
-
Bw81rd7: ["f1kjnpwc", "f1o2ludy"],
|
|
90
|
-
B6xbmo0: ["fxmnebo", "f1witrsb"],
|
|
91
|
-
dm238s: ["f1witrsb", "fxmnebo"],
|
|
92
|
-
B8q5s1w: "f1rzxaq5",
|
|
93
|
-
Bci5o5g: ["fipsau9", "f6jszy8"],
|
|
94
|
-
n8qw10: "f1emqxbc",
|
|
95
|
-
Bdrgwmp: ["f6jszy8", "fipsau9"],
|
|
96
|
-
Bfpq7zp: "fr1u5pk",
|
|
97
|
-
Bn4voq9: "f1p7hgxw",
|
|
98
|
-
g9k6zt: "f9znhxp",
|
|
99
|
-
j6ew2k: ["fvbipq7", "fvbipq7"],
|
|
100
|
-
Bhxq17a: "f1vjpng2"
|
|
101
|
-
},
|
|
102
|
-
large: {
|
|
103
|
-
z8tnut: "fclwglc",
|
|
104
|
-
z189sj: ["f1w3695s", "f1b0r8ql"],
|
|
105
|
-
Byoj8tv: "fywfov9",
|
|
106
|
-
uwmqm3: ["f1b0r8ql", "f1w3695s"]
|
|
107
|
-
}
|
|
108
|
-
}, {
|
|
109
|
-
d: [".f122n59{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}", ".f1ewtqcl{box-sizing:border-box;}", ".ftuwxu6{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;}", ".f4d9j23{-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;}", ".f1iuv45f{text-decoration-line:none;}", ".fmrv4ls{vertical-align:middle;}", ".f1c21dwh{background-color:var(--colorTransparentBackground);}", ".fkfq4zb{color:var(--colorNeutralForeground2);}", ".f1p9o1ba{overflow-x:hidden;}", ".f1sil6mw{overflow-y:hidden;}", ".f192inf7{border-top-width:var(--strokeWidthThin);}", ".f5tn483{border-right-width:var(--strokeWidthThin);}", ".f1ojsxk5{border-left-width:var(--strokeWidthThin);}", ".f1vxd6vx{border-bottom-width:var(--strokeWidthThin);}", ".fzkkow9{border-top-style:solid;}", ".fcdblym{border-right-style:solid;}", ".fjik90z{border-left-style:solid;}", ".fg706s2{border-bottom-style:solid;}", ".fghlq4f{border-top-color:var(--colorTransparentStroke);}", ".f1gn591s{border-right-color:var(--colorTransparentStroke);}", ".fjscplz{border-left-color:var(--colorTransparentStroke);}", ".fb073pr{border-bottom-color:var(--colorTransparentStroke);}", ".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}", ".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}", ".f1jar5jt{border-top-right-radius:var(--borderRadiusMedium);}", ".fyu767a{border-top-left-radius:var(--borderRadiusMedium);}", ".f1hu3pq6{margin-top:0;}", ".f11qmguv{margin-right:0;}", ".f1tyq0we{margin-left:0;}", ".f19f4twv{margin-bottom:0;}", ".f1ywm7hm{padding-top:var(--spacingVerticalXS);}", ".f7x41pl{padding-right:var(--spacingHorizontalXS);}", ".fruq291{padding-left:var(--spacingHorizontalXS);}", ".f14wxoun{padding-bottom:var(--spacingVerticalXS);}", ".f16u1re .fui-Icon-filled{display:none;}", ".f1rw4040 .fui-Icon-regular{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;}", ".f1q9pm1r{background-color:var(--colorTransparentBackgroundSelected);}", ".f1qj7y59{color:var(--colorNeutralForeground2BrandSelected);}", ".fgzdkf0 .fui-Icon-filled{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;}", ".f15q0o9g .fui-Icon-regular{display:none;}", ".f1o2ludy[data-fui-focus-visible]{border-bottom-right-radius:var(--borderRadiusMedium);}", ".f1kjnpwc[data-fui-focus-visible]{border-bottom-left-radius:var(--borderRadiusMedium);}", ".fxmnebo[data-fui-focus-visible]{border-top-right-radius:var(--borderRadiusMedium);}", ".f1witrsb[data-fui-focus-visible]{border-top-left-radius:var(--borderRadiusMedium);}", ".f1rzxaq5[data-fui-focus-visible]{border-top-color:var(--colorTransparentStroke);}", ".fipsau9[data-fui-focus-visible]{border-right-color:var(--colorTransparentStroke);}", ".f6jszy8[data-fui-focus-visible]{border-left-color:var(--colorTransparentStroke);}", ".f1emqxbc[data-fui-focus-visible]{border-bottom-color:var(--colorTransparentStroke);}", ".fr1u5pk[data-fui-focus-visible]{outline-color:var(--colorTransparentStroke);}", ".f1p7hgxw[data-fui-focus-visible]{outline-width:var(--strokeWidthThick);}", ".f9znhxp[data-fui-focus-visible]{outline-style:solid;}", ".fvbipq7[data-fui-focus-visible]{box-shadow:var(--shadow4),0 0 0 2px var(--colorStrokeFocus2);}", ".f1vjpng2[data-fui-focus-visible]{z-index:1;}", ".fclwglc{padding-top:var(--spacingVerticalXXS);}", ".f1w3695s{padding-right:var(--spacingVerticalXXS);}", ".f1b0r8ql{padding-left:var(--spacingVerticalXXS);}", ".fywfov9{padding-bottom:var(--spacingVerticalXXS);}"],
|
|
110
|
-
h: [".fjxutwb:hover{background-color:var(--colorTransparentBackgroundHover);}", ".f139oj5f:hover{color:var(--colorNeutralForeground2BrandHover);}", ".f1jpd6y0:hover .fui-Icon-filled{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;}", ".fuxngvv:hover .fui-Icon-regular{display:none;}", ".fwiml72:hover:active{background-color:var(--colorTransparentBackgroundPressed);}", ".f1fg1p5m:hover:active{color:var(--colorNeutralForeground2BrandPressed);}"],
|
|
111
|
-
m: [["@media (forced-colors: active){.f1rirnrt{background-color:Highlight;}}", {
|
|
112
|
-
m: "(forced-colors: active)"
|
|
113
|
-
}], ["@media (forced-colors: active){.f14pvji2{border-top-color:Canvas;}}", {
|
|
114
|
-
m: "(forced-colors: active)"
|
|
115
|
-
}], ["@media (forced-colors: active){.f1xeojaw{border-right-color:Canvas;}.f1hodmrf{border-left-color:Canvas;}}", {
|
|
116
|
-
m: "(forced-colors: active)"
|
|
117
|
-
}], ["@media (forced-colors: active){.fcbbwn3{border-bottom-color:Canvas;}}", {
|
|
118
|
-
m: "(forced-colors: active)"
|
|
119
|
-
}], ["@media (forced-colors: active){.f1hodmrf{border-left-color:Canvas;}.f1xeojaw{border-right-color:Canvas;}}", {
|
|
120
|
-
m: "(forced-colors: active)"
|
|
121
|
-
}], ["@media (forced-colors: active){.f1cg6951{color:Canvas;}}", {
|
|
122
|
-
m: "(forced-colors: active)"
|
|
123
|
-
}], ["@media (forced-colors: active){.f14pvji2{border-top-color:Canvas;}}", {
|
|
124
|
-
m: "(forced-colors: active)"
|
|
125
|
-
}], ["@media (forced-colors: active){.f1xeojaw{border-right-color:Canvas;}.f1hodmrf{border-left-color:Canvas;}}", {
|
|
126
|
-
m: "(forced-colors: active)"
|
|
127
|
-
}], ["@media (forced-colors: active){.fcbbwn3{border-bottom-color:Canvas;}}", {
|
|
128
|
-
m: "(forced-colors: active)"
|
|
129
|
-
}], ["@media (forced-colors: active){.f1hodmrf{border-left-color:Canvas;}.f1xeojaw{border-right-color:Canvas;}}", {
|
|
130
|
-
m: "(forced-colors: active)"
|
|
131
|
-
}], ["@media (forced-colors: active){.fn0tkbb{color:CanvasText;}}", {
|
|
132
|
-
m: "(forced-colors: active)"
|
|
133
|
-
}], ["@media (forced-colors: active){.f18rpr9v:hover,.f18rpr9v :hover:active{forced-color-adjust:none;}}", {
|
|
134
|
-
m: "(forced-colors: active)"
|
|
135
|
-
}], ["@media (forced-colors: active){.f5mt1fw:hover,.f5mt1fw :hover:active{background-color:Highlight;}}", {
|
|
136
|
-
m: "(forced-colors: active)"
|
|
137
|
-
}], ["@media (forced-colors: active){.f17188ff:hover,.f17188ff :hover:active{border-top-color:Canvas;}}", {
|
|
138
|
-
m: "(forced-colors: active)"
|
|
139
|
-
}], ["@media (forced-colors: active){.fzyms9j:hover,.fzyms9j :hover:active{border-right-color:Canvas;}.f12bfk5t:hover,.f12bfk5t :hover:active{border-left-color:Canvas;}}", {
|
|
140
|
-
m: "(forced-colors: active)"
|
|
141
|
-
}], ["@media (forced-colors: active){.f1ucftwv:hover,.f1ucftwv :hover:active{border-bottom-color:Canvas;}}", {
|
|
142
|
-
m: "(forced-colors: active)"
|
|
143
|
-
}], ["@media (forced-colors: active){.f12bfk5t:hover,.f12bfk5t :hover:active{border-left-color:Canvas;}.fzyms9j:hover,.fzyms9j :hover:active{border-right-color:Canvas;}}", {
|
|
144
|
-
m: "(forced-colors: active)"
|
|
145
|
-
}], ["@media (forced-colors: active){.f10s0nbj:hover,.f10s0nbj :hover:active{color:Canvas;}}", {
|
|
146
|
-
m: "(forced-colors: active)"
|
|
147
|
-
}]],
|
|
148
|
-
f: [".ftqa4ok:focus{outline-style:none;}"],
|
|
149
|
-
i: [".f2hkw1w:focus-visible{outline-style:none;}"]
|
|
150
|
-
});
|
|
151
|
-
const usePopoverSurfaceStyles = /*#__PURE__*/__styles({
|
|
152
|
-
smallMedium: {
|
|
153
|
-
Bahqtrf: "fk6fouc",
|
|
154
|
-
Be2twd7: "fy9rknc",
|
|
155
|
-
Bhrd7zp: "figsok6",
|
|
156
|
-
Bg96gwp: "fwrc4pm"
|
|
157
|
-
},
|
|
158
|
-
large: {
|
|
159
|
-
Bahqtrf: "fk6fouc",
|
|
160
|
-
Be2twd7: "fkhj508",
|
|
161
|
-
Bhrd7zp: "figsok6",
|
|
162
|
-
Bg96gwp: "f1i3iumi"
|
|
163
|
-
}
|
|
164
|
-
}, {
|
|
165
|
-
d: [".fk6fouc{font-family:var(--fontFamilyBase);}", ".fy9rknc{font-size:var(--fontSizeBase200);}", ".figsok6{font-weight:var(--fontWeightRegular);}", ".fwrc4pm{line-height:var(--lineHeightBase200);}", ".fkhj508{font-size:var(--fontSizeBase300);}", ".f1i3iumi{line-height:var(--lineHeightBase300);}"]
|
|
166
|
-
});
|
|
167
|
-
/**
|
|
168
|
-
* Apply styling to the InfoButton slots based on the state
|
|
169
|
-
*/
|
|
170
|
-
export const useInfoButtonStyles_unstable = state => {
|
|
171
|
-
const {
|
|
172
|
-
size
|
|
173
|
-
} = state;
|
|
174
|
-
const {
|
|
175
|
-
open
|
|
176
|
-
} = state.popover;
|
|
177
|
-
const buttonStyles = useButtonStyles();
|
|
178
|
-
const popoverSurfaceStyles = usePopoverSurfaceStyles();
|
|
179
|
-
state.content.className = mergeClasses(infoButtonClassNames.content, size === 'large' && popoverSurfaceStyles.large, state.content.className);
|
|
180
|
-
state.root.className = mergeClasses(infoButtonClassNames.root, buttonStyles.base, buttonStyles.highContrast, buttonStyles.focusIndicator, open && buttonStyles.selected, size === 'large' && buttonStyles.large, state.root.className);
|
|
181
|
-
return state;
|
|
182
|
-
};
|
|
183
|
-
//# sourceMappingURL=useInfoButtonStyles.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"mappings":"AAAA,SAASA,+BAA+B,QAAQ,yBAAyB;AACzE,SAASC,mBAAmB,EAAEC,oBAAoB,QAAQ,uBAAuB;AACjF,mBAAqBC,YAAY,EAAEC,UAAU,QAAQ,gBAAgB;AACrE,SAASC,MAAM,EAAEC,gBAAgB,QAAQ,uBAAuB;AAIhE,OAAO,MAAMC,oBAAoB,GAAoC;EACnEC,IAAI,EAAE,gBAAgB;EACtB;EACAC,OAAO,EAAE,yBAAyB;EAClCC,OAAO,EAAE;CACV;AAED;;;AAGA,MAAMC,eAAe,gBAAG;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;IAAA;IAAA;IAAA;EAAA;AAAA;EAAA;EAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;EAAA;EAAA;AAAA,EA0FtB;AAEF,MAAMC,uBAAuB,gBAAG;EAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;IAAA;IAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAG9B;AAEF;;;AAGA,OAAO,MAAMC,4BAA4B,GAAIC,KAAsB,IAAqB;EACtF,MAAM;IAAEC;EAAI,CAAE,GAAGD,KAAK;EACtB,MAAM;IAAEE;EAAI,CAAE,GAAGF,KAAK,CAACL,OAAO;EAC9B,MAAMQ,YAAY,GAAGN,eAAe,EAAE;EACtC,MAAMO,oBAAoB,GAAGN,uBAAuB,EAAE;EAEtDE,KAAK,CAACJ,OAAO,CAACS,SAAS,GAAGhB,YAAY,CACpCI,oBAAoB,CAACG,OAAO,EAC5BK,IAAI,KAAK,OAAO,IAAIG,oBAAoB,CAACE,KAAK,EAC9CN,KAAK,CAACJ,OAAO,CAACS,SAAS,CACxB;EAEDL,KAAK,CAACN,IAAI,CAACW,SAAS,GAAGhB,YAAY,CACjCI,oBAAoB,CAACC,IAAI,EACzBS,YAAY,CAACI,IAAI,EACjBJ,YAAY,CAACK,YAAY,EACzBL,YAAY,CAACM,cAAc,EAC3BP,IAAI,IAAIC,YAAY,CAACO,QAAQ,EAC7BT,IAAI,KAAK,OAAO,IAAIE,YAAY,CAACG,KAAK,EACtCN,KAAK,CAACN,IAAI,CAACW,SAAS,CACrB;EAED,OAAOL,KAAK;AACd,CAAC","names":["createCustomFocusIndicatorStyle","iconFilledClassName","iconRegularClassName","mergeClasses","shorthands","tokens","typographyStyles","infoButtonClassNames","root","popover","content","useButtonStyles","usePopoverSurfaceStyles","useInfoButtonStyles_unstable","state","size","open","buttonStyles","popoverSurfaceStyles","className","large","base","highContrast","focusIndicator","selected"],"sourceRoot":"../src/","sources":["packages/react-components/react-infobutton/src/components/InfoButton/useInfoButtonStyles.ts"],"sourcesContent":["import { createCustomFocusIndicatorStyle } from '@fluentui/react-tabster';\nimport { iconFilledClassName, iconRegularClassName } from '@fluentui/react-icons';\nimport { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport { tokens, typographyStyles } from '@fluentui/react-theme';\nimport type { InfoButtonSlots, InfoButtonState } from './InfoButton.types';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\n\nexport const infoButtonClassNames: SlotClassNames<InfoButtonSlots> = {\n root: 'fui-InfoButton',\n // this className won't be used, but it's needed to satisfy the type checker\n popover: 'fui-InfoButton__popover',\n content: 'fui-InfoButton__content',\n};\n\n/**\n * Styles for the root slot\n */\nconst useButtonStyles = makeStyles({\n base: {\n alignItems: 'center',\n boxSizing: 'border-box',\n display: 'inline-flex',\n justifyContent: 'center',\n textDecorationLine: 'none',\n verticalAlign: 'middle',\n\n backgroundColor: tokens.colorTransparentBackground,\n color: tokens.colorNeutralForeground2,\n\n ...shorthands.overflow('hidden'),\n ...shorthands.border(tokens.strokeWidthThin, 'solid', tokens.colorTransparentStroke),\n ...shorthands.borderRadius(tokens.borderRadiusMedium),\n ...shorthands.margin(0),\n ...shorthands.padding(tokens.spacingVerticalXS, tokens.spacingHorizontalXS),\n\n [`& .${iconFilledClassName}`]: {\n display: 'none',\n },\n [`& .${iconRegularClassName}`]: {\n display: 'inline-flex',\n },\n\n ':hover': {\n backgroundColor: tokens.colorTransparentBackgroundHover,\n color: tokens.colorNeutralForeground2BrandHover,\n\n [`& .${iconFilledClassName}`]: {\n display: 'inline-flex',\n },\n [`& .${iconRegularClassName}`]: {\n display: 'none',\n },\n },\n ':hover:active': {\n backgroundColor: tokens.colorTransparentBackgroundPressed,\n color: tokens.colorNeutralForeground2BrandPressed,\n },\n },\n\n selected: {\n backgroundColor: tokens.colorTransparentBackgroundSelected,\n color: tokens.colorNeutralForeground2BrandSelected,\n\n [`& .${iconFilledClassName}`]: {\n display: 'inline-flex',\n },\n [`& .${iconRegularClassName}`]: {\n display: 'none',\n },\n\n '@media (forced-colors: active)': {\n backgroundColor: 'Highlight',\n ...shorthands.borderColor('Canvas'),\n color: 'Canvas',\n },\n },\n\n highContrast: {\n '@media (forced-colors: active)': {\n ...shorthands.borderColor('Canvas'),\n color: 'CanvasText',\n\n ':hover, :hover:active': {\n forcedColorAdjust: 'none',\n backgroundColor: 'Highlight',\n ...shorthands.borderColor('Canvas'),\n color: 'Canvas',\n },\n },\n },\n\n focusIndicator: createCustomFocusIndicatorStyle({\n ...shorthands.borderRadius(tokens.borderRadiusMedium),\n ...shorthands.borderColor(tokens.colorTransparentStroke),\n outlineColor: tokens.colorTransparentStroke,\n outlineWidth: tokens.strokeWidthThick,\n outlineStyle: 'solid',\n boxShadow: `\n ${tokens.shadow4},\n 0 0 0 2px ${tokens.colorStrokeFocus2}\n `,\n zIndex: 1,\n }),\n\n large: {\n ...shorthands.padding(tokens.spacingVerticalXXS, tokens.spacingVerticalXXS),\n },\n});\n\nconst usePopoverSurfaceStyles = makeStyles({\n smallMedium: typographyStyles.caption1,\n large: typographyStyles.body1,\n});\n\n/**\n * Apply styling to the InfoButton slots based on the state\n */\nexport const useInfoButtonStyles_unstable = (state: InfoButtonState): InfoButtonState => {\n const { size } = state;\n const { open } = state.popover;\n const buttonStyles = useButtonStyles();\n const popoverSurfaceStyles = usePopoverSurfaceStyles();\n\n state.content.className = mergeClasses(\n infoButtonClassNames.content,\n size === 'large' && popoverSurfaceStyles.large,\n state.content.className,\n );\n\n state.root.className = mergeClasses(\n infoButtonClassNames.root,\n buttonStyles.base,\n buttonStyles.highContrast,\n buttonStyles.focusIndicator,\n open && buttonStyles.selected,\n size === 'large' && buttonStyles.large,\n state.root.className,\n );\n\n return state;\n};\n"]}
|
|
@@ -1,190 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.useInfoButtonStyles_unstable = exports.infoButtonClassNames = void 0;
|
|
7
|
-
const react_tabster_1 = /*#__PURE__*/require("@fluentui/react-tabster");
|
|
8
|
-
const react_icons_1 = /*#__PURE__*/require("@fluentui/react-icons");
|
|
9
|
-
const react_1 = /*#__PURE__*/require("@griffel/react");
|
|
10
|
-
const react_theme_1 = /*#__PURE__*/require("@fluentui/react-theme");
|
|
11
|
-
exports.infoButtonClassNames = {
|
|
12
|
-
root: 'fui-InfoButton',
|
|
13
|
-
// this className won't be used, but it's needed to satisfy the type checker
|
|
14
|
-
popover: 'fui-InfoButton__popover',
|
|
15
|
-
content: 'fui-InfoButton__content'
|
|
16
|
-
};
|
|
17
|
-
/**
|
|
18
|
-
* Styles for the root slot
|
|
19
|
-
*/
|
|
20
|
-
const useButtonStyles = /*#__PURE__*/react_1.__styles({
|
|
21
|
-
base: {
|
|
22
|
-
Bt984gj: "f122n59",
|
|
23
|
-
B7ck84d: "f1ewtqcl",
|
|
24
|
-
mc9l5x: "ftuwxu6",
|
|
25
|
-
Brf1p80: "f4d9j23",
|
|
26
|
-
w71qe1: "f1iuv45f",
|
|
27
|
-
ha4doy: "fmrv4ls",
|
|
28
|
-
De3pzq: "f1c21dwh",
|
|
29
|
-
sj55zd: "fkfq4zb",
|
|
30
|
-
B68tc82: "f1p9o1ba",
|
|
31
|
-
Bmxbyg5: "f1sil6mw",
|
|
32
|
-
B4j52fo: "f192inf7",
|
|
33
|
-
Bekrc4i: ["f5tn483", "f1ojsxk5"],
|
|
34
|
-
Bn0qgzm: "f1vxd6vx",
|
|
35
|
-
ibv6hh: ["f1ojsxk5", "f5tn483"],
|
|
36
|
-
icvyot: "fzkkow9",
|
|
37
|
-
vrafjx: ["fcdblym", "fjik90z"],
|
|
38
|
-
oivjwe: "fg706s2",
|
|
39
|
-
wvpqe5: ["fjik90z", "fcdblym"],
|
|
40
|
-
g2u3we: "fghlq4f",
|
|
41
|
-
h3c5rm: ["f1gn591s", "fjscplz"],
|
|
42
|
-
B9xav0g: "fb073pr",
|
|
43
|
-
zhjwy3: ["fjscplz", "f1gn591s"],
|
|
44
|
-
Bbmb7ep: ["f1aa9q02", "f16jpd5f"],
|
|
45
|
-
Beyfa6y: ["f16jpd5f", "f1aa9q02"],
|
|
46
|
-
B7oj6ja: ["f1jar5jt", "fyu767a"],
|
|
47
|
-
Btl43ni: ["fyu767a", "f1jar5jt"],
|
|
48
|
-
B6of3ja: "f1hu3pq6",
|
|
49
|
-
t21cq0: ["f11qmguv", "f1tyq0we"],
|
|
50
|
-
jrapky: "f19f4twv",
|
|
51
|
-
Frg6f3: ["f1tyq0we", "f11qmguv"],
|
|
52
|
-
z8tnut: "f1ywm7hm",
|
|
53
|
-
z189sj: ["f7x41pl", "fruq291"],
|
|
54
|
-
Byoj8tv: "f14wxoun",
|
|
55
|
-
uwmqm3: ["fruq291", "f7x41pl"],
|
|
56
|
-
D0sxk3: "f16u1re",
|
|
57
|
-
t6yez3: "f1rw4040",
|
|
58
|
-
Jwef8y: "fjxutwb",
|
|
59
|
-
Bi91k9c: "f139oj5f",
|
|
60
|
-
Bk3fhr4: "f1jpd6y0",
|
|
61
|
-
Bmfj8id: "fuxngvv",
|
|
62
|
-
iro3zm: "fwiml72",
|
|
63
|
-
B2d53fq: "f1fg1p5m"
|
|
64
|
-
},
|
|
65
|
-
selected: {
|
|
66
|
-
De3pzq: "f1q9pm1r",
|
|
67
|
-
sj55zd: "f1qj7y59",
|
|
68
|
-
D0sxk3: "fgzdkf0",
|
|
69
|
-
t6yez3: "f15q0o9g",
|
|
70
|
-
Bsw6fvg: "f1rirnrt",
|
|
71
|
-
Bjwas2f: "f14pvji2",
|
|
72
|
-
Bn1d65q: ["f1xeojaw", "f1hodmrf"],
|
|
73
|
-
Bxeuatn: "fcbbwn3",
|
|
74
|
-
n51gp8: ["f1hodmrf", "f1xeojaw"],
|
|
75
|
-
Bbusuzp: "f1cg6951"
|
|
76
|
-
},
|
|
77
|
-
highContrast: {
|
|
78
|
-
Bjwas2f: "f14pvji2",
|
|
79
|
-
Bn1d65q: ["f1xeojaw", "f1hodmrf"],
|
|
80
|
-
Bxeuatn: "fcbbwn3",
|
|
81
|
-
n51gp8: ["f1hodmrf", "f1xeojaw"],
|
|
82
|
-
Bbusuzp: "fn0tkbb",
|
|
83
|
-
w76p1f: "f18rpr9v",
|
|
84
|
-
B3sm7at: "f5mt1fw",
|
|
85
|
-
fe9h6n: "f17188ff",
|
|
86
|
-
Bmhq1k7: ["fzyms9j", "f12bfk5t"],
|
|
87
|
-
E428ku: "f1ucftwv",
|
|
88
|
-
Bipfp3: ["f12bfk5t", "fzyms9j"],
|
|
89
|
-
nrfbsj: "f10s0nbj"
|
|
90
|
-
},
|
|
91
|
-
focusIndicator: {
|
|
92
|
-
Brovlpu: "ftqa4ok",
|
|
93
|
-
B486eqv: "f2hkw1w",
|
|
94
|
-
kdpuga: ["f1o2ludy", "f1kjnpwc"],
|
|
95
|
-
Bw81rd7: ["f1kjnpwc", "f1o2ludy"],
|
|
96
|
-
B6xbmo0: ["fxmnebo", "f1witrsb"],
|
|
97
|
-
dm238s: ["f1witrsb", "fxmnebo"],
|
|
98
|
-
B8q5s1w: "f1rzxaq5",
|
|
99
|
-
Bci5o5g: ["fipsau9", "f6jszy8"],
|
|
100
|
-
n8qw10: "f1emqxbc",
|
|
101
|
-
Bdrgwmp: ["f6jszy8", "fipsau9"],
|
|
102
|
-
Bfpq7zp: "fr1u5pk",
|
|
103
|
-
Bn4voq9: "f1p7hgxw",
|
|
104
|
-
g9k6zt: "f9znhxp",
|
|
105
|
-
j6ew2k: ["fvbipq7", "fvbipq7"],
|
|
106
|
-
Bhxq17a: "f1vjpng2"
|
|
107
|
-
},
|
|
108
|
-
large: {
|
|
109
|
-
z8tnut: "fclwglc",
|
|
110
|
-
z189sj: ["f1w3695s", "f1b0r8ql"],
|
|
111
|
-
Byoj8tv: "fywfov9",
|
|
112
|
-
uwmqm3: ["f1b0r8ql", "f1w3695s"]
|
|
113
|
-
}
|
|
114
|
-
}, {
|
|
115
|
-
d: [".f122n59{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}", ".f1ewtqcl{box-sizing:border-box;}", ".ftuwxu6{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;}", ".f4d9j23{-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;}", ".f1iuv45f{text-decoration-line:none;}", ".fmrv4ls{vertical-align:middle;}", ".f1c21dwh{background-color:var(--colorTransparentBackground);}", ".fkfq4zb{color:var(--colorNeutralForeground2);}", ".f1p9o1ba{overflow-x:hidden;}", ".f1sil6mw{overflow-y:hidden;}", ".f192inf7{border-top-width:var(--strokeWidthThin);}", ".f5tn483{border-right-width:var(--strokeWidthThin);}", ".f1ojsxk5{border-left-width:var(--strokeWidthThin);}", ".f1vxd6vx{border-bottom-width:var(--strokeWidthThin);}", ".fzkkow9{border-top-style:solid;}", ".fcdblym{border-right-style:solid;}", ".fjik90z{border-left-style:solid;}", ".fg706s2{border-bottom-style:solid;}", ".fghlq4f{border-top-color:var(--colorTransparentStroke);}", ".f1gn591s{border-right-color:var(--colorTransparentStroke);}", ".fjscplz{border-left-color:var(--colorTransparentStroke);}", ".fb073pr{border-bottom-color:var(--colorTransparentStroke);}", ".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}", ".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}", ".f1jar5jt{border-top-right-radius:var(--borderRadiusMedium);}", ".fyu767a{border-top-left-radius:var(--borderRadiusMedium);}", ".f1hu3pq6{margin-top:0;}", ".f11qmguv{margin-right:0;}", ".f1tyq0we{margin-left:0;}", ".f19f4twv{margin-bottom:0;}", ".f1ywm7hm{padding-top:var(--spacingVerticalXS);}", ".f7x41pl{padding-right:var(--spacingHorizontalXS);}", ".fruq291{padding-left:var(--spacingHorizontalXS);}", ".f14wxoun{padding-bottom:var(--spacingVerticalXS);}", ".f16u1re .fui-Icon-filled{display:none;}", ".f1rw4040 .fui-Icon-regular{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;}", ".f1q9pm1r{background-color:var(--colorTransparentBackgroundSelected);}", ".f1qj7y59{color:var(--colorNeutralForeground2BrandSelected);}", ".fgzdkf0 .fui-Icon-filled{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;}", ".f15q0o9g .fui-Icon-regular{display:none;}", ".f1o2ludy[data-fui-focus-visible]{border-bottom-right-radius:var(--borderRadiusMedium);}", ".f1kjnpwc[data-fui-focus-visible]{border-bottom-left-radius:var(--borderRadiusMedium);}", ".fxmnebo[data-fui-focus-visible]{border-top-right-radius:var(--borderRadiusMedium);}", ".f1witrsb[data-fui-focus-visible]{border-top-left-radius:var(--borderRadiusMedium);}", ".f1rzxaq5[data-fui-focus-visible]{border-top-color:var(--colorTransparentStroke);}", ".fipsau9[data-fui-focus-visible]{border-right-color:var(--colorTransparentStroke);}", ".f6jszy8[data-fui-focus-visible]{border-left-color:var(--colorTransparentStroke);}", ".f1emqxbc[data-fui-focus-visible]{border-bottom-color:var(--colorTransparentStroke);}", ".fr1u5pk[data-fui-focus-visible]{outline-color:var(--colorTransparentStroke);}", ".f1p7hgxw[data-fui-focus-visible]{outline-width:var(--strokeWidthThick);}", ".f9znhxp[data-fui-focus-visible]{outline-style:solid;}", ".fvbipq7[data-fui-focus-visible]{box-shadow:var(--shadow4),0 0 0 2px var(--colorStrokeFocus2);}", ".f1vjpng2[data-fui-focus-visible]{z-index:1;}", ".fclwglc{padding-top:var(--spacingVerticalXXS);}", ".f1w3695s{padding-right:var(--spacingVerticalXXS);}", ".f1b0r8ql{padding-left:var(--spacingVerticalXXS);}", ".fywfov9{padding-bottom:var(--spacingVerticalXXS);}"],
|
|
116
|
-
h: [".fjxutwb:hover{background-color:var(--colorTransparentBackgroundHover);}", ".f139oj5f:hover{color:var(--colorNeutralForeground2BrandHover);}", ".f1jpd6y0:hover .fui-Icon-filled{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;}", ".fuxngvv:hover .fui-Icon-regular{display:none;}", ".fwiml72:hover:active{background-color:var(--colorTransparentBackgroundPressed);}", ".f1fg1p5m:hover:active{color:var(--colorNeutralForeground2BrandPressed);}"],
|
|
117
|
-
m: [["@media (forced-colors: active){.f1rirnrt{background-color:Highlight;}}", {
|
|
118
|
-
m: "(forced-colors: active)"
|
|
119
|
-
}], ["@media (forced-colors: active){.f14pvji2{border-top-color:Canvas;}}", {
|
|
120
|
-
m: "(forced-colors: active)"
|
|
121
|
-
}], ["@media (forced-colors: active){.f1xeojaw{border-right-color:Canvas;}.f1hodmrf{border-left-color:Canvas;}}", {
|
|
122
|
-
m: "(forced-colors: active)"
|
|
123
|
-
}], ["@media (forced-colors: active){.fcbbwn3{border-bottom-color:Canvas;}}", {
|
|
124
|
-
m: "(forced-colors: active)"
|
|
125
|
-
}], ["@media (forced-colors: active){.f1hodmrf{border-left-color:Canvas;}.f1xeojaw{border-right-color:Canvas;}}", {
|
|
126
|
-
m: "(forced-colors: active)"
|
|
127
|
-
}], ["@media (forced-colors: active){.f1cg6951{color:Canvas;}}", {
|
|
128
|
-
m: "(forced-colors: active)"
|
|
129
|
-
}], ["@media (forced-colors: active){.f14pvji2{border-top-color:Canvas;}}", {
|
|
130
|
-
m: "(forced-colors: active)"
|
|
131
|
-
}], ["@media (forced-colors: active){.f1xeojaw{border-right-color:Canvas;}.f1hodmrf{border-left-color:Canvas;}}", {
|
|
132
|
-
m: "(forced-colors: active)"
|
|
133
|
-
}], ["@media (forced-colors: active){.fcbbwn3{border-bottom-color:Canvas;}}", {
|
|
134
|
-
m: "(forced-colors: active)"
|
|
135
|
-
}], ["@media (forced-colors: active){.f1hodmrf{border-left-color:Canvas;}.f1xeojaw{border-right-color:Canvas;}}", {
|
|
136
|
-
m: "(forced-colors: active)"
|
|
137
|
-
}], ["@media (forced-colors: active){.fn0tkbb{color:CanvasText;}}", {
|
|
138
|
-
m: "(forced-colors: active)"
|
|
139
|
-
}], ["@media (forced-colors: active){.f18rpr9v:hover,.f18rpr9v :hover:active{forced-color-adjust:none;}}", {
|
|
140
|
-
m: "(forced-colors: active)"
|
|
141
|
-
}], ["@media (forced-colors: active){.f5mt1fw:hover,.f5mt1fw :hover:active{background-color:Highlight;}}", {
|
|
142
|
-
m: "(forced-colors: active)"
|
|
143
|
-
}], ["@media (forced-colors: active){.f17188ff:hover,.f17188ff :hover:active{border-top-color:Canvas;}}", {
|
|
144
|
-
m: "(forced-colors: active)"
|
|
145
|
-
}], ["@media (forced-colors: active){.fzyms9j:hover,.fzyms9j :hover:active{border-right-color:Canvas;}.f12bfk5t:hover,.f12bfk5t :hover:active{border-left-color:Canvas;}}", {
|
|
146
|
-
m: "(forced-colors: active)"
|
|
147
|
-
}], ["@media (forced-colors: active){.f1ucftwv:hover,.f1ucftwv :hover:active{border-bottom-color:Canvas;}}", {
|
|
148
|
-
m: "(forced-colors: active)"
|
|
149
|
-
}], ["@media (forced-colors: active){.f12bfk5t:hover,.f12bfk5t :hover:active{border-left-color:Canvas;}.fzyms9j:hover,.fzyms9j :hover:active{border-right-color:Canvas;}}", {
|
|
150
|
-
m: "(forced-colors: active)"
|
|
151
|
-
}], ["@media (forced-colors: active){.f10s0nbj:hover,.f10s0nbj :hover:active{color:Canvas;}}", {
|
|
152
|
-
m: "(forced-colors: active)"
|
|
153
|
-
}]],
|
|
154
|
-
f: [".ftqa4ok:focus{outline-style:none;}"],
|
|
155
|
-
i: [".f2hkw1w:focus-visible{outline-style:none;}"]
|
|
156
|
-
});
|
|
157
|
-
const usePopoverSurfaceStyles = /*#__PURE__*/react_1.__styles({
|
|
158
|
-
smallMedium: {
|
|
159
|
-
Bahqtrf: "fk6fouc",
|
|
160
|
-
Be2twd7: "fy9rknc",
|
|
161
|
-
Bhrd7zp: "figsok6",
|
|
162
|
-
Bg96gwp: "fwrc4pm"
|
|
163
|
-
},
|
|
164
|
-
large: {
|
|
165
|
-
Bahqtrf: "fk6fouc",
|
|
166
|
-
Be2twd7: "fkhj508",
|
|
167
|
-
Bhrd7zp: "figsok6",
|
|
168
|
-
Bg96gwp: "f1i3iumi"
|
|
169
|
-
}
|
|
170
|
-
}, {
|
|
171
|
-
d: [".fk6fouc{font-family:var(--fontFamilyBase);}", ".fy9rknc{font-size:var(--fontSizeBase200);}", ".figsok6{font-weight:var(--fontWeightRegular);}", ".fwrc4pm{line-height:var(--lineHeightBase200);}", ".fkhj508{font-size:var(--fontSizeBase300);}", ".f1i3iumi{line-height:var(--lineHeightBase300);}"]
|
|
172
|
-
});
|
|
173
|
-
/**
|
|
174
|
-
* Apply styling to the InfoButton slots based on the state
|
|
175
|
-
*/
|
|
176
|
-
const useInfoButtonStyles_unstable = state => {
|
|
177
|
-
const {
|
|
178
|
-
size
|
|
179
|
-
} = state;
|
|
180
|
-
const {
|
|
181
|
-
open
|
|
182
|
-
} = state.popover;
|
|
183
|
-
const buttonStyles = useButtonStyles();
|
|
184
|
-
const popoverSurfaceStyles = usePopoverSurfaceStyles();
|
|
185
|
-
state.content.className = react_1.mergeClasses(exports.infoButtonClassNames.content, size === 'large' && popoverSurfaceStyles.large, state.content.className);
|
|
186
|
-
state.root.className = react_1.mergeClasses(exports.infoButtonClassNames.root, buttonStyles.base, buttonStyles.highContrast, buttonStyles.focusIndicator, open && buttonStyles.selected, size === 'large' && buttonStyles.large, state.root.className);
|
|
187
|
-
return state;
|
|
188
|
-
};
|
|
189
|
-
exports.useInfoButtonStyles_unstable = useInfoButtonStyles_unstable;
|
|
190
|
-
//# sourceMappingURL=useInfoButtonStyles.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"mappings":";;;;;;AAAA;AACA;AACA;AACA;AAIaA,4BAAoB,GAAoC;EACnEC,IAAI,EAAE,gBAAgB;EACtB;EACAC,OAAO,EAAE,yBAAyB;EAClCC,OAAO,EAAE;CACV;AAED;;;AAGA,MAAMC,eAAe,gBAAGC,gBAAU;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;IAAA;IAAA;IAAA;EAAA;AAAA;EAAA;EAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;IAAA;EAAA;EAAA;EAAA;AAAA,EA0FhC;AAEF,MAAMC,uBAAuB,gBAAGD,gBAAU;EAAA;IAAA;IAAA;IAAA;IAAA;EAAA;EAAA;IAAA;IAAA;IAAA;IAAA;EAAA;AAAA;EAAA;AAAA,EAGxC;AAEF;;;AAGO,MAAME,4BAA4B,GAAIC,KAAsB,IAAqB;EACtF,MAAM;IAAEC;EAAI,CAAE,GAAGD,KAAK;EACtB,MAAM;IAAEE;EAAI,CAAE,GAAGF,KAAK,CAACN,OAAO;EAC9B,MAAMS,YAAY,GAAGP,eAAe,EAAE;EACtC,MAAMQ,oBAAoB,GAAGN,uBAAuB,EAAE;EAEtDE,KAAK,CAACL,OAAO,CAACU,SAAS,GAAGR,oBAAY,CACpCL,4BAAoB,CAACG,OAAO,EAC5BM,IAAI,KAAK,OAAO,IAAIG,oBAAoB,CAACE,KAAK,EAC9CN,KAAK,CAACL,OAAO,CAACU,SAAS,CACxB;EAEDL,KAAK,CAACP,IAAI,CAACY,SAAS,GAAGR,oBAAY,CACjCL,4BAAoB,CAACC,IAAI,EACzBU,YAAY,CAACI,IAAI,EACjBJ,YAAY,CAACK,YAAY,EACzBL,YAAY,CAACM,cAAc,EAC3BP,IAAI,IAAIC,YAAY,CAACO,QAAQ,EAC7BT,IAAI,KAAK,OAAO,IAAIE,YAAY,CAACG,KAAK,EACtCN,KAAK,CAACP,IAAI,CAACY,SAAS,CACrB;EAED,OAAOL,KAAK;AACd,CAAC;AAvBYR,oCAA4B","names":["exports","root","popover","content","useButtonStyles","react_1","usePopoverSurfaceStyles","useInfoButtonStyles_unstable","state","size","open","buttonStyles","popoverSurfaceStyles","className","large","base","highContrast","focusIndicator","selected"],"sourceRoot":"../src/","sources":["packages/react-components/react-infobutton/src/components/InfoButton/useInfoButtonStyles.ts"],"sourcesContent":["import { createCustomFocusIndicatorStyle } from '@fluentui/react-tabster';\nimport { iconFilledClassName, iconRegularClassName } from '@fluentui/react-icons';\nimport { makeStyles, mergeClasses, shorthands } from '@griffel/react';\nimport { tokens, typographyStyles } from '@fluentui/react-theme';\nimport type { InfoButtonSlots, InfoButtonState } from './InfoButton.types';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\n\nexport const infoButtonClassNames: SlotClassNames<InfoButtonSlots> = {\n root: 'fui-InfoButton',\n // this className won't be used, but it's needed to satisfy the type checker\n popover: 'fui-InfoButton__popover',\n content: 'fui-InfoButton__content',\n};\n\n/**\n * Styles for the root slot\n */\nconst useButtonStyles = makeStyles({\n base: {\n alignItems: 'center',\n boxSizing: 'border-box',\n display: 'inline-flex',\n justifyContent: 'center',\n textDecorationLine: 'none',\n verticalAlign: 'middle',\n\n backgroundColor: tokens.colorTransparentBackground,\n color: tokens.colorNeutralForeground2,\n\n ...shorthands.overflow('hidden'),\n ...shorthands.border(tokens.strokeWidthThin, 'solid', tokens.colorTransparentStroke),\n ...shorthands.borderRadius(tokens.borderRadiusMedium),\n ...shorthands.margin(0),\n ...shorthands.padding(tokens.spacingVerticalXS, tokens.spacingHorizontalXS),\n\n [`& .${iconFilledClassName}`]: {\n display: 'none',\n },\n [`& .${iconRegularClassName}`]: {\n display: 'inline-flex',\n },\n\n ':hover': {\n backgroundColor: tokens.colorTransparentBackgroundHover,\n color: tokens.colorNeutralForeground2BrandHover,\n\n [`& .${iconFilledClassName}`]: {\n display: 'inline-flex',\n },\n [`& .${iconRegularClassName}`]: {\n display: 'none',\n },\n },\n ':hover:active': {\n backgroundColor: tokens.colorTransparentBackgroundPressed,\n color: tokens.colorNeutralForeground2BrandPressed,\n },\n },\n\n selected: {\n backgroundColor: tokens.colorTransparentBackgroundSelected,\n color: tokens.colorNeutralForeground2BrandSelected,\n\n [`& .${iconFilledClassName}`]: {\n display: 'inline-flex',\n },\n [`& .${iconRegularClassName}`]: {\n display: 'none',\n },\n\n '@media (forced-colors: active)': {\n backgroundColor: 'Highlight',\n ...shorthands.borderColor('Canvas'),\n color: 'Canvas',\n },\n },\n\n highContrast: {\n '@media (forced-colors: active)': {\n ...shorthands.borderColor('Canvas'),\n color: 'CanvasText',\n\n ':hover, :hover:active': {\n forcedColorAdjust: 'none',\n backgroundColor: 'Highlight',\n ...shorthands.borderColor('Canvas'),\n color: 'Canvas',\n },\n },\n },\n\n focusIndicator: createCustomFocusIndicatorStyle({\n ...shorthands.borderRadius(tokens.borderRadiusMedium),\n ...shorthands.borderColor(tokens.colorTransparentStroke),\n outlineColor: tokens.colorTransparentStroke,\n outlineWidth: tokens.strokeWidthThick,\n outlineStyle: 'solid',\n boxShadow: `\n ${tokens.shadow4},\n 0 0 0 2px ${tokens.colorStrokeFocus2}\n `,\n zIndex: 1,\n }),\n\n large: {\n ...shorthands.padding(tokens.spacingVerticalXXS, tokens.spacingVerticalXXS),\n },\n});\n\nconst usePopoverSurfaceStyles = makeStyles({\n smallMedium: typographyStyles.caption1,\n large: typographyStyles.body1,\n});\n\n/**\n * Apply styling to the InfoButton slots based on the state\n */\nexport const useInfoButtonStyles_unstable = (state: InfoButtonState): InfoButtonState => {\n const { size } = state;\n const { open } = state.popover;\n const buttonStyles = useButtonStyles();\n const popoverSurfaceStyles = usePopoverSurfaceStyles();\n\n state.content.className = mergeClasses(\n infoButtonClassNames.content,\n size === 'large' && popoverSurfaceStyles.large,\n state.content.className,\n );\n\n state.root.className = mergeClasses(\n infoButtonClassNames.root,\n buttonStyles.base,\n buttonStyles.highContrast,\n buttonStyles.focusIndicator,\n open && buttonStyles.selected,\n size === 'large' && buttonStyles.large,\n state.root.className,\n );\n\n return state;\n};\n"]}
|