@hortiview/shared-components 0.0.4775 → 0.0.4779
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ListAreaService-BPp_O2BH.js +67 -0
- package/dist/assets/DeleteModal.css +1 -22
- package/dist/assets/main.css +22 -0
- package/dist/components/BaseView/BaseView.js +23 -21
- package/dist/components/BaseView/BaseView.test.js +1 -1
- package/dist/components/BasicHeading/BasicHeading.js +52 -41
- package/dist/components/BlockView/BlockView.js +51 -41
- package/dist/components/DeleteModal/DeleteModal.js +34 -51
- package/dist/components/Disclaimer/Disclaimer.js +11 -8
- package/dist/components/FormComponents/FormDatePicker/FormDatePicker.js +31 -29
- package/dist/components/FormComponents/FormSelect/FormSelect.js +57 -53
- package/dist/components/FormComponents/FormText/FormText.js +64 -59
- package/dist/components/HashTabView/HashTabView.js +48 -40
- package/dist/components/HeaderFilter/HeaderFilter.js +16 -14
- package/dist/components/ListArea/ListArea.js +494 -283
- package/dist/components/ListArea/ListArea.test.js +1 -1
- package/dist/components/ListArea/ListAreaService.js +8 -55
- package/dist/components/SearchBar/SearchBar.js +23 -21
- package/dist/components/VerticalDivider/VerticalDivider.js +6 -4
- package/dist/get-Dyz8NMrE.js +321 -0
- package/dist/hooks/useBreakpoint.js +2 -2
- package/dist/main.js +44 -43
- package/dist/{useBreakpoint-DyAmuka7.js → useBreakpoint-DROHPVxO.js} +2 -2
- package/package.json +1 -1
- package/dist/BlockView.module-8kbPxxc4.js +0 -15
- package/dist/HashTabView.module-BY0tbl3B.js +0 -13
- package/dist/HeaderFilter.module-DiBmulr5.js +0 -7
- package/dist/_baseToString-ByHt83eL.js +0 -282
- package/dist/_getTag-D4bRay2z.js +0 -226
- package/dist/baseView.module-DXWalo9p.js +0 -7
- package/dist/basicHeading.module-ClcvD7x2.js +0 -16
- package/dist/disclaimer.module-BZydt-Q_.js +0 -8
- package/dist/formDatePicker.module-DllLVp7D.js +0 -7
- package/dist/formSelect.module-CdHEvmH_.js +0 -9
- package/dist/formText.module-3BZ0M2vV.js +0 -10
- package/dist/get-BYajYtEc.js +0 -46
- package/dist/listArea.module-B04TR5bj.js +0 -14
- package/dist/searchBar.module-9gKyrZRT.js +0 -7
- package/dist/verticalDivider.module-C3_GL-fH.js +0 -7
- /package/dist/assets/{baseView.css → BaseView.css} +0 -0
- /package/dist/assets/{basicHeading.css → BasicHeading.css} +0 -0
- /package/dist/assets/{disclaimer.css → Disclaimer.css} +0 -0
- /package/dist/assets/{formDatePicker.css → FormDatePicker.css} +0 -0
- /package/dist/assets/{formSelect.css → FormSelect.css} +0 -0
- /package/dist/assets/{formText.css → FormText.css} +0 -0
- /package/dist/assets/{listArea.css → ListAreaService.css} +0 -0
- /package/dist/assets/{searchBar.css → SearchBar.css} +0 -0
- /package/dist/assets/{verticalDivider.css → VerticalDivider.css} +0 -0
|
@@ -1,15 +1,17 @@
|
|
|
1
|
-
import
|
|
1
|
+
import "../../assets/BaseView.css";
|
|
2
|
+
import { jsx as t, Fragment as x, jsxs as e } from "react/jsx-runtime";
|
|
2
3
|
import { useMemo as n } from "react";
|
|
3
4
|
import { EmptyView as k } from "../EmptyView/EmptyView.js";
|
|
4
|
-
import { ListArea as
|
|
5
|
-
import { VerticalDivider as
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import { Grid as W, GridRow as j, GridCol as m, Group as u } from "@element/react-components";
|
|
5
|
+
import { ListArea as y } from "../ListArea/ListArea.js";
|
|
6
|
+
import { VerticalDivider as A } from "../VerticalDivider/VerticalDivider.js";
|
|
7
|
+
import { a as H } from "../../useBreakpoint-DROHPVxO.js";
|
|
8
|
+
import { Grid as L, GridRow as V, GridCol as m, Group as u } from "@element/react-components";
|
|
9
9
|
import { BasicHeading as a } from "../BasicHeading/BasicHeading.js";
|
|
10
|
-
const
|
|
11
|
-
|
|
12
|
-
|
|
10
|
+
const W = "_divider_anyyu_1", _ = {
|
|
11
|
+
divider: W
|
|
12
|
+
}, z = ({
|
|
13
|
+
action: d,
|
|
14
|
+
heading: c,
|
|
13
15
|
elements: o,
|
|
14
16
|
emptyText: s,
|
|
15
17
|
hasSearch: h = !0,
|
|
@@ -21,13 +23,13 @@ const z = ({
|
|
|
21
23
|
routerLinkElement: C,
|
|
22
24
|
searchPlaceholder: B
|
|
23
25
|
}) => {
|
|
24
|
-
const { isLg: r } =
|
|
25
|
-
return /* @__PURE__ */
|
|
26
|
+
const { isLg: r } = H(), i = n(() => o.find((w) => w.route === l), [l, o]), G = n(() => i?.component ?? (r ? /* @__PURE__ */ t(k, { subtitle: s }) : /* @__PURE__ */ t(x, {})), [i, r, s]), b = n(() => r ? !0 : !i, [i, r]);
|
|
27
|
+
return /* @__PURE__ */ t(L, { className: f ?? "", fullHeight: !0, fullWidth: !0, columnGap: 0, children: /* @__PURE__ */ e(V, { children: [
|
|
26
28
|
b && /* @__PURE__ */ e(m, { desktopCol: 4, tabletCol: 12, phoneCol: 12, children: [
|
|
27
29
|
/* @__PURE__ */ e(u, { direction: "vertical", fullWidth: !0, children: [
|
|
28
|
-
|
|
29
|
-
/* @__PURE__ */
|
|
30
|
-
|
|
30
|
+
c && /* @__PURE__ */ t(a, { heading: c, level: 4, marginBottom: 0, children: d }),
|
|
31
|
+
/* @__PURE__ */ t(
|
|
32
|
+
y,
|
|
31
33
|
{
|
|
32
34
|
elements: o,
|
|
33
35
|
hasSearch: h,
|
|
@@ -39,19 +41,19 @@ const z = ({
|
|
|
39
41
|
}
|
|
40
42
|
)
|
|
41
43
|
] }),
|
|
42
|
-
r && /* @__PURE__ */
|
|
44
|
+
r && /* @__PURE__ */ t(A, { className: _.divider, height: "100%" })
|
|
43
45
|
] }),
|
|
44
|
-
/* @__PURE__ */
|
|
45
|
-
/* @__PURE__ */
|
|
46
|
+
/* @__PURE__ */ t(m, { desktopCol: 8, tabletCol: 12, phoneCol: 12, children: /* @__PURE__ */ e(u, { direction: "vertical", fullWidth: !0, children: [
|
|
47
|
+
/* @__PURE__ */ t(
|
|
46
48
|
a,
|
|
47
49
|
{
|
|
48
|
-
heading:
|
|
50
|
+
heading: i?.detailTitle ?? i?.title ?? "",
|
|
49
51
|
level: 4,
|
|
50
|
-
icon:
|
|
52
|
+
icon: i?.hideIconInDetail === !0 ? void 0 : i?.icon,
|
|
51
53
|
marginBottom: 0,
|
|
52
|
-
invisibleButton:
|
|
54
|
+
invisibleButton: i?.detailAction === void 0,
|
|
53
55
|
withAvatar: v,
|
|
54
|
-
children:
|
|
56
|
+
children: i?.detailAction ?? d
|
|
55
57
|
}
|
|
56
58
|
),
|
|
57
59
|
G
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as a, Fragment as s } from "react/jsx-runtime";
|
|
2
|
-
import {
|
|
2
|
+
import { u as l } from "../../useBreakpoint-DROHPVxO.js";
|
|
3
3
|
import { BaseView as r } from "./BaseView.js";
|
|
4
4
|
import { r as i, s as e, f as p } from "../../react.esm-BeDwcQWb.js";
|
|
5
5
|
import { d as u, b as m, t as n, g as t, v as c } from "../../vi.JYQecGiw-BbUbJcT8.js";
|
|
@@ -1,63 +1,74 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { AvailableCustomIcons as
|
|
7
|
-
const
|
|
8
|
-
|
|
1
|
+
import "../../assets/BasicHeading.css";
|
|
2
|
+
import { jsxs as t, jsx as i } from "react/jsx-runtime";
|
|
3
|
+
import { TypoDisplay as C, TypoBody as w, Icon as y } from "@element/react-components";
|
|
4
|
+
import { a as u } from "../../useBreakpoint-DROHPVxO.js";
|
|
5
|
+
import { Iconify as I } from "../Iconify/Iconify.js";
|
|
6
|
+
import { AvailableCustomIcons as B } from "../../enums/AvailableCustomIcons.js";
|
|
7
|
+
const N = "_pageHeader_fwns1_1", H = "_headlineContainer_fwns1_11", b = "_actionButtonContainer_fwns1_16", A = "_content_fwns1_25", W = "_leadingIcon_fwns1_31", $ = "_headingWrapper_fwns1_38", x = "_headingContainer_fwns1_43", T = "_invisible_fwns1_48", j = "_withAvatar_fwns1_52", z = "_iconContainer_fwns1_57", n = {
|
|
8
|
+
pageHeader: N,
|
|
9
|
+
headlineContainer: H,
|
|
10
|
+
actionButtonContainer: b,
|
|
11
|
+
content: A,
|
|
12
|
+
leadingIcon: W,
|
|
13
|
+
headingWrapper: $,
|
|
14
|
+
headingContainer: x,
|
|
15
|
+
invisible: T,
|
|
16
|
+
withAvatar: j,
|
|
17
|
+
iconContainer: z
|
|
18
|
+
}, L = ({ icon: e }) => e ? typeof e != "string" ? /* @__PURE__ */ i("div", { className: n.iconContainer, children: e }) : e in B ? /* @__PURE__ */ i(
|
|
19
|
+
I,
|
|
9
20
|
{
|
|
10
|
-
icon:
|
|
11
|
-
className:
|
|
21
|
+
icon: e,
|
|
22
|
+
className: n.leadingIcon,
|
|
12
23
|
iconSize: "large",
|
|
13
24
|
iconType: "filled"
|
|
14
25
|
}
|
|
15
|
-
) : /* @__PURE__ */
|
|
16
|
-
children:
|
|
17
|
-
marginBottom:
|
|
18
|
-
heading:
|
|
19
|
-
icon:
|
|
20
|
-
className:
|
|
21
|
-
subHeading:
|
|
22
|
-
subHeadingLevel:
|
|
26
|
+
) : /* @__PURE__ */ i(y, { iconSize: "large", iconType: "filled", icon: e, className: n.leadingIcon }) : null, q = ({
|
|
27
|
+
children: e,
|
|
28
|
+
marginBottom: a,
|
|
29
|
+
heading: l,
|
|
30
|
+
icon: d,
|
|
31
|
+
className: p,
|
|
32
|
+
subHeading: o,
|
|
33
|
+
subHeadingLevel: _ = 2,
|
|
23
34
|
invisibleButton: f = !1,
|
|
24
|
-
level:
|
|
25
|
-
fontWeight:
|
|
26
|
-
withAvatar:
|
|
35
|
+
level: r = 4,
|
|
36
|
+
fontWeight: s = 400,
|
|
37
|
+
withAvatar: g = !1
|
|
27
38
|
}) => {
|
|
28
|
-
const { isLg:
|
|
29
|
-
if (
|
|
30
|
-
return typeof
|
|
39
|
+
const { isLg: c } = u(), h = c ? r : r + 1, m = s === "bold" ? 500 : s, v = () => {
|
|
40
|
+
if (a !== void 0)
|
|
41
|
+
return typeof a == "number" ? `${a}px` : "2rem";
|
|
31
42
|
};
|
|
32
|
-
return /* @__PURE__ */
|
|
43
|
+
return /* @__PURE__ */ t(
|
|
33
44
|
"div",
|
|
34
45
|
{
|
|
35
|
-
className:
|
|
36
|
-
style: { marginBottom:
|
|
46
|
+
className: n.pageHeader,
|
|
47
|
+
style: { marginBottom: v() },
|
|
37
48
|
"data-testid": "HeaderContainer",
|
|
38
49
|
children: [
|
|
39
|
-
/* @__PURE__ */
|
|
40
|
-
/* @__PURE__ */
|
|
41
|
-
/* @__PURE__ */
|
|
42
|
-
/* @__PURE__ */
|
|
43
|
-
|
|
50
|
+
/* @__PURE__ */ t("div", { className: `${g && c ? n.withAvatar : ""} ${n.headingWrapper}`, children: [
|
|
51
|
+
/* @__PURE__ */ i(L, { icon: d }),
|
|
52
|
+
/* @__PURE__ */ t("div", { className: o ? n.headingContainer : "", children: [
|
|
53
|
+
/* @__PURE__ */ i(
|
|
54
|
+
C,
|
|
44
55
|
{
|
|
45
|
-
level:
|
|
56
|
+
level: h,
|
|
46
57
|
"data-testid": "Header",
|
|
47
|
-
className:
|
|
48
|
-
style: { fontWeight:
|
|
49
|
-
children:
|
|
58
|
+
className: p ?? "",
|
|
59
|
+
style: { fontWeight: m },
|
|
60
|
+
children: l
|
|
50
61
|
}
|
|
51
62
|
),
|
|
52
|
-
/* @__PURE__ */
|
|
63
|
+
/* @__PURE__ */ i(w, { level: _, children: o })
|
|
53
64
|
] })
|
|
54
65
|
] }),
|
|
55
|
-
/* @__PURE__ */
|
|
66
|
+
/* @__PURE__ */ i(
|
|
56
67
|
"div",
|
|
57
68
|
{
|
|
58
|
-
className: `${
|
|
69
|
+
className: `${n.actionButtonContainer} ${f && n.invisible}`,
|
|
59
70
|
"data-testid": "RightPart",
|
|
60
|
-
children:
|
|
71
|
+
children: e
|
|
61
72
|
}
|
|
62
73
|
)
|
|
63
74
|
]
|
|
@@ -65,5 +76,5 @@ const x = ({ icon: i }) => i ? typeof i != "string" ? /* @__PURE__ */ a("div", {
|
|
|
65
76
|
);
|
|
66
77
|
};
|
|
67
78
|
export {
|
|
68
|
-
|
|
79
|
+
q as BasicHeading
|
|
69
80
|
};
|
|
@@ -1,63 +1,73 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import { getBlockNumberByDto as
|
|
6
|
-
const
|
|
1
|
+
import "../../assets/BlockView.css";
|
|
2
|
+
import { jsxs as g, jsx as l } from "react/jsx-runtime";
|
|
3
|
+
import { TypoSubtitle as x, TypoDisplay as T } from "@element/react-components";
|
|
4
|
+
import { useState as L, useEffect as R, useMemo as B } from "react";
|
|
5
|
+
import { getBlockNumberByDto as C } from "../../services/BlockService.js";
|
|
6
|
+
const A = "_grid_g18cu_1", D = "_black_g18cu_11", E = "_blockLayout_g18cu_15", S = "_blockRow_g18cu_27", V = "_block_g18cu_15", M = "_active_g18cu_46", j = "_error_g18cu_52", q = "_empty_g18cu_58", F = "_blockText_g18cu_65", o = {
|
|
7
|
+
grid: A,
|
|
8
|
+
black: D,
|
|
9
|
+
blockLayout: E,
|
|
10
|
+
blockRow: S,
|
|
11
|
+
block: V,
|
|
12
|
+
active: M,
|
|
13
|
+
error: j,
|
|
14
|
+
empty: q,
|
|
15
|
+
blockText: F
|
|
16
|
+
}, O = ({
|
|
7
17
|
rows: s,
|
|
8
18
|
columns: t,
|
|
9
|
-
hideText:
|
|
10
|
-
errorBlocks:
|
|
19
|
+
hideText: u = !1,
|
|
20
|
+
errorBlocks: p = [],
|
|
11
21
|
showNumbers: y = !0,
|
|
12
|
-
clickable:
|
|
13
|
-
size:
|
|
14
|
-
onClick:
|
|
15
|
-
currentBlock:
|
|
16
|
-
blocks:
|
|
22
|
+
clickable: h = !0,
|
|
23
|
+
size: m = 15,
|
|
24
|
+
onClick: b = null,
|
|
25
|
+
currentBlock: i,
|
|
26
|
+
blocks: _,
|
|
17
27
|
blockViewTitle: v,
|
|
18
|
-
blockLabel:
|
|
28
|
+
blockLabel: f
|
|
19
29
|
}) => {
|
|
20
|
-
const [
|
|
21
|
-
|
|
22
|
-
if (!
|
|
30
|
+
const [k, d] = L(0);
|
|
31
|
+
R(() => {
|
|
32
|
+
if (!i)
|
|
23
33
|
return;
|
|
24
|
-
const
|
|
25
|
-
|
|
26
|
-
}, [
|
|
27
|
-
const
|
|
28
|
-
|
|
29
|
-
},
|
|
30
|
-
return /* @__PURE__ */
|
|
31
|
-
!
|
|
32
|
-
/* @__PURE__ */
|
|
33
|
-
const
|
|
34
|
-
return /* @__PURE__ */
|
|
34
|
+
const c = C(i, t);
|
|
35
|
+
d(c);
|
|
36
|
+
}, [i, t]);
|
|
37
|
+
const N = B(() => s * t, [s, t]), $ = (c) => {
|
|
38
|
+
b && b(c, i ?? void 0);
|
|
39
|
+
}, w = ({ row: c, column: r }) => _.length === 0 ? !0 : _.some((n) => n.position?.row === c && n.position?.column === r);
|
|
40
|
+
return /* @__PURE__ */ g("div", { className: o.grid, children: [
|
|
41
|
+
!u && /* @__PURE__ */ l(x, { level: 1, bold: !0, className: o.black, children: v }),
|
|
42
|
+
/* @__PURE__ */ l("div", { className: o.blockLayout, style: { width: `${m}rem`, height: `${m}rem` }, children: Array.from({ length: s }).map((c, r) => /* @__PURE__ */ l("div", { className: o.blockRow, children: Array.from({ length: t }).map((n, a) => {
|
|
43
|
+
const e = t * r + a + 1;
|
|
44
|
+
return /* @__PURE__ */ l(
|
|
35
45
|
"div",
|
|
36
46
|
{
|
|
37
47
|
"data-testid": "blockViewBlock",
|
|
38
|
-
className: `${
|
|
39
|
-
id: `block${
|
|
40
|
-
onClick:
|
|
41
|
-
|
|
48
|
+
className: `${o.block} ${k === e ? o.active : ""} ${w({ row: r + 1, column: a + 1 }) ? "" : o.empty} ${p.includes(e) ? o.error : ""}`,
|
|
49
|
+
id: `block${e}`,
|
|
50
|
+
onClick: h ? () => {
|
|
51
|
+
d(e), $({ row: r + 1, column: a + 1 });
|
|
42
52
|
} : void 0,
|
|
43
|
-
children: y && /* @__PURE__ */
|
|
53
|
+
children: y && /* @__PURE__ */ l(
|
|
44
54
|
"div",
|
|
45
55
|
{
|
|
46
|
-
className: `${
|
|
47
|
-
children:
|
|
56
|
+
className: `${o.blockText} ${k === e ? o.black : ""}`,
|
|
57
|
+
children: e
|
|
48
58
|
}
|
|
49
59
|
)
|
|
50
60
|
},
|
|
51
|
-
|
|
61
|
+
e
|
|
52
62
|
);
|
|
53
|
-
}) },
|
|
54
|
-
!
|
|
55
|
-
|
|
63
|
+
}) }, r)) }),
|
|
64
|
+
!u && /* @__PURE__ */ g(T, { themeColor: "primary", level: 6, children: [
|
|
65
|
+
N,
|
|
56
66
|
" ",
|
|
57
|
-
|
|
67
|
+
f
|
|
58
68
|
] })
|
|
59
69
|
] });
|
|
60
70
|
};
|
|
61
71
|
export {
|
|
62
|
-
|
|
72
|
+
O as BlockView
|
|
63
73
|
};
|
|
@@ -1,86 +1,69 @@
|
|
|
1
1
|
import "../../assets/DeleteModal.css";
|
|
2
|
-
import { jsx as
|
|
3
|
-
import { Modal as k, Button as
|
|
2
|
+
import { jsx as e, jsxs as c, Fragment as f } from "react/jsx-runtime";
|
|
3
|
+
import { Modal as k, Button as m, Group as r, Icon as y, TypoBody as t } from "@element/react-components";
|
|
4
4
|
import { Iconify as C } from "../Iconify/Iconify.js";
|
|
5
5
|
import { uniqueId as D } from "lodash";
|
|
6
|
-
import "
|
|
7
|
-
|
|
8
|
-
import "../../_getTag-D4bRay2z.js";
|
|
9
|
-
import "../../searchBar.module-9gKyrZRT.js";
|
|
10
|
-
import "../../listArea.module-B04TR5bj.js";
|
|
11
|
-
import { AvailableCustomIcons as p } from "../../enums/AvailableCustomIcons.js";
|
|
12
|
-
import "../../verticalDivider.module-C3_GL-fH.js";
|
|
13
|
-
import "../../baseView.module-DXWalo9p.js";
|
|
14
|
-
import "../../basicHeading.module-ClcvD7x2.js";
|
|
15
|
-
import "../../BlockView.module-8kbPxxc4.js";
|
|
16
|
-
import "../../disclaimer.module-BZydt-Q_.js";
|
|
17
|
-
import "../../HashTabView.module-BY0tbl3B.js";
|
|
18
|
-
import "../../HeaderFilter.module-DiBmulr5.js";
|
|
19
|
-
import "../Scrollbar/Scrollbar.js";
|
|
20
|
-
import "react-hook-form";
|
|
21
|
-
import "../../formDatePicker.module-DllLVp7D.js";
|
|
22
|
-
import "../../formSelect.module-CdHEvmH_.js";
|
|
23
|
-
import "../../formText.module-3BZ0M2vV.js";
|
|
24
|
-
const j = "_bulletPoint_469qk_1", q = "_modal_469qk_6", I = "_colorDanger_469qk_10", t = {
|
|
6
|
+
import { AvailableCustomIcons as s } from "../../enums/AvailableCustomIcons.js";
|
|
7
|
+
const j = "_bulletPoint_469qk_1", q = "_modal_469qk_6", I = "_colorDanger_469qk_10", l = {
|
|
25
8
|
bulletPoint: j,
|
|
26
9
|
modal: q,
|
|
27
10
|
colorDanger: I
|
|
28
|
-
},
|
|
29
|
-
title:
|
|
30
|
-
confirmButtonLabel:
|
|
31
|
-
cancelButtonLabel:
|
|
32
|
-
deleteHeader:
|
|
33
|
-
deleteBody:
|
|
34
|
-
icon:
|
|
11
|
+
}, M = ({
|
|
12
|
+
title: d,
|
|
13
|
+
confirmButtonLabel: u,
|
|
14
|
+
cancelButtonLabel: g,
|
|
15
|
+
deleteHeader: p,
|
|
16
|
+
deleteBody: a,
|
|
17
|
+
icon: o,
|
|
35
18
|
impossibleDeleteHeader: b,
|
|
36
19
|
open: v,
|
|
37
|
-
setOpen:
|
|
20
|
+
setOpen: n,
|
|
38
21
|
onDelete: h,
|
|
39
|
-
isDeletePossible:
|
|
40
|
-
}) => /* @__PURE__ */
|
|
22
|
+
isDeletePossible: i = !0
|
|
23
|
+
}) => /* @__PURE__ */ e(
|
|
41
24
|
k,
|
|
42
25
|
{
|
|
43
|
-
className:
|
|
26
|
+
className: l.modal,
|
|
44
27
|
modalSize: "small",
|
|
45
28
|
open: v,
|
|
46
|
-
onClose: () =>
|
|
47
|
-
title:
|
|
48
|
-
primaryButton: /* @__PURE__ */
|
|
49
|
-
|
|
29
|
+
onClose: () => n(!1),
|
|
30
|
+
title: d,
|
|
31
|
+
primaryButton: /* @__PURE__ */ e(
|
|
32
|
+
m,
|
|
50
33
|
{
|
|
51
34
|
variant: "danger",
|
|
52
|
-
label:
|
|
35
|
+
label: u,
|
|
53
36
|
onClick: h,
|
|
54
|
-
disabled: !
|
|
37
|
+
disabled: !i
|
|
55
38
|
}
|
|
56
39
|
),
|
|
57
|
-
dismissiveButton: /* @__PURE__ */
|
|
58
|
-
children: /* @__PURE__ */
|
|
59
|
-
|
|
40
|
+
dismissiveButton: /* @__PURE__ */ e(m, { variant: "text", label: g, onClick: () => n(!1) }),
|
|
41
|
+
children: /* @__PURE__ */ c(r, { direction: "vertical", secondaryAlign: "center", children: [
|
|
42
|
+
o && Object.values(s).includes(o) && /* @__PURE__ */ e(
|
|
60
43
|
C,
|
|
61
44
|
{
|
|
62
|
-
icon:
|
|
45
|
+
icon: o,
|
|
63
46
|
iconSize: "xlarge",
|
|
64
|
-
className:
|
|
47
|
+
className: l.colorDanger
|
|
65
48
|
}
|
|
66
49
|
),
|
|
67
|
-
|
|
68
|
-
/* @__PURE__ */
|
|
69
|
-
/* @__PURE__ */
|
|
70
|
-
|
|
71
|
-
|
|
50
|
+
o && !Object.values(s).includes(o) && /* @__PURE__ */ e(y, { icon: o, iconSize: "xlarge", className: l.colorDanger }),
|
|
51
|
+
/* @__PURE__ */ e(r, { direction: "vertical", children: i ? /* @__PURE__ */ c(f, { children: [
|
|
52
|
+
/* @__PURE__ */ e(t, { level: 1, themeColor: "text-primary-on-background", children: p }),
|
|
53
|
+
a && /* @__PURE__ */ e(r, { direction: "vertical", gap: "none", children: a.map((x, _) => /* @__PURE__ */ e(
|
|
54
|
+
t,
|
|
72
55
|
{
|
|
73
56
|
level: 2,
|
|
74
|
-
className:
|
|
57
|
+
className: l.bulletPoint,
|
|
75
58
|
themeColor: "text-secondary-on-background",
|
|
76
59
|
children: x
|
|
77
60
|
},
|
|
78
61
|
D(_.toString())
|
|
79
62
|
)) })
|
|
80
|
-
] }) : /* @__PURE__ */
|
|
63
|
+
] }) : /* @__PURE__ */ e(t, { level: 1, themeColor: "text-primary-on-background", children: b }) })
|
|
81
64
|
] })
|
|
82
65
|
}
|
|
83
66
|
);
|
|
84
67
|
export {
|
|
85
|
-
|
|
68
|
+
M as DeleteModal
|
|
86
69
|
};
|
|
@@ -1,16 +1,19 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import { s as
|
|
4
|
-
const
|
|
5
|
-
|
|
1
|
+
import "../../assets/Disclaimer.css";
|
|
2
|
+
import { jsxs as n, jsx as r } from "react/jsx-runtime";
|
|
3
|
+
import { Group as s, TypoSubtitle as t, TypoBody as m, Icon as d } from "@element/react-components";
|
|
4
|
+
const p = "_disclaimer_1k38t_1", y = "_iconArea_1k38t_7", c = {
|
|
5
|
+
disclaimer: p,
|
|
6
|
+
iconArea: y
|
|
7
|
+
}, f = ({ text: o, subtext: e, icon: i, level: l = 2, bold: a = !1 }) => /* @__PURE__ */ n(
|
|
8
|
+
s,
|
|
6
9
|
{
|
|
7
10
|
direction: i || e ? "vertical" : "horizontal",
|
|
8
11
|
secondaryAlign: "center",
|
|
9
12
|
primaryAlign: "center",
|
|
10
13
|
children: [
|
|
11
|
-
/* @__PURE__ */ r(
|
|
12
|
-
e && /* @__PURE__ */ r(
|
|
13
|
-
i && /* @__PURE__ */ r("div", { className:
|
|
14
|
+
/* @__PURE__ */ r(t, { className: c.disclaimer, level: l, bold: a, children: o }),
|
|
15
|
+
e && /* @__PURE__ */ r(m, { level: 2, children: e }),
|
|
16
|
+
i && /* @__PURE__ */ r("div", { className: c.iconArea, children: /* @__PURE__ */ r(d, { className: c.Icon, icon: i, iconSize: "large" }) })
|
|
14
17
|
]
|
|
15
18
|
}
|
|
16
19
|
);
|
|
@@ -1,58 +1,60 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
const
|
|
1
|
+
import "../../../assets/FormDatePicker.css";
|
|
2
|
+
import { jsx as r, jsxs as h } from "react/jsx-runtime";
|
|
3
|
+
import { Datepicker as F } from "@element/react-components";
|
|
4
|
+
import { g as Y } from "../../../get-Dyz8NMrE.js";
|
|
5
|
+
import { useState as _, useEffect as s, useMemo as c } from "react";
|
|
6
|
+
import { useFormContext as j, Controller as v } from "react-hook-form";
|
|
7
|
+
const O = "_datePickerContainer_1l698_1", i = {
|
|
8
|
+
datePickerContainer: O
|
|
9
|
+
}, N = ({
|
|
8
10
|
propertyName: t,
|
|
9
|
-
label:
|
|
11
|
+
label: l,
|
|
10
12
|
required: a = !1,
|
|
11
13
|
requiredText: m,
|
|
12
|
-
className:
|
|
13
|
-
minRangeYear:
|
|
14
|
-
maxRangeYear:
|
|
14
|
+
className: u,
|
|
15
|
+
minRangeYear: d,
|
|
16
|
+
maxRangeYear: f,
|
|
15
17
|
locale: D
|
|
16
18
|
}) => {
|
|
17
19
|
const {
|
|
18
20
|
control: g,
|
|
19
|
-
formState: { errors:
|
|
20
|
-
watch:
|
|
21
|
-
} =
|
|
21
|
+
formState: { errors: k },
|
|
22
|
+
watch: C
|
|
23
|
+
} = j(), [S, n] = _(), o = C(t);
|
|
22
24
|
s(() => {
|
|
23
|
-
|
|
25
|
+
n(/* @__PURE__ */ new Date());
|
|
24
26
|
}, []), s(() => {
|
|
25
|
-
|
|
26
|
-
}, [
|
|
27
|
-
const
|
|
27
|
+
n(new Date(o));
|
|
28
|
+
}, [o]);
|
|
29
|
+
const x = c(() => (/* @__PURE__ */ new Date()).getFullYear() - (d ?? 95), []), p = c(() => (/* @__PURE__ */ new Date()).getFullYear() + (f ?? 15), []);
|
|
28
30
|
return /* @__PURE__ */ r(
|
|
29
|
-
|
|
31
|
+
v,
|
|
30
32
|
{
|
|
31
33
|
name: t,
|
|
32
34
|
rules: {
|
|
33
35
|
required: a
|
|
34
36
|
},
|
|
35
37
|
control: g,
|
|
36
|
-
render: ({ field: { onChange:
|
|
38
|
+
render: ({ field: { onChange: w, ...P } }) => /* @__PURE__ */ h("div", { className: i.datePickerContainer, children: [
|
|
37
39
|
/* @__PURE__ */ r(
|
|
38
|
-
|
|
40
|
+
F,
|
|
39
41
|
{
|
|
40
|
-
...
|
|
41
|
-
className:
|
|
42
|
-
value:
|
|
42
|
+
...P,
|
|
43
|
+
className: u ?? "",
|
|
44
|
+
value: S,
|
|
43
45
|
variant: "outlined",
|
|
44
|
-
label:
|
|
46
|
+
label: l,
|
|
45
47
|
format: (e) => e ? e.toLocaleDateString(D ?? "en") : "",
|
|
46
48
|
disableClearing: !0,
|
|
47
49
|
onChange: (e) => {
|
|
48
|
-
|
|
50
|
+
w(e?.toISOString());
|
|
49
51
|
},
|
|
50
|
-
minQuickSelectYear:
|
|
51
|
-
maxQuickSelectYear:
|
|
52
|
+
minQuickSelectYear: x,
|
|
53
|
+
maxQuickSelectYear: p,
|
|
52
54
|
readOnly: !0
|
|
53
55
|
}
|
|
54
56
|
),
|
|
55
|
-
a &&
|
|
57
|
+
a && Y(k, t) && /* @__PURE__ */ r("span", { className: i.errorText, children: m })
|
|
56
58
|
] })
|
|
57
59
|
}
|
|
58
60
|
);
|