@reportportal/ui-kit 0.0.1-alpha.7 → 0.0.1-alpha.70
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-33bc880f.js +64 -0
- package/dist/button.js +1 -1
- package/dist/calendarArrow-3e1339ea.js +6 -0
- package/dist/checkbox-aa91985d.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 +4 -4
- 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 +3 -2
- 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 +48 -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 +20 -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/constants.d.ts +2 -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 +52 -0
- package/dist/components/table/utils.d.ts +6 -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-382ef010.js +201 -0
- package/dist/datePicker.js +28 -0
- package/dist/dropdown-0260bb66.js +5 -0
- package/dist/dropdown-13d7d50e.js +278 -0
- package/dist/dropdown.js +6 -4
- package/dist/fieldLabel.js +18 -0
- package/dist/fieldNumber-2542b311.js +128 -0
- package/dist/fieldNumber.js +4 -3
- package/dist/fieldText-e605a521.js +158 -0
- package/dist/fieldText.js +6 -2
- package/dist/fieldTextFlex-9e616f66.js +78 -0
- package/dist/fieldTextFlex.js +10 -0
- package/dist/fonts/OpenSans/OpenSans-Bold.ttf +0 -0
- package/dist/fonts/OpenSans/OpenSans-Medium.ttf +0 -0
- package/dist/icons.js +60 -0
- package/dist/index.js +103 -23
- package/dist/maxValueDisplay-9be01a75.js +13 -0
- package/dist/maxValueDisplay.js +6 -0
- package/dist/modal.js +115 -97
- package/dist/openEye-7b9cf080.js +7 -0
- package/dist/pagination-ecbc9940.js +345 -0
- package/dist/pagination.js +20 -0
- package/dist/plus-0929dda4.js +6 -0
- package/dist/popover.js +99 -0
- package/dist/prevPage-87faf576.js +6 -0
- package/dist/radio-62546efa.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-62c3133d.js → systemMessage-924fdaa6.js} +14 -14
- package/dist/systemMessage.js +1 -1
- package/dist/table-20aa2cdf.js +142 -0
- package/dist/table.js +11 -0
- package/dist/themeProvider-46c2be7b.js +23 -0
- package/dist/themeProvider.js +4 -3
- package/dist/toggle-304107fa.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-27e69676.js +0 -132
- package/dist/fieldText-c7085849.js +0 -99
- package/dist/icon-71262f5c.js +0 -26
- package/dist/themeProvider-5800417e.js +0 -19
- package/dist/toggle-5b3d8333.js +0 -67
package/dist/index.js
CHANGED
|
@@ -1,34 +1,114 @@
|
|
|
1
|
-
import { B as
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import { F as
|
|
11
|
-
import { B as N } from "./bubblesLoader-
|
|
1
|
+
import { B as u } from "./button-33bc880f.js";
|
|
2
|
+
import { B as D } from "./baseIconButton-251479f7.js";
|
|
3
|
+
import { C as g } from "./checkbox-aa91985d.js";
|
|
4
|
+
import { S as y } from "./systemMessage-924fdaa6.js";
|
|
5
|
+
import { F as b } from "./fieldText-e605a521.js";
|
|
6
|
+
import { T as w } from "./themeProvider-46c2be7b.js";
|
|
7
|
+
import { Modal as v } from "./modal.js";
|
|
8
|
+
import { D as M } from "./dropdown-13d7d50e.js";
|
|
9
|
+
import { T as k } from "./toggle-304107fa.js";
|
|
10
|
+
import { F as R } from "./fieldNumber-2542b311.js";
|
|
11
|
+
import { B as N } from "./bubblesLoader-a7e709d4.js";
|
|
12
|
+
import { S as U } from "./spinLoader-c4a53718.js";
|
|
13
|
+
import { F as J } from "./fieldTextFlex-9e616f66.js";
|
|
14
|
+
import { R as j } from "./radio-62546efa.js";
|
|
15
|
+
import { Tooltip as G } from "./tooltip.js";
|
|
16
|
+
import { Popover as Q } from "./popover.js";
|
|
17
|
+
import { P as X } from "./pagination-ecbc9940.js";
|
|
18
|
+
import { T as Z } from "./table-20aa2cdf.js";
|
|
19
|
+
import { D as $ } from "./datePicker-382ef010.js";
|
|
20
|
+
import "react-datepicker";
|
|
21
|
+
import { SystemAlert as ro } from "./systemAlert.js";
|
|
22
|
+
import { AddCsvIcon as to, AddImageIcon as no, AddJarIcon as ao, BreadcrumbsTreeIcon as co, ChevronDownDropdownIcon as po, ChevronRightBreadcrumbsIcon as io, CopyIcon as mo, DeleteIcon as so, DragAndDropIcon as Io, DragNDropIcon as xo, DurationIcon as fo, EditIcon as lo, ExportIcon as So, ExternalLinkIcon as uo, FilterFilledIcon as Po, FilterOutlineIcon as Do, FlagIcon as Co, HideIcon as go, MaximizeIcon as Fo, MeatballMenuIcon as yo, MoveToFolderIcon as To, PriorityBlockerIcon as bo, PriorityCriticalIcon as Bo, PriorityHighIcon as wo, PriorityLowIcon as ho, PriorityMediumIcon as vo, PriorityUnspecifiedIcon as Ao, RerunIcon as Mo, SearchIcon as Eo, SortIcon as ko, StatusSuccessIcon as Lo, WarningIcon as Ro } from "./icons.js";
|
|
23
|
+
import { S as No, a as Oo } from "./arrowUp-4a5caee7.js";
|
|
24
|
+
import { a as zo, S as Jo } from "./calendarArrow-3e1339ea.js";
|
|
25
|
+
import { S as jo, a as qo, b as Go } from "./openEye-7b9cf080.js";
|
|
26
|
+
import { S as Qo } from "./close-4b33d7c1.js";
|
|
27
|
+
import { S as Xo } from "./dropdown-0260bb66.js";
|
|
28
|
+
import { S as Zo, a as _o, b as $o } from "./success-dc1914aa.js";
|
|
29
|
+
import { S as rr, a as er } from "./plus-0929dda4.js";
|
|
30
|
+
import { S as nr, a as ar } from "./prevPage-87faf576.js";
|
|
12
31
|
import "react/jsx-runtime";
|
|
13
32
|
import "react";
|
|
14
33
|
import "./bind-06a7ff84.js";
|
|
15
34
|
import "./keyCodes-f63c0e11.js";
|
|
16
|
-
import "./
|
|
35
|
+
import "./maxValueDisplay-9be01a75.js";
|
|
36
|
+
import "./fieldLabel.js";
|
|
17
37
|
import "rc-scrollbars";
|
|
18
38
|
import "framer-motion";
|
|
19
39
|
import "./useOnClickOutside-c332f7d3.js";
|
|
20
|
-
import "react-
|
|
40
|
+
import "@floating-ui/react-dom";
|
|
21
41
|
import "downshift";
|
|
42
|
+
import "react-dom";
|
|
43
|
+
import "@floating-ui/react";
|
|
44
|
+
import "react-datepicker/dist/es/index.js";
|
|
22
45
|
export {
|
|
46
|
+
to as AddCsvIcon,
|
|
47
|
+
no as AddImageIcon,
|
|
48
|
+
ao as AddJarIcon,
|
|
49
|
+
No as ArrowDownIcon,
|
|
50
|
+
Oo as ArrowUpIcon,
|
|
51
|
+
D as BaseIconButton,
|
|
52
|
+
co as BreadcrumbsTreeIcon,
|
|
23
53
|
N as BubblesLoader,
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
54
|
+
u as Button,
|
|
55
|
+
zo as CalendarArrowIcon,
|
|
56
|
+
Jo as CalendarIcon,
|
|
57
|
+
g as Checkbox,
|
|
58
|
+
po as ChevronDownDropdownIcon,
|
|
59
|
+
io as ChevronRightBreadcrumbsIcon,
|
|
60
|
+
jo as ClearIcon,
|
|
61
|
+
qo as CloseEyeIcon,
|
|
62
|
+
Qo as CloseIcon,
|
|
63
|
+
mo as CopyIcon,
|
|
64
|
+
$ as DatePicker,
|
|
65
|
+
so as DeleteIcon,
|
|
66
|
+
Io as DragAndDropIcon,
|
|
67
|
+
xo as DragNDropIcon,
|
|
68
|
+
M as Dropdown,
|
|
69
|
+
Xo as DropdownIcon,
|
|
70
|
+
fo as DurationIcon,
|
|
71
|
+
lo as EditIcon,
|
|
72
|
+
Zo as ErrorIcon,
|
|
73
|
+
So as ExportIcon,
|
|
74
|
+
uo as ExternalLinkIcon,
|
|
75
|
+
R as FieldNumber,
|
|
76
|
+
b as FieldText,
|
|
77
|
+
J as FieldTextFlex,
|
|
78
|
+
Po as FilterFilledIcon,
|
|
79
|
+
Do as FilterOutlineIcon,
|
|
80
|
+
Co as FlagIcon,
|
|
81
|
+
go as HideIcon,
|
|
82
|
+
_o as InfoIcon,
|
|
83
|
+
Fo as MaximizeIcon,
|
|
84
|
+
yo as MeatballMenuIcon,
|
|
85
|
+
rr as MinusIcon,
|
|
86
|
+
v as Modal,
|
|
87
|
+
To as MoveToFolderIcon,
|
|
88
|
+
Go as OpenEyeIcon,
|
|
89
|
+
X as Pagination,
|
|
90
|
+
er as PlusIcon,
|
|
91
|
+
Q as Popover,
|
|
92
|
+
nr as PrevChapterIcon,
|
|
93
|
+
ar as PrevPageIcon,
|
|
94
|
+
bo as PriorityBlockerIcon,
|
|
95
|
+
Bo as PriorityCriticalIcon,
|
|
96
|
+
wo as PriorityHighIcon,
|
|
97
|
+
ho as PriorityLowIcon,
|
|
98
|
+
vo as PriorityMediumIcon,
|
|
99
|
+
Ao as PriorityUnspecifiedIcon,
|
|
100
|
+
j as Radio,
|
|
101
|
+
Mo as RerunIcon,
|
|
102
|
+
Eo as SearchIcon,
|
|
103
|
+
ko as SortIcon,
|
|
104
|
+
U as SpinLoader,
|
|
105
|
+
Lo as StatusSuccessIcon,
|
|
106
|
+
$o as SuccessIcon,
|
|
107
|
+
ro as SystemAlert,
|
|
108
|
+
y as SystemMessage,
|
|
109
|
+
Z as Table,
|
|
110
|
+
w as ThemeProvider,
|
|
111
|
+
k as Toggle,
|
|
112
|
+
G as Tooltip,
|
|
113
|
+
Ro as WarningIcon
|
|
34
114
|
};
|
|
@@ -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 d, Fragment as F } from "react/jsx-runtime";
|
|
2
|
+
import { useState as u, useEffect as y, useRef as G } from "react";
|
|
3
|
+
import { Scrollbars as K } from "rc-scrollbars";
|
|
4
|
+
import { AnimatePresence as P, motion as B } from "framer-motion";
|
|
5
|
+
import { c as w } 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 O } from "./button-33bc880f.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 y(() => {
|
|
14
|
+
const a = () => {
|
|
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", a), a(), () => window.removeEventListener("resize", a);
|
|
21
|
+
}, []), o;
|
|
22
|
+
}, V = "_scrollable_zh8d2_12", Z = {
|
|
23
|
+
"modal-content": "_modal-content_zh8d2_1",
|
|
24
|
+
scrollable: V
|
|
25
|
+
}, ee = w.bind(Z), z = ({ 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 = w.bind(te), oe = ({
|
|
32
|
+
footerNode: o,
|
|
33
|
+
closeHandler: n,
|
|
34
|
+
okButton: a,
|
|
35
|
+
cancelButton: r,
|
|
36
|
+
size: l
|
|
37
|
+
}) => /* @__PURE__ */ d("div", { className: m("modal-footer", { "with-extra-node": o, [`size-${l}`]: l }), children: [
|
|
38
|
+
o && o,
|
|
39
|
+
/* @__PURE__ */ d("div", { className: m("buttons-block"), children: [
|
|
40
|
+
r && /* @__PURE__ */ e("div", { className: m("button-container"), children: /* @__PURE__ */ e(
|
|
41
|
+
O,
|
|
41
42
|
{
|
|
42
43
|
variant: "ghost",
|
|
43
|
-
adjustWidthOn:
|
|
44
|
-
onClick:
|
|
45
|
-
...
|
|
44
|
+
adjustWidthOn: l === "small" ? "parent" : "min-width",
|
|
45
|
+
onClick: n,
|
|
46
|
+
...r
|
|
46
47
|
}
|
|
47
48
|
) }),
|
|
48
|
-
|
|
49
|
+
a && /* @__PURE__ */ e("div", { className: m("button-container"), children: /* @__PURE__ */ e(O, { adjustWidthOn: l === "small" ? "parent" : "min-width", ...a }) })
|
|
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_w4aaf_1",
|
|
53
|
+
"width-description": "_width-description_w4aaf_10",
|
|
54
|
+
"modal-header-content": "_modal-header-content_w4aaf_14",
|
|
55
|
+
"modal-title": "_modal-title_w4aaf_20",
|
|
56
|
+
"close-modal-icon": "_close-modal-icon_w4aaf_29"
|
|
57
|
+
}, _ = w.bind(ne), ae = ({ title: o, onClose: n, withDescription: a = !1 }) => /* @__PURE__ */ d("div", { className: _("modal-header", { "width-description": a }), 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
|
+
] }), le = "_modal_yxql5_1", se = "_description_yxql5_43", ie = "_scrollable_yxql5_53", de = {
|
|
61
|
+
modal: le,
|
|
62
|
+
"overlay-default": "_overlay-default_yxql5_12",
|
|
63
|
+
"overlay-light-cyan": "_overlay-light-cyan_yxql5_16",
|
|
64
|
+
"scrolling-content": "_scrolling-content_yxql5_20",
|
|
65
|
+
"modal-window": "_modal-window_yxql5_26",
|
|
66
|
+
description: se,
|
|
67
|
+
scrollable: ie,
|
|
68
|
+
"size-default": "_size-default_yxql5_57",
|
|
69
|
+
"size-small": "_size-small_yxql5_69",
|
|
70
|
+
"size-large": "_size-large_yxql5_81"
|
|
71
|
+
}, h = w.bind(de), ce = 0.9, re = 32 + 24, me = 32 + 8, _e = 36 + 16, he = 32 * 2, Ee = ({
|
|
72
|
+
title: o,
|
|
73
|
+
children: n,
|
|
74
|
+
footerNode: a,
|
|
75
|
+
okButton: r,
|
|
76
|
+
cancelButton: l,
|
|
77
|
+
className: A,
|
|
78
|
+
size: f = "default",
|
|
79
|
+
onClose: C = () => {
|
|
80
80
|
},
|
|
81
|
-
overlay:
|
|
82
|
-
|
|
81
|
+
overlay: x = "default",
|
|
82
|
+
zIndex: D = 2,
|
|
83
|
+
allowCloseOutside: S = !0,
|
|
84
|
+
scrollable: p = !1,
|
|
85
|
+
withoutFooter: v = !1,
|
|
86
|
+
createFooter: b = null,
|
|
87
|
+
description: s = null
|
|
83
88
|
}) => {
|
|
84
|
-
const [
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
+
const [T, H] = u(!1), [I, q] = u(0), [L, $] = u(!1), i = G(null), E = Q(), M = E.height, k = M * ce, g = (M - I) / 2, R = () => {
|
|
90
|
+
let t = k - he;
|
|
91
|
+
return v || (t = t - _e), s ? t = t - me : t = t - re, t;
|
|
92
|
+
}, c = () => {
|
|
93
|
+
H(!1);
|
|
94
|
+
}, N = (t) => {
|
|
95
|
+
const { keyCode: j } = t;
|
|
96
|
+
j === U.ESCAPE_KEY_CODE && c();
|
|
97
|
+
}, W = () => {
|
|
98
|
+
var t;
|
|
99
|
+
L || ((t = i.current) == null || t.focus(), $(!0));
|
|
89
100
|
};
|
|
90
|
-
return
|
|
91
|
-
if (
|
|
92
|
-
const { clientHeight:
|
|
93
|
-
|
|
101
|
+
return y(() => {
|
|
102
|
+
if (i && i.current) {
|
|
103
|
+
const { clientHeight: t } = i.current;
|
|
104
|
+
q(t);
|
|
94
105
|
}
|
|
95
|
-
}, [
|
|
96
|
-
|
|
106
|
+
}, [n, E]), y(() => (H(!0), document.addEventListener("keydown", N, !1), () => document.removeEventListener("keydown", N, !1)), []), Y(i, S ? c : void 0), /* @__PURE__ */ e(P, { onExitComplete: C, children: T && /* @__PURE__ */ e("div", { className: h("modal", { [`overlay-${x}`]: x }), style: { zIndex: D }, children: /* @__PURE__ */ d(
|
|
107
|
+
B.div,
|
|
97
108
|
{
|
|
98
|
-
className:
|
|
99
|
-
ref:
|
|
109
|
+
className: h("modal-window", { [`size-${f}`]: f }, A),
|
|
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: -g },
|
|
113
|
+
animate: { opacity: 1, marginTop: g },
|
|
114
|
+
exit: { opacity: 0, marginTop: -g },
|
|
104
115
|
transition: { duration: 0.3 },
|
|
116
|
+
onAnimationStart: W,
|
|
105
117
|
children: [
|
|
106
|
-
/* @__PURE__ */ e(
|
|
107
|
-
/* @__PURE__ */
|
|
108
|
-
|
|
109
|
-
|
|
118
|
+
/* @__PURE__ */ e(ae, { title: o, onClose: c, withDescription: !!s }),
|
|
119
|
+
p ? /* @__PURE__ */ d(K, { autoHeight: !0, autoHeightMax: R(), hideTracksWhenNotNeeded: !0, children: [
|
|
120
|
+
s && /* @__PURE__ */ e("span", { className: h("description", { scrollable: p }), children: s }),
|
|
121
|
+
/* @__PURE__ */ e(z, { scrollable: !0, children: n })
|
|
122
|
+
] }) : /* @__PURE__ */ d(F, { children: [
|
|
123
|
+
s && /* @__PURE__ */ e("span", { className: h("description"), children: s }),
|
|
124
|
+
/* @__PURE__ */ e(z, { children: n })
|
|
125
|
+
] }),
|
|
126
|
+
!v && (b ? b(c) : /* @__PURE__ */ e(
|
|
127
|
+
oe,
|
|
110
128
|
{
|
|
111
|
-
size:
|
|
112
|
-
footerNode:
|
|
113
|
-
okButton:
|
|
114
|
-
cancelButton:
|
|
115
|
-
closeHandler:
|
|
129
|
+
size: f,
|
|
130
|
+
footerNode: a,
|
|
131
|
+
okButton: r,
|
|
132
|
+
cancelButton: l,
|
|
133
|
+
closeHandler: c
|
|
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
|
+
z as ModalContent,
|
|
144
|
+
oe as ModalFooter,
|
|
145
|
+
ae 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
|
+
};
|