@fluentui/react-badge 9.74.7-experimental.cli-api.20261006-ccaa611d58.0 → 9.75.0-experimental.css-modules.20261031-810ab07afb.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +29 -9
- package/lib/components/Badge/Badge.js.map +1 -1
- package/lib/components/Badge/Badge.module.css +290 -0
- package/lib/components/Badge/Badge.types.js.map +1 -1
- package/lib/components/Badge/index.js.map +1 -1
- package/lib/components/Badge/renderBadge.js +2 -2
- package/lib/components/Badge/renderBadge.js.map +1 -1
- package/lib/components/Badge/useBadge.js.map +1 -1
- package/lib/components/Badge/useBadgeStyles.styles.css.js +24 -0
- package/lib/components/Badge/useBadgeStyles.styles.css.js.map +1 -0
- package/lib/components/Badge/useBadgeStyles.styles.raw.css.js +24 -0
- package/lib/components/Badge/useBadgeStyles.styles.raw.css.js.map +1 -0
- package/lib/components/Badge/useBadgeStyles.styles.raw.js.map +1 -1
- package/lib/components/CounterBadge/CounterBadge.js.map +1 -1
- package/lib/components/CounterBadge/CounterBadge.module.css +12 -0
- package/lib/components/CounterBadge/CounterBadge.types.js.map +1 -1
- package/lib/components/CounterBadge/index.js.map +1 -1
- package/lib/components/CounterBadge/useCounterBadge.js.map +1 -1
- package/lib/components/CounterBadge/useCounterBadgeStyles.styles.css.js +17 -0
- package/lib/components/CounterBadge/useCounterBadgeStyles.styles.css.js.map +1 -0
- package/lib/components/CounterBadge/useCounterBadgeStyles.styles.raw.css.js +17 -0
- package/lib/components/CounterBadge/useCounterBadgeStyles.styles.raw.css.js.map +1 -0
- package/lib/components/CounterBadge/useCounterBadgeStyles.styles.raw.js.map +1 -1
- package/lib/components/PresenceBadge/PresenceBadge.js.map +1 -1
- package/lib/components/PresenceBadge/PresenceBadge.module.css +94 -0
- package/lib/components/PresenceBadge/PresenceBadge.types.js.map +1 -1
- package/lib/components/PresenceBadge/index.js.map +1 -1
- package/lib/components/PresenceBadge/presenceIcons.js.map +1 -1
- package/lib/components/PresenceBadge/usePresenceBadge.js +2 -3
- package/lib/components/PresenceBadge/usePresenceBadge.js.map +1 -1
- package/lib/components/PresenceBadge/usePresenceBadgeStyles.styles.css.js +15 -0
- package/lib/components/PresenceBadge/usePresenceBadgeStyles.styles.css.js.map +1 -0
- package/lib/components/PresenceBadge/usePresenceBadgeStyles.styles.raw.css.js +15 -0
- package/lib/components/PresenceBadge/usePresenceBadgeStyles.styles.raw.css.js.map +1 -0
- package/lib/components/PresenceBadge/usePresenceBadgeStyles.styles.raw.js.map +1 -1
- package/lib-commonjs/Badge.cjs +7 -7
- package/lib-commonjs/CounterBadge.cjs +6 -6
- package/lib-commonjs/PresenceBadge.cjs +17 -17
- package/lib-commonjs/PresenceBadge.cjs.map +1 -1
- package/lib-commonjs/components/Badge/Badge.cjs.map +1 -1
- package/lib-commonjs/components/Badge/Badge.module.css +290 -0
- package/lib-commonjs/components/Badge/Badge.types.cjs.map +1 -1
- package/lib-commonjs/components/Badge/index.cjs +7 -7
- package/lib-commonjs/components/Badge/index.cjs.map +1 -1
- package/lib-commonjs/components/Badge/renderBadge.cjs.map +1 -1
- package/lib-commonjs/components/Badge/useBadge.cjs +3 -3
- package/lib-commonjs/components/Badge/useBadge.cjs.map +1 -1
- package/lib-commonjs/components/Badge/useBadgeStyles.styles.cjs +3 -3
- package/lib-commonjs/components/Badge/useBadgeStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/Badge/useBadgeStyles.styles.css.cjs +41 -0
- package/lib-commonjs/components/Badge/useBadgeStyles.styles.css.cjs.map +1 -0
- package/lib-commonjs/components/Badge/useBadgeStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/Badge/useBadgeStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/Badge/useBadgeStyles.styles.raw.css.cjs +41 -0
- package/lib-commonjs/components/Badge/useBadgeStyles.styles.raw.css.cjs.map +1 -0
- package/lib-commonjs/components/CounterBadge/CounterBadge.cjs.map +1 -1
- package/lib-commonjs/components/CounterBadge/CounterBadge.module.css +12 -0
- package/lib-commonjs/components/CounterBadge/CounterBadge.types.cjs.map +1 -1
- package/lib-commonjs/components/CounterBadge/index.cjs +6 -6
- package/lib-commonjs/components/CounterBadge/index.cjs.map +1 -1
- package/lib-commonjs/components/CounterBadge/useCounterBadge.cjs +3 -3
- package/lib-commonjs/components/CounterBadge/useCounterBadge.cjs.map +1 -1
- package/lib-commonjs/components/CounterBadge/useCounterBadgeStyles.styles.cjs +3 -3
- package/lib-commonjs/components/CounterBadge/useCounterBadgeStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/CounterBadge/useCounterBadgeStyles.styles.css.cjs +36 -0
- package/lib-commonjs/components/CounterBadge/useCounterBadgeStyles.styles.css.cjs.map +1 -0
- package/lib-commonjs/components/CounterBadge/useCounterBadgeStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/CounterBadge/useCounterBadgeStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/CounterBadge/useCounterBadgeStyles.styles.raw.css.cjs +36 -0
- package/lib-commonjs/components/CounterBadge/useCounterBadgeStyles.styles.raw.css.cjs.map +1 -0
- package/lib-commonjs/components/PresenceBadge/PresenceBadge.cjs.map +1 -1
- package/lib-commonjs/components/PresenceBadge/PresenceBadge.module.css +94 -0
- package/lib-commonjs/components/PresenceBadge/PresenceBadge.types.cjs.map +1 -1
- package/lib-commonjs/components/PresenceBadge/index.cjs +17 -17
- package/lib-commonjs/components/PresenceBadge/index.cjs.map +1 -1
- package/lib-commonjs/components/PresenceBadge/presenceIcons.cjs +12 -12
- package/lib-commonjs/components/PresenceBadge/presenceIcons.cjs.map +1 -1
- package/lib-commonjs/components/PresenceBadge/usePresenceBadge.cjs +6 -7
- package/lib-commonjs/components/PresenceBadge/usePresenceBadge.cjs.map +1 -1
- package/lib-commonjs/components/PresenceBadge/usePresenceBadgeStyles.styles.cjs +3 -3
- package/lib-commonjs/components/PresenceBadge/usePresenceBadgeStyles.styles.cjs.map +1 -1
- package/lib-commonjs/components/PresenceBadge/usePresenceBadgeStyles.styles.css.cjs +34 -0
- package/lib-commonjs/components/PresenceBadge/usePresenceBadgeStyles.styles.css.cjs.map +1 -0
- package/lib-commonjs/components/PresenceBadge/usePresenceBadgeStyles.styles.raw.cjs +3 -3
- package/lib-commonjs/components/PresenceBadge/usePresenceBadgeStyles.styles.raw.cjs.map +1 -1
- package/lib-commonjs/components/PresenceBadge/usePresenceBadgeStyles.styles.raw.css.cjs +34 -0
- package/lib-commonjs/components/PresenceBadge/usePresenceBadgeStyles.styles.raw.css.cjs.map +1 -0
- package/lib-commonjs/index.cjs +28 -28
- package/lib-commonjs/index.cjs.map +1 -1
- package/package.json +12 -12
- package/dist/metadata/api/api-root.json +0 -1
- package/dist/metadata/index.json +0 -1
|
@@ -0,0 +1,290 @@
|
|
|
1
|
+
@layer fluentui {
|
|
2
|
+
/* ---- Root base (20px medium, circular, caption1Strong) ---- */
|
|
3
|
+
.root {
|
|
4
|
+
display: inline-flex;
|
|
5
|
+
box-sizing: border-box;
|
|
6
|
+
align-items: center;
|
|
7
|
+
justify-content: center;
|
|
8
|
+
position: relative;
|
|
9
|
+
font-family: var(--fontFamilyBase);
|
|
10
|
+
font-size: var(--fontSizeBase200);
|
|
11
|
+
font-weight: var(--fontWeightSemibold);
|
|
12
|
+
line-height: var(--lineHeightBase200);
|
|
13
|
+
height: 20px;
|
|
14
|
+
min-width: 20px;
|
|
15
|
+
padding: 0 calc(var(--spacingHorizontalXS) + var(--spacingHorizontalXXS));
|
|
16
|
+
border-radius: var(--borderRadiusCircular);
|
|
17
|
+
border-color: var(--colorTransparentStroke);
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
/* Border via ::after so it never affects layout */
|
|
21
|
+
.root::after {
|
|
22
|
+
content: '';
|
|
23
|
+
position: absolute;
|
|
24
|
+
top: 0;
|
|
25
|
+
left: 0;
|
|
26
|
+
bottom: 0;
|
|
27
|
+
right: 0;
|
|
28
|
+
border-style: solid;
|
|
29
|
+
border-color: inherit;
|
|
30
|
+
border-width: var(--strokeWidthThin);
|
|
31
|
+
border-radius: inherit;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
/* ---- Sizes: class name = prop value ---- */
|
|
35
|
+
.tiny {
|
|
36
|
+
width: 6px;
|
|
37
|
+
height: 6px;
|
|
38
|
+
font-size: 4px;
|
|
39
|
+
line-height: 4px;
|
|
40
|
+
min-width: unset;
|
|
41
|
+
padding: unset;
|
|
42
|
+
}
|
|
43
|
+
.extra-small {
|
|
44
|
+
width: 10px;
|
|
45
|
+
height: 10px;
|
|
46
|
+
font-size: 6px;
|
|
47
|
+
line-height: 6px;
|
|
48
|
+
min-width: unset;
|
|
49
|
+
padding: unset;
|
|
50
|
+
}
|
|
51
|
+
.small {
|
|
52
|
+
min-width: 16px;
|
|
53
|
+
height: 16px;
|
|
54
|
+
padding: 0 calc(var(--spacingHorizontalXXS) + var(--spacingHorizontalXXS));
|
|
55
|
+
}
|
|
56
|
+
/* medium: .root default */
|
|
57
|
+
.large {
|
|
58
|
+
min-width: 24px;
|
|
59
|
+
height: 24px;
|
|
60
|
+
padding: 0 calc(var(--spacingHorizontalXS) + var(--spacingHorizontalXXS));
|
|
61
|
+
}
|
|
62
|
+
.extra-large {
|
|
63
|
+
min-width: 32px;
|
|
64
|
+
height: 32px;
|
|
65
|
+
padding: 0 calc(var(--spacingHorizontalSNudge) + var(--spacingHorizontalXXS));
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
/* caption2Strong font for small-to-tiny */
|
|
69
|
+
.tiny,
|
|
70
|
+
.extra-small,
|
|
71
|
+
.small {
|
|
72
|
+
font-size: var(--fontSizeBase100);
|
|
73
|
+
line-height: var(--lineHeightBase100);
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
/* ---- Shapes: class name = prop value ---- */
|
|
77
|
+
.square {
|
|
78
|
+
border-radius: var(--borderRadiusNone);
|
|
79
|
+
}
|
|
80
|
+
/* circular: .root default */
|
|
81
|
+
|
|
82
|
+
.rounded {
|
|
83
|
+
border-radius: var(--borderRadiusMedium);
|
|
84
|
+
}
|
|
85
|
+
.rounded:where(.tiny, .extra-small, .small) {
|
|
86
|
+
border-radius: var(--borderRadiusSmall);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
/* ---- Icon slot ---- */
|
|
90
|
+
.icon {
|
|
91
|
+
display: flex;
|
|
92
|
+
line-height: 1;
|
|
93
|
+
margin: 0 calc(-1 * var(--spacingHorizontalXXS));
|
|
94
|
+
font-size: 12px;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
/* Icon size via descendant from root size class */
|
|
98
|
+
.tiny :global(.fui-Badge__icon) {
|
|
99
|
+
font-size: 6px;
|
|
100
|
+
}
|
|
101
|
+
.extra-small :global(.fui-Badge__icon) {
|
|
102
|
+
font-size: 10px;
|
|
103
|
+
}
|
|
104
|
+
/* .small, .medium: 12px from .icon */
|
|
105
|
+
.large :global(.fui-Badge__icon) {
|
|
106
|
+
font-size: 16px;
|
|
107
|
+
}
|
|
108
|
+
.extra-large :global(.fui-Badge__icon) {
|
|
109
|
+
font-size: 20px;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
/* Icon position gap between icon and adjacent text */
|
|
113
|
+
.iconBeforeText {
|
|
114
|
+
margin-inline-end: calc(var(--spacingHorizontalXXS) + var(--spacingHorizontalXXS));
|
|
115
|
+
}
|
|
116
|
+
.iconAfterText {
|
|
117
|
+
margin-inline-start: calc(var(--spacingHorizontalXXS) + var(--spacingHorizontalXXS));
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
/* Extra-large gets wider gaps — compound CSS, no hook conditional */
|
|
121
|
+
.extra-large .iconBeforeText {
|
|
122
|
+
margin-inline-end: calc(var(--spacingHorizontalXS) + var(--spacingHorizontalXXS));
|
|
123
|
+
}
|
|
124
|
+
.extra-large .iconAfterText {
|
|
125
|
+
margin-inline-start: calc(var(--spacingHorizontalXS) + var(--spacingHorizontalXXS));
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
/* ---- Appearance × color classes: names use hyphens to match `${appearance}-${color}` ---- */
|
|
129
|
+
/* Hook uses styles[`${appearance}-${color}`] — no lookup map needed. */
|
|
130
|
+
|
|
131
|
+
/* filled */
|
|
132
|
+
.filled-brand {
|
|
133
|
+
background-color: var(--colorBrandBackground);
|
|
134
|
+
color: var(--colorNeutralForegroundOnBrand);
|
|
135
|
+
}
|
|
136
|
+
.filled-danger {
|
|
137
|
+
background-color: var(--colorPaletteRedBackground3);
|
|
138
|
+
color: var(--colorNeutralForegroundOnBrand);
|
|
139
|
+
}
|
|
140
|
+
.filled-important {
|
|
141
|
+
background-color: var(--colorNeutralForeground1);
|
|
142
|
+
color: var(--colorNeutralBackground1);
|
|
143
|
+
}
|
|
144
|
+
.filled-informative {
|
|
145
|
+
background-color: var(--colorNeutralBackground5);
|
|
146
|
+
color: var(--colorNeutralForeground3);
|
|
147
|
+
}
|
|
148
|
+
.filled-severe {
|
|
149
|
+
background-color: var(--colorPaletteDarkOrangeBackground3);
|
|
150
|
+
color: var(--colorNeutralForegroundOnBrand);
|
|
151
|
+
}
|
|
152
|
+
.filled-subtle {
|
|
153
|
+
background-color: var(--colorNeutralBackground1);
|
|
154
|
+
color: var(--colorNeutralForeground1);
|
|
155
|
+
}
|
|
156
|
+
.filled-success {
|
|
157
|
+
background-color: var(--colorPaletteGreenBackground3);
|
|
158
|
+
color: var(--colorNeutralForegroundOnBrand);
|
|
159
|
+
}
|
|
160
|
+
.filled-warning {
|
|
161
|
+
background-color: var(--colorPaletteYellowBackground3);
|
|
162
|
+
color: var(--colorNeutralForeground1Static);
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
/* ghost: ::after hidden in CSS */
|
|
166
|
+
.ghost-brand {
|
|
167
|
+
color: var(--colorBrandForeground1);
|
|
168
|
+
&::after {
|
|
169
|
+
display: none;
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
.ghost-danger {
|
|
173
|
+
color: var(--colorPaletteRedForeground3);
|
|
174
|
+
&::after {
|
|
175
|
+
display: none;
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
.ghost-important {
|
|
179
|
+
color: var(--colorNeutralForeground1);
|
|
180
|
+
&::after {
|
|
181
|
+
display: none;
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
.ghost-informative {
|
|
185
|
+
color: var(--colorNeutralForeground3);
|
|
186
|
+
&::after {
|
|
187
|
+
display: none;
|
|
188
|
+
}
|
|
189
|
+
}
|
|
190
|
+
.ghost-severe {
|
|
191
|
+
color: var(--colorPaletteDarkOrangeForeground3);
|
|
192
|
+
&::after {
|
|
193
|
+
display: none;
|
|
194
|
+
}
|
|
195
|
+
}
|
|
196
|
+
.ghost-subtle {
|
|
197
|
+
color: var(--colorNeutralForegroundStaticInverted);
|
|
198
|
+
&::after {
|
|
199
|
+
display: none;
|
|
200
|
+
}
|
|
201
|
+
}
|
|
202
|
+
.ghost-success {
|
|
203
|
+
color: var(--colorPaletteGreenForeground3);
|
|
204
|
+
&::after {
|
|
205
|
+
display: none;
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
.ghost-warning {
|
|
209
|
+
color: var(--colorPaletteYellowForeground2);
|
|
210
|
+
&::after {
|
|
211
|
+
display: none;
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
/* outline: border-color embedded per class */
|
|
216
|
+
.outline-brand {
|
|
217
|
+
color: var(--colorBrandForeground1);
|
|
218
|
+
border-color: currentColor;
|
|
219
|
+
}
|
|
220
|
+
.outline-danger {
|
|
221
|
+
color: var(--colorPaletteRedForeground3);
|
|
222
|
+
border-color: var(--colorPaletteRedBorder2);
|
|
223
|
+
}
|
|
224
|
+
.outline-important {
|
|
225
|
+
color: var(--colorNeutralForeground3);
|
|
226
|
+
border-color: var(--colorNeutralStrokeAccessible);
|
|
227
|
+
}
|
|
228
|
+
.outline-informative {
|
|
229
|
+
color: var(--colorNeutralForeground3);
|
|
230
|
+
border-color: var(--colorNeutralStroke2);
|
|
231
|
+
}
|
|
232
|
+
.outline-severe {
|
|
233
|
+
color: var(--colorPaletteDarkOrangeForeground3);
|
|
234
|
+
border-color: currentColor;
|
|
235
|
+
}
|
|
236
|
+
.outline-subtle {
|
|
237
|
+
color: var(--colorNeutralForegroundStaticInverted);
|
|
238
|
+
border-color: currentColor;
|
|
239
|
+
}
|
|
240
|
+
.outline-success {
|
|
241
|
+
color: var(--colorPaletteGreenForeground3);
|
|
242
|
+
border-color: var(--colorPaletteGreenBorder2);
|
|
243
|
+
}
|
|
244
|
+
.outline-warning {
|
|
245
|
+
color: var(--colorPaletteYellowForeground2);
|
|
246
|
+
border-color: currentColor;
|
|
247
|
+
}
|
|
248
|
+
|
|
249
|
+
/* tint */
|
|
250
|
+
.tint-brand {
|
|
251
|
+
background-color: var(--colorBrandBackground2);
|
|
252
|
+
color: var(--colorBrandForeground2);
|
|
253
|
+
border-color: var(--colorBrandStroke2);
|
|
254
|
+
}
|
|
255
|
+
.tint-danger {
|
|
256
|
+
background-color: var(--colorPaletteRedBackground1);
|
|
257
|
+
color: var(--colorPaletteRedForeground1);
|
|
258
|
+
border-color: var(--colorPaletteRedBorder1);
|
|
259
|
+
}
|
|
260
|
+
.tint-important {
|
|
261
|
+
background-color: var(--colorNeutralForeground3);
|
|
262
|
+
color: var(--colorNeutralBackground1);
|
|
263
|
+
border-color: var(--colorTransparentStroke);
|
|
264
|
+
}
|
|
265
|
+
.tint-informative {
|
|
266
|
+
background-color: var(--colorNeutralBackground4);
|
|
267
|
+
color: var(--colorNeutralForeground3);
|
|
268
|
+
border-color: var(--colorNeutralStroke2);
|
|
269
|
+
}
|
|
270
|
+
.tint-severe {
|
|
271
|
+
background-color: var(--colorPaletteDarkOrangeBackground1);
|
|
272
|
+
color: var(--colorPaletteDarkOrangeForeground1);
|
|
273
|
+
border-color: var(--colorPaletteDarkOrangeBorder1);
|
|
274
|
+
}
|
|
275
|
+
.tint-subtle {
|
|
276
|
+
background-color: var(--colorNeutralBackground1);
|
|
277
|
+
color: var(--colorNeutralForeground3);
|
|
278
|
+
border-color: var(--colorNeutralStroke2);
|
|
279
|
+
}
|
|
280
|
+
.tint-success {
|
|
281
|
+
background-color: var(--colorPaletteGreenBackground1);
|
|
282
|
+
color: var(--colorPaletteGreenForeground1);
|
|
283
|
+
border-color: var(--colorPaletteGreenBorder1);
|
|
284
|
+
}
|
|
285
|
+
.tint-warning {
|
|
286
|
+
background-color: var(--colorPaletteYellowBackground1);
|
|
287
|
+
color: var(--colorPaletteYellowForeground1);
|
|
288
|
+
border-color: var(--colorPaletteYellowBorder1);
|
|
289
|
+
}
|
|
290
|
+
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["
|
|
1
|
+
{"version":3,"sources":["../../../src/components/Badge/Badge.types.ts"],"sourcesContent":["import type { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';\n\nexport type BadgeSlots = {\n root: Slot<'div'>;\n icon?: Slot<'span'>;\n};\n\n// react has a non-standard `color` attribute in its types\n// https://github.com/DefinitelyTyped/DefinitelyTyped/blob/a4ab0fa432320e70da9e51c8ae2e47377f65804b/types/react/index.d.ts#L1868\nexport type BadgeProps = Omit<ComponentProps<BadgeSlots>, 'color'> & {\n /**\n * A Badge can be filled, outline, ghost, inverted\n * @defaultvalue filled\n */\n appearance?: 'filled' | 'ghost' | 'outline' | 'tint';\n\n /**\n * A Badge can be one of preset colors\n * @defaultvalue brand\n */\n color?: 'brand' | 'danger' | 'important' | 'informative' | 'severe' | 'subtle' | 'success' | 'warning';\n\n /**\n * A Badge can position the icon before or after the content.\n * @defaultvalue before\n */\n iconPosition?: 'before' | 'after';\n\n /**\n * A Badge can be square, circular or rounded.\n * @defaultvalue circular\n */\n shape?: 'circular' | 'rounded' | 'square';\n\n /**\n * A Badge can be on of several preset sizes.\n * @defaultvalue medium\n */\n size?: 'tiny' | 'extra-small' | 'small' | 'medium' | 'large' | 'extra-large';\n};\n\nexport type BadgeState = ComponentState<BadgeSlots> &\n Required<Pick<BadgeProps, 'appearance' | 'color' | 'iconPosition' | 'shape' | 'size'>>;\n\nexport type BadgeBaseProps = Omit<BadgeProps, 'appearance' | 'color' | 'shape' | 'size'>;\n\nexport type BadgeBaseState = Omit<BadgeState, 'appearance' | 'color' | 'shape' | 'size'>;\n"],"names":[],"mappings":""}
|
|
@@ -5,26 +5,26 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
function _export(target, all) {
|
|
6
6
|
for(var name in all)Object.defineProperty(target, name, {
|
|
7
7
|
enumerable: true,
|
|
8
|
-
get: all
|
|
8
|
+
get: Object.getOwnPropertyDescriptor(all, name).get
|
|
9
9
|
});
|
|
10
10
|
}
|
|
11
11
|
_export(exports, {
|
|
12
|
-
Badge
|
|
12
|
+
get Badge () {
|
|
13
13
|
return _Badge.Badge;
|
|
14
14
|
},
|
|
15
|
-
badgeClassNames
|
|
15
|
+
get badgeClassNames () {
|
|
16
16
|
return _useBadgeStylesstyles.badgeClassNames;
|
|
17
17
|
},
|
|
18
|
-
renderBadge_unstable
|
|
18
|
+
get renderBadge_unstable () {
|
|
19
19
|
return _renderBadge.renderBadge_unstable;
|
|
20
20
|
},
|
|
21
|
-
useBadgeBase_unstable
|
|
21
|
+
get useBadgeBase_unstable () {
|
|
22
22
|
return _useBadge.useBadgeBase_unstable;
|
|
23
23
|
},
|
|
24
|
-
useBadgeStyles_unstable
|
|
24
|
+
get useBadgeStyles_unstable () {
|
|
25
25
|
return _useBadgeStylesstyles.useBadgeStyles_unstable;
|
|
26
26
|
},
|
|
27
|
-
useBadge_unstable
|
|
27
|
+
get useBadge_unstable () {
|
|
28
28
|
return _useBadge.useBadge_unstable;
|
|
29
29
|
}
|
|
30
30
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["
|
|
1
|
+
{"version":3,"sources":["../../../src/components/Badge/index.ts"],"sourcesContent":["export { Badge } from './Badge';\n// Explicit exports to omit BadgeCommons\nexport type { BadgeBaseProps, BadgeBaseState, BadgeProps, BadgeSlots, BadgeState } from './Badge.types';\nexport { renderBadge_unstable } from './renderBadge';\nexport { useBadge_unstable, useBadgeBase_unstable } from './useBadge';\nexport { badgeClassNames, useBadgeStyles_unstable } from './useBadgeStyles.styles';\n"],"names":["Badge","renderBadge_unstable","useBadge_unstable","useBadgeBase_unstable","badgeClassNames","useBadgeStyles_unstable"],"mappings":";;;;;;;;;;;;eAASA,YAAK;;;eAKLI,qCAAe;;;eAFfH,iCAAoB;;;eACDE,+BAAqB;;;eACvBE,6CAAuB;;;eADxCH,2BAAiB;;;uBAJJ,aAAU;6BAGK,mBAAgB;0BACI,gBAAa;sCACb,6BAA0B"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["
|
|
1
|
+
{"version":3,"sources":["../../../src/components/Badge/renderBadge.tsx"],"sourcesContent":["/** @jsxRuntime automatic */\n/** @jsxImportSource @fluentui/react-jsx-runtime */\n\nimport { assertSlots } from '@fluentui/react-utilities';\nimport type { JSXElement } from '@fluentui/react-utilities';\n\nimport type { BadgeBaseState, BadgeSlots } from './Badge.types';\n\nexport const renderBadge_unstable = (state: BadgeBaseState): JSXElement => {\n assertSlots<BadgeSlots>(state);\n\n return (\n <state.root>\n {state.iconPosition === 'before' && state.icon && <state.icon />}\n {state.root.children}\n {state.iconPosition === 'after' && state.icon && <state.icon />}\n </state.root>\n );\n};\n"],"names":["assertSlots","renderBadge_unstable","state","root","iconPosition","icon","children"],"mappings":";;;;+BAQaC;;;;;;;gCAPb,gDAAiD,GAEjD,SAASD,WAAW,QAAQ,4BAA4B;AAKjD,6BAA6B,CAACE;QACnCF,2BAAAA,EAAwBE;IAExB,OAAA,WAAA,OACE,gBAAA,EAACA,MAAMC,IAAI,EAAA;;YACRD,MAAME,YAAY,KAAK,YAAYF,MAAMG,IAAI,IAAA,WAAA,OAAI,eAAA,EAACH,MAAMG,IAAI,EAAA,CAAA;YAC5DH,MAAMC,IAAI,CAACG,QAAQ;YACnBJ,MAAME,YAAY,KAAK,WAAWF,MAAMG,IAAI,IAAA,WAAA,OAAI,eAAA,EAACH,MAAMG,IAAI,EAAA,CAAA;;;AAGlE,EAAE"}
|
|
@@ -6,14 +6,14 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
function _export(target, all) {
|
|
7
7
|
for(var name in all)Object.defineProperty(target, name, {
|
|
8
8
|
enumerable: true,
|
|
9
|
-
get: all
|
|
9
|
+
get: Object.getOwnPropertyDescriptor(all, name).get
|
|
10
10
|
});
|
|
11
11
|
}
|
|
12
12
|
_export(exports, {
|
|
13
|
-
useBadgeBase_unstable
|
|
13
|
+
get useBadgeBase_unstable () {
|
|
14
14
|
return useBadgeBase_unstable;
|
|
15
15
|
},
|
|
16
|
-
useBadge_unstable
|
|
16
|
+
get useBadge_unstable () {
|
|
17
17
|
return useBadge_unstable;
|
|
18
18
|
}
|
|
19
19
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["
|
|
1
|
+
{"version":3,"sources":["../../../src/components/Badge/useBadge.ts"],"sourcesContent":["'use client';\n\nimport type * as React from 'react';\nimport { getIntrinsicElementProps, slot } from '@fluentui/react-utilities';\nimport type { BadgeBaseProps, BadgeBaseState, BadgeProps, BadgeState } from './Badge.types';\n\n/**\n * Returns the props and state required to render the component\n */\nexport const useBadge_unstable = (props: BadgeProps, ref: React.Ref<HTMLElement>): BadgeState => {\n const { shape = 'circular', size = 'medium', appearance = 'filled', color = 'brand', ...badgeProps } = props;\n\n const state = useBadgeBase_unstable(badgeProps, ref as React.Ref<HTMLDivElement>);\n\n return {\n ...state,\n shape,\n size,\n appearance,\n color,\n };\n};\n\n/**\n * Base hook for Badge component, which manages state related to slots structure and ARIA attributes.\n *\n * @param props - User provided props to the Badge component.\n * @param ref - User provided ref to be passed to the Badge component.\n */\nexport const useBadgeBase_unstable = (props: BadgeBaseProps, ref: React.Ref<HTMLDivElement>): BadgeBaseState => {\n const { iconPosition = 'before' } = props;\n\n return {\n iconPosition,\n components: {\n root: 'div',\n icon: 'span',\n },\n root: slot.always(\n getIntrinsicElementProps('div', {\n ref,\n ...props,\n }),\n { elementType: 'div' },\n ),\n icon: slot.optional(props.icon, { elementType: 'span' }),\n };\n};\n"],"names":["getIntrinsicElementProps","slot","useBadge_unstable","props","ref","shape","size","appearance","color","badgeProps","state","useBadgeBase_unstable","iconPosition","components","root","icon","always","elementType","optional"],"mappings":"AAAA;;;;;;;;;;;;QA6BaW;;;;;;;gCA1BkC,4BAA4B;AAMpE,MAAMT,oBAAoB,CAACC,OAAmBC;IACnD,MAAM,EAAEC,QAAQ,UAAU,EAAEC,OAAO,QAAQ,EAAEC,aAAa,QAAQ,EAAEC,QAAQ,OAAO,EAAE,GAAGC,YAAY,GAAGN;IAEvG,MAAMO,QAAQC,sBAAsBF,YAAYL;IAEhD,OAAO;QACL,GAAGM,KAAK;QACRL;QACAC;QACAC;QACAC;IACF;AACF,EAAE;AAQK,8BAA8B,CAACL,OAAuBC;IAC3D,MAAM,EAAEQ,eAAe,QAAQ,EAAE,GAAGT;IAEpC,OAAO;QACLS;QACAC,YAAY;YACVC,MAAM;YACNC,MAAM;QACR;QACAD,MAAMb,oBAAAA,CAAKe,MAAM,CACfhB,4CAAAA,EAAyB,OAAO;YAC9BI;YACA,GAAGD,KAAK;QACV,IACA;YAAEc,aAAa;QAAM;QAEvBF,MAAMd,oBAAAA,CAAKiB,QAAQ,CAACf,MAAMY,IAAI,EAAE;YAAEE,aAAa;QAAO;IACxD;AACF,EAAE"}
|
|
@@ -6,14 +6,14 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
function _export(target, all) {
|
|
7
7
|
for(var name in all)Object.defineProperty(target, name, {
|
|
8
8
|
enumerable: true,
|
|
9
|
-
get: all
|
|
9
|
+
get: Object.getOwnPropertyDescriptor(all, name).get
|
|
10
10
|
});
|
|
11
11
|
}
|
|
12
12
|
_export(exports, {
|
|
13
|
-
badgeClassNames
|
|
13
|
+
get badgeClassNames () {
|
|
14
14
|
return badgeClassNames;
|
|
15
15
|
},
|
|
16
|
-
useBadgeStyles_unstable
|
|
16
|
+
get useBadgeStyles_unstable () {
|
|
17
17
|
return useBadgeStyles_unstable;
|
|
18
18
|
}
|
|
19
19
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["useBadgeStyles.styles.js"],"sourcesContent":["'use client';\nimport * as React from \"react\";\nimport { shorthands, makeResetStyles, makeStyles, mergeClasses } from \"@griffel/react\";\nimport { tokens, typographyStyles } from \"@fluentui/react-theme\";\nexport const badgeClassNames = {\n root: 'fui-Badge',\n icon: 'fui-Badge__icon'\n};\n// The text content of the badge has additional horizontal padding, but there is no `text` slot to add that padding to.\n// Instead, add extra padding to the root, and a negative margin on the icon to \"remove\" the extra padding on the icon.\nconst textPadding = tokens.spacingHorizontalXXS;\nconst useRootClassName = makeResetStyles({\n display: 'inline-flex',\n boxSizing: 'border-box',\n alignItems: 'center',\n justifyContent: 'center',\n position: 'relative',\n ...typographyStyles.caption1Strong,\n height: '20px',\n minWidth: '20px',\n padding: `0 calc(${tokens.spacingHorizontalXS} + ${textPadding})`,\n borderRadius: tokens.borderRadiusCircular,\n // Use a transparent stroke (rather than no border) so the border is visible in high contrast\n borderColor: tokens.colorTransparentStroke,\n '::after': {\n content: '\"\"',\n position: 'absolute',\n top: 0,\n left: 0,\n bottom: 0,\n right: 0,\n borderStyle: 'solid',\n borderColor: 'inherit',\n borderWidth: tokens.strokeWidthThin,\n borderRadius: 'inherit'\n }\n});\nconst useRootStyles = makeStyles({\n fontSmallToTiny: {\n ...typographyStyles.caption2Strong\n },\n // size\n tiny: {\n width: '6px',\n height: '6px',\n fontSize: '4px',\n lineHeight: '4px',\n minWidth: 'unset',\n padding: 'unset'\n },\n 'extra-small': {\n width: '10px',\n height: '10px',\n fontSize: '6px',\n lineHeight: '6px',\n minWidth: 'unset',\n padding: 'unset'\n },\n small: {\n minWidth: '16px',\n height: '16px',\n padding: `0 calc(${tokens.spacingHorizontalXXS} + ${textPadding})`\n },\n medium: {\n },\n large: {\n minWidth: '24px',\n height: '24px',\n padding: `0 calc(${tokens.spacingHorizontalXS} + ${textPadding})`\n },\n 'extra-large': {\n minWidth: '32px',\n height: '32px',\n padding: `0 calc(${tokens.spacingHorizontalSNudge} + ${textPadding})`\n },\n // shape\n square: {\n borderRadius: tokens.borderRadiusNone\n },\n rounded: {\n borderRadius: tokens.borderRadiusMedium\n },\n roundedSmallToTiny: {\n borderRadius: tokens.borderRadiusSmall\n },\n circular: {\n },\n // hide the boder when appearance is \"ghost\"\n borderGhost: {\n // The border is applied in an ::after pseudo-element because it should not affect layout.\n // The padding and size of the badge should be the same regardless of whether or not it has a border.\n '::after': {\n display: 'none'\n }\n },\n // appearance: filled\n filled: {\n },\n 'filled-brand': {\n backgroundColor: tokens.colorBrandBackground,\n color: tokens.colorNeutralForegroundOnBrand\n },\n 'filled-danger': {\n backgroundColor: tokens.colorPaletteRedBackground3,\n color: tokens.colorNeutralForegroundOnBrand\n },\n 'filled-important': {\n backgroundColor: tokens.colorNeutralForeground1,\n color: tokens.colorNeutralBackground1\n },\n 'filled-informative': {\n backgroundColor: tokens.colorNeutralBackground5,\n color: tokens.colorNeutralForeground3\n },\n 'filled-severe': {\n backgroundColor: tokens.colorPaletteDarkOrangeBackground3,\n color: tokens.colorNeutralForegroundOnBrand\n },\n 'filled-subtle': {\n backgroundColor: tokens.colorNeutralBackground1,\n color: tokens.colorNeutralForeground1\n },\n 'filled-success': {\n backgroundColor: tokens.colorPaletteGreenBackground3,\n color: tokens.colorNeutralForegroundOnBrand\n },\n 'filled-warning': {\n backgroundColor: tokens.colorPaletteYellowBackground3,\n color: tokens.colorNeutralForeground1Static\n },\n // appearance: ghost\n ghost: {\n },\n 'ghost-brand': {\n color: tokens.colorBrandForeground1\n },\n 'ghost-danger': {\n color: tokens.colorPaletteRedForeground3\n },\n 'ghost-important': {\n color: tokens.colorNeutralForeground1\n },\n 'ghost-informative': {\n color: tokens.colorNeutralForeground3\n },\n 'ghost-severe': {\n color: tokens.colorPaletteDarkOrangeForeground3\n },\n 'ghost-subtle': {\n color: tokens.colorNeutralForegroundStaticInverted\n },\n 'ghost-success': {\n color: tokens.colorPaletteGreenForeground3\n },\n 'ghost-warning': {\n color: tokens.colorPaletteYellowForeground2\n },\n // appearance: outline\n outline: {\n ...shorthands.borderColor('currentColor')\n },\n 'outline-brand': {\n color: tokens.colorBrandForeground1\n },\n 'outline-danger': {\n color: tokens.colorPaletteRedForeground3,\n ...shorthands.borderColor(tokens.colorPaletteRedBorder2)\n },\n 'outline-important': {\n color: tokens.colorNeutralForeground3,\n ...shorthands.borderColor(tokens.colorNeutralStrokeAccessible)\n },\n 'outline-informative': {\n color: tokens.colorNeutralForeground3,\n ...shorthands.borderColor(tokens.colorNeutralStroke2)\n },\n 'outline-severe': {\n color: tokens.colorPaletteDarkOrangeForeground3\n },\n 'outline-subtle': {\n color: tokens.colorNeutralForegroundStaticInverted\n },\n 'outline-success': {\n color: tokens.colorPaletteGreenForeground3,\n ...shorthands.borderColor(tokens.colorPaletteGreenBorder2)\n },\n 'outline-warning': {\n color: tokens.colorPaletteYellowForeground2\n },\n // appearance: tint\n tint: {\n },\n 'tint-brand': {\n backgroundColor: tokens.colorBrandBackground2,\n color: tokens.colorBrandForeground2,\n ...shorthands.borderColor(tokens.colorBrandStroke2)\n },\n 'tint-danger': {\n backgroundColor: tokens.colorPaletteRedBackground1,\n color: tokens.colorPaletteRedForeground1,\n ...shorthands.borderColor(tokens.colorPaletteRedBorder1)\n },\n 'tint-important': {\n backgroundColor: tokens.colorNeutralForeground3,\n color: tokens.colorNeutralBackground1,\n ...shorthands.borderColor(tokens.colorTransparentStroke)\n },\n 'tint-informative': {\n backgroundColor: tokens.colorNeutralBackground4,\n color: tokens.colorNeutralForeground3,\n ...shorthands.borderColor(tokens.colorNeutralStroke2)\n },\n 'tint-severe': {\n backgroundColor: tokens.colorPaletteDarkOrangeBackground1,\n color: tokens.colorPaletteDarkOrangeForeground1,\n ...shorthands.borderColor(tokens.colorPaletteDarkOrangeBorder1)\n },\n 'tint-subtle': {\n backgroundColor: tokens.colorNeutralBackground1,\n color: tokens.colorNeutralForeground3,\n ...shorthands.borderColor(tokens.colorNeutralStroke2)\n },\n 'tint-success': {\n backgroundColor: tokens.colorPaletteGreenBackground1,\n color: tokens.colorPaletteGreenForeground1,\n ...shorthands.borderColor(tokens.colorPaletteGreenBorder1)\n },\n 'tint-warning': {\n backgroundColor: tokens.colorPaletteYellowBackground1,\n color: tokens.colorPaletteYellowForeground1,\n ...shorthands.borderColor(tokens.colorPaletteYellowBorder1)\n }\n});\nconst useIconRootClassName = makeResetStyles({\n display: 'flex',\n lineHeight: '1',\n margin: `0 calc(-1 * ${textPadding})`,\n fontSize: '12px'\n});\nconst useIconStyles = makeStyles({\n beforeText: {\n marginRight: `calc(${tokens.spacingHorizontalXXS} + ${textPadding})`\n },\n afterText: {\n marginLeft: `calc(${tokens.spacingHorizontalXXS} + ${textPadding})`\n },\n beforeTextXL: {\n marginRight: `calc(${tokens.spacingHorizontalXS} + ${textPadding})`\n },\n afterTextXL: {\n marginLeft: `calc(${tokens.spacingHorizontalXS} + ${textPadding})`\n },\n // size\n tiny: {\n fontSize: '6px'\n },\n 'extra-small': {\n fontSize: '10px'\n },\n small: {\n fontSize: '12px'\n },\n medium: {\n },\n large: {\n fontSize: '16px'\n },\n 'extra-large': {\n fontSize: '20px'\n }\n});\n/**\n * Applies style classnames to slots\n */ export const useBadgeStyles_unstable = (state)=>{\n const rootClassName = useRootClassName();\n const rootStyles = useRootStyles();\n const smallToTiny = state.size === 'small' || state.size === 'extra-small' || state.size === 'tiny';\n // eslint-disable-next-line react-hooks/immutability\n state.root.className = mergeClasses(badgeClassNames.root, rootClassName, smallToTiny && rootStyles.fontSmallToTiny, rootStyles[state.size], rootStyles[state.shape], state.shape === 'rounded' && smallToTiny && rootStyles.roundedSmallToTiny, state.appearance === 'ghost' && rootStyles.borderGhost, rootStyles[state.appearance], rootStyles[`${state.appearance}-${state.color}`], state.root.className);\n const iconRootClassName = useIconRootClassName();\n const iconStyles = useIconStyles();\n if (state.icon) {\n let iconPositionClass;\n // Handle the edge case where children is 0 (a falsy value that should still render text and have margin)\n if (React.Children.toArray(state.root.children).length > 0) {\n if (state.size === 'extra-large') {\n iconPositionClass = state.iconPosition === 'after' ? iconStyles.afterTextXL : iconStyles.beforeTextXL;\n } else {\n iconPositionClass = state.iconPosition === 'after' ? iconStyles.afterText : iconStyles.beforeText;\n }\n }\n // eslint-disable-next-line react-hooks/immutability\n state.icon.className = mergeClasses(badgeClassNames.icon, iconRootClassName, iconPositionClass, iconStyles[state.size], state.icon.className);\n }\n return state;\n};\n"],"names":["React","shorthands","__resetStyles","__styles","mergeClasses","tokens","typographyStyles","badgeClassNames","root","icon","textPadding","spacingHorizontalXXS","useRootClassName","useRootStyles","fontSmallToTiny","Bahqtrf","Be2twd7","Bhrd7zp","Bg96gwp","tiny","a9b677","Bqenvij","Bf4jedk","Byoj8tv","uwmqm3","z189sj","z8tnut","B0ocmuz","small","medium","large","square","Beyfa6y","Bbmb7ep","Btl43ni","B7oj6ja","Dimara","rounded","roundedSmallToTiny","circular","borderGhost","ap17g6","filled","De3pzq","sj55zd","ghost","outline","g2u3we","h3c5rm","B9xav0g","zhjwy3","tint","d","p","useIconRootClassName","useIconStyles","beforeText","t21cq0","afterText","Frg6f3","beforeTextXL","afterTextXL","useBadgeStyles_unstable","state","rootClassName","rootStyles","smallToTiny","size","className","shape","appearance","color","iconRootClassName","iconStyles","iconPositionClass","Children","toArray","children","length","iconPosition"],"mappings":"AAAA,YAAY;;;;;;;;;;;;IAICO,eAAe;;;2BA6QY;eAAvBuD;;;;iEAhRM,OAAO;wBACwC,gBAAgB;4BAC7C,uBAAuB;AACzD,wBAAwB;IAC3BtD,IAAI,EAAE,WAAW;IACjBC,IAAI,EAAE;AACV,CAAC;AACD,uHAAA;AACA,uHAAA;A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,CAAC4D,SAAS,CAAC;IAC7Y,MAAMI,iBAAiB,GAAGlB,oBAAoB,CAAC,CAAC;IAChD,MAAMmB,UAAU,GAAGlB,aAAa,CAAC,CAAC;IAClC,IAAIQ,KAAK,CAACtD,IAAI,EAAE;QACZ,IAAIiE,iBAAiB;QACrB,yGAAA;QACA,IAAI1E,KAAK,EAAC2E,QAAQ,CAACC,OAAO,CAACb,KAAK,CAACvD,IAAI,CAACqE,QAAQ,CAAC,CAACC,MAAM,GAAG,CAAC,EAAE;YACxD,IAAIf,KAAK,CAACI,IAAI,KAAK,aAAa,EAAE;gBAC9BO,iBAAiB,GAAGX,KAAK,CAACgB,YAAY,KAAK,OAAO,GAAGN,UAAU,CAACZ,WAAW,GAAGY,UAAU,CAACb,YAAY;YACzG,CAAC,MAAM;gBACHc,iBAAiB,GAAGX,KAAK,CAACgB,YAAY,KAAK,OAAO,GAAGN,UAAU,CAACf,SAAS,GAAGe,UAAU,CAACjB,UAAU;YACrG;QACJ;QACA,oDAAA;QACAO,KAAK,CAACtD,IAAI,CAAC2D,SAAS,GAAGhE,wBAAY,EAACG,eAAe,CAACE,IAAI,EAAE+D,iBAAiB,EAAEE,iBAAiB,EAAED,UAAU,CAACV,KAAK,CAACI,IAAI,CAAC,EAAEJ,KAAK,CAACtD,IAAI,CAAC2D,SAAS,CAAC;IACjJ;IACA,OAAOL,KAAK;AAChB,CAAC"}
|
|
1
|
+
{"version":3,"sources":["useBadgeStyles.styles.js"],"sourcesContent":["'use client';\nimport * as React from \"react\";\nimport { shorthands, makeResetStyles, makeStyles, mergeClasses } from \"@griffel/react\";\nimport { tokens, typographyStyles } from \"@fluentui/react-theme\";\nexport const badgeClassNames = {\n root: 'fui-Badge',\n icon: 'fui-Badge__icon'\n};\n// The text content of the badge has additional horizontal padding, but there is no `text` slot to add that padding to.\n// Instead, add extra padding to the root, and a negative margin on the icon to \"remove\" the extra padding on the icon.\nconst textPadding = tokens.spacingHorizontalXXS;\nconst useRootClassName = makeResetStyles({\n display: 'inline-flex',\n boxSizing: 'border-box',\n alignItems: 'center',\n justifyContent: 'center',\n position: 'relative',\n ...typographyStyles.caption1Strong,\n height: '20px',\n minWidth: '20px',\n padding: `0 calc(${tokens.spacingHorizontalXS} + ${textPadding})`,\n borderRadius: tokens.borderRadiusCircular,\n // Use a transparent stroke (rather than no border) so the border is visible in high contrast\n borderColor: tokens.colorTransparentStroke,\n '::after': {\n content: '\"\"',\n position: 'absolute',\n top: 0,\n left: 0,\n bottom: 0,\n right: 0,\n borderStyle: 'solid',\n borderColor: 'inherit',\n borderWidth: tokens.strokeWidthThin,\n borderRadius: 'inherit'\n }\n});\nconst useRootStyles = makeStyles({\n fontSmallToTiny: {\n ...typographyStyles.caption2Strong\n },\n // size\n tiny: {\n width: '6px',\n height: '6px',\n fontSize: '4px',\n lineHeight: '4px',\n minWidth: 'unset',\n padding: 'unset'\n },\n 'extra-small': {\n width: '10px',\n height: '10px',\n fontSize: '6px',\n lineHeight: '6px',\n minWidth: 'unset',\n padding: 'unset'\n },\n small: {\n minWidth: '16px',\n height: '16px',\n padding: `0 calc(${tokens.spacingHorizontalXXS} + ${textPadding})`\n },\n medium: {\n },\n large: {\n minWidth: '24px',\n height: '24px',\n padding: `0 calc(${tokens.spacingHorizontalXS} + ${textPadding})`\n },\n 'extra-large': {\n minWidth: '32px',\n height: '32px',\n padding: `0 calc(${tokens.spacingHorizontalSNudge} + ${textPadding})`\n },\n // shape\n square: {\n borderRadius: tokens.borderRadiusNone\n },\n rounded: {\n borderRadius: tokens.borderRadiusMedium\n },\n roundedSmallToTiny: {\n borderRadius: tokens.borderRadiusSmall\n },\n circular: {\n },\n // hide the boder when appearance is \"ghost\"\n borderGhost: {\n // The border is applied in an ::after pseudo-element because it should not affect layout.\n // The padding and size of the badge should be the same regardless of whether or not it has a border.\n '::after': {\n display: 'none'\n }\n },\n // appearance: filled\n filled: {\n },\n 'filled-brand': {\n backgroundColor: tokens.colorBrandBackground,\n color: tokens.colorNeutralForegroundOnBrand\n },\n 'filled-danger': {\n backgroundColor: tokens.colorPaletteRedBackground3,\n color: tokens.colorNeutralForegroundOnBrand\n },\n 'filled-important': {\n backgroundColor: tokens.colorNeutralForeground1,\n color: tokens.colorNeutralBackground1\n },\n 'filled-informative': {\n backgroundColor: tokens.colorNeutralBackground5,\n color: tokens.colorNeutralForeground3\n },\n 'filled-severe': {\n backgroundColor: tokens.colorPaletteDarkOrangeBackground3,\n color: tokens.colorNeutralForegroundOnBrand\n },\n 'filled-subtle': {\n backgroundColor: tokens.colorNeutralBackground1,\n color: tokens.colorNeutralForeground1\n },\n 'filled-success': {\n backgroundColor: tokens.colorPaletteGreenBackground3,\n color: tokens.colorNeutralForegroundOnBrand\n },\n 'filled-warning': {\n backgroundColor: tokens.colorPaletteYellowBackground3,\n color: tokens.colorNeutralForeground1Static\n },\n // appearance: ghost\n ghost: {\n },\n 'ghost-brand': {\n color: tokens.colorBrandForeground1\n },\n 'ghost-danger': {\n color: tokens.colorPaletteRedForeground3\n },\n 'ghost-important': {\n color: tokens.colorNeutralForeground1\n },\n 'ghost-informative': {\n color: tokens.colorNeutralForeground3\n },\n 'ghost-severe': {\n color: tokens.colorPaletteDarkOrangeForeground3\n },\n 'ghost-subtle': {\n color: tokens.colorNeutralForegroundStaticInverted\n },\n 'ghost-success': {\n color: tokens.colorPaletteGreenForeground3\n },\n 'ghost-warning': {\n color: tokens.colorPaletteYellowForeground2\n },\n // appearance: outline\n outline: {\n ...shorthands.borderColor('currentColor')\n },\n 'outline-brand': {\n color: tokens.colorBrandForeground1\n },\n 'outline-danger': {\n color: tokens.colorPaletteRedForeground3,\n ...shorthands.borderColor(tokens.colorPaletteRedBorder2)\n },\n 'outline-important': {\n color: tokens.colorNeutralForeground3,\n ...shorthands.borderColor(tokens.colorNeutralStrokeAccessible)\n },\n 'outline-informative': {\n color: tokens.colorNeutralForeground3,\n ...shorthands.borderColor(tokens.colorNeutralStroke2)\n },\n 'outline-severe': {\n color: tokens.colorPaletteDarkOrangeForeground3\n },\n 'outline-subtle': {\n color: tokens.colorNeutralForegroundStaticInverted\n },\n 'outline-success': {\n color: tokens.colorPaletteGreenForeground3,\n ...shorthands.borderColor(tokens.colorPaletteGreenBorder2)\n },\n 'outline-warning': {\n color: tokens.colorPaletteYellowForeground2\n },\n // appearance: tint\n tint: {\n },\n 'tint-brand': {\n backgroundColor: tokens.colorBrandBackground2,\n color: tokens.colorBrandForeground2,\n ...shorthands.borderColor(tokens.colorBrandStroke2)\n },\n 'tint-danger': {\n backgroundColor: tokens.colorPaletteRedBackground1,\n color: tokens.colorPaletteRedForeground1,\n ...shorthands.borderColor(tokens.colorPaletteRedBorder1)\n },\n 'tint-important': {\n backgroundColor: tokens.colorNeutralForeground3,\n color: tokens.colorNeutralBackground1,\n ...shorthands.borderColor(tokens.colorTransparentStroke)\n },\n 'tint-informative': {\n backgroundColor: tokens.colorNeutralBackground4,\n color: tokens.colorNeutralForeground3,\n ...shorthands.borderColor(tokens.colorNeutralStroke2)\n },\n 'tint-severe': {\n backgroundColor: tokens.colorPaletteDarkOrangeBackground1,\n color: tokens.colorPaletteDarkOrangeForeground1,\n ...shorthands.borderColor(tokens.colorPaletteDarkOrangeBorder1)\n },\n 'tint-subtle': {\n backgroundColor: tokens.colorNeutralBackground1,\n color: tokens.colorNeutralForeground3,\n ...shorthands.borderColor(tokens.colorNeutralStroke2)\n },\n 'tint-success': {\n backgroundColor: tokens.colorPaletteGreenBackground1,\n color: tokens.colorPaletteGreenForeground1,\n ...shorthands.borderColor(tokens.colorPaletteGreenBorder1)\n },\n 'tint-warning': {\n backgroundColor: tokens.colorPaletteYellowBackground1,\n color: tokens.colorPaletteYellowForeground1,\n ...shorthands.borderColor(tokens.colorPaletteYellowBorder1)\n }\n});\nconst useIconRootClassName = makeResetStyles({\n display: 'flex',\n lineHeight: '1',\n margin: `0 calc(-1 * ${textPadding})`,\n fontSize: '12px'\n});\nconst useIconStyles = makeStyles({\n beforeText: {\n marginRight: `calc(${tokens.spacingHorizontalXXS} + ${textPadding})`\n },\n afterText: {\n marginLeft: `calc(${tokens.spacingHorizontalXXS} + ${textPadding})`\n },\n beforeTextXL: {\n marginRight: `calc(${tokens.spacingHorizontalXS} + ${textPadding})`\n },\n afterTextXL: {\n marginLeft: `calc(${tokens.spacingHorizontalXS} + ${textPadding})`\n },\n // size\n tiny: {\n fontSize: '6px'\n },\n 'extra-small': {\n fontSize: '10px'\n },\n small: {\n fontSize: '12px'\n },\n medium: {\n },\n large: {\n fontSize: '16px'\n },\n 'extra-large': {\n fontSize: '20px'\n }\n});\n/**\n * Applies style classnames to slots\n */ export const useBadgeStyles_unstable = (state)=>{\n const rootClassName = useRootClassName();\n const rootStyles = useRootStyles();\n const smallToTiny = state.size === 'small' || state.size === 'extra-small' || state.size === 'tiny';\n // eslint-disable-next-line react-hooks/immutability\n state.root.className = mergeClasses(badgeClassNames.root, rootClassName, smallToTiny && rootStyles.fontSmallToTiny, rootStyles[state.size], rootStyles[state.shape], state.shape === 'rounded' && smallToTiny && rootStyles.roundedSmallToTiny, state.appearance === 'ghost' && rootStyles.borderGhost, rootStyles[state.appearance], rootStyles[`${state.appearance}-${state.color}`], state.root.className);\n const iconRootClassName = useIconRootClassName();\n const iconStyles = useIconStyles();\n if (state.icon) {\n let iconPositionClass;\n // Handle the edge case where children is 0 (a falsy value that should still render text and have margin)\n if (React.Children.toArray(state.root.children).length > 0) {\n if (state.size === 'extra-large') {\n iconPositionClass = state.iconPosition === 'after' ? iconStyles.afterTextXL : iconStyles.beforeTextXL;\n } else {\n iconPositionClass = state.iconPosition === 'after' ? iconStyles.afterText : iconStyles.beforeText;\n }\n }\n // eslint-disable-next-line react-hooks/immutability\n state.icon.className = mergeClasses(badgeClassNames.icon, iconRootClassName, iconPositionClass, iconStyles[state.size], state.icon.className);\n }\n return state;\n};\n"],"names":["React","shorthands","__resetStyles","__styles","mergeClasses","tokens","typographyStyles","badgeClassNames","root","icon","textPadding","spacingHorizontalXXS","useRootClassName","useRootStyles","fontSmallToTiny","Bahqtrf","Be2twd7","Bhrd7zp","Bg96gwp","tiny","a9b677","Bqenvij","Bf4jedk","Byoj8tv","uwmqm3","z189sj","z8tnut","B0ocmuz","small","medium","large","square","Beyfa6y","Bbmb7ep","Btl43ni","B7oj6ja","Dimara","rounded","roundedSmallToTiny","circular","borderGhost","ap17g6","filled","De3pzq","sj55zd","ghost","outline","g2u3we","h3c5rm","B9xav0g","zhjwy3","tint","d","p","useIconRootClassName","useIconStyles","beforeText","t21cq0","afterText","Frg6f3","beforeTextXL","afterTextXL","useBadgeStyles_unstable","state","rootClassName","rootStyles","smallToTiny","size","className","shape","appearance","color","iconRootClassName","iconStyles","iconPositionClass","Children","toArray","children","length","iconPosition"],"mappings":"AAAA,YAAY;;;;;;;;;;;;QAICO,eAAe;;;;eA6QXuD,uBAAuB;;;;iEAhRjB,OAAO;wBACwC,gBAAgB;4BAC7C,uBAAuB;AACzD,wBAAwB;IAC3BtD,IAAI,EAAE,WAAW;IACjBC,IAAI,EAAE;AACV,CAAC;AACD,uHAAA;AACA,uHAAA;AACA,MAAMC,WAAW,GAAGL,kBAAM,CAACM,oBAAoB;AAC/C,MAAMC,gBAAgB,GAAA,WAAA,OAAGV,qBAAA,EAAA,WAAA,YAAA;IAAA;IAAA;IAAA;IAAA;CAyBxB,CAAC;AACF,MAAMW,aAAa,GAAA,WAAA,OAAGV,gBAAA,EAAA;IAAAW,eAAA,EAAA;QAAAC,OAAA,EAAA;QAAAC,OAAA,EAAA;QAAAC,OAAA,EAAA;QAAAC,OAAA,EAAA;IAAA;IAAAC,IAAA,EAAA;QAAAC,MAAA,EAAA;QAAAC,OAAA,EAAA;QAAAL,OAAA,EAAA;QAAAE,OAAA,EAAA;QAAAI,OAAA,EAAA;QAAAC,OAAA,EAAA;QAAAC,MAAA,EAAA;QAAAC,MAAA,EAAA;QAAAC,MAAA,EAAA;QAAAC,OAAA,EAAA;IAAA;IAAA,eAAA;QAAAP,MAAA,EAAA;QAAAC,OAAA,EAAA;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S,GAAGe,UAAU,CAACjB,UAAU;YACrG;QACJ;QACA,oDAAA;QACAO,KAAK,CAACtD,IAAI,CAAC2D,SAAS,GAAGhE,wBAAY,EAACG,eAAe,CAACE,IAAI,EAAE+D,iBAAiB,EAAEE,iBAAiB,EAAED,UAAU,CAACV,KAAK,CAACI,IAAI,CAAC,EAAEJ,KAAK,CAACtD,IAAI,CAAC2D,SAAS,CAAC;IACjJ;IACA,OAAOL,KAAK;AAChB,CAAC"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", {
|
|
3
|
+
value: true
|
|
4
|
+
});
|
|
5
|
+
function _export(target, all) {
|
|
6
|
+
for(var name in all)Object.defineProperty(target, name, {
|
|
7
|
+
enumerable: true,
|
|
8
|
+
get: Object.getOwnPropertyDescriptor(all, name).get
|
|
9
|
+
});
|
|
10
|
+
}
|
|
11
|
+
_export(exports, {
|
|
12
|
+
get badgeClassNames () {
|
|
13
|
+
return badgeClassNames;
|
|
14
|
+
},
|
|
15
|
+
get useBadgeStyles_unstable () {
|
|
16
|
+
return useBadgeStyles_unstable;
|
|
17
|
+
}
|
|
18
|
+
});
|
|
19
|
+
const _interop_require_default = require("@swc/helpers/_/_interop_require_default");
|
|
20
|
+
const _interop_require_wildcard = require("@swc/helpers/_/_interop_require_wildcard");
|
|
21
|
+
const _react = /*#__PURE__*/ _interop_require_wildcard._(require("react"));
|
|
22
|
+
const _clsx = require("clsx");
|
|
23
|
+
const _Badgemodulecss = /*#__PURE__*/ _interop_require_default._(require("./Badge.module.css"));
|
|
24
|
+
const badgeClassNames = {
|
|
25
|
+
root: 'fui-Badge',
|
|
26
|
+
icon: 'fui-Badge__icon'
|
|
27
|
+
};
|
|
28
|
+
const useBadgeStyles_unstable = (state)=>{
|
|
29
|
+
// CSS class names match prop values exactly — styles[propValue] replaces all lookup maps.
|
|
30
|
+
// Ghost ::after, outline border-color, rounded radius for small/tiny, font-size for small/tiny,
|
|
31
|
+
// icon sizes, and extra-large icon margins are all handled by CSS (compound selectors + descendants).
|
|
32
|
+
state.root.className = (0, _clsx.clsx)(badgeClassNames.root, _Badgemodulecss.default.root, state.size !== 'medium' && _Badgemodulecss.default[state.size], state.shape !== 'circular' && _Badgemodulecss.default[state.shape], _Badgemodulecss.default[`${state.appearance}-${state.color}`], state.root.className);
|
|
33
|
+
if (state.icon) {
|
|
34
|
+
let iconPositionClass;
|
|
35
|
+
if (_react.Children.toArray(state.root.children).length > 0) {
|
|
36
|
+
iconPositionClass = state.iconPosition === 'after' ? _Badgemodulecss.default.iconAfterText : _Badgemodulecss.default.iconBeforeText;
|
|
37
|
+
}
|
|
38
|
+
state.icon.className = (0, _clsx.clsx)(badgeClassNames.icon, _Badgemodulecss.default.icon, iconPositionClass, state.icon.className);
|
|
39
|
+
}
|
|
40
|
+
return state;
|
|
41
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../src/components/Badge/useBadgeStyles.styles.css.ts"],"sourcesContent":["import * as React from 'react';\nimport { clsx } from 'clsx';\nimport type { SlotClassNames } from '@fluentui/react-utilities';\nimport styles from './Badge.module.css';\nimport type { BadgeSlots, BadgeState } from './Badge.types';\n\nexport const badgeClassNames: SlotClassNames<BadgeSlots> = {\n root: 'fui-Badge',\n icon: 'fui-Badge__icon',\n};\n\nexport const useBadgeStyles_unstable = (state: BadgeState): BadgeState => {\n // CSS class names match prop values exactly — styles[propValue] replaces all lookup maps.\n // Ghost ::after, outline border-color, rounded radius for small/tiny, font-size for small/tiny,\n // icon sizes, and extra-large icon margins are all handled by CSS (compound selectors + descendants).\n\n state.root.className = clsx(\n badgeClassNames.root,\n styles.root,\n // size: 'medium' is the .root default; all others match CSS class names including 'extra-small'/'extra-large'\n state.size !== 'medium' && (styles[state.size as keyof typeof styles] as string | undefined),\n // shape: 'circular' is the .root default\n state.shape !== 'circular' && (styles[state.shape as keyof typeof styles] as string | undefined),\n // appearance × color: CSS class `.filled-brand`, `.ghost-danger`, etc. match `${appearance}-${color}`\n styles[`${state.appearance}-${state.color}` as keyof typeof styles] as string | undefined,\n state.root.className,\n );\n\n if (state.icon) {\n let iconPositionClass: string | undefined;\n if (React.Children.toArray(state.root.children).length > 0) {\n iconPositionClass = state.iconPosition === 'after' ? styles.iconAfterText : styles.iconBeforeText;\n }\n\n state.icon.className = clsx(badgeClassNames.icon, styles.icon, iconPositionClass, state.icon.className);\n }\n\n return state;\n};\n"],"names":["React","clsx","styles","badgeClassNames","root","icon","useBadgeStyles_unstable","state","className","size","shape","appearance","color","iconPositionClass","Children","toArray","children","length","iconPosition","iconAfterText","iconBeforeText"],"mappings":";;;;;;;;;;;QAMaG;;;QAKAG;;;;;;iEAXU,QAAQ;sBACV,OAAO;yEAET,qBAAqB;AAGjC,wBAAoD;IACzDF,MAAM;IACNC,MAAM;AACR,EAAE;AAEK,gCAAgC,CAACE;IACtC,0FAA0F;IAC1F,gGAAgG;IAChG,sGAAsG;IAEtGA,MAAMH,IAAI,CAACI,SAAS,OAAGP,UAAAA,EACrBE,gBAAgBC,IAAI,EACpBF,uBAAAA,CAAOE,IAAI,EAEXG,AADA,MACME,IAAI,KAAK,YAAaP,uBAAM,CAACK,MAAME,IAAI,CAAwB,EACrE,AACAF,MAAMG,KAAK,KAAK,cAAeR,WADU,KAFqE,OAGzE,CAACK,MAAMG,KAAK,CAAwB,EACzE,AACAR,uBAAM,CAAC,GAAGK,MAAMI,UAAU,CAAC,CAAC,EAAEJ,MAAMK,KAAK,EAAE,CAAwB,EACnEL,MAAMH,IAAI,CAACI,SAAS,mBAFkF;IAKxG,IAAID,MAAMF,IAAI,EAAE;QACd,IAAIQ;QACJ,IAAIb,OAAMc,QAAQ,CAACC,OAAO,CAACR,MAAMH,IAAI,CAACY,QAAQ,EAAEC,MAAM,GAAG,GAAG;YAC1DJ,oBAAoBN,MAAMW,YAAY,KAAK,UAAUhB,uBAAAA,CAAOiB,aAAa,GAAGjB,uBAAAA,CAAOkB,cAAc;QACnG;QAEAb,MAAMF,IAAI,CAACG,SAAS,OAAGP,UAAAA,EAAKE,gBAAgBE,IAAI,EAAEH,uBAAAA,CAAOG,IAAI,EAAEQ,mBAAmBN,MAAMF,IAAI,CAACG,SAAS;IACxG;IAEA,OAAOD;AACT,EAAE"}
|
|
@@ -6,14 +6,14 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
function _export(target, all) {
|
|
7
7
|
for(var name in all)Object.defineProperty(target, name, {
|
|
8
8
|
enumerable: true,
|
|
9
|
-
get: all
|
|
9
|
+
get: Object.getOwnPropertyDescriptor(all, name).get
|
|
10
10
|
});
|
|
11
11
|
}
|
|
12
12
|
_export(exports, {
|
|
13
|
-
badgeClassNames
|
|
13
|
+
get badgeClassNames () {
|
|
14
14
|
return badgeClassNames;
|
|
15
15
|
},
|
|
16
|
-
useBadgeStyles_unstable
|
|
16
|
+
get useBadgeStyles_unstable () {
|
|
17
17
|
return useBadgeStyles_unstable;
|
|
18
18
|
}
|
|
19
19
|
});
|