bmi-next-brokers 2.3.1 → 2.3.3
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/components/Select/Select.js +170 -171
- package/dist/icons/Icon.js +1 -1
- package/dist/icons/components/SortArrowsAsc.d.ts +3 -0
- package/dist/icons/components/SortArrowsAsc.js +42 -0
- package/dist/icons/components/SortArrowsDefault.d.ts +3 -0
- package/dist/icons/components/SortArrowsDefault.js +39 -0
- package/dist/icons/components/SortArrowsDesc.d.ts +3 -0
- package/dist/icons/components/SortArrowsDesc.js +42 -0
- package/dist/icons/components/index.d.ts +3 -0
- package/dist/icons/components/index.js +138 -132
- package/dist/icons/index.d.ts +3 -0
- package/dist/icons/index.js +74 -68
- package/dist/{index-S4_4Z0mU.js → index-DSh882Th.js} +68 -62
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { jsxs as b, jsx as o, Fragment as
|
|
2
|
-
import { useState as P, useRef as N, useEffect as
|
|
1
|
+
import { jsxs as b, jsx as o, Fragment as ee } from "react/jsx-runtime";
|
|
2
|
+
import { useState as P, useRef as N, useEffect as te, useMemo as ue, useLayoutEffect as Qe } from "react";
|
|
3
3
|
import { createPortal as Me } from "react-dom";
|
|
4
4
|
import { Icon as F } from "../../icons/Icon.js";
|
|
5
5
|
import { HelperText as je } from "../helperText/index.js";
|
|
@@ -9,7 +9,7 @@ import { Drawer as Xe } from "../drawer/index.js";
|
|
|
9
9
|
import { useClose as Ge } from "../../hooks/useClose.js";
|
|
10
10
|
import { Input as Je } from "../Input/Input.js";
|
|
11
11
|
import { useBTC as Ke } from "../../hooks/btcContext/useBtcContext.js";
|
|
12
|
-
import '../../assets/Select.css';const Ue = "_selectContainer_1sakp_23", Ze = "_selectContainer_medium_1sakp_47", ze = "_selectContainer_large_1sakp_55", et = "_selectContainer_extraLarge_1sakp_57", tt = "_label_1sakp_75", nt = "_label_large_1sakp_89", rt = "_label_extraLarge_1sakp_91", ot = "_label_disabled_1sakp_99", st = "_label_inverted_1sakp_107", at = "_label_inverted_disabled_1sakp_115", lt = "_selectWrapper_1sakp_133", it = "_select_1sakp_23", ct = "_open_1sakp_213", dt = "_disabled_1sakp_221", _t = "_placeholder_1sakp_235", pt = "_small_1sakp_257", ut = "_medium_1sakp_279", ht = "_large_1sakp_301", mt = "_extraLarge_1sakp_323", ft = "_selectValue_1sakp_351", bt = "_selectInput_1sakp_371", gt = "_error_1sakp_467", wt = "_btc_1sakp_495", kt = "_errorShake_1sakp_1", vt = "_inverted_1sakp_625", St = "_chevron_1sakp_685", $t = "_icon_inverted_1sakp_693", Ct = "_icon_inverted_disabled_1sakp_825", Lt = "_chevronOpen_1sakp_893", Dt = "_icon_1sakp_693", yt = "_icon_disabled_1sakp_927", xt = "_iconLabel_1sakp_945", Nt = "_optionIcon_1sakp_967", Wt = "_required_1sakp_989",
|
|
12
|
+
import '../../assets/Select.css';const Ue = "_selectContainer_1sakp_23", Ze = "_selectContainer_medium_1sakp_47", ze = "_selectContainer_large_1sakp_55", et = "_selectContainer_extraLarge_1sakp_57", tt = "_label_1sakp_75", nt = "_label_large_1sakp_89", rt = "_label_extraLarge_1sakp_91", ot = "_label_disabled_1sakp_99", st = "_label_inverted_1sakp_107", at = "_label_inverted_disabled_1sakp_115", lt = "_selectWrapper_1sakp_133", it = "_select_1sakp_23", ct = "_open_1sakp_213", dt = "_disabled_1sakp_221", _t = "_placeholder_1sakp_235", pt = "_small_1sakp_257", ut = "_medium_1sakp_279", ht = "_large_1sakp_301", mt = "_extraLarge_1sakp_323", ft = "_selectValue_1sakp_351", bt = "_selectInput_1sakp_371", gt = "_error_1sakp_467", wt = "_btc_1sakp_495", kt = "_errorShake_1sakp_1", vt = "_inverted_1sakp_625", St = "_chevron_1sakp_685", $t = "_icon_inverted_1sakp_693", Ct = "_icon_inverted_disabled_1sakp_825", Lt = "_chevronOpen_1sakp_893", Dt = "_icon_1sakp_693", yt = "_icon_disabled_1sakp_927", xt = "_iconLabel_1sakp_945", Nt = "_optionIcon_1sakp_967", Wt = "_required_1sakp_989", It = "_required_inverted_1sakp_999", Ot = "_required_disabled_1sakp_1007", Et = "_required_inverted_disabled_1sakp_1015", Tt = "_dropdown_1sakp_1033", qt = "_highlight_1sakp_1067", Vt = "_isDrawer_1sakp_1083", Ht = "_dropdownPortal_1sakp_1129", Rt = "_drawerSelect_1sakp_1155", Bt = "_drawerSelectHeader_1sakp_1163", Pt = "_drawerSearchInput_1sakp_1171", Ft = "_option_1sakp_967", Qt = "_optionSelected_1sakp_1203", Mt = "_optionWithCheckbox_1sakp_1295", jt = "_optionCheckbox_1sakp_1307", At = "_optionWithDescriptionWrapper_1sakp_1395", Yt = "_optionWithDescription_1sakp_1395", Xt = "_optionWithDescriptionLabel_1sakp_1427", Gt = "_optionWithDescriptionValue_1sakp_1439", Jt = "_dropdownTable_1sakp_1459", Kt = "_optionTable_1sakp_1469", Ut = "_tableColumn_1sakp_1485", Zt = "_columnHeader_1sakp_1501", zt = "_columnValue_1sakp_1517", en = "_noResults_1sakp_1551", tn = "_dropdown_inverted_1sakp_1579", nn = "_option_inverted_1sakp_1625", e = {
|
|
13
13
|
selectContainer: Ue,
|
|
14
14
|
selectContainer_medium: Ze,
|
|
15
15
|
selectContainer_large: ze,
|
|
@@ -44,8 +44,8 @@ import '../../assets/Select.css';const Ue = "_selectContainer_1sakp_23", Ze = "_
|
|
|
44
44
|
iconLabel: xt,
|
|
45
45
|
optionIcon: Nt,
|
|
46
46
|
required: Wt,
|
|
47
|
-
required_inverted:
|
|
48
|
-
required_disabled:
|
|
47
|
+
required_inverted: It,
|
|
48
|
+
required_disabled: Ot,
|
|
49
49
|
required_inverted_disabled: Et,
|
|
50
50
|
dropdown: Tt,
|
|
51
51
|
highlight: qt,
|
|
@@ -71,160 +71,159 @@ import '../../assets/Select.css';const Ue = "_selectContainer_1sakp_23", Ze = "_
|
|
|
71
71
|
dropdown_inverted: tn,
|
|
72
72
|
option_inverted: nn
|
|
73
73
|
}, gn = ({
|
|
74
|
-
size:
|
|
74
|
+
size: l = "medium",
|
|
75
75
|
label: T,
|
|
76
|
-
error:
|
|
76
|
+
error: ne,
|
|
77
77
|
helperText: q,
|
|
78
78
|
icon: W,
|
|
79
|
-
className:
|
|
80
|
-
required:
|
|
79
|
+
className: he,
|
|
80
|
+
required: me,
|
|
81
81
|
placeholder: Q = "Seleccionar...",
|
|
82
82
|
options: $ = [],
|
|
83
83
|
value: f,
|
|
84
|
-
onChange:
|
|
84
|
+
onChange: d,
|
|
85
85
|
onSearchInput: M,
|
|
86
|
-
disabled:
|
|
87
|
-
inverted:
|
|
88
|
-
dynamicIcon:
|
|
89
|
-
showPlaceholderIcon:
|
|
90
|
-
btc:
|
|
86
|
+
disabled: _ = !1,
|
|
87
|
+
inverted: p = !1,
|
|
88
|
+
dynamicIcon: fe = !1,
|
|
89
|
+
showPlaceholderIcon: be = !1,
|
|
90
|
+
btc: re,
|
|
91
91
|
columnHeaders: V,
|
|
92
|
-
searchable:
|
|
93
|
-
noSearchResult:
|
|
92
|
+
searchable: ge = !1,
|
|
93
|
+
noSearchResult: oe = "No se encontraron resultados",
|
|
94
94
|
searchAndCheckbox: H = !1,
|
|
95
|
-
customBorderColor:
|
|
96
|
-
responsive:
|
|
97
|
-
title:
|
|
98
|
-
responsiveQuery:
|
|
99
|
-
highlightMatch:
|
|
100
|
-
|
|
95
|
+
customBorderColor: se,
|
|
96
|
+
responsive: we = !1,
|
|
97
|
+
title: ke,
|
|
98
|
+
responsiveQuery: ve = 1024,
|
|
99
|
+
highlightMatch: Se = !1,
|
|
100
|
+
...$e
|
|
101
101
|
}) => {
|
|
102
|
-
const j = !!M, { btc:
|
|
103
|
-
|
|
102
|
+
const j = !!M, { btc: Ce } = Ke(), Le = re ?? Ce, [i, S] = P(!1), [m, De] = P(""), s = ge || H, g = H, A = N(null), ye = N(null), I = N(null), Y = N(null), X = N(null), [C, w] = P([]), xe = i && !_, Ne = Ye(`(max-width: ${ve}px)`), G = we && Ne && !_;
|
|
103
|
+
te(() => {
|
|
104
104
|
if (g)
|
|
105
105
|
if (Array.isArray(f) && f.length > 0) {
|
|
106
106
|
const t = $.filter((n) => f.includes(n.value)), r = t.map((n) => n.value);
|
|
107
|
-
|
|
107
|
+
w(t), (r.length !== f.length || !r.every((n) => f.includes(n))) && d && d(r);
|
|
108
108
|
} else
|
|
109
|
-
|
|
109
|
+
w([]);
|
|
110
110
|
else if (f) {
|
|
111
111
|
const t = $.find((r) => r.value === f);
|
|
112
|
-
t ? (
|
|
112
|
+
t ? w([t]) : (w([]), d && d(""));
|
|
113
113
|
} else
|
|
114
|
-
|
|
114
|
+
w([]);
|
|
115
115
|
}, [f, $, g]);
|
|
116
|
-
const
|
|
117
|
-
|
|
116
|
+
const O = C.map((t) => t.value), u = C[0] ?? null, k = (t) => typeof t == "string" ? t.normalize("NFD").replace(/[\u0300-\u036f]/g, "").replace(/\s+/g, "").toLowerCase() : "", ae = N("");
|
|
117
|
+
te(() => {
|
|
118
118
|
if (!s) return;
|
|
119
|
-
const t =
|
|
119
|
+
const t = m.trim(), r = ae.current.trim();
|
|
120
120
|
if (g) {
|
|
121
121
|
if (t.length > 0) {
|
|
122
|
-
const c =
|
|
123
|
-
(
|
|
124
|
-
), n = c.map((
|
|
125
|
-
c.length !==
|
|
122
|
+
const c = C.filter(
|
|
123
|
+
(a) => k(a.label).includes(k(t))
|
|
124
|
+
), n = c.map((a) => a.value);
|
|
125
|
+
c.length !== C.length && (w(c), d && d(n));
|
|
126
126
|
}
|
|
127
|
-
t === "" && r.length > 0 && (
|
|
127
|
+
t === "" && r.length > 0 && (w([]), d && d([]));
|
|
128
128
|
} else
|
|
129
|
-
|
|
130
|
-
|
|
129
|
+
u && t.length > 0 && !k(u.label).includes(k(t)) && (w([]), d && d("")), t === "" && r.length > 0 && (w([]), d && d(""));
|
|
130
|
+
ae.current = m;
|
|
131
131
|
}, [
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
132
|
+
m,
|
|
133
|
+
u,
|
|
134
|
+
C,
|
|
135
135
|
g,
|
|
136
136
|
s,
|
|
137
|
-
|
|
137
|
+
d
|
|
138
138
|
]);
|
|
139
|
-
const
|
|
139
|
+
const le = ue(() => s ? i ? m : !g && u ? u.label : g && O.length > 0 ? `${O.length} ${O.length === 1 ? "seleccionado" : "seleccionados"}` : "" : "", [
|
|
140
140
|
s,
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
141
|
+
i,
|
|
142
|
+
m,
|
|
143
|
+
u,
|
|
144
|
+
O,
|
|
145
145
|
g
|
|
146
|
-
]),
|
|
147
|
-
(t) =>
|
|
148
|
-
), [$,
|
|
149
|
-
if (
|
|
150
|
-
if (s &&
|
|
151
|
-
return
|
|
146
|
+
]), ie = (t) => C.some((r) => r.value === t), R = ue(() => !s || !m || j ? $ : $.filter(
|
|
147
|
+
(t) => k(t.label).includes(k(m))
|
|
148
|
+
), [$, m, s, j]), L = (() => {
|
|
149
|
+
if (ne) return ne;
|
|
150
|
+
if (s && m && m.trim().length > 0 && R.length === 0 && !i && !f)
|
|
151
|
+
return oe;
|
|
152
152
|
})();
|
|
153
|
-
|
|
153
|
+
te(() => {
|
|
154
154
|
const t = (r) => {
|
|
155
|
-
|
|
155
|
+
A.current && !A.current.contains(r.target) && I.current && !I.current.contains(r.target) && S(!1);
|
|
156
156
|
};
|
|
157
157
|
return document.addEventListener("mousedown", t), () => {
|
|
158
158
|
document.removeEventListener("mousedown", t);
|
|
159
159
|
};
|
|
160
|
-
}, [s, j,
|
|
160
|
+
}, [s, j, u]);
|
|
161
161
|
const We = [
|
|
162
162
|
e.select,
|
|
163
|
-
|
|
164
|
-
e[
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
].filter(Boolean).join(" "),
|
|
163
|
+
Le && e.btc,
|
|
164
|
+
e[l],
|
|
165
|
+
L ? e.error : "",
|
|
166
|
+
_ ? e.disabled : "",
|
|
167
|
+
i ? e.open : "",
|
|
168
|
+
p ? e.inverted : "",
|
|
169
|
+
he
|
|
170
|
+
].filter(Boolean).join(" "), D = l === "small" ? 16 : l === "large" ? 20 : l === "extraLarge" ? 24 : 18, ce = fe && (u != null && u.icon) && !(s && i) ? u.icon : W, Ie = () => {
|
|
171
171
|
var t;
|
|
172
|
-
|
|
173
|
-
},
|
|
174
|
-
if (
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
}, _e = (t) => {
|
|
172
|
+
_ || (S(!i), s && !i && (_e(), (t = X.current) == null || t.focus()));
|
|
173
|
+
}, J = (t, r = !0) => {
|
|
174
|
+
if (d)
|
|
175
|
+
if (g) {
|
|
176
|
+
const c = Array.isArray(f) ? f : [], a = c.includes(t) ? c.filter((h) => h !== t) : [...c, t];
|
|
177
|
+
d(a);
|
|
178
|
+
} else
|
|
179
|
+
d(t), r && S(!1);
|
|
180
|
+
}, de = (t) => {
|
|
182
181
|
const r = t.target.value;
|
|
183
|
-
|
|
184
|
-
},
|
|
185
|
-
|
|
186
|
-
},
|
|
187
|
-
|
|
182
|
+
De(r), i || S(!0), M && M(r);
|
|
183
|
+
}, _e = () => {
|
|
184
|
+
i || S(!0);
|
|
185
|
+
}, Oe = (t) => {
|
|
186
|
+
G && (t.preventDefault(), t.stopPropagation()), s && (t.stopPropagation(), i || (S(!0), setTimeout(() => {
|
|
188
187
|
var r;
|
|
189
|
-
(r =
|
|
188
|
+
(r = X.current) == null || r.focus();
|
|
190
189
|
}, 0)));
|
|
191
|
-
},
|
|
192
|
-
if (
|
|
193
|
-
const c =
|
|
190
|
+
}, K = (t, r) => {
|
|
191
|
+
if (!Se || !r.trim()) return t;
|
|
192
|
+
const c = k(t), n = k(r.trim());
|
|
194
193
|
if (!c.includes(n)) return t;
|
|
195
|
-
const
|
|
196
|
-
for (let
|
|
197
|
-
const
|
|
198
|
-
for (let x = 0; x <
|
|
199
|
-
|
|
194
|
+
const a = [], h = [];
|
|
195
|
+
for (let v = 0; v < t.length; v++) {
|
|
196
|
+
const Z = k(t[v]);
|
|
197
|
+
for (let x = 0; x < Z.length; x++)
|
|
198
|
+
h.push(v);
|
|
200
199
|
}
|
|
201
|
-
const
|
|
202
|
-
return
|
|
203
|
-
/* @__PURE__ */ o("mark", { className: e.highlight, children: t.slice(E,
|
|
204
|
-
),
|
|
200
|
+
const y = c.indexOf(n), B = y + n.length - 1, E = h[y], U = h[B] + 1;
|
|
201
|
+
return a.push(t.slice(0, E)), a.push(
|
|
202
|
+
/* @__PURE__ */ o("mark", { className: e.highlight, children: t.slice(E, U) }, "highlight")
|
|
203
|
+
), a.push(t.slice(U)), /* @__PURE__ */ o(ee, { children: a });
|
|
205
204
|
}, [Ee, Te] = P();
|
|
206
205
|
Qe(() => {
|
|
207
206
|
const t = document.body.style.overflow === "hidden", r = () => {
|
|
208
|
-
if (
|
|
209
|
-
const n =
|
|
207
|
+
if (i && Y.current && I.current) {
|
|
208
|
+
const n = Y.current.getBoundingClientRect(), a = I.current.offsetHeight, h = window.innerHeight, y = (Re) => {
|
|
210
209
|
const { label: Be, helperText: Pe, displayError: Fe } = Re;
|
|
211
210
|
return { top: s && !Be ? 3 : 0, bottom: s && !Pe && !Fe ? 3 : 0 };
|
|
212
|
-
}, { top: B, bottom: E } =
|
|
211
|
+
}, { top: B, bottom: E } = y({
|
|
213
212
|
label: T,
|
|
214
213
|
helperText: q,
|
|
215
|
-
displayError:
|
|
216
|
-
}),
|
|
214
|
+
displayError: L
|
|
215
|
+
}), v = {
|
|
217
216
|
small: 1,
|
|
218
217
|
//Meter gap en small
|
|
219
218
|
medium: 2,
|
|
220
219
|
large: 4,
|
|
221
220
|
extraLarge: 4
|
|
222
|
-
}[
|
|
221
|
+
}[l], Z = n.bottom + v + E, x = h - Z, z = n.top - v - B, Ve = (
|
|
223
222
|
//si no hay espacio abajo pero sí arriba, se muestra arriba con separación dependiendo del size y tamaño del label
|
|
224
|
-
x <
|
|
225
|
-
), He = x <
|
|
223
|
+
x < a && z >= a ? n.top + window.scrollY - a - v - B : n.bottom + window.scrollY + v + E
|
|
224
|
+
), He = x < a && z >= a ? (
|
|
226
225
|
//si no cabe abajo, pero si arriba, se coloca con el tamaño mas pequeño entre 300 px y el espacio que hay arriba -15 px de margen (para que cuadre con el margen de los overlays de los modales etc)
|
|
227
|
-
Math.min(
|
|
226
|
+
Math.min(z - 15, 300)
|
|
228
227
|
) : (
|
|
229
228
|
//si tiene espacio abajo, se calcula la altura igual que arriba pero teniendo en cuenta el espacio que tiene abajo
|
|
230
229
|
Math.min(x - 15, 300)
|
|
@@ -248,86 +247,86 @@ import '../../assets/Select.css';const Ue = "_selectContainer_1sakp_23", Ze = "_
|
|
|
248
247
|
cancelAnimationFrame(c), window.removeEventListener("resize", r), window.removeEventListener("scroll", r, !0);
|
|
249
248
|
};
|
|
250
249
|
}, [
|
|
250
|
+
i,
|
|
251
251
|
l,
|
|
252
|
-
a,
|
|
253
252
|
R.length,
|
|
254
253
|
s,
|
|
255
254
|
T,
|
|
256
|
-
|
|
255
|
+
L,
|
|
257
256
|
q
|
|
258
257
|
]);
|
|
259
|
-
const
|
|
258
|
+
const pe = ({
|
|
260
259
|
insideDrawer: t = !1,
|
|
261
260
|
handleOptionClickProp: r
|
|
262
261
|
}) => {
|
|
263
262
|
const c = (n) => {
|
|
264
|
-
r ? r(n) :
|
|
263
|
+
r ? r(n) : J(n);
|
|
265
264
|
};
|
|
266
|
-
return R.length > 0 ? R.map((n,
|
|
265
|
+
return R.length > 0 ? R.map((n, a) => /* @__PURE__ */ b(
|
|
267
266
|
"div",
|
|
268
267
|
{
|
|
269
|
-
className: `${e.option} ${t ? e.isDrawer : ""} ${
|
|
270
|
-
onClick: (
|
|
271
|
-
|
|
268
|
+
className: `${e.option} ${t ? e.isDrawer : ""} ${ie(n.value) ? e.optionSelected : ""} ${p ? e.option_inverted : ""} ${n.columns ? e.optionTable : ""} ${H ? e.optionWithCheckbox : ""}`,
|
|
269
|
+
onClick: (h) => {
|
|
270
|
+
h.stopPropagation(), c(n.value);
|
|
272
271
|
},
|
|
273
272
|
children: [
|
|
274
273
|
H && /* @__PURE__ */ o(
|
|
275
274
|
"input",
|
|
276
275
|
{
|
|
277
276
|
type: "checkbox",
|
|
278
|
-
checked:
|
|
279
|
-
onChange: () =>
|
|
280
|
-
onClick: (
|
|
277
|
+
checked: ie(n.value),
|
|
278
|
+
onChange: () => J(n.value),
|
|
279
|
+
onClick: (h) => h.stopPropagation(),
|
|
281
280
|
className: e.optionCheckbox
|
|
282
281
|
}
|
|
283
282
|
),
|
|
284
|
-
n.columns ? /* @__PURE__ */ o(
|
|
285
|
-
/* @__PURE__ */ o("div", { className: `${e.columnHeader} ${e[
|
|
286
|
-
/* @__PURE__ */ o("div", { className: `${e.columnValue} ${e[
|
|
287
|
-
String(n.columns[
|
|
288
|
-
|
|
283
|
+
n.columns ? /* @__PURE__ */ o(ee, { children: V && Object.entries(V).map(([h, y]) => /* @__PURE__ */ b("div", { className: e.tableColumn, children: [
|
|
284
|
+
/* @__PURE__ */ o("div", { className: `${e.columnHeader} ${e[l]}`, children: y }),
|
|
285
|
+
/* @__PURE__ */ o("div", { className: `${e.columnValue} ${e[l]}`, children: K(
|
|
286
|
+
String(n.columns[h] ?? ""),
|
|
287
|
+
m
|
|
289
288
|
) })
|
|
290
|
-
] },
|
|
289
|
+
] }, h)) }) : (
|
|
291
290
|
//opción tiene descripción
|
|
292
291
|
n.description ? /* @__PURE__ */ b("div", { className: e.optionWithDescriptionWrapper, children: [
|
|
293
292
|
(n.icon || W) && /* @__PURE__ */ o(
|
|
294
293
|
F,
|
|
295
294
|
{
|
|
296
295
|
name: n.icon || W,
|
|
297
|
-
width:
|
|
298
|
-
height:
|
|
296
|
+
width: D,
|
|
297
|
+
height: D
|
|
299
298
|
}
|
|
300
299
|
),
|
|
301
300
|
/* @__PURE__ */ b("div", { className: e.optionWithDescription, children: [
|
|
302
|
-
/* @__PURE__ */ o("span", { className: e.optionWithDescriptionLabel, children:
|
|
301
|
+
/* @__PURE__ */ o("span", { className: e.optionWithDescriptionLabel, children: K(n.label, m) }),
|
|
303
302
|
/* @__PURE__ */ o("span", { className: e.optionWithDescriptionValue, children: n.description })
|
|
304
303
|
] })
|
|
305
|
-
] }) : /* @__PURE__ */ b(
|
|
304
|
+
] }) : /* @__PURE__ */ b(ee, { children: [
|
|
306
305
|
(n.icon || W) && /* @__PURE__ */ o("div", { className: e.optionIcon, children: /* @__PURE__ */ o(
|
|
307
306
|
F,
|
|
308
307
|
{
|
|
309
308
|
name: n.icon || W,
|
|
310
|
-
width:
|
|
311
|
-
height:
|
|
309
|
+
width: D,
|
|
310
|
+
height: D
|
|
312
311
|
}
|
|
313
312
|
) }),
|
|
314
|
-
/* @__PURE__ */ o("div", { style: { whiteSpace: "pre-line", lineHeight: 1.25 }, children:
|
|
313
|
+
/* @__PURE__ */ o("div", { style: { whiteSpace: "pre-line", lineHeight: 1.25 }, children: K(n.label, m) })
|
|
315
314
|
] })
|
|
316
315
|
)
|
|
317
316
|
]
|
|
318
317
|
},
|
|
319
|
-
|
|
320
|
-
)) : /* @__PURE__ */ o("span", { className: e.noResults, children:
|
|
318
|
+
a
|
|
319
|
+
)) : /* @__PURE__ */ o("span", { className: e.noResults, children: oe });
|
|
321
320
|
}, qe = () => {
|
|
322
321
|
const t = Ge(), r = (c) => {
|
|
323
|
-
|
|
322
|
+
J(c, !1), g || t();
|
|
324
323
|
};
|
|
325
324
|
return /* @__PURE__ */ o(
|
|
326
325
|
"div",
|
|
327
326
|
{
|
|
328
|
-
className: `${e.dropdown} ${e.isDrawer} ${e[
|
|
327
|
+
className: `${e.dropdown} ${e.isDrawer} ${e[l]} ${p ? e.dropdown_inverted : ""} ${V ? e.dropdownTable : ""} ${s ? e.dropdownSearchable : ""}`,
|
|
329
328
|
children: /* @__PURE__ */ o(
|
|
330
|
-
|
|
329
|
+
pe,
|
|
331
330
|
{
|
|
332
331
|
insideDrawer: !0,
|
|
333
332
|
handleOptionClickProp: r
|
|
@@ -339,21 +338,21 @@ import '../../assets/Select.css';const Ue = "_selectContainer_1sakp_23", Ze = "_
|
|
|
339
338
|
return /* @__PURE__ */ b(
|
|
340
339
|
"div",
|
|
341
340
|
{
|
|
342
|
-
ref:
|
|
343
|
-
className: `${e.selectContainer} ${
|
|
344
|
-
|
|
341
|
+
ref: Y,
|
|
342
|
+
className: `${e.selectContainer} ${l === "medium" ? e.selectContainer_medium : l === "large" ? e.selectContainer_large : l === "extraLarge" ? e.selectContainer_extraLarge : ""}`,
|
|
343
|
+
...$e,
|
|
345
344
|
children: [
|
|
346
345
|
T && /* @__PURE__ */ b(
|
|
347
346
|
"label",
|
|
348
347
|
{
|
|
349
|
-
className: `${e.label} ${
|
|
348
|
+
className: `${e.label} ${l === "large" ? e.label_large : ""} ${l === "extraLarge" ? e.label_extraLarge : ""} ${_ && !p ? e.label_disabled : ""} ${p && !_ ? e.label_inverted : ""} ${p && _ ? e.label_inverted_disabled : ""}`,
|
|
350
349
|
children: [
|
|
351
350
|
T,
|
|
352
351
|
/* @__PURE__ */ o(
|
|
353
352
|
"span",
|
|
354
353
|
{
|
|
355
|
-
className: `${e.required} ${
|
|
356
|
-
children:
|
|
354
|
+
className: `${e.required} ${_ && !p ? e.required_disabled : ""} ${p && !_ ? e.required_inverted : ""} ${p && _ ? e.required_inverted_disabled : ""}`,
|
|
355
|
+
children: me && "*"
|
|
357
356
|
}
|
|
358
357
|
)
|
|
359
358
|
]
|
|
@@ -364,21 +363,21 @@ import '../../assets/Select.css';const Ue = "_selectContainer_1sakp_23", Ze = "_
|
|
|
364
363
|
"div",
|
|
365
364
|
{
|
|
366
365
|
className: We,
|
|
367
|
-
onClick:
|
|
368
|
-
ref:
|
|
369
|
-
style:
|
|
366
|
+
onClick: Ie,
|
|
367
|
+
ref: A,
|
|
368
|
+
style: se ? { borderColor: se } : void 0,
|
|
370
369
|
children: [
|
|
371
370
|
/* @__PURE__ */ b("div", { className: e.iconLabel, children: [
|
|
372
|
-
(s ||
|
|
371
|
+
(s || ce && be) && /* @__PURE__ */ o(
|
|
373
372
|
"div",
|
|
374
373
|
{
|
|
375
|
-
className: `${e.icon} ${
|
|
374
|
+
className: `${e.icon} ${_ && !p ? e.icon_disabled : ""} ${p && !_ ? e.icon_inverted : ""} ${p && _ ? e.icon_inverted_disabled : ""}`,
|
|
376
375
|
children: /* @__PURE__ */ o(
|
|
377
376
|
F,
|
|
378
377
|
{
|
|
379
|
-
name: s ? "SearchIcon" :
|
|
380
|
-
width:
|
|
381
|
-
height:
|
|
378
|
+
name: s ? "SearchIcon" : ce,
|
|
379
|
+
width: D,
|
|
380
|
+
height: D
|
|
382
381
|
}
|
|
383
382
|
)
|
|
384
383
|
}
|
|
@@ -386,21 +385,21 @@ import '../../assets/Select.css';const Ue = "_selectContainer_1sakp_23", Ze = "_
|
|
|
386
385
|
s ? /* @__PURE__ */ o(
|
|
387
386
|
"input",
|
|
388
387
|
{
|
|
389
|
-
ref:
|
|
390
|
-
value:
|
|
391
|
-
className: `${e.selectInput} ${!
|
|
388
|
+
ref: X,
|
|
389
|
+
value: le,
|
|
390
|
+
className: `${e.selectInput} ${!u && !i && O.length === 0 ? e.placeholder : ""}`,
|
|
392
391
|
placeholder: Q,
|
|
393
|
-
onChange:
|
|
394
|
-
onFocus:
|
|
395
|
-
onClick:
|
|
396
|
-
disabled:
|
|
397
|
-
readOnly:
|
|
392
|
+
onChange: de,
|
|
393
|
+
onFocus: _e,
|
|
394
|
+
onClick: Oe,
|
|
395
|
+
disabled: _,
|
|
396
|
+
readOnly: G || !i
|
|
398
397
|
}
|
|
399
398
|
) : /* @__PURE__ */ o(
|
|
400
399
|
"span",
|
|
401
400
|
{
|
|
402
|
-
className: `${e.selectValue} ${
|
|
403
|
-
children:
|
|
401
|
+
className: `${e.selectValue} ${u ? "" : e.placeholder}`,
|
|
402
|
+
children: u ? u.label : Q
|
|
404
403
|
}
|
|
405
404
|
)
|
|
406
405
|
] }),
|
|
@@ -410,20 +409,20 @@ import '../../assets/Select.css';const Ue = "_selectContainer_1sakp_23", Ze = "_
|
|
|
410
409
|
name: "ArrowDown",
|
|
411
410
|
width: 16,
|
|
412
411
|
height: 16,
|
|
413
|
-
className: `${e.chevron} ${
|
|
412
|
+
className: `${e.chevron} ${i ? e.chevronOpen : ""}`
|
|
414
413
|
}
|
|
415
414
|
)
|
|
416
415
|
]
|
|
417
416
|
}
|
|
418
417
|
),
|
|
419
|
-
|
|
418
|
+
G ? /* @__PURE__ */ b(
|
|
420
419
|
Xe,
|
|
421
420
|
{
|
|
422
421
|
className: e.drawerSelect,
|
|
423
422
|
headerClassName: e.drawerSelectHeader,
|
|
424
|
-
isOpen:
|
|
425
|
-
setIsOpen:
|
|
426
|
-
title:
|
|
423
|
+
isOpen: i,
|
|
424
|
+
setIsOpen: S,
|
|
425
|
+
title: ke,
|
|
427
426
|
zIndex: 1,
|
|
428
427
|
children: [
|
|
429
428
|
s && /* @__PURE__ */ o("div", { className: e.drawerSearchInput, children: /* @__PURE__ */ o(
|
|
@@ -431,9 +430,9 @@ import '../../assets/Select.css';const Ue = "_selectContainer_1sakp_23", Ze = "_
|
|
|
431
430
|
{
|
|
432
431
|
placeholder: Q,
|
|
433
432
|
icon: "SearchIcon",
|
|
434
|
-
value:
|
|
435
|
-
onChange:
|
|
436
|
-
btc:
|
|
433
|
+
value: le,
|
|
434
|
+
onChange: de,
|
|
435
|
+
btc: re
|
|
437
436
|
}
|
|
438
437
|
) }),
|
|
439
438
|
/* @__PURE__ */ o(qe, {})
|
|
@@ -443,23 +442,23 @@ import '../../assets/Select.css';const Ue = "_selectContainer_1sakp_23", Ze = "_
|
|
|
443
442
|
/* @__PURE__ */ o(
|
|
444
443
|
"div",
|
|
445
444
|
{
|
|
446
|
-
ref:
|
|
447
|
-
className: `${e.dropdown} ${e[
|
|
445
|
+
ref: I,
|
|
446
|
+
className: `${e.dropdown} ${e[l]} ${e.dropdownPortal} ${p ? e.dropdown_inverted : ""} ${V ? e.dropdownTable : ""} ${s ? e.dropdownSearchable : ""}`,
|
|
448
447
|
style: Ee,
|
|
449
|
-
children: /* @__PURE__ */ o(
|
|
448
|
+
children: /* @__PURE__ */ o(pe, {})
|
|
450
449
|
}
|
|
451
450
|
),
|
|
452
451
|
document.getElementById("root") || document.body
|
|
453
452
|
)
|
|
454
453
|
] }),
|
|
455
|
-
|
|
456
|
-
q && !
|
|
454
|
+
L && /* @__PURE__ */ o(Ae, { message: L, size: l, inverted: p }),
|
|
455
|
+
q && !L && /* @__PURE__ */ o(
|
|
457
456
|
je,
|
|
458
457
|
{
|
|
459
458
|
message: q,
|
|
460
|
-
size:
|
|
461
|
-
disabled:
|
|
462
|
-
inverted:
|
|
459
|
+
size: l,
|
|
460
|
+
disabled: _,
|
|
461
|
+
inverted: p
|
|
463
462
|
}
|
|
464
463
|
)
|
|
465
464
|
]
|
package/dist/icons/Icon.js
CHANGED
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { jsxs as a, jsx as s } from "react/jsx-runtime";
|
|
2
|
+
const l = (t) => /* @__PURE__ */ a(
|
|
3
|
+
"svg",
|
|
4
|
+
{
|
|
5
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
6
|
+
fill: "none",
|
|
7
|
+
viewBox: "0 0 51 51",
|
|
8
|
+
width: "1em",
|
|
9
|
+
height: "1em",
|
|
10
|
+
...t,
|
|
11
|
+
children: [
|
|
12
|
+
/* @__PURE__ */ s(
|
|
13
|
+
"mask",
|
|
14
|
+
{
|
|
15
|
+
id: "sort_arrows_asc_svg__a",
|
|
16
|
+
width: 51,
|
|
17
|
+
height: 51,
|
|
18
|
+
x: 0,
|
|
19
|
+
y: 0,
|
|
20
|
+
maskUnits: "userSpaceOnUse",
|
|
21
|
+
style: {
|
|
22
|
+
maskType: "alpha"
|
|
23
|
+
},
|
|
24
|
+
children: /* @__PURE__ */ s("path", { fill: "currentColor", d: "M0 0h50.625v50.625H0z" })
|
|
25
|
+
}
|
|
26
|
+
),
|
|
27
|
+
/* @__PURE__ */ a("g", { fill: "#525252", mask: "url(#sort_arrows_asc_svg__a)", children: [
|
|
28
|
+
/* @__PURE__ */ s("path", { d: "M16.875 36.176V23.15q0-.896.607-1.502.606-.607 1.503-.607t1.502.607q.607.606.607 1.502v13.026l1.793-1.793q.633-.633 1.476-.607.844.027 1.477.607.633.633.66 1.503.025.87-.607 1.503L20.46 42.82q-.633.633-1.476.633-.844 0-1.477-.633l-5.432-5.431q-.633-.633-.606-1.503a2.15 2.15 0 0 1 .659-1.503 2.22 2.22 0 0 1 1.476-.607q.844-.026 1.477.607z" }),
|
|
29
|
+
/* @__PURE__ */ s(
|
|
30
|
+
"path",
|
|
31
|
+
{
|
|
32
|
+
d: "m27.862 15.721 2.022-1.789v12.277q0 .846.645 1.417.646.572 1.6.572t1.601-.572.646-1.417V13.933l2.022 1.79q.617.546 1.572.546.954 0 1.572-.547.618-.546.618-1.391 0-.846-.618-1.392l-5.84-5.17a2.3 2.3 0 0 0-1.572-.596q-.899 0-1.573.596l-5.84 5.17a1.78 1.78 0 0 0-.617 1.392q0 .845.617 1.391.618.547 1.573.547.954 0 1.572-.547",
|
|
33
|
+
opacity: 0.3
|
|
34
|
+
}
|
|
35
|
+
)
|
|
36
|
+
] })
|
|
37
|
+
]
|
|
38
|
+
}
|
|
39
|
+
);
|
|
40
|
+
export {
|
|
41
|
+
l as default
|
|
42
|
+
};
|