@starasia/admin 3.21.8 → 3.22.0
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/index.es.js
CHANGED
|
@@ -8,7 +8,7 @@ export * from "@starasia/button";
|
|
|
8
8
|
export * from "@starasia/card";
|
|
9
9
|
import { StarasiaDate as Tt } from "@starasia/date";
|
|
10
10
|
export * from "@starasia/date";
|
|
11
|
-
import { Dialog as
|
|
11
|
+
import { Dialog as Ue, DialogTitle as Se, DialogBody as Pe, DialogFooter as nt } from "@starasia/dialog";
|
|
12
12
|
export * from "@starasia/dialog";
|
|
13
13
|
import { Drawer as Ot } from "@starasia/drawer";
|
|
14
14
|
export * from "@starasia/drawer";
|
|
@@ -16,11 +16,11 @@ import { Dropdown as lt } from "@starasia/dropdown";
|
|
|
16
16
|
export * from "@starasia/dropdown";
|
|
17
17
|
import { useMediaQuery as ee } from "@starasia/hooks";
|
|
18
18
|
export * from "@starasia/hooks";
|
|
19
|
-
import { searchParamsToObject as
|
|
19
|
+
import { searchParamsToObject as qe } from "@starasia/http";
|
|
20
20
|
export * from "@starasia/http";
|
|
21
21
|
import { Input as ot } from "@starasia/input";
|
|
22
22
|
export * from "@starasia/input";
|
|
23
|
-
import { Menu as Dt, MenuButton as
|
|
23
|
+
import { Menu as Dt, MenuButton as $e, MenuLists as bt, MenuHeading as Nt, MenuBody as vt, MenuFooter as Zt } from "@starasia/menu";
|
|
24
24
|
export * from "@starasia/menu";
|
|
25
25
|
import { Pagination as jt } from "@starasia/pagination";
|
|
26
26
|
export * from "@starasia/pagination";
|
|
@@ -30,14 +30,14 @@ export * from "@starasia/table";
|
|
|
30
30
|
export * from "@starasia/tabs";
|
|
31
31
|
import { Textarea as Ut } from "@starasia/textarea";
|
|
32
32
|
export * from "@starasia/textarea";
|
|
33
|
-
import { useTheme as
|
|
33
|
+
import { useTheme as Pt, ThemeProvider as ht, useRadius as qt, useColor as Jt } from "@starasia/theme";
|
|
34
34
|
export * from "@starasia/theme";
|
|
35
35
|
export * from "@starasia/toast";
|
|
36
36
|
import { Toggle as kt } from "@starasia/toggle";
|
|
37
37
|
export * from "@starasia/toggle";
|
|
38
38
|
import { Tooltip as ue } from "@starasia/tooltip";
|
|
39
39
|
export * from "@starasia/tooltip";
|
|
40
|
-
import { Checkbox as
|
|
40
|
+
import { Checkbox as et } from "@starasia/checkbox";
|
|
41
41
|
export * from "@starasia/checkbox";
|
|
42
42
|
import { Radio as Gt } from "@starasia/radio";
|
|
43
43
|
export * from "@starasia/radio";
|
|
@@ -55,10 +55,11 @@ import { Skeleton as Re } from "@starasia/skeleton";
|
|
|
55
55
|
export * from "@starasia/skeleton";
|
|
56
56
|
export * from "@starasia/progress-stepper";
|
|
57
57
|
import { jsx as e, jsxs as d, Fragment as X } from "react/jsx-runtime";
|
|
58
|
-
import Ft, { createContext as St, useState as A, useContext as Et, useCallback as Ve, useMemo as De, memo as te, useEffect as U, useRef as le, useLayoutEffect as
|
|
59
|
-
import { useSearchParams as
|
|
60
|
-
import Kt from "react-
|
|
61
|
-
|
|
58
|
+
import Ft, { createContext as St, useState as A, useContext as Et, useCallback as Ve, useMemo as De, memo as te, useEffect as U, useRef as le, useLayoutEffect as tt, isValidElement as rt, forwardRef as Mt, Children as Qt, useImperativeHandle as Yt } from "react";
|
|
59
|
+
import { useSearchParams as Je, useNavigate as ct, useLocation as ze, Outlet as ut, Link as Xt, useParams as Lt } from "react-router";
|
|
60
|
+
import Kt from "react-dom";
|
|
61
|
+
import er from "react-easy-crop";
|
|
62
|
+
const tr = {
|
|
62
63
|
menus: [],
|
|
63
64
|
menuBottom: void 0,
|
|
64
65
|
logo: "",
|
|
@@ -66,7 +67,7 @@ const er = {
|
|
|
66
67
|
userData: null,
|
|
67
68
|
setUserData: () => {
|
|
68
69
|
}
|
|
69
|
-
}, Wt = St(
|
|
70
|
+
}, Wt = St(tr), Bt = () => Et(Wt), rr = (t) => {
|
|
70
71
|
const [r, n] = A(
|
|
71
72
|
(t == null ? void 0 : t.initialUserData) || null
|
|
72
73
|
);
|
|
@@ -82,7 +83,7 @@ const er = {
|
|
|
82
83
|
},
|
|
83
84
|
clearBadge: () => {
|
|
84
85
|
}
|
|
85
|
-
}),
|
|
86
|
+
}), ir = ({ children: t }) => {
|
|
86
87
|
const [r, n] = A({}), l = Ve(
|
|
87
88
|
(a) => {
|
|
88
89
|
n(
|
|
@@ -109,10 +110,10 @@ const er = {
|
|
|
109
110
|
[r, i, l, o]
|
|
110
111
|
);
|
|
111
112
|
return /* @__PURE__ */ e(At.Provider, { value: s, children: t });
|
|
112
|
-
},
|
|
113
|
+
}, nr = () => Et(At), Ye = (t, r) => {
|
|
113
114
|
const n = r !== void 0 ? r : t;
|
|
114
115
|
return n == null ? null : typeof n == "string" || typeof n == "number" ? { value: n } : n;
|
|
115
|
-
},
|
|
116
|
+
}, lr = ({
|
|
116
117
|
router: t,
|
|
117
118
|
menus: r = [],
|
|
118
119
|
menuBottom: n,
|
|
@@ -121,7 +122,7 @@ const er = {
|
|
|
121
122
|
initialUserData: o,
|
|
122
123
|
theme: s
|
|
123
124
|
}) => {
|
|
124
|
-
const a =
|
|
125
|
+
const a = rr({ initialUserData: o }), { theme: h } = Pt();
|
|
125
126
|
return /* @__PURE__ */ e(
|
|
126
127
|
Wt.Provider,
|
|
127
128
|
{
|
|
@@ -133,11 +134,11 @@ const er = {
|
|
|
133
134
|
setUserData: a.setUserData,
|
|
134
135
|
menuBottom: n
|
|
135
136
|
},
|
|
136
|
-
children: /* @__PURE__ */ e(
|
|
137
|
+
children: /* @__PURE__ */ e(ir, { children: s ? /* @__PURE__ */ e(ht, { value: s, children: t }) : h ? /* @__PURE__ */ e(ht, { value: h, children: t }) : t })
|
|
137
138
|
}
|
|
138
139
|
);
|
|
139
|
-
},
|
|
140
|
-
function
|
|
140
|
+
}, ln = te(lr);
|
|
141
|
+
function or({
|
|
141
142
|
collapsed: t = !1,
|
|
142
143
|
children: r
|
|
143
144
|
}) {
|
|
@@ -174,18 +175,18 @@ function lr({
|
|
|
174
175
|
}
|
|
175
176
|
);
|
|
176
177
|
}
|
|
177
|
-
const
|
|
178
|
+
const _e = "moduleSwitcherGroupId", it = "sa-module-switcher-change";
|
|
178
179
|
function ft() {
|
|
179
180
|
if (typeof window > "u") return null;
|
|
180
|
-
const t = window.localStorage.getItem(
|
|
181
|
+
const t = window.localStorage.getItem(_e);
|
|
181
182
|
if (t === null) return null;
|
|
182
183
|
const r = Number(t);
|
|
183
184
|
return Number.isFinite(r) ? r : null;
|
|
184
185
|
}
|
|
185
186
|
function Rt(t) {
|
|
186
|
-
typeof window > "u" || (t === null ? window.localStorage.removeItem(
|
|
187
|
+
typeof window > "u" || (t === null ? window.localStorage.removeItem(_e) : window.localStorage.setItem(_e, String(t)), window.dispatchEvent(new CustomEvent(it, { detail: t })));
|
|
187
188
|
}
|
|
188
|
-
function
|
|
189
|
+
function on() {
|
|
189
190
|
Rt(null);
|
|
190
191
|
}
|
|
191
192
|
function Ht() {
|
|
@@ -196,16 +197,16 @@ function Ht() {
|
|
|
196
197
|
const l = () => {
|
|
197
198
|
r(ft());
|
|
198
199
|
}, i = (o) => {
|
|
199
|
-
o.key ===
|
|
200
|
+
o.key === _e && l();
|
|
200
201
|
};
|
|
201
|
-
return window.addEventListener(
|
|
202
|
-
window.removeEventListener(
|
|
202
|
+
return window.addEventListener(it, l), window.addEventListener("storage", i), () => {
|
|
203
|
+
window.removeEventListener(it, l), window.removeEventListener("storage", i);
|
|
203
204
|
};
|
|
204
205
|
}, []), { selectedGroupId: t, setSelectedGroupId: (l) => {
|
|
205
206
|
Rt(l), r(l);
|
|
206
207
|
} };
|
|
207
208
|
}
|
|
208
|
-
let
|
|
209
|
+
let je = 0, ve = !1;
|
|
209
210
|
const gt = () => /* @__PURE__ */ d(
|
|
210
211
|
"svg",
|
|
211
212
|
{
|
|
@@ -240,7 +241,7 @@ const gt = () => /* @__PURE__ */ d(
|
|
|
240
241
|
cursor: "pointer",
|
|
241
242
|
textAlign: "left"
|
|
242
243
|
};
|
|
243
|
-
function
|
|
244
|
+
function cn({
|
|
244
245
|
children: t,
|
|
245
246
|
headerRight: r,
|
|
246
247
|
profile: n,
|
|
@@ -252,33 +253,33 @@ function ln({
|
|
|
252
253
|
headerActions: h,
|
|
253
254
|
profileRole: f,
|
|
254
255
|
profileMenuButtons: g,
|
|
255
|
-
profileMenuItems:
|
|
256
|
-
logoutButton:
|
|
256
|
+
profileMenuItems: p,
|
|
257
|
+
logoutButton: y
|
|
257
258
|
}) {
|
|
258
|
-
var ke,
|
|
259
|
-
const [b] =
|
|
259
|
+
var ke, Ne;
|
|
260
|
+
const [b] = Je(), H = b.get("embed") === "true", D = Bt(), { badges: T } = nr(), Z = ct(), j = ze(), M = !ee("md"), [fe, G] = A(!1), [V, K] = A(!1), [oe, ce] = A(!1), [_, ae] = A(!1), [se, re] = A(/* @__PURE__ */ new Set()), [Q, q] = A(null), { selectedGroupId: z, setSelectedGroupId: I } = Ht(), Y = le(null), de = le(null);
|
|
260
261
|
U(() => {
|
|
261
262
|
const m = Y.current;
|
|
262
263
|
if (!m) return;
|
|
263
264
|
const F = () => {
|
|
264
|
-
ve || (
|
|
265
|
+
ve || (je = m.scrollTop);
|
|
265
266
|
};
|
|
266
267
|
return m.addEventListener("scroll", F), () => m.removeEventListener("scroll", F);
|
|
267
268
|
}, []);
|
|
268
269
|
const he = () => {
|
|
269
270
|
const m = Y.current;
|
|
270
|
-
m &&
|
|
271
|
+
m && je > 0 && (ve = !0, m.scrollTop = je, requestAnimationFrame(() => {
|
|
271
272
|
ve = !1;
|
|
272
273
|
}));
|
|
273
274
|
};
|
|
274
|
-
|
|
275
|
+
tt(() => {
|
|
275
276
|
ve = !0, he();
|
|
276
277
|
const m = setTimeout(() => {
|
|
277
278
|
ve = !1;
|
|
278
279
|
}, 300);
|
|
279
280
|
return () => clearTimeout(m);
|
|
280
|
-
}, []),
|
|
281
|
-
D.menus.length > 0 && (
|
|
281
|
+
}, []), tt(() => {
|
|
282
|
+
D.menus.length > 0 && (je > 0 ? he() : requestAnimationFrame(() => {
|
|
282
283
|
var F;
|
|
283
284
|
const m = (F = Y.current) == null ? void 0 : F.querySelector(
|
|
284
285
|
"[data-menu-active='true']"
|
|
@@ -302,16 +303,16 @@ function ln({
|
|
|
302
303
|
}, [M]);
|
|
303
304
|
const Me = () => {
|
|
304
305
|
G(!0);
|
|
305
|
-
},
|
|
306
|
+
}, Ie = () => {
|
|
306
307
|
G(!1);
|
|
307
|
-
},
|
|
308
|
+
}, Ge = () => {
|
|
308
309
|
G(!1), i();
|
|
309
|
-
},
|
|
310
|
+
}, Te = (m) => {
|
|
310
311
|
const F = [m.to];
|
|
311
312
|
return m.children && F.push(...m.children.map((S) => S.to)), F;
|
|
312
313
|
}, Le = [
|
|
313
|
-
...D.menus.flatMap((m) => m.items.flatMap(
|
|
314
|
-
...((ke = D.menuBottom) == null ? void 0 : ke.flatMap(
|
|
314
|
+
...D.menus.flatMap((m) => m.items.flatMap(Te)),
|
|
315
|
+
...((ke = D.menuBottom) == null ? void 0 : ke.flatMap(Te)) ?? []
|
|
315
316
|
], ie = (m) => {
|
|
316
317
|
if (!j.pathname.startsWith(m)) return !1;
|
|
317
318
|
const F = Le.filter((S) => j.pathname.startsWith(S)).sort((S, x) => x.length - S.length)[0];
|
|
@@ -330,30 +331,30 @@ function ln({
|
|
|
330
331
|
S.items.forEach(m);
|
|
331
332
|
}), (F = D.menuBottom) == null || F.forEach(m);
|
|
332
333
|
}, [j.pathname, D.menus, D.menuBottom]);
|
|
333
|
-
const
|
|
334
|
+
const Oe = (m) => {
|
|
334
335
|
re((F) => {
|
|
335
336
|
const S = new Set(F);
|
|
336
337
|
return S.has(m) ? S.delete(m) : S.add(m), S;
|
|
337
338
|
});
|
|
338
339
|
};
|
|
339
340
|
U(() => {
|
|
340
|
-
D.menus.length !== 0 &&
|
|
341
|
-
}, [D.menus,
|
|
341
|
+
D.menus.length !== 0 && z !== null && !D.menus.some((m) => m.id === z) && I(null);
|
|
342
|
+
}, [D.menus, z, I]);
|
|
342
343
|
const We = De(() => {
|
|
343
|
-
if (
|
|
344
|
+
if (z !== null)
|
|
344
345
|
return D.menus.filter(
|
|
345
|
-
(S) => S.id ===
|
|
346
|
+
(S) => S.id === z || S.parentGroupId === z
|
|
346
347
|
);
|
|
347
348
|
const m = D.menus.filter((S) => S.parentGroupId === void 0), F = D.menus.filter((S) => S.parentGroupId !== void 0).flatMap((S) => S.items);
|
|
348
349
|
return F.length === 0 ? m : [
|
|
349
350
|
...m,
|
|
350
351
|
{ id: 18, name: "Pengaturan", items: F, parentGroupId: void 0 }
|
|
351
352
|
];
|
|
352
|
-
}, [D.menus,
|
|
353
|
+
}, [D.menus, z]);
|
|
353
354
|
if (H)
|
|
354
355
|
return /* @__PURE__ */ e("main", { style: { height: "100vh", overflowY: "auto", backgroundColor: "var(--sa-background-primary-inverse, #f8f8f8)" }, children: t || /* @__PURE__ */ e(ut, {}) });
|
|
355
356
|
const Be = (m) => {
|
|
356
|
-
const F = m.children && m.children.length > 0, S = se.has(m.id), x = F ? m.children.some((L) => ie(L.to)) : ie(m.to), w =
|
|
357
|
+
const F = m.children && m.children.length > 0, S = se.has(m.id), x = F ? m.children.some((L) => ie(L.to)) : ie(m.to), w = Ye(m.badge, T[m.id]), v = !!w && V && !M;
|
|
357
358
|
return /* @__PURE__ */ d("div", { "data-menu-active": x || void 0, children: [
|
|
358
359
|
/* @__PURE__ */ d(
|
|
359
360
|
"button",
|
|
@@ -362,13 +363,13 @@ function ln({
|
|
|
362
363
|
if (F)
|
|
363
364
|
if (V && !M) {
|
|
364
365
|
const R = L.currentTarget.getBoundingClientRect();
|
|
365
|
-
|
|
366
|
+
q({
|
|
366
367
|
item: m,
|
|
367
368
|
top: R.top,
|
|
368
369
|
left: R.right + 8
|
|
369
370
|
});
|
|
370
371
|
} else
|
|
371
|
-
|
|
372
|
+
Oe(m.id);
|
|
372
373
|
else
|
|
373
374
|
Z(m.to);
|
|
374
375
|
},
|
|
@@ -532,9 +533,9 @@ function ln({
|
|
|
532
533
|
}
|
|
533
534
|
),
|
|
534
535
|
m.children.map((R) => {
|
|
535
|
-
const ne =
|
|
536
|
+
const ne = Ye(
|
|
536
537
|
R.badge,
|
|
537
|
-
|
|
538
|
+
T[R.id]
|
|
538
539
|
);
|
|
539
540
|
return /* @__PURE__ */ d(
|
|
540
541
|
"button",
|
|
@@ -557,11 +558,11 @@ function ln({
|
|
|
557
558
|
cursor: "pointer",
|
|
558
559
|
border: ie(R.to) ? "1px solid var(--sa-border-subtle, #0b120e24)" : "1px solid transparent"
|
|
559
560
|
},
|
|
560
|
-
onMouseEnter: (
|
|
561
|
-
ie(R.to) || (
|
|
561
|
+
onMouseEnter: (pe) => {
|
|
562
|
+
ie(R.to) || (pe.currentTarget.style.backgroundColor = "var(--sa-background-neutral, #f0f1f2)");
|
|
562
563
|
},
|
|
563
|
-
onMouseLeave: (
|
|
564
|
-
ie(R.to) || (
|
|
564
|
+
onMouseLeave: (pe) => {
|
|
565
|
+
ie(R.to) || (pe.currentTarget.style.backgroundColor = "transparent");
|
|
565
566
|
},
|
|
566
567
|
children: [
|
|
567
568
|
/* @__PURE__ */ e(
|
|
@@ -812,7 +813,7 @@ function ln({
|
|
|
812
813
|
}
|
|
813
814
|
),
|
|
814
815
|
a && /* @__PURE__ */ e(
|
|
815
|
-
|
|
816
|
+
or,
|
|
816
817
|
{
|
|
817
818
|
collapsed: M ? !1 : V,
|
|
818
819
|
children: a
|
|
@@ -951,7 +952,7 @@ function ln({
|
|
|
951
952
|
/* @__PURE__ */ d("div", { style: { display: "flex", alignItems: "center", gap: "0.75rem" }, children: [
|
|
952
953
|
h,
|
|
953
954
|
/* @__PURE__ */ d(Dt, { position: "bottom-right", children: [
|
|
954
|
-
/* @__PURE__ */ e(
|
|
955
|
+
/* @__PURE__ */ e($e, { children: /* @__PURE__ */ d(
|
|
955
956
|
"div",
|
|
956
957
|
{
|
|
957
958
|
style: {
|
|
@@ -1114,8 +1115,8 @@ function ln({
|
|
|
1114
1115
|
]
|
|
1115
1116
|
}
|
|
1116
1117
|
) }),
|
|
1117
|
-
(g && g.length > 0 ||
|
|
1118
|
-
g == null ? void 0 : g.map((m, F) => /* @__PURE__ */ e(
|
|
1118
|
+
(g && g.length > 0 || p) && /* @__PURE__ */ d(vt, { children: [
|
|
1119
|
+
g == null ? void 0 : g.map((m, F) => /* @__PURE__ */ e($e, { children: /* @__PURE__ */ d(
|
|
1119
1120
|
"button",
|
|
1120
1121
|
{
|
|
1121
1122
|
type: "button",
|
|
@@ -1133,9 +1134,9 @@ function ln({
|
|
|
1133
1134
|
]
|
|
1134
1135
|
}
|
|
1135
1136
|
) }, `${m.label}-${F}`)),
|
|
1136
|
-
|
|
1137
|
+
p
|
|
1137
1138
|
] }),
|
|
1138
|
-
|
|
1139
|
+
y ?? /* @__PURE__ */ e(Zt, { children: /* @__PURE__ */ e($e, { children: /* @__PURE__ */ d(
|
|
1139
1140
|
"button",
|
|
1140
1141
|
{
|
|
1141
1142
|
type: "button",
|
|
@@ -1204,19 +1205,19 @@ function ln({
|
|
|
1204
1205
|
children: s
|
|
1205
1206
|
}
|
|
1206
1207
|
),
|
|
1207
|
-
/* @__PURE__ */ d(
|
|
1208
|
+
/* @__PURE__ */ d(Ue, { isShow: fe, onHide: Ie, children: [
|
|
1208
1209
|
/* @__PURE__ */ e(Se, { children: "Confirmation Logout" }),
|
|
1209
|
-
/* @__PURE__ */ e(
|
|
1210
|
-
/* @__PURE__ */ e(
|
|
1211
|
-
/* @__PURE__ */ e(u, { children: /* @__PURE__ */ e(B, { secondary: !0, onClick:
|
|
1212
|
-
/* @__PURE__ */ e(u, { children: /* @__PURE__ */ e(B, { primary: !0, onClick:
|
|
1210
|
+
/* @__PURE__ */ e(Pe, { children: "Are you sure you want to end the session and exit the page?" }),
|
|
1211
|
+
/* @__PURE__ */ e(nt, { children: /* @__PURE__ */ e(u, { display: "flex", align: "flex-end", justify: "center", children: /* @__PURE__ */ d($, { direction: "row", gap: "sm", align: "center", children: [
|
|
1212
|
+
/* @__PURE__ */ e(u, { children: /* @__PURE__ */ e(B, { secondary: !0, onClick: Ie, children: "Cancel" }) }),
|
|
1213
|
+
/* @__PURE__ */ e(u, { children: /* @__PURE__ */ e(B, { primary: !0, onClick: Ge, children: "Yes, Sure" }) })
|
|
1213
1214
|
] }) }) })
|
|
1214
1215
|
] }),
|
|
1215
1216
|
Q && /* @__PURE__ */ d(X, { children: [
|
|
1216
1217
|
/* @__PURE__ */ e(
|
|
1217
1218
|
"div",
|
|
1218
1219
|
{
|
|
1219
|
-
onClick: () =>
|
|
1220
|
+
onClick: () => q(null),
|
|
1220
1221
|
style: {
|
|
1221
1222
|
position: "fixed",
|
|
1222
1223
|
inset: 0,
|
|
@@ -1261,16 +1262,16 @@ function ln({
|
|
|
1261
1262
|
children: Q.item.title
|
|
1262
1263
|
}
|
|
1263
1264
|
),
|
|
1264
|
-
(
|
|
1265
|
-
const F = ie(m.to), S =
|
|
1265
|
+
(Ne = Q.item.children) == null ? void 0 : Ne.map((m) => {
|
|
1266
|
+
const F = ie(m.to), S = Ye(
|
|
1266
1267
|
m.badge,
|
|
1267
|
-
|
|
1268
|
+
T[m.id]
|
|
1268
1269
|
);
|
|
1269
1270
|
return /* @__PURE__ */ d(
|
|
1270
1271
|
"button",
|
|
1271
1272
|
{
|
|
1272
1273
|
onClick: () => {
|
|
1273
|
-
Z(m.to),
|
|
1274
|
+
Z(m.to), q(null);
|
|
1274
1275
|
},
|
|
1275
1276
|
style: {
|
|
1276
1277
|
width: "100%",
|
|
@@ -1323,7 +1324,7 @@ function ln({
|
|
|
1323
1324
|
] })
|
|
1324
1325
|
] });
|
|
1325
1326
|
}
|
|
1326
|
-
function
|
|
1327
|
+
function cr({
|
|
1327
1328
|
isShow: t,
|
|
1328
1329
|
onHide: r,
|
|
1329
1330
|
menus: n,
|
|
@@ -1334,7 +1335,7 @@ function or({
|
|
|
1334
1335
|
i(s), r();
|
|
1335
1336
|
};
|
|
1336
1337
|
return /* @__PURE__ */ e(
|
|
1337
|
-
|
|
1338
|
+
Ue,
|
|
1338
1339
|
{
|
|
1339
1340
|
isShow: t,
|
|
1340
1341
|
onHide: r,
|
|
@@ -1344,7 +1345,7 @@ function or({
|
|
|
1344
1345
|
boxShadow: "none",
|
|
1345
1346
|
border: "none"
|
|
1346
1347
|
},
|
|
1347
|
-
children: /* @__PURE__ */ e(
|
|
1348
|
+
children: /* @__PURE__ */ e(Pe, { children: /* @__PURE__ */ d(
|
|
1348
1349
|
"div",
|
|
1349
1350
|
{
|
|
1350
1351
|
style: {
|
|
@@ -1468,15 +1469,15 @@ function or({
|
|
|
1468
1469
|
}
|
|
1469
1470
|
);
|
|
1470
1471
|
}
|
|
1471
|
-
function
|
|
1472
|
+
function an({
|
|
1472
1473
|
onSelect: t,
|
|
1473
1474
|
"aria-label": r = "Pilih module"
|
|
1474
1475
|
} = {}) {
|
|
1475
1476
|
const n = Bt(), l = ct(), { selectedGroupId: i, setSelectedGroupId: o } = Ht(), [s, a] = A(!1), h = (f) => {
|
|
1476
1477
|
var g;
|
|
1477
1478
|
if (o(f), f !== null) {
|
|
1478
|
-
const
|
|
1479
|
-
|
|
1479
|
+
const p = n.menus.find((b) => b.id === f), y = (g = p == null ? void 0 : p.items[0]) == null ? void 0 : g.to;
|
|
1480
|
+
y && l(y);
|
|
1480
1481
|
}
|
|
1481
1482
|
t == null || t(f);
|
|
1482
1483
|
};
|
|
@@ -1525,7 +1526,7 @@ function on({
|
|
|
1525
1526
|
)
|
|
1526
1527
|
] }),
|
|
1527
1528
|
/* @__PURE__ */ e(
|
|
1528
|
-
|
|
1529
|
+
cr,
|
|
1529
1530
|
{
|
|
1530
1531
|
isShow: s,
|
|
1531
1532
|
onHide: () => a(!1),
|
|
@@ -1536,9 +1537,9 @@ function on({
|
|
|
1536
1537
|
)
|
|
1537
1538
|
] });
|
|
1538
1539
|
}
|
|
1539
|
-
const
|
|
1540
|
+
const sn = te(
|
|
1540
1541
|
({ children: t, coverImage: r, logo: n }) => {
|
|
1541
|
-
const l = ee("md"), i =
|
|
1542
|
+
const l = ee("md"), i = qt();
|
|
1542
1543
|
return /* @__PURE__ */ d(
|
|
1543
1544
|
u,
|
|
1544
1545
|
{
|
|
@@ -1624,7 +1625,7 @@ const cn = te(
|
|
|
1624
1625
|
}
|
|
1625
1626
|
);
|
|
1626
1627
|
}
|
|
1627
|
-
),
|
|
1628
|
+
), ar = (t, r) => {
|
|
1628
1629
|
const n = [];
|
|
1629
1630
|
if (r === 0)
|
|
1630
1631
|
return n.push(t), n;
|
|
@@ -1633,7 +1634,7 @@ const cn = te(
|
|
|
1633
1634
|
n.push(i);
|
|
1634
1635
|
}
|
|
1635
1636
|
return n;
|
|
1636
|
-
},
|
|
1637
|
+
}, sr = te(
|
|
1637
1638
|
({
|
|
1638
1639
|
value: t,
|
|
1639
1640
|
label: r,
|
|
@@ -1665,8 +1666,8 @@ const cn = te(
|
|
|
1665
1666
|
/* @__PURE__ */ e(we, { style: s, children: f() })
|
|
1666
1667
|
] });
|
|
1667
1668
|
}
|
|
1668
|
-
),
|
|
1669
|
-
|
|
1669
|
+
), dr = te(({ fields: t, separator: r, labelWidth: n }) => /* @__PURE__ */ e(wt, { children: t.map((l, i) => /* @__PURE__ */ e(
|
|
1670
|
+
sr,
|
|
1670
1671
|
{
|
|
1671
1672
|
separator: r,
|
|
1672
1673
|
labelWidth: n,
|
|
@@ -1674,7 +1675,7 @@ const cn = te(
|
|
|
1674
1675
|
...l
|
|
1675
1676
|
},
|
|
1676
1677
|
`field-group-field-${i}`
|
|
1677
|
-
)) })),
|
|
1678
|
+
)) })), dn = te(
|
|
1678
1679
|
({
|
|
1679
1680
|
maxRow: t = 0,
|
|
1680
1681
|
maxColumn: r = 2,
|
|
@@ -1684,7 +1685,7 @@ const cn = te(
|
|
|
1684
1685
|
bordered: o = !1
|
|
1685
1686
|
}) => {
|
|
1686
1687
|
const s = De(
|
|
1687
|
-
() =>
|
|
1688
|
+
() => ar(l, t),
|
|
1688
1689
|
[l, t]
|
|
1689
1690
|
), a = s.length > 2, h = () => {
|
|
1690
1691
|
switch (r) {
|
|
@@ -1720,7 +1721,7 @@ const cn = te(
|
|
|
1720
1721
|
width: a ? h() : void 0,
|
|
1721
1722
|
marginBottom: a ? "lg" : void 0,
|
|
1722
1723
|
children: /* @__PURE__ */ e(
|
|
1723
|
-
|
|
1724
|
+
dr,
|
|
1724
1725
|
{
|
|
1725
1726
|
labelWidth: i,
|
|
1726
1727
|
fields: f,
|
|
@@ -1733,7 +1734,7 @@ const cn = te(
|
|
|
1733
1734
|
}
|
|
1734
1735
|
);
|
|
1735
1736
|
}
|
|
1736
|
-
),
|
|
1737
|
+
), hn = ({
|
|
1737
1738
|
title: t,
|
|
1738
1739
|
content: r,
|
|
1739
1740
|
onHide: n,
|
|
@@ -1765,15 +1766,15 @@ const cn = te(
|
|
|
1765
1766
|
return /* @__PURE__ */ e(B, { primary: !0, onClick: l, children: o });
|
|
1766
1767
|
}
|
|
1767
1768
|
};
|
|
1768
|
-
return /* @__PURE__ */ d(
|
|
1769
|
+
return /* @__PURE__ */ d(Ue, { isShow: i, onHide: n, children: [
|
|
1769
1770
|
a(),
|
|
1770
|
-
/* @__PURE__ */ e(
|
|
1771
|
-
/* @__PURE__ */ e(
|
|
1771
|
+
/* @__PURE__ */ e(Pe, { children: /* @__PURE__ */ e(C, { children: r }) }),
|
|
1772
|
+
/* @__PURE__ */ e(nt, { children: /* @__PURE__ */ d(u, { justify: "flex-end", direction: "row", gap: "sm", children: [
|
|
1772
1773
|
/* @__PURE__ */ e(B, { secondary: !0, onClick: n, children: "Cancel" }),
|
|
1773
1774
|
h()
|
|
1774
1775
|
] }) })
|
|
1775
1776
|
] });
|
|
1776
|
-
},
|
|
1777
|
+
}, hr = ({ children: t, ...r }) => /* @__PURE__ */ e(
|
|
1777
1778
|
u,
|
|
1778
1779
|
{
|
|
1779
1780
|
role: "button",
|
|
@@ -1784,7 +1785,7 @@ const cn = te(
|
|
|
1784
1785
|
...r,
|
|
1785
1786
|
children: t
|
|
1786
1787
|
}
|
|
1787
|
-
), Vt = te(
|
|
1788
|
+
), Vt = te(hr), ur = ({ backButton: t }) => {
|
|
1788
1789
|
const [r, n] = A(!1), l = (t == null ? void 0 : t.iconColor) ?? "var(--sa-text-subtle, #8c8f97)", i = (t == null ? void 0 : t.textColor) ?? "var(--sa-text-subtle, #8c8f97)", o = (t == null ? void 0 : t.hoverIconColor) ?? "var(--sa-text-subtle, #8c8f97)", s = (t == null ? void 0 : t.hoverTextColor) ?? "var(--sa-text-primary, #292a2e)";
|
|
1789
1790
|
return /* @__PURE__ */ d(
|
|
1790
1791
|
u,
|
|
@@ -1822,7 +1823,7 @@ const cn = te(
|
|
|
1822
1823
|
]
|
|
1823
1824
|
}
|
|
1824
1825
|
);
|
|
1825
|
-
},
|
|
1826
|
+
}, fr = ({
|
|
1826
1827
|
backButton: t,
|
|
1827
1828
|
title: r,
|
|
1828
1829
|
titleTag: n,
|
|
@@ -1833,18 +1834,18 @@ const cn = te(
|
|
|
1833
1834
|
containerProps: a,
|
|
1834
1835
|
headerProps: h
|
|
1835
1836
|
}) => {
|
|
1836
|
-
const f = ee("lg"), g = ct(),
|
|
1837
|
+
const f = ee("lg"), g = ct(), p = ze(), y = t == null ? void 0 : t.show, b = () => {
|
|
1837
1838
|
if (typeof (t == null ? void 0 : t.onClick) == "function") {
|
|
1838
1839
|
t.onClick();
|
|
1839
1840
|
return;
|
|
1840
1841
|
}
|
|
1841
1842
|
g(-1, { replace: !0 });
|
|
1842
|
-
}, H = () => o ?
|
|
1843
|
-
({ title: j, icon:
|
|
1843
|
+
}, H = () => o ? rt(o) ? o : /* @__PURE__ */ e(u, { direction: "row", gap: "lg", children: o.map(
|
|
1844
|
+
({ title: j, icon: J, buttonProps: M, onClick: fe }, G) => !j && !J ? null : /* @__PURE__ */ e(
|
|
1844
1845
|
B,
|
|
1845
1846
|
{
|
|
1846
1847
|
fullWidth: !f,
|
|
1847
|
-
iconLeft:
|
|
1848
|
+
iconLeft: J ? /* @__PURE__ */ e(k, { name: J, size: "md" }) : void 0,
|
|
1848
1849
|
onClick: fe,
|
|
1849
1850
|
...M,
|
|
1850
1851
|
children: j
|
|
@@ -1852,7 +1853,7 @@ const cn = te(
|
|
|
1852
1853
|
`action-${G}`
|
|
1853
1854
|
)
|
|
1854
1855
|
) }) : null, D = () => {
|
|
1855
|
-
const j = /* @__PURE__ */ e(
|
|
1856
|
+
const j = /* @__PURE__ */ e(ur, { backButton: t });
|
|
1856
1857
|
return t != null && t.navigateTo ? /* @__PURE__ */ e(u, { direction: "row", children: /* @__PURE__ */ e(
|
|
1857
1858
|
Xt,
|
|
1858
1859
|
{
|
|
@@ -1862,9 +1863,9 @@ const cn = te(
|
|
|
1862
1863
|
children: j
|
|
1863
1864
|
}
|
|
1864
1865
|
) }) : /* @__PURE__ */ e(u, { direction: "row", children: /* @__PURE__ */ e(Vt, { onClick: b, children: j }) });
|
|
1865
|
-
},
|
|
1866
|
-
const j = !!r,
|
|
1867
|
-
return !j && !
|
|
1866
|
+
}, T = () => {
|
|
1867
|
+
const j = !!r, J = rt(o) ? !0 : Array.isArray(o) && o.length > 0;
|
|
1868
|
+
return !j && !J && !y ? null : /* @__PURE__ */ d(
|
|
1868
1869
|
u,
|
|
1869
1870
|
{
|
|
1870
1871
|
gap: "xs",
|
|
@@ -1872,8 +1873,8 @@ const cn = te(
|
|
|
1872
1873
|
paddingInline: h == null ? void 0 : h.paddingInline,
|
|
1873
1874
|
...h,
|
|
1874
1875
|
children: [
|
|
1875
|
-
|
|
1876
|
-
(j ||
|
|
1876
|
+
y && D(),
|
|
1877
|
+
(j || J) && /* @__PURE__ */ d(
|
|
1877
1878
|
u,
|
|
1878
1879
|
{
|
|
1879
1880
|
direction: f ? "row" : "column",
|
|
@@ -1905,28 +1906,28 @@ const cn = te(
|
|
|
1905
1906
|
animation: "pageLayoutEnter 320ms cubic-bezier(0.16, 1, 0.3, 1) backwards"
|
|
1906
1907
|
},
|
|
1907
1908
|
children: [
|
|
1908
|
-
i &&
|
|
1909
|
+
i && T(),
|
|
1909
1910
|
Z()
|
|
1910
1911
|
]
|
|
1911
1912
|
},
|
|
1912
|
-
|
|
1913
|
+
p.pathname
|
|
1913
1914
|
);
|
|
1914
|
-
},
|
|
1915
|
+
}, un = te(fr), gr = {
|
|
1915
1916
|
icon: "Cross",
|
|
1916
1917
|
title: ""
|
|
1917
|
-
},
|
|
1918
|
+
}, mr = "calc(100vw - 16px)", pt = (t) => t == null ? void 0 : `min(${typeof t == "number" ? `${t}px` : t}, ${mr})`, pr = Mt(
|
|
1918
1919
|
({
|
|
1919
1920
|
onHide: t,
|
|
1920
1921
|
show: r,
|
|
1921
1922
|
withBlur: n = !1,
|
|
1922
1923
|
style: l,
|
|
1923
1924
|
children: i,
|
|
1924
|
-
closeButton: o =
|
|
1925
|
+
closeButton: o = gr,
|
|
1925
1926
|
width: s,
|
|
1926
1927
|
minWidth: a = "357px",
|
|
1927
1928
|
maxWidth: h = "357px"
|
|
1928
1929
|
}, f) => {
|
|
1929
|
-
const g =
|
|
1930
|
+
const g = pt(s ?? a), p = pt(s ?? h);
|
|
1930
1931
|
return /* @__PURE__ */ e(
|
|
1931
1932
|
Ot,
|
|
1932
1933
|
{
|
|
@@ -1937,7 +1938,7 @@ const cn = te(
|
|
|
1937
1938
|
ref: f,
|
|
1938
1939
|
style: {
|
|
1939
1940
|
minWidth: g,
|
|
1940
|
-
maxWidth:
|
|
1941
|
+
maxWidth: p,
|
|
1941
1942
|
...l
|
|
1942
1943
|
},
|
|
1943
1944
|
children: /* @__PURE__ */ d(u, { padding: "lg", children: [
|
|
@@ -2013,7 +2014,7 @@ const cn = te(
|
|
|
2013
2014
|
children: t
|
|
2014
2015
|
}
|
|
2015
2016
|
)
|
|
2016
|
-
),
|
|
2017
|
+
), fn = te(
|
|
2017
2018
|
({
|
|
2018
2019
|
children: t,
|
|
2019
2020
|
title: r,
|
|
@@ -2026,11 +2027,11 @@ const cn = te(
|
|
|
2026
2027
|
bodyProps: h,
|
|
2027
2028
|
headerProps: f = { borderBottom: !0 },
|
|
2028
2029
|
footerProps: g = { borderTop: !0 },
|
|
2029
|
-
variantTag:
|
|
2030
|
+
variantTag: p = "info"
|
|
2030
2031
|
}) => {
|
|
2031
|
-
const
|
|
2032
|
+
const y = ee("lg"), b = () => n ? /* @__PURE__ */ d(u, { direction: "row", gap: "sm", align: "center", children: [
|
|
2032
2033
|
/* @__PURE__ */ e(C, { fontWeight: "medium", children: r }),
|
|
2033
|
-
/* @__PURE__ */ e(Ee, { border: !0, text: n, variant:
|
|
2034
|
+
/* @__PURE__ */ e(Ee, { border: !0, text: n, variant: p })
|
|
2034
2035
|
] }) : /* @__PURE__ */ e(C, { fontWeight: "medium", children: r }), H = () => i || /* @__PURE__ */ d(
|
|
2035
2036
|
u,
|
|
2036
2037
|
{
|
|
@@ -2043,7 +2044,7 @@ const cn = te(
|
|
|
2043
2044
|
/* @__PURE__ */ e(
|
|
2044
2045
|
u,
|
|
2045
2046
|
{
|
|
2046
|
-
style:
|
|
2047
|
+
style: y ? { width: "100%", maxWidth: "19.313rem" } : { flex: 1 },
|
|
2047
2048
|
...s,
|
|
2048
2049
|
children: l ?? null
|
|
2049
2050
|
}
|
|
@@ -2073,7 +2074,7 @@ const cn = te(
|
|
|
2073
2074
|
}
|
|
2074
2075
|
);
|
|
2075
2076
|
}
|
|
2076
|
-
),
|
|
2077
|
+
), xr = "var(--sa-color-secondary-50, #e6e9fb)", Cr = ({ children: t, onClick: r }) => {
|
|
2077
2078
|
const [n, l] = A("");
|
|
2078
2079
|
return /* @__PURE__ */ e(
|
|
2079
2080
|
Vt,
|
|
@@ -2088,14 +2089,14 @@ const cn = te(
|
|
|
2088
2089
|
gap: "spacing-1",
|
|
2089
2090
|
cursor: "pointer",
|
|
2090
2091
|
onClick: r,
|
|
2091
|
-
onMouseEnter: () => l(
|
|
2092
|
+
onMouseEnter: () => l(xr),
|
|
2092
2093
|
borderRadius: "rounded-md",
|
|
2093
2094
|
onMouseLeave: () => l(""),
|
|
2094
2095
|
style: { backgroundColor: n },
|
|
2095
2096
|
children: t
|
|
2096
2097
|
}
|
|
2097
2098
|
);
|
|
2098
|
-
},
|
|
2099
|
+
}, Dr = te(Cr), br = ({
|
|
2099
2100
|
icon: t,
|
|
2100
2101
|
items: r = [],
|
|
2101
2102
|
style: n,
|
|
@@ -2115,8 +2116,8 @@ const cn = te(
|
|
|
2115
2116
|
[i]
|
|
2116
2117
|
);
|
|
2117
2118
|
return /* @__PURE__ */ d(Dt, { position: o, style: n, children: [
|
|
2118
|
-
/* @__PURE__ */ e(
|
|
2119
|
-
/* @__PURE__ */ e(bt, { style: f, children: r.map((g,
|
|
2119
|
+
/* @__PURE__ */ e($e, { style: l, children: /* @__PURE__ */ e(B, { size: "sm", secondary: !0, ...s, children: /* @__PURE__ */ e(k, { name: t, ...a }) }) }),
|
|
2120
|
+
/* @__PURE__ */ e(bt, { style: f, children: r.map((g, p) => h === "outline-button" ? /* @__PURE__ */ e(vt, { children: /* @__PURE__ */ d(
|
|
2120
2121
|
B,
|
|
2121
2122
|
{
|
|
2122
2123
|
size: "sm",
|
|
@@ -2129,8 +2130,8 @@ const cn = te(
|
|
|
2129
2130
|
/* @__PURE__ */ e(C, { fontSize: "sm", color: "text", ...g.textProps, children: g.label })
|
|
2130
2131
|
]
|
|
2131
2132
|
}
|
|
2132
|
-
) }, g.id ||
|
|
2133
|
-
|
|
2133
|
+
) }, g.id || p) : /* @__PURE__ */ d(
|
|
2134
|
+
Dr,
|
|
2134
2135
|
{
|
|
2135
2136
|
onClick: g.onClick,
|
|
2136
2137
|
...g.buttonProps,
|
|
@@ -2139,30 +2140,30 @@ const cn = te(
|
|
|
2139
2140
|
/* @__PURE__ */ e(C, { fontSize: "sm", color: "text", ...g.textProps, children: g.label })
|
|
2140
2141
|
]
|
|
2141
2142
|
},
|
|
2142
|
-
g.id ||
|
|
2143
|
+
g.id || p
|
|
2143
2144
|
)) })
|
|
2144
2145
|
] });
|
|
2145
|
-
},
|
|
2146
|
-
H1:
|
|
2147
|
-
H2:
|
|
2148
|
-
H3:
|
|
2149
|
-
H4:
|
|
2150
|
-
H5:
|
|
2151
|
-
H6:
|
|
2152
|
-
SubH1:
|
|
2153
|
-
SubH2:
|
|
2154
|
-
SubH3:
|
|
2155
|
-
Body1:
|
|
2156
|
-
Body2:
|
|
2157
|
-
Body3:
|
|
2146
|
+
}, gn = te(br), vr = (t) => /* @__PURE__ */ e(C, { variant: "h1", children: t.children, ...t.props }), wr = (t) => /* @__PURE__ */ e(C, { variant: "h2", children: t.children, ...t.props }), kr = (t) => /* @__PURE__ */ e(C, { variant: "h3", children: t.children, ...t.props }), Fr = (t) => /* @__PURE__ */ e(C, { variant: "h4", children: t.children, ...t.props }), Sr = (t) => /* @__PURE__ */ e(C, { variant: "h5", children: t.children, ...t.props }), Er = (t) => /* @__PURE__ */ e(C, { variant: "h6", children: t.children, ...t.props }), Mr = (t) => /* @__PURE__ */ e(C, { variant: "sub-h1", children: t.children, ...t.props }), Lr = (t) => /* @__PURE__ */ e(C, { variant: "sub-h2", children: t.children, ...t.props }), Wr = (t) => /* @__PURE__ */ e(C, { variant: "sub-h3", children: t.children, ...t.props }), Br = (t) => /* @__PURE__ */ e(C, { variant: "body-1", children: t.children, ...t.props }), Ar = (t) => /* @__PURE__ */ e(C, { variant: "body-2", children: t.children, ...t.props }), Rr = (t) => /* @__PURE__ */ e(C, { variant: "body-3", children: t.children, ...t.props }), me = {
|
|
2147
|
+
H1: vr,
|
|
2148
|
+
H2: wr,
|
|
2149
|
+
H3: kr,
|
|
2150
|
+
H4: Fr,
|
|
2151
|
+
H5: Sr,
|
|
2152
|
+
H6: Er,
|
|
2153
|
+
SubH1: Mr,
|
|
2154
|
+
SubH2: Lr,
|
|
2155
|
+
SubH3: Wr,
|
|
2156
|
+
Body1: Br,
|
|
2157
|
+
Body2: Ar,
|
|
2158
|
+
Body3: Rr
|
|
2158
2159
|
}, at = () => {
|
|
2159
|
-
const [t, r] =
|
|
2160
|
+
const [t, r] = Je(), n = qe(t.toString()), l = Lt(), i = ze(), o = l.id;
|
|
2160
2161
|
return {
|
|
2161
2162
|
// query params
|
|
2162
2163
|
setSearchParams: r,
|
|
2163
2164
|
searchParams: t,
|
|
2164
2165
|
searchQueries: n,
|
|
2165
|
-
isHasQuery: (g,
|
|
2166
|
+
isHasQuery: (g, p) => t.has(g) && t.get(g) === p,
|
|
2166
2167
|
getQueryParam: (g) => t.get(g),
|
|
2167
2168
|
// route params
|
|
2168
2169
|
getRouteParam: (g) => l[g],
|
|
@@ -2173,7 +2174,7 @@ const cn = te(
|
|
|
2173
2174
|
id: o,
|
|
2174
2175
|
hasId: !!o
|
|
2175
2176
|
};
|
|
2176
|
-
},
|
|
2177
|
+
}, Hr = (t) => JSON.stringify(t), Vr = (t) => JSON.stringify(t), zr = (t) => JSON.stringify(t), Ir = (t) => JSON.stringify(t), Tr = (t) => t, Or = (t) => JSON.stringify(t), yt = ({
|
|
2177
2178
|
value: t,
|
|
2178
2179
|
name: r,
|
|
2179
2180
|
type: n,
|
|
@@ -2188,37 +2189,37 @@ const cn = te(
|
|
|
2188
2189
|
let f;
|
|
2189
2190
|
switch (n) {
|
|
2190
2191
|
case "search":
|
|
2191
|
-
f =
|
|
2192
|
+
f = Tr(t);
|
|
2192
2193
|
break;
|
|
2193
2194
|
case "dropdown":
|
|
2194
2195
|
case "dropdown-multiple":
|
|
2195
|
-
f =
|
|
2196
|
+
f = Hr(t);
|
|
2196
2197
|
break;
|
|
2197
2198
|
case "radio":
|
|
2198
|
-
f =
|
|
2199
|
+
f = Vr(t);
|
|
2199
2200
|
break;
|
|
2200
2201
|
case "date-range":
|
|
2201
|
-
f =
|
|
2202
|
+
f = zr(t);
|
|
2202
2203
|
break;
|
|
2203
2204
|
case "advanced-date-range":
|
|
2204
|
-
f =
|
|
2205
|
+
f = Or(t);
|
|
2205
2206
|
break;
|
|
2206
2207
|
case "date":
|
|
2207
|
-
f =
|
|
2208
|
+
f = Ir(t);
|
|
2208
2209
|
break;
|
|
2209
2210
|
default:
|
|
2210
2211
|
f = t;
|
|
2211
2212
|
break;
|
|
2212
2213
|
}
|
|
2213
2214
|
if (typeof f < "u") {
|
|
2214
|
-
const
|
|
2215
|
+
const p = {
|
|
2215
2216
|
...o[a] && typeof o[a] == "string" ? JSON.parse(o[a]) : void 0,
|
|
2216
2217
|
[r]: f
|
|
2217
|
-
},
|
|
2218
|
-
s && typeof s == "string" && delete
|
|
2218
|
+
}, y = { ...o };
|
|
2219
|
+
s && typeof s == "string" && delete y[s], delete y[h];
|
|
2219
2220
|
const b = {
|
|
2220
|
-
...
|
|
2221
|
-
[a]: JSON.stringify(
|
|
2221
|
+
...y,
|
|
2222
|
+
[a]: JSON.stringify(p)
|
|
2222
2223
|
}, H = new URLSearchParams(o).toString(), D = new URLSearchParams(
|
|
2223
2224
|
b
|
|
2224
2225
|
).toString();
|
|
@@ -2227,7 +2228,7 @@ const cn = te(
|
|
|
2227
2228
|
i(b);
|
|
2228
2229
|
}
|
|
2229
2230
|
}
|
|
2230
|
-
},
|
|
2231
|
+
}, Xe = ({
|
|
2231
2232
|
name: t,
|
|
2232
2233
|
filterKey: r = "filter",
|
|
2233
2234
|
searchParams: n,
|
|
@@ -2235,7 +2236,7 @@ const cn = te(
|
|
|
2235
2236
|
}) => {
|
|
2236
2237
|
const i = n.get(r) || void 0, o = i && typeof i == "string" ? JSON.parse(i) : void 0, s = o ? o[t] : void 0;
|
|
2237
2238
|
return l === "label" && s ? JSON.parse(s)[0].label : l === "value" && s ? JSON.parse(s)[0].value : s;
|
|
2238
|
-
},
|
|
2239
|
+
}, mn = ({
|
|
2239
2240
|
name: t,
|
|
2240
2241
|
filterKey: r = "filter",
|
|
2241
2242
|
searchParams: n,
|
|
@@ -2243,7 +2244,7 @@ const cn = te(
|
|
|
2243
2244
|
}) => {
|
|
2244
2245
|
const i = n.get(r) || void 0, o = i && typeof i == "string" ? JSON.parse(i) : void 0, s = o ? o[t] : void 0;
|
|
2245
2246
|
return l === "label" && s ? JSON.parse(s).map((a) => a.label) : l === "value" && s ? JSON.parse(s).map((a) => a.value) : l === "array" && s ? JSON.parse(s) : s;
|
|
2246
|
-
},
|
|
2247
|
+
}, pn = ({
|
|
2247
2248
|
name: t,
|
|
2248
2249
|
filterKey: r = "filter",
|
|
2249
2250
|
searchParams: n,
|
|
@@ -2251,10 +2252,10 @@ const cn = te(
|
|
|
2251
2252
|
}) => {
|
|
2252
2253
|
const i = n.get(r) || void 0, o = i && typeof i == "string" ? JSON.parse(i) : void 0, s = o ? o[t] : void 0;
|
|
2253
2254
|
return l === "id" && s ? JSON.parse(s).id : l === "label" && s ? JSON.parse(s).label : l === "value" && s ? JSON.parse(s).value : s;
|
|
2254
|
-
},
|
|
2255
|
+
}, Nr = (t, r, n) => {
|
|
2255
2256
|
const l = r.get(n || "filter") || void 0, i = l && typeof l == "string" ? JSON.parse(l) : void 0;
|
|
2256
2257
|
return i ? i[t] : void 0;
|
|
2257
|
-
},
|
|
2258
|
+
}, yn = ({
|
|
2258
2259
|
name: t,
|
|
2259
2260
|
filterKey: r = "filter",
|
|
2260
2261
|
searchParams: n
|
|
@@ -2264,21 +2265,21 @@ const cn = te(
|
|
|
2264
2265
|
start: o ? JSON.parse(o).from : void 0,
|
|
2265
2266
|
end: o ? JSON.parse(o).to : void 0
|
|
2266
2267
|
};
|
|
2267
|
-
},
|
|
2268
|
+
}, xn = ({
|
|
2268
2269
|
name: t,
|
|
2269
2270
|
filterKey: r = "filter",
|
|
2270
2271
|
searchParams: n
|
|
2271
2272
|
}) => {
|
|
2272
2273
|
const l = n.get(r || "filter") || void 0, i = l && typeof l == "string" ? JSON.parse(l) : void 0, o = i ? i[t] : void 0;
|
|
2273
2274
|
return o ? JSON.parse(o) : void 0;
|
|
2274
|
-
},
|
|
2275
|
+
}, Cn = (t, {
|
|
2275
2276
|
filterKey: r = "filter",
|
|
2276
2277
|
perPageKey: n = "perPage",
|
|
2277
2278
|
pageKey: l = "page"
|
|
2278
2279
|
}) => {
|
|
2279
2280
|
const i = t.get(r) || void 0, o = t.get(n) || void 0, s = t.get(l) || void 0;
|
|
2280
2281
|
return !!i || !!o || !!s;
|
|
2281
|
-
},
|
|
2282
|
+
}, Zr = ({
|
|
2282
2283
|
isOpen: t,
|
|
2283
2284
|
onClose: r,
|
|
2284
2285
|
filterKey: n,
|
|
@@ -2287,29 +2288,29 @@ const cn = te(
|
|
|
2287
2288
|
}) => {
|
|
2288
2289
|
const { searchParams: o, setSearchParams: s, searchQueries: a } = at(), [h, f] = A({}), g = () => {
|
|
2289
2290
|
o.delete(n || "filter"), s(o);
|
|
2290
|
-
},
|
|
2291
|
-
switch (
|
|
2291
|
+
}, p = (y, b) => {
|
|
2292
|
+
switch (y.type) {
|
|
2292
2293
|
case "radio": {
|
|
2293
|
-
const { show: H = !0 } =
|
|
2294
|
-
return H && /* @__PURE__ */ e(u, { children: /* @__PURE__ */ e(u, { children:
|
|
2294
|
+
const { show: H = !0 } = y;
|
|
2295
|
+
return H && /* @__PURE__ */ e(u, { children: /* @__PURE__ */ e(u, { children: y.title }) }, b);
|
|
2295
2296
|
}
|
|
2296
2297
|
case "dropdown": {
|
|
2297
|
-
const { show: H = !0 } =
|
|
2298
|
-
return H && /* @__PURE__ */ e(u, { children: /* @__PURE__ */ e(u, { children:
|
|
2298
|
+
const { show: H = !0 } = y;
|
|
2299
|
+
return H && /* @__PURE__ */ e(u, { children: /* @__PURE__ */ e(u, { children: y.title }) }, b);
|
|
2299
2300
|
}
|
|
2300
2301
|
case "date-range":
|
|
2301
|
-
return /* @__PURE__ */ e(u, { children: /* @__PURE__ */ e(u, { children:
|
|
2302
|
+
return /* @__PURE__ */ e(u, { children: /* @__PURE__ */ e(u, { children: y.title }) }, b);
|
|
2302
2303
|
case "date":
|
|
2303
|
-
return /* @__PURE__ */ e(u, { children: /* @__PURE__ */ e(u, { children:
|
|
2304
|
+
return /* @__PURE__ */ e(u, { children: /* @__PURE__ */ e(u, { children: y.title }) }, b);
|
|
2304
2305
|
case "dropdown-multiple": {
|
|
2305
|
-
const { show: H = !0 } =
|
|
2306
|
-
return H && /* @__PURE__ */ e(u, { children: /* @__PURE__ */ e(u, { children:
|
|
2306
|
+
const { show: H = !0 } = y;
|
|
2307
|
+
return H && /* @__PURE__ */ e(u, { children: /* @__PURE__ */ e(u, { children: y.title }) }, b);
|
|
2307
2308
|
}
|
|
2308
2309
|
default:
|
|
2309
2310
|
return null;
|
|
2310
2311
|
}
|
|
2311
2312
|
};
|
|
2312
|
-
return /* @__PURE__ */ e(
|
|
2313
|
+
return /* @__PURE__ */ e(pr, { onHide: r, show: t || !1, children: /* @__PURE__ */ d(u, { direction: "column", gap: "md", children: [
|
|
2313
2314
|
/* @__PURE__ */ d($, { direction: "row", justify: "space-between", align: "center", children: [
|
|
2314
2315
|
/* @__PURE__ */ e(u, { children: "Filter" }),
|
|
2315
2316
|
/* @__PURE__ */ e(
|
|
@@ -2321,9 +2322,9 @@ const cn = te(
|
|
|
2321
2322
|
}
|
|
2322
2323
|
)
|
|
2323
2324
|
] }),
|
|
2324
|
-
i == null ? void 0 : i.map((
|
|
2325
|
+
i == null ? void 0 : i.map((y, b) => p(y, b))
|
|
2325
2326
|
] }) });
|
|
2326
|
-
},
|
|
2327
|
+
}, jr = ({
|
|
2327
2328
|
searchKey: t = "q",
|
|
2328
2329
|
statusKey: r = "status",
|
|
2329
2330
|
searchPlaceholder: n = "Search",
|
|
@@ -2335,31 +2336,31 @@ const cn = te(
|
|
|
2335
2336
|
pageKey: h = "page",
|
|
2336
2337
|
customWidthSearch: f,
|
|
2337
2338
|
handleOnReset: g,
|
|
2338
|
-
filterConfigs:
|
|
2339
|
-
buttonToggleProps:
|
|
2339
|
+
filterConfigs: p,
|
|
2340
|
+
buttonToggleProps: y,
|
|
2340
2341
|
position: b = "right",
|
|
2341
2342
|
titleSearchLabel: H = "Work Order",
|
|
2342
2343
|
withTitleLabels: D = !1
|
|
2343
2344
|
}) => {
|
|
2344
|
-
const Z = (
|
|
2345
|
-
fe((
|
|
2346
|
-
}, { searchParams: V, setSearchParams: K, getQueryParam: oe } = at(), ce =
|
|
2345
|
+
const Z = (y == null ? void 0 : y.isShowLabel) ?? !0, [j, J] = A(!1), [M, fe] = A(0), G = () => {
|
|
2346
|
+
fe((I) => I + 1);
|
|
2347
|
+
}, { searchParams: V, setSearchParams: K, getQueryParam: oe } = at(), ce = qe(V.toString()), _ = Nr(t, V, a) || "", [ae, se] = A(_), re = oe(a), q = !!(re && !(() => {
|
|
2347
2348
|
if (re)
|
|
2348
2349
|
try {
|
|
2349
|
-
const
|
|
2350
|
-
return Object.keys(
|
|
2351
|
-
} catch (
|
|
2352
|
-
console.error("Filter parameter is not a valid JSON:",
|
|
2350
|
+
const I = JSON.parse(re);
|
|
2351
|
+
return Object.keys(I).length === 1 && I[t] === "";
|
|
2352
|
+
} catch (I) {
|
|
2353
|
+
console.error("Filter parameter is not a valid JSON:", I);
|
|
2353
2354
|
}
|
|
2354
2355
|
return !1;
|
|
2355
|
-
})()),
|
|
2356
|
+
})()), z = ee("md");
|
|
2356
2357
|
return U(() => {
|
|
2357
2358
|
se(_);
|
|
2358
2359
|
}, [_]), U(() => {
|
|
2359
2360
|
if (ae === _)
|
|
2360
2361
|
return;
|
|
2361
|
-
const
|
|
2362
|
-
|
|
2362
|
+
const I = window.setTimeout(() => {
|
|
2363
|
+
yt({
|
|
2363
2364
|
value: ae,
|
|
2364
2365
|
name: t,
|
|
2365
2366
|
type: "search",
|
|
@@ -2370,7 +2371,7 @@ const cn = te(
|
|
|
2370
2371
|
});
|
|
2371
2372
|
}, 350);
|
|
2372
2373
|
return () => {
|
|
2373
|
-
window.clearTimeout(
|
|
2374
|
+
window.clearTimeout(I);
|
|
2374
2375
|
};
|
|
2375
2376
|
}, [
|
|
2376
2377
|
ae,
|
|
@@ -2385,29 +2386,29 @@ const cn = te(
|
|
|
2385
2386
|
{
|
|
2386
2387
|
gap: "md",
|
|
2387
2388
|
style: {
|
|
2388
|
-
flexDirection:
|
|
2389
|
+
flexDirection: z && b === "left" ? "row" : z && b === "right" ? "row-reverse" : "column"
|
|
2389
2390
|
},
|
|
2390
2391
|
align: "flex-end",
|
|
2391
2392
|
children: [
|
|
2392
|
-
|
|
2393
|
+
q && /* @__PURE__ */ e(u, { justify: "flex-end", children: /* @__PURE__ */ e(
|
|
2393
2394
|
B,
|
|
2394
2395
|
{
|
|
2395
2396
|
onClick: () => {
|
|
2396
|
-
const
|
|
2397
|
-
|
|
2397
|
+
const I = new URLSearchParams(V);
|
|
2398
|
+
I.delete(a), K(I), se(""), G(), g && g();
|
|
2398
2399
|
},
|
|
2399
2400
|
variant: "outline",
|
|
2400
2401
|
tone: "neutral",
|
|
2401
2402
|
children: /* @__PURE__ */ e(C, { color: "error", fontWeight: "semibold", children: "Reset" })
|
|
2402
2403
|
}
|
|
2403
2404
|
) }),
|
|
2404
|
-
i == null ? void 0 : i.map(({ minWidth:
|
|
2405
|
+
i == null ? void 0 : i.map(({ minWidth: I, content: Y, title: de, onClickContainer: he }, Me) => /* @__PURE__ */ d(
|
|
2405
2406
|
u,
|
|
2406
2407
|
{
|
|
2407
2408
|
gap: "sm",
|
|
2408
2409
|
onClick: he,
|
|
2409
2410
|
style: {
|
|
2410
|
-
minWidth:
|
|
2411
|
+
minWidth: I
|
|
2411
2412
|
},
|
|
2412
2413
|
children: [
|
|
2413
2414
|
de && /* @__PURE__ */ e(me.SubH3, { children: de }),
|
|
@@ -2416,23 +2417,23 @@ const cn = te(
|
|
|
2416
2417
|
},
|
|
2417
2418
|
`extended-filter-${Me}-${M}`
|
|
2418
2419
|
)),
|
|
2419
|
-
!!(
|
|
2420
|
+
!!(p != null && p.length) && /* @__PURE__ */ e(
|
|
2420
2421
|
B,
|
|
2421
2422
|
{
|
|
2422
|
-
primary:
|
|
2423
|
-
secondary: !
|
|
2423
|
+
primary: q,
|
|
2424
|
+
secondary: !q,
|
|
2424
2425
|
iconLeft: /* @__PURE__ */ e(
|
|
2425
2426
|
k,
|
|
2426
2427
|
{
|
|
2427
2428
|
size: "sm",
|
|
2428
|
-
name: (
|
|
2429
|
+
name: (y == null ? void 0 : y.icon) || "FilterHorizontal",
|
|
2429
2430
|
style: {
|
|
2430
2431
|
color: re ? "var(--sa-background-brand, #04254f)" : "var(--sa-text-primary, #292a2e)"
|
|
2431
2432
|
}
|
|
2432
2433
|
}
|
|
2433
2434
|
),
|
|
2434
|
-
fullWidth: !
|
|
2435
|
-
onClick: () =>
|
|
2435
|
+
fullWidth: !z,
|
|
2436
|
+
onClick: () => J(!0),
|
|
2436
2437
|
children: Z ? "Filter" : void 0
|
|
2437
2438
|
}
|
|
2438
2439
|
),
|
|
@@ -2458,20 +2459,20 @@ const cn = te(
|
|
|
2458
2459
|
value: "inactive"
|
|
2459
2460
|
}
|
|
2460
2461
|
],
|
|
2461
|
-
defaultValue:
|
|
2462
|
+
defaultValue: Xe({
|
|
2462
2463
|
get: "value",
|
|
2463
2464
|
name: r,
|
|
2464
2465
|
searchParams: V,
|
|
2465
2466
|
filterKey: a
|
|
2466
2467
|
}) ? [
|
|
2467
2468
|
{
|
|
2468
|
-
label:
|
|
2469
|
+
label: Xe({
|
|
2469
2470
|
get: "value",
|
|
2470
2471
|
name: r,
|
|
2471
2472
|
searchParams: V,
|
|
2472
2473
|
filterKey: a
|
|
2473
2474
|
}) === "active" ? "Active" : "InActive",
|
|
2474
|
-
value:
|
|
2475
|
+
value: Xe({
|
|
2475
2476
|
get: "value",
|
|
2476
2477
|
name: r,
|
|
2477
2478
|
searchParams: V,
|
|
@@ -2479,8 +2480,8 @@ const cn = te(
|
|
|
2479
2480
|
})
|
|
2480
2481
|
}
|
|
2481
2482
|
] : [],
|
|
2482
|
-
onChange: (
|
|
2483
|
-
value:
|
|
2483
|
+
onChange: (I) => yt({
|
|
2484
|
+
value: I,
|
|
2484
2485
|
name: r,
|
|
2485
2486
|
type: "dropdown",
|
|
2486
2487
|
searchQueries: ce,
|
|
@@ -2499,7 +2500,7 @@ const cn = te(
|
|
|
2499
2500
|
{
|
|
2500
2501
|
gap: "sm",
|
|
2501
2502
|
style: {
|
|
2502
|
-
width: f &&
|
|
2503
|
+
width: f && z ? f : z ? "310px" : ""
|
|
2503
2504
|
},
|
|
2504
2505
|
children: [
|
|
2505
2506
|
D && /* @__PURE__ */ d(me.SubH3, { children: [
|
|
@@ -2511,7 +2512,7 @@ const cn = te(
|
|
|
2511
2512
|
{
|
|
2512
2513
|
placeholder: n,
|
|
2513
2514
|
leftIcon: /* @__PURE__ */ e(k, { name: "Search", width: 20, height: 20 }),
|
|
2514
|
-
onChange: (
|
|
2515
|
+
onChange: (I) => se(I.target.value),
|
|
2515
2516
|
value: ae,
|
|
2516
2517
|
fullWidth: !0
|
|
2517
2518
|
},
|
|
@@ -2521,19 +2522,19 @@ const cn = te(
|
|
|
2521
2522
|
}
|
|
2522
2523
|
),
|
|
2523
2524
|
/* @__PURE__ */ e(
|
|
2524
|
-
|
|
2525
|
+
Zr,
|
|
2525
2526
|
{
|
|
2526
2527
|
isOpen: j,
|
|
2527
|
-
onClose: () =>
|
|
2528
|
+
onClose: () => J(!1),
|
|
2528
2529
|
filterKey: a,
|
|
2529
|
-
filters:
|
|
2530
|
+
filters: p,
|
|
2530
2531
|
pageKey: h
|
|
2531
2532
|
}
|
|
2532
2533
|
)
|
|
2533
2534
|
]
|
|
2534
2535
|
}
|
|
2535
2536
|
);
|
|
2536
|
-
},
|
|
2537
|
+
}, $r = ({ children: t, borderRadius: r, height: n }) => {
|
|
2537
2538
|
const l = le(null), [i, o] = A("100vh");
|
|
2538
2539
|
return U(() => {
|
|
2539
2540
|
if (n) return;
|
|
@@ -2561,33 +2562,34 @@ const cn = te(
|
|
|
2561
2562
|
children: t
|
|
2562
2563
|
}
|
|
2563
2564
|
);
|
|
2564
|
-
},
|
|
2565
|
+
}, _r = ({
|
|
2565
2566
|
action: t,
|
|
2566
2567
|
rightContent: r,
|
|
2567
|
-
|
|
2568
|
-
|
|
2568
|
+
leftContent: n,
|
|
2569
|
+
advanceFilter: l,
|
|
2570
|
+
showFilter: i = !0
|
|
2569
2571
|
}) => {
|
|
2570
|
-
const
|
|
2572
|
+
const o = ee("md"), s = () => t ? rt(t) ? t : /* @__PURE__ */ e(
|
|
2571
2573
|
u,
|
|
2572
2574
|
{
|
|
2573
2575
|
style: {
|
|
2574
2576
|
display: "flex",
|
|
2575
|
-
flexDirection:
|
|
2577
|
+
flexDirection: o ? "row" : "column",
|
|
2576
2578
|
gap: "8px",
|
|
2577
|
-
width:
|
|
2579
|
+
width: o ? "auto" : "100%",
|
|
2578
2580
|
textWrap: "nowrap"
|
|
2579
2581
|
},
|
|
2580
2582
|
children: t.map(
|
|
2581
|
-
({ title:
|
|
2583
|
+
({ title: a, icon: h, buttonProps: f, onClick: g }, p) => !a && !h ? null : /* @__PURE__ */ e(
|
|
2582
2584
|
B,
|
|
2583
2585
|
{
|
|
2584
|
-
fullWidth: !
|
|
2585
|
-
iconLeft:
|
|
2586
|
-
onClick:
|
|
2587
|
-
...
|
|
2588
|
-
children:
|
|
2586
|
+
fullWidth: !o,
|
|
2587
|
+
iconLeft: h ? /* @__PURE__ */ e(k, { name: h }) : void 0,
|
|
2588
|
+
onClick: g,
|
|
2589
|
+
...f,
|
|
2590
|
+
children: a
|
|
2589
2591
|
},
|
|
2590
|
-
`action-${
|
|
2592
|
+
`action-${p}`
|
|
2591
2593
|
)
|
|
2592
2594
|
)
|
|
2593
2595
|
}
|
|
@@ -2608,19 +2610,22 @@ const cn = te(
|
|
|
2608
2610
|
flexShrink: 0,
|
|
2609
2611
|
position: "relative",
|
|
2610
2612
|
zIndex: 10,
|
|
2611
|
-
flexDirection:
|
|
2613
|
+
flexDirection: o ? "row" : "column-reverse",
|
|
2612
2614
|
gap: "16px"
|
|
2613
2615
|
},
|
|
2614
2616
|
children: [
|
|
2615
|
-
|
|
2616
|
-
|
|
2617
|
+
/* @__PURE__ */ d(u, { style: { display: "flex", gap: "8px", flexDirection: "row", alignItems: "center", flex: 1, minWidth: 0 }, children: [
|
|
2618
|
+
i && /* @__PURE__ */ e(jr, { ...l }),
|
|
2619
|
+
n
|
|
2620
|
+
] }),
|
|
2621
|
+
/* @__PURE__ */ d(u, { style: { display: "flex", gap: "8px", flexDirection: "row", alignItems: "center", flexShrink: 0 }, children: [
|
|
2617
2622
|
r,
|
|
2618
|
-
|
|
2623
|
+
s()
|
|
2619
2624
|
] })
|
|
2620
2625
|
]
|
|
2621
2626
|
}
|
|
2622
2627
|
);
|
|
2623
|
-
},
|
|
2628
|
+
}, Ur = ({
|
|
2624
2629
|
totalData: t,
|
|
2625
2630
|
withMarginBottom: r = !0,
|
|
2626
2631
|
withMarginTop: n = !0
|
|
@@ -2651,7 +2656,7 @@ const cn = te(
|
|
|
2651
2656
|
/* @__PURE__ */ e(me.Body1, { children: t || 0 })
|
|
2652
2657
|
]
|
|
2653
2658
|
}
|
|
2654
|
-
),
|
|
2659
|
+
), Pr = ({
|
|
2655
2660
|
pagination: t,
|
|
2656
2661
|
pageKey: r = "page",
|
|
2657
2662
|
perPageKey: n = "perPage",
|
|
@@ -2661,13 +2666,13 @@ const cn = te(
|
|
|
2661
2666
|
}) => {
|
|
2662
2667
|
const { searchQueries: s, setSearchParams: a, searchParams: h } = at(), f = h.get(n), g = (H) => {
|
|
2663
2668
|
a({ ...s, [r]: String(H) });
|
|
2664
|
-
},
|
|
2669
|
+
}, p = (H) => {
|
|
2665
2670
|
a({
|
|
2666
2671
|
...s,
|
|
2667
2672
|
[n]: H,
|
|
2668
2673
|
[r]: "1"
|
|
2669
2674
|
});
|
|
2670
|
-
},
|
|
2675
|
+
}, y = (t == null ? void 0 : t.rangeStart) ?? (((t == null ? void 0 : t.currentPage) || 0) > 1 ? (((t == null ? void 0 : t.currentPage) || 0) - 1) * ((t == null ? void 0 : t.perPage) || 0) + 1 : 1), b = (t == null ? void 0 : t.rangeEnd) ?? ((t == null ? void 0 : t.totalCurrentPage) !== (t == null ? void 0 : t.perPage) ? t == null ? void 0 : t.totalData : ((t == null ? void 0 : t.currentPage) || 1) * ((t == null ? void 0 : t.totalCurrentPage) || 0));
|
|
2671
2676
|
return /* @__PURE__ */ e(
|
|
2672
2677
|
u,
|
|
2673
2678
|
{
|
|
@@ -2698,13 +2703,13 @@ const cn = te(
|
|
|
2698
2703
|
{ label: "100", value: "100" }
|
|
2699
2704
|
],
|
|
2700
2705
|
onChange: (H) => {
|
|
2701
|
-
|
|
2706
|
+
p(H[0].value);
|
|
2702
2707
|
},
|
|
2703
2708
|
value: f ? [{ label: `${f} per row`, value: f }] : [{ label: `${l} per row`, value: `${l}` }],
|
|
2704
2709
|
defaultValue: f ? [{ label: `${f} per row`, value: f }] : [{ label: `${l} per row`, value: `${l}` }]
|
|
2705
2710
|
}
|
|
2706
2711
|
),
|
|
2707
|
-
/* @__PURE__ */ e(C, { children: `${
|
|
2712
|
+
/* @__PURE__ */ e(C, { children: `${y}-${b} of ${(t == null ? void 0 : t.totalData) || 0}` })
|
|
2708
2713
|
] }),
|
|
2709
2714
|
/* @__PURE__ */ e(
|
|
2710
2715
|
jt,
|
|
@@ -2715,7 +2720,7 @@ const cn = te(
|
|
|
2715
2720
|
}
|
|
2716
2721
|
)
|
|
2717
2722
|
] }) : /* @__PURE__ */ e(
|
|
2718
|
-
|
|
2723
|
+
Ur,
|
|
2719
2724
|
{
|
|
2720
2725
|
totalData: o,
|
|
2721
2726
|
withMarginBottom: !1,
|
|
@@ -2725,15 +2730,15 @@ const cn = te(
|
|
|
2725
2730
|
}
|
|
2726
2731
|
);
|
|
2727
2732
|
}, qr = ({ filter: t, columnTitle: r }) => {
|
|
2728
|
-
const [n, l] = A(!1), i = le(null), o = le(null), s = le(null), [a, h] = A(""), [f, g] = A({ top: 0, left: 0 }),
|
|
2733
|
+
const [n, l] = A(!1), i = le(null), o = le(null), s = le(null), [a, h] = A(""), [f, g] = A({ top: 0, left: 0 }), p = t.selectedValues, y = De(() => a ? t.options.filter(
|
|
2729
2734
|
(D) => D.label.toLowerCase().includes(a.toLowerCase())
|
|
2730
2735
|
) : t.options, [t.options, a]);
|
|
2731
2736
|
U(() => {
|
|
2732
2737
|
if (n && o.current) {
|
|
2733
|
-
const D = o.current.getBoundingClientRect(),
|
|
2738
|
+
const D = o.current.getBoundingClientRect(), T = 280, Z = {
|
|
2734
2739
|
top: D.bottom + 8
|
|
2735
2740
|
};
|
|
2736
|
-
t.position === "left" || D.left +
|
|
2741
|
+
t.position === "left" || D.left + T > window.innerWidth ? Z.right = window.innerWidth - D.right : Z.left = D.left, g(Z);
|
|
2737
2742
|
}
|
|
2738
2743
|
}, [n, t.position]), U(() => {
|
|
2739
2744
|
n && s.current ? setTimeout(() => {
|
|
@@ -2741,14 +2746,14 @@ const cn = te(
|
|
|
2741
2746
|
return (D = s.current) == null ? void 0 : D.focus();
|
|
2742
2747
|
}, 50) : h("");
|
|
2743
2748
|
}, [n]), U(() => {
|
|
2744
|
-
const D = (
|
|
2745
|
-
i.current && !i.current.contains(
|
|
2749
|
+
const D = (T) => {
|
|
2750
|
+
i.current && !i.current.contains(T.target) && o.current && !o.current.contains(T.target) && l(!1);
|
|
2746
2751
|
};
|
|
2747
2752
|
return n && document.addEventListener("mousedown", D), () => document.removeEventListener("mousedown", D);
|
|
2748
2753
|
}, [n]);
|
|
2749
2754
|
const b = (D) => {
|
|
2750
|
-
const
|
|
2751
|
-
t.onFilterChange(
|
|
2755
|
+
const T = p.includes(D) ? p.filter((Z) => Z !== D) : [...p, D];
|
|
2756
|
+
t.onFilterChange(T);
|
|
2752
2757
|
}, H = () => t.onFilterChange([]);
|
|
2753
2758
|
return /* @__PURE__ */ d(u, { style: { position: "relative" }, children: [
|
|
2754
2759
|
/* @__PURE__ */ e(
|
|
@@ -2762,8 +2767,8 @@ const cn = te(
|
|
|
2762
2767
|
cursor: "pointer"
|
|
2763
2768
|
},
|
|
2764
2769
|
onClick: (D) => {
|
|
2765
|
-
var
|
|
2766
|
-
D.stopPropagation(), n || (
|
|
2770
|
+
var T;
|
|
2771
|
+
D.stopPropagation(), n || (T = t.onOpen) == null || T.call(t), l((Z) => !Z);
|
|
2767
2772
|
},
|
|
2768
2773
|
children: /* @__PURE__ */ e(
|
|
2769
2774
|
k,
|
|
@@ -2771,7 +2776,7 @@ const cn = te(
|
|
|
2771
2776
|
name: n ? "ChevronUp" : "ChevronDown",
|
|
2772
2777
|
size: "sm",
|
|
2773
2778
|
style: {
|
|
2774
|
-
color:
|
|
2779
|
+
color: p.length > 0 ? "var(--sa-color-brand-500, #1a4fa0)" : "var(--sa-text-subtle, #8c8f97)"
|
|
2775
2780
|
}
|
|
2776
2781
|
}
|
|
2777
2782
|
)
|
|
@@ -2815,7 +2820,7 @@ const cn = te(
|
|
|
2815
2820
|
"Filter ",
|
|
2816
2821
|
r
|
|
2817
2822
|
] }),
|
|
2818
|
-
|
|
2823
|
+
p.length > 0 && /* @__PURE__ */ e(u, { style: { cursor: "pointer" }, children: /* @__PURE__ */ e(
|
|
2819
2824
|
C,
|
|
2820
2825
|
{
|
|
2821
2826
|
fontSize: "xs",
|
|
@@ -2896,7 +2901,7 @@ const cn = te(
|
|
|
2896
2901
|
)
|
|
2897
2902
|
]
|
|
2898
2903
|
}
|
|
2899
|
-
) :
|
|
2904
|
+
) : y.length > 0 ? /* @__PURE__ */ e(u, { style: { gap: "2px", paddingTop: "4px", paddingBottom: "4px" }, children: y.map((D) => /* @__PURE__ */ d(
|
|
2900
2905
|
u,
|
|
2901
2906
|
{
|
|
2902
2907
|
style: {
|
|
@@ -2911,22 +2916,22 @@ const cn = te(
|
|
|
2911
2916
|
cursor: "pointer",
|
|
2912
2917
|
borderRadius: "8px",
|
|
2913
2918
|
transition: "all 0.2s ease",
|
|
2914
|
-
backgroundColor:
|
|
2919
|
+
backgroundColor: p.includes(D.value) ? "var(--sa-color-brand-50, #e6edf6)" : "transparent"
|
|
2915
2920
|
},
|
|
2916
|
-
onClick: (
|
|
2917
|
-
|
|
2921
|
+
onClick: (T) => {
|
|
2922
|
+
T.stopPropagation(), b(D.value);
|
|
2918
2923
|
},
|
|
2919
|
-
onMouseEnter: (
|
|
2920
|
-
|
|
2924
|
+
onMouseEnter: (T) => {
|
|
2925
|
+
p.includes(D.value) || (T.currentTarget.style.backgroundColor = "var(--sa-background-primary, #ffffff)"), T.currentTarget.style.transform = "translateX(2px)";
|
|
2921
2926
|
},
|
|
2922
|
-
onMouseLeave: (
|
|
2923
|
-
|
|
2927
|
+
onMouseLeave: (T) => {
|
|
2928
|
+
T.currentTarget.style.backgroundColor = p.includes(D.value) ? "var(--sa-color-brand-50, #e6edf6)" : "transparent", T.currentTarget.style.transform = "translateX(0)";
|
|
2924
2929
|
},
|
|
2925
2930
|
children: [
|
|
2926
2931
|
/* @__PURE__ */ e(
|
|
2927
|
-
|
|
2932
|
+
et,
|
|
2928
2933
|
{
|
|
2929
|
-
checked:
|
|
2934
|
+
checked: p.includes(D.value),
|
|
2930
2935
|
onChange: () => {
|
|
2931
2936
|
}
|
|
2932
2937
|
}
|
|
@@ -2935,8 +2940,8 @@ const cn = te(
|
|
|
2935
2940
|
C,
|
|
2936
2941
|
{
|
|
2937
2942
|
fontSize: "sm",
|
|
2938
|
-
fontWeight:
|
|
2939
|
-
color:
|
|
2943
|
+
fontWeight: p.includes(D.value) ? "medium" : "normal",
|
|
2944
|
+
color: p.includes(D.value) ? "primary" : "gray-700",
|
|
2940
2945
|
children: D.label
|
|
2941
2946
|
}
|
|
2942
2947
|
)
|
|
@@ -2977,7 +2982,7 @@ const cn = te(
|
|
|
2977
2982
|
)
|
|
2978
2983
|
}
|
|
2979
2984
|
),
|
|
2980
|
-
|
|
2985
|
+
p.length > 0 && /* @__PURE__ */ e(
|
|
2981
2986
|
u,
|
|
2982
2987
|
{
|
|
2983
2988
|
style: {
|
|
@@ -3001,12 +3006,12 @@ const cn = te(
|
|
|
3001
3006
|
fontWeight: 600,
|
|
3002
3007
|
color: "white"
|
|
3003
3008
|
},
|
|
3004
|
-
children:
|
|
3009
|
+
children: p.length
|
|
3005
3010
|
}
|
|
3006
3011
|
),
|
|
3007
3012
|
/* @__PURE__ */ d(C, { fontSize: "xs", color: "primary", fontWeight: "medium", children: [
|
|
3008
3013
|
"item",
|
|
3009
|
-
|
|
3014
|
+
p.length > 1 ? "s" : "",
|
|
3010
3015
|
" selected"
|
|
3011
3016
|
] })
|
|
3012
3017
|
] })
|
|
@@ -3056,7 +3061,7 @@ const cn = te(
|
|
|
3056
3061
|
]
|
|
3057
3062
|
}
|
|
3058
3063
|
);
|
|
3059
|
-
},
|
|
3064
|
+
}, Gr = ({ frozen: t }) => /* @__PURE__ */ d(
|
|
3060
3065
|
"svg",
|
|
3061
3066
|
{
|
|
3062
3067
|
width: "11",
|
|
@@ -3072,7 +3077,7 @@ const cn = te(
|
|
|
3072
3077
|
/* @__PURE__ */ e("path", { d: t ? "M7 11V7a5 5 0 0 1 10 0v4" : "M7 11V7a5 5 0 0 1 9.9-1" })
|
|
3073
3078
|
]
|
|
3074
3079
|
}
|
|
3075
|
-
),
|
|
3080
|
+
), Ke = "var(--sa-background-primary, #ffffff)", xt = "var(--sa-background-primary-inverse, #f8f8f8)", Qr = ({
|
|
3076
3081
|
columns: t,
|
|
3077
3082
|
records: r,
|
|
3078
3083
|
handleDetail: n,
|
|
@@ -3084,15 +3089,15 @@ const cn = te(
|
|
|
3084
3089
|
visibleHandleDetail: h,
|
|
3085
3090
|
showHeadBorder: f = !1,
|
|
3086
3091
|
scrollParentRef: g,
|
|
3087
|
-
frozenCount:
|
|
3088
|
-
onFrozenCountChange:
|
|
3092
|
+
frozenCount: p = 0,
|
|
3093
|
+
onFrozenCountChange: y,
|
|
3089
3094
|
customActions: b,
|
|
3090
3095
|
actionsOrder: H = ["detail", "update", "delete", "custom"],
|
|
3091
3096
|
customEmptyState: D,
|
|
3092
|
-
enableColumnResize:
|
|
3097
|
+
enableColumnResize: T = !1,
|
|
3093
3098
|
defaultColumnWidths: Z,
|
|
3094
3099
|
onColumnWidthsChange: j,
|
|
3095
|
-
defaultMinColumnWidth:
|
|
3100
|
+
defaultMinColumnWidth: J = 60,
|
|
3096
3101
|
sort: M,
|
|
3097
3102
|
defaultSort: fe,
|
|
3098
3103
|
onSortChange: G,
|
|
@@ -3108,22 +3113,22 @@ const cn = te(
|
|
|
3108
3113
|
if (!w) return;
|
|
3109
3114
|
let v;
|
|
3110
3115
|
!_ || _.key !== w ? v = { key: w, direction: "asc" } : _.direction === "asc" ? v = { key: w, direction: "desc" } : v = null, K || ce(v), G == null || G(v);
|
|
3111
|
-
}, Q = [n, l, i].filter((x) => x !== void 0).length,
|
|
3116
|
+
}, Q = [n, l, i].filter((x) => x !== void 0).length, q = !!b, z = !!n || !!l || !!i || q, I = "var(--sa-border-subtle, #0b120e24)", Y = `1px solid ${I}`, de = `inset 1px 0 0 ${I}`, he = `inset -1px 0 0 ${I}`, Me = Q === 3 ? q ? "178px" : "140px" : Q === 2 ? q ? "140px" : "102px" : Q === 1 ? q ? "112px" : "74px" : q ? "74px" : "", Ie = (x, w) => {
|
|
3112
3117
|
if (!w) return x;
|
|
3113
3118
|
if (typeof w == "function") return w(x);
|
|
3114
3119
|
if (typeof w == "string") return x[w];
|
|
3115
|
-
}, [
|
|
3120
|
+
}, [Ge, Te] = A(!1);
|
|
3116
3121
|
U(() => {
|
|
3117
3122
|
if (!(g != null && g.current)) return;
|
|
3118
3123
|
const x = g.current;
|
|
3119
|
-
|
|
3124
|
+
Te(x.scrollHeight > x.clientHeight);
|
|
3120
3125
|
}, [r, g]);
|
|
3121
|
-
const Le = le(null), [ie,
|
|
3126
|
+
const Le = le(null), [ie, Oe] = A([]), [We, Be] = A(
|
|
3122
3127
|
() => Z ?? {}
|
|
3123
3128
|
), ke = le(null);
|
|
3124
|
-
|
|
3125
|
-
if (!
|
|
3126
|
-
|
|
3129
|
+
tt(() => {
|
|
3130
|
+
if (!p || !Le.current) {
|
|
3131
|
+
Oe([]);
|
|
3127
3132
|
return;
|
|
3128
3133
|
}
|
|
3129
3134
|
const x = Array.from(
|
|
@@ -3131,11 +3136,11 @@ const cn = te(
|
|
|
3131
3136
|
), w = [];
|
|
3132
3137
|
let v = 0;
|
|
3133
3138
|
x.forEach((L, R) => {
|
|
3134
|
-
w[R] = v, R <
|
|
3135
|
-
}),
|
|
3136
|
-
}, [
|
|
3137
|
-
const
|
|
3138
|
-
|
|
3139
|
+
w[R] = v, R < p && (v += L.offsetWidth);
|
|
3140
|
+
}), Oe(w);
|
|
3141
|
+
}, [p, t, r, We]);
|
|
3142
|
+
const Ne = (x) => {
|
|
3143
|
+
y && y(x < p ? x : x + 1);
|
|
3139
3144
|
}, m = (x, w) => {
|
|
3140
3145
|
const v = We[x];
|
|
3141
3146
|
if (v !== void 0) {
|
|
@@ -3143,7 +3148,7 @@ const cn = te(
|
|
|
3143
3148
|
return { width: L, minWidth: L, maxWidth: L };
|
|
3144
3149
|
}
|
|
3145
3150
|
return w ? { width: w } : {};
|
|
3146
|
-
}, F = (x) =>
|
|
3151
|
+
}, F = (x) => T && (x.resizable ?? !0), S = (x, w) => {
|
|
3147
3152
|
x.preventDefault(), x.stopPropagation();
|
|
3148
3153
|
const v = x.currentTarget.closest("th");
|
|
3149
3154
|
if (!v) return;
|
|
@@ -3151,18 +3156,18 @@ const cn = te(
|
|
|
3151
3156
|
ke.current = { colIndex: w, startX: x.clientX, startWidth: L };
|
|
3152
3157
|
const R = document.body.style.userSelect, ne = document.body.style.cursor;
|
|
3153
3158
|
document.body.style.userSelect = "none", document.body.style.cursor = "col-resize";
|
|
3154
|
-
const
|
|
3159
|
+
const pe = (xe) => {
|
|
3155
3160
|
var Fe;
|
|
3156
|
-
const
|
|
3157
|
-
if (!
|
|
3158
|
-
const
|
|
3161
|
+
const ye = ke.current;
|
|
3162
|
+
if (!ye) return;
|
|
3163
|
+
const Ze = ((Fe = t[ye.colIndex]) == null ? void 0 : Fe.minWidth) ?? J, Ae = Math.max(Ze, ye.startWidth + (xe.clientX - ye.startX));
|
|
3159
3164
|
Be(
|
|
3160
|
-
(
|
|
3165
|
+
(Qe) => Qe[ye.colIndex] === Ae ? Qe : { ...Qe, [ye.colIndex]: Ae }
|
|
3161
3166
|
);
|
|
3162
3167
|
}, be = () => {
|
|
3163
|
-
document.removeEventListener("mousemove",
|
|
3168
|
+
document.removeEventListener("mousemove", pe), document.removeEventListener("mouseup", be), document.body.style.userSelect = R, document.body.style.cursor = ne, ke.current = null, j && Be((xe) => (j(xe), xe));
|
|
3164
3169
|
};
|
|
3165
|
-
document.addEventListener("mousemove",
|
|
3170
|
+
document.addEventListener("mousemove", pe), document.addEventListener("mouseup", be);
|
|
3166
3171
|
};
|
|
3167
3172
|
return /* @__PURE__ */ e("div", { ref: Le, children: /* @__PURE__ */ d(wt, { fullWidth: !0, children: [
|
|
3168
3173
|
/* @__PURE__ */ e(
|
|
@@ -3174,8 +3179,8 @@ const cn = te(
|
|
|
3174
3179
|
},
|
|
3175
3180
|
children: /* @__PURE__ */ d(He, { children: [
|
|
3176
3181
|
t.map((x, w) => {
|
|
3177
|
-
var
|
|
3178
|
-
const v =
|
|
3182
|
+
var Ze, Ae;
|
|
3183
|
+
const v = p > 0 && w < p, L = ie[w] ?? 0, R = F(x), pe = w === t.length - 1 && z && V, be = ae(x), xe = !!x.sortable && !!be, ye = xe && (_ == null ? void 0 : _.key) === be ? _.direction : null;
|
|
3179
3184
|
return /* @__PURE__ */ d(
|
|
3180
3185
|
dt,
|
|
3181
3186
|
{
|
|
@@ -3185,7 +3190,7 @@ const cn = te(
|
|
|
3185
3190
|
left: v ? L : void 0,
|
|
3186
3191
|
zIndex: v ? 4 : 2,
|
|
3187
3192
|
paddingLeft: w === 0 ? "12px" : "",
|
|
3188
|
-
borderRight: f && !
|
|
3193
|
+
borderRight: f && !pe && !v ? Y : void 0,
|
|
3189
3194
|
borderBottom: f ? Y : void 0,
|
|
3190
3195
|
boxShadow: f && v ? he : void 0,
|
|
3191
3196
|
backgroundColor: "var(--sa-background-primary-inverse, #f8f8f8)",
|
|
@@ -3209,7 +3214,7 @@ const cn = te(
|
|
|
3209
3214
|
{
|
|
3210
3215
|
type: "button",
|
|
3211
3216
|
onClick: () => se(x),
|
|
3212
|
-
title:
|
|
3217
|
+
title: ye === "asc" ? "Sorted ascending — click to sort descending" : ye === "desc" ? "Sorted descending — click to clear" : "Click to sort ascending",
|
|
3213
3218
|
style: {
|
|
3214
3219
|
flex: 1,
|
|
3215
3220
|
minWidth: 0,
|
|
@@ -3236,10 +3241,10 @@ const cn = te(
|
|
|
3236
3241
|
textOverflow: "ellipsis",
|
|
3237
3242
|
whiteSpace: "nowrap"
|
|
3238
3243
|
},
|
|
3239
|
-
children: x.title || ((
|
|
3244
|
+
children: x.title || ((Ze = x.accessor) == null ? void 0 : Ze.toString())
|
|
3240
3245
|
}
|
|
3241
3246
|
),
|
|
3242
|
-
/* @__PURE__ */ e(Jr, { direction:
|
|
3247
|
+
/* @__PURE__ */ e(Jr, { direction: ye })
|
|
3243
3248
|
]
|
|
3244
3249
|
}
|
|
3245
3250
|
) : /* @__PURE__ */ e(
|
|
@@ -3262,10 +3267,10 @@ const cn = te(
|
|
|
3262
3267
|
columnTitle: x.title
|
|
3263
3268
|
}
|
|
3264
3269
|
),
|
|
3265
|
-
|
|
3270
|
+
y && /* @__PURE__ */ e(
|
|
3266
3271
|
"button",
|
|
3267
3272
|
{
|
|
3268
|
-
onClick: () =>
|
|
3273
|
+
onClick: () => Ne(w),
|
|
3269
3274
|
title: v ? "Unfreeze column" : "Freeze column",
|
|
3270
3275
|
style: {
|
|
3271
3276
|
background: "none",
|
|
@@ -3279,7 +3284,7 @@ const cn = te(
|
|
|
3279
3284
|
opacity: v ? 1 : 0.45,
|
|
3280
3285
|
transition: "opacity 0.15s"
|
|
3281
3286
|
},
|
|
3282
|
-
children: /* @__PURE__ */ e(
|
|
3287
|
+
children: /* @__PURE__ */ e(Gr, { frozen: v })
|
|
3283
3288
|
}
|
|
3284
3289
|
)
|
|
3285
3290
|
]
|
|
@@ -3311,7 +3316,7 @@ const cn = te(
|
|
|
3311
3316
|
`table-head-${w}`
|
|
3312
3317
|
);
|
|
3313
3318
|
}),
|
|
3314
|
-
|
|
3319
|
+
z ? /* @__PURE__ */ e(
|
|
3315
3320
|
dt,
|
|
3316
3321
|
{
|
|
3317
3322
|
style: {
|
|
@@ -3340,7 +3345,7 @@ const cn = te(
|
|
|
3340
3345
|
style: {
|
|
3341
3346
|
transition: "background-color 0.3s ease",
|
|
3342
3347
|
padding: 0,
|
|
3343
|
-
borderBottom: w === r.length - 1 &&
|
|
3348
|
+
borderBottom: w === r.length - 1 && Ge ? void 0 : "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
3344
3349
|
},
|
|
3345
3350
|
onMouseEnter: (v) => {
|
|
3346
3351
|
const L = v.currentTarget;
|
|
@@ -3351,20 +3356,20 @@ const cn = te(
|
|
|
3351
3356
|
onMouseLeave: (v) => {
|
|
3352
3357
|
const L = v.currentTarget;
|
|
3353
3358
|
L.style.backgroundColor = "", Array.from(L.querySelectorAll("td")).forEach((R) => {
|
|
3354
|
-
R.style.position === "sticky" && (R.style.backgroundColor =
|
|
3359
|
+
R.style.position === "sticky" && (R.style.backgroundColor = Ke);
|
|
3355
3360
|
});
|
|
3356
3361
|
},
|
|
3357
3362
|
children: [
|
|
3358
3363
|
t.map((v, L) => {
|
|
3359
|
-
const R = v.render ? v.render(x, w, r) :
|
|
3364
|
+
const R = v.render ? v.render(x, w, r) : Ie(x, v.accessor), ne = p > 0 && L < p, pe = ie[L] ?? 0, be = We[L] !== void 0, xe = ne && L === p - 1;
|
|
3360
3365
|
return /* @__PURE__ */ e(
|
|
3361
3366
|
we,
|
|
3362
3367
|
{
|
|
3363
3368
|
style: {
|
|
3364
3369
|
position: ne ? "sticky" : void 0,
|
|
3365
|
-
left: ne ?
|
|
3370
|
+
left: ne ? pe : void 0,
|
|
3366
3371
|
zIndex: ne ? 1 : void 0,
|
|
3367
|
-
backgroundColor: ne ?
|
|
3372
|
+
backgroundColor: ne ? Ke : void 0,
|
|
3368
3373
|
transition: ne ? "background-color 0.3s ease" : void 0,
|
|
3369
3374
|
paddingLeft: L === 0 ? "12px" : "",
|
|
3370
3375
|
whiteSpace: "nowrap",
|
|
@@ -3391,12 +3396,12 @@ const cn = te(
|
|
|
3391
3396
|
`row-${w}-col-${L}`
|
|
3392
3397
|
);
|
|
3393
3398
|
}),
|
|
3394
|
-
|
|
3399
|
+
z ? /* @__PURE__ */ e(we, { style: {
|
|
3395
3400
|
width: Me,
|
|
3396
3401
|
position: "sticky",
|
|
3397
3402
|
right: 0,
|
|
3398
3403
|
zIndex: 1,
|
|
3399
|
-
backgroundColor:
|
|
3404
|
+
backgroundColor: Ke,
|
|
3400
3405
|
boxShadow: V ? de : void 0,
|
|
3401
3406
|
transition: "background-color 0.3s ease"
|
|
3402
3407
|
}, children: /* @__PURE__ */ e($, { direction: "row", align: "center", justify: "center", gap: "sm", children: H.map((v) => {
|
|
@@ -3435,20 +3440,20 @@ const cn = te(
|
|
|
3435
3440
|
`${x}${w}`
|
|
3436
3441
|
)) })
|
|
3437
3442
|
] }) });
|
|
3438
|
-
},
|
|
3443
|
+
}, Yr = ({
|
|
3439
3444
|
wrapperProps: t,
|
|
3440
3445
|
dataTableProps: r,
|
|
3441
3446
|
headerProps: n,
|
|
3442
3447
|
footerProps: l
|
|
3443
3448
|
}) => {
|
|
3444
|
-
var
|
|
3449
|
+
var p;
|
|
3445
3450
|
const i = le(null), [o, s] = A(
|
|
3446
3451
|
(r == null ? void 0 : r.defaultFrozenCount) ?? 0
|
|
3447
|
-
), a = (n == null ? void 0 : n.show) ?? !0, h = le(null), f = (
|
|
3452
|
+
), a = (n == null ? void 0 : n.show) ?? !0, h = le(null), f = (p = r == null ? void 0 : r.pagination) == null ? void 0 : p.totalData;
|
|
3448
3453
|
typeof f == "number" && (h.current = f);
|
|
3449
3454
|
const g = (l == null ? void 0 : l.showFooter) ?? (f === void 0 ? h.current !== 0 : f !== 0);
|
|
3450
|
-
return /* @__PURE__ */ d(
|
|
3451
|
-
a && /* @__PURE__ */ e(
|
|
3455
|
+
return /* @__PURE__ */ d($r, { ...t, children: [
|
|
3456
|
+
a && /* @__PURE__ */ e(_r, { ...n }),
|
|
3452
3457
|
/* @__PURE__ */ e(
|
|
3453
3458
|
u,
|
|
3454
3459
|
{
|
|
@@ -3459,7 +3464,7 @@ const cn = te(
|
|
|
3459
3464
|
overflowX: "auto"
|
|
3460
3465
|
},
|
|
3461
3466
|
children: r ? /* @__PURE__ */ e(
|
|
3462
|
-
|
|
3467
|
+
Qr,
|
|
3463
3468
|
{
|
|
3464
3469
|
...r,
|
|
3465
3470
|
scrollParentRef: i,
|
|
@@ -3470,7 +3475,7 @@ const cn = te(
|
|
|
3470
3475
|
}
|
|
3471
3476
|
),
|
|
3472
3477
|
g && /* @__PURE__ */ e(
|
|
3473
|
-
|
|
3478
|
+
Pr,
|
|
3474
3479
|
{
|
|
3475
3480
|
pagination: r == null ? void 0 : r.pagination,
|
|
3476
3481
|
pageKey: r == null ? void 0 : r.pageKey,
|
|
@@ -3482,15 +3487,15 @@ const cn = te(
|
|
|
3482
3487
|
)
|
|
3483
3488
|
] });
|
|
3484
3489
|
};
|
|
3485
|
-
function
|
|
3490
|
+
function Xr(t) {
|
|
3486
3491
|
return te(
|
|
3487
3492
|
t
|
|
3488
3493
|
);
|
|
3489
3494
|
}
|
|
3490
|
-
const
|
|
3495
|
+
const Dn = Xr(Yr), st = ({
|
|
3491
3496
|
of: t,
|
|
3492
3497
|
render: r
|
|
3493
|
-
}) => Qt.toArray(t == null ? void 0 : t.map((n, l, i) => r(n, l, i))),
|
|
3498
|
+
}) => Qt.toArray(t == null ? void 0 : t.map((n, l, i) => r(n, l, i))), O = ({
|
|
3494
3499
|
condition: t,
|
|
3495
3500
|
fallback: r,
|
|
3496
3501
|
children: n,
|
|
@@ -3506,7 +3511,7 @@ const xn = Yr(Qr), st = ({
|
|
|
3506
3511
|
color: t.color || "gray-700",
|
|
3507
3512
|
children: t.children
|
|
3508
3513
|
}
|
|
3509
|
-
), Ce = (t) => /* @__PURE__ */ e(C, { color: "red-600", fontSize: "sm", children: t.message }),
|
|
3514
|
+
), Ce = (t) => /* @__PURE__ */ e(C, { color: "red-600", fontSize: "sm", children: t.message }), Kr = ({
|
|
3510
3515
|
size: t = "md",
|
|
3511
3516
|
direction: r = "vertical",
|
|
3512
3517
|
requiredTitle: n = "(Required)",
|
|
@@ -3523,7 +3528,7 @@ const xn = Yr(Qr), st = ({
|
|
|
3523
3528
|
...i.containerProps,
|
|
3524
3529
|
children: [
|
|
3525
3530
|
i.title && /* @__PURE__ */ e(
|
|
3526
|
-
|
|
3531
|
+
O,
|
|
3527
3532
|
{
|
|
3528
3533
|
condition: !!i.inputProps.required,
|
|
3529
3534
|
fallback: /* @__PURE__ */ d(
|
|
@@ -3548,7 +3553,7 @@ const xn = Yr(Qr), st = ({
|
|
|
3548
3553
|
/* @__PURE__ */ d($, { direction: "row", gap: "xs", align: "center", children: [
|
|
3549
3554
|
/* @__PURE__ */ e(N, { fontSize: t, children: i.title }),
|
|
3550
3555
|
/* @__PURE__ */ e(N, { color: "error", fontSize: t, children: n }),
|
|
3551
|
-
/* @__PURE__ */ e(
|
|
3556
|
+
/* @__PURE__ */ e(O, { condition: !!((a = i.tooltip) != null && a.label), children: /* @__PURE__ */ e(
|
|
3552
3557
|
ue,
|
|
3553
3558
|
{
|
|
3554
3559
|
label: (h = i.tooltip) == null ? void 0 : h.label,
|
|
@@ -3568,7 +3573,7 @@ const xn = Yr(Qr), st = ({
|
|
|
3568
3573
|
}
|
|
3569
3574
|
) })
|
|
3570
3575
|
] }),
|
|
3571
|
-
/* @__PURE__ */ e(
|
|
3576
|
+
/* @__PURE__ */ e(O, { condition: !!i.description, children: /* @__PURE__ */ e(C, { fontSize: t, color: "gray-500", children: i.description }) })
|
|
3572
3577
|
]
|
|
3573
3578
|
}
|
|
3574
3579
|
)
|
|
@@ -3591,7 +3596,7 @@ const xn = Yr(Qr), st = ({
|
|
|
3591
3596
|
]
|
|
3592
3597
|
}
|
|
3593
3598
|
);
|
|
3594
|
-
},
|
|
3599
|
+
}, ei = ({
|
|
3595
3600
|
size: t = "md",
|
|
3596
3601
|
direction: r = "vertical",
|
|
3597
3602
|
requiredTitle: n = "(Required)",
|
|
@@ -3608,7 +3613,7 @@ const xn = Yr(Qr), st = ({
|
|
|
3608
3613
|
onClick: i.onClickContainer,
|
|
3609
3614
|
children: [
|
|
3610
3615
|
i.title && /* @__PURE__ */ e(
|
|
3611
|
-
|
|
3616
|
+
O,
|
|
3612
3617
|
{
|
|
3613
3618
|
condition: !!i.inputProps.required,
|
|
3614
3619
|
fallback: /* @__PURE__ */ d(
|
|
@@ -3633,7 +3638,7 @@ const xn = Yr(Qr), st = ({
|
|
|
3633
3638
|
/* @__PURE__ */ d($, { direction: "row", gap: "xs", align: "center", children: [
|
|
3634
3639
|
/* @__PURE__ */ e(N, { fontSize: t, children: i.title }),
|
|
3635
3640
|
/* @__PURE__ */ e(N, { color: "error", fontSize: t, children: n }),
|
|
3636
|
-
/* @__PURE__ */ e(
|
|
3641
|
+
/* @__PURE__ */ e(O, { condition: !!((a = i.tooltip) != null && a.label), children: /* @__PURE__ */ e(
|
|
3637
3642
|
ue,
|
|
3638
3643
|
{
|
|
3639
3644
|
label: (h = i.tooltip) == null ? void 0 : h.label,
|
|
@@ -3653,7 +3658,7 @@ const xn = Yr(Qr), st = ({
|
|
|
3653
3658
|
}
|
|
3654
3659
|
) })
|
|
3655
3660
|
] }),
|
|
3656
|
-
/* @__PURE__ */ e(
|
|
3661
|
+
/* @__PURE__ */ e(O, { condition: !!i.description, children: /* @__PURE__ */ e(C, { fontSize: t, color: "gray-500", children: i.description }) })
|
|
3657
3662
|
]
|
|
3658
3663
|
}
|
|
3659
3664
|
)
|
|
@@ -3682,7 +3687,7 @@ const xn = Yr(Qr), st = ({
|
|
|
3682
3687
|
]
|
|
3683
3688
|
}
|
|
3684
3689
|
);
|
|
3685
|
-
},
|
|
3690
|
+
}, ti = (t, r) => typeof t == "string" && t || r === "error" ? "var(--sa-text-error, #a4133c)" : "var(--sa-text-disable, #181a198f)", ri = (t) => {
|
|
3686
3691
|
var a;
|
|
3687
3692
|
const [r, n] = A(!1), l = (h) => {
|
|
3688
3693
|
h.preventDefault(), h.stopPropagation();
|
|
@@ -3709,7 +3714,7 @@ const xn = Yr(Qr), st = ({
|
|
|
3709
3714
|
paddingBlock: "md",
|
|
3710
3715
|
borderRadius: "rounded-md",
|
|
3711
3716
|
style: {
|
|
3712
|
-
border: r ? "1px solid var(--sa-text-info, #0073ab)" : `1px solid ${
|
|
3717
|
+
border: r ? "1px solid var(--sa-text-info, #0073ab)" : `1px solid ${ti(t.errorMessage, t.status)}`
|
|
3713
3718
|
},
|
|
3714
3719
|
children: [
|
|
3715
3720
|
/* @__PURE__ */ e(
|
|
@@ -3751,17 +3756,17 @@ const xn = Yr(Qr), st = ({
|
|
|
3751
3756
|
}
|
|
3752
3757
|
);
|
|
3753
3758
|
};
|
|
3754
|
-
function
|
|
3759
|
+
function bn(t) {
|
|
3755
3760
|
return t.split(" ").map((r) => r[0]).join("").slice(0, 2).toUpperCase();
|
|
3756
3761
|
}
|
|
3757
|
-
const
|
|
3762
|
+
const ii = (t) => {
|
|
3758
3763
|
const r = {
|
|
3759
3764
|
day: "2-digit",
|
|
3760
3765
|
month: "short",
|
|
3761
3766
|
year: "numeric"
|
|
3762
3767
|
};
|
|
3763
3768
|
return t.toLocaleDateString("id-ID", r);
|
|
3764
|
-
},
|
|
3769
|
+
}, vn = (t) => {
|
|
3765
3770
|
const r = {
|
|
3766
3771
|
Jan: 0,
|
|
3767
3772
|
Feb: 1,
|
|
@@ -3781,7 +3786,7 @@ const ri = (t) => {
|
|
|
3781
3786
|
const l = parseInt(n[0], 10), i = r[n[1]], o = parseInt(n[2], 10);
|
|
3782
3787
|
return isNaN(l) || isNaN(i) || isNaN(o) ? null : new Date(o, i, l);
|
|
3783
3788
|
};
|
|
3784
|
-
function
|
|
3789
|
+
function wn(t, r = !0) {
|
|
3785
3790
|
if (!t)
|
|
3786
3791
|
return "Rp 0";
|
|
3787
3792
|
const n = typeof t == "number" ? t.toString() : t;
|
|
@@ -3796,19 +3801,19 @@ String.prototype.toTitleCase = function() {
|
|
|
3796
3801
|
String.prototype.toNumber = function() {
|
|
3797
3802
|
return Number(this);
|
|
3798
3803
|
};
|
|
3799
|
-
const
|
|
3804
|
+
const kn = (t) => {
|
|
3800
3805
|
const r = t.split(" ");
|
|
3801
3806
|
let n = r[0].charAt(0);
|
|
3802
3807
|
return r.length > 1 && (n += "" + r[1].charAt(0)), n.toUpperCase();
|
|
3803
3808
|
};
|
|
3804
|
-
function
|
|
3809
|
+
function Fn(t) {
|
|
3805
3810
|
const r = typeof t == "string" ? new Date(t) : t;
|
|
3806
3811
|
if (isNaN(r.getTime()))
|
|
3807
3812
|
throw new Error("Invalid date format");
|
|
3808
3813
|
const n = r.getFullYear(), l = String(r.getMonth() + 1).padStart(2, "0"), i = String(r.getDate()).padStart(2, "0");
|
|
3809
3814
|
return `${n}-${l}-${i}`;
|
|
3810
3815
|
}
|
|
3811
|
-
const
|
|
3816
|
+
const ni = "sa-admin", ge = (t) => `var(--${ni}-${t})`, Sn = {
|
|
3812
3817
|
base: {
|
|
3813
3818
|
borderColor: ge("base-border-color"),
|
|
3814
3819
|
textColor: ge("base-text-color"),
|
|
@@ -3826,22 +3831,22 @@ const ii = "sa-admin", ge = (t) => `var(--${ii}-${t})`, kn = {
|
|
|
3826
3831
|
collapseWidth: ge("sidebar-collapse-width"),
|
|
3827
3832
|
collapseV2Width: ge("sidebar-v2-collapse-width")
|
|
3828
3833
|
}
|
|
3829
|
-
},
|
|
3834
|
+
}, En = 24 * 60 * 60 * 1e3, Mn = (t) => {
|
|
3830
3835
|
const r = "14px poppins", l = document.createElement("canvas").getContext("2d");
|
|
3831
3836
|
l.font = r;
|
|
3832
3837
|
const i = l.measureText(t).width;
|
|
3833
3838
|
return Number(Math.ceil(i));
|
|
3834
|
-
},
|
|
3835
|
-
function
|
|
3839
|
+
}, li = /^[^\s@]+@[^\s@]+\.[^\s@]+$/, oi = /--+/, ci = /-$/;
|
|
3840
|
+
function Ln(t, r) {
|
|
3836
3841
|
return JSON.stringify(t) !== JSON.stringify(r);
|
|
3837
3842
|
}
|
|
3838
|
-
function
|
|
3843
|
+
function Wn(t) {
|
|
3839
3844
|
return /^(?:\+62|62|0)8[1-9][0-9]{7,10}$/.test(t);
|
|
3840
3845
|
}
|
|
3841
|
-
function
|
|
3846
|
+
function Bn(t) {
|
|
3842
3847
|
return /^[A-Za-z\s]+$/.test(t);
|
|
3843
3848
|
}
|
|
3844
|
-
const
|
|
3849
|
+
const An = (t) => {
|
|
3845
3850
|
const r = /^[0-9]$/, n = [
|
|
3846
3851
|
"ArrowLeft",
|
|
3847
3852
|
"ArrowRight",
|
|
@@ -3853,7 +3858,7 @@ const Wn = (t) => {
|
|
|
3853
3858
|
"Tab"
|
|
3854
3859
|
];
|
|
3855
3860
|
(t.ctrlKey || t.metaKey) && (t.key === "a" || t.key === "c" || t.key === "v") || !r.test(t.key) && !n.includes(t.key) && t.preventDefault();
|
|
3856
|
-
},
|
|
3861
|
+
}, Rn = (t) => {
|
|
3857
3862
|
const r = /^[0-9]$/, n = [
|
|
3858
3863
|
"ArrowLeft",
|
|
3859
3864
|
"ArrowRight",
|
|
@@ -3865,7 +3870,7 @@ const Wn = (t) => {
|
|
|
3865
3870
|
"Tab"
|
|
3866
3871
|
];
|
|
3867
3872
|
(t.ctrlKey || t.metaKey) && t.key === "v" || r.test(t.key) && !n.includes(t.key) && t.preventDefault();
|
|
3868
|
-
},
|
|
3873
|
+
}, Hn = (t) => {
|
|
3869
3874
|
const r = /^[0-9.]$/, n = [
|
|
3870
3875
|
"ArrowLeft",
|
|
3871
3876
|
"ArrowRight",
|
|
@@ -3877,11 +3882,11 @@ const Wn = (t) => {
|
|
|
3877
3882
|
"Tab"
|
|
3878
3883
|
];
|
|
3879
3884
|
(t.ctrlKey || t.metaKey) && t.key === "v" || !r.test(t.key) && !n.includes(t.key) && t.preventDefault();
|
|
3880
|
-
},
|
|
3881
|
-
function
|
|
3882
|
-
return !(
|
|
3885
|
+
}, Vn = (t) => li.test(t);
|
|
3886
|
+
function zn(t) {
|
|
3887
|
+
return !(oi.test(t) || ci.test(t));
|
|
3883
3888
|
}
|
|
3884
|
-
const
|
|
3889
|
+
const In = (t) => {
|
|
3885
3890
|
const r = [
|
|
3886
3891
|
"ArrowLeft",
|
|
3887
3892
|
"ArrowRight",
|
|
@@ -3898,7 +3903,7 @@ const Vn = (t) => {
|
|
|
3898
3903
|
return;
|
|
3899
3904
|
const n = t.currentTarget.value;
|
|
3900
3905
|
/^[0-9]$/.test(t.key) || t.key === "." && !n.includes(".") || t.key === "-" && n.length === 0 && !n.includes("-") || r.includes(t.key) || t.preventDefault();
|
|
3901
|
-
},
|
|
3906
|
+
}, Tn = (t) => {
|
|
3902
3907
|
const r = document.getElementById(t);
|
|
3903
3908
|
if (r) {
|
|
3904
3909
|
const n = r.getBoundingClientRect(), l = window.scrollY + n.top - 80;
|
|
@@ -3908,7 +3913,7 @@ const Vn = (t) => {
|
|
|
3908
3913
|
});
|
|
3909
3914
|
}
|
|
3910
3915
|
};
|
|
3911
|
-
function
|
|
3916
|
+
function ai(t) {
|
|
3912
3917
|
const r = t.toLowerCase();
|
|
3913
3918
|
if (["kb", "mb", "gb"].find((o) => r.endsWith(o)))
|
|
3914
3919
|
return t;
|
|
@@ -3917,11 +3922,11 @@ function ci(t) {
|
|
|
3917
3922
|
throw new Error("Invalid size format");
|
|
3918
3923
|
return i >= 1e6 ? `${(i / 1e6).toFixed(2)}MB` : i >= 1e3 ? `${(i / 1e3).toFixed(2)}KB` : `${i}B`;
|
|
3919
3924
|
}
|
|
3920
|
-
function
|
|
3925
|
+
function si(t) {
|
|
3921
3926
|
const r = t.split("/");
|
|
3922
3927
|
return r[r.length - 1];
|
|
3923
3928
|
}
|
|
3924
|
-
const
|
|
3929
|
+
const di = (t) => {
|
|
3925
3930
|
var r, n;
|
|
3926
3931
|
return /* @__PURE__ */ d(
|
|
3927
3932
|
u,
|
|
@@ -3966,11 +3971,11 @@ const si = (t) => {
|
|
|
3966
3971
|
whiteSpace: "nowrap",
|
|
3967
3972
|
overflow: "hidden"
|
|
3968
3973
|
},
|
|
3969
|
-
children:
|
|
3974
|
+
children: si(t.defaultUrl || "") || ((r = t.fileSelected) == null ? void 0 : r.name)
|
|
3970
3975
|
}
|
|
3971
3976
|
),
|
|
3972
3977
|
!t.defaultUrl && /* @__PURE__ */ d($, { direction: "row", gap: "xs", align: "center", children: [
|
|
3973
|
-
/* @__PURE__ */ e(C, { fontSize: "sm", fontWeight: "medium", children: `${
|
|
3978
|
+
/* @__PURE__ */ e(C, { fontSize: "sm", fontWeight: "medium", children: `${ai(
|
|
3974
3979
|
((n = t.fileSelected) == null ? void 0 : n.size.toString()) || "100000"
|
|
3975
3980
|
)}` }),
|
|
3976
3981
|
/* @__PURE__ */ e(k, { name: "Dot", size: "xs" }),
|
|
@@ -3982,7 +3987,7 @@ const si = (t) => {
|
|
|
3982
3987
|
style: {
|
|
3983
3988
|
textWrap: "nowrap"
|
|
3984
3989
|
},
|
|
3985
|
-
children: t.fileDate ? t.fileDate :
|
|
3990
|
+
children: t.fileDate ? t.fileDate : ii(/* @__PURE__ */ new Date())
|
|
3986
3991
|
}
|
|
3987
3992
|
)
|
|
3988
3993
|
] })
|
|
@@ -4011,7 +4016,7 @@ const si = (t) => {
|
|
|
4011
4016
|
]
|
|
4012
4017
|
}
|
|
4013
4018
|
);
|
|
4014
|
-
},
|
|
4019
|
+
}, hi = ({ status: t = "default", ...r }) => {
|
|
4015
4020
|
var o;
|
|
4016
4021
|
const n = le(null), l = () => {
|
|
4017
4022
|
if (r.defaultUrl) {
|
|
@@ -4048,7 +4053,7 @@ const si = (t) => {
|
|
|
4048
4053
|
...r.containerProps,
|
|
4049
4054
|
children: [
|
|
4050
4055
|
(r.fileSelected || r.defaultUrl) && /* @__PURE__ */ e(
|
|
4051
|
-
|
|
4056
|
+
di,
|
|
4052
4057
|
{
|
|
4053
4058
|
fileSelected: r.fileSelected,
|
|
4054
4059
|
fileDate: r.fileDate,
|
|
@@ -4058,7 +4063,7 @@ const si = (t) => {
|
|
|
4058
4063
|
}
|
|
4059
4064
|
),
|
|
4060
4065
|
!r.fileSelected && !r.defaultUrl && /* @__PURE__ */ e(
|
|
4061
|
-
|
|
4066
|
+
ri,
|
|
4062
4067
|
{
|
|
4063
4068
|
fileSupports: r.fileSupportOption,
|
|
4064
4069
|
isDesktop: i,
|
|
@@ -4073,7 +4078,7 @@ const si = (t) => {
|
|
|
4073
4078
|
),
|
|
4074
4079
|
typeof r.errorMessage == "string" && r.errorMessage && /* @__PURE__ */ e(C, { color: "error", fontSize: "xs", children: r.errorMessage })
|
|
4075
4080
|
] });
|
|
4076
|
-
},
|
|
4081
|
+
}, ui = ({
|
|
4077
4082
|
size: t = "md",
|
|
4078
4083
|
direction: r = "vertical",
|
|
4079
4084
|
requiredTitle: n = "(Required)",
|
|
@@ -4090,7 +4095,7 @@ const si = (t) => {
|
|
|
4090
4095
|
...i.containerProps,
|
|
4091
4096
|
children: [
|
|
4092
4097
|
i.title && /* @__PURE__ */ e(
|
|
4093
|
-
|
|
4098
|
+
O,
|
|
4094
4099
|
{
|
|
4095
4100
|
condition: !!i.inputProps.required,
|
|
4096
4101
|
fallback: /* @__PURE__ */ d(
|
|
@@ -4115,7 +4120,7 @@ const si = (t) => {
|
|
|
4115
4120
|
/* @__PURE__ */ d($, { direction: "row", gap: "xs", align: "center", children: [
|
|
4116
4121
|
/* @__PURE__ */ e(N, { fontSize: t, children: i.title }),
|
|
4117
4122
|
/* @__PURE__ */ e(N, { color: "error", fontSize: t, children: n }),
|
|
4118
|
-
/* @__PURE__ */ e(
|
|
4123
|
+
/* @__PURE__ */ e(O, { condition: !!((a = i.tooltip) != null && a.label), children: /* @__PURE__ */ e(
|
|
4119
4124
|
ue,
|
|
4120
4125
|
{
|
|
4121
4126
|
label: (h = i.tooltip) == null ? void 0 : h.label,
|
|
@@ -4135,7 +4140,7 @@ const si = (t) => {
|
|
|
4135
4140
|
}
|
|
4136
4141
|
) })
|
|
4137
4142
|
] }),
|
|
4138
|
-
/* @__PURE__ */ e(
|
|
4143
|
+
/* @__PURE__ */ e(O, { condition: !!i.description, children: /* @__PURE__ */ e(C, { fontSize: t, color: "gray-500", children: i.description }) })
|
|
4139
4144
|
]
|
|
4140
4145
|
}
|
|
4141
4146
|
)
|
|
@@ -4143,7 +4148,7 @@ const si = (t) => {
|
|
|
4143
4148
|
),
|
|
4144
4149
|
/* @__PURE__ */ d($, { gap: "xs", children: [
|
|
4145
4150
|
/* @__PURE__ */ e(
|
|
4146
|
-
|
|
4151
|
+
hi,
|
|
4147
4152
|
{
|
|
4148
4153
|
...i.inputProps,
|
|
4149
4154
|
status: i.errorMessage ? "error" : "default"
|
|
@@ -4154,7 +4159,7 @@ const si = (t) => {
|
|
|
4154
4159
|
]
|
|
4155
4160
|
}
|
|
4156
4161
|
);
|
|
4157
|
-
},
|
|
4162
|
+
}, fi = ({
|
|
4158
4163
|
size: t = "md",
|
|
4159
4164
|
direction: r = "vertical",
|
|
4160
4165
|
requiredTitle: n = "(Required)",
|
|
@@ -4162,7 +4167,7 @@ const si = (t) => {
|
|
|
4162
4167
|
required: i = !1,
|
|
4163
4168
|
...o
|
|
4164
4169
|
}) => {
|
|
4165
|
-
var h, f, g,
|
|
4170
|
+
var h, f, g, p;
|
|
4166
4171
|
const s = o.hideMessageError || !1, a = r === "horizontal" ? t === "sm" ? 342 : t === "lg" ? 400 : 342 : void 0;
|
|
4167
4172
|
return /* @__PURE__ */ d(
|
|
4168
4173
|
u,
|
|
@@ -4172,7 +4177,7 @@ const si = (t) => {
|
|
|
4172
4177
|
...o.containerProps,
|
|
4173
4178
|
children: [
|
|
4174
4179
|
o.title && /* @__PURE__ */ e(
|
|
4175
|
-
|
|
4180
|
+
O,
|
|
4176
4181
|
{
|
|
4177
4182
|
condition: !!i,
|
|
4178
4183
|
fallback: /* @__PURE__ */ d(
|
|
@@ -4197,7 +4202,7 @@ const si = (t) => {
|
|
|
4197
4202
|
/* @__PURE__ */ d($, { direction: "row", gap: "xs", align: "center", children: [
|
|
4198
4203
|
/* @__PURE__ */ e(N, { fontSize: t, children: o.title }),
|
|
4199
4204
|
/* @__PURE__ */ e(N, { color: "error", fontSize: t, children: n }),
|
|
4200
|
-
/* @__PURE__ */ e(
|
|
4205
|
+
/* @__PURE__ */ e(O, { condition: !!((h = o.tooltip) != null && h.label), children: /* @__PURE__ */ e(
|
|
4201
4206
|
ue,
|
|
4202
4207
|
{
|
|
4203
4208
|
label: (f = o.tooltip) == null ? void 0 : f.label,
|
|
@@ -4217,7 +4222,7 @@ const si = (t) => {
|
|
|
4217
4222
|
}
|
|
4218
4223
|
) })
|
|
4219
4224
|
] }),
|
|
4220
|
-
/* @__PURE__ */ e(
|
|
4225
|
+
/* @__PURE__ */ e(O, { condition: !!o.description, children: /* @__PURE__ */ e(C, { fontSize: t, color: "gray-500", children: o.description }) })
|
|
4221
4226
|
]
|
|
4222
4227
|
}
|
|
4223
4228
|
)
|
|
@@ -4232,11 +4237,11 @@ const si = (t) => {
|
|
|
4232
4237
|
children: /* @__PURE__ */ e(
|
|
4233
4238
|
st,
|
|
4234
4239
|
{
|
|
4235
|
-
of: (
|
|
4236
|
-
...
|
|
4237
|
-
isChecked: o.checkBoxesAreChecked.includes(
|
|
4240
|
+
of: (p = o.checkBoxesList) == null ? void 0 : p.map((y) => ({
|
|
4241
|
+
...y,
|
|
4242
|
+
isChecked: o.checkBoxesAreChecked.includes(y.id)
|
|
4238
4243
|
})),
|
|
4239
|
-
render: (
|
|
4244
|
+
render: (y) => y.renderBadge ? /* @__PURE__ */ d(
|
|
4240
4245
|
u,
|
|
4241
4246
|
{
|
|
4242
4247
|
direction: "row",
|
|
@@ -4245,28 +4250,28 @@ const si = (t) => {
|
|
|
4245
4250
|
...o.badgeContainerProps,
|
|
4246
4251
|
children: [
|
|
4247
4252
|
/* @__PURE__ */ e(
|
|
4248
|
-
|
|
4253
|
+
et,
|
|
4249
4254
|
{
|
|
4250
|
-
name:
|
|
4251
|
-
value:
|
|
4252
|
-
checked:
|
|
4253
|
-
onChange: (b) => o.onChecked(b.target.value,
|
|
4254
|
-
label:
|
|
4255
|
-
description:
|
|
4255
|
+
name: y.name,
|
|
4256
|
+
value: y.id,
|
|
4257
|
+
checked: y.isChecked,
|
|
4258
|
+
onChange: (b) => o.onChecked(b.target.value, y),
|
|
4259
|
+
label: y.name,
|
|
4260
|
+
description: y.description
|
|
4256
4261
|
}
|
|
4257
4262
|
),
|
|
4258
|
-
|
|
4263
|
+
y.renderBadge
|
|
4259
4264
|
]
|
|
4260
4265
|
}
|
|
4261
4266
|
) : /* @__PURE__ */ e(
|
|
4262
|
-
|
|
4267
|
+
et,
|
|
4263
4268
|
{
|
|
4264
|
-
name:
|
|
4265
|
-
value:
|
|
4266
|
-
checked:
|
|
4267
|
-
onChange: (b) => o.onChecked(b.target.value,
|
|
4268
|
-
label:
|
|
4269
|
-
description:
|
|
4269
|
+
name: y.name,
|
|
4270
|
+
value: y.id,
|
|
4271
|
+
checked: y.isChecked,
|
|
4272
|
+
onChange: (b) => o.onChecked(b.target.value, y),
|
|
4273
|
+
label: y.name,
|
|
4274
|
+
description: y.description
|
|
4270
4275
|
}
|
|
4271
4276
|
)
|
|
4272
4277
|
}
|
|
@@ -4277,7 +4282,7 @@ const si = (t) => {
|
|
|
4277
4282
|
]
|
|
4278
4283
|
}
|
|
4279
4284
|
);
|
|
4280
|
-
},
|
|
4285
|
+
}, gi = ({
|
|
4281
4286
|
position: t = "vertical",
|
|
4282
4287
|
size: r = "md",
|
|
4283
4288
|
fullWidth: n = !1,
|
|
@@ -4291,7 +4296,7 @@ const si = (t) => {
|
|
|
4291
4296
|
gap: t === "horizontal-inline" || t === "horizontal-block" ? "spacing-96" : "sm",
|
|
4292
4297
|
direction: t === "horizontal-inline" || t === "horizontal-block" ? "row" : "column",
|
|
4293
4298
|
children: [
|
|
4294
|
-
/* @__PURE__ */ e(
|
|
4299
|
+
/* @__PURE__ */ e(O, { condition: !!l.description || !!l.title, children: /* @__PURE__ */ d(
|
|
4295
4300
|
u,
|
|
4296
4301
|
{
|
|
4297
4302
|
direction: "column",
|
|
@@ -4299,7 +4304,7 @@ const si = (t) => {
|
|
|
4299
4304
|
fullWidth: n,
|
|
4300
4305
|
children: [
|
|
4301
4306
|
l.title && /* @__PURE__ */ e(N, { children: l.title }),
|
|
4302
|
-
/* @__PURE__ */ e(
|
|
4307
|
+
/* @__PURE__ */ e(O, { condition: !!l.description, children: /* @__PURE__ */ e(C, { color: "gray-500", children: l.description }) })
|
|
4303
4308
|
]
|
|
4304
4309
|
}
|
|
4305
4310
|
) }),
|
|
@@ -4317,7 +4322,7 @@ const si = (t) => {
|
|
|
4317
4322
|
...s,
|
|
4318
4323
|
isChecked: l.radioIsChecked === s.id
|
|
4319
4324
|
})),
|
|
4320
|
-
render: ({ value: s, id: a, isChecked: h, subInput: f, label: g, description:
|
|
4325
|
+
render: ({ value: s, id: a, isChecked: h, subInput: f, label: g, description: p }) => /* @__PURE__ */ d(u, { gap: "xs", customMaxWidth: i, children: [
|
|
4321
4326
|
/* @__PURE__ */ e(
|
|
4322
4327
|
Gt,
|
|
4323
4328
|
{
|
|
@@ -4326,23 +4331,23 @@ const si = (t) => {
|
|
|
4326
4331
|
label: g,
|
|
4327
4332
|
value: s,
|
|
4328
4333
|
checked: h,
|
|
4329
|
-
onChange: (
|
|
4334
|
+
onChange: (y) => l.onChecked({
|
|
4330
4335
|
id: a,
|
|
4331
|
-
label:
|
|
4332
|
-
value:
|
|
4336
|
+
label: y.target.name,
|
|
4337
|
+
value: y.target.value
|
|
4333
4338
|
}),
|
|
4334
4339
|
disabled: l.disableAll
|
|
4335
4340
|
},
|
|
4336
4341
|
a
|
|
4337
4342
|
),
|
|
4338
|
-
|
|
4343
|
+
p && /* @__PURE__ */ e(
|
|
4339
4344
|
C,
|
|
4340
4345
|
{
|
|
4341
4346
|
color: "gray-500",
|
|
4342
4347
|
style: {
|
|
4343
4348
|
marginLeft: 28
|
|
4344
4349
|
},
|
|
4345
|
-
children:
|
|
4350
|
+
children: p
|
|
4346
4351
|
}
|
|
4347
4352
|
),
|
|
4348
4353
|
f
|
|
@@ -4355,7 +4360,7 @@ const si = (t) => {
|
|
|
4355
4360
|
]
|
|
4356
4361
|
}
|
|
4357
4362
|
);
|
|
4358
|
-
},
|
|
4363
|
+
}, mi = ({
|
|
4359
4364
|
size: t = "md",
|
|
4360
4365
|
direction: r = "vertical",
|
|
4361
4366
|
requiredTitle: n = "(Required)",
|
|
@@ -4372,7 +4377,7 @@ const si = (t) => {
|
|
|
4372
4377
|
...i.containerProps,
|
|
4373
4378
|
children: [
|
|
4374
4379
|
i.title && /* @__PURE__ */ e(
|
|
4375
|
-
|
|
4380
|
+
O,
|
|
4376
4381
|
{
|
|
4377
4382
|
condition: !!i.inputProps.required,
|
|
4378
4383
|
fallback: /* @__PURE__ */ d(
|
|
@@ -4397,7 +4402,7 @@ const si = (t) => {
|
|
|
4397
4402
|
/* @__PURE__ */ d($, { direction: "row", gap: "xs", align: "center", children: [
|
|
4398
4403
|
/* @__PURE__ */ e(N, { fontSize: t, children: i.title }),
|
|
4399
4404
|
/* @__PURE__ */ e(N, { color: "error", fontSize: t, children: n }),
|
|
4400
|
-
/* @__PURE__ */ e(
|
|
4405
|
+
/* @__PURE__ */ e(O, { condition: !!((a = i.tooltip) != null && a.label), children: /* @__PURE__ */ e(
|
|
4401
4406
|
ue,
|
|
4402
4407
|
{
|
|
4403
4408
|
label: (h = i.tooltip) == null ? void 0 : h.label,
|
|
@@ -4417,7 +4422,7 @@ const si = (t) => {
|
|
|
4417
4422
|
}
|
|
4418
4423
|
) })
|
|
4419
4424
|
] }),
|
|
4420
|
-
/* @__PURE__ */ e(
|
|
4425
|
+
/* @__PURE__ */ e(O, { condition: !!i.description, children: /* @__PURE__ */ e(C, { fontSize: t, color: "gray-500", children: i.description }) })
|
|
4421
4426
|
]
|
|
4422
4427
|
}
|
|
4423
4428
|
)
|
|
@@ -4438,7 +4443,7 @@ const si = (t) => {
|
|
|
4438
4443
|
]
|
|
4439
4444
|
}
|
|
4440
4445
|
);
|
|
4441
|
-
},
|
|
4446
|
+
}, pi = ({
|
|
4442
4447
|
size: t = "md",
|
|
4443
4448
|
direction: r = "vertical",
|
|
4444
4449
|
requiredTitle: n = "(Required)",
|
|
@@ -4456,7 +4461,7 @@ const si = (t) => {
|
|
|
4456
4461
|
...o.containerProps,
|
|
4457
4462
|
children: [
|
|
4458
4463
|
o.title && /* @__PURE__ */ e(
|
|
4459
|
-
|
|
4464
|
+
O,
|
|
4460
4465
|
{
|
|
4461
4466
|
condition: l,
|
|
4462
4467
|
fallback: /* @__PURE__ */ d(
|
|
@@ -4481,7 +4486,7 @@ const si = (t) => {
|
|
|
4481
4486
|
/* @__PURE__ */ d($, { direction: "row", gap: "xs", align: "center", children: [
|
|
4482
4487
|
/* @__PURE__ */ e(N, { fontSize: t, children: o.title }),
|
|
4483
4488
|
/* @__PURE__ */ e(N, { color: "error", fontSize: t, children: n }),
|
|
4484
|
-
/* @__PURE__ */ e(
|
|
4489
|
+
/* @__PURE__ */ e(O, { condition: !!((a = o.tooltip) != null && a.label), children: /* @__PURE__ */ e(
|
|
4485
4490
|
ue,
|
|
4486
4491
|
{
|
|
4487
4492
|
label: (h = o.tooltip) == null ? void 0 : h.label,
|
|
@@ -4501,7 +4506,7 @@ const si = (t) => {
|
|
|
4501
4506
|
}
|
|
4502
4507
|
) })
|
|
4503
4508
|
] }),
|
|
4504
|
-
/* @__PURE__ */ e(
|
|
4509
|
+
/* @__PURE__ */ e(O, { condition: !!o.titleDescription, children: /* @__PURE__ */ e(C, { fontSize: t, color: "gray-500", children: o.titleDescription }) })
|
|
4505
4510
|
]
|
|
4506
4511
|
}
|
|
4507
4512
|
)
|
|
@@ -4525,10 +4530,10 @@ const si = (t) => {
|
|
|
4525
4530
|
size: r = "md",
|
|
4526
4531
|
...n
|
|
4527
4532
|
}) => {
|
|
4528
|
-
const l =
|
|
4529
|
-
var h, f, g,
|
|
4533
|
+
const l = Jt(), i = (s) => {
|
|
4534
|
+
var h, f, g, p, y, b;
|
|
4530
4535
|
if (!s) return;
|
|
4531
|
-
const a = n.disabled ? "var(--sa-text-disable, #181a198f)" : t === "secondary" ? "var(--sa-text-subtle, #8c8f97)" : t === "secondary-danger" ? (f = (h = l == null ? void 0 : l.computed) == null ? void 0 : h.red) == null ? void 0 : f[600] : t === "secondary-primary" ? (
|
|
4536
|
+
const a = n.disabled ? "var(--sa-text-disable, #181a198f)" : t === "secondary" ? "var(--sa-text-subtle, #8c8f97)" : t === "secondary-danger" ? (f = (h = l == null ? void 0 : l.computed) == null ? void 0 : h.red) == null ? void 0 : f[600] : t === "secondary-primary" ? (p = (g = l == null ? void 0 : l.computed) == null ? void 0 : g.blue) == null ? void 0 : p[700] : (b = (y = l == null ? void 0 : l.computed) == null ? void 0 : y.gray) == null ? void 0 : b[50];
|
|
4532
4537
|
return /* @__PURE__ */ e(k, { name: s, size: r, style: { color: a } });
|
|
4533
4538
|
}, o = () => {
|
|
4534
4539
|
var a, h, f, g;
|
|
@@ -4565,7 +4570,7 @@ const si = (t) => {
|
|
|
4565
4570
|
children: o()
|
|
4566
4571
|
}
|
|
4567
4572
|
);
|
|
4568
|
-
},
|
|
4573
|
+
}, xi = (t) => /* @__PURE__ */ e(
|
|
4569
4574
|
me.H5,
|
|
4570
4575
|
{
|
|
4571
4576
|
props: {
|
|
@@ -4573,7 +4578,7 @@ const si = (t) => {
|
|
|
4573
4578
|
},
|
|
4574
4579
|
children: t.title
|
|
4575
4580
|
}
|
|
4576
|
-
),
|
|
4581
|
+
), Ci = ({
|
|
4577
4582
|
size: t = "md",
|
|
4578
4583
|
direction: r = "vertical",
|
|
4579
4584
|
requiredTitle: n = "(Required)",
|
|
@@ -4590,7 +4595,7 @@ const si = (t) => {
|
|
|
4590
4595
|
onClick: i.onClickContainer,
|
|
4591
4596
|
children: [
|
|
4592
4597
|
i.title && /* @__PURE__ */ e(
|
|
4593
|
-
|
|
4598
|
+
O,
|
|
4594
4599
|
{
|
|
4595
4600
|
condition: !!i.inputProps.required,
|
|
4596
4601
|
fallback: /* @__PURE__ */ d(
|
|
@@ -4615,7 +4620,7 @@ const si = (t) => {
|
|
|
4615
4620
|
/* @__PURE__ */ d($, { direction: "row", gap: "xs", align: "center", children: [
|
|
4616
4621
|
/* @__PURE__ */ e(N, { fontSize: t, children: i.title }),
|
|
4617
4622
|
/* @__PURE__ */ e(N, { color: "error", fontSize: t, children: n }),
|
|
4618
|
-
/* @__PURE__ */ e(
|
|
4623
|
+
/* @__PURE__ */ e(O, { condition: !!((a = i.tooltip) != null && a.label), children: /* @__PURE__ */ e(
|
|
4619
4624
|
ue,
|
|
4620
4625
|
{
|
|
4621
4626
|
label: (h = i.tooltip) == null ? void 0 : h.label,
|
|
@@ -4635,7 +4640,7 @@ const si = (t) => {
|
|
|
4635
4640
|
}
|
|
4636
4641
|
) })
|
|
4637
4642
|
] }),
|
|
4638
|
-
/* @__PURE__ */ e(
|
|
4643
|
+
/* @__PURE__ */ e(O, { condition: !!i.description, children: /* @__PURE__ */ e(C, { fontSize: t, color: "gray-500", children: i.description }) })
|
|
4639
4644
|
]
|
|
4640
4645
|
}
|
|
4641
4646
|
)
|
|
@@ -4664,7 +4669,7 @@ const si = (t) => {
|
|
|
4664
4669
|
}
|
|
4665
4670
|
);
|
|
4666
4671
|
};
|
|
4667
|
-
async function
|
|
4672
|
+
async function Di(t, r) {
|
|
4668
4673
|
const n = new Image();
|
|
4669
4674
|
n.src = t, await new Promise((o, s) => {
|
|
4670
4675
|
n.onload = o, n.onerror = s;
|
|
@@ -4700,7 +4705,7 @@ const Ct = {
|
|
|
4700
4705
|
"2:3": 2 / 3,
|
|
4701
4706
|
"3:2": 3 / 2,
|
|
4702
4707
|
"32:9": 32 / 9
|
|
4703
|
-
},
|
|
4708
|
+
}, bi = Mt(
|
|
4704
4709
|
({
|
|
4705
4710
|
handleUpload: t,
|
|
4706
4711
|
urlImage: r,
|
|
@@ -4713,34 +4718,34 @@ const Ct = {
|
|
|
4713
4718
|
maxFileSize: h = 2,
|
|
4714
4719
|
onError: f
|
|
4715
4720
|
}, g) => {
|
|
4716
|
-
const
|
|
4721
|
+
const p = ee("md"), [y, b] = A(!1), [H, D] = A(null), [T, Z] = A(!1), [j, J] = A({ x: 0, y: 0 }), [M, fe] = A(1), [G, V] = A(null);
|
|
4717
4722
|
U(() => {
|
|
4718
4723
|
r === null && i(null);
|
|
4719
4724
|
}, [r]);
|
|
4720
4725
|
const K = Ve(
|
|
4721
|
-
(
|
|
4722
|
-
V(
|
|
4726
|
+
(z, I) => {
|
|
4727
|
+
V(I);
|
|
4723
4728
|
},
|
|
4724
4729
|
[]
|
|
4725
|
-
), oe = (
|
|
4730
|
+
), oe = (z) => {
|
|
4726
4731
|
var de;
|
|
4727
|
-
const
|
|
4728
|
-
if (!
|
|
4732
|
+
const I = (de = z.target.files) == null ? void 0 : de[0];
|
|
4733
|
+
if (!I) return;
|
|
4729
4734
|
const Y = new FileReader();
|
|
4730
4735
|
Y.onload = () => {
|
|
4731
4736
|
D(Y.result), Z(!0);
|
|
4732
|
-
}, Y.readAsDataURL(
|
|
4737
|
+
}, Y.readAsDataURL(I);
|
|
4733
4738
|
}, ce = async () => {
|
|
4734
4739
|
if (!(!H || !G))
|
|
4735
4740
|
try {
|
|
4736
|
-
const
|
|
4737
|
-
if (h &&
|
|
4741
|
+
const z = await Di(H, G);
|
|
4742
|
+
if (h && z.size > h * 1024 * 1024) {
|
|
4738
4743
|
f == null || f(`Ukuran file maksimal ${h}MB`);
|
|
4739
4744
|
return;
|
|
4740
4745
|
}
|
|
4741
|
-
t == null || t(
|
|
4742
|
-
const
|
|
4743
|
-
i(
|
|
4746
|
+
t == null || t(z);
|
|
4747
|
+
const I = URL.createObjectURL(z);
|
|
4748
|
+
i(I, z), Z(!1);
|
|
4744
4749
|
} catch {
|
|
4745
4750
|
f == null || f("Gagal memproses gambar");
|
|
4746
4751
|
}
|
|
@@ -4749,13 +4754,13 @@ const Ct = {
|
|
|
4749
4754
|
};
|
|
4750
4755
|
Yt(g, () => ({
|
|
4751
4756
|
openFileDialog: () => {
|
|
4752
|
-
var
|
|
4753
|
-
(
|
|
4757
|
+
var z;
|
|
4758
|
+
(z = _.current) == null || z.click();
|
|
4754
4759
|
}
|
|
4755
4760
|
}));
|
|
4756
4761
|
const se = parseInt(o, 10), re = Ct[s];
|
|
4757
|
-
let Q,
|
|
4758
|
-
return re >= 1 ? (
|
|
4762
|
+
let Q, q;
|
|
4763
|
+
return re >= 1 ? (q = se, Q = se * re) : (Q = se, q = se / re), /* @__PURE__ */ d(
|
|
4759
4764
|
u,
|
|
4760
4765
|
{
|
|
4761
4766
|
display: "flex",
|
|
@@ -4770,7 +4775,7 @@ const Ct = {
|
|
|
4770
4775
|
justify: "center",
|
|
4771
4776
|
style: {
|
|
4772
4777
|
width: a != null && a.fullWidth ? "100%" : `${Q}px`,
|
|
4773
|
-
height: a != null && a.fullWidth ? "auto" : `${
|
|
4778
|
+
height: a != null && a.fullWidth ? "auto" : `${q}px`,
|
|
4774
4779
|
aspectRatio: re,
|
|
4775
4780
|
flexShrink: 0
|
|
4776
4781
|
},
|
|
@@ -4820,7 +4825,7 @@ const Ct = {
|
|
|
4820
4825
|
style: {
|
|
4821
4826
|
inset: 0,
|
|
4822
4827
|
backgroundColor: "var(--sa-color-black-alpha-a30, #080f214a)",
|
|
4823
|
-
opacity:
|
|
4828
|
+
opacity: y ? 1 : 0,
|
|
4824
4829
|
transition: "opacity 0.3s ease-in-out"
|
|
4825
4830
|
},
|
|
4826
4831
|
onClick: ae,
|
|
@@ -4844,7 +4849,7 @@ const Ct = {
|
|
|
4844
4849
|
style: { color: "var(--sa-background-primary, #ffffff)" }
|
|
4845
4850
|
}
|
|
4846
4851
|
),
|
|
4847
|
-
/* @__PURE__ */ e(
|
|
4852
|
+
/* @__PURE__ */ e(O, { condition: o.toNumber() > 80, children: /* @__PURE__ */ e(
|
|
4848
4853
|
C,
|
|
4849
4854
|
{
|
|
4850
4855
|
color: "gray-50",
|
|
@@ -4884,53 +4889,88 @@ const Ct = {
|
|
|
4884
4889
|
)
|
|
4885
4890
|
}
|
|
4886
4891
|
),
|
|
4887
|
-
|
|
4888
|
-
|
|
4889
|
-
|
|
4890
|
-
|
|
4891
|
-
|
|
4892
|
-
|
|
4893
|
-
|
|
4894
|
-
|
|
4895
|
-
|
|
4896
|
-
|
|
4897
|
-
|
|
4892
|
+
T && Kt.createPortal(
|
|
4893
|
+
/* @__PURE__ */ e(
|
|
4894
|
+
"div",
|
|
4895
|
+
{
|
|
4896
|
+
style: {
|
|
4897
|
+
position: "fixed",
|
|
4898
|
+
inset: 0,
|
|
4899
|
+
zIndex: 19999,
|
|
4900
|
+
display: "flex",
|
|
4901
|
+
alignItems: "center",
|
|
4902
|
+
justifyContent: "center",
|
|
4903
|
+
backgroundColor: "rgba(0,0,0,0.6)"
|
|
4904
|
+
},
|
|
4905
|
+
onClick: () => Z(!1),
|
|
4906
|
+
children: /* @__PURE__ */ d(
|
|
4907
|
+
"div",
|
|
4898
4908
|
{
|
|
4899
|
-
position: "relative",
|
|
4900
4909
|
style: {
|
|
4901
|
-
|
|
4902
|
-
|
|
4903
|
-
|
|
4910
|
+
backgroundColor: "var(--sa-background-primary)",
|
|
4911
|
+
borderRadius: "var(--sa-radii-md)",
|
|
4912
|
+
boxShadow: "0 20px 60px rgba(0,0,0,0.3)",
|
|
4913
|
+
overflow: "hidden",
|
|
4914
|
+
width: p ? s === "1:1" ? "min(90vw, 480px)" : `min(90vw, ${Q * 2}px)` : "calc(100vw - 2rem)",
|
|
4915
|
+
display: "flex",
|
|
4916
|
+
flexDirection: "column"
|
|
4904
4917
|
},
|
|
4905
|
-
|
|
4906
|
-
|
|
4907
|
-
|
|
4908
|
-
|
|
4909
|
-
|
|
4910
|
-
|
|
4911
|
-
|
|
4912
|
-
|
|
4913
|
-
|
|
4914
|
-
|
|
4915
|
-
|
|
4916
|
-
|
|
4917
|
-
|
|
4918
|
-
|
|
4919
|
-
|
|
4918
|
+
onClick: (z) => z.stopPropagation(),
|
|
4919
|
+
children: [
|
|
4920
|
+
/* @__PURE__ */ e(
|
|
4921
|
+
"div",
|
|
4922
|
+
{
|
|
4923
|
+
style: {
|
|
4924
|
+
position: "relative",
|
|
4925
|
+
width: "100%",
|
|
4926
|
+
height: "20rem",
|
|
4927
|
+
backgroundColor: "var(--sa-color-gray-100)"
|
|
4928
|
+
},
|
|
4929
|
+
children: H && /* @__PURE__ */ e(
|
|
4930
|
+
er,
|
|
4931
|
+
{
|
|
4932
|
+
image: H,
|
|
4933
|
+
crop: j,
|
|
4934
|
+
zoom: M,
|
|
4935
|
+
aspect: s ? Ct[s] : void 0,
|
|
4936
|
+
onCropChange: J,
|
|
4937
|
+
onZoomChange: fe,
|
|
4938
|
+
onCropComplete: K,
|
|
4939
|
+
objectFit: "contain",
|
|
4940
|
+
minZoom: 0.5,
|
|
4941
|
+
restrictPosition: !1
|
|
4942
|
+
}
|
|
4943
|
+
)
|
|
4944
|
+
}
|
|
4945
|
+
),
|
|
4946
|
+
/* @__PURE__ */ d(
|
|
4947
|
+
"div",
|
|
4948
|
+
{
|
|
4949
|
+
style: {
|
|
4950
|
+
display: "flex",
|
|
4951
|
+
justifyContent: "flex-end",
|
|
4952
|
+
gap: "0.5rem",
|
|
4953
|
+
padding: "0.75rem 1rem",
|
|
4954
|
+
borderTop: "1px solid var(--sa-border-subtle)"
|
|
4955
|
+
},
|
|
4956
|
+
children: [
|
|
4957
|
+
/* @__PURE__ */ e(B, { size: "sm", secondary: !0, onClick: () => Z(!1), children: "Cancel" }),
|
|
4958
|
+
/* @__PURE__ */ e(B, { size: "sm", primary: !0, onClick: ce, children: "Crop" })
|
|
4959
|
+
]
|
|
4960
|
+
}
|
|
4961
|
+
)
|
|
4962
|
+
]
|
|
4920
4963
|
}
|
|
4921
|
-
)
|
|
4922
|
-
|
|
4923
|
-
|
|
4924
|
-
|
|
4925
|
-
] }) })
|
|
4926
|
-
]
|
|
4927
|
-
}
|
|
4964
|
+
)
|
|
4965
|
+
}
|
|
4966
|
+
),
|
|
4967
|
+
document.body
|
|
4928
4968
|
)
|
|
4929
4969
|
]
|
|
4930
4970
|
}
|
|
4931
4971
|
);
|
|
4932
4972
|
}
|
|
4933
|
-
),
|
|
4973
|
+
), vi = ({
|
|
4934
4974
|
size: t = "md",
|
|
4935
4975
|
direction: r = "vertical",
|
|
4936
4976
|
requiredTitle: n = "(Required)",
|
|
@@ -4948,7 +4988,7 @@ const Ct = {
|
|
|
4948
4988
|
...o.containerProps,
|
|
4949
4989
|
children: [
|
|
4950
4990
|
o.title && /* @__PURE__ */ e(
|
|
4951
|
-
|
|
4991
|
+
O,
|
|
4952
4992
|
{
|
|
4953
4993
|
condition: !!i,
|
|
4954
4994
|
fallback: /* @__PURE__ */ d(
|
|
@@ -4973,7 +5013,7 @@ const Ct = {
|
|
|
4973
5013
|
/* @__PURE__ */ d($, { direction: "row", gap: "xs", align: "center", children: [
|
|
4974
5014
|
/* @__PURE__ */ e(N, { fontSize: t, children: o.title }),
|
|
4975
5015
|
/* @__PURE__ */ e(N, { color: "error", fontSize: t, children: n }),
|
|
4976
|
-
/* @__PURE__ */ e(
|
|
5016
|
+
/* @__PURE__ */ e(O, { condition: !!((h = o.tooltip) != null && h.label), children: /* @__PURE__ */ e(
|
|
4977
5017
|
ue,
|
|
4978
5018
|
{
|
|
4979
5019
|
label: (f = o.tooltip) == null ? void 0 : f.label,
|
|
@@ -4993,20 +5033,20 @@ const Ct = {
|
|
|
4993
5033
|
}
|
|
4994
5034
|
) })
|
|
4995
5035
|
] }),
|
|
4996
|
-
/* @__PURE__ */ e(
|
|
5036
|
+
/* @__PURE__ */ e(O, { condition: !!o.description, children: /* @__PURE__ */ e(C, { fontSize: t, color: "gray-500", children: o.description }) })
|
|
4997
5037
|
]
|
|
4998
5038
|
}
|
|
4999
5039
|
)
|
|
5000
5040
|
}
|
|
5001
5041
|
),
|
|
5002
5042
|
/* @__PURE__ */ d($, { gap: "xs", children: [
|
|
5003
|
-
/* @__PURE__ */ e(
|
|
5043
|
+
/* @__PURE__ */ e(bi, { ...o.inputProps }),
|
|
5004
5044
|
!s && o.errorMessage && /* @__PURE__ */ e(Ce, { message: o.errorMessage })
|
|
5005
5045
|
] })
|
|
5006
5046
|
]
|
|
5007
5047
|
}
|
|
5008
5048
|
);
|
|
5009
|
-
},
|
|
5049
|
+
}, wi = ({
|
|
5010
5050
|
size: t = "md",
|
|
5011
5051
|
direction: r = "vertical",
|
|
5012
5052
|
requiredTitle: n = "(Required)",
|
|
@@ -5023,7 +5063,7 @@ const Ct = {
|
|
|
5023
5063
|
...i.containerProps,
|
|
5024
5064
|
children: [
|
|
5025
5065
|
i.title && /* @__PURE__ */ e(
|
|
5026
|
-
|
|
5066
|
+
O,
|
|
5027
5067
|
{
|
|
5028
5068
|
condition: !!i.inputProps.required,
|
|
5029
5069
|
fallback: /* @__PURE__ */ d(
|
|
@@ -5048,7 +5088,7 @@ const Ct = {
|
|
|
5048
5088
|
/* @__PURE__ */ d($, { direction: "row", gap: "xs", align: "center", children: [
|
|
5049
5089
|
/* @__PURE__ */ e(N, { fontSize: t, children: i.title }),
|
|
5050
5090
|
/* @__PURE__ */ e(N, { color: "error", fontSize: t, children: n }),
|
|
5051
|
-
/* @__PURE__ */ e(
|
|
5091
|
+
/* @__PURE__ */ e(O, { condition: !!((s = i.tooltip) != null && s.label), children: /* @__PURE__ */ e(
|
|
5052
5092
|
ue,
|
|
5053
5093
|
{
|
|
5054
5094
|
label: (a = i.tooltip) == null ? void 0 : a.label,
|
|
@@ -5068,7 +5108,7 @@ const Ct = {
|
|
|
5068
5108
|
}
|
|
5069
5109
|
) })
|
|
5070
5110
|
] }),
|
|
5071
|
-
/* @__PURE__ */ e(
|
|
5111
|
+
/* @__PURE__ */ e(O, { condition: !!i.description, children: /* @__PURE__ */ e(C, { fontSize: t, color: "gray-500", children: i.description }) })
|
|
5072
5112
|
]
|
|
5073
5113
|
}
|
|
5074
5114
|
)
|
|
@@ -5078,7 +5118,7 @@ const Ct = {
|
|
|
5078
5118
|
]
|
|
5079
5119
|
}
|
|
5080
5120
|
);
|
|
5081
|
-
},
|
|
5121
|
+
}, On = ({
|
|
5082
5122
|
items: t,
|
|
5083
5123
|
id: r,
|
|
5084
5124
|
handleOnUpdate: n,
|
|
@@ -5089,11 +5129,11 @@ const Ct = {
|
|
|
5089
5129
|
var g;
|
|
5090
5130
|
const [s, a] = A([]);
|
|
5091
5131
|
U(() => {
|
|
5092
|
-
t && a([...t.map((
|
|
5132
|
+
t && a([...t.map((p) => ({ id: p.id, isActive: p.isActive }))]);
|
|
5093
5133
|
}, [t]);
|
|
5094
|
-
const h = (g = s.find((
|
|
5134
|
+
const h = (g = s.find((p) => p.id === r)) == null ? void 0 : g.isActive, f = Ve(() => {
|
|
5095
5135
|
a(
|
|
5096
|
-
(
|
|
5136
|
+
(p) => p.map((y) => y.id === r ? { ...y, isActive: !y.isActive } : y)
|
|
5097
5137
|
), n && n(!h);
|
|
5098
5138
|
}, [r, n, h]);
|
|
5099
5139
|
return /* @__PURE__ */ e(
|
|
@@ -5115,20 +5155,20 @@ const Ct = {
|
|
|
5115
5155
|
)
|
|
5116
5156
|
}
|
|
5117
5157
|
);
|
|
5118
|
-
},
|
|
5119
|
-
InputText:
|
|
5120
|
-
InputDropdown:
|
|
5121
|
-
InputSingleFile:
|
|
5122
|
-
CheckBoxOptions:
|
|
5123
|
-
RadioOptions:
|
|
5124
|
-
InputTextArea:
|
|
5125
|
-
ToggleForm:
|
|
5158
|
+
}, Nn = {
|
|
5159
|
+
InputText: Kr,
|
|
5160
|
+
InputDropdown: ei,
|
|
5161
|
+
InputSingleFile: ui,
|
|
5162
|
+
CheckBoxOptions: fi,
|
|
5163
|
+
RadioOptions: gi,
|
|
5164
|
+
InputTextArea: mi,
|
|
5165
|
+
ToggleForm: pi,
|
|
5126
5166
|
ActionButton: yi,
|
|
5127
|
-
FormTitle:
|
|
5128
|
-
InputDate:
|
|
5129
|
-
InputImgFile:
|
|
5130
|
-
Custom:
|
|
5131
|
-
},
|
|
5167
|
+
FormTitle: xi,
|
|
5168
|
+
InputDate: Ci,
|
|
5169
|
+
InputImgFile: vi,
|
|
5170
|
+
Custom: wi
|
|
5171
|
+
}, ki = ({ customBottom: t }) => {
|
|
5132
5172
|
const [r, n] = A(!1), l = () => {
|
|
5133
5173
|
window.scrollY > window.screenY ? n(!0) : n(!1);
|
|
5134
5174
|
}, i = () => {
|
|
@@ -5178,7 +5218,7 @@ const Ct = {
|
|
|
5178
5218
|
)
|
|
5179
5219
|
}
|
|
5180
5220
|
);
|
|
5181
|
-
},
|
|
5221
|
+
}, Zn = ({ pageLayout: t, children: r }) => {
|
|
5182
5222
|
const n = ee("lg");
|
|
5183
5223
|
return /* @__PURE__ */ d(
|
|
5184
5224
|
u,
|
|
@@ -5217,7 +5257,7 @@ const Ct = {
|
|
|
5217
5257
|
]
|
|
5218
5258
|
}
|
|
5219
5259
|
);
|
|
5220
|
-
},
|
|
5260
|
+
}, jn = ({
|
|
5221
5261
|
children: t,
|
|
5222
5262
|
withScrollToTopButton: r = !1,
|
|
5223
5263
|
scrollToTopButtonProps: n,
|
|
@@ -5244,7 +5284,7 @@ const Ct = {
|
|
|
5244
5284
|
borderWidth: "border-t",
|
|
5245
5285
|
children: [
|
|
5246
5286
|
r && /* @__PURE__ */ e(
|
|
5247
|
-
|
|
5287
|
+
ki,
|
|
5248
5288
|
{
|
|
5249
5289
|
...n,
|
|
5250
5290
|
customBottom: (n == null ? void 0 : n.customBottom) || "5.7rem"
|
|
@@ -5253,23 +5293,23 @@ const Ct = {
|
|
|
5253
5293
|
t
|
|
5254
5294
|
]
|
|
5255
5295
|
}
|
|
5256
|
-
) }),
|
|
5296
|
+
) }), $n = ({ fields: t }) => /* @__PURE__ */ e(u, { display: "flex", direction: "column", gap: "lg", children: /* @__PURE__ */ e(
|
|
5257
5297
|
st,
|
|
5258
5298
|
{
|
|
5259
5299
|
of: t,
|
|
5260
|
-
render: (r, n) => /* @__PURE__ */ e(
|
|
5300
|
+
render: (r, n) => /* @__PURE__ */ e(Fi, { ...r }, n)
|
|
5261
5301
|
}
|
|
5262
|
-
) }),
|
|
5302
|
+
) }), Fi = ({ title: t, value: r, icon: n }) => /* @__PURE__ */ d(u, { display: "flex", direction: "column", gap: "sm", children: [
|
|
5263
5303
|
n ? /* @__PURE__ */ d(u, { display: "flex", direction: "row", align: "center", gap: "xs", children: [
|
|
5264
5304
|
/* @__PURE__ */ e(k, { name: n, color: "subtle" }),
|
|
5265
5305
|
/* @__PURE__ */ e(C, { color: "gray-500", variant: "sub-h3", children: t })
|
|
5266
5306
|
] }) : /* @__PURE__ */ e(C, { color: "gray-500", variant: "sub-h3", children: t }),
|
|
5267
5307
|
typeof r == "string" ? /* @__PURE__ */ e(C, { variant: "sub-h3", children: r }) : r
|
|
5268
|
-
] }),
|
|
5308
|
+
] }), P = {
|
|
5269
5309
|
silhouette: "#A7B0AC",
|
|
5270
5310
|
accent: "#78867F"
|
|
5271
5311
|
};
|
|
5272
|
-
function
|
|
5312
|
+
function Si({ width: t, height: r }) {
|
|
5273
5313
|
return /* @__PURE__ */ e(X, { children: /* @__PURE__ */ d(
|
|
5274
5314
|
"svg",
|
|
5275
5315
|
{
|
|
@@ -5283,112 +5323,112 @@ function Fi({ width: t, height: r }) {
|
|
|
5283
5323
|
"path",
|
|
5284
5324
|
{
|
|
5285
5325
|
d: "M51.0002 16.8145C36.0811 16.8145 24.8296 21.3801 24.8296 27.4328V76.5344C24.8296 82.573 36.0799 87.127 51.0002 87.127C65.9204 87.127 77.1707 82.573 77.1707 76.5344V27.4328C77.1707 21.3801 65.9204 16.8145 51.0002 16.8145ZM51.0002 19.1582C65.0602 19.1582 74.8582 23.5187 74.8582 27.4328C74.8582 30.1363 70.1615 32.9664 63.1708 34.4746C55.861 36.0543 46.1416 36.0543 38.8318 34.4746C31.8399 32.9664 27.1432 30.1363 27.1432 27.4328C27.1432 23.5187 36.9402 19.1582 51.0002 19.1582ZM74.8582 31.9199V43.784C74.8582 46.532 70.3142 49.2941 63.2737 50.8328C63.2391 50.8375 63.2032 50.8434 63.1697 50.8504C57.6867 52.0352 50.8498 52.3305 44.6893 51.7387C42.6358 51.5418 40.6575 51.2453 38.8306 50.8504C38.8029 50.8445 38.7682 50.8387 38.7347 50.8352C32.5707 49.4898 28.318 47.2047 27.3514 44.8141C27.2138 44.4719 27.1421 44.1285 27.1421 43.7852V31.9199C27.1999 31.9715 27.2693 32.0207 27.3294 32.0723C27.5052 32.2246 27.6902 32.3758 27.8844 32.5234C27.9954 32.609 28.1064 32.6934 28.2232 32.7766C28.4371 32.9301 28.6637 33.0801 28.8973 33.2289C29.0083 33.2992 29.1135 33.3719 29.2291 33.441C29.5702 33.6473 29.9275 33.8488 30.3044 34.0434C30.3195 34.0516 30.3333 34.0598 30.3484 34.068C30.7427 34.2707 31.1601 34.4652 31.5925 34.6551C31.7301 34.716 31.8758 34.7734 32.0168 34.832C32.3221 34.9598 32.6331 35.0852 32.9557 35.207C33.1303 35.2727 33.3095 35.3359 33.4887 35.4004C33.8032 35.5117 34.1247 35.6207 34.4542 35.7273C34.6404 35.7871 34.8254 35.8469 35.015 35.9043C35.3734 36.0133 35.7434 36.1164 36.1181 36.2184C36.2915 36.2652 36.4603 36.3145 36.6361 36.3602C37.1911 36.5031 37.7588 36.6402 38.3485 36.7668C42.1595 37.5906 46.5336 38.0254 50.999 38.0254C55.4644 38.0254 59.8397 37.5906 63.6495 36.768C64.2404 36.6402 64.8092 36.5031 65.3666 36.3602C65.5377 36.3156 65.7007 36.2688 65.8684 36.223C66.2499 36.1199 66.6246 36.0145 66.9888 35.9031C67.1749 35.8469 67.3553 35.7883 67.5368 35.7309C67.8745 35.623 68.2028 35.5105 68.5243 35.3969C68.6966 35.3359 68.8677 35.275 69.0353 35.2117C69.3672 35.0863 69.6852 34.9574 69.9985 34.8262C70.1326 34.7699 70.2725 34.7148 70.4032 34.6574C70.8379 34.4664 71.2576 34.2707 71.6542 34.0668C71.66 34.0633 71.6658 34.0609 71.6716 34.0574C72.0589 33.8582 72.4243 33.6508 72.7735 33.441C72.8868 33.3719 72.9909 33.3016 73.1007 33.2313C73.3354 33.0813 73.5632 32.9312 73.7794 32.7766C73.8951 32.6934 74.0049 32.609 74.1159 32.5258C74.3102 32.377 74.4963 32.2258 74.6732 32.0723C74.7322 32.0207 74.8027 31.9727 74.8594 31.9211L74.8582 31.9199ZM74.8582 48.2887V60.1598C74.8582 62.8773 70.3396 65.6359 63.335 67.2004C63.2737 67.2051 63.2136 67.2156 63.1547 67.2285C59.5021 68.016 55.2482 68.4109 50.9955 68.4098C48.8692 68.4098 46.7428 68.3113 44.6917 68.1145C42.6405 67.9176 40.6656 67.6211 38.8399 67.2273C38.7832 67.2133 38.7266 67.2051 38.6699 67.2004C31.663 65.6359 27.1432 62.8785 27.1432 60.1598V48.2887C27.2022 48.3426 27.2739 48.393 27.3352 48.4457C27.5075 48.5945 27.6878 48.7422 27.8763 48.8875C27.9908 48.9754 28.1052 49.0633 28.2255 49.15C28.4348 49.3 28.6568 49.4477 28.8834 49.593C28.999 49.6668 29.1089 49.7418 29.228 49.8145C29.5633 50.0172 29.9136 50.2152 30.2825 50.4074C30.3114 50.4227 30.338 50.4379 30.3669 50.452C30.7507 50.6488 31.1566 50.8398 31.5775 51.0262C31.722 51.0895 31.8746 51.1504 32.0226 51.2125C32.3198 51.3379 32.6227 51.4609 32.9372 51.5793C33.1164 51.6473 33.2991 51.7129 33.4841 51.7785C33.7917 51.8887 34.1073 51.9953 34.4299 52.0996C34.6196 52.1605 34.8092 52.2227 35.0046 52.2812C35.3584 52.3891 35.7238 52.4922 36.0938 52.593C36.2684 52.641 36.4395 52.6902 36.6176 52.7359C37.1714 52.8789 37.738 53.016 38.3253 53.1426C38.3554 53.1496 38.3889 53.1555 38.4236 53.159C42.2161 53.9723 46.5636 54.4023 51.0013 54.4023C55.439 54.4023 59.7784 53.9734 63.5697 53.1613C63.6056 53.1566 63.6414 53.1508 63.6773 53.1426C64.2647 53.0148 64.8312 52.8789 65.3851 52.7359C65.5643 52.6902 65.7342 52.6398 65.9088 52.593C66.2788 52.4922 66.6442 52.3891 66.998 52.2812C67.1934 52.2215 67.3831 52.1605 67.5727 52.0996C67.8953 51.9953 68.2109 51.8887 68.5185 51.7785C68.7023 51.7129 68.8862 51.6473 69.0654 51.5793C69.3799 51.4598 69.6817 51.3367 69.98 51.2125C70.128 51.1504 70.2806 51.0895 70.4252 51.0262C70.846 50.841 71.2507 50.65 71.6357 50.452C71.6646 50.4367 71.6912 50.4215 71.7201 50.4074C72.0901 50.2152 72.4405 50.0172 72.7747 49.8145C72.8949 49.7418 73.0036 49.6668 73.1192 49.593C73.347 49.4477 73.5678 49.3 73.7771 49.15C73.8974 49.0633 74.0118 48.9766 74.1263 48.8875C74.3148 48.7422 74.4952 48.5945 74.6674 48.4457C74.7287 48.393 74.7992 48.3426 74.8582 48.2887ZM74.8582 76.5355C74.8582 80.4367 65.0602 84.7844 51.0002 84.7844C36.9402 84.7844 27.1421 80.4367 27.1421 76.5355V64.6469C27.1987 64.6984 27.2693 64.7477 27.3282 64.7992C27.5028 64.9504 27.6844 65.0992 27.8763 65.2469C27.9873 65.3324 28.0995 65.418 28.2162 65.5023C28.4302 65.6559 28.6568 65.807 28.8892 65.9559C28.9979 66.0262 29.1019 66.0977 29.2152 66.1656C29.5691 66.3801 29.9367 66.591 30.3299 66.7937C30.331 66.7937 30.3322 66.7938 30.3333 66.7961C30.7253 66.9988 31.1404 67.1945 31.5694 67.3855C31.7058 67.4465 31.8515 67.5039 31.9914 67.5637C32.2955 67.6926 32.6054 67.8191 32.928 67.9422C33.1002 68.0078 33.2772 68.0711 33.4541 68.1355C33.7674 68.248 34.0888 68.3582 34.4184 68.466C34.6034 68.5258 34.7872 68.5867 34.9768 68.6453C35.3341 68.7555 35.703 68.8609 36.0764 68.9641C36.2476 69.0109 36.4141 69.0602 36.5887 69.1059C37.1413 69.2512 37.7079 69.3895 38.2941 69.5195C38.3462 69.5312 38.3993 69.5383 38.4514 69.543C42.2369 70.3516 46.5717 70.7793 50.999 70.7793C55.4263 70.7793 59.7599 70.3527 63.5478 69.543C63.5998 69.5383 63.653 69.5312 63.705 69.5195C64.2912 69.3906 64.8578 69.2512 65.4105 69.1059C65.5839 69.0602 65.7493 69.0121 65.9192 68.9652C66.295 68.8621 66.665 68.7555 67.0246 68.6453C67.2131 68.5879 67.3958 68.5281 67.5785 68.4684C67.9092 68.3605 68.2329 68.2492 68.5486 68.1355C68.7231 68.0723 68.8977 68.009 69.0689 67.9445C69.3938 67.8203 69.7071 67.6926 70.0135 67.5625C70.1511 67.5039 70.2933 67.4477 70.4275 67.3879C71.29 67.0047 72.0774 66.5969 72.7851 66.1668C72.8972 66.0988 73.0001 66.0273 73.1088 65.9582C73.3424 65.8082 73.5702 65.657 73.7852 65.5023C73.9008 65.4191 74.0118 65.3336 74.1217 65.2492C74.3148 65.1016 74.4975 64.9516 74.6732 64.7992C74.7322 64.7488 74.8016 64.6996 74.8582 64.648V76.5355Z",
|
|
5286
|
-
fill:
|
|
5326
|
+
fill: P.silhouette
|
|
5287
5327
|
}
|
|
5288
5328
|
),
|
|
5289
5329
|
/* @__PURE__ */ e(
|
|
5290
5330
|
"path",
|
|
5291
5331
|
{
|
|
5292
5332
|
d: "M33.2089 38.8535C31.3993 38.8535 29.9263 40.3453 29.9263 42.1805C29.9263 44.0156 31.3982 45.5062 33.2089 45.5062C35.0196 45.5062 36.4903 44.0145 36.4903 42.1805C36.4903 40.3465 35.0184 38.8535 33.2089 38.8535ZM33.2089 43.1625C32.6735 43.1625 32.2388 42.7219 32.2388 42.1805C32.2388 41.6391 32.6735 41.1973 33.2089 41.1973C33.7442 41.1973 34.1778 41.6379 34.1778 42.1805C34.1778 42.723 33.7431 43.1625 33.2089 43.1625Z",
|
|
5293
|
-
fill:
|
|
5333
|
+
fill: P.silhouette
|
|
5294
5334
|
}
|
|
5295
5335
|
),
|
|
5296
5336
|
/* @__PURE__ */ e(
|
|
5297
5337
|
"path",
|
|
5298
5338
|
{
|
|
5299
5339
|
d: "M33.2089 54.6777C31.3993 54.6777 29.9263 56.1695 29.9263 58.0047C29.9263 59.8398 31.3982 61.3316 33.2089 61.3316C35.0196 61.3316 36.4903 59.8398 36.4903 58.0047C36.4903 56.1695 35.0184 54.6777 33.2089 54.6777ZM33.2089 58.9879C32.6735 58.9879 32.2388 58.5473 32.2388 58.0047C32.2388 57.4621 32.6735 57.0215 33.2089 57.0215C33.7442 57.0215 34.1778 57.4621 34.1778 58.0047C34.1778 58.5473 33.7431 58.9879 33.2089 58.9879Z",
|
|
5300
|
-
fill:
|
|
5340
|
+
fill: P.silhouette
|
|
5301
5341
|
}
|
|
5302
5342
|
),
|
|
5303
5343
|
/* @__PURE__ */ e(
|
|
5304
5344
|
"path",
|
|
5305
5345
|
{
|
|
5306
5346
|
d: "M33.2089 70.5C31.3993 70.5 29.9263 71.9918 29.9263 73.827C29.9263 75.6621 31.3982 77.1539 33.2089 77.1539C35.0196 77.1539 36.4903 75.6621 36.4903 73.827C36.4903 71.9918 35.0184 70.5 33.2089 70.5ZM33.2089 74.8102C32.6735 74.8102 32.2388 74.3695 32.2388 73.827C32.2388 73.2844 32.6735 72.8438 33.2089 72.8438C33.7442 72.8438 34.1778 73.2844 34.1778 73.827C34.1778 74.3695 33.7431 74.8102 33.2089 74.8102Z",
|
|
5307
|
-
fill:
|
|
5347
|
+
fill: P.silhouette
|
|
5308
5348
|
}
|
|
5309
5349
|
),
|
|
5310
5350
|
/* @__PURE__ */ e(
|
|
5311
5351
|
"path",
|
|
5312
5352
|
{
|
|
5313
5353
|
d: "M70.0215 38.2852C69.3821 38.2852 68.8652 38.809 68.8652 39.457V44.3332C68.8652 44.9812 69.3821 45.5051 70.0215 45.5051C70.6609 45.5051 71.1777 44.9812 71.1777 44.3332V39.457C71.1777 38.809 70.6609 38.2852 70.0215 38.2852Z",
|
|
5314
|
-
fill:
|
|
5354
|
+
fill: P.silhouette
|
|
5315
5355
|
}
|
|
5316
5356
|
),
|
|
5317
5357
|
/* @__PURE__ */ e(
|
|
5318
5358
|
"path",
|
|
5319
5359
|
{
|
|
5320
5360
|
d: "M70.0215 54.3926C69.3821 54.3926 68.8652 54.9164 68.8652 55.5645V60.4406C68.8652 61.0887 69.3821 61.6125 70.0215 61.6125C70.6609 61.6125 71.1777 61.0887 71.1777 60.4406V55.5645C71.1777 54.9164 70.6609 54.3926 70.0215 54.3926Z",
|
|
5321
|
-
fill:
|
|
5361
|
+
fill: P.silhouette
|
|
5322
5362
|
}
|
|
5323
5363
|
),
|
|
5324
5364
|
/* @__PURE__ */ e(
|
|
5325
5365
|
"path",
|
|
5326
5366
|
{
|
|
5327
5367
|
d: "M70.0215 70.5C69.3821 70.5 68.8652 71.0238 68.8652 71.6719V76.5492C68.8652 77.1973 69.3821 77.7211 70.0215 77.7211C70.6609 77.7211 71.1777 77.1973 71.1777 76.5492V71.6719C71.1777 71.0238 70.6609 70.5 70.0215 70.5Z",
|
|
5328
|
-
fill:
|
|
5368
|
+
fill: P.silhouette
|
|
5329
5369
|
}
|
|
5330
5370
|
),
|
|
5331
5371
|
/* @__PURE__ */ e(
|
|
5332
5372
|
"path",
|
|
5333
5373
|
{
|
|
5334
5374
|
d: "M65.77 39.7617C65.1306 39.7617 64.6138 40.2855 64.6138 40.9336V45.8098C64.6138 46.4578 65.1306 46.9816 65.77 46.9816C66.4094 46.9816 66.9263 46.4578 66.9263 45.8098V40.9336C66.9263 40.2855 66.4094 39.7617 65.77 39.7617Z",
|
|
5335
|
-
fill:
|
|
5375
|
+
fill: P.silhouette
|
|
5336
5376
|
}
|
|
5337
5377
|
),
|
|
5338
5378
|
/* @__PURE__ */ e(
|
|
5339
5379
|
"path",
|
|
5340
5380
|
{
|
|
5341
5381
|
d: "M65.77 55.8691C65.1306 55.8691 64.6138 56.393 64.6138 57.041V61.9172C64.6138 62.5652 65.1306 63.0891 65.77 63.0891C66.4094 63.0891 66.9263 62.5652 66.9263 61.9172V57.041C66.9263 56.393 66.4094 55.8691 65.77 55.8691Z",
|
|
5342
|
-
fill:
|
|
5382
|
+
fill: P.silhouette
|
|
5343
5383
|
}
|
|
5344
5384
|
),
|
|
5345
5385
|
/* @__PURE__ */ e(
|
|
5346
5386
|
"path",
|
|
5347
5387
|
{
|
|
5348
5388
|
d: "M65.77 71.9766C65.1306 71.9766 64.6138 72.5004 64.6138 73.1484V78.0246C64.6138 78.6727 65.1306 79.1965 65.77 79.1965C66.4094 79.1965 66.9263 78.6727 66.9263 78.0246V73.1484C66.9263 72.5004 66.4094 71.9766 65.77 71.9766Z",
|
|
5349
|
-
fill:
|
|
5389
|
+
fill: P.silhouette
|
|
5350
5390
|
}
|
|
5351
5391
|
),
|
|
5352
5392
|
/* @__PURE__ */ e(
|
|
5353
5393
|
"path",
|
|
5354
5394
|
{
|
|
5355
5395
|
d: "M61.2939 40.7246C60.6545 40.7246 60.1377 41.2484 60.1377 41.8965V46.7727C60.1377 47.4207 60.6545 47.9445 61.2939 47.9445C61.9334 47.9445 62.4502 47.4207 62.4502 46.7727V41.8965C62.4502 41.2484 61.9334 40.7246 61.2939 40.7246Z",
|
|
5356
|
-
fill:
|
|
5396
|
+
fill: P.silhouette
|
|
5357
5397
|
}
|
|
5358
5398
|
),
|
|
5359
5399
|
/* @__PURE__ */ e(
|
|
5360
5400
|
"path",
|
|
5361
5401
|
{
|
|
5362
5402
|
d: "M61.2939 56.832C60.6545 56.832 60.1377 57.3559 60.1377 58.0039V62.8801C60.1377 63.5281 60.6545 64.052 61.2939 64.052C61.9334 64.052 62.4502 63.5281 62.4502 62.8801V58.0039C62.4502 57.3559 61.9334 56.832 61.2939 56.832Z",
|
|
5363
|
-
fill:
|
|
5403
|
+
fill: P.silhouette
|
|
5364
5404
|
}
|
|
5365
5405
|
),
|
|
5366
5406
|
/* @__PURE__ */ e(
|
|
5367
5407
|
"path",
|
|
5368
5408
|
{
|
|
5369
5409
|
d: "M61.2939 72.9395C60.6545 72.9395 60.1377 73.4633 60.1377 74.1113V78.9875C60.1377 79.6355 60.6545 80.1594 61.2939 80.1594C61.9334 80.1594 62.4502 79.6355 62.4502 78.9875V74.1113C62.4502 73.4633 61.9334 72.9395 61.2939 72.9395Z",
|
|
5370
|
-
fill:
|
|
5410
|
+
fill: P.silhouette
|
|
5371
5411
|
}
|
|
5372
5412
|
),
|
|
5373
5413
|
/* @__PURE__ */ e(
|
|
5374
5414
|
"path",
|
|
5375
5415
|
{
|
|
5376
5416
|
d: "M39.0489 24.4037C39.131 24.4037 39.2154 24.3944 39.2986 24.3768C42.7316 23.6127 46.6755 23.185 51.0207 23.11C51.659 23.0983 52.1677 22.5651 52.1561 21.917C52.1446 21.2701 51.652 20.7451 50.9791 20.7662C46.4813 20.8448 42.3835 21.2889 38.8015 22.0881C38.1782 22.2264 37.7828 22.8522 37.9204 23.4838C38.0395 24.0311 38.5182 24.4037 39.0489 24.4037Z",
|
|
5377
|
-
fill:
|
|
5417
|
+
fill: P.silhouette
|
|
5378
5418
|
}
|
|
5379
5419
|
),
|
|
5380
5420
|
/* @__PURE__ */ e(
|
|
5381
5421
|
"path",
|
|
5382
5422
|
{
|
|
5383
5423
|
d: "M32.5406 26.6215C32.7407 26.6215 32.9442 26.57 33.128 26.4586C33.1315 26.4563 33.5096 26.2336 34.2889 25.9055C34.8786 25.6582 35.1584 24.9727 34.9144 24.3739C34.6704 23.775 33.9917 23.4926 33.4032 23.7399C32.4632 24.1348 31.9926 24.4149 31.9417 24.4465C31.396 24.7782 31.219 25.4942 31.544 26.0485C31.7613 26.4164 32.1452 26.6204 32.5395 26.6204L32.5406 26.6215Z",
|
|
5384
|
-
fill:
|
|
5424
|
+
fill: P.silhouette
|
|
5385
5425
|
}
|
|
5386
5426
|
),
|
|
5387
5427
|
/* @__PURE__ */ e(
|
|
5388
5428
|
"path",
|
|
5389
5429
|
{
|
|
5390
5430
|
d: "M92.7251 26.7272L82.3845 29.3124C81.6929 29.4856 80.9911 29.0642 80.8179 28.3727C80.6447 27.6799 81.066 26.978 81.7576 26.8048L92.0982 24.2196C92.791 24.0464 93.4929 24.4678 93.6661 25.1593C93.8393 25.8521 93.4179 26.554 92.7251 26.7272Z",
|
|
5391
|
-
fill:
|
|
5431
|
+
fill: P.accent,
|
|
5392
5432
|
fillOpacity: "0.65"
|
|
5393
5433
|
}
|
|
5394
5434
|
),
|
|
@@ -5396,7 +5436,7 @@ function Fi({ width: t, height: r }) {
|
|
|
5396
5436
|
"path",
|
|
5397
5437
|
{
|
|
5398
5438
|
d: "M94.4649 11.0082L80.2465 21.3488C79.6701 21.7676 78.8609 21.6409 78.4408 21.0632C78.022 20.4867 78.1487 19.6775 78.7265 19.2574L92.9448 8.91682C93.5213 8.49803 94.3305 8.6247 94.7505 9.20248C95.1693 9.77897 95.0414 10.5881 94.4649 11.0082Z",
|
|
5399
|
-
fill:
|
|
5439
|
+
fill: P.accent,
|
|
5400
5440
|
fillOpacity: "0.65"
|
|
5401
5441
|
}
|
|
5402
5442
|
),
|
|
@@ -5404,7 +5444,7 @@ function Fi({ width: t, height: r }) {
|
|
|
5404
5444
|
"path",
|
|
5405
5445
|
{
|
|
5406
5446
|
d: "M78.0091 10.6269L74.1314 17.0898C73.7643 17.7025 72.9706 17.9002 72.358 17.5331C71.7466 17.1673 71.5475 16.3724 71.9146 15.7597L75.7923 9.29684C76.1594 8.68545 76.9544 8.48769 77.5657 8.85349C78.1784 9.22058 78.3762 10.0155 78.0091 10.6269Z",
|
|
5407
|
-
fill:
|
|
5447
|
+
fill: P.accent,
|
|
5408
5448
|
fillOpacity: "0.65"
|
|
5409
5449
|
}
|
|
5410
5450
|
)
|
|
@@ -5412,7 +5452,7 @@ function Fi({ width: t, height: r }) {
|
|
|
5412
5452
|
}
|
|
5413
5453
|
) });
|
|
5414
5454
|
}
|
|
5415
|
-
const
|
|
5455
|
+
const _n = ({
|
|
5416
5456
|
title: t = "create",
|
|
5417
5457
|
children: r,
|
|
5418
5458
|
onClickAction: n,
|
|
@@ -5457,17 +5497,17 @@ const jn = ({
|
|
|
5457
5497
|
marginBlock: "auto",
|
|
5458
5498
|
customHeight: a,
|
|
5459
5499
|
children: [
|
|
5460
|
-
f || /* @__PURE__ */ e(
|
|
5461
|
-
/* @__PURE__ */ e(u, { children: r.map((
|
|
5500
|
+
f || /* @__PURE__ */ e(Si, {}),
|
|
5501
|
+
/* @__PURE__ */ e(u, { children: r.map((p, y) => /* @__PURE__ */ e(
|
|
5462
5502
|
me.Body1,
|
|
5463
5503
|
{
|
|
5464
5504
|
props: {
|
|
5465
5505
|
align: "center",
|
|
5466
5506
|
textAlign: "center"
|
|
5467
5507
|
},
|
|
5468
|
-
children:
|
|
5508
|
+
children: y > 2 ? null : p
|
|
5469
5509
|
},
|
|
5470
|
-
|
|
5510
|
+
y
|
|
5471
5511
|
)) }),
|
|
5472
5512
|
s ? g() : null
|
|
5473
5513
|
]
|
|
@@ -5483,7 +5523,7 @@ const jn = ({
|
|
|
5483
5523
|
c000000: "#000000",
|
|
5484
5524
|
cFFFFFF: "#FFFFFF"
|
|
5485
5525
|
};
|
|
5486
|
-
function
|
|
5526
|
+
function Ei({ width: t, height: r }) {
|
|
5487
5527
|
return /* @__PURE__ */ e(X, { children: /* @__PURE__ */ d(
|
|
5488
5528
|
"svg",
|
|
5489
5529
|
{
|
|
@@ -5686,7 +5726,7 @@ function Si({ width: t, height: r }) {
|
|
|
5686
5726
|
}
|
|
5687
5727
|
) });
|
|
5688
5728
|
}
|
|
5689
|
-
function
|
|
5729
|
+
function Un({ onClick: t }) {
|
|
5690
5730
|
const r = ee("md");
|
|
5691
5731
|
return /* @__PURE__ */ d(
|
|
5692
5732
|
u,
|
|
@@ -5698,7 +5738,7 @@ function $n({ onClick: t }) {
|
|
|
5698
5738
|
justify: "center",
|
|
5699
5739
|
gap: "md",
|
|
5700
5740
|
children: [
|
|
5701
|
-
/* @__PURE__ */ e(
|
|
5741
|
+
/* @__PURE__ */ e(Ei, { width: r ? 600 : 300 }),
|
|
5702
5742
|
/* @__PURE__ */ e(
|
|
5703
5743
|
C,
|
|
5704
5744
|
{
|
|
@@ -5743,7 +5783,7 @@ const W = {
|
|
|
5743
5783
|
cF4F4F4: "#F4F4F4",
|
|
5744
5784
|
cFFFFFF: "#FFFFFF"
|
|
5745
5785
|
};
|
|
5746
|
-
function
|
|
5786
|
+
function Mi({ width: t, height: r }) {
|
|
5747
5787
|
return /* @__PURE__ */ e(X, { children: /* @__PURE__ */ d(
|
|
5748
5788
|
"svg",
|
|
5749
5789
|
{
|
|
@@ -5958,7 +5998,7 @@ function Ei({ width: t, height: r }) {
|
|
|
5958
5998
|
}
|
|
5959
5999
|
) });
|
|
5960
6000
|
}
|
|
5961
|
-
function
|
|
6001
|
+
function Pn({ onClick: t }) {
|
|
5962
6002
|
const r = ee("md");
|
|
5963
6003
|
return /* @__PURE__ */ d(
|
|
5964
6004
|
u,
|
|
@@ -5970,7 +6010,7 @@ function _n({ onClick: t }) {
|
|
|
5970
6010
|
justify: "center",
|
|
5971
6011
|
gap: "md",
|
|
5972
6012
|
children: [
|
|
5973
|
-
/* @__PURE__ */ e(
|
|
6013
|
+
/* @__PURE__ */ e(Mi, { width: r ? 600 : 300 }),
|
|
5974
6014
|
/* @__PURE__ */ e(C, { fontWeight: "bold", fontSize: r ? "3xl" : "2xl", children: "We Are Sorry ..." }),
|
|
5975
6015
|
t && /* @__PURE__ */ e(B, { size: r ? "md" : "xs", onClick: t, children: "Go Back" })
|
|
5976
6016
|
]
|
|
@@ -5994,7 +6034,7 @@ const c = {
|
|
|
5994
6034
|
cFFE18B: "#FFE18B",
|
|
5995
6035
|
cFFFFFF: "#FFFFFF"
|
|
5996
6036
|
};
|
|
5997
|
-
function
|
|
6037
|
+
function Li({ width: t, height: r }) {
|
|
5998
6038
|
return /* @__PURE__ */ e(X, { children: /* @__PURE__ */ d(
|
|
5999
6039
|
"svg",
|
|
6000
6040
|
{
|
|
@@ -6666,7 +6706,7 @@ function Mi({ width: t, height: r }) {
|
|
|
6666
6706
|
}
|
|
6667
6707
|
) });
|
|
6668
6708
|
}
|
|
6669
|
-
function
|
|
6709
|
+
function qn({ onClick: t }) {
|
|
6670
6710
|
const r = ee("md");
|
|
6671
6711
|
return /* @__PURE__ */ d(
|
|
6672
6712
|
u,
|
|
@@ -6679,7 +6719,7 @@ function Un({ onClick: t }) {
|
|
|
6679
6719
|
gap: "md",
|
|
6680
6720
|
overflow: "overflow-hidden",
|
|
6681
6721
|
children: [
|
|
6682
|
-
/* @__PURE__ */ e(
|
|
6722
|
+
/* @__PURE__ */ e(Li, { width: r ? 600 : 300 }),
|
|
6683
6723
|
/* @__PURE__ */ e(
|
|
6684
6724
|
C,
|
|
6685
6725
|
{
|
|
@@ -6703,11 +6743,11 @@ function Un({ onClick: t }) {
|
|
|
6703
6743
|
}
|
|
6704
6744
|
);
|
|
6705
6745
|
}
|
|
6706
|
-
const
|
|
6746
|
+
const Jn = (t) => {
|
|
6707
6747
|
var n, l, i, o, s;
|
|
6708
6748
|
const r = ee("md");
|
|
6709
6749
|
return /* @__PURE__ */ d(
|
|
6710
|
-
|
|
6750
|
+
Ue,
|
|
6711
6751
|
{
|
|
6712
6752
|
isShow: t.isShow,
|
|
6713
6753
|
onHide: t.onHide,
|
|
@@ -6720,8 +6760,8 @@ const qn = (t) => {
|
|
|
6720
6760
|
},
|
|
6721
6761
|
children: [
|
|
6722
6762
|
/* @__PURE__ */ e(Se, { ...t.dialogTitleProps, children: typeof t.title == "string" ? /* @__PURE__ */ e(C, { fontSize: "lg", fontWeight: "medium", children: t.title }) : t.title }),
|
|
6723
|
-
/* @__PURE__ */ e(
|
|
6724
|
-
/* @__PURE__ */ e(
|
|
6763
|
+
/* @__PURE__ */ e(Pe, { children: typeof t.description == "string" ? /* @__PURE__ */ e(C, { fontSize: "md", lineHeight: "leading-6", color: "tertiary", children: t.description }) : t.description }),
|
|
6764
|
+
/* @__PURE__ */ e(nt, { children: /* @__PURE__ */ e(
|
|
6725
6765
|
u,
|
|
6726
6766
|
{
|
|
6727
6767
|
display: "flex",
|
|
@@ -6766,7 +6806,7 @@ const qn = (t) => {
|
|
|
6766
6806
|
},
|
|
6767
6807
|
t.key
|
|
6768
6808
|
);
|
|
6769
|
-
},
|
|
6809
|
+
}, Gn = te(
|
|
6770
6810
|
({
|
|
6771
6811
|
children: t,
|
|
6772
6812
|
height: r,
|
|
@@ -6779,26 +6819,26 @@ const qn = (t) => {
|
|
|
6779
6819
|
title: h,
|
|
6780
6820
|
titleTag: f,
|
|
6781
6821
|
action: g,
|
|
6782
|
-
actionContainer:
|
|
6783
|
-
containerProps:
|
|
6822
|
+
actionContainer: p,
|
|
6823
|
+
containerProps: y,
|
|
6784
6824
|
bodyProps: b,
|
|
6785
6825
|
headerProps: H = { borderBottom: !0 },
|
|
6786
6826
|
footerProps: D = { borderTop: !0 },
|
|
6787
|
-
variantTag:
|
|
6827
|
+
variantTag: T = "info"
|
|
6788
6828
|
}) => {
|
|
6789
|
-
const Z = le(null), [j,
|
|
6829
|
+
const Z = le(null), [j, J] = A("100vh");
|
|
6790
6830
|
U(() => {
|
|
6791
6831
|
const V = () => {
|
|
6792
6832
|
if (Z.current) {
|
|
6793
6833
|
const K = Z.current.getBoundingClientRect().top;
|
|
6794
|
-
|
|
6834
|
+
J(`calc(100vh - ${K}px)`);
|
|
6795
6835
|
}
|
|
6796
6836
|
};
|
|
6797
6837
|
return V(), window.addEventListener("resize", V), () => window.removeEventListener("resize", V);
|
|
6798
6838
|
}, []);
|
|
6799
6839
|
const M = () => f ? /* @__PURE__ */ d(u, { direction: "row", gap: "sm", align: "center", children: [
|
|
6800
6840
|
/* @__PURE__ */ e(C, { fontWeight: "medium", children: h }),
|
|
6801
|
-
/* @__PURE__ */ e(Ee, { border: !0, text: f, variant:
|
|
6841
|
+
/* @__PURE__ */ e(Ee, { border: !0, text: f, variant: T })
|
|
6802
6842
|
] }) : /* @__PURE__ */ e(C, { fontWeight: "medium", children: h }), fe = () => s || /* @__PURE__ */ d(
|
|
6803
6843
|
u,
|
|
6804
6844
|
{
|
|
@@ -6808,7 +6848,7 @@ const qn = (t) => {
|
|
|
6808
6848
|
gap: "md",
|
|
6809
6849
|
children: [
|
|
6810
6850
|
/* @__PURE__ */ e(u, { children: h ? M() : null }),
|
|
6811
|
-
/* @__PURE__ */ e(u, { ...
|
|
6851
|
+
/* @__PURE__ */ e(u, { ...p, children: g ?? null })
|
|
6812
6852
|
]
|
|
6813
6853
|
}
|
|
6814
6854
|
), G = !!(s || h || g);
|
|
@@ -6823,12 +6863,12 @@ const qn = (t) => {
|
|
|
6823
6863
|
paddingInline: i,
|
|
6824
6864
|
bg: "white",
|
|
6825
6865
|
direction: "column",
|
|
6826
|
-
...
|
|
6866
|
+
...y,
|
|
6827
6867
|
style: {
|
|
6828
6868
|
backgroundColor: "var(--sa-background-primary, #ffffff)",
|
|
6829
6869
|
display: "flex",
|
|
6830
6870
|
minHeight: j,
|
|
6831
|
-
...(
|
|
6871
|
+
...(y == null ? void 0 : y.style) ?? {}
|
|
6832
6872
|
},
|
|
6833
6873
|
children: [
|
|
6834
6874
|
s !== null && G ? /* @__PURE__ */ e(zt, { ...H, children: fe() }) : null,
|
|
@@ -6850,7 +6890,7 @@ const qn = (t) => {
|
|
|
6850
6890
|
}
|
|
6851
6891
|
);
|
|
6852
6892
|
}
|
|
6853
|
-
),
|
|
6893
|
+
), Qn = Ft.memo(
|
|
6854
6894
|
({ value: t, options: r = [], onChange: n, multiple: l }) => {
|
|
6855
6895
|
const i = (t == null ? void 0 : t.map((a) => a.value)) || [], o = (r == null ? void 0 : r.filter((a) => i.includes(a.value))) || [], s = (a) => {
|
|
6856
6896
|
const h = [...o];
|
|
@@ -6867,8 +6907,8 @@ const qn = (t) => {
|
|
|
6867
6907
|
h
|
|
6868
6908
|
)) });
|
|
6869
6909
|
}
|
|
6870
|
-
),
|
|
6871
|
-
const { defaultTab: r = 0, paramKey: n = "tab" } = t || {}, [l, i] =
|
|
6910
|
+
), Yn = (t) => {
|
|
6911
|
+
const { defaultTab: r = 0, paramKey: n = "tab" } = t || {}, [l, i] = Je(), o = qe(l.toString());
|
|
6872
6912
|
return {
|
|
6873
6913
|
activeTab: o[n] ? parseInt(o[n]) : r,
|
|
6874
6914
|
handleTabChange: (h) => {
|
|
@@ -6880,12 +6920,12 @@ const qn = (t) => {
|
|
|
6880
6920
|
searchQueries: o
|
|
6881
6921
|
};
|
|
6882
6922
|
};
|
|
6883
|
-
function
|
|
6923
|
+
function Xn({
|
|
6884
6924
|
appName: t,
|
|
6885
6925
|
menuConfig: r,
|
|
6886
6926
|
formatTitle: n
|
|
6887
6927
|
}) {
|
|
6888
|
-
const l =
|
|
6928
|
+
const l = ze();
|
|
6889
6929
|
U(() => {
|
|
6890
6930
|
let i = null, o = null;
|
|
6891
6931
|
for (const h of r) {
|
|
@@ -6901,14 +6941,14 @@ function Qn({
|
|
|
6901
6941
|
document.title = (n || a)(s, t);
|
|
6902
6942
|
}, [l.pathname]);
|
|
6903
6943
|
}
|
|
6904
|
-
const
|
|
6905
|
-
const [t, r] =
|
|
6944
|
+
const Kn = () => {
|
|
6945
|
+
const [t, r] = Je(), n = qe(t.toString()), l = Lt(), i = ze(), o = l.id;
|
|
6906
6946
|
return {
|
|
6907
6947
|
// query params
|
|
6908
6948
|
setSearchParams: r,
|
|
6909
6949
|
searchParams: t,
|
|
6910
6950
|
searchQueries: n,
|
|
6911
|
-
isHasQuery: (g,
|
|
6951
|
+
isHasQuery: (g, p) => t.has(g) && t.get(g) === p,
|
|
6912
6952
|
getQueryParam: (g) => t.get(g),
|
|
6913
6953
|
// route params
|
|
6914
6954
|
getRouteParam: (g) => l[g],
|
|
@@ -6920,24 +6960,24 @@ const Yn = () => {
|
|
|
6920
6960
|
hasId: !!o
|
|
6921
6961
|
};
|
|
6922
6962
|
};
|
|
6923
|
-
function
|
|
6963
|
+
function el(t) {
|
|
6924
6964
|
var l, i;
|
|
6925
6965
|
const r = t.decodedAccessToken;
|
|
6926
6966
|
return De(() => {
|
|
6927
6967
|
var h, f;
|
|
6928
6968
|
const o = ((f = (h = r == null ? void 0 : r.access) == null ? void 0 : h.role) == null ? void 0 : f.code) ?? "", s = Object.keys(t.role).reduce(
|
|
6929
|
-
(g,
|
|
6930
|
-
const
|
|
6931
|
-
return { ...g, [
|
|
6969
|
+
(g, p) => {
|
|
6970
|
+
const y = `is${p.toLowerCase().replace(/(^\w|_\w)/g, (b) => b.replace("_", "").toUpperCase())}`;
|
|
6971
|
+
return { ...g, [y]: !1 };
|
|
6932
6972
|
},
|
|
6933
6973
|
{}
|
|
6934
6974
|
);
|
|
6935
6975
|
return {
|
|
6936
|
-
...Object.keys(t.role).reduce((g,
|
|
6937
|
-
const
|
|
6976
|
+
...Object.keys(t.role).reduce((g, p) => {
|
|
6977
|
+
const y = `is${p.toLowerCase().replace(/(^\w|_\w)/g, (b) => b.replace("_", "").toUpperCase())}`;
|
|
6938
6978
|
return {
|
|
6939
6979
|
...g,
|
|
6940
|
-
[
|
|
6980
|
+
[y]: o === t.role[p]
|
|
6941
6981
|
};
|
|
6942
6982
|
}, s),
|
|
6943
6983
|
hasRole: (g) => o === t.role[g],
|
|
@@ -6946,90 +6986,90 @@ function Xn(t) {
|
|
|
6946
6986
|
}, [(i = (l = r == null ? void 0 : r.access) == null ? void 0 : l.role) == null ? void 0 : i.code, t]);
|
|
6947
6987
|
}
|
|
6948
6988
|
export {
|
|
6949
|
-
|
|
6950
|
-
|
|
6951
|
-
|
|
6952
|
-
|
|
6989
|
+
gn as ActionMenu,
|
|
6990
|
+
jr as AdvanceFilterBar,
|
|
6991
|
+
ln as App,
|
|
6992
|
+
lr as AppComponent,
|
|
6953
6993
|
Wt as AppContext,
|
|
6954
|
-
|
|
6955
|
-
|
|
6956
|
-
|
|
6994
|
+
cn as AppLayout,
|
|
6995
|
+
Zn as AsideBar,
|
|
6996
|
+
sn as AuthLayout,
|
|
6957
6997
|
qr as ColumnFilterDropdown,
|
|
6958
|
-
|
|
6959
|
-
|
|
6960
|
-
|
|
6998
|
+
Jn as ConfirmationDialog,
|
|
6999
|
+
Qr as DataTable,
|
|
7000
|
+
O as DecisionWrapper,
|
|
6961
7001
|
st as EachUtils,
|
|
6962
|
-
|
|
6963
|
-
|
|
6964
|
-
|
|
6965
|
-
|
|
6966
|
-
|
|
6967
|
-
|
|
6968
|
-
|
|
6969
|
-
|
|
6970
|
-
|
|
6971
|
-
|
|
6972
|
-
|
|
6973
|
-
|
|
6974
|
-
|
|
6975
|
-
|
|
7002
|
+
_n as EmptyStatePage,
|
|
7003
|
+
Zr as FilterDrawer,
|
|
7004
|
+
jn as FloatingFooter,
|
|
7005
|
+
Pn as ForbiddenPage,
|
|
7006
|
+
Nn as Form,
|
|
7007
|
+
Gn as FullSection,
|
|
7008
|
+
dn as HorizontalField,
|
|
7009
|
+
hi as InputFile,
|
|
7010
|
+
bi as InputImage,
|
|
7011
|
+
hn as ModalDialog,
|
|
7012
|
+
an as ModuleSwitcher,
|
|
7013
|
+
cr as ModuleSwitcherModal,
|
|
7014
|
+
Un as NotFoundPage,
|
|
7015
|
+
un as PageLayout,
|
|
6976
7016
|
Vt as Pressable,
|
|
6977
|
-
|
|
6978
|
-
|
|
6979
|
-
|
|
7017
|
+
pr as RightDrawer,
|
|
7018
|
+
ki as ScrollToTopButton,
|
|
7019
|
+
fn as Section,
|
|
6980
7020
|
It as SectionFooter,
|
|
6981
7021
|
zt as SectionHeader,
|
|
6982
|
-
|
|
6983
|
-
|
|
6984
|
-
|
|
6985
|
-
|
|
6986
|
-
|
|
6987
|
-
|
|
6988
|
-
|
|
6989
|
-
|
|
6990
|
-
|
|
7022
|
+
Qn as SelectButton,
|
|
7023
|
+
qn as ServerErrorPage,
|
|
7024
|
+
ir as SidebarBadgesProvider,
|
|
7025
|
+
or as SidebarHeaderSlot,
|
|
7026
|
+
Pr as TableFooter,
|
|
7027
|
+
_r as TableHeader,
|
|
7028
|
+
Dn as TableSection,
|
|
7029
|
+
$r as TableWrapper,
|
|
7030
|
+
On as ToggleStatus,
|
|
6991
7031
|
me as Typography,
|
|
6992
|
-
|
|
6993
|
-
|
|
6994
|
-
|
|
6995
|
-
|
|
6996
|
-
|
|
6997
|
-
|
|
6998
|
-
|
|
6999
|
-
|
|
7000
|
-
|
|
7001
|
-
|
|
7002
|
-
|
|
7003
|
-
|
|
7004
|
-
|
|
7005
|
-
|
|
7006
|
-
|
|
7007
|
-
|
|
7008
|
-
|
|
7009
|
-
|
|
7010
|
-
|
|
7011
|
-
|
|
7012
|
-
|
|
7013
|
-
|
|
7014
|
-
|
|
7015
|
-
|
|
7016
|
-
|
|
7017
|
-
|
|
7018
|
-
|
|
7019
|
-
|
|
7020
|
-
|
|
7021
|
-
|
|
7022
|
-
|
|
7023
|
-
|
|
7024
|
-
|
|
7025
|
-
|
|
7032
|
+
$n as VerticalField,
|
|
7033
|
+
on as clearModuleSelection,
|
|
7034
|
+
bn as createInitialFromUserName,
|
|
7035
|
+
Sn as cssVars,
|
|
7036
|
+
Ln as formHasChanged,
|
|
7037
|
+
Fn as formatDate,
|
|
7038
|
+
ii as formatDateToIndonesian,
|
|
7039
|
+
wn as formatRupiah,
|
|
7040
|
+
xn as getDateFilterValue,
|
|
7041
|
+
yn as getDateRangeFilterValue,
|
|
7042
|
+
kn as getInitials,
|
|
7043
|
+
mn as getValueDropdownMultipleFilter,
|
|
7044
|
+
pn as getValueRadioFilter,
|
|
7045
|
+
Nr as getValueSearch,
|
|
7046
|
+
Xe as getValuesFilter,
|
|
7047
|
+
yt as handleChangeFilter,
|
|
7048
|
+
Tn as handleOnScroll,
|
|
7049
|
+
Vn as isEmail,
|
|
7050
|
+
Cn as isFilterActive,
|
|
7051
|
+
Bn as isOnlyLettersAndSpaces,
|
|
7052
|
+
Wn as isPhoneNumber,
|
|
7053
|
+
zn as isSlug,
|
|
7054
|
+
En as oneDayInMs,
|
|
7055
|
+
vn as parseIndonesianDateToDate,
|
|
7056
|
+
In as preventNonCoordinateInput,
|
|
7057
|
+
Hn as preventNonNumberAndDecimalInput,
|
|
7058
|
+
An as preventNonNumberInput,
|
|
7059
|
+
Rn as preventNumberInput,
|
|
7060
|
+
zr as resolveDateRangeValueToString,
|
|
7061
|
+
Ir as resolveDateValueToString,
|
|
7062
|
+
Hr as resolveDropdownValueToString,
|
|
7063
|
+
Vr as resolveRadioValueToString,
|
|
7064
|
+
Ye as resolveSidebarBadge,
|
|
7065
|
+
Mn as textWidth,
|
|
7026
7066
|
Bt as useApp,
|
|
7027
|
-
|
|
7028
|
-
|
|
7029
|
-
|
|
7067
|
+
rr as useAppState,
|
|
7068
|
+
el as useAuthRole,
|
|
7069
|
+
Xn as useDynamicTitle,
|
|
7030
7070
|
Ht as useModuleSelection,
|
|
7031
7071
|
at as useRouteInfo,
|
|
7032
|
-
|
|
7033
|
-
|
|
7034
|
-
|
|
7072
|
+
Kn as useRouteParams,
|
|
7073
|
+
nr as useSidebarBadges,
|
|
7074
|
+
Yn as useTabState
|
|
7035
7075
|
};
|