@primer/react 0.0.0-20260813224533 → 0.0.0-20260814130501
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 +3 -28
- package/dist/ActionBar/ActionBar.js +8 -10
- package/dist/ActionList/Group-efcb39da.css +2 -0
- package/dist/ActionList/Group-efcb39da.css.map +1 -0
- package/dist/ActionList/Group.module.css.js +2 -2
- package/dist/ActionList/Heading.js +1 -2
- package/dist/ActionList/Item.js +277 -282
- package/dist/ActionList/LinkItem.js +3 -11
- package/dist/ActionList/index.d.ts +0 -3
- package/dist/ActionList/shared.d.ts +0 -4
- package/dist/AvatarStack/{AvatarStack-e6a99916.css → AvatarStack-9bb5649f.css} +2 -2
- package/dist/AvatarStack/AvatarStack-9bb5649f.css.map +1 -0
- package/dist/AvatarStack/AvatarStack.module.css.js +1 -1
- package/dist/CounterLabel/CounterLabel.js +2 -5
- package/dist/Details/Details.js +1 -2
- package/dist/Dialog/Dialog.js +2 -3
- package/dist/FeatureFlags/DefaultFeatureFlags.js +2 -1
- package/dist/NavList/NavList.d.ts +2 -4
- package/dist/NavList/NavList.js +45 -87
- package/dist/PageHeader/PageHeader.js +1 -2
- package/dist/Popover/Popover.d.ts +0 -1
- package/dist/Popover/Popover.js +47 -84
- package/dist/Portal/Portal.js +29 -91
- package/dist/Radio/Radio.js +1 -1
- package/dist/SelectPanel/SelectPanel.js +25 -26
- package/dist/ThemeProvider.d.ts +0 -3
- package/dist/ThemeProvider.js +129 -39
- package/dist/TooltipV2/Tooltip.js +2 -3
- package/dist/TreeView/TreeView.js +1 -0
- package/dist/UnderlineNav/UnderlineNav.d.ts +2 -3
- package/dist/UnderlineNav/UnderlineNav.js +1 -1
- package/dist/deprecated/ActionList/List.js +1 -2
- package/dist/experimental/SelectPanel2/SelectPanel.js +4 -7
- package/dist/experimental/Tabs/Tabs.js +33 -19
- package/dist/experimental/Tabs/types.d.ts +6 -0
- package/dist/experimental/Tabs/useTab.js +6 -1
- package/dist/experimental/Tabs/useTabList.js +29 -22
- package/dist/experimental/UnderlinePanels/UnderlinePanels.d.ts +38 -1
- package/dist/experimental/UnderlinePanels/UnderlinePanels.js +69 -18
- package/dist/hooks/useFocusZone.js +1 -2
- package/dist/hooks/useMenuInitialFocus.js +57 -72
- package/dist/legacy-theme/ts/color-schemes.js +3942 -3942
- package/dist/next/index.d.ts +1 -4
- package/dist/next/index.js +1 -3
- package/dist/theme.d.ts +54 -16
- package/dist/useTheme.d.ts +14 -2
- package/generated/components.json +56 -14
- package/generated/hooks.json +7 -2
- package/package.json +10 -8
- package/dist/ActionList/Group-d89306a8.css +0 -2
- package/dist/ActionList/Group-d89306a8.css.map +0 -1
- package/dist/AvatarStack/AvatarStack-e6a99916.css.map +0 -1
- package/dist/ThemeContext.d.ts +0 -20
- package/dist/internal/components/ThemeProviderBase.js +0 -50
- package/dist/internal/hooks/useThemeProvider.js +0 -71
- package/dist/next/ThemeProvider.d.ts +0 -7
- package/dist/next/ThemeProvider.js +0 -35
package/dist/ActionList/Item.js
CHANGED
|
@@ -138,10 +138,9 @@ const listRoleTypes = [
|
|
|
138
138
|
"tree"
|
|
139
139
|
];
|
|
140
140
|
const UnwrappedItem = (t0, forwardedRef) => {
|
|
141
|
-
var _slots$trailingVisual, _slots$description$pr, _slots$description, _slots$trailingAction
|
|
142
|
-
const $ = c(
|
|
141
|
+
var _slots$trailingVisual, _slots$description$pr, _slots$description, _slots$trailingAction;
|
|
142
|
+
const $ = c(161);
|
|
143
143
|
let _PrivateItemWrapper;
|
|
144
|
-
let _PrivateTooltipText;
|
|
145
144
|
let className;
|
|
146
145
|
let id;
|
|
147
146
|
let inactiveText;
|
|
@@ -155,7 +154,7 @@ const UnwrappedItem = (t0, forwardedRef) => {
|
|
|
155
154
|
let t4;
|
|
156
155
|
let t5;
|
|
157
156
|
if ($[0] !== t0) {
|
|
158
|
-
const { variant: t6, size: t7, disabled: t8, inactiveText: t9, selected: t10, active: t11, onSelect: t12, id: t13, role: t14, loading: t15, _PrivateItemWrapper: t16,
|
|
157
|
+
const { variant: t6, size: t7, disabled: t8, inactiveText: t9, selected: t10, active: t11, onSelect: t12, id: t13, role: t14, loading: t15, _PrivateItemWrapper: t16, className: t17, groupId: _groupId, renderItem: _renderItem, handleAddItem: _handleAddItem, ...t18 } = t0;
|
|
159
158
|
t1 = t6;
|
|
160
159
|
t2 = t7;
|
|
161
160
|
t3 = t8;
|
|
@@ -167,39 +166,36 @@ const UnwrappedItem = (t0, forwardedRef) => {
|
|
|
167
166
|
role = t14;
|
|
168
167
|
loading = t15;
|
|
169
168
|
_PrivateItemWrapper = t16;
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
props = t19;
|
|
169
|
+
className = t17;
|
|
170
|
+
props = t18;
|
|
173
171
|
$[0] = t0;
|
|
174
172
|
$[1] = _PrivateItemWrapper;
|
|
175
|
-
$[2] =
|
|
176
|
-
$[3] =
|
|
177
|
-
$[4] =
|
|
178
|
-
$[5] =
|
|
179
|
-
$[6] =
|
|
180
|
-
$[7] =
|
|
181
|
-
$[8] =
|
|
182
|
-
$[9] =
|
|
183
|
-
$[10] =
|
|
184
|
-
$[11] =
|
|
185
|
-
$[12] =
|
|
186
|
-
$[13] =
|
|
187
|
-
$[14] = t5;
|
|
173
|
+
$[2] = className;
|
|
174
|
+
$[3] = id;
|
|
175
|
+
$[4] = inactiveText;
|
|
176
|
+
$[5] = loading;
|
|
177
|
+
$[6] = onSelectUser;
|
|
178
|
+
$[7] = props;
|
|
179
|
+
$[8] = role;
|
|
180
|
+
$[9] = t1;
|
|
181
|
+
$[10] = t2;
|
|
182
|
+
$[11] = t3;
|
|
183
|
+
$[12] = t4;
|
|
184
|
+
$[13] = t5;
|
|
188
185
|
} else {
|
|
189
186
|
_PrivateItemWrapper = $[1];
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
t5 = $[14];
|
|
187
|
+
className = $[2];
|
|
188
|
+
id = $[3];
|
|
189
|
+
inactiveText = $[4];
|
|
190
|
+
loading = $[5];
|
|
191
|
+
onSelectUser = $[6];
|
|
192
|
+
props = $[7];
|
|
193
|
+
role = $[8];
|
|
194
|
+
t1 = $[9];
|
|
195
|
+
t2 = $[10];
|
|
196
|
+
t3 = $[11];
|
|
197
|
+
t4 = $[12];
|
|
198
|
+
t5 = $[13];
|
|
203
199
|
}
|
|
204
200
|
const variant = t1 === void 0 ? "default" : t1;
|
|
205
201
|
const size = t2 === void 0 ? "medium" : t2;
|
|
@@ -208,22 +204,22 @@ const UnwrappedItem = (t0, forwardedRef) => {
|
|
|
208
204
|
const active = t5 === void 0 ? false : t5;
|
|
209
205
|
const [partialSlots, childrenWithoutSlots] = useSlots(props.children, slotsConfig);
|
|
210
206
|
let t6;
|
|
211
|
-
if ($[
|
|
207
|
+
if ($[14] !== partialSlots) {
|
|
212
208
|
t6 = {
|
|
213
209
|
description: void 0,
|
|
214
210
|
...partialSlots
|
|
215
211
|
};
|
|
216
|
-
$[
|
|
217
|
-
$[
|
|
218
|
-
} else t6 = $[
|
|
212
|
+
$[14] = partialSlots;
|
|
213
|
+
$[15] = t6;
|
|
214
|
+
} else t6 = $[15];
|
|
219
215
|
const slots = t6;
|
|
220
216
|
const { container, afterSelect, selectionAttribute, defaultTrailingVisual } = React.useContext(ActionListContainerContext);
|
|
221
217
|
let t7;
|
|
222
|
-
if ($[
|
|
218
|
+
if ($[16] !== defaultTrailingVisual) {
|
|
223
219
|
t7 = defaultTrailingVisual ? /*#__PURE__*/ jsx(TrailingVisual, { children: defaultTrailingVisual }) : null;
|
|
224
|
-
$[
|
|
225
|
-
$[
|
|
226
|
-
} else t7 = $[
|
|
220
|
+
$[16] = defaultTrailingVisual;
|
|
221
|
+
$[17] = t7;
|
|
222
|
+
} else t7 = $[17];
|
|
227
223
|
const wrappedDefaultTrailingVisual = t7;
|
|
228
224
|
const trailingVisual = (_slots$trailingVisual = slots.trailingVisual) !== null && _slots$trailingVisual !== void 0 ? _slots$trailingVisual : wrappedDefaultTrailingVisual;
|
|
229
225
|
const { role: listRole, selectionVariant: listSelectionVariant } = React.useContext(ListContext);
|
|
@@ -231,23 +227,23 @@ const UnwrappedItem = (t0, forwardedRef) => {
|
|
|
231
227
|
const inactive = Boolean(inactiveText);
|
|
232
228
|
const menuContext = container === "ActionMenu" || container === "SelectPanel" || container === "FilteredActionList";
|
|
233
229
|
let t8;
|
|
234
|
-
if ($[
|
|
230
|
+
if ($[18] !== inactive || $[19] !== listRole) {
|
|
235
231
|
t8 = inactive && !(listRole !== void 0 && ["menu", "listbox"].includes(listRole));
|
|
236
|
-
$[
|
|
237
|
-
$[
|
|
238
|
-
$[
|
|
239
|
-
} else t8 = $[
|
|
232
|
+
$[18] = inactive;
|
|
233
|
+
$[19] = listRole;
|
|
234
|
+
$[20] = t8;
|
|
235
|
+
} else t8 = $[20];
|
|
240
236
|
const showInactiveIndicator = t8;
|
|
241
237
|
let t9;
|
|
242
|
-
if ($[
|
|
238
|
+
if ($[21] !== onSelectUser) {
|
|
243
239
|
t9 = (event, afterSelect_0) => {
|
|
244
240
|
if (typeof onSelectUser === "function") onSelectUser(event);
|
|
245
241
|
if (event.defaultPrevented) return;
|
|
246
242
|
if (typeof afterSelect_0 === "function") afterSelect_0(event);
|
|
247
243
|
};
|
|
248
|
-
$[
|
|
249
|
-
$[
|
|
250
|
-
} else t9 = $[
|
|
244
|
+
$[21] = onSelectUser;
|
|
245
|
+
$[22] = t9;
|
|
246
|
+
} else t9 = $[22];
|
|
251
247
|
const onSelect = t9;
|
|
252
248
|
const selectionVariant = groupSelectionVariant ? groupSelectionVariant : listSelectionVariant;
|
|
253
249
|
let inferredItemRole;
|
|
@@ -265,31 +261,31 @@ const UnwrappedItem = (t0, forwardedRef) => {
|
|
|
265
261
|
const itemSelectionAttribute = selectionAttribute || inferredSelectionAttribute;
|
|
266
262
|
const listItemSemantics = itemRole === "option" || itemRole === "menuitem" || itemRole === "menuitemradio" || itemRole === "menuitemcheckbox" || itemRole === "tab";
|
|
267
263
|
let t10;
|
|
268
|
-
if ($[
|
|
264
|
+
if ($[23] !== inactive || $[24] !== listItemSemantics || $[25] !== listRole) {
|
|
269
265
|
t10 = listRole && listRoleTypes.includes(listRole) || inactive || listItemSemantics;
|
|
270
|
-
$[
|
|
271
|
-
$[
|
|
272
|
-
$[
|
|
273
|
-
$[
|
|
274
|
-
} else t10 = $[
|
|
266
|
+
$[23] = inactive;
|
|
267
|
+
$[24] = listItemSemantics;
|
|
268
|
+
$[25] = listRole;
|
|
269
|
+
$[26] = t10;
|
|
270
|
+
} else t10 = $[26];
|
|
275
271
|
const listSemantics = t10;
|
|
276
272
|
const buttonSemantics = !listSemantics && !_PrivateItemWrapper;
|
|
277
273
|
let t11;
|
|
278
|
-
if ($[
|
|
274
|
+
if ($[27] !== afterSelect || $[28] !== disabled || $[29] !== inactive || $[30] !== loading || $[31] !== onSelect) {
|
|
279
275
|
t11 = (event_0) => {
|
|
280
276
|
if (disabled || inactive || loading) return;
|
|
281
277
|
onSelect(event_0, afterSelect);
|
|
282
278
|
};
|
|
283
|
-
$[
|
|
284
|
-
$[
|
|
285
|
-
$[
|
|
286
|
-
$[
|
|
287
|
-
$[
|
|
288
|
-
$[
|
|
289
|
-
} else t11 = $[
|
|
279
|
+
$[27] = afterSelect;
|
|
280
|
+
$[28] = disabled;
|
|
281
|
+
$[29] = inactive;
|
|
282
|
+
$[30] = loading;
|
|
283
|
+
$[31] = onSelect;
|
|
284
|
+
$[32] = t11;
|
|
285
|
+
} else t11 = $[32];
|
|
290
286
|
const clickHandler = t11;
|
|
291
287
|
let t12;
|
|
292
|
-
if ($[
|
|
288
|
+
if ($[33] !== afterSelect || $[34] !== disabled || $[35] !== inactive || $[36] !== loading || $[37] !== onSelect) {
|
|
293
289
|
t12 = (event_1) => {
|
|
294
290
|
if (disabled || inactive || loading) return;
|
|
295
291
|
if (event_1.key === " " || event_1.key === "Enter") {
|
|
@@ -300,13 +296,13 @@ const UnwrappedItem = (t0, forwardedRef) => {
|
|
|
300
296
|
onSelect(event_1, afterSelect);
|
|
301
297
|
}
|
|
302
298
|
};
|
|
303
|
-
$[
|
|
304
|
-
$[
|
|
305
|
-
$[
|
|
306
|
-
$[
|
|
307
|
-
$[
|
|
308
|
-
$[
|
|
309
|
-
} else t12 = $[
|
|
299
|
+
$[33] = afterSelect;
|
|
300
|
+
$[34] = disabled;
|
|
301
|
+
$[35] = inactive;
|
|
302
|
+
$[36] = loading;
|
|
303
|
+
$[37] = onSelect;
|
|
304
|
+
$[38] = t12;
|
|
305
|
+
} else t12 = $[38];
|
|
310
306
|
const keyPressHandler = t12;
|
|
311
307
|
const itemId = useId$1(id);
|
|
312
308
|
const labelId = `${itemId}--label`;
|
|
@@ -317,40 +313,40 @@ const UnwrappedItem = (t0, forwardedRef) => {
|
|
|
317
313
|
const [truncatedText, setTruncatedText] = React.useState(void 0);
|
|
318
314
|
const ItemWrapper = _PrivateItemWrapper || (listSemantics ? DivItemContainer : ButtonItemContainer);
|
|
319
315
|
let t13;
|
|
320
|
-
if ($[
|
|
316
|
+
if ($[39] !== itemRole || $[40] !== itemSelectionAttribute) {
|
|
321
317
|
t13 = itemSelectionAttribute && itemRole && selectableRoles.includes(itemRole);
|
|
322
|
-
$[
|
|
323
|
-
$[
|
|
324
|
-
$[
|
|
325
|
-
} else t13 = $[
|
|
318
|
+
$[39] = itemRole;
|
|
319
|
+
$[40] = itemSelectionAttribute;
|
|
320
|
+
$[41] = t13;
|
|
321
|
+
} else t13 = $[41];
|
|
326
322
|
const includeSelectionAttribute = t13;
|
|
327
323
|
const focusable = showInactiveIndicator ? true : void 0;
|
|
328
324
|
const descriptionVariant = (_slots$description$pr = (_slots$description = slots.description) === null || _slots$description === void 0 ? void 0 : _slots$description.props.variant) !== null && _slots$description$pr !== void 0 ? _slots$description$pr : "inline";
|
|
329
325
|
const hasTrailingVisualSlot = Boolean(slots.trailingVisual);
|
|
330
326
|
const hasDescriptionSlot = Boolean(slots.description);
|
|
331
327
|
let parts;
|
|
332
|
-
if ($[
|
|
328
|
+
if ($[42] !== hasTrailingVisualSlot || $[43] !== labelId || $[44] !== trailingVisualId) {
|
|
333
329
|
parts = [labelId];
|
|
334
330
|
if (hasTrailingVisualSlot) parts.push(trailingVisualId);
|
|
335
|
-
$[
|
|
336
|
-
$[
|
|
337
|
-
$[
|
|
338
|
-
$[
|
|
339
|
-
} else parts = $[
|
|
331
|
+
$[42] = hasTrailingVisualSlot;
|
|
332
|
+
$[43] = labelId;
|
|
333
|
+
$[44] = trailingVisualId;
|
|
334
|
+
$[45] = parts;
|
|
335
|
+
} else parts = $[45];
|
|
340
336
|
const ariaLabelledBy = parts.join(" ");
|
|
341
337
|
let parts_0;
|
|
342
|
-
if ($[
|
|
338
|
+
if ($[46] !== blockDescriptionId || $[47] !== descriptionVariant || $[48] !== hasDescriptionSlot || $[49] !== inactiveWarningId || $[50] !== inlineDescriptionId) {
|
|
343
339
|
parts_0 = [];
|
|
344
340
|
if (hasDescriptionSlot && descriptionVariant === "block") parts_0.push(blockDescriptionId);
|
|
345
341
|
if (hasDescriptionSlot && descriptionVariant === "inline") parts_0.push(inlineDescriptionId);
|
|
346
342
|
if (inactiveWarningId) parts_0.push(inactiveWarningId);
|
|
347
|
-
$[
|
|
348
|
-
$[
|
|
349
|
-
$[
|
|
350
|
-
$[
|
|
351
|
-
$[
|
|
352
|
-
$[
|
|
353
|
-
} else parts_0 = $[
|
|
343
|
+
$[46] = blockDescriptionId;
|
|
344
|
+
$[47] = descriptionVariant;
|
|
345
|
+
$[48] = hasDescriptionSlot;
|
|
346
|
+
$[49] = inactiveWarningId;
|
|
347
|
+
$[50] = inlineDescriptionId;
|
|
348
|
+
$[51] = parts_0;
|
|
349
|
+
} else parts_0 = $[51];
|
|
354
350
|
const ariaDescribedBy = parts_0.length > 0 ? parts_0.join(" ") : void 0;
|
|
355
351
|
const t14 = !buttonSemantics ? keyPressHandler : void 0;
|
|
356
352
|
const t15 = disabled ? true : void 0;
|
|
@@ -358,15 +354,15 @@ const UnwrappedItem = (t0, forwardedRef) => {
|
|
|
358
354
|
const t17 = loading && !inactive ? true : void 0;
|
|
359
355
|
const t18 = focusable ? void 0 : 0;
|
|
360
356
|
let t19;
|
|
361
|
-
if ($[
|
|
357
|
+
if ($[52] !== includeSelectionAttribute || $[53] !== itemSelectionAttribute || $[54] !== selected) {
|
|
362
358
|
t19 = includeSelectionAttribute && { [itemSelectionAttribute]: selected };
|
|
363
|
-
$[
|
|
364
|
-
$[
|
|
365
|
-
$[
|
|
366
|
-
$[
|
|
367
|
-
} else t19 = $[
|
|
359
|
+
$[52] = includeSelectionAttribute;
|
|
360
|
+
$[53] = itemSelectionAttribute;
|
|
361
|
+
$[54] = selected;
|
|
362
|
+
$[55] = t19;
|
|
363
|
+
} else t19 = $[55];
|
|
368
364
|
let t20;
|
|
369
|
-
if ($[
|
|
365
|
+
if ($[56] !== ariaDescribedBy || $[57] !== ariaLabelledBy || $[58] !== clickHandler || $[59] !== itemId || $[60] !== itemRole || $[61] !== t14 || $[62] !== t15 || $[63] !== t16 || $[64] !== t17 || $[65] !== t18 || $[66] !== t19) {
|
|
370
366
|
t20 = {
|
|
371
367
|
onClick: clickHandler,
|
|
372
368
|
onKeyPress: t14,
|
|
@@ -380,22 +376,22 @@ const UnwrappedItem = (t0, forwardedRef) => {
|
|
|
380
376
|
role: itemRole,
|
|
381
377
|
id: itemId
|
|
382
378
|
};
|
|
383
|
-
$[
|
|
384
|
-
$[
|
|
385
|
-
$[
|
|
386
|
-
$[
|
|
387
|
-
$[
|
|
388
|
-
$[
|
|
389
|
-
$[
|
|
390
|
-
$[
|
|
391
|
-
$[
|
|
392
|
-
$[
|
|
393
|
-
$[
|
|
394
|
-
$[
|
|
395
|
-
} else t20 = $[
|
|
379
|
+
$[56] = ariaDescribedBy;
|
|
380
|
+
$[57] = ariaLabelledBy;
|
|
381
|
+
$[58] = clickHandler;
|
|
382
|
+
$[59] = itemId;
|
|
383
|
+
$[60] = itemRole;
|
|
384
|
+
$[61] = t14;
|
|
385
|
+
$[62] = t15;
|
|
386
|
+
$[63] = t16;
|
|
387
|
+
$[64] = t17;
|
|
388
|
+
$[65] = t18;
|
|
389
|
+
$[66] = t19;
|
|
390
|
+
$[67] = t20;
|
|
391
|
+
} else t20 = $[67];
|
|
396
392
|
const menuItemProps = t20;
|
|
397
393
|
let t21;
|
|
398
|
-
if ($[
|
|
394
|
+
if ($[68] !== _PrivateItemWrapper || $[69] !== forwardedRef || $[70] !== itemRole || $[71] !== listSemantics || $[72] !== menuItemProps || $[73] !== props) {
|
|
399
395
|
t21 = _PrivateItemWrapper ? {
|
|
400
396
|
role: itemRole ? "none" : void 0,
|
|
401
397
|
...props
|
|
@@ -404,34 +400,34 @@ const UnwrappedItem = (t0, forwardedRef) => {
|
|
|
404
400
|
...props,
|
|
405
401
|
ref: forwardedRef
|
|
406
402
|
} || {};
|
|
407
|
-
$[
|
|
408
|
-
$[
|
|
409
|
-
$[
|
|
410
|
-
$[
|
|
411
|
-
$[
|
|
412
|
-
$[
|
|
413
|
-
$[
|
|
414
|
-
} else t21 = $[
|
|
403
|
+
$[68] = _PrivateItemWrapper;
|
|
404
|
+
$[69] = forwardedRef;
|
|
405
|
+
$[70] = itemRole;
|
|
406
|
+
$[71] = listSemantics;
|
|
407
|
+
$[72] = menuItemProps;
|
|
408
|
+
$[73] = props;
|
|
409
|
+
$[74] = t21;
|
|
410
|
+
} else t21 = $[74];
|
|
415
411
|
const containerProps = t21;
|
|
416
412
|
let t22;
|
|
417
|
-
if ($[
|
|
413
|
+
if ($[75] !== _PrivateItemWrapper || $[76] !== forwardedRef || $[77] !== listSemantics || $[78] !== menuItemProps || $[79] !== props) {
|
|
418
414
|
t22 = _PrivateItemWrapper ? menuItemProps : !listSemantics && {
|
|
419
415
|
...menuItemProps,
|
|
420
416
|
...props,
|
|
421
417
|
ref: forwardedRef
|
|
422
418
|
};
|
|
423
|
-
$[
|
|
424
|
-
$[
|
|
425
|
-
$[
|
|
426
|
-
$[
|
|
427
|
-
$[
|
|
428
|
-
$[
|
|
429
|
-
} else t22 = $[
|
|
419
|
+
$[75] = _PrivateItemWrapper;
|
|
420
|
+
$[76] = forwardedRef;
|
|
421
|
+
$[77] = listSemantics;
|
|
422
|
+
$[78] = menuItemProps;
|
|
423
|
+
$[79] = props;
|
|
424
|
+
$[80] = t22;
|
|
425
|
+
} else t22 = $[80];
|
|
430
426
|
const wrapperProps = t22;
|
|
431
427
|
const t23 = Boolean(inactiveText);
|
|
432
428
|
const t24 = buttonSemantics ? setTruncatedText : void 0;
|
|
433
429
|
let t25;
|
|
434
|
-
if ($[
|
|
430
|
+
if ($[81] !== blockDescriptionId || $[82] !== disabled || $[83] !== inlineDescriptionId || $[84] !== size || $[85] !== t23 || $[86] !== t24 || $[87] !== trailingVisualId || $[88] !== variant) {
|
|
435
431
|
t25 = {
|
|
436
432
|
variant,
|
|
437
433
|
size,
|
|
@@ -442,16 +438,16 @@ const UnwrappedItem = (t0, forwardedRef) => {
|
|
|
442
438
|
trailingVisualId,
|
|
443
439
|
setTruncatedText: t24
|
|
444
440
|
};
|
|
445
|
-
$[
|
|
446
|
-
$[
|
|
447
|
-
$[
|
|
448
|
-
$[
|
|
449
|
-
$[
|
|
450
|
-
$[
|
|
451
|
-
$[
|
|
452
|
-
$[
|
|
453
|
-
$[
|
|
454
|
-
} else t25 = $[
|
|
441
|
+
$[81] = blockDescriptionId;
|
|
442
|
+
$[82] = disabled;
|
|
443
|
+
$[83] = inlineDescriptionId;
|
|
444
|
+
$[84] = size;
|
|
445
|
+
$[85] = t23;
|
|
446
|
+
$[86] = t24;
|
|
447
|
+
$[87] = trailingVisualId;
|
|
448
|
+
$[88] = variant;
|
|
449
|
+
$[89] = t25;
|
|
450
|
+
} else t25 = $[89];
|
|
455
451
|
const itemContextValue = t25;
|
|
456
452
|
const trailingActionRendered = !inactive && !loading && !menuContext && Boolean(slots.trailingAction);
|
|
457
453
|
const t26 = listSemantics ? forwardedRef : null;
|
|
@@ -464,183 +460,182 @@ const UnwrappedItem = (t0, forwardedRef) => {
|
|
|
464
460
|
const t33 = trailingActionRendered ? true : void 0;
|
|
465
461
|
const t34 = trailingActionRendered && (_slots$trailingAction = slots.trailingAction) !== null && _slots$trailingAction !== void 0 && _slots$trailingAction.props.loading ? true : void 0;
|
|
466
462
|
let t35;
|
|
467
|
-
if ($[
|
|
463
|
+
if ($[90] !== className) {
|
|
468
464
|
t35 = clsx(ActionList_module_css_default.ActionListItem, className);
|
|
469
|
-
$[
|
|
470
|
-
$[
|
|
471
|
-
} else t35 = $[
|
|
472
|
-
|
|
465
|
+
$[90] = className;
|
|
466
|
+
$[91] = t35;
|
|
467
|
+
} else t35 = $[91];
|
|
468
|
+
let t36;
|
|
473
469
|
let t37;
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
t37 = {};
|
|
477
|
-
|
|
470
|
+
if ($[92] === Symbol.for("react.memo_cache_sentinel")) {
|
|
471
|
+
t36 = {};
|
|
472
|
+
t37 = /*#__PURE__*/ jsx("span", { className: ActionList_module_css_default.Spacer });
|
|
473
|
+
$[92] = t36;
|
|
478
474
|
$[93] = t37;
|
|
479
|
-
$[94] = t38;
|
|
480
475
|
} else {
|
|
476
|
+
t36 = $[92];
|
|
481
477
|
t37 = $[93];
|
|
482
|
-
t38 = $[94];
|
|
483
478
|
}
|
|
484
|
-
let
|
|
485
|
-
if ($[
|
|
486
|
-
|
|
479
|
+
let t38;
|
|
480
|
+
if ($[94] !== selected) {
|
|
481
|
+
t38 = /*#__PURE__*/ jsx(Selection, {
|
|
487
482
|
selected,
|
|
488
483
|
className: ActionList_module_css_default.LeadingAction
|
|
489
484
|
});
|
|
490
|
-
$[
|
|
491
|
-
$[
|
|
492
|
-
} else
|
|
493
|
-
const
|
|
494
|
-
const
|
|
495
|
-
let
|
|
496
|
-
if ($[
|
|
497
|
-
|
|
498
|
-
inactiveText:
|
|
499
|
-
itemHasLeadingVisual:
|
|
485
|
+
$[94] = selected;
|
|
486
|
+
$[95] = t38;
|
|
487
|
+
} else t38 = $[95];
|
|
488
|
+
const t39 = showInactiveIndicator ? inactiveText : void 0;
|
|
489
|
+
const t40 = Boolean(slots.leadingVisual);
|
|
490
|
+
let t41;
|
|
491
|
+
if ($[96] !== labelId || $[97] !== loading || $[98] !== slots.leadingVisual || $[99] !== t39 || $[100] !== t40) {
|
|
492
|
+
t41 = /*#__PURE__*/ jsx(VisualOrIndicator, {
|
|
493
|
+
inactiveText: t39,
|
|
494
|
+
itemHasLeadingVisual: t40,
|
|
500
495
|
labelId,
|
|
501
496
|
loading,
|
|
502
497
|
position: "leading",
|
|
503
498
|
children: slots.leadingVisual
|
|
504
499
|
});
|
|
505
|
-
$[
|
|
506
|
-
$[
|
|
507
|
-
$[
|
|
500
|
+
$[96] = labelId;
|
|
501
|
+
$[97] = loading;
|
|
502
|
+
$[98] = slots.leadingVisual;
|
|
503
|
+
$[99] = t39;
|
|
508
504
|
$[100] = t40;
|
|
509
505
|
$[101] = t41;
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
506
|
+
} else t41 = $[101];
|
|
507
|
+
const t42 = !!slots.description;
|
|
508
|
+
let t43;
|
|
509
|
+
if ($[102] !== inactive || $[103] !== loading) {
|
|
510
|
+
t43 = loading === true && !inactive && /*#__PURE__*/ jsx(VisuallyHidden, { children: "Loading" });
|
|
511
|
+
$[102] = inactive;
|
|
512
|
+
$[103] = loading;
|
|
513
|
+
$[104] = t43;
|
|
514
|
+
} else t43 = $[104];
|
|
513
515
|
let t44;
|
|
514
|
-
if ($[
|
|
515
|
-
t44 =
|
|
516
|
-
$[103] = inactive;
|
|
517
|
-
$[104] = loading;
|
|
518
|
-
$[105] = t44;
|
|
519
|
-
} else t44 = $[105];
|
|
520
|
-
let t45;
|
|
521
|
-
if ($[106] !== childrenWithoutSlots || $[107] !== labelId || $[108] !== t44) {
|
|
522
|
-
t45 = /*#__PURE__*/ jsxs("span", {
|
|
516
|
+
if ($[105] !== childrenWithoutSlots || $[106] !== labelId || $[107] !== t43) {
|
|
517
|
+
t44 = /*#__PURE__*/ jsxs("span", {
|
|
523
518
|
id: labelId,
|
|
524
519
|
className: ActionList_module_css_default.ItemLabel,
|
|
525
520
|
"data-component": "ActionList.Item.Label",
|
|
526
|
-
children: [childrenWithoutSlots,
|
|
521
|
+
children: [childrenWithoutSlots, t43]
|
|
527
522
|
});
|
|
528
|
-
$[
|
|
529
|
-
$[
|
|
523
|
+
$[105] = childrenWithoutSlots;
|
|
524
|
+
$[106] = labelId;
|
|
525
|
+
$[107] = t43;
|
|
530
526
|
$[108] = t44;
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
if: t43,
|
|
527
|
+
} else t44 = $[108];
|
|
528
|
+
let t45;
|
|
529
|
+
if ($[109] !== descriptionVariant || $[110] !== slots.description || $[111] !== t42 || $[112] !== t44) {
|
|
530
|
+
t45 = /*#__PURE__*/ jsxs(ConditionalWrapper, {
|
|
531
|
+
if: t42,
|
|
537
532
|
className: ActionList_module_css_default.ItemDescriptionWrap,
|
|
538
533
|
"data-description-variant": descriptionVariant,
|
|
539
|
-
children: [
|
|
534
|
+
children: [t44, slots.description]
|
|
540
535
|
});
|
|
541
|
-
$[
|
|
542
|
-
$[
|
|
543
|
-
$[
|
|
536
|
+
$[109] = descriptionVariant;
|
|
537
|
+
$[110] = slots.description;
|
|
538
|
+
$[111] = t42;
|
|
539
|
+
$[112] = t44;
|
|
544
540
|
$[113] = t45;
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
const t47 =
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
itemHasLeadingVisual: t48,
|
|
541
|
+
} else t45 = $[113];
|
|
542
|
+
const t46 = showInactiveIndicator ? inactiveText : void 0;
|
|
543
|
+
const t47 = Boolean(slots.leadingVisual);
|
|
544
|
+
let t48;
|
|
545
|
+
if ($[114] !== labelId || $[115] !== loading || $[116] !== t46 || $[117] !== t47 || $[118] !== trailingVisual) {
|
|
546
|
+
t48 = /*#__PURE__*/ jsx(VisualOrIndicator, {
|
|
547
|
+
inactiveText: t46,
|
|
548
|
+
itemHasLeadingVisual: t47,
|
|
554
549
|
labelId,
|
|
555
550
|
loading,
|
|
556
551
|
position: "trailing",
|
|
557
552
|
children: trailingVisual
|
|
558
553
|
});
|
|
559
|
-
$[
|
|
560
|
-
$[
|
|
554
|
+
$[114] = labelId;
|
|
555
|
+
$[115] = loading;
|
|
556
|
+
$[116] = t46;
|
|
561
557
|
$[117] = t47;
|
|
562
|
-
$[118] =
|
|
563
|
-
$[119] =
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
t50 = !showInactiveIndicator && inactiveText ? /*#__PURE__*/ jsx("span", {
|
|
558
|
+
$[118] = trailingVisual;
|
|
559
|
+
$[119] = t48;
|
|
560
|
+
} else t48 = $[119];
|
|
561
|
+
let t49;
|
|
562
|
+
if ($[120] !== inactiveText || $[121] !== inactiveWarningId || $[122] !== showInactiveIndicator) {
|
|
563
|
+
t49 = !showInactiveIndicator && inactiveText ? /*#__PURE__*/ jsx("span", {
|
|
569
564
|
className: ActionList_module_css_default.InactiveWarning,
|
|
570
565
|
id: inactiveWarningId,
|
|
571
566
|
children: inactiveText
|
|
572
567
|
}) : null;
|
|
573
|
-
$[
|
|
574
|
-
$[
|
|
575
|
-
$[
|
|
576
|
-
$[
|
|
577
|
-
} else
|
|
578
|
-
let
|
|
579
|
-
if ($[
|
|
580
|
-
|
|
568
|
+
$[120] = inactiveText;
|
|
569
|
+
$[121] = inactiveWarningId;
|
|
570
|
+
$[122] = showInactiveIndicator;
|
|
571
|
+
$[123] = t49;
|
|
572
|
+
} else t49 = $[123];
|
|
573
|
+
let t50;
|
|
574
|
+
if ($[124] !== t45 || $[125] !== t48 || $[126] !== t49) {
|
|
575
|
+
t50 = /*#__PURE__*/ jsxs("span", {
|
|
581
576
|
className: ActionList_module_css_default.ActionListSubContent,
|
|
582
577
|
"data-component": "ActionList.Item--DividerContainer",
|
|
583
578
|
children: [
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
579
|
+
t45,
|
|
580
|
+
t48,
|
|
581
|
+
t49
|
|
587
582
|
]
|
|
588
583
|
});
|
|
589
|
-
$[
|
|
584
|
+
$[124] = t45;
|
|
585
|
+
$[125] = t48;
|
|
590
586
|
$[126] = t49;
|
|
591
587
|
$[127] = t50;
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
value: t37,
|
|
588
|
+
} else t50 = $[127];
|
|
589
|
+
let t51;
|
|
590
|
+
if ($[128] !== t38 || $[129] !== t41 || $[130] !== t50) {
|
|
591
|
+
t51 = /*#__PURE__*/ jsxs(TooltipContext.Provider, {
|
|
592
|
+
value: t36,
|
|
598
593
|
children: [
|
|
594
|
+
t37,
|
|
599
595
|
t38,
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
t51
|
|
596
|
+
t41,
|
|
597
|
+
t50
|
|
603
598
|
]
|
|
604
599
|
});
|
|
605
|
-
$[
|
|
606
|
-
$[
|
|
600
|
+
$[128] = t38;
|
|
601
|
+
$[129] = t41;
|
|
602
|
+
$[130] = t50;
|
|
607
603
|
$[131] = t51;
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
t53 = /*#__PURE__*/ jsx(ItemWrapper, {
|
|
604
|
+
} else t51 = $[131];
|
|
605
|
+
let t52;
|
|
606
|
+
if ($[132] !== ItemWrapper || $[133] !== forwardedRef || $[134] !== size || $[135] !== t51 || $[136] !== wrapperProps) {
|
|
607
|
+
t52 = /*#__PURE__*/ jsx(ItemWrapper, {
|
|
613
608
|
...wrapperProps,
|
|
614
609
|
className: ActionList_module_css_default.ActionListContent,
|
|
615
610
|
"data-size": size,
|
|
616
611
|
ref: forwardedRef,
|
|
617
|
-
children:
|
|
612
|
+
children: t51
|
|
618
613
|
});
|
|
619
|
-
$[
|
|
620
|
-
$[
|
|
621
|
-
$[
|
|
622
|
-
$[
|
|
623
|
-
$[
|
|
624
|
-
$[
|
|
625
|
-
} else
|
|
626
|
-
let
|
|
627
|
-
if ($[
|
|
628
|
-
|
|
614
|
+
$[132] = ItemWrapper;
|
|
615
|
+
$[133] = forwardedRef;
|
|
616
|
+
$[134] = size;
|
|
617
|
+
$[135] = t51;
|
|
618
|
+
$[136] = wrapperProps;
|
|
619
|
+
$[137] = t52;
|
|
620
|
+
} else t52 = $[137];
|
|
621
|
+
let t53;
|
|
622
|
+
if ($[138] !== buttonSemantics || $[139] !== forwardedRef || $[140] !== t52 || $[141] !== truncatedText) {
|
|
623
|
+
t53 = /*#__PURE__*/ jsx(ConditionalTooltip, {
|
|
629
624
|
ref: forwardedRef,
|
|
630
|
-
text:
|
|
625
|
+
text: truncatedText,
|
|
631
626
|
enabled: buttonSemantics,
|
|
632
|
-
children:
|
|
627
|
+
children: t52
|
|
633
628
|
});
|
|
634
|
-
$[
|
|
635
|
-
$[
|
|
636
|
-
$[
|
|
629
|
+
$[138] = buttonSemantics;
|
|
630
|
+
$[139] = forwardedRef;
|
|
631
|
+
$[140] = t52;
|
|
632
|
+
$[141] = truncatedText;
|
|
637
633
|
$[142] = t53;
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
t56 = /*#__PURE__*/ jsxs("li", {
|
|
634
|
+
} else t53 = $[142];
|
|
635
|
+
const t54 = !inactive && !loading && !menuContext && Boolean(slots.trailingAction) && slots.trailingAction;
|
|
636
|
+
let t55;
|
|
637
|
+
if ($[143] !== containerProps || $[144] !== slots.subItem || $[145] !== t26 || $[146] !== t27 || $[147] !== t28 || $[148] !== t29 || $[149] !== t30 || $[150] !== t31 || $[151] !== t32 || $[152] !== t33 || $[153] !== t34 || $[154] !== t35 || $[155] !== t53 || $[156] !== t54) {
|
|
638
|
+
t55 = /*#__PURE__*/ jsxs("li", {
|
|
644
639
|
...containerProps,
|
|
645
640
|
ref: t26,
|
|
646
641
|
"data-component": "ActionList.Item",
|
|
@@ -654,38 +649,38 @@ const UnwrappedItem = (t0, forwardedRef) => {
|
|
|
654
649
|
"data-trailing-action-loading": t34,
|
|
655
650
|
className: t35,
|
|
656
651
|
children: [
|
|
652
|
+
t53,
|
|
657
653
|
t54,
|
|
658
|
-
t55,
|
|
659
654
|
slots.subItem
|
|
660
655
|
]
|
|
661
656
|
});
|
|
662
|
-
$[
|
|
663
|
-
$[
|
|
664
|
-
$[
|
|
665
|
-
$[
|
|
666
|
-
$[
|
|
667
|
-
$[
|
|
668
|
-
$[
|
|
669
|
-
$[
|
|
670
|
-
$[
|
|
671
|
-
$[
|
|
672
|
-
$[
|
|
673
|
-
$[
|
|
657
|
+
$[143] = containerProps;
|
|
658
|
+
$[144] = slots.subItem;
|
|
659
|
+
$[145] = t26;
|
|
660
|
+
$[146] = t27;
|
|
661
|
+
$[147] = t28;
|
|
662
|
+
$[148] = t29;
|
|
663
|
+
$[149] = t30;
|
|
664
|
+
$[150] = t31;
|
|
665
|
+
$[151] = t32;
|
|
666
|
+
$[152] = t33;
|
|
667
|
+
$[153] = t34;
|
|
668
|
+
$[154] = t35;
|
|
669
|
+
$[155] = t53;
|
|
674
670
|
$[156] = t54;
|
|
675
671
|
$[157] = t55;
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
t57 = /*#__PURE__*/ jsx(ItemContext.Provider, {
|
|
672
|
+
} else t55 = $[157];
|
|
673
|
+
let t56;
|
|
674
|
+
if ($[158] !== itemContextValue || $[159] !== t55) {
|
|
675
|
+
t56 = /*#__PURE__*/ jsx(ItemContext.Provider, {
|
|
681
676
|
value: itemContextValue,
|
|
682
|
-
children:
|
|
677
|
+
children: t55
|
|
683
678
|
});
|
|
684
|
-
$[
|
|
679
|
+
$[158] = itemContextValue;
|
|
680
|
+
$[159] = t55;
|
|
685
681
|
$[160] = t56;
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
return t57;
|
|
682
|
+
} else t56 = $[160];
|
|
683
|
+
return t56;
|
|
689
684
|
};
|
|
690
685
|
const Item = Object.assign(fixedForwardRef(UnwrappedItem), {
|
|
691
686
|
displayName: "ActionList.Item",
|