mimir-ui-kit 1.37.3 → 1.37.5
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/assets/styles.css +1 -1
- package/dist/{combobox-BpYucpxz.js → combobox-CDU06zJj.js} +1080 -1121
- package/dist/components/Accordion/Accordion.d.ts +10 -3
- package/dist/components/Accordion/Accordion.js +144 -139
- package/dist/components/CheckboxMimir/CheckboxMimir.js +4 -4
- package/dist/components/DatePicker/DatePicker.d.ts +4 -4
- package/dist/components/DatePicker/DatePicker.js +102 -99
- package/dist/components/DatePicker/DatePickerModal.js +1 -1
- package/dist/components/DatePicker/MonthPickerModal.js +1 -1
- package/dist/components/DatePicker/YearPickerModal.js +1 -1
- package/dist/components/MultiSelectSearch/MultiSelectSearch.js +22 -22
- package/dist/components/RadioGroup/RadioGroup.js +3 -3
- package/dist/components/SelectSearch/SelectSearch.js +24 -24
- package/dist/components/Switcher/Switcher.js +4 -4
- package/dist/components/TabTrail/TabTrail.js +4 -4
- package/dist/{field-C1kt7aNM.js → field-FJ34aSs4.js} +2 -2
- package/dist/{focus-management-DOYCPyGg.js → focus-management-XwV-9qkO.js} +1 -1
- package/dist/{hidden-PvGXrYUY.js → hidden-DbgtYPOH.js} +1 -1
- package/dist/{keyboard-mgWkd2Vh.js → keyboard-B0lm_zyn.js} +111 -114
- package/dist/{label-D4GFpe5F.js → label-y3ANLTNC.js} +2 -2
- package/dist/open-closed-CdldUPoq.js +86 -0
- package/dist/styles.module-CPvzaOtD.js +27 -0
- package/dist/{use-active-press-CqLGIFz7.js → use-active-press-86hajhdd.js} +1 -1
- package/package.json +1 -1
- package/dist/open-closed-D2VjDhAN.js +0 -86
- package/dist/styles.module-B3xL6-zc.js +0 -25
@@ -1,10 +1,10 @@
|
|
1
|
-
import { jsxs as
|
2
|
-
import { c as
|
1
|
+
import { jsxs as H, jsx as a } from "react/jsx-runtime";
|
2
|
+
import { c as _ } from "../../index-DIxK0V-G.js";
|
3
3
|
import { memo as V, forwardRef as tt, useState as w, useEffect as T } from "react";
|
4
4
|
import { MAX_DAY as st, MAX_MONTH as et, DATE_LENGTH as it } from "./constants.js";
|
5
|
-
import { DatePickerModal as
|
6
|
-
import { MonthPickerModal as
|
7
|
-
import { c as
|
5
|
+
import { DatePickerModal as rt } from "./DatePickerModal.js";
|
6
|
+
import { MonthPickerModal as ot } from "./MonthPickerModal.js";
|
7
|
+
import { c as e } from "../../styles.module-CPvzaOtD.js";
|
8
8
|
import { formatDatePart as L } from "./utils.js";
|
9
9
|
import { YearPickerModal as at } from "./YearPickerModal.js";
|
10
10
|
import { useClickOutside as ct } from "../../hooks/useClickOutside/useClickOutside.js";
|
@@ -13,137 +13,140 @@ import { formating as y } from "../../utils/index.js";
|
|
13
13
|
import { I as mt } from "../../Input-BYrIS5GU.js";
|
14
14
|
import { EInputStatus as pt, EInputSize as U } from "../Input/constants.js";
|
15
15
|
const dt = {
|
16
|
-
days:
|
17
|
-
months:
|
16
|
+
days: rt,
|
17
|
+
months: ot,
|
18
18
|
years: at
|
19
19
|
}, ft = V(
|
20
20
|
tt(
|
21
21
|
({
|
22
|
-
size:
|
23
|
-
value:
|
22
|
+
size: M,
|
23
|
+
value: i,
|
24
24
|
onChangeValue: s,
|
25
|
-
name:
|
26
|
-
before:
|
25
|
+
name: c,
|
26
|
+
before: v,
|
27
27
|
type: p = "days",
|
28
|
-
error:
|
28
|
+
error: x,
|
29
29
|
onError: d,
|
30
|
-
onBlur:
|
31
|
-
validateImmediately:
|
30
|
+
onBlur: r,
|
31
|
+
validateImmediately: b,
|
32
32
|
variant: X,
|
33
|
-
disabled:
|
33
|
+
disabled: S = !1,
|
34
34
|
editable: D = !1,
|
35
35
|
openOnInput: j = !0,
|
36
|
-
...
|
36
|
+
...E
|
37
37
|
}, F) => {
|
38
|
-
const [
|
39
|
-
() =>
|
40
|
-
), [
|
38
|
+
const [l, m] = w(!1), [g, f] = w(p), [o, k] = w(
|
39
|
+
() => i && !isNaN(new Date(i).getTime()) ? new Date(i) : void 0
|
40
|
+
), [n, h] = w(x), [G, A] = w("");
|
41
41
|
T(() => {
|
42
|
-
|
43
|
-
}, [
|
44
|
-
|
45
|
-
|
42
|
+
h(x);
|
43
|
+
}, [x]), T(() => {
|
44
|
+
k(
|
45
|
+
i && !isNaN(new Date(i).getTime()) ? new Date(i) : void 0
|
46
46
|
);
|
47
|
-
}, [
|
48
|
-
|
49
|
-
}, [
|
50
|
-
const
|
47
|
+
}, [i]), T(() => {
|
48
|
+
o && typeof o != "string" && !isNaN(o == null ? void 0 : o.getTime()) ? A(y.Date(o, "dd/mm/yyyy")) : A("");
|
49
|
+
}, [o]);
|
50
|
+
const u = i && new Date(i).getTime;
|
51
51
|
T(() => {
|
52
|
-
|
53
|
-
}, [
|
54
|
-
isActive:
|
52
|
+
b && (u ? (h(!1), d == null || d({ name: c, active: !1 })) : (h(!0), d == null || d({ name: c, active: !0 })));
|
53
|
+
}, [b, c, u]), ct({
|
54
|
+
isActive: l,
|
55
55
|
setActive: (t) => {
|
56
|
-
|
56
|
+
m(t), f(p);
|
57
57
|
},
|
58
|
-
className:
|
58
|
+
className: e["calendar-block"]
|
59
59
|
});
|
60
60
|
const K = () => {
|
61
|
-
!
|
61
|
+
!S && (j || !D) && m(!0);
|
62
62
|
}, W = (t) => {
|
63
|
-
isNaN(t.getTime()) || (
|
63
|
+
isNaN(t.getTime()) || (k(t), s == null || s({
|
64
64
|
value: y.Date(t, "yyyy-mm-dd"),
|
65
|
-
name:
|
66
|
-
})),
|
65
|
+
name: c
|
66
|
+
})), g === "years" && (p === "years" ? (m(!1), f(p)) : f("months")), g === "months" && (p === "months" ? (m(!1), f(p)) : f("days")), k(t), s == null || s({
|
67
67
|
value: y.Date(t, "yyyy-mm-dd"),
|
68
|
-
name:
|
69
|
-
}),
|
68
|
+
name: c
|
69
|
+
}), r == null || r(y.Date(t, "yyyy-mm-dd"));
|
70
70
|
}, q = (t) => {
|
71
71
|
if (D) {
|
72
|
-
const
|
73
|
-
if (
|
74
|
-
|
72
|
+
const N = t.target.value.replace(/[^\d]/g, "");
|
73
|
+
if (N.length === 0)
|
74
|
+
A(""), s == null || s({ value: "", name: c }), r == null || r("");
|
75
75
|
else {
|
76
|
-
const [
|
77
|
-
L(
|
78
|
-
L(
|
79
|
-
|
80
|
-
],
|
81
|
-
if (
|
82
|
-
const
|
83
|
-
`${
|
76
|
+
const [I, O, Y] = [
|
77
|
+
L(N.substring(0, 2), st),
|
78
|
+
L(N.substring(2, 4), et),
|
79
|
+
N.substring(4, 8)
|
80
|
+
], $ = [I, O, Y].filter(Boolean).join("/");
|
81
|
+
if (A($), $.length === it) {
|
82
|
+
const B = parseInt(Y), P = /* @__PURE__ */ new Date(
|
83
|
+
`${B}-${O.padStart(2, "0")}-${I.padStart(2, "0")}`
|
84
84
|
);
|
85
|
-
isNaN(
|
86
|
-
value: y.Date(
|
87
|
-
name:
|
88
|
-
}),
|
85
|
+
isNaN(P.getTime()) || (k(P), s == null || s({
|
86
|
+
value: y.Date(P, "yyyy-mm-dd"),
|
87
|
+
name: c
|
88
|
+
}), r == null || r(y.Date(P, "yyyy-mm-dd")));
|
89
89
|
}
|
90
90
|
}
|
91
91
|
}
|
92
|
-
},
|
92
|
+
}, J = _(e.wrapper, l && e.active), Q = _(e.input, e.inputBorderControl), Z = {
|
93
93
|
onChangeValue: W,
|
94
|
-
date:
|
95
|
-
before: typeof
|
94
|
+
date: o || /* @__PURE__ */ new Date(),
|
95
|
+
before: typeof v == "string" ? new Date(v) : v,
|
96
96
|
onChangeType: f,
|
97
|
-
setIsActive:
|
98
|
-
},
|
99
|
-
|
100
|
-
}, className:
|
97
|
+
setIsActive: m
|
98
|
+
}, z = dt[g], C = ({ isActive: t }) => /* @__PURE__ */ a("button", { onClick: (I) => {
|
99
|
+
I.stopPropagation(), S || m(!t);
|
100
|
+
}, className: e["icon-button"], children: t ? /* @__PURE__ */ a(
|
101
101
|
R,
|
102
102
|
{
|
103
|
-
iconName:
|
103
|
+
iconName: M === U.S ? "DropdownArrowUp16px" : "DropdownArrowUp24px"
|
104
104
|
}
|
105
|
-
) : /* @__PURE__ */
|
105
|
+
) : /* @__PURE__ */ a(
|
106
106
|
R,
|
107
107
|
{
|
108
|
-
iconName:
|
108
|
+
iconName: M === U.S ? "DropdownArrowBottom16px" : "DropdownArrowDown24px"
|
109
109
|
}
|
110
110
|
) });
|
111
|
-
return /* @__PURE__ */
|
112
|
-
/* @__PURE__ */
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
[
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
111
|
+
return /* @__PURE__ */ H("div", { className: e["input-field-group-datePicker"], children: [
|
112
|
+
/* @__PURE__ */ H("div", { className: J, "data-disabled": S, children: [
|
113
|
+
/* @__PURE__ */ a(
|
114
|
+
"div",
|
115
|
+
{
|
116
|
+
role: "button",
|
117
|
+
"data-error": n,
|
118
|
+
className: _(e["date-wrapper"], {
|
119
|
+
[e.editable]: D
|
120
|
+
}),
|
121
|
+
onClick: K,
|
122
|
+
children: /* @__PURE__ */ a(
|
123
|
+
mt,
|
124
|
+
{
|
125
|
+
ref: F,
|
126
|
+
className: Q,
|
127
|
+
wrapperClassName: e["input-wrapper"],
|
128
|
+
size: M,
|
129
|
+
type: "text",
|
130
|
+
variant: X,
|
131
|
+
status: n ? pt.Error : void 0,
|
132
|
+
value: G,
|
133
|
+
onChange: q,
|
134
|
+
rightAddon: {
|
135
|
+
addonType: "react-node",
|
136
|
+
addonContent: /* @__PURE__ */ a(C, { isActive: l })
|
137
|
+
},
|
138
|
+
onFocus: () => {
|
139
|
+
j && !D && m(!0);
|
140
|
+
},
|
141
|
+
"data-error": n,
|
142
|
+
...E
|
143
|
+
}
|
144
|
+
)
|
145
|
+
}
|
146
|
+
),
|
147
|
+
l && /* @__PURE__ */ a(z, { ...Z })
|
148
|
+
] }),
|
149
|
+
n && typeof n == "string" && /* @__PURE__ */ a("div", { className: e.textError, children: n })
|
147
150
|
] });
|
148
151
|
}
|
149
152
|
)
|
@@ -3,7 +3,7 @@ import { c as x } from "../../index-DIxK0V-G.js";
|
|
3
3
|
import { useState as O } from "react";
|
4
4
|
import { week as Y, COUNT_WORK_DAYS as j } from "./constants.js";
|
5
5
|
import { useDatePickerPosition as z } from "./hooks.js";
|
6
|
-
import { c as o } from "../../styles.module-
|
6
|
+
import { c as o } from "../../styles.module-CPvzaOtD.js";
|
7
7
|
import { getUpdateDate as M } from "./utils.js";
|
8
8
|
import { Icon as G } from "../../icons/Icon.js";
|
9
9
|
import { formating as s } from "../../utils/index.js";
|
@@ -3,7 +3,7 @@ import { c as k } from "../../index-DIxK0V-G.js";
|
|
3
3
|
import { useState as $ } from "react";
|
4
4
|
import { months as x } from "./constants.js";
|
5
5
|
import { useDatePickerPosition as v } from "./hooks.js";
|
6
|
-
import { c as e } from "../../styles.module-
|
6
|
+
import { c as e } from "../../styles.module-CPvzaOtD.js";
|
7
7
|
import { Icon as B } from "../../icons/Icon.js";
|
8
8
|
import { formating as a } from "../../utils/index.js";
|
9
9
|
import { Button as b } from "../Button/Button.js";
|
@@ -2,7 +2,7 @@ import { jsxs as p, jsx as o } from "react/jsx-runtime";
|
|
2
2
|
import { c as v } from "../../index-DIxK0V-G.js";
|
3
3
|
import { useState as x } from "react";
|
4
4
|
import { useDatePickerPosition as Y } from "./hooks.js";
|
5
|
-
import { c as t } from "../../styles.module-
|
5
|
+
import { c as t } from "../../styles.module-CPvzaOtD.js";
|
6
6
|
import { formating as n } from "../../utils/index.js";
|
7
7
|
import { Button as y } from "../Button/Button.js";
|
8
8
|
const F = ({
|
@@ -1,15 +1,15 @@
|
|
1
1
|
import { jsxs as g, jsx as n, Fragment as B } from "react/jsx-runtime";
|
2
2
|
import { c as l } from "../../index-DIxK0V-G.js";
|
3
|
-
import { forwardRef as ie, useRef as R, useState as S, useEffect as
|
3
|
+
import { forwardRef as ie, useRef as R, useState as S, useEffect as E, useMemo as le } from "react";
|
4
4
|
import { EMultiSelectSearchSize as M } from "./constants.js";
|
5
|
-
import { getInitialInputValue as
|
5
|
+
import { getInitialInputValue as F, mapSizeToInputSize as P, getDropdownArrowIcon as re, joinSelectedItems as j } from "./utils.js";
|
6
6
|
import { Icon as ce } from "../../icons/Icon.js";
|
7
7
|
import { Button as ae } from "../Button/Button.js";
|
8
8
|
import { CheckboxMimir as ue } from "../CheckboxMimir/CheckboxMimir.js";
|
9
9
|
import { Chip as de } from "../Chip/Chip.js";
|
10
10
|
import { I as G } from "../../Input-BYrIS5GU.js";
|
11
11
|
import { EInputVariant as pe } from "../Input/constants.js";
|
12
|
-
import { H as me, U as
|
12
|
+
import { H as me, U as W, G as H, K as _e, W as he } from "../../combobox-CDU06zJj.js";
|
13
13
|
import '../../assets/MultiSelectSearch.css';const fe = "_disabled_17kql_5", ke = "_container_17kql_9", qe = "_full_17kql_27", ge = "_button_17kql_39", be = "_options_17kql_53", ve = "_top_17kql_64", Ne = "_bottom_17kql_69", Ie = "_m_17kql_2", we = "_l_17kql_111", Ce = "_focused_17kql_129", Se = "_option_17kql_53", Me = "_chip_17kql_158", xe = "_clear_17kql_183", e = {
|
14
14
|
"multi-select-search": "_multi-select-search_17kql_2",
|
15
15
|
disabled: fe,
|
@@ -40,14 +40,14 @@ import '../../assets/MultiSelectSearch.css';const fe = "_disabled_17kql_5", ke =
|
|
40
40
|
"required-mark": "_required-mark_17kql_178",
|
41
41
|
clear: xe,
|
42
42
|
"icon-button": "_icon-button_17kql_192"
|
43
|
-
},
|
44
|
-
(
|
43
|
+
}, Pe = ie(
|
44
|
+
(J, K) => {
|
45
45
|
const {
|
46
46
|
placeholder: x,
|
47
47
|
size: i = M.L,
|
48
48
|
value: a,
|
49
49
|
onChange: s,
|
50
|
-
full:
|
50
|
+
full: U,
|
51
51
|
showArrow: Q = !0,
|
52
52
|
items: m = [],
|
53
53
|
classNameOption: X,
|
@@ -63,13 +63,13 @@ import '../../assets/MultiSelectSearch.css';const fe = "_disabled_17kql_5", ke =
|
|
63
63
|
chipVariant: Z = "sapphire",
|
64
64
|
disableInput: _ = !1,
|
65
65
|
autocomplete: O = "on"
|
66
|
-
} =
|
67
|
-
() =>
|
66
|
+
} = J, w = R(null), p = R(null), [b, h] = S(!1), [f, k] = S(
|
67
|
+
() => F(a, d)
|
68
68
|
), [u, q] = S(
|
69
69
|
a || []
|
70
70
|
);
|
71
|
-
|
72
|
-
a && (q(a), JSON.stringify(a) !== JSON.stringify(u) && k(
|
71
|
+
E(() => {
|
72
|
+
a && (q(a), JSON.stringify(a) !== JSON.stringify(u) && k(F(a, d)));
|
73
73
|
}, [a, d, u]);
|
74
74
|
const A = le(() => {
|
75
75
|
var o;
|
@@ -80,7 +80,7 @@ import '../../assets/MultiSelectSearch.css';const fe = "_disabled_17kql_5", ke =
|
|
80
80
|
);
|
81
81
|
}, [y, m, f]), $ = (t) => {
|
82
82
|
q(t), s == null || s(t);
|
83
|
-
const o =
|
83
|
+
const o = j(t, d);
|
84
84
|
k(o), h(!0), setTimeout(() => {
|
85
85
|
if (p.current) {
|
86
86
|
p.current.focus(), p.current.scrollLeft = p.current.scrollWidth;
|
@@ -100,7 +100,7 @@ import '../../assets/MultiSelectSearch.css';const fe = "_disabled_17kql_5", ke =
|
|
100
100
|
const o = u.filter(
|
101
101
|
(c) => c.id !== t.id
|
102
102
|
);
|
103
|
-
q(o), s == null || s(o), k(
|
103
|
+
q(o), s == null || s(o), k(j(o, d));
|
104
104
|
}, T = () => h((t) => !t), te = (t) => {
|
105
105
|
t.preventDefault(), t.currentTarget.focus();
|
106
106
|
const o = t.currentTarget.value.length;
|
@@ -112,7 +112,7 @@ import '../../assets/MultiSelectSearch.css';const fe = "_disabled_17kql_5", ke =
|
|
112
112
|
}, se = (t) => {
|
113
113
|
_ && t.target.blur();
|
114
114
|
};
|
115
|
-
return
|
115
|
+
return E(() => {
|
116
116
|
const t = (o) => {
|
117
117
|
w.current && !w.current.contains(o.target) && !o.defaultPrevented && h(!1);
|
118
118
|
};
|
@@ -127,11 +127,11 @@ import '../../assets/MultiSelectSearch.css';const fe = "_disabled_17kql_5", ke =
|
|
127
127
|
as: "div",
|
128
128
|
value: u,
|
129
129
|
className: l(e["multi-select-search"], {
|
130
|
-
[e.full]:
|
130
|
+
[e.full]: U,
|
131
131
|
[e.disabled]: r
|
132
132
|
}),
|
133
133
|
onChange: $,
|
134
|
-
ref:
|
134
|
+
ref: K,
|
135
135
|
disabled: r,
|
136
136
|
virtual: { options: A },
|
137
137
|
children: /* @__PURE__ */ g(
|
@@ -143,17 +143,17 @@ import '../../assets/MultiSelectSearch.css';const fe = "_disabled_17kql_5", ke =
|
|
143
143
|
children: [
|
144
144
|
_ && /* @__PURE__ */ g("div", { className: e["input-container"], children: [
|
145
145
|
/* @__PURE__ */ n(
|
146
|
-
|
146
|
+
W,
|
147
147
|
{
|
148
148
|
disabled: r,
|
149
149
|
style: { width: "100%" },
|
150
150
|
onClick: T,
|
151
151
|
children: /* @__PURE__ */ n(
|
152
|
-
|
152
|
+
H,
|
153
153
|
{
|
154
154
|
as: G,
|
155
155
|
label: x,
|
156
|
-
size:
|
156
|
+
size: P(i),
|
157
157
|
className: l(e["multi-select-input"], {
|
158
158
|
[e["multi-select-input-disabled"]]: _ && I
|
159
159
|
}),
|
@@ -195,11 +195,11 @@ import '../../assets/MultiSelectSearch.css';const fe = "_disabled_17kql_5", ke =
|
|
195
195
|
)
|
196
196
|
] }),
|
197
197
|
!_ && /* @__PURE__ */ n(
|
198
|
-
|
198
|
+
H,
|
199
199
|
{
|
200
200
|
as: G,
|
201
201
|
label: x,
|
202
|
-
size:
|
202
|
+
size: P(i),
|
203
203
|
className: e["multi-select-input"],
|
204
204
|
rightSlotClassName: e["right-slot"],
|
205
205
|
requiredMarkClassName: e["required-mark"],
|
@@ -214,7 +214,7 @@ import '../../assets/MultiSelectSearch.css';const fe = "_disabled_17kql_5", ke =
|
|
214
214
|
rightAddon: {
|
215
215
|
addonType: "react-node",
|
216
216
|
addonContent: Q && /* @__PURE__ */ n(
|
217
|
-
|
217
|
+
W,
|
218
218
|
{
|
219
219
|
className: l(e.button, {
|
220
220
|
[e.disabled]: r
|
@@ -323,5 +323,5 @@ import '../../assets/MultiSelectSearch.css';const fe = "_disabled_17kql_5", ke =
|
|
323
323
|
}
|
324
324
|
);
|
325
325
|
export {
|
326
|
-
|
326
|
+
Pe as MultiSelectSearch
|
327
327
|
};
|
@@ -1,10 +1,10 @@
|
|
1
1
|
import { jsxs as ee, jsx as L, Fragment as _e } from "react/jsx-runtime";
|
2
|
-
import { K as V, w as ye, a as oe, z as te, U as ie, b as ke, T as Oe, j as we, u as Pe, I as Ee, G as Te, p as De } from "../../label-
|
3
|
-
import { W, y as z, o as U, H as K, s as se, n as ne, $ as le, b as de, D as ue, a as Ce, u as Ge, c as N } from "../../keyboard-
|
2
|
+
import { K as V, w as ye, a as oe, z as te, U as ie, b as ke, T as Oe, j as we, u as Pe, I as Ee, G as Te, p as De } from "../../label-y3ANLTNC.js";
|
3
|
+
import { W, y as z, o as U, H as K, s as se, n as ne, $ as le, b as de, D as ue, a as Ce, u as Ge, c as N } from "../../keyboard-B0lm_zyn.js";
|
4
4
|
import E, { createContext as ce, useId as q, useReducer as xe, useRef as B, useMemo as T, useCallback as Fe, useContext as pe, forwardRef as Ne } from "react";
|
5
5
|
import { u as Ae } from "../../use-by-comparator-CVuf9KBq.js";
|
6
6
|
import { r as fe } from "../../bugs-diTMAGNw.js";
|
7
|
-
import { P as re, F as H, T as ae, _ as Ie } from "../../focus-management-
|
7
|
+
import { P as re, F as H, T as ae, _ as Ie } from "../../focus-management-XwV-9qkO.js";
|
8
8
|
import { c as M } from "../../index-DIxK0V-G.js";
|
9
9
|
import '../../assets/RadioGroup.css';var Se = ((e) => (e[e.RegisterOption = 0] = "RegisterOption", e[e.UnregisterOption = 1] = "UnregisterOption", e))(Se || {});
|
10
10
|
let Le = { 0(e, r) {
|
@@ -1,13 +1,13 @@
|
|
1
1
|
import { jsx as s, jsxs as _, Fragment as z } from "react/jsx-runtime";
|
2
2
|
import { c as i } from "../../index-DIxK0V-G.js";
|
3
|
-
import { forwardRef as K, useState as D, useMemo as U, useCallback as
|
3
|
+
import { forwardRef as K, useState as D, useMemo as U, useCallback as W, useEffect as R } from "react";
|
4
4
|
import { ESelectSearchSize as v } from "./constants.js";
|
5
|
-
import { mapSizeToInputSize as
|
6
|
-
import { Icon as
|
7
|
-
import { Button as
|
8
|
-
import { I as
|
9
|
-
import { EInputVariant as
|
10
|
-
import { H as X, U as
|
5
|
+
import { mapSizeToInputSize as q, getDropdownArrowIcon as $ } from "./utils.js";
|
6
|
+
import { Icon as A } from "../../icons/Icon.js";
|
7
|
+
import { Button as J } from "../Button/Button.js";
|
8
|
+
import { I as O } from "../../Input-BYrIS5GU.js";
|
9
|
+
import { EInputVariant as Q } from "../Input/constants.js";
|
10
|
+
import { H as X, U as B, G as M, K as Y, W as Z } from "../../combobox-CDU06zJj.js";
|
11
11
|
import '../../assets/SelectSearch.css';const ee = "_disabled_rphak_5", te = "_container_rphak_9", oe = "_full_rphak_22", ae = "_button_rphak_34", ne = "_options_rphak_48", se = "_top_rphak_59", re = "_bottom_rphak_64", ie = "_m_rphak_91", le = "_l_rphak_106", ce = "_option_rphak_48", pe = "_clear_rphak_160", e = {
|
12
12
|
"select-search": "_select-search_rphak_2",
|
13
13
|
disabled: ee,
|
@@ -34,7 +34,7 @@ import '../../assets/SelectSearch.css';const ee = "_disabled_rphak_5", te = "_co
|
|
34
34
|
clear: pe,
|
35
35
|
"icon-button": "_icon-button_rphak_169"
|
36
36
|
}, ge = K(
|
37
|
-
(
|
37
|
+
(j, E) => {
|
38
38
|
const {
|
39
39
|
placeholder: g,
|
40
40
|
size: r = v.L,
|
@@ -47,18 +47,18 @@ import '../../assets/SelectSearch.css';const ee = "_disabled_rphak_5", te = "_co
|
|
47
47
|
displayValue: G = "name",
|
48
48
|
filterOnSearch: w = !0,
|
49
49
|
onSearch: m,
|
50
|
-
variant: C =
|
50
|
+
variant: C = Q.DefaultGray,
|
51
51
|
menuPlacement: b = "bottom",
|
52
52
|
disabled: l = !1,
|
53
53
|
searchProps: I,
|
54
54
|
withClearButton: f = !1,
|
55
55
|
disableInput: c = !1,
|
56
56
|
autocomplete: S = "on"
|
57
|
-
} =
|
57
|
+
} = j, k = String((a == null ? void 0 : a[G]) || ""), [p, u] = D(k), [N, h] = D(a), y = U(() => !w || a && (a.id || a.name) ? d : p.trim().toLowerCase() ? d.filter(
|
58
58
|
(o) => o.name.toLowerCase().includes(p.toLowerCase())
|
59
59
|
) : d, [p, d, a, w]), P = (o) => {
|
60
60
|
o ? (u(o.name), h(o), n == null || n(o)) : (u(""), h(null), n == null || n({ id: "", name: "" }));
|
61
|
-
}, x =
|
61
|
+
}, x = W(
|
62
62
|
(o) => {
|
63
63
|
if (c) return;
|
64
64
|
const t = o.target.value;
|
@@ -68,7 +68,7 @@ import '../../assets/SelectSearch.css';const ee = "_disabled_rphak_5", te = "_co
|
|
68
68
|
), T = () => {
|
69
69
|
u(""), h(null), n == null || n({ id: "", name: "" });
|
70
70
|
};
|
71
|
-
return
|
71
|
+
return R(() => {
|
72
72
|
const o = !a || typeof a == "object" && !Object.keys(a).length;
|
73
73
|
u(o ? "" : k), h(o ? null : a);
|
74
74
|
}, [a, k]), /* @__PURE__ */ s(
|
@@ -93,12 +93,12 @@ import '../../assets/SelectSearch.css';const ee = "_disabled_rphak_5", te = "_co
|
|
93
93
|
}),
|
94
94
|
children: [
|
95
95
|
c && /* @__PURE__ */ _("div", { style: { position: "relative", width: "100%" }, children: [
|
96
|
-
/* @__PURE__ */ s(
|
97
|
-
|
96
|
+
/* @__PURE__ */ s(B, { disabled: l, style: { width: "100%" }, children: /* @__PURE__ */ s(
|
97
|
+
M,
|
98
98
|
{
|
99
|
-
as:
|
99
|
+
as: O,
|
100
100
|
label: g,
|
101
|
-
size:
|
101
|
+
size: q(r),
|
102
102
|
className: i(e["select-input"], {
|
103
103
|
[e["select-input-disabled"]]: c && f
|
104
104
|
}),
|
@@ -114,14 +114,14 @@ import '../../assets/SelectSearch.css';const ee = "_disabled_rphak_5", te = "_co
|
|
114
114
|
},
|
115
115
|
rightAddon: {
|
116
116
|
addonType: "icon",
|
117
|
-
addonContent:
|
117
|
+
addonContent: $(o, r)
|
118
118
|
},
|
119
119
|
autocomplete: S,
|
120
120
|
...I
|
121
121
|
}
|
122
122
|
) }),
|
123
123
|
f && p && /* @__PURE__ */ s(
|
124
|
-
|
124
|
+
J,
|
125
125
|
{
|
126
126
|
tabIndex: -1,
|
127
127
|
className: i(e.clear, {
|
@@ -142,11 +142,11 @@ import '../../assets/SelectSearch.css';const ee = "_disabled_rphak_5", te = "_co
|
|
142
142
|
)
|
143
143
|
] }),
|
144
144
|
!c && /* @__PURE__ */ s(
|
145
|
-
|
145
|
+
M,
|
146
146
|
{
|
147
|
-
as:
|
147
|
+
as: O,
|
148
148
|
label: g,
|
149
|
-
size:
|
149
|
+
size: q(r),
|
150
150
|
className: e["select-input"],
|
151
151
|
onChange: x,
|
152
152
|
value: p,
|
@@ -159,14 +159,14 @@ import '../../assets/SelectSearch.css';const ee = "_disabled_rphak_5", te = "_co
|
|
159
159
|
rightAddon: {
|
160
160
|
addonType: "react-node",
|
161
161
|
addonContent: V && /* @__PURE__ */ s(
|
162
|
-
|
162
|
+
B,
|
163
163
|
{
|
164
164
|
className: i(e.button, {
|
165
165
|
[e.disabled]: l
|
166
166
|
}),
|
167
167
|
disabled: l,
|
168
168
|
children: /* @__PURE__ */ s(
|
169
|
-
|
169
|
+
A,
|
170
170
|
{
|
171
171
|
iconName: r == v.M ? "DropdownArrowBottom16px" : "DropdownArrowDown24px",
|
172
172
|
className: i(e["selector-icon"], {
|
@@ -215,7 +215,7 @@ import '../../assets/SelectSearch.css';const ee = "_disabled_rphak_5", te = "_co
|
|
215
215
|
t.bottom && /* @__PURE__ */ s("div", { children: t.bottom })
|
216
216
|
] }),
|
217
217
|
N && N.id === t.id && /* @__PURE__ */ s(
|
218
|
-
|
218
|
+
A,
|
219
219
|
{
|
220
220
|
iconName: r === v.M ? "Done16px" : "Done24px",
|
221
221
|
className: e["selected-icon"]
|
@@ -1,9 +1,9 @@
|
|
1
1
|
import { jsxs as L, jsx as N } from "react/jsx-runtime";
|
2
|
-
import { H as te } from "../../field-
|
3
|
-
import { K as I, w as re, z as se, U as ae, u as ce, a as le, b as oe, T as ie, I as ne, G as ue, j as he, p as me } from "../../label-
|
4
|
-
import { W as de, H as j, y as pe, p as fe, o as $, $ as be, b as we, D as _e, c as H } from "../../keyboard-
|
2
|
+
import { H as te } from "../../field-FJ34aSs4.js";
|
3
|
+
import { K as I, w as re, z as se, U as ae, u as ce, a as le, b as oe, T as ie, I as ne, G as ue, j as he, p as me } from "../../label-y3ANLTNC.js";
|
4
|
+
import { W as de, H as j, y as pe, p as fe, o as $, $ as be, b as we, D as _e, c as H } from "../../keyboard-B0lm_zyn.js";
|
5
5
|
import u, { createContext as $e, useState as x, useMemo as G, useId as ge, useContext as ve, useRef as ke, useCallback as xe, Fragment as ye, forwardRef as Pe } from "react";
|
6
|
-
import { w as Ce } from "../../use-active-press-
|
6
|
+
import { w as Ce } from "../../use-active-press-86hajhdd.js";
|
7
7
|
import { e as De } from "../../use-resolve-button-type-DhFdPxnv.js";
|
8
8
|
import { r as Fe } from "../../bugs-diTMAGNw.js";
|
9
9
|
import { c as g } from "../../index-DIxK0V-G.js";
|
@@ -5,11 +5,11 @@ import N, { useRef as U, useState as Q, createContext as oe, useReducer as ke, u
|
|
5
5
|
import { ETabTrailSize as Ae } from "./constants.js";
|
6
6
|
import { TabButtons as Se } from "./TabButtons/TabButtons.js";
|
7
7
|
import { NotificationBadge as Fe } from "../NotificationBadge/NotificationBadge.js";
|
8
|
-
import { n as W, M as se, W as q, s as H, y as z, o as E, H as V, $ as ce, b as De, D as de, a as B, u as Ne, c as h, t as Re } from "../../keyboard-
|
9
|
-
import { w as Me } from "../../use-active-press-
|
8
|
+
import { n as W, M as se, W as q, s as H, y as z, o as E, H as V, $ as ce, b as De, D as de, a as B, u as Ne, c as h, t as Re } from "../../keyboard-B0lm_zyn.js";
|
9
|
+
import { w as Me } from "../../use-active-press-86hajhdd.js";
|
10
10
|
import { e as Ce } from "../../use-resolve-button-type-DhFdPxnv.js";
|
11
|
-
import { T as pe, s as Le } from "../../hidden-
|
12
|
-
import { _ as G, T as J, P as D, F as T } from "../../focus-management-
|
11
|
+
import { T as pe, s as Le } from "../../hidden-DbgtYPOH.js";
|
12
|
+
import { _ as G, T as J, P as D, F as T } from "../../focus-management-XwV-9qkO.js";
|
13
13
|
import '../../assets/TabTrail.css';function Oe() {
|
14
14
|
let e = U(!1);
|
15
15
|
return W(() => (e.current = !0, () => {
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import l, { useId as u, useMemo as f } from "react";
|
2
|
-
import { z as p, U as h, a as v, l as E, f as b, W as $ } from "./label-
|
3
|
-
import { W as H, H as W } from "./keyboard-
|
2
|
+
import { z as p, U as h, a as v, l as E, f as b, W as $ } from "./label-y3ANLTNC.js";
|
3
|
+
import { W as H, H as W } from "./keyboard-B0lm_zyn.js";
|
4
4
|
let P = "div";
|
5
5
|
function _(a, i) {
|
6
6
|
let d = `headlessui-control-${u()}`, [o, n] = p(), [m, s] = h(), c = v(), { disabled: e = c || !1, ...t } = a, r = f(() => ({ disabled: e }), [e]);
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { u as N, a as v } from "./keyboard-
|
1
|
+
import { u as N, a as v } from "./keyboard-B0lm_zyn.js";
|
2
2
|
let m = ["[contentEditable=true]", "[tabindex]", "a[href]", "area[href]", "button:not([disabled])", "iframe", "input:not([disabled])", "select:not([disabled])", "textarea:not([disabled])"].map((e) => `${e}:not([tabindex='-1'])`).join(","), F = ["[data-autofocus]"].map((e) => `${e}:not([tabindex='-1'])`).join(",");
|
3
3
|
var h = ((e) => (e[e.First = 1] = "First", e[e.Previous = 2] = "Previous", e[e.Next = 4] = "Next", e[e.Last = 8] = "Last", e[e.WrapAround = 16] = "WrapAround", e[e.NoScroll = 32] = "NoScroll", e[e.AutoFocus = 64] = "AutoFocus", e))(h || {}), x = ((e) => (e[e.Error = 0] = "Error", e[e.Overflow = 1] = "Overflow", e[e.Success = 2] = "Success", e[e.Underflow = 3] = "Underflow", e))(x || {}), A = ((e) => (e[e.Previous = -1] = "Previous", e[e.Next = 1] = "Next", e))(A || {});
|
4
4
|
function y(e = document.body) {
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { W as t, H as a } from "./keyboard-
|
1
|
+
import { W as t, H as a } from "./keyboard-B0lm_zyn.js";
|
2
2
|
let l = "span";
|
3
3
|
var p = ((e) => (e[e.None = 1] = "None", e[e.Focusable = 2] = "Focusable", e[e.Hidden = 4] = "Hidden", e))(p || {});
|
4
4
|
function s(e, n) {
|