@tesouro/embedded-components-react 0.5.303 → 0.5.305
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/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index.js +9 -9
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index12.js +7 -7
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index13.js +10 -9
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index14.js +8 -7
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index15.js +7 -8
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index16.js +8 -28
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index17.js +24 -157
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index18.js +20 -13
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index19.js +13 -34
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index20.js +153 -89
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index21.js +17 -83
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index22.js +23 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index23.js +42 -55
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index24.js +93 -107
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index25.js +77 -185
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index26.js +3 -80
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index27.js +55 -72
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index28.js +111 -113
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index29.js +184 -463
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index3.js +14 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index30.js +78 -11
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index31.js +61 -74
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index32.js +115 -80
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index33.js +449 -216
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index34.js +116 -42
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index35.js +11 -249
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index36.js +85 -23
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index37.js +80 -648
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index38.js +240 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index39.js +44 -40
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index4.js +38 -15
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index40.js +242 -240
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index41.js +25 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index42.js +538 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index43.js +3 -66
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index44.js +42 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index45.js +239 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index46.js +3 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index47.js +5 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index48.js +67 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index49.js +1 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index5.js +227 -38
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index6.js +82 -224
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index7.js +45 -82
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index8.js +4 -47
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index9.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index29.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index31.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/lib/BillPayWidgetNative/BillsTab.js +6 -6
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
- package/package.json +1 -1
|
@@ -1,194 +1,86 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import "
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import { UNSAVED_BILL_DIALOG_LABELS_EN as h } from "../../ui/dist/index51.js";
|
|
10
|
-
import "../../ui/dist/index.js";
|
|
1
|
+
import { formatCalendarDate as e } from "../../../../shared/util/dist/lib/formatCalendarDate.js";
|
|
2
|
+
import { derivePayableStatus as t } from "../../../util/dist/lib/derivePayableStatus.js";
|
|
3
|
+
import { formatBillMoney as n } from "../../../util/dist/lib/formatBillMoney.js";
|
|
4
|
+
import { resolveAmountDueMinorUnits as r } from "../../../util/dist/lib/resolveAmountDue.js";
|
|
5
|
+
import { resolveLineItemAmountMinorUnits as i } from "../../../util/dist/lib/resolveLineItemAmount.js";
|
|
6
|
+
import { resolveLineItemQuantity as a } from "../../../util/dist/lib/resolveLineItemQuantity.js";
|
|
7
|
+
import { resolveVendor as o } from "../../../util/dist/lib/resolveVendor.js";
|
|
8
|
+
import { getPaidAtLabel as s, resolveInvoiceTotalMinorUnits as c } from "./index24.js";
|
|
11
9
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index25.js
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
submittedDemoted: "Bill updated. It moved back to Drafts because some required details are missing.",
|
|
23
|
-
billFinalized: "Bill submitted for approval.",
|
|
24
|
-
numbersOnly: "Enter numbers only.",
|
|
25
|
-
unreadableMoney: "Enter a valid amount.",
|
|
26
|
-
unusableQuantity: "Enter a quantity greater than 0.",
|
|
27
|
-
lineItemsNeedAttention: "Check the highlighted line items before saving.",
|
|
28
|
-
unreadableDiscount: "Enter a valid discount amount.",
|
|
29
|
-
unreadableTax: "Enter a valid tax amount.",
|
|
30
|
-
unreadableTotal: "Enter a valid total amount.",
|
|
31
|
-
totalNotGreaterThanZero: "Total amount must be greater than $0.",
|
|
32
|
-
poNumberTooLong: "PO number must be 255 characters or fewer.",
|
|
33
|
-
implausibleInvoiceDate: "Enter an invoice date within the last 10 years, no more than 30 days from today.",
|
|
34
|
-
implausibleDueDate: "Enter a due date within the last 10 years and next 5 years.",
|
|
35
|
-
dueBeforeInvoiceDate: "Due date must be on or after the invoice date."
|
|
36
|
-
}, _ = {
|
|
37
|
-
paymentInstructionsValue: (e) => `Account ending in ${e}`,
|
|
38
|
-
noMethod: "No payment method on file",
|
|
39
|
-
paymentMethodLoading: "Loading payment method...",
|
|
40
|
-
paymentMethodUnavailable: "We could not load payment methods. Try again.",
|
|
41
|
-
searchFailed: "We could not load vendors. Try again.",
|
|
42
|
-
vendorDetailsFailed: "We could not load this vendor. Try again.",
|
|
43
|
-
pendingVendorDescription: "Will be created when submitted",
|
|
44
|
-
pendingVendorIncompleteDescription: "Add the missing vendor details before submitting",
|
|
45
|
-
bankAccountSaveFailed: "We could not save these payment instructions. Try again."
|
|
46
|
-
}, v = {
|
|
47
|
-
attachFailed: "We could not attach that file. Try again.",
|
|
48
|
-
deleteFailed: "We could not remove that document. Try again.",
|
|
49
|
-
noDocument: "No document attached to this bill.",
|
|
50
|
-
pendingDeletionNotice: "This document will be removed when you save this bill.",
|
|
51
|
-
preview: d
|
|
52
|
-
}, y = {
|
|
53
|
-
...r,
|
|
54
|
-
notProvided: "Not provided",
|
|
55
|
-
paymentInstructionsValue: (e) => `Account ending in ${e}`,
|
|
56
|
-
paymentInstructionsNotSet: "Not set",
|
|
57
|
-
invoiceDateRow: "Invoice date",
|
|
58
|
-
dueDateRow: "Due date",
|
|
59
|
-
invoiceNumberRow: "Invoice number",
|
|
60
|
-
glCodeMissing: "GL code not specified",
|
|
61
|
-
glCodeUnavailable: "GL code unavailable",
|
|
62
|
-
qtyPriceValue: (e, t) => `${e} x ${t}`,
|
|
63
|
-
qtyOnlyValue: (e) => e,
|
|
64
|
-
subtotalRow: "Subtotal",
|
|
65
|
-
taxRow: "Tax",
|
|
66
|
-
discountRow: "Discounts",
|
|
67
|
-
totalRow: "Total",
|
|
68
|
-
paidOnLabel: (e) => `Paid on ${e}`,
|
|
69
|
-
paymentInstructionsSaveError: "Couldn't save payment instructions. Try again.",
|
|
70
|
-
paymentInstructionsLinkError: "Payment instructions were saved to the vendor, but couldn't be added to this bill. Try again.",
|
|
71
|
-
rejectedByOn: (e, t) => `Rejected by ${e} on ${t}`,
|
|
72
|
-
rejectedOn: (e) => `Rejected on ${e}`,
|
|
73
|
-
rejectionMessage: (e) => `"${e}"`
|
|
74
|
-
}, b = {
|
|
75
|
-
newTitle: "New bill",
|
|
76
|
-
extractedTitle: (e) => `Bill from ${e}`,
|
|
77
|
-
viewTitle: (e) => `Bill from ${e}`,
|
|
78
|
-
readOnlyTitle: "Bill details",
|
|
79
|
-
addedOn: (e) => `Added on ${e}`,
|
|
80
|
-
unsavedChanges: h,
|
|
81
|
-
discardChanges: m,
|
|
82
|
-
scheduledRelativeDay: i,
|
|
83
|
-
scheduledSummary: o,
|
|
84
|
-
scheduledStatusBadge: a,
|
|
85
|
-
awaitingApprovalNotice: e,
|
|
86
|
-
awaitingApprovalUnknownNotice: t,
|
|
87
|
-
actions: n,
|
|
88
|
-
detail: y,
|
|
89
|
-
history: u,
|
|
90
|
-
approvalPolicyCopy: l,
|
|
91
|
-
deleteDraft: {
|
|
92
|
-
menuItem: "Delete draft",
|
|
93
|
-
dialog: {
|
|
94
|
-
title: "Delete this draft?",
|
|
95
|
-
description: "The draft and anything entered on it are removed. This can't be undone.",
|
|
96
|
-
confirmButton: "Delete draft"
|
|
10
|
+
function l({ payable: l, lineItems: u, glCodeOptions: d, glCodeRosterAvailable: f = !0, history: p, paymentHistory: m, approvalPolicy: h, labels: g, hasScheduledPayment: _, rejection: v, payableAchInstructions: y, payableAchInstructionsReadable: b = !1 }) {
|
|
11
|
+
let x = l.currency, S = t({
|
|
12
|
+
apiStatus: l.status,
|
|
13
|
+
dueDate: l.due_date,
|
|
14
|
+
scheduledPaymentDate: l.scheduled_payment_date,
|
|
15
|
+
hasScheduledPayment: _
|
|
16
|
+
}), C = o(l), w = b ? y : void 0, T = w?.account_number, E = !!(w?.account_holder_name && w.routing_number && w.account_number), D = e(l.issued_at) || g.notProvided, O = e(l.due_date) || g.notProvided, k = new Map(d.map((e) => [e.value, e.label])), A = [
|
|
17
|
+
{
|
|
18
|
+
label: g.subtotalRow,
|
|
19
|
+
minorUnits: l.subtotal
|
|
97
20
|
},
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
loadError: "Couldn't load GL codes",
|
|
102
|
-
noAccess: "You don't have access to GL codes",
|
|
103
|
-
empty: "No GL codes set up yet"
|
|
104
|
-
},
|
|
105
|
-
rejectedBanner: p
|
|
106
|
-
};
|
|
107
|
-
function x(e) {
|
|
108
|
-
return {
|
|
109
|
-
...b,
|
|
110
|
-
...e,
|
|
111
|
-
actions: s(e?.actions),
|
|
112
|
-
detail: {
|
|
113
|
-
...b.detail,
|
|
114
|
-
...e?.detail,
|
|
115
|
-
paymentHistoryMethodLabels: c(e?.detail?.paymentHistoryMethodLabels)
|
|
116
|
-
},
|
|
117
|
-
history: {
|
|
118
|
-
...b.history,
|
|
119
|
-
...e?.history
|
|
120
|
-
},
|
|
121
|
-
lineItemsGlCodeUnavailable: {
|
|
122
|
-
...b.lineItemsGlCodeUnavailable,
|
|
123
|
-
...e?.lineItemsGlCodeUnavailable
|
|
124
|
-
},
|
|
125
|
-
unsavedChanges: {
|
|
126
|
-
...b.unsavedChanges,
|
|
127
|
-
...e?.unsavedChanges
|
|
128
|
-
},
|
|
129
|
-
discardChanges: {
|
|
130
|
-
...b.discardChanges,
|
|
131
|
-
...e?.discardChanges
|
|
132
|
-
},
|
|
133
|
-
rejectedBanner: {
|
|
134
|
-
...b.rejectedBanner,
|
|
135
|
-
...e?.rejectedBanner
|
|
21
|
+
{
|
|
22
|
+
label: g.discountRow,
|
|
23
|
+
minorUnits: l.discount
|
|
136
24
|
},
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
},
|
|
141
|
-
scheduledRelativeDay: {
|
|
142
|
-
...b.scheduledRelativeDay,
|
|
143
|
-
...e?.scheduledRelativeDay
|
|
144
|
-
},
|
|
145
|
-
deleteDraft: {
|
|
146
|
-
...b.deleteDraft,
|
|
147
|
-
...e?.deleteDraft,
|
|
148
|
-
dialog: (() => {
|
|
149
|
-
let t = {
|
|
150
|
-
...b.deleteDraft.dialog,
|
|
151
|
-
...e?.deleteDraft?.dialog
|
|
152
|
-
};
|
|
153
|
-
return delete t.reason, t;
|
|
154
|
-
})()
|
|
25
|
+
{
|
|
26
|
+
label: g.taxRow,
|
|
27
|
+
minorUnits: l.tax_amount
|
|
155
28
|
}
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
addAsNewVendor: (e) => `Add "${e}" as a new vendor`,
|
|
167
|
-
addAsNewVendorDescription: "Uses the details extracted from this bill",
|
|
168
|
-
fieldsNeedAttention: (e) => `${e} ${e === 1 ? "field needs" : "fields need"} attention`,
|
|
169
|
-
nameLabel: "Business name",
|
|
170
|
-
cancel: "Cancel",
|
|
171
|
-
save: "Save",
|
|
172
|
-
cancelAriaLabel: "Cancel vendor",
|
|
173
|
-
saveAriaLabel: "Save vendor",
|
|
174
|
-
paymentInstructionsHeading: "Payment instructions",
|
|
175
|
-
paymentInstructionsDescription: "How and where will the money be sent. This information is required to send a payment.",
|
|
176
|
-
paymentInstructionsExtracted: "We read these from the bill. Check them before saving.",
|
|
177
|
-
ach: f
|
|
178
|
-
};
|
|
179
|
-
function C(e) {
|
|
29
|
+
].map((e) => ({
|
|
30
|
+
label: e.label,
|
|
31
|
+
value: n(e.minorUnits, x)
|
|
32
|
+
})).filter((e) => !!e.value), j = n(c(l), x);
|
|
33
|
+
j && A.push({
|
|
34
|
+
label: g.totalRow,
|
|
35
|
+
value: j,
|
|
36
|
+
emphasis: !0
|
|
37
|
+
});
|
|
38
|
+
let M = s(l);
|
|
180
39
|
return {
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
40
|
+
amountDue: n(r(l), x) ?? "",
|
|
41
|
+
amountPaid: M ? n(l.amount_paid, x) : void 0,
|
|
42
|
+
paidOnLabel: M ? g.paidOnLabel(M) : void 0,
|
|
43
|
+
invoiceDateLabel: D,
|
|
44
|
+
dueDateLabel: O,
|
|
45
|
+
dueDateTone: S.isOverdue ? "danger" : "default",
|
|
46
|
+
status: S.status,
|
|
47
|
+
statusTone: S.tone,
|
|
48
|
+
payTo: {
|
|
49
|
+
name: C?.name || g.notProvided,
|
|
50
|
+
email: C?.email ?? "",
|
|
51
|
+
methodLabel: E ? g.paymentInstructionsValue(T?.slice(-4) ?? "") : g.paymentInstructionsNotSet,
|
|
52
|
+
hasPaymentInstructions: E
|
|
53
|
+
},
|
|
54
|
+
invoiceFields: [
|
|
55
|
+
{
|
|
56
|
+
label: g.invoiceDateRow,
|
|
57
|
+
value: D
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
label: g.dueDateRow,
|
|
61
|
+
value: O
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
label: g.invoiceNumberRow,
|
|
65
|
+
value: l.document_id || g.notProvided
|
|
189
66
|
}
|
|
190
|
-
|
|
67
|
+
],
|
|
68
|
+
lineItems: u.map((e) => {
|
|
69
|
+
let t = n(e.unit_price, x), r = String(a(e));
|
|
70
|
+
return {
|
|
71
|
+
id: e.id,
|
|
72
|
+
description: e.name ?? e.description ?? "",
|
|
73
|
+
glCodeLabel: e.ledger_account_id ? k.get(e.ledger_account_id) ?? (f ? g.glCodeMissing : g.glCodeUnavailable) : g.glCodeMissing,
|
|
74
|
+
qtyPriceLabel: t ? g.qtyPriceValue(r, t) : g.qtyOnlyValue(r),
|
|
75
|
+
amount: n(i(e), x) ?? ""
|
|
76
|
+
};
|
|
77
|
+
}),
|
|
78
|
+
amountRows: A,
|
|
79
|
+
approvalPolicy: h,
|
|
80
|
+
paymentHistory: m,
|
|
81
|
+
history: p,
|
|
82
|
+
rejection: v
|
|
191
83
|
};
|
|
192
84
|
}
|
|
193
85
|
//#endregion
|
|
194
|
-
export {
|
|
86
|
+
export { l as buildBillDetailView };
|
|
@@ -1,83 +1,6 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
"use client";
|
|
3
|
-
"use client";
|
|
4
|
-
"use client";
|
|
5
|
-
import { createSourceDocumentPreview as e } from "./index24.js";
|
|
6
|
-
import { SourceDocumentPanel as t } from "../../ui/dist/index49.js";
|
|
7
|
-
import "../../ui/dist/index.js";
|
|
8
|
-
import { SOURCE_DOCUMENT_CONTAINER_LABELS_EN as n } from "./index25.js";
|
|
9
|
-
import { useAttachPayableFileMutation as r } from "../../data-access/dist/index5.js";
|
|
10
|
-
import "../../data-access/dist/index.js";
|
|
11
|
-
import { useEffect as i, useState as a } from "react";
|
|
12
|
-
import { jsx as o } from "react/jsx-runtime";
|
|
13
1
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index26.js
|
|
14
|
-
function
|
|
15
|
-
|
|
16
|
-
return i(() => {
|
|
17
|
-
if (!e) {
|
|
18
|
-
n(void 0);
|
|
19
|
-
return;
|
|
20
|
-
}
|
|
21
|
-
let t = URL.createObjectURL(e);
|
|
22
|
-
return n(t), () => URL.revokeObjectURL(t);
|
|
23
|
-
}, [e]), t;
|
|
24
|
-
}
|
|
25
|
-
function c({ payableId: i, file: a, isDocumentPending: c, pendingFileName: l, readOnly: u, staging: d, deletion: f, labels: p }) {
|
|
26
|
-
let { stagedFile: m, onFileStaged: h, onClearStagedFile: g, isSaving: _ } = d ?? {}, { isPending: v, onRequest: y, onDetachNow: b, isDeleting: x, hasFailed: S } = f ?? {}, C = {
|
|
27
|
-
...n,
|
|
28
|
-
...p,
|
|
29
|
-
preview: {
|
|
30
|
-
...n.preview,
|
|
31
|
-
...p?.preview
|
|
32
|
-
}
|
|
33
|
-
}, w = r(), T = s(m), E = !!(a && !v || m);
|
|
34
|
-
if (!E && (c || w.isPending)) return /* @__PURE__ */ o(t, {
|
|
35
|
-
mode: "loading",
|
|
36
|
-
fileName: l,
|
|
37
|
-
labels: p?.panel
|
|
38
|
-
});
|
|
39
|
-
if (!E && u) return /* @__PURE__ */ o("div", {
|
|
40
|
-
className: "ttw:rounded-lg ttw:border ttw:border-border ttw:bg-card ttw:p-4 ttw:text-sm ttw:text-muted-foreground",
|
|
41
|
-
children: C.noDocument
|
|
42
|
-
});
|
|
43
|
-
if (!E) return /* @__PURE__ */ o(t, {
|
|
44
|
-
mode: "upload",
|
|
45
|
-
labels: p?.panel,
|
|
46
|
-
uploadStatus: w.isPending || x ? "uploading" : "idle",
|
|
47
|
-
uploadErrorMessage: w.isError ? C.attachFailed : S ? C.deleteFailed : void 0,
|
|
48
|
-
noticeMessage: v && !S ? C.pendingDeletionNotice : void 0,
|
|
49
|
-
onFilesSelected: (e) => {
|
|
50
|
-
let [t] = e;
|
|
51
|
-
if (t) {
|
|
52
|
-
if (i) {
|
|
53
|
-
let e = () => w.mutate({
|
|
54
|
-
path: { payable_id: i },
|
|
55
|
-
file: t
|
|
56
|
-
});
|
|
57
|
-
if (v && b) {
|
|
58
|
-
b().then(e, () => void 0);
|
|
59
|
-
return;
|
|
60
|
-
}
|
|
61
|
-
e();
|
|
62
|
-
} else h?.(t);
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
});
|
|
66
|
-
let D = a?.name ?? m?.name ?? "", O = e(a || {
|
|
67
|
-
name: D,
|
|
68
|
-
url: T ?? "",
|
|
69
|
-
mimetype: m?.type ?? ""
|
|
70
|
-
}, C.preview);
|
|
71
|
-
return /* @__PURE__ */ o(t, {
|
|
72
|
-
mode: "document",
|
|
73
|
-
labels: p?.panel,
|
|
74
|
-
fileName: D,
|
|
75
|
-
preview: O,
|
|
76
|
-
isDeleting: x,
|
|
77
|
-
deleteErrorMessage: S ? C.deleteFailed : void 0,
|
|
78
|
-
onDownload: a ? () => window.open(a.url, "_blank", "noopener,noreferrer") : void 0,
|
|
79
|
-
onDelete: u ? void 0 : a && i ? y : _ ? void 0 : g
|
|
80
|
-
});
|
|
2
|
+
function e({ isUnsavedPromptOpen: e, isLocked: t, isDirty: n }) {
|
|
3
|
+
return e ? "dismiss-prompt" : !t && n ? "prompt" : "close";
|
|
81
4
|
}
|
|
82
5
|
//#endregion
|
|
83
|
-
export {
|
|
6
|
+
export { e as resolveEditorDismissal };
|
|
@@ -1,74 +1,57 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import "../../../../shared/counterpart-management/feature/dist/index.js";
|
|
1
|
+
import { formatCalendarDate as e } from "../../../../shared/util/dist/lib/formatCalendarDate.js";
|
|
2
|
+
import { formatBillMoney as t } from "../../../util/dist/lib/formatBillMoney.js";
|
|
4
3
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index27.js
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
phone: r(e.phone),
|
|
58
|
-
address: {
|
|
59
|
-
...n?.address,
|
|
60
|
-
line1: r(a.line1),
|
|
61
|
-
line2: r(a.line2),
|
|
62
|
-
city: r(a.city),
|
|
63
|
-
state: r(a.state),
|
|
64
|
-
postal_code: r(a.postalCode)
|
|
65
|
-
},
|
|
66
|
-
bank_account: {
|
|
67
|
-
account_holder_name: r(t.accountHolderName),
|
|
68
|
-
routing_number: r(t.routingNumber),
|
|
69
|
-
account_number: r(t.accountNumber)
|
|
70
|
-
}
|
|
71
|
-
};
|
|
72
|
-
}
|
|
4
|
+
var n = {
|
|
5
|
+
dateLabel: (e) => new Date(e).toLocaleDateString("en-US", {
|
|
6
|
+
month: "short",
|
|
7
|
+
day: "numeric",
|
|
8
|
+
year: "numeric"
|
|
9
|
+
}),
|
|
10
|
+
timeLabel: (e) => new Date(e).toLocaleTimeString(void 0, {
|
|
11
|
+
hour: "numeric",
|
|
12
|
+
minute: "2-digit",
|
|
13
|
+
timeZoneName: "short"
|
|
14
|
+
}),
|
|
15
|
+
byActor: (e, t) => `${e} by ${t}`,
|
|
16
|
+
formatAmount: (e) => t(e) ?? "",
|
|
17
|
+
billCreated: "Bill created",
|
|
18
|
+
createdManually: "Data entered manually",
|
|
19
|
+
createdFromUpload: "File uploaded and scanned automatically",
|
|
20
|
+
billCreatedByEmail: "Bill created by email",
|
|
21
|
+
sentFrom: (e) => `Sent from ${e}`,
|
|
22
|
+
billDetailsUpdated: "Bill details updated",
|
|
23
|
+
filledInFromFile: "Filled in from the attached file",
|
|
24
|
+
submittedForReview: "Finalized and submitted for review",
|
|
25
|
+
approvalRequested: "Approval requested",
|
|
26
|
+
approved: "Approved",
|
|
27
|
+
approvedAutomatically: "Auto-approved",
|
|
28
|
+
rejected: "Rejected",
|
|
29
|
+
policyOverrideApproved: "Policy override: Approved",
|
|
30
|
+
policyOverrideRejected: "Policy override: Rejected",
|
|
31
|
+
quotedReason: (e) => `"${e}"`,
|
|
32
|
+
cancelled: "Cancelled",
|
|
33
|
+
reopened: "Re-opened",
|
|
34
|
+
paymentReleased: "Payment released",
|
|
35
|
+
paid: (e) => `Paid ${e}`,
|
|
36
|
+
paymentReverted: "Payment reverted",
|
|
37
|
+
calendarDateLabel: (t) => e(t),
|
|
38
|
+
paymentScheduled: "Payment scheduled",
|
|
39
|
+
scheduledFor: (e) => `Scheduled for ${e}`,
|
|
40
|
+
scheduledPaymentCancelled: "Scheduled payment cancelled",
|
|
41
|
+
cancelledAsBillChanged: "The bill was changed",
|
|
42
|
+
cancelledAsBillDeleted: "The bill was deleted",
|
|
43
|
+
paymentFailed: "Payment failed",
|
|
44
|
+
billMarkedAsFullyPaid: "Bill marked as fully paid",
|
|
45
|
+
billMarkedAsPartiallyPaid: "Bill marked as partially paid",
|
|
46
|
+
draftDeleted: "Draft deleted",
|
|
47
|
+
fileAttached: "File attached",
|
|
48
|
+
fileRemoved: "File removed",
|
|
49
|
+
creditNoteLinked: "Credit note linked",
|
|
50
|
+
creditNoteUnlinked: "Credit note unlinked",
|
|
51
|
+
lineItemsUpdated: "Line items updated",
|
|
52
|
+
lineItemAdded: "Line item added",
|
|
53
|
+
lineItemUpdated: "Line item updated",
|
|
54
|
+
lineItemRemoved: "Line item removed"
|
|
55
|
+
};
|
|
73
56
|
//#endregion
|
|
74
|
-
export {
|
|
57
|
+
export { n as PAYABLE_AUDIT_HISTORY_LABELS_EN };
|