@tesouro/embedded-components-react 0.11.120 → 0.11.123
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/README.md +6 -3
- package/dist/index.css +32 -161
- package/dist/index.d.ts +40 -8
- package/dist/index.js +29 -28
- package/dist/lib/ExpenseManagementWidget.d.ts +11 -2
- package/dist/lib/ReceivablesWidget.d.ts +29 -6
- package/dist/lib/ReceivablesWidget.js +3 -1
- package/dist/lib/WidgetSuite.d.ts +38 -6
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/feature/dist/lib/ExpenseManagementWidget/ExpenseManagementWidget.js +343 -264
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/feature/dist/lib/ExpenseManagementWidget/labels.js +14 -0
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/feature/dist/lib/ExpenseManagementWidget/permissions.js +6 -3
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/feature/dist/lib/ExpenseManagementWidget/useExpenseTabBadgeCounts.js +34 -19
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/feature/dist/lib/ExpenseManagementWidget/useExpensesTransactions.js +100 -98
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/feature/dist/lib/TransactionDetails/TransactionDetailsActionsFeature.js +27 -24
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/feature/dist/lib/TransactionDetails/TransactionDetailsFeature.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/feature/dist/lib/expenseStatus.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/receipt-match/feature/dist/index2.js +43 -44
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/receipt-match/feature/dist/index4.js +79 -40
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/receipt-match/ui/dist/index2.js +10 -0
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/receipt-match/ui/dist/index3.js +47 -46
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/receipt-match/ui/dist/index4.js +78 -84
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/receipt-match/ui/dist/index5.js +165 -158
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/receipt-match/ui/dist/index6.js +38 -100
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/receipt-match/ui/dist/index7.js +77 -54
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/ui/dist/lib/AccordionItemCard/AccordionItemCard.js +213 -229
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/ui/dist/lib/ExpenseStatusBadge/ExpenseStatusBadge.js +6 -8
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/ui/dist/lib/ExpensesScreen/ExpensesScreen.js +66 -73
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/ui/dist/lib/ExpensesTransactionsFilterBar/ExpensesTransactionsFilterBar.js +13 -13
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/ui/dist/lib/ExpensesTransactionsTable/ExpensesTransactionsTable.js +123 -80
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/ui/dist/lib/ExpensesTransactionsTable/labels.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/ui/dist/lib/FileViewer/FileViewer.js +83 -74
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/ui/dist/lib/TransactionDetails/DeleteReceiptDialog/DeleteReceiptDialog.js +22 -30
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/ui/dist/lib/TransactionDetails/TransactionDetails.js +176 -259
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/ui/dist/lib/TransactionDetails/labels.js +4 -2
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/ui/dist/lib/TransactionDetailsActions/BulkProgress.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/ui/dist/lib/TransactionDetailsActions/TransactionDetailsActions.js +112 -121
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/ui/dist/lib/TransactionDetailsActions/labels.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/index.js +3 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/lib/ReceivablesWidget/ReceivableAttachmentsSection.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/lib/ReceivablesWidget/ReceivableCustomerSection.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/lib/ReceivablesWidget/ReceivablesWidget.js +342 -295
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/lib/ReceivablesWidget/paymentTerms.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/lib/ReceivablesWidget/preview.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/lib/ReceivablesWidget/recurrence.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/lib/ReceivablesWidget/reminders.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/lib/ReceivablesWidget/tabs.js +26 -0
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/lib/ReceivablesWidget/useReceivableDetails.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/lib/ReceivablesWidget/useReceivableForm.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/feature/dist/mocks/labels.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index.js +30 -26
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index10.js +18 -2
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index11.js +121 -11
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index12.js +100 -11
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index13.js +39 -27
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index14.js +2 -205
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index15.js +11 -52
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index16.js +11 -210
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index17.js +27 -159
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index18.js +203 -14
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index19.js +51 -22
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index20.js +210 -2
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index21.js +154 -111
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index22.js +15 -3
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index23.js +21 -195
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index24.js +3 -2
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index25.js +116 -53
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index26.js +3 -22
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index27.js +197 -8
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index28.js +2 -78
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index29.js +53 -39
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index30.js +20 -17
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index31.js +8 -41
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index32.js +73 -25
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index33.js +36 -17
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index34.js +17 -9
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index35.js +39 -34
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index36.js +29 -14
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index37.js +18 -24
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index38.js +8 -85
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index39.js +33 -490
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index40.js +15 -2
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index41.js +22 -42
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index42.js +82 -65
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index43.js +475 -426
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index44.js +2 -226
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index45.js +46 -21
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index46.js +69 -5
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index47.js +445 -0
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index48.js +208 -246
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index49.js +22 -2
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index50.js +5 -129
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index52.js +247 -222
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index53.js +1 -2
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index54.js +125 -242
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index55.js +23 -56
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index56.js +229 -209
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index57.js +3 -47
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index58.js +248 -0
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index59.js +60 -0
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index6.js +2 -17
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index60.js +194 -0
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index61.js +47 -0
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index7.js +53 -117
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index8.js +9 -99
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index9.js +3 -40
- package/dist/libs/tesouro-embedded-components-react/shared/expense-requirements/feature/dist/lib/ExpenseRequirementsWidget.js +41 -32
- package/dist/libs/tesouro-embedded-components-react/shared/expense-requirements/ui/dist/index3.js +43 -53
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/ui/dist/index.js +3 -1
- package/dist/libs/tesouro-embedded-components-react/shared/ui/dist/lib/CopyAddress/CopyAddress.js +55 -0
- package/dist/libs/tesouro-embedded-components-react/shared/ui/dist/lib/UploadTray/UploadTray.js +84 -0
- package/dist/libs/tesouro-embedded-components-react/upload-receipt-widget/feature/dist/lib/UploadReceiptWidget.js +126 -73
- package/dist/libs/tesouro-embedded-components-react/upload-receipt-widget/ui/dist/index2.js +14 -1
- package/dist/libs/tesouro-embedded-components-react/upload-receipt-widget/ui/dist/index3.js +9 -8
- package/dist/libs/tesouro-embedded-components-react/upload-receipt-widget/ui/dist/index4.js +75 -128
- package/dist/packages/shared-ui-shadcn/dist/index.js +1399 -1302
- package/package.json +1 -1
- package/dist/libs/tesouro-embedded-components-react/expense-management-widget/ui/dist/lib/ExpenseStatusBadge/badgeTones.js +0 -9
- package/dist/libs/tesouro-embedded-components-react/invoicing-widget/ui/dist/index51.js +0 -27
|
@@ -2,20 +2,20 @@
|
|
|
2
2
|
"use client";
|
|
3
3
|
"use client";
|
|
4
4
|
"use client";
|
|
5
|
-
import { Accordion as e, AccordionContent as t, AccordionItem as n, AccordionTrigger as r, Alert as i, AlertDescription as a, AlertTitle as o, AuditHistoryList as s,
|
|
6
|
-
import { ACCORDION_ITEM_CARD_LABELS_EN as
|
|
7
|
-
import { useId as
|
|
8
|
-
import { Fragment as
|
|
9
|
-
import { ArrowRight as
|
|
5
|
+
import { Accordion as e, AccordionContent as t, AccordionItem as n, AccordionTrigger as r, Alert as i, AlertDescription as a, AlertTitle as o, AuditHistoryList as s, Badge as c, Button as l, DropdownMenu as u, DropdownMenuContent as d, DropdownMenuItem as f, DropdownMenuTrigger as p, Select as m, SelectContent as h, SelectItem as g, SelectTrigger as _, SelectValue as v, Textarea as y, Typography as b, cn as x } from "../../../../../../../packages/shared-ui-shadcn/dist/index.js";
|
|
6
|
+
import { ACCORDION_ITEM_CARD_LABELS_EN as S } from "./labels.js";
|
|
7
|
+
import { useId as C } from "react";
|
|
8
|
+
import { Fragment as w, jsx as T, jsxs as E } from "react/jsx-runtime";
|
|
9
|
+
import { ArrowRight as D, ChevronDown as O, CircleAlert as k, ClipboardCheck as A, CreditCard as j, Download as ee, FileImage as te, Info as ne, Paperclip as M, Receipt as N, Send as P, Trash2 as re, TriangleAlert as ie, Zap as F } from "lucide-react";
|
|
10
10
|
// ../../libs/tesouro-embedded-components-react/expense-management-widget/ui/dist/lib/AccordionItemCard/AccordionItemCard.js
|
|
11
|
-
var
|
|
12
|
-
receipt:
|
|
13
|
-
paperclip:
|
|
14
|
-
send:
|
|
15
|
-
},
|
|
16
|
-
function
|
|
17
|
-
let e = `spent-from-card-${
|
|
18
|
-
return /* @__PURE__ */
|
|
11
|
+
var I = {
|
|
12
|
+
receipt: N,
|
|
13
|
+
paperclip: M,
|
|
14
|
+
send: P
|
|
15
|
+
}, L = "ttw:rounded-sm ttw:bg-muted ttw:p-1 ttw:text-sm ttw:text-muted-foreground", R = "ttw:min-w-35 ttw:px-3 ttw:py-4";
|
|
16
|
+
function z() {
|
|
17
|
+
let e = `spent-from-card-${C().replace(/:/g, "")}`;
|
|
18
|
+
return /* @__PURE__ */ E("svg", {
|
|
19
19
|
width: "42",
|
|
20
20
|
height: "28",
|
|
21
21
|
viewBox: "0 0 42 28",
|
|
@@ -23,13 +23,13 @@ function se() {
|
|
|
23
23
|
"aria-hidden": !0,
|
|
24
24
|
xmlns: "http://www.w3.org/2000/svg",
|
|
25
25
|
children: [
|
|
26
|
-
/* @__PURE__ */
|
|
26
|
+
/* @__PURE__ */ T("rect", {
|
|
27
27
|
width: "42",
|
|
28
28
|
height: "28",
|
|
29
29
|
rx: "3.5",
|
|
30
30
|
fill: `url(#${e})`
|
|
31
31
|
}),
|
|
32
|
-
/* @__PURE__ */
|
|
32
|
+
/* @__PURE__ */ T("rect", {
|
|
33
33
|
x: "5",
|
|
34
34
|
y: "7",
|
|
35
35
|
width: "6",
|
|
@@ -37,14 +37,14 @@ function se() {
|
|
|
37
37
|
rx: "1",
|
|
38
38
|
fill: "#A1A1AA"
|
|
39
39
|
}),
|
|
40
|
-
/* @__PURE__ */
|
|
40
|
+
/* @__PURE__ */ T("defs", { children: /* @__PURE__ */ E("radialGradient", {
|
|
41
41
|
id: e,
|
|
42
42
|
cx: "0",
|
|
43
43
|
cy: "0",
|
|
44
44
|
r: "1",
|
|
45
45
|
gradientUnits: "userSpaceOnUse",
|
|
46
46
|
gradientTransform: "rotate(33.6901) scale(50.4777 75.7166)",
|
|
47
|
-
children: [/* @__PURE__ */
|
|
47
|
+
children: [/* @__PURE__ */ T("stop", { stopColor: "#3F3F46" }), /* @__PURE__ */ T("stop", {
|
|
48
48
|
offset: "1",
|
|
49
49
|
stopColor: "#18181B"
|
|
50
50
|
})]
|
|
@@ -52,269 +52,255 @@ function se() {
|
|
|
52
52
|
]
|
|
53
53
|
});
|
|
54
54
|
}
|
|
55
|
-
function
|
|
56
|
-
return /* @__PURE__ */
|
|
55
|
+
function B({ title: i, value: a, children: o }) {
|
|
56
|
+
return /* @__PURE__ */ T(e, {
|
|
57
57
|
type: "single",
|
|
58
58
|
collapsible: !0,
|
|
59
59
|
defaultValue: a,
|
|
60
|
-
children: /* @__PURE__ */
|
|
60
|
+
children: /* @__PURE__ */ E(n, {
|
|
61
61
|
value: a,
|
|
62
62
|
className: "ttw:flex ttw:w-full ttw:flex-col ttw:gap-4 ttw:rounded-xl ttw:border ttw:border-border ttw:p-4 ttw:last:border-b",
|
|
63
|
-
children: [/* @__PURE__ */
|
|
63
|
+
children: [/* @__PURE__ */ T(r, {
|
|
64
64
|
iconPosition: "left",
|
|
65
65
|
iconClassName: "ttw:size-5",
|
|
66
66
|
className: "ttw:items-center ttw:py-0 ttw:hover:no-underline",
|
|
67
|
-
children: /* @__PURE__ */
|
|
67
|
+
children: /* @__PURE__ */ T(b, {
|
|
68
68
|
variant: "h6",
|
|
69
69
|
children: i
|
|
70
70
|
})
|
|
71
|
-
}), /* @__PURE__ */
|
|
71
|
+
}), /* @__PURE__ */ T(t, {
|
|
72
72
|
className: "ttw:flex ttw:flex-col ttw:pb-0",
|
|
73
73
|
children: o
|
|
74
74
|
})]
|
|
75
75
|
})
|
|
76
76
|
});
|
|
77
77
|
}
|
|
78
|
-
function
|
|
79
|
-
return /* @__PURE__ */
|
|
78
|
+
function V({ marker: e }) {
|
|
79
|
+
return /* @__PURE__ */ T("span", {
|
|
80
80
|
className: "ttw:inline-block ttw:-translate-y-0.5 ttw:text-sm ttw:font-normal ttw:text-destructive",
|
|
81
81
|
children: e
|
|
82
82
|
});
|
|
83
83
|
}
|
|
84
|
-
function
|
|
85
|
-
let
|
|
86
|
-
...
|
|
87
|
-
...
|
|
88
|
-
},
|
|
89
|
-
|
|
90
|
-
onSelect:
|
|
91
|
-
children: [/* @__PURE__ */
|
|
84
|
+
function H({ title: e, cardLabel: t, cardName: n, cardholder: r, showCardholder: s = !0, showPhysicalPill: m, receiptFileUrl: h, hasMissingInfo: g, showNoReceiptWarning: _, isReceiptRequired: v, isDescriptionRequired: x, isReceiptAutoMatched: C, isReceiptActionDisabled: D, receiptButtonLabel: k, receiptButtonIcon: A = "receipt", receiptButtonVariant: F = "outline", onUploadClick: L, onOpenReceiptInbox: H, onSubmitWithoutReceipt: U, onDeleteReceipt: W, descriptionValue: G, initialDescriptionValue: K, onDescriptionChange: q, onSaveDescription: ae, onCancelDescription: oe, isSavingDescription: J, isMemoEditable: Y, memoBadgeLabel: X, labels: se }) {
|
|
85
|
+
let Z = {
|
|
86
|
+
...S,
|
|
87
|
+
...se
|
|
88
|
+
}, ce = I[A], le = h ? [] : [
|
|
89
|
+
L && /* @__PURE__ */ E(f, {
|
|
90
|
+
onSelect: L,
|
|
91
|
+
children: [/* @__PURE__ */ T(M, {
|
|
92
92
|
className: "ttw:size-4",
|
|
93
93
|
"aria-hidden": !0
|
|
94
|
-
}),
|
|
94
|
+
}), Z.uploadDropdownUploadOption]
|
|
95
95
|
}, "upload"),
|
|
96
|
-
H && /* @__PURE__ */
|
|
96
|
+
H && /* @__PURE__ */ E(f, {
|
|
97
97
|
onSelect: H,
|
|
98
|
-
children: [/* @__PURE__ */
|
|
98
|
+
children: [/* @__PURE__ */ T(te, {
|
|
99
99
|
className: "ttw:size-4",
|
|
100
100
|
"aria-hidden": !0
|
|
101
|
-
}),
|
|
101
|
+
}), Z.uploadDropdownFindReceiptOption]
|
|
102
102
|
}, "inbox"),
|
|
103
|
-
U && /* @__PURE__ */
|
|
103
|
+
U && /* @__PURE__ */ E(f, {
|
|
104
104
|
onSelect: U,
|
|
105
|
-
children: [/* @__PURE__ */
|
|
105
|
+
children: [/* @__PURE__ */ T(P, {
|
|
106
106
|
className: "ttw:size-4",
|
|
107
107
|
"aria-hidden": !0
|
|
108
|
-
}),
|
|
108
|
+
}), Z.uploadDropdownSubmitWithoutOption]
|
|
109
109
|
}, "without")
|
|
110
|
-
],
|
|
110
|
+
], ue = h ? [/* @__PURE__ */ T(f, {
|
|
111
111
|
asChild: !0,
|
|
112
|
-
children: /* @__PURE__ */
|
|
113
|
-
href:
|
|
112
|
+
children: /* @__PURE__ */ E("a", {
|
|
113
|
+
href: h,
|
|
114
114
|
download: !0,
|
|
115
115
|
target: "_blank",
|
|
116
116
|
rel: "noreferrer",
|
|
117
|
-
children: [/* @__PURE__ */
|
|
117
|
+
children: [/* @__PURE__ */ T(ee, { "aria-hidden": !0 }), Z.uploadedReceiptDownloadOption]
|
|
118
118
|
})
|
|
119
|
-
}, "download"), W && /* @__PURE__ */
|
|
119
|
+
}, "download"), W && /* @__PURE__ */ E(f, {
|
|
120
120
|
variant: "destructive",
|
|
121
121
|
onClick: W,
|
|
122
|
-
children: [/* @__PURE__ */
|
|
123
|
-
}, "delete")] : [], Q = [...
|
|
122
|
+
children: [/* @__PURE__ */ T(re, { "aria-hidden": !0 }), Z.uploadedReceiptDeleteOption]
|
|
123
|
+
}, "delete")] : [], Q = [...le, ...ue].filter(Boolean), $ = C ? /* @__PURE__ */ E(l, {
|
|
124
124
|
type: "button",
|
|
125
125
|
variant: "ghost",
|
|
126
|
-
className: "ttw:flex ttw:items-center ttw:gap-2 ttw:text-
|
|
127
|
-
disabled:
|
|
126
|
+
className: "ttw:flex ttw:items-center ttw:gap-2 ttw:text-violet-foreground",
|
|
127
|
+
disabled: D,
|
|
128
128
|
children: [
|
|
129
|
-
/* @__PURE__ */
|
|
129
|
+
/* @__PURE__ */ T(N, {
|
|
130
130
|
className: "ttw:size-4",
|
|
131
131
|
"aria-hidden": !0
|
|
132
132
|
}),
|
|
133
|
-
|
|
134
|
-
Q.length > 0 && /* @__PURE__ */
|
|
133
|
+
Z.receiptAutoMatchedBadge,
|
|
134
|
+
Q.length > 0 && /* @__PURE__ */ T(O, {
|
|
135
135
|
className: "ttw:size-4",
|
|
136
136
|
"aria-hidden": !0
|
|
137
137
|
})
|
|
138
138
|
]
|
|
139
|
-
}) : /* @__PURE__ */
|
|
139
|
+
}) : /* @__PURE__ */ E(l, {
|
|
140
140
|
type: "button",
|
|
141
|
-
variant:
|
|
141
|
+
variant: F,
|
|
142
142
|
className: "ttw:flex ttw:items-center ttw:gap-2",
|
|
143
|
-
disabled:
|
|
143
|
+
disabled: D,
|
|
144
144
|
children: [
|
|
145
|
-
/* @__PURE__ */
|
|
145
|
+
/* @__PURE__ */ T(ce, {
|
|
146
146
|
className: "ttw:size-4",
|
|
147
147
|
"aria-hidden": !0
|
|
148
148
|
}),
|
|
149
|
-
|
|
150
|
-
Q.length > 0 && /* @__PURE__ */
|
|
149
|
+
k,
|
|
150
|
+
Q.length > 0 && /* @__PURE__ */ T(O, {
|
|
151
151
|
className: "ttw:size-4",
|
|
152
152
|
"aria-hidden": !0
|
|
153
153
|
})
|
|
154
154
|
]
|
|
155
155
|
});
|
|
156
|
-
return /* @__PURE__ */
|
|
156
|
+
return /* @__PURE__ */ E(B, {
|
|
157
157
|
title: e,
|
|
158
158
|
value: "requirements",
|
|
159
159
|
children: [
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
160
|
+
g && /* @__PURE__ */ E(i, {
|
|
161
|
+
variant: "warning",
|
|
162
|
+
className: "ttw:mb-4",
|
|
163
|
+
children: [/* @__PURE__ */ T(ie, { "aria-hidden": !0 }), /* @__PURE__ */ T(o, {
|
|
163
164
|
className: "ttw:font-medium",
|
|
164
|
-
children:
|
|
165
|
+
children: Z.missingInfoWarning
|
|
165
166
|
})]
|
|
166
167
|
}),
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
"aria-hidden": !0
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
/* @__PURE__ */ w("span", {
|
|
176
|
-
className: "ttw:font-semibold ttw:text-foreground",
|
|
177
|
-
children: X.noReceiptWarningTitle
|
|
178
|
-
}),
|
|
179
|
-
" ",
|
|
180
|
-
X.noReceiptWarningDescription
|
|
181
|
-
]
|
|
182
|
-
})]
|
|
168
|
+
_ && /* @__PURE__ */ E(i, {
|
|
169
|
+
variant: "info",
|
|
170
|
+
className: "ttw:mb-4",
|
|
171
|
+
children: [
|
|
172
|
+
/* @__PURE__ */ T(ne, { "aria-hidden": !0 }),
|
|
173
|
+
/* @__PURE__ */ T(o, { children: Z.noReceiptWarningTitle }),
|
|
174
|
+
/* @__PURE__ */ T(a, { children: Z.noReceiptWarningDescription })
|
|
175
|
+
]
|
|
183
176
|
}),
|
|
184
|
-
/* @__PURE__ */
|
|
177
|
+
/* @__PURE__ */ E("div", {
|
|
185
178
|
className: "ttw:flex",
|
|
186
|
-
children: [/* @__PURE__ */
|
|
179
|
+
children: [/* @__PURE__ */ T("div", {
|
|
187
180
|
className: R,
|
|
188
|
-
children: /* @__PURE__ */
|
|
181
|
+
children: /* @__PURE__ */ E(b, {
|
|
189
182
|
variant: "body2",
|
|
190
183
|
color: "muted",
|
|
191
184
|
className: "ttw:flex ttw:items-center ttw:gap-2",
|
|
192
185
|
children: [
|
|
193
|
-
/* @__PURE__ */
|
|
186
|
+
/* @__PURE__ */ T(j, {
|
|
194
187
|
className: "ttw:size-4",
|
|
195
188
|
"aria-hidden": !0
|
|
196
189
|
}),
|
|
197
190
|
" ",
|
|
198
|
-
|
|
191
|
+
Z.spentFrom
|
|
199
192
|
]
|
|
200
193
|
})
|
|
201
|
-
}), /* @__PURE__ */
|
|
194
|
+
}), /* @__PURE__ */ T("div", {
|
|
202
195
|
className: "ttw:flex ttw:items-center ttw:gap-3 ttw:px-3",
|
|
203
|
-
children: n ? /* @__PURE__ */
|
|
196
|
+
children: n ? /* @__PURE__ */ E(w, { children: [/* @__PURE__ */ T(z, {}), /* @__PURE__ */ E("div", {
|
|
204
197
|
className: "ttw:flex ttw:flex-col",
|
|
205
|
-
children: [/* @__PURE__ */
|
|
198
|
+
children: [/* @__PURE__ */ T(b, {
|
|
206
199
|
variant: "body2",
|
|
207
200
|
className: "ttw:m-0 ttw:font-semibold ttw:leading-tight",
|
|
208
201
|
children: n
|
|
209
|
-
}), /* @__PURE__ */
|
|
202
|
+
}), /* @__PURE__ */ E("div", {
|
|
210
203
|
className: "ttw:flex ttw:items-center ttw:gap-2",
|
|
211
|
-
children: [/* @__PURE__ */
|
|
204
|
+
children: [/* @__PURE__ */ T(b, {
|
|
212
205
|
variant: "caption",
|
|
213
206
|
color: "muted",
|
|
214
207
|
className: "ttw:leading-tight",
|
|
215
208
|
children: t
|
|
216
|
-
}),
|
|
217
|
-
|
|
218
|
-
children:
|
|
209
|
+
}), m && /* @__PURE__ */ T(c, {
|
|
210
|
+
variant: "secondary",
|
|
211
|
+
children: Z.physical
|
|
219
212
|
})]
|
|
220
213
|
})]
|
|
221
|
-
})] }) : /* @__PURE__ */
|
|
214
|
+
})] }) : /* @__PURE__ */ E(w, { children: [/* @__PURE__ */ T(b, {
|
|
222
215
|
variant: "body2",
|
|
223
216
|
className: "ttw:font-medium",
|
|
224
217
|
children: t
|
|
225
|
-
}),
|
|
226
|
-
|
|
227
|
-
children:
|
|
218
|
+
}), m && /* @__PURE__ */ T(c, {
|
|
219
|
+
variant: "secondary",
|
|
220
|
+
children: Z.physical
|
|
228
221
|
})] })
|
|
229
222
|
})]
|
|
230
223
|
}),
|
|
231
|
-
s && /* @__PURE__ */
|
|
224
|
+
s && /* @__PURE__ */ E("div", {
|
|
232
225
|
className: "ttw:flex",
|
|
233
|
-
children: [/* @__PURE__ */
|
|
226
|
+
children: [/* @__PURE__ */ T("div", {
|
|
234
227
|
className: R,
|
|
235
|
-
children: /* @__PURE__ */
|
|
228
|
+
children: /* @__PURE__ */ T(b, {
|
|
236
229
|
variant: "body2",
|
|
237
230
|
color: "muted",
|
|
238
|
-
children:
|
|
231
|
+
children: Z.cardholder
|
|
239
232
|
})
|
|
240
|
-
}), /* @__PURE__ */
|
|
233
|
+
}), /* @__PURE__ */ T("div", {
|
|
241
234
|
className: "ttw:flex ttw:items-center ttw:px-3",
|
|
242
|
-
children: /* @__PURE__ */
|
|
235
|
+
children: /* @__PURE__ */ T(b, {
|
|
243
236
|
variant: "body2",
|
|
244
237
|
className: "ttw:font-medium",
|
|
245
238
|
children: r
|
|
246
239
|
})
|
|
247
240
|
})]
|
|
248
241
|
}),
|
|
249
|
-
/* @__PURE__ */
|
|
242
|
+
/* @__PURE__ */ E("div", {
|
|
250
243
|
className: "ttw:flex",
|
|
251
|
-
children: [/* @__PURE__ */
|
|
244
|
+
children: [/* @__PURE__ */ T("div", {
|
|
252
245
|
className: R,
|
|
253
|
-
children: /* @__PURE__ */
|
|
246
|
+
children: /* @__PURE__ */ E(b, {
|
|
254
247
|
variant: "body2",
|
|
255
248
|
color: "muted",
|
|
256
249
|
className: "ttw:flex ttw:items-center ttw:gap-2",
|
|
257
250
|
children: [
|
|
258
|
-
/* @__PURE__ */
|
|
251
|
+
/* @__PURE__ */ T(N, {
|
|
259
252
|
className: "ttw:size-4",
|
|
260
253
|
"aria-hidden": !0
|
|
261
254
|
}),
|
|
262
255
|
" ",
|
|
263
|
-
/* @__PURE__ */
|
|
256
|
+
/* @__PURE__ */ E("span", { children: [Z.receipt, v && /* @__PURE__ */ T(V, { marker: Z.requiredMarker })] })
|
|
264
257
|
]
|
|
265
258
|
})
|
|
266
|
-
}), /* @__PURE__ */
|
|
259
|
+
}), /* @__PURE__ */ T("div", {
|
|
267
260
|
className: "ttw:flex ttw:items-center ttw:px-3",
|
|
268
|
-
children: Q.length > 0 ? /* @__PURE__ */
|
|
261
|
+
children: Q.length > 0 ? /* @__PURE__ */ E(u, { children: [/* @__PURE__ */ T(p, {
|
|
269
262
|
asChild: !0,
|
|
270
263
|
children: $
|
|
271
|
-
}), /* @__PURE__ */
|
|
272
|
-
"aria-label":
|
|
264
|
+
}), /* @__PURE__ */ T(d, {
|
|
265
|
+
"aria-label": Z.receiptMenuAriaLabel,
|
|
273
266
|
children: Q
|
|
274
267
|
})] }) : $
|
|
275
268
|
})]
|
|
276
269
|
}),
|
|
277
|
-
/* @__PURE__ */
|
|
270
|
+
/* @__PURE__ */ E("div", {
|
|
278
271
|
className: "ttw:flex",
|
|
279
|
-
children: [/* @__PURE__ */
|
|
272
|
+
children: [/* @__PURE__ */ E("div", {
|
|
280
273
|
className: R,
|
|
281
|
-
children: [/* @__PURE__ */ T(
|
|
274
|
+
children: [/* @__PURE__ */ T(b, {
|
|
282
275
|
variant: "body2",
|
|
283
|
-
color:
|
|
284
|
-
className:
|
|
285
|
-
children: [
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
}),
|
|
290
|
-
" ",
|
|
291
|
-
/* @__PURE__ */ T("span", { children: [X.memo, S && /* @__PURE__ */ w(B, { marker: X.requiredMarker })] })
|
|
292
|
-
]
|
|
293
|
-
}), Y && /* @__PURE__ */ w("span", {
|
|
294
|
-
className: "ttw:rounded-md ttw:bg-purple-100 ttw:px-2 ttw:py-0.5 ttw:text-sm ttw:font-medium ttw:text-purple-700",
|
|
295
|
-
children: Y
|
|
276
|
+
color: "muted",
|
|
277
|
+
className: "ttw:flex ttw:items-center ttw:gap-2",
|
|
278
|
+
children: /* @__PURE__ */ E("span", { children: [Z.memo, x && /* @__PURE__ */ T(V, { marker: Z.requiredMarker })] })
|
|
279
|
+
}), X && /* @__PURE__ */ T(c, {
|
|
280
|
+
accent: "violet",
|
|
281
|
+
children: X
|
|
296
282
|
})]
|
|
297
|
-
}), /* @__PURE__ */
|
|
283
|
+
}), /* @__PURE__ */ E("div", {
|
|
298
284
|
className: "ttw:flex ttw:w-full ttw:flex-col ttw:gap-3 ttw:px-3 ttw:py-1",
|
|
299
|
-
children: [/* @__PURE__ */
|
|
300
|
-
"aria-label":
|
|
285
|
+
children: [/* @__PURE__ */ T(y, {
|
|
286
|
+
"aria-label": Z.memo,
|
|
301
287
|
className: "ttw:max-h-24 ttw:min-h-24 ttw:resize-none",
|
|
302
288
|
value: G,
|
|
303
|
-
onChange:
|
|
304
|
-
disabled: !
|
|
305
|
-
}), G !== K && /* @__PURE__ */
|
|
289
|
+
onChange: q,
|
|
290
|
+
disabled: !Y
|
|
291
|
+
}), G !== K && /* @__PURE__ */ E("div", {
|
|
306
292
|
className: "ttw:flex ttw:gap-2",
|
|
307
|
-
children: [/* @__PURE__ */
|
|
293
|
+
children: [/* @__PURE__ */ T(l, {
|
|
308
294
|
type: "button",
|
|
309
295
|
variant: "ghost",
|
|
310
|
-
disabled:
|
|
311
|
-
onClick:
|
|
312
|
-
children:
|
|
313
|
-
}), /* @__PURE__ */
|
|
296
|
+
disabled: J,
|
|
297
|
+
onClick: oe,
|
|
298
|
+
children: Z.cancelButton
|
|
299
|
+
}), /* @__PURE__ */ T(l, {
|
|
314
300
|
type: "button",
|
|
315
|
-
onClick:
|
|
316
|
-
disabled:
|
|
317
|
-
children:
|
|
301
|
+
onClick: ae,
|
|
302
|
+
disabled: J || !Y,
|
|
303
|
+
children: Z.saveButton
|
|
318
304
|
})]
|
|
319
305
|
})]
|
|
320
306
|
})]
|
|
@@ -322,106 +308,104 @@ function V({ title: e, cardLabel: t, cardName: n, cardholder: r, showCardholder:
|
|
|
322
308
|
]
|
|
323
309
|
});
|
|
324
310
|
}
|
|
325
|
-
function
|
|
326
|
-
let
|
|
327
|
-
...
|
|
328
|
-
...
|
|
311
|
+
function U({ title: e, greaterThanValue: t, lessThanValue: n, ruleLabel: r, hasAppliedPolicy: o, isRejected: s, isAutoApproved: l, isManuallyApproved: u, isPendingReview: d, rejectionReason: f, approverName: p, labels: m }) {
|
|
312
|
+
let h = {
|
|
313
|
+
...S,
|
|
314
|
+
...m
|
|
329
315
|
};
|
|
330
|
-
return /* @__PURE__ */
|
|
316
|
+
return /* @__PURE__ */ E(B, {
|
|
331
317
|
title: e,
|
|
332
318
|
value: "approvals",
|
|
333
319
|
children: [
|
|
334
|
-
s && /* @__PURE__ */
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
children: d ? `"${d}"` : m.emptyRejectionReason
|
|
339
|
-
})]
|
|
320
|
+
s && /* @__PURE__ */ E(i, {
|
|
321
|
+
variant: "destructive",
|
|
322
|
+
className: "ttw:mb-4",
|
|
323
|
+
children: [/* @__PURE__ */ T(k, { "aria-hidden": !0 }), /* @__PURE__ */ T(a, { children: f ? `"${f}"` : h.emptyRejectionReason })]
|
|
340
324
|
}),
|
|
341
|
-
/* @__PURE__ */
|
|
325
|
+
/* @__PURE__ */ E("div", {
|
|
342
326
|
className: "ttw:flex",
|
|
343
|
-
children: [/* @__PURE__ */
|
|
327
|
+
children: [/* @__PURE__ */ T("div", {
|
|
344
328
|
className: R,
|
|
345
|
-
children: /* @__PURE__ */
|
|
329
|
+
children: /* @__PURE__ */ E(b, {
|
|
346
330
|
variant: "body2",
|
|
347
331
|
color: "muted",
|
|
348
332
|
className: "ttw:flex ttw:items-center ttw:gap-2",
|
|
349
333
|
children: [
|
|
350
|
-
/* @__PURE__ */
|
|
334
|
+
/* @__PURE__ */ T(A, {
|
|
351
335
|
className: "ttw:size-4",
|
|
352
336
|
"aria-hidden": !0
|
|
353
337
|
}),
|
|
354
338
|
" ",
|
|
355
|
-
|
|
339
|
+
h.rule
|
|
356
340
|
]
|
|
357
341
|
})
|
|
358
|
-
}), /* @__PURE__ */
|
|
342
|
+
}), /* @__PURE__ */ T("div", {
|
|
359
343
|
className: "ttw:flex ttw:items-center ttw:gap-0.5 ttw:px-3",
|
|
360
|
-
children: r ? /* @__PURE__ */
|
|
361
|
-
className:
|
|
344
|
+
children: r ? /* @__PURE__ */ T("span", {
|
|
345
|
+
className: L,
|
|
362
346
|
children: r
|
|
363
|
-
}) : o ? /* @__PURE__ */
|
|
364
|
-
!!t && /* @__PURE__ */
|
|
347
|
+
}) : o ? /* @__PURE__ */ E(w, { children: [
|
|
348
|
+
!!t && /* @__PURE__ */ E(w, { children: [/* @__PURE__ */ T(b, {
|
|
365
349
|
variant: "body2",
|
|
366
350
|
className: "ttw:font-medium",
|
|
367
|
-
children:
|
|
368
|
-
}), /* @__PURE__ */
|
|
369
|
-
className:
|
|
351
|
+
children: h.greaterThan
|
|
352
|
+
}), /* @__PURE__ */ T("span", {
|
|
353
|
+
className: L,
|
|
370
354
|
children: t
|
|
371
355
|
})] }),
|
|
372
|
-
!!(t && n) && /* @__PURE__ */
|
|
356
|
+
!!(t && n) && /* @__PURE__ */ T(D, {
|
|
373
357
|
className: "ttw:size-4",
|
|
374
358
|
"aria-hidden": !0
|
|
375
359
|
}),
|
|
376
|
-
!!n && /* @__PURE__ */
|
|
360
|
+
!!n && /* @__PURE__ */ E(w, { children: [/* @__PURE__ */ T(b, {
|
|
377
361
|
variant: "body2",
|
|
378
362
|
className: "ttw:font-medium",
|
|
379
|
-
children:
|
|
380
|
-
}), /* @__PURE__ */
|
|
381
|
-
className:
|
|
363
|
+
children: h.lessThan
|
|
364
|
+
}), /* @__PURE__ */ T("span", {
|
|
365
|
+
className: L,
|
|
382
366
|
children: n
|
|
383
367
|
})] })
|
|
384
|
-
] }) : /* @__PURE__ */
|
|
385
|
-
className:
|
|
386
|
-
children:
|
|
368
|
+
] }) : /* @__PURE__ */ T("span", {
|
|
369
|
+
className: L,
|
|
370
|
+
children: h.systemDefaultApplied
|
|
387
371
|
})
|
|
388
372
|
})]
|
|
389
373
|
}),
|
|
390
|
-
/* @__PURE__ */
|
|
374
|
+
/* @__PURE__ */ E("div", {
|
|
391
375
|
className: "ttw:flex",
|
|
392
|
-
children: [/* @__PURE__ */
|
|
376
|
+
children: [/* @__PURE__ */ T("div", {
|
|
393
377
|
className: R,
|
|
394
|
-
children: /* @__PURE__ */
|
|
378
|
+
children: /* @__PURE__ */ E(b, {
|
|
395
379
|
variant: "body2",
|
|
396
380
|
color: "muted",
|
|
397
381
|
className: "ttw:flex ttw:items-center ttw:gap-2",
|
|
398
382
|
children: [
|
|
399
|
-
/* @__PURE__ */
|
|
383
|
+
/* @__PURE__ */ T(F, {
|
|
400
384
|
className: "ttw:size-4",
|
|
401
385
|
"aria-hidden": !0
|
|
402
386
|
}),
|
|
403
387
|
" ",
|
|
404
|
-
|
|
388
|
+
h.status
|
|
405
389
|
]
|
|
406
390
|
})
|
|
407
|
-
}), /* @__PURE__ */
|
|
391
|
+
}), /* @__PURE__ */ E("div", {
|
|
408
392
|
className: "ttw:flex ttw:items-center ttw:px-3",
|
|
409
393
|
children: [
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
children:
|
|
394
|
+
l && /* @__PURE__ */ T(c, {
|
|
395
|
+
tone: "success",
|
|
396
|
+
children: h.autoApproval
|
|
413
397
|
}),
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
children:
|
|
398
|
+
u && /* @__PURE__ */ T(c, {
|
|
399
|
+
tone: "success",
|
|
400
|
+
children: p ? h.approvedBy(p) : h.approved
|
|
417
401
|
}),
|
|
418
|
-
s && /* @__PURE__ */
|
|
419
|
-
|
|
420
|
-
children:
|
|
402
|
+
s && /* @__PURE__ */ T(c, {
|
|
403
|
+
tone: "destructive",
|
|
404
|
+
children: p ? h.rejectedBy(p) : h.rejected
|
|
421
405
|
}),
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
children:
|
|
406
|
+
d && /* @__PURE__ */ T(c, {
|
|
407
|
+
tone: "warning",
|
|
408
|
+
children: h.awaitingReview
|
|
425
409
|
})
|
|
426
410
|
]
|
|
427
411
|
})]
|
|
@@ -429,24 +413,24 @@ function H({ title: e, greaterThanValue: t, lessThanValue: n, ruleLabel: r, hasA
|
|
|
429
413
|
]
|
|
430
414
|
});
|
|
431
415
|
}
|
|
432
|
-
function
|
|
433
|
-
return /* @__PURE__ */
|
|
416
|
+
function W({ title: i, rows: a, isLoading: o, isError: c, historyLabels: l }) {
|
|
417
|
+
return /* @__PURE__ */ T(e, {
|
|
434
418
|
type: "single",
|
|
435
419
|
collapsible: !0,
|
|
436
|
-
children: /* @__PURE__ */
|
|
420
|
+
children: /* @__PURE__ */ E(n, {
|
|
437
421
|
value: "auditHistory",
|
|
438
422
|
className: "ttw:flex ttw:w-full ttw:flex-col ttw:gap-4 ttw:rounded-xl ttw:border ttw:border-border ttw:p-4 ttw:last:border-b",
|
|
439
|
-
children: [/* @__PURE__ */
|
|
423
|
+
children: [/* @__PURE__ */ T(r, {
|
|
440
424
|
iconPosition: "left",
|
|
441
425
|
iconClassName: "ttw:size-5",
|
|
442
426
|
className: "ttw:items-center ttw:py-0 ttw:hover:no-underline",
|
|
443
|
-
children: /* @__PURE__ */
|
|
427
|
+
children: /* @__PURE__ */ T(b, {
|
|
444
428
|
variant: "h6",
|
|
445
429
|
children: i
|
|
446
430
|
})
|
|
447
|
-
}), /* @__PURE__ */
|
|
431
|
+
}), /* @__PURE__ */ T(t, {
|
|
448
432
|
className: "ttw:flex ttw:flex-col ttw:pb-0",
|
|
449
|
-
children: /* @__PURE__ */
|
|
433
|
+
children: /* @__PURE__ */ T(s, {
|
|
450
434
|
rows: a,
|
|
451
435
|
isLoading: o,
|
|
452
436
|
isError: c,
|
|
@@ -457,17 +441,17 @@ function U({ title: i, rows: a, isLoading: o, isError: c, historyLabels: l }) {
|
|
|
457
441
|
})
|
|
458
442
|
});
|
|
459
443
|
}
|
|
460
|
-
function
|
|
461
|
-
return /* @__PURE__ */
|
|
444
|
+
function G({ label: e, highlighted: t, value: n, options: r, onChange: i, disabled: a }) {
|
|
445
|
+
return /* @__PURE__ */ E("div", {
|
|
462
446
|
className: "ttw:flex ttw:items-center",
|
|
463
|
-
children: [/* @__PURE__ */
|
|
447
|
+
children: [/* @__PURE__ */ T("div", {
|
|
464
448
|
className: R,
|
|
465
|
-
children: /* @__PURE__ */
|
|
449
|
+
children: /* @__PURE__ */ E(b, {
|
|
466
450
|
variant: "body2",
|
|
467
451
|
color: t ? void 0 : "muted",
|
|
468
|
-
className:
|
|
452
|
+
className: x("ttw:flex ttw:items-center ttw:gap-2 ttw:font-medium", t && "ttw:text-violet-foreground"),
|
|
469
453
|
children: [
|
|
470
|
-
/* @__PURE__ */
|
|
454
|
+
/* @__PURE__ */ T(F, {
|
|
471
455
|
className: "ttw:size-4",
|
|
472
456
|
"aria-hidden": !0
|
|
473
457
|
}),
|
|
@@ -475,17 +459,17 @@ function W({ label: e, highlighted: t, value: n, options: r, onChange: i, disabl
|
|
|
475
459
|
e
|
|
476
460
|
]
|
|
477
461
|
})
|
|
478
|
-
}), /* @__PURE__ */
|
|
462
|
+
}), /* @__PURE__ */ T("div", {
|
|
479
463
|
className: "ttw:w-full ttw:px-3",
|
|
480
|
-
children: /* @__PURE__ */
|
|
464
|
+
children: /* @__PURE__ */ E(m, {
|
|
481
465
|
value: n,
|
|
482
466
|
onValueChange: i,
|
|
483
467
|
disabled: a,
|
|
484
|
-
children: [/* @__PURE__ */
|
|
468
|
+
children: [/* @__PURE__ */ T(_, {
|
|
485
469
|
className: "ttw:w-full",
|
|
486
470
|
"aria-label": e,
|
|
487
|
-
children: /* @__PURE__ */
|
|
488
|
-
}), /* @__PURE__ */
|
|
471
|
+
children: /* @__PURE__ */ T(v, {})
|
|
472
|
+
}), /* @__PURE__ */ T(h, { children: r.map((e) => /* @__PURE__ */ T(g, {
|
|
489
473
|
value: e.value,
|
|
490
474
|
children: e.label
|
|
491
475
|
}, e.value)) })]
|
|
@@ -493,58 +477,58 @@ function W({ label: e, highlighted: t, value: n, options: r, onChange: i, disabl
|
|
|
493
477
|
})]
|
|
494
478
|
});
|
|
495
479
|
}
|
|
496
|
-
function
|
|
497
|
-
let
|
|
498
|
-
...
|
|
480
|
+
function K({ title: e, glCategory: t, initialGlCategory: n, glCategoryOptions: r, onGlCategoryChange: i, department: a, initialDepartment: o, departmentOptions: s, onDepartmentChange: c, location: u, initialLocation: d, locationOptions: f, onLocationChange: p, onSave: m, onCancel: h, isSaving: g, isGlCategoryDisabled: _, isDisabled: v, glCategoryHighlight: y, departmentHighlight: b, locationHighlight: x, labels: C }) {
|
|
481
|
+
let w = {
|
|
482
|
+
...S,
|
|
499
483
|
...C
|
|
500
484
|
}, D = t !== n || a !== o || u !== d;
|
|
501
|
-
return /* @__PURE__ */
|
|
485
|
+
return /* @__PURE__ */ E(B, {
|
|
502
486
|
title: e,
|
|
503
487
|
value: "accounting",
|
|
504
488
|
children: [
|
|
505
|
-
/* @__PURE__ */
|
|
506
|
-
label:
|
|
489
|
+
/* @__PURE__ */ T(G, {
|
|
490
|
+
label: w.glCategory,
|
|
507
491
|
highlighted: y,
|
|
508
492
|
value: t,
|
|
509
493
|
options: r,
|
|
510
494
|
onChange: i,
|
|
511
495
|
disabled: _ || v
|
|
512
496
|
}),
|
|
513
|
-
/* @__PURE__ */
|
|
514
|
-
label:
|
|
497
|
+
/* @__PURE__ */ T(G, {
|
|
498
|
+
label: w.department,
|
|
515
499
|
highlighted: b,
|
|
516
500
|
value: a,
|
|
517
501
|
options: s,
|
|
518
|
-
onChange:
|
|
502
|
+
onChange: c,
|
|
519
503
|
disabled: v
|
|
520
504
|
}),
|
|
521
|
-
/* @__PURE__ */
|
|
522
|
-
label:
|
|
523
|
-
highlighted:
|
|
505
|
+
/* @__PURE__ */ T(G, {
|
|
506
|
+
label: w.location,
|
|
507
|
+
highlighted: x,
|
|
524
508
|
value: u,
|
|
525
509
|
options: f,
|
|
526
510
|
onChange: p,
|
|
527
511
|
disabled: v
|
|
528
512
|
}),
|
|
529
|
-
D && /* @__PURE__ */
|
|
513
|
+
D && /* @__PURE__ */ E("div", {
|
|
530
514
|
className: "ttw:flex ttw:justify-end ttw:gap-2 ttw:px-3",
|
|
531
|
-
children: [/* @__PURE__ */
|
|
515
|
+
children: [/* @__PURE__ */ T(l, {
|
|
532
516
|
type: "button",
|
|
533
517
|
variant: "ghost",
|
|
534
518
|
disabled: g,
|
|
535
519
|
onClick: h,
|
|
536
|
-
children:
|
|
537
|
-
}), /* @__PURE__ */
|
|
520
|
+
children: w.cancelButton
|
|
521
|
+
}), /* @__PURE__ */ T(l, {
|
|
538
522
|
type: "button",
|
|
539
523
|
disabled: g || v,
|
|
540
524
|
onClick: m,
|
|
541
|
-
children:
|
|
525
|
+
children: w.saveButton
|
|
542
526
|
})]
|
|
543
527
|
})
|
|
544
528
|
]
|
|
545
529
|
});
|
|
546
530
|
}
|
|
547
|
-
function
|
|
548
|
-
return e.type === "auditHistory" ? /* @__PURE__ */
|
|
531
|
+
function q(e) {
|
|
532
|
+
return e.type === "auditHistory" ? /* @__PURE__ */ T(W, { ...e }) : e.type === "approvals" ? /* @__PURE__ */ T(U, { ...e }) : e.type === "accounting" ? /* @__PURE__ */ T(K, { ...e }) : /* @__PURE__ */ T(H, { ...e });
|
|
549
533
|
}
|
|
550
|
-
export {
|
|
534
|
+
export { q as AccordionItemCard, q as default };
|