@starasia/admin 14.2.1 → 14.4.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/components/TableLayout/types.d.ts +9 -0
- package/dist/index.cjs.js +3 -3
- package/dist/index.es.js +352 -365
- package/dist/index.umd.js +3 -3
- package/dist/style.css +1 -1
- package/package.json +9 -9
package/dist/index.es.js
CHANGED
|
@@ -49,7 +49,7 @@ import { Radio as Xi } from "@starasia/radio";
|
|
|
49
49
|
export * from "@starasia/radio";
|
|
50
50
|
import { Text as C } from "@starasia/text";
|
|
51
51
|
export * from "@starasia/text";
|
|
52
|
-
import { Icon as
|
|
52
|
+
import { Icon as M } from "@starasia/icon";
|
|
53
53
|
export * from "@starasia/icon";
|
|
54
54
|
import { Flex as fe } from "@starasia/flex";
|
|
55
55
|
export * from "@starasia/flex";
|
|
@@ -61,7 +61,7 @@ export * from "@starasia/story-record";
|
|
|
61
61
|
import { Skeleton as mt } from "@starasia/skeleton";
|
|
62
62
|
export * from "@starasia/skeleton";
|
|
63
63
|
export * from "@starasia/progress-stepper";
|
|
64
|
-
import { jsx as e, Fragment as
|
|
64
|
+
import { jsx as e, Fragment as ae, jsxs as d } from "react/jsx-runtime";
|
|
65
65
|
import Ct, { createContext as At, useState as H, useContext as wt, useCallback as G, useMemo as ve, memo as ut, useEffect as Y, useRef as oe, useLayoutEffect as at, forwardRef as Pr, isValidElement as Rr, Children as Ki, useImperativeHandle as eo } from "react";
|
|
66
66
|
import to, { createPortal as jr } from "react-dom";
|
|
67
67
|
import ro from "react-easy-crop";
|
|
@@ -189,7 +189,7 @@ const no = {
|
|
|
189
189
|
), F = G(() => {
|
|
190
190
|
const w = Br(n, o, i);
|
|
191
191
|
pn(l, w), p(w);
|
|
192
|
-
}, [n, o, i, l]),
|
|
192
|
+
}, [n, o, i, l]), A = G(
|
|
193
193
|
(w) => {
|
|
194
194
|
u(
|
|
195
195
|
(R) => typeof w == "function" ? w(R) : w
|
|
@@ -209,7 +209,7 @@ const no = {
|
|
|
209
209
|
minWidth: o,
|
|
210
210
|
maxWidth: i,
|
|
211
211
|
mobileOpen: a,
|
|
212
|
-
setMobileOpen:
|
|
212
|
+
setMobileOpen: A,
|
|
213
213
|
openMobile: D,
|
|
214
214
|
closeMobile: k,
|
|
215
215
|
toggleMobile: I
|
|
@@ -226,7 +226,7 @@ const no = {
|
|
|
226
226
|
o,
|
|
227
227
|
i,
|
|
228
228
|
a,
|
|
229
|
-
|
|
229
|
+
A,
|
|
230
230
|
D,
|
|
231
231
|
k,
|
|
232
232
|
I
|
|
@@ -330,11 +330,11 @@ function go({ children: t }) {
|
|
|
330
330
|
}
|
|
331
331
|
function po({ children: t }) {
|
|
332
332
|
const r = wt(Zr);
|
|
333
|
-
return r ? /* @__PURE__ */ d(
|
|
333
|
+
return r ? /* @__PURE__ */ d(ae, { children: [
|
|
334
334
|
/* @__PURE__ */ e("div", { ref: r.setPrependNode, style: { display: "contents" } }),
|
|
335
335
|
r.replaceCount > 0 ? /* @__PURE__ */ e("div", { ref: r.setReplaceNode, style: { display: "contents" } }) : t,
|
|
336
336
|
/* @__PURE__ */ e("div", { ref: r.setAppendNode, style: { display: "contents" } })
|
|
337
|
-
] }) : /* @__PURE__ */ e(
|
|
337
|
+
] }) : /* @__PURE__ */ e(ae, { children: t });
|
|
338
338
|
}
|
|
339
339
|
function Fs({
|
|
340
340
|
children: t,
|
|
@@ -375,7 +375,7 @@ function bo({ slotKey: t, fallback: r }) {
|
|
|
375
375
|
[t]
|
|
376
376
|
// slotKey is a stable string from group config
|
|
377
377
|
);
|
|
378
|
-
return /* @__PURE__ */ e(
|
|
378
|
+
return /* @__PURE__ */ e(ae, { children: o ? /* @__PURE__ */ e("div", { ref: l, style: { display: "contents" } }) : r });
|
|
379
379
|
}
|
|
380
380
|
function Ls({ slotKey: t, children: r }) {
|
|
381
381
|
const n = wt(Gr), o = oe(n == null ? void 0 : n.registerSlot);
|
|
@@ -477,7 +477,7 @@ function As({
|
|
|
477
477
|
resizableSidebar: b = !0
|
|
478
478
|
}) {
|
|
479
479
|
var xt, Et;
|
|
480
|
-
const { useSearchParams: S, useNavigate: v, useLocation: W, Outlet: F } = pt(), [
|
|
480
|
+
const { useSearchParams: S, useNavigate: v, useLocation: W, Outlet: F } = pt(), [A] = S(), D = A.get("embed") === "true", k = ei(), { badges: I } = lo(), B = v(), w = W(), z = !We("md"), [U, Q] = H(!1), {
|
|
481
481
|
collapsed: _,
|
|
482
482
|
setCollapsed: P,
|
|
483
483
|
width: X,
|
|
@@ -493,7 +493,7 @@ function As({
|
|
|
493
493
|
Y(() => {
|
|
494
494
|
bn = we;
|
|
495
495
|
}, [we]);
|
|
496
|
-
const pe = oe(null), He = oe(null), Je = oe(null), [ue, Ye] = H(!1), [ht, O] = H(null), K = b && !z && !_, q = (E) => Math.min(Math.max(E, T), V), he = ht ?? X,
|
|
496
|
+
const pe = oe(null), He = oe(null), Je = oe(null), [ue, Ye] = H(!1), [ht, O] = H(null), K = b && !z && !_, q = (E) => Math.min(Math.max(E, T), V), he = ht ?? X, de = (E) => {
|
|
497
497
|
var Fe, Ae, Pe;
|
|
498
498
|
if (!K) return;
|
|
499
499
|
E.preventDefault();
|
|
@@ -686,7 +686,7 @@ function As({
|
|
|
686
686
|
flexShrink: "0",
|
|
687
687
|
style: { alignItems: "center" },
|
|
688
688
|
children: [
|
|
689
|
-
/* @__PURE__ */ e(
|
|
689
|
+
/* @__PURE__ */ e(M, { name: E.icon, size: "sm", style: { flexShrink: 0 } }),
|
|
690
690
|
it && /* @__PURE__ */ e(
|
|
691
691
|
h,
|
|
692
692
|
{
|
|
@@ -707,7 +707,7 @@ function As({
|
|
|
707
707
|
]
|
|
708
708
|
}
|
|
709
709
|
),
|
|
710
|
-
(!_ || z) && /* @__PURE__ */ d(
|
|
710
|
+
(!_ || z) && /* @__PURE__ */ d(ae, { children: [
|
|
711
711
|
/* @__PURE__ */ e(
|
|
712
712
|
xn,
|
|
713
713
|
{
|
|
@@ -725,7 +725,7 @@ function As({
|
|
|
725
725
|
}
|
|
726
726
|
),
|
|
727
727
|
j && /* @__PURE__ */ e(
|
|
728
|
-
|
|
728
|
+
M,
|
|
729
729
|
{
|
|
730
730
|
name: "ChevronDown",
|
|
731
731
|
size: "sm",
|
|
@@ -823,7 +823,7 @@ function As({
|
|
|
823
823
|
},
|
|
824
824
|
children: [
|
|
825
825
|
/* @__PURE__ */ e(
|
|
826
|
-
|
|
826
|
+
M,
|
|
827
827
|
{
|
|
828
828
|
name: Fe.icon,
|
|
829
829
|
size: "sm",
|
|
@@ -928,7 +928,7 @@ function As({
|
|
|
928
928
|
},
|
|
929
929
|
children: (() => {
|
|
930
930
|
const E = !z && _ && !ce, j = E && Le;
|
|
931
|
-
return /* @__PURE__ */ d(
|
|
931
|
+
return /* @__PURE__ */ d(ae, { children: [
|
|
932
932
|
/* @__PURE__ */ d(
|
|
933
933
|
h,
|
|
934
934
|
{
|
|
@@ -981,7 +981,7 @@ function As({
|
|
|
981
981
|
justify: "center",
|
|
982
982
|
flexShrink: "0",
|
|
983
983
|
style: { color: "var(--sa-text-subtle, #8c8f97)" },
|
|
984
|
-
children: /* @__PURE__ */ e(
|
|
984
|
+
children: /* @__PURE__ */ e(M, { name: "LayoutLeft", size: "sm" })
|
|
985
985
|
}
|
|
986
986
|
),
|
|
987
987
|
E && /* @__PURE__ */ e(
|
|
@@ -1010,7 +1010,7 @@ function As({
|
|
|
1010
1010
|
pointerEvents: j ? "auto" : "none",
|
|
1011
1011
|
transition: "opacity 0.2s"
|
|
1012
1012
|
},
|
|
1013
|
-
children: /* @__PURE__ */ e(
|
|
1013
|
+
children: /* @__PURE__ */ e(M, { name: "LayoutLeft", size: "sm" })
|
|
1014
1014
|
}
|
|
1015
1015
|
),
|
|
1016
1016
|
z && /* @__PURE__ */ e(
|
|
@@ -1026,7 +1026,7 @@ function As({
|
|
|
1026
1026
|
padding: "0.375rem",
|
|
1027
1027
|
color: "var(--sa-text-subtle, #8c8f97)"
|
|
1028
1028
|
},
|
|
1029
|
-
children: /* @__PURE__ */ e(
|
|
1029
|
+
children: /* @__PURE__ */ e(M, { name: "Cross", size: "md" })
|
|
1030
1030
|
}
|
|
1031
1031
|
)
|
|
1032
1032
|
] });
|
|
@@ -1139,7 +1139,7 @@ function As({
|
|
|
1139
1139
|
"aria-valuemin": T,
|
|
1140
1140
|
"aria-valuemax": V,
|
|
1141
1141
|
tabIndex: 0,
|
|
1142
|
-
onPointerDown:
|
|
1142
|
+
onPointerDown: de,
|
|
1143
1143
|
onKeyDown: Me,
|
|
1144
1144
|
onDoubleClick: $,
|
|
1145
1145
|
title: "Drag to resize · double-click to reset",
|
|
@@ -1202,7 +1202,7 @@ function As({
|
|
|
1202
1202
|
padding: "0.375rem",
|
|
1203
1203
|
color: "var(--sa-text-subtle, #8c8f97)"
|
|
1204
1204
|
},
|
|
1205
|
-
children: /* @__PURE__ */ e(
|
|
1205
|
+
children: /* @__PURE__ */ e(M, { name: "MenuBurger", size: "lg" })
|
|
1206
1206
|
}
|
|
1207
1207
|
),
|
|
1208
1208
|
/* @__PURE__ */ e(po, { children: r })
|
|
@@ -1262,7 +1262,7 @@ function As({
|
|
|
1262
1262
|
}
|
|
1263
1263
|
),
|
|
1264
1264
|
/* @__PURE__ */ e(
|
|
1265
|
-
|
|
1265
|
+
M,
|
|
1266
1266
|
{
|
|
1267
1267
|
name: "ChevronDown",
|
|
1268
1268
|
size: "xs",
|
|
@@ -1347,7 +1347,7 @@ function As({
|
|
|
1347
1347
|
Ue,
|
|
1348
1348
|
{
|
|
1349
1349
|
onClick: E.onClick,
|
|
1350
|
-
startIcon: /* @__PURE__ */ e(
|
|
1350
|
+
startIcon: /* @__PURE__ */ e(M, { name: E.icon, size: "md" }),
|
|
1351
1351
|
children: E.label
|
|
1352
1352
|
},
|
|
1353
1353
|
`${E.label}-${j}`
|
|
@@ -1359,7 +1359,7 @@ function As({
|
|
|
1359
1359
|
{
|
|
1360
1360
|
intent: "danger",
|
|
1361
1361
|
onClick: lt,
|
|
1362
|
-
startIcon: /* @__PURE__ */ e(
|
|
1362
|
+
startIcon: /* @__PURE__ */ e(M, { name: "Logout", size: "md" }),
|
|
1363
1363
|
children: "Logout"
|
|
1364
1364
|
}
|
|
1365
1365
|
) })
|
|
@@ -1404,7 +1404,7 @@ function As({
|
|
|
1404
1404
|
/* @__PURE__ */ e(h, { direction: "column", children: /* @__PURE__ */ e(N, { primary: !0, onClick: Re, children: "Yes, Sure" }) })
|
|
1405
1405
|
] }) }) })
|
|
1406
1406
|
] }),
|
|
1407
|
-
ke && /* @__PURE__ */ d(
|
|
1407
|
+
ke && /* @__PURE__ */ d(ae, { children: [
|
|
1408
1408
|
/* @__PURE__ */ e(
|
|
1409
1409
|
h,
|
|
1410
1410
|
{
|
|
@@ -1479,7 +1479,7 @@ function As({
|
|
|
1479
1479
|
},
|
|
1480
1480
|
children: [
|
|
1481
1481
|
E.icon && /* @__PURE__ */ e(
|
|
1482
|
-
|
|
1482
|
+
M,
|
|
1483
1483
|
{
|
|
1484
1484
|
name: E.icon,
|
|
1485
1485
|
size: "sm",
|
|
@@ -1551,7 +1551,7 @@ const nr = Pr(
|
|
|
1551
1551
|
style: { cursor: "pointer" },
|
|
1552
1552
|
children: [
|
|
1553
1553
|
/* @__PURE__ */ e(
|
|
1554
|
-
|
|
1554
|
+
M,
|
|
1555
1555
|
{
|
|
1556
1556
|
name: r || "ChevronLeft",
|
|
1557
1557
|
size: "xs",
|
|
@@ -1583,7 +1583,7 @@ const nr = Pr(
|
|
|
1583
1583
|
hoverIconColor: i
|
|
1584
1584
|
}) => {
|
|
1585
1585
|
const { Link: l } = pt(), [c, s] = H(!1), a = o ?? "var(--sa-text-subtle, #8c8f97)", u = i ?? "var(--sa-text-subtle, #8c8f97)", m = t.length > 1 ? t[0] : void 0, p = !!(m != null && m.to || m != null && m.onClick), g = /* @__PURE__ */ e(
|
|
1586
|
-
|
|
1586
|
+
M,
|
|
1587
1587
|
{
|
|
1588
1588
|
name: n || "ChevronLeft",
|
|
1589
1589
|
size: "xs",
|
|
@@ -1732,7 +1732,7 @@ function wo({
|
|
|
1732
1732
|
onMouseLeave: () => c(void 0),
|
|
1733
1733
|
style: Sn,
|
|
1734
1734
|
children: [
|
|
1735
|
-
/* @__PURE__ */ e("div", { style: Dn(o === null, l === "all", a), children: /* @__PURE__ */ e("div", { style: { color: a.icon, display: "flex", alignItems: "center", justifyContent: "center" }, children: /* @__PURE__ */ e(
|
|
1735
|
+
/* @__PURE__ */ e("div", { style: Dn(o === null, l === "all", a), children: /* @__PURE__ */ e("div", { style: { color: a.icon, display: "flex", alignItems: "center", justifyContent: "center" }, children: /* @__PURE__ */ e(M, { name: "Grid", size: "lg", style: { width: 32, height: 32 } }) }) }),
|
|
1736
1736
|
/* @__PURE__ */ e("span", { style: kn, children: "Semua" })
|
|
1737
1737
|
]
|
|
1738
1738
|
}
|
|
@@ -1748,7 +1748,7 @@ function wo({
|
|
|
1748
1748
|
onMouseLeave: () => c(void 0),
|
|
1749
1749
|
style: Sn,
|
|
1750
1750
|
children: [
|
|
1751
|
-
/* @__PURE__ */ e("div", { style: Dn(p, g, S), children: /* @__PURE__ */ e("div", { style: { color: S.icon, display: "flex", alignItems: "center", justifyContent: "center" }, children: /* @__PURE__ */ e(
|
|
1751
|
+
/* @__PURE__ */ e("div", { style: Dn(p, g, S), children: /* @__PURE__ */ e("div", { style: { color: S.icon, display: "flex", alignItems: "center", justifyContent: "center" }, children: /* @__PURE__ */ e(M, { name: b, size: "lg", style: { width: 32, height: 32 } }) }) }),
|
|
1752
1752
|
/* @__PURE__ */ e("span", { style: kn, children: u.name })
|
|
1753
1753
|
]
|
|
1754
1754
|
},
|
|
@@ -1773,7 +1773,7 @@ function zs({
|
|
|
1773
1773
|
}
|
|
1774
1774
|
t == null || t(m);
|
|
1775
1775
|
};
|
|
1776
|
-
return /* @__PURE__ */ d(
|
|
1776
|
+
return /* @__PURE__ */ d(ae, { children: [
|
|
1777
1777
|
/* @__PURE__ */ d("div", { style: { position: "relative" }, children: [
|
|
1778
1778
|
/* @__PURE__ */ e(
|
|
1779
1779
|
"button",
|
|
@@ -1798,7 +1798,7 @@ function zs({
|
|
|
1798
1798
|
onMouseLeave: (m) => {
|
|
1799
1799
|
m.currentTarget.style.backgroundColor = "transparent";
|
|
1800
1800
|
},
|
|
1801
|
-
children: /* @__PURE__ */ e(
|
|
1801
|
+
children: /* @__PURE__ */ e(M, { name: "GridApplication", size: "sm" })
|
|
1802
1802
|
}
|
|
1803
1803
|
),
|
|
1804
1804
|
l !== null && /* @__PURE__ */ e(
|
|
@@ -1952,7 +1952,7 @@ const Do = (t, r) => {
|
|
|
1952
1952
|
style: { cursor: "pointer" },
|
|
1953
1953
|
children: [
|
|
1954
1954
|
/* @__PURE__ */ e(
|
|
1955
|
-
|
|
1955
|
+
M,
|
|
1956
1956
|
{
|
|
1957
1957
|
name: (t == null ? void 0 : t.iconName) || "ChevronLeft",
|
|
1958
1958
|
size: "xs",
|
|
@@ -1994,7 +1994,7 @@ const Do = (t, r) => {
|
|
|
1994
1994
|
containerProps: b,
|
|
1995
1995
|
headerProps: S
|
|
1996
1996
|
}) => {
|
|
1997
|
-
const v = We("md"), { Link: W, useNavigate: F, useLocation:
|
|
1997
|
+
const v = We("md"), { Link: W, useNavigate: F, useLocation: A } = pt(), D = F(), k = A(), I = t == null ? void 0 : t.show, B = () => {
|
|
1998
1998
|
if (typeof (t == null ? void 0 : t.onClick) == "function") {
|
|
1999
1999
|
t.onClick();
|
|
2000
2000
|
return;
|
|
@@ -2009,7 +2009,7 @@ const Do = (t, r) => {
|
|
|
2009
2009
|
return P.length === 0 ? null : v ? /* @__PURE__ */ e(h, { direction: "row", gap: "md", children: P.map(({ title: X, icon: re, buttonProps: $, onClick: T }, V) => /* @__PURE__ */ e(
|
|
2010
2010
|
N,
|
|
2011
2011
|
{
|
|
2012
|
-
iconLeft: re ? /* @__PURE__ */ e(
|
|
2012
|
+
iconLeft: re ? /* @__PURE__ */ e(M, { name: re, size: "md" }) : void 0,
|
|
2013
2013
|
onClick: T,
|
|
2014
2014
|
...$,
|
|
2015
2015
|
children: X
|
|
@@ -2022,7 +2022,7 @@ const Do = (t, r) => {
|
|
|
2022
2022
|
variant: "tertiary",
|
|
2023
2023
|
size: "sm",
|
|
2024
2024
|
iconLeft: /* @__PURE__ */ e(
|
|
2025
|
-
|
|
2025
|
+
M,
|
|
2026
2026
|
{
|
|
2027
2027
|
name: "MenuBurger"
|
|
2028
2028
|
}
|
|
@@ -2037,7 +2037,7 @@ const Do = (t, r) => {
|
|
|
2037
2037
|
{
|
|
2038
2038
|
intent: ce ? "danger" : void 0,
|
|
2039
2039
|
disabled: $ == null ? void 0 : $.disabled,
|
|
2040
|
-
startIcon: re ? /* @__PURE__ */ e(
|
|
2040
|
+
startIcon: re ? /* @__PURE__ */ e(M, { name: re }) : void 0,
|
|
2041
2041
|
onClick: T,
|
|
2042
2042
|
children: X
|
|
2043
2043
|
},
|
|
@@ -2091,7 +2091,7 @@ const Do = (t, r) => {
|
|
|
2091
2091
|
children: [
|
|
2092
2092
|
P ? typeof r == "string" ? /* @__PURE__ */ d(h, { direction: "row", gap: "lg", align: "center", children: [
|
|
2093
2093
|
/* @__PURE__ */ d(h, { direction: "row", gap: "sm", align: "center", children: [
|
|
2094
|
-
n && /* @__PURE__ */ e(
|
|
2094
|
+
n && /* @__PURE__ */ e(M, { name: n, size: "md", color: "primary" }),
|
|
2095
2095
|
/* @__PURE__ */ e(
|
|
2096
2096
|
C,
|
|
2097
2097
|
{
|
|
@@ -2215,7 +2215,7 @@ const Do = (t, r) => {
|
|
|
2215
2215
|
resizable: v = !0,
|
|
2216
2216
|
resizeMin: W = Mo,
|
|
2217
2217
|
resizeMax: F,
|
|
2218
|
-
onWidthChange:
|
|
2218
|
+
onWidthChange: A
|
|
2219
2219
|
}, D) => {
|
|
2220
2220
|
const I = !We("md"), B = s ?? u ?? a ?? "357px", w = S ?? [], R = w.length > 1, [z, U] = H(() => {
|
|
2221
2221
|
const J = w.indexOf(B);
|
|
@@ -2224,7 +2224,7 @@ const Do = (t, r) => {
|
|
|
2224
2224
|
T.current = J, typeof D == "function" ? D(J) : D && (D.current = J);
|
|
2225
2225
|
}, ce = R ? w[z] : B, Ce = Q != null ? `${Q}px` : ce, Le = v && !I, ge = z === w.length - 1, we = () => {
|
|
2226
2226
|
const J = (z + 1) % w.length;
|
|
2227
|
-
_(null), U(J),
|
|
2227
|
+
_(null), U(J), A == null || A(w[J]);
|
|
2228
2228
|
}, De = G(
|
|
2229
2229
|
(J) => {
|
|
2230
2230
|
const pe = F ?? window.innerWidth;
|
|
@@ -2267,7 +2267,7 @@ const Do = (t, r) => {
|
|
|
2267
2267
|
ue = null, ke.current != null && _(ke.current);
|
|
2268
2268
|
}));
|
|
2269
2269
|
}, ht = (O) => {
|
|
2270
|
-
ue != null && window.cancelAnimationFrame(ue), ke.current != null && _(ke.current), pe.releasePointerCapture(O.pointerId), pe.removeEventListener("pointermove", Ye), pe.removeEventListener("pointerup", ht), pe.removeEventListener("pointercancel", ht), document.body.style.cursor = He, document.body.style.userSelect = Je, X(!1), ke.current != null && (
|
|
2270
|
+
ue != null && window.cancelAnimationFrame(ue), ke.current != null && _(ke.current), pe.releasePointerCapture(O.pointerId), pe.removeEventListener("pointermove", Ye), pe.removeEventListener("pointerup", ht), pe.removeEventListener("pointercancel", ht), document.body.style.cursor = He, document.body.style.userSelect = Je, X(!1), ke.current != null && (A == null || A(`${ke.current}px`));
|
|
2271
2271
|
};
|
|
2272
2272
|
pe.addEventListener("pointermove", Ye), pe.addEventListener("pointerup", ht), pe.addEventListener("pointercancel", ht);
|
|
2273
2273
|
},
|
|
@@ -2276,10 +2276,10 @@ const Do = (t, r) => {
|
|
|
2276
2276
|
if (!Le || J.key !== "ArrowLeft" && J.key !== "ArrowRight") return;
|
|
2277
2277
|
J.preventDefault();
|
|
2278
2278
|
const pe = J.key === "ArrowLeft" ? En : -En, He = Q ?? ((ue = T.current) == null ? void 0 : ue.offsetWidth) ?? W, Je = De(He + pe);
|
|
2279
|
-
_(Je),
|
|
2279
|
+
_(Je), A == null || A(`${Je}px`);
|
|
2280
2280
|
},
|
|
2281
2281
|
onDoubleClick: () => {
|
|
2282
|
-
Le && (_(null),
|
|
2282
|
+
Le && (_(null), A == null || A(ce));
|
|
2283
2283
|
},
|
|
2284
2284
|
title: "Tarik untuk mengubah lebar — klik dua kali untuk reset",
|
|
2285
2285
|
onPointerEnter: () => $(!0),
|
|
@@ -2337,7 +2337,7 @@ const Do = (t, r) => {
|
|
|
2337
2337
|
onClick: we,
|
|
2338
2338
|
"aria-label": ge ? "Kecilkan panel" : "Lebarkan panel",
|
|
2339
2339
|
iconRight: /* @__PURE__ */ e(
|
|
2340
|
-
|
|
2340
|
+
M,
|
|
2341
2341
|
{
|
|
2342
2342
|
name: ge ? "ChevronRight" : "ChevronLeft"
|
|
2343
2343
|
}
|
|
@@ -2352,7 +2352,7 @@ const Do = (t, r) => {
|
|
|
2352
2352
|
size: "xs",
|
|
2353
2353
|
onClick: t,
|
|
2354
2354
|
"aria-label": l.title || "Tutup",
|
|
2355
|
-
iconRight: /* @__PURE__ */ e(
|
|
2355
|
+
iconRight: /* @__PURE__ */ e(M, { name: l.icon }),
|
|
2356
2356
|
children: l.title || void 0
|
|
2357
2357
|
}
|
|
2358
2358
|
) : null
|
|
@@ -2692,7 +2692,7 @@ const Do = (t, r) => {
|
|
|
2692
2692
|
titleSearchLabel: S = "Work Order",
|
|
2693
2693
|
withTitleLabels: v = !1
|
|
2694
2694
|
}) => {
|
|
2695
|
-
const F = (g == null ? void 0 : g.isShowLabel) ?? !0, [
|
|
2695
|
+
const F = (g == null ? void 0 : g.isShowLabel) ?? !0, [A, D] = H(!1), [k, I] = H(0), B = () => {
|
|
2696
2696
|
I((V) => V + 1);
|
|
2697
2697
|
}, { searchParams: w, setSearchParams: R, getQueryParam: z } = rt(), U = tr(w.toString()), Q = qr(t, w, s) || "", [_, P] = H(Q), X = z(s), $ = !!(X && !(() => {
|
|
2698
2698
|
if (X)
|
|
@@ -2774,7 +2774,7 @@ const Do = (t, r) => {
|
|
|
2774
2774
|
primary: $,
|
|
2775
2775
|
secondary: !$,
|
|
2776
2776
|
iconLeft: /* @__PURE__ */ e(
|
|
2777
|
-
|
|
2777
|
+
M,
|
|
2778
2778
|
{
|
|
2779
2779
|
size: "sm",
|
|
2780
2780
|
name: (g == null ? void 0 : g.icon) || "FilterHorizontal",
|
|
@@ -2864,7 +2864,7 @@ const Do = (t, r) => {
|
|
|
2864
2864
|
Mt,
|
|
2865
2865
|
{
|
|
2866
2866
|
placeholder: n,
|
|
2867
|
-
leftIcon: /* @__PURE__ */ e(
|
|
2867
|
+
leftIcon: /* @__PURE__ */ e(M, { name: "Search", width: 20, height: 20 }),
|
|
2868
2868
|
onChange: (V) => P(V.target.value),
|
|
2869
2869
|
value: _,
|
|
2870
2870
|
fullWidth: !0
|
|
@@ -2877,7 +2877,7 @@ const Do = (t, r) => {
|
|
|
2877
2877
|
/* @__PURE__ */ e(
|
|
2878
2878
|
Ko,
|
|
2879
2879
|
{
|
|
2880
|
-
isOpen:
|
|
2880
|
+
isOpen: A,
|
|
2881
2881
|
onClose: () => D(!1),
|
|
2882
2882
|
filterKey: s,
|
|
2883
2883
|
filters: p,
|
|
@@ -2996,7 +2996,7 @@ function Ur({
|
|
|
2996
2996
|
k in B && (delete B[k], Object.keys(B).length ? I[r] = JSON.stringify(B) : delete I[r]), delete I[o], c(I);
|
|
2997
2997
|
},
|
|
2998
2998
|
[s, r, o, m, c]
|
|
2999
|
-
),
|
|
2999
|
+
), A = G(() => {
|
|
3000
3000
|
const k = { ...s };
|
|
3001
3001
|
delete k[r], delete k[n], delete k[o], c(k);
|
|
3002
3002
|
}, [s, r, n, o, c]), D = u.length > 0;
|
|
@@ -3010,7 +3010,7 @@ function Ur({
|
|
|
3010
3010
|
getValue: v,
|
|
3011
3011
|
setValue: W,
|
|
3012
3012
|
clearValue: F,
|
|
3013
|
-
clearAll:
|
|
3013
|
+
clearAll: A
|
|
3014
3014
|
};
|
|
3015
3015
|
}
|
|
3016
3016
|
const ui = {
|
|
@@ -3082,7 +3082,7 @@ function rl({
|
|
|
3082
3082
|
v({ ...a, hidden: R });
|
|
3083
3083
|
},
|
|
3084
3084
|
[a, v]
|
|
3085
|
-
),
|
|
3085
|
+
), A = G(
|
|
3086
3086
|
(w, R) => {
|
|
3087
3087
|
if (w === R) return;
|
|
3088
3088
|
const z = [...a.order], [U] = z.splice(w, 1);
|
|
@@ -3106,7 +3106,7 @@ function rl({
|
|
|
3106
3106
|
orderedColumns: W,
|
|
3107
3107
|
allVisible: B,
|
|
3108
3108
|
toggleVisibility: F,
|
|
3109
|
-
reorder:
|
|
3109
|
+
reorder: A,
|
|
3110
3110
|
setAllHidden: D,
|
|
3111
3111
|
reset: k,
|
|
3112
3112
|
applyState: I
|
|
@@ -3137,14 +3137,14 @@ function nl({
|
|
|
3137
3137
|
const k = c.get(D);
|
|
3138
3138
|
k != null && (F[D] = k);
|
|
3139
3139
|
});
|
|
3140
|
-
const
|
|
3140
|
+
const A = {
|
|
3141
3141
|
id: `${Date.now()}`,
|
|
3142
3142
|
name: W,
|
|
3143
3143
|
query: F,
|
|
3144
3144
|
columns: i == null ? void 0 : i(),
|
|
3145
3145
|
createdAt: Date.now()
|
|
3146
3146
|
};
|
|
3147
|
-
p([...u,
|
|
3147
|
+
p([...u, A]);
|
|
3148
3148
|
},
|
|
3149
3149
|
[n, c, i, p, u]
|
|
3150
3150
|
), b = G(
|
|
@@ -3313,7 +3313,7 @@ const al = ({
|
|
|
3313
3313
|
variant: o ? "secondary" : "outline",
|
|
3314
3314
|
tone: "neutral",
|
|
3315
3315
|
size: "sm",
|
|
3316
|
-
iconLeft: /* @__PURE__ */ e(
|
|
3316
|
+
iconLeft: /* @__PURE__ */ e(M, { name: "FilterHorizontal" }),
|
|
3317
3317
|
"aria-label": "Add filter"
|
|
3318
3318
|
}
|
|
3319
3319
|
) }),
|
|
@@ -3370,7 +3370,7 @@ const al = ({
|
|
|
3370
3370
|
variant: "link",
|
|
3371
3371
|
tone: "neutral",
|
|
3372
3372
|
size: "xs",
|
|
3373
|
-
iconLeft: /* @__PURE__ */ e(
|
|
3373
|
+
iconLeft: /* @__PURE__ */ e(M, { name: "MenuHorizontal" }),
|
|
3374
3374
|
"aria-label": "Filter actions"
|
|
3375
3375
|
}
|
|
3376
3376
|
) }),
|
|
@@ -3378,7 +3378,7 @@ const al = ({
|
|
|
3378
3378
|
/* @__PURE__ */ e(
|
|
3379
3379
|
Ue,
|
|
3380
3380
|
{
|
|
3381
|
-
startIcon: /* @__PURE__ */ e(
|
|
3381
|
+
startIcon: /* @__PURE__ */ e(M, { name: "CrossCircle" }),
|
|
3382
3382
|
onClick: t,
|
|
3383
3383
|
children: "Clear value"
|
|
3384
3384
|
}
|
|
@@ -3387,7 +3387,7 @@ const al = ({
|
|
|
3387
3387
|
Ue,
|
|
3388
3388
|
{
|
|
3389
3389
|
intent: "danger",
|
|
3390
|
-
startIcon: /* @__PURE__ */ e(
|
|
3390
|
+
startIcon: /* @__PURE__ */ e(M, { name: "Trash1" }),
|
|
3391
3391
|
onClick: r,
|
|
3392
3392
|
children: "Remove filter"
|
|
3393
3393
|
}
|
|
@@ -3460,7 +3460,7 @@ const al = ({
|
|
|
3460
3460
|
onClear: o,
|
|
3461
3461
|
onRemove: i
|
|
3462
3462
|
}) => {
|
|
3463
|
-
const l = r ? mi(new Date(r)) : null, c = !!l, s = c ? /* @__PURE__ */ d(
|
|
3463
|
+
const l = r ? mi(new Date(r)) : null, c = !!l, s = c ? /* @__PURE__ */ d(ae, { children: [
|
|
3464
3464
|
/* @__PURE__ */ d("span", { style: { fontWeight: 500 }, children: [
|
|
3465
3465
|
t.label,
|
|
3466
3466
|
":"
|
|
@@ -3475,8 +3475,8 @@ const al = ({
|
|
|
3475
3475
|
variant: c ? "secondary" : "outline",
|
|
3476
3476
|
tone: "neutral",
|
|
3477
3477
|
size: "sm",
|
|
3478
|
-
iconLeft: c ? /* @__PURE__ */ e(
|
|
3479
|
-
iconRight: /* @__PURE__ */ e(
|
|
3478
|
+
iconLeft: c ? /* @__PURE__ */ e(M, { name: "Calendar", size: "sm" }) : void 0,
|
|
3479
|
+
iconRight: /* @__PURE__ */ e(M, { name: "ChevronSmallDown" }),
|
|
3480
3480
|
children: s
|
|
3481
3481
|
}
|
|
3482
3482
|
) }),
|
|
@@ -3543,7 +3543,7 @@ const al = ({
|
|
|
3543
3543
|
onClear: o,
|
|
3544
3544
|
onRemove: i
|
|
3545
3545
|
}) => {
|
|
3546
|
-
const l = t.ops && t.ops.length > 0 ? t.ops : ul, c = t.defaultOp && l.includes(t.defaultOp) ? t.defaultOp : l[0], s = t.mode ?? "days", a = (r == null ? void 0 : r.op) ?? c, u = r ? pl(r, s) : null, m = !!u, p = m ? /* @__PURE__ */ d(
|
|
3546
|
+
const l = t.ops && t.ops.length > 0 ? t.ops : ul, c = t.defaultOp && l.includes(t.defaultOp) ? t.defaultOp : l[0], s = t.mode ?? "days", a = (r == null ? void 0 : r.op) ?? c, u = r ? pl(r, s) : null, m = !!u, p = m ? /* @__PURE__ */ d(ae, { children: [
|
|
3547
3547
|
/* @__PURE__ */ d("span", { style: { fontWeight: 500 }, children: [
|
|
3548
3548
|
t.label,
|
|
3549
3549
|
":"
|
|
@@ -3581,8 +3581,8 @@ const al = ({
|
|
|
3581
3581
|
variant: m ? "secondary" : "outline",
|
|
3582
3582
|
tone: "neutral",
|
|
3583
3583
|
size: "sm",
|
|
3584
|
-
iconLeft: m ? /* @__PURE__ */ e(
|
|
3585
|
-
iconRight: /* @__PURE__ */ e(
|
|
3584
|
+
iconLeft: m ? /* @__PURE__ */ e(M, { name: "Calendar", size: "sm" }) : void 0,
|
|
3585
|
+
iconRight: /* @__PURE__ */ e(M, { name: "ChevronSmallDown" }),
|
|
3586
3586
|
children: p
|
|
3587
3587
|
}
|
|
3588
3588
|
) }),
|
|
@@ -3632,7 +3632,7 @@ const al = ({
|
|
|
3632
3632
|
variant: "link",
|
|
3633
3633
|
tone: "neutral",
|
|
3634
3634
|
size: "xs",
|
|
3635
|
-
iconRight: /* @__PURE__ */ e(
|
|
3635
|
+
iconRight: /* @__PURE__ */ e(M, { name: "ChevronSmallDown" }),
|
|
3636
3636
|
children: Kt[t]
|
|
3637
3637
|
}
|
|
3638
3638
|
) }),
|
|
@@ -3641,7 +3641,7 @@ const al = ({
|
|
|
3641
3641
|
{
|
|
3642
3642
|
selected: t === o,
|
|
3643
3643
|
onClick: () => n(o),
|
|
3644
|
-
endIcon: t === o ? /* @__PURE__ */ e(
|
|
3644
|
+
endIcon: t === o ? /* @__PURE__ */ e(M, { name: "Check" }) : void 0,
|
|
3645
3645
|
children: Kt[o]
|
|
3646
3646
|
},
|
|
3647
3647
|
o
|
|
@@ -3727,7 +3727,7 @@ const al = ({
|
|
|
3727
3727
|
variant: "outline",
|
|
3728
3728
|
tone: "neutral",
|
|
3729
3729
|
size: "sm",
|
|
3730
|
-
iconRight: /* @__PURE__ */ e(
|
|
3730
|
+
iconRight: /* @__PURE__ */ e(M, { name: "ChevronSmallDown" }),
|
|
3731
3731
|
children: Or[n]
|
|
3732
3732
|
}
|
|
3733
3733
|
) }),
|
|
@@ -3735,7 +3735,7 @@ const al = ({
|
|
|
3735
3735
|
Ue,
|
|
3736
3736
|
{
|
|
3737
3737
|
selected: n === s,
|
|
3738
|
-
endIcon: n === s ? /* @__PURE__ */ e(
|
|
3738
|
+
endIcon: n === s ? /* @__PURE__ */ e(M, { name: "Check" }) : void 0,
|
|
3739
3739
|
onClick: () => r(
|
|
3740
3740
|
s === "this" ? { direction: s, period: i } : { direction: s, count: o, period: i }
|
|
3741
3741
|
),
|
|
@@ -3770,7 +3770,7 @@ const al = ({
|
|
|
3770
3770
|
variant: "outline",
|
|
3771
3771
|
tone: "neutral",
|
|
3772
3772
|
size: "sm",
|
|
3773
|
-
iconRight: /* @__PURE__ */ e(
|
|
3773
|
+
iconRight: /* @__PURE__ */ e(M, { name: "ChevronSmallDown" }),
|
|
3774
3774
|
children: i
|
|
3775
3775
|
}
|
|
3776
3776
|
) }),
|
|
@@ -3778,7 +3778,7 @@ const al = ({
|
|
|
3778
3778
|
Ue,
|
|
3779
3779
|
{
|
|
3780
3780
|
selected: i === s,
|
|
3781
|
-
endIcon: i === s ? /* @__PURE__ */ e(
|
|
3781
|
+
endIcon: i === s ? /* @__PURE__ */ e(M, { name: "Check" }) : void 0,
|
|
3782
3782
|
onClick: () => r(
|
|
3783
3783
|
n === "this" ? { direction: n, period: s } : { direction: n, count: o, period: s }
|
|
3784
3784
|
),
|
|
@@ -3813,19 +3813,19 @@ const al = ({
|
|
|
3813
3813
|
const l = t.type === "dropdown-multiple", c = r.length, s = t.searchable !== !1, [a, u] = H(""), m = t.options, p = typeof t.onSearch == "function", g = (() => {
|
|
3814
3814
|
if (p) return m;
|
|
3815
3815
|
const F = a.trim().toLowerCase();
|
|
3816
|
-
return F ? m.filter((
|
|
3817
|
-
})(), b = (F) => r.some((
|
|
3816
|
+
return F ? m.filter((A) => A.label.toLowerCase().includes(F)) : m;
|
|
3817
|
+
})(), b = (F) => r.some((A) => A.value === F.value), S = (F) => {
|
|
3818
3818
|
if (!l) {
|
|
3819
3819
|
n([{ label: F.label, value: F.value }]), u("");
|
|
3820
3820
|
return;
|
|
3821
3821
|
}
|
|
3822
3822
|
n(
|
|
3823
|
-
b(F) ? r.filter((
|
|
3823
|
+
b(F) ? r.filter((A) => A.value !== F.value) : [...r, { label: F.label, value: F.value }]
|
|
3824
3824
|
);
|
|
3825
3825
|
}, v = (F) => {
|
|
3826
|
-
var
|
|
3827
|
-
u(F), (
|
|
3828
|
-
}, W = c === 0 ? t.label : /* @__PURE__ */ d(
|
|
3826
|
+
var A;
|
|
3827
|
+
u(F), (A = t.onSearch) == null || A.call(t, F);
|
|
3828
|
+
}, W = c === 0 ? t.label : /* @__PURE__ */ d(ae, { children: [
|
|
3829
3829
|
/* @__PURE__ */ d("span", { style: { fontWeight: 500 }, children: [
|
|
3830
3830
|
t.label,
|
|
3831
3831
|
":"
|
|
@@ -3840,8 +3840,8 @@ const al = ({
|
|
|
3840
3840
|
variant: c > 0 ? "secondary" : "outline",
|
|
3841
3841
|
tone: "neutral",
|
|
3842
3842
|
size: "sm",
|
|
3843
|
-
iconLeft: c > 0 ? /* @__PURE__ */ e(
|
|
3844
|
-
iconRight: /* @__PURE__ */ e(
|
|
3843
|
+
iconLeft: c > 0 ? /* @__PURE__ */ e(M, { name: "Tag", size: "sm" }) : void 0,
|
|
3844
|
+
iconRight: /* @__PURE__ */ e(M, { name: "ChevronSmallDown" }),
|
|
3845
3845
|
children: W
|
|
3846
3846
|
}
|
|
3847
3847
|
) }),
|
|
@@ -3893,7 +3893,7 @@ const al = ({
|
|
|
3893
3893
|
closeOnSelect: !l,
|
|
3894
3894
|
selected: b(F),
|
|
3895
3895
|
startIcon: F.avatar,
|
|
3896
|
-
endIcon: b(F) ? /* @__PURE__ */ e(
|
|
3896
|
+
endIcon: b(F) ? /* @__PURE__ */ e(M, { name: "Check" }) : void 0,
|
|
3897
3897
|
description: F.description,
|
|
3898
3898
|
onClick: () => S(F),
|
|
3899
3899
|
children: F.label
|
|
@@ -3931,7 +3931,7 @@ const al = ({
|
|
|
3931
3931
|
n(
|
|
3932
3932
|
s ? [] : t.options.map((g) => ({ label: g.label, value: g.value }))
|
|
3933
3933
|
);
|
|
3934
|
-
}, p = c === 0 ? t.label : /* @__PURE__ */ d(
|
|
3934
|
+
}, p = c === 0 ? t.label : /* @__PURE__ */ d(ae, { children: [
|
|
3935
3935
|
/* @__PURE__ */ d(C, { as: "span", fontWeight: "semibold", children: [
|
|
3936
3936
|
t.label,
|
|
3937
3937
|
":"
|
|
@@ -3946,8 +3946,8 @@ const al = ({
|
|
|
3946
3946
|
variant: c > 0 ? "secondary" : "outline",
|
|
3947
3947
|
tone: "neutral",
|
|
3948
3948
|
size: "sm",
|
|
3949
|
-
iconLeft: c > 0 ? /* @__PURE__ */ e(
|
|
3950
|
-
iconRight: /* @__PURE__ */ e(
|
|
3949
|
+
iconLeft: c > 0 ? /* @__PURE__ */ e(M, { name: "Tag", size: "sm" }) : void 0,
|
|
3950
|
+
iconRight: /* @__PURE__ */ e(M, { name: "ChevronSmallDown" }),
|
|
3951
3951
|
children: p
|
|
3952
3952
|
}
|
|
3953
3953
|
) }),
|
|
@@ -4008,7 +4008,7 @@ const al = ({
|
|
|
4008
4008
|
setValue: o,
|
|
4009
4009
|
clearValue: i,
|
|
4010
4010
|
removeFilter: l
|
|
4011
|
-
}) => /* @__PURE__ */ e(
|
|
4011
|
+
}) => /* @__PURE__ */ e(ae, { children: t.map((c) => {
|
|
4012
4012
|
const s = r[c];
|
|
4013
4013
|
if (!s) return null;
|
|
4014
4014
|
const a = n(s), u = s.locked ? void 0 : () => l(c);
|
|
@@ -4054,17 +4054,17 @@ const al = ({
|
|
|
4054
4054
|
showPagination: s = !0
|
|
4055
4055
|
}) => {
|
|
4056
4056
|
var F;
|
|
4057
|
-
const { searchQueries: a, setSearchParams: u, searchParams: m } = rt(), p = m.get(n), g = p ? Number(p) : i, b = (
|
|
4058
|
-
u({ ...a, [r]: String(
|
|
4059
|
-
}, S = (
|
|
4057
|
+
const { searchQueries: a, setSearchParams: u, searchParams: m } = rt(), p = m.get(n), g = p ? Number(p) : i, b = (A) => {
|
|
4058
|
+
u({ ...a, [r]: String(A) });
|
|
4059
|
+
}, S = (A) => {
|
|
4060
4060
|
u({
|
|
4061
4061
|
...a,
|
|
4062
|
-
[n]:
|
|
4062
|
+
[n]: A,
|
|
4063
4063
|
[r]: "1"
|
|
4064
4064
|
// reset to first page when page size changes
|
|
4065
4065
|
});
|
|
4066
4066
|
}, v = (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 : 0), W = (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));
|
|
4067
|
-
return /* @__PURE__ */ d(
|
|
4067
|
+
return /* @__PURE__ */ d(ae, { children: [
|
|
4068
4068
|
l && /* @__PURE__ */ e(C, { fontSize: "sm", fontWeight: "medium", color: "primary", truncate: !0, children: `${v}-${W} of ${((F = t == null ? void 0 : t.totalData) == null ? void 0 : F.toLocaleString()) || 0}` }),
|
|
4069
4069
|
c && /* @__PURE__ */ d(je, { position: "bottom-left", children: [
|
|
4070
4070
|
/* @__PURE__ */ e(Ze, { children: /* @__PURE__ */ e(
|
|
@@ -4073,19 +4073,19 @@ const al = ({
|
|
|
4073
4073
|
variant: "outline",
|
|
4074
4074
|
tone: "neutral",
|
|
4075
4075
|
size: "sm",
|
|
4076
|
-
iconRight: /* @__PURE__ */ e(
|
|
4076
|
+
iconRight: /* @__PURE__ */ e(M, { name: "ChevronSmallDown" }),
|
|
4077
4077
|
"aria-label": "Rows per page",
|
|
4078
4078
|
children: Bn(g)
|
|
4079
4079
|
}
|
|
4080
4080
|
) }),
|
|
4081
|
-
/* @__PURE__ */ e(Ge, { children: /* @__PURE__ */ e(qe, { children: o.map((
|
|
4081
|
+
/* @__PURE__ */ e(Ge, { children: /* @__PURE__ */ e(qe, { children: o.map((A) => /* @__PURE__ */ e(
|
|
4082
4082
|
Ue,
|
|
4083
4083
|
{
|
|
4084
|
-
selected:
|
|
4085
|
-
onClick: () => S(String(
|
|
4086
|
-
children: Bn(
|
|
4084
|
+
selected: A === g,
|
|
4085
|
+
onClick: () => S(String(A)),
|
|
4086
|
+
children: Bn(A)
|
|
4087
4087
|
},
|
|
4088
|
-
|
|
4088
|
+
A
|
|
4089
4089
|
)) }) })
|
|
4090
4090
|
] }),
|
|
4091
4091
|
s && ((t == null ? void 0 : t.totalPage) ?? 0) > 1 && /* @__PURE__ */ e(
|
|
@@ -4150,13 +4150,13 @@ const Fl = 240, pi = ({
|
|
|
4150
4150
|
pageKey: n
|
|
4151
4151
|
});
|
|
4152
4152
|
}, [W]);
|
|
4153
|
-
const
|
|
4153
|
+
const A = G(() => {
|
|
4154
4154
|
p(!0), requestAnimationFrame(() => {
|
|
4155
4155
|
var B;
|
|
4156
4156
|
return (B = F.current) == null ? void 0 : B.focus();
|
|
4157
4157
|
});
|
|
4158
4158
|
}, []);
|
|
4159
|
-
return El(i,
|
|
4159
|
+
return El(i, A), // No internal gap: the trigger and the animated input are never visible at
|
|
4160
4160
|
// the same time, so spacing to neighbours is handled by the parent cluster.
|
|
4161
4161
|
/* @__PURE__ */ d(h, { display: "flex", direction: "row", align: "center", gap: "spacing-0", children: [
|
|
4162
4162
|
g && /* @__PURE__ */ e(
|
|
@@ -4165,10 +4165,10 @@ const Fl = 240, pi = ({
|
|
|
4165
4165
|
variant: "outline",
|
|
4166
4166
|
tone: "neutral",
|
|
4167
4167
|
size: "sm",
|
|
4168
|
-
iconLeft: /* @__PURE__ */ e(
|
|
4168
|
+
iconLeft: /* @__PURE__ */ e(M, { name: "Search", size: "sm" }),
|
|
4169
4169
|
"aria-label": "Search",
|
|
4170
4170
|
"aria-expanded": !1,
|
|
4171
|
-
onClick:
|
|
4171
|
+
onClick: A
|
|
4172
4172
|
}
|
|
4173
4173
|
),
|
|
4174
4174
|
/* @__PURE__ */ d(
|
|
@@ -4192,7 +4192,7 @@ const Fl = 240, pi = ({
|
|
|
4192
4192
|
fullWidth: !0,
|
|
4193
4193
|
value: S,
|
|
4194
4194
|
placeholder: o,
|
|
4195
|
-
leftIcon: /* @__PURE__ */ e(
|
|
4195
|
+
leftIcon: /* @__PURE__ */ e(M, { name: "Search", width: 16, height: 16 }),
|
|
4196
4196
|
onChange: (B) => v(B.target.value),
|
|
4197
4197
|
onKeyDown: (B) => {
|
|
4198
4198
|
var w;
|
|
@@ -4252,7 +4252,7 @@ const Fl = 240, pi = ({
|
|
|
4252
4252
|
variant: r ? "outline" : "secondary",
|
|
4253
4253
|
tone: "neutral",
|
|
4254
4254
|
size: "sm",
|
|
4255
|
-
iconLeft: /* @__PURE__ */ e(
|
|
4255
|
+
iconLeft: /* @__PURE__ */ e(M, { name: "Grid", size: "sm" }),
|
|
4256
4256
|
"aria-label": "Customize columns"
|
|
4257
4257
|
}
|
|
4258
4258
|
) }),
|
|
@@ -4331,7 +4331,7 @@ const Fl = 240, pi = ({
|
|
|
4331
4331
|
cursor: b ? "grab" : "default",
|
|
4332
4332
|
opacity: b ? 1 : 0.4
|
|
4333
4333
|
},
|
|
4334
|
-
children: /* @__PURE__ */ e(
|
|
4334
|
+
children: /* @__PURE__ */ e(M, { name: "DragVertical", width: 16, height: 16 })
|
|
4335
4335
|
}
|
|
4336
4336
|
),
|
|
4337
4337
|
p.icon && /* @__PURE__ */ e(h, { direction: "column", align: "center", color: "icon-subtle", style: { display: "inline-flex" }, children: p.icon }),
|
|
@@ -4381,7 +4381,7 @@ const Fl = 240, pi = ({
|
|
|
4381
4381
|
variant: t.length > 0 ? "secondary" : "outline",
|
|
4382
4382
|
tone: (t.length > 0, "neutral"),
|
|
4383
4383
|
size: "sm",
|
|
4384
|
-
iconLeft: /* @__PURE__ */ e(
|
|
4384
|
+
iconLeft: /* @__PURE__ */ e(M, { name: "Bookmark", size: "sm" }),
|
|
4385
4385
|
"aria-label": "Saved views"
|
|
4386
4386
|
}
|
|
4387
4387
|
) }),
|
|
@@ -4402,7 +4402,7 @@ const Fl = 240, pi = ({
|
|
|
4402
4402
|
children: t.length === 0 ? /* @__PURE__ */ e(h, { direction: "column", paddingBlock: "sm", children: /* @__PURE__ */ e(C, { fontSize: "sm", color: "subtlest", children: "No saved views yet" }) }) : t.map((s) => /* @__PURE__ */ e(
|
|
4403
4403
|
Ue,
|
|
4404
4404
|
{
|
|
4405
|
-
startIcon: /* @__PURE__ */ e(
|
|
4405
|
+
startIcon: /* @__PURE__ */ e(M, { name: "Bookmark" }),
|
|
4406
4406
|
onClick: () => r(s),
|
|
4407
4407
|
endIcon: /* @__PURE__ */ e(
|
|
4408
4408
|
N,
|
|
@@ -4410,7 +4410,7 @@ const Fl = 240, pi = ({
|
|
|
4410
4410
|
variant: "link",
|
|
4411
4411
|
tone: "error",
|
|
4412
4412
|
size: "sm",
|
|
4413
|
-
iconLeft: /* @__PURE__ */ e(
|
|
4413
|
+
iconLeft: /* @__PURE__ */ e(M, { name: "Trash2" }),
|
|
4414
4414
|
"aria-label": `Delete ${s.name}`,
|
|
4415
4415
|
onClick: (a) => {
|
|
4416
4416
|
a.stopPropagation(), n(s.id);
|
|
@@ -4508,7 +4508,7 @@ const Fl = 240, pi = ({
|
|
|
4508
4508
|
variant: "link",
|
|
4509
4509
|
tone: "neutral",
|
|
4510
4510
|
size: "sm",
|
|
4511
|
-
iconLeft: /* @__PURE__ */ e(
|
|
4511
|
+
iconLeft: /* @__PURE__ */ e(M, { name: "Cross" }),
|
|
4512
4512
|
"aria-label": "Close filter",
|
|
4513
4513
|
onClick: r
|
|
4514
4514
|
}
|
|
@@ -4671,7 +4671,7 @@ const Fl = 240, pi = ({
|
|
|
4671
4671
|
variant: "outline",
|
|
4672
4672
|
tone: "neutral",
|
|
4673
4673
|
size: "sm",
|
|
4674
|
-
iconLeft: /* @__PURE__ */ e(
|
|
4674
|
+
iconLeft: /* @__PURE__ */ e(M, { name: "MenuVertical", size: "sm" }),
|
|
4675
4675
|
"aria-label": "More options"
|
|
4676
4676
|
}
|
|
4677
4677
|
) }),
|
|
@@ -4681,7 +4681,7 @@ const Fl = 240, pi = ({
|
|
|
4681
4681
|
Ue,
|
|
4682
4682
|
{
|
|
4683
4683
|
selected: p === u,
|
|
4684
|
-
endIcon: p === u ? /* @__PURE__ */ e(
|
|
4684
|
+
endIcon: p === u ? /* @__PURE__ */ e(M, { name: "Check" }) : void 0,
|
|
4685
4685
|
onClick: () => m(String(p)),
|
|
4686
4686
|
children: Ml(p)
|
|
4687
4687
|
},
|
|
@@ -4709,7 +4709,7 @@ const Fl = 240, pi = ({
|
|
|
4709
4709
|
pageKey: v,
|
|
4710
4710
|
searchPlaceholder: W,
|
|
4711
4711
|
searchShortcut: F,
|
|
4712
|
-
searchCollapsible:
|
|
4712
|
+
searchCollapsible: A,
|
|
4713
4713
|
pagination: D,
|
|
4714
4714
|
perPageKey: k,
|
|
4715
4715
|
pageSizeOptions: I,
|
|
@@ -4766,7 +4766,7 @@ const Fl = 240, pi = ({
|
|
|
4766
4766
|
pageKey: v,
|
|
4767
4767
|
placeholder: W,
|
|
4768
4768
|
shortcut: F,
|
|
4769
|
-
collapsible:
|
|
4769
|
+
collapsible: A
|
|
4770
4770
|
}
|
|
4771
4771
|
),
|
|
4772
4772
|
/* @__PURE__ */ e(
|
|
@@ -4775,7 +4775,7 @@ const Fl = 240, pi = ({
|
|
|
4775
4775
|
variant: l ? "secondary" : "outline",
|
|
4776
4776
|
tone: "neutral",
|
|
4777
4777
|
size: "sm",
|
|
4778
|
-
iconLeft: /* @__PURE__ */ e(
|
|
4778
|
+
iconLeft: /* @__PURE__ */ e(M, { name: "FilterHorizontal" }),
|
|
4779
4779
|
onClick: () => we(!0),
|
|
4780
4780
|
"aria-label": "Open filters",
|
|
4781
4781
|
children: l ? `Filter: ${o.length}` : null
|
|
@@ -4890,7 +4890,7 @@ const Fl = 240, pi = ({
|
|
|
4890
4890
|
searchPosition: v = "right",
|
|
4891
4891
|
searchCollapsible: W = !0,
|
|
4892
4892
|
pagination: F,
|
|
4893
|
-
columns:
|
|
4893
|
+
columns: A = [],
|
|
4894
4894
|
onColumnsChange: D,
|
|
4895
4895
|
columnsState: k,
|
|
4896
4896
|
scopeId: I,
|
|
@@ -4918,7 +4918,7 @@ const Fl = 240, pi = ({
|
|
|
4918
4918
|
pageKey: i,
|
|
4919
4919
|
searchKey: g
|
|
4920
4920
|
}), ge = rl({
|
|
4921
|
-
columns:
|
|
4921
|
+
columns: A,
|
|
4922
4922
|
scopeId: _,
|
|
4923
4923
|
storage: z,
|
|
4924
4924
|
onColumnsChange: D,
|
|
@@ -5063,7 +5063,7 @@ const Fl = 240, pi = ({
|
|
|
5063
5063
|
onSave: we.saveView
|
|
5064
5064
|
}
|
|
5065
5065
|
),
|
|
5066
|
-
|
|
5066
|
+
A.length > 0 && /* @__PURE__ */ e(
|
|
5067
5067
|
yi,
|
|
5068
5068
|
{
|
|
5069
5069
|
columns: ge.orderedColumns,
|
|
@@ -5104,7 +5104,7 @@ const Fl = 240, pi = ({
|
|
|
5104
5104
|
showPagination: a,
|
|
5105
5105
|
showResultCount: u,
|
|
5106
5106
|
showPageSize: m,
|
|
5107
|
-
hasColumns:
|
|
5107
|
+
hasColumns: A.length > 0,
|
|
5108
5108
|
orderedColumns: ge.orderedColumns,
|
|
5109
5109
|
allVisible: ge.allVisible,
|
|
5110
5110
|
onToggleVisibility: ge.toggleVisibility,
|
|
@@ -5165,10 +5165,10 @@ const Fl = 240, pi = ({
|
|
|
5165
5165
|
searchKey: c
|
|
5166
5166
|
}), { searchParams: v } = rt(), W = v.toString();
|
|
5167
5167
|
return ve(() => {
|
|
5168
|
-
const
|
|
5169
|
-
|
|
5168
|
+
const A = {}, D = {}, k = In(v.get(i), s), I = In(v.get(l), a);
|
|
5169
|
+
A[(u == null ? void 0 : u.page) ?? "page"] = k, A[(u == null ? void 0 : u.perPage) ?? "perPage"] = I;
|
|
5170
5170
|
const B = qr(c, v, n) || "";
|
|
5171
|
-
B && (
|
|
5171
|
+
B && (A[(u == null ? void 0 : u.search) ?? "search"] = B);
|
|
5172
5172
|
let w = !1;
|
|
5173
5173
|
for (const R of p) {
|
|
5174
5174
|
const z = g[R];
|
|
@@ -5179,10 +5179,10 @@ const Fl = 240, pi = ({
|
|
|
5179
5179
|
if (_ == null || Array.isArray(_) && _.length === 0)
|
|
5180
5180
|
continue;
|
|
5181
5181
|
const P = (u == null ? void 0 : u[R]) ?? R;
|
|
5182
|
-
|
|
5182
|
+
A[P] = _, w = !0;
|
|
5183
5183
|
}
|
|
5184
5184
|
return {
|
|
5185
|
-
params:
|
|
5185
|
+
params: A,
|
|
5186
5186
|
raw: D,
|
|
5187
5187
|
hasActiveFilter: b || !!B || w
|
|
5188
5188
|
};
|
|
@@ -5218,23 +5218,23 @@ const Fl = 240, pi = ({
|
|
|
5218
5218
|
activeFilterKey: n,
|
|
5219
5219
|
pageKey: o,
|
|
5220
5220
|
searchKey: i
|
|
5221
|
-
}), p = (F,
|
|
5221
|
+
}), p = (F, A) => {
|
|
5222
5222
|
var k;
|
|
5223
5223
|
const D = F.options;
|
|
5224
|
-
return ((k = D == null ? void 0 : D.find((I) => I.value ===
|
|
5224
|
+
return ((k = D == null ? void 0 : D.find((I) => I.value === A)) == null ? void 0 : k.label) ?? A;
|
|
5225
5225
|
}, g = G(
|
|
5226
5226
|
(F) => {
|
|
5227
|
-
const
|
|
5228
|
-
if (!
|
|
5229
|
-
const D = c(
|
|
5227
|
+
const A = l[F];
|
|
5228
|
+
if (!A) return [];
|
|
5229
|
+
const D = c(A);
|
|
5230
5230
|
return Array.isArray(D) ? D.map((k) => String(k.value)) : [];
|
|
5231
5231
|
},
|
|
5232
5232
|
[l, c]
|
|
5233
5233
|
), b = G(
|
|
5234
|
-
(F,
|
|
5234
|
+
(F, A) => {
|
|
5235
5235
|
const D = l[F];
|
|
5236
5236
|
if (!D || !Il.includes(D.type)) return;
|
|
5237
|
-
const k = Array.isArray(
|
|
5237
|
+
const k = Array.isArray(A) ? A : [A];
|
|
5238
5238
|
if (k.length === 0) {
|
|
5239
5239
|
a(F);
|
|
5240
5240
|
return;
|
|
@@ -5246,13 +5246,13 @@ const Fl = 240, pi = ({
|
|
|
5246
5246
|
},
|
|
5247
5247
|
[l, s, a]
|
|
5248
5248
|
), S = G(
|
|
5249
|
-
(F,
|
|
5249
|
+
(F, A) => {
|
|
5250
5250
|
const D = g(F);
|
|
5251
|
-
b(F, D.includes(
|
|
5251
|
+
b(F, D.includes(A) ? D.filter((k) => k !== A) : [...D, A]);
|
|
5252
5252
|
},
|
|
5253
5253
|
[g, b]
|
|
5254
5254
|
), v = G(
|
|
5255
|
-
(F,
|
|
5255
|
+
(F, A) => g(F).includes(A),
|
|
5256
5256
|
[g]
|
|
5257
5257
|
), W = G((F) => a(F), [a]);
|
|
5258
5258
|
return { set: b, toggle: S, clear: W, clearAll: u, isActive: v, values: g, hasActiveFilter: m };
|
|
@@ -5335,7 +5335,7 @@ const Fl = 240, pi = ({
|
|
|
5335
5335
|
flexDirection: c ? "row" : "column-reverse",
|
|
5336
5336
|
gap: "16px"
|
|
5337
5337
|
},
|
|
5338
|
-
children: o ? o({ filter: s }) : /* @__PURE__ */ d(
|
|
5338
|
+
children: o ? o({ filter: s }) : /* @__PURE__ */ d(ae, { children: [
|
|
5339
5339
|
/* @__PURE__ */ d(h, { style: { display: "flex", gap: "8px", flexDirection: "row", alignItems: "center", flex: 1, minWidth: 0 }, children: [
|
|
5340
5340
|
s,
|
|
5341
5341
|
n
|
|
@@ -5357,7 +5357,7 @@ const Fl = 240, pi = ({
|
|
|
5357
5357
|
N,
|
|
5358
5358
|
{
|
|
5359
5359
|
fullWidth: !c,
|
|
5360
|
-
iconLeft: m ? /* @__PURE__ */ e(
|
|
5360
|
+
iconLeft: m ? /* @__PURE__ */ e(M, { name: m }) : void 0,
|
|
5361
5361
|
onClick: g,
|
|
5362
5362
|
...p,
|
|
5363
5363
|
children: u
|
|
@@ -5435,7 +5435,7 @@ const Fl = 240, pi = ({
|
|
|
5435
5435
|
borderTop: "1px solid var(--sa-border-subtle, #0b120e24)",
|
|
5436
5436
|
flexShrink: 0
|
|
5437
5437
|
},
|
|
5438
|
-
children: i ? /* @__PURE__ */ d(
|
|
5438
|
+
children: i ? /* @__PURE__ */ d(ae, { children: [
|
|
5439
5439
|
/* @__PURE__ */ d(h, { style: { display: "flex", flexDirection: "row", gap: "8px", alignItems: "center", textWrap: "nowrap" }, children: [
|
|
5440
5440
|
/* @__PURE__ */ e(C, { children: "Rows Per Page: " }),
|
|
5441
5441
|
/* @__PURE__ */ e(
|
|
@@ -5517,7 +5517,7 @@ const Fl = 240, pi = ({
|
|
|
5517
5517
|
v.stopPropagation(), n || (W = t.onOpen) == null || W.call(t), o((F) => !F);
|
|
5518
5518
|
},
|
|
5519
5519
|
children: /* @__PURE__ */ e(
|
|
5520
|
-
|
|
5520
|
+
M,
|
|
5521
5521
|
{
|
|
5522
5522
|
name: n ? "ChevronUp" : "ChevronDown",
|
|
5523
5523
|
size: "sm",
|
|
@@ -5596,7 +5596,7 @@ const Fl = 240, pi = ({
|
|
|
5596
5596
|
{
|
|
5597
5597
|
ref: c,
|
|
5598
5598
|
placeholder: `Search ${r.toLowerCase()}...`,
|
|
5599
|
-
leftIcon: /* @__PURE__ */ e(
|
|
5599
|
+
leftIcon: /* @__PURE__ */ e(M, { name: "Search", size: "sm" }),
|
|
5600
5600
|
value: s,
|
|
5601
5601
|
onChange: (v) => a(v.target.value),
|
|
5602
5602
|
style: { fontSize: "14px" }
|
|
@@ -5628,7 +5628,7 @@ const Fl = 240, pi = ({
|
|
|
5628
5628
|
},
|
|
5629
5629
|
children: [
|
|
5630
5630
|
/* @__PURE__ */ e(
|
|
5631
|
-
|
|
5631
|
+
M,
|
|
5632
5632
|
{
|
|
5633
5633
|
name: "Loading",
|
|
5634
5634
|
size: "lg",
|
|
@@ -5709,7 +5709,7 @@ const Fl = 240, pi = ({
|
|
|
5709
5709
|
},
|
|
5710
5710
|
children: [
|
|
5711
5711
|
/* @__PURE__ */ e(
|
|
5712
|
-
|
|
5712
|
+
M,
|
|
5713
5713
|
{
|
|
5714
5714
|
name: "Search",
|
|
5715
5715
|
size: "lg",
|
|
@@ -5846,7 +5846,7 @@ const Fl = 240, pi = ({
|
|
|
5846
5846
|
customEmptyState: v,
|
|
5847
5847
|
enableColumnResize: W = !1,
|
|
5848
5848
|
defaultColumnWidths: F,
|
|
5849
|
-
onColumnWidthsChange:
|
|
5849
|
+
onColumnWidthsChange: A,
|
|
5850
5850
|
defaultMinColumnWidth: D = 60,
|
|
5851
5851
|
sort: k,
|
|
5852
5852
|
defaultSort: I,
|
|
@@ -5885,8 +5885,8 @@ const Fl = 240, pi = ({
|
|
|
5885
5885
|
$e.current.querySelectorAll("thead tr th")
|
|
5886
5886
|
), K = [];
|
|
5887
5887
|
let q = 0;
|
|
5888
|
-
O.forEach((he,
|
|
5889
|
-
K[
|
|
5888
|
+
O.forEach((he, de) => {
|
|
5889
|
+
K[de] = q, de < p && (q += he.offsetWidth);
|
|
5890
5890
|
}), Qe(K);
|
|
5891
5891
|
}, [p, t, r, J]);
|
|
5892
5892
|
const Je = (O) => {
|
|
@@ -5904,7 +5904,7 @@ const Fl = 240, pi = ({
|
|
|
5904
5904
|
if (!q) return;
|
|
5905
5905
|
const he = Math.round(q.getBoundingClientRect().width);
|
|
5906
5906
|
He.current = { colIndex: K, startX: O.clientX, startWidth: he };
|
|
5907
|
-
const
|
|
5907
|
+
const de = document.body.style.userSelect, Me = document.body.style.cursor;
|
|
5908
5908
|
document.body.style.userSelect = "none", document.body.style.cursor = "col-resize";
|
|
5909
5909
|
const Oe = (Xe) => {
|
|
5910
5910
|
var Ke;
|
|
@@ -5915,7 +5915,7 @@ const Fl = 240, pi = ({
|
|
|
5915
5915
|
(ft) => ft[Re.colIndex] === Se ? ft : { ...ft, [Re.colIndex]: Se }
|
|
5916
5916
|
);
|
|
5917
5917
|
}, lt = () => {
|
|
5918
|
-
document.removeEventListener("mousemove", Oe), document.removeEventListener("mouseup", lt), document.body.style.userSelect =
|
|
5918
|
+
document.removeEventListener("mousemove", Oe), document.removeEventListener("mouseup", lt), document.body.style.userSelect = de, document.body.style.cursor = Me, He.current = null, A && pe((Xe) => (A(Xe), Xe));
|
|
5919
5919
|
};
|
|
5920
5920
|
document.addEventListener("mousemove", Oe), document.addEventListener("mouseup", lt);
|
|
5921
5921
|
};
|
|
@@ -5930,8 +5930,8 @@ const Fl = 240, pi = ({
|
|
|
5930
5930
|
children: /* @__PURE__ */ d(tt, { children: [
|
|
5931
5931
|
t.map((O, K) => {
|
|
5932
5932
|
var Dt, bt;
|
|
5933
|
-
const q = p > 0 && K < p, he = ze[K] ?? 0,
|
|
5934
|
-
|
|
5933
|
+
const q = p > 0 && K < p, he = ze[K] ?? 0, de = Ye(O), Oe = K === t.length - 1 && T && w, lt = _(O), Xe = !!O.sortable && !!lt, Re = Xe && (Q == null ? void 0 : Q.key) === lt ? Q.direction : null, nt = O.title || ((Dt = O.accessor) == null ? void 0 : Dt.toString()) || "", Se = (bt = O.headerTooltip) != null && bt.showIcon ? /* @__PURE__ */ e(
|
|
5934
|
+
M,
|
|
5935
5935
|
{
|
|
5936
5936
|
name: "InfoCircle",
|
|
5937
5937
|
size: "xs",
|
|
@@ -6027,7 +6027,7 @@ const Fl = 240, pi = ({
|
|
|
6027
6027
|
]
|
|
6028
6028
|
}
|
|
6029
6029
|
),
|
|
6030
|
-
|
|
6030
|
+
de && /* @__PURE__ */ e(
|
|
6031
6031
|
"div",
|
|
6032
6032
|
{
|
|
6033
6033
|
onMouseDown: (xt) => ht(xt, K),
|
|
@@ -6086,19 +6086,19 @@ const Fl = 240, pi = ({
|
|
|
6086
6086
|
},
|
|
6087
6087
|
onMouseEnter: (q) => {
|
|
6088
6088
|
const he = q.currentTarget;
|
|
6089
|
-
he.style.backgroundColor = Hn, Array.from(he.querySelectorAll("td")).forEach((
|
|
6090
|
-
|
|
6089
|
+
he.style.backgroundColor = Hn, Array.from(he.querySelectorAll("td")).forEach((de) => {
|
|
6090
|
+
de.style.position === "sticky" && (de.style.backgroundColor = Hn);
|
|
6091
6091
|
});
|
|
6092
6092
|
},
|
|
6093
6093
|
onMouseLeave: (q) => {
|
|
6094
6094
|
const he = q.currentTarget;
|
|
6095
|
-
he.style.backgroundColor = "", Array.from(he.querySelectorAll("td")).forEach((
|
|
6096
|
-
|
|
6095
|
+
he.style.backgroundColor = "", Array.from(he.querySelectorAll("td")).forEach((de) => {
|
|
6096
|
+
de.style.position === "sticky" && (de.style.backgroundColor = Er);
|
|
6097
6097
|
});
|
|
6098
6098
|
},
|
|
6099
6099
|
children: [
|
|
6100
6100
|
t.map((q, he) => {
|
|
6101
|
-
const
|
|
6101
|
+
const de = q.render ? q.render(O, K, r) : we(O, q.accessor), Me = p > 0 && he < p, Oe = ze[he] ?? 0, lt = J[he] !== void 0, Xe = Me && he === p - 1;
|
|
6102
6102
|
return /* @__PURE__ */ e(
|
|
6103
6103
|
Ve,
|
|
6104
6104
|
{
|
|
@@ -6117,7 +6117,7 @@ const Fl = 240, pi = ({
|
|
|
6117
6117
|
textAlign: q.textAlign === "text-right" ? "right" : q.textAlign === "text-center" ? "center" : "left",
|
|
6118
6118
|
...ue(he, q.width)
|
|
6119
6119
|
},
|
|
6120
|
-
children: typeof
|
|
6120
|
+
children: typeof de == "string" ? /* @__PURE__ */ e(
|
|
6121
6121
|
C,
|
|
6122
6122
|
{
|
|
6123
6123
|
style: {
|
|
@@ -6126,9 +6126,9 @@ const Fl = 240, pi = ({
|
|
|
6126
6126
|
textOverflow: "ellipsis",
|
|
6127
6127
|
textAlign: q.textAlign === "text-right" ? "right" : q.textAlign === "text-center" ? "center" : "left"
|
|
6128
6128
|
},
|
|
6129
|
-
children:
|
|
6129
|
+
children: de
|
|
6130
6130
|
}
|
|
6131
|
-
) :
|
|
6131
|
+
) : de
|
|
6132
6132
|
},
|
|
6133
6133
|
`row-${K}-col-${he}`
|
|
6134
6134
|
);
|
|
@@ -6150,7 +6150,7 @@ const Fl = 240, pi = ({
|
|
|
6150
6150
|
variant: "outline",
|
|
6151
6151
|
tone: "neutral",
|
|
6152
6152
|
onClick: () => n(O.id, O),
|
|
6153
|
-
iconLeft: /* @__PURE__ */ e(
|
|
6153
|
+
iconLeft: /* @__PURE__ */ e(M, { name: "DocumentClean", size: "sm", style: { color: "var(--sa-text-subtle, #8c8f97)" } })
|
|
6154
6154
|
}
|
|
6155
6155
|
) }, "detail") : q === "update" && o && (s == null ? void 0 : s(O)) !== !1 ? /* @__PURE__ */ e(Ne, { label: "Update", position: he, children: /* @__PURE__ */ e(
|
|
6156
6156
|
N,
|
|
@@ -6159,7 +6159,7 @@ const Fl = 240, pi = ({
|
|
|
6159
6159
|
variant: "outline",
|
|
6160
6160
|
tone: "neutral",
|
|
6161
6161
|
onClick: () => o(O),
|
|
6162
|
-
iconLeft: /* @__PURE__ */ e(
|
|
6162
|
+
iconLeft: /* @__PURE__ */ e(M, { name: "Edit1", size: "sm", style: { color: "var(--sa-text-subtle, #8c8f97)" } })
|
|
6163
6163
|
}
|
|
6164
6164
|
) }, "update") : q === "delete" && i && (c == null ? void 0 : c(O)) !== !1 ? /* @__PURE__ */ e(Ne, { label: "Delete", position: he, children: /* @__PURE__ */ e(
|
|
6165
6165
|
N,
|
|
@@ -6168,7 +6168,7 @@ const Fl = 240, pi = ({
|
|
|
6168
6168
|
variant: "outline",
|
|
6169
6169
|
tone: "neutral",
|
|
6170
6170
|
onClick: () => i(O.id, O),
|
|
6171
|
-
iconLeft: /* @__PURE__ */ e(
|
|
6171
|
+
iconLeft: /* @__PURE__ */ e(M, { name: "Trash1", size: "sm", style: { color: "var(--sa-color-error-600, #c9184a)" } })
|
|
6172
6172
|
}
|
|
6173
6173
|
) }, "delete") : q === "custom" ? /* @__PURE__ */ e(Ct.Fragment, { children: b == null ? void 0 : b(O) }, "custom") : null;
|
|
6174
6174
|
}) }) }) : null
|
|
@@ -6238,7 +6238,7 @@ function Zl(t) {
|
|
|
6238
6238
|
const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)", Gl = ({
|
|
6239
6239
|
sortDir: t,
|
|
6240
6240
|
frozen: r
|
|
6241
|
-
}) => t === "asc" ? /* @__PURE__ */ e(
|
|
6241
|
+
}) => t === "asc" ? /* @__PURE__ */ e(M, { name: "ChevronSmallUp" }) : t === "desc" ? /* @__PURE__ */ e(M, { name: "ChevronSmallDown" }) : r ? /* @__PURE__ */ e(M, { name: "LockOn", size: "xs" }) : /* @__PURE__ */ e(M, { name: "Filter", size: "xs" }), Zt = ({ icon: t, label: r, active: n, danger: o, onClick: i }) => {
|
|
6242
6242
|
const l = o ? "var(--sa-text-error, #a4133c)" : "var(--sa-text-primary, #292a2e)";
|
|
6243
6243
|
return /* @__PURE__ */ d(
|
|
6244
6244
|
"button",
|
|
@@ -6265,7 +6265,7 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6265
6265
|
c.currentTarget.style.background = n ? "var(--sa-background-brand-subtlest, #e6edf6)" : "none";
|
|
6266
6266
|
},
|
|
6267
6267
|
children: [
|
|
6268
|
-
/* @__PURE__ */ e(
|
|
6268
|
+
/* @__PURE__ */ e(M, { name: t, size: "sm", style: { color: l, flexShrink: 0 } }),
|
|
6269
6269
|
/* @__PURE__ */ e(C, { as: "span", style: { color: l }, children: r })
|
|
6270
6270
|
]
|
|
6271
6271
|
}
|
|
@@ -6302,7 +6302,7 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6302
6302
|
const v = (W) => {
|
|
6303
6303
|
W(), m(!1);
|
|
6304
6304
|
};
|
|
6305
|
-
return /* @__PURE__ */ d(
|
|
6305
|
+
return /* @__PURE__ */ d(ae, { children: [
|
|
6306
6306
|
/* @__PURE__ */ e(
|
|
6307
6307
|
"button",
|
|
6308
6308
|
{
|
|
@@ -6350,7 +6350,7 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6350
6350
|
flexDirection: "column"
|
|
6351
6351
|
},
|
|
6352
6352
|
children: [
|
|
6353
|
-
r && /* @__PURE__ */ d(
|
|
6353
|
+
r && /* @__PURE__ */ d(ae, { children: [
|
|
6354
6354
|
/* @__PURE__ */ e(
|
|
6355
6355
|
Zt,
|
|
6356
6356
|
{
|
|
@@ -6480,7 +6480,7 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6480
6480
|
mobileLayout: v = "cards",
|
|
6481
6481
|
mobileBreakpoint: W = "md",
|
|
6482
6482
|
groupSeparator: F,
|
|
6483
|
-
summary:
|
|
6483
|
+
summary: A,
|
|
6484
6484
|
footer: D,
|
|
6485
6485
|
stickyFooter: k = !1,
|
|
6486
6486
|
emptyState: I,
|
|
@@ -6511,42 +6511,42 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6511
6511
|
), J = $e ? p ?? null : ze, pe = !b, He = (y) => {
|
|
6512
6512
|
b == null || b(y), $e || Qe(y);
|
|
6513
6513
|
}, { headerGroups: Je, leafColumns: ue, hasGroups: Ye } = ve(() => {
|
|
6514
|
-
var
|
|
6515
|
-
const y = new Set(De.hidden ?? []), x = (
|
|
6514
|
+
var se;
|
|
6515
|
+
const y = new Set(De.hidden ?? []), x = (ne, be) => ne.key ?? (typeof ne.accessor == "string" ? ne.accessor : `col-${be}`), L = t.map((ne, be) => {
|
|
6516
6516
|
var ot;
|
|
6517
|
-
if ((ot =
|
|
6518
|
-
const zt =
|
|
6519
|
-
return { col:
|
|
6517
|
+
if ((ot = ne.children) != null && ot.length) {
|
|
6518
|
+
const zt = ne.children.map((ct, Rt) => ({ col: ct, key: x(ct, `${be}-${Rt}`) })).filter((ct) => !y.has(ct.key));
|
|
6519
|
+
return { col: ne, key: ne.key ?? `group-${be}`, isGroup: !0, leaves: zt };
|
|
6520
6520
|
}
|
|
6521
|
-
const xe = { col:
|
|
6521
|
+
const xe = { col: ne, key: x(ne, `${be}`) };
|
|
6522
6522
|
return {
|
|
6523
|
-
col:
|
|
6523
|
+
col: ne,
|
|
6524
6524
|
key: xe.key,
|
|
6525
6525
|
isGroup: !1,
|
|
6526
6526
|
leaves: y.has(xe.key) ? [] : [xe]
|
|
6527
6527
|
};
|
|
6528
|
-
}).filter((
|
|
6529
|
-
let
|
|
6530
|
-
if (!Z && ((
|
|
6531
|
-
const
|
|
6532
|
-
|
|
6533
|
-
(be, xe) => (
|
|
6528
|
+
}).filter((ne) => ne.leaves.length > 0), Z = L.some((ne) => ne.isGroup);
|
|
6529
|
+
let ie = L.flatMap((ne) => ne.leaves);
|
|
6530
|
+
if (!Z && ((se = De.order) != null && se.length)) {
|
|
6531
|
+
const ne = new Map(De.order.map((be, xe) => [be, xe]));
|
|
6532
|
+
ie = [...ie].sort(
|
|
6533
|
+
(be, xe) => (ne.get(be.key) ?? 1 / 0) - (ne.get(xe.key) ?? 1 / 0)
|
|
6534
6534
|
);
|
|
6535
6535
|
}
|
|
6536
|
-
return { headerGroups:
|
|
6536
|
+
return { headerGroups: L, leafColumns: ie, hasGroups: Z };
|
|
6537
6537
|
}, [t, De]), ht = ve(
|
|
6538
6538
|
() => new Map(ue.map((y, x) => [y.key, x])),
|
|
6539
6539
|
[ue]
|
|
6540
6540
|
), O = !Ye && ue.some((y) => (y.col.headerColSpan ?? 1) > 1), K = ue.map((y) => y.key).join("|"), q = (y, x) => {
|
|
6541
|
-
const
|
|
6542
|
-
return
|
|
6543
|
-
}, he = (y) => y.sortable ?? (!!y.sortKey || typeof y.accessor == "string"),
|
|
6541
|
+
const L = y.sortKey ?? (typeof y.accessor == "string" ? y.accessor : void 0);
|
|
6542
|
+
return L ? x[L] : void 0;
|
|
6543
|
+
}, he = (y) => y.sortable ?? (!!y.sortKey || typeof y.accessor == "string"), de = ve(() => {
|
|
6544
6544
|
if (!pe || !J) return r;
|
|
6545
|
-
const y = ue.find((
|
|
6545
|
+
const y = ue.find((L) => L.key === J.key);
|
|
6546
6546
|
if (!y) return r;
|
|
6547
6547
|
const x = J.direction === "asc" ? 1 : -1;
|
|
6548
6548
|
return [...r].sort(
|
|
6549
|
-
(
|
|
6549
|
+
(L, Z) => Xl(q(y.col, L), q(y.col, Z)) * x
|
|
6550
6550
|
);
|
|
6551
6551
|
}, [r, pe, J, ue]), Me = !Ye && !O, Oe = !!s && Me, [lt, Xe] = qi(s ?? ""), Re = Oe ? lt : void 0, nt = oe(null), [Se, Ke] = H();
|
|
6552
6552
|
at(() => {
|
|
@@ -6569,9 +6569,9 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6569
6569
|
}, E = (y, x) => typeof y.width == "number" ? y.width : Se == null ? void 0 : Se[x], j = De.frozenKey && !Ye && !O ? ue.findIndex((y) => y.key === De.frozenKey) : -1, ee = (y) => y <= j, Ee = z ? It : 0, Be = (y) => {
|
|
6570
6570
|
const x = ft ?? Se;
|
|
6571
6571
|
if (!x) return Ee;
|
|
6572
|
-
let
|
|
6573
|
-
for (let Z = 0; Z < y; Z++)
|
|
6574
|
-
return
|
|
6572
|
+
let L = Ee;
|
|
6573
|
+
for (let Z = 0; Z < y; Z++) L += x[Z] ?? 0;
|
|
6574
|
+
return L;
|
|
6575
6575
|
};
|
|
6576
6576
|
at(() => {
|
|
6577
6577
|
const y = nt.current;
|
|
@@ -6580,18 +6580,18 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6580
6580
|
return;
|
|
6581
6581
|
}
|
|
6582
6582
|
let x = 0;
|
|
6583
|
-
const
|
|
6583
|
+
const L = () => {
|
|
6584
6584
|
x = 0;
|
|
6585
|
-
const
|
|
6586
|
-
(
|
|
6585
|
+
const ie = y.querySelectorAll("th.sa-tl-leaf"), se = Array.from(ie).map(
|
|
6586
|
+
(ne) => ne.getBoundingClientRect().width
|
|
6587
6587
|
);
|
|
6588
6588
|
Dt(
|
|
6589
|
-
(
|
|
6589
|
+
(ne) => ne && ne.length === se.length && ne.every((be, xe) => Math.abs(be - se[xe]) < 0.5) ? ne : se
|
|
6590
6590
|
);
|
|
6591
6591
|
}, Z = new ResizeObserver(() => {
|
|
6592
|
-
x || (x = requestAnimationFrame(
|
|
6592
|
+
x || (x = requestAnimationFrame(L));
|
|
6593
6593
|
});
|
|
6594
|
-
return Z.observe(y), y.querySelectorAll("th.sa-tl-leaf").forEach((
|
|
6594
|
+
return Z.observe(y), y.querySelectorAll("th.sa-tl-leaf").forEach((ie) => Z.observe(ie)), L(), () => {
|
|
6595
6595
|
x && cancelAnimationFrame(x), Z.disconnect();
|
|
6596
6596
|
};
|
|
6597
6597
|
}, [K, j, z, Se, Re]);
|
|
@@ -6621,28 +6621,28 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6621
6621
|
}, [z, !n]);
|
|
6622
6622
|
const tn = (y) => {
|
|
6623
6623
|
if (Pe || Ci(y), _) {
|
|
6624
|
-
const x =
|
|
6624
|
+
const x = de.filter((L, Z) => y.has(Ae(L, Z)));
|
|
6625
6625
|
_(Array.from(y), x);
|
|
6626
6626
|
}
|
|
6627
6627
|
}, lr = (y, x) => z && (P ? P(y, x) : !0), cr = (y) => {
|
|
6628
6628
|
const x = new Set(gt);
|
|
6629
6629
|
x.has(y) ? x.delete(y) : x.add(y), tn(x);
|
|
6630
6630
|
}, Ft = ve(
|
|
6631
|
-
() => z ?
|
|
6631
|
+
() => z ? de.map((y, x) => ({ row: y, i: x, key: Ae(y, x) })).filter(
|
|
6632
6632
|
({ row: y, i: x }) => P ? P(y, x) : !0
|
|
6633
6633
|
).map(({ key: y }) => y) : [],
|
|
6634
6634
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
6635
|
-
[z,
|
|
6635
|
+
[z, de, P, n]
|
|
6636
6636
|
), rn = Ft.filter((y) => gt.has(y)), sr = Ft.length > 0 && rn.length === Ft.length, nn = rn.length > 0 && !sr, wi = () => {
|
|
6637
6637
|
const y = new Set(gt);
|
|
6638
6638
|
sr ? Ft.forEach((x) => y.delete(x)) : Ft.forEach((x) => y.add(x)), tn(y);
|
|
6639
|
-
}, ar = (y, x,
|
|
6639
|
+
}, ar = (y, x, L) => y.render ? y.render(x, L, de) : Yl(x, y.accessor), dr = ue.length + (z ? 1 : 0) + ($ ? 1 : 0), on = ["80%", "55%", "70%", "45%", "90%", "60%"], Di = (y, x) => on[(y * 7 + x * 3) % on.length], ki = (y, x) => /* @__PURE__ */ e(mt, { height: 14, width: Di(y, x), borderRadius: "rounded-sm" }), Si = Array.from({ length: w }, (y, x) => /* @__PURE__ */ d(tt, { children: [
|
|
6640
6640
|
z && /* @__PURE__ */ e(Ve, { style: { width: It, padding: 0 }, children: /* @__PURE__ */ e("div", { style: { display: "flex", justifyContent: "center" }, children: /* @__PURE__ */ e(mt, { height: 14, width: 14, borderRadius: "rounded-sm" }) }) }),
|
|
6641
|
-
ue.map(({ col:
|
|
6641
|
+
ue.map(({ col: L, key: Z }, ie) => /* @__PURE__ */ e(
|
|
6642
6642
|
Ve,
|
|
6643
6643
|
{
|
|
6644
|
-
style: { textAlign: Ht(
|
|
6645
|
-
children: ki(x,
|
|
6644
|
+
style: { textAlign: Ht(L.align) },
|
|
6645
|
+
children: ki(x, ie)
|
|
6646
6646
|
},
|
|
6647
6647
|
`sa-tl-sk-${x}-${Z}`
|
|
6648
6648
|
)),
|
|
@@ -6656,8 +6656,8 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6656
6656
|
...De,
|
|
6657
6657
|
frozenKey: De.frozenKey === y ? void 0 : y
|
|
6658
6658
|
}), Nt = (y) => (R ?? []).filter((x) => {
|
|
6659
|
-
var
|
|
6660
|
-
return !((
|
|
6659
|
+
var L;
|
|
6660
|
+
return !((L = x.hidden) != null && L.call(x, y));
|
|
6661
6661
|
}), ln = {
|
|
6662
6662
|
position: "absolute",
|
|
6663
6663
|
right: 0,
|
|
@@ -6669,73 +6669,73 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6669
6669
|
paddingRight: 16,
|
|
6670
6670
|
paddingLeft: 40,
|
|
6671
6671
|
background: "linear-gradient(to right, transparent, var(--sa-background-primary-inverse, #f8f8f8) 40px)"
|
|
6672
|
-
}, $t = (y, x,
|
|
6672
|
+
}, $t = (y, x, L, Z) => {
|
|
6673
6673
|
var ot;
|
|
6674
|
-
const
|
|
6674
|
+
const ie = (ot = y.disabled) == null ? void 0 : ot.call(y, x), se = (Z == null ? void 0 : Z.showLabel) ?? y.showLabel, ne = (Z == null ? void 0 : Z.size) ?? "xs", be = /* @__PURE__ */ e(
|
|
6675
6675
|
N,
|
|
6676
6676
|
{
|
|
6677
|
-
size:
|
|
6677
|
+
size: ne,
|
|
6678
6678
|
variant: y.variant ?? "tertiary",
|
|
6679
6679
|
tone: y.tone ?? "neutral",
|
|
6680
|
-
disabled:
|
|
6681
|
-
onClick: () => y.onClick(x,
|
|
6682
|
-
iconLeft: y.icon ? /* @__PURE__ */ e(
|
|
6683
|
-
children:
|
|
6680
|
+
disabled: ie,
|
|
6681
|
+
onClick: () => y.onClick(x, L),
|
|
6682
|
+
iconLeft: y.icon ? /* @__PURE__ */ e(M, { name: y.icon, size: "sm" }) : void 0,
|
|
6683
|
+
children: se && y.label
|
|
6684
6684
|
}
|
|
6685
6685
|
), xe = y.tooltip;
|
|
6686
6686
|
return xe ? /* @__PURE__ */ e(Ne, { label: xe, position: "top-end", children: be }) : be;
|
|
6687
6687
|
}, Li = (y, x) => {
|
|
6688
|
-
const
|
|
6689
|
-
if (!
|
|
6690
|
-
if (
|
|
6691
|
-
const
|
|
6688
|
+
const L = Nt(y);
|
|
6689
|
+
if (!L.length) return null;
|
|
6690
|
+
if (L.length > 5) {
|
|
6691
|
+
const ie = Ae(y, x), se = (T == null ? void 0 : T.rowKey) === ie;
|
|
6692
6692
|
return /* @__PURE__ */ e(
|
|
6693
6693
|
"div",
|
|
6694
6694
|
{
|
|
6695
6695
|
className: "sa-tl-row-actions",
|
|
6696
6696
|
style: ln,
|
|
6697
|
-
onClick: (
|
|
6697
|
+
onClick: (ne) => ne.stopPropagation(),
|
|
6698
6698
|
children: /* @__PURE__ */ e(Ne, { label: "Aksi lainnya", position: "top", children: /* @__PURE__ */ e(
|
|
6699
6699
|
N,
|
|
6700
6700
|
{
|
|
6701
6701
|
size: "xs",
|
|
6702
6702
|
variant: "tertiary",
|
|
6703
|
-
onClick: (
|
|
6704
|
-
const be =
|
|
6705
|
-
V(
|
|
6706
|
-
rowKey:
|
|
6703
|
+
onClick: (ne) => {
|
|
6704
|
+
const be = ne.currentTarget.getBoundingClientRect();
|
|
6705
|
+
V(se ? null : {
|
|
6706
|
+
rowKey: ie,
|
|
6707
6707
|
top: be.bottom + 4,
|
|
6708
6708
|
right: window.innerWidth - be.right
|
|
6709
6709
|
});
|
|
6710
6710
|
},
|
|
6711
|
-
children: /* @__PURE__ */ e(
|
|
6711
|
+
children: /* @__PURE__ */ e(M, { name: "MenuVertical", size: "sm" })
|
|
6712
6712
|
}
|
|
6713
6713
|
) })
|
|
6714
6714
|
}
|
|
6715
6715
|
);
|
|
6716
6716
|
}
|
|
6717
|
-
return /* @__PURE__ */ e("div", { className: "sa-tl-row-actions", style: ln, children:
|
|
6717
|
+
return /* @__PURE__ */ e("div", { className: "sa-tl-row-actions", style: ln, children: L.map((ie) => /* @__PURE__ */ e(Ct.Fragment, { children: $t(ie, y, x) }, ie.key)) });
|
|
6718
6718
|
}, Mi = (y, x) => {
|
|
6719
|
-
const
|
|
6720
|
-
return
|
|
6719
|
+
const L = Nt(y);
|
|
6720
|
+
return L.length ? /* @__PURE__ */ e("div", { style: { display: "flex", gap: 6, flexWrap: "wrap", paddingTop: 8, marginTop: 8, borderTop: Bt }, children: L.map((Z) => /* @__PURE__ */ e(Ct.Fragment, { children: $t(Z, y, x, { showLabel: !0, size: "sm" }) }, Z.key)) }) : null;
|
|
6721
6721
|
}, Ai = (y, x) => {
|
|
6722
|
-
const
|
|
6723
|
-
return
|
|
6722
|
+
const L = Nt(y);
|
|
6723
|
+
return L.length ? /* @__PURE__ */ e("div", { style: { display: "flex", gap: 4, paddingRight: 8, flexShrink: 0 }, children: L.map((Z) => /* @__PURE__ */ e(Ct.Fragment, { children: $t(Z, y, x, { showLabel: !1 }) }, Z.key)) }) : null;
|
|
6724
6724
|
}, ur = (y, x) => {
|
|
6725
|
-
const { col:
|
|
6725
|
+
const { col: L, key: Z } = y, ie = ht.get(Z) ?? 0, se = ee(ie), ne = se && ie === j, be = (J == null ? void 0 : J.key) === Z ? J.direction : null, xe = m && !L.disableMenu ? /* @__PURE__ */ e(
|
|
6726
6726
|
ql,
|
|
6727
6727
|
{
|
|
6728
|
-
active: !!be ||
|
|
6729
|
-
canSort: he(
|
|
6730
|
-
canHide: !
|
|
6728
|
+
active: !!be || se,
|
|
6729
|
+
canSort: he(L),
|
|
6730
|
+
canHide: !L.locked,
|
|
6731
6731
|
sortDir: be,
|
|
6732
|
-
frozen:
|
|
6732
|
+
frozen: se,
|
|
6733
6733
|
onSort: (Rt) => He({ key: Z, direction: Rt }),
|
|
6734
6734
|
onClearSort: () => He(null),
|
|
6735
6735
|
onToggleFreeze: () => Fi(Z),
|
|
6736
|
-
onHide: () => Ei(Z,
|
|
6736
|
+
onHide: () => Ei(Z, L.locked)
|
|
6737
6737
|
}
|
|
6738
|
-
) : null, ot =
|
|
6738
|
+
) : null, ot = L.align === "right", zt = L.align === "right" ? "flex-end" : L.align === "center" ? "center" : "flex-start", ct = /* @__PURE__ */ d(
|
|
6739
6739
|
"span",
|
|
6740
6740
|
{
|
|
6741
6741
|
style: {
|
|
@@ -6748,29 +6748,30 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6748
6748
|
overflow: "hidden"
|
|
6749
6749
|
},
|
|
6750
6750
|
children: [
|
|
6751
|
-
|
|
6752
|
-
/* @__PURE__ */ e("span", { style: Gt, children:
|
|
6751
|
+
L.icon && /* @__PURE__ */ e(M, { name: L.icon, size: "sm", style: { flexShrink: 0 } }),
|
|
6752
|
+
/* @__PURE__ */ e("span", { style: Gt, children: L.title })
|
|
6753
6753
|
]
|
|
6754
6754
|
}
|
|
6755
6755
|
);
|
|
6756
6756
|
return /* @__PURE__ */ e(
|
|
6757
6757
|
St,
|
|
6758
6758
|
{
|
|
6759
|
-
className: `sa-tl-leaf${
|
|
6759
|
+
className: `sa-tl-leaf${se ? " sa-tl-frozen" : ""}`,
|
|
6760
6760
|
rowSpan: x == null ? void 0 : x.rowSpan,
|
|
6761
6761
|
colSpan: x == null ? void 0 : x.colSpan,
|
|
6762
|
-
minWidth:
|
|
6763
|
-
|
|
6764
|
-
|
|
6762
|
+
minWidth: L.minWidth,
|
|
6763
|
+
numeric: L.numeric,
|
|
6764
|
+
resizable: Me ? L.resizable : !1,
|
|
6765
|
+
defaultWidth: E(L, ie),
|
|
6765
6766
|
style: {
|
|
6766
|
-
textAlign: Ht(
|
|
6767
|
-
width: Et(
|
|
6767
|
+
textAlign: Ht(L.align),
|
|
6768
|
+
width: Et(L, ie),
|
|
6768
6769
|
position: "sticky",
|
|
6769
6770
|
top: (x == null ? void 0 : x.top) ?? 0,
|
|
6770
|
-
left:
|
|
6771
|
-
zIndex:
|
|
6771
|
+
left: se ? Be(ie) : void 0,
|
|
6772
|
+
zIndex: se ? 3 : 2,
|
|
6772
6773
|
backgroundColor: Lt,
|
|
6773
|
-
boxShadow:
|
|
6774
|
+
boxShadow: ne ? Vn : void 0
|
|
6774
6775
|
},
|
|
6775
6776
|
children: /* @__PURE__ */ e(
|
|
6776
6777
|
"div",
|
|
@@ -6781,10 +6782,10 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6781
6782
|
gap: 6,
|
|
6782
6783
|
width: "100%"
|
|
6783
6784
|
},
|
|
6784
|
-
children: ot ? /* @__PURE__ */ d(
|
|
6785
|
+
children: ot ? /* @__PURE__ */ d(ae, { children: [
|
|
6785
6786
|
xe,
|
|
6786
6787
|
ct
|
|
6787
|
-
] }) : /* @__PURE__ */ d(
|
|
6788
|
+
] }) : /* @__PURE__ */ d(ae, { children: [
|
|
6788
6789
|
ct,
|
|
6789
6790
|
xe
|
|
6790
6791
|
] })
|
|
@@ -6796,8 +6797,8 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6796
6797
|
}, Wi = () => {
|
|
6797
6798
|
const y = [];
|
|
6798
6799
|
for (let x = 0; x < ue.length; ) {
|
|
6799
|
-
const
|
|
6800
|
-
y.push(ur(
|
|
6800
|
+
const L = ue[x], Z = L.col.headerColSpan ?? 1, ie = Math.max(1, Math.min(Z, ue.length - x));
|
|
6801
|
+
y.push(ur(L, ie > 1 ? { colSpan: ie } : void 0)), x += ie;
|
|
6801
6802
|
}
|
|
6802
6803
|
return y;
|
|
6803
6804
|
}, cn = (y) => /* @__PURE__ */ e(
|
|
@@ -6838,7 +6839,7 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6838
6839
|
)
|
|
6839
6840
|
},
|
|
6840
6841
|
"th-select"
|
|
6841
|
-
), zi = (y, x,
|
|
6842
|
+
), zi = (y, x, L) => {
|
|
6842
6843
|
const Z = Ae(y, x);
|
|
6843
6844
|
return /* @__PURE__ */ e(
|
|
6844
6845
|
Ve,
|
|
@@ -6851,7 +6852,7 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6851
6852
|
left: 0,
|
|
6852
6853
|
zIndex: 2,
|
|
6853
6854
|
// di atas frozen body cells (1)
|
|
6854
|
-
...
|
|
6855
|
+
...L ? { "--sa-tl-bg": L } : {}
|
|
6855
6856
|
},
|
|
6856
6857
|
children: lr(y, x) && /* @__PURE__ */ e(
|
|
6857
6858
|
"div",
|
|
@@ -6861,7 +6862,7 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6861
6862
|
alignItems: "center",
|
|
6862
6863
|
justifyContent: "center"
|
|
6863
6864
|
},
|
|
6864
|
-
onClick: (
|
|
6865
|
+
onClick: (ie) => ie.stopPropagation(),
|
|
6865
6866
|
children: /* @__PURE__ */ e(
|
|
6866
6867
|
vt,
|
|
6867
6868
|
{
|
|
@@ -6877,32 +6878,16 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6877
6878
|
`tl-select-${x}`
|
|
6878
6879
|
);
|
|
6879
6880
|
}, hr = ue.filter((y) => !y.col.hideOnMobile), fr = hr.find((y) => y.col.primary) ?? hr[0], Ri = hr.filter((y) => y !== fr), Bi = (y) => Ce((x) => {
|
|
6880
|
-
const
|
|
6881
|
-
return
|
|
6882
|
-
}), sn = (y, x) => Ri.map(({ col:
|
|
6883
|
-
const
|
|
6884
|
-
|
|
6885
|
-
|
|
6886
|
-
|
|
6887
|
-
|
|
6888
|
-
|
|
6889
|
-
|
|
6890
|
-
textAlign: "right"
|
|
6891
|
-
},
|
|
6892
|
-
children: ne
|
|
6893
|
-
}
|
|
6894
|
-
) : /* @__PURE__ */ e(
|
|
6895
|
-
"div",
|
|
6896
|
-
{
|
|
6897
|
-
style: {
|
|
6898
|
-
minWidth: 0,
|
|
6899
|
-
overflow: "hidden",
|
|
6900
|
-
textOverflow: "ellipsis",
|
|
6901
|
-
textAlign: "right"
|
|
6902
|
-
},
|
|
6903
|
-
children: ne
|
|
6904
|
-
}
|
|
6905
|
-
);
|
|
6881
|
+
const L = new Set(x);
|
|
6882
|
+
return L.has(y) ? L.delete(y) : L.add(y), L;
|
|
6883
|
+
}), sn = (y, x) => Ri.map(({ col: L, key: Z }) => {
|
|
6884
|
+
const ie = ar(L, y, x), se = {
|
|
6885
|
+
minWidth: 0,
|
|
6886
|
+
overflow: "hidden",
|
|
6887
|
+
textOverflow: "ellipsis",
|
|
6888
|
+
textAlign: "right",
|
|
6889
|
+
...L.numeric ? { fontVariantNumeric: "tabular-nums" } : {}
|
|
6890
|
+
}, ne = typeof ie == "string" || typeof ie == "number" ? /* @__PURE__ */ e(C, { style: se, children: ie }) : /* @__PURE__ */ e("div", { style: se, children: ie });
|
|
6906
6891
|
return /* @__PURE__ */ d(
|
|
6907
6892
|
"div",
|
|
6908
6893
|
{
|
|
@@ -6913,23 +6898,23 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6913
6898
|
alignItems: "baseline"
|
|
6914
6899
|
},
|
|
6915
6900
|
children: [
|
|
6916
|
-
typeof
|
|
6901
|
+
typeof L.title == "string" ? /* @__PURE__ */ e(
|
|
6917
6902
|
C,
|
|
6918
6903
|
{
|
|
6919
6904
|
color: "subtle",
|
|
6920
6905
|
fontWeight: "medium",
|
|
6921
6906
|
style: { color: Ul, flexShrink: 0 },
|
|
6922
|
-
children:
|
|
6907
|
+
children: L.title
|
|
6923
6908
|
}
|
|
6924
|
-
) : /* @__PURE__ */ e("div", { style: { flexShrink: 0 }, children:
|
|
6925
|
-
|
|
6909
|
+
) : /* @__PURE__ */ e("div", { style: { flexShrink: 0 }, children: L.title }),
|
|
6910
|
+
ne
|
|
6926
6911
|
]
|
|
6927
6912
|
},
|
|
6928
6913
|
Z
|
|
6929
6914
|
);
|
|
6930
6915
|
}), mr = (y, x) => {
|
|
6931
|
-
const
|
|
6932
|
-
return typeof
|
|
6916
|
+
const L = fr ? ar(fr.col, y, x) : null;
|
|
6917
|
+
return typeof L == "string" || typeof L == "number" ? /* @__PURE__ */ e(C, { as: "span", style: Gt, children: L }) : /* @__PURE__ */ e("span", { style: Gt, children: L });
|
|
6933
6918
|
}, Ii = /* @__PURE__ */ e(
|
|
6934
6919
|
h,
|
|
6935
6920
|
{
|
|
@@ -6967,12 +6952,12 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6967
6952
|
},
|
|
6968
6953
|
children: I == null ? void 0 : I.content
|
|
6969
6954
|
}
|
|
6970
|
-
), Hi = B ? Ii :
|
|
6971
|
-
const
|
|
6955
|
+
), Hi = B ? Ii : de.length === 0 ? an : v === "expand" ? /* @__PURE__ */ e(h, { style: { display: "flex", flexDirection: "column" }, children: de.map((y, x) => {
|
|
6956
|
+
const L = Ae(y, x), Z = ce.has(L), se = z && gt.has(L) ? Lr : qt(o == null ? void 0 : o(y, x));
|
|
6972
6957
|
return /* @__PURE__ */ d(
|
|
6973
6958
|
"div",
|
|
6974
6959
|
{
|
|
6975
|
-
style: { borderBottom: Bt, backgroundColor:
|
|
6960
|
+
style: { borderBottom: Bt, backgroundColor: se },
|
|
6976
6961
|
children: [
|
|
6977
6962
|
/* @__PURE__ */ d("div", { style: { display: "flex", alignItems: "center" }, children: [
|
|
6978
6963
|
lr(y, x) && // Sibling dari tombol expand — tap checkbox tidak memuai baris.
|
|
@@ -6990,8 +6975,8 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
6990
6975
|
vt,
|
|
6991
6976
|
{
|
|
6992
6977
|
size: "sm",
|
|
6993
|
-
checked: gt.has(
|
|
6994
|
-
onChange: () => cr(
|
|
6978
|
+
checked: gt.has(L),
|
|
6979
|
+
onChange: () => cr(L),
|
|
6995
6980
|
"aria-label": "Pilih baris"
|
|
6996
6981
|
}
|
|
6997
6982
|
)
|
|
@@ -7001,7 +6986,7 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
7001
6986
|
"button",
|
|
7002
6987
|
{
|
|
7003
6988
|
type: "button",
|
|
7004
|
-
onClick: () => Bi(
|
|
6989
|
+
onClick: () => Bi(L),
|
|
7005
6990
|
style: {
|
|
7006
6991
|
flex: 1,
|
|
7007
6992
|
minWidth: 0,
|
|
@@ -7020,7 +7005,7 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
7020
7005
|
children: [
|
|
7021
7006
|
mr(y, x),
|
|
7022
7007
|
/* @__PURE__ */ e(
|
|
7023
|
-
|
|
7008
|
+
M,
|
|
7024
7009
|
{
|
|
7025
7010
|
name: Z ? "ChevronUp" : "ChevronDown",
|
|
7026
7011
|
size: "sm",
|
|
@@ -7046,14 +7031,14 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
7046
7031
|
)
|
|
7047
7032
|
]
|
|
7048
7033
|
},
|
|
7049
|
-
|
|
7034
|
+
L
|
|
7050
7035
|
);
|
|
7051
7036
|
}) }) : /* @__PURE__ */ e(
|
|
7052
7037
|
h,
|
|
7053
7038
|
{
|
|
7054
7039
|
style: { display: "flex", flexDirection: "column", gap: 8, padding: 8 },
|
|
7055
|
-
children:
|
|
7056
|
-
const
|
|
7040
|
+
children: de.map((y, x) => {
|
|
7041
|
+
const L = Ae(y, x), Z = z && gt.has(L);
|
|
7057
7042
|
return /* @__PURE__ */ d(
|
|
7058
7043
|
h,
|
|
7059
7044
|
{
|
|
@@ -7072,8 +7057,8 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
7072
7057
|
vt,
|
|
7073
7058
|
{
|
|
7074
7059
|
size: "sm",
|
|
7075
|
-
checked: gt.has(
|
|
7076
|
-
onChange: () => cr(
|
|
7060
|
+
checked: gt.has(L),
|
|
7061
|
+
onChange: () => cr(L),
|
|
7077
7062
|
"aria-label": "Pilih baris"
|
|
7078
7063
|
}
|
|
7079
7064
|
),
|
|
@@ -7086,17 +7071,18 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
7086
7071
|
$ && Mi(y, x)
|
|
7087
7072
|
]
|
|
7088
7073
|
},
|
|
7089
|
-
|
|
7074
|
+
L
|
|
7090
7075
|
);
|
|
7091
7076
|
})
|
|
7092
7077
|
}
|
|
7093
|
-
), Oi = l && Me && Se !== void 0, dn = c === "fixed" && !l && (Me ? Se !== void 0 : !0), Ti = dn && !Me, _t = D && D.length > 0 ? D.map((y, x) => /* @__PURE__ */ e(tt, { children: y.cells.map((
|
|
7078
|
+
), Oi = l && Me && Se !== void 0, dn = c === "fixed" && !l && (Me ? Se !== void 0 : !0), Ti = dn && !Me, _t = D && D.length > 0 ? D.map((y, x) => /* @__PURE__ */ e(tt, { children: y.cells.map((L, Z) => /* @__PURE__ */ e(
|
|
7094
7079
|
Ve,
|
|
7095
7080
|
{
|
|
7096
|
-
colSpan:
|
|
7097
|
-
rowSpan:
|
|
7098
|
-
|
|
7099
|
-
|
|
7081
|
+
colSpan: L.colSpan,
|
|
7082
|
+
rowSpan: L.rowSpan,
|
|
7083
|
+
numeric: L.numeric,
|
|
7084
|
+
style: { textAlign: Ht(L.align) },
|
|
7085
|
+
children: L.content
|
|
7100
7086
|
},
|
|
7101
7087
|
`tl-foot-${x}-${Z}`
|
|
7102
7088
|
)) }, `tl-foot-${x}`)) : null, Vi = /* @__PURE__ */ d(
|
|
@@ -7111,10 +7097,10 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
7111
7097
|
children: [
|
|
7112
7098
|
Ti && /* @__PURE__ */ d("colgroup", { children: [
|
|
7113
7099
|
z && /* @__PURE__ */ e("col", { style: { width: It } }),
|
|
7114
|
-
ue.map(({ col: y, key: x },
|
|
7100
|
+
ue.map(({ col: y, key: x }, L) => /* @__PURE__ */ e("col", { style: { width: Et(y, L) } }, `col-${x}`)),
|
|
7115
7101
|
$ && /* @__PURE__ */ e("col", { style: { width: 1 } })
|
|
7116
7102
|
] }),
|
|
7117
|
-
/* @__PURE__ */ e(Xn, { ref: nt, children: Ye ? /* @__PURE__ */ d(
|
|
7103
|
+
/* @__PURE__ */ e(Xn, { ref: nt, children: Ye ? /* @__PURE__ */ d(ae, { children: [
|
|
7118
7104
|
/* @__PURE__ */ d(tt, { children: [
|
|
7119
7105
|
z && cn({ rowSpan: 2 }),
|
|
7120
7106
|
Je.map(
|
|
@@ -7173,32 +7159,33 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
7173
7159
|
}
|
|
7174
7160
|
)
|
|
7175
7161
|
] }) }),
|
|
7176
|
-
/* @__PURE__ */ e(zr, { children: B ? Si :
|
|
7177
|
-
|
|
7178
|
-
const
|
|
7162
|
+
/* @__PURE__ */ e(zr, { children: B ? Si : de.length === 0 ? /* @__PURE__ */ e(tt, { children: /* @__PURE__ */ e(Ve, { colSpan: dr, children: an }) }) : /* @__PURE__ */ d(ae, { children: [
|
|
7163
|
+
de.map((y, x) => {
|
|
7164
|
+
const L = F == null ? void 0 : F(
|
|
7179
7165
|
y,
|
|
7180
7166
|
x,
|
|
7181
|
-
x > 0 ?
|
|
7182
|
-
),
|
|
7167
|
+
x > 0 ? de[x - 1] : void 0
|
|
7168
|
+
), ie = z && gt.has(Ae(y, x)) ? Lr : qt(o == null ? void 0 : o(y, x));
|
|
7183
7169
|
return /* @__PURE__ */ d(Ct.Fragment, { children: [
|
|
7184
|
-
|
|
7170
|
+
L != null && L !== !1 && /* @__PURE__ */ e(tt, { children: /* @__PURE__ */ e(Ve, { colSpan: dr, style: { backgroundColor: Lt }, children: L }) }),
|
|
7185
7171
|
/* @__PURE__ */ d(tt, { children: [
|
|
7186
|
-
z && zi(y, x,
|
|
7187
|
-
ue.map(({ col:
|
|
7172
|
+
z && zi(y, x, ie),
|
|
7173
|
+
ue.map(({ col: se, key: ne }, be) => {
|
|
7188
7174
|
var hn;
|
|
7189
|
-
const xe = (hn =
|
|
7175
|
+
const xe = (hn = se.cellProps) == null ? void 0 : hn.call(se, y, x, de);
|
|
7190
7176
|
if (xe != null && xe.hidden) return null;
|
|
7191
|
-
const ot = ee(be), zt = ot && be === j, ct = ar(
|
|
7177
|
+
const ot = ee(be), zt = ot && be === j, ct = ar(se, y, x), Rt = typeof se.bg == "function" ? se.bg(y, x, de) : se.bg, un = qt(Rt) ?? ie;
|
|
7192
7178
|
return /* @__PURE__ */ e(
|
|
7193
7179
|
Ve,
|
|
7194
7180
|
{
|
|
7195
7181
|
className: ot ? "sa-tl-frozen" : void 0,
|
|
7196
7182
|
colSpan: xe == null ? void 0 : xe.colSpan,
|
|
7197
7183
|
rowSpan: xe == null ? void 0 : xe.rowSpan,
|
|
7184
|
+
numeric: se.numeric,
|
|
7198
7185
|
style: {
|
|
7199
|
-
textAlign: Ht(
|
|
7200
|
-
width: Et(
|
|
7201
|
-
minWidth:
|
|
7186
|
+
textAlign: Ht(se.align),
|
|
7187
|
+
width: Et(se, be),
|
|
7188
|
+
minWidth: se.minWidth,
|
|
7202
7189
|
position: ot ? "sticky" : void 0,
|
|
7203
7190
|
left: ot ? Be(be) : void 0,
|
|
7204
7191
|
zIndex: ot ? 1 : void 0,
|
|
@@ -7212,13 +7199,13 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
7212
7199
|
whiteSpace: "nowrap",
|
|
7213
7200
|
overflow: "hidden",
|
|
7214
7201
|
textOverflow: "ellipsis",
|
|
7215
|
-
textAlign: Ht(
|
|
7202
|
+
textAlign: Ht(se.align)
|
|
7216
7203
|
},
|
|
7217
7204
|
children: ct
|
|
7218
7205
|
}
|
|
7219
7206
|
) : ct
|
|
7220
7207
|
},
|
|
7221
|
-
`tl-cell-${x}-${
|
|
7208
|
+
`tl-cell-${x}-${ne}`
|
|
7222
7209
|
);
|
|
7223
7210
|
}),
|
|
7224
7211
|
$ && /* @__PURE__ */ e(
|
|
@@ -7239,13 +7226,13 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
7239
7226
|
] })
|
|
7240
7227
|
] }, Ae(y, x));
|
|
7241
7228
|
}),
|
|
7242
|
-
|
|
7229
|
+
A != null && /* @__PURE__ */ e(tt, { children: /* @__PURE__ */ e(Ve, { colSpan: dr, children: A }) })
|
|
7243
7230
|
] }) }),
|
|
7244
7231
|
_t && /* @__PURE__ */ e(Ui, { className: k ? "sa-tl-sticky-foot" : void 0, children: _t })
|
|
7245
7232
|
]
|
|
7246
7233
|
}
|
|
7247
|
-
), gr = T ?
|
|
7248
|
-
return /* @__PURE__ */ d(
|
|
7234
|
+
), gr = T ? de.findIndex((y, x) => Ae(y, x) === T.rowKey) : -1, pr = gr >= 0 ? de[gr] : null;
|
|
7235
|
+
return /* @__PURE__ */ d(ae, { children: [
|
|
7249
7236
|
/* @__PURE__ */ e(
|
|
7250
7237
|
h,
|
|
7251
7238
|
{
|
|
@@ -7255,9 +7242,9 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
7255
7242
|
overflow: "auto",
|
|
7256
7243
|
height: S ?? Te
|
|
7257
7244
|
},
|
|
7258
|
-
children: re ? /* @__PURE__ */ d(
|
|
7245
|
+
children: re ? /* @__PURE__ */ d(ae, { children: [
|
|
7259
7246
|
Hi,
|
|
7260
|
-
_t && !B &&
|
|
7247
|
+
_t && !B && de.length > 0 && /* @__PURE__ */ e(h, { style: { borderTop: Bt }, children: /* @__PURE__ */ e(Jt, { fullWidth: !0, size: i, className: "sa-table-layout", children: /* @__PURE__ */ e(zr, { children: _t }) }) })
|
|
7261
7248
|
] }) : Vi
|
|
7262
7249
|
}
|
|
7263
7250
|
),
|
|
@@ -7306,14 +7293,14 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
7306
7293
|
const v = (l == null ? void 0 : l.sortBy) ?? "sortBy", W = (l == null ? void 0 : l.sortOrder) ?? "sortOrder", F = ve(() => S ? {
|
|
7307
7294
|
[v]: S.key,
|
|
7308
7295
|
[W]: S.direction
|
|
7309
|
-
} : {}, [S, v, W]),
|
|
7296
|
+
} : {}, [S, v, W]), A = G(
|
|
7310
7297
|
(D) => {
|
|
7311
7298
|
const k = { ...m };
|
|
7312
7299
|
D ? (k[r] = D.key, k[n] = D.direction) : (delete k[r], delete k[n]), delete k[o], u(k);
|
|
7313
7300
|
},
|
|
7314
7301
|
[m, r, n, o, u]
|
|
7315
7302
|
);
|
|
7316
|
-
return { sort: S, setSort:
|
|
7303
|
+
return { sort: S, setSort: A, params: F };
|
|
7317
7304
|
}, Qr = ({
|
|
7318
7305
|
of: t,
|
|
7319
7306
|
render: r
|
|
@@ -7323,7 +7310,7 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
7323
7310
|
children: n,
|
|
7324
7311
|
loading: o,
|
|
7325
7312
|
isLoading: i
|
|
7326
|
-
}) => /* @__PURE__ */ e(
|
|
7313
|
+
}) => /* @__PURE__ */ e(ae, { children: i ? o : t ? n : r }), ye = (t) => /* @__PURE__ */ e(
|
|
7327
7314
|
C,
|
|
7328
7315
|
{
|
|
7329
7316
|
...t,
|
|
@@ -7381,7 +7368,7 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
7381
7368
|
arrowPosition: (u = i.tooltip) == null ? void 0 : u.arrowPosition,
|
|
7382
7369
|
...i.tooltip,
|
|
7383
7370
|
children: /* @__PURE__ */ e(
|
|
7384
|
-
|
|
7371
|
+
M,
|
|
7385
7372
|
{
|
|
7386
7373
|
name: "InfoCircle",
|
|
7387
7374
|
size: t === "lg" ? "sm" : "xs",
|
|
@@ -7466,7 +7453,7 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
7466
7453
|
arrowPosition: (u = i.tooltip) == null ? void 0 : u.arrowPosition,
|
|
7467
7454
|
...i.tooltip,
|
|
7468
7455
|
children: /* @__PURE__ */ e(
|
|
7469
|
-
|
|
7456
|
+
M,
|
|
7470
7457
|
{
|
|
7471
7458
|
name: "InfoCircle",
|
|
7472
7459
|
size: t === "lg" ? "sm" : "xs",
|
|
@@ -7540,7 +7527,7 @@ const Ps = Zl(jl), Tn = 200, Fr = "1px solid var(--sa-border-subtle, #0b120e24)"
|
|
|
7540
7527
|
},
|
|
7541
7528
|
children: [
|
|
7542
7529
|
/* @__PURE__ */ e(
|
|
7543
|
-
|
|
7530
|
+
M,
|
|
7544
7531
|
{
|
|
7545
7532
|
name: "Upload",
|
|
7546
7533
|
size: "lg",
|
|
@@ -7771,7 +7758,7 @@ const dc = (t) => {
|
|
|
7771
7758
|
children: [
|
|
7772
7759
|
/* @__PURE__ */ d(fe, { direction: "row", align: "center", gap: "sm", style: { flex: 1, minWidth: 0 }, children: [
|
|
7773
7760
|
/* @__PURE__ */ e(
|
|
7774
|
-
|
|
7761
|
+
M,
|
|
7775
7762
|
{
|
|
7776
7763
|
name: "DocumentFilled",
|
|
7777
7764
|
size: "lg",
|
|
@@ -7798,11 +7785,11 @@ const dc = (t) => {
|
|
|
7798
7785
|
),
|
|
7799
7786
|
t.defaultFile ? (t.defaultFile.size || t.defaultFile.date) && /* @__PURE__ */ d(fe, { direction: "row", gap: "xs", align: "center", children: [
|
|
7800
7787
|
t.defaultFile.size && /* @__PURE__ */ e(C, { fontSize: "sm", fontWeight: "medium", children: t.defaultFile.size }),
|
|
7801
|
-
t.defaultFile.size && t.defaultFile.date && /* @__PURE__ */ e(
|
|
7788
|
+
t.defaultFile.size && t.defaultFile.date && /* @__PURE__ */ e(M, { name: "Dot", size: "xs" }),
|
|
7802
7789
|
t.defaultFile.date && /* @__PURE__ */ e(C, { fontSize: "sm", fontWeight: "medium", style: { textWrap: "nowrap" }, children: t.defaultFile.date })
|
|
7803
7790
|
] }) : /* @__PURE__ */ d(fe, { direction: "row", gap: "xs", align: "center", children: [
|
|
7804
7791
|
/* @__PURE__ */ e(C, { fontSize: "sm", fontWeight: "medium", children: sc(((n = t.fileSelected) == null ? void 0 : n.size.toString()) || "100000") }),
|
|
7805
|
-
/* @__PURE__ */ e(
|
|
7792
|
+
/* @__PURE__ */ e(M, { name: "Dot", size: "xs" }),
|
|
7806
7793
|
/* @__PURE__ */ e(C, { fontSize: "sm", fontWeight: "medium", style: { textWrap: "nowrap" }, children: nc(/* @__PURE__ */ new Date()) })
|
|
7807
7794
|
] })
|
|
7808
7795
|
] })
|
|
@@ -7817,7 +7804,7 @@ const dc = (t) => {
|
|
|
7817
7804
|
onClick: (o) => {
|
|
7818
7805
|
o.stopPropagation(), t.handleOnDeleteFile();
|
|
7819
7806
|
},
|
|
7820
|
-
iconLeft: /* @__PURE__ */ e(
|
|
7807
|
+
iconLeft: /* @__PURE__ */ e(M, { name: "Trash1" })
|
|
7821
7808
|
}
|
|
7822
7809
|
)
|
|
7823
7810
|
]
|
|
@@ -7850,7 +7837,7 @@ const dc = (t) => {
|
|
|
7850
7837
|
alignItems: "center"
|
|
7851
7838
|
}, children: "Optional" }),
|
|
7852
7839
|
n.required && /* @__PURE__ */ e("span", { style: { fontSize: "14px", fontWeight: 500, color: "var(--sa-text-error)" }, children: "*" })
|
|
7853
|
-
] }) : null, a = n.description ? /* @__PURE__ */ e(C, { style: { fontSize: "12px", fontWeight: 400, color: "var(--sa-text-subtlest, #6b6e76)", lineHeight: "18px" }, children: n.description }) : null, u = /* @__PURE__ */ d(
|
|
7840
|
+
] }) : null, a = n.description ? /* @__PURE__ */ e(C, { style: { fontSize: "12px", fontWeight: 400, color: "var(--sa-text-subtlest, #6b6e76)", lineHeight: "18px" }, children: n.description }) : null, u = /* @__PURE__ */ d(ae, { children: [
|
|
7854
7841
|
n.helperText && /* @__PURE__ */ e(C, { style: { fontSize: "12px", fontWeight: 400, color: "var(--sa-text-subtlest, #6b6e76)", lineHeight: "18px" }, children: n.helperText }),
|
|
7855
7842
|
n.errorText && t === "error" && /* @__PURE__ */ e(C, { style: { fontSize: "12px", fontWeight: 400, color: "var(--sa-text-error, #a4133c)", lineHeight: "18px" }, children: n.errorText }),
|
|
7856
7843
|
n.errorMessage && !n.errorText && /* @__PURE__ */ e(C, { style: { fontSize: "12px", fontWeight: 400, color: "var(--sa-text-error, #a4133c)", lineHeight: "18px" }, children: n.errorMessage })
|
|
@@ -7968,7 +7955,7 @@ const dc = (t) => {
|
|
|
7968
7955
|
arrowPosition: (u = i.tooltip) == null ? void 0 : u.arrowPosition,
|
|
7969
7956
|
...i.tooltip,
|
|
7970
7957
|
children: /* @__PURE__ */ e(
|
|
7971
|
-
|
|
7958
|
+
M,
|
|
7972
7959
|
{
|
|
7973
7960
|
name: "InfoCircle",
|
|
7974
7961
|
size: t === "lg" ? "sm" : "xs",
|
|
@@ -8050,7 +8037,7 @@ const dc = (t) => {
|
|
|
8050
8037
|
arrowPosition: (m = l.tooltip) == null ? void 0 : m.arrowPosition,
|
|
8051
8038
|
...l.tooltip,
|
|
8052
8039
|
children: /* @__PURE__ */ e(
|
|
8053
|
-
|
|
8040
|
+
M,
|
|
8054
8041
|
{
|
|
8055
8042
|
name: "InfoCircle",
|
|
8056
8043
|
size: t === "lg" ? "sm" : "xs",
|
|
@@ -8250,7 +8237,7 @@ const dc = (t) => {
|
|
|
8250
8237
|
arrowPosition: (u = i.tooltip) == null ? void 0 : u.arrowPosition,
|
|
8251
8238
|
...i.tooltip,
|
|
8252
8239
|
children: /* @__PURE__ */ e(
|
|
8253
|
-
|
|
8240
|
+
M,
|
|
8254
8241
|
{
|
|
8255
8242
|
name: "InfoCircle",
|
|
8256
8243
|
size: t === "lg" ? "sm" : "xs",
|
|
@@ -8334,7 +8321,7 @@ const dc = (t) => {
|
|
|
8334
8321
|
arrowPosition: (u = l.tooltip) == null ? void 0 : u.arrowPosition,
|
|
8335
8322
|
...l.tooltip,
|
|
8336
8323
|
children: /* @__PURE__ */ e(
|
|
8337
|
-
|
|
8324
|
+
M,
|
|
8338
8325
|
{
|
|
8339
8326
|
name: "InfoCircle",
|
|
8340
8327
|
size: t === "lg" ? "sm" : "xs",
|
|
@@ -8375,7 +8362,7 @@ const dc = (t) => {
|
|
|
8375
8362
|
var a, u, m, p, g, b;
|
|
8376
8363
|
if (!c) return;
|
|
8377
8364
|
const s = n.disabled ? "var(--sa-text-disable, #181a198f)" : t === "secondary" ? "var(--sa-text-subtle, #8c8f97)" : t === "secondary-danger" ? (u = (a = o == null ? void 0 : o.computed) == null ? void 0 : a.red) == null ? void 0 : u[600] : t === "secondary-primary" ? (p = (m = o == null ? void 0 : o.computed) == null ? void 0 : m.blue) == null ? void 0 : p[700] : (b = (g = o == null ? void 0 : o.computed) == null ? void 0 : g.gray) == null ? void 0 : b[50];
|
|
8378
|
-
return /* @__PURE__ */ e(
|
|
8365
|
+
return /* @__PURE__ */ e(M, { name: c, size: r, style: { color: s } });
|
|
8379
8366
|
}, l = () => {
|
|
8380
8367
|
var s, a, u, m;
|
|
8381
8368
|
if (t !== "secondary-danger" && t !== "secondary-primary")
|
|
@@ -8468,7 +8455,7 @@ const dc = (t) => {
|
|
|
8468
8455
|
arrowPosition: (u = i.tooltip) == null ? void 0 : u.arrowPosition,
|
|
8469
8456
|
...i.tooltip,
|
|
8470
8457
|
children: /* @__PURE__ */ e(
|
|
8471
|
-
|
|
8458
|
+
M,
|
|
8472
8459
|
{
|
|
8473
8460
|
name: "InfoCircle",
|
|
8474
8461
|
size: t === "lg" ? "sm" : "xs",
|
|
@@ -8560,7 +8547,7 @@ const $n = {
|
|
|
8560
8547
|
maxFileSize: a = 2,
|
|
8561
8548
|
onError: u
|
|
8562
8549
|
}, m) => {
|
|
8563
|
-
const p = We("md"), [g, b] = H(!1), [S, v] = H(null), [W, F] = H(!1), [
|
|
8550
|
+
const p = We("md"), [g, b] = H(!1), [S, v] = H(null), [W, F] = H(!1), [A, D] = H({ x: 0, y: 0 }), [k, I] = H(1), [B, w] = H(null);
|
|
8564
8551
|
Y(() => {
|
|
8565
8552
|
r === null && i(null);
|
|
8566
8553
|
}, [r]);
|
|
@@ -8645,7 +8632,7 @@ const $n = {
|
|
|
8645
8632
|
justify: "center",
|
|
8646
8633
|
padding: "spacing-4",
|
|
8647
8634
|
children: /* @__PURE__ */ e(
|
|
8648
|
-
|
|
8635
|
+
M,
|
|
8649
8636
|
{
|
|
8650
8637
|
name: "Image",
|
|
8651
8638
|
style: {
|
|
@@ -8687,7 +8674,7 @@ const $n = {
|
|
|
8687
8674
|
),
|
|
8688
8675
|
/* @__PURE__ */ d(h, { display: "flex", align: "center", gap: "spacing-2", direction: "row", children: [
|
|
8689
8676
|
/* @__PURE__ */ e(
|
|
8690
|
-
|
|
8677
|
+
M,
|
|
8691
8678
|
{
|
|
8692
8679
|
name: "Edit3",
|
|
8693
8680
|
style: { color: "var(--sa-background-primary, #ffffff)" }
|
|
@@ -8776,7 +8763,7 @@ const $n = {
|
|
|
8776
8763
|
ro,
|
|
8777
8764
|
{
|
|
8778
8765
|
image: S,
|
|
8779
|
-
crop:
|
|
8766
|
+
crop: A,
|
|
8780
8767
|
zoom: k,
|
|
8781
8768
|
aspect: c ? $n[c] : void 0,
|
|
8782
8769
|
onCropChange: D,
|
|
@@ -8866,7 +8853,7 @@ const $n = {
|
|
|
8866
8853
|
arrowPosition: (m = l.tooltip) == null ? void 0 : m.arrowPosition,
|
|
8867
8854
|
...l.tooltip,
|
|
8868
8855
|
children: /* @__PURE__ */ e(
|
|
8869
|
-
|
|
8856
|
+
M,
|
|
8870
8857
|
{
|
|
8871
8858
|
name: "InfoCircle",
|
|
8872
8859
|
size: t === "lg" ? "sm" : "xs",
|
|
@@ -8941,7 +8928,7 @@ const $n = {
|
|
|
8941
8928
|
arrowPosition: (a = i.tooltip) == null ? void 0 : a.arrowPosition,
|
|
8942
8929
|
...i.tooltip,
|
|
8943
8930
|
children: /* @__PURE__ */ e(
|
|
8944
|
-
|
|
8931
|
+
M,
|
|
8945
8932
|
{
|
|
8946
8933
|
name: "InfoCircle",
|
|
8947
8934
|
size: t === "lg" ? "sm" : "xs",
|
|
@@ -9050,7 +9037,7 @@ const $n = {
|
|
|
9050
9037
|
onClick: i,
|
|
9051
9038
|
type: "button",
|
|
9052
9039
|
iconLeft: /* @__PURE__ */ e(
|
|
9053
|
-
|
|
9040
|
+
M,
|
|
9054
9041
|
{
|
|
9055
9042
|
width: 16,
|
|
9056
9043
|
size: "xs",
|
|
@@ -9226,7 +9213,7 @@ const ha = ({
|
|
|
9226
9213
|
className: v,
|
|
9227
9214
|
pageLayout: W,
|
|
9228
9215
|
overlay: F = "mobile",
|
|
9229
|
-
wrapperProps:
|
|
9216
|
+
wrapperProps: A,
|
|
9230
9217
|
contentProps: D
|
|
9231
9218
|
}) => {
|
|
9232
9219
|
const k = We("md"), I = n !== void 0, [B, w] = H(o), R = I ? n : B, z = () => {
|
|
@@ -9326,7 +9313,7 @@ const ha = ({
|
|
|
9326
9313
|
// boxShadow: "-2px 0 6px rgba(0, 0, 0, 0.04)",
|
|
9327
9314
|
}
|
|
9328
9315
|
},
|
|
9329
|
-
children: /* @__PURE__ */ e(
|
|
9316
|
+
children: /* @__PURE__ */ e(M, { name: re, size: "sm" })
|
|
9330
9317
|
}
|
|
9331
9318
|
)
|
|
9332
9319
|
]
|
|
@@ -9337,11 +9324,11 @@ const ha = ({
|
|
|
9337
9324
|
{
|
|
9338
9325
|
direction: "row",
|
|
9339
9326
|
position: "relative",
|
|
9340
|
-
...
|
|
9327
|
+
...A,
|
|
9341
9328
|
style: {
|
|
9342
9329
|
height: `calc(100vh - ${Q})`,
|
|
9343
9330
|
overflow: "hidden",
|
|
9344
|
-
...(
|
|
9331
|
+
...(A == null ? void 0 : A.style) ?? {}
|
|
9345
9332
|
},
|
|
9346
9333
|
children: [
|
|
9347
9334
|
!$ && U ? V : null,
|
|
@@ -9361,7 +9348,7 @@ const ha = ({
|
|
|
9361
9348
|
}
|
|
9362
9349
|
),
|
|
9363
9350
|
!$ && !U ? V : null,
|
|
9364
|
-
$ && /* @__PURE__ */ d(
|
|
9351
|
+
$ && /* @__PURE__ */ d(ae, { children: [
|
|
9365
9352
|
!R && /* @__PURE__ */ e(
|
|
9366
9353
|
"div",
|
|
9367
9354
|
{
|
|
@@ -9487,7 +9474,7 @@ const ha = ({
|
|
|
9487
9474
|
}
|
|
9488
9475
|
) }), Rc = ({ title: t, value: r, icon: n }) => /* @__PURE__ */ d(h, { display: "flex", direction: "column", gap: "sm", children: [
|
|
9489
9476
|
n ? /* @__PURE__ */ d(h, { display: "flex", direction: "row", align: "center", gap: "xs", children: [
|
|
9490
|
-
/* @__PURE__ */ e(
|
|
9477
|
+
/* @__PURE__ */ e(M, { name: n, color: "subtle" }),
|
|
9491
9478
|
/* @__PURE__ */ e(C, { color: "gray-500", variant: "sub-h3", children: t })
|
|
9492
9479
|
] }) : /* @__PURE__ */ e(C, { color: "gray-500", variant: "sub-h3", children: t }),
|
|
9493
9480
|
typeof r == "string" ? /* @__PURE__ */ e(C, { variant: "sub-h3", children: r }) : r
|
|
@@ -9496,7 +9483,7 @@ const ha = ({
|
|
|
9496
9483
|
accent: "#78867F"
|
|
9497
9484
|
};
|
|
9498
9485
|
function Bc({ width: t, height: r }) {
|
|
9499
|
-
return /* @__PURE__ */ e(
|
|
9486
|
+
return /* @__PURE__ */ e(ae, { children: /* @__PURE__ */ d(
|
|
9500
9487
|
"svg",
|
|
9501
9488
|
{
|
|
9502
9489
|
width: t || "100",
|
|
@@ -9653,9 +9640,9 @@ const ya = ({
|
|
|
9653
9640
|
const m = () => {
|
|
9654
9641
|
switch (o) {
|
|
9655
9642
|
case "primary":
|
|
9656
|
-
return /* @__PURE__ */ e(
|
|
9643
|
+
return /* @__PURE__ */ e(ae, { children: l ? /* @__PURE__ */ e(N, { primary: !0, iconLeft: l, onClick: n, children: a || t }) : /* @__PURE__ */ e(N, { primary: !0, onClick: n, children: a || t }) });
|
|
9657
9644
|
case "secondary":
|
|
9658
|
-
return /* @__PURE__ */ e(
|
|
9645
|
+
return /* @__PURE__ */ e(ae, { children: l ? /* @__PURE__ */ e(N, { secondary: !0, iconLeft: l, onClick: n, children: i ? /* @__PURE__ */ e(
|
|
9659
9646
|
C,
|
|
9660
9647
|
{
|
|
9661
9648
|
fontSize: "md",
|
|
@@ -9665,9 +9652,9 @@ const ya = ({
|
|
|
9665
9652
|
}
|
|
9666
9653
|
) : t }) : /* @__PURE__ */ e(N, { secondary: !0, onClick: n, children: a || t }) });
|
|
9667
9654
|
case "success":
|
|
9668
|
-
return /* @__PURE__ */ e(
|
|
9655
|
+
return /* @__PURE__ */ e(ae, { children: l ? /* @__PURE__ */ e(N, { success: !0, iconLeft: l, onClick: n, children: a || t }) : /* @__PURE__ */ e(N, { success: !0, onClick: n, children: a || t }) });
|
|
9669
9656
|
default:
|
|
9670
|
-
return /* @__PURE__ */ e(
|
|
9657
|
+
return /* @__PURE__ */ e(ae, { children: l ? /* @__PURE__ */ e(N, { primary: !0, iconLeft: l, onClick: n, children: a || t }) : /* @__PURE__ */ e(N, { primary: !0, onClick: n, children: a || t }) });
|
|
9671
9658
|
}
|
|
9672
9659
|
};
|
|
9673
9660
|
return /* @__PURE__ */ d(
|
|
@@ -9709,7 +9696,7 @@ const ya = ({
|
|
|
9709
9696
|
cFFFFFF: "#FFFFFF"
|
|
9710
9697
|
};
|
|
9711
9698
|
function Ic({ width: t, height: r }) {
|
|
9712
|
-
return /* @__PURE__ */ e(
|
|
9699
|
+
return /* @__PURE__ */ e(ae, { children: /* @__PURE__ */ d(
|
|
9713
9700
|
"svg",
|
|
9714
9701
|
{
|
|
9715
9702
|
width: t,
|
|
@@ -9970,7 +9957,7 @@ const le = {
|
|
|
9970
9957
|
cFFFFFF: "#FFFFFF"
|
|
9971
9958
|
};
|
|
9972
9959
|
function Hc({ width: t, height: r }) {
|
|
9973
|
-
return /* @__PURE__ */ e(
|
|
9960
|
+
return /* @__PURE__ */ e(ae, { children: /* @__PURE__ */ d(
|
|
9974
9961
|
"svg",
|
|
9975
9962
|
{
|
|
9976
9963
|
width: t,
|
|
@@ -10222,7 +10209,7 @@ const f = {
|
|
|
10222
10209
|
cFFFFFF: "#FFFFFF"
|
|
10223
10210
|
};
|
|
10224
10211
|
function Oc({ width: t, height: r }) {
|
|
10225
|
-
return /* @__PURE__ */ e(
|
|
10212
|
+
return /* @__PURE__ */ e(ae, { children: /* @__PURE__ */ d(
|
|
10226
10213
|
"svg",
|
|
10227
10214
|
{
|
|
10228
10215
|
width: t,
|
|
@@ -11015,7 +11002,7 @@ const Ca = (t) => {
|
|
|
11015
11002
|
footerProps: v = { borderTop: !0 },
|
|
11016
11003
|
variantTag: W = "info"
|
|
11017
11004
|
}) => {
|
|
11018
|
-
const F = oe(null), [
|
|
11005
|
+
const F = oe(null), [A, D] = H("100vh");
|
|
11019
11006
|
Y(() => {
|
|
11020
11007
|
const w = () => {
|
|
11021
11008
|
if (F.current) {
|
|
@@ -11056,7 +11043,7 @@ const Ca = (t) => {
|
|
|
11056
11043
|
style: {
|
|
11057
11044
|
backgroundColor: "var(--sa-background-primary, #ffffff)",
|
|
11058
11045
|
display: "flex",
|
|
11059
|
-
minHeight:
|
|
11046
|
+
minHeight: A,
|
|
11060
11047
|
...(g == null ? void 0 : g.style) ?? {}
|
|
11061
11048
|
},
|
|
11062
11049
|
children: [
|
|
@@ -11140,12 +11127,12 @@ const _e = {
|
|
|
11140
11127
|
{
|
|
11141
11128
|
mode: "modal",
|
|
11142
11129
|
label: "Modal",
|
|
11143
|
-
icon: /* @__PURE__ */ e(
|
|
11130
|
+
icon: /* @__PURE__ */ e(M, { name: "Newscreen", size: "sm" })
|
|
11144
11131
|
},
|
|
11145
11132
|
{
|
|
11146
11133
|
mode: "fullscreen",
|
|
11147
11134
|
label: "Fullscreen",
|
|
11148
|
-
icon: /* @__PURE__ */ e(
|
|
11135
|
+
icon: /* @__PURE__ */ e(M, { name: "Fullscreen", size: "sm" })
|
|
11149
11136
|
}
|
|
11150
11137
|
];
|
|
11151
11138
|
function Vc({ value: t, onChange: r }) {
|
|
@@ -11214,7 +11201,7 @@ function _c(t) {
|
|
|
11214
11201
|
disableBackdropClose: p = !1,
|
|
11215
11202
|
lockBodyScroll: g = !0,
|
|
11216
11203
|
children: b
|
|
11217
|
-
} = t, [S, v] = H(i), W = o ?? S,
|
|
11204
|
+
} = t, [S, v] = H(i), W = o ?? S, A = We("md") ? W : "fullscreen", D = G(
|
|
11218
11205
|
(P) => {
|
|
11219
11206
|
o === void 0 && v(P), l == null || l(P);
|
|
11220
11207
|
},
|
|
@@ -11249,9 +11236,9 @@ function _c(t) {
|
|
|
11249
11236
|
if (!r) return null;
|
|
11250
11237
|
const U = [
|
|
11251
11238
|
_e["lyd-panel"],
|
|
11252
|
-
|
|
11253
|
-
|
|
11254
|
-
|
|
11239
|
+
A === "modal" && _e["lyd-modal"],
|
|
11240
|
+
A === "fullscreen" && _e["lyd-fullscreen"],
|
|
11241
|
+
A === "sidebar" && _e["lyd-sidebar"]
|
|
11255
11242
|
].filter(Boolean).join(" "), Q = {
|
|
11256
11243
|
"--lyd-max-w": $c(a),
|
|
11257
11244
|
...u !== void 0 && { "--lyd-aside-w": u }
|
|
@@ -11287,7 +11274,7 @@ function _c(t) {
|
|
|
11287
11274
|
className: _e["lyd-close-btn"],
|
|
11288
11275
|
onClick: n,
|
|
11289
11276
|
"aria-label": "Close dialog",
|
|
11290
|
-
children: /* @__PURE__ */ e(
|
|
11277
|
+
children: /* @__PURE__ */ e(M, { name: "Cross", size: "md" })
|
|
11291
11278
|
}
|
|
11292
11279
|
)
|
|
11293
11280
|
] })
|
|
@@ -11465,7 +11452,7 @@ function jc({
|
|
|
11465
11452
|
),
|
|
11466
11453
|
/* @__PURE__ */ e(Tr, {}),
|
|
11467
11454
|
r,
|
|
11468
|
-
o && /* @__PURE__ */ d(
|
|
11455
|
+
o && /* @__PURE__ */ d(ae, { children: [
|
|
11469
11456
|
/* @__PURE__ */ e(Tr, {}),
|
|
11470
11457
|
/* @__PURE__ */ e(Ne, { label: i, position: "top", children: /* @__PURE__ */ e(
|
|
11471
11458
|
N,
|
|
@@ -11473,7 +11460,7 @@ function jc({
|
|
|
11473
11460
|
variant: "tertiary",
|
|
11474
11461
|
tone: "neutral",
|
|
11475
11462
|
size: "sm",
|
|
11476
|
-
iconLeft: /* @__PURE__ */ e(
|
|
11463
|
+
iconLeft: /* @__PURE__ */ e(M, { name: "Cross", size: "xs" }),
|
|
11477
11464
|
"aria-label": i,
|
|
11478
11465
|
onClick: o,
|
|
11479
11466
|
disabled: l
|