se-design 1.0.83-dev.5 → 1.0.84-dev.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/style.css +1 -1
- package/dist/components/Avatar/index.d.ts +1 -0
- package/dist/components/InfoTooltip/index.d.ts +6 -1
- package/dist/components/TableLayout/index.d.ts +10 -0
- package/dist/index16.js +4 -4
- package/dist/index16.js.map +1 -1
- package/dist/index18.js +61 -58
- package/dist/index18.js.map +1 -1
- package/dist/index19.js +163 -181
- package/dist/index19.js.map +1 -1
- package/dist/index207.js +16 -15
- package/dist/index207.js.map +1 -1
- package/dist/index215.js +17 -12
- package/dist/index215.js.map +1 -1
- package/dist/index22.js +51 -46
- package/dist/index22.js.map +1 -1
- package/dist/index25.js +257 -212
- package/dist/index25.js.map +1 -1
- package/dist/index28.js +49 -45
- package/dist/index28.js.map +1 -1
- package/dist/index31.js +43 -36
- package/dist/index31.js.map +1 -1
- package/dist/index38.js +184 -172
- package/dist/index38.js.map +1 -1
- package/dist/index4.js +53 -48
- package/dist/index4.js.map +1 -1
- package/dist/index43.js +30 -30
- package/dist/index43.js.map +1 -1
- package/dist/index48.js +15 -12
- package/dist/index48.js.map +1 -1
- package/dist/index53.js +22 -17
- package/dist/index53.js.map +1 -1
- package/dist/index61.js +57 -47
- package/dist/index61.js.map +1 -1
- package/dist/index68.js +46 -49
- package/dist/index68.js.map +1 -1
- package/dist/index72.js +46 -46
- package/dist/index72.js.map +1 -1
- package/dist/index75.js +107 -44
- package/dist/index75.js.map +1 -1
- package/package.json +1 -1
package/dist/index38.js
CHANGED
|
@@ -1,44 +1,45 @@
|
|
|
1
|
-
import
|
|
1
|
+
import r, { forwardRef as Ee, useState as _, useRef as M, useCallback as F, useEffect as W, useImperativeHandle as Pe } from "react";
|
|
2
2
|
import { Popover as Ce } from "./index19.js";
|
|
3
|
-
import { Icon as
|
|
4
|
-
import { Checkbox as
|
|
5
|
-
import { Button as
|
|
3
|
+
import { Icon as Se } from "./index6.js";
|
|
4
|
+
import { Checkbox as De } from "./index23.js";
|
|
5
|
+
import { Button as X } from "./index4.js";
|
|
6
6
|
import { getA11yNameAttributes as Ne } from "./index81.js";
|
|
7
7
|
import "./index72.js";
|
|
8
8
|
import { useCombobox as $e } from "./index68.js";
|
|
9
|
-
import { useStableId as
|
|
9
|
+
import { useStableId as Ae } from "./index205.js";
|
|
10
|
+
import { useLiveAnnouncer as Oe } from "./index77.js";
|
|
10
11
|
/* empty css */
|
|
11
|
-
function
|
|
12
|
-
return
|
|
12
|
+
function g() {
|
|
13
|
+
return g = Object.assign ? Object.assign.bind() : function(h) {
|
|
13
14
|
for (var i = 1; i < arguments.length; i++) {
|
|
14
|
-
var
|
|
15
|
-
for (var
|
|
15
|
+
var k = arguments[i];
|
|
16
|
+
for (var y in k) ({}).hasOwnProperty.call(k, y) && (h[y] = k[y]);
|
|
16
17
|
}
|
|
17
18
|
return h;
|
|
18
|
-
},
|
|
19
|
+
}, g.apply(null, arguments);
|
|
19
20
|
}
|
|
20
|
-
const
|
|
21
|
+
const xe = /* @__PURE__ */ Ee(({
|
|
21
22
|
value: h,
|
|
22
23
|
onChange: i,
|
|
23
|
-
placeholder:
|
|
24
|
-
className:
|
|
25
|
-
options:
|
|
26
|
-
renderOption:
|
|
24
|
+
placeholder: k = "Type to search or add custom tags...",
|
|
25
|
+
className: y = "",
|
|
26
|
+
options: d = [],
|
|
27
|
+
renderOption: x,
|
|
27
28
|
label: R,
|
|
28
|
-
ariaLabel:
|
|
29
|
-
ariaLabelledBy:
|
|
30
|
-
ariaDescribedBy:
|
|
29
|
+
ariaLabel: Y,
|
|
30
|
+
ariaLabelledBy: Z,
|
|
31
|
+
ariaDescribedBy: ee,
|
|
31
32
|
automationId: u = "",
|
|
32
|
-
noOptionsMessage:
|
|
33
|
-
allowCustomTags:
|
|
34
|
-
disabled:
|
|
33
|
+
noOptionsMessage: U = "No options found",
|
|
34
|
+
allowCustomTags: j = !0,
|
|
35
|
+
disabled: a = !1,
|
|
35
36
|
type: H = "select",
|
|
36
|
-
showInput:
|
|
37
|
-
displayTagBy:
|
|
37
|
+
showInput: z = !0,
|
|
38
|
+
displayTagBy: B = "label",
|
|
38
39
|
isWithPortal: te = !1
|
|
39
40
|
}, ne) => {
|
|
40
|
-
const
|
|
41
|
-
const n =
|
|
41
|
+
const G = (e) => e.map((t) => {
|
|
42
|
+
const n = d.find((s) => s.value === t);
|
|
42
43
|
return n ? {
|
|
43
44
|
label: n.label,
|
|
44
45
|
value: n.value
|
|
@@ -46,145 +47,155 @@ const Le = /* @__PURE__ */ Ee(({
|
|
|
46
47
|
label: t,
|
|
47
48
|
value: t
|
|
48
49
|
};
|
|
49
|
-
}), [
|
|
50
|
-
if (
|
|
51
|
-
const t = [...
|
|
50
|
+
}), [o, f] = _(() => G(h || [])), [l, b] = _(""), [K, re] = _(d), [p, c] = _(!1), ae = M(null), S = M(null), D = M(!1), E = H === "multi-select-without-cta", m = H === "multi-select" || E, oe = Ae(u, "dropdown-input-tags-listbox"), N = F((e) => {
|
|
51
|
+
if (a) return;
|
|
52
|
+
const t = [...o];
|
|
52
53
|
t.some((n) => n.value === e.value) || (t.push({
|
|
53
54
|
label: e.label,
|
|
54
55
|
value: e.value
|
|
55
|
-
}),
|
|
56
|
-
}, [
|
|
56
|
+
}), f(t), i?.(t.map((n) => n.value))), b(""), c(!1);
|
|
57
|
+
}, [a, o, i]), L = F((e, t) => {
|
|
57
58
|
let n = [];
|
|
58
|
-
e ? n = [...
|
|
59
|
+
e ? n = [...o, {
|
|
59
60
|
label: t.label,
|
|
60
61
|
value: t.value
|
|
61
|
-
}] : n =
|
|
62
|
-
}, [
|
|
63
|
-
if (!
|
|
62
|
+
}] : n = o.filter((s) => s.value !== t.value), f(n), b(""), E && (D.current = !0, i?.(n.map((s) => s.value)));
|
|
63
|
+
}, [o, E, i]), $ = "__add_custom_tag__", q = F((e) => {
|
|
64
|
+
if (!a) {
|
|
64
65
|
if (e.value === $) {
|
|
65
|
-
const t =
|
|
66
|
+
const t = l.trim();
|
|
66
67
|
if (!t) return;
|
|
67
|
-
const n = [...
|
|
68
|
+
const n = [...o];
|
|
68
69
|
n.some((s) => s.value === t) || (n.push({
|
|
69
70
|
label: t,
|
|
70
71
|
value: t
|
|
71
|
-
}),
|
|
72
|
+
}), f(n), i?.(n.map((s) => s.value))), b(""), c(!1);
|
|
72
73
|
return;
|
|
73
74
|
}
|
|
74
|
-
if (
|
|
75
|
-
const t =
|
|
76
|
-
|
|
75
|
+
if (m) {
|
|
76
|
+
const t = o.some((n) => n.value === e.value);
|
|
77
|
+
L(!t, e);
|
|
77
78
|
} else
|
|
78
79
|
N(e);
|
|
79
80
|
}
|
|
80
|
-
}, [
|
|
81
|
+
}, [a, m, o, l, i, L, N]), v = K.length > 0 ? K : j && l.trim() ? [{
|
|
81
82
|
id: $,
|
|
82
|
-
label: `Add "${
|
|
83
|
+
label: `Add "${l.trim()}"`,
|
|
83
84
|
value: $
|
|
84
85
|
}] : [], {
|
|
85
|
-
containerProps:
|
|
86
|
-
inputProps:
|
|
86
|
+
containerProps: le,
|
|
87
|
+
inputProps: J,
|
|
87
88
|
listboxProps: se,
|
|
88
|
-
getOptionProps:
|
|
89
|
-
highlightedIndex:
|
|
90
|
-
setHighlightedIndex:
|
|
91
|
-
isKeyboardFocused:
|
|
89
|
+
getOptionProps: A,
|
|
90
|
+
highlightedIndex: O,
|
|
91
|
+
setHighlightedIndex: w,
|
|
92
|
+
isKeyboardFocused: Q
|
|
92
93
|
} = $e({
|
|
93
|
-
items:
|
|
94
|
-
isOpen:
|
|
94
|
+
items: v,
|
|
95
|
+
isOpen: p,
|
|
95
96
|
onOpenChange: c,
|
|
96
|
-
onSelect:
|
|
97
|
-
listboxId:
|
|
98
|
-
hasItems:
|
|
99
|
-
keepHighlightOnSelect:
|
|
97
|
+
onSelect: q,
|
|
98
|
+
listboxId: oe,
|
|
99
|
+
hasItems: v.length > 0,
|
|
100
|
+
keepHighlightOnSelect: m,
|
|
100
101
|
closeOnTab: H !== "multi-select"
|
|
101
|
-
}),
|
|
102
|
-
|
|
103
|
-
if (
|
|
104
|
-
|
|
102
|
+
}), T = (e) => e ? `highlighted${Q ? " keyboard-highlight" : ""}` : "";
|
|
103
|
+
W(() => {
|
|
104
|
+
if (D.current) {
|
|
105
|
+
D.current = !1;
|
|
105
106
|
return;
|
|
106
107
|
}
|
|
107
|
-
|
|
108
|
-
}, [h,
|
|
109
|
-
const e =
|
|
110
|
-
|
|
111
|
-
}, [
|
|
112
|
-
const
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
108
|
+
f(G(h || []));
|
|
109
|
+
}, [h, d, p]), W(() => {
|
|
110
|
+
const e = d.filter((t) => t.label.toLowerCase().includes(l.toLowerCase()) || t.value.toLowerCase().includes(l.toLowerCase()));
|
|
111
|
+
re(e);
|
|
112
|
+
}, [l, d]);
|
|
113
|
+
const {
|
|
114
|
+
announce: ie
|
|
115
|
+
} = Oe();
|
|
116
|
+
W(() => {
|
|
117
|
+
p && v.length === 0 && l.trim() && ie(U, {
|
|
118
|
+
assertiveness: "polite",
|
|
119
|
+
batchId: "dropdown-input-tags-empty-state",
|
|
120
|
+
delay: 300
|
|
121
|
+
});
|
|
122
|
+
}, [v.length, p, l]);
|
|
123
|
+
const ce = (e) => {
|
|
124
|
+
if (a) return;
|
|
125
|
+
const t = o.filter((n, s) => s !== e);
|
|
126
|
+
f(t), (!m || E || m && !p) && i?.(t.map((n) => n.value));
|
|
127
|
+
}, ue = (e) => {
|
|
128
|
+
if (!a) {
|
|
129
|
+
if (e.key === "Backspace" && l === "" && o.length > 0) {
|
|
119
130
|
e.preventDefault();
|
|
120
|
-
const t =
|
|
121
|
-
|
|
131
|
+
const t = o.slice(0, -1);
|
|
132
|
+
f(t), i?.(t.map((n) => n.value));
|
|
122
133
|
return;
|
|
123
134
|
}
|
|
124
|
-
if (e.key === "Enter" &&
|
|
135
|
+
if (e.key === "Enter" && l.trim() && K.length === 0 && j) {
|
|
125
136
|
e.preventDefault();
|
|
126
|
-
const t = [...
|
|
127
|
-
t.some((n) => n.value ===
|
|
128
|
-
label:
|
|
129
|
-
value:
|
|
130
|
-
}),
|
|
137
|
+
const t = [...o];
|
|
138
|
+
t.some((n) => n.value === l.trim()) || (t.push({
|
|
139
|
+
label: l.trim(),
|
|
140
|
+
value: l.trim()
|
|
141
|
+
}), f(t), i?.(t.map((n) => n.value))), b(""), w(-1), c(!1);
|
|
131
142
|
return;
|
|
132
143
|
}
|
|
133
|
-
|
|
144
|
+
J.onKeyDown(e);
|
|
134
145
|
}
|
|
135
|
-
},
|
|
136
|
-
if (
|
|
146
|
+
}, pe = (e) => {
|
|
147
|
+
if (a) return;
|
|
137
148
|
const t = e.target.value;
|
|
138
|
-
|
|
139
|
-
},
|
|
140
|
-
|
|
141
|
-
}, me = (e) => {
|
|
142
|
-
l || (e.stopPropagation(), P.current?.focus(), !d && (o.trim() || g.length > 0) && c(!0));
|
|
149
|
+
b(t), w(-1), t.trim() && !p && c(!0);
|
|
150
|
+
}, me = () => {
|
|
151
|
+
a || (l.trim() || d.length > 0) && c(!0);
|
|
143
152
|
}, fe = (e) => {
|
|
144
|
-
|
|
153
|
+
a || (e.stopPropagation(), S.current?.focus(), !p && (l.trim() || d.length > 0) && c(!0));
|
|
154
|
+
}, ge = (e) => {
|
|
155
|
+
if (a) {
|
|
145
156
|
e.preventDefault(), e.stopPropagation();
|
|
146
157
|
return;
|
|
147
158
|
}
|
|
148
159
|
e.target.closest(".input-with-tags-container") && e.stopPropagation();
|
|
149
|
-
},
|
|
150
|
-
|
|
160
|
+
}, de = () => {
|
|
161
|
+
a || c(!p);
|
|
151
162
|
};
|
|
152
|
-
|
|
153
|
-
toggleDropdown:
|
|
163
|
+
Pe(ne, () => ({
|
|
164
|
+
toggleDropdown: de
|
|
154
165
|
}), []);
|
|
155
|
-
const
|
|
156
|
-
const
|
|
157
|
-
return /* @__PURE__ */
|
|
166
|
+
const he = (e, t, n, s) => {
|
|
167
|
+
const P = o.some((C) => C.value === e.value), I = O === t, V = A(t, P);
|
|
168
|
+
return /* @__PURE__ */ r.createElement("div", g({
|
|
158
169
|
key: e.id
|
|
159
170
|
}, V, {
|
|
160
|
-
className: `dropdown-with-input-tags-option ${
|
|
171
|
+
className: `dropdown-with-input-tags-option ${T(I)}`,
|
|
161
172
|
onClick: () => !s && n(e),
|
|
162
|
-
onMouseEnter: () =>
|
|
173
|
+
onMouseEnter: () => w(t),
|
|
163
174
|
"data-automation-id": `${u}-option-${e.id}`
|
|
164
|
-
}), /* @__PURE__ */
|
|
175
|
+
}), /* @__PURE__ */ r.createElement("span", {
|
|
165
176
|
className: "option-label"
|
|
166
|
-
}, e.label), e.value !== e.label && /* @__PURE__ */
|
|
177
|
+
}, e.label), e.value !== e.label && /* @__PURE__ */ r.createElement("span", {
|
|
167
178
|
className: "option-value"
|
|
168
179
|
}, e.value));
|
|
169
|
-
}, he = () => {
|
|
170
|
-
S.current = !0;
|
|
171
|
-
const e = r.map((t) => t.value);
|
|
172
|
-
i?.(e), c(!1);
|
|
173
180
|
}, ve = () => {
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
181
|
+
D.current = !0;
|
|
182
|
+
const e = o.map((t) => t.value);
|
|
183
|
+
i?.(e), c(!1);
|
|
184
|
+
}, we = () => {
|
|
185
|
+
f([]);
|
|
186
|
+
}, ke = (e, t) => {
|
|
187
|
+
const n = o.some((I) => I.value === e.value), s = O === t, P = A(t, n);
|
|
188
|
+
return /* @__PURE__ */ r.createElement("div", g({
|
|
178
189
|
key: e.id
|
|
179
|
-
},
|
|
180
|
-
className: `dropdown-with-input-tags-option dropdown-with-input-tags-multi-select-option ${
|
|
190
|
+
}, P, {
|
|
191
|
+
className: `dropdown-with-input-tags-option dropdown-with-input-tags-multi-select-option ${T(s)}`,
|
|
181
192
|
"aria-checked": n,
|
|
182
193
|
onClick: () => {
|
|
183
|
-
|
|
194
|
+
a || (L(!n, e), S.current?.focus());
|
|
184
195
|
},
|
|
185
|
-
onMouseEnter: () =>
|
|
196
|
+
onMouseEnter: () => w(t),
|
|
186
197
|
"data-automation-id": `${u}-option-${e.id}`
|
|
187
|
-
}), /* @__PURE__ */
|
|
198
|
+
}), /* @__PURE__ */ r.createElement(De, {
|
|
188
199
|
automationId: "checkbox",
|
|
189
200
|
className: "checkbox",
|
|
190
201
|
checked: n,
|
|
@@ -193,111 +204,112 @@ const Le = /* @__PURE__ */ Ee(({
|
|
|
193
204
|
label: e.label,
|
|
194
205
|
tabIndex: -1
|
|
195
206
|
}));
|
|
196
|
-
},
|
|
197
|
-
className: "dropdown-with-input-tags-ctas-container"
|
|
198
|
-
|
|
207
|
+
}, ye = () => /* @__PURE__ */ r.createElement("div", {
|
|
208
|
+
className: "dropdown-with-input-tags-ctas-container",
|
|
209
|
+
onKeyDown: (e) => {
|
|
210
|
+
(e.key === "ArrowDown" || e.key === "ArrowUp" || e.key === "Home" || e.key === "End") && e.stopPropagation();
|
|
211
|
+
}
|
|
212
|
+
}, /* @__PURE__ */ r.createElement(X, {
|
|
199
213
|
label: "Clear",
|
|
200
214
|
type: "link",
|
|
201
215
|
size: "sm",
|
|
202
|
-
onClick:
|
|
216
|
+
onClick: we,
|
|
203
217
|
automationId: `${u}-clear-button`
|
|
204
|
-
}), /* @__PURE__ */
|
|
218
|
+
}), /* @__PURE__ */ r.createElement(X, {
|
|
205
219
|
label: "Apply",
|
|
206
220
|
type: "primary",
|
|
207
221
|
size: "sm",
|
|
208
|
-
onClick:
|
|
222
|
+
onClick: ve,
|
|
209
223
|
automationId: `${u}-apply-button`
|
|
210
224
|
}));
|
|
211
|
-
return /* @__PURE__ */
|
|
212
|
-
className: `dropdown-with-input-tags-wrapper ${
|
|
225
|
+
return /* @__PURE__ */ r.createElement("div", g({
|
|
226
|
+
className: `dropdown-with-input-tags-wrapper ${y} ${a ? "disabled-wrapper" : ""}`,
|
|
213
227
|
"data-automation-id": u
|
|
214
|
-
},
|
|
228
|
+
}, le), R && /* @__PURE__ */ r.createElement("label", {
|
|
215
229
|
id: `${u}-label`,
|
|
216
230
|
className: "dropdown-with-input-tags-label"
|
|
217
|
-
}, R), /* @__PURE__ */
|
|
218
|
-
onClick:
|
|
219
|
-
}, /* @__PURE__ */
|
|
220
|
-
ref:
|
|
231
|
+
}, R), /* @__PURE__ */ r.createElement("div", {
|
|
232
|
+
onClick: ge
|
|
233
|
+
}, /* @__PURE__ */ r.createElement(Ce, {
|
|
234
|
+
ref: ae,
|
|
221
235
|
className: "dropdown-with-input-tags-popover",
|
|
222
236
|
contentWidth: "full",
|
|
223
237
|
position: "bottom-left",
|
|
224
|
-
isPopoverOpen: !
|
|
225
|
-
onPopoverToggle:
|
|
238
|
+
isPopoverOpen: !a && p,
|
|
239
|
+
onPopoverToggle: a ? () => {
|
|
226
240
|
} : c,
|
|
227
241
|
disableClickToggle: !0,
|
|
228
242
|
isWithPortal: te,
|
|
229
243
|
renderPopoverContents: ({
|
|
230
244
|
closePopoverCb: e
|
|
231
|
-
}) => /* @__PURE__ */
|
|
245
|
+
}) => /* @__PURE__ */ r.createElement(r.Fragment, null, /* @__PURE__ */ r.createElement("div", g({}, se, {
|
|
232
246
|
className: "dropdown-with-input-tags-content"
|
|
233
|
-
},
|
|
247
|
+
}, m && {
|
|
234
248
|
"aria-multiselectable": "true"
|
|
235
|
-
}),
|
|
249
|
+
}), v.length > 0 ? v.map((t, n) => {
|
|
236
250
|
if (t.value === $) {
|
|
237
|
-
const C =
|
|
238
|
-
return /* @__PURE__ */
|
|
251
|
+
const C = O === n, be = A(n, !1);
|
|
252
|
+
return /* @__PURE__ */ r.createElement("div", g({
|
|
239
253
|
key: t.id
|
|
240
|
-
},
|
|
241
|
-
className: `dropdown-with-input-tags-option dropdown-with-input-tags-custom-option ${
|
|
254
|
+
}, be, {
|
|
255
|
+
className: `dropdown-with-input-tags-option dropdown-with-input-tags-custom-option ${T(C)}`,
|
|
242
256
|
onClick: () => {
|
|
243
|
-
|
|
257
|
+
a || (q(t), e());
|
|
244
258
|
},
|
|
245
|
-
onMouseEnter: () =>
|
|
246
|
-
}), 'Add "',
|
|
259
|
+
onMouseEnter: () => w(n)
|
|
260
|
+
}), 'Add "', l.trim(), '"');
|
|
247
261
|
}
|
|
248
|
-
if (
|
|
249
|
-
return
|
|
250
|
-
const s =
|
|
251
|
-
...
|
|
252
|
-
onMouseEnter: () =>
|
|
253
|
-
className: `dropdown-with-input-tags-option ${
|
|
262
|
+
if (m)
|
|
263
|
+
return ke(t, n);
|
|
264
|
+
const s = o.some((C) => C.value === t.value), P = O === n, V = {
|
|
265
|
+
...A(n, s),
|
|
266
|
+
onMouseEnter: () => w(n),
|
|
267
|
+
className: `dropdown-with-input-tags-option ${T(P)}`
|
|
254
268
|
};
|
|
255
|
-
return
|
|
256
|
-
}) : /* @__PURE__ */
|
|
269
|
+
return x ? x(t, V, N) : he(t, n, N, a);
|
|
270
|
+
}) : /* @__PURE__ */ r.createElement("div", {
|
|
257
271
|
className: "dropdown-with-input-tags-no-options"
|
|
258
|
-
}, /* @__PURE__ */
|
|
259
|
-
className: "dropdown-with-input-tags-no-options-text"
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
}, ee))), p && !E && be()),
|
|
263
|
-
renderPopoverSrcElement: () => /* @__PURE__ */ a.createElement("div", {
|
|
272
|
+
}, /* @__PURE__ */ r.createElement("div", {
|
|
273
|
+
className: "dropdown-with-input-tags-no-options-text"
|
|
274
|
+
}, U))), m && !E && ye()),
|
|
275
|
+
renderPopoverSrcElement: () => /* @__PURE__ */ r.createElement("div", {
|
|
264
276
|
className: "dropdown-with-input-tags-input-container"
|
|
265
|
-
}, /* @__PURE__ */
|
|
266
|
-
className: `input-with-tags-container ${
|
|
267
|
-
onClick:
|
|
277
|
+
}, /* @__PURE__ */ r.createElement("div", {
|
|
278
|
+
className: `input-with-tags-container ${a ? "disabled-input-with-tags-container" : ""} ${Q ? "keyboard-focused" : ""}`,
|
|
279
|
+
onClick: fe,
|
|
268
280
|
onKeyDown: (e) => {
|
|
269
|
-
e.key.length === 1 && !e.ctrlKey && !e.metaKey && !e.altKey &&
|
|
281
|
+
e.key.length === 1 && !e.ctrlKey && !e.metaKey && !e.altKey && S.current?.focus();
|
|
270
282
|
}
|
|
271
|
-
},
|
|
283
|
+
}, o.map((e, t) => /* @__PURE__ */ r.createElement("span", {
|
|
272
284
|
key: t,
|
|
273
285
|
className: "tag-in-inputwithtags"
|
|
274
|
-
}, e[
|
|
286
|
+
}, e[B], !a && /* @__PURE__ */ r.createElement(Se, {
|
|
275
287
|
name: "close",
|
|
276
288
|
className: "close-icon-in-inputwithtags",
|
|
277
|
-
ariaLabel: `Remove tag ${e[
|
|
278
|
-
onClick: () =>
|
|
289
|
+
ariaLabel: `Remove tag ${e[B]}`,
|
|
290
|
+
onClick: () => ce(t),
|
|
279
291
|
shouldStopPropagation: !0
|
|
280
|
-
}))), (
|
|
281
|
-
ref:
|
|
282
|
-
},
|
|
292
|
+
}))), (z || !o.length || m) && /* @__PURE__ */ r.createElement("input", g({
|
|
293
|
+
ref: S
|
|
294
|
+
}, J, {
|
|
283
295
|
type: "text",
|
|
284
|
-
value:
|
|
285
|
-
onChange:
|
|
286
|
-
onKeyDown:
|
|
287
|
-
onFocus:
|
|
288
|
-
placeholder:
|
|
289
|
-
className: `input-with-tags-input${!
|
|
290
|
-
disabled:
|
|
296
|
+
value: l,
|
|
297
|
+
onChange: pe,
|
|
298
|
+
onKeyDown: ue,
|
|
299
|
+
onFocus: me,
|
|
300
|
+
placeholder: o.length === 0 ? k : "",
|
|
301
|
+
className: `input-with-tags-input${!z && o.length > 0 && !l ? " sr-only" : ""}`,
|
|
302
|
+
disabled: a
|
|
291
303
|
}, Ne({
|
|
292
|
-
ariaLabel:
|
|
293
|
-
ariaLabelledBy:
|
|
294
|
-
ariaDescribedBy:
|
|
304
|
+
ariaLabel: Y || R || "Search and select options",
|
|
305
|
+
ariaLabelledBy: Z,
|
|
306
|
+
ariaDescribedBy: ee
|
|
295
307
|
}))))),
|
|
296
308
|
automationId: u,
|
|
297
309
|
popoverContentAutomationId: `${u}-content`
|
|
298
310
|
})));
|
|
299
311
|
});
|
|
300
312
|
export {
|
|
301
|
-
|
|
313
|
+
xe as DropdownWithInputTags
|
|
302
314
|
};
|
|
303
315
|
//# sourceMappingURL=index38.js.map
|