@sproutsocial/seeds-react-menu 1.17.0 → 1.18.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.
Files changed (59) hide show
  1. package/.turbo/turbo-build.log +14 -22
  2. package/CHANGELOG.md +30 -0
  3. package/dist/esm/index.js +542 -229
  4. package/dist/esm/index.js.map +1 -1
  5. package/dist/esm/v3/index.js +793 -1038
  6. package/dist/esm/v3/index.js.map +1 -1
  7. package/dist/v3/index.d.mts +64 -38
  8. package/dist/v3/index.d.ts +64 -38
  9. package/dist/v3/index.js +813 -1058
  10. package/dist/v3/index.js.map +1 -1
  11. package/dist/v3/menu.css +947 -0
  12. package/package.json +20 -21
  13. package/src/v3/ActionMenuStyles.tsx +169 -149
  14. package/src/v3/Common/ComboboxStyles.tsx +396 -511
  15. package/src/v3/Common/SelectIcons.tsx +17 -8
  16. package/src/v3/Common/SelectItem.tsx +25 -38
  17. package/src/v3/Common/SelectStyles.tsx +146 -144
  18. package/src/v3/Common/cn.ts +38 -0
  19. package/src/v3/MenuButtonStyles.tsx +55 -34
  20. package/src/v3/MultiSearchableSelect.tsx +8 -8
  21. package/src/v3/MultiSelect.tsx +11 -16
  22. package/src/v3/SingleSelect.tsx +13 -13
  23. package/src/v3/menu.css +947 -0
  24. package/tsup.config.ts +0 -1
  25. package/dist/esm/chunk-ROQATIB7.js +0 -357
  26. package/dist/esm/chunk-ROQATIB7.js.map +0 -1
  27. package/dist/esm/v2/index.js +0 -2089
  28. package/dist/esm/v2/index.js.map +0 -1
  29. package/dist/v2/index.d.mts +0 -108
  30. package/dist/v2/index.d.ts +0 -108
  31. package/dist/v2/index.js +0 -2280
  32. package/dist/v2/index.js.map +0 -1
  33. package/src/v2/Autocomplete/Autocomplete.stories.tsx +0 -645
  34. package/src/v2/Autocomplete/MultiAutocomplete.tsx +0 -487
  35. package/src/v2/Autocomplete/SingleAutocomplete.tsx +0 -366
  36. package/src/v2/Autocomplete/index.ts +0 -2
  37. package/src/v2/Common-V2/ComboboxContent.tsx +0 -457
  38. package/src/v2/Common-V2/MenuGroup.tsx +0 -60
  39. package/src/v2/Common-V2/MenuGroupTypes.ts +0 -30
  40. package/src/v2/Common-V2/MenuHeading.tsx +0 -83
  41. package/src/v2/Common-V2/MenuItem.tsx +0 -138
  42. package/src/v2/Common-V2/Popout.tsx +0 -124
  43. package/src/v2/Common-V2/PopoutTypes.tsx +0 -109
  44. package/src/v2/Common-V2/SelectToggleButton.tsx +0 -99
  45. package/src/v2/Common-V2/index.ts +0 -11
  46. package/src/v2/Common-V2/props.ts +0 -84
  47. package/src/v2/Common-V2/styles.tsx +0 -41
  48. package/src/v2/Common-V2/types.ts +0 -16
  49. package/src/v2/Common-V2/useHighlightedIndex.ts +0 -62
  50. package/src/v2/Common-V2/utils.ts +0 -238
  51. package/src/v2/SearchableSelect/AutocompleteContent.tsx +0 -325
  52. package/src/v2/SearchableSelect/SearchableMultiSelect.tsx +0 -527
  53. package/src/v2/SearchableSelect/SearchableSelect.tsx +0 -395
  54. package/src/v2/SearchableSelect/index.ts +0 -12
  55. package/src/v2/Select/MultiSelect.tsx +0 -417
  56. package/src/v2/Select/Select.stories.tsx +0 -593
  57. package/src/v2/Select/SingleSelect.tsx +0 -285
  58. package/src/v2/Select/index.ts +0 -2
  59. package/src/v2/index.ts +0 -2
package/dist/v3/index.js CHANGED
@@ -79,9 +79,8 @@ __export(v3_exports, {
79
79
  module.exports = __toCommonJS(v3_exports);
80
80
 
81
81
  // src/v3/SingleSelect.tsx
82
- var React4 = __toESM(require("react"));
82
+ var React5 = __toESM(require("react"));
83
83
  var import_select3 = require("@base-ui/react/select");
84
- var import_styled_components4 = __toESM(require("styled-components"));
85
84
 
86
85
  // src/v3/SeedsPortal.tsx
87
86
  var React = __toESM(require("react"));
@@ -104,49 +103,51 @@ function useSeedsPortalContainer() {
104
103
  }
105
104
 
106
105
  // src/v3/Common/SelectItem.tsx
107
- var React2 = require("react");
106
+ var React2 = __toESM(require("react"));
108
107
  var import_select = require("@base-ui/react/select");
109
- var import_styled_components = __toESM(require("styled-components"));
110
108
  var import_seeds_react_radio = __toESM(require("@sproutsocial/seeds-react-radio"));
111
109
  var import_seeds_react_checkbox = __toESM(require("@sproutsocial/seeds-react-checkbox"));
112
110
  var import_seeds_react_icon = require("@sproutsocial/seeds-react-icon");
113
- var import_jsx_runtime = require("react/jsx-runtime");
114
- var StyledItem = (0, import_styled_components.default)(import_select.Select.Item)`
115
- display: flex;
116
- align-items: center;
117
- gap: 8px;
118
- padding: 6px 8px;
119
- border-radius: ${({ theme }) => theme.radii[500]};
120
- font-size: 14px;
121
- color: ${({ theme }) => theme.colors.text.body};
122
- cursor: default;
123
- outline: none;
124
111
 
125
- &[data-highlighted] {
126
- background: ${({ theme }) => theme.colors.listItem.background.hover};
112
+ // src/v3/Common/cn.ts
113
+ function cn(...inputs) {
114
+ const classes = [];
115
+ for (const input of inputs) {
116
+ if (!input) continue;
117
+ if (typeof input === "string") {
118
+ classes.push(input);
119
+ } else if (typeof input === "object") {
120
+ for (const [key, value] of Object.entries(input)) {
121
+ if (value) {
122
+ classes.push(key);
123
+ }
124
+ }
125
+ }
127
126
  }
127
+ return classes.join(" ");
128
+ }
128
129
 
129
- &[data-selected] {
130
- font-weight: ${({ theme }) => theme.fontWeights.semibold};
130
+ // src/v3/Common/SelectItem.tsx
131
+ var import_jsx_runtime = require("react/jsx-runtime");
132
+ var StyledItem = React2.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
133
+ import_select.Select.Item,
134
+ {
135
+ ref,
136
+ className: cn("seeds-select-item", className),
137
+ ...rest
131
138
  }
132
-
133
- &[data-disabled] {
134
- opacity: 0.5;
135
- cursor: not-allowed;
136
- }
137
- `;
138
- var StyledItemIndicator = (0, import_styled_components.default)(import_select.Select.ItemIndicator)`
139
- display: flex;
140
- align-items: center;
141
- width: 16px;
142
- color: ${({ theme }) => theme.colors.text.body};
143
- visibility: hidden;
144
-
145
- &[data-selected] {
146
- visibility: visible;
139
+ ));
140
+ StyledItem.displayName = "StyledItem";
141
+ var StyledItemIndicator = React2.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
142
+ import_select.Select.ItemIndicator,
143
+ {
144
+ ref,
145
+ className: cn("seeds-select-item-indicator", className),
146
+ ...rest
147
147
  }
148
- `;
149
- var StyledItemText = (0, import_styled_components.default)(import_select.Select.ItemText)``;
148
+ ));
149
+ StyledItemIndicator.displayName = "StyledItemIndicator";
150
+ var StyledItemText = import_select.Select.ItemText;
150
151
  function CheckIcon() {
151
152
  return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_seeds_react_icon.Icon, { name: "check-outline", fixedWidth: true, "aria-hidden": true });
152
153
  }
@@ -217,173 +218,148 @@ function groupItems(data, groupBy) {
217
218
  }
218
219
 
219
220
  // src/v3/Common/SelectStyles.tsx
221
+ var React3 = __toESM(require("react"));
220
222
  var import_select2 = require("@base-ui/react/select");
221
- var import_styled_components3 = __toESM(require("styled-components"));
222
- var import_seeds_react_mixins = require("@sproutsocial/seeds-react-mixins");
223
-
224
- // src/v3/Common/SelectIcons.tsx
225
- var React3 = require("react");
226
- var import_styled_components2 = __toESM(require("styled-components"));
227
- var import_seeds_react_icon2 = require("@sproutsocial/seeds-react-icon");
228
223
  var import_jsx_runtime2 = require("react/jsx-runtime");
229
- var StyledChevron = import_styled_components2.default.div`
230
- display: flex;
231
- align-items: center;
232
- transition: transform 0.15s;
233
- ${({ $isOpen }) => $isOpen && "transform: rotate(-180deg);"}
234
- `;
235
- function ChevronIcon() {
236
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_seeds_react_icon2.Icon, { name: "chevron-down-outline", fixedWidth: true, "aria-hidden": true });
237
- }
238
- function ClearIcon() {
239
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_seeds_react_icon2.Icon, { name: "circle-x-outline", fixedWidth: true, "aria-hidden": true, size: "mini" });
240
- }
241
- function CheckIcon2() {
242
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_seeds_react_icon2.Icon, { name: "check-outline", fixedWidth: true, "aria-hidden": true });
243
- }
244
-
245
- // src/v3/Common/SelectStyles.tsx
246
- var invalidStyles = import_styled_components3.css`
247
- border-color: ${({ theme }) => theme.colors.form.border.error};
248
-
249
- ${StyledChevron} {
250
- color: ${({ theme }) => theme.colors.icon.error};
251
- }
252
- `;
253
- var Field = import_styled_components3.default.div`
254
- display: ${({ $fullWidth }) => $fullWidth === false ? "inline-flex" : "flex"};
255
- flex-direction: column;
256
- gap: ${({ theme }) => theme.space[200]};
257
- ${({ $fullWidth }) => $fullWidth !== false && "width: 100%;"}
258
- `;
259
- var SelectLabel = (0, import_styled_components3.default)(import_select2.Select.Label)`
260
- font-size: ${({ theme }) => theme.typography[200].fontSize};
261
- font-weight: ${({ theme }) => theme.fontWeights.semibold};
262
- color: ${({ theme }) => theme.colors.text.body};
263
- `;
264
- var SelectTrigger = (0, import_styled_components3.default)(import_select2.Select.Trigger)`
265
- display: flex;
266
- align-items: center;
267
- justify-content: space-between;
268
- gap: ${({ theme }) => theme.space[300]};
269
- padding: ${({ theme }) => `${theme.space[300]}`};
270
- min-width: 160px;
271
- border-radius: ${({ theme }) => theme.radii[500]};
272
- border: 1px solid ${({ theme }) => theme.colors.form.border.base};
273
- background: ${({ theme }) => theme.colors.form.background.base};
274
- font-size: ${({ theme }) => theme.typography[200].fontSize};
275
- color: ${({ theme }) => theme.colors.text.body};
276
- cursor: default;
277
- outline: none;
278
- transition: border-color ${({ theme }) => theme.duration.fast}
279
- ${({ theme }) => theme.easing.ease_in},
280
- box-shadow ${({ theme }) => theme.duration.fast}
281
- ${({ theme }) => theme.easing.ease_in};
282
-
283
- &:focus-visible {
284
- ${import_seeds_react_mixins.focusRing}
224
+ var Field = React3.forwardRef(
225
+ ({ $fullWidth, className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
226
+ "div",
227
+ {
228
+ ref,
229
+ className: cn(
230
+ "seeds-menu-field",
231
+ { "seeds-menu-field--inline": $fullWidth === false },
232
+ className
233
+ ),
234
+ ...rest
235
+ }
236
+ )
237
+ );
238
+ Field.displayName = "Field";
239
+ var SelectLabel = React3.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
240
+ import_select2.Select.Label,
241
+ {
242
+ ref,
243
+ className: cn("seeds-menu-label", className),
244
+ ...rest
285
245
  }
286
-
287
- &[data-popup-open] {
288
- ${import_seeds_react_mixins.focusRing}
246
+ ));
247
+ SelectLabel.displayName = "SelectLabel";
248
+ var SelectTrigger = React3.forwardRef(({ $isInvalid, className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
249
+ import_select2.Select.Trigger,
250
+ {
251
+ ref,
252
+ className: cn(
253
+ "seeds-select-trigger",
254
+ { "seeds-select-trigger--invalid": !!$isInvalid },
255
+ className
256
+ ),
257
+ ...rest
289
258
  }
290
-
291
- &[data-popup-open] [data-chevron] {
292
- transform: rotate(-180deg);
259
+ ));
260
+ SelectTrigger.displayName = "SelectTrigger";
261
+ var SelectValue = React3.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
262
+ import_select2.Select.Value,
263
+ {
264
+ ref,
265
+ className: cn("seeds-select-value", className),
266
+ ...rest
293
267
  }
294
-
295
- &[data-disabled] {
296
- opacity: 0.4;
297
- cursor: not-allowed;
268
+ ));
269
+ SelectValue.displayName = "SelectValue";
270
+ var SelectIcon = React3.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
271
+ import_select2.Select.Icon,
272
+ {
273
+ ref,
274
+ className: cn("seeds-select-icon", className),
275
+ ...rest
298
276
  }
299
-
300
- ${({ $isInvalid }) => $isInvalid && invalidStyles}
301
- `;
302
- var SelectValue = (0, import_styled_components3.default)(import_select2.Select.Value)`
303
- min-width: 0;
304
- overflow: hidden;
305
- `;
306
- var SelectIcon = (0, import_styled_components3.default)(import_select2.Select.Icon)`
307
- display: flex;
308
- align-items: center;
309
- color: ${({ theme }) => theme.colors.icon.base};
310
- flex-shrink: 0;
311
- `;
312
- var SelectGroup = (0, import_styled_components3.default)(import_select2.Select.Group)`
313
- display: block;
314
- `;
315
- var SelectGroupLabel = (0, import_styled_components3.default)(import_select2.Select.GroupLabel)`
316
- padding: ${({ theme }) => `${theme.space[300]} ${theme.space[300]} ${theme.space[200]}`};
317
- font-size: ${({ theme }) => theme.typography[100].fontSize};
318
- font-weight: ${({ theme }) => theme.fontWeights.semibold};
319
- text-transform: uppercase;
320
- letter-spacing: 0.05em;
321
- color: ${({ theme }) => theme.colors.text.subtext};
322
- `;
323
- var SelectSeparator = (0, import_styled_components3.default)(import_select2.Select.Separator)`
324
- height: 1px;
325
- margin: ${({ theme }) => `${theme.space[200]} ${theme.space[300]}`};
326
- background: ${({ theme }) => theme.colors.container.border.base};
327
- `;
328
- var SelectPositioner = (0, import_styled_components3.default)(import_select2.Select.Positioner)`
329
- width: var(--anchor-width);
330
- z-index: 7;
331
- `;
332
- var SelectPopup = (0, import_styled_components3.default)(import_select2.Select.Popup)`
333
- font-family: ${({ theme }) => theme.fontFamily};
334
- background: ${({ theme }) => theme.colors.container.background.base};
335
- border: 1px solid ${({ theme }) => theme.colors.container.border.base};
336
- border-radius: ${({ theme }) => theme.radii[500]};
337
- box-shadow: ${({ theme }) => theme.shadows.low};
338
- outline: none;
339
- max-height: min(var(--available-height, 400px), 400px);
340
- overflow-y: auto;
341
- padding: ${({ theme }) => theme.space[200]};
342
-
343
- &[data-open] {
344
- animation: select-popup-in 120ms ease-out;
277
+ ));
278
+ SelectIcon.displayName = "SelectIcon";
279
+ var SelectGroup = React3.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
280
+ import_select2.Select.Group,
281
+ {
282
+ ref,
283
+ className: cn("seeds-select-group", className),
284
+ ...rest
345
285
  }
346
-
347
- &[data-closed] {
348
- animation: select-popup-out 100ms ease-in;
286
+ ));
287
+ SelectGroup.displayName = "SelectGroup";
288
+ var SelectGroupLabel = React3.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
289
+ import_select2.Select.GroupLabel,
290
+ {
291
+ ref,
292
+ className: cn("seeds-select-group-label", className),
293
+ ...rest
349
294
  }
350
-
351
- @keyframes select-popup-in {
352
- from {
353
- opacity: 0;
354
- transform: scale(0.95);
355
- }
356
- to {
357
- opacity: 1;
358
- transform: scale(1);
359
- }
295
+ ));
296
+ SelectGroupLabel.displayName = "SelectGroupLabel";
297
+ var SelectSeparator = React3.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
298
+ import_select2.Select.Separator,
299
+ {
300
+ ref,
301
+ className: cn("seeds-select-separator", className),
302
+ ...rest
360
303
  }
361
-
362
- @keyframes select-popup-out {
363
- from {
364
- opacity: 1;
365
- transform: scale(1);
366
- }
367
- to {
368
- opacity: 0;
369
- transform: scale(0.95);
370
- }
304
+ ));
305
+ SelectSeparator.displayName = "SelectSeparator";
306
+ var SelectPositioner = React3.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
307
+ import_select2.Select.Positioner,
308
+ {
309
+ ref,
310
+ className: cn("seeds-select-positioner", className),
311
+ ...rest
371
312
  }
372
- `;
313
+ ));
314
+ SelectPositioner.displayName = "SelectPositioner";
315
+ var SelectPopup = React3.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
316
+ import_select2.Select.Popup,
317
+ {
318
+ ref,
319
+ className: cn("seeds-select-popup", className),
320
+ ...rest
321
+ }
322
+ ));
323
+ SelectPopup.displayName = "SelectPopup";
373
324
 
374
- // src/v3/SingleSelect.tsx
325
+ // src/v3/Common/SelectIcons.tsx
326
+ var React4 = __toESM(require("react"));
327
+ var import_seeds_react_icon2 = require("@sproutsocial/seeds-react-icon");
375
328
  var import_jsx_runtime3 = require("react/jsx-runtime");
376
- var StyledValue = (0, import_styled_components4.default)(import_select3.Select.Value)`
377
- flex: 1;
378
- text-align: left;
379
- overflow: hidden;
380
- text-overflow: ellipsis;
381
- white-space: nowrap;
329
+ var StyledChevron = React4.forwardRef(({ $isOpen, className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
330
+ "div",
331
+ {
332
+ ref,
333
+ className: cn(
334
+ "seeds-menu-chevron",
335
+ { "seeds-menu-chevron--open": !!$isOpen },
336
+ className
337
+ ),
338
+ ...rest
339
+ }
340
+ ));
341
+ StyledChevron.displayName = "StyledChevron";
342
+ function ChevronIcon() {
343
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_seeds_react_icon2.Icon, { name: "chevron-down-outline", fixedWidth: true, "aria-hidden": true });
344
+ }
345
+ function ClearIcon() {
346
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_seeds_react_icon2.Icon, { name: "circle-x-outline", fixedWidth: true, "aria-hidden": true, size: "mini" });
347
+ }
348
+ function CheckIcon2() {
349
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_seeds_react_icon2.Icon, { name: "check-outline", fixedWidth: true, "aria-hidden": true });
350
+ }
382
351
 
383
- &[data-placeholder] {
384
- color: ${({ theme }) => theme.colors.text.subtext};
352
+ // src/v3/SingleSelect.tsx
353
+ var import_jsx_runtime4 = require("react/jsx-runtime");
354
+ var StyledValue = React5.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
355
+ import_select3.Select.Value,
356
+ {
357
+ ref,
358
+ className: cn("seeds-select-value-text", className),
359
+ ...rest
385
360
  }
386
- `;
361
+ ));
362
+ StyledValue.displayName = "StyledValue";
387
363
  function SingleSelect(props) {
388
364
  const { id, placeholder, includePlaceholderItem, fullWidth = true } = props;
389
365
  const ariaDescribedBy = props["aria-describedby"];
@@ -403,7 +379,7 @@ function SingleSelect(props) {
403
379
  const renderGroupHeading = isChildrenMode ? void 0 : props.renderGroupHeading;
404
380
  const children = isChildrenMode ? props.children : void 0;
405
381
  const { containerRef, portalContainer } = useSeedsPortalContainer();
406
- const items = React4.useMemo(() => {
382
+ const items = React5.useMemo(() => {
407
383
  const dataItems = data.map((item) => ({
408
384
  value: String(item.id),
409
385
  label: itemToString(item)
@@ -415,11 +391,11 @@ function SingleSelect(props) {
415
391
  }, [data, itemToString, includePlaceholderItem, placeholder]);
416
392
  const dataWithPlaceholder = includePlaceholderItem ? [{ id: null, value: null, label: placeholder ?? "" }, ...data] : data;
417
393
  const isControlled = selectedItemId !== void 0;
418
- const [internalValue, setInternalValue] = React4.useState(
394
+ const [internalValue, setInternalValue] = React5.useState(
419
395
  defaultSelectedItemId != null ? String(defaultSelectedItemId) : null
420
396
  );
421
397
  const value = isControlled ? selectedItemId != null ? String(selectedItemId) : null : internalValue;
422
- const selectedItem = React4.useMemo(
398
+ const selectedItem = React5.useMemo(
423
399
  () => value != null ? data.find((d) => String(d.id) === value) ?? null : null,
424
400
  [data, value]
425
401
  );
@@ -436,9 +412,9 @@ function SingleSelect(props) {
436
412
  }
437
413
  }
438
414
  }
439
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(Field, { $fullWidth: fullWidth, children: [
440
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { ref: containerRef, style: { position: "relative" } }),
441
- /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
415
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Field, { $fullWidth: fullWidth, children: [
416
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { ref: containerRef, style: { position: "relative" } }),
417
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
442
418
  import_select3.Select.Root,
443
419
  {
444
420
  items,
@@ -447,7 +423,7 @@ function SingleSelect(props) {
447
423
  onValueChange: handleValueChange,
448
424
  id,
449
425
  children: [
450
- /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
426
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
451
427
  SelectTrigger,
452
428
  {
453
429
  "aria-describedby": ariaDescribedBy,
@@ -455,22 +431,22 @@ function SingleSelect(props) {
455
431
  "aria-required": props.required || void 0,
456
432
  $isInvalid: isInvalid,
457
433
  children: [
458
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(StyledValue, { placeholder, children: renderSelection && selectedItem ? renderSelection(selectedItem) : void 0 }),
459
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(SelectIcon, { children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(StyledChevron, { "data-chevron": true, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(ChevronIcon, {}) }) })
434
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(StyledValue, { placeholder, children: renderSelection && selectedItem ? renderSelection(selectedItem) : void 0 }),
435
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(SelectIcon, { children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(StyledChevron, { "data-chevron": true, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(ChevronIcon, {}) }) })
460
436
  ]
461
437
  }
462
438
  ),
463
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_select3.Select.Portal, { container: portalContainer, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(SelectPositioner, { sideOffset: 8, alignItemWithTrigger: false, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(SelectPopup, { children: [
464
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_select3.Select.ScrollUpArrow, {}),
465
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
439
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_select3.Select.Portal, { container: portalContainer, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(SelectPositioner, { sideOffset: 8, alignItemWithTrigger: false, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(SelectPopup, { children: [
440
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_select3.Select.ScrollUpArrow, {}),
441
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
466
442
  import_select3.Select.List,
467
443
  {
468
444
  "aria-label": ariaLabel,
469
445
  "aria-labelledby": ariaLabelledBy,
470
- children: children ? children : groupBy ? groupItems(data, groupBy).map((group, index, arr) => /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(React4.Fragment, { children: [
471
- /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(SelectGroup, { children: [
472
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(SelectGroupLabel, { children: renderGroupHeading ? renderGroupHeading(group.value) : group.value }),
473
- group.items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
446
+ children: children ? children : groupBy ? groupItems(data, groupBy).map((group, index, arr) => /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(React5.Fragment, { children: [
447
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(SelectGroup, { children: [
448
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(SelectGroupLabel, { children: renderGroupHeading ? renderGroupHeading(group.value) : group.value }),
449
+ group.items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
474
450
  SelectItem,
475
451
  {
476
452
  value: String(item.id),
@@ -482,9 +458,9 @@ function SingleSelect(props) {
482
458
  item.id
483
459
  ))
484
460
  ] }),
485
- index < arr.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(SelectSeparator, {})
486
- ] }, group.value)) : /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(import_jsx_runtime3.Fragment, { children: [
487
- includePlaceholderItem && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
461
+ index < arr.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(SelectSeparator, {})
462
+ ] }, group.value)) : /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(import_jsx_runtime4.Fragment, { children: [
463
+ includePlaceholderItem && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
488
464
  SelectItem,
489
465
  {
490
466
  value: null,
@@ -492,7 +468,7 @@ function SingleSelect(props) {
492
468
  },
493
469
  "placeholder"
494
470
  ),
495
- data.map((item) => /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
471
+ data.map((item) => /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
496
472
  SelectItem,
497
473
  {
498
474
  value: String(item.id),
@@ -506,7 +482,7 @@ function SingleSelect(props) {
506
482
  ] })
507
483
  }
508
484
  ),
509
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_select3.Select.ScrollDownArrow, {})
485
+ /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_select3.Select.ScrollDownArrow, {})
510
486
  ] }) }) })
511
487
  ]
512
488
  }
@@ -515,24 +491,14 @@ function SingleSelect(props) {
515
491
  }
516
492
 
517
493
  // src/v3/MultiSelect.tsx
518
- var React5 = __toESM(require("react"));
494
+ var React6 = __toESM(require("react"));
519
495
  var import_select4 = require("@base-ui/react/select");
520
- var import_styled_components5 = __toESM(require("styled-components"));
521
- var import_jsx_runtime4 = require("react/jsx-runtime");
522
- var SelectionText = import_styled_components5.default.span`
523
- flex: 1;
524
- overflow: hidden;
525
- text-overflow: ellipsis;
526
- white-space: nowrap;
527
- `;
528
- var Placeholder = import_styled_components5.default.div`
529
- color: ${({ theme }) => theme.colors.text.subtext};
530
- font-size: ${({ theme }) => theme.typography[200].fontSize};
531
- line-height: 16px;
532
- padding-top: 2px;
533
- padding-bottom: 2px;
534
- margin: 2px 8px 0px 0px;
535
- `;
496
+ var import_jsx_runtime5 = require("react/jsx-runtime");
497
+ var SelectionText = ({
498
+ className,
499
+ ...rest
500
+ }) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: cn("seeds-select-selection-text", className), ...rest });
501
+ var Placeholder = ({ className, ...rest }) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { className: cn("seeds-select-placeholder", className), ...rest });
536
502
  function MultiSelect(props) {
537
503
  const { id, placeholder = "Select...", fullWidth = true } = props;
538
504
  const ariaDescribedBy = props["aria-describedby"];
@@ -556,18 +522,18 @@ function MultiSelect(props) {
556
522
  const children = isChildrenMode ? props.children : void 0;
557
523
  const { containerRef, portalContainer } = useSeedsPortalContainer();
558
524
  const isControlled = selectedItemIds !== void 0;
559
- const [internalValue, setInternalValue] = React5.useState(
525
+ const [internalValue, setInternalValue] = React6.useState(
560
526
  () => defaultSelectedItemIds?.map(String) ?? []
561
527
  );
562
528
  const value = isControlled ? selectedItemIds.map(String) : internalValue;
563
- const items = React5.useMemo(
529
+ const items = React6.useMemo(
564
530
  () => data.map((item) => ({
565
531
  value: String(item.id),
566
532
  label: itemToString(item)
567
533
  })),
568
534
  [data, itemToString]
569
535
  );
570
- const selectedItems = React5.useMemo(
536
+ const selectedItems = React6.useMemo(
571
537
  () => value.map((v) => data.find((d) => String(d.id) === v)).filter((d) => d != null),
572
538
  [data, value]
573
539
  );
@@ -583,9 +549,9 @@ function MultiSelect(props) {
583
549
  onSelectedItemIdsChange(ids);
584
550
  }
585
551
  }
586
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(Field, { $fullWidth: fullWidth, children: [
587
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)("div", { ref: containerRef, style: { position: "relative" } }),
588
- /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
552
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(Field, { $fullWidth: fullWidth, children: [
553
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { ref: containerRef, style: { position: "relative" } }),
554
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
589
555
  import_select4.Select.Root,
590
556
  {
591
557
  multiple: true,
@@ -595,7 +561,7 @@ function MultiSelect(props) {
595
561
  disabled: props.disabled,
596
562
  id,
597
563
  children: [
598
- /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
564
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(
599
565
  SelectTrigger,
600
566
  {
601
567
  "aria-describedby": ariaDescribedBy,
@@ -603,35 +569,35 @@ function MultiSelect(props) {
603
569
  "aria-required": props.required || void 0,
604
570
  $isInvalid: isInvalid,
605
571
  children: [
606
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(SelectValue, { children: () => {
572
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(SelectValue, { children: () => {
607
573
  if (renderSelection) return renderSelection(selectedItems);
608
574
  if (selectedItems.length === 0)
609
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Placeholder, { children: placeholder });
575
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(Placeholder, { children: placeholder });
610
576
  const visibleItems = maxSelections != null ? selectedItems.slice(0, maxSelections) : selectedItems;
611
577
  const overflowCount = maxSelections != null && selectedItems.length > maxSelections ? selectedItems.length - maxSelections : 0;
612
578
  const text = visibleItems.map(
613
579
  (item) => customRenderSelections ? customRenderSelections(item) : itemToString(item)
614
580
  ).join(", ");
615
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(SelectionText, { children: [
581
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(SelectionText, { children: [
616
582
  text,
617
583
  overflowCount > 0 ? `, +${overflowCount}` : ""
618
584
  ] });
619
585
  } }),
620
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(SelectIcon, { children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(StyledChevron, { "data-chevron": true, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(ChevronIcon, {}) }) })
586
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(SelectIcon, { children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(StyledChevron, { "data-chevron": true, children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(ChevronIcon, {}) }) })
621
587
  ]
622
588
  }
623
589
  ),
624
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_select4.Select.Portal, { container: portalContainer, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(SelectPositioner, { sideOffset: 8, alignItemWithTrigger: false, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(SelectPopup, { children: [
625
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_select4.Select.ScrollUpArrow, {}),
626
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
590
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_select4.Select.Portal, { container: portalContainer, children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(SelectPositioner, { sideOffset: 8, alignItemWithTrigger: false, children: /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(SelectPopup, { children: [
591
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_select4.Select.ScrollUpArrow, {}),
592
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
627
593
  import_select4.Select.List,
628
594
  {
629
595
  "aria-label": ariaLabel,
630
596
  "aria-labelledby": ariaLabelledBy,
631
- children: children ? children : groupBy ? groupItems(data, groupBy).map((group, index, arr) => /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(React5.Fragment, { children: [
632
- /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(SelectGroup, { children: [
633
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(SelectGroupLabel, { children: renderGroupHeading ? renderGroupHeading(group.value) : group.value }),
634
- group.items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
597
+ children: children ? children : groupBy ? groupItems(data, groupBy).map((group, index, arr) => /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(React6.Fragment, { children: [
598
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsxs)(SelectGroup, { children: [
599
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(SelectGroupLabel, { children: renderGroupHeading ? renderGroupHeading(group.value) : group.value }),
600
+ group.items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
635
601
  SelectItem,
636
602
  {
637
603
  value: String(item.id),
@@ -644,8 +610,8 @@ function MultiSelect(props) {
644
610
  item.id
645
611
  ))
646
612
  ] }),
647
- index < arr.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(SelectSeparator, {})
648
- ] }, group.value)) : data.map((item) => /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
613
+ index < arr.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(SelectSeparator, {})
614
+ ] }, group.value)) : data.map((item) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
649
615
  SelectItem,
650
616
  {
651
617
  value: String(item.id),
@@ -659,7 +625,7 @@ function MultiSelect(props) {
659
625
  ))
660
626
  }
661
627
  ),
662
- /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_select4.Select.ScrollDownArrow, {})
628
+ /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_select4.Select.ScrollDownArrow, {})
663
629
  ] }) }) })
664
630
  ]
665
631
  }
@@ -668,14 +634,14 @@ function MultiSelect(props) {
668
634
  }
669
635
 
670
636
  // src/v3/SingleCombobox.tsx
671
- var React9 = __toESM(require("react"));
637
+ var React11 = __toESM(require("react"));
672
638
  var import_combobox3 = require("@base-ui/react/combobox");
673
639
  var import_react_virtual2 = require("@tanstack/react-virtual");
674
640
 
675
641
  // src/v3/Common/useSuppressEscapeClear.ts
676
- var React6 = __toESM(require("react"));
642
+ var React7 = __toESM(require("react"));
677
643
  function useSuppressEscapeClear(open) {
678
- return React6.useCallback(
644
+ return React7.useCallback(
679
645
  (event) => {
680
646
  if (event.key === "Escape" && !open) {
681
647
  event.stopPropagation();
@@ -686,309 +652,189 @@ function useSuppressEscapeClear(open) {
686
652
  }
687
653
 
688
654
  // src/v3/Common/ComboboxItem.tsx
689
- var React7 = __toESM(require("react"));
655
+ var React9 = __toESM(require("react"));
690
656
  var import_seeds_react_radio2 = __toESM(require("@sproutsocial/seeds-react-radio"));
691
657
  var import_seeds_react_checkbox3 = __toESM(require("@sproutsocial/seeds-react-checkbox"));
692
658
 
693
659
  // src/v3/Common/ComboboxStyles.tsx
660
+ var React8 = __toESM(require("react"));
694
661
  var import_combobox = require("@base-ui/react/combobox");
695
- var import_styled_components6 = __toESM(require("styled-components"));
696
- var import_seeds_react_mixins2 = require("@sproutsocial/seeds-react-mixins");
697
662
  var import_seeds_react_checkbox2 = __toESM(require("@sproutsocial/seeds-react-checkbox"));
698
- var import_jsx_runtime5 = require("react/jsx-runtime");
699
- var invalidStyles2 = import_styled_components6.css`
700
- border-color: ${({ theme }) => theme.colors.form.border.error};
701
-
702
- ${StyledChevron} {
703
- color: ${({ theme }) => theme.colors.icon.error};
704
- }
705
- `;
706
- var ComboboxLabel = import_styled_components6.default.label`
707
- font-size: ${({ theme }) => theme.typography[200].fontSize};
708
- font-weight: ${({ theme }) => theme.fontWeights.semibold};
709
- color: ${({ theme }) => theme.colors.text.body};
710
- `;
711
- var ComboboxInputGroup = (0, import_styled_components6.default)(import_combobox.Combobox.InputGroup)`
712
- display: flex;
713
- align-items: center;
714
- min-width: 160px;
715
- border-radius: ${({ theme }) => theme.radii[500]};
716
- border: 1px solid ${({ theme }) => theme.colors.form.border.base};
717
- background: ${({ theme }) => theme.colors.form.background.base};
718
- color: ${({ theme }) => theme.colors.text.body};
719
- transition: border-color ${({ theme }) => theme.duration.fast}
720
- ${({ theme }) => theme.easing.ease_in},
721
- box-shadow ${({ theme }) => theme.duration.fast}
722
- ${({ theme }) => theme.easing.ease_in};
723
-
724
- &:focus-within {
725
- ${import_seeds_react_mixins2.focusRing}
663
+ var import_jsx_runtime6 = require("react/jsx-runtime");
664
+ var ComboboxLabel = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("label", { ref, className: cn("seeds-menu-label", className), ...rest }));
665
+ ComboboxLabel.displayName = "ComboboxLabel";
666
+ var ComboboxInputGroup = React8.forwardRef(({ $isInvalid, className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
667
+ import_combobox.Combobox.InputGroup,
668
+ {
669
+ ref,
670
+ className: cn(
671
+ "seeds-combobox-input-group",
672
+ { "seeds-combobox-input-group--invalid": !!$isInvalid },
673
+ className
674
+ ),
675
+ ...rest
726
676
  }
727
-
728
- &[data-disabled] {
729
- opacity: 0.4;
730
- cursor: not-allowed;
677
+ ));
678
+ ComboboxInputGroup.displayName = "ComboboxInputGroup";
679
+ var ComboboxInput = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
680
+ import_combobox.Combobox.Input,
681
+ {
682
+ ref,
683
+ className: cn("seeds-combobox-input", className),
684
+ ...rest
731
685
  }
732
-
733
- ${({ $isInvalid }) => $isInvalid && invalidStyles2}
734
- `;
735
- var ComboboxInput = (0, import_styled_components6.default)(import_combobox.Combobox.Input)`
736
- flex: 1;
737
- min-width: 30px;
738
- padding: ${({ theme }) => theme.space[300]};
739
- border: none !important;
740
- background: transparent;
741
- font-size: ${({ theme }) => theme.typography[200].fontSize};
742
- line-height: ${({ theme }) => theme.typography[200].lineHeight};
743
- color: ${({ theme }) => theme.colors.text.body};
744
- outline: none;
745
-
746
- &::placeholder {
747
- color: ${({ theme }) => theme.colors.text.subtext};
686
+ ));
687
+ ComboboxInput.displayName = "ComboboxInput";
688
+ var ComboboxTokenInput = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
689
+ import_combobox.Combobox.Input,
690
+ {
691
+ ref,
692
+ className: cn("seeds-combobox-token-input", className),
693
+ ...rest
748
694
  }
749
-
750
- &:disabled {
751
- cursor: not-allowed;
752
- }
753
- `;
754
- var ComboboxTokenInput = (0, import_styled_components6.default)(import_combobox.Combobox.Input)`
755
- flex: 1;
756
- min-width: 60px;
757
- padding: ${({ theme }) => theme.space[200]} ${({ theme }) => theme.space[300]}
758
- ${({ theme }) => theme.space[200]} ${({ theme }) => theme.space[350]};
759
- border: none !important;
760
- background: transparent;
761
- font-size: ${({ theme }) => theme.typography[200].fontSize};
762
- line-height: ${({ theme }) => theme.typography[200].lineHeight};
763
- color: ${({ theme }) => theme.colors.text.body};
764
- outline: none;
765
-
766
- &::placeholder {
767
- color: ${({ theme }) => theme.colors.text.subtext};
695
+ ));
696
+ ComboboxTokenInput.displayName = "ComboboxTokenInput";
697
+ var ComboboxActionButtons = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
698
+ "div",
699
+ {
700
+ ref,
701
+ className: cn("seeds-combobox-action-buttons", className),
702
+ ...rest
768
703
  }
769
-
770
- &:disabled {
771
- cursor: not-allowed;
772
- }
773
- `;
774
- var ComboboxActionButtons = import_styled_components6.default.div`
775
- display: flex;
776
- align-items: center;
777
- flex-shrink: 0;
778
- margin-left: auto;
779
- gap: ${({ theme }) => theme.space[100]};
780
- `;
781
- var ComboboxClear = (0, import_styled_components6.default)(import_combobox.Combobox.Clear).attrs({ tabIndex: 0 })`
782
- display: flex;
783
- align-items: center;
784
- justify-content: center;
785
- width: 20px;
786
- height: 20px;
787
- border: none;
788
- background: transparent;
789
- color: ${({ theme }) => theme.colors.icon.base};
790
- cursor: pointer;
791
- border-radius: ${({ theme }) => theme.radii[300]};
792
- padding: 0;
793
-
794
- &:hover {
795
- color: ${({ theme }) => theme.colors.text.body};
704
+ ));
705
+ ComboboxActionButtons.displayName = "ComboboxActionButtons";
706
+ var ComboboxClear = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
707
+ import_combobox.Combobox.Clear,
708
+ {
709
+ ref,
710
+ tabIndex: 0,
711
+ className: cn("seeds-combobox-clear", className),
712
+ ...rest
796
713
  }
797
-
798
- &:focus-visible {
799
- ${import_seeds_react_mixins2.focusRing}
714
+ ));
715
+ ComboboxClear.displayName = "ComboboxClear";
716
+ var ComboboxTrigger = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
717
+ import_combobox.Combobox.Trigger,
718
+ {
719
+ ref,
720
+ className: cn("seeds-combobox-trigger", className),
721
+ ...rest
800
722
  }
801
-
802
- &[data-empty] {
803
- display: none;
804
- }
805
- `;
806
- var ComboboxTrigger = (0, import_styled_components6.default)(import_combobox.Combobox.Trigger)`
807
- display: flex;
808
- align-items: center;
809
- justify-content: center;
810
- width: 20px;
811
- height: 20px;
812
- border: none;
813
- background: transparent;
814
- color: ${({ theme }) => theme.colors.icon.base};
815
- cursor: default;
816
- padding: 0;
817
-
818
- &:hover {
819
- color: ${({ theme }) => theme.colors.text.body};
820
- }
821
- `;
822
- var ComboboxPositioner = (0, import_styled_components6.default)(import_combobox.Combobox.Positioner)`
823
- width: var(--anchor-width);
824
- z-index: 7;
825
- `;
826
- var ComboboxPopup = (0, import_styled_components6.default)(import_combobox.Combobox.Popup)`
827
- font-family: ${({ theme }) => theme.fontFamily};
828
- background: ${({ theme }) => theme.colors.container.background.base};
829
- border: 1px solid ${({ theme }) => theme.colors.container.border.base};
830
- border-radius: ${({ theme }) => theme.radii[500]};
831
- box-shadow: ${({ theme }) => theme.shadows.medium};
832
- outline: none;
833
- width: 100%;
834
- max-height: min(var(--available-height, 400px), 400px);
835
- overflow-y: auto;
836
- padding: 0;
837
-
838
- &[data-open] {
839
- animation: combobox-popup-in 120ms ease-out;
723
+ ));
724
+ ComboboxTrigger.displayName = "ComboboxTrigger";
725
+ var ComboboxPositioner = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
726
+ import_combobox.Combobox.Positioner,
727
+ {
728
+ ref,
729
+ className: cn("seeds-combobox-positioner", className),
730
+ ...rest
840
731
  }
841
-
842
- &[data-closed] {
843
- animation: combobox-popup-out 100ms ease-in;
732
+ ));
733
+ ComboboxPositioner.displayName = "ComboboxPositioner";
734
+ var ComboboxPopup = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
735
+ import_combobox.Combobox.Popup,
736
+ {
737
+ ref,
738
+ className: cn("seeds-combobox-popup", className),
739
+ ...rest
844
740
  }
845
-
846
- @keyframes combobox-popup-in {
847
- from {
848
- opacity: 0;
849
- transform: scale(0.95);
850
- }
851
- to {
852
- opacity: 1;
853
- transform: scale(1);
854
- }
741
+ ));
742
+ ComboboxPopup.displayName = "ComboboxPopup";
743
+ var ComboboxList = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
744
+ import_combobox.Combobox.List,
745
+ {
746
+ ref,
747
+ className: cn("seeds-combobox-list", className),
748
+ ...rest
855
749
  }
856
-
857
- @keyframes combobox-popup-out {
858
- from {
859
- opacity: 1;
860
- transform: scale(1);
861
- }
862
- to {
863
- opacity: 0;
864
- transform: scale(0.95);
865
- }
750
+ ));
751
+ ComboboxList.displayName = "ComboboxList";
752
+ var ComboboxStatus = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
753
+ import_combobox.Combobox.Status,
754
+ {
755
+ ref,
756
+ className: cn("seeds-combobox-status", className),
757
+ ...rest
866
758
  }
867
- `;
868
- var ComboboxList = (0, import_styled_components6.default)(import_combobox.Combobox.List)`
869
- padding: ${({ theme }) => theme.space[200]};
870
-
871
- &:empty {
872
- padding: 0;
873
- }
874
- `;
875
- var ComboboxStatus = (0, import_styled_components6.default)(import_combobox.Combobox.Status)`
876
- padding: ${({ theme }) => `${theme.space[300]} ${theme.space[350]}`};
877
- font-size: ${({ theme }) => theme.typography[200].fontSize};
878
- color: ${({ theme }) => theme.colors.text.subtext};
879
-
880
- &:empty {
881
- padding: 0;
882
- }
883
- `;
884
- var ComboboxEmpty = (0, import_styled_components6.default)(import_combobox.Combobox.Empty)`
885
- padding: ${({ theme }) => `${theme.space[300]} ${theme.space[350]}`};
886
- font-size: ${({ theme }) => theme.typography[200].fontSize};
887
- color: ${({ theme }) => theme.colors.text.subtext};
888
-
889
- &:empty {
890
- padding: 0;
891
- }
892
- `;
893
- var ComboboxItem = (0, import_styled_components6.default)(import_combobox.Combobox.Item)`
894
- display: flex;
895
- align-items: center;
896
- gap: ${({ theme }) => theme.space[300]};
897
- padding: ${({ theme }) => `${theme.space[300]} ${theme.space[300]}`};
898
- border-radius: ${({ theme }) => theme.radii[500]};
899
- font-size: ${({ theme }) => theme.typography[200].fontSize};
900
- color: ${({ theme }) => theme.colors.text.body};
901
- cursor: default;
902
- outline: none;
903
-
904
- &[data-highlighted] {
905
- background: ${({ theme }) => theme.colors.listItem.background.hover};
759
+ ));
760
+ ComboboxStatus.displayName = "ComboboxStatus";
761
+ var ComboboxEmpty = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
762
+ import_combobox.Combobox.Empty,
763
+ {
764
+ ref,
765
+ className: cn("seeds-combobox-empty", className),
766
+ ...rest
906
767
  }
907
-
908
- &[data-selected] {
909
- font-weight: ${({ theme }) => theme.fontWeights.semibold};
768
+ ));
769
+ ComboboxEmpty.displayName = "ComboboxEmpty";
770
+ var ComboboxItem = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
771
+ import_combobox.Combobox.Item,
772
+ {
773
+ ref,
774
+ className: cn("seeds-combobox-item", className),
775
+ ...rest
910
776
  }
911
-
912
- &[data-disabled] {
913
- opacity: 0.5;
914
- cursor: not-allowed;
915
- }
916
- `;
917
- var ComboboxItemIndicator = (0, import_styled_components6.default)(import_combobox.Combobox.ItemIndicator)`
918
- display: flex;
919
- align-items: center;
920
- width: ${({ theme }) => theme.space[400]};
921
- color: ${({ theme }) => theme.colors.text.body};
922
- visibility: hidden;
923
-
924
- &[data-selected] {
925
- visibility: visible;
926
- }
927
- `;
928
- var ComboboxGroup = (0, import_styled_components6.default)(import_combobox.Combobox.Group)`
929
- display: block;
930
- `;
931
- var ComboboxGroupLabel = (0, import_styled_components6.default)(import_combobox.Combobox.GroupLabel)`
932
- padding: ${({ theme }) => `${theme.space[300]} ${theme.space[300]} ${theme.space[200]}`};
933
- font-size: ${({ theme }) => theme.typography[100].fontSize};
934
- font-weight: ${({ theme }) => theme.fontWeights.semibold};
935
- text-transform: uppercase;
936
- letter-spacing: 0.05em;
937
- color: ${({ theme }) => theme.colors.text.subtext};
938
- `;
939
- var ComboboxSeparator = import_styled_components6.default.div`
940
- height: 1px;
941
- margin: ${({ theme }) => `${theme.space[200]} ${theme.space[300]}`};
942
- background: ${({ theme }) => theme.colors.container.border.base};
943
- `;
944
- var ComboboxGroupHeaderItem = (0, import_styled_components6.default)(import_combobox.Combobox.Item)`
945
- display: flex;
946
- align-items: center;
947
- gap: ${({ theme }) => theme.space[300]};
948
- padding: ${({ theme }) => `${theme.space[300]} ${theme.space[300]}`};
949
- border-radius: ${({ theme }) => theme.radii[500]};
950
- font-size: ${({ theme }) => theme.typography[100].fontSize};
951
- font-weight: ${({ theme }) => theme.fontWeights.semibold};
952
- text-transform: uppercase;
953
- letter-spacing: 0.05em;
954
- color: ${({ theme }) => theme.colors.text.subtext};
955
- cursor: default;
956
- outline: none;
957
-
958
- &[data-highlighted] {
959
- background: ${({ theme }) => theme.colors.listItem.background.hover};
960
- color: ${({ theme }) => theme.colors.text.body};
777
+ ));
778
+ ComboboxItem.displayName = "ComboboxItem";
779
+ var ComboboxItemIndicator = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
780
+ import_combobox.Combobox.ItemIndicator,
781
+ {
782
+ ref,
783
+ className: cn("seeds-combobox-item-indicator", className),
784
+ ...rest
961
785
  }
962
-
963
- &[data-disabled] {
964
- opacity: 0.4;
965
- cursor: not-allowed;
966
- pointer-events: none;
967
- }
968
- `;
969
- var ComboboxSelectAllItem = (0, import_styled_components6.default)(import_combobox.Combobox.Item)`
970
- display: flex;
971
- align-items: center;
972
- gap: ${({ theme }) => theme.space[300]};
973
- padding: ${({ theme }) => `${theme.space[300]} ${theme.space[300]}`};
974
- border-radius: ${({ theme }) => theme.radii[500]};
975
- font-size: ${({ theme }) => theme.typography[200].fontSize};
976
- font-weight: ${({ theme }) => theme.fontWeights.semibold};
977
- color: ${({ theme }) => theme.colors.text.body};
978
- cursor: default;
979
- outline: none;
980
- border-bottom: 1px solid ${({ theme }) => theme.colors.container.border.base};
981
- margin-bottom: ${({ theme }) => theme.space[200]};
982
-
983
- &[data-highlighted] {
984
- background: ${({ theme }) => theme.colors.listItem.background.hover};
786
+ ));
787
+ ComboboxItemIndicator.displayName = "ComboboxItemIndicator";
788
+ var ComboboxGroup = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
789
+ import_combobox.Combobox.Group,
790
+ {
791
+ ref,
792
+ className: cn("seeds-combobox-group", className),
793
+ ...rest
794
+ }
795
+ ));
796
+ ComboboxGroup.displayName = "ComboboxGroup";
797
+ var ComboboxGroupLabel = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
798
+ import_combobox.Combobox.GroupLabel,
799
+ {
800
+ ref,
801
+ className: cn("seeds-combobox-group-label", className),
802
+ ...rest
985
803
  }
986
- `;
804
+ ));
805
+ ComboboxGroupLabel.displayName = "ComboboxGroupLabel";
806
+ var ComboboxSeparator = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
807
+ "div",
808
+ {
809
+ ref,
810
+ className: cn("seeds-combobox-separator", className),
811
+ ...rest
812
+ }
813
+ ));
814
+ ComboboxSeparator.displayName = "ComboboxSeparator";
815
+ var ComboboxGroupHeaderItem = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
816
+ import_combobox.Combobox.Item,
817
+ {
818
+ ref,
819
+ className: cn("seeds-combobox-group-header-item", className),
820
+ ...rest
821
+ }
822
+ ));
823
+ ComboboxGroupHeaderItem.displayName = "ComboboxGroupHeaderItem";
824
+ var ComboboxSelectAllItem = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
825
+ import_combobox.Combobox.Item,
826
+ {
827
+ ref,
828
+ className: cn("seeds-combobox-select-all-item", className),
829
+ ...rest
830
+ }
831
+ ));
832
+ ComboboxSelectAllItem.displayName = "ComboboxSelectAllItem";
987
833
  function ComboboxGroupHeaderCheckbox({
988
834
  $state,
989
835
  id
990
836
  }) {
991
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
837
+ return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
992
838
  import_seeds_react_checkbox2.default,
993
839
  {
994
840
  id,
@@ -1000,196 +846,114 @@ function ComboboxGroupHeaderCheckbox({
1000
846
  }
1001
847
  );
1002
848
  }
1003
- var ComboboxToken = (0, import_styled_components6.default)(import_combobox.Combobox.Chips)`
1004
- display: flex;
1005
- width: 100%;
1006
- flex-wrap: wrap;
1007
- gap: ${({ theme }) => theme.space[200]};
1008
- `;
1009
- var ComboboxTokenInputGroup = (0, import_styled_components6.default)(import_combobox.Combobox.InputGroup)`
1010
- display: flex;
1011
- align-items: center;
1012
- flex-wrap: wrap;
1013
- border-radius: ${({ theme }) => theme.radii[500]};
1014
- border: 1px solid ${({ theme }) => theme.colors.form.border.base};
1015
- background: ${({ theme }) => theme.colors.form.background.base};
1016
- color: ${({ theme }) => theme.colors.text.body};
1017
- padding: ${({ theme }) => `${theme.space[200]} ${theme.space[300]} ${theme.space[200]} ${theme.space[200]}`};
1018
- gap: ${({ theme }) => theme.space[200]};
1019
- transition: border-color ${({ theme }) => theme.duration.fast}
1020
- ${({ theme }) => theme.easing.ease_in},
1021
- box-shadow ${({ theme }) => theme.duration.fast}
1022
- ${({ theme }) => theme.easing.ease_in};
1023
-
1024
- &:focus-within {
1025
- ${import_seeds_react_mixins2.focusRing}
849
+ var ComboboxToken = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
850
+ import_combobox.Combobox.Chips,
851
+ {
852
+ ref,
853
+ className: cn("seeds-combobox-tokens", className),
854
+ ...rest
1026
855
  }
1027
-
1028
- &[data-disabled] {
1029
- opacity: 0.4;
1030
- cursor: not-allowed;
856
+ ));
857
+ ComboboxToken.displayName = "ComboboxToken";
858
+ var ComboboxTokenInputGroup = React8.forwardRef(({ $isInvalid, className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
859
+ import_combobox.Combobox.InputGroup,
860
+ {
861
+ ref,
862
+ className: cn(
863
+ "seeds-combobox-token-input-group",
864
+ { "seeds-combobox-token-input-group--invalid": !!$isInvalid },
865
+ className
866
+ ),
867
+ ...rest
1031
868
  }
1032
-
1033
- ${({ $isInvalid }) => $isInvalid && invalidStyles2}
1034
- `;
1035
- var Token = import_styled_components6.default.span`
1036
- display: inline-flex;
1037
- align-items: center;
1038
- gap: ${({ theme }) => theme.space[200]};
1039
- padding: ${({ theme }) => `${theme.space[200]} ${theme.space[300]}`};
1040
- border-radius: ${({ theme }) => theme.radii[500]};
1041
- border: 1px solid ${({ theme }) => theme.colors.container.border.base};
1042
- background: ${({ theme }) => theme.colors.container.background.base};
1043
- color: ${({ theme }) => theme.colors.text.body};
1044
- font-size: ${({ theme }) => theme.typography[200].fontSize};
1045
- font-weight: ${({ theme }) => theme.fontWeights.normal};
1046
- line-height: 1;
1047
- white-space: nowrap;
1048
- transition: all ${({ theme }) => theme.duration.fast}
1049
- ${({ theme }) => theme.easing.ease_inout};
1050
-
1051
- &:hover {
1052
- box-shadow: ${({ theme }) => theme.shadows.low};
1053
- border-color: ${({ theme }) => theme.colors.container.border.base};
1054
- }
1055
- `;
1056
- var TokenRemove = import_styled_components6.default.button`
1057
- display: flex;
1058
- align-items: center;
1059
- justify-content: center;
1060
- border: none;
1061
- background: transparent;
1062
- color: inherit;
1063
- cursor: pointer;
1064
- padding: 0;
1065
- line-height: 1;
1066
-
1067
- &:focus-visible {
1068
- ${import_seeds_react_mixins2.focusRing}
1069
- }
1070
- `;
1071
- var SearchableSelectTrigger = (0, import_styled_components6.default)(import_combobox.Combobox.Trigger)`
1072
- display: flex;
1073
- align-items: center;
1074
- justify-content: space-between;
1075
- gap: ${({ theme }) => theme.space[300]};
1076
- padding: ${({ theme }) => theme.space[200]} ${({ theme }) => theme.space[350]};
1077
- min-width: 160px;
1078
- border-radius: ${({ theme }) => theme.radii[500]};
1079
- border: 1px solid ${({ theme }) => theme.colors.form.border.base};
1080
- background: ${({ theme }) => theme.colors.form.background.base};
1081
- font-size: ${({ theme }) => theme.typography[200].fontSize};
1082
- color: ${({ theme }) => theme.colors.text.body};
1083
- cursor: default;
1084
- outline: none;
1085
- user-select: none;
1086
- transition: border-color ${({ theme }) => theme.duration.fast}
1087
- ${({ theme }) => theme.easing.ease_in},
1088
- box-shadow ${({ theme }) => theme.duration.fast}
1089
- ${({ theme }) => theme.easing.ease_in};
1090
-
1091
- &:focus-visible {
1092
- ${import_seeds_react_mixins2.focusRing}
869
+ ));
870
+ ComboboxTokenInputGroup.displayName = "ComboboxTokenInputGroup";
871
+ var Token = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { ref, className: cn("seeds-combobox-token", className), ...rest }));
872
+ Token.displayName = "Token";
873
+ var TokenRemove = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
874
+ "button",
875
+ {
876
+ ref,
877
+ className: cn("seeds-combobox-token-remove", className),
878
+ ...rest
1093
879
  }
1094
-
1095
- &[data-popup-open] [data-chevron] {
1096
- transform: rotate(-180deg);
880
+ ));
881
+ TokenRemove.displayName = "TokenRemove";
882
+ var SearchableSelectTrigger = React8.forwardRef(({ $isInvalid, className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
883
+ import_combobox.Combobox.Trigger,
884
+ {
885
+ ref,
886
+ className: cn(
887
+ "seeds-searchable-select-trigger",
888
+ { "seeds-searchable-select-trigger--invalid": !!$isInvalid },
889
+ className
890
+ ),
891
+ ...rest
1097
892
  }
1098
-
1099
- &[data-disabled] {
1100
- opacity: 0.4;
1101
- cursor: not-allowed;
893
+ ));
894
+ SearchableSelectTrigger.displayName = "SearchableSelectTrigger";
895
+ var SearchableSelectTriggerIcon = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
896
+ import_combobox.Combobox.Icon,
897
+ {
898
+ ref,
899
+ className: cn("seeds-searchable-select-trigger-icon", className),
900
+ ...rest
1102
901
  }
1103
-
1104
- ${({ $isInvalid }) => $isInvalid && invalidStyles2}
1105
- `;
1106
- var SearchableSelectTriggerIcon = (0, import_styled_components6.default)(import_combobox.Combobox.Icon)`
1107
- display: flex;
1108
- align-items: center;
1109
- color: ${({ theme }) => theme.colors.icon.base};
1110
- flex-shrink: 0;
1111
- `;
1112
- var SearchableSelectPlaceholder = import_styled_components6.default.span`
1113
- color: ${({ theme }) => theme.colors.text.subtext};
1114
- padding: ${({ theme }) => theme.space[200]} 0;
1115
- `;
1116
- var SearchableSelectPopup = ComboboxPopup;
1117
- var SearchableSelectSearchContainer = import_styled_components6.default.div`
1118
- padding: ${({ theme }) => theme.space[300]};
1119
- border-bottom: 1px solid ${({ theme }) => theme.colors.container.border.base};
1120
- flex-shrink: 0;
1121
- `;
1122
- var SearchableSelectInput = (0, import_styled_components6.default)(import_combobox.Combobox.Input)`
1123
- width: 100%;
1124
- height: ${({ theme }) => theme.space[500]};
1125
- padding: 0 ${({ theme }) => theme.space[300]};
1126
- border-radius: ${({ theme }) => theme.radii[500]};
1127
- border: 1px solid ${({ theme }) => theme.colors.container.border.base};
1128
- background: ${({ theme }) => theme.colors.container.background.base};
1129
- font-size: ${({ theme }) => theme.typography[200].fontSize};
1130
- color: ${({ theme }) => theme.colors.text.body};
1131
- outline: none;
1132
- box-sizing: border-box;
1133
-
1134
- &:focus {
1135
- ${import_seeds_react_mixins2.focusRing}
902
+ ));
903
+ SearchableSelectTriggerIcon.displayName = "SearchableSelectTriggerIcon";
904
+ var SearchableSelectPlaceholder = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
905
+ "span",
906
+ {
907
+ ref,
908
+ className: cn("seeds-searchable-select-placeholder", className),
909
+ ...rest
1136
910
  }
1137
-
1138
- &::placeholder {
1139
- color: ${({ theme }) => theme.colors.text.subtext};
1140
- }
1141
- `;
1142
- var SearchableSelectList = (0, import_styled_components6.default)(import_combobox.Combobox.List)`
1143
- overflow-y: auto;
1144
- padding: ${({ theme }) => theme.space[200]};
1145
- flex: 1;
1146
- min-height: 0;
1147
- &:empty {
1148
- padding: 0;
1149
- }
1150
- `;
1151
- var SearchableSelectTokenTrigger = (0, import_styled_components6.default)(import_combobox.Combobox.Trigger)`
1152
- display: flex;
1153
- align-items: center;
1154
- flex-wrap: wrap;
1155
- min-width: 160px;
1156
- border-radius: ${({ theme }) => theme.radii[500]};
1157
- border: 1px solid ${({ theme }) => theme.colors.form.border.base};
1158
- background: ${({ theme }) => theme.colors.form.background.base};
1159
- color: ${({ theme }) => theme.colors.text.body};
1160
- padding: ${({ theme }) => theme.space[200]} ${({ theme }) => theme.space[300]};
1161
- gap: ${({ theme }) => theme.space[200]};
1162
- cursor: default;
1163
- text-align: left;
1164
- outline: none;
1165
- user-select: none;
1166
- transition: border-color ${({ theme }) => theme.duration.fast}
1167
- ${({ theme }) => theme.easing.ease_in},
1168
- box-shadow ${({ theme }) => theme.duration.fast}
1169
- ${({ theme }) => theme.easing.ease_in};
1170
-
1171
- &:focus-visible {
1172
- ${import_seeds_react_mixins2.focusRing}
911
+ ));
912
+ SearchableSelectPlaceholder.displayName = "SearchableSelectPlaceholder";
913
+ var SearchableSelectPopup = ComboboxPopup;
914
+ var SearchableSelectSearchContainer = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
915
+ "div",
916
+ {
917
+ ref,
918
+ className: cn("seeds-searchable-select-search-container", className),
919
+ ...rest
1173
920
  }
1174
-
1175
- &[data-popup-open] {
1176
- border-color: ${({ theme }) => theme.colors.blue[600]};
921
+ ));
922
+ SearchableSelectSearchContainer.displayName = "SearchableSelectSearchContainer";
923
+ var SearchableSelectInput = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
924
+ import_combobox.Combobox.Input,
925
+ {
926
+ ref,
927
+ className: cn("seeds-searchable-select-input", className),
928
+ ...rest
1177
929
  }
1178
-
1179
- &[data-popup-open] [data-chevron] {
1180
- transform: rotate(-180deg);
930
+ ));
931
+ SearchableSelectInput.displayName = "SearchableSelectInput";
932
+ var SearchableSelectList = React8.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
933
+ import_combobox.Combobox.List,
934
+ {
935
+ ref,
936
+ className: cn("seeds-searchable-select-list", className),
937
+ ...rest
1181
938
  }
1182
-
1183
- &[data-disabled] {
1184
- opacity: 0.4;
1185
- cursor: not-allowed;
939
+ ));
940
+ SearchableSelectList.displayName = "SearchableSelectList";
941
+ var SearchableSelectTokenTrigger = React8.forwardRef(({ $isInvalid, className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
942
+ import_combobox.Combobox.Trigger,
943
+ {
944
+ ref,
945
+ className: cn(
946
+ "seeds-searchable-select-token-trigger",
947
+ { "seeds-searchable-select-token-trigger--invalid": !!$isInvalid },
948
+ className
949
+ ),
950
+ ...rest
1186
951
  }
1187
-
1188
- ${({ $isInvalid }) => $isInvalid && invalidStyles2}
1189
- `;
952
+ ));
953
+ SearchableSelectTokenTrigger.displayName = "SearchableSelectTokenTrigger";
1190
954
 
1191
955
  // src/v3/Common/ComboboxItem.tsx
1192
- var import_jsx_runtime6 = require("react/jsx-runtime");
956
+ var import_jsx_runtime7 = require("react/jsx-runtime");
1193
957
  function ComboboxItemInner({
1194
958
  value,
1195
959
  itemId,
@@ -1201,7 +965,7 @@ function ComboboxItemInner({
1201
965
  "data-index": dataIndex,
1202
966
  style
1203
967
  }, ref) {
1204
- return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(
968
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(
1205
969
  ComboboxItem,
1206
970
  {
1207
971
  value,
@@ -1212,11 +976,11 @@ function ComboboxItemInner({
1212
976
  disabled,
1213
977
  "data-qa-menu-item": label,
1214
978
  children: [
1215
- inputType === "radio" ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
979
+ inputType === "radio" ? /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
1216
980
  ComboboxItemIndicator,
1217
981
  {
1218
982
  keepMounted: true,
1219
- render: (_props, state) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
983
+ render: (_props, state) => /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
1220
984
  import_seeds_react_radio2.default,
1221
985
  {
1222
986
  checked: state.selected,
@@ -1228,11 +992,11 @@ function ComboboxItemInner({
1228
992
  }
1229
993
  )
1230
994
  }
1231
- ) : inputType === "checkbox" ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
995
+ ) : inputType === "checkbox" ? /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
1232
996
  ComboboxItemIndicator,
1233
997
  {
1234
998
  keepMounted: true,
1235
- render: (_props, state) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
999
+ render: (_props, state) => /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
1236
1000
  import_seeds_react_checkbox3.default,
1237
1001
  {
1238
1002
  checked: state.selected,
@@ -1244,17 +1008,17 @@ function ComboboxItemInner({
1244
1008
  }
1245
1009
  )
1246
1010
  }
1247
- ) : inputType === "icon" ? /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ComboboxItemIndicator, { keepMounted: true, children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(CheckIcon2, {}) }) : null,
1248
- /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("span", { children: renderItem ? renderItem() : label })
1011
+ ) : inputType === "icon" ? /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(ComboboxItemIndicator, { keepMounted: true, children: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(CheckIcon2, {}) }) : null,
1012
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("span", { children: renderItem ? renderItem() : label })
1249
1013
  ]
1250
1014
  }
1251
1015
  );
1252
1016
  }
1253
- var ComboboxItem2 = React7.forwardRef(ComboboxItemInner);
1017
+ var ComboboxItem2 = React9.forwardRef(ComboboxItemInner);
1254
1018
  var ComboboxItem_default = ComboboxItem2;
1255
1019
 
1256
1020
  // src/v3/Common/VirtualizedComboboxList.tsx
1257
- var React8 = __toESM(require("react"));
1021
+ var React10 = __toESM(require("react"));
1258
1022
  var import_combobox2 = require("@base-ui/react/combobox");
1259
1023
  var import_react_virtual = require("@tanstack/react-virtual");
1260
1024
 
@@ -1273,7 +1037,7 @@ function isCreatableSentinel(v) {
1273
1037
  }
1274
1038
 
1275
1039
  // src/v3/Common/VirtualizedComboboxList.tsx
1276
- var import_jsx_runtime7 = require("react/jsx-runtime");
1040
+ var import_jsx_runtime8 = require("react/jsx-runtime");
1277
1041
  var ITEM_HEIGHT = 32;
1278
1042
  function isGroupHeaderSentinel(v) {
1279
1043
  return typeof v === "object" && v !== null && "__groupHeader" in v;
@@ -1295,7 +1059,7 @@ function VirtualizedComboboxList({
1295
1059
  renderCreatableItem
1296
1060
  }) {
1297
1061
  const filteredItems = import_combobox2.Combobox.useFilteredItems();
1298
- const scrollElementRef = React8.useRef(null);
1062
+ const scrollElementRef = React10.useRef(null);
1299
1063
  const virtualizer = (0, import_react_virtual.useVirtualizer)({
1300
1064
  enabled: open,
1301
1065
  count: filteredItems.length,
@@ -1307,8 +1071,8 @@ function VirtualizedComboboxList({
1307
1071
  scrollPaddingStart: 4,
1308
1072
  scrollPaddingEnd: 4
1309
1073
  });
1310
- React8.useImperativeHandle(virtualizerRef, () => virtualizer);
1311
- const handleScrollRef = React8.useCallback(
1074
+ React10.useImperativeHandle(virtualizerRef, () => virtualizer);
1075
+ const handleScrollRef = React10.useCallback(
1312
1076
  (el) => {
1313
1077
  scrollElementRef.current = el;
1314
1078
  if (el) requestAnimationFrame(() => virtualizer.measure());
@@ -1318,7 +1082,7 @@ function VirtualizedComboboxList({
1318
1082
  if (!filteredItems.length) return null;
1319
1083
  const selectedArray = Array.isArray(value) ? value : value != null ? [value] : [];
1320
1084
  const totalSize = virtualizer.getTotalSize();
1321
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
1085
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
1322
1086
  "div",
1323
1087
  {
1324
1088
  role: "presentation",
@@ -1329,7 +1093,7 @@ function VirtualizedComboboxList({
1329
1093
  overflowY: "auto",
1330
1094
  overscrollBehavior: "contain"
1331
1095
  },
1332
- children: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
1096
+ children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
1333
1097
  "div",
1334
1098
  {
1335
1099
  role: "presentation",
@@ -1346,7 +1110,7 @@ function VirtualizedComboboxList({
1346
1110
  boxSizing: "border-box"
1347
1111
  };
1348
1112
  if (isPlaceholderSentinel(row)) {
1349
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
1113
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
1350
1114
  ComboboxItem_default,
1351
1115
  {
1352
1116
  index: virtualItem.index,
@@ -1365,7 +1129,7 @@ function VirtualizedComboboxList({
1365
1129
  const selectedCount = selectedArray.length;
1366
1130
  const totalCount = data.length;
1367
1131
  const state = selectedCount === 0 ? "none" : selectedCount === totalCount ? "all" : "partial";
1368
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(
1132
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
1369
1133
  ComboboxSelectAllItem,
1370
1134
  {
1371
1135
  index: virtualItem.index,
@@ -1374,7 +1138,7 @@ function VirtualizedComboboxList({
1374
1138
  style: baseStyle,
1375
1139
  ref: virtualizer.measureElement,
1376
1140
  children: [
1377
- /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(ComboboxGroupHeaderCheckbox, { $state: state, id: "__selectAll" }),
1141
+ /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(ComboboxGroupHeaderCheckbox, { $state: state, id: "__selectAll" }),
1378
1142
  "Select all"
1379
1143
  ]
1380
1144
  },
@@ -1388,7 +1152,7 @@ function VirtualizedComboboxList({
1388
1152
  (item2) => selectedArray.some((s) => s.id === item2.id)
1389
1153
  ).length;
1390
1154
  const state = selectedCount === 0 ? "none" : selectedCount === groupItems2.length ? "all" : "partial";
1391
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(
1155
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
1392
1156
  ComboboxGroupHeaderItem,
1393
1157
  {
1394
1158
  index: virtualItem.index,
@@ -1398,7 +1162,7 @@ function VirtualizedComboboxList({
1398
1162
  style: baseStyle,
1399
1163
  ref: virtualizer.measureElement,
1400
1164
  children: [
1401
- /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
1165
+ /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
1402
1166
  ComboboxGroupHeaderCheckbox,
1403
1167
  {
1404
1168
  $state: state,
@@ -1423,7 +1187,7 @@ function VirtualizedComboboxList({
1423
1187
  return null;
1424
1188
  }
1425
1189
  const item = row;
1426
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
1190
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
1427
1191
  ComboboxItem_default,
1428
1192
  {
1429
1193
  index: virtualItem.index,
@@ -1447,7 +1211,7 @@ function VirtualizedComboboxList({
1447
1211
  }
1448
1212
 
1449
1213
  // src/v3/SingleCombobox.tsx
1450
- var import_jsx_runtime8 = require("react/jsx-runtime");
1214
+ var import_jsx_runtime9 = require("react/jsx-runtime");
1451
1215
  function SingleCombobox(props) {
1452
1216
  const {
1453
1217
  id,
@@ -1473,18 +1237,18 @@ function SingleCombobox(props) {
1473
1237
  const defaultSelectedItemId = props.defaultSelectedItemId;
1474
1238
  const onSelectedItemIdChange = props.onSelectedItemIdChange;
1475
1239
  const { containerRef, portalContainer } = useSeedsPortalContainer();
1476
- const [open, setOpen] = React9.useState(false);
1477
- const virtualizerRef = React9.useRef(null);
1240
+ const [open, setOpen] = React11.useState(false);
1241
+ const virtualizerRef = React11.useRef(null);
1478
1242
  const onInputKeyDownCapture = useSuppressEscapeClear(open);
1479
1243
  const isControlled = selectedItemId !== void 0;
1480
- const idToItem = React9.useCallback(
1244
+ const idToItem = React11.useCallback(
1481
1245
  (id2) => {
1482
1246
  if (id2 == null) return null;
1483
1247
  return data.find((d) => String(d.id) === String(id2)) ?? null;
1484
1248
  },
1485
1249
  [data]
1486
1250
  );
1487
- const [internalValue, setInternalValue] = React9.useState(
1251
+ const [internalValue, setInternalValue] = React11.useState(
1488
1252
  () => idToItem(defaultSelectedItemId)
1489
1253
  );
1490
1254
  const value = isControlled ? idToItem(selectedItemId) : internalValue;
@@ -1496,13 +1260,13 @@ function SingleCombobox(props) {
1496
1260
  onSelectedItemIdChange(newItem ? newItem.id : null);
1497
1261
  }
1498
1262
  }
1499
- const groups = React9.useMemo(
1263
+ const groups = React11.useMemo(
1500
1264
  () => groupBy ? groupItems(data, groupBy) : null,
1501
1265
  [data, groupBy]
1502
1266
  );
1503
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(Field, { $fullWidth: fullWidth, children: [
1504
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { ref: containerRef, style: { position: "relative" } }),
1505
- /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
1267
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(Field, { $fullWidth: fullWidth, children: [
1268
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("div", { ref: containerRef, style: { position: "relative" } }),
1269
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(
1506
1270
  import_combobox3.Combobox.Root,
1507
1271
  {
1508
1272
  id,
@@ -1530,13 +1294,13 @@ function SingleCombobox(props) {
1530
1294
  }
1531
1295
  } : void 0,
1532
1296
  children: [
1533
- /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
1297
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(
1534
1298
  ComboboxInputGroup,
1535
1299
  {
1536
1300
  $isInvalid: isInvalid,
1537
1301
  onKeyDownCapture: onInputKeyDownCapture,
1538
1302
  children: [
1539
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
1303
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1540
1304
  ComboboxInput,
1541
1305
  {
1542
1306
  placeholder,
@@ -1546,20 +1310,20 @@ function SingleCombobox(props) {
1546
1310
  "aria-required": props.required || void 0
1547
1311
  }
1548
1312
  ),
1549
- /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(ComboboxActionButtons, { children: [
1550
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(ComboboxClear, { "aria-label": "Clear selection", children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(ClearIcon, {}) }),
1551
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(ComboboxTrigger, { "aria-label": "Open popup", children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(StyledChevron, { $isOpen: open, children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(ChevronIcon, {}) }) })
1313
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(ComboboxActionButtons, { children: [
1314
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ComboboxClear, { "aria-label": "Clear selection", children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ClearIcon, {}) }),
1315
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ComboboxTrigger, { "aria-label": "Open popup", children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(StyledChevron, { $isOpen: open, children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ChevronIcon, {}) }) })
1552
1316
  ] })
1553
1317
  ]
1554
1318
  }
1555
1319
  ),
1556
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_combobox3.Combobox.Portal, { container: portalContainer, children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(ComboboxPositioner, { sideOffset: 4, children: /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
1320
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_combobox3.Combobox.Portal, { container: portalContainer, children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ComboboxPositioner, { sideOffset: 4, children: /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(
1557
1321
  ComboboxPopup,
1558
1322
  {
1559
1323
  style: isVirtualized ? { display: "flex", flexDirection: "column" } : void 0,
1560
1324
  children: [
1561
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(ComboboxEmpty, { children: emptyText }),
1562
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
1325
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ComboboxEmpty, { children: emptyText }),
1326
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1563
1327
  ComboboxList,
1564
1328
  {
1565
1329
  "aria-label": ariaLabel,
@@ -1571,7 +1335,7 @@ function SingleCombobox(props) {
1571
1335
  display: "flex",
1572
1336
  flexDirection: "column"
1573
1337
  } : void 0,
1574
- children: isVirtualized ? /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
1338
+ children: isVirtualized ? /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1575
1339
  VirtualizedComboboxList,
1576
1340
  {
1577
1341
  open,
@@ -1584,10 +1348,10 @@ function SingleCombobox(props) {
1584
1348
  renderItem,
1585
1349
  renderGroupHeading
1586
1350
  }
1587
- ) : children ? children : groups ? ((group, index) => /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(React9.Fragment, { children: [
1588
- /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(ComboboxGroup, { items: group.items, children: [
1589
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(ComboboxGroupLabel, { children: renderGroupHeading ? renderGroupHeading(group.value) : group.value }),
1590
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_combobox3.Combobox.Collection, { children: (item) => /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
1351
+ ) : children ? children : groups ? ((group, index) => /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(React11.Fragment, { children: [
1352
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(ComboboxGroup, { items: group.items, children: [
1353
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ComboboxGroupLabel, { children: renderGroupHeading ? renderGroupHeading(group.value) : group.value }),
1354
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_combobox3.Combobox.Collection, { children: (item) => /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1591
1355
  ComboboxItem_default,
1592
1356
  {
1593
1357
  value: item,
@@ -1600,8 +1364,8 @@ function SingleCombobox(props) {
1600
1364
  item.id
1601
1365
  ) })
1602
1366
  ] }),
1603
- index < groups.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(ComboboxSeparator, {})
1604
- ] }, group.value)) : ((item) => /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
1367
+ index < groups.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ComboboxSeparator, {})
1368
+ ] }, group.value)) : ((item) => /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1605
1369
  ComboboxItem_default,
1606
1370
  {
1607
1371
  value: item,
@@ -1625,11 +1389,11 @@ function SingleCombobox(props) {
1625
1389
  }
1626
1390
 
1627
1391
  // src/v3/MultiCombobox.tsx
1628
- var React10 = __toESM(require("react"));
1392
+ var React12 = __toESM(require("react"));
1629
1393
  var import_combobox4 = require("@base-ui/react/combobox");
1630
1394
  var import_react_virtual3 = require("@tanstack/react-virtual");
1631
1395
  var import_seeds_react_icon3 = __toESM(require("@sproutsocial/seeds-react-icon"));
1632
- var import_jsx_runtime9 = require("react/jsx-runtime");
1396
+ var import_jsx_runtime10 = require("react/jsx-runtime");
1633
1397
  function makeGroupHeaderSentinel(groupName) {
1634
1398
  return { __groupHeader: true, groupName };
1635
1399
  }
@@ -1680,31 +1444,31 @@ function MultiCombobox(props) {
1680
1444
  const defaultSelectedItemIds = props.defaultSelectedItemIds;
1681
1445
  const onSelectedItemIdsChange = props.onSelectedItemIdsChange;
1682
1446
  const { containerRef, portalContainer } = useSeedsPortalContainer();
1683
- const [open, setOpen] = React10.useState(false);
1684
- const [internalInputValue, setInternalInputValue] = React10.useState("");
1685
- const skipNextInputChangeRef = React10.useRef(false);
1686
- const virtualizerRef = React10.useRef(null);
1687
- const inputRef = React10.useRef(null);
1447
+ const [open, setOpen] = React12.useState(false);
1448
+ const [internalInputValue, setInternalInputValue] = React12.useState("");
1449
+ const skipNextInputChangeRef = React12.useRef(false);
1450
+ const virtualizerRef = React12.useRef(null);
1451
+ const inputRef = React12.useRef(null);
1688
1452
  const onInputKeyDownCapture = useSuppressEscapeClear(open);
1689
1453
  const isControlled = selectedItemIds !== void 0;
1690
- const idsToItems = React10.useCallback(
1454
+ const idsToItems = React12.useCallback(
1691
1455
  (ids) => ids.map((id2) => data.find((d) => d.id === id2)).filter((d) => d != null),
1692
1456
  [data]
1693
1457
  );
1694
- const [internalValue, setInternalValue] = React10.useState(
1458
+ const [internalValue, setInternalValue] = React12.useState(
1695
1459
  () => defaultSelectedItemIds ? idsToItems(defaultSelectedItemIds) : []
1696
1460
  );
1697
1461
  const value = isControlled ? idsToItems(selectedItemIds) : internalValue;
1698
- const visibleData = React10.useMemo(
1462
+ const visibleData = React12.useMemo(
1699
1463
  () => removeSelectedItems ? data.filter((item) => !value.some((v) => v.id === item.id)) : data,
1700
1464
  [data, value, removeSelectedItems]
1701
1465
  );
1702
- const groups = React10.useMemo(
1466
+ const groups = React12.useMemo(
1703
1467
  () => groupBy ? groupItems(visibleData, groupBy) : null,
1704
1468
  [visibleData, groupBy]
1705
1469
  );
1706
1470
  const currentInputValue = inputValue ?? internalInputValue;
1707
- const creatableSentinel = React10.useMemo(() => {
1471
+ const creatableSentinel = React12.useMemo(() => {
1708
1472
  if (!creatableProp) return null;
1709
1473
  const trimmed = currentInputValue.trim();
1710
1474
  if (!trimmed) return null;
@@ -1715,7 +1479,7 @@ function MultiCombobox(props) {
1715
1479
  if (exactExists) return null;
1716
1480
  return makeCreatableSentinel(trimmed);
1717
1481
  }, [creatableProp, currentInputValue, data, itemToString]);
1718
- const flatItems = React10.useMemo(() => {
1482
+ const flatItems = React12.useMemo(() => {
1719
1483
  if (!selectHeadings && !selectAll) return null;
1720
1484
  if (!groups && !selectAll) return null;
1721
1485
  const rows = [];
@@ -1809,8 +1573,8 @@ function MultiCombobox(props) {
1809
1573
  const totalCount = data.length;
1810
1574
  const selectedCount = value.length;
1811
1575
  const state = selectedCount === 0 ? "none" : selectedCount === totalCount ? "all" : "partial";
1812
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(ComboboxSelectAllItem, { value: row, children: [
1813
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ComboboxGroupHeaderCheckbox, { $state: state, id: "__selectAll" }),
1576
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(ComboboxSelectAllItem, { value: row, children: [
1577
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(ComboboxGroupHeaderCheckbox, { $state: state, id: "__selectAll" }),
1814
1578
  selectAllLabel
1815
1579
  ] }, "__selectAll");
1816
1580
  }
@@ -1821,13 +1585,13 @@ function MultiCombobox(props) {
1821
1585
  (item2) => value.some((s) => s.id === item2.id)
1822
1586
  ).length;
1823
1587
  const state = selectedCount === 0 ? "none" : selectedCount === groupItemsList.length ? "all" : "partial";
1824
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(
1588
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
1825
1589
  ComboboxGroupHeaderItem,
1826
1590
  {
1827
1591
  value: row,
1828
1592
  disabled: isGroupHeaderDisabled?.(row.groupName),
1829
1593
  children: [
1830
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1594
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
1831
1595
  ComboboxGroupHeaderCheckbox,
1832
1596
  {
1833
1597
  $state: state,
@@ -1844,7 +1608,7 @@ function MultiCombobox(props) {
1844
1608
  return renderCreatableItem(row);
1845
1609
  }
1846
1610
  const item = row;
1847
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1611
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
1848
1612
  ComboboxItem_default,
1849
1613
  {
1850
1614
  value: item,
@@ -1858,15 +1622,15 @@ function MultiCombobox(props) {
1858
1622
  );
1859
1623
  }
1860
1624
  function renderCreatableItem(sentinel, style, index, measureRef) {
1861
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1625
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
1862
1626
  ComboboxItem_default,
1863
1627
  {
1864
1628
  value: sentinel,
1865
1629
  itemId: "__creatable",
1866
1630
  label: `Create "${sentinel.label}"`,
1867
1631
  inputType: "none",
1868
- renderItem: () => /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(import_jsx_runtime9.Fragment, { children: [
1869
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_seeds_react_icon3.default, { name: "plus-outline", size: "mini" }),
1632
+ renderItem: () => /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
1633
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_seeds_react_icon3.default, { name: "plus-outline", size: "mini" }),
1870
1634
  `Create "${sentinel.label}"`
1871
1635
  ] }),
1872
1636
  style,
@@ -1881,9 +1645,9 @@ function MultiCombobox(props) {
1881
1645
  const rootItems = creatableSentinel && Array.isArray(baseItems) ? [...baseItems, creatableSentinel] : baseItems;
1882
1646
  const hasSentinels = selectAll || selectHeadings;
1883
1647
  const rootValue = hasSentinels ? [...value] : value;
1884
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(Field, { $fullWidth: fullWidth, children: [
1885
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("div", { ref: containerRef, style: { position: "relative" } }),
1886
- /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(
1648
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(Field, { $fullWidth: fullWidth, children: [
1649
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { ref: containerRef, style: { position: "relative" } }),
1650
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
1887
1651
  import_combobox4.Combobox.Root,
1888
1652
  {
1889
1653
  multiple: true,
@@ -1958,35 +1722,35 @@ function MultiCombobox(props) {
1958
1722
  },
1959
1723
  items: rootItems,
1960
1724
  children: [
1961
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1725
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
1962
1726
  ComboboxTokenInputGroup,
1963
1727
  {
1964
1728
  $isInvalid: isInvalid,
1965
1729
  onKeyDownCapture: onInputKeyDownCapture,
1966
- children: /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(ComboboxToken, { children: [
1730
+ children: /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(ComboboxToken, { children: [
1967
1731
  renderSelection ? renderSelection(value) : (() => {
1968
1732
  const visibleTokens = maxTokens != null ? value.slice(0, maxTokens) : value;
1969
1733
  const overflow = maxTokens != null ? value.length - maxTokens : 0;
1970
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(import_jsx_runtime9.Fragment, { children: [
1971
- visibleTokens.map((item) => /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(Token, { children: [
1734
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
1735
+ visibleTokens.map((item) => /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(Token, { children: [
1972
1736
  renderToken ? renderToken(item) : itemToString(item),
1973
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1737
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
1974
1738
  TokenRemove,
1975
1739
  {
1976
1740
  "aria-label": `Remove ${itemToString(item)}`,
1977
1741
  onPointerDown: (e) => e.preventDefault(),
1978
1742
  onClick: (e) => removeItem(item, e),
1979
- children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_seeds_react_icon3.default, { name: "x-outline", size: "mini" })
1743
+ children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_seeds_react_icon3.default, { name: "x-outline", size: "mini" })
1980
1744
  }
1981
1745
  )
1982
1746
  ] }, item.id)),
1983
- overflow > 0 && /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(Token, { children: [
1747
+ overflow > 0 && /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(Token, { children: [
1984
1748
  "+",
1985
1749
  overflow
1986
1750
  ] }, "__overflow")
1987
1751
  ] });
1988
1752
  })(),
1989
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1753
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
1990
1754
  ComboboxTokenInput,
1991
1755
  {
1992
1756
  ref: inputRef,
@@ -1997,22 +1761,22 @@ function MultiCombobox(props) {
1997
1761
  "aria-required": props.required || void 0
1998
1762
  }
1999
1763
  ),
2000
- /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(ComboboxActionButtons, { children: [
2001
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ComboboxClear, { "aria-label": "Clear all", children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ClearIcon, {}) }),
2002
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ComboboxTrigger, { "aria-label": "Open popup", children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(StyledChevron, { $isOpen: open, children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ChevronIcon, {}) }) })
1764
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(ComboboxActionButtons, { children: [
1765
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(ComboboxClear, { "aria-label": "Clear all", children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(ClearIcon, {}) }),
1766
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(ComboboxTrigger, { "aria-label": "Open popup", children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(StyledChevron, { $isOpen: open, children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(ChevronIcon, {}) }) })
2003
1767
  ] })
2004
1768
  ] })
2005
1769
  }
2006
1770
  ),
2007
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_combobox4.Combobox.Portal, { container: portalContainer, children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ComboboxPositioner, { sideOffset: 4, children: /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(
1771
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_combobox4.Combobox.Portal, { container: portalContainer, children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(ComboboxPositioner, { sideOffset: 4, children: /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
2008
1772
  ComboboxPopup,
2009
1773
  {
2010
1774
  "aria-busy": isLoading || void 0,
2011
1775
  style: isVirtualized ? { display: "flex", flexDirection: "column" } : void 0,
2012
1776
  children: [
2013
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ComboboxStatus, { children: isLoading ? loadingText : null }),
2014
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ComboboxEmpty, { children: isLoading ? null : emptyText }),
2015
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1777
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(ComboboxStatus, { children: isLoading ? loadingText : null }),
1778
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(ComboboxEmpty, { children: isLoading ? null : emptyText }),
1779
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
2016
1780
  ComboboxList,
2017
1781
  {
2018
1782
  "aria-label": ariaLabel,
@@ -2024,7 +1788,7 @@ function MultiCombobox(props) {
2024
1788
  display: "flex",
2025
1789
  flexDirection: "column"
2026
1790
  } : void 0,
2027
- children: isVirtualized ? /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1791
+ children: isVirtualized ? /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
2028
1792
  VirtualizedComboboxList,
2029
1793
  {
2030
1794
  open,
@@ -2049,10 +1813,10 @@ function MultiCombobox(props) {
2049
1813
  return renderCreatableItem(group);
2050
1814
  }
2051
1815
  const g = group;
2052
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(React10.Fragment, { children: [
2053
- /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(ComboboxGroup, { items: g.items, children: [
2054
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ComboboxGroupLabel, { children: renderGroupHeading ? renderGroupHeading(g.value) : g.value }),
2055
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_combobox4.Combobox.Collection, { children: (item) => /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1816
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(React12.Fragment, { children: [
1817
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(ComboboxGroup, { items: g.items, children: [
1818
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(ComboboxGroupLabel, { children: renderGroupHeading ? renderGroupHeading(g.value) : g.value }),
1819
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_combobox4.Combobox.Collection, { children: (item) => /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
2056
1820
  ComboboxItem_default,
2057
1821
  {
2058
1822
  value: item,
@@ -2065,14 +1829,14 @@ function MultiCombobox(props) {
2065
1829
  item.id
2066
1830
  ) })
2067
1831
  ] }),
2068
- index < groups.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ComboboxSeparator, {})
1832
+ index < groups.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(ComboboxSeparator, {})
2069
1833
  ] }, g.value);
2070
1834
  }) : ((item) => {
2071
1835
  if (isCreatableSentinel(item)) {
2072
1836
  return renderCreatableItem(item);
2073
1837
  }
2074
1838
  const dataItem = item;
2075
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
1839
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
2076
1840
  ComboboxItem_default,
2077
1841
  {
2078
1842
  value: dataItem,
@@ -2097,10 +1861,10 @@ function MultiCombobox(props) {
2097
1861
  }
2098
1862
 
2099
1863
  // src/v3/SingleSearchableSelect.tsx
2100
- var React11 = __toESM(require("react"));
1864
+ var React13 = __toESM(require("react"));
2101
1865
  var import_combobox5 = require("@base-ui/react/combobox");
2102
1866
  var import_react_virtual4 = require("@tanstack/react-virtual");
2103
- var import_jsx_runtime10 = require("react/jsx-runtime");
1867
+ var import_jsx_runtime11 = require("react/jsx-runtime");
2104
1868
  function SingleSearchableSelect(props) {
2105
1869
  const {
2106
1870
  id,
@@ -2131,17 +1895,17 @@ function SingleSearchableSelect(props) {
2131
1895
  const defaultSelectedItemId = props.defaultSelectedItemId;
2132
1896
  const onSelectedItemIdChange = props.onSelectedItemIdChange;
2133
1897
  const { containerRef, portalContainer } = useSeedsPortalContainer();
2134
- const [open, setOpen] = React11.useState(false);
2135
- const virtualizerRef = React11.useRef(null);
1898
+ const [open, setOpen] = React13.useState(false);
1899
+ const virtualizerRef = React13.useRef(null);
2136
1900
  const isControlled = selectedItemId !== void 0;
2137
- const idToItem = React11.useCallback(
1901
+ const idToItem = React13.useCallback(
2138
1902
  (id2) => {
2139
1903
  if (id2 == null) return null;
2140
1904
  return data.find((d) => String(d.id) === String(id2)) ?? null;
2141
1905
  },
2142
1906
  [data]
2143
1907
  );
2144
- const [internalValue, setInternalValue] = React11.useState(
1908
+ const [internalValue, setInternalValue] = React13.useState(
2145
1909
  () => idToItem(defaultSelectedItemId)
2146
1910
  );
2147
1911
  const value = isControlled ? idToItem(selectedItemId) : internalValue;
@@ -2152,13 +1916,13 @@ function SingleSearchableSelect(props) {
2152
1916
  onSelectedItemIdChange(realItem ? realItem.id : null);
2153
1917
  }
2154
1918
  }
2155
- const groups = React11.useMemo(
1919
+ const groups = React13.useMemo(
2156
1920
  () => groupBy ? groupItems(data, groupBy) : null,
2157
1921
  [data, groupBy]
2158
1922
  );
2159
- return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(Field, { $fullWidth: fullWidth, children: [
2160
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { ref: containerRef, style: { position: "relative" } }),
2161
- /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
1923
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(Field, { $fullWidth: fullWidth, children: [
1924
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("div", { ref: containerRef, style: { position: "relative" } }),
1925
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
2162
1926
  import_combobox5.Combobox.Root,
2163
1927
  {
2164
1928
  id,
@@ -2191,7 +1955,7 @@ function SingleSearchableSelect(props) {
2191
1955
  }
2192
1956
  } : void 0,
2193
1957
  children: [
2194
- /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
1958
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
2195
1959
  SearchableSelectTrigger,
2196
1960
  {
2197
1961
  id,
@@ -2200,27 +1964,27 @@ function SingleSearchableSelect(props) {
2200
1964
  "aria-required": props.required || void 0,
2201
1965
  $isInvalid: isInvalid,
2202
1966
  children: [
2203
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(SearchableSelectPlaceholder, { children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_combobox5.Combobox.Value, { placeholder, children: value ? renderSelection ? renderSelection(value) : itemToString(value) : placeholder }) }),
2204
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(SearchableSelectTriggerIcon, { children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(StyledChevron, { "data-chevron": true, children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(ChevronIcon, {}) }) })
1967
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(SearchableSelectPlaceholder, { children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_combobox5.Combobox.Value, { placeholder, children: value ? renderSelection ? renderSelection(value) : itemToString(value) : placeholder }) }),
1968
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(SearchableSelectTriggerIcon, { children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(StyledChevron, { "data-chevron": true, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ChevronIcon, {}) }) })
2205
1969
  ]
2206
1970
  }
2207
1971
  ),
2208
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_combobox5.Combobox.Portal, { container: portalContainer, children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(ComboboxPositioner, { sideOffset: 4, children: /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
1972
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_combobox5.Combobox.Portal, { container: portalContainer, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ComboboxPositioner, { sideOffset: 4, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
2209
1973
  SearchableSelectPopup,
2210
1974
  {
2211
1975
  "aria-busy": isLoading || void 0,
2212
1976
  style: { display: "flex", flexDirection: "column" },
2213
1977
  children: [
2214
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(SearchableSelectSearchContainer, { children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
1978
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(SearchableSelectSearchContainer, { children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
2215
1979
  SearchableSelectInput,
2216
1980
  {
2217
1981
  placeholder: searchPlaceholder,
2218
1982
  autoFocus: true
2219
1983
  }
2220
1984
  ) }),
2221
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(ComboboxStatus, { children: isLoading ? loadingText : null }),
2222
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(ComboboxEmpty, { children: isLoading ? null : emptyText }),
2223
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
1985
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ComboboxStatus, { children: isLoading ? loadingText : null }),
1986
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ComboboxEmpty, { children: isLoading ? null : emptyText }),
1987
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
2224
1988
  SearchableSelectList,
2225
1989
  {
2226
1990
  "aria-label": ariaLabel,
@@ -2232,7 +1996,7 @@ function SingleSearchableSelect(props) {
2232
1996
  display: "flex",
2233
1997
  flexDirection: "column"
2234
1998
  } : void 0,
2235
- children: isVirtualized ? /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
1999
+ children: isVirtualized ? /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
2236
2000
  VirtualizedComboboxList,
2237
2001
  {
2238
2002
  open,
@@ -2244,10 +2008,10 @@ function SingleSearchableSelect(props) {
2244
2008
  inputType,
2245
2009
  renderItem
2246
2010
  }
2247
- ) : children ? children : groups ? ((group, index) => /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(React11.Fragment, { children: [
2248
- /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(ComboboxGroup, { items: group.items, children: [
2249
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(ComboboxGroupLabel, { children: renderGroupHeading ? renderGroupHeading(group.value) : group.value }),
2250
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_combobox5.Combobox.Collection, { children: (item) => /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
2011
+ ) : children ? children : groups ? ((group, index) => /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(React13.Fragment, { children: [
2012
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(ComboboxGroup, { items: group.items, children: [
2013
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ComboboxGroupLabel, { children: renderGroupHeading ? renderGroupHeading(group.value) : group.value }),
2014
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_combobox5.Combobox.Collection, { children: (item) => /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
2251
2015
  ComboboxItem_default,
2252
2016
  {
2253
2017
  value: item,
@@ -2260,9 +2024,9 @@ function SingleSearchableSelect(props) {
2260
2024
  item.id
2261
2025
  ) })
2262
2026
  ] }),
2263
- index < groups.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(ComboboxSeparator, {})
2264
- ] }, group.value)) : /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
2265
- includePlaceholderItem && /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
2027
+ index < groups.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ComboboxSeparator, {})
2028
+ ] }, group.value)) : /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(import_jsx_runtime11.Fragment, { children: [
2029
+ includePlaceholderItem && /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
2266
2030
  ComboboxItem_default,
2267
2031
  {
2268
2032
  value: makePlaceholderSentinel(placeholder),
@@ -2272,7 +2036,7 @@ function SingleSearchableSelect(props) {
2272
2036
  },
2273
2037
  "placeholder"
2274
2038
  ),
2275
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_combobox5.Combobox.Collection, { children: (item) => /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
2039
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_combobox5.Combobox.Collection, { children: (item) => /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
2276
2040
  ComboboxItem_default,
2277
2041
  {
2278
2042
  value: item,
@@ -2297,18 +2061,15 @@ function SingleSearchableSelect(props) {
2297
2061
  }
2298
2062
 
2299
2063
  // src/v3/MultiSearchableSelect.tsx
2300
- var React12 = __toESM(require("react"));
2064
+ var React14 = __toESM(require("react"));
2301
2065
  var import_combobox6 = require("@base-ui/react/combobox");
2302
2066
  var import_react_virtual5 = require("@tanstack/react-virtual");
2303
2067
  var import_seeds_react_icon4 = __toESM(require("@sproutsocial/seeds-react-icon"));
2304
- var import_styled_components7 = __toESM(require("styled-components"));
2305
- var import_jsx_runtime11 = require("react/jsx-runtime");
2306
- var SelectionText2 = import_styled_components7.default.span`
2307
- flex: 1;
2308
- overflow: hidden;
2309
- text-overflow: ellipsis;
2310
- white-space: nowrap;
2311
- `;
2068
+ var import_jsx_runtime12 = require("react/jsx-runtime");
2069
+ var SelectionText2 = ({
2070
+ className,
2071
+ ...rest
2072
+ }) => /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("span", { className: cn("seeds-select-selection-text", className), ...rest });
2312
2073
  function makeGroupHeaderSentinel2(groupName) {
2313
2074
  return { __groupHeader: true, groupName };
2314
2075
  }
@@ -2355,29 +2116,29 @@ function MultiSearchableSelect(props) {
2355
2116
  const defaultSelectedItemIds = props.defaultSelectedItemIds;
2356
2117
  const onSelectedItemIdsChange = props.onSelectedItemIdsChange;
2357
2118
  const { containerRef, portalContainer } = useSeedsPortalContainer();
2358
- const [open, setOpen] = React12.useState(false);
2359
- const [internalInputValue, setInternalInputValue] = React12.useState("");
2360
- const skipNextInputChangeRef = React12.useRef(false);
2361
- const virtualizerRef = React12.useRef(null);
2119
+ const [open, setOpen] = React14.useState(false);
2120
+ const [internalInputValue, setInternalInputValue] = React14.useState("");
2121
+ const skipNextInputChangeRef = React14.useRef(false);
2122
+ const virtualizerRef = React14.useRef(null);
2362
2123
  const isControlled = selectedItemIds !== void 0;
2363
- const idsToItems = React12.useCallback(
2124
+ const idsToItems = React14.useCallback(
2364
2125
  (ids) => ids.map((id2) => data.find((d) => d.id === id2)).filter((d) => d != null),
2365
2126
  [data]
2366
2127
  );
2367
- const [internalValue, setInternalValue] = React12.useState(
2128
+ const [internalValue, setInternalValue] = React14.useState(
2368
2129
  () => defaultSelectedItemIds ? idsToItems(defaultSelectedItemIds) : []
2369
2130
  );
2370
2131
  const value = isControlled ? idsToItems(selectedItemIds) : internalValue;
2371
- const visibleData = React12.useMemo(
2132
+ const visibleData = React14.useMemo(
2372
2133
  () => removeSelectedItems ? data.filter((item) => !value.some((v) => v.id === item.id)) : data,
2373
2134
  [data, value, removeSelectedItems]
2374
2135
  );
2375
- const groups = React12.useMemo(
2136
+ const groups = React14.useMemo(
2376
2137
  () => groupBy ? groupItems(visibleData, groupBy) : null,
2377
2138
  [visibleData, groupBy]
2378
2139
  );
2379
2140
  const currentInputValue = internalInputValue;
2380
- const creatableSentinel = React12.useMemo(() => {
2141
+ const creatableSentinel = React14.useMemo(() => {
2381
2142
  if (!creatableProp) return null;
2382
2143
  const trimmed = currentInputValue.trim();
2383
2144
  if (!trimmed) return null;
@@ -2388,7 +2149,7 @@ function MultiSearchableSelect(props) {
2388
2149
  if (exactExists) return null;
2389
2150
  return makeCreatableSentinel(trimmed);
2390
2151
  }, [creatableProp, currentInputValue, data, itemToString]);
2391
- const flatItems = React12.useMemo(() => {
2152
+ const flatItems = React14.useMemo(() => {
2392
2153
  if (!groups || !selectHeadings && !selectAll) return null;
2393
2154
  const rows = [];
2394
2155
  if (selectAll) rows.push(SELECT_ALL_SENTINEL2);
@@ -2468,8 +2229,8 @@ function MultiSearchableSelect(props) {
2468
2229
  const totalCount = data.length;
2469
2230
  const selectedCount = value.length;
2470
2231
  const state = selectedCount === 0 ? "none" : selectedCount === totalCount ? "all" : "partial";
2471
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(ComboboxSelectAllItem, { value: row, children: [
2472
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ComboboxGroupHeaderCheckbox, { $state: state, id: "__selectAll" }),
2232
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(ComboboxSelectAllItem, { value: row, children: [
2233
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ComboboxGroupHeaderCheckbox, { $state: state, id: "__selectAll" }),
2473
2234
  "Select all"
2474
2235
  ] }, "__selectAll");
2475
2236
  }
@@ -2480,8 +2241,8 @@ function MultiSearchableSelect(props) {
2480
2241
  (item2) => value.some((s) => s.id === item2.id)
2481
2242
  ).length;
2482
2243
  const state = selectedCount === 0 ? "none" : selectedCount === groupItemsList.length ? "all" : "partial";
2483
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(ComboboxGroupHeaderItem, { value: row, children: [
2484
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
2244
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(ComboboxGroupHeaderItem, { value: row, children: [
2245
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
2485
2246
  ComboboxGroupHeaderCheckbox,
2486
2247
  {
2487
2248
  $state: state,
@@ -2495,7 +2256,7 @@ function MultiSearchableSelect(props) {
2495
2256
  return renderCreatableItem(row);
2496
2257
  }
2497
2258
  const item = row;
2498
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
2259
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
2499
2260
  ComboboxItem_default,
2500
2261
  {
2501
2262
  value: item,
@@ -2509,15 +2270,15 @@ function MultiSearchableSelect(props) {
2509
2270
  );
2510
2271
  }
2511
2272
  function renderCreatableItem(sentinel, style, index, measureRef) {
2512
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
2273
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
2513
2274
  ComboboxItem_default,
2514
2275
  {
2515
2276
  value: sentinel,
2516
2277
  itemId: "__creatable",
2517
2278
  label: `Create "${sentinel.label}"`,
2518
2279
  inputType: "none",
2519
- renderItem: () => /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(import_jsx_runtime11.Fragment, { children: [
2520
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_seeds_react_icon4.default, { name: "plus-outline", size: "mini" }),
2280
+ renderItem: () => /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(import_jsx_runtime12.Fragment, { children: [
2281
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_seeds_react_icon4.default, { name: "plus-outline", size: "mini" }),
2521
2282
  `Create "${sentinel.label}"`
2522
2283
  ] }),
2523
2284
  style,
@@ -2532,9 +2293,9 @@ function MultiSearchableSelect(props) {
2532
2293
  const rootItems = creatableSentinel && Array.isArray(baseItems) ? [...baseItems, creatableSentinel] : baseItems;
2533
2294
  const hasSentinels = selectAll || selectHeadings;
2534
2295
  const rootValue = hasSentinels ? [...value] : value;
2535
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(Field, { $fullWidth: fullWidth, children: [
2536
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("div", { ref: containerRef, style: { position: "relative" } }),
2537
- /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
2296
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(Field, { $fullWidth: fullWidth, children: [
2297
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { ref: containerRef, style: { position: "relative" } }),
2298
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
2538
2299
  import_combobox6.Combobox.Root,
2539
2300
  {
2540
2301
  multiple: true,
@@ -2595,7 +2356,7 @@ function MultiSearchableSelect(props) {
2595
2356
  },
2596
2357
  items: rootItems,
2597
2358
  children: [
2598
- /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
2359
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
2599
2360
  SearchableSelectTokenTrigger,
2600
2361
  {
2601
2362
  id,
@@ -2610,31 +2371,31 @@ function MultiSearchableSelect(props) {
2610
2371
  const text = visibleItems.map(
2611
2372
  (item) => customRenderSelections ? customRenderSelections(item) : itemToString(item)
2612
2373
  ).join(", ");
2613
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(SelectionText2, { children: [
2374
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(SelectionText2, { children: [
2614
2375
  text,
2615
2376
  overflowCount > 0 ? `, +${overflowCount}` : ""
2616
2377
  ] });
2617
- })() : /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(SearchableSelectPlaceholder, { children: placeholder }),
2618
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(SearchableSelectTriggerIcon, { style: { marginLeft: "auto" }, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(StyledChevron, { "data-chevron": true, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ChevronIcon, {}) }) })
2378
+ })() : /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(SearchableSelectPlaceholder, { children: placeholder }),
2379
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(SearchableSelectTriggerIcon, { style: { marginLeft: "auto" }, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(StyledChevron, { "data-chevron": true, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ChevronIcon, {}) }) })
2619
2380
  ]
2620
2381
  }
2621
2382
  ),
2622
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_combobox6.Combobox.Portal, { container: portalContainer, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ComboboxPositioner, { sideOffset: 4, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
2383
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_combobox6.Combobox.Portal, { container: portalContainer, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ComboboxPositioner, { sideOffset: 4, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
2623
2384
  SearchableSelectPopup,
2624
2385
  {
2625
2386
  "aria-busy": isLoading || void 0,
2626
2387
  style: { display: "flex", flexDirection: "column" },
2627
2388
  children: [
2628
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(SearchableSelectSearchContainer, { children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
2389
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(SearchableSelectSearchContainer, { children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
2629
2390
  SearchableSelectInput,
2630
2391
  {
2631
2392
  placeholder: searchPlaceholder,
2632
2393
  autoFocus: true
2633
2394
  }
2634
2395
  ) }),
2635
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ComboboxStatus, { children: isLoading ? loadingText : null }),
2636
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ComboboxEmpty, { children: isLoading ? null : emptyText }),
2637
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
2396
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ComboboxStatus, { children: isLoading ? loadingText : null }),
2397
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ComboboxEmpty, { children: isLoading ? null : emptyText }),
2398
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
2638
2399
  SearchableSelectList,
2639
2400
  {
2640
2401
  "aria-label": ariaLabel,
@@ -2646,7 +2407,7 @@ function MultiSearchableSelect(props) {
2646
2407
  display: "flex",
2647
2408
  flexDirection: "column"
2648
2409
  } : void 0,
2649
- children: isVirtualized ? /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
2410
+ children: isVirtualized ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
2650
2411
  VirtualizedComboboxList,
2651
2412
  {
2652
2413
  open,
@@ -2670,10 +2431,10 @@ function MultiSearchableSelect(props) {
2670
2431
  return renderCreatableItem(group);
2671
2432
  }
2672
2433
  const g = group;
2673
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(React12.Fragment, { children: [
2674
- /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(ComboboxGroup, { items: g.items, children: [
2675
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ComboboxGroupLabel, { children: renderGroupHeading ? renderGroupHeading(g.value) : g.value }),
2676
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_combobox6.Combobox.Collection, { children: (item) => /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
2434
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(React14.Fragment, { children: [
2435
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(ComboboxGroup, { items: g.items, children: [
2436
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ComboboxGroupLabel, { children: renderGroupHeading ? renderGroupHeading(g.value) : g.value }),
2437
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_combobox6.Combobox.Collection, { children: (item) => /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
2677
2438
  ComboboxItem_default,
2678
2439
  {
2679
2440
  value: item,
@@ -2686,14 +2447,14 @@ function MultiSearchableSelect(props) {
2686
2447
  item.id
2687
2448
  ) })
2688
2449
  ] }),
2689
- index < groups.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ComboboxSeparator, {})
2450
+ index < groups.length - 1 && /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ComboboxSeparator, {})
2690
2451
  ] }, g.value);
2691
2452
  }) : ((item) => {
2692
2453
  if (isCreatableSentinel(item)) {
2693
2454
  return renderCreatableItem(item);
2694
2455
  }
2695
2456
  const dataItem = item;
2696
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
2457
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
2697
2458
  ComboboxItem_default,
2698
2459
  {
2699
2460
  value: dataItem,
@@ -2718,153 +2479,141 @@ function MultiSearchableSelect(props) {
2718
2479
  }
2719
2480
 
2720
2481
  // src/v3/ActionMenu.tsx
2721
- var React13 = __toESM(require("react"));
2482
+ var React16 = __toESM(require("react"));
2722
2483
  var import_menu2 = require("@base-ui/react/menu");
2723
2484
  var import_seeds_react_radio3 = __toESM(require("@sproutsocial/seeds-react-radio"));
2724
2485
  var import_seeds_react_checkbox4 = __toESM(require("@sproutsocial/seeds-react-checkbox"));
2725
2486
  var import_seeds_react_icon5 = require("@sproutsocial/seeds-react-icon");
2726
2487
 
2727
2488
  // src/v3/ActionMenuStyles.tsx
2489
+ var React15 = __toESM(require("react"));
2728
2490
  var import_menu = require("@base-ui/react/menu");
2729
- var import_styled_components8 = __toESM(require("styled-components"));
2730
- var import_seeds_react_mixins3 = require("@sproutsocial/seeds-react-mixins");
2731
- var ActionMenuTrigger = (0, import_styled_components8.default)(import_menu.Menu.Trigger)``;
2732
- var ActionMenuPositioner = (0, import_styled_components8.default)(import_menu.Menu.Positioner)`
2733
- min-width: var(--anchor-width);
2734
- z-index: 7;
2735
- `;
2736
- var ActionMenuPopup = (0, import_styled_components8.default)(import_menu.Menu.Popup).attrs({
2737
- "data-base-ui-swipe-ignore": ""
2738
- })`
2739
- font-family: ${({ theme }) => theme.fontFamily};
2740
- background: ${({ theme }) => theme.colors.container.background.base};
2741
- border: 1px solid ${({ theme }) => theme.colors.container.border.base};
2742
- border-radius: ${({ theme }) => theme.radii[500]};
2743
- box-shadow: ${({ theme }) => theme.shadows.low};
2744
- outline: none;
2745
- max-height: min(var(--available-height, 400px), 400px);
2746
- overflow-y: auto;
2747
- padding: ${({ theme }) => theme.space[300]};
2748
-
2749
- &[data-open] {
2750
- animation: action-menu-popup-in 120ms ease-out;
2491
+ var import_jsx_runtime13 = require("react/jsx-runtime");
2492
+ var ActionMenuTrigger = import_menu.Menu.Trigger;
2493
+ var ActionMenuPositioner = React15.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
2494
+ import_menu.Menu.Positioner,
2495
+ {
2496
+ ref,
2497
+ className: cn("seeds-action-menu-positioner", className),
2498
+ ...rest
2751
2499
  }
2752
-
2753
- &[data-closed] {
2754
- animation: action-menu-popup-out 100ms ease-in;
2500
+ ));
2501
+ ActionMenuPositioner.displayName = "ActionMenuPositioner";
2502
+ var ActionMenuPopup = React15.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
2503
+ import_menu.Menu.Popup,
2504
+ {
2505
+ ref,
2506
+ "data-base-ui-swipe-ignore": "",
2507
+ className: cn("seeds-action-menu-popup", className),
2508
+ ...rest
2755
2509
  }
2756
-
2757
- @keyframes action-menu-popup-in {
2758
- from {
2759
- opacity: 0;
2760
- transform: scale(0.95);
2761
- }
2762
- to {
2763
- opacity: 1;
2764
- transform: scale(1);
2765
- }
2510
+ ));
2511
+ ActionMenuPopup.displayName = "ActionMenuPopup";
2512
+ var ActionMenuGroup = React15.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
2513
+ import_menu.Menu.Group,
2514
+ {
2515
+ ref,
2516
+ className: cn("seeds-action-menu-group", className),
2517
+ ...rest
2766
2518
  }
2767
-
2768
- @keyframes action-menu-popup-out {
2769
- from {
2770
- opacity: 1;
2771
- transform: scale(1);
2772
- }
2773
- to {
2774
- opacity: 0;
2775
- transform: scale(0.95);
2776
- }
2519
+ ));
2520
+ ActionMenuGroup.displayName = "ActionMenuGroup";
2521
+ var ActionMenuGroupLabel = React15.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
2522
+ import_menu.Menu.GroupLabel,
2523
+ {
2524
+ ref,
2525
+ className: cn("seeds-action-menu-group-label", className),
2526
+ ...rest
2777
2527
  }
2778
- `;
2779
- var ActionMenuGroup = (0, import_styled_components8.default)(import_menu.Menu.Group)`
2780
- display: block;
2781
- `;
2782
- var ActionMenuGroupLabel = (0, import_styled_components8.default)(import_menu.Menu.GroupLabel)`
2783
- padding: ${({ theme }) => `${theme.space[300]}`};
2784
- font-size: ${({ theme }) => theme.typography[100].fontSize};
2785
- color: ${({ theme }) => theme.colors.text.body};
2786
- `;
2787
- var ActionMenuSeparator = (0, import_styled_components8.default)(import_menu.Menu.Separator)`
2788
- height: 1px;
2789
- margin: ${({ theme }) => `${theme.space[300]} -${theme.space[300]}`};
2790
- background: ${({ theme }) => theme.colors.container.border.base};
2791
- `;
2792
- var menuItemStyles = import_styled_components8.css`
2793
- box-sizing: border-box;
2794
- display: block;
2795
- width: 100%;
2796
- border-radius: ${({ theme }) => theme.radii[500]};
2797
- background-color: ${({ theme }) => theme.colors.listItem.background.base};
2798
- border: 1px solid ${({ theme }) => theme.colors.listItem.background.base};
2799
- color: ${({ theme }) => theme.colors.text.body};
2800
- font-family: ${({ theme }) => theme.fontFamily};
2801
- font-weight: ${({ theme }) => theme.fontWeights.normal};
2802
- text-align: left;
2803
- text-decoration: none;
2804
- padding: ${({ theme }) => theme.space[300]};
2805
- outline: 0;
2806
- ${({ theme }) => theme.typography[200]};
2807
- transition: all ${({ theme }) => theme.duration.fast};
2808
- cursor: pointer;
2809
- user-select: none;
2810
-
2811
- &[data-highlighted] {
2812
- border-color: ${({ theme }) => theme.colors.listItem.border.base};
2813
- background-color: ${({ theme }) => theme.colors.listItem.background.hover};
2814
- color: ${({ theme }) => theme.colors.text.body};
2815
- text-decoration: none;
2528
+ ));
2529
+ ActionMenuGroupLabel.displayName = "ActionMenuGroupLabel";
2530
+ var ActionMenuSeparator = React15.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
2531
+ import_menu.Menu.Separator,
2532
+ {
2533
+ ref,
2534
+ className: cn("seeds-action-menu-separator", className),
2535
+ ...rest
2816
2536
  }
2817
-
2818
- &[data-disabled] {
2819
- cursor: not-allowed;
2820
- opacity: 0.4;
2821
- }
2822
- `;
2823
- var StyledMenuItem = (0, import_styled_components8.default)(import_menu.Menu.Item)`
2824
- ${menuItemStyles}
2825
- `;
2826
- var StyledCheckboxItem = (0, import_styled_components8.default)(import_menu.Menu.CheckboxItem)`
2827
- ${menuItemStyles}
2828
- display: flex;
2829
- align-items: center;
2830
- gap: ${({ theme }) => theme.space[300]};
2831
- `;
2832
- var StyledRadioItem = (0, import_styled_components8.default)(import_menu.Menu.RadioItem)`
2833
- ${menuItemStyles}
2834
- display: flex;
2835
- align-items: center;
2836
- gap: ${({ theme }) => theme.space[300]};
2837
- `;
2838
- var StyledCheckboxItemIndicator = (0, import_styled_components8.default)(import_menu.Menu.CheckboxItemIndicator)`
2839
- display: flex;
2840
- align-items: center;
2841
- width: 16px;
2842
- color: ${({ theme }) => theme.colors.text.body};
2843
- `;
2844
- var StyledRadioItemIndicator = (0, import_styled_components8.default)(import_menu.Menu.RadioItemIndicator)`
2845
- display: flex;
2846
- align-items: center;
2847
- width: 16px;
2848
- color: ${({ theme }) => theme.colors.text.body};
2849
- `;
2850
- var StyledSubmenuTrigger = (0, import_styled_components8.default)(import_menu.Menu.SubmenuTrigger)`
2851
- ${menuItemStyles}
2852
- display: flex;
2853
- align-items: center;
2854
- gap: ${({ theme }) => theme.space[300]};
2855
- justify-content: space-between;
2856
-
2857
- &[data-popup-open] {
2858
- border-color: ${({ theme }) => theme.colors.listItem.border.base};
2859
- background-color: ${({ theme }) => theme.colors.listItem.background.hover};
2860
- }
2861
- `;
2862
- var StyledLinkItem = (0, import_styled_components8.default)(import_menu.Menu.LinkItem)`
2863
- ${menuItemStyles}
2864
- `;
2537
+ ));
2538
+ ActionMenuSeparator.displayName = "ActionMenuSeparator";
2539
+ var StyledMenuItem = React15.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
2540
+ import_menu.Menu.Item,
2541
+ {
2542
+ ref,
2543
+ className: cn("seeds-action-menu-item", className),
2544
+ ...rest
2545
+ }
2546
+ ));
2547
+ StyledMenuItem.displayName = "StyledMenuItem";
2548
+ var StyledCheckboxItem = React15.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
2549
+ import_menu.Menu.CheckboxItem,
2550
+ {
2551
+ ref,
2552
+ className: cn(
2553
+ "seeds-action-menu-item",
2554
+ "seeds-action-menu-item--flex",
2555
+ className
2556
+ ),
2557
+ ...rest
2558
+ }
2559
+ ));
2560
+ StyledCheckboxItem.displayName = "StyledCheckboxItem";
2561
+ var StyledRadioItem = React15.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
2562
+ import_menu.Menu.RadioItem,
2563
+ {
2564
+ ref,
2565
+ className: cn(
2566
+ "seeds-action-menu-item",
2567
+ "seeds-action-menu-item--flex",
2568
+ className
2569
+ ),
2570
+ ...rest
2571
+ }
2572
+ ));
2573
+ StyledRadioItem.displayName = "StyledRadioItem";
2574
+ var StyledCheckboxItemIndicator = React15.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
2575
+ import_menu.Menu.CheckboxItemIndicator,
2576
+ {
2577
+ ref,
2578
+ className: cn("seeds-action-menu-item-indicator", className),
2579
+ ...rest
2580
+ }
2581
+ ));
2582
+ StyledCheckboxItemIndicator.displayName = "StyledCheckboxItemIndicator";
2583
+ var StyledRadioItemIndicator = React15.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
2584
+ import_menu.Menu.RadioItemIndicator,
2585
+ {
2586
+ ref,
2587
+ className: cn("seeds-action-menu-item-indicator", className),
2588
+ ...rest
2589
+ }
2590
+ ));
2591
+ StyledRadioItemIndicator.displayName = "StyledRadioItemIndicator";
2592
+ var StyledSubmenuTrigger = React15.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
2593
+ import_menu.Menu.SubmenuTrigger,
2594
+ {
2595
+ ref,
2596
+ className: cn(
2597
+ "seeds-action-menu-item",
2598
+ "seeds-action-menu-submenu-trigger",
2599
+ className
2600
+ ),
2601
+ ...rest
2602
+ }
2603
+ ));
2604
+ StyledSubmenuTrigger.displayName = "StyledSubmenuTrigger";
2605
+ var StyledLinkItem = React15.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
2606
+ import_menu.Menu.LinkItem,
2607
+ {
2608
+ ref,
2609
+ className: cn("seeds-action-menu-item", className),
2610
+ ...rest
2611
+ }
2612
+ ));
2613
+ StyledLinkItem.displayName = "StyledLinkItem";
2865
2614
 
2866
2615
  // src/v3/ActionMenu.tsx
2867
- var import_jsx_runtime12 = require("react/jsx-runtime");
2616
+ var import_jsx_runtime14 = require("react/jsx-runtime");
2868
2617
  function ActionMenu({
2869
2618
  trigger,
2870
2619
  children,
@@ -2874,16 +2623,16 @@ function ActionMenu({
2874
2623
  disabled
2875
2624
  }) {
2876
2625
  const { containerRef, portalContainer } = useSeedsPortalContainer();
2877
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
2626
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
2878
2627
  import_menu2.Menu.Root,
2879
2628
  {
2880
2629
  open,
2881
2630
  defaultOpen,
2882
2631
  onOpenChange,
2883
2632
  children: [
2884
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { ref: containerRef, style: { position: "relative" } }),
2885
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ActionMenuTrigger, { render: trigger, disabled }),
2886
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_menu2.Menu.Portal, { container: portalContainer, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ActionMenuPositioner, { sideOffset: 8, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ActionMenuPopup, { children }) }) })
2633
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { ref: containerRef, style: { position: "relative" } }),
2634
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(ActionMenuTrigger, { render: trigger, disabled }),
2635
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_menu2.Menu.Portal, { container: portalContainer, children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(ActionMenuPositioner, { sideOffset: 8, children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(ActionMenuPopup, { children }) }) })
2887
2636
  ]
2888
2637
  }
2889
2638
  );
@@ -2893,12 +2642,12 @@ function MenuGroup({
2893
2642
  label,
2894
2643
  showSeparator = false
2895
2644
  }) {
2896
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(import_jsx_runtime12.Fragment, { children: [
2897
- /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(ActionMenuGroup, { children: [
2898
- label && /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ActionMenuGroupLabel, { children: label }),
2645
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(import_jsx_runtime14.Fragment, { children: [
2646
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(ActionMenuGroup, { children: [
2647
+ label && /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(ActionMenuGroupLabel, { children: label }),
2899
2648
  children
2900
2649
  ] }),
2901
- showSeparator && /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ActionMenuSeparator, {})
2650
+ showSeparator && /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(ActionMenuSeparator, {})
2902
2651
  ] });
2903
2652
  }
2904
2653
  function MenuRadioGroup({
@@ -2907,7 +2656,7 @@ function MenuRadioGroup({
2907
2656
  defaultValue,
2908
2657
  onValueChange
2909
2658
  }) {
2910
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
2659
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
2911
2660
  import_menu2.Menu.RadioGroup,
2912
2661
  {
2913
2662
  value,
@@ -2918,7 +2667,7 @@ function MenuRadioGroup({
2918
2667
  );
2919
2668
  }
2920
2669
  function MenuItem(props) {
2921
- const generatedId = React13.useId();
2670
+ const generatedId = React16.useId();
2922
2671
  if (props.type === "checkbox") {
2923
2672
  const {
2924
2673
  children: children2,
@@ -2930,7 +2679,7 @@ function MenuItem(props) {
2930
2679
  id
2931
2680
  } = props;
2932
2681
  const itemId = id ?? `checkbox-menu-item-${generatedId}`;
2933
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
2682
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
2934
2683
  StyledCheckboxItem,
2935
2684
  {
2936
2685
  checked,
@@ -2939,11 +2688,11 @@ function MenuItem(props) {
2939
2688
  disabled: disabled2,
2940
2689
  closeOnClick: closeOnClick2,
2941
2690
  children: [
2942
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
2691
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
2943
2692
  StyledCheckboxItemIndicator,
2944
2693
  {
2945
2694
  keepMounted: true,
2946
- render: (_indicatorProps, state) => /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
2695
+ render: (_indicatorProps, state) => /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
2947
2696
  import_seeds_react_checkbox4.default,
2948
2697
  {
2949
2698
  checked: state.checked,
@@ -2963,18 +2712,18 @@ function MenuItem(props) {
2963
2712
  }
2964
2713
  if (props.type === "radio") {
2965
2714
  const { children: children2, value, disabled: disabled2, closeOnClick: closeOnClick2 = false } = props;
2966
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
2715
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
2967
2716
  StyledRadioItem,
2968
2717
  {
2969
2718
  value,
2970
2719
  disabled: disabled2,
2971
2720
  closeOnClick: closeOnClick2,
2972
2721
  children: [
2973
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
2722
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
2974
2723
  StyledRadioItemIndicator,
2975
2724
  {
2976
2725
  keepMounted: true,
2977
- render: (_indicatorProps, state) => /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
2726
+ render: (_indicatorProps, state) => /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
2978
2727
  import_seeds_react_radio3.default,
2979
2728
  {
2980
2729
  checked: state.checked,
@@ -3001,9 +2750,9 @@ function MenuItem(props) {
3001
2750
  target
3002
2751
  } = props;
3003
2752
  if (href) {
3004
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(StyledLinkItem, { href, target, closeOnClick, children });
2753
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(StyledLinkItem, { href, target, closeOnClick, children });
3005
2754
  }
3006
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
2755
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
3007
2756
  StyledMenuItem,
3008
2757
  {
3009
2758
  onClick,
@@ -3022,7 +2771,7 @@ function MenuSub({
3022
2771
  closeParentOnEsc = false
3023
2772
  }) {
3024
2773
  const { containerRef, portalContainer } = useSeedsPortalContainer();
3025
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
2774
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
3026
2775
  import_menu2.Menu.SubmenuRoot,
3027
2776
  {
3028
2777
  open,
@@ -3030,9 +2779,9 @@ function MenuSub({
3030
2779
  onOpenChange,
3031
2780
  closeParentOnEsc,
3032
2781
  children: [
3033
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { ref: containerRef, style: { position: "relative" } }),
2782
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { ref: containerRef, style: { position: "relative" } }),
3034
2783
  trigger,
3035
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_menu2.Menu.Portal, { container: portalContainer, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ActionMenuPositioner, { sideOffset: getOffset, alignOffset: getOffset, children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(ActionMenuPopup, { children }) }) })
2784
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_menu2.Menu.Portal, { container: portalContainer, children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(ActionMenuPositioner, { sideOffset: getOffset, alignOffset: getOffset, children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(ActionMenuPopup, { children }) }) })
3036
2785
  ]
3037
2786
  }
3038
2787
  );
@@ -3046,7 +2795,7 @@ function MenuSubTrigger({
3046
2795
  label,
3047
2796
  openOnHover = true
3048
2797
  }) {
3049
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
2798
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(
3050
2799
  StyledSubmenuTrigger,
3051
2800
  {
3052
2801
  disabled,
@@ -3054,47 +2803,53 @@ function MenuSubTrigger({
3054
2803
  openOnHover,
3055
2804
  children: [
3056
2805
  children,
3057
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_seeds_react_icon5.Icon, { name: "chevron-right-outline", fixedWidth: true, "aria-hidden": true })
2806
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_seeds_react_icon5.Icon, { name: "chevron-right-outline", fixedWidth: true, "aria-hidden": true })
3058
2807
  ]
3059
2808
  }
3060
2809
  );
3061
2810
  }
3062
2811
 
3063
2812
  // src/v3/MenuButton.tsx
3064
- var React14 = require("react");
2813
+ var React18 = require("react");
3065
2814
  var import_seeds_react_button2 = require("@sproutsocial/seeds-react-button");
3066
2815
  var import_seeds_react_icon6 = require("@sproutsocial/seeds-react-icon");
3067
2816
 
3068
2817
  // src/v3/MenuButtonStyles.tsx
3069
- var import_styled_components9 = __toESM(require("styled-components"));
2818
+ var React17 = __toESM(require("react"));
3070
2819
  var import_seeds_react_button = require("@sproutsocial/seeds-react-button");
3071
- var MenuButtonContainer = import_styled_components9.default.div`
3072
- display: inline-flex;
3073
- gap: 1px;
3074
- `;
3075
- var MainButton = (0, import_styled_components9.default)(import_seeds_react_button.Button)`
3076
- && {
3077
- border-top-right-radius: 0;
3078
- border-bottom-right-radius: 0;
3079
- }
3080
- `;
3081
- var TriggerButton = (0, import_styled_components9.default)(import_seeds_react_button.Button)`
3082
- && {
3083
- border-top-left-radius: 0;
3084
- border-bottom-left-radius: 0;
3085
- }
3086
-
3087
- .Icon-svg {
3088
- transition: transform ${({ theme }) => theme.duration.fast} ease;
2820
+ var import_jsx_runtime15 = require("react/jsx-runtime");
2821
+ var MenuButtonContainer = React17.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
2822
+ "div",
2823
+ {
2824
+ ref,
2825
+ className: cn("seeds-menu-button-container", className),
2826
+ ...rest
3089
2827
  }
3090
-
3091
- &[data-popup-open] .Icon-svg {
3092
- transform: rotate(180deg);
2828
+ ));
2829
+ MenuButtonContainer.displayName = "MenuButtonContainer";
2830
+ var MainButton = React17.forwardRef(
2831
+ ({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
2832
+ import_seeds_react_button.Button,
2833
+ {
2834
+ ref,
2835
+ className: cn("seeds-menu-button-main", className),
2836
+ ...rest
2837
+ }
2838
+ )
2839
+ );
2840
+ MainButton.displayName = "MainButton";
2841
+ var TriggerButton = React17.forwardRef(({ className, ...rest }, ref) => /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
2842
+ import_seeds_react_button.Button,
2843
+ {
2844
+ ref,
2845
+ className: cn("seeds-menu-button-trigger", className),
2846
+ ...rest
3093
2847
  }
3094
- `;
2848
+ ));
2849
+ TriggerButton.displayName = "TriggerButton";
3095
2850
 
3096
2851
  // src/v3/MenuButton.tsx
3097
- var import_jsx_runtime13 = require("react/jsx-runtime");
2852
+ var import_jsx_runtime16 = require("react/jsx-runtime");
3098
2853
  function MenuButton({
3099
2854
  actionMenu,
3100
2855
  appearance = "primary",
@@ -3104,8 +2859,8 @@ function MenuButton({
3104
2859
  children,
3105
2860
  ...rest
3106
2861
  }) {
3107
- return /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(MenuButtonContainer, { children: [
3108
- /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
2862
+ return /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(MenuButtonContainer, { children: [
2863
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
3109
2864
  MainButton,
3110
2865
  {
3111
2866
  appearance,
@@ -3115,18 +2870,18 @@ function MenuButton({
3115
2870
  children
3116
2871
  }
3117
2872
  ),
3118
- /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
2873
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
3119
2874
  ActionMenu,
3120
2875
  {
3121
2876
  disabled,
3122
- trigger: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
2877
+ trigger: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
3123
2878
  TriggerButton,
3124
2879
  {
3125
2880
  appearance,
3126
2881
  size,
3127
2882
  disabled,
3128
2883
  ariaLabel: menuButtonAriaLabel,
3129
- children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_seeds_react_icon6.Icon, { name: "chevron-down-outline", fixedWidth: true, "aria-hidden": true })
2884
+ children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_seeds_react_icon6.Icon, { name: "chevron-down-outline", fixedWidth: true, "aria-hidden": true })
3130
2885
  }
3131
2886
  ),
3132
2887
  children: actionMenu