@primer/react 0.0.0-20260223214708 → 0.0.0-20260223221323
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 +2 -38
- package/dist/ActionBar/ActionBar.d.ts.map +1 -1
- package/dist/ActionBar/ActionBar.js +302 -396
- package/dist/ActionList/ActionList-f4ac3b54.css +2 -0
- package/dist/ActionList/ActionList-f4ac3b54.css.map +1 -0
- package/dist/ActionList/ActionList.module.css.js +1 -1
- package/dist/ActionList/Item.d.ts.map +1 -1
- package/dist/ActionList/Item.js +0 -1
- package/dist/Autocomplete/Autocomplete.js +159 -76
- package/dist/Autocomplete/AutocompleteMenu.js +333 -128
- package/dist/Autocomplete/AutocompleteOverlay.js +130 -49
- package/dist/Banner/Banner.js +238 -64
- package/dist/Blankslate/{Blankslate-a039d79a.css → Blankslate-f5a9755a.css} +2 -2
- package/dist/Blankslate/Blankslate-f5a9755a.css.map +1 -0
- package/dist/Blankslate/Blankslate.module.css.js +1 -1
- package/dist/Button/ButtonBase.d.ts.map +1 -1
- package/dist/Button/ButtonBase.js +14 -9
- package/dist/Checkbox/Checkbox.js +163 -55
- package/dist/Dialog/Dialog.js +347 -105
- package/dist/FilteredActionList/FilteredActionList-f6c2dc7a.css +2 -0
- package/dist/FilteredActionList/FilteredActionList-f6c2dc7a.css.map +1 -0
- package/dist/FilteredActionList/FilteredActionList.d.ts +1 -16
- package/dist/FilteredActionList/FilteredActionList.d.ts.map +1 -1
- package/dist/FilteredActionList/FilteredActionList.js +42 -147
- package/dist/FilteredActionList/FilteredActionList.module.css.js +2 -2
- package/dist/Overlay/Overlay-43cda449.css +2 -0
- package/dist/Overlay/Overlay-43cda449.css.map +1 -0
- package/dist/Overlay/Overlay.module.css.js +1 -1
- package/dist/PageLayout/PageLayout-cb491b47.css +2 -0
- package/dist/PageLayout/PageLayout-cb491b47.css.map +1 -0
- package/dist/PageLayout/PageLayout.d.ts +2 -72
- package/dist/PageLayout/PageLayout.d.ts.map +1 -1
- package/dist/PageLayout/PageLayout.js +1235 -750
- package/dist/PageLayout/PageLayout.module.css.js +2 -2
- package/dist/PageLayout/usePaneWidth.d.ts +6 -18
- package/dist/PageLayout/usePaneWidth.d.ts.map +1 -1
- package/dist/PageLayout/usePaneWidth.js +112 -126
- package/dist/SelectPanel/SelectPanel.d.ts +1 -1
- package/dist/SelectPanel/SelectPanel.d.ts.map +1 -1
- package/dist/SelectPanel/SelectPanel.js +33 -85
- package/dist/SplitPageLayout/SplitPageLayout.d.ts +1 -4
- package/dist/SplitPageLayout/SplitPageLayout.d.ts.map +1 -1
- package/dist/SplitPageLayout/SplitPageLayout.js +2 -54
- package/dist/Text/Text.d.ts +1 -1
- package/dist/Text/Text.d.ts.map +1 -1
- package/dist/Text/Text.js +13 -10
- package/dist/UnderlineNav/UnderlineNavItem.js +149 -56
- package/dist/experimental/SelectPanel2/SelectPanel-1f8c23b5.css +2 -0
- package/dist/experimental/SelectPanel2/{SelectPanel-f0c4b9ca.css.map → SelectPanel-1f8c23b5.css.map} +1 -1
- package/dist/experimental/SelectPanel2/SelectPanel.js +593 -209
- package/dist/experimental/SelectPanel2/SelectPanel.module.css.js +1 -1
- package/dist/hooks/useRefObjectAsForwardedRef.d.ts.map +1 -1
- package/dist/hooks/useRefObjectAsForwardedRef.js +2 -10
- package/dist/hooks/useScrollFlash.d.ts.map +1 -1
- package/dist/hooks/useScrollFlash.js +22 -14
- package/dist/hooks/useSlots.d.ts +6 -50
- package/dist/hooks/useSlots.d.ts.map +1 -1
- package/dist/hooks/useSlots.js +36 -114
- package/dist/live-region/Announce.d.ts.map +1 -1
- package/dist/live-region/Announce.js +4 -7
- package/dist/utils/descendant-registry.d.ts +29 -0
- package/dist/utils/descendant-registry.d.ts.map +1 -0
- package/dist/utils/descendant-registry.js +188 -0
- package/generated/components.json +5 -197
- package/package.json +4 -4
- package/dist/ActionList/ActionList-c04a02d6.css +0 -2
- package/dist/ActionList/ActionList-c04a02d6.css.map +0 -1
- package/dist/Blankslate/Blankslate-a039d79a.css.map +0 -1
- package/dist/FilteredActionList/FilteredActionList-02db90c6.css +0 -2
- package/dist/FilteredActionList/FilteredActionList-02db90c6.css.map +0 -1
- package/dist/Overlay/Overlay-15519c09.css +0 -2
- package/dist/Overlay/Overlay-15519c09.css.map +0 -1
- package/dist/PageLayout/PageLayout-3444a142.css +0 -2
- package/dist/PageLayout/PageLayout-3444a142.css.map +0 -1
- package/dist/experimental/SelectPanel2/SelectPanel-f0c4b9ca.css +0 -2
- package/dist/utils/environment.js +0 -9
|
@@ -108,7 +108,6 @@ function Panel({
|
|
|
108
108
|
align,
|
|
109
109
|
showSelectAll = false,
|
|
110
110
|
focusPrependedElements,
|
|
111
|
-
virtualized,
|
|
112
111
|
...listProps
|
|
113
112
|
}) {
|
|
114
113
|
var _listProps$groupMetad;
|
|
@@ -133,6 +132,8 @@ function Panel({
|
|
|
133
132
|
wide: false
|
|
134
133
|
}, false);
|
|
135
134
|
const [selectedOnSort, setSelectedOnSort] = useState([]);
|
|
135
|
+
const [prevItems, setPrevItems] = useState([]);
|
|
136
|
+
const [prevOpen, setPrevOpen] = useState(open);
|
|
136
137
|
const initialHeightRef = useRef(0);
|
|
137
138
|
const initialScaleRef = useRef(1);
|
|
138
139
|
const noticeRef = useRef(null);
|
|
@@ -204,19 +205,6 @@ function Panel({
|
|
|
204
205
|
resetSort();
|
|
205
206
|
}
|
|
206
207
|
}, [loadingManagedInternally, externalOnFilterChange, setInternalFilterValue, dataLoadedOnce, safeSetTimeout, safeClearTimeout, items.length, resetSort]);
|
|
207
|
-
|
|
208
|
-
// Pre-compute a Set of item IDs in the current filtered view for O(1) lookups
|
|
209
|
-
const itemsInViewSet = useMemo(() => {
|
|
210
|
-
const set = new Set();
|
|
211
|
-
for (const item of items) {
|
|
212
|
-
if (item.id !== undefined) {
|
|
213
|
-
set.add(item.id);
|
|
214
|
-
} else {
|
|
215
|
-
set.add(item);
|
|
216
|
-
}
|
|
217
|
-
}
|
|
218
|
-
return set;
|
|
219
|
-
}, [items]);
|
|
220
208
|
const handleSelectAllChange = useCallback(checked => {
|
|
221
209
|
// Exit early if not in multi-select mode
|
|
222
210
|
if (!isMultiSelectVariant(selected)) {
|
|
@@ -224,20 +212,13 @@ function Panel({
|
|
|
224
212
|
}
|
|
225
213
|
const multiSelectOnChange = onSelectedChange;
|
|
226
214
|
const selectedArray = selected;
|
|
227
|
-
|
|
228
|
-
// Use Set for O(1) lookup instead of O(n) items.some()
|
|
229
|
-
const selectedItemsNotInFilteredView = selectedArray.filter(selectedItem => {
|
|
230
|
-
if (selectedItem.id !== undefined) {
|
|
231
|
-
return !itemsInViewSet.has(selectedItem.id);
|
|
232
|
-
}
|
|
233
|
-
return !itemsInViewSet.has(selectedItem);
|
|
234
|
-
});
|
|
215
|
+
const selectedItemsNotInFilteredView = selectedArray.filter(selectedItem => !items.some(item => areItemsEqual(item, selectedItem)));
|
|
235
216
|
if (checked) {
|
|
236
217
|
multiSelectOnChange([...selectedItemsNotInFilteredView, ...items]);
|
|
237
218
|
} else {
|
|
238
219
|
multiSelectOnChange(selectedItemsNotInFilteredView);
|
|
239
220
|
}
|
|
240
|
-
}, [items,
|
|
221
|
+
}, [items, onSelectedChange, selected]);
|
|
241
222
|
|
|
242
223
|
// disable body scroll when the panel is open on narrow screens
|
|
243
224
|
useEffect(() => {
|
|
@@ -403,29 +384,10 @@ function Panel({
|
|
|
403
384
|
});
|
|
404
385
|
};
|
|
405
386
|
}, [placeholder, renderAnchor, selected]);
|
|
406
|
-
|
|
407
|
-
// Pre-compute a Set of selected item IDs/references for O(1) lookups
|
|
408
|
-
// This optimizes isItemCurrentlySelected from O(m) to O(1) per call
|
|
409
|
-
const selectedItemsSet = useMemo(() => {
|
|
410
|
-
const set = new Set();
|
|
411
|
-
if (isMultiSelectVariant(selected)) {
|
|
412
|
-
for (const item of selected) {
|
|
413
|
-
if (item.id !== undefined) {
|
|
414
|
-
set.add(item.id);
|
|
415
|
-
} else {
|
|
416
|
-
set.add(item);
|
|
417
|
-
}
|
|
418
|
-
}
|
|
419
|
-
}
|
|
420
|
-
return set;
|
|
421
|
-
}, [selected]);
|
|
422
387
|
const isItemCurrentlySelected = useCallback(item => {
|
|
423
|
-
// For multi-select,
|
|
388
|
+
// For multi-select, we just need to check if the item is in the selected array
|
|
424
389
|
if (isMultiSelectVariant(selected)) {
|
|
425
|
-
|
|
426
|
-
return selectedItemsSet.has(item.id);
|
|
427
|
-
}
|
|
428
|
-
return selectedItemsSet.has(item);
|
|
390
|
+
return doesItemsIncludeItem(selected, item);
|
|
429
391
|
}
|
|
430
392
|
|
|
431
393
|
// For single-select modal, there is an intermediate state when the user has selected
|
|
@@ -436,24 +398,8 @@ function Panel({
|
|
|
436
398
|
|
|
437
399
|
// For single-select anchored, we just need to check if the item is the selected item
|
|
438
400
|
return (selected === null || selected === void 0 ? void 0 : selected.id) !== undefined ? selected.id === item.id : selected === item;
|
|
439
|
-
}, [selected,
|
|
401
|
+
}, [selected, intermediateSelected, isSingleSelectModal]);
|
|
440
402
|
const itemsToRender = useMemo(() => {
|
|
441
|
-
// Pre-compute a Set of selected item IDs/references for O(1) lookups during sorting
|
|
442
|
-
// This avoids O(m * k) work per comparison in the sort function
|
|
443
|
-
const selectedOnSortSet = new Set();
|
|
444
|
-
for (const item of selectedOnSort) {
|
|
445
|
-
if (item.id !== undefined) {
|
|
446
|
-
selectedOnSortSet.add(item.id);
|
|
447
|
-
} else {
|
|
448
|
-
selectedOnSortSet.add(item);
|
|
449
|
-
}
|
|
450
|
-
}
|
|
451
|
-
const isSelectedForSort = item => {
|
|
452
|
-
if (item.id !== undefined) {
|
|
453
|
-
return selectedOnSortSet.has(item.id);
|
|
454
|
-
}
|
|
455
|
-
return selectedOnSortSet.has(item);
|
|
456
|
-
};
|
|
457
403
|
return items.map(item => {
|
|
458
404
|
return {
|
|
459
405
|
...item,
|
|
@@ -490,39 +436,42 @@ function Panel({
|
|
|
490
436
|
};
|
|
491
437
|
}).sort((itemA, itemB) => {
|
|
492
438
|
if (shouldOrderSelectedFirst) {
|
|
493
|
-
|
|
494
|
-
const
|
|
439
|
+
// itemA is selected (for sorting purposes) if an object in selectedOnSort matches every property of itemA, except for the selected property
|
|
440
|
+
const itemASelected = selectedOnSort.some(item => Object.entries(item).every(([key, value]) => {
|
|
441
|
+
if (key === 'selected') {
|
|
442
|
+
return true;
|
|
443
|
+
}
|
|
444
|
+
return itemA[key] === value;
|
|
445
|
+
}));
|
|
446
|
+
|
|
447
|
+
// itemB is selected (for sorting purposes) if an object in selectedOnSort matches every property of itemA, except for the selected property
|
|
448
|
+
const itemBSelected = selectedOnSort.some(item => Object.entries(item).every(([key, value]) => {
|
|
449
|
+
if (key === 'selected') {
|
|
450
|
+
return true;
|
|
451
|
+
}
|
|
452
|
+
return itemB[key] === value;
|
|
453
|
+
}));
|
|
495
454
|
|
|
496
455
|
// order selected items first
|
|
497
|
-
if (itemASelected
|
|
456
|
+
if (itemASelected > itemBSelected) {
|
|
498
457
|
return -1;
|
|
499
|
-
} else if (
|
|
458
|
+
} else if (itemASelected < itemBSelected) {
|
|
500
459
|
return 1;
|
|
501
460
|
}
|
|
502
461
|
}
|
|
503
462
|
return 0;
|
|
504
463
|
});
|
|
505
464
|
}, [onClose, onSelectedChange, items, selected, isItemCurrentlySelected, isSingleSelectModal, intermediateSelected, shouldOrderSelectedFirst, selectedOnSort]);
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
useEffect(() => {
|
|
510
|
-
if (prevItemsRef.current !== items) {
|
|
511
|
-
if (prevItemsRef.current.length === 0 && items.length > 0) {
|
|
512
|
-
resetSort();
|
|
513
|
-
}
|
|
514
|
-
prevItemsRef.current = items;
|
|
515
|
-
}
|
|
516
|
-
}, [items, resetSort]);
|
|
517
|
-
|
|
518
|
-
// Reset sort when panel opens
|
|
519
|
-
const prevOpenRef = useRef(open);
|
|
520
|
-
useEffect(() => {
|
|
521
|
-
if (prevOpenRef.current !== open) {
|
|
465
|
+
if (prevItems !== items) {
|
|
466
|
+
setPrevItems(items);
|
|
467
|
+
if (prevItems.length === 0 && items.length > 0) {
|
|
522
468
|
resetSort();
|
|
523
|
-
prevOpenRef.current = open;
|
|
524
469
|
}
|
|
525
|
-
}
|
|
470
|
+
}
|
|
471
|
+
if (open !== prevOpen) {
|
|
472
|
+
setPrevOpen(open);
|
|
473
|
+
resetSort();
|
|
474
|
+
}
|
|
526
475
|
const focusTrapSettings = {
|
|
527
476
|
initialFocusRef: inputRef || undefined
|
|
528
477
|
};
|
|
@@ -732,8 +681,7 @@ function Panel({
|
|
|
732
681
|
},
|
|
733
682
|
fullScreenOnNarrow: usingFullScreenOnNarrow,
|
|
734
683
|
className: clsx(className, classes.FilteredActionList),
|
|
735
|
-
focusPrependedElements: focusPrependedElements
|
|
736
|
-
virtualized: virtualized
|
|
684
|
+
focusPrependedElements: focusPrependedElements
|
|
737
685
|
}), footer ? /*#__PURE__*/jsx("div", {
|
|
738
686
|
className: classes.Footer,
|
|
739
687
|
children: footer
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type React from 'react';
|
|
2
|
-
import type { PageLayoutContentProps, PageLayoutFooterProps, PageLayoutHeaderProps, PageLayoutPaneProps
|
|
2
|
+
import type { PageLayoutContentProps, PageLayoutFooterProps, PageLayoutHeaderProps, PageLayoutPaneProps } from '../PageLayout';
|
|
3
3
|
export type SplitPageLayoutProps = {
|
|
4
4
|
className?: string;
|
|
5
5
|
};
|
|
@@ -10,15 +10,12 @@ export type SplitPageLayoutContentProps = PageLayoutContentProps;
|
|
|
10
10
|
export declare const Content: React.FC<React.PropsWithChildren<SplitPageLayoutContentProps>>;
|
|
11
11
|
export type SplitPageLayoutPaneProps = PageLayoutPaneProps;
|
|
12
12
|
export declare const Pane: React.FC<React.PropsWithChildren<SplitPageLayoutPaneProps>>;
|
|
13
|
-
export type SplitPageLayoutSidebarProps = PageLayoutSidebarProps;
|
|
14
|
-
export declare const Sidebar: React.FC<React.PropsWithChildren<SplitPageLayoutSidebarProps>>;
|
|
15
13
|
export type SplitPageLayoutFooterProps = PageLayoutFooterProps;
|
|
16
14
|
export declare const Footer: React.FC<React.PropsWithChildren<SplitPageLayoutFooterProps>>;
|
|
17
15
|
export declare const SplitPageLayout: React.FC<React.PropsWithChildren<SplitPageLayoutProps>> & {
|
|
18
16
|
Header: React.FC<React.PropsWithChildren<PageLayoutHeaderProps>>;
|
|
19
17
|
Content: React.FC<React.PropsWithChildren<PageLayoutContentProps>>;
|
|
20
18
|
Pane: React.FC<React.PropsWithChildren<PageLayoutPaneProps>>;
|
|
21
|
-
Sidebar: React.FC<React.PropsWithChildren<PageLayoutSidebarProps>>;
|
|
22
19
|
Footer: React.FC<React.PropsWithChildren<PageLayoutFooterProps>>;
|
|
23
20
|
};
|
|
24
21
|
//# sourceMappingURL=SplitPageLayout.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SplitPageLayout.d.ts","sourceRoot":"","sources":["../../src/SplitPageLayout/SplitPageLayout.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,EACV,sBAAsB,EACtB,qBAAqB,EACrB,qBAAqB,EACrB,mBAAmB,
|
|
1
|
+
{"version":3,"file":"SplitPageLayout.d.ts","sourceRoot":"","sources":["../../src/SplitPageLayout/SplitPageLayout.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,KAAK,EACV,sBAAsB,EACtB,qBAAqB,EACrB,qBAAqB,EACrB,mBAAmB,EACpB,MAAM,eAAe,CAAA;AAMtB,MAAM,MAAM,oBAAoB,GAAG;IAAC,SAAS,CAAC,EAAE,MAAM,CAAA;CAAC,CAAA;AAEvD,eAAO,MAAM,IAAI,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CAAC,iBAAiB,CAAC,oBAAoB,CAAC,CAcxE,CAAA;AAOD,MAAM,MAAM,0BAA0B,GAAG,qBAAqB,CAAA;AAE9D,eAAO,MAAM,MAAM,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CAAC,iBAAiB,CAAC,0BAA0B,CAAC,CAOhF,CAAA;AAOD,MAAM,MAAM,2BAA2B,GAAG,sBAAsB,CAAA;AAEhE,eAAO,MAAM,OAAO,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CAAC,iBAAiB,CAAC,2BAA2B,CAAC,CAMlF,CAAA;AAOD,MAAM,MAAM,wBAAwB,GAAG,mBAAmB,CAAA;AAE1D,eAAO,MAAM,IAAI,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CAAC,iBAAiB,CAAC,wBAAwB,CAAC,CAgB5E,CAAA;AAMD,MAAM,MAAM,0BAA0B,GAAG,qBAAqB,CAAA;AAE9D,eAAO,MAAM,MAAM,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CAAC,iBAAiB,CAAC,0BAA0B,CAAC,CAOhF,CAAA;AAOD,eAAO,MAAM,eAAe;;;;;CAK1B,CAAA"}
|
|
@@ -8,8 +8,7 @@ const Root = props => {
|
|
|
8
8
|
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
|
|
9
9
|
t0 = {
|
|
10
10
|
header: Header,
|
|
11
|
-
footer: Footer
|
|
12
|
-
sidebar: Sidebar
|
|
11
|
+
footer: Footer
|
|
13
12
|
};
|
|
14
13
|
$[0] = t0;
|
|
15
14
|
} else {
|
|
@@ -177,56 +176,6 @@ const Pane = t0 => {
|
|
|
177
176
|
};
|
|
178
177
|
Pane.displayName = 'SplitPageLayout.Pane';
|
|
179
178
|
|
|
180
|
-
// ----------------------------------------------------------------------------
|
|
181
|
-
// SplitPageLayout.Sidebar
|
|
182
|
-
|
|
183
|
-
const Sidebar = t0 => {
|
|
184
|
-
const $ = c(10);
|
|
185
|
-
let props;
|
|
186
|
-
let t1;
|
|
187
|
-
let t2;
|
|
188
|
-
let t3;
|
|
189
|
-
if ($[0] !== t0) {
|
|
190
|
-
({
|
|
191
|
-
position: t1,
|
|
192
|
-
padding: t2,
|
|
193
|
-
divider: t3,
|
|
194
|
-
...props
|
|
195
|
-
} = t0);
|
|
196
|
-
$[0] = t0;
|
|
197
|
-
$[1] = props;
|
|
198
|
-
$[2] = t1;
|
|
199
|
-
$[3] = t2;
|
|
200
|
-
$[4] = t3;
|
|
201
|
-
} else {
|
|
202
|
-
props = $[1];
|
|
203
|
-
t1 = $[2];
|
|
204
|
-
t2 = $[3];
|
|
205
|
-
t3 = $[4];
|
|
206
|
-
}
|
|
207
|
-
const position = t1 === undefined ? "start" : t1;
|
|
208
|
-
const padding = t2 === undefined ? "normal" : t2;
|
|
209
|
-
const divider = t3 === undefined ? "line" : t3;
|
|
210
|
-
let t4;
|
|
211
|
-
if ($[5] !== divider || $[6] !== padding || $[7] !== position || $[8] !== props) {
|
|
212
|
-
t4 = /*#__PURE__*/jsx(PageLayout.Sidebar, {
|
|
213
|
-
position: position,
|
|
214
|
-
padding: padding,
|
|
215
|
-
divider: divider,
|
|
216
|
-
...props
|
|
217
|
-
});
|
|
218
|
-
$[5] = divider;
|
|
219
|
-
$[6] = padding;
|
|
220
|
-
$[7] = position;
|
|
221
|
-
$[8] = props;
|
|
222
|
-
$[9] = t4;
|
|
223
|
-
} else {
|
|
224
|
-
t4 = $[9];
|
|
225
|
-
}
|
|
226
|
-
return t4;
|
|
227
|
-
};
|
|
228
|
-
Sidebar.displayName = 'SplitPageLayout.Sidebar';
|
|
229
|
-
|
|
230
179
|
// ----------------------------------------------------------------------------
|
|
231
180
|
// SplitPageLayout.Footer
|
|
232
181
|
|
|
@@ -277,8 +226,7 @@ const SplitPageLayout = Object.assign(Root, {
|
|
|
277
226
|
Header,
|
|
278
227
|
Content,
|
|
279
228
|
Pane,
|
|
280
|
-
Sidebar,
|
|
281
229
|
Footer
|
|
282
230
|
});
|
|
283
231
|
|
|
284
|
-
export { Content, Footer, Header, Pane, Root,
|
|
232
|
+
export { Content, Footer, Header, Pane, Root, SplitPageLayout };
|
package/dist/Text/Text.d.ts
CHANGED
package/dist/Text/Text.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Text.d.ts","sourceRoot":"","sources":["../../src/Text/Text.tsx"],"names":[],"mappings":"AACA,OAAO,
|
|
1
|
+
{"version":3,"file":"Text.d.ts","sourceRoot":"","sources":["../../src/Text/Text.tsx"],"names":[],"mappings":"AACA,OAAO,KAA0B,MAAM,OAAO,CAAA;AAG9C,OAAO,EAAkB,KAAK,gBAAgB,EAAC,MAAM,6BAA6B,CAAA;AAElF,MAAM,MAAM,SAAS,CAAC,EAAE,SAAS,KAAK,CAAC,WAAW,GAAG,MAAM,IAAI,gBAAgB,CAC7E,EAAE,EACF,MAAM,EACN;IACE,IAAI,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAA;IACnC,MAAM,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,QAAQ,GAAG,UAAU,CAAA;IACnD,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CACF,CAAA;yBAGa,EAAE,SAAS,KAAK,CAAC,WAAW;WAP/B,OAAO,GAAG,QAAQ,GAAG,OAAO;aAC1B,OAAO,GAAG,QAAQ,GAAG,QAAQ,GAAG,UAAU;gBACvC,MAAM;;WAFX,OAAO,GAAG,QAAQ,GAAG,OAAO;aAC1B,OAAO,GAAG,QAAQ,GAAG,QAAQ,GAAG,UAAU;gBACvC,MAAM;;;;AAuBtB,wBAAoC"}
|
package/dist/Text/Text.js
CHANGED
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
import { c } from 'react-compiler-runtime';
|
|
2
2
|
import { clsx } from 'clsx';
|
|
3
|
+
import React from 'react';
|
|
3
4
|
import classes from './Text.module.css.js';
|
|
4
5
|
import { fixedForwardRef } from '../utils/modern-polymorphic.js';
|
|
5
6
|
import { jsx } from 'react/jsx-runtime';
|
|
7
|
+
import { useRefObjectAsForwardedRef } from '../hooks/useRefObjectAsForwardedRef.js';
|
|
6
8
|
|
|
7
9
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
8
10
|
function Text(props, ref) {
|
|
9
|
-
const $ = c(
|
|
11
|
+
const $ = c(14);
|
|
10
12
|
let className;
|
|
11
13
|
let rest;
|
|
12
14
|
let size;
|
|
@@ -34,6 +36,8 @@ function Text(props, ref) {
|
|
|
34
36
|
weight = $[5];
|
|
35
37
|
}
|
|
36
38
|
const Component = t0 === undefined ? "span" : t0;
|
|
39
|
+
const innerRef = React.useRef(null);
|
|
40
|
+
useRefObjectAsForwardedRef(ref, innerRef);
|
|
37
41
|
let t1;
|
|
38
42
|
if ($[6] !== className) {
|
|
39
43
|
t1 = clsx(className, classes.Text);
|
|
@@ -43,23 +47,22 @@ function Text(props, ref) {
|
|
|
43
47
|
t1 = $[7];
|
|
44
48
|
}
|
|
45
49
|
let t2;
|
|
46
|
-
if ($[8] !== Component || $[9] !==
|
|
50
|
+
if ($[8] !== Component || $[9] !== rest || $[10] !== size || $[11] !== t1 || $[12] !== weight) {
|
|
47
51
|
t2 = /*#__PURE__*/jsx(Component, {
|
|
48
52
|
className: t1,
|
|
49
53
|
"data-size": size,
|
|
50
54
|
"data-weight": weight,
|
|
51
55
|
...rest,
|
|
52
|
-
ref:
|
|
56
|
+
ref: innerRef
|
|
53
57
|
});
|
|
54
58
|
$[8] = Component;
|
|
55
|
-
$[9] =
|
|
56
|
-
$[10] =
|
|
57
|
-
$[11] =
|
|
58
|
-
$[12] =
|
|
59
|
-
$[13] =
|
|
60
|
-
$[14] = t2;
|
|
59
|
+
$[9] = rest;
|
|
60
|
+
$[10] = size;
|
|
61
|
+
$[11] = t1;
|
|
62
|
+
$[12] = weight;
|
|
63
|
+
$[13] = t2;
|
|
61
64
|
} else {
|
|
62
|
-
t2 = $[
|
|
65
|
+
t2 = $[13];
|
|
63
66
|
}
|
|
64
67
|
return t2;
|
|
65
68
|
}
|
|
@@ -1,21 +1,58 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { c } from 'react-compiler-runtime';
|
|
2
|
+
import { forwardRef, useRef, useContext } from 'react';
|
|
2
3
|
import { UnderlineNavContext } from './UnderlineNavContext.js';
|
|
3
4
|
import useIsomorphicLayoutEffect from '../utils/useIsomorphicLayoutEffect.js';
|
|
4
5
|
import { UnderlineItem } from '../internal/components/UnderlineTabbedInterface.js';
|
|
5
6
|
import classes from './UnderlineNavItem.module.css.js';
|
|
6
7
|
import { jsx } from 'react/jsx-runtime';
|
|
7
8
|
|
|
8
|
-
const UnderlineNavItem = /*#__PURE__*/forwardRef(({
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
9
|
+
const UnderlineNavItem = /*#__PURE__*/forwardRef((t0, forwardedRef) => {
|
|
10
|
+
var _leadingVisual;
|
|
11
|
+
const $ = c(32);
|
|
12
|
+
let Icon;
|
|
13
|
+
let ariaCurrent;
|
|
14
|
+
let children;
|
|
15
|
+
let counter;
|
|
16
|
+
let leadingVisual;
|
|
17
|
+
let onSelect;
|
|
18
|
+
let props;
|
|
19
|
+
let t1;
|
|
20
|
+
let t2;
|
|
21
|
+
if ($[0] !== t0) {
|
|
22
|
+
({
|
|
23
|
+
as: t1,
|
|
24
|
+
href: t2,
|
|
25
|
+
children,
|
|
26
|
+
counter,
|
|
27
|
+
onSelect,
|
|
28
|
+
"aria-current": ariaCurrent,
|
|
29
|
+
icon: Icon,
|
|
30
|
+
leadingVisual,
|
|
31
|
+
...props
|
|
32
|
+
} = t0);
|
|
33
|
+
$[0] = t0;
|
|
34
|
+
$[1] = Icon;
|
|
35
|
+
$[2] = ariaCurrent;
|
|
36
|
+
$[3] = children;
|
|
37
|
+
$[4] = counter;
|
|
38
|
+
$[5] = leadingVisual;
|
|
39
|
+
$[6] = onSelect;
|
|
40
|
+
$[7] = props;
|
|
41
|
+
$[8] = t1;
|
|
42
|
+
$[9] = t2;
|
|
43
|
+
} else {
|
|
44
|
+
Icon = $[1];
|
|
45
|
+
ariaCurrent = $[2];
|
|
46
|
+
children = $[3];
|
|
47
|
+
counter = $[4];
|
|
48
|
+
leadingVisual = $[5];
|
|
49
|
+
onSelect = $[6];
|
|
50
|
+
props = $[7];
|
|
51
|
+
t1 = $[8];
|
|
52
|
+
t2 = $[9];
|
|
53
|
+
}
|
|
54
|
+
const Component = t1 === undefined ? "a" : t1;
|
|
55
|
+
const href = t2 === undefined ? "#" : t2;
|
|
19
56
|
const backupRef = useRef(null);
|
|
20
57
|
const ref = forwardedRef !== null && forwardedRef !== void 0 ? forwardedRef : backupRef;
|
|
21
58
|
const {
|
|
@@ -24,51 +61,107 @@ const UnderlineNavItem = /*#__PURE__*/forwardRef(({
|
|
|
24
61
|
loadingCounters,
|
|
25
62
|
iconsVisible
|
|
26
63
|
} = useContext(UnderlineNavContext);
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
text
|
|
36
|
-
width:
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
64
|
+
let t3;
|
|
65
|
+
let t4;
|
|
66
|
+
if ($[10] !== ref || $[11] !== setChildrenWidth || $[12] !== setNoIconChildrenWidth) {
|
|
67
|
+
t3 = () => {
|
|
68
|
+
if (ref.current) {
|
|
69
|
+
const domRect = ref.current.getBoundingClientRect();
|
|
70
|
+
const icon = Array.from(ref.current.children).find(_temp);
|
|
71
|
+
const content = Array.from(ref.current.children).find(_temp2);
|
|
72
|
+
const text = content.textContent;
|
|
73
|
+
const iconWidthWithMargin = icon ? icon.getBoundingClientRect().width + Number(getComputedStyle(icon).marginRight.slice(0, -2)) + Number(getComputedStyle(icon).marginLeft.slice(0, -2)) : 0;
|
|
74
|
+
setChildrenWidth({
|
|
75
|
+
text,
|
|
76
|
+
width: domRect.width
|
|
77
|
+
});
|
|
78
|
+
setNoIconChildrenWidth({
|
|
79
|
+
text,
|
|
80
|
+
width: domRect.width - iconWidthWithMargin
|
|
81
|
+
});
|
|
82
|
+
}
|
|
83
|
+
};
|
|
84
|
+
t4 = [ref, setChildrenWidth, setNoIconChildrenWidth];
|
|
85
|
+
$[10] = ref;
|
|
86
|
+
$[11] = setChildrenWidth;
|
|
87
|
+
$[12] = setNoIconChildrenWidth;
|
|
88
|
+
$[13] = t3;
|
|
89
|
+
$[14] = t4;
|
|
90
|
+
} else {
|
|
91
|
+
t3 = $[13];
|
|
92
|
+
t4 = $[14];
|
|
93
|
+
}
|
|
94
|
+
useIsomorphicLayoutEffect(t3, t4);
|
|
95
|
+
let t5;
|
|
96
|
+
if ($[15] !== onSelect) {
|
|
97
|
+
t5 = event => {
|
|
98
|
+
if ((event.key === " " || event.key === "Enter") && !event.defaultPrevented && typeof onSelect === "function") {
|
|
99
|
+
onSelect(event);
|
|
100
|
+
}
|
|
101
|
+
};
|
|
102
|
+
$[15] = onSelect;
|
|
103
|
+
$[16] = t5;
|
|
104
|
+
} else {
|
|
105
|
+
t5 = $[16];
|
|
106
|
+
}
|
|
107
|
+
const keyDownHandler = t5;
|
|
108
|
+
let t6;
|
|
109
|
+
if ($[17] !== onSelect) {
|
|
110
|
+
t6 = event_0 => {
|
|
111
|
+
if (!event_0.defaultPrevented && typeof onSelect === "function") {
|
|
112
|
+
onSelect(event_0);
|
|
113
|
+
}
|
|
114
|
+
};
|
|
115
|
+
$[17] = onSelect;
|
|
116
|
+
$[18] = t6;
|
|
117
|
+
} else {
|
|
118
|
+
t6 = $[18];
|
|
119
|
+
}
|
|
120
|
+
const clickHandler = t6;
|
|
121
|
+
const t7 = (_leadingVisual = leadingVisual) !== null && _leadingVisual !== void 0 ? _leadingVisual : Icon;
|
|
122
|
+
let t8;
|
|
123
|
+
if ($[19] !== Component || $[20] !== ariaCurrent || $[21] !== children || $[22] !== clickHandler || $[23] !== counter || $[24] !== href || $[25] !== iconsVisible || $[26] !== keyDownHandler || $[27] !== loadingCounters || $[28] !== props || $[29] !== ref || $[30] !== t7) {
|
|
124
|
+
t8 = /*#__PURE__*/jsx("li", {
|
|
125
|
+
className: classes.UnderlineNavItem,
|
|
126
|
+
children: /*#__PURE__*/jsx(UnderlineItem, {
|
|
127
|
+
ref: ref,
|
|
128
|
+
as: Component,
|
|
129
|
+
href: href,
|
|
130
|
+
"aria-current": ariaCurrent,
|
|
131
|
+
onKeyDown: keyDownHandler,
|
|
132
|
+
onClick: clickHandler,
|
|
133
|
+
counter: counter,
|
|
134
|
+
icon: t7,
|
|
135
|
+
loadingCounters: loadingCounters,
|
|
136
|
+
iconsVisible: iconsVisible,
|
|
137
|
+
...props,
|
|
138
|
+
children: children
|
|
139
|
+
})
|
|
140
|
+
});
|
|
141
|
+
$[19] = Component;
|
|
142
|
+
$[20] = ariaCurrent;
|
|
143
|
+
$[21] = children;
|
|
144
|
+
$[22] = clickHandler;
|
|
145
|
+
$[23] = counter;
|
|
146
|
+
$[24] = href;
|
|
147
|
+
$[25] = iconsVisible;
|
|
148
|
+
$[26] = keyDownHandler;
|
|
149
|
+
$[27] = loadingCounters;
|
|
150
|
+
$[28] = props;
|
|
151
|
+
$[29] = ref;
|
|
152
|
+
$[30] = t7;
|
|
153
|
+
$[31] = t8;
|
|
154
|
+
} else {
|
|
155
|
+
t8 = $[31];
|
|
156
|
+
}
|
|
157
|
+
return t8;
|
|
71
158
|
});
|
|
72
159
|
UnderlineNavItem.displayName = 'UnderlineNavItem';
|
|
160
|
+
function _temp(child) {
|
|
161
|
+
return child.getAttribute("data-component") === "icon";
|
|
162
|
+
}
|
|
163
|
+
function _temp2(child_0) {
|
|
164
|
+
return child_0.getAttribute("data-component") === "text";
|
|
165
|
+
}
|
|
73
166
|
|
|
74
167
|
export { UnderlineNavItem };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
.prc-SelectPanel2-Overlay--Q-FI{border:none;color:var(--fgColor-default,var(--color-fg-default));padding:0;--max-height:0;--position-top:0;--position-left:0}.prc-SelectPanel2-Overlay--Q-FI:where([open]){display:flex}.prc-SelectPanel2-Overlay--Q-FI:where([data-variant=anchored]),.prc-SelectPanel2-Overlay--Q-FI:where([data-variant=full-screen]){left:var(--position-left);margin:0;top:var(--position-top)}:is(.prc-SelectPanel2-Overlay--Q-FI:where([data-variant=anchored]),.prc-SelectPanel2-Overlay--Q-FI:where([data-variant=full-screen]))::backdrop{background-color:transparent}.prc-SelectPanel2-Overlay--Q-FI:where([data-variant=modal]){bottom:0;left:0;right:0;top:0}.prc-SelectPanel2-Overlay--Q-FI:where([data-variant=modal])::backdrop{background-color:var(--overlay-backdrop-bgColor,var(--color-overlay-backdrop))}.prc-SelectPanel2-Overlay--Q-FI:where([data-variant=full-screen]){border-radius:unset;height:100%;left:0;margin:0;max-height:100vh;max-width:100vw;top:0;width:100%}.prc-SelectPanel2-Overlay--Q-FI:where([data-variant=bottom-sheet]){border-bottom-left-radius:0;border-bottom-right-radius:0;bottom:0;left:0;margin:0;max-height:calc(100vh - 64px);max-width:100vw;top:auto;width:100%}.prc-SelectPanel2-Form-bZ9HS{width:100%}.prc-SelectPanel2-Container-e5e6-,.prc-SelectPanel2-Form-bZ9HS{display:flex;flex-direction:column}.prc-SelectPanel2-Container-e5e6-{flex-grow:1;flex-shrink:1;justify-content:space-between;overflow:hidden}.prc-SelectPanel2-Container-e5e6- ul{flex-grow:1;overflow-y:auto}.prc-SelectPanel2-HeaderContent-MsaAS{align-items:center;display:flex;justify-content:space-between;margin-bottom:0}.prc-SelectPanel2-HeaderContent-MsaAS:where([data-description]){align-items:flex-start}.prc-SelectPanel2-HeaderContent-MsaAS:where([data-search-input]){margin-bottom:var(--base-size-8,.5rem)}.prc-SelectPanel2-TitleWrapper-HzPu3{margin-left:var(--base-size-8,.5rem);margin-top:0}.prc-SelectPanel2-TitleWrapper-HzPu3:where([data-description]){margin-top:2px}.prc-SelectPanel2-TitleWrapper-HzPu3:where([data-on-back]){margin-left:var(--base-size-4,.25rem)}.prc-SelectPanel2-TextInput-lHH1n{padding-left:var(--base-size-8,.5rem)!important}.prc-SelectPanel2-TextInput-lHH1n:has(input:placeholder-shown) .TextInput-action{display:none}.prc-SelectPanel2-Checkbox-AYR38{margin-top:0}.prc-SelectPanel2-FlexBox-gWPRg{display:flex}.prc-SelectPanel2-Title-T-h3f{font-size:var(--text-body-size-medium,.875rem);font-weight:var(--base-text-weight-semibold,600)}.prc-SelectPanel2-Description-qTXfi{display:block;font-size:var(--text-body-size-small,.75rem)}.prc-SelectPanel2-ClearAction-tQj-f,.prc-SelectPanel2-Description-qTXfi{color:var(--fgColor-muted,var(--color-fg-muted))}.prc-SelectPanel2-ClearAction-tQj-f{background:none}.prc-SelectPanel2-Footer-TibV0{align-items:center;border-top:var(--borderWidth-thin,.0625rem) solid;border-top-color:var(--borderColor-default,var(--color-border-default));display:flex;flex-shrink:0;justify-content:space-between;min-height:44px;padding:var(--base-size-16,1rem)}.prc-SelectPanel2-Footer-TibV0:where([data-hide-primary-actions]){padding:var(--base-size-8,.5rem)}.prc-SelectPanel2-FooterContent-UjAOM{flex-grow:0}.prc-SelectPanel2-FooterContent-UjAOM:where([data-hide-primary-actions]){flex-grow:1}.prc-SelectPanel2-FooterActions-T6yQR,.prc-SelectPanel2-SecondaryCheckbox-omkf-{display:flex;gap:var(--stack-gap-condensed,.5rem)}.prc-SelectPanel2-SecondaryCheckbox-omkf-{align-items:center}.prc-SelectPanel2-SmallText-c42ay{font-size:var(--text-body-size-small,.75rem)}.prc-SelectPanel2-SelectPanelLoading-mtyhD{align-items:center;display:flex;flex-direction:column;gap:var(--stack-gap-normal,1rem);height:100%;justify-content:center;min-height:min(calc(var(--max-height) - 150px),324px)}.prc-SelectPanel2-LoadingText-DB0wN{color:var(--fgColor-muted,var(--color-fg-muted));font-size:var(--text-body-size-medium,.875rem)}.prc-SelectPanel2-MessageFull-nY-qF{align-items:center;display:flex;flex-direction:column;flex-grow:1;gap:var(--base-size-4,.25rem);height:100%;justify-content:center;min-height:min(calc(var(--max-height) - 150px),324px);padding-left:var(--base-size-24,1.5rem);padding-right:var(--base-size-24,1.5rem);text-align:center}.prc-SelectPanel2-MessageFull-nY-qF a{color:inherit;-webkit-text-decoration:underline;text-decoration:underline}.prc-SelectPanel2-Octicon-zt-zU{margin-bottom:var(--base-size-8,.5rem)}.prc-SelectPanel2-Octicon-zt-zU.prc-SelectPanel2-Error-ZrZQQ{color:var(--fgColor-danger,var(--color-danger-fg))}.prc-SelectPanel2-Octicon-zt-zU.prc-SelectPanel2-Warning-PDsVF{color:var(--fgColor-attention,var(--color-attention-fg))}.prc-SelectPanel2-MessageTitle-T7v9d{font-size:var(--text-body-size-medium,.875rem);font-weight:var(--base-text-weight-medium,500)}.prc-SelectPanel2-MessageContent-UZ9vY{align-items:center;color:var(--fgColor-muted,var(--color-fg-muted));flex-direction:column;font-size:var(--text-body-size-medium,.875rem)}.prc-SelectPanel2-MessageContent-UZ9vY,.prc-SelectPanel2-MessageInline-sErQf{display:flex;gap:var(--stack-gap-condensed,.5rem)}.prc-SelectPanel2-MessageInline-sErQf{border-bottom:var(--borderWidth-thin,.0625rem) solid;font-size:var(--text-body-size-small,.75rem);padding:var(--base-size-12,.75rem) var(--base-size-16,1rem)}.prc-SelectPanel2-MessageInline-sErQf a{color:inherit;-webkit-text-decoration:underline;text-decoration:underline}.prc-SelectPanel2-MessageInline-sErQf:where([data-variant=error]){background-color:var(--bgColor-danger-muted,var(--color-danger-subtle));border-color:var(--borderColor-danger-muted,var(--color-danger-muted));color:var(--fgColor-danger,var(--color-danger-fg))}.prc-SelectPanel2-MessageInline-sErQf:where([data-variant=warning]){background-color:var(--bgColor-attention-muted,var(--color-attention-subtle));border-color:var(--borderColor-attention-muted,var(--color-attention-muted));color:var(--fgColor-attention,var(--color-attention-fg))}.prc-SelectPanel2-Header-LKyEJ{border-bottom:var(--borderWidth-thin,.0625rem) solid;border-bottom-color:var(--borderColor-default,var(--color-border-default));display:flex;flex-direction:column;padding:var(--base-size-8,.5rem)}
|
|
2
|
+
/*# sourceMappingURL=SelectPanel-1f8c23b5.css.map */
|
package/dist/experimental/SelectPanel2/{SelectPanel-f0c4b9ca.css.map → SelectPanel-1f8c23b5.css.map}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/experimental/SelectPanel2/SelectPanel.module.css.js"],"names":[],"mappings":"AAAA,gCAGE,WAAY,CADZ,oDAA6B,CAD7B,SAAU,CAKV,cAAe,CACf,gBAAiB,CACjB,iBAoDF,CAlDE,8CACE,YACF,CAEA,iIAKE,yBAA0B,CAC1B,QAAS,CAHT,uBAQF,CAHE,gJACE,4BACF,CAGF,4DAIE,QAAS,CAFT,MAAO,CACP,OAAQ,CAFR,KAIF,CAEA,sEACE,8EACF,CAEA,kEAQE,mBAAoB,CAHpB,WAAY,CAHZ,MAAO,CAKP,QAAS,CADT,gBAAiB,CAFjB,eAAgB,CAHhB,KAAM,CAEN,UAMF,CAEA,mEASE,2BAA4B,CAD5B,4BAA6B,CAN7B,QAAS,CACT,MAAO,CAIP,QAAS,CADT,6BAA8B,CAD9B,eAAgB,CAJhB,QAAS,CAGT,UAMF,CAGF,6BAEE,UAEF,CAEA,+DALE,YAAa,CAEb,
|
|
1
|
+
{"version":3,"sources":["../../src/experimental/SelectPanel2/SelectPanel.module.css.js"],"names":[],"mappings":"AAAA,gCAGE,WAAY,CADZ,oDAA6B,CAD7B,SAAU,CAKV,cAAe,CACf,gBAAiB,CACjB,iBAoDF,CAlDE,8CACE,YACF,CAEA,iIAKE,yBAA0B,CAC1B,QAAS,CAHT,uBAQF,CAHE,gJACE,4BACF,CAGF,4DAIE,QAAS,CAFT,MAAO,CACP,OAAQ,CAFR,KAIF,CAEA,sEACE,8EACF,CAEA,kEAQE,mBAAoB,CAHpB,WAAY,CAHZ,MAAO,CAKP,QAAS,CADT,gBAAiB,CAFjB,eAAgB,CAHhB,KAAM,CAEN,UAMF,CAEA,mEASE,2BAA4B,CAD5B,4BAA6B,CAN7B,QAAS,CACT,MAAO,CAIP,QAAS,CADT,6BAA8B,CAD9B,eAAgB,CAJhB,QAAS,CAGT,UAMF,CAGF,6BAEE,UAEF,CAEA,+DALE,YAAa,CAEb,qBAeF,CAZA,kCAKE,WAAY,CADZ,aAAc,CAEd,6BAA8B,CAJ9B,eAUF,CAJE,qCAEE,WAAY,CADZ,eAEF,CAGF,sCAGE,kBAAmB,CAFnB,YAAa,CACb,6BAA8B,CAE9B,eASF,CAPE,gEACE,sBACF,CAEA,iEACE,sCACF,CAGF,qCAEE,oCAA+B,CAD/B,YAWF,CARE,+DAEE,cACF,CAEA,2DACE,qCACF,CAGF,kCACE,+CAMF,CAHE,iFACE,YACF,CAGF,iCACE,YACF,CAEA,gCACE,YACF,CAEA,8BACE,8CAAuC,CACvC,gDACF,CAEA,oCACE,aAAc,CACd,4CAEF,CAEA,wEAHE,gDAMF,CAHA,oCAEE,eACF,CAEA,+BAOE,kBAAmB,CAHnB,iDAAyC,CACzC,uEAA4C,CAJ5C,YAAa,CAOb,aAAc,CAFd,6BAA8B,CAJ9B,eAAgB,CAChB,gCAUF,CAHE,kEACE,gCACF,CAGF,sCACE,WAKF,CAHE,yEACE,WACF,CAQF,gFAJE,YAAa,CACb,oCAOF,CAJA,0CAEE,kBAEF,CAEA,kCACE,4CACF,CAEA,2CAQE,kBAAmB,CAPnB,YAAa,CAKb,qBAAsB,CAGtB,gCAA4B,CAP5B,WAAY,CAKZ,sBAAuB,CAFvB,qDAKF,CAEA,oCAEE,gDAA2B,CAD3B,8CAEF,CAEA,oCAWE,kBAAmB,CAVnB,YAAa,CAQb,qBAAsB,CAGtB,WAAY,CACZ,6BAAuB,CAXvB,WAAY,CAQZ,sBAAuB,CALvB,qDAAuD,CAEvD,uCAAiC,CADjC,wCAAkC,CAElC,iBAWF,CAJE,sCACE,aAAc,CACd,iCAA0B,CAA1B,yBACF,CAGF,gCACE,sCASF,CAPE,6DACE,kDACF,CAEA,+DACE,wDACF,CAGF,qCACE,8CAAuC,CACvC,8CACF,CAEA,uCAME,kBAAmB,CAHnB,gDAA2B,CAC3B,qBAAsB,CAFtB,8CAKF,CAEA,6EARE,YAAa,CAIb,oCA8BF,CA1BA,sCAOE,oDAA4C,CAD5C,4CAAsC,CADtC,2DAqBF,CAhBE,wCACE,aAAc,CACd,iCAA0B,CAA1B,yBACF,CAEA,kEAEE,uEAA6C,CAC7C,sEAA6C,CAF7C,kDAGF,CAEA,oEAEE,6EAAgD,CAChD,4EAAgD,CAFhD,wDAGF,CAGF,+BAIE,oDAA4C,CAC5C,0EAA+C,CAJ/C,YAAa,CAEb,qBAAsB,CADtB,gCAIF","file":"SelectPanel-1f8c23b5.css","sourcesContent":[".Overlay {\n padding: 0;\n color: var(--fgColor-default);\n border: none;\n\n /* CSS variables values are passed in via styles */\n --max-height: 0;\n --position-top: 0;\n --position-left: 0;\n\n &:where([open]) {\n display: flex; /* to fit children */\n }\n\n &:where([data-variant='anchored']),\n &:where([data-variant='full-screen']) {\n /* stylelint-disable-next-line primer/spacing */\n top: var(--position-top);\n /* stylelint-disable-next-line primer/spacing */\n left: var(--position-left);\n margin: 0;\n\n &::backdrop {\n background-color: transparent;\n }\n }\n\n &:where([data-variant='modal']) {\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n }\n\n &:where([data-variant='modal'])::backdrop {\n background-color: var(--overlay-backdrop-bgColor);\n }\n\n &:where([data-variant='full-screen']) {\n top: 0;\n left: 0;\n width: 100%;\n max-width: 100vw;\n height: 100%;\n max-height: 100vh;\n margin: 0;\n border-radius: unset;\n }\n\n &:where([data-variant='bottom-sheet']) {\n top: auto;\n bottom: 0;\n left: 0;\n width: 100%;\n max-width: 100vw;\n max-height: calc(100vh - 64px);\n margin: 0;\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n }\n}\n\n.Form {\n display: flex;\n width: 100%;\n flex-direction: column;\n}\n\n.Container {\n display: flex;\n overflow: hidden;\n flex-direction: column;\n flex-shrink: 1;\n flex-grow: 1;\n justify-content: space-between;\n\n ul {\n overflow-y: auto;\n flex-grow: 1;\n }\n}\n\n.HeaderContent {\n display: flex;\n justify-content: space-between;\n align-items: center;\n margin-bottom: 0;\n\n &:where([data-description]) {\n align-items: flex-start;\n }\n\n &:where([data-search-input]) {\n margin-bottom: var(--base-size-8);\n }\n}\n\n.TitleWrapper {\n margin-top: 0;\n margin-left: var(--base-size-8);\n\n &:where([data-description]) {\n /* stylelint-disable-next-line primer/spacing */\n margin-top: 2px;\n }\n\n &:where([data-on-back]) {\n margin-left: var(--base-size-4);\n }\n}\n\n.TextInput {\n padding-left: var(--base-size-8) !important;\n\n /* stylelint-disable-next-line selector-class-pattern */\n &:has(input:placeholder-shown) :global(.TextInput-action) {\n display: none;\n }\n}\n\n.Checkbox {\n margin-top: 0;\n}\n\n.FlexBox {\n display: flex;\n}\n\n.Title {\n font-size: var(--text-body-size-medium);\n font-weight: var(--base-text-weight-semibold);\n}\n\n.Description {\n display: block;\n font-size: var(--text-body-size-small);\n color: var(--fgColor-muted);\n}\n\n.ClearAction {\n color: var(--fgColor-muted);\n background: none;\n}\n\n.Footer {\n display: flex;\n min-height: 44px;\n padding: var(--base-size-16);\n border-top: var(--borderWidth-thin) solid;\n border-top-color: var(--borderColor-default);\n justify-content: space-between;\n align-items: center;\n flex-shrink: 0;\n\n &:where([data-hide-primary-actions]) {\n padding: var(--base-size-8);\n }\n}\n\n.FooterContent {\n flex-grow: 0;\n\n &:where([data-hide-primary-actions]) {\n flex-grow: 1;\n }\n}\n\n.FooterActions {\n display: flex;\n gap: var(--stack-gap-condensed);\n}\n\n.SecondaryCheckbox {\n display: flex;\n align-items: center;\n gap: var(--stack-gap-condensed);\n}\n\n.SmallText {\n font-size: var(--text-body-size-small);\n}\n\n.SelectPanelLoading {\n display: flex;\n height: 100%;\n\n /* maxHeight of dialog - (header & footer) */\n min-height: min(calc(var(--max-height) - 150px), 324px);\n flex-direction: column;\n justify-content: center;\n align-items: center;\n gap: var(--stack-gap-normal);\n}\n\n.LoadingText {\n font-size: var(--text-body-size-medium);\n color: var(--fgColor-muted);\n}\n\n.MessageFull {\n display: flex;\n height: 100%;\n\n /* maxHeight of dialog - (header & footer) */\n min-height: min(calc(var(--max-height) - 150px), 324px);\n padding-right: var(--base-size-24);\n padding-left: var(--base-size-24);\n text-align: center;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n flex-grow: 1;\n gap: var(--base-size-4);\n\n a {\n color: inherit;\n text-decoration: underline;\n }\n}\n\n.Octicon {\n margin-bottom: var(--base-size-8);\n\n &.Error {\n color: var(--fgColor-danger);\n }\n\n &.Warning {\n color: var(--fgColor-attention);\n }\n}\n\n.MessageTitle {\n font-size: var(--text-body-size-medium);\n font-weight: var(--base-text-weight-medium);\n}\n\n.MessageContent {\n display: flex;\n font-size: var(--text-body-size-medium);\n color: var(--fgColor-muted);\n flex-direction: column;\n gap: var(--stack-gap-condensed);\n align-items: center;\n}\n\n.MessageInline {\n display: flex;\n padding-top: var(--base-size-12);\n padding-right: var(--base-size-16);\n padding-bottom: var(--base-size-12);\n padding-left: var(--base-size-16);\n font-size: var(--text-body-size-small);\n border-bottom: var(--borderWidth-thin) solid;\n gap: var(--stack-gap-condensed);\n\n a {\n color: inherit;\n text-decoration: underline;\n }\n\n &:where([data-variant='error']) {\n color: var(--fgColor-danger);\n background-color: var(--bgColor-danger-muted);\n border-color: var(--borderColor-danger-muted);\n }\n\n &:where([data-variant='warning']) {\n color: var(--fgColor-attention);\n background-color: var(--bgColor-attention-muted);\n border-color: var(--borderColor-attention-muted);\n }\n}\n\n.Header {\n display: flex;\n padding: var(--base-size-8);\n flex-direction: column;\n border-bottom: var(--borderWidth-thin) solid;\n border-bottom-color: var(--borderColor-default);\n}\n"]}
|