@reportportal/ui-kit 0.0.1-alpha.6 → 0.0.1-alpha.8
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/LICENSE +201 -201
- package/README.md +197 -3
- package/dist/baseIconButton-7bc53dec.js +25 -0
- package/dist/baseIconButton.js +7 -0
- package/dist/bubblesLoader-a7e709d4.js +17 -0
- package/dist/bubblesLoader.js +1 -1
- package/dist/button-497b4d19.js +62 -0
- package/dist/button.js +1 -1
- package/dist/{checkbox-fdc44740.js → checkbox-1e21cf3e.js} +16 -16
- package/dist/checkbox.js +1 -1
- package/dist/components/button/button.d.ts +0 -1
- package/dist/components/button/index.d.ts +2 -2
- package/dist/components/dropdown/constants.d.ts +4 -0
- package/dist/components/dropdown/dropdown.d.ts +0 -1
- package/dist/components/fieldNumber/fieldNumber.d.ts +1 -1
- package/dist/components/fieldTextFlex/fieldTextFlex.d.ts +14 -0
- package/dist/components/fieldTextFlex/index.d.ts +3 -0
- package/dist/components/icons/baseIconButton/baseIconButton.d.ts +8 -0
- package/dist/components/icons/baseIconButton/index.d.ts +4 -0
- package/dist/components/icons/index.d.ts +7 -0
- package/dist/components/index.d.ts +1 -1
- package/dist/components/modal/modal.d.ts +3 -1
- package/dist/components/radio/index.d.ts +4 -0
- package/dist/components/radio/radio.d.ts +16 -0
- package/dist/components/radio/radioGroup.d.ts +8 -0
- package/dist/components/themeProvider/themeProvider.d.ts +2 -1
- package/dist/dropdown-e07f2a71.js +212 -0
- package/dist/dropdown.js +3 -4
- package/dist/fieldNumber-46fe79b9.js +127 -0
- package/dist/fieldNumber.js +2 -3
- package/dist/fieldText-65a50d9d.js +101 -0
- package/dist/fieldText.js +2 -2
- package/dist/index-2bee4457.js +131 -0
- package/dist/index.js +31 -25
- package/dist/modal.js +14 -126
- package/dist/style.css +1 -1
- package/dist/systemMessage-1ced6079.js +30 -0
- package/dist/systemMessage.js +1 -1
- package/dist/themeProvider-46c2be7b.js +23 -0
- package/dist/themeProvider.js +4 -3
- package/dist/toggle-707ecb74.js +67 -0
- package/dist/toggle.js +1 -1
- package/package.json +28 -5
- package/dist/bubblesLoader-9bec3797.js +0 -17
- package/dist/button-d4944dbc.js +0 -64
- package/dist/clear-4963efcd.js +0 -5
- package/dist/components/icon/icon.d.ts +0 -11
- package/dist/components/icon/icons.d.ts +0 -21
- package/dist/components/icon/index.d.ts +0 -3
- package/dist/dropdown-45e7bc7d.js +0 -204
- package/dist/fieldNumber-8417cd65.js +0 -132
- package/dist/fieldText-c7085849.js +0 -99
- package/dist/icon-71262f5c.js +0 -26
- package/dist/icon.js +0 -9
- package/dist/systemMessage-62c3133d.js +0 -30
- package/dist/themeProvider-5800417e.js +0 -19
- package/dist/toggle-5b3d8333.js +0 -67
|
@@ -1,204 +0,0 @@
|
|
|
1
|
-
import { jsx as d, jsxs as R } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef as Q, useState as X, useRef as S } from "react";
|
|
3
|
-
import { c as H } from "./bind-06a7ff84.js";
|
|
4
|
-
import { Manager as Z, Reference as U, Popper as F } from "react-popper";
|
|
5
|
-
import { useSelect as N } from "downshift";
|
|
6
|
-
import { Scrollbars as B } from "rc-scrollbars";
|
|
7
|
-
import { u as ee } from "./useOnClickOutside-c332f7d3.js";
|
|
8
|
-
import { K as u } from "./keyCodes-f63c0e11.js";
|
|
9
|
-
import { I as ne } from "./icon-71262f5c.js";
|
|
10
|
-
const te = "_disabled_ev7l2_13", oe = "_hidden_ev7l2_17", de = "_selected_ev7l2_23", re = "_hover_ev7l2_26", le = {
|
|
11
|
-
"dropdown-option": "_dropdown-option_ev7l2_1",
|
|
12
|
-
disabled: te,
|
|
13
|
-
hidden: oe,
|
|
14
|
-
selected: de,
|
|
15
|
-
hover: re,
|
|
16
|
-
"single-option": "_single-option_ev7l2_39",
|
|
17
|
-
"sub-option": "_sub-option_ev7l2_45"
|
|
18
|
-
}, T = H.bind(le), se = Q(
|
|
19
|
-
(t, n) => {
|
|
20
|
-
const {
|
|
21
|
-
option: { value: l, disabled: a, hidden: m, label: i, title: r, groupRef: b },
|
|
22
|
-
selected: w,
|
|
23
|
-
onChange: g,
|
|
24
|
-
render: f,
|
|
25
|
-
highlightHovered: E,
|
|
26
|
-
onMouseEnter: p
|
|
27
|
-
} = t, C = () => {
|
|
28
|
-
g && g(l);
|
|
29
|
-
};
|
|
30
|
-
return /* @__PURE__ */ d(
|
|
31
|
-
"div",
|
|
32
|
-
{
|
|
33
|
-
className: T("dropdown-option", {
|
|
34
|
-
selected: w,
|
|
35
|
-
disabled: a,
|
|
36
|
-
hidden: m,
|
|
37
|
-
hover: E
|
|
38
|
-
}),
|
|
39
|
-
title: a && r || void 0,
|
|
40
|
-
onClick: C,
|
|
41
|
-
ref: n,
|
|
42
|
-
onMouseEnter: p,
|
|
43
|
-
children: /* @__PURE__ */ d("div", { className: T("single-option", { "sub-option": !!b }), children: f ? f(t) : i })
|
|
44
|
-
}
|
|
45
|
-
);
|
|
46
|
-
}
|
|
47
|
-
), ae = [
|
|
48
|
-
u.ENTER_KEY_CODE,
|
|
49
|
-
u.SPACE_KEY_CODE,
|
|
50
|
-
u.ARROW_DOWN_KEY_CODE
|
|
51
|
-
], ie = [u.ESCAPE_KEY_CODE, u.TAB_KEY_CODE], ce = (t, n) => t.map(({ value: l }) => l).indexOf(n), _e = (t, n) => (t % n + n) % n, x = (t, n = 0, l = 1) => {
|
|
52
|
-
if (!t[n].disabled)
|
|
53
|
-
return n;
|
|
54
|
-
const a = t.length;
|
|
55
|
-
return x(t, _e(n + l, a));
|
|
56
|
-
}, he = (t, n) => x(t, n), ue = (t, n) => x(t, n, -1), fe = "_container_1d54v_1", ge = "_icon_1d54v_10", pe = "_arrow_1d54v_16", ve = "_dropdown_1d54v_22", me = "_disabled_1d54v_39", be = "_error_1d54v_43", we = "_touched_1d54v_43", Ee = "_opened_1d54v_47", Ce = "_placeholder_1d54v_72", De = "_value_1d54v_75", Oe = "_ghost_1d54v_113", Ne = {
|
|
57
|
-
container: fe,
|
|
58
|
-
"default-width": "_default-width_1d54v_6",
|
|
59
|
-
icon: ge,
|
|
60
|
-
arrow: pe,
|
|
61
|
-
dropdown: ve,
|
|
62
|
-
"transparent-background": "_transparent-background_1d54v_36",
|
|
63
|
-
disabled: me,
|
|
64
|
-
error: be,
|
|
65
|
-
touched: we,
|
|
66
|
-
opened: Ee,
|
|
67
|
-
placeholder: Ce,
|
|
68
|
-
value: De,
|
|
69
|
-
"mobile-disabled": "_mobile-disabled_1d54v_87",
|
|
70
|
-
"select-list": "_select-list_1d54v_92",
|
|
71
|
-
ghost: Oe
|
|
72
|
-
}, h = H.bind(Ne), Pe = ({
|
|
73
|
-
value: t = "",
|
|
74
|
-
options: n = [],
|
|
75
|
-
disabled: l = !1,
|
|
76
|
-
error: a,
|
|
77
|
-
onChange: m,
|
|
78
|
-
onFocus: i,
|
|
79
|
-
onBlur: r,
|
|
80
|
-
mobileDisabled: b,
|
|
81
|
-
title: w,
|
|
82
|
-
touched: g = !1,
|
|
83
|
-
icon: f,
|
|
84
|
-
variant: E,
|
|
85
|
-
placeholder: p = "",
|
|
86
|
-
defaultWidth: C = !0,
|
|
87
|
-
renderOption: M,
|
|
88
|
-
transparentBackground: P = !1,
|
|
89
|
-
className: Y,
|
|
90
|
-
toggleButtonClassName: A
|
|
91
|
-
}) => {
|
|
92
|
-
const [c, _] = X(!1), y = S(null), s = S(null);
|
|
93
|
-
ee(y, () => {
|
|
94
|
-
c && (_(!1), r && r());
|
|
95
|
-
});
|
|
96
|
-
const I = (e) => {
|
|
97
|
-
e.disabled || (m(e.value), _((o) => !o));
|
|
98
|
-
}, W = () => n.find(({ value: e }) => e === t), K = ce(n, t), {
|
|
99
|
-
getToggleButtonProps: $,
|
|
100
|
-
getMenuProps: j,
|
|
101
|
-
getItemProps: V,
|
|
102
|
-
setHighlightedIndex: v,
|
|
103
|
-
highlightedIndex: k,
|
|
104
|
-
selectedItem: D
|
|
105
|
-
} = N({
|
|
106
|
-
items: n,
|
|
107
|
-
itemToString: (e) => (e != null && e.label ? String(e.label) : p) || "",
|
|
108
|
-
selectedItem: W(),
|
|
109
|
-
isOpen: c,
|
|
110
|
-
circularNavigation: !0,
|
|
111
|
-
defaultHighlightedIndex: K,
|
|
112
|
-
onHighlightedIndexChange: (e) => {
|
|
113
|
-
switch (e.type) {
|
|
114
|
-
case N.stateChangeTypes.MenuKeyDownArrowUp:
|
|
115
|
-
return v(ue(n, e.highlightedIndex)), e;
|
|
116
|
-
case N.stateChangeTypes.MenuKeyDownArrowDown:
|
|
117
|
-
return v(he(n, e.highlightedIndex)), e;
|
|
118
|
-
default:
|
|
119
|
-
return e;
|
|
120
|
-
}
|
|
121
|
-
}
|
|
122
|
-
}), L = () => {
|
|
123
|
-
l || (s != null && s.current && s.current(), _((e) => !e), c ? r && r() : i && i());
|
|
124
|
-
}, q = () => {
|
|
125
|
-
if (!t && t !== !1)
|
|
126
|
-
return p;
|
|
127
|
-
let e = t;
|
|
128
|
-
return n.forEach((o) => {
|
|
129
|
-
o.value === t && (e = o.label);
|
|
130
|
-
}), e;
|
|
131
|
-
}, z = (e) => {
|
|
132
|
-
const { keyCode: o } = e;
|
|
133
|
-
ae.includes(o) && !c && (e.preventDefault(), v(K), s != null && s.current && s.current(), _(!0), i && i());
|
|
134
|
-
}, G = (e) => {
|
|
135
|
-
const { keyCode: o } = e;
|
|
136
|
-
if (o === u.ENTER_KEY_CODE) {
|
|
137
|
-
const O = n[k];
|
|
138
|
-
I(O), _(!1), r && r();
|
|
139
|
-
return;
|
|
140
|
-
}
|
|
141
|
-
ie.includes(o) && (e.stopPropagation(), _(!1), r && r());
|
|
142
|
-
}, J = () => n.map((e, o) => /* @__PURE__ */ d(
|
|
143
|
-
se,
|
|
144
|
-
{
|
|
145
|
-
...V({
|
|
146
|
-
item: e,
|
|
147
|
-
index: o
|
|
148
|
-
}),
|
|
149
|
-
selected: e.value === (D == null ? void 0 : D.value),
|
|
150
|
-
option: e,
|
|
151
|
-
highlightHovered: k === o,
|
|
152
|
-
render: M,
|
|
153
|
-
onChange: e.disabled ? null : () => I(e),
|
|
154
|
-
onMouseEnter: () => v(o)
|
|
155
|
-
},
|
|
156
|
-
e.value
|
|
157
|
-
));
|
|
158
|
-
return /* @__PURE__ */ d(Z, { children: /* @__PURE__ */ R(
|
|
159
|
-
"div",
|
|
160
|
-
{
|
|
161
|
-
ref: y,
|
|
162
|
-
className: h("container", { "default-width": C }, Y),
|
|
163
|
-
title: w,
|
|
164
|
-
children: [
|
|
165
|
-
/* @__PURE__ */ d(U, { children: ({ ref: e }) => /* @__PURE__ */ R(
|
|
166
|
-
"button",
|
|
167
|
-
{
|
|
168
|
-
...$({
|
|
169
|
-
ref: e,
|
|
170
|
-
tabIndex: l ? -1 : 0,
|
|
171
|
-
className: h("dropdown", E, A, {
|
|
172
|
-
"transparent-background": P,
|
|
173
|
-
opened: c,
|
|
174
|
-
disabled: l,
|
|
175
|
-
error: a,
|
|
176
|
-
touched: g,
|
|
177
|
-
"mobile-disabled": b
|
|
178
|
-
}),
|
|
179
|
-
onClick: L,
|
|
180
|
-
onKeyDown: z
|
|
181
|
-
}),
|
|
182
|
-
children: [
|
|
183
|
-
f && /* @__PURE__ */ d("span", { className: h("icon"), children: f }),
|
|
184
|
-
/* @__PURE__ */ d("span", { className: h("value", { placeholder: !t }), children: q() }),
|
|
185
|
-
/* @__PURE__ */ d(ne, { icon: "dropdown", className: h("arrow") })
|
|
186
|
-
]
|
|
187
|
-
}
|
|
188
|
-
) }),
|
|
189
|
-
/* @__PURE__ */ d(F, { placement: "bottom-start", children: ({ ref: e, style: o, update: O }) => (s.current = O, /* @__PURE__ */ d(
|
|
190
|
-
"div",
|
|
191
|
-
{
|
|
192
|
-
className: h("select-list", { opened: c }),
|
|
193
|
-
style: o,
|
|
194
|
-
...j({ ref: e, onKeyDown: G }),
|
|
195
|
-
children: /* @__PURE__ */ d(B, { autoHeight: !0, autoHeightMax: 216, hideTracksWhenNotNeeded: !0, children: J() })
|
|
196
|
-
}
|
|
197
|
-
)) })
|
|
198
|
-
]
|
|
199
|
-
}
|
|
200
|
-
) });
|
|
201
|
-
};
|
|
202
|
-
export {
|
|
203
|
-
Pe as D
|
|
204
|
-
};
|
|
@@ -1,132 +0,0 @@
|
|
|
1
|
-
import { jsxs as O, jsx as r } from "react/jsx-runtime";
|
|
2
|
-
import { useRef as A, useMemo as j } from "react";
|
|
3
|
-
import { c as T } from "./bind-06a7ff84.js";
|
|
4
|
-
import { K as _ } from "./keyCodes-f63c0e11.js";
|
|
5
|
-
import { I as d } from "./icon-71262f5c.js";
|
|
6
|
-
const W = 5, D = 16, g = [
|
|
7
|
-
_.TAB_KEY_CODE,
|
|
8
|
-
_.BACKSPACE_KEY_CODE,
|
|
9
|
-
_.ARROW_LEFT_KEY_CODE,
|
|
10
|
-
_.ARROW_UP_KEY_CODE,
|
|
11
|
-
_.ARROW_RIGHT_KEY_CODE,
|
|
12
|
-
_.ARROW_DOWN_KEY_CODE,
|
|
13
|
-
_.DELETE_KEY_CODE,
|
|
14
|
-
_.NUM_LOCK_0_KEY_CODE,
|
|
15
|
-
_.NUM_LOCK_1_KEY_CODE,
|
|
16
|
-
_.NUM_LOCK_2_KEY_CODE,
|
|
17
|
-
_.NUM_LOCK_3_KEY_CODE,
|
|
18
|
-
_.NUM_LOCK_4_KEY_CODE,
|
|
19
|
-
_.NUM_LOCK_5_KEY_CODE,
|
|
20
|
-
_.NUM_LOCK_6_KEY_CODE,
|
|
21
|
-
_.NUM_LOCK_7_KEY_CODE,
|
|
22
|
-
_.NUM_LOCK_8_KEY_CODE,
|
|
23
|
-
_.NUM_LOCK_9_KEY_CODE
|
|
24
|
-
], y = "_disabled_1jvvf_6", I = "_label_1jvvf_10", w = "_sign_1jvvf_21", b = "_error_1jvvf_36", k = "_touched_1jvvf_36", B = "_filled_1jvvf_41", F = "_input_1jvvf_26", H = {
|
|
25
|
-
"field-number": "_field-number_1jvvf_1",
|
|
26
|
-
disabled: y,
|
|
27
|
-
label: I,
|
|
28
|
-
sign: w,
|
|
29
|
-
"input-container": "_input-container_1jvvf_26",
|
|
30
|
-
error: b,
|
|
31
|
-
touched: k,
|
|
32
|
-
filled: B,
|
|
33
|
-
"input-field": "_input-field_1jvvf_48",
|
|
34
|
-
input: F
|
|
35
|
-
}, c = T.bind(H), q = ({
|
|
36
|
-
value: e = "",
|
|
37
|
-
placeholder: a = "0",
|
|
38
|
-
disabled: s = !1,
|
|
39
|
-
onChange: l,
|
|
40
|
-
onFocus: f,
|
|
41
|
-
onBlur: S,
|
|
42
|
-
label: u,
|
|
43
|
-
postfix: i = "",
|
|
44
|
-
min: o = 0,
|
|
45
|
-
max: E = Number.MAX_SAFE_INTEGER,
|
|
46
|
-
title: p,
|
|
47
|
-
error: N,
|
|
48
|
-
touched: h = !1,
|
|
49
|
-
...m
|
|
50
|
-
}) => {
|
|
51
|
-
const C = A(null), Y = (n) => {
|
|
52
|
-
let t = n.target.value.replace(/^0(?=\d+|^\d)/g, "");
|
|
53
|
-
if (t === "") {
|
|
54
|
-
l("");
|
|
55
|
-
return;
|
|
56
|
-
}
|
|
57
|
-
t = +t, t >= o && t <= E && l(t);
|
|
58
|
-
}, v = (n) => {
|
|
59
|
-
const { keyCode: t } = n;
|
|
60
|
-
g.includes(t) || (t < _.NUMBER_START_KEY_CODE || t > _.NUMBER_END_KEY_CODE || n.shiftKey) && n.preventDefault();
|
|
61
|
-
}, L = () => {
|
|
62
|
-
const n = +e - 1;
|
|
63
|
-
n >= o && n <= E && l(n);
|
|
64
|
-
}, M = () => {
|
|
65
|
-
const n = +e + 1;
|
|
66
|
-
n >= o && n <= E && l(n);
|
|
67
|
-
}, K = a + i, R = j(() => {
|
|
68
|
-
let n = (String(e) || K).length;
|
|
69
|
-
return i && !e && (n += 1), n > D ? `${D}ch` : `${n || W}ch`;
|
|
70
|
-
}, [K, i, e]), U = () => {
|
|
71
|
-
C && C.current && C.current.focus(), f && f();
|
|
72
|
-
};
|
|
73
|
-
return /* @__PURE__ */ O("div", { className: c("field-number", { disabled: s }), children: [
|
|
74
|
-
u && /* @__PURE__ */ r("span", { className: c("label"), children: u }),
|
|
75
|
-
/* @__PURE__ */ O(
|
|
76
|
-
"div",
|
|
77
|
-
{
|
|
78
|
-
className: c("input-container", {
|
|
79
|
-
filled: !!e || e === 0,
|
|
80
|
-
error: N,
|
|
81
|
-
disabled: s,
|
|
82
|
-
touched: h
|
|
83
|
-
}),
|
|
84
|
-
title: p,
|
|
85
|
-
children: [
|
|
86
|
-
/* @__PURE__ */ r(
|
|
87
|
-
d,
|
|
88
|
-
{
|
|
89
|
-
icon: "minus",
|
|
90
|
-
className: c("sign", "minus"),
|
|
91
|
-
disabled: s,
|
|
92
|
-
onClick: L
|
|
93
|
-
}
|
|
94
|
-
),
|
|
95
|
-
/* @__PURE__ */ O("span", { className: c("input-field", { disabled: s }), onClick: U, children: [
|
|
96
|
-
/* @__PURE__ */ r(
|
|
97
|
-
"input",
|
|
98
|
-
{
|
|
99
|
-
ref: C,
|
|
100
|
-
className: c("input"),
|
|
101
|
-
type: "number",
|
|
102
|
-
value: e,
|
|
103
|
-
placeholder: K,
|
|
104
|
-
disabled: s,
|
|
105
|
-
min: o,
|
|
106
|
-
max: E,
|
|
107
|
-
onKeyDown: s ? void 0 : v,
|
|
108
|
-
onChange: s ? void 0 : Y,
|
|
109
|
-
onFocus: s ? void 0 : f,
|
|
110
|
-
style: { width: R },
|
|
111
|
-
...m
|
|
112
|
-
}
|
|
113
|
-
),
|
|
114
|
-
!!i && (e === 0 || !!e) && /* @__PURE__ */ r("span", { children: i.slice(0, 1) })
|
|
115
|
-
] }),
|
|
116
|
-
/* @__PURE__ */ r(
|
|
117
|
-
d,
|
|
118
|
-
{
|
|
119
|
-
icon: "plus",
|
|
120
|
-
className: c("sign", "plus"),
|
|
121
|
-
disabled: s,
|
|
122
|
-
onClick: M
|
|
123
|
-
}
|
|
124
|
-
)
|
|
125
|
-
]
|
|
126
|
-
}
|
|
127
|
-
)
|
|
128
|
-
] });
|
|
129
|
-
};
|
|
130
|
-
export {
|
|
131
|
-
q as F
|
|
132
|
-
};
|
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
import { jsx as e, jsxs as t, Fragment as h } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef as S } from "react";
|
|
3
|
-
import { c as v } from "./bind-06a7ff84.js";
|
|
4
|
-
import { S as C } from "./clear-4963efcd.js";
|
|
5
|
-
const E = "_label_11rxn_18", z = "_asterisk_11rxn_27", A = "_disabled_11rxn_33", B = "_field_11rxn_37", D = "_error_11rxn_51", G = "_touched_11rxn_51", H = "_input_11rxn_65", J = "_placeholder_11rxn_88", K = "_icon_11rxn_1", L = "_text_11rxn_151", M = {
|
|
6
|
-
"icon-container": "_icon-container_11rxn_1",
|
|
7
|
-
"icon-container-end": "_icon-container-end_11rxn_1",
|
|
8
|
-
"icon-container-start": "_icon-container-start_11rxn_1",
|
|
9
|
-
label: E,
|
|
10
|
-
asterisk: z,
|
|
11
|
-
disabled: A,
|
|
12
|
-
field: B,
|
|
13
|
-
error: D,
|
|
14
|
-
touched: G,
|
|
15
|
-
"default-width": "_default-width_11rxn_61",
|
|
16
|
-
"input-container": "_input-container_11rxn_65",
|
|
17
|
-
input: H,
|
|
18
|
-
placeholder: J,
|
|
19
|
-
icon: K,
|
|
20
|
-
"clear-icon": "_clear-icon_11rxn_108",
|
|
21
|
-
"additional-content": "_additional-content_11rxn_144",
|
|
22
|
-
text: L,
|
|
23
|
-
"error-text": "_error-text_11rxn_159",
|
|
24
|
-
"help-text": "_help-text_11rxn_163"
|
|
25
|
-
}, n = v.bind(M), T = S(
|
|
26
|
-
({
|
|
27
|
-
value: s,
|
|
28
|
-
className: f,
|
|
29
|
-
error: c,
|
|
30
|
-
placeholder: l,
|
|
31
|
-
disabled: a = !1,
|
|
32
|
-
onChange: N,
|
|
33
|
-
touched: r = !1,
|
|
34
|
-
title: u,
|
|
35
|
-
label: i,
|
|
36
|
-
helpText: o,
|
|
37
|
-
defaultWidth: k = !0,
|
|
38
|
-
startIcon: _,
|
|
39
|
-
endIcon: d,
|
|
40
|
-
clearable: b = !1,
|
|
41
|
-
onClear: x,
|
|
42
|
-
isRequired: p = !1,
|
|
43
|
-
hasDoubleMessage: w = !1,
|
|
44
|
-
type: F = "text",
|
|
45
|
-
...g
|
|
46
|
-
}, j) => {
|
|
47
|
-
const y = () => {
|
|
48
|
-
x && x(s);
|
|
49
|
-
}, m = /* @__PURE__ */ e("span", { className: n("text", "help-text"), children: o });
|
|
50
|
-
return /* @__PURE__ */ t(h, { children: [
|
|
51
|
-
i && /* @__PURE__ */ t("span", { className: n("label", { disabled: a }), children: [
|
|
52
|
-
i,
|
|
53
|
-
p && /* @__PURE__ */ e("span", { className: n("asterisk"), children: "*" })
|
|
54
|
-
] }),
|
|
55
|
-
/* @__PURE__ */ t(
|
|
56
|
-
"div",
|
|
57
|
-
{
|
|
58
|
-
className: n("field", f, {
|
|
59
|
-
error: c,
|
|
60
|
-
touched: r,
|
|
61
|
-
disabled: a,
|
|
62
|
-
"default-width": k
|
|
63
|
-
}),
|
|
64
|
-
title: u,
|
|
65
|
-
children: [
|
|
66
|
-
_ && /* @__PURE__ */ e("span", { className: n("icon-container-start"), children: /* @__PURE__ */ e("span", { className: n("icon"), children: _ }) }),
|
|
67
|
-
/* @__PURE__ */ t("span", { className: n("input-container"), children: [
|
|
68
|
-
/* @__PURE__ */ e(
|
|
69
|
-
"input",
|
|
70
|
-
{
|
|
71
|
-
ref: j,
|
|
72
|
-
type: F,
|
|
73
|
-
className: n("input"),
|
|
74
|
-
value: s,
|
|
75
|
-
disabled: a,
|
|
76
|
-
onChange: N,
|
|
77
|
-
...g
|
|
78
|
-
}
|
|
79
|
-
),
|
|
80
|
-
l && !s && /* @__PURE__ */ t("span", { className: n("placeholder"), children: [
|
|
81
|
-
l,
|
|
82
|
-
p && !i && /* @__PURE__ */ e("span", { className: n("asterisk") })
|
|
83
|
-
] })
|
|
84
|
-
] }),
|
|
85
|
-
d && /* @__PURE__ */ e("span", { className: n("icon-container-end"), children: /* @__PURE__ */ e("span", { className: n("icon"), children: d }) }),
|
|
86
|
-
b && /* @__PURE__ */ e("span", { className: n("icon-container-end"), children: /* @__PURE__ */ e("button", { type: "button", className: n("clear-icon", { disabled: a }), onClick: y, children: /* @__PURE__ */ e(C, {}) }) })
|
|
87
|
-
]
|
|
88
|
-
}
|
|
89
|
-
),
|
|
90
|
-
(c && r || o) && /* @__PURE__ */ e("div", { className: n("additional-content", { disabled: a }), children: c && r ? /* @__PURE__ */ t(h, { children: [
|
|
91
|
-
/* @__PURE__ */ e("span", { className: n("text", "error-text"), children: c }),
|
|
92
|
-
w && m
|
|
93
|
-
] }) : o && m })
|
|
94
|
-
] });
|
|
95
|
-
}
|
|
96
|
-
);
|
|
97
|
-
export {
|
|
98
|
-
T as F
|
|
99
|
-
};
|
package/dist/icon-71262f5c.js
DELETED
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { jsx as n } from "react/jsx-runtime";
|
|
2
|
-
import { c as i } from "./bind-06a7ff84.js";
|
|
3
|
-
import { S as c } from "./clear-4963efcd.js";
|
|
4
|
-
import * as l from "react";
|
|
5
|
-
const L = (e) => /* @__PURE__ */ l.createElement("svg", { width: 16, height: 16, viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e }, /* @__PURE__ */ l.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M0.732179 15.2698C0.330639 14.8683 0.33064 14.2172 0.73218 13.8157L6.54858 7.99928L0.73218 2.18288C0.33064 1.78134 0.330639 1.13031 0.732179 0.728774C1.13372 0.327235 1.78474 0.327235 2.18628 0.728774L8.00269 6.54518L13.8191 0.728767C14.2206 0.327229 14.8717 0.327228 15.2732 0.728767C15.6747 1.13031 15.6747 1.78133 15.2732 2.18287L9.45679 7.99928L15.2732 13.8157C15.6747 14.2172 15.6747 14.8683 15.2732 15.2698C14.8717 15.6713 14.2206 15.6713 13.8191 15.2698L8.00269 9.45338L2.18628 15.2698C1.78474 15.6713 1.13372 15.6713 0.732179 15.2698Z", fill: "#A2AAB5" })), d = (e) => /* @__PURE__ */ l.createElement("svg", { width: 16, height: 16, viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e }, /* @__PURE__ */ l.createElement("path", { d: "M14.2174 5.82426C14.3736 5.66805 14.3736 5.41479 14.2174 5.25858L14.0759 5.11716C13.9197 4.96095 13.6665 4.96095 13.5103 5.11716L8.16726 10.4602L2.82426 5.11716C2.66805 4.96095 2.41479 4.96095 2.25858 5.11716L2.11716 5.25858C1.96095 5.41479 1.96095 5.66805 2.11716 5.82426L7.89176 11.5989C8.04797 11.7551 8.30124 11.7551 8.45745 11.5989L8.88171 11.1746L8.87436 11.1673L14.2174 5.82426Z", fill: "#A2AAB5" })), a = (e) => /* @__PURE__ */ l.createElement("svg", { width: 16, height: 16, viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...e }, /* @__PURE__ */ l.createElement("path", { d: "M9.80051 6.3661C9.95672 6.20989 10.21 6.20989 10.3662 6.3661L10.6338 6.63375C10.7901 6.78996 10.7901 7.04323 10.6338 7.19944L8.83331 8.99996L10.6338 10.8005C10.79 10.9567 10.79 11.2099 10.6338 11.3662L10.3662 11.6338C10.21 11.79 9.95669 11.79 9.80048 11.6338L7.99998 9.8333L6.19953 11.6338C6.04332 11.79 5.79005 11.79 5.63384 11.6338L5.36619 11.3661C5.20998 11.2099 5.20998 10.9566 5.36619 10.8004L7.16665 8.99996L5.36617 7.19949C5.20996 7.04328 5.20996 6.79001 5.36617 6.6338L5.63382 6.36615C5.79003 6.20994 6.04329 6.20994 6.1995 6.36615L7.99998 8.16663L9.80051 6.3661Z", fill: "#A2AAB5" }), /* @__PURE__ */ l.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M4.99878 3V2C4.99878 1.44772 5.44649 1 5.99878 1H9.99878C10.5511 1 10.9988 1.44772 10.9988 2V3H14.5C14.7761 3 15 3.22386 15 3.5C15 3.77614 14.7761 4 14.5 4H13.4167L12.6146 13.6246C12.5498 14.402 11.8999 15 11.1198 15H4.8802C4.10007 15 3.45017 14.402 3.38538 13.6246L2.58333 4H1.5C1.22386 4 1 3.77614 1 3.5C1 3.22386 1.22386 3 1.5 3H4.99878ZM5.99878 2H9.99878V3H5.99878V2ZM3.5868 4L4.38193 13.5415C4.40352 13.8007 4.62016 14 4.8802 14H11.1198C11.3798 14 11.5965 13.8007 11.6181 13.5415L12.4132 4H3.5868Z", fill: "#A2AAB5" })), r = (e) => /* @__PURE__ */ l.createElement("svg", { width: 16, height: 16, viewBox: "0 0 16 16", fill: "#C1C7D0", xmlns: "http://www.w3.org/2000/svg", ...e }, /* @__PURE__ */ l.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M8.00117 2.62046C7.63142 2.6189 7.33294 2.91738 7.3345 3.28712L7.35159 7.35159L3.28712 7.3345C2.91738 7.33295 2.6189 7.63142 2.62045 8.00117C2.62201 8.37091 2.92301 8.67191 3.29275 8.67346L7.35722 8.69056L7.37391 12.6599C7.37547 13.0296 7.67647 13.3306 8.04621 13.3322C8.41596 13.3337 8.71443 13.0352 8.71288 12.6655L8.69619 8.69619L12.6655 8.71288C13.0352 8.71444 13.3337 8.41596 13.3322 8.04621C13.3306 7.67647 13.0296 7.37547 12.6599 7.37392L8.69056 7.35722L8.67346 3.29275C8.67191 2.92301 8.37091 2.62201 8.00117 2.62046Z" })), w = (e) => /* @__PURE__ */ l.createElement("svg", { width: 16, height: 16, viewBox: "0 0 16 16", fill: "#C1C7D0", xmlns: "http://www.w3.org/2000/svg", ...e }, /* @__PURE__ */ l.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M3.31082 7.31081C2.94108 7.30926 2.6426 7.60773 2.64415 7.97748C2.64571 8.34722 2.9467 8.64822 3.31645 8.64977L12.6892 8.68919C13.0589 8.69074 13.3574 8.39227 13.3559 8.02252C13.3543 7.65278 13.0533 7.35178 12.6836 7.35023L3.31082 7.31081Z" })), v = {
|
|
6
|
-
clear: c,
|
|
7
|
-
close: L,
|
|
8
|
-
dropdown: d,
|
|
9
|
-
delete: a,
|
|
10
|
-
plus: r,
|
|
11
|
-
minus: w
|
|
12
|
-
}, g = "_icon_pgc7q_1", h = "_disabled_pgc7q_4", m = {
|
|
13
|
-
icon: g,
|
|
14
|
-
disabled: h
|
|
15
|
-
}, p = i.bind(m), A = ({
|
|
16
|
-
icon: e,
|
|
17
|
-
className: o,
|
|
18
|
-
disabled: t = !1,
|
|
19
|
-
onClick: s
|
|
20
|
-
}) => {
|
|
21
|
-
const C = v[e];
|
|
22
|
-
return /* @__PURE__ */ n("span", { className: p("icon", o, { disabled: t }), onClick: t ? void 0 : s, children: /* @__PURE__ */ n(C, {}) });
|
|
23
|
-
};
|
|
24
|
-
export {
|
|
25
|
-
A as I
|
|
26
|
-
};
|
package/dist/icon.js
DELETED
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { jsxs as t, jsx as s } from "react/jsx-runtime";
|
|
2
|
-
import { c as _ } from "./bind-06a7ff84.js";
|
|
3
|
-
const c = "_children_19dbq_54", m = {
|
|
4
|
-
"system-message": "_system-message_19dbq_1",
|
|
5
|
-
"stripes-info": "_stripes-info_19dbq_12",
|
|
6
|
-
"stripes-warning": "_stripes-warning_19dbq_17",
|
|
7
|
-
"stripes-error": "_stripes-error_19dbq_22",
|
|
8
|
-
"text-container": "_text-container_19dbq_27",
|
|
9
|
-
"message-header-info": "_message-header-info_19dbq_30",
|
|
10
|
-
"message-header-warning": "_message-header-warning_19dbq_38",
|
|
11
|
-
"message-header-error": "_message-header-error_19dbq_46",
|
|
12
|
-
children: c,
|
|
13
|
-
"content-width": "_content-width_19dbq_70"
|
|
14
|
-
}, e = _.bind(m), l = ({
|
|
15
|
-
header: r,
|
|
16
|
-
caption: a,
|
|
17
|
-
children: i,
|
|
18
|
-
mode: n = "info",
|
|
19
|
-
widthByContent: d = !1
|
|
20
|
-
}) => /* @__PURE__ */ t("div", { className: e("system-message", { "content-width": d }), children: [
|
|
21
|
-
/* @__PURE__ */ s("div", { className: e(`stripes-${n}`) }),
|
|
22
|
-
/* @__PURE__ */ t("div", { className: e("text-container"), children: [
|
|
23
|
-
r && /* @__PURE__ */ s("h1", { className: e(`message-header-${n}`), children: r }),
|
|
24
|
-
/* @__PURE__ */ s("div", { className: e("children"), children: i }),
|
|
25
|
-
a && /* @__PURE__ */ s("p", { children: a })
|
|
26
|
-
] })
|
|
27
|
-
] });
|
|
28
|
-
export {
|
|
29
|
-
l as S
|
|
30
|
-
};
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { jsx as h } from "react/jsx-runtime";
|
|
2
|
-
const e = {
|
|
3
|
-
light: "rp-ui-kit-theme-light",
|
|
4
|
-
dark: "rp-ui-kit-theme-dark"
|
|
5
|
-
};
|
|
6
|
-
function o({
|
|
7
|
-
children: t,
|
|
8
|
-
theme: i = "light",
|
|
9
|
-
customThemes: r = {}
|
|
10
|
-
}) {
|
|
11
|
-
const s = {
|
|
12
|
-
...e,
|
|
13
|
-
...r
|
|
14
|
-
}[i] || e.light;
|
|
15
|
-
return /* @__PURE__ */ h("div", { className: s, children: t });
|
|
16
|
-
}
|
|
17
|
-
export {
|
|
18
|
-
o as T
|
|
19
|
-
};
|
package/dist/toggle-5b3d8333.js
DELETED
|
@@ -1,67 +0,0 @@
|
|
|
1
|
-
import { jsxs as f, jsx as t } from "react/jsx-runtime";
|
|
2
|
-
import { c as b } from "./bind-06a7ff84.js";
|
|
3
|
-
import { useRef as k } from "react";
|
|
4
|
-
import { K as d } from "./keyCodes-f63c0e11.js";
|
|
5
|
-
const h = "_toggle_19mjs_1", j = "_slider_19mjs_26", x = "_round_19mjs_46", y = "_input_19mjs_50", E = "_disabled_19mjs_63", D = {
|
|
6
|
-
toggle: h,
|
|
7
|
-
"children-container": "_children-container_19mjs_13",
|
|
8
|
-
slider: j,
|
|
9
|
-
round: x,
|
|
10
|
-
input: y,
|
|
11
|
-
disabled: E
|
|
12
|
-
}, e = b.bind(D), T = ({
|
|
13
|
-
children: r,
|
|
14
|
-
value: c,
|
|
15
|
-
onChange: _,
|
|
16
|
-
className: m,
|
|
17
|
-
disabled: s = !1,
|
|
18
|
-
title: u,
|
|
19
|
-
...p
|
|
20
|
-
}) => {
|
|
21
|
-
const n = k(null), g = (o) => {
|
|
22
|
-
var i, a;
|
|
23
|
-
const { keyCode: l } = o;
|
|
24
|
-
if (l === d.SPACE_KEY_CODE) {
|
|
25
|
-
o.preventDefault(), (i = n.current) == null || i.click();
|
|
26
|
-
return;
|
|
27
|
-
}
|
|
28
|
-
l === d.ENTER_KEY_CODE && (o.preventDefault(), (a = n.current) == null || a.click());
|
|
29
|
-
};
|
|
30
|
-
return /* @__PURE__ */ f(
|
|
31
|
-
"label",
|
|
32
|
-
{
|
|
33
|
-
id: "rp-ui-kit-toggle-label",
|
|
34
|
-
title: u,
|
|
35
|
-
className: e("toggle", m, { disabled: s }),
|
|
36
|
-
children: [
|
|
37
|
-
/* @__PURE__ */ t(
|
|
38
|
-
"input",
|
|
39
|
-
{
|
|
40
|
-
ref: n,
|
|
41
|
-
tabIndex: s ? -1 : 0,
|
|
42
|
-
onChange: _,
|
|
43
|
-
checked: c,
|
|
44
|
-
disabled: s,
|
|
45
|
-
onKeyDown: g,
|
|
46
|
-
className: e("input"),
|
|
47
|
-
type: "checkbox",
|
|
48
|
-
...p
|
|
49
|
-
}
|
|
50
|
-
),
|
|
51
|
-
/* @__PURE__ */ t(
|
|
52
|
-
"div",
|
|
53
|
-
{
|
|
54
|
-
"aria-labelledby": "rp-ui-kit-toggle-label",
|
|
55
|
-
role: "checkbox",
|
|
56
|
-
"aria-checked": c,
|
|
57
|
-
className: e("slider", "round")
|
|
58
|
-
}
|
|
59
|
-
),
|
|
60
|
-
r && /* @__PURE__ */ t("span", { className: e("children-container"), children: r })
|
|
61
|
-
]
|
|
62
|
-
}
|
|
63
|
-
);
|
|
64
|
-
};
|
|
65
|
-
export {
|
|
66
|
-
T
|
|
67
|
-
};
|