@tesouro/embedded-components-react 0.5.25 → 0.5.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.css +3 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index70.js +2 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index71.js +82 -65
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index82.js +108 -92
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index79.js +2 -0
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
- package/dist/packages/shared-ui-shadcn/dist/index.js +117 -116
- package/package.json +1 -1
package/dist/index.css
CHANGED
|
@@ -6,7 +6,8 @@ var e = {
|
|
|
6
6
|
duplicateCaption: (e) => `${e} possible ${e === 1 ? "duplicate" : "duplicates"}`,
|
|
7
7
|
failedCaption: (e) => `${e} failed to upload`,
|
|
8
8
|
tooManyFilesError: (e) => `You can only upload up to ${e} files at a time`,
|
|
9
|
-
remainingCapacityError: (e) => e === 0 ? "Wait for the current uploads to finish before adding more files" : `You can upload ${e} more ${e === 1 ? "file" : "files"} right now
|
|
9
|
+
remainingCapacityError: (e) => e === 0 ? "Wait for the current uploads to finish before adding more files" : `You can upload ${e} more ${e === 1 ? "file" : "files"} right now`,
|
|
10
|
+
billDeletedError: "This bill was already deleted"
|
|
10
11
|
};
|
|
11
12
|
//#endregion
|
|
12
13
|
export { e as BILL_UPLOAD_QUEUE_LABELS_EN };
|
|
@@ -4,109 +4,126 @@
|
|
|
4
4
|
"use client";
|
|
5
5
|
import { toast as e } from "../../../../../packages/shared-ui-shadcn/dist/index.js";
|
|
6
6
|
import { useEmbedApi as t } from "../../../shared/data-access/dist/lib/EmbedApiContext.js";
|
|
7
|
+
import { organizationHeaders as n } from "../../../shared/data-access/dist/lib/organizationHeaders.js";
|
|
8
|
+
import { getPayablesIdOptions as r } from "../../../shared/data-access/dist/lib/rest/@tanstack/react-query.gen.js";
|
|
9
|
+
import { withAuthEpoch as i } from "../../../shared/data-access/dist/lib/withAuthEpoch.js";
|
|
10
|
+
import { isApiNotFoundError as a } from "../../../shared/data-access/dist/lib/isApiNotFoundError.js";
|
|
11
|
+
import "../../../shared/data-access/dist/index.js";
|
|
7
12
|
import "../../../shared/ui/dist/index.js";
|
|
8
|
-
import { useUploadPayableFromFileMutation as
|
|
9
|
-
import { usePayableOcrQueries as
|
|
13
|
+
import { useUploadPayableFromFileMutation as o } from "../../data-access/dist/index13.js";
|
|
14
|
+
import { usePayableOcrQueries as s } from "../../data-access/dist/index15.js";
|
|
10
15
|
import "../../data-access/dist/index.js";
|
|
11
|
-
import { billPayUploadQueueKey as
|
|
12
|
-
import { BILL_UPLOAD_QUEUE_LABELS_EN as
|
|
13
|
-
import { useCallback as
|
|
14
|
-
import { useQuery as
|
|
16
|
+
import { billPayUploadQueueKey as c } from "./index69.js";
|
|
17
|
+
import { BILL_UPLOAD_QUEUE_LABELS_EN as l } from "./index70.js";
|
|
18
|
+
import { useCallback as u, useEffect as d, useMemo as f, useState as p } from "react";
|
|
19
|
+
import { useQuery as m, useQueryClient as h } from "@tanstack/react-query";
|
|
15
20
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index71.js
|
|
16
|
-
function
|
|
17
|
-
let
|
|
18
|
-
...
|
|
19
|
-
...
|
|
20
|
-
},
|
|
21
|
-
queryKey:
|
|
22
|
-
queryFn: () =>
|
|
21
|
+
function g({ onOpenBill: g, labels: _ } = {}) {
|
|
22
|
+
let v = {
|
|
23
|
+
...l,
|
|
24
|
+
..._
|
|
25
|
+
}, y = _?.tooManyFilesError ?? l.tooManyFilesError, b = _?.remainingCapacityError ?? l.remainingCapacityError, { client: x, organizationId: S, authEpoch: C } = t(), w = h(), T = f(() => c(S), [S]), E = o(), [D, O] = p(!1), { data: k = [] } = m({
|
|
26
|
+
queryKey: T,
|
|
27
|
+
queryFn: () => w.getQueryData(T) ?? [],
|
|
23
28
|
staleTime: Infinity,
|
|
24
29
|
gcTime: Infinity,
|
|
25
30
|
initialData: []
|
|
26
|
-
}),
|
|
27
|
-
|
|
31
|
+
}), A = u((e, t) => {
|
|
32
|
+
w.setQueryData(T, (n) => (n ?? []).map((n) => n.localId === e ? {
|
|
28
33
|
...n,
|
|
29
34
|
...t
|
|
30
35
|
} : n));
|
|
31
|
-
}, [
|
|
32
|
-
|
|
33
|
-
}, [
|
|
34
|
-
let n = (
|
|
36
|
+
}, [w, T]), j = u((e) => {
|
|
37
|
+
w.setQueryData(T, (t) => (t ?? []).filter((t) => t.localId !== e));
|
|
38
|
+
}, [w, T]), M = u((t) => {
|
|
39
|
+
let n = (w.getQueryData(T) ?? []).filter((e) => e.status === "uploading").length;
|
|
35
40
|
if (t.length + n > 10) {
|
|
36
|
-
e.error(n > 0 ?
|
|
41
|
+
e.error(n > 0 ? b(10 - n) : y(10));
|
|
37
42
|
return;
|
|
38
43
|
}
|
|
39
|
-
|
|
44
|
+
O(!1);
|
|
40
45
|
for (let e of t) {
|
|
41
46
|
let t = crypto.randomUUID();
|
|
42
|
-
|
|
47
|
+
w.setQueryData(T, (n) => [...n ?? [], {
|
|
43
48
|
localId: t,
|
|
44
49
|
fileName: e.name,
|
|
45
50
|
status: "uploading"
|
|
46
|
-
}]),
|
|
51
|
+
}]), E.mutateAsync({ file: e }).then((e) => A(t, { payableId: e?.id })).catch(() => A(t, { status: "failed" }));
|
|
47
52
|
}
|
|
48
53
|
}, [
|
|
54
|
+
A,
|
|
49
55
|
w,
|
|
50
|
-
|
|
56
|
+
T,
|
|
57
|
+
b,
|
|
51
58
|
y,
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
]), D = r({ payableIds: C.filter((e) => e.status === "uploading" && e.payableId).map((e) => e.payableId) });
|
|
56
|
-
s(() => {
|
|
59
|
+
E
|
|
60
|
+
]), N = s({ payableIds: k.filter((e) => e.status === "uploading" && e.payableId).map((e) => e.payableId) });
|
|
61
|
+
d(() => {
|
|
57
62
|
let e = /* @__PURE__ */ new Set();
|
|
58
|
-
for (let t of
|
|
63
|
+
for (let t of N) if (t.suspectedDuplicateOf.length !== 0) {
|
|
59
64
|
e.add(t.payableId);
|
|
60
65
|
for (let n of t.suspectedDuplicateOf) e.add(n);
|
|
61
66
|
}
|
|
62
|
-
for (let { payableId: t, ocrStatus: n, isError: r } of
|
|
63
|
-
let i =
|
|
64
|
-
i && (n === "success" ?
|
|
67
|
+
for (let { payableId: t, ocrStatus: n, isError: r } of N) {
|
|
68
|
+
let i = k.find((e) => e.payableId === t && e.status === "uploading");
|
|
69
|
+
i && (n === "success" ? A(i.localId, { status: e.has(t) ? "duplicate" : "ready" }) : (r || n === "error" || n === "canceled") && A(i.localId, { status: "failed" }));
|
|
65
70
|
}
|
|
66
|
-
for (let t of
|
|
71
|
+
for (let t of k) t.status === "ready" && t.payableId && e.has(t.payableId) && A(t.localId, { status: "duplicate" });
|
|
67
72
|
}, [
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
73
|
+
k,
|
|
74
|
+
N,
|
|
75
|
+
A
|
|
71
76
|
]);
|
|
72
|
-
let
|
|
73
|
-
id:
|
|
74
|
-
fileName:
|
|
75
|
-
status:
|
|
76
|
-
onOpen: (
|
|
77
|
-
|
|
77
|
+
let P = k.filter((e) => e.status === "uploading"), F = k.filter((e) => e.status === "ready"), I = k.filter((e) => e.status === "duplicate"), L = k.filter((e) => e.status === "failed"), R = (t) => ({
|
|
78
|
+
id: t.localId,
|
|
79
|
+
fileName: t.fileName,
|
|
80
|
+
status: t.status,
|
|
81
|
+
onOpen: (t.status === "ready" || t.status === "duplicate") && t.payableId && g ? () => {
|
|
82
|
+
let o = t.payableId;
|
|
83
|
+
w.fetchQuery({
|
|
84
|
+
...i(r({
|
|
85
|
+
client: x,
|
|
86
|
+
headers: n(S),
|
|
87
|
+
path: { payable_id: o }
|
|
88
|
+
}), C),
|
|
89
|
+
retry: !1
|
|
90
|
+
}).catch((e) => {
|
|
91
|
+
if (a(e)) return "deleted";
|
|
92
|
+
}).then((n) => {
|
|
93
|
+
n === "deleted" ? e.error(v.billDeletedError) : g(o), j(t.localId);
|
|
94
|
+
});
|
|
78
95
|
} : void 0
|
|
79
|
-
}),
|
|
96
|
+
}), z = P.length ? [{
|
|
80
97
|
id: "in-progress",
|
|
81
|
-
items:
|
|
98
|
+
items: k.map(R)
|
|
82
99
|
}] : [
|
|
83
|
-
...
|
|
100
|
+
...F.length ? [{
|
|
84
101
|
id: "ready",
|
|
85
|
-
caption:
|
|
86
|
-
items:
|
|
102
|
+
caption: v.readyCaption(F.length),
|
|
103
|
+
items: F.map(R)
|
|
87
104
|
}] : [],
|
|
88
|
-
...
|
|
105
|
+
...I.length ? [{
|
|
89
106
|
id: "duplicate",
|
|
90
|
-
caption:
|
|
91
|
-
items:
|
|
107
|
+
caption: v.duplicateCaption(I.length),
|
|
108
|
+
items: I.map(R)
|
|
92
109
|
}] : [],
|
|
93
|
-
...
|
|
110
|
+
...L.length ? [{
|
|
94
111
|
id: "failed",
|
|
95
|
-
caption:
|
|
96
|
-
items:
|
|
112
|
+
caption: v.failedCaption(L.length),
|
|
113
|
+
items: L.map(R)
|
|
97
114
|
}] : []
|
|
98
|
-
],
|
|
99
|
-
|
|
100
|
-
}, [
|
|
115
|
+
], B = F.length + I.length, V = P.length ? v.uploadingSummary(k.length) : B ? v.completeSummary(B) : v.failedCaption(L.length), H = u(() => {
|
|
116
|
+
w.setQueryData(T, []);
|
|
117
|
+
}, [w, T]);
|
|
101
118
|
return {
|
|
102
|
-
enqueue:
|
|
103
|
-
sections:
|
|
104
|
-
summaryLabel:
|
|
105
|
-
collapsed:
|
|
106
|
-
onToggleCollapsed:
|
|
107
|
-
onClose:
|
|
108
|
-
isVisible:
|
|
119
|
+
enqueue: M,
|
|
120
|
+
sections: z,
|
|
121
|
+
summaryLabel: V,
|
|
122
|
+
collapsed: D,
|
|
123
|
+
onToggleCollapsed: u(() => O((e) => !e), []),
|
|
124
|
+
onClose: H,
|
|
125
|
+
isVisible: k.length > 0
|
|
109
126
|
};
|
|
110
127
|
}
|
|
111
128
|
//#endregion
|
|
112
|
-
export {
|
|
129
|
+
export { g as useBillUploadQueue };
|
|
@@ -2,117 +2,133 @@
|
|
|
2
2
|
"use client";
|
|
3
3
|
"use client";
|
|
4
4
|
"use client";
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
5
|
+
import { useEmbedApi as e } from "../../../shared/data-access/dist/lib/EmbedApiContext.js";
|
|
6
|
+
import { formatCalendarDate as t } from "../../../shared/util/dist/lib/formatCalendarDate.js";
|
|
7
|
+
import { formatMoneyExact as n } from "../../../shared/util/dist/lib/formatMoneyExact.js";
|
|
8
|
+
import { hasSuspectedPayableDuplicate as ee } from "../../data-access/dist/index7.js";
|
|
8
9
|
import { usePayablesQuery as r, usePayablesTotalCountQuery as i } from "../../data-access/dist/index17.js";
|
|
9
10
|
import "../../data-access/dist/index.js";
|
|
10
|
-
import { derivePayableStatus as
|
|
11
|
-
import { resolveVendorName as
|
|
12
|
-
import { isEditablePayableStatus as
|
|
13
|
-
import { BillQueue as
|
|
14
|
-
import { useBillsFilters as
|
|
15
|
-
import { useCallback as
|
|
11
|
+
import { derivePayableStatus as te } from "./index7.js";
|
|
12
|
+
import { resolveVendorName as a } from "./index8.js";
|
|
13
|
+
import { isEditablePayableStatus as ne } from "./index19.js";
|
|
14
|
+
import { BillQueue as o, DEFAULT_BILL_QUEUE as s, billQueueColumns as c, billQueueHasScheduledPayment as l, billQueueOffersAddPanel as u, billQueueStatuses as d, billSortColumnId as f, billSortField as p } from "./index73.js";
|
|
15
|
+
import { useBillsFilters as m } from "./index81.js";
|
|
16
|
+
import { useCallback as h, useEffect as g, useMemo as _, useState as v } from "react";
|
|
16
17
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index82.js
|
|
17
|
-
var
|
|
18
|
+
var y = 10, b = [{
|
|
18
19
|
id: "addedOnLabel",
|
|
19
20
|
desc: !0
|
|
20
21
|
}];
|
|
21
|
-
function
|
|
22
|
-
let [
|
|
23
|
-
|
|
22
|
+
function x({ enabled: x = !0, canReadVendors: S = !0, isVendorFilterPaused: C = !1, filterLabels: w, onOpenBill: T, duplicateRowNote: E, attachmentLabel: D }) {
|
|
23
|
+
let [O, k] = v(s), [A, j] = v(b), [M, N] = v(y), [P, F] = v(), [I, L] = v(""), [R, z] = v(""), B = h(() => F(void 0), []);
|
|
24
|
+
g(() => {
|
|
24
25
|
let e = setTimeout(() => {
|
|
25
|
-
|
|
26
|
+
z(I), B();
|
|
26
27
|
}, 300);
|
|
27
28
|
return () => clearTimeout(e);
|
|
28
|
-
}, [
|
|
29
|
-
let
|
|
30
|
-
offersStatusFilter:
|
|
31
|
-
offersVendorFilter:
|
|
32
|
-
isVendorFilterPaused:
|
|
33
|
-
labels:
|
|
34
|
-
onFiltersChange:
|
|
35
|
-
}),
|
|
36
|
-
...
|
|
37
|
-
limit:
|
|
38
|
-
pagination_token:
|
|
39
|
-
status__in:
|
|
40
|
-
has_scheduled_payment:
|
|
41
|
-
counterpart_name__icontains:
|
|
42
|
-
sort:
|
|
43
|
-
order:
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
29
|
+
}, [I, B]);
|
|
30
|
+
let V = m({
|
|
31
|
+
offersStatusFilter: O === o.All,
|
|
32
|
+
offersVendorFilter: S,
|
|
33
|
+
isVendorFilterPaused: C,
|
|
34
|
+
labels: w,
|
|
35
|
+
onFiltersChange: B
|
|
36
|
+
}), H = A[0], U = p(H?.id), W = U ? H?.desc ? "desc" : "asc" : void 0, G = _(() => ({
|
|
37
|
+
...V.query,
|
|
38
|
+
limit: M,
|
|
39
|
+
pagination_token: P,
|
|
40
|
+
status__in: d(O) ?? V.query.status__in,
|
|
41
|
+
has_scheduled_payment: l(O),
|
|
42
|
+
counterpart_name__icontains: R || void 0,
|
|
43
|
+
sort: U,
|
|
44
|
+
order: W
|
|
45
|
+
}), [
|
|
46
|
+
V.query,
|
|
47
|
+
M,
|
|
48
|
+
P,
|
|
49
|
+
O,
|
|
50
|
+
R,
|
|
51
|
+
U,
|
|
52
|
+
W
|
|
53
|
+
]), { organizationId: K } = e(), q = JSON.stringify([K, G]), J = r({
|
|
54
|
+
...G,
|
|
55
|
+
enabled: x
|
|
56
|
+
}), [Y, X] = v(q);
|
|
57
|
+
g(() => {
|
|
58
|
+
J.isFetching || X(q);
|
|
59
|
+
}, [J.isFetching, q]);
|
|
60
|
+
let Z = J.data?.data.length === 0, Q = i({ enabled: x && Z }), re = !Z || (Q.data?.count ?? 1) > 0, ie = _(() => (J.data?.data ?? []).map((e) => {
|
|
61
|
+
let r = te({
|
|
62
|
+
apiStatus: e.status,
|
|
63
|
+
dueDate: e.due_date,
|
|
64
|
+
scheduledPaymentDate: e.scheduled_payment_date
|
|
65
|
+
}), i = e.amount_due ?? e.total_amount, s = e.status === "partially_paid" || e.status === "paid", c = (t) => t == null ? "" : n(t / 100, { currencyCode: e.currency ?? "USD" });
|
|
51
66
|
return {
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
67
|
+
rowKey: e.id,
|
|
68
|
+
vendorLabel: a(e),
|
|
69
|
+
issueDateLabel: t(e.issued_at),
|
|
70
|
+
dueDateLabel: t(e.due_date),
|
|
71
|
+
dueDateTone: r.isOverdue ? "danger" : "default",
|
|
72
|
+
scheduledDateLabel: t(e.scheduled_payment_date),
|
|
73
|
+
scheduledDateIsGap: O === o.Scheduled,
|
|
74
|
+
paidDateLabel: t(e.paid_at?.slice(0, 10)),
|
|
75
|
+
amountDueLabel: c(i),
|
|
76
|
+
amountPaidLabel: s ? c(e.amount_paid) : "",
|
|
77
|
+
amountPaidIsGap: O === o.Paid,
|
|
78
|
+
amountScheduledLabel: c(e.amount_to_pay ?? i),
|
|
79
|
+
totalAmountLabel: c(e.total_amount),
|
|
80
|
+
attachment: e.file_id ? { label: D } : void 0,
|
|
81
|
+
status: r.status,
|
|
82
|
+
statusTone: r.tone,
|
|
83
|
+
addedOnLabel: t(e.created_at?.slice(0, 10)),
|
|
84
|
+
...ee(e) ? {
|
|
69
85
|
rowTone: "warning",
|
|
70
|
-
rowNote:
|
|
86
|
+
rowNote: E
|
|
71
87
|
} : {},
|
|
72
|
-
onOpen: () =>
|
|
88
|
+
onOpen: () => T(e.id, ne(e.status))
|
|
73
89
|
};
|
|
74
90
|
}), [
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
k,
|
|
91
|
+
J.data?.data,
|
|
92
|
+
E,
|
|
78
93
|
D,
|
|
79
|
-
|
|
80
|
-
|
|
94
|
+
T,
|
|
95
|
+
O
|
|
96
|
+
]), ae = h((e) => {
|
|
81
97
|
let t = e;
|
|
82
|
-
|
|
98
|
+
k(t), j((e) => {
|
|
83
99
|
let n = e[0]?.id;
|
|
84
|
-
return n ?
|
|
85
|
-
}),
|
|
86
|
-
}, [
|
|
87
|
-
|
|
88
|
-
}, [
|
|
89
|
-
|
|
90
|
-
}, [
|
|
91
|
-
|
|
92
|
-
}, [
|
|
100
|
+
return n ? c(t).some((e) => f(e) === n) ? e : b : e;
|
|
101
|
+
}), B();
|
|
102
|
+
}, [B]), oe = h((e) => {
|
|
103
|
+
j((t) => typeof e == "function" ? e(t) : e), B();
|
|
104
|
+
}, [B]), $ = h((e) => {
|
|
105
|
+
N(e), B();
|
|
106
|
+
}, [B]), se = h(() => F(J.data?.next_pagination_token ?? void 0), [J.data?.next_pagination_token]), ce = h(() => F(J.data?.prev_pagination_token ?? void 0), [J.data?.prev_pagination_token]), le = h(() => {
|
|
107
|
+
J.refetch();
|
|
108
|
+
}, [J.refetch]);
|
|
93
109
|
return {
|
|
94
|
-
rows:
|
|
95
|
-
isLoading:
|
|
96
|
-
isError:
|
|
97
|
-
onRetry:
|
|
98
|
-
selectedFilterTabId:
|
|
99
|
-
onFilterTabChange:
|
|
100
|
-
searchValue:
|
|
101
|
-
onSearchChange:
|
|
102
|
-
hasAnyBills:
|
|
103
|
-
isSearchActive:
|
|
104
|
-
filterBarProps:
|
|
105
|
-
visibleColumns:
|
|
106
|
-
showAddPanelWhenEmpty:
|
|
107
|
-
sorting:
|
|
108
|
-
onSortingChange:
|
|
109
|
-
pageSize:
|
|
110
|
+
rows: ie,
|
|
111
|
+
isLoading: J.isLoading || q !== Y || Z && Q.isLoading,
|
|
112
|
+
isError: J.isError,
|
|
113
|
+
onRetry: le,
|
|
114
|
+
selectedFilterTabId: O,
|
|
115
|
+
onFilterTabChange: ae,
|
|
116
|
+
searchValue: I,
|
|
117
|
+
onSearchChange: L,
|
|
118
|
+
hasAnyBills: re,
|
|
119
|
+
isSearchActive: R.length > 0 || V.isFilterActive,
|
|
120
|
+
filterBarProps: V.filterBarProps,
|
|
121
|
+
visibleColumns: c(O),
|
|
122
|
+
showAddPanelWhenEmpty: u(O),
|
|
123
|
+
sorting: A,
|
|
124
|
+
onSortingChange: oe,
|
|
125
|
+
pageSize: M,
|
|
110
126
|
onPageSizeChange: $,
|
|
111
|
-
hasNextPage: !!
|
|
112
|
-
hasPrevPage: !!
|
|
113
|
-
onNextPage:
|
|
114
|
-
onPrevPage:
|
|
127
|
+
hasNextPage: !!J.data?.next_pagination_token,
|
|
128
|
+
hasPrevPage: !!J.data?.prev_pagination_token,
|
|
129
|
+
onNextPage: se,
|
|
130
|
+
onPrevPage: ce
|
|
115
131
|
};
|
|
116
132
|
}
|
|
117
133
|
//#endregion
|
|
118
|
-
export {
|
|
134
|
+
export { x as useBillsTable };
|
|
@@ -328,6 +328,8 @@ function x({ rows: x, isLoading: S, isError: C, sorting: ve, onSortingChange: ye
|
|
|
328
328
|
}) : /* @__PURE__ */ g(r, {
|
|
329
329
|
columns: we,
|
|
330
330
|
data: x,
|
|
331
|
+
getRowId: (e) => e.rowKey,
|
|
332
|
+
animatesNewRows: !0,
|
|
331
333
|
isLoading: S,
|
|
332
334
|
sorting: ve,
|
|
333
335
|
onSortingChange: ye,
|
package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
//#region ../../libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js
|
|
2
|
-
var e = "@tesouro/embedded-components-react", t = "0.5.
|
|
2
|
+
var e = "@tesouro/embedded-components-react", t = "0.5.26", n = "31105c434866639eaab7908d1eaf7754fc9dde6e", r = Object.freeze({
|
|
3
3
|
library_name: e,
|
|
4
4
|
library_version: t,
|
|
5
5
|
library_sha: n
|
|
@@ -13,8 +13,8 @@ var w = Object.defineProperty, T = (e, t) => {
|
|
|
13
13
|
enumerable: !0
|
|
14
14
|
});
|
|
15
15
|
return t || w(n, Symbol.toStringTag, { value: "Module" }), n;
|
|
16
|
-
}, E = (...e) => e.filter((e, t, n) => !!e && e.trim() !== "" && n.indexOf(e) === t).join(" ").trim(),
|
|
17
|
-
let t =
|
|
16
|
+
}, E = (...e) => e.filter((e, t, n) => !!e && e.trim() !== "" && n.indexOf(e) === t).join(" ").trim(), D = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase(), O = (e) => e.replace(/^([A-Z])|[\s-_]+(\w)/g, (e, t, n) => n ? n.toUpperCase() : t.toLowerCase()), ee = (e) => {
|
|
17
|
+
let t = O(e);
|
|
18
18
|
return t.charAt(0).toUpperCase() + t.slice(1);
|
|
19
19
|
}, k = {
|
|
20
20
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -46,10 +46,10 @@ var w = Object.defineProperty, T = (e, t) => {
|
|
|
46
46
|
let n = i(({ className: n, ...i }, a) => r(N, {
|
|
47
47
|
ref: a,
|
|
48
48
|
iconNode: t,
|
|
49
|
-
className: E(`lucide-${ee(
|
|
49
|
+
className: E(`lucide-${D(ee(e))}`, `lucide-${e}`, n),
|
|
50
50
|
...i
|
|
51
51
|
}));
|
|
52
|
-
return n.displayName =
|
|
52
|
+
return n.displayName = ee(e), n;
|
|
53
53
|
}, F = P("arrow-down", [["path", {
|
|
54
54
|
d: "M12 5v14",
|
|
55
55
|
key: "s699le"
|
|
@@ -1388,15 +1388,15 @@ var qn = Object.defineProperty, Jn = (e, t) => qn(e, "name", {
|
|
|
1388
1388
|
if (i && w.current) return;
|
|
1389
1389
|
let t = e.target;
|
|
1390
1390
|
[...d.branches].some((e) => e.contains(t)) || (s?.(e), c?.(e), e.defaultPrevented || l?.());
|
|
1391
|
-
}, m),
|
|
1391
|
+
}, m), D = f ? x === v.length - 1 : !1, O = Kn((e) => {
|
|
1392
1392
|
e.key === "Escape" && (a?.(e), !e.defaultPrevented && l && (e.preventDefault(), l()));
|
|
1393
1393
|
});
|
|
1394
1394
|
return e.useEffect(() => {
|
|
1395
|
-
if (
|
|
1395
|
+
if (D) return m.addEventListener("keydown", O, { capture: !0 }), () => m.removeEventListener("keydown", O, { capture: !0 });
|
|
1396
1396
|
}, [
|
|
1397
1397
|
m,
|
|
1398
|
-
|
|
1399
|
-
|
|
1398
|
+
D,
|
|
1399
|
+
O
|
|
1400
1400
|
]), e.useEffect(() => {
|
|
1401
1401
|
if (f) return r && (d.layersWithOutsidePointerEventsDisabled.size === 0 && (Qn = m.body.style.pointerEvents, m.body.style.pointerEvents = "none"), d.layersWithOutsidePointerEventsDisabled.add(f)), d.layers.add(f), ar(), () => {
|
|
1402
1402
|
r && (d.layersWithOutsidePointerEventsDisabled.delete(f), d.layersWithOutsidePointerEventsDisabled.size === 0 && (m.body.style.pointerEvents = Qn));
|
|
@@ -2939,7 +2939,7 @@ var os = 50, ss = async (e, t, n) => {
|
|
|
2939
2939
|
y: r
|
|
2940
2940
|
}, p = Wo(i), m = Ho(p), h = await o.getDimensions(l), g = p === "y", _ = g ? "top" : "left", v = g ? "bottom" : "right", y = g ? "clientHeight" : "clientWidth", b = a.reference[m] + a.reference[p] - f[p] - a.floating[m], x = f[p] - a.reference[p], S = await (o.getOffsetParent == null ? void 0 : o.getOffsetParent(l)), C = S ? S[y] : 0;
|
|
2941
2941
|
(!C || !await (o.isElement == null ? void 0 : o.isElement(S))) && (C = s.floating[y] || a.floating[m]);
|
|
2942
|
-
let w = b / 2 - x / 2, T = C / 2 - h[m] / 2 - 1, E = Po(d[_], T),
|
|
2942
|
+
let w = b / 2 - x / 2, T = C / 2 - h[m] / 2 - 1, E = Po(d[_], T), D = Po(d[v], T), O = E, ee = C - h[m] - D, k = C / 2 - h[m] / 2 + w, A = Lo(O, k, ee), j = !c.arrow && Bo(i) != null && k !== A && a.reference[m] / 2 - (k < O ? E : D) - h[m] / 2 < 0, M = j ? k < O ? k - O : k - ee : 0;
|
|
2943
2943
|
return {
|
|
2944
2944
|
[p]: f[p] + M,
|
|
2945
2945
|
data: {
|
|
@@ -3640,14 +3640,14 @@ function Rc(t) {
|
|
|
3640
3640
|
e !== w.current && (w.current = e, _(e));
|
|
3641
3641
|
}, []), x = e.useCallback((e) => {
|
|
3642
3642
|
e !== T.current && (T.current = e, y(e));
|
|
3643
|
-
}, []), S = o || g, C = s || v, w = e.useRef(null), T = e.useRef(null), E = e.useRef(d),
|
|
3643
|
+
}, []), S = o || g, C = s || v, w = e.useRef(null), T = e.useRef(null), E = e.useRef(d), D = l != null, O = Lc(l), ee = Lc(a), k = Lc(u), A = e.useCallback(() => {
|
|
3644
3644
|
if (!w.current || !T.current) return;
|
|
3645
3645
|
let e = {
|
|
3646
3646
|
placement: n,
|
|
3647
3647
|
strategy: r,
|
|
3648
3648
|
middleware: m
|
|
3649
3649
|
};
|
|
3650
|
-
|
|
3650
|
+
ee.current && (e.platform = ee.current), Mc(w.current, T.current, e).then((e) => {
|
|
3651
3651
|
let t = {
|
|
3652
3652
|
...e,
|
|
3653
3653
|
isPositioned: k.current !== !1
|
|
@@ -3660,7 +3660,7 @@ function Rc(t) {
|
|
|
3660
3660
|
m,
|
|
3661
3661
|
n,
|
|
3662
3662
|
r,
|
|
3663
|
-
|
|
3663
|
+
ee,
|
|
3664
3664
|
k
|
|
3665
3665
|
]);
|
|
3666
3666
|
Nc(() => {
|
|
@@ -3674,15 +3674,15 @@ function Rc(t) {
|
|
|
3674
3674
|
j.current = !1;
|
|
3675
3675
|
}), []), Nc(() => {
|
|
3676
3676
|
if (S && (w.current = S), C && (T.current = C), S && C) {
|
|
3677
|
-
if (
|
|
3677
|
+
if (O.current) return O.current(S, C, A);
|
|
3678
3678
|
A();
|
|
3679
3679
|
}
|
|
3680
3680
|
}, [
|
|
3681
3681
|
S,
|
|
3682
3682
|
C,
|
|
3683
3683
|
A,
|
|
3684
|
-
|
|
3685
|
-
|
|
3684
|
+
O,
|
|
3685
|
+
D
|
|
3686
3686
|
]);
|
|
3687
3687
|
let M = e.useMemo(() => ({
|
|
3688
3688
|
reference: w,
|
|
@@ -3837,19 +3837,19 @@ var zc = (e) => {
|
|
|
3837
3837
|
ref: l
|
|
3838
3838
|
});
|
|
3839
3839
|
}, "PopperAnchor")), al = "PopperContent", [ol, sl] = Qc(al), cl = /* @__PURE__ */ e.forwardRef(/* @__PURE__ */ Xc(function(t, n) {
|
|
3840
|
-
let { __scopePopper: r, side: i = "bottom", sideOffset: a = 0, align: o = "center", alignOffset: s = 0, arrowPadding: c = 0, avoidCollisions: l = !0, collisionBoundary: u = [], collisionPadding: d = 0, sticky: f = "partial", hideWhenDetached: p = !1, updatePositionStrategy: m = "optimized", onPlaced: h, ..._ } = t, v = tl(al, r), [y, b] = e.useState(null), x = z(n, b), [S, C] = e.useState(null), w = mo(S), T = w?.width ?? 0, E = w?.height ?? 0,
|
|
3840
|
+
let { __scopePopper: r, side: i = "bottom", sideOffset: a = 0, align: o = "center", alignOffset: s = 0, arrowPadding: c = 0, avoidCollisions: l = !0, collisionBoundary: u = [], collisionPadding: d = 0, sticky: f = "partial", hideWhenDetached: p = !1, updatePositionStrategy: m = "optimized", onPlaced: h, ..._ } = t, v = tl(al, r), [y, b] = e.useState(null), x = z(n, b), [S, C] = e.useState(null), w = mo(S), T = w?.width ?? 0, E = w?.height ?? 0, D = i + (o === "center" ? "" : "-" + o), O = typeof d == "number" ? d : {
|
|
3841
3841
|
top: 0,
|
|
3842
3842
|
right: 0,
|
|
3843
3843
|
bottom: 0,
|
|
3844
3844
|
left: 0,
|
|
3845
3845
|
...d
|
|
3846
|
-
},
|
|
3847
|
-
padding:
|
|
3848
|
-
boundary:
|
|
3846
|
+
}, ee = Array.isArray(u) ? u : [u], k = ee.length > 0, A = {
|
|
3847
|
+
padding: O,
|
|
3848
|
+
boundary: ee.filter(fl),
|
|
3849
3849
|
altBoundary: k
|
|
3850
3850
|
}, { refs: j, floatingStyles: M, placement: N, isPositioned: P, middlewareData: F } = Rc({
|
|
3851
3851
|
strategy: "fixed",
|
|
3852
|
-
placement:
|
|
3852
|
+
placement: D,
|
|
3853
3853
|
whileElementsMounted: /* @__PURE__ */ Xc((...e) => wc(...e, { animationFrame: m === "always" }), "whileElementsMounted"),
|
|
3854
3854
|
elements: { reference: v.anchor },
|
|
3855
3855
|
middleware: [
|
|
@@ -4282,20 +4282,20 @@ var tu = "Menu", [nu, ru, iu] = /* @__PURE__ */ Je(tu), [au, ou] = /* @__PURE__
|
|
|
4282
4282
|
onDismiss: () => n.onOpenChange(!1)
|
|
4283
4283
|
});
|
|
4284
4284
|
}, "MenuRootContentNonModal")), Tu = /* @__PURE__ */ ye("MenuContent.ScrollLock"), Eu = /* @__PURE__ */ e.forwardRef(/* @__PURE__ */ H(function(t, n) {
|
|
4285
|
-
let { __scopeMenu: r, loop: i = !1, trapFocus: a, onOpenAutoFocus: o, onCloseAutoFocus: s, disableOutsidePointerEvents: c, onEntryFocus: l, onEscapeKeyDown: u, onPointerDownOutside: d, onFocusOutside: f, onInteractOutside: p, onDismiss: m, disableOutsideScroll: h, ..._ } = t, v = uu(yu, r), y = fu(yu, r), b = su(r), x = cu(r), S = ru(r), [C, w] = e.useState(null), T = e.useRef(null), E = z(n, T, v.onContentChange),
|
|
4285
|
+
let { __scopeMenu: r, loop: i = !1, trapFocus: a, onOpenAutoFocus: o, onCloseAutoFocus: s, disableOutsidePointerEvents: c, onEntryFocus: l, onEscapeKeyDown: u, onPointerDownOutside: d, onFocusOutside: f, onInteractOutside: p, onDismiss: m, disableOutsideScroll: h, ..._ } = t, v = uu(yu, r), y = fu(yu, r), b = su(r), x = cu(r), S = ru(r), [C, w] = e.useState(null), T = e.useRef(null), E = z(n, T, v.onContentChange), D = e.useRef(0), O = e.useRef(""), ee = e.useRef(0), k = e.useRef(null), A = e.useRef("right"), j = e.useRef(0), M = h ? Bi : e.Fragment, N = h ? {
|
|
4286
4286
|
as: Tu,
|
|
4287
4287
|
allowPinchZoom: !0
|
|
4288
4288
|
} : void 0, P = /* @__PURE__ */ H((e) => {
|
|
4289
|
-
let t =
|
|
4289
|
+
let t = O.current + e, n = S().filter((e) => !e.disabled), r = document.activeElement, i = n.find((e) => e.ref.current === r)?.textValue, a = Ju(n.map((e) => e.textValue), t, i), o = n.find((e) => e.textValue === a)?.ref.current;
|
|
4290
4290
|
(/* @__PURE__ */ H((function e(t) {
|
|
4291
|
-
|
|
4291
|
+
O.current = t, window.clearTimeout(D.current), t !== "" && (D.current = window.setTimeout(() => e(""), 1e3));
|
|
4292
4292
|
}), "updateSearch"))(t), o && setTimeout(() => o.focus());
|
|
4293
4293
|
}, "handleTypeaheadSearch");
|
|
4294
|
-
e.useEffect(() => () => window.clearTimeout(
|
|
4294
|
+
e.useEffect(() => () => window.clearTimeout(D.current), []), jr();
|
|
4295
4295
|
let F = e.useCallback((e) => A.current === k.current?.side && Xu(e, k.current?.area), []);
|
|
4296
4296
|
return /* @__PURE__ */ g(bu, {
|
|
4297
4297
|
scope: r,
|
|
4298
|
-
searchRef:
|
|
4298
|
+
searchRef: O,
|
|
4299
4299
|
onItemEnter: e.useCallback((e) => {
|
|
4300
4300
|
F(e) && e.preventDefault();
|
|
4301
4301
|
}, [F]),
|
|
@@ -4305,7 +4305,7 @@ var tu = "Menu", [nu, ru, iu] = /* @__PURE__ */ Je(tu), [au, ou] = /* @__PURE__
|
|
|
4305
4305
|
onTriggerLeave: e.useCallback((e) => {
|
|
4306
4306
|
F(e) && e.preventDefault();
|
|
4307
4307
|
}, [F]),
|
|
4308
|
-
pointerGraceTimerRef:
|
|
4308
|
+
pointerGraceTimerRef: ee,
|
|
4309
4309
|
onPointerGraceIntentChange: e.useCallback((e) => {
|
|
4310
4310
|
k.current = e;
|
|
4311
4311
|
}, []),
|
|
@@ -4361,7 +4361,7 @@ var tu = "Menu", [nu, ru, iu] = /* @__PURE__ */ Je(tu), [au, ou] = /* @__PURE__
|
|
|
4361
4361
|
$l.includes(e.key) && a.reverse(), Ku(a);
|
|
4362
4362
|
}),
|
|
4363
4363
|
onBlur: V(t.onBlur, (e) => {
|
|
4364
|
-
e.currentTarget.contains(e.target) || (window.clearTimeout(
|
|
4364
|
+
e.currentTarget.contains(e.target) || (window.clearTimeout(D.current), O.current = "");
|
|
4365
4365
|
}),
|
|
4366
4366
|
onPointerMove: V(t.onPointerMove, Zu((e) => {
|
|
4367
4367
|
let t = e.target, n = j.current !== e.clientX;
|
|
@@ -5139,27 +5139,27 @@ var xp = /* @__PURE__ */ e.forwardRef(/* @__PURE__ */ Jf(function(t, n) {
|
|
|
5139
5139
|
"ArrowDown"
|
|
5140
5140
|
], Dp = [" ", "Enter"], Op = "Select", [kp, Ap, jp] = /* @__PURE__ */ Je(Op), [Mp, Np] = /* @__PURE__ */ We(Op, [jp, $c]), Pp = $c(), [Fp, Ip] = Mp(Op), [Lp, Rp] = Mp(Op);
|
|
5141
5141
|
function zp(t) {
|
|
5142
|
-
let { __scopeSelect: n, children: r, open: i, defaultOpen: a, onOpenChange: o, value: s, defaultValue: c, onValueChange: l, dir: u, name: d, autoComplete: f, disabled: p, required: m, form: h, internal_do_not_use_render: _ } = t, v = Pp(n), [y, b] = e.useState(null), [x, S] = e.useState(null), [C, w] = e.useState(!1), T = sn(u), [E,
|
|
5142
|
+
let { __scopeSelect: n, children: r, open: i, defaultOpen: a, onOpenChange: o, value: s, defaultValue: c, onValueChange: l, dir: u, name: d, autoComplete: f, disabled: p, required: m, form: h, internal_do_not_use_render: _ } = t, v = Pp(n), [y, b] = e.useState(null), [x, S] = e.useState(null), [C, w] = e.useState(!1), T = sn(u), [E, D] = xt({
|
|
5143
5143
|
prop: i,
|
|
5144
5144
|
defaultProp: a ?? !1,
|
|
5145
5145
|
onChange: o,
|
|
5146
5146
|
caller: Op
|
|
5147
|
-
}), [
|
|
5147
|
+
}), [O, ee] = xt({
|
|
5148
5148
|
prop: s,
|
|
5149
5149
|
defaultProp: c,
|
|
5150
5150
|
onChange: l,
|
|
5151
5151
|
caller: Op
|
|
5152
|
-
}), k = e.useRef(null), A = e.useRef(
|
|
5152
|
+
}), k = e.useRef(null), A = e.useRef(O);
|
|
5153
5153
|
e.useEffect(() => {
|
|
5154
5154
|
let e = h ? y?.ownerDocument.getElementById(h) : y?.form;
|
|
5155
5155
|
if (e instanceof HTMLFormElement) {
|
|
5156
|
-
let t = /* @__PURE__ */ U(() =>
|
|
5156
|
+
let t = /* @__PURE__ */ U(() => ee(A.current), "reset");
|
|
5157
5157
|
return e.addEventListener("reset", t), () => e.removeEventListener("reset", t);
|
|
5158
5158
|
}
|
|
5159
5159
|
}, [
|
|
5160
5160
|
h,
|
|
5161
5161
|
y,
|
|
5162
|
-
|
|
5162
|
+
ee
|
|
5163
5163
|
]);
|
|
5164
5164
|
let j = !y || !!h || !!y.closest("form"), [M, N] = e.useState(/* @__PURE__ */ new Set()), P = zt(), F = Array.from(M).map((e) => e.props.value).join(";"), te = e.useCallback((e) => {
|
|
5165
5165
|
N((t) => new Set(t).add(e));
|
|
@@ -5177,10 +5177,10 @@ function zp(t) {
|
|
|
5177
5177
|
valueNodeHasChildren: C,
|
|
5178
5178
|
onValueNodeHasChildrenChange: w,
|
|
5179
5179
|
contentId: P,
|
|
5180
|
-
value:
|
|
5181
|
-
onValueChange:
|
|
5180
|
+
value: O,
|
|
5181
|
+
onValueChange: ee,
|
|
5182
5182
|
open: E,
|
|
5183
|
-
onOpenChange:
|
|
5183
|
+
onOpenChange: D,
|
|
5184
5184
|
dir: T,
|
|
5185
5185
|
triggerPointerDownPosRef: k,
|
|
5186
5186
|
disabled: p,
|
|
@@ -5315,7 +5315,7 @@ var Bp = /* @__PURE__ */ U((e) => {
|
|
|
5315
5315
|
})
|
|
5316
5316
|
}), i) : null;
|
|
5317
5317
|
}, "SelectContentFragment")), Qp = 10, [$p, em] = Mp(Yp), tm = /* @__PURE__ */ ye("SelectContent.RemoveScroll"), nm = /* @__PURE__ */ e.forwardRef(/* @__PURE__ */ U(function(t, n) {
|
|
5318
|
-
let { __scopeSelect: r } = t, { position: i = "item-aligned", onCloseAutoFocus: a, onEscapeKeyDown: o, onPointerDownOutside: s, side: c, sideOffset: l, align: u, alignOffset: d, arrowPadding: f, collisionBoundary: p, collisionPadding: m, sticky: h, hideWhenDetached: _, avoidCollisions: v, ...y } = t, b = Ip(Yp, r), [x, S] = e.useState(null), [C, w] = e.useState(null), T = z(n, S), [E,
|
|
5318
|
+
let { __scopeSelect: r } = t, { position: i = "item-aligned", onCloseAutoFocus: a, onEscapeKeyDown: o, onPointerDownOutside: s, side: c, sideOffset: l, align: u, alignOffset: d, arrowPadding: f, collisionBoundary: p, collisionPadding: m, sticky: h, hideWhenDetached: _, avoidCollisions: v, ...y } = t, b = Ip(Yp, r), [x, S] = e.useState(null), [C, w] = e.useState(null), T = z(n, S), [E, D] = e.useState(null), [O, ee] = e.useState(null), k = Ap(r), [A, j] = e.useState(!1), M = e.useRef(!1);
|
|
5319
5319
|
e.useEffect(() => {
|
|
5320
5320
|
if (x) return Yi(x);
|
|
5321
5321
|
}, [x]), jr();
|
|
@@ -5366,10 +5366,10 @@ var Bp = /* @__PURE__ */ U((e) => {
|
|
|
5366
5366
|
n && setTimeout(() => n.ref.current?.focus());
|
|
5367
5367
|
}), ie = e.useCallback((e, t, n) => {
|
|
5368
5368
|
let r = !M.current && !n;
|
|
5369
|
-
(b.value !== void 0 && b.value === t || r) && (
|
|
5369
|
+
(b.value !== void 0 && b.value === t || r) && (D(e), r && (M.current = !0));
|
|
5370
5370
|
}, [b.value]), I = e.useCallback(() => x?.focus(), [x]), L = e.useCallback((e, t, n) => {
|
|
5371
5371
|
let r = !M.current && !n;
|
|
5372
|
-
(b.value !== void 0 && b.value === t || r) &&
|
|
5372
|
+
(b.value !== void 0 && b.value === t || r) && ee(e);
|
|
5373
5373
|
}, [b.value]), ae = i === "popper" ? im : rm, oe = ae === im ? {
|
|
5374
5374
|
side: c,
|
|
5375
5375
|
sideOffset: l,
|
|
@@ -5392,7 +5392,7 @@ var Bp = /* @__PURE__ */ U((e) => {
|
|
|
5392
5392
|
onItemLeave: I,
|
|
5393
5393
|
itemTextRefCallback: L,
|
|
5394
5394
|
focusSelectedItem: P,
|
|
5395
|
-
selectedItemText:
|
|
5395
|
+
selectedItemText: O,
|
|
5396
5396
|
position: i,
|
|
5397
5397
|
isPositioned: A,
|
|
5398
5398
|
searchRef: ne,
|
|
@@ -5463,16 +5463,16 @@ var Bp = /* @__PURE__ */ U((e) => {
|
|
|
5463
5463
|
let i = t.right - r.right, a = window.innerWidth - n.right - i, o = window.innerWidth - e.right - a, s = e.width + o, l = Math.max(s, t.width), u = window.innerWidth - Qp, d = _f(a, [Qp, Math.max(Qp, u - l)]);
|
|
5464
5464
|
c.style.minWidth = s + "px", c.style.right = d + "px";
|
|
5465
5465
|
}
|
|
5466
|
-
let a = p(), s = window.innerHeight - Qp * 2, l = _.scrollHeight, d = window.getComputedStyle(u), f = parseInt(d.borderTopWidth, 10), h = parseInt(d.paddingTop, 10), g = parseInt(d.borderBottomWidth, 10), b = parseInt(d.paddingBottom, 10), x = f + h + l + b + g, S = Math.min(v.offsetHeight * 5, x), C = window.getComputedStyle(_), w = parseInt(C.paddingTop, 10), T = parseInt(C.paddingBottom, 10), E = e.top + e.height / 2 - Qp,
|
|
5466
|
+
let a = p(), s = window.innerHeight - Qp * 2, l = _.scrollHeight, d = window.getComputedStyle(u), f = parseInt(d.borderTopWidth, 10), h = parseInt(d.paddingTop, 10), g = parseInt(d.borderBottomWidth, 10), b = parseInt(d.paddingBottom, 10), x = f + h + l + b + g, S = Math.min(v.offsetHeight * 5, x), C = window.getComputedStyle(_), w = parseInt(C.paddingTop, 10), T = parseInt(C.paddingBottom, 10), E = e.top + e.height / 2 - Qp, D = s - E, O = v.offsetHeight / 2, ee = v.offsetTop + O, k = f + h + ee, A = x - k;
|
|
5467
5467
|
if (k <= E) {
|
|
5468
5468
|
let e = a.length > 0 && v === a[a.length - 1].ref.current;
|
|
5469
5469
|
c.style.bottom = "0px";
|
|
5470
|
-
let t = u.clientHeight - _.offsetTop - _.offsetHeight, n = k + Math.max(
|
|
5470
|
+
let t = u.clientHeight - _.offsetTop - _.offsetHeight, n = k + Math.max(D, O + (e ? T : 0) + t + g);
|
|
5471
5471
|
c.style.height = n + "px";
|
|
5472
5472
|
} else {
|
|
5473
5473
|
let e = a.length > 0 && v === a[0].ref.current;
|
|
5474
5474
|
c.style.top = "0px";
|
|
5475
|
-
let t = Math.max(E, f + _.offsetTop + (e ? w : 0) +
|
|
5475
|
+
let t = Math.max(E, f + _.offsetTop + (e ? w : 0) + O) + A;
|
|
5476
5476
|
c.style.height = t + "px", _.scrollTop = k - E + _.offsetTop;
|
|
5477
5477
|
}
|
|
5478
5478
|
c.style.margin = `${Qp}px 0`, c.style.minHeight = S + "px", c.style.maxHeight = s + "px", i?.(), requestAnimationFrame(() => m.current = !0);
|
|
@@ -6109,12 +6109,12 @@ var xh = fh, Sh = mh, Ch = gh, wh = vh, Th = Object.defineProperty, Eh = (e, t)
|
|
|
6109
6109
|
e.useEffect(() => () => {
|
|
6110
6110
|
_.current &&= (window.clearTimeout(_.current), 0);
|
|
6111
6111
|
}, []);
|
|
6112
|
-
let
|
|
6112
|
+
let D = p ?? h;
|
|
6113
6113
|
return /* @__PURE__ */ g(hl, {
|
|
6114
6114
|
...u,
|
|
6115
6115
|
children: /* @__PURE__ */ g(Lh, {
|
|
6116
6116
|
scope: n,
|
|
6117
|
-
contentId:
|
|
6117
|
+
contentId: D,
|
|
6118
6118
|
setContentId: m,
|
|
6119
6119
|
open: x,
|
|
6120
6120
|
stateAttribute: C,
|
|
@@ -6701,7 +6701,7 @@ var fg = (e, t) => {
|
|
|
6701
6701
|
"subgrid",
|
|
6702
6702
|
K,
|
|
6703
6703
|
G
|
|
6704
|
-
],
|
|
6704
|
+
], D = () => [
|
|
6705
6705
|
"auto",
|
|
6706
6706
|
{ span: [
|
|
6707
6707
|
"full",
|
|
@@ -6712,12 +6712,12 @@ var fg = (e, t) => {
|
|
|
6712
6712
|
t_,
|
|
6713
6713
|
K,
|
|
6714
6714
|
G
|
|
6715
|
-
],
|
|
6715
|
+
], O = () => [
|
|
6716
6716
|
t_,
|
|
6717
6717
|
"auto",
|
|
6718
6718
|
K,
|
|
6719
6719
|
G
|
|
6720
|
-
],
|
|
6720
|
+
], ee = () => [
|
|
6721
6721
|
"auto",
|
|
6722
6722
|
"min",
|
|
6723
6723
|
"max",
|
|
@@ -7102,13 +7102,13 @@ var fg = (e, t) => {
|
|
|
7102
7102
|
G
|
|
7103
7103
|
] }],
|
|
7104
7104
|
"grid-cols": [{ "grid-cols": E() }],
|
|
7105
|
-
"col-start-end": [{ col:
|
|
7106
|
-
"col-start": [{ "col-start":
|
|
7107
|
-
"col-end": [{ "col-end":
|
|
7105
|
+
"col-start-end": [{ col: D() }],
|
|
7106
|
+
"col-start": [{ "col-start": O() }],
|
|
7107
|
+
"col-end": [{ "col-end": O() }],
|
|
7108
7108
|
"grid-rows": [{ "grid-rows": E() }],
|
|
7109
|
-
"row-start-end": [{ row:
|
|
7110
|
-
"row-start": [{ "row-start":
|
|
7111
|
-
"row-end": [{ "row-end":
|
|
7109
|
+
"row-start-end": [{ row: D() }],
|
|
7110
|
+
"row-start": [{ "row-start": O() }],
|
|
7111
|
+
"row-end": [{ "row-end": O() }],
|
|
7112
7112
|
"grid-flow": [{ "grid-flow": [
|
|
7113
7113
|
"row",
|
|
7114
7114
|
"col",
|
|
@@ -7116,8 +7116,8 @@ var fg = (e, t) => {
|
|
|
7116
7116
|
"row-dense",
|
|
7117
7117
|
"col-dense"
|
|
7118
7118
|
] }],
|
|
7119
|
-
"auto-cols": [{ "auto-cols":
|
|
7120
|
-
"auto-rows": [{ "auto-rows":
|
|
7119
|
+
"auto-cols": [{ "auto-cols": ee() }],
|
|
7120
|
+
"auto-rows": [{ "auto-rows": ee() }],
|
|
7121
7121
|
gap: [{ gap: w() }],
|
|
7122
7122
|
"gap-x": [{ "gap-x": w() }],
|
|
7123
7123
|
"gap-y": [{ "gap-y": w() }],
|
|
@@ -8462,13 +8462,13 @@ function jv({ items: t, value: n, onValueChange: r, multiple: i = !1, disabled:
|
|
|
8462
8462
|
let h = {
|
|
8463
8463
|
...Dv,
|
|
8464
8464
|
...d
|
|
8465
|
-
}, v = e.useRef(null), y = e.useRef(null), b = e.useRef(null), [x, S] = e.useState(!1), [C, w] = e.useState(""), [T, E] = e.useState(0),
|
|
8465
|
+
}, v = e.useRef(null), y = e.useRef(null), b = e.useRef(null), [x, S] = e.useState(!1), [C, w] = e.useState(""), [T, E] = e.useState(0), D = e.useRef(u);
|
|
8466
8466
|
e.useEffect(() => {
|
|
8467
|
-
|
|
8467
|
+
D.current = u;
|
|
8468
8468
|
});
|
|
8469
|
-
let
|
|
8470
|
-
w(e),
|
|
8471
|
-
}, []),
|
|
8469
|
+
let O = e.useCallback((e) => {
|
|
8470
|
+
w(e), D.current?.(e);
|
|
8471
|
+
}, []), ee = e.useRef(null), k = ov(), [A, j] = e.useState(null);
|
|
8472
8472
|
e.useEffect(() => {
|
|
8473
8473
|
if (!x) {
|
|
8474
8474
|
j(null);
|
|
@@ -8514,7 +8514,7 @@ function jv({ items: t, value: n, onValueChange: r, multiple: i = !1, disabled:
|
|
|
8514
8514
|
let e = (e) => {
|
|
8515
8515
|
if (!v.current) return;
|
|
8516
8516
|
let t = e.target;
|
|
8517
|
-
t instanceof Node && !v.current.contains(t) && !
|
|
8517
|
+
t instanceof Node && !v.current.contains(t) && !ee.current?.contains(t) && (S(!1), O(""));
|
|
8518
8518
|
};
|
|
8519
8519
|
return document.addEventListener("mousedown", e), () => {
|
|
8520
8520
|
document.removeEventListener("mousedown", e);
|
|
@@ -8523,10 +8523,10 @@ function jv({ items: t, value: n, onValueChange: r, multiple: i = !1, disabled:
|
|
|
8523
8523
|
let te = (e) => {
|
|
8524
8524
|
if (!a) {
|
|
8525
8525
|
if (i) {
|
|
8526
|
-
M.includes(e) ? r(M.filter((t) => t !== e)) : r([...M, e]),
|
|
8526
|
+
M.includes(e) ? r(M.filter((t) => t !== e)) : r([...M, e]), O(""), y.current?.focus();
|
|
8527
8527
|
return;
|
|
8528
8528
|
}
|
|
8529
|
-
r(e),
|
|
8529
|
+
r(e), O(""), S(!1);
|
|
8530
8530
|
}
|
|
8531
8531
|
}, ne = (e) => {
|
|
8532
8532
|
if (!a) {
|
|
@@ -8555,7 +8555,7 @@ function jv({ items: t, value: n, onValueChange: r, multiple: i = !1, disabled:
|
|
|
8555
8555
|
T >= 0 && t && te(kv(t));
|
|
8556
8556
|
return;
|
|
8557
8557
|
}
|
|
8558
|
-
e.key === "Escape" && (S(!1),
|
|
8558
|
+
e.key === "Escape" && (S(!1), O(""));
|
|
8559
8559
|
}
|
|
8560
8560
|
};
|
|
8561
8561
|
return /* @__PURE__ */ _("div", {
|
|
@@ -8565,7 +8565,7 @@ function jv({ items: t, value: n, onValueChange: r, multiple: i = !1, disabled:
|
|
|
8565
8565
|
children: [/* @__PURE__ */ _("div", {
|
|
8566
8566
|
className: q("ttw:flex ttw:min-h-9 ttw:w-full ttw:flex-wrap ttw:items-center ttw:gap-1.5 ttw:rounded-md ttw:border ttw:border-input ttw:bg-transparent ttw:px-2.5 ttw:py-1.5 ttw:text-sm ttw:shadow-xs", a ? "ttw:cursor-not-allowed ttw:opacity-60" : "ttw:focus-within:border-ring ttw:focus-within:ring-[3px] ttw:focus-within:ring-ring/50"),
|
|
8567
8567
|
onClick: () => {
|
|
8568
|
-
a || (x ||
|
|
8568
|
+
a || (x || O(""), S(!0), y.current?.focus());
|
|
8569
8569
|
},
|
|
8570
8570
|
children: [
|
|
8571
8571
|
i ? M.map((e) => /* @__PURE__ */ _("span", {
|
|
@@ -8595,15 +8595,15 @@ function jv({ items: t, value: n, onValueChange: r, multiple: i = !1, disabled:
|
|
|
8595
8595
|
placeholder: h.placeholder,
|
|
8596
8596
|
className: "ttw:min-w-16 ttw:flex-1 ttw:bg-transparent ttw:outline-none",
|
|
8597
8597
|
onFocus: () => {
|
|
8598
|
-
a || (x ||
|
|
8598
|
+
a || (x || O(""), S(!0));
|
|
8599
8599
|
},
|
|
8600
8600
|
onChange: (e) => {
|
|
8601
8601
|
if (!x) {
|
|
8602
8602
|
let t = e.nativeEvent.data ?? "";
|
|
8603
|
-
|
|
8603
|
+
O(t), S(!0);
|
|
8604
8604
|
return;
|
|
8605
8605
|
}
|
|
8606
|
-
|
|
8606
|
+
O(e.target.value), S(!0);
|
|
8607
8607
|
},
|
|
8608
8608
|
onKeyDown: re
|
|
8609
8609
|
}),
|
|
@@ -8612,13 +8612,13 @@ function jv({ items: t, value: n, onValueChange: r, multiple: i = !1, disabled:
|
|
|
8612
8612
|
"aria-label": h.clearAriaLabel,
|
|
8613
8613
|
className: "ttw:inline-flex ttw:size-4 ttw:shrink-0 ttw:cursor-pointer ttw:items-center ttw:justify-center ttw:rounded-sm ttw:opacity-60 ttw:hover:opacity-100",
|
|
8614
8614
|
onClick: (e) => {
|
|
8615
|
-
e.stopPropagation(), ne(M[0]),
|
|
8615
|
+
e.stopPropagation(), ne(M[0]), O("");
|
|
8616
8616
|
},
|
|
8617
8617
|
children: /* @__PURE__ */ g(fe, { className: "ttw:size-3" })
|
|
8618
8618
|
}) : null
|
|
8619
8619
|
]
|
|
8620
8620
|
}), x && A ? m(/* @__PURE__ */ g("div", {
|
|
8621
|
-
ref:
|
|
8621
|
+
ref: ee,
|
|
8622
8622
|
style: {
|
|
8623
8623
|
position: "fixed",
|
|
8624
8624
|
top: A.top + 6,
|
|
@@ -8879,13 +8879,14 @@ function ny({ className: e, ...t }) {
|
|
|
8879
8879
|
});
|
|
8880
8880
|
}
|
|
8881
8881
|
var ry = 52, iy = 40, ay = "60vh";
|
|
8882
|
-
function oy({ columns: t, data: n, sorting: r, onSortingChange: i, pageSize: a, onPageSizeChange: o, hasNextPage: s, hasPrevPage: c, onNextPage: l, onPrevPage: u, labels: d, pageInfo: f, filterComponent: p, showColumnVisibility: m = !1, showSelectedRowsInfo: S = !1, onRowClick: C, rowClassName: w, children: T, className: E, pageSizeOptions:
|
|
8883
|
-
let
|
|
8882
|
+
function oy({ columns: t, data: n, sorting: r, onSortingChange: i, pageSize: a, onPageSizeChange: o, hasNextPage: s, hasPrevPage: c, onNextPage: l, onPrevPage: u, labels: d, pageInfo: f, filterComponent: p, showColumnVisibility: m = !1, showSelectedRowsInfo: S = !1, onRowClick: C, rowClassName: w, children: T, className: E, pageSizeOptions: D, isLoading: O = !1, getRowId: ee, animatesNewRows: k = !1 }) {
|
|
8883
|
+
let A = {
|
|
8884
8884
|
...Nv,
|
|
8885
8885
|
...d
|
|
8886
|
-
}, [
|
|
8886
|
+
}, [j, M] = e.useState([]), [N, P] = e.useState({}), [F, te] = e.useState({}), ne = x({
|
|
8887
8887
|
data: n,
|
|
8888
8888
|
columns: t,
|
|
8889
|
+
getRowId: ee,
|
|
8889
8890
|
getCoreRowModel: y(),
|
|
8890
8891
|
getFilteredRowModel: b(),
|
|
8891
8892
|
manualPagination: !0,
|
|
@@ -8893,18 +8894,18 @@ function oy({ columns: t, data: n, sorting: r, onSortingChange: i, pageSize: a,
|
|
|
8893
8894
|
enableMultiSort: !1,
|
|
8894
8895
|
defaultColumn: { enableSorting: !1 },
|
|
8895
8896
|
onSortingChange: i,
|
|
8896
|
-
onColumnFiltersChange:
|
|
8897
|
-
onColumnVisibilityChange:
|
|
8898
|
-
onRowSelectionChange:
|
|
8897
|
+
onColumnFiltersChange: M,
|
|
8898
|
+
onColumnVisibilityChange: P,
|
|
8899
|
+
onRowSelectionChange: te,
|
|
8899
8900
|
state: {
|
|
8900
8901
|
sorting: r,
|
|
8901
8902
|
pagination: {
|
|
8902
8903
|
pageIndex: 0,
|
|
8903
8904
|
pageSize: a
|
|
8904
8905
|
},
|
|
8905
|
-
columnFilters:
|
|
8906
|
-
columnVisibility:
|
|
8907
|
-
rowSelection:
|
|
8906
|
+
columnFilters: j,
|
|
8907
|
+
columnVisibility: N,
|
|
8908
|
+
rowSelection: F
|
|
8908
8909
|
}
|
|
8909
8910
|
});
|
|
8910
8911
|
return /* @__PURE__ */ _(h, { children: [/* @__PURE__ */ _("div", {
|
|
@@ -8920,14 +8921,14 @@ function oy({ columns: t, data: n, sorting: r, onSortingChange: i, pageSize: a,
|
|
|
8920
8921
|
variant: "outline",
|
|
8921
8922
|
className: "ttw:ml-auto",
|
|
8922
8923
|
children: [
|
|
8923
|
-
|
|
8924
|
+
A.columns,
|
|
8924
8925
|
" ",
|
|
8925
8926
|
/* @__PURE__ */ g(I, {})
|
|
8926
8927
|
]
|
|
8927
8928
|
})
|
|
8928
8929
|
}), /* @__PURE__ */ g(Iv, {
|
|
8929
8930
|
align: "end",
|
|
8930
|
-
children:
|
|
8931
|
+
children: ne.getAllColumns().filter((e) => e.getCanHide()).map((e) => /* @__PURE__ */ g(zv, {
|
|
8931
8932
|
className: "ttw:capitalize",
|
|
8932
8933
|
checked: e.getIsVisible(),
|
|
8933
8934
|
onCheckedChange: (t) => e.toggleVisibility(!!t),
|
|
@@ -8939,7 +8940,7 @@ function oy({ columns: t, data: n, sorting: r, onSortingChange: i, pageSize: a,
|
|
|
8939
8940
|
className: "ttw:border-none",
|
|
8940
8941
|
containerClassName: "ttw:overflow-y-auto",
|
|
8941
8942
|
containerStyle: { height: `min(${iy + a * ry}px, ${ay})` },
|
|
8942
|
-
children: [/* @__PURE__ */ g(Qv, { children:
|
|
8943
|
+
children: [/* @__PURE__ */ g(Qv, { children: ne.getHeaderGroups().map((e) => /* @__PURE__ */ g(ey, { children: e.headers.map((e) => /* @__PURE__ */ g(ty, {
|
|
8943
8944
|
"aria-sort": e.column.getCanSort() ? cy(e.column.getIsSorted()) : void 0,
|
|
8944
8945
|
className: "ttw:sticky ttw:top-0 ttw:z-10 ttw:bg-card ttw:p-3 ttw:text-xs ttw:text-zinc-950 ttw:border-b ttw:border-zinc-100",
|
|
8945
8946
|
style: {
|
|
@@ -8950,12 +8951,12 @@ function oy({ columns: t, data: n, sorting: r, onSortingChange: i, pageSize: a,
|
|
|
8950
8951
|
...e.column.columnDef.minSize !== void 0 && { minWidth: e.column.columnDef.minSize }
|
|
8951
8952
|
},
|
|
8952
8953
|
children: e.isPlaceholder ? null : v(e.column.columnDef.header, e.getContext())
|
|
8953
|
-
}, e.id)) }, e.id)) }), /* @__PURE__ */ g($v, { children:
|
|
8954
|
+
}, e.id)) }, e.id)) }), /* @__PURE__ */ g($v, { children: O ? Array.from({ length: a }).map((e, n) => /* @__PURE__ */ g(ey, { children: t.map((e, t) => /* @__PURE__ */ g(ny, {
|
|
8954
8955
|
className: "ttw:px-3 ttw:h-13 ttw:border-zinc-100 ttw:border-b",
|
|
8955
8956
|
children: /* @__PURE__ */ g(Sv, { className: "ttw:h-4 ttw:w-full" })
|
|
8956
|
-
}, t)) }, `skeleton-${n}`)) :
|
|
8957
|
+
}, t)) }, `skeleton-${n}`)) : ne.getRowModel().rows?.length ? ne.getRowModel().rows.map((e) => /* @__PURE__ */ g(ey, {
|
|
8957
8958
|
"data-state": e.getIsSelected() ? "selected" : void 0,
|
|
8958
|
-
className: q(C && "ttw:cursor-pointer", w?.(e.original)),
|
|
8959
|
+
className: q(C && "ttw:cursor-pointer", k && "ttw:animate-in ttw:fade-in-0 ttw:slide-in-from-top-1 ttw:duration-300", w?.(e.original)),
|
|
8959
8960
|
onClick: () => C?.(e.original),
|
|
8960
8961
|
children: e.getVisibleCells().map((e) => /* @__PURE__ */ g(ny, {
|
|
8961
8962
|
className: "ttw:px-3 ttw:h-13 ttw:font-medium ttw:border-zinc-100 ttw:border-b",
|
|
@@ -8973,7 +8974,7 @@ function oy({ columns: t, data: n, sorting: r, onSortingChange: i, pageSize: a,
|
|
|
8973
8974
|
className: "ttw:p-0",
|
|
8974
8975
|
children: /* @__PURE__ */ g("div", {
|
|
8975
8976
|
className: "ttw:flex ttw:min-h-64 ttw:items-center ttw:justify-center ttw:text-center",
|
|
8976
|
-
children: T ||
|
|
8977
|
+
children: T || A.noResults
|
|
8977
8978
|
})
|
|
8978
8979
|
}) }) })]
|
|
8979
8980
|
})
|
|
@@ -8983,14 +8984,14 @@ function oy({ columns: t, data: n, sorting: r, onSortingChange: i, pageSize: a,
|
|
|
8983
8984
|
children: [
|
|
8984
8985
|
S && /* @__PURE__ */ g("div", {
|
|
8985
8986
|
className: "ttw:text-sm ttw:leading-5 ttw:font-medium ttw:text-zinc-950",
|
|
8986
|
-
children: Mv(
|
|
8987
|
-
selected:
|
|
8988
|
-
total:
|
|
8987
|
+
children: Mv(A.selectedRows, {
|
|
8988
|
+
selected: ne.getFilteredSelectedRowModel().rows.length,
|
|
8989
|
+
total: ne.getFilteredRowModel().rows.length
|
|
8989
8990
|
})
|
|
8990
8991
|
}),
|
|
8991
8992
|
/* @__PURE__ */ _("span", {
|
|
8992
8993
|
className: "ttw:flex ttw:items-center ttw:gap-2 ttw:text-sm ttw:leading-5 ttw:font-medium ttw:text-zinc-950",
|
|
8993
|
-
children: [
|
|
8994
|
+
children: [A.rowsPerPage, /* @__PURE__ */ _(Hv, {
|
|
8994
8995
|
value: String(a),
|
|
8995
8996
|
onValueChange: (e) => {
|
|
8996
8997
|
o(Number(e));
|
|
@@ -8998,7 +8999,7 @@ function oy({ columns: t, data: n, sorting: r, onSortingChange: i, pageSize: a,
|
|
|
8998
8999
|
children: [/* @__PURE__ */ g(Gv, {
|
|
8999
9000
|
size: "sm",
|
|
9000
9001
|
children: /* @__PURE__ */ g(Wv, {})
|
|
9001
|
-
}), /* @__PURE__ */ g(Kv, { children:
|
|
9002
|
+
}), /* @__PURE__ */ g(Kv, { children: D.map((e) => /* @__PURE__ */ g(Jv, {
|
|
9002
9003
|
value: String(e),
|
|
9003
9004
|
children: e
|
|
9004
9005
|
}, e)) })]
|
|
@@ -9012,14 +9013,14 @@ function oy({ columns: t, data: n, sorting: r, onSortingChange: i, pageSize: a,
|
|
|
9012
9013
|
className: "ttw:flex ttw:items-center ttw:space-x-3",
|
|
9013
9014
|
children: [/* @__PURE__ */ g(rv, {
|
|
9014
9015
|
variant: "ghost",
|
|
9015
|
-
"aria-label":
|
|
9016
|
+
"aria-label": A.previousPage,
|
|
9016
9017
|
className: "ttw:px-2 ttw:py-2 ttw:border ttw:border-zinc-200 ttw:rounded-lg",
|
|
9017
9018
|
onClick: u,
|
|
9018
9019
|
disabled: !c,
|
|
9019
9020
|
children: /* @__PURE__ */ g(L, {})
|
|
9020
9021
|
}), /* @__PURE__ */ g(rv, {
|
|
9021
9022
|
variant: "ghost",
|
|
9022
|
-
"aria-label":
|
|
9023
|
+
"aria-label": A.nextPage,
|
|
9023
9024
|
className: "ttw:px-2 ttw:py-2 ttw:border ttw:border-zinc-200 ttw:rounded-lg",
|
|
9024
9025
|
onClick: l,
|
|
9025
9026
|
disabled: !s,
|
|
@@ -10151,7 +10152,7 @@ var Cb = Sb(), wb = (e) => {
|
|
|
10151
10152
|
"subgrid",
|
|
10152
10153
|
X,
|
|
10153
10154
|
Y
|
|
10154
|
-
],
|
|
10155
|
+
], D = () => [
|
|
10155
10156
|
"auto",
|
|
10156
10157
|
{ span: [
|
|
10157
10158
|
"full",
|
|
@@ -10162,12 +10163,12 @@ var Cb = Sb(), wb = (e) => {
|
|
|
10162
10163
|
Yx,
|
|
10163
10164
|
X,
|
|
10164
10165
|
Y
|
|
10165
|
-
],
|
|
10166
|
+
], O = () => [
|
|
10166
10167
|
Yx,
|
|
10167
10168
|
"auto",
|
|
10168
10169
|
X,
|
|
10169
10170
|
Y
|
|
10170
|
-
],
|
|
10171
|
+
], ee = () => [
|
|
10171
10172
|
"auto",
|
|
10172
10173
|
"min",
|
|
10173
10174
|
"max",
|
|
@@ -10551,13 +10552,13 @@ var Cb = Sb(), wb = (e) => {
|
|
|
10551
10552
|
Y
|
|
10552
10553
|
] }],
|
|
10553
10554
|
"grid-cols": [{ "grid-cols": E() }],
|
|
10554
|
-
"col-start-end": [{ col:
|
|
10555
|
-
"col-start": [{ "col-start":
|
|
10556
|
-
"col-end": [{ "col-end":
|
|
10555
|
+
"col-start-end": [{ col: D() }],
|
|
10556
|
+
"col-start": [{ "col-start": O() }],
|
|
10557
|
+
"col-end": [{ "col-end": O() }],
|
|
10557
10558
|
"grid-rows": [{ "grid-rows": E() }],
|
|
10558
|
-
"row-start-end": [{ row:
|
|
10559
|
-
"row-start": [{ "row-start":
|
|
10560
|
-
"row-end": [{ "row-end":
|
|
10559
|
+
"row-start-end": [{ row: D() }],
|
|
10560
|
+
"row-start": [{ "row-start": O() }],
|
|
10561
|
+
"row-end": [{ "row-end": O() }],
|
|
10561
10562
|
"grid-flow": [{ "grid-flow": [
|
|
10562
10563
|
"row",
|
|
10563
10564
|
"col",
|
|
@@ -10565,8 +10566,8 @@ var Cb = Sb(), wb = (e) => {
|
|
|
10565
10566
|
"row-dense",
|
|
10566
10567
|
"col-dense"
|
|
10567
10568
|
] }],
|
|
10568
|
-
"auto-cols": [{ "auto-cols":
|
|
10569
|
-
"auto-rows": [{ "auto-rows":
|
|
10569
|
+
"auto-cols": [{ "auto-cols": ee() }],
|
|
10570
|
+
"auto-rows": [{ "auto-rows": ee() }],
|
|
10570
10571
|
gap: [{ gap: w() }],
|
|
10571
10572
|
"gap-x": [{ "gap-x": w() }],
|
|
10572
10573
|
"gap-y": [{ "gap-y": w() }],
|
|
@@ -14204,7 +14205,7 @@ function pD(e) {
|
|
|
14204
14205
|
...n,
|
|
14205
14206
|
today: c.today()
|
|
14206
14207
|
});
|
|
14207
|
-
let { captionLayout: p, mode: m, navLayout: h, numberOfMonths: g = 1, onDayBlur: _, onDayClick: v, onDayFocus: y, onDayKeyDown: b, onDayMouseEnter: x, onDayMouseLeave: S, onNextClick: C, onPrevClick: w, showWeekNumber: T, styles: E } = n, { formatCaption:
|
|
14208
|
+
let { captionLayout: p, mode: m, navLayout: h, numberOfMonths: g = 1, onDayBlur: _, onDayClick: v, onDayFocus: y, onDayKeyDown: b, onDayMouseEnter: x, onDayMouseLeave: S, onNextClick: C, onPrevClick: w, showWeekNumber: T, styles: E } = n, { formatCaption: D, formatDay: O, formatMonthDropdown: ee, formatWeekNumber: k, formatWeekNumberHeader: A, formatWeekdayName: j, formatYearDropdown: M } = o, N = JE(n, c), { days: P, months: F, navStart: te, navEnd: ne, previousMonth: re, nextMonth: ie, goToMonth: I } = N, L = KT(P, n, te, ne, c), { isSelected: ae, select: oe, selected: R } = cD(n, c) ?? {}, { blur: se, focused: ce, isFocusTarget: le, moveFocus: ue, setFocused: de } = eD(n, N, L, ae ?? (() => !1), c), { labelDayButton: fe, labelGridcell: pe, labelGrid: me, labelMonthDropdown: he, labelNav: ge, labelPrevious: z, labelNext: _e, labelWeekday: ve, labelWeekNumber: ye, labelWeekNumberHeader: be, labelYearDropdown: xe } = s, Se = l(() => DE(c, n.ISOWeek, n.broadcastCalendar, n.today), [
|
|
14208
14209
|
c,
|
|
14209
14210
|
n.ISOWeek,
|
|
14210
14211
|
n.broadcastCalendar,
|
|
@@ -14361,7 +14362,7 @@ function pD(e) {
|
|
|
14361
14362
|
options: TE(e.date, te, ne, o, c),
|
|
14362
14363
|
style: E?.[$.Dropdown],
|
|
14363
14364
|
value: c.getMonth(e.date)
|
|
14364
|
-
}) : t.createElement("span", { key: "month" },
|
|
14365
|
+
}) : t.createElement("span", { key: "month" }, ee(e.date, c)), a = p === "dropdown" || p === "dropdown-years" ? t.createElement(i.YearsDropdown, {
|
|
14365
14366
|
key: "year",
|
|
14366
14367
|
className: f[$.YearsDropdown],
|
|
14367
14368
|
"aria-label": xe(c.options),
|
|
@@ -14389,11 +14390,11 @@ function pD(e) {
|
|
|
14389
14390
|
whiteSpace: "nowrap",
|
|
14390
14391
|
wordWrap: "normal"
|
|
14391
14392
|
}
|
|
14392
|
-
},
|
|
14393
|
+
}, D(e.date, c.options, c))) : t.createElement(i.CaptionLabel, {
|
|
14393
14394
|
className: f[$.CaptionLabel],
|
|
14394
14395
|
role: "status",
|
|
14395
14396
|
"aria-live": "polite"
|
|
14396
|
-
},
|
|
14397
|
+
}, D(e.date, c.options, c))), h === "around" && !n.hideNavigation && r === g - 1 && t.createElement(i.NextMonthButton, {
|
|
14397
14398
|
type: "button",
|
|
14398
14399
|
className: f[$.NextMonthButton],
|
|
14399
14400
|
tabIndex: ie ? void 0 : -1,
|
|
@@ -14491,7 +14492,7 @@ function pD(e) {
|
|
|
14491
14492
|
onKeyDown: ke(e, a),
|
|
14492
14493
|
onMouseEnter: Ae(e, a),
|
|
14493
14494
|
onMouseLeave: je(e, a)
|
|
14494
|
-
},
|
|
14495
|
+
}, O(r, c.options, c)) : !a.hidden && O(e.date, c.options, c));
|
|
14495
14496
|
})))))))), n.footer && t.createElement(i.Footer, {
|
|
14496
14497
|
className: f[$.Footer],
|
|
14497
14498
|
style: E?.[$.Footer],
|
|
@@ -15582,7 +15583,7 @@ var zk = [
|
|
|
15582
15583
|
setState: (e, t, n) => {
|
|
15583
15584
|
var i, a, o;
|
|
15584
15585
|
if (!Object.is(r.current[e], t)) {
|
|
15585
|
-
if (r.current[e] = t, e === "search")
|
|
15586
|
+
if (r.current[e] = t, e === "search") ee(), D(), C(1, O);
|
|
15586
15587
|
else if (e === "value") {
|
|
15587
15588
|
if (document.activeElement.hasAttribute("cmdk-input") || document.activeElement.hasAttribute("cmdk-root")) {
|
|
15588
15589
|
let e = document.getElementById(x);
|
|
@@ -15608,16 +15609,16 @@ var zk = [
|
|
|
15608
15609
|
value: t,
|
|
15609
15610
|
keywords: n
|
|
15610
15611
|
}), r.current.filtered.items.set(e, E(t, n)), C(2, () => {
|
|
15611
|
-
|
|
15612
|
+
D(), w.emit();
|
|
15612
15613
|
}));
|
|
15613
15614
|
},
|
|
15614
15615
|
item: (e, t) => (i.current.add(e), t && (a.current.has(t) ? a.current.get(t).add(e) : a.current.set(t, /* @__PURE__ */ new Set([e]))), C(3, () => {
|
|
15615
|
-
|
|
15616
|
+
ee(), D(), r.current.value || O(), w.emit();
|
|
15616
15617
|
}), () => {
|
|
15617
15618
|
o.current.delete(e), i.current.delete(e), r.current.filtered.items.delete(e);
|
|
15618
15619
|
let t = A();
|
|
15619
15620
|
C(4, () => {
|
|
15620
|
-
|
|
15621
|
+
ee(), t?.getAttribute("id") === e && O(), w.emit();
|
|
15621
15622
|
});
|
|
15622
15623
|
}),
|
|
15623
15624
|
group: (e) => (a.current.has(e) || a.current.set(e, /* @__PURE__ */ new Set()), () => {
|
|
@@ -15635,7 +15636,7 @@ var zk = [
|
|
|
15635
15636
|
let n = c.current?.filter ?? qk;
|
|
15636
15637
|
return e ? n(e, r.current.search, t) : 0;
|
|
15637
15638
|
}
|
|
15638
|
-
function
|
|
15639
|
+
function D() {
|
|
15639
15640
|
if (!r.current.search || c.current.shouldFilter === !1) return;
|
|
15640
15641
|
let e = r.current.filtered.items, t = [];
|
|
15641
15642
|
r.current.filtered.groups.forEach((n) => {
|
|
@@ -15657,11 +15658,11 @@ var zk = [
|
|
|
15657
15658
|
t?.parentElement.appendChild(t);
|
|
15658
15659
|
});
|
|
15659
15660
|
}
|
|
15660
|
-
function
|
|
15661
|
+
function O() {
|
|
15661
15662
|
let e = j().find((e) => e.getAttribute("aria-disabled") !== "true")?.getAttribute(Kk);
|
|
15662
15663
|
w.setState("value", e || void 0);
|
|
15663
15664
|
}
|
|
15664
|
-
function
|
|
15665
|
+
function ee() {
|
|
15665
15666
|
if (!r.current.search || c.current.shouldFilter === !1) {
|
|
15666
15667
|
r.current.filtered.count = i.current.size;
|
|
15667
15668
|
return;
|