@tesouro/embedded-components-react 0.11.253 → 0.11.254

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.
Files changed (111) hide show
  1. package/dist/index.css +9 -344
  2. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index23.js +35 -38
  3. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index26.js +21 -14
  4. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index27.js +3 -105
  5. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index28.js +4 -0
  6. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index31.js +47 -47
  7. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index32.js +1 -1
  8. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index34.js +1 -1
  9. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index4.js +87 -90
  10. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index44.js +238 -248
  11. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index46.js +15 -34
  12. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index47.js +199 -202
  13. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/feature/dist/index5.js +16 -14
  14. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index.js +25 -25
  15. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index10.js +18 -32
  16. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index11.js +150 -19
  17. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index12.js +2 -150
  18. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index13.js +75 -1
  19. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index14.js +272 -70
  20. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index15.js +1 -279
  21. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index16.js +20 -2
  22. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index17.js +51 -16
  23. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index18.js +2 -55
  24. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index19.js +34 -2
  25. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index20.js +369 -30
  26. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index21.js +2 -373
  27. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index22.js +22 -2
  28. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index23.js +124 -20
  29. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index24.js +2 -126
  30. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index25.js +30 -1
  31. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index26.js +51 -29
  32. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index27.js +1 -52
  33. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index28.js +54 -1
  34. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index29.js +10 -54
  35. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index3.js +35 -35
  36. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index30.js +133 -10
  37. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index31.js +1 -198
  38. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index32.js +30 -2
  39. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index33.js +52 -43
  40. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index34.js +2 -315
  41. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index35.js +15 -2
  42. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index36.js +158 -14
  43. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index37.js +2 -162
  44. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index38.js +3 -2
  45. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index39.js +19 -2
  46. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index40.js +2 -35
  47. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index41.js +9 -2
  48. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index42.js +31 -8
  49. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index43.js +2 -33
  50. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index44.js +6 -2
  51. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index45.js +27 -5
  52. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index46.js +2 -29
  53. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index47.js +13 -2
  54. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index48.js +100 -11
  55. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index49.js +2 -107
  56. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index5.js +12 -16
  57. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index50.js +9 -2
  58. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index51.js +41 -8
  59. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index52.js +2 -52
  60. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index6.js +1 -22
  61. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index7.js +31 -1
  62. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index8.js +1 -31
  63. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index9.js +34 -1
  64. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bills-list/feature/dist/index14.js +1 -3
  65. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bills-list/feature/dist/index19.js +2 -6
  66. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bills-list/ui/dist/index15.js +1 -1
  67. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bills-list/ui/dist/index17.js +2 -6
  68. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/feature/dist/index10.js +119 -104
  69. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/feature/dist/index11.js +2 -2
  70. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/feature/dist/index14.js +1 -1
  71. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/feature/dist/index2.js +2 -1
  72. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/feature/dist/index4.js +11 -11
  73. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/feature/dist/index9.js +9 -4
  74. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/ui/dist/index.js +8 -8
  75. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/ui/dist/index10.js +76 -171
  76. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/ui/dist/index11.js +1 -1
  77. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/ui/dist/index12.js +33 -0
  78. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/ui/dist/index13.js +9 -0
  79. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/ui/dist/index14.js +126 -0
  80. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/ui/dist/index15.js +2 -0
  81. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/ui/dist/index2.js +23 -29
  82. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/ui/dist/index3.js +32 -126
  83. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/ui/dist/index4.js +14 -2
  84. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/ui/dist/index5.js +3 -13
  85. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/ui/dist/index6.js +28 -104
  86. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/ui/dist/index7.js +72 -1
  87. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/ui/dist/index8.js +2 -33
  88. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/ui/dist/index9.js +12 -7
  89. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index.js +6 -9
  90. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index12.js +6 -9
  91. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index13.js +32 -31
  92. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index2.js +4 -2
  93. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index3.js +15 -5
  94. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index4.js +53 -84
  95. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/util/dist/index.js +17 -18
  96. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/util/dist/lib/billDetailLabels.js +12 -12
  97. package/dist/libs/tesouro-embedded-components-react/shared/document-status/ui/dist/index.js +4 -4
  98. package/dist/libs/tesouro-embedded-components-react/shared/document-status/ui/dist/index3.js +9 -9
  99. package/dist/libs/tesouro-embedded-components-react/shared/document-status/ui/dist/index4.js +13 -14
  100. package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
  101. package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/document/documentPreview.js +1 -1
  102. package/dist/libs/tesouro-embedded-components-react/shared/ui/dist/index.js +20 -19
  103. package/dist/libs/tesouro-embedded-components-react/shared/ui/dist/lib/MaskedAccountNumber/MaskedAccountNumber.js +30 -34
  104. package/dist/libs/tesouro-embedded-components-react/shared/ui/dist/lib/TooltipIconButton/TooltipIconButton.js +55 -0
  105. package/dist/packages/shared-ui-shadcn/dist/index.js +1322 -1312
  106. package/package.json +1 -1
  107. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/bill-detail/ui/dist/index53.js +0 -2
  108. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index22.js +0 -6
  109. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index23.js +0 -31
  110. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index24.js +0 -2
  111. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/util/dist/lib/maskAccountNumber.js +0 -5
@@ -11,150 +11,165 @@ import "../../../../shared/data-access/dist/index.js";
11
11
  import "../../../../shared/ui/dist/index.js";
12
12
  import { useAnalyticsCaptureException as i } from "../../../../shared/feature/dist/lib/analytics/hooks.js";
13
13
  import "../../../../shared/feature/dist/index.js";
14
- import { maskAccountNumber as a } from "../../../util/dist/lib/maskAccountNumber.js";
15
14
  import "../../../util/dist/index.js";
16
- import { dateToCalendarKey as o, getDefaultPaymentDate as s, isPastEasternDate as c, isTodayInEastern as l } from "./index3.js";
17
- import { useSchedulePaymentMutation as u } from "../../data-access/dist/index5.js";
15
+ import { dateToCalendarKey as a, getDefaultPaymentDate as o, isPastEasternDate as s, isTodayInEastern as c } from "./index3.js";
16
+ import { useSchedulePaymentMutation as ee } from "../../data-access/dist/index5.js";
18
17
  import "../../data-access/dist/index.js";
19
- import { deriveSourceAccountFunds as d, mapSourceAccountOptions as ee } from "./index8.js";
20
- import { mergePayBillFlowLabels as f } from "./index9.js";
21
- import { useMemo as p, useState as m } from "react";
18
+ import { deriveSourceAccountFunds as l, mapSourceAccountOptions as u } from "./index8.js";
19
+ import { mergePayBillFlowLabels as te } from "./index9.js";
20
+ import { useMemo as d, useState as f } from "react";
22
21
  // ../../libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/feature/dist/index10.js
23
- function h(e) {
22
+ function p(e) {
24
23
  return !!(e?.account_holder_name && e.routing_number && e.account_number);
25
24
  }
26
- function g({ selectedDate: e, selectedAccount: t, amountDueMinorUnits: n, labels: r }) {
27
- if (!e) return {
25
+ function m({ selectedDate: e, selectedAccount: t, amountDueMinorUnits: n, labels: r }) {
26
+ let i = {};
27
+ if (e ? s(e) && (i.paymentDate = r.staleDateError) : i.paymentDate = r.selectDateError, !t) i.sourceAccount = r.selectAccountError;
28
+ else if (e) {
29
+ let a = l({
30
+ selectedAccount: t,
31
+ amountDueMinorUnits: n,
32
+ isToday: c(e),
33
+ labels: r
34
+ });
35
+ a.state === "error" && (i.sourceAccount = a.message ?? r.todayInsufficientFunds);
36
+ }
37
+ return !e || !t || i.paymentDate || i.sourceAccount ? {
28
38
  ok: !1,
29
- error: r.selectDateError
30
- };
31
- if (c(e)) return {
32
- ok: !1,
33
- error: r.staleDateError
34
- };
35
- if (!t) return {
36
- ok: !1,
37
- error: r.selectAccountError
38
- };
39
- let i = d({
40
- selectedAccount: t,
41
- amountDueMinorUnits: n,
42
- isToday: l(e),
43
- labels: r
44
- });
45
- return i.state === "error" ? {
46
- ok: !1,
47
- error: i.message ?? r.todayInsufficientFunds
39
+ errors: i
48
40
  } : {
49
41
  ok: !0,
50
42
  date: e,
51
43
  account: t
52
44
  };
53
45
  }
54
- function _({ payableId: c, amountDueMinorUnits: _, currencyCode: v = "USD", dueDate: y, vendorName: b, vendorEmail: x, vendorBankAccount: S, isVendorBankAccountLoading: te, isVendorBankAccountError: ne, onMissingAchInstructions: C, poweredByBankName: w, isOpen: T, onOpenChange: E, labels: D }) {
55
- let O = p(() => f(D), [D]), k = b ?? O.missingVendorName, [A, j] = m(!1), M = T ?? A, N = (e) => {
56
- T === void 0 && j(e), E?.(e);
57
- }, [P, F] = m("schedule"), I = M && P === "schedule", L = M && P === "review", [R, z] = m(() => s()), [B, V] = m(), H = r({ enabled: I || L }), U = u(), W = i(), G = p(() => ee(H.data?.data ?? [], O), [H.data?.data, O]), K = G.find((e) => e.id === B), q = R ? l(R) : !1, J = { before: s() }, Y = d({
58
- selectedAccount: K,
59
- amountDueMinorUnits: _,
60
- isToday: q,
61
- labels: O
62
- }), X = n(_ / 100, { currencyCode: v }), Z = R ? t(o(R)) : void 0, re = y ? O.dueDateSuffix(t(y)) : void 0, Q = () => g({
63
- selectedDate: R,
64
- selectedAccount: K,
65
- amountDueMinorUnits: _,
66
- labels: O
67
- }), ie = () => {
68
- te ? e.error(O.checkingPaymentInstructionsError) : ne ? e.error(O.paymentInstructionsUnavailableError) : h(S) ? (F("schedule"), N(!0)) : C ? C() : e.error(O.missingPaymentInstructionsError);
46
+ function h({ payableId: s, amountDueMinorUnits: h, currencyCode: g = "USD", dueDate: _, vendorName: ne, vendorEmail: re, vendorBankAccount: v, isVendorBankAccountLoading: y, isVendorBankAccountError: b, onMissingAchInstructions: x, poweredByBankName: S, isOpen: C, onOpenChange: w, labels: T }) {
47
+ let E = d(() => te(T), [T]), D = ne ?? E.missingVendorName, [O, k] = f(!1), A = C ?? O, j = (e) => {
48
+ C === void 0 && k(e), w?.(e);
49
+ }, [M, N] = f("schedule"), [P, F] = f({}), [ie, I] = f(), L = A && M === "schedule", R = A && (M === "review" || M === "result"), [z, B] = f(() => o()), [V, H] = f(), U = r({ enabled: L || R }), W = ee(), G = i(), K = d(() => u(U.data?.data ?? [], E), [U.data?.data, E]), q = K.find((e) => e.id === V), J = z ? c(z) : !1, ae = o(), oe = l({
50
+ selectedAccount: q,
51
+ amountDueMinorUnits: h,
52
+ isToday: J,
53
+ labels: E
54
+ }), Y = n(h / 100, { currencyCode: g }), se = z ? t(a(z)) : void 0, X = {
55
+ label: E.sourceAccount,
56
+ value: q?.primaryLabel ?? ""
57
+ }, Z = {
58
+ label: E.paymentDate,
59
+ value: se ?? ""
60
+ }, ce = _ ? E.dueDateSuffix(t(_)) : void 0, Q = () => m({
61
+ selectedDate: z,
62
+ selectedAccount: q,
63
+ amountDueMinorUnits: h,
64
+ labels: E
65
+ }), le = () => {
66
+ y ? e.error(E.checkingPaymentInstructionsError) : b ? e.error(E.paymentInstructionsUnavailableError) : p(v) ? (N("schedule"), F({}), I(void 0), j(!0)) : x ? x() : e.error(E.missingPaymentInstructionsError);
69
67
  }, $ = () => {
70
- N(!1);
68
+ j(!1);
71
69
  };
72
70
  return {
73
- open: ie,
71
+ open: le,
74
72
  dialogProps: {
75
- open: I,
73
+ open: L,
76
74
  onOpenChange: (e) => {
77
- e && F("schedule"), N(e);
75
+ e && N("schedule"), j(e);
76
+ },
77
+ amountDueLabel: E.amountDue,
78
+ amountDue: Y,
79
+ dueDateSuffix: ce,
80
+ paymentAmountLabel: E.paymentAmount,
81
+ paymentAmount: Y,
82
+ selectedDate: z,
83
+ minDate: ae,
84
+ isToday: J,
85
+ selectedAccountId: V,
86
+ accounts: K,
87
+ poweredByBankName: S,
88
+ funds: oe,
89
+ errors: P,
90
+ isAccountsLoading: U.isLoading,
91
+ isAccountsError: U.isError,
92
+ isSubmitting: W.isPending,
93
+ onDateChange: (e) => {
94
+ B(e), F(({ sourceAccount: e }) => e === E.selectAccountError ? { sourceAccount: e } : {});
95
+ },
96
+ onAccountChange: (e) => {
97
+ H(e), F(({ paymentDate: e }) => ({ paymentDate: e }));
78
98
  },
79
- amountDueLabel: O.amountDue,
80
- amountDue: X,
81
- dueDateSuffix: re,
82
- paymentAmountLabel: O.paymentAmount,
83
- paymentAmount: X,
84
- selectedDate: R,
85
- selectedDateLabel: Z,
86
- calendarDisabled: J,
87
- isToday: q,
88
- selectedAccountId: B,
89
- accounts: G,
90
- poweredByBankName: w,
91
- funds: Y,
92
- isAccountsLoading: H.isLoading,
93
- isAccountsError: H.isError,
94
- isSubmitting: U.isPending,
95
- onDateChange: z,
96
- onAccountChange: V,
97
99
  onReview: () => {
98
- let t = Q();
99
- t.ok ? F("review") : e.error(t.error);
100
+ let e = Q();
101
+ e.ok ? (F({}), I(void 0), N("review")) : F(e.errors);
100
102
  },
101
103
  onCancel: $,
102
- labels: O.scheduleDialog
104
+ labels: E.scheduleDialog
103
105
  },
104
106
  reviewProps: {
105
- open: L,
107
+ open: R,
106
108
  onOpenChange: (e) => {
107
- e || N(!1);
109
+ e || j(!1);
108
110
  },
109
- amountLabel: O.paymentAmount,
110
- amount: X,
111
- rows: [{
112
- label: O.sourceAccount,
113
- value: K?.primaryLabel ?? ""
114
- }, {
115
- label: O.paymentDate,
116
- value: Z ?? ""
117
- }],
111
+ amountLabel: E.paymentAmount,
112
+ amount: Y,
113
+ rows: [X, Z],
118
114
  payTo: {
119
- name: k,
120
- email: x,
121
- methodLabel: O.achMethod,
122
- fields: h(S) ? [
115
+ name: D,
116
+ email: re,
117
+ methodLabel: E.achMethod,
118
+ fields: p(v) ? [
123
119
  {
124
- label: O.routingNumber,
125
- value: S.routing_number
120
+ label: E.routingNumber,
121
+ value: v.routing_number
126
122
  },
127
123
  {
128
- label: O.accountNumber,
129
- value: S.account_number,
130
- maskedValue: a(S.account_number)
124
+ label: E.accountNumber,
125
+ accountNumber: v.account_number
131
126
  },
132
127
  {
133
- label: O.accountHolder,
134
- value: S.account_holder_name
128
+ label: E.accountHolder,
129
+ value: v.account_holder_name
135
130
  }
136
131
  ] : []
137
132
  },
138
- isSubmitting: U.isPending,
133
+ isSubmitting: W.isPending,
134
+ submitError: ie,
139
135
  onBack: () => {
140
- F("schedule");
136
+ N("schedule");
141
137
  },
142
138
  onCancel: $,
143
139
  onSubmit: async () => {
144
- let t = Q();
145
- if (!t.ok) e.error(t.error), F("schedule");
146
- else try {
147
- await U.mutateAsync({
148
- payableId: c,
149
- paymentDate: o(t.date),
150
- sourceBankAccountId: t.account.id
151
- }), $(), e.success(O.scheduledToast);
152
- } catch (t) {
153
- t instanceof Error && W(t), $(), e.error(O.submitError);
140
+ let e = Q();
141
+ if (!e.ok) F(e.errors), N("schedule");
142
+ else {
143
+ I(void 0);
144
+ try {
145
+ await W.mutateAsync({
146
+ payableId: s,
147
+ paymentDate: a(e.date),
148
+ sourceBankAccountId: e.account.id
149
+ }), N("result");
150
+ } catch (e) {
151
+ e instanceof Error && G(e), I(E.submitError);
152
+ }
154
153
  }
155
154
  },
156
- labels: O.reviewDialog
155
+ result: M === "result" ? {
156
+ title: E.scheduledTitle,
157
+ details: [
158
+ {
159
+ label: E.paymentAmount,
160
+ value: Y
161
+ },
162
+ Z,
163
+ X,
164
+ {
165
+ label: E.payTo,
166
+ value: D
167
+ }
168
+ ]
169
+ } : void 0,
170
+ onDone: $,
171
+ labels: E.reviewDialog
157
172
  }
158
173
  };
159
174
  }
160
- export { _ as usePayBillFlow };
175
+ export { h as usePayBillFlow };
@@ -9,8 +9,8 @@ import { resolveVendor as n } from "../../../util/dist/lib/resolveVendor.js";
9
9
  import "../../../util/dist/index.js";
10
10
  import { usePayableAchInstructions as r } from "../../../../shared/counterpart-management/feature/dist/lib/usePayableAchInstructions.js";
11
11
  import "../../../../shared/counterpart-management/feature/dist/index.js";
12
- import { ReviewTransactionDialog as i } from "../../ui/dist/index6.js";
13
- import { SchedulePaymentDialog as a } from "../../ui/dist/index10.js";
12
+ import { ReviewTransactionDialog as i } from "../../ui/dist/index10.js";
13
+ import { SchedulePaymentDialog as a } from "../../ui/dist/index14.js";
14
14
  import "../../ui/dist/index.js";
15
15
  import { canReadCounterpartBankAccounts as o } from "./index6.js";
16
16
  import { payBillFlowTestIds as s } from "./index7.js";
@@ -7,7 +7,7 @@ import { WidgetProvider as t } from "../../../../shared/feature/dist/lib/WidgetP
7
7
  import "../../../../shared/feature/dist/index.js";
8
8
  import { resolveAmountDueMinorUnits as n } from "../../../util/dist/lib/resolveAmountDue.js";
9
9
  import "../../../util/dist/index.js";
10
- import { MarkAsPaidDialog as r } from "../../ui/dist/index3.js";
10
+ import { MarkAsPaidDialog as r } from "../../ui/dist/index7.js";
11
11
  import "../../ui/dist/index.js";
12
12
  import { useMarkAsPaidFlow as i } from "./index4.js";
13
13
  import "./index5.js";
@@ -1,10 +1,11 @@
1
- import { MARK_AS_PAID_DIALOG_LABELS_EN as e, mergeMarkAsPaidDialogLabels as t } from "../../ui/dist/index2.js";
1
+ import { MARK_AS_PAID_DIALOG_LABELS_EN as e, mergeMarkAsPaidDialogLabels as t } from "../../ui/dist/index6.js";
2
2
  import "../../ui/dist/index.js";
3
3
  // ../../libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/feature/dist/index2.js
4
4
  var n = {
5
5
  dueDateSuffix: (e) => `by ${e}`,
6
6
  paidToast: "Bill marked as paid",
7
7
  submitError: "Couldn't mark this bill as paid. Try again.",
8
+ paymentDateRequired: "Choose a payment date.",
8
9
  dialog: e
9
10
  };
10
11
  function r(e) {
@@ -16,8 +16,8 @@ import { useCallback as c, useEffect as l, useState as u } from "react";
16
16
  function d({ payableId: d, amountDueMinorUnits: f, amountToPayMinorUnits: p, currencyCode: m, dueDate: h, hasScheduledPayment: g, isOpen: _, onOpenChange: v, testId: y, labels: b }) {
17
17
  let x = r(b), S = s(), [C, w] = u(!1), T = _ !== void 0, E = _ ?? C, D = c((e) => {
18
18
  T || w(e), v?.(e);
19
- }, [T, v]), [O, k] = u(void 0), [A, j] = u(""), M = E && !g, N = n(f / 100, { currencyCode: m }), P = n((p ?? f) / 100, { currencyCode: m }), F = O ? t(i(O)) : void 0, I = h ? x.dueDateSuffix(t(h)) : void 0, L = () => {
20
- D(!1), k(void 0), j("");
19
+ }, [T, v]), [O, k] = u(void 0), [A, j] = u(""), [M, N] = u(!1), P = E && !g, F = n(f / 100, { currencyCode: m }), I = n((p ?? f) / 100, { currencyCode: m }), L = h ? x.dueDateSuffix(t(h)) : void 0, R = () => {
20
+ D(!1), k(void 0), j(""), N(!1);
21
21
  };
22
22
  return l(() => {
23
23
  g && (E && D(!1), k(void 0), j(""));
@@ -31,19 +31,19 @@ function d({ payableId: d, amountDueMinorUnits: f, amountToPayMinorUnits: p, cur
31
31
  },
32
32
  isPending: S.isPending,
33
33
  dialogProps: {
34
- open: M,
35
- amountDue: N,
36
- dueDateSuffix: I,
37
- paymentAmount: P,
34
+ open: P,
35
+ amountDue: F,
36
+ dueDateSuffix: L,
37
+ paymentAmount: I,
38
38
  selectedDate: O,
39
- selectedDateLabel: F,
40
39
  isToday: O ? o(O) : !1,
40
+ paymentDateError: M && !O ? x.paymentDateRequired : void 0,
41
41
  comment: A,
42
42
  isSubmitting: S.isPending,
43
43
  onDateChange: k,
44
44
  onCommentChange: j,
45
45
  onConfirm: () => {
46
- d && O && !S.isPending && !g && S.mutate({
46
+ !d || S.isPending || g || (O ? S.mutate({
47
47
  path: { payable_id: d },
48
48
  body: {
49
49
  paid_at: `${i(O)}T12:00:00.000Z`,
@@ -52,15 +52,15 @@ function d({ payableId: d, amountDueMinorUnits: f, amountToPayMinorUnits: p, cur
52
52
  }
53
53
  }, {
54
54
  onSuccess: () => {
55
- e.success(x.paidToast), L();
55
+ e.success(x.paidToast), R();
56
56
  },
57
57
  onError: () => {
58
58
  e.error(x.submitError);
59
59
  }
60
- });
60
+ }) : N(!0));
61
61
  },
62
62
  onCancel: () => {
63
- S.isPending || L();
63
+ S.isPending || R();
64
64
  },
65
65
  testId: y ? `${y}-mark-as-paid-dialog` : void 0,
66
66
  confirmTestId: y ? `${y}-mark-as-paid-confirm` : void 0,
@@ -1,5 +1,5 @@
1
- import { REVIEW_TRANSACTION_DIALOG_LABELS_EN as e } from "../../ui/dist/index5.js";
2
- import { SCHEDULE_PAYMENT_DIALOG_LABELS_EN as t, mergeSchedulePaymentDialogLabels as n } from "../../ui/dist/index8.js";
1
+ import { REVIEW_TRANSACTION_DIALOG_LABELS_EN as e } from "../../ui/dist/index9.js";
2
+ import { SCHEDULE_PAYMENT_DIALOG_LABELS_EN as t, mergeSchedulePaymentDialogLabels as n } from "../../ui/dist/index12.js";
3
3
  import "../../ui/dist/index.js";
4
4
  import { SOURCE_ACCOUNT_LABELS_EN as r } from "./index8.js";
5
5
  // ../../libs/tesouro-embedded-components-react/bill-pay-widget/pay-bill/feature/dist/index9.js
@@ -13,7 +13,8 @@ var i = {
13
13
  routingNumber: "Routing number",
14
14
  accountNumber: "Account number",
15
15
  achMethod: "Pay by ACH bank transfer",
16
- scheduledToast: "Payment scheduled",
16
+ scheduledTitle: "Payment scheduled",
17
+ payTo: "Pay to",
17
18
  submitError: "Couldn't schedule this payment. Try again.",
18
19
  selectAccountError: "Select a source account.",
19
20
  selectDateError: "Select a payment date.",
@@ -33,7 +34,11 @@ function a(e) {
33
34
  scheduleDialog: n(e?.scheduleDialog),
34
35
  reviewDialog: {
35
36
  ...i.reviewDialog,
36
- ...e?.reviewDialog
37
+ ...e?.reviewDialog,
38
+ maskedAccountNumber: {
39
+ ...i.reviewDialog.maskedAccountNumber,
40
+ ...e?.reviewDialog?.maskedAccountNumber
41
+ }
37
42
  }
38
43
  };
39
44
  }
@@ -1,10 +1,10 @@
1
- import { MARK_AS_PAID_DIALOG_LABELS_EN as e, mergeMarkAsPaidDialogLabels as t } from "./index2.js";
2
- import { MarkAsPaidDialog as n } from "./index3.js";
3
- import "./index4.js";
4
- import { REVIEW_TRANSACTION_DIALOG_LABELS_EN as r } from "./index5.js";
5
- import { ReviewTransactionDialog as i } from "./index6.js";
6
- import "./index7.js";
7
- import { SCHEDULE_PAYMENT_DIALOG_LABELS_EN as a, mergeSchedulePaymentDialogLabels as o } from "./index8.js";
8
- import { SchedulePaymentDialog as s } from "./index10.js";
1
+ import { MARK_AS_PAID_DIALOG_LABELS_EN as e, mergeMarkAsPaidDialogLabels as t } from "./index6.js";
2
+ import { MarkAsPaidDialog as n } from "./index7.js";
3
+ import "./index8.js";
4
+ import { REVIEW_TRANSACTION_DIALOG_LABELS_EN as r } from "./index9.js";
5
+ import { ReviewTransactionDialog as i } from "./index10.js";
9
6
  import "./index11.js";
7
+ import { SCHEDULE_PAYMENT_DIALOG_LABELS_EN as a, mergeSchedulePaymentDialogLabels as o } from "./index12.js";
8
+ import { SchedulePaymentDialog as s } from "./index14.js";
9
+ import "./index15.js";
10
10
  export { e as MARK_AS_PAID_DIALOG_LABELS_EN, n as MarkAsPaidDialog, r as REVIEW_TRANSACTION_DIALOG_LABELS_EN, i as ReviewTransactionDialog, a as SCHEDULE_PAYMENT_DIALOG_LABELS_EN, s as SchedulePaymentDialog, t as mergeMarkAsPaidDialogLabels, o as mergeSchedulePaymentDialogLabels };