@gusto/embedded-react-sdk 0.55.3 → 0.55.5

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 (99) hide show
  1. package/CHANGELOG.md +29 -0
  2. package/dist/components/Common/DataView/DataCards/DataCards.d.ts +2 -1
  3. package/dist/components/Common/DataView/DataCards/DataCards.js +63 -54
  4. package/dist/components/Common/DataView/DataCards/DataCards.js.map +1 -1
  5. package/dist/components/Common/DataView/DataCards/DataCards.module.scss.js +14 -12
  6. package/dist/components/Common/DataView/DataCards/DataCards.module.scss.js.map +1 -1
  7. package/dist/components/Common/DataView/DataTable/DataTable.d.ts +2 -1
  8. package/dist/components/Common/DataView/DataTable/DataTable.js +75 -66
  9. package/dist/components/Common/DataView/DataTable/DataTable.js.map +1 -1
  10. package/dist/components/Common/DataView/DataTable/DataTable.module.scss.js +8 -4
  11. package/dist/components/Common/DataView/DataTable/DataTable.module.scss.js.map +1 -1
  12. package/dist/components/Common/DataView/DataView.js +18 -17
  13. package/dist/components/Common/DataView/DataView.js.map +1 -1
  14. package/dist/components/Company/Locations/LocationsList/List.js +27 -25
  15. package/dist/components/Company/Locations/LocationsList/List.js.map +1 -1
  16. package/dist/components/Company/Locations/LocationsList/LocationsList.js +41 -36
  17. package/dist/components/Company/Locations/LocationsList/LocationsList.js.map +1 -1
  18. package/dist/components/Company/Locations/LocationsList/useLocationsList.d.ts +1 -0
  19. package/dist/components/Company/Locations/LocationsList/useLocationsList.js.map +1 -1
  20. package/dist/components/Company/StateTaxes/StateTaxesForm/Form.d.ts +9 -2
  21. package/dist/components/Company/StateTaxes/StateTaxesForm/Form.js +19 -18
  22. package/dist/components/Company/StateTaxes/StateTaxesForm/Form.js.map +1 -1
  23. package/dist/components/Company/StateTaxes/StateTaxesForm/StateTaxesForm.js +63 -62
  24. package/dist/components/Company/StateTaxes/StateTaxesForm/StateTaxesForm.js.map +1 -1
  25. package/dist/components/Company/StateTaxes/TaxRateManagement/AddTaxRateDialog.js +69 -65
  26. package/dist/components/Company/StateTaxes/TaxRateManagement/AddTaxRateDialog.js.map +1 -1
  27. package/dist/components/Company/StateTaxes/TaxRateManagement/toHistoryRows.js +30 -23
  28. package/dist/components/Company/StateTaxes/TaxRateManagement/toHistoryRows.js.map +1 -1
  29. package/dist/components/Company/StateTaxes/shared/RequirementFields.d.ts +8 -4
  30. package/dist/components/Company/StateTaxes/shared/RequirementFields.js +13 -12
  31. package/dist/components/Company/StateTaxes/shared/RequirementFields.js.map +1 -1
  32. package/dist/components/Company/StateTaxes/shared/prepareRequirements.d.ts +29 -0
  33. package/dist/components/Company/StateTaxes/shared/prepareRequirements.js +24 -0
  34. package/dist/components/Company/StateTaxes/shared/prepareRequirements.js.map +1 -0
  35. package/dist/components/Company/StateTaxes/shared/prepareRequirements.test.d.ts +1 -0
  36. package/dist/components/Contractor/Payments/PaymentsList/PaymentsList.js +68 -55
  37. package/dist/components/Contractor/Payments/PaymentsList/PaymentsList.js.map +1 -1
  38. package/dist/components/Contractor/Payments/PaymentsList/PaymentsListPresentation.js +36 -35
  39. package/dist/components/Contractor/Payments/PaymentsList/PaymentsListPresentation.js.map +1 -1
  40. package/dist/components/Employee/Paystubs/management/PaystubsCard/PaystubsCard.js +84 -96
  41. package/dist/components/Employee/Paystubs/management/PaystubsCard/PaystubsCard.js.map +1 -1
  42. package/dist/components/Flow/Flow.js +22 -22
  43. package/dist/components/Flow/Flow.js.map +1 -1
  44. package/dist/components/Flow/useFlow.js +3 -3
  45. package/dist/components/InformationRequests/InformationRequests.d.ts +1 -1
  46. package/dist/components/InformationRequests/InformationRequests.js +66 -52
  47. package/dist/components/InformationRequests/InformationRequests.js.map +1 -1
  48. package/dist/components/Payroll/OffCycleCreation/OffCycleCreation.js +52 -50
  49. package/dist/components/Payroll/OffCycleCreation/OffCycleCreation.js.map +1 -1
  50. package/dist/components/Payroll/OffCycleCreation/OffCycleCreationPresentation.d.ts +1 -1
  51. package/dist/components/Payroll/OffCycleCreation/OffCycleCreationPresentation.js +86 -67
  52. package/dist/components/Payroll/OffCycleCreation/OffCycleCreationPresentation.js.map +1 -1
  53. package/dist/components/Payroll/OffCycleCreation/OffCycleCreationTypes.d.ts +4 -0
  54. package/dist/components/Payroll/OffCycleDeductionsSetting/OffCycleDeductionsSetting.d.ts +1 -1
  55. package/dist/components/Payroll/OffCycleDeductionsSetting/OffCycleDeductionsSetting.js +26 -21
  56. package/dist/components/Payroll/OffCycleDeductionsSetting/OffCycleDeductionsSetting.js.map +1 -1
  57. package/dist/components/Payroll/OffCyclePayPeriodDateForm/OffCyclePayPeriodDateFormPresentation.d.ts +8 -1
  58. package/dist/components/Payroll/OffCyclePayPeriodDateForm/OffCyclePayPeriodDateFormPresentation.js +29 -17
  59. package/dist/components/Payroll/OffCyclePayPeriodDateForm/OffCyclePayPeriodDateFormPresentation.js.map +1 -1
  60. package/dist/components/Payroll/OffCycleTaxWithholdingTable/OffCycleTaxWithholdingTable.js +21 -18
  61. package/dist/components/Payroll/OffCycleTaxWithholdingTable/OffCycleTaxWithholdingTable.js.map +1 -1
  62. package/dist/components/Payroll/OffCycleTaxWithholdingTable/OffCycleTaxWithholdingTable.module.scss.js +9 -7
  63. package/dist/components/Payroll/OffCycleTaxWithholdingTable/OffCycleTaxWithholdingTable.module.scss.js.map +1 -1
  64. package/dist/components/Payroll/OffCycleTaxWithholdingTable/OffCycleTaxWithholdingTableTypes.d.ts +2 -0
  65. package/dist/components/Payroll/OffCycleTaxWithholdingTable/OffCycleTaxWithholdingTableTypes.js.map +1 -1
  66. package/dist/components/Payroll/PayrollConfiguration/PayrollConfiguration.js +193 -191
  67. package/dist/components/Payroll/PayrollConfiguration/PayrollConfiguration.js.map +1 -1
  68. package/dist/components/Payroll/PayrollConfiguration/usePayrollConfigurationData.d.ts +3 -2
  69. package/dist/components/Payroll/PayrollConfiguration/usePayrollConfigurationData.js +31 -31
  70. package/dist/components/Payroll/PayrollConfiguration/usePayrollConfigurationData.js.map +1 -1
  71. package/dist/components/Payroll/PayrollEditEmployee/PayrollEditEmployeePresentation.js +254 -243
  72. package/dist/components/Payroll/PayrollEditEmployee/PayrollEditEmployeePresentation.js.map +1 -1
  73. package/dist/components/Payroll/PayrollHistory/PayrollHistory.js +83 -76
  74. package/dist/components/Payroll/PayrollHistory/PayrollHistory.js.map +1 -1
  75. package/dist/components/Payroll/PayrollHistory/PayrollHistoryPresentation.js +23 -22
  76. package/dist/components/Payroll/PayrollHistory/PayrollHistoryPresentation.js.map +1 -1
  77. package/dist/components/Payroll/PayrollList/PayrollList.js +108 -97
  78. package/dist/components/Payroll/PayrollList/PayrollList.js.map +1 -1
  79. package/dist/components/Payroll/PayrollList/PayrollListPresentation.js +38 -37
  80. package/dist/components/Payroll/PayrollList/PayrollListPresentation.js.map +1 -1
  81. package/dist/components/Payroll/PayrollOverview/PayrollOverview.js +176 -167
  82. package/dist/components/Payroll/PayrollOverview/PayrollOverview.js.map +1 -1
  83. package/dist/components/Payroll/PayrollOverview/PayrollOverviewPresentation.d.ts +2 -1
  84. package/dist/components/Payroll/PayrollOverview/PayrollOverviewPresentation.js +173 -164
  85. package/dist/components/Payroll/PayrollOverview/PayrollOverviewPresentation.js.map +1 -1
  86. package/dist/helpers/openPdfInNewTab.d.ts +15 -0
  87. package/dist/helpers/openPdfInNewTab.js +28 -0
  88. package/dist/helpers/openPdfInNewTab.js.map +1 -0
  89. package/dist/i18n/en/Company.StateTaxes.json.js +1 -1
  90. package/dist/i18n/en/Payroll.OffCycleCreation.json.js +11 -9
  91. package/dist/i18n/en/Payroll.OffCycleCreation.json.js.map +1 -1
  92. package/dist/i18n/en/Payroll.OffCycleTaxWithholding.json.js +7 -7
  93. package/dist/i18n/en/Payroll.PayrollEditEmployee.json.js +29 -27
  94. package/dist/i18n/en/Payroll.PayrollEditEmployee.json.js.map +1 -1
  95. package/dist/i18n/en/Payroll.PayrollOverview.json.js +43 -41
  96. package/dist/i18n/en/Payroll.PayrollOverview.json.js.map +1 -1
  97. package/dist/i18n/types.d.ts +20 -0
  98. package/dist/style.css +1 -1
  99. package/package.json +17 -17
@@ -1,87 +1,88 @@
1
- import { jsx as a, jsxs as o, Fragment as k } from "react/jsx-runtime";
2
- import { useTranslation as Pe, Trans as Ne } from "react-i18next";
3
- import { useState as ae, useRef as ke } from "react";
4
- import { isDismissalPayroll as Ce, getPayrollTypeLabel as Se, calculateTotalPayroll as we, getReimbursements as A } from "../helpers.js";
1
+ import { jsx as r, jsxs as o, Fragment as k } from "react/jsx-runtime";
2
+ import { useTranslation as Ne, Trans as ke } from "react-i18next";
3
+ import { useState as re, useRef as Se } from "react";
4
+ import { isDismissalPayroll as we, getPayrollTypeLabel as Ce, calculateTotalPayroll as ve, getReimbursements as A } from "../helpers.js";
5
5
  import { PayrollOverviewStatus as p } from "./PayrollOverviewTypes.js";
6
- import re from "./PayrollOverviewPresentation.module.scss.js";
6
+ import le from "./PayrollOverviewPresentation.module.scss.js";
7
7
  import { Flex as s } from "../../Common/Flex/Flex.js";
8
- import { Grid as ve } from "../../Common/Grid/Grid.js";
8
+ import { Grid as Le } from "../../Common/Grid/Grid.js";
9
9
  import _e from "../../../hooks/useContainerBreakpoints/useContainerBreakpoints.js";
10
- import { useComponentContext as Le } from "../../../contexts/ComponentAdapter/useComponentContext.js";
11
- import { useI18n as Ee } from "../../../i18n/I18n.js";
12
- import { useDateFormatter as Oe } from "../../../hooks/useDateFormatter.js";
13
- import Ae from "../../../hooks/useNumberFormatter.js";
10
+ import { useComponentContext as Ee } from "../../../contexts/ComponentAdapter/useComponentContext.js";
11
+ import { useI18n as Oe } from "../../../i18n/I18n.js";
12
+ import { useDateFormatter as Ae } from "../../../hooks/useDateFormatter.js";
13
+ import Be from "../../../hooks/useNumberFormatter.js";
14
14
  import { firstLastName as B } from "../../../helpers/formattedStrings.js";
15
- import { FlsaStatus as le, compensationTypeLabels as V, PAYROLL_RESOLVABLE_SUBMISSION_BLOCKER_TYPES as ne } from "../../../shared/constants.js";
16
- import ie from "../../../assets/icons/download-cloud.svg.js";
17
- import { PayrollLoading as oe } from "../../Common/PayrollLoading/PayrollLoading.js";
18
- import { FastAchSubmissionBlockerBanner as Be } from "./SubmissionBlockers/FastAchSubmissionBlockerBanner.js";
19
- import { GenericBlocker as Ve } from "./SubmissionBlockers/GenericBlocker.js";
20
- import { DataView as m } from "../../Common/DataView/DataView.js";
21
- const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate, u.endDate) : { startDate: "", endDate: "" }, nt = ({
15
+ import { FlsaStatus as ne, compensationTypeLabels as V, PAYROLL_RESOLVABLE_SUBMISSION_BLOCKER_TYPES as ie } from "../../../shared/constants.js";
16
+ import oe from "../../../assets/icons/download-cloud.svg.js";
17
+ import { PayrollLoading as se } from "../../Common/PayrollLoading/PayrollLoading.js";
18
+ import { FastAchSubmissionBlockerBanner as Ve } from "./SubmissionBlockers/FastAchSubmissionBlockerBanner.js";
19
+ import { GenericBlocker as We } from "./SubmissionBlockers/GenericBlocker.js";
20
+ import { DataView as c } from "../../Common/DataView/DataView.js";
21
+ const Ye = (u, S) => u?.startDate && u.endDate ? S.formatPayPeriod(u.startDate, u.endDate) : { startDate: "", endDate: "" }, it = ({
22
22
  onEdit: u,
23
- onSubmit: C,
24
- onCancel: se,
25
- onPayrollReceipt: de,
23
+ onSubmit: S,
24
+ onCancel: de,
25
+ onPayrollReceipt: ce,
26
26
  onPaystubDownload: W,
27
27
  payrollData: n,
28
28
  bankAccount: Y,
29
- taxes: S,
29
+ taxes: w,
30
30
  status: f = p.Viewing,
31
31
  isProcessed: h,
32
32
  canCancel: me = !1,
33
- canEdit: ce = !0,
33
+ canEdit: ue = !0,
34
34
  alerts: I = [],
35
35
  submissionBlockers: b = [],
36
- selectedUnblockOptions: w = {},
36
+ selectedUnblockOptions: C = {},
37
37
  onUnblockOptionChange: M,
38
- wireInConfirmationRequest: ue,
39
- printChecksBanner: be,
38
+ wireInConfirmationRequest: be,
39
+ printChecksBanner: ye,
40
40
  withReimbursements: g = !0,
41
- paymentSpeed: ye,
42
- pagination: v
41
+ paymentSpeed: pe,
42
+ pagination: v,
43
+ downloadingEmployeeIds: U = /* @__PURE__ */ new Set()
43
44
  }) => {
44
- const { Alert: F, Badge: _, Button: T, ButtonIcon: R, Dialog: pe, Heading: j, Text: y, Tabs: fe } = Le();
45
- Ee("Payroll.PayrollOverview");
46
- const d = Oe(), { t } = Pe("Payroll.PayrollOverview"), l = Ae("currency"), [he, ge] = ae("companyPays"), [U, G] = ae(!1), L = ke(null), D = _e({ ref: L }).includes("small"), H = f === p.Submitting || f === p.Cancelling, $ = /* @__PURE__ */ a(j, { as: "h1", children: t(h ? "summaryTitle" : "overviewTitle") }), z = Ce(n.offCycleReason), K = /* @__PURE__ */ a(y, { children: /* @__PURE__ */ a(
47
- Ne,
45
+ const { Alert: F, Badge: L, Button: T, ButtonIcon: R, Dialog: fe, Heading: j, Text: y, Tabs: he } = Ee();
46
+ Oe("Payroll.PayrollOverview");
47
+ const d = Ae(), { t } = Ne("Payroll.PayrollOverview"), l = Be("currency"), [ge, Te] = re("companyPays"), [G, $] = re(!1), _ = Se(null), D = _e({ ref: _ }).includes("small"), H = f === p.Submitting || f === p.Cancelling, z = /* @__PURE__ */ r(j, { as: "h1", children: t(h ? "summaryTitle" : "overviewTitle") }), K = we(n.offCycleReason), X = /* @__PURE__ */ r(y, { children: /* @__PURE__ */ r(
48
+ ke,
48
49
  {
49
- i18nKey: z ? "pageSubtitleDismissal" : "pageSubtitle",
50
+ i18nKey: K ? "pageSubtitleDismissal" : "pageSubtitle",
50
51
  t,
51
- components: { dateWrapper: /* @__PURE__ */ a(y, { weight: "bold", as: "span" }) },
52
+ components: { dateWrapper: /* @__PURE__ */ r(y, { weight: "bold", as: "span" }) },
52
53
  values: {
53
- ...We(n.payPeriod, d),
54
- payrollType: Se(n)
54
+ ...Ye(n.payPeriod, d),
55
+ payrollType: Ce(n)
55
56
  }
56
57
  }
57
58
  ) });
58
59
  if (f === p.Cancelled)
59
- return /* @__PURE__ */ a("div", { ref: L, className: re.container, children: /* @__PURE__ */ o(s, { flexDirection: "column", alignItems: "stretch", children: [
60
- /* @__PURE__ */ a(s, { justifyContent: "space-between", alignItems: "flex-start", gap: 16, children: /* @__PURE__ */ o(s, { flexDirection: "column", gap: 4, children: [
61
- $,
62
- K
60
+ return /* @__PURE__ */ r("div", { ref: _, className: le.container, children: /* @__PURE__ */ o(s, { flexDirection: "column", alignItems: "stretch", children: [
61
+ /* @__PURE__ */ r(s, { justifyContent: "space-between", alignItems: "flex-start", gap: 16, children: /* @__PURE__ */ o(s, { flexDirection: "column", gap: 4, children: [
62
+ z,
63
+ X
63
64
  ] }) }),
64
- /* @__PURE__ */ a(F, { status: "info", label: t("cancelledEmptyState") })
65
+ /* @__PURE__ */ r(F, { status: "info", label: t("cancelledEmptyState") })
65
66
  ] }) });
66
- const x = we(n), Te = n.payrollStatusMeta?.expectedDebitTime ?? n.payrollDeadline, X = (e) => e.taxes?.reduce(
67
- (r, i) => i.employer ? r + Number(i.amount) : r,
67
+ const x = ve(n), De = n.payrollStatusMeta?.expectedDebitTime ?? n.payrollDeadline, q = (e) => e.taxes?.reduce(
68
+ (a, i) => i.employer ? a + Number(i.amount) : a,
68
69
  0
69
- ) ?? 0, q = (e) => e.benefits?.reduce(
70
- (r, i) => i.companyContribution ? r + Number(i.companyContribution) : r,
70
+ ) ?? 0, J = (e) => e.benefits?.reduce(
71
+ (a, i) => i.companyContribution ? a + Number(i.companyContribution) : a,
71
72
  0
72
- ) ?? 0, De = (e) => Number(e.grossPay) + A(e) + X(e) + q(e), E = b.find(
73
+ ) ?? 0, He = (e) => Number(e.grossPay) + A(e) + q(e) + J(e), E = b.find(
73
74
  (e) => e.blockerType === "fast_ach_threshold_exceeded" || e.blockerType === "needs_earned_access_for_fast_ach"
74
- ), O = E ? w[E.blockerType || ""] : void 0, c = E?.unblockOptions?.find(
75
+ ), O = E ? C[E.blockerType || ""] : void 0, m = E?.unblockOptions?.find(
75
76
  (e) => e.unblockType === O
76
- ), J = O === "wire_in", Q = O === "move_to_four_day", P = (e) => e.hourlyCompensations?.reduce(
77
- (r, i) => {
77
+ ), Q = O === "wire_in", Z = O === "move_to_four_day", P = (e) => e.hourlyCompensations?.reduce(
78
+ (a, i) => {
78
79
  if (typeof i.name > "u")
79
- return r;
80
- const N = i.name.toLowerCase(), xe = r[N] ?? 0;
81
- return r[N] = xe + Number(i.hours || 0), r;
80
+ return a;
81
+ const N = i.name.toLowerCase(), Pe = a[N] ?? 0;
82
+ return a[N] = Pe + Number(i.hours || 0), a;
82
83
  },
83
84
  {}
84
- ) || {}, Z = (e) => e.paidTimeOff?.reduce((r, i) => r + Number(i.hours || 0), 0) ?? 0, ee = [
85
+ ) || {}, ee = (e) => e.paidTimeOff?.reduce((a, i) => a + Number(i.hours || 0), 0) ?? 0, te = [
85
86
  {
86
87
  key: "employeeName",
87
88
  title: t("tableHeaders.employees"),
@@ -90,7 +91,7 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
90
91
  first_name: e.firstName,
91
92
  last_name: e.lastName
92
93
  }),
93
- e.excluded && /* @__PURE__ */ a(_, { status: "warning", children: t("skippedBadge") })
94
+ e.excluded && /* @__PURE__ */ r(L, { status: "warning", children: t("skippedBadge") })
94
95
  ] })
95
96
  },
96
97
  {
@@ -108,60 +109,68 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
108
109
  {
109
110
  key: "companyTaxes",
110
111
  title: t("tableHeaders.companyTaxes"),
111
- render: (e) => l(X(e))
112
+ render: (e) => l(q(e))
112
113
  },
113
114
  {
114
115
  key: "companyBenefits",
115
116
  title: t("tableHeaders.companyBenefits"),
116
- render: (e) => l(q(e))
117
+ render: (e) => l(J(e))
117
118
  },
118
119
  {
119
120
  key: "companyPays",
120
121
  title: t("tableHeaders.companyPays"),
121
- render: (e) => l(De(e))
122
+ render: (e) => l(He(e))
122
123
  }
123
124
  ];
124
- h && D && ee.push({
125
+ h && D && te.push({
125
126
  key: "paystubs",
126
127
  title: t("tableHeaders.paystub"),
127
- render: (e) => /* @__PURE__ */ a(s, { justifyContent: "flex-end", children: /* @__PURE__ */ a(
128
- R,
129
- {
130
- "aria-label": t("downloadPaystubLabel"),
131
- variant: "tertiary",
132
- onClick: () => {
133
- e.employeeUuid && W(e.employeeUuid);
134
- },
135
- children: /* @__PURE__ */ a(ie, {})
136
- }
137
- ) })
128
+ render: (e) => {
129
+ const a = !!e.employeeUuid && U.has(e.employeeUuid);
130
+ return /* @__PURE__ */ r(s, { justifyContent: "flex-end", children: /* @__PURE__ */ r(
131
+ R,
132
+ {
133
+ "aria-label": t("downloadPaystubLabel"),
134
+ variant: "tertiary",
135
+ isLoading: a,
136
+ onClick: () => {
137
+ e.employeeUuid && W(e.employeeUuid);
138
+ },
139
+ children: /* @__PURE__ */ r(oe, {})
140
+ }
141
+ ) });
142
+ }
138
143
  });
139
- const He = [
144
+ const xe = [
140
145
  {
141
146
  id: "companyPays",
142
147
  label: t("dataViews.companyPaysTab"),
143
- content: /* @__PURE__ */ a(
144
- m,
148
+ content: /* @__PURE__ */ r(
149
+ c,
145
150
  {
146
151
  label: t("dataViews.companyPaysTable"),
147
- columns: ee,
152
+ columns: te,
148
153
  data: n.employeeCompensations,
149
154
  pagination: v,
150
- itemMenu: h && !D ? (e) => /* @__PURE__ */ a(
151
- R,
152
- {
153
- "aria-label": t("downloadPaystubLabel"),
154
- variant: "tertiary",
155
- onClick: () => {
156
- e.employeeUuid && W(e.employeeUuid);
157
- },
158
- children: /* @__PURE__ */ a(ie, {})
159
- }
160
- ) : void 0,
155
+ itemMenu: h && !D ? (e) => {
156
+ const a = !!e.employeeUuid && U.has(e.employeeUuid);
157
+ return /* @__PURE__ */ r(
158
+ R,
159
+ {
160
+ "aria-label": t("downloadPaystubLabel"),
161
+ variant: "tertiary",
162
+ isLoading: a,
163
+ onClick: () => {
164
+ e.employeeUuid && W(e.employeeUuid);
165
+ },
166
+ children: /* @__PURE__ */ r(oe, {})
167
+ }
168
+ );
169
+ } : void 0,
161
170
  footer: () => ({
162
171
  employeeName: /* @__PURE__ */ o(k, { children: [
163
172
  t("tableHeaders.footerTotalsLabel"),
164
- /* @__PURE__ */ a(y, { variant: "supporting", size: "sm", children: t("tableHeaders.footerTotalsDescription") })
173
+ /* @__PURE__ */ r(y, { variant: "supporting", size: "sm", children: t("tableHeaders.footerTotalsDescription") })
165
174
  ] }),
166
175
  grossPay: l(Number(n.totals?.grossPay ?? 0)),
167
176
  ...g ? {
@@ -177,8 +186,8 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
177
186
  {
178
187
  id: "hoursWorked",
179
188
  label: t("dataViews.hoursWorkedTab"),
180
- content: /* @__PURE__ */ a(
181
- m,
189
+ content: /* @__PURE__ */ r(
190
+ c,
182
191
  {
183
192
  label: t("dataViews.hoursWorkedTable"),
184
193
  columns: [
@@ -189,22 +198,22 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
189
198
  first_name: e.firstName,
190
199
  last_name: e.lastName
191
200
  }),
192
- e.excluded && /* @__PURE__ */ a(_, { status: "warning", children: t("skippedBadge") })
201
+ e.excluded && /* @__PURE__ */ r(L, { status: "warning", children: t("skippedBadge") })
193
202
  ] })
194
203
  },
195
204
  {
196
205
  title: t("tableHeaders.compensationType"),
197
206
  render: (e) => {
198
- const r = e.hourlyCompensations?.find(
207
+ const a = e.hourlyCompensations?.find(
199
208
  (i) => i.flsaStatus
200
209
  )?.flsaStatus;
201
- switch (r) {
202
- case le.EXEMPT:
210
+ switch (a) {
211
+ case ne.EXEMPT:
203
212
  return t("compensationTypeLabels.exempt");
204
- case le.NONEXEMPT:
213
+ case ne.NONEXEMPT:
205
214
  return t("compensationTypeLabels.nonexempt");
206
215
  default:
207
- return r ?? "";
216
+ return a ?? "";
208
217
  }
209
218
  }
210
219
  },
@@ -222,14 +231,14 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
222
231
  },
223
232
  {
224
233
  title: t("tableHeaders.timeOff"),
225
- render: (e) => Z(e)
234
+ render: (e) => ee(e)
226
235
  },
227
236
  {
228
237
  title: t("tableHeaders.totalHours"),
229
238
  render: (e) => Object.values(P(e)).reduce(
230
- (r, i) => r + i,
239
+ (a, i) => a + i,
231
240
  0
232
- ) + Z(e)
241
+ ) + ee(e)
233
242
  }
234
243
  ],
235
244
  data: n.employeeCompensations,
@@ -240,8 +249,8 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
240
249
  {
241
250
  id: "employeeTakeHome",
242
251
  label: t("dataViews.employeeTakeHomeTab"),
243
- content: /* @__PURE__ */ a(
244
- m,
252
+ content: /* @__PURE__ */ r(
253
+ c,
245
254
  {
246
255
  label: t("dataViews.employeeTakeHomeTable"),
247
256
  columns: [
@@ -252,7 +261,7 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
252
261
  first_name: e.firstName,
253
262
  last_name: e.lastName
254
263
  }),
255
- e.excluded && /* @__PURE__ */ a(_, { status: "warning", children: t("skippedBadge") })
264
+ e.excluded && /* @__PURE__ */ r(L, { status: "warning", children: t("skippedBadge") })
256
265
  ] })
257
266
  },
258
267
  {
@@ -267,7 +276,7 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
267
276
  title: t("tableHeaders.deductions"),
268
277
  render: (e) => l(
269
278
  e.deductions?.reduce(
270
- (r, i) => r + Number(i.amount),
279
+ (a, i) => a + Number(i.amount),
271
280
  0
272
281
  ) ?? 0
273
282
  )
@@ -282,7 +291,7 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
282
291
  title: t("tableHeaders.employeeTaxes"),
283
292
  render: (e) => l(
284
293
  e.taxes?.reduce(
285
- (r, i) => i.employer ? r : r + Number(i.amount),
294
+ (a, i) => i.employer ? a : a + Number(i.amount),
286
295
  0
287
296
  ) ?? 0
288
297
  )
@@ -291,7 +300,7 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
291
300
  title: t("tableHeaders.employeeBenefits"),
292
301
  render: (e) => l(
293
302
  e.benefits?.reduce(
294
- (r, i) => r + Number(i.employeeDeduction ?? 0),
303
+ (a, i) => a + Number(i.employeeDeduction ?? 0),
295
304
  0
296
305
  ) ?? 0
297
306
  )
@@ -310,8 +319,8 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
310
319
  id: "taxes",
311
320
  label: t("dataViews.taxesTab"),
312
321
  content: /* @__PURE__ */ o(s, { flexDirection: "column", gap: 32, children: [
313
- /* @__PURE__ */ a(
314
- m,
322
+ /* @__PURE__ */ r(
323
+ c,
315
324
  {
316
325
  label: t("dataViews.taxesTable"),
317
326
  columns: [
@@ -323,24 +332,24 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
323
332
  {
324
333
  key: "byYourEmployees",
325
334
  title: t("tableHeaders.byYourEmployees"),
326
- render: (e) => l(S[e]?.employee ?? 0)
335
+ render: (e) => l(w[e]?.employee ?? 0)
327
336
  },
328
337
  {
329
338
  key: "byYourCompany",
330
339
  title: t("tableHeaders.byYourCompany"),
331
- render: (e) => l(S[e]?.employer ?? 0)
340
+ render: (e) => l(w[e]?.employer ?? 0)
332
341
  }
333
342
  ],
334
343
  footer: () => ({
335
- taxDescription: /* @__PURE__ */ a(y, { weight: "semibold", size: "sm", children: t("totalsLabel") }),
344
+ taxDescription: /* @__PURE__ */ r(y, { weight: "semibold", size: "sm", children: t("totalsLabel") }),
336
345
  byYourEmployees: l(Number(n.totals?.employeeTaxes ?? 0)),
337
346
  byYourCompany: l(Number(n.totals?.employerTaxes ?? 0))
338
347
  }),
339
- data: Object.keys(S)
348
+ data: Object.keys(w)
340
349
  }
341
350
  ),
342
- /* @__PURE__ */ a(
343
- m,
351
+ /* @__PURE__ */ r(
352
+ c,
344
353
  {
345
354
  label: t("dataViews.debitedTable"),
346
355
  columns: [
@@ -371,13 +380,13 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
371
380
  )
372
381
  ] })
373
382
  }
374
- ], te = h ? /* @__PURE__ */ o(k, { children: [
375
- /* @__PURE__ */ a(T, { onClick: de, variant: "secondary", isDisabled: H, children: t("payrollReceiptCta") }),
376
- me && /* @__PURE__ */ a(
383
+ ], ae = h ? /* @__PURE__ */ o(k, { children: [
384
+ /* @__PURE__ */ r(T, { onClick: ce, variant: "secondary", isDisabled: H, children: t("payrollReceiptCta") }),
385
+ me && /* @__PURE__ */ r(
377
386
  T,
378
387
  {
379
388
  onClick: () => {
380
- G(!0);
389
+ $(!0);
381
390
  },
382
391
  variant: "error",
383
392
  isDisabled: H,
@@ -385,32 +394,32 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
385
394
  }
386
395
  )
387
396
  ] }) : /* @__PURE__ */ o(k, { children: [
388
- ce && /* @__PURE__ */ a(T, { onClick: u, variant: "secondary", isDisabled: H, children: t("editCta") }),
389
- /* @__PURE__ */ a(
397
+ ue && /* @__PURE__ */ r(T, { onClick: u, variant: "secondary", isDisabled: H, children: t("editCta") }),
398
+ /* @__PURE__ */ r(
390
399
  T,
391
400
  {
392
- onClick: C,
401
+ onClick: S,
393
402
  isDisabled: H || b.length > 0 && (b.some(
394
- (e) => !ne.includes(e.blockerType || "")
403
+ (e) => !ie.includes(e.blockerType || "")
395
404
  ) || b.some(
396
- (e) => !w[e.blockerType || ""]
405
+ (e) => !C[e.blockerType || ""]
397
406
  )),
398
407
  children: t("submitCta")
399
408
  }
400
409
  )
401
410
  ] });
402
- return /* @__PURE__ */ a("div", { ref: L, className: re.container, children: /* @__PURE__ */ o(s, { flexDirection: "column", alignItems: "stretch", children: [
411
+ return /* @__PURE__ */ r("div", { ref: _, className: le.container, children: /* @__PURE__ */ o(s, { flexDirection: "column", alignItems: "stretch", children: [
403
412
  /* @__PURE__ */ o(s, { justifyContent: "space-between", alignItems: "flex-start", gap: 16, children: [
404
413
  /* @__PURE__ */ o(s, { flexDirection: "column", gap: 4, children: [
405
- $,
406
- K
414
+ z,
415
+ X
407
416
  ] }),
408
- D && /* @__PURE__ */ a(s, { gap: 8, justifyContent: "flex-end", children: te })
417
+ D && /* @__PURE__ */ r(s, { gap: 8, justifyContent: "flex-end", children: ae })
409
418
  ] }),
410
- !D && /* @__PURE__ */ a(ve, { gridTemplateColumns: "1fr", gap: 8, children: te }),
411
- f === p.Cancelling ? /* @__PURE__ */ a(oe, { title: t("cancellingTitle") }) : f === p.Submitting ? /* @__PURE__ */ a(oe, { title: t("loadingTitle"), description: t("loadingDescription") }) : /* @__PURE__ */ o(k, { children: [
412
- ue,
413
- I.length > 0 && /* @__PURE__ */ a(s, { flexDirection: "column", gap: 16, children: I.map((e, r) => /* @__PURE__ */ a(
419
+ !D && /* @__PURE__ */ r(Le, { gridTemplateColumns: "1fr", gap: 8, children: ae }),
420
+ f === p.Cancelling ? /* @__PURE__ */ r(se, { title: t("cancellingTitle") }) : f === p.Submitting ? /* @__PURE__ */ r(se, { title: t("loadingTitle"), description: t("loadingDescription") }) : /* @__PURE__ */ o(k, { children: [
421
+ be,
422
+ I.length > 0 && /* @__PURE__ */ r(s, { flexDirection: "column", gap: 16, children: I.map((e, a) => /* @__PURE__ */ r(
414
423
  F,
415
424
  {
416
425
  label: e.title,
@@ -421,21 +430,21 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
421
430
  `${e.type}-${e.title}`
422
431
  )) }),
423
432
  b.length > 0 && M && b.map((e) => {
424
- const r = e.blockerType || "";
425
- return ne.includes(r) ? /* @__PURE__ */ a(
426
- Be,
433
+ const a = e.blockerType || "";
434
+ return ie.includes(a) ? /* @__PURE__ */ r(
435
+ Ve,
427
436
  {
428
437
  blocker: e,
429
- selectedValue: w[r],
438
+ selectedValue: C[a],
430
439
  onUnblockOptionChange: M,
431
- paymentSpeed: ye
440
+ paymentSpeed: pe
432
441
  },
433
- r
434
- ) : /* @__PURE__ */ a(Ve, { blocker: e }, r);
442
+ a
443
+ ) : /* @__PURE__ */ r(We, { blocker: e }, a);
435
444
  }),
436
- /* @__PURE__ */ a(j, { as: "h2", styledAs: "h3", children: t(J ? "payrollSummaryTitleWire" : Q ? "payrollSummaryTitleFourDay" : "payrollSummaryTitle") }),
437
- J ? /* @__PURE__ */ a(
438
- m,
445
+ /* @__PURE__ */ r(j, { as: "h2", styledAs: "h3", children: t(Q ? "payrollSummaryTitleWire" : Z ? "payrollSummaryTitleFourDay" : "payrollSummaryTitle") }),
446
+ Q ? /* @__PURE__ */ r(
447
+ c,
439
448
  {
440
449
  label: t("payrollSummaryLabel"),
441
450
  columns: [
@@ -446,26 +455,26 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
446
455
  {
447
456
  title: t("tableHeaders.wireAmount"),
448
457
  render: () => {
449
- const r = c?.metadata?.wire_in_amount;
450
- return r ? l(Number(r)) : "-";
458
+ const a = m?.metadata?.wire_in_amount;
459
+ return a ? l(Number(a)) : "-";
451
460
  }
452
461
  },
453
462
  {
454
463
  title: t("tableHeaders.wireTransferDeadline"),
455
464
  render: () => {
456
- const r = c?.metadata?.wire_in_deadline, i = d.formatWithTime(r), N = d.formatShortWithYear(r);
457
- return r ? `${i.time} on ${N}` : "-";
465
+ const a = m?.metadata?.wire_in_deadline, i = d.formatWithTime(a), N = d.formatShortWithYear(a);
466
+ return a ? `${i.time} on ${N}` : "-";
458
467
  }
459
468
  },
460
469
  {
461
470
  title: t("tableHeaders.employeePayDate"),
462
- render: () => c?.checkDate ? d.formatShortWithYear(c.checkDate) : "-"
471
+ render: () => m?.checkDate ? d.formatShortWithYear(m.checkDate) : "-"
463
472
  }
464
473
  ],
465
474
  data: [{}]
466
475
  }
467
- ) : Q ? /* @__PURE__ */ a(
468
- m,
476
+ ) : Z ? /* @__PURE__ */ r(
477
+ c,
469
478
  {
470
479
  label: t("payrollSummaryLabel"),
471
480
  columns: [
@@ -487,19 +496,19 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
487
496
  {
488
497
  title: t("tableHeaders.debitDate"),
489
498
  render: () => {
490
- const r = c?.metadata?.debit_date;
491
- return d.formatShortWithYear(r);
499
+ const a = m?.metadata?.debit_date;
500
+ return d.formatShortWithYear(a);
492
501
  }
493
502
  },
494
503
  {
495
504
  title: t("tableHeaders.employeePayDate"),
496
- render: () => c?.checkDate ? d.formatShortWithYear(c.checkDate) : "-"
505
+ render: () => m?.checkDate ? d.formatShortWithYear(m.checkDate) : "-"
497
506
  }
498
507
  ],
499
508
  data: [{}]
500
509
  }
501
- ) : /* @__PURE__ */ a(
502
- m,
510
+ ) : /* @__PURE__ */ r(
511
+ c,
503
512
  {
504
513
  label: t("payrollSummaryLabel"),
505
514
  columns: [
@@ -517,7 +526,7 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
517
526
  },
518
527
  {
519
528
  title: t("tableHeaders.debitDate"),
520
- render: () => d.formatShortWithYear(Te)
529
+ render: () => d.formatShortWithYear(De)
521
530
  },
522
531
  {
523
532
  title: t("tableHeaders.employeePayDate"),
@@ -527,35 +536,35 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
527
536
  data: [{}]
528
537
  }
529
538
  ),
530
- be,
531
- /* @__PURE__ */ a(
532
- fe,
539
+ ye,
540
+ /* @__PURE__ */ r(
541
+ he,
533
542
  {
534
- onSelectionChange: ge,
535
- selectedId: he,
543
+ onSelectionChange: Te,
544
+ selectedId: ge,
536
545
  "aria-label": t("dataViews.label"),
537
- tabs: He
546
+ tabs: xe
538
547
  }
539
548
  ),
540
- U && /* @__PURE__ */ a(
541
- pe,
549
+ G && /* @__PURE__ */ r(
550
+ fe,
542
551
  {
543
- isOpen: U,
552
+ isOpen: G,
544
553
  onClose: () => {
545
- G(!1);
554
+ $(!1);
546
555
  },
547
- onPrimaryActionClick: se,
556
+ onPrimaryActionClick: de,
548
557
  shouldCloseOnBackdropClick: !0,
549
558
  primaryActionLabel: t("confirmCancelCta"),
550
559
  isDestructive: !0,
551
560
  closeActionLabel: t("declineCancelCta"),
552
- title: t(z ? "cancelDialogTitleDismissal" : "cancelDialogTitle", {
561
+ title: t(K ? "cancelDialogTitleDismissal" : "cancelDialogTitle", {
553
562
  startDate: d.formatLong(n.payPeriod?.startDate),
554
563
  endDate: d.formatLongWithYear(n.payPeriod?.endDate)
555
564
  }),
556
565
  children: /* @__PURE__ */ o(s, { gap: 14, flexDirection: "column", children: [
557
- /* @__PURE__ */ a(y, { children: t("cancelDialogDescription") }),
558
- Number(n.totals?.netPayDebit ?? 0) > 0 && /* @__PURE__ */ a(y, { children: t("cancelDialogDescriptionDeadline", {
566
+ /* @__PURE__ */ r(y, { children: t("cancelDialogDescription") }),
567
+ Number(n.totals?.netPayDebit ?? 0) > 0 && /* @__PURE__ */ r(y, { children: t("cancelDialogDescriptionDeadline", {
559
568
  deadline: d.formatWithTime(n.payrollDeadline).time
560
569
  }) })
561
570
  ] })
@@ -565,6 +574,6 @@ const We = (u, C) => u?.startDate && u.endDate ? C.formatPayPeriod(u.startDate,
565
574
  ] }) });
566
575
  };
567
576
  export {
568
- nt as PayrollOverviewPresentation
577
+ it as PayrollOverviewPresentation
569
578
  };
570
579
  //# sourceMappingURL=PayrollOverviewPresentation.js.map