@reportportal/ui-kit 0.0.1-alpha.6 → 0.0.1-alpha.61
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 +255 -3
- package/dist/arrowUp-4a5caee7.js +6 -0
- package/dist/baseIconButton-251479f7.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-33c88abf.js +62 -0
- package/dist/button.js +1 -1
- package/dist/calendarArrow-3e1339ea.js +6 -0
- package/dist/checkbox-9a6c7ce1.js +73 -0
- package/dist/checkbox.js +1 -1
- package/dist/close-4b33d7c1.js +5 -0
- package/dist/common/hooks/useOnClickOutside.d.ts +1 -0
- package/dist/common/types.d.ts +3 -0
- package/dist/components/baseIconButton/baseIconButton.d.ts +9 -0
- package/dist/components/baseIconButton/index.d.ts +5 -0
- package/dist/components/bubblesLoader/bubblesLoader.d.ts +1 -0
- package/dist/components/bubblesLoader/index.d.ts +1 -0
- package/dist/components/button/button.d.ts +1 -1
- package/dist/components/button/index.d.ts +3 -2
- package/dist/components/checkbox/checkbox.d.ts +3 -0
- package/dist/components/checkbox/index.d.ts +1 -0
- package/dist/components/datePicker/datePicker.d.ts +25 -0
- package/dist/components/datePicker/header/datePickerHeader.d.ts +16 -0
- package/dist/components/datePicker/header/index.d.ts +4 -0
- package/dist/components/datePicker/index.d.ts +5 -0
- package/dist/components/datePicker/utils.d.ts +4 -0
- package/dist/components/dropdown/constants.d.ts +5 -0
- package/dist/components/dropdown/dropdown.d.ts +13 -5
- package/dist/components/dropdown/dropdownOption/dropdownOption.d.ts +1 -0
- package/dist/components/dropdown/dropdownOption/index.d.ts +1 -0
- package/dist/components/dropdown/index.d.ts +1 -0
- package/dist/components/dropdown/types.d.ts +3 -0
- package/dist/components/dropdown/utils.d.ts +2 -1
- package/dist/components/fieldLabel/fieldLabel.d.ts +7 -0
- package/dist/components/fieldLabel/index.d.ts +1 -0
- package/dist/components/fieldNumber/constants.d.ts +1 -0
- package/dist/components/fieldNumber/fieldNumber.d.ts +2 -1
- package/dist/components/fieldNumber/index.d.ts +1 -0
- package/dist/components/fieldText/fieldText.d.ts +13 -5
- package/dist/components/fieldText/index.d.ts +1 -0
- package/dist/components/fieldText/types.d.ts +5 -0
- package/dist/components/fieldTextFlex/fieldTextFlex.d.ts +16 -0
- package/dist/components/fieldTextFlex/index.d.ts +4 -0
- package/dist/components/icons/index.d.ts +37 -0
- package/dist/components/index.d.ts +11 -1
- package/dist/components/maxValueDisplay/index.d.ts +4 -0
- package/dist/components/maxValueDisplay/maxValueDisplay.d.ts +8 -0
- package/dist/components/maxValueDisplay/utils/index.d.ts +1 -0
- package/dist/components/maxValueDisplay/utils/isPositiveInteger.d.ts +1 -0
- package/dist/components/modal/modal.d.ts +7 -2
- package/dist/components/modal/modalContent/modalContent.d.ts +2 -0
- package/dist/components/modal/modalFooter/modalFooter.d.ts +1 -0
- package/dist/components/modal/modalHeader/modalHeader.d.ts +2 -1
- package/dist/components/pagination/index.d.ts +5 -0
- package/dist/components/pagination/itemsCounter/index.d.ts +1 -0
- package/dist/components/pagination/itemsCounter/itemCounter.d.ts +10 -0
- package/dist/components/pagination/pageControls/activePage/activePage.d.ts +13 -0
- package/dist/components/pagination/pageControls/activePage/index.d.ts +1 -0
- package/dist/components/pagination/pageControls/activePage/pageSelector/index.d.ts +1 -0
- package/dist/components/pagination/pageControls/activePage/pageSelector/pageSelector.d.ts +11 -0
- package/dist/components/pagination/pageControls/index.d.ts +1 -0
- package/dist/components/pagination/pageControls/pageControls.d.ts +17 -0
- package/dist/components/pagination/pageControls/pageNavigator/bar/bar.d.ts +12 -0
- package/dist/components/pagination/pageControls/pageNavigator/bar/index.d.ts +1 -0
- package/dist/components/pagination/pageControls/pageNavigator/index.d.ts +1 -0
- package/dist/components/pagination/pageControls/pageNavigator/pageNavigator.d.ts +12 -0
- package/dist/components/pagination/pageSizeControl/index.d.ts +1 -0
- package/dist/components/pagination/pageSizeControl/pageSizeControl.d.ts +11 -0
- package/dist/components/pagination/pageSizeControl/sizeSelector/index.d.ts +1 -0
- package/dist/components/pagination/pageSizeControl/sizeSelector/sizeSelector.d.ts +9 -0
- package/dist/components/pagination/pagination.d.ts +23 -0
- package/dist/components/pagination/types.d.ts +2 -0
- package/dist/components/popover/index.d.ts +1 -0
- package/dist/components/popover/popover.d.ts +19 -0
- package/dist/components/radio/index.d.ts +5 -0
- package/dist/components/radio/radio.d.ts +17 -0
- package/dist/components/radio/radioGroup.d.ts +9 -0
- package/dist/components/spinLoader/index.d.ts +4 -0
- package/dist/components/spinLoader/spinLoader.d.ts +8 -0
- package/dist/components/systemAlert/index.d.ts +1 -0
- package/dist/components/systemAlert/systemAlert.d.ts +4 -0
- package/dist/components/systemAlert/types.d.ts +16 -0
- package/dist/components/systemMessage/index.d.ts +1 -0
- package/dist/components/systemMessage/systemMessage.d.ts +1 -0
- package/dist/components/table/index.d.ts +4 -0
- package/dist/components/table/table.d.ts +4 -0
- package/dist/components/table/types.d.ts +54 -0
- package/dist/components/table/utils.d.ts +4 -0
- package/dist/components/themeProvider/index.d.ts +1 -0
- package/dist/components/themeProvider/themeProvider.d.ts +3 -1
- package/dist/components/toggle/index.d.ts +1 -0
- package/dist/components/toggle/toggle.d.ts +1 -0
- package/dist/components/tooltip/index.d.ts +1 -0
- package/dist/components/tooltip/tooltip.d.ts +23 -0
- package/dist/datePicker-a2b6acf5.js +201 -0
- package/dist/datePicker.js +28 -0
- package/dist/dropdown-0260bb66.js +5 -0
- package/dist/dropdown-29285346.js +278 -0
- package/dist/dropdown.js +6 -4
- package/dist/fieldLabel.js +13 -0
- package/dist/fieldNumber-d81e551e.js +125 -0
- package/dist/fieldNumber.js +3 -3
- package/dist/fieldText-1ab17a11.js +158 -0
- package/dist/fieldText.js +6 -2
- package/dist/fieldTextFlex-314741ad.js +78 -0
- package/dist/fieldTextFlex.js +9 -0
- package/dist/icons.js +49 -0
- package/dist/index.js +92 -23
- package/dist/maxValueDisplay-9be01a75.js +13 -0
- package/dist/maxValueDisplay.js +6 -0
- package/dist/modal.js +114 -96
- package/dist/openEye-7b9cf080.js +7 -0
- package/dist/pagination-7c6ebae2.js +345 -0
- package/dist/pagination.js +20 -0
- package/dist/plus-0929dda4.js +6 -0
- package/dist/popover.js +95 -0
- package/dist/prevPage-87faf576.js +6 -0
- package/dist/radio-bccc84f2.js +76 -0
- package/dist/{icon.js → radio.js} +4 -4
- package/dist/spinLoader-c4a53718.js +11 -0
- package/dist/spinLoader.js +7 -0
- package/dist/style.css +1 -1
- package/dist/success-dc1914aa.js +7 -0
- package/dist/systemAlert.js +63 -0
- package/dist/systemMessage-1ced6079.js +30 -0
- package/dist/systemMessage.js +1 -1
- package/dist/table-32fc8c70.js +144 -0
- package/dist/table.js +11 -0
- package/dist/themeProvider-46c2be7b.js +23 -0
- package/dist/themeProvider.js +4 -3
- package/dist/toggle-1a3aacb5.js +59 -0
- package/dist/toggle.js +1 -1
- package/dist/tooltip.js +101 -0
- package/package.json +53 -17
- package/dist/bubblesLoader-9bec3797.js +0 -17
- package/dist/button-d4944dbc.js +0 -64
- package/dist/checkbox-fdc44740.js +0 -68
- 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/systemMessage-62c3133d.js +0 -30
- package/dist/themeProvider-5800417e.js +0 -19
- package/dist/toggle-5b3d8333.js +0 -67
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { jsxs as r } from "react/jsx-runtime";
|
|
2
|
+
const t = (s) => typeof s == "number" && Number.isFinite(s) && Number.isInteger(s) && s > 0, p = ({
|
|
3
|
+
className: s,
|
|
4
|
+
value: e,
|
|
5
|
+
maxValue: n
|
|
6
|
+
}) => t(n) ? /* @__PURE__ */ r("span", { className: s, children: [
|
|
7
|
+
e,
|
|
8
|
+
"/",
|
|
9
|
+
n
|
|
10
|
+
] }) : null;
|
|
11
|
+
export {
|
|
12
|
+
p as M
|
|
13
|
+
};
|
package/dist/modal.js
CHANGED
|
@@ -1,128 +1,146 @@
|
|
|
1
|
-
import { jsx as e, jsxs as
|
|
2
|
-
import { useState as
|
|
3
|
-
import { Scrollbars as
|
|
4
|
-
import { AnimatePresence as
|
|
5
|
-
import { c as
|
|
6
|
-
import { u as
|
|
7
|
-
import { K as
|
|
8
|
-
import { B as
|
|
9
|
-
import {
|
|
10
|
-
import "./
|
|
11
|
-
const
|
|
12
|
-
const [
|
|
13
|
-
return
|
|
14
|
-
const
|
|
15
|
-
|
|
1
|
+
import { jsx as e, jsxs as c, Fragment as G } from "react/jsx-runtime";
|
|
2
|
+
import { useState as u, useEffect as g, useRef as K } from "react";
|
|
3
|
+
import { Scrollbars as P } from "rc-scrollbars";
|
|
4
|
+
import { AnimatePresence as B, motion as q } from "framer-motion";
|
|
5
|
+
import { c as f } from "./bind-06a7ff84.js";
|
|
6
|
+
import { u as Y } from "./useOnClickOutside-c332f7d3.js";
|
|
7
|
+
import { K as U } from "./keyCodes-f63c0e11.js";
|
|
8
|
+
import { B as N } from "./button-33c88abf.js";
|
|
9
|
+
import { B as X } from "./baseIconButton-251479f7.js";
|
|
10
|
+
import { S as J } from "./close-4b33d7c1.js";
|
|
11
|
+
const Q = () => {
|
|
12
|
+
const [o, n] = u({ width: 0, height: 0 });
|
|
13
|
+
return g(() => {
|
|
14
|
+
const l = () => {
|
|
15
|
+
n({
|
|
16
16
|
width: window.innerWidth,
|
|
17
17
|
height: window.innerHeight
|
|
18
18
|
});
|
|
19
19
|
};
|
|
20
|
-
return window.addEventListener("resize",
|
|
21
|
-
}, []),
|
|
22
|
-
},
|
|
23
|
-
"modal-content": "_modal-
|
|
24
|
-
|
|
20
|
+
return window.addEventListener("resize", l), l(), () => window.removeEventListener("resize", l);
|
|
21
|
+
}, []), o;
|
|
22
|
+
}, V = "_scrollable_qziry_12", Z = {
|
|
23
|
+
"modal-content": "_modal-content_qziry_1",
|
|
24
|
+
scrollable: V
|
|
25
|
+
}, ee = f.bind(Z), O = ({ scrollable: o = !1, children: n }) => /* @__PURE__ */ e("div", { className: ee("modal-content", { scrollable: o }), children: n }), te = {
|
|
25
26
|
"buttons-block": "_buttons-block_1dgm4_1",
|
|
26
27
|
"button-container": "_button-container_1dgm4_5",
|
|
27
28
|
"modal-footer": "_modal-footer_1dgm4_14",
|
|
28
29
|
"with-extra-node": "_with-extra-node_1dgm4_21",
|
|
29
30
|
"size-small": "_size-small_1dgm4_25"
|
|
30
|
-
},
|
|
31
|
-
footerNode:
|
|
32
|
-
closeHandler:
|
|
33
|
-
okButton:
|
|
34
|
-
cancelButton:
|
|
35
|
-
size:
|
|
36
|
-
}) => /* @__PURE__ */
|
|
37
|
-
|
|
38
|
-
/* @__PURE__ */
|
|
39
|
-
|
|
40
|
-
|
|
31
|
+
}, m = f.bind(te), oe = ({
|
|
32
|
+
footerNode: o,
|
|
33
|
+
closeHandler: n,
|
|
34
|
+
okButton: l,
|
|
35
|
+
cancelButton: r,
|
|
36
|
+
size: s
|
|
37
|
+
}) => /* @__PURE__ */ c("div", { className: m("modal-footer", { "with-extra-node": o, [`size-${s}`]: s }), children: [
|
|
38
|
+
o && o,
|
|
39
|
+
/* @__PURE__ */ c("div", { className: m("buttons-block"), children: [
|
|
40
|
+
r && /* @__PURE__ */ e("div", { className: m("button-container"), children: /* @__PURE__ */ e(
|
|
41
|
+
N,
|
|
41
42
|
{
|
|
42
43
|
variant: "ghost",
|
|
43
|
-
adjustWidthOn:
|
|
44
|
-
onClick:
|
|
45
|
-
...
|
|
44
|
+
adjustWidthOn: s === "small" ? "parent" : "content",
|
|
45
|
+
onClick: n,
|
|
46
|
+
...r
|
|
46
47
|
}
|
|
47
48
|
) }),
|
|
48
|
-
|
|
49
|
+
l && /* @__PURE__ */ e("div", { className: m("button-container"), children: /* @__PURE__ */ e(N, { adjustWidthOn: s === "small" ? "parent" : "content", ...l }) })
|
|
49
50
|
] })
|
|
50
|
-
] }),
|
|
51
|
-
"modal-header": "_modal-
|
|
52
|
-
"
|
|
53
|
-
"modal-
|
|
54
|
-
"
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
"
|
|
64
|
-
"
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
"size-default": "_size-
|
|
68
|
-
"size-small": "_size-
|
|
69
|
-
"size-large": "_size-
|
|
70
|
-
},
|
|
71
|
-
title:
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
onClose: z = () => {
|
|
51
|
+
] }), ne = {
|
|
52
|
+
"modal-header": "_modal-header_68lru_1",
|
|
53
|
+
"width-description": "_width-description_68lru_10",
|
|
54
|
+
"modal-header-content": "_modal-header-content_68lru_14",
|
|
55
|
+
"modal-title": "_modal-title_68lru_20",
|
|
56
|
+
"close-modal-icon": "_close-modal-icon_68lru_29"
|
|
57
|
+
}, _ = f.bind(ne), le = ({ title: o, onClose: n, withDescription: l = !1 }) => /* @__PURE__ */ c("div", { className: _("modal-header", { "width-description": l }), children: [
|
|
58
|
+
/* @__PURE__ */ e("div", { className: _("modal-header-content"), children: o && /* @__PURE__ */ e("div", { className: _("modal-title"), children: o }) }),
|
|
59
|
+
/* @__PURE__ */ e(X, { className: _("close-modal-icon"), onClick: n, children: /* @__PURE__ */ e(J, {}) })
|
|
60
|
+
] }), se = "_modal_f3ckb_1", ae = "_description_f3ckb_43", ie = "_scrollable_f3ckb_53", ce = {
|
|
61
|
+
modal: se,
|
|
62
|
+
"overlay-default": "_overlay-default_f3ckb_12",
|
|
63
|
+
"overlay-light-cyan": "_overlay-light-cyan_f3ckb_16",
|
|
64
|
+
"scrolling-content": "_scrolling-content_f3ckb_20",
|
|
65
|
+
"modal-window": "_modal-window_f3ckb_26",
|
|
66
|
+
description: ae,
|
|
67
|
+
scrollable: ie,
|
|
68
|
+
"size-default": "_size-default_f3ckb_57",
|
|
69
|
+
"size-small": "_size-small_f3ckb_69",
|
|
70
|
+
"size-large": "_size-large_f3ckb_81"
|
|
71
|
+
}, h = f.bind(ce), de = 0.9, re = 32 + 24, me = 32 + 8, _e = 36 + 16, he = 32 * 2, Ee = ({
|
|
72
|
+
title: o,
|
|
73
|
+
children: n,
|
|
74
|
+
footerNode: l,
|
|
75
|
+
okButton: r,
|
|
76
|
+
cancelButton: s,
|
|
77
|
+
className: z,
|
|
78
|
+
size: w = "default",
|
|
79
|
+
onClose: A = () => {
|
|
80
80
|
},
|
|
81
|
-
overlay:
|
|
82
|
-
|
|
81
|
+
overlay: p = "default",
|
|
82
|
+
zIndex: C = 2,
|
|
83
|
+
allowCloseOutside: D = !0,
|
|
84
|
+
scrollable: v = !1,
|
|
85
|
+
withoutFooter: y = !1,
|
|
86
|
+
createFooter: H = null,
|
|
87
|
+
description: a = null
|
|
83
88
|
}) => {
|
|
84
|
-
const [
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
+
const [S, k] = u(!1), [T, I] = u(0), [L, $] = u(!1), i = K(null), E = Q(), x = E.height, R = x * de, b = (x - T) / 2, W = () => {
|
|
90
|
+
let t = R - he;
|
|
91
|
+
return y || (t = t - _e), a ? t = t - me : t = t - re, t;
|
|
92
|
+
}, d = () => {
|
|
93
|
+
k(!1);
|
|
94
|
+
}, M = (t) => {
|
|
95
|
+
const { keyCode: F } = t;
|
|
96
|
+
F === U.ESCAPE_KEY_CODE && d();
|
|
97
|
+
}, j = () => {
|
|
98
|
+
var t;
|
|
99
|
+
L || ((t = i.current) == null || t.focus(), $(!0));
|
|
89
100
|
};
|
|
90
|
-
return
|
|
91
|
-
if (
|
|
92
|
-
const { clientHeight:
|
|
93
|
-
|
|
101
|
+
return g(() => {
|
|
102
|
+
if (i && i.current) {
|
|
103
|
+
const { clientHeight: t } = i.current;
|
|
104
|
+
I(t);
|
|
94
105
|
}
|
|
95
|
-
}, [
|
|
96
|
-
|
|
106
|
+
}, [n, E]), g(() => (k(!0), document.addEventListener("keydown", M, !1), () => document.removeEventListener("keydown", M, !1)), []), Y(i, D ? d : void 0), /* @__PURE__ */ e(B, { onExitComplete: A, children: S && /* @__PURE__ */ e("div", { className: h("modal", { [`overlay-${p}`]: p }), style: { zIndex: C }, children: /* @__PURE__ */ c(
|
|
107
|
+
q.div,
|
|
97
108
|
{
|
|
98
|
-
className:
|
|
99
|
-
ref:
|
|
109
|
+
className: h("modal-window", { [`size-${w}`]: w }, z),
|
|
110
|
+
ref: i,
|
|
100
111
|
tabIndex: 0,
|
|
101
|
-
initial: { opacity: 0, marginTop: -
|
|
102
|
-
animate: { opacity: 1, marginTop:
|
|
103
|
-
exit: { opacity: 0, marginTop: -
|
|
112
|
+
initial: { opacity: 0, marginTop: -b },
|
|
113
|
+
animate: { opacity: 1, marginTop: b },
|
|
114
|
+
exit: { opacity: 0, marginTop: -b },
|
|
104
115
|
transition: { duration: 0.3 },
|
|
116
|
+
onAnimationStart: j,
|
|
105
117
|
children: [
|
|
106
|
-
/* @__PURE__ */ e(
|
|
107
|
-
/* @__PURE__ */
|
|
108
|
-
|
|
109
|
-
|
|
118
|
+
/* @__PURE__ */ e(le, { title: o, onClose: d, withDescription: !!a }),
|
|
119
|
+
v ? /* @__PURE__ */ c(P, { autoHeight: !0, autoHeightMax: W(), hideTracksWhenNotNeeded: !0, children: [
|
|
120
|
+
a && /* @__PURE__ */ e("span", { className: h("description", { scrollable: v }), children: a }),
|
|
121
|
+
/* @__PURE__ */ e(O, { scrollable: !0, children: n })
|
|
122
|
+
] }) : /* @__PURE__ */ c(G, { children: [
|
|
123
|
+
a && /* @__PURE__ */ e("span", { className: h("description"), children: a }),
|
|
124
|
+
/* @__PURE__ */ e(O, { children: n })
|
|
125
|
+
] }),
|
|
126
|
+
!y && (H ? H(d) : /* @__PURE__ */ e(
|
|
127
|
+
oe,
|
|
110
128
|
{
|
|
111
|
-
size:
|
|
112
|
-
footerNode:
|
|
113
|
-
okButton:
|
|
114
|
-
cancelButton:
|
|
129
|
+
size: w,
|
|
130
|
+
footerNode: l,
|
|
131
|
+
okButton: r,
|
|
132
|
+
cancelButton: s,
|
|
115
133
|
closeHandler: d
|
|
116
134
|
}
|
|
117
|
-
)
|
|
135
|
+
))
|
|
118
136
|
]
|
|
119
137
|
},
|
|
120
138
|
"modal-window"
|
|
121
139
|
) }) });
|
|
122
140
|
};
|
|
123
141
|
export {
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
142
|
+
Ee as Modal,
|
|
143
|
+
O as ModalContent,
|
|
144
|
+
oe as ModalFooter,
|
|
145
|
+
le as ModalHeader
|
|
128
146
|
};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import * as e from "react";
|
|
2
|
+
const l = (C) => /* @__PURE__ */ e.createElement("svg", { width: 16, height: 16, viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...C }, /* @__PURE__ */ e.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M1 8C1 4.14001 4.14001 1 8 1C11.86 1 15 4.14001 15 8C15 11.8595 11.86 15 8 15C4.14001 15 1 11.8595 1 8ZM5 5.54545L5.54545 5L8 7.45455L10.4545 5L11 5.54545L8.54545 8L11 10.4545L10.4545 11L8 8.54545L5.54545 11L5 10.4545L7.45455 8L5 5.54545Z", fill: "#A2AAB5" })), t = (C) => /* @__PURE__ */ e.createElement("svg", { width: 16, height: 16, viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...C }, /* @__PURE__ */ e.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M9.09194 3.90153C8.73249 3.84853 8.36745 3.82135 7.99778 3.82135C5.24735 3.82135 2.75312 5.32613 0.912626 7.77031C0.762442 7.97055 0.762442 8.25031 0.912626 8.45055C1.96494 9.84971 3.23098 10.9408 4.63642 11.6187L5.59679 9.95532C5.16732 9.39694 4.92809 8.68447 4.97644 7.91459C5.07067 6.40686 6.29276 5.18478 7.80049 5.09055C8.00285 5.07782 8.2013 5.08498 8.39407 5.11028L9.09194 3.90153ZM7.56961 6.5383C6.91222 6.71981 6.41543 7.30478 6.37225 8.00589C6.36032 8.18701 6.37814 8.36223 6.42131 8.5272L7.56961 6.5383ZM8.40613 9.68939L9.57119 7.67146C9.61868 7.84288 9.6387 8.02571 9.62624 8.21497C9.58001 8.92637 9.07238 9.51681 8.40613 9.68939ZM7.58518 11.1113C7.78307 11.1384 7.98701 11.1463 8.19509 11.1332C9.69987 11.0361 10.922 9.81398 11.0191 8.3092C11.0679 7.53332 10.8245 6.81576 10.3887 6.25546L11.3454 4.59845C12.7563 5.27587 14.0272 6.36953 15.0829 7.77325C15.2331 7.9735 15.2331 8.25325 15.0829 8.4535C13.2424 10.8977 10.7482 12.4025 7.99778 12.4025C7.62256 12.4025 7.25211 12.3744 6.88743 12.3199L7.58518 11.1113Z", fill: "#A2AAB5" }), /* @__PURE__ */ e.createElement("path", { d: "M10.5051 2.25952C10.7122 1.9008 11.1709 1.7779 11.5296 1.985C11.8883 2.19211 12.0112 2.6508 11.8041 3.00952L5.35413 14.1812C5.14702 14.54 4.68833 14.6629 4.32961 14.4558C3.97089 14.2487 3.84798 13.79 4.05509 13.4312L10.5051 2.25952Z", fill: "#A2AAB5" })), n = (C) => /* @__PURE__ */ e.createElement("svg", { width: 16, height: 16, viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...C }, /* @__PURE__ */ e.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M7.99778 3.82135C5.24735 3.82135 2.75312 5.32613 0.912626 7.77031C0.762442 7.97055 0.762442 8.25031 0.912626 8.45055C2.75312 10.8977 5.24735 12.4025 7.99778 12.4025C10.7482 12.4025 13.2424 10.8977 15.0829 8.4535C15.2331 8.25325 15.2331 7.9735 15.0829 7.77325C13.2424 5.32614 10.7482 3.82135 7.99778 3.82135ZM8.19509 11.1332C6.36932 11.2481 4.86159 9.74331 4.97644 7.91459C5.07067 6.40686 6.29276 5.18478 7.80049 5.09055C9.62625 4.9757 11.134 6.48048 11.0191 8.3092C10.922 9.81398 9.69987 11.0361 8.19509 11.1332ZM6.37225 8.00589C6.30746 8.98945 7.12022 9.79926 8.10378 9.73742C8.9136 9.68736 9.57323 9.03068 9.62624 8.21497C9.69102 7.23141 8.87826 6.4216 7.8947 6.48344C7.08194 6.53644 6.42231 7.19313 6.37225 8.00589Z", fill: "#A2AAB5" }));
|
|
3
|
+
export {
|
|
4
|
+
l as S,
|
|
5
|
+
t as a,
|
|
6
|
+
n as b
|
|
7
|
+
};
|
|
@@ -0,0 +1,345 @@
|
|
|
1
|
+
import { jsxs as p, jsx as t } from "react/jsx-runtime";
|
|
2
|
+
import { c as m } from "./bind-06a7ff84.js";
|
|
3
|
+
import { useState as h } from "react";
|
|
4
|
+
import { Popover as O } from "./popover.js";
|
|
5
|
+
import { B as x } from "./button-33c88abf.js";
|
|
6
|
+
import { F as A } from "./fieldText-1ab17a11.js";
|
|
7
|
+
import { B as f } from "./baseIconButton-251479f7.js";
|
|
8
|
+
import { S as y, a as T } from "./prevPage-87faf576.js";
|
|
9
|
+
import { Tooltip as B } from "./tooltip.js";
|
|
10
|
+
const P = {
|
|
11
|
+
"item-counter": "_item-counter_4g6do_1"
|
|
12
|
+
}, E = m.bind(P), M = ({
|
|
13
|
+
activePage: o,
|
|
14
|
+
pageSize: n,
|
|
15
|
+
totalItems: s,
|
|
16
|
+
ofText: r,
|
|
17
|
+
itemsText: a
|
|
18
|
+
}) => {
|
|
19
|
+
const c = o * n, i = c - n;
|
|
20
|
+
return /* @__PURE__ */ p("div", { className: E("item-counter"), children: [
|
|
21
|
+
`${i + 1} - ${c < s ? c : s}`,
|
|
22
|
+
` ${r} ${s} ${a}`
|
|
23
|
+
] });
|
|
24
|
+
}, V = "_selected_183l8_32", W = {
|
|
25
|
+
"size-selector": "_size-selector_183l8_1",
|
|
26
|
+
"size-option": "_size-option_183l8_6",
|
|
27
|
+
selected: V
|
|
28
|
+
}, C = m.bind(W), D = ({
|
|
29
|
+
currentSize: o,
|
|
30
|
+
options: n,
|
|
31
|
+
onClickOption: s
|
|
32
|
+
}) => /* @__PURE__ */ t("div", { className: C("size-selector"), children: n.map((r) => /* @__PURE__ */ t(
|
|
33
|
+
"button",
|
|
34
|
+
{
|
|
35
|
+
className: C("size-option", { selected: r === o }),
|
|
36
|
+
onClick: () => {
|
|
37
|
+
s(r);
|
|
38
|
+
},
|
|
39
|
+
children: r
|
|
40
|
+
},
|
|
41
|
+
r
|
|
42
|
+
)) }), F = {
|
|
43
|
+
"page-size-control": "_page-size-control_1y4na_1",
|
|
44
|
+
"size-selector-button": "_size-selector-button_1y4na_10"
|
|
45
|
+
}, w = m.bind(F), j = ({
|
|
46
|
+
size: o,
|
|
47
|
+
sizeOptions: n,
|
|
48
|
+
perPageText: s,
|
|
49
|
+
changeSize: r
|
|
50
|
+
}) => {
|
|
51
|
+
const [a, c] = h(!1), i = (e) => {
|
|
52
|
+
r(e), c(!1);
|
|
53
|
+
};
|
|
54
|
+
return /* @__PURE__ */ p("div", { className: w("page-size-control"), children: [
|
|
55
|
+
/* @__PURE__ */ t(
|
|
56
|
+
O,
|
|
57
|
+
{
|
|
58
|
+
content: /* @__PURE__ */ t(D, { options: n, onClickOption: i, currentSize: o }),
|
|
59
|
+
placement: "top",
|
|
60
|
+
isOpened: a,
|
|
61
|
+
setIsOpened: c,
|
|
62
|
+
children: /* @__PURE__ */ t(x, { className: w("size-selector-button"), variant: "text", children: o })
|
|
63
|
+
}
|
|
64
|
+
),
|
|
65
|
+
` ${s}`
|
|
66
|
+
] });
|
|
67
|
+
}, G = {
|
|
68
|
+
"page-selector": "_page-selector_rtho4_1",
|
|
69
|
+
"field-wrapper": "_field-wrapper_rtho4_6",
|
|
70
|
+
"apply-button": "_apply-button_rtho4_10"
|
|
71
|
+
}, b = m.bind(G), H = ({
|
|
72
|
+
totalPages: o,
|
|
73
|
+
pageText: n,
|
|
74
|
+
goActionText: s,
|
|
75
|
+
selectPage: r
|
|
76
|
+
}) => {
|
|
77
|
+
const [a, c] = h(""), [i, e] = h(!0), d = (u) => {
|
|
78
|
+
const v = u.target.value.replace(/\D/g, ""), $ = Number(v), k = $ > 0 && $ <= o;
|
|
79
|
+
e(k), c(v);
|
|
80
|
+
}, l = () => {
|
|
81
|
+
r(Number(a));
|
|
82
|
+
};
|
|
83
|
+
return /* @__PURE__ */ p("div", { className: b("page-selector"), children: [
|
|
84
|
+
/* @__PURE__ */ t("div", { className: b("field-wrapper"), children: /* @__PURE__ */ t(
|
|
85
|
+
A,
|
|
86
|
+
{
|
|
87
|
+
onChange: d,
|
|
88
|
+
value: a,
|
|
89
|
+
placeholder: n,
|
|
90
|
+
error: i ? "" : "Error",
|
|
91
|
+
touched: !0,
|
|
92
|
+
defaultWidth: !1,
|
|
93
|
+
displayError: !1
|
|
94
|
+
}
|
|
95
|
+
) }),
|
|
96
|
+
/* @__PURE__ */ t(x, { onClick: l, disabled: !a || !i, className: b("apply-button"), children: s })
|
|
97
|
+
] });
|
|
98
|
+
}, L = {
|
|
99
|
+
"active-page": "_active-page_rmw5h_1",
|
|
100
|
+
"page-selector": "_page-selector_rmw5h_10",
|
|
101
|
+
"page-selector-button": "_page-selector-button_rmw5h_14"
|
|
102
|
+
}, N = m.bind(L), R = ({
|
|
103
|
+
activePage: o,
|
|
104
|
+
totalPages: n,
|
|
105
|
+
pageText: s,
|
|
106
|
+
goToText: r,
|
|
107
|
+
goActionText: a,
|
|
108
|
+
changePage: c
|
|
109
|
+
}) => {
|
|
110
|
+
const [i, e] = h(!1), d = (l) => {
|
|
111
|
+
c(l), e(!1);
|
|
112
|
+
};
|
|
113
|
+
return /* @__PURE__ */ p("div", { className: N("active-page"), children: [
|
|
114
|
+
`${s} `,
|
|
115
|
+
/* @__PURE__ */ t(
|
|
116
|
+
O,
|
|
117
|
+
{
|
|
118
|
+
content: /* @__PURE__ */ t(
|
|
119
|
+
H,
|
|
120
|
+
{
|
|
121
|
+
pageText: s,
|
|
122
|
+
goActionText: a,
|
|
123
|
+
selectPage: d,
|
|
124
|
+
totalPages: n
|
|
125
|
+
}
|
|
126
|
+
),
|
|
127
|
+
title: r,
|
|
128
|
+
placement: "top",
|
|
129
|
+
isOpened: i,
|
|
130
|
+
setIsOpened: e,
|
|
131
|
+
className: N("page-selector"),
|
|
132
|
+
children: /* @__PURE__ */ t(x, { className: N("page-selector-button"), variant: "text", children: o })
|
|
133
|
+
}
|
|
134
|
+
)
|
|
135
|
+
] });
|
|
136
|
+
}, q = "_bar_dfnmf_1", J = "_section_dfnmf_9", K = "_selected_dfnmf_33", Q = "_tooltip_dfnmf_37", U = {
|
|
137
|
+
bar: q,
|
|
138
|
+
"section-with-tooltip": "_section-with-tooltip_dfnmf_9",
|
|
139
|
+
section: J,
|
|
140
|
+
selected: K,
|
|
141
|
+
"tooltip-wrapper": "_tooltip-wrapper_dfnmf_37",
|
|
142
|
+
tooltip: Q,
|
|
143
|
+
"tooltip-text": "_tooltip-text_dfnmf_48",
|
|
144
|
+
"page-number": "_page-number_dfnmf_52"
|
|
145
|
+
}, _ = m.bind(U), S = 13, z = 260, X = ({
|
|
146
|
+
totalPages: o,
|
|
147
|
+
activePage: n,
|
|
148
|
+
changePage: s,
|
|
149
|
+
captions: r
|
|
150
|
+
}) => {
|
|
151
|
+
const a = z / o, c = Math.min(Math.ceil(z / S), o), i = Math.max(S, a), e = [];
|
|
152
|
+
for (let l = 1; l <= o; l++)
|
|
153
|
+
e.push({
|
|
154
|
+
end: l * a,
|
|
155
|
+
pageNumber: l
|
|
156
|
+
});
|
|
157
|
+
const d = Array.from({ length: c }, () => ({ pages: { from: void 0, to: void 0 } }));
|
|
158
|
+
return d.forEach((l, u) => {
|
|
159
|
+
for (l.pages.from = e[0].pageNumber; i * (u + 1) > e[0].end; )
|
|
160
|
+
e.shift();
|
|
161
|
+
l.pages.to = e[0].pageNumber, e.shift();
|
|
162
|
+
}), /* @__PURE__ */ t("div", { className: _("bar"), children: d.map((l, u) => /* @__PURE__ */ t(
|
|
163
|
+
"div",
|
|
164
|
+
{
|
|
165
|
+
className: _("section-with-tooltip"),
|
|
166
|
+
style: { width: i },
|
|
167
|
+
onClick: () => l.pages.from && s(l.pages.from),
|
|
168
|
+
children: /* @__PURE__ */ t(
|
|
169
|
+
B,
|
|
170
|
+
{
|
|
171
|
+
content: /* @__PURE__ */ p("div", { className: _("tooltip"), children: [
|
|
172
|
+
/* @__PURE__ */ t("div", { className: _("tooltip-text"), children: r.goTo }),
|
|
173
|
+
/* @__PURE__ */ t("div", { className: _("page-number"), children: l.pages.from })
|
|
174
|
+
] }),
|
|
175
|
+
wrapperClassName: _("tooltip-wrapper"),
|
|
176
|
+
placement: "top",
|
|
177
|
+
children: /* @__PURE__ */ t(
|
|
178
|
+
"div",
|
|
179
|
+
{
|
|
180
|
+
className: _("section", {
|
|
181
|
+
selected: l.pages.from && l.pages.to && l.pages.from <= n && n <= l.pages.to
|
|
182
|
+
})
|
|
183
|
+
}
|
|
184
|
+
)
|
|
185
|
+
}
|
|
186
|
+
)
|
|
187
|
+
},
|
|
188
|
+
u
|
|
189
|
+
)) });
|
|
190
|
+
}, Y = "_next_1p2t5_18", Z = {
|
|
191
|
+
"page-navigator": "_page-navigator_1p2t5_1",
|
|
192
|
+
"page-buttons": "_page-buttons_1p2t5_6",
|
|
193
|
+
"page-button": "_page-button_1p2t5_6",
|
|
194
|
+
next: Y
|
|
195
|
+
}, g = m.bind(Z), ee = ({
|
|
196
|
+
activePage: o,
|
|
197
|
+
changePage: n,
|
|
198
|
+
totalPages: s,
|
|
199
|
+
captions: r
|
|
200
|
+
}) => {
|
|
201
|
+
const a = () => {
|
|
202
|
+
n(1);
|
|
203
|
+
}, c = () => {
|
|
204
|
+
n(o - 1);
|
|
205
|
+
}, i = () => {
|
|
206
|
+
n(o + 1);
|
|
207
|
+
}, e = () => {
|
|
208
|
+
n(s);
|
|
209
|
+
};
|
|
210
|
+
return /* @__PURE__ */ p("div", { className: g("page-navigator"), children: [
|
|
211
|
+
/* @__PURE__ */ p("div", { className: g("page-buttons"), children: [
|
|
212
|
+
/* @__PURE__ */ t(
|
|
213
|
+
f,
|
|
214
|
+
{
|
|
215
|
+
className: g("page-button"),
|
|
216
|
+
onClick: a,
|
|
217
|
+
disabled: o === 1,
|
|
218
|
+
children: /* @__PURE__ */ t(y, {})
|
|
219
|
+
}
|
|
220
|
+
),
|
|
221
|
+
/* @__PURE__ */ t(
|
|
222
|
+
f,
|
|
223
|
+
{
|
|
224
|
+
className: g("page-button"),
|
|
225
|
+
onClick: c,
|
|
226
|
+
disabled: o === 1,
|
|
227
|
+
children: /* @__PURE__ */ t(T, {})
|
|
228
|
+
}
|
|
229
|
+
)
|
|
230
|
+
] }),
|
|
231
|
+
/* @__PURE__ */ t(
|
|
232
|
+
X,
|
|
233
|
+
{
|
|
234
|
+
totalPages: s,
|
|
235
|
+
activePage: o,
|
|
236
|
+
changePage: n,
|
|
237
|
+
captions: r
|
|
238
|
+
}
|
|
239
|
+
),
|
|
240
|
+
/* @__PURE__ */ p("div", { className: g("page-buttons"), children: [
|
|
241
|
+
/* @__PURE__ */ t(
|
|
242
|
+
f,
|
|
243
|
+
{
|
|
244
|
+
className: g("page-button", "next"),
|
|
245
|
+
onClick: i,
|
|
246
|
+
disabled: o === s,
|
|
247
|
+
children: /* @__PURE__ */ t(T, {})
|
|
248
|
+
}
|
|
249
|
+
),
|
|
250
|
+
/* @__PURE__ */ t(
|
|
251
|
+
f,
|
|
252
|
+
{
|
|
253
|
+
className: g("page-button", "next"),
|
|
254
|
+
onClick: e,
|
|
255
|
+
disabled: o === s,
|
|
256
|
+
children: /* @__PURE__ */ t(y, {})
|
|
257
|
+
}
|
|
258
|
+
)
|
|
259
|
+
] })
|
|
260
|
+
] });
|
|
261
|
+
}, te = {
|
|
262
|
+
"page-controls": "_page-controls_thyf8_1",
|
|
263
|
+
"total-pages": "_total-pages_thyf8_8"
|
|
264
|
+
}, I = m.bind(te), oe = ({
|
|
265
|
+
activePage: o,
|
|
266
|
+
changePage: n,
|
|
267
|
+
captions: s,
|
|
268
|
+
totalPages: r
|
|
269
|
+
}) => /* @__PURE__ */ p("div", { className: I("page-controls"), children: [
|
|
270
|
+
/* @__PURE__ */ t(
|
|
271
|
+
R,
|
|
272
|
+
{
|
|
273
|
+
activePage: o,
|
|
274
|
+
totalPages: r,
|
|
275
|
+
changePage: n,
|
|
276
|
+
pageText: s.page,
|
|
277
|
+
goToText: s.goTo,
|
|
278
|
+
goActionText: s.goAction
|
|
279
|
+
}
|
|
280
|
+
),
|
|
281
|
+
/* @__PURE__ */ t(
|
|
282
|
+
ee,
|
|
283
|
+
{
|
|
284
|
+
changePage: n,
|
|
285
|
+
activePage: o,
|
|
286
|
+
totalPages: r,
|
|
287
|
+
captions: { goTo: s.goTo }
|
|
288
|
+
}
|
|
289
|
+
),
|
|
290
|
+
/* @__PURE__ */ p("span", { className: I("total-pages"), children: [
|
|
291
|
+
`${s.of} `,
|
|
292
|
+
r
|
|
293
|
+
] })
|
|
294
|
+
] }), se = "_pagination_wi26a_1", ne = {
|
|
295
|
+
pagination: se
|
|
296
|
+
}, re = m.bind(ne), ue = ({
|
|
297
|
+
activePage: o,
|
|
298
|
+
totalPages: n,
|
|
299
|
+
pageSize: s,
|
|
300
|
+
totalItems: r,
|
|
301
|
+
pageSizeOptions: a,
|
|
302
|
+
changePage: c,
|
|
303
|
+
changePageSize: i,
|
|
304
|
+
captions: e
|
|
305
|
+
}) => {
|
|
306
|
+
const d = (e == null ? void 0 : e.of) || "of", l = (e == null ? void 0 : e.page) || "Page";
|
|
307
|
+
return /* @__PURE__ */ p("div", { className: re("pagination"), children: [
|
|
308
|
+
/* @__PURE__ */ t(
|
|
309
|
+
M,
|
|
310
|
+
{
|
|
311
|
+
activePage: o,
|
|
312
|
+
pageSize: s,
|
|
313
|
+
totalItems: r,
|
|
314
|
+
ofText: d,
|
|
315
|
+
itemsText: (e == null ? void 0 : e.items) || "items"
|
|
316
|
+
}
|
|
317
|
+
),
|
|
318
|
+
n > 1 && /* @__PURE__ */ t(
|
|
319
|
+
oe,
|
|
320
|
+
{
|
|
321
|
+
activePage: o,
|
|
322
|
+
totalPages: n,
|
|
323
|
+
changePage: c,
|
|
324
|
+
captions: {
|
|
325
|
+
page: l,
|
|
326
|
+
of: d,
|
|
327
|
+
goTo: (e == null ? void 0 : e.goTo) || "Go to page",
|
|
328
|
+
goAction: (e == null ? void 0 : e.goAction) || "Go"
|
|
329
|
+
}
|
|
330
|
+
}
|
|
331
|
+
),
|
|
332
|
+
/* @__PURE__ */ t(
|
|
333
|
+
j,
|
|
334
|
+
{
|
|
335
|
+
size: s,
|
|
336
|
+
sizeOptions: a,
|
|
337
|
+
changeSize: i,
|
|
338
|
+
perPageText: (e == null ? void 0 : e.perPage) || "per page"
|
|
339
|
+
}
|
|
340
|
+
)
|
|
341
|
+
] });
|
|
342
|
+
};
|
|
343
|
+
export {
|
|
344
|
+
ue as P
|
|
345
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { P as t } from "./pagination-7c6ebae2.js";
|
|
2
|
+
import "react/jsx-runtime";
|
|
3
|
+
import "./bind-06a7ff84.js";
|
|
4
|
+
import "react";
|
|
5
|
+
import "./popover.js";
|
|
6
|
+
import "@floating-ui/react";
|
|
7
|
+
import "./button-33c88abf.js";
|
|
8
|
+
import "./fieldText-1ab17a11.js";
|
|
9
|
+
import "./openEye-7b9cf080.js";
|
|
10
|
+
import "./spinLoader-c4a53718.js";
|
|
11
|
+
import "./maxValueDisplay-9be01a75.js";
|
|
12
|
+
import "./fieldLabel.js";
|
|
13
|
+
import "./baseIconButton-251479f7.js";
|
|
14
|
+
import "./prevPage-87faf576.js";
|
|
15
|
+
import "./tooltip.js";
|
|
16
|
+
import "react-dom";
|
|
17
|
+
export {
|
|
18
|
+
t as Pagination,
|
|
19
|
+
t as default
|
|
20
|
+
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import * as e from "react";
|
|
2
|
+
const l = (t) => /* @__PURE__ */ e.createElement("svg", { width: 16, height: 16, viewBox: "0 0 16 16", fill: "#C1C7D0", xmlns: "http://www.w3.org/2000/svg", ...t }, /* @__PURE__ */ e.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" })), C = (t) => /* @__PURE__ */ e.createElement("svg", { width: 16, height: 16, viewBox: "0 0 16 16", fill: "#C1C7D0", xmlns: "http://www.w3.org/2000/svg", ...t }, /* @__PURE__ */ e.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" }));
|
|
3
|
+
export {
|
|
4
|
+
l as S,
|
|
5
|
+
C as a
|
|
6
|
+
};
|