@box/user-selector 1.74.32 → 1.74.34

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 (29) hide show
  1. package/dist/chunks/buildOptionsWithOverlay.js +21 -22
  2. package/dist/chunks/user-selector-headless.module.js +13 -14
  3. package/dist/chunks/user-selector-list-item.js +84 -0
  4. package/dist/chunks/user-selector.js +89 -0
  5. package/dist/esm/index.js +4 -9
  6. package/dist/esm/lib/messages.js +42 -44
  7. package/dist/esm/lib/shared.js +6 -8
  8. package/dist/esm/lib/user-selector-container.js +29 -42
  9. package/dist/esm/lib/user-selector-headless/components/user-avatar.js +25 -31
  10. package/dist/esm/lib/user-selector-headless/components/user-selector-content.js +27 -50
  11. package/dist/esm/lib/user-selector-headless/components/user-selector-default-empty.js +34 -42
  12. package/dist/esm/lib/user-selector-headless/components/user-selector-default-error.js +13 -19
  13. package/dist/esm/lib/user-selector-headless/components/user-selector-skeleton.js +19 -25
  14. package/dist/esm/lib/user-selector-headless/hooks/use-avatars.js +13 -21
  15. package/dist/esm/lib/user-selector-headless/hooks/use-keyboard-navigation.js +25 -27
  16. package/dist/esm/lib/user-selector-headless/hooks/use-select-options.js +24 -27
  17. package/dist/esm/lib/user-selector-headless/user-selector-context.js +6 -10
  18. package/dist/esm/lib/user-selector-headless/user-selector-headless.js +171 -167
  19. package/dist/esm/lib/user-selector-list-item.js +2 -113
  20. package/dist/esm/lib/user-selector.js +2 -108
  21. package/dist/esm/lib/utils/VariantsAggregator.js +26 -45
  22. package/dist/esm/lib/utils/buildOptionsWithOverlay.js +2 -4
  23. package/dist/esm/lib/utils/defaultRenderCustomOption.js +10 -11
  24. package/dist/esm/lib/utils/getInitials.js +4 -6
  25. package/dist/esm/lib/utils/isUserContactType.js +3 -5
  26. package/dist/styles/user-selector-headless.css +1 -1
  27. package/dist/styles/user-selector-list-item.css +1 -1
  28. package/dist/styles/user-selector.css +1 -1
  29. package/package.json +8 -8
@@ -1,168 +1,172 @@
1
- import { Popover as m } from "@box/blueprint-web";
2
- import J from "clsx";
3
- import { forwardRef as Q, useState as W, useId as X, useRef as Y, useMemo as K, useCallback as i, useImperativeHandle as Z, useEffect as _ } from "react";
4
- import { UserSelectorContent as F } from "./components/user-selector-content.js";
5
- import { useAvatars as U } from "./hooks/use-avatars.js";
6
- import { useKeyboardNavigation as E } from "./hooks/use-keyboard-navigation.js";
7
- import { useSelectOptions as tt } from "./hooks/use-select-options.js";
8
- import { UserSelectorContext as ot } from "./user-selector-context.js";
9
- import { s as M } from "../../../chunks/user-selector-headless.module.js";
10
- import { jsx as f, jsxs as et } from "react/jsx-runtime";
11
- const mt = /* @__PURE__ */ Q(({
12
- fetchUsers: g,
13
- fetchAvatarUrls: w,
14
- open: d,
15
- value: y,
16
- rootElement: R,
17
- onSelectedUserChange: a,
18
- inputElementRef: N,
19
- focusOnOpen: A = !1,
20
- renderError: $,
21
- renderEmpty: H,
22
- loadingAriaLabel: L,
23
- ariaRoleDescription: P,
24
- nativeFocusEnabled: c = !0,
25
- allowEmptyQuery: V = !1,
26
- onInvite: q,
27
- popoverContentContainerProps: b
28
- }, S) => {
29
- const [s, I] = W(null), {
30
- options: t,
31
- isEmpty: j,
32
- isLoading: k,
33
- error: C
34
- } = tt({
35
- fetcher: g,
36
- value: y,
37
- allowEmptyQuery: V
38
- }), {
39
- avatars: T
40
- } = U({
41
- fetchAvatarUrls: w,
42
- options: t
43
- }), u = X(), h = Y(/* @__PURE__ */ new Map()), D = K(() => `listbox-${u}`, [u]), e = i((o) => `${u}-option-${o.id}`, [u]), n = i((o) => {
44
- const r = h.current.get(o);
45
- if (r) {
46
- if (I(o), c) {
47
- r.focus();
48
- return;
49
- }
50
- r.scrollIntoView({
51
- behavior: "smooth",
52
- block: "nearest",
53
- inline: "nearest"
54
- });
55
- }
56
- }, [c]), l = K(() => t.findIndex((o) => e(o) === s), [s, e, t]), p = i(() => {
57
- N.current?.focus(), I(null);
58
- }, [N]), x = i(() => {
59
- if (s) {
60
- const o = t.find((r) => e(r) === s);
61
- o && a(o);
62
- }
63
- }, [a, s, e, t]), v = i(() => {
64
- if (t.length === 0)
65
- return;
66
- if (l < t.length - 1) {
67
- const r = e(t[l + 1]);
68
- n(r);
69
- return;
70
- }
71
- if (c) {
72
- p();
73
- return;
74
- }
75
- const o = e(t[0]);
76
- n(o);
77
- }, [l, n, e, t, c, p]), O = i(() => {
78
- if (t.length === 0)
79
- return;
80
- if (l > 0) {
81
- const r = e(t[l - 1]);
82
- n(r);
83
- return;
84
- }
85
- if (c) {
86
- p();
87
- return;
88
- }
89
- const o = e(t[t.length - 1]);
90
- n(o);
91
- }, [l, n, e, t, c, p]), z = E({
92
- isLoading: k,
93
- error: C,
94
- isEmpty: j,
95
- open: d,
96
- selectNext: v,
97
- selectPrevious: O,
98
- selectItem: x
99
- }), B = i((o, r) => {
100
- n(r), a(o);
101
- }, [n, a]);
102
- Z(S, () => ({
103
- focusFirstOption: () => {
104
- t.length > 0 && n(e(t[0]));
105
- },
106
- focusLastOption: () => {
107
- t.length > 0 && n(e(t[t.length - 1]));
108
- },
109
- selectNext: v,
110
- selectPrevious: O,
111
- selectItem: x
112
- }), [n, e, t, v, O, x]), _(() => {
113
- t.length > 0 && A && n(e(t[0]));
114
- }, [t, d, e, n, A]);
115
- const G = {
116
- fetchUsers: g,
117
- fetchAvatarUrls: w,
118
- onSelectedUserChange: a,
119
- value: y,
120
- avatars: T,
121
- activeId: s,
122
- setActiveId: I,
123
- listboxId: D,
124
- getOptionId: e
125
- };
126
- return /* @__PURE__ */ f(ot.Provider, {
127
- value: G,
128
- children: /* @__PURE__ */ et(m.Root, {
129
- modal: !1,
130
- open: d,
131
- children: [/* @__PURE__ */ f(m.Anchor, {
132
- children: R
133
- }), /* @__PURE__ */ f(m.ContentContainer, {
134
- ...b,
135
- align: "start",
136
- className: J(M.popoverContainer, b?.className),
137
- onOpenAutoFocus: (o) => {
138
- o.preventDefault();
139
- },
140
- children: /* @__PURE__ */ f(m.MainContent, {
141
- "aria-activedescendant": s,
142
- "aria-owns": Array.from(h.current.values()).map((o) => o.id).join(" "),
143
- "aria-roledescription": P,
144
- className: M.popoverContent,
145
- id: D,
146
- onKeyDown: z,
147
- role: "listbox",
148
- tabIndex: -1,
149
- children: /* @__PURE__ */ f(F, {
150
- error: C,
151
- handleInvite: q,
152
- handleOptionClick: B,
153
- isEmpty: j,
154
- isLoading: k,
155
- loadingAriaLabel: L,
156
- optionRefs: h,
157
- options: t,
158
- renderEmpty: H,
159
- renderError: $
160
- })
161
- })
162
- })]
163
- })
164
- });
1
+ import { UserSelectorContext as e } from "./user-selector-context.js";
2
+ import { t } from "../../../chunks/user-selector-headless.module.js";
3
+ import { UserSelectorContent as n } from "./components/user-selector-content.js";
4
+ import { useAvatars as r } from "./hooks/use-avatars.js";
5
+ import { useKeyboardNavigation as i } from "./hooks/use-keyboard-navigation.js";
6
+ import { useSelectOptions as a } from "./hooks/use-select-options.js";
7
+ import { forwardRef as o, useCallback as s, useEffect as c, useId as l, useImperativeHandle as u, useMemo as d, useRef as f, useState as p } from "react";
8
+ import m from "clsx";
9
+ import { Popover as h } from "@box/blueprint-web";
10
+ import { jsx as g, jsxs as _ } from "react/jsx-runtime";
11
+ var v = /* @__PURE__ */ o(({ fetchUsers: o, fetchAvatarUrls: v, open: y, value: b, rootElement: x, onSelectedUserChange: S, inputElementRef: C, focusOnOpen: w = !1, renderError: T, renderEmpty: E, loadingAriaLabel: D, ariaRoleDescription: O, nativeFocusEnabled: k = !0, allowEmptyQuery: A = !1, onInvite: j, popoverContentContainerProps: M }, N) => {
12
+ let [P, F] = p(null), { options: I, isEmpty: L, isLoading: R, error: z } = a({
13
+ fetcher: o,
14
+ value: b,
15
+ allowEmptyQuery: A
16
+ }), { avatars: B } = r({
17
+ fetchAvatarUrls: v,
18
+ options: I
19
+ }), V = l(), H = f(/* @__PURE__ */ new Map()), U = d(() => `listbox-${V}`, [V]), W = s((e) => `${V}-option-${e.id}`, [V]), G = s((e) => {
20
+ let t = H.current.get(e);
21
+ if (t) {
22
+ if (F(e), k) {
23
+ t.focus();
24
+ return;
25
+ }
26
+ t.scrollIntoView({
27
+ behavior: "smooth",
28
+ block: "nearest",
29
+ inline: "nearest"
30
+ });
31
+ }
32
+ }, [k]), K = d(() => I.findIndex((e) => W(e) === P), [
33
+ P,
34
+ W,
35
+ I
36
+ ]), q = s(() => {
37
+ C.current?.focus(), F(null);
38
+ }, [C]), J = s(() => {
39
+ if (P) {
40
+ let e = I.find((e) => W(e) === P);
41
+ e && S(e);
42
+ }
43
+ }, [
44
+ S,
45
+ P,
46
+ W,
47
+ I
48
+ ]), Y = s(() => {
49
+ if (I.length !== 0) {
50
+ if (K < I.length - 1) {
51
+ G(W(I[K + 1]));
52
+ return;
53
+ }
54
+ if (k) {
55
+ q();
56
+ return;
57
+ }
58
+ G(W(I[0]));
59
+ }
60
+ }, [
61
+ K,
62
+ G,
63
+ W,
64
+ I,
65
+ k,
66
+ q
67
+ ]), X = s(() => {
68
+ if (I.length !== 0) {
69
+ if (K > 0) {
70
+ G(W(I[K - 1]));
71
+ return;
72
+ }
73
+ if (k) {
74
+ q();
75
+ return;
76
+ }
77
+ G(W(I[I.length - 1]));
78
+ }
79
+ }, [
80
+ K,
81
+ G,
82
+ W,
83
+ I,
84
+ k,
85
+ q
86
+ ]), Z = i({
87
+ isLoading: R,
88
+ error: z,
89
+ isEmpty: L,
90
+ open: y,
91
+ selectNext: Y,
92
+ selectPrevious: X,
93
+ selectItem: J
94
+ }), Q = s((e, t) => {
95
+ G(t), S(e);
96
+ }, [G, S]);
97
+ u(N, () => ({
98
+ focusFirstOption: () => {
99
+ I.length > 0 && G(W(I[0]));
100
+ },
101
+ focusLastOption: () => {
102
+ I.length > 0 && G(W(I[I.length - 1]));
103
+ },
104
+ selectNext: Y,
105
+ selectPrevious: X,
106
+ selectItem: J
107
+ }), [
108
+ G,
109
+ W,
110
+ I,
111
+ Y,
112
+ X,
113
+ J
114
+ ]), c(() => {
115
+ I.length > 0 && w && G(W(I[0]));
116
+ }, [
117
+ I,
118
+ y,
119
+ W,
120
+ G,
121
+ w
122
+ ]);
123
+ let $ = {
124
+ fetchUsers: o,
125
+ fetchAvatarUrls: v,
126
+ onSelectedUserChange: S,
127
+ value: b,
128
+ avatars: B,
129
+ activeId: P,
130
+ setActiveId: F,
131
+ listboxId: U,
132
+ getOptionId: W
133
+ };
134
+ return /* @__PURE__ */ g(e.Provider, {
135
+ value: $,
136
+ children: /* @__PURE__ */ _(h.Root, {
137
+ modal: !1,
138
+ open: y,
139
+ children: [/* @__PURE__ */ g(h.Anchor, { children: x }), /* @__PURE__ */ g(h.ContentContainer, {
140
+ ...M,
141
+ align: "start",
142
+ className: m(t.popoverContainer, M?.className),
143
+ onOpenAutoFocus: (e) => {
144
+ e.preventDefault();
145
+ },
146
+ children: /* @__PURE__ */ g(h.MainContent, {
147
+ "aria-activedescendant": P,
148
+ "aria-owns": Array.from(H.current.values()).map((e) => e.id).join(" "),
149
+ "aria-roledescription": O,
150
+ className: t.popoverContent,
151
+ id: U,
152
+ onKeyDown: Z,
153
+ role: "listbox",
154
+ tabIndex: -1,
155
+ children: /* @__PURE__ */ g(n, {
156
+ error: z,
157
+ handleInvite: j,
158
+ handleOptionClick: Q,
159
+ isEmpty: L,
160
+ isLoading: R,
161
+ loadingAriaLabel: D,
162
+ optionRefs: H,
163
+ options: I,
164
+ renderEmpty: E,
165
+ renderError: T
166
+ })
167
+ })
168
+ })]
169
+ })
170
+ });
165
171
  });
166
- export {
167
- mt as UserSelectorHeadless
168
- };
172
+ export { v as UserSelectorHeadless };
@@ -1,113 +1,2 @@
1
- import { Combobox as L, Text as p, Tooltip as x } from "@box/blueprint-web";
2
- import { AvatarPlusBadge as b } from "@box/blueprint-web-assets/icons/Line";
3
- import a from "clsx";
4
- import C, { forwardRef as d } from "react";
5
- import { useIntl as v } from "react-intl";
6
- import S from "./messages.js";
7
- import { isUserContactType as O } from "./utils/isUserContactType.js";
8
- import { jsx as r, jsxs as _ } from "react/jsx-runtime";
9
- import '../../styles/user-selector-list-item.css';const U = "_userSelectorListItem_1m2q6_1", q = "_listItemAvatar_1m2q6_18", A = "_userInfo_1m2q6_21", g = "_title_1m2q6_28", E = "_userName_1m2q6_34", T = "_userEmail_1m2q6_35", k = "_userSelectorListItemInviteIcon_1m2q6_43", o = {
10
- userSelectorListItem: U,
11
- listItemAvatar: q,
12
- userInfo: A,
13
- title: g,
14
- userName: E,
15
- userEmail: T,
16
- userSelectorListItemInviteIcon: k
17
- }, y = /* @__PURE__ */ d(({
18
- renderAvatar: c,
19
- title: t,
20
- subtitle: m,
21
- onClick: s,
22
- className: e,
23
- id: n,
24
- selected: u,
25
- isCollaborator: i = !0,
26
- ...l
27
- }, I) => {
28
- const h = /* @__PURE__ */ C.cloneElement(c(), {
29
- className: a(o.listItemAvatar)
30
- }), {
31
- formatMessage: N
32
- } = v(), f = /* @__PURE__ */ _("div", {
33
- ref: I,
34
- "aria-selected": u,
35
- className: a(o.userSelectorListItem, e),
36
- id: n,
37
- ...s ? {
38
- onClick: s
39
- } : {},
40
- ...l,
41
- children: [h, /* @__PURE__ */ _("div", {
42
- className: a(o.userInfo),
43
- children: [/* @__PURE__ */ r("div", {
44
- className: a(o.title),
45
- children: /* @__PURE__ */ r(p, {
46
- as: "span",
47
- className: a(o.userName),
48
- variant: "bodyDefaultSemibold",
49
- children: t
50
- })
51
- }), /* @__PURE__ */ r(p, {
52
- as: "span",
53
- className: a(o.userEmail),
54
- color: "textOnLightSecondary",
55
- variant: "caption",
56
- children: m
57
- })]
58
- }), !i && /* @__PURE__ */ r(b, {
59
- className: o.userSelectorListItemInviteIcon
60
- })]
61
- });
62
- return i ? f : /* @__PURE__ */ r(x, {
63
- content: N(S.inviteCollaboratorsTooltip),
64
- side: "right",
65
- children: f
66
- });
67
- }), j = /* @__PURE__ */ d(({
68
- renderAvatar: c,
69
- userContact: t,
70
- onClick: m,
71
- id: s,
72
- ...e
73
- }, n) => {
74
- const i = v().formatMessage(S.userName, {
75
- name: t.name,
76
- isCurrentUser: !!t.isCurrentUser
77
- });
78
- return /* @__PURE__ */ r(y, {
79
- ref: n,
80
- id: s,
81
- onClick: () => {
82
- m?.(t, s);
83
- },
84
- renderAvatar: () => c(t),
85
- subtitle: t.email,
86
- title: i,
87
- ...e
88
- });
89
- }), G = /* @__PURE__ */ d(function(t, m) {
90
- const {
91
- className: s,
92
- userContact: e,
93
- renderAvatar: n,
94
- renderCustomOption: u,
95
- ...i
96
- } = t, l = O(e), I = l ? !0 : e.hideOnClick ?? !0;
97
- return /* @__PURE__ */ r(L.Option, {
98
- ref: m,
99
- className: s,
100
- hideOnClick: I,
101
- value: e.value,
102
- ...i,
103
- children: l ? /* @__PURE__ */ r(j, {
104
- renderAvatar: n,
105
- userContact: e
106
- }) : u(e, () => n(e))
107
- });
108
- });
109
- export {
110
- G as UserSelectorComboboxOption,
111
- j as UserSelectorListItem,
112
- y as UserSelectorListItemInfo
113
- };
1
+ import { n as e, r as t, t as n } from "../../chunks/user-selector-list-item.js";
2
+ export { n as UserSelectorComboboxOption, e as UserSelectorListItem, t as UserSelectorListItemInfo };
@@ -1,108 +1,2 @@
1
- import H from "clsx";
2
- import { useCallback as z } from "react";
3
- import { useIntl as D } from "react-intl";
4
- import { Combobox as p, Text as M, Divider as N, Avatar as h, IconBadge as T } from "@box/blueprint-web";
5
- import { ComboboxWithApi as W } from "@box/combobox-with-api";
6
- import u from "./messages.js";
7
- import { b as w, O as b, a as y } from "../../chunks/buildOptionsWithOverlay.js";
8
- import { UserSelectorComboboxOption as Y } from "./user-selector-list-item.js";
9
- import { defaultRenderCustomOption as j } from "./utils/defaultRenderCustomOption.js";
10
- import { getInitials as k } from "./utils/getInitials.js";
11
- import { isUserContactType as O } from "./utils/isUserContactType.js";
12
- import { jsx as r } from "react/jsx-runtime";
13
- import '../../styles/user-selector.css';const B = "_overlayHeader_zdn0a_1", P = "_overlaySeparatorOption_zdn0a_8", q = "_textArea_zdn0a_15", m = {
14
- overlayHeader: B,
15
- overlaySeparatorOption: P,
16
- textArea: q
17
- }, se = (x) => {
18
- const {
19
- fetchedAvatarUrls: A,
20
- fetchUsers: v,
21
- onSelectedUsersChange: g,
22
- selectedUsers: i,
23
- variant: _,
24
- className: C,
25
- defaultOptions: S,
26
- overlayDividerIndex: a,
27
- overlayTitle: c,
28
- renderCustomOption: U = j,
29
- ...V
30
- } = x, d = D(), f = (e) => {
31
- if (!(e.value === b || e.value === y)) {
32
- if (O(e)) {
33
- const {
34
- name: t,
35
- isExternalUser: l,
36
- id: n
37
- } = e, s = /* @__PURE__ */ r(h, {
38
- alt: d.formatMessage(u.userAvatar),
39
- colorIndex: n,
40
- src: A[n],
41
- text: k(t)
42
- });
43
- return l ? /* @__PURE__ */ r(T, {
44
- offset: {
45
- right: -4,
46
- bottom: -2
47
- },
48
- size: "medium",
49
- variant: "collaborator-external",
50
- children: s
51
- }) : s;
52
- }
53
- return /* @__PURE__ */ r(h, {
54
- ...e.avatar
55
- });
56
- }
57
- }, E = (e) => {
58
- if (!O(e))
59
- return e.chipVariant;
60
- }, R = z(async (e) => {
61
- const t = await v(e);
62
- if (!c || a === void 0 || a === null || a < 0)
63
- return t;
64
- const l = new Set(i.map((o) => o.value)), n = t.filter((o) => !l.has(o.value)), s = t.slice(0, a + 1).filter((o) => !l.has(o.value)).length, L = s > 0 ? s - 1 : -1;
65
- return w(n, c, L);
66
- }, [v, c, a, i]), I = (e) => e.value === b && "label" in e ? /* @__PURE__ */ r(p.Option, {
67
- className: m.overlayHeader,
68
- disabled: !0,
69
- value: e.value,
70
- children: /* @__PURE__ */ r(M, {
71
- as: "span",
72
- variant: "bodySmallSemibold",
73
- color: "textOnLightSecondary",
74
- children: e.label
75
- })
76
- }) : e.value === y ? /* @__PURE__ */ r(p.Option, {
77
- className: m.overlaySeparatorOption,
78
- disabled: !0,
79
- value: e.value,
80
- children: /* @__PURE__ */ r(N, {
81
- "aria-hidden": !0
82
- })
83
- }) : /* @__PURE__ */ r(Y, {
84
- renderAvatar: f,
85
- renderCustomOption: U,
86
- userContact: e
87
- });
88
- return /* @__PURE__ */ r(W, {
89
- as: "input",
90
- className: H(C, _ === "textarea" && m.textArea),
91
- defaultOptions: S,
92
- displayAvatar: f,
93
- displayChipVariant: E,
94
- displayValue: (e) => e.name,
95
- fetcher: R,
96
- freeInput: !1,
97
- loadingAriaLabel: d.formatMessage(u.loading),
98
- multiselect: !0,
99
- noResultMessage: d.formatMessage(u.noResults),
100
- onValueChange: g,
101
- renderOption: I,
102
- value: i,
103
- ...V
104
- });
105
- };
106
- export {
107
- se as default
108
- };
1
+ import { t as e } from "../../chunks/user-selector.js";
2
+ export { e as default };
@@ -1,46 +1,27 @@
1
- import { Text as d } from "@box/blueprint-web";
2
- import { Fragment as m } from "react";
3
- import { jsx as r, jsxs as c } from "react/jsx-runtime";
4
- const g = ({
5
- defaultProps: t,
6
- DefaultComponentTemplate: s,
7
- variantsMap: n,
8
- containerStyle: o
9
- }) => {
10
- const l = Object.entries(n);
11
- return /* @__PURE__ */ r("div", {
12
- style: {
13
- display: "grid",
14
- gridTemplateColumns: "auto auto",
15
- alignItems: "baseline",
16
- gap: "254px 12px",
17
- ...o
18
- },
19
- children: l.map(([a, {
20
- props: e = {},
21
- ComponentTemplate: i
22
- }]) => /* @__PURE__ */ c(m, {
23
- children: [/* @__PURE__ */ r(d, {
24
- as: "span",
25
- color: "textOnLightSecondary",
26
- style: {
27
- textTransform: "uppercase"
28
- },
29
- variant: "bodyDefaultBold",
30
- children: a
31
- }), /* @__PURE__ */ r("div", {
32
- children: i ? /* @__PURE__ */ r(i, {
33
- ...t,
34
- ...e
35
- }) : /* @__PURE__ */ r(s, {
36
- ...t,
37
- ...e
38
- })
39
- })]
40
- }, a))
41
- });
42
- };
43
- g.displayName = "variants";
44
- export {
45
- g as VariantsAggregator
1
+ import { Fragment as e } from "react";
2
+ import { Text as t } from "@box/blueprint-web";
3
+ import { jsx as n, jsxs as r } from "react/jsx-runtime";
4
+ var i = ({ defaultProps: i, DefaultComponentTemplate: a, variantsMap: o, containerStyle: s }) => {
5
+ let c = Object.entries(o);
6
+ return /* @__PURE__ */ n("div", {
7
+ style: {
8
+ display: "grid",
9
+ gridTemplateColumns: "auto auto",
10
+ alignItems: "baseline",
11
+ gap: "254px 12px",
12
+ ...s
13
+ },
14
+ children: c.map(([o, { props: s = {}, ComponentTemplate: c }]) => /* @__PURE__ */ r(e, { children: [/* @__PURE__ */ n(t, {
15
+ as: "span",
16
+ color: "textOnLightSecondary",
17
+ style: { textTransform: "uppercase" },
18
+ variant: "bodyDefaultBold",
19
+ children: o
20
+ }), /* @__PURE__ */ n("div", { children: n(c || a, {
21
+ ...i,
22
+ ...s
23
+ }) })] }, o))
24
+ });
46
25
  };
26
+ i.displayName = "variants";
27
+ export { i as VariantsAggregator };
@@ -1,4 +1,2 @@
1
- import { b as r } from "../../../chunks/buildOptionsWithOverlay.js";
2
- export {
3
- r as buildOptionsWithOverlay
4
- };
1
+ import { t as e } from "../../../chunks/buildOptionsWithOverlay.js";
2
+ export { e as buildOptionsWithOverlay };
@@ -1,12 +1,11 @@
1
- import { UserSelectorListItemInfo as r } from "../user-selector-list-item.js";
2
- import { jsx as o } from "react/jsx-runtime";
3
- function n(t, e) {
4
- return /* @__PURE__ */ o(r, {
5
- renderAvatar: e,
6
- subtitle: t.subtitle,
7
- title: t.name
8
- });
1
+ import { r as e } from "../../../chunks/user-selector-list-item.js";
2
+ import "react";
3
+ import { jsx as t } from "react/jsx-runtime";
4
+ function n(n, r) {
5
+ return /* @__PURE__ */ t(e, {
6
+ renderAvatar: r,
7
+ subtitle: n.subtitle,
8
+ title: n.name
9
+ });
9
10
  }
10
- export {
11
- n as defaultRenderCustomOption
12
- };
11
+ export { n as defaultRenderCustomOption };