@gusto/embedded-react-sdk 0.37.0 → 0.38.0-rc.2
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/CHANGELOG.md +45 -0
- package/README.md +3 -0
- package/dist/UNSTABLE_Hooks.d.ts +1 -1
- package/dist/UNSTABLE_Hooks.js +65 -47
- package/dist/UNSTABLE_Hooks.js.map +1 -1
- package/dist/assets/icons/filter-funnel.svg.js +10 -0
- package/dist/assets/icons/filter-funnel.svg.js.map +1 -0
- package/dist/assets/icons/percent-circle.svg.js +10 -0
- package/dist/assets/icons/percent-circle.svg.js.map +1 -0
- package/dist/assets/icons/plus-circle.svg.js +1 -1
- package/dist/assets/icons/plus-circle.svg.js.map +1 -1
- package/dist/components/Base/Base.js +2 -3
- package/dist/components/Base/Base.js.map +1 -1
- package/dist/components/Base/createCompoundContext.js.map +1 -1
- package/dist/components/Common/DataView/DataCards/DataCards.d.ts +5 -3
- package/dist/components/Common/DataView/DataCards/DataCards.js +58 -39
- package/dist/components/Common/DataView/DataCards/DataCards.js.map +1 -1
- package/dist/components/Common/DataView/DataCards/DataCards.module.scss.js +9 -7
- package/dist/components/Common/DataView/DataCards/DataCards.module.scss.js.map +1 -1
- package/dist/components/Common/DataView/DataTable/DataTable.d.ts +4 -2
- package/dist/components/Common/DataView/DataTable/DataTable.js +95 -76
- package/dist/components/Common/DataView/DataTable/DataTable.js.map +1 -1
- package/dist/components/Common/DataView/DataView.d.ts +4 -3
- package/dist/components/Common/DataView/DataView.js +24 -22
- package/dist/components/Common/DataView/DataView.js.map +1 -1
- package/dist/components/Common/DataView/useDataView.d.ts +33 -6
- package/dist/components/Common/DataView/useDataView.js +23 -20
- package/dist/components/Common/DataView/useDataView.js.map +1 -1
- package/dist/components/Common/DataView/useSelectionState.d.ts +5 -0
- package/dist/components/Common/DataView/useSelectionState.js +8 -0
- package/dist/components/Common/DataView/useSelectionState.js.map +1 -0
- package/dist/components/Common/DateRangeFilter/DateRangeFilter.d.ts +19 -0
- package/dist/components/Common/DateRangeFilter/DateRangeFilter.js +94 -0
- package/dist/components/Common/DateRangeFilter/DateRangeFilter.js.map +1 -0
- package/dist/components/Common/DateRangeFilter/DateRangeFilter.module.scss.js +14 -0
- package/dist/components/Common/DateRangeFilter/DateRangeFilter.module.scss.js.map +1 -0
- package/dist/components/Common/DetailViewLayout/DetailViewLayout.d.ts +2 -0
- package/dist/components/Common/DetailViewLayout/DetailViewLayoutTypes.d.ts +40 -0
- package/dist/components/Common/DetailViewLayout/index.d.ts +3 -0
- package/dist/components/Common/EmptyData/EmptyData.d.ts +2 -1
- package/dist/components/Common/EmptyData/EmptyData.js +15 -13
- package/dist/components/Common/EmptyData/EmptyData.js.map +1 -1
- package/dist/components/Common/EmptyData/EmptyData.module.scss.js +6 -4
- package/dist/components/Common/EmptyData/EmptyData.module.scss.js.map +1 -1
- package/dist/components/Common/Fields/CheckboxField/CheckboxField.js +26 -24
- package/dist/components/Common/Fields/CheckboxField/CheckboxField.js.map +1 -1
- package/dist/components/Common/Fields/CheckboxGroupField/CheckboxGroupField.d.ts +1 -1
- package/dist/components/Common/Fields/CheckboxGroupField/CheckboxGroupField.js +32 -30
- package/dist/components/Common/Fields/CheckboxGroupField/CheckboxGroupField.js.map +1 -1
- package/dist/components/Common/Fields/ComboBoxField/ComboBoxField.d.ts +1 -1
- package/dist/components/Common/Fields/ComboBoxField/ComboBoxField.js +36 -34
- package/dist/components/Common/Fields/ComboBoxField/ComboBoxField.js.map +1 -1
- package/dist/components/Common/Fields/DatePickerField/DatePickerField.d.ts +1 -1
- package/dist/components/Common/Fields/DatePickerField/DatePickerField.js +40 -38
- package/dist/components/Common/Fields/DatePickerField/DatePickerField.js.map +1 -1
- package/dist/components/Common/Fields/FileInputField/FileInputField.js +24 -22
- package/dist/components/Common/Fields/FileInputField/FileInputField.js.map +1 -1
- package/dist/components/Common/Fields/MultiSelectComboBoxField/MultiSelectComboBoxField.js +24 -22
- package/dist/components/Common/Fields/MultiSelectComboBoxField/MultiSelectComboBoxField.js.map +1 -1
- package/dist/components/Common/Fields/NumberInputField/NumberInputField.js +27 -25
- package/dist/components/Common/Fields/NumberInputField/NumberInputField.js.map +1 -1
- package/dist/components/Common/Fields/RadioGroupField/RadioGroupField.d.ts +1 -1
- package/dist/components/Common/Fields/RadioGroupField/RadioGroupField.js +34 -32
- package/dist/components/Common/Fields/RadioGroupField/RadioGroupField.js.map +1 -1
- package/dist/components/Common/Fields/SelectField/SelectField.d.ts +1 -1
- package/dist/components/Common/Fields/SelectField/SelectField.js +34 -32
- package/dist/components/Common/Fields/SelectField/SelectField.js.map +1 -1
- package/dist/components/Common/Fields/SwitchField/SwitchField.js +26 -24
- package/dist/components/Common/Fields/SwitchField/SwitchField.js.map +1 -1
- package/dist/components/Common/Fields/TextAreaField/TextAreaField.js +24 -22
- package/dist/components/Common/Fields/TextAreaField/TextAreaField.js.map +1 -1
- package/dist/components/Common/Fields/TextInputField/TextInputField.js +26 -24
- package/dist/components/Common/Fields/TextInputField/TextInputField.js.map +1 -1
- package/dist/components/Common/Fields/hooks/useField.d.ts +3 -2
- package/dist/components/Common/Fields/hooks/useField.js +37 -33
- package/dist/components/Common/Fields/hooks/useField.js.map +1 -1
- package/dist/components/Common/Fields/hooks/useStringifyGenericFieldValue.d.ts +2 -2
- package/dist/components/Common/Fields/hooks/useStringifyGenericFieldValue.js +2 -2
- package/dist/components/Common/Fields/hooks/useStringifyGenericFieldValue.js.map +1 -1
- package/dist/components/Common/FlowBreadcrumbs/FlowBreadcrumbs.js +21 -20
- package/dist/components/Common/FlowBreadcrumbs/FlowBreadcrumbs.js.map +1 -1
- package/dist/components/Common/FlowBreadcrumbs/FlowBreadcrumbsTypes.d.ts +5 -0
- package/dist/components/Common/FlowBreadcrumbs/breadcrumbTransitionHelpers.d.ts +1 -1
- package/dist/components/Common/FlowBreadcrumbs/breadcrumbTransitionHelpers.js +10 -8
- package/dist/components/Common/FlowBreadcrumbs/breadcrumbTransitionHelpers.js.map +1 -1
- package/dist/components/Common/ReorderableList/ReorderableList.js.map +1 -1
- package/dist/components/Common/SignatureForm/SignatureForm.js +10 -15
- package/dist/components/Common/SignatureForm/SignatureForm.js.map +1 -1
- package/dist/components/Common/SignatureForm/SignatureFormActions.js +9 -12
- package/dist/components/Common/SignatureForm/SignatureFormActions.js.map +1 -1
- package/dist/components/Common/SignatureForm/SignatureFormFields.js +14 -18
- package/dist/components/Common/SignatureForm/SignatureFormFields.js.map +1 -1
- package/dist/components/Common/UI/Box/Box.d.ts +1 -1
- package/dist/components/Common/UI/Box/Box.js +9 -8
- package/dist/components/Common/UI/Box/Box.js.map +1 -1
- package/dist/components/Common/UI/Box/Box.module.scss.js +12 -8
- package/dist/components/Common/UI/Box/Box.module.scss.js.map +1 -1
- package/dist/components/Common/UI/Box/BoxTypes.d.ts +2 -9
- package/dist/components/Common/UI/BoxHeader/BoxHeader.d.ts +2 -0
- package/dist/components/Common/UI/BoxHeader/BoxHeader.js +23 -0
- package/dist/components/Common/UI/BoxHeader/BoxHeader.js.map +1 -0
- package/dist/components/Common/UI/BoxHeader/BoxHeader.module.scss.js +8 -0
- package/dist/components/Common/UI/BoxHeader/BoxHeader.module.scss.js.map +1 -0
- package/dist/components/Common/UI/BoxHeader/BoxHeaderTypes.d.ts +10 -0
- package/dist/components/Common/UI/BoxHeader/BoxHeaderTypes.js +7 -0
- package/dist/components/Common/UI/BoxHeader/BoxHeaderTypes.js.map +1 -0
- package/dist/components/Common/UI/BoxHeader/index.d.ts +2 -0
- package/dist/components/Common/UI/Breadcrumbs/Breadcrumbs.js +17 -17
- package/dist/components/Common/UI/Breadcrumbs/Breadcrumbs.js.map +1 -1
- package/dist/components/Common/UI/Breadcrumbs/BreadcrumbsTypes.d.ts +5 -0
- package/dist/components/Common/UI/Breadcrumbs/BreadcrumbsTypes.js.map +1 -1
- package/dist/components/Common/UI/Button/Button.js +33 -29
- package/dist/components/Common/UI/Button/Button.js.map +1 -1
- package/dist/components/Common/UI/Button/Button.module.scss.js +5 -3
- package/dist/components/Common/UI/Button/Button.module.scss.js.map +1 -1
- package/dist/components/Common/UI/Button/ButtonTypes.d.ts +4 -0
- package/dist/components/Common/UI/Button/ButtonTypes.js.map +1 -1
- package/dist/components/Common/UI/Checkbox/Checkbox.js +60 -49
- package/dist/components/Common/UI/Checkbox/Checkbox.js.map +1 -1
- package/dist/components/Common/UI/Checkbox/Checkbox.module.scss.js +10 -6
- package/dist/components/Common/UI/Checkbox/Checkbox.module.scss.js.map +1 -1
- package/dist/components/Common/UI/ComboBox/ComboBox.js +1 -1
- package/dist/components/Common/UI/ComboBox/ComboBox.js.map +1 -1
- package/dist/components/Common/UI/ComboBox/ComboBoxTypes.d.ts +1 -1
- package/dist/components/Common/UI/DatePicker/DatePicker.d.ts +1 -1
- package/dist/components/Common/UI/DatePicker/DatePicker.js +88 -69
- package/dist/components/Common/UI/DatePicker/DatePicker.js.map +1 -1
- package/dist/components/Common/UI/DatePicker/DatePickerTypes.d.ts +13 -0
- package/dist/components/Common/UI/DateRangePicker/DateRangePicker.d.ts +2 -0
- package/dist/components/Common/UI/DateRangePicker/DateRangePicker.js +72 -0
- package/dist/components/Common/UI/DateRangePicker/DateRangePicker.js.map +1 -0
- package/dist/components/Common/UI/DateRangePicker/DateRangePicker.module.scss.js +30 -0
- package/dist/components/Common/UI/DateRangePicker/DateRangePicker.module.scss.js.map +1 -0
- package/dist/components/Common/UI/DateRangePicker/DateRangePickerTypes.d.ts +14 -0
- package/dist/components/Common/UI/DateRangePicker/index.d.ts +2 -0
- package/dist/components/Common/UI/DescriptionList/DescriptionList.js +19 -12
- package/dist/components/Common/UI/DescriptionList/DescriptionList.js.map +1 -1
- package/dist/components/Common/UI/DescriptionList/DescriptionList.module.scss.js +6 -4
- package/dist/components/Common/UI/DescriptionList/DescriptionList.module.scss.js.map +1 -1
- package/dist/components/Common/UI/DescriptionList/DescriptionListTypes.d.ts +6 -1
- package/dist/components/Common/UI/DescriptionList/DescriptionListTypes.js +4 -1
- package/dist/components/Common/UI/DescriptionList/DescriptionListTypes.js.map +1 -1
- package/dist/components/Common/UI/Heading/Heading.d.ts +1 -1
- package/dist/components/Common/UI/Heading/Heading.js +11 -9
- package/dist/components/Common/UI/Heading/Heading.js.map +1 -1
- package/dist/components/Common/UI/Heading/Heading.module.scss.js +15 -15
- package/dist/components/Common/UI/Heading/HeadingTypes.d.ts +1 -1
- package/dist/components/Common/UI/Input/Input.js.map +1 -1
- package/dist/components/Common/UI/Menu/Menu.module.scss.js +5 -5
- package/dist/components/Common/UI/MultiSelectComboBox/MultiSelectComboBox.js +94 -80
- package/dist/components/Common/UI/MultiSelectComboBox/MultiSelectComboBox.js.map +1 -1
- package/dist/components/Common/UI/NumberInput/NumberInput.js +1 -1
- package/dist/components/Common/UI/NumberInput/NumberInput.js.map +1 -1
- package/dist/components/Common/UI/RadioGroup/RadioGroupTypes.d.ts +1 -1
- package/dist/components/Common/UI/RadioGroup/RadioGroupTypes.js.map +1 -1
- package/dist/components/Common/UI/Select/Select.js +22 -22
- package/dist/components/Common/UI/Select/Select.js.map +1 -1
- package/dist/components/Common/UI/Select/SelectTypes.d.ts +1 -1
- package/dist/components/Common/UI/Table/Table.js +12 -12
- package/dist/components/Common/UI/Table/Table.js.map +1 -1
- package/dist/components/Common/UI/Table/Table.module.scss.js +1 -1
- package/dist/components/Common/UI/Table/TableTypes.d.ts +3 -3
- package/dist/components/Common/UI/Table/TableTypes.js +3 -3
- package/dist/components/Common/UI/Table/TableTypes.js.map +1 -1
- package/dist/components/Common/UI/TextArea/TextArea.js +1 -1
- package/dist/components/Common/UI/TextArea/TextArea.js.map +1 -1
- package/dist/components/Common/UI/TextInput/TextInput.js +13 -13
- package/dist/components/Common/UI/TextInput/TextInput.js.map +1 -1
- package/dist/components/Common/index.d.ts +2 -0
- package/dist/components/Company/AssignSignatory/AssignSignatory.js +7 -11
- package/dist/components/Company/AssignSignatory/AssignSignatory.js.map +1 -1
- package/dist/components/Company/AssignSignatory/AssignSignatorySelection.js +2 -5
- package/dist/components/Company/AssignSignatory/AssignSignatorySelection.js.map +1 -1
- package/dist/components/Company/AssignSignatory/CreateSignatory/Actions.js +2 -4
- package/dist/components/Company/AssignSignatory/CreateSignatory/Actions.js.map +1 -1
- package/dist/components/Company/AssignSignatory/CreateSignatory/CreateSignatory.js +6 -9
- package/dist/components/Company/AssignSignatory/CreateSignatory/CreateSignatory.js.map +1 -1
- package/dist/components/Company/AssignSignatory/CreateSignatory/CreateSignatoryForm.js +13 -14
- package/dist/components/Company/AssignSignatory/CreateSignatory/CreateSignatoryForm.js.map +1 -1
- package/dist/components/Company/AssignSignatory/CreateSignatory/useCreateSignatory.js +3 -4
- package/dist/components/Company/AssignSignatory/CreateSignatory/useCreateSignatory.js.map +1 -1
- package/dist/components/Company/AssignSignatory/InviteSignatory/Actions.js +2 -4
- package/dist/components/Company/AssignSignatory/InviteSignatory/Actions.js.map +1 -1
- package/dist/components/Company/AssignSignatory/InviteSignatory/InviteSignatory.js +5 -8
- package/dist/components/Company/AssignSignatory/InviteSignatory/InviteSignatory.js.map +1 -1
- package/dist/components/Company/AssignSignatory/InviteSignatory/InviteSignatoryForm.js +13 -14
- package/dist/components/Company/AssignSignatory/InviteSignatory/InviteSignatoryForm.js.map +1 -1
- package/dist/components/Company/AssignSignatory/InviteSignatory/useInviteSignatory.js +3 -4
- package/dist/components/Company/AssignSignatory/InviteSignatory/useInviteSignatory.js.map +1 -1
- package/dist/components/Company/AssignSignatory/TitleSelect.js +2 -5
- package/dist/components/Company/AssignSignatory/TitleSelect.js.map +1 -1
- package/dist/components/Company/AssignSignatory/useAssignSignatory.js +5 -6
- package/dist/components/Company/AssignSignatory/useAssignSignatory.js.map +1 -1
- package/dist/components/Company/BankAccount/BankAccountForm/Actions.js +8 -10
- package/dist/components/Company/BankAccount/BankAccountForm/Actions.js.map +1 -1
- package/dist/components/Company/BankAccount/BankAccountForm/Form.js +9 -13
- package/dist/components/Company/BankAccount/BankAccountForm/Form.js.map +1 -1
- package/dist/components/Company/BankAccount/BankAccountForm/context.js +3 -4
- package/dist/components/Company/BankAccount/BankAccountForm/context.js.map +1 -1
- package/dist/components/Company/BankAccount/BankAccountList/Actions.js +8 -10
- package/dist/components/Company/BankAccount/BankAccountList/Actions.js.map +1 -1
- package/dist/components/Company/BankAccount/BankAccountVerify/Actions.js +8 -10
- package/dist/components/Company/BankAccount/BankAccountVerify/Actions.js.map +1 -1
- package/dist/components/Company/BankAccount/BankAccountVerify/Form.js +4 -8
- package/dist/components/Company/BankAccount/BankAccountVerify/Form.js.map +1 -1
- package/dist/components/Company/DocumentSigner/DocumentList/Actions.js +2 -4
- package/dist/components/Company/DocumentSigner/DocumentList/Actions.js.map +1 -1
- package/dist/components/Company/DocumentSigner/DocumentList/DocumentList.js +11 -15
- package/dist/components/Company/DocumentSigner/DocumentList/DocumentList.js.map +1 -1
- package/dist/components/Company/DocumentSigner/DocumentList/useDocumentList.js +3 -4
- package/dist/components/Company/DocumentSigner/DocumentList/useDocumentList.js.map +1 -1
- package/dist/components/Company/DocumentSigner/SignatureForm/SignatureForm.js +11 -15
- package/dist/components/Company/DocumentSigner/SignatureForm/SignatureForm.js.map +1 -1
- package/dist/components/Company/DocumentSigner/SignatureForm/useSignatureForm.js +3 -4
- package/dist/components/Company/DocumentSigner/SignatureForm/useSignatureForm.js.map +1 -1
- package/dist/components/Company/FederalTaxes/Actions.js +7 -9
- package/dist/components/Company/FederalTaxes/Actions.js.map +1 -1
- package/dist/components/Company/FederalTaxes/FederalTaxes.js +22 -26
- package/dist/components/Company/FederalTaxes/FederalTaxes.js.map +1 -1
- package/dist/components/Company/FederalTaxes/Form.js +7 -9
- package/dist/components/Company/FederalTaxes/Form.js.map +1 -1
- package/dist/components/Company/FederalTaxes/useFederalTaxes.js +8 -9
- package/dist/components/Company/FederalTaxes/useFederalTaxes.js.map +1 -1
- package/dist/components/Company/Industry/Actions.js +7 -9
- package/dist/components/Company/Industry/Actions.js.map +1 -1
- package/dist/components/Company/Industry/Context.js +6 -7
- package/dist/components/Company/Industry/Context.js.map +1 -1
- package/dist/components/Company/Industry/Edit.js +4 -7
- package/dist/components/Company/Industry/Edit.js.map +1 -1
- package/dist/components/Company/Locations/LocationForm/Actions.js +8 -10
- package/dist/components/Company/Locations/LocationForm/Actions.js.map +1 -1
- package/dist/components/Company/Locations/LocationForm/Form.js +5 -7
- package/dist/components/Company/Locations/LocationForm/Form.js.map +1 -1
- package/dist/components/Company/Locations/LocationForm/LocationForm.js +15 -19
- package/dist/components/Company/Locations/LocationForm/LocationForm.js.map +1 -1
- package/dist/components/Company/Locations/LocationForm/useLocationForm.js +3 -4
- package/dist/components/Company/Locations/LocationForm/useLocationForm.js.map +1 -1
- package/dist/components/Company/Locations/LocationsList/Actions.js +6 -8
- package/dist/components/Company/Locations/LocationsList/Actions.js.map +1 -1
- package/dist/components/Company/Locations/LocationsList/List.js +15 -16
- package/dist/components/Company/Locations/LocationsList/List.js.map +1 -1
- package/dist/components/Company/Locations/LocationsList/LocationsList.js +6 -10
- package/dist/components/Company/Locations/LocationsList/LocationsList.js.map +1 -1
- package/dist/components/Company/Locations/LocationsList/useLocationsList.js +3 -4
- package/dist/components/Company/Locations/LocationsList/useLocationsList.js.map +1 -1
- package/dist/components/Company/OnboardingOverview/Completed.js +12 -15
- package/dist/components/Company/OnboardingOverview/Completed.js.map +1 -1
- package/dist/components/Company/OnboardingOverview/MissingRequirements.js +9 -12
- package/dist/components/Company/OnboardingOverview/MissingRequirements.js.map +1 -1
- package/dist/components/Company/OnboardingOverview/OnboardingOverview.js +6 -10
- package/dist/components/Company/OnboardingOverview/OnboardingOverview.js.map +1 -1
- package/dist/components/Company/OnboardingOverview/context.js +3 -4
- package/dist/components/Company/OnboardingOverview/context.js.map +1 -1
- package/dist/components/Company/PaySchedule/PaySchedule.js +94 -91
- package/dist/components/Company/PaySchedule/PaySchedule.js.map +1 -1
- package/dist/components/Company/PaySchedule/_parts/Actions.js +16 -18
- package/dist/components/Company/PaySchedule/_parts/Actions.js.map +1 -1
- package/dist/components/Company/PaySchedule/_parts/Edit.js +47 -39
- package/dist/components/Company/PaySchedule/_parts/Edit.js.map +1 -1
- package/dist/components/Company/PaySchedule/_parts/Head.js +11 -14
- package/dist/components/Company/PaySchedule/_parts/Head.js.map +1 -1
- package/dist/components/Company/PaySchedule/_parts/List.js +19 -21
- package/dist/components/Company/PaySchedule/_parts/List.js.map +1 -1
- package/dist/components/Company/PaySchedule/usePaySchedule.d.ts +6 -5
- package/dist/components/Company/PaySchedule/usePaySchedule.js +5 -6
- package/dist/components/Company/PaySchedule/usePaySchedule.js.map +1 -1
- package/dist/components/Company/StateTaxes/StateTaxesForm/Actions.js +2 -4
- package/dist/components/Company/StateTaxes/StateTaxesForm/Actions.js.map +1 -1
- package/dist/components/Company/StateTaxes/StateTaxesForm/StateTaxesForm.js +33 -33
- package/dist/components/Company/StateTaxes/StateTaxesForm/StateTaxesForm.js.map +1 -1
- package/dist/components/Company/StateTaxes/StateTaxesForm/context.js +3 -4
- package/dist/components/Company/StateTaxes/StateTaxesForm/context.js.map +1 -1
- package/dist/components/Company/StateTaxes/StateTaxesList/Actions.js +2 -4
- package/dist/components/Company/StateTaxes/StateTaxesList/Actions.js.map +1 -1
- package/dist/components/Company/StateTaxes/StateTaxesList/List.js +5 -7
- package/dist/components/Company/StateTaxes/StateTaxesList/List.js.map +1 -1
- package/dist/components/Company/StateTaxes/StateTaxesList/StateTaxesList.js +14 -14
- package/dist/components/Company/StateTaxes/StateTaxesList/StateTaxesList.js.map +1 -1
- package/dist/components/Company/StateTaxes/StateTaxesList/context.d.ts +2 -2
- package/dist/components/Company/StateTaxes/StateTaxesList/context.js +3 -4
- package/dist/components/Company/StateTaxes/StateTaxesList/context.js.map +1 -1
- package/dist/components/Contractor/Address/Address.js +3 -7
- package/dist/components/Contractor/Address/Address.js.map +1 -1
- package/dist/components/Contractor/Address/Form.js +2 -4
- package/dist/components/Contractor/Address/Form.js.map +1 -1
- package/dist/components/Contractor/Address/useAddress.js +5 -6
- package/dist/components/Contractor/Address/useAddress.js.map +1 -1
- package/dist/components/Contractor/ContractorList/index.js +33 -34
- package/dist/components/Contractor/ContractorList/index.js.map +1 -1
- package/dist/components/Contractor/NewHireReport/NewHireReport.js +2 -3
- package/dist/components/Contractor/NewHireReport/NewHireReport.js.map +1 -1
- package/dist/components/Contractor/PaymentMethod/BankAccountForm.js +10 -13
- package/dist/components/Contractor/PaymentMethod/BankAccountForm.js.map +1 -1
- package/dist/components/Contractor/PaymentMethod/PaymentMethod.js +2 -3
- package/dist/components/Contractor/PaymentMethod/PaymentMethod.js.map +1 -1
- package/dist/components/Contractor/PaymentMethod/PaymentTypeForm.js +2 -5
- package/dist/components/Contractor/PaymentMethod/PaymentTypeForm.js.map +1 -1
- package/dist/components/Contractor/Payments/CreatePayment/CreatePayment.js +135 -126
- package/dist/components/Contractor/Payments/CreatePayment/CreatePayment.js.map +1 -1
- package/dist/components/Contractor/Payments/CreatePayment/CreatePaymentPresentation.d.ts +2 -1
- package/dist/components/Contractor/Payments/CreatePayment/CreatePaymentPresentation.js +72 -71
- package/dist/components/Contractor/Payments/CreatePayment/CreatePaymentPresentation.js.map +1 -1
- package/dist/components/Contractor/Payments/CreatePayment/EditContractorPaymentPresentation.js +10 -10
- package/dist/components/Contractor/Payments/CreatePayment/FastAchSubmissionBlockerBanner.d.ts +2 -1
- package/dist/components/Contractor/Payments/CreatePayment/FastAchSubmissionBlockerBanner.js +18 -21
- package/dist/components/Contractor/Payments/CreatePayment/FastAchSubmissionBlockerBanner.js.map +1 -1
- package/dist/components/Contractor/Payments/CreatePayment/PreviewPresentation.d.ts +2 -1
- package/dist/components/Contractor/Payments/CreatePayment/PreviewPresentation.js +83 -84
- package/dist/components/Contractor/Payments/CreatePayment/PreviewPresentation.js.map +1 -1
- package/dist/components/Contractor/Payments/PaymentHistory/PaymentHistoryPresentation.js +17 -19
- package/dist/components/Contractor/Payments/PaymentHistory/PaymentHistoryPresentation.js.map +1 -1
- package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatement.js +10 -10
- package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatement.js.map +1 -1
- package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatementPresentation.js +67 -79
- package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatementPresentation.js.map +1 -1
- package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatementPresentation.module.scss.js +10 -12
- package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatementPresentation.module.scss.js.map +1 -1
- package/dist/components/Contractor/Payments/PaymentSummary/PaymentSummaryPresentation.js +47 -49
- package/dist/components/Contractor/Payments/PaymentSummary/PaymentSummaryPresentation.js.map +1 -1
- package/dist/components/Contractor/Payments/PaymentsList/PaymentsListPresentation.js +63 -66
- package/dist/components/Contractor/Payments/PaymentsList/PaymentsListPresentation.js.map +1 -1
- package/dist/components/Contractor/Payments/PaymentsList/PaymentsListPresentation.module.scss.js +4 -4
- package/dist/components/Contractor/Profile/ContractorProfileForm.js +13 -13
- package/dist/components/Contractor/Profile/useContractorProfile.js +31 -30
- package/dist/components/Contractor/Profile/useContractorProfile.js.map +1 -1
- package/dist/components/Contractor/Submit/Submit.d.ts +2 -2
- package/dist/components/Contractor/Submit/Submit.js +44 -46
- package/dist/components/Contractor/Submit/Submit.js.map +1 -1
- package/dist/components/Employee/Compensation/Actions.js +12 -14
- package/dist/components/Employee/Compensation/Actions.js.map +1 -1
- package/dist/components/Employee/Compensation/Compensation.js +80 -77
- package/dist/components/Employee/Compensation/Compensation.js.map +1 -1
- package/dist/components/Employee/Compensation/Edit.js +27 -28
- package/dist/components/Employee/Compensation/Edit.js.map +1 -1
- package/dist/components/Employee/Compensation/List.js +22 -23
- package/dist/components/Employee/Compensation/List.js.map +1 -1
- package/dist/components/Employee/Dashboard/BasicDetailsView.d.ts +13 -0
- package/dist/components/Employee/Dashboard/BasicDetailsView.js +107 -0
- package/dist/components/Employee/Dashboard/BasicDetailsView.js.map +1 -0
- package/dist/components/Employee/Dashboard/Dashboard.d.ts +5 -0
- package/dist/components/Employee/Dashboard/Dashboard.js +146 -0
- package/dist/components/Employee/Dashboard/Dashboard.js.map +1 -0
- package/dist/components/Employee/Dashboard/DashboardComponents.d.ts +5 -0
- package/dist/components/Employee/Dashboard/DashboardComponents.js +12 -0
- package/dist/components/Employee/Dashboard/DashboardComponents.js.map +1 -0
- package/dist/components/Employee/Dashboard/DashboardFlow.d.ts +5 -0
- package/dist/components/Employee/Dashboard/DashboardFlow.js +25 -0
- package/dist/components/Employee/Dashboard/DashboardFlow.js.map +1 -0
- package/dist/components/Employee/Dashboard/DocumentsView.d.ts +7 -0
- package/dist/components/Employee/Dashboard/DocumentsView.js +51 -0
- package/dist/components/Employee/Dashboard/DocumentsView.js.map +1 -0
- package/dist/components/Employee/Dashboard/JobAndPayView.d.ts +22 -0
- package/dist/components/Employee/Dashboard/JobAndPayView.js +211 -0
- package/dist/components/Employee/Dashboard/JobAndPayView.js.map +1 -0
- package/dist/components/Employee/Dashboard/TaxesView.d.ts +13 -0
- package/dist/components/Employee/Dashboard/TaxesView.js +97 -0
- package/dist/components/Employee/Dashboard/TaxesView.js.map +1 -0
- package/dist/components/Employee/Dashboard/dashboardStateMachine.d.ts +3 -0
- package/dist/components/Employee/Dashboard/dashboardStateMachine.js +8 -0
- package/dist/components/Employee/Dashboard/dashboardStateMachine.js.map +1 -0
- package/dist/components/Employee/Dashboard/hooks/index.d.ts +9 -0
- package/dist/components/Employee/Dashboard/hooks/useEmployeeBasicDetails.d.ts +20 -0
- package/dist/components/Employee/Dashboard/hooks/useEmployeeBasicDetails.js +29 -0
- package/dist/components/Employee/Dashboard/hooks/useEmployeeBasicDetails.js.map +1 -0
- package/dist/components/Employee/Dashboard/hooks/useEmployeeCompensation.d.ts +30 -0
- package/dist/components/Employee/Dashboard/hooks/useEmployeeCompensation.js +52 -0
- package/dist/components/Employee/Dashboard/hooks/useEmployeeCompensation.js.map +1 -0
- package/dist/components/Employee/Dashboard/hooks/useEmployeeForms.d.ts +16 -0
- package/dist/components/Employee/Dashboard/hooks/useEmployeeForms.js +22 -0
- package/dist/components/Employee/Dashboard/hooks/useEmployeeForms.js.map +1 -0
- package/dist/components/Employee/Dashboard/hooks/useEmployeeTaxes.d.ts +20 -0
- package/dist/components/Employee/Dashboard/hooks/useEmployeeTaxes.js +24 -0
- package/dist/components/Employee/Dashboard/hooks/useEmployeeTaxes.js.map +1 -0
- package/dist/components/Employee/Dashboard/index.d.ts +14 -0
- package/dist/components/Employee/Deductions/DeductionsForm/ChildSupportForm.js +57 -53
- package/dist/components/Employee/Deductions/DeductionsForm/ChildSupportForm.js.map +1 -1
- package/dist/components/Employee/Deductions/DeductionsForm/CustomDeductionForm.js +17 -18
- package/dist/components/Employee/Deductions/DeductionsForm/CustomDeductionForm.js.map +1 -1
- package/dist/components/Employee/Deductions/DeductionsForm/DeductionsForm.js.map +1 -1
- package/dist/components/Employee/Deductions/DeductionsForm/GarnishmentForm.js +11 -12
- package/dist/components/Employee/Deductions/DeductionsForm/GarnishmentForm.js.map +1 -1
- package/dist/components/Employee/Deductions/DeductionsList/DeductionsList.js +18 -19
- package/dist/components/Employee/Deductions/DeductionsList/DeductionsList.js.map +1 -1
- package/dist/components/Employee/Deductions/IncludeDeductions/IncludeDeductions.js +6 -7
- package/dist/components/Employee/Deductions/IncludeDeductions/IncludeDeductions.js.map +1 -1
- package/dist/components/Employee/DocumentSigner/DocumentList/Actions.js +6 -8
- package/dist/components/Employee/DocumentSigner/DocumentList/Actions.js.map +1 -1
- package/dist/components/Employee/DocumentSigner/DocumentList/DocumentList.js +10 -14
- package/dist/components/Employee/DocumentSigner/DocumentList/DocumentList.js.map +1 -1
- package/dist/components/Employee/DocumentSigner/DocumentList/List.js +2 -6
- package/dist/components/Employee/DocumentSigner/DocumentList/List.js.map +1 -1
- package/dist/components/Employee/DocumentSigner/DocumentList/useDocumentList.js +3 -4
- package/dist/components/Employee/DocumentSigner/DocumentList/useDocumentList.js.map +1 -1
- package/dist/components/Employee/DocumentSigner/EmploymentEligibility/EmploymentEligibility.js +22 -22
- package/dist/components/Employee/DocumentSigner/EmploymentEligibility/EmploymentEligibility.js.map +1 -1
- package/dist/components/Employee/DocumentSigner/EmploymentEligibility/EmploymentEligibilityPresentation.js +24 -26
- package/dist/components/Employee/DocumentSigner/EmploymentEligibility/EmploymentEligibilityPresentation.js.map +1 -1
- package/dist/components/Employee/DocumentSigner/I9SignatureForm/I9SignatureForm.js +12 -14
- package/dist/components/Employee/DocumentSigner/I9SignatureForm/I9SignatureForm.js.map +1 -1
- package/dist/components/Employee/DocumentSigner/SignatureForm/SignatureForm.js +11 -15
- package/dist/components/Employee/DocumentSigner/SignatureForm/SignatureForm.js.map +1 -1
- package/dist/components/Employee/DocumentSigner/SignatureForm/useSignatureForm.js +3 -4
- package/dist/components/Employee/DocumentSigner/SignatureForm/useSignatureForm.js.map +1 -1
- package/dist/components/Employee/EmployeeDocuments/EmployeeDocumentsPresentation.js +6 -9
- package/dist/components/Employee/EmployeeDocuments/EmployeeDocumentsPresentation.js.map +1 -1
- package/dist/components/Employee/EmployeeList/EmployeeList.d.ts +3 -7
- package/dist/components/Employee/EmployeeList/EmployeeList.js +45 -95
- package/dist/components/Employee/EmployeeList/EmployeeList.js.map +1 -1
- package/dist/components/Employee/EmployeeList/EmployeeListView.d.ts +15 -0
- package/dist/components/Employee/EmployeeList/EmployeeListView.js +130 -0
- package/dist/components/Employee/EmployeeList/EmployeeListView.js.map +1 -0
- package/dist/components/Employee/EmployeeList/ManagementEmployeeList.d.ts +9 -0
- package/dist/components/Employee/EmployeeList/ManagementEmployeeList.js +81 -0
- package/dist/components/Employee/EmployeeList/ManagementEmployeeList.js.map +1 -0
- package/dist/components/Employee/EmployeeList/ManagementEmployeeListView.d.ts +17 -0
- package/dist/components/Employee/EmployeeList/ManagementEmployeeListView.js +193 -0
- package/dist/components/Employee/EmployeeList/ManagementEmployeeListView.js.map +1 -0
- package/dist/components/Employee/EmployeeList/index.d.ts +3 -0
- package/dist/components/Employee/EmployeeList/useEmployeeList.d.ts +36 -23
- package/dist/components/Employee/EmployeeList/useEmployeeList.js +114 -19
- package/dist/components/Employee/EmployeeList/useEmployeeList.js.map +1 -1
- package/dist/components/Employee/FederalTaxes/Actions.js +7 -9
- package/dist/components/Employee/FederalTaxes/Actions.js.map +1 -1
- package/dist/components/Employee/FederalTaxes/FederalForm.js +10 -12
- package/dist/components/Employee/FederalTaxes/FederalForm.js.map +1 -1
- package/dist/components/Employee/FederalTaxes/useFederalTaxes.js +3 -4
- package/dist/components/Employee/FederalTaxes/useFederalTaxes.js.map +1 -1
- package/dist/components/Employee/Landing/Landing.js +14 -15
- package/dist/components/Employee/Landing/Landing.js.map +1 -1
- package/dist/components/Employee/OnboardingFlow/OnboardingFlow.js +4 -4
- package/dist/components/Employee/OnboardingFlow/OnboardingFlow.js.map +1 -1
- package/dist/components/Employee/OnboardingFlow/OnboardingFlowComponents.d.ts +1 -0
- package/dist/components/Employee/OnboardingFlow/OnboardingFlowComponents.js +14 -8
- package/dist/components/Employee/OnboardingFlow/OnboardingFlowComponents.js.map +1 -1
- package/dist/components/Employee/OnboardingFlow/onboardingStateMachine.js +10 -11
- package/dist/components/Employee/OnboardingFlow/onboardingStateMachine.js.map +1 -1
- package/dist/components/Employee/OnboardingSummary/OnboardingSummary.js +7 -7
- package/dist/components/Employee/PaymentMethod/Actions.js +6 -8
- package/dist/components/Employee/PaymentMethod/Actions.js.map +1 -1
- package/dist/components/Employee/PaymentMethod/BankAccountEdit.js +5 -8
- package/dist/components/Employee/PaymentMethod/BankAccountEdit.js.map +1 -1
- package/dist/components/Employee/PaymentMethod/BankAccountsList.js +12 -13
- package/dist/components/Employee/PaymentMethod/BankAccountsList.js.map +1 -1
- package/dist/components/Employee/PaymentMethod/PaymentMethod.js +44 -43
- package/dist/components/Employee/PaymentMethod/PaymentMethod.js.map +1 -1
- package/dist/components/Employee/PaymentMethod/PaymentTypeForm.js +7 -10
- package/dist/components/Employee/PaymentMethod/PaymentTypeForm.js.map +1 -1
- package/dist/components/Employee/PaymentMethod/Split.js +9 -10
- package/dist/components/Employee/PaymentMethod/Split.js.map +1 -1
- package/dist/components/Employee/PaymentMethod/usePaymentMethod.d.ts +1 -0
- package/dist/components/Employee/PaymentMethod/usePaymentMethod.js +5 -6
- package/dist/components/Employee/PaymentMethod/usePaymentMethod.js.map +1 -1
- package/dist/components/Employee/Profile/Actions.js +7 -9
- package/dist/components/Employee/Profile/Actions.js.map +1 -1
- package/dist/components/Employee/Profile/AdminPersonalDetails.js +14 -16
- package/dist/components/Employee/Profile/AdminPersonalDetails.js.map +1 -1
- package/dist/components/Employee/Profile/HomeAddress.js +9 -10
- package/dist/components/Employee/Profile/HomeAddress.js.map +1 -1
- package/dist/components/Employee/Profile/PersonalDetailsInputs.js +10 -12
- package/dist/components/Employee/Profile/PersonalDetailsInputs.js.map +1 -1
- package/dist/components/Employee/Profile/Profile.js.map +1 -1
- package/dist/components/Employee/Profile/useProfile.js +3 -4
- package/dist/components/Employee/Profile/useProfile.js.map +1 -1
- package/dist/components/Employee/StateTaxes/Actions.js +8 -10
- package/dist/components/Employee/StateTaxes/Actions.js.map +1 -1
- package/dist/components/Employee/StateTaxes/useStateTaxes.js +3 -4
- package/dist/components/Employee/StateTaxes/useStateTaxes.js.map +1 -1
- package/dist/components/Employee/Taxes/Actions.js +8 -10
- package/dist/components/Employee/Taxes/Actions.js.map +1 -1
- package/dist/components/Employee/Taxes/FederalForm.js +10 -12
- package/dist/components/Employee/Taxes/FederalForm.js.map +1 -1
- package/dist/components/Employee/Taxes/useTaxes.js +3 -4
- package/dist/components/Employee/Taxes/useTaxes.js.map +1 -1
- package/dist/components/Employee/Terminations/TerminateEmployee/TerminateEmployee.js +48 -48
- package/dist/components/Employee/Terminations/TerminateEmployee/TerminateEmployee.js.map +1 -1
- package/dist/components/Employee/Terminations/TerminateEmployee/TerminateEmployeePresentation.js +14 -17
- package/dist/components/Employee/Terminations/TerminateEmployee/TerminateEmployeePresentation.js.map +1 -1
- package/dist/components/Employee/Terminations/TerminationFlow/TerminationFlowComponents.d.ts +1 -0
- package/dist/components/Employee/Terminations/TerminationFlow/TerminationFlowComponents.js +37 -33
- package/dist/components/Employee/Terminations/TerminationFlow/TerminationFlowComponents.js.map +1 -1
- package/dist/components/Employee/Terminations/TerminationFlow/terminationStateMachine.d.ts +1 -0
- package/dist/components/Employee/Terminations/TerminationFlow/terminationStateMachine.js +57 -45
- package/dist/components/Employee/Terminations/TerminationFlow/terminationStateMachine.js.map +1 -1
- package/dist/components/Employee/Terminations/TerminationSummary/TerminationSummaryPresentation.js +8 -11
- package/dist/components/Employee/Terminations/TerminationSummary/TerminationSummaryPresentation.js.map +1 -1
- package/dist/components/Employee/index.d.ts +3 -0
- package/dist/components/Employee/index.js +38 -34
- package/dist/components/Employee/index.js.map +1 -1
- package/dist/components/Flow/Flow.js +20 -23
- package/dist/components/Flow/Flow.js.map +1 -1
- package/dist/components/InformationRequests/InformationRequestForm/InformationRequestForm.js +16 -18
- package/dist/components/InformationRequests/InformationRequestForm/InformationRequestForm.js.map +1 -1
- package/dist/components/InformationRequests/InformationRequestList/InformationRequestList.js +18 -20
- package/dist/components/InformationRequests/InformationRequestList/InformationRequestList.js.map +1 -1
- package/dist/components/InformationRequests/InformationRequests.js +3 -4
- package/dist/components/InformationRequests/InformationRequests.js.map +1 -1
- package/dist/components/Payroll/ConfirmWireDetails/ConfirmWireDetailsBanner/ConfirmWireDetailsBanner.js.map +1 -1
- package/dist/components/Payroll/ConfirmWireDetails/ConfirmWireDetailsForm/ConfirmWireDetailsForm.js +8 -10
- package/dist/components/Payroll/ConfirmWireDetails/ConfirmWireDetailsForm/ConfirmWireDetailsForm.js.map +1 -1
- package/dist/components/Payroll/Dismissal/DismissalFlow.js +14 -14
- package/dist/components/Payroll/Dismissal/DismissalFlow.js.map +1 -1
- package/dist/components/Payroll/Dismissal/DismissalFlowComponents.d.ts +2 -2
- package/dist/components/Payroll/Dismissal/DismissalFlowComponents.js +21 -20
- package/dist/components/Payroll/Dismissal/DismissalFlowComponents.js.map +1 -1
- package/dist/components/Payroll/Dismissal/DismissalPayPeriodSelection/DismissalPayPeriodSelection.d.ts +2 -1
- package/dist/components/Payroll/Dismissal/DismissalPayPeriodSelection/DismissalPayPeriodSelection.js +57 -55
- package/dist/components/Payroll/Dismissal/DismissalPayPeriodSelection/DismissalPayPeriodSelection.js.map +1 -1
- package/dist/components/Payroll/Dismissal/DismissalPayPeriodSelection/DismissalPayPeriodSelectionPresentation.js +8 -11
- package/dist/components/Payroll/Dismissal/DismissalPayPeriodSelection/DismissalPayPeriodSelectionPresentation.js.map +1 -1
- package/dist/components/Payroll/GrossUpModal/GrossUpModal.d.ts +1 -1
- package/dist/components/Payroll/GrossUpModal/GrossUpModal.js +85 -74
- package/dist/components/Payroll/GrossUpModal/GrossUpModal.js.map +1 -1
- package/dist/components/Payroll/GrossUpModal/GrossUpModal.module.scss.js +7 -7
- package/dist/components/Payroll/GrossUpModal/GrossUpModalTypes.d.ts +0 -1
- package/dist/components/Payroll/OffCycle/OffCycleFlow.d.ts +1 -1
- package/dist/components/Payroll/OffCycle/OffCycleFlow.js +24 -18
- package/dist/components/Payroll/OffCycle/OffCycleFlow.js.map +1 -1
- package/dist/components/Payroll/OffCycle/OffCycleFlowComponents.d.ts +2 -0
- package/dist/components/Payroll/OffCycle/OffCycleFlowComponents.js +28 -22
- package/dist/components/Payroll/OffCycle/OffCycleFlowComponents.js.map +1 -1
- package/dist/components/Payroll/OffCycleCreation/OffCycleCreation.js +92 -84
- package/dist/components/Payroll/OffCycleCreation/OffCycleCreation.js.map +1 -1
- package/dist/components/Payroll/OffCycleCreation/OffCycleCreationPresentation.js +30 -32
- package/dist/components/Payroll/OffCycleCreation/OffCycleCreationPresentation.js.map +1 -1
- package/dist/components/Payroll/OffCyclePayPeriodDateForm/OffCyclePayPeriodDateFormPresentation.js +17 -24
- package/dist/components/Payroll/OffCyclePayPeriodDateForm/OffCyclePayPeriodDateFormPresentation.js.map +1 -1
- package/dist/components/Payroll/OffCyclePayPeriodDateForm/OffCyclePayPeriodDateFormTypes.d.ts +1 -1
- package/dist/components/Payroll/OffCyclePayPeriodDateForm/OffCyclePayPeriodDateFormTypes.js +21 -21
- package/dist/components/Payroll/OffCyclePayPeriodDateForm/OffCyclePayPeriodDateFormTypes.js.map +1 -1
- package/dist/components/Payroll/OffCyclePayPeriodDateForm/useOffCyclePayPeriodDateValidation.d.ts +3 -3
- package/dist/components/Payroll/OffCyclePayPeriodDateForm/useOffCyclePayPeriodDateValidation.js +13 -13
- package/dist/components/Payroll/OffCyclePayPeriodDateForm/useOffCyclePayPeriodDateValidation.js.map +1 -1
- package/dist/components/Payroll/OffCycleReasonSelection/OffCycleReasonSelectionPresentation.js +6 -8
- package/dist/components/Payroll/OffCycleReasonSelection/OffCycleReasonSelectionPresentation.js.map +1 -1
- package/dist/components/Payroll/OffCycleTaxWithholdingModal/OffCycleTaxWithholdingModal.js +12 -13
- package/dist/components/Payroll/OffCycleTaxWithholdingModal/OffCycleTaxWithholdingModal.js.map +1 -1
- package/dist/components/Payroll/PayrollBlocker/components/PayrollBlockerAlerts.js +11 -14
- package/dist/components/Payroll/PayrollBlocker/components/PayrollBlockerAlerts.js.map +1 -1
- package/dist/components/Payroll/PayrollBlocker/components/PayrollBlockerList.js +12 -12
- package/dist/components/Payroll/PayrollConfiguration/PayrollConfiguration.js +194 -190
- package/dist/components/Payroll/PayrollConfiguration/PayrollConfiguration.js.map +1 -1
- package/dist/components/Payroll/PayrollConfiguration/PayrollConfigurationPresentation.d.ts +1 -1
- package/dist/components/Payroll/PayrollConfiguration/PayrollConfigurationPresentation.js +69 -69
- package/dist/components/Payroll/PayrollConfiguration/PayrollConfigurationPresentation.js.map +1 -1
- package/dist/components/Payroll/PayrollConfiguration/usePayrollConfigurationData.d.ts +4 -3
- package/dist/components/Payroll/PayrollConfiguration/usePayrollConfigurationData.js +102 -76
- package/dist/components/Payroll/PayrollConfiguration/usePayrollConfigurationData.js.map +1 -1
- package/dist/components/Payroll/PayrollEditEmployee/PayrollEditEmployeePresentation.d.ts +2 -2
- package/dist/components/Payroll/PayrollEditEmployee/PayrollEditEmployeePresentation.js +235 -238
- package/dist/components/Payroll/PayrollEditEmployee/PayrollEditEmployeePresentation.js.map +1 -1
- package/dist/components/Payroll/PayrollEditEmployee/PayrollEditEmployeePresentation.module.scss.js +7 -7
- package/dist/components/Payroll/PayrollEditEmployee/TimeOffField.d.ts +11 -0
- package/dist/components/Payroll/PayrollEditEmployee/TimeOffField.js +63 -30
- package/dist/components/Payroll/PayrollEditEmployee/TimeOffField.js.map +1 -1
- package/dist/components/Payroll/PayrollExecutionFlow/PayrollExecutionFlow.d.ts +2 -1
- package/dist/components/Payroll/PayrollExecutionFlow/PayrollExecutionFlow.js +43 -41
- package/dist/components/Payroll/PayrollExecutionFlow/PayrollExecutionFlow.js.map +1 -1
- package/dist/components/Payroll/PayrollExecutionFlow/index.d.ts +1 -1
- package/dist/components/Payroll/PayrollExecutionFlow/payrollExecutionMachine.d.ts +1 -1
- package/dist/components/Payroll/PayrollExecutionFlow/payrollExecutionMachine.js +62 -51
- package/dist/components/Payroll/PayrollExecutionFlow/payrollExecutionMachine.js.map +1 -1
- package/dist/components/Payroll/PayrollFlow/OffCycleFlowContextual.js +13 -6
- package/dist/components/Payroll/PayrollFlow/OffCycleFlowContextual.js.map +1 -1
- package/dist/components/Payroll/PayrollFlow/PayrollExecutionFlowContextual.js +22 -20
- package/dist/components/Payroll/PayrollFlow/PayrollExecutionFlowContextual.js.map +1 -1
- package/dist/components/Payroll/PayrollFlow/PayrollFlowComponents.d.ts +1 -0
- package/dist/components/Payroll/PayrollFlow/PayrollFlowComponents.js.map +1 -1
- package/dist/components/Payroll/PayrollFlow/TransitionFlowContextual.js +35 -14
- package/dist/components/Payroll/PayrollFlow/TransitionFlowContextual.js.map +1 -1
- package/dist/components/Payroll/PayrollFlow/payrollStateMachine.js +80 -69
- package/dist/components/Payroll/PayrollFlow/payrollStateMachine.js.map +1 -1
- package/dist/components/Payroll/PayrollHistory/PayrollHistory.d.ts +0 -1
- package/dist/components/Payroll/PayrollHistory/PayrollHistory.js +59 -66
- package/dist/components/Payroll/PayrollHistory/PayrollHistory.js.map +1 -1
- package/dist/components/Payroll/PayrollHistory/PayrollHistoryPresentation.d.ts +5 -4
- package/dist/components/Payroll/PayrollHistory/PayrollHistoryPresentation.js +97 -105
- package/dist/components/Payroll/PayrollHistory/PayrollHistoryPresentation.js.map +1 -1
- package/dist/components/Payroll/PayrollList/PayrollList.js +98 -64
- package/dist/components/Payroll/PayrollList/PayrollList.js.map +1 -1
- package/dist/components/Payroll/PayrollList/PayrollListPresentation.d.ts +11 -3
- package/dist/components/Payroll/PayrollList/PayrollListPresentation.js +225 -123
- package/dist/components/Payroll/PayrollList/PayrollListPresentation.js.map +1 -1
- package/dist/components/Payroll/PayrollList/PayrollListPresentation.module.scss.js +10 -8
- package/dist/components/Payroll/PayrollList/PayrollListPresentation.module.scss.js.map +1 -1
- package/dist/components/Payroll/PayrollOverview/PayrollOverview.js +106 -105
- package/dist/components/Payroll/PayrollOverview/PayrollOverview.js.map +1 -1
- package/dist/components/Payroll/PayrollOverview/PayrollOverviewPresentation.d.ts +2 -1
- package/dist/components/Payroll/PayrollOverview/PayrollOverviewPresentation.js +222 -213
- package/dist/components/Payroll/PayrollOverview/PayrollOverviewPresentation.js.map +1 -1
- package/dist/components/Payroll/PayrollOverview/SubmissionBlockers/FastAchSubmissionBlockerBanner.d.ts +2 -1
- package/dist/components/Payroll/PayrollOverview/SubmissionBlockers/FastAchSubmissionBlockerBanner.js +7 -10
- package/dist/components/Payroll/PayrollOverview/SubmissionBlockers/FastAchSubmissionBlockerBanner.js.map +1 -1
- package/dist/components/Payroll/PayrollReceipts/PayrollReceiptsPresentation.js +103 -114
- package/dist/components/Payroll/PayrollReceipts/PayrollReceiptsPresentation.js.map +1 -1
- package/dist/components/Payroll/PayrollReceipts/PayrollReceiptsPresentation.module.scss.js +16 -18
- package/dist/components/Payroll/PayrollReceipts/PayrollReceiptsPresentation.module.scss.js.map +1 -1
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesList/RecoveryCasesList.js +2 -4
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesList/RecoveryCasesList.js.map +1 -1
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesResubmit/RecoveryCasesResubmit.js +11 -13
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesResubmit/RecoveryCasesResubmit.js.map +1 -1
- package/dist/components/Payroll/RecoveryCases/useRecoveryCaseErrorCode.js +2 -5
- package/dist/components/Payroll/RecoveryCases/useRecoveryCaseErrorCode.js.map +1 -1
- package/dist/components/Payroll/Transition/TransitionFlow.d.ts +1 -1
- package/dist/components/Payroll/Transition/TransitionFlow.js +29 -27
- package/dist/components/Payroll/Transition/TransitionFlow.js.map +1 -1
- package/dist/components/Payroll/Transition/TransitionFlowComponents.d.ts +1 -0
- package/dist/components/Payroll/Transition/TransitionFlowComponents.js.map +1 -1
- package/dist/components/Payroll/TransitionCreation/TransitionCreation.js +67 -63
- package/dist/components/Payroll/TransitionCreation/TransitionCreation.js.map +1 -1
- package/dist/components/Payroll/TransitionCreation/TransitionCreationPresentation.js +12 -14
- package/dist/components/Payroll/TransitionCreation/TransitionCreationPresentation.js.map +1 -1
- package/dist/components/Payroll/TransitionCreation/TransitionCreationTypes.d.ts +1 -1
- package/dist/components/Payroll/TransitionCreation/TransitionCreationTypes.js +5 -5
- package/dist/components/Payroll/TransitionCreation/TransitionCreationTypes.js.map +1 -1
- package/dist/components/Payroll/TransitionPayrollAlert/TransitionPayrollAlert.js +13 -13
- package/dist/components/Payroll/TransitionPayrollAlert/TransitionPayrollAlert.js.map +1 -1
- package/dist/components/Payroll/TransitionPayrollAlert/TransitionPayrollAlertPresentation.js +44 -55
- package/dist/components/Payroll/TransitionPayrollAlert/TransitionPayrollAlertPresentation.js.map +1 -1
- package/dist/components/Payroll/helpers.d.ts +6 -1
- package/dist/components/Payroll/helpers.js +81 -74
- package/dist/components/Payroll/helpers.js.map +1 -1
- package/dist/components/Payroll/usePreparedPayrollData.d.ts +2 -2
- package/dist/components/Payroll/usePreparedPayrollData.js +7 -8
- package/dist/components/Payroll/usePreparedPayrollData.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/form/FormFieldsMetadataContext.d.ts +2 -2
- package/dist/components/UNSTABLE_Hooks/form/FormFieldsMetadataContext.js +6 -9
- package/dist/components/UNSTABLE_Hooks/form/FormFieldsMetadataContext.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/form/FormFieldsMetadataProvider.d.ts +1 -1
- package/dist/components/UNSTABLE_Hooks/form/FormFieldsMetadataProvider.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/form/SDKFormProvider.d.ts +1 -2
- package/dist/components/UNSTABLE_Hooks/form/SDKFormProvider.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/form/buildFormSchema.d.ts +48 -0
- package/dist/components/UNSTABLE_Hooks/form/buildFormSchema.js +94 -0
- package/dist/components/UNSTABLE_Hooks/form/buildFormSchema.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/form/fields/CheckboxHookField.d.ts +3 -2
- package/dist/components/UNSTABLE_Hooks/form/fields/CheckboxHookField.js +24 -23
- package/dist/components/UNSTABLE_Hooks/form/fields/CheckboxHookField.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/form/fields/DatePickerHookField.d.ts +3 -2
- package/dist/components/UNSTABLE_Hooks/form/fields/DatePickerHookField.js +22 -17
- package/dist/components/UNSTABLE_Hooks/form/fields/DatePickerHookField.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/form/fields/NumberInputHookField.d.ts +3 -2
- package/dist/components/UNSTABLE_Hooks/form/fields/NumberInputHookField.js +31 -30
- package/dist/components/UNSTABLE_Hooks/form/fields/NumberInputHookField.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/form/fields/RadioGroupHookField.d.ts +3 -2
- package/dist/components/UNSTABLE_Hooks/form/fields/RadioGroupHookField.js +27 -26
- package/dist/components/UNSTABLE_Hooks/form/fields/RadioGroupHookField.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/form/fields/SelectHookField.d.ts +3 -2
- package/dist/components/UNSTABLE_Hooks/form/fields/SelectHookField.js +28 -27
- package/dist/components/UNSTABLE_Hooks/form/fields/SelectHookField.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/form/fields/SwitchHookField.d.ts +3 -2
- package/dist/components/UNSTABLE_Hooks/form/fields/SwitchHookField.js +24 -23
- package/dist/components/UNSTABLE_Hooks/form/fields/SwitchHookField.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/form/fields/TextInputHookField.d.ts +5 -4
- package/dist/components/UNSTABLE_Hooks/form/fields/TextInputHookField.js +28 -27
- package/dist/components/UNSTABLE_Hooks/form/fields/TextInputHookField.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/form/getFieldWithOptions.d.ts +1 -1
- package/dist/components/UNSTABLE_Hooks/form/getFieldWithOptions.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/form/index.d.ts +5 -5
- package/dist/components/UNSTABLE_Hooks/form/preprocessors.d.ts +3 -0
- package/dist/components/UNSTABLE_Hooks/form/preprocessors.js +15 -0
- package/dist/components/UNSTABLE_Hooks/form/preprocessors.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/form/resolveFieldError.d.ts +4 -0
- package/dist/components/UNSTABLE_Hooks/form/resolveFieldError.js +14 -0
- package/dist/components/UNSTABLE_Hooks/form/resolveFieldError.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/form/useDeriveFieldsMetadata.d.ts +17 -0
- package/dist/components/UNSTABLE_Hooks/form/useDeriveFieldsMetadata.js +21 -0
- package/dist/components/UNSTABLE_Hooks/form/useDeriveFieldsMetadata.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/form/useFieldErrorMessage.d.ts +1 -1
- package/dist/components/UNSTABLE_Hooks/form/useFieldErrorMessage.js +8 -8
- package/dist/components/UNSTABLE_Hooks/form/useFieldErrorMessage.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/form/useHookFieldResolution.d.ts +22 -0
- package/dist/components/UNSTABLE_Hooks/form/useHookFieldResolution.js +11 -0
- package/dist/components/UNSTABLE_Hooks/form/useHookFieldResolution.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/form/withOptions.d.ts +1 -1
- package/dist/components/UNSTABLE_Hooks/form/withOptions.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/hooks/useCompensationForm/CompensationForm.js +3 -5
- package/dist/components/UNSTABLE_Hooks/hooks/useCompensationForm/CompensationForm.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/hooks/useCompensationForm/compensationSchema.d.ts +48 -42
- package/dist/components/UNSTABLE_Hooks/hooks/useCompensationForm/compensationSchema.js +48 -79
- package/dist/components/UNSTABLE_Hooks/hooks/useCompensationForm/compensationSchema.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/hooks/useCompensationForm/fields.d.ts +2 -2
- package/dist/components/UNSTABLE_Hooks/hooks/useCompensationForm/fields.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/hooks/useCompensationForm/index.d.ts +2 -2
- package/dist/components/UNSTABLE_Hooks/hooks/useCompensationForm/useCompensationForm.d.ts +13 -15
- package/dist/components/UNSTABLE_Hooks/hooks/useCompensationForm/useCompensationForm.js +109 -110
- package/dist/components/UNSTABLE_Hooks/hooks/useCompensationForm/useCompensationForm.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/hooks/useEmployeeDetailsForm/EmployeeDetailsForm.js +16 -18
- package/dist/components/UNSTABLE_Hooks/hooks/useEmployeeDetailsForm/EmployeeDetailsForm.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/hooks/useEmployeeDetailsForm/employeeDetailsSchema.d.ts +13 -4
- package/dist/components/UNSTABLE_Hooks/hooks/useEmployeeDetailsForm/employeeDetailsSchema.js +31 -25
- package/dist/components/UNSTABLE_Hooks/hooks/useEmployeeDetailsForm/employeeDetailsSchema.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/hooks/useEmployeeDetailsForm/fields.d.ts +5 -4
- package/dist/components/UNSTABLE_Hooks/hooks/useEmployeeDetailsForm/fields.js +27 -27
- package/dist/components/UNSTABLE_Hooks/hooks/useEmployeeDetailsForm/fields.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/hooks/useEmployeeDetailsForm/index.d.ts +1 -1
- package/dist/components/UNSTABLE_Hooks/hooks/useEmployeeDetailsForm/useEmployeeDetailsForm.d.ts +8 -22
- package/dist/components/UNSTABLE_Hooks/hooks/useEmployeeDetailsForm/useEmployeeDetailsForm.js +81 -84
- package/dist/components/UNSTABLE_Hooks/hooks/useEmployeeDetailsForm/useEmployeeDetailsForm.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/hooks/usePayScheduleForm/PayScheduleForm.d.ts +5 -0
- package/dist/components/UNSTABLE_Hooks/hooks/usePayScheduleForm/PayScheduleForm.js +172 -0
- package/dist/components/UNSTABLE_Hooks/hooks/usePayScheduleForm/PayScheduleForm.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/hooks/usePayScheduleForm/PayScheduleForm.module.scss.js +14 -0
- package/dist/components/UNSTABLE_Hooks/hooks/usePayScheduleForm/PayScheduleForm.module.scss.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/hooks/usePayScheduleForm/fields.d.ts +23 -0
- package/dist/components/UNSTABLE_Hooks/hooks/usePayScheduleForm/fields.js +37 -0
- package/dist/components/UNSTABLE_Hooks/hooks/usePayScheduleForm/fields.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/hooks/usePayScheduleForm/index.d.ts +7 -0
- package/dist/components/UNSTABLE_Hooks/hooks/usePayScheduleForm/payScheduleSchema.d.ts +55 -0
- package/dist/components/UNSTABLE_Hooks/hooks/usePayScheduleForm/payScheduleSchema.js +54 -0
- package/dist/components/UNSTABLE_Hooks/hooks/usePayScheduleForm/payScheduleSchema.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/hooks/usePayScheduleForm/usePayScheduleForm.d.ts +69 -0
- package/dist/components/UNSTABLE_Hooks/hooks/usePayScheduleForm/usePayScheduleForm.js +180 -0
- package/dist/components/UNSTABLE_Hooks/hooks/usePayScheduleForm/usePayScheduleForm.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignCompanyForm/SignCompanyForm.d.ts +5 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignCompanyForm/SignCompanyForm.js +69 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignCompanyForm/SignCompanyForm.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignCompanyForm/fields.d.ts +9 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignCompanyForm/fields.js +14 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignCompanyForm/fields.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignCompanyForm/index.d.ts +7 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignCompanyForm/signCompanyFormSchema.d.ts +25 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignCompanyForm/signCompanyFormSchema.js +24 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignCompanyForm/signCompanyFormSchema.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignCompanyForm/useSignCompanyForm.d.ts +57 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignCompanyForm/useSignCompanyForm.js +101 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignCompanyForm/useSignCompanyForm.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignEmployeeForm/SignEmployeeForm.d.ts +5 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignEmployeeForm/SignEmployeeForm.js +71 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignEmployeeForm/SignEmployeeForm.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignEmployeeForm/SignEmployeeI9Form.d.ts +5 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignEmployeeForm/SignEmployeeI9Form.js +179 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignEmployeeForm/SignEmployeeI9Form.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignEmployeeForm/fields.d.ts +53 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignEmployeeForm/fields.js +164 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignEmployeeForm/fields.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignEmployeeForm/index.d.ts +9 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignEmployeeForm/signEmployeeFormSchema.d.ts +150 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignEmployeeForm/signEmployeeFormSchema.js +152 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignEmployeeForm/signEmployeeFormSchema.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignEmployeeForm/useSignEmployeeForm.d.ts +151 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignEmployeeForm/useSignEmployeeForm.js +172 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useSignEmployeeForm/useSignEmployeeForm.js.map +1 -0
- package/dist/components/UNSTABLE_Hooks/hooks/useWorkAddressForm/WorkAddressForm.js +15 -17
- package/dist/components/UNSTABLE_Hooks/hooks/useWorkAddressForm/WorkAddressForm.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/hooks/useWorkAddressForm/fields.d.ts +1 -1
- package/dist/components/UNSTABLE_Hooks/hooks/useWorkAddressForm/fields.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/hooks/useWorkAddressForm/index.d.ts +1 -1
- package/dist/components/UNSTABLE_Hooks/hooks/useWorkAddressForm/useWorkAddressForm.d.ts +9 -10
- package/dist/components/UNSTABLE_Hooks/hooks/useWorkAddressForm/useWorkAddressForm.js +85 -83
- package/dist/components/UNSTABLE_Hooks/hooks/useWorkAddressForm/useWorkAddressForm.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/hooks/useWorkAddressForm/workAddressSchema.d.ts +8 -4
- package/dist/components/UNSTABLE_Hooks/hooks/useWorkAddressForm/workAddressSchema.js +18 -17
- package/dist/components/UNSTABLE_Hooks/hooks/useWorkAddressForm/workAddressSchema.js.map +1 -1
- package/dist/components/UNSTABLE_Hooks/index.d.ts +10 -7
- package/dist/components/UNSTABLE_TimeOff/AddEmployeesHoliday/AddEmployeesHoliday.d.ts +5 -0
- package/dist/components/UNSTABLE_TimeOff/AddEmployeesHoliday/AddEmployeesHoliday.js +46 -0
- package/dist/components/UNSTABLE_TimeOff/AddEmployeesHoliday/AddEmployeesHoliday.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/AddEmployeesToPolicy/AddEmployeesToPolicy.d.ts +5 -0
- package/dist/components/UNSTABLE_TimeOff/AddEmployeesToPolicy/AddEmployeesToPolicy.js +46 -0
- package/dist/components/UNSTABLE_TimeOff/AddEmployeesToPolicy/AddEmployeesToPolicy.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/HolidaySelectionForm/HolidaySelectionForm.d.ts +5 -0
- package/dist/components/UNSTABLE_TimeOff/HolidaySelectionForm/HolidaySelectionForm.js +49 -0
- package/dist/components/UNSTABLE_TimeOff/HolidaySelectionForm/HolidaySelectionForm.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/HolidaySelectionForm/HolidaySelectionFormPresentation.d.ts +2 -0
- package/dist/components/UNSTABLE_TimeOff/HolidaySelectionForm/HolidaySelectionFormPresentation.js +55 -0
- package/dist/components/UNSTABLE_TimeOff/HolidaySelectionForm/HolidaySelectionFormPresentation.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/HolidaySelectionForm/HolidaySelectionFormTypes.d.ts +25 -0
- package/dist/components/UNSTABLE_TimeOff/PolicyList/PolicyList.d.ts +5 -0
- package/dist/components/UNSTABLE_TimeOff/PolicyList/PolicyList.js +73 -0
- package/dist/components/UNSTABLE_TimeOff/PolicyList/PolicyList.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/PolicyList/PolicyListPresentation.d.ts +2 -0
- package/dist/components/UNSTABLE_TimeOff/PolicyList/PolicyListPresentation.js +122 -0
- package/dist/components/UNSTABLE_TimeOff/PolicyList/PolicyListPresentation.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/PolicyList/PolicyListPresentation.module.scss.js +8 -0
- package/dist/components/UNSTABLE_TimeOff/PolicyList/PolicyListPresentation.module.scss.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/PolicyList/PolicyListTypes.d.ts +17 -0
- package/dist/components/UNSTABLE_TimeOff/PolicySettings/PolicySettings.d.ts +5 -0
- package/dist/components/UNSTABLE_TimeOff/PolicySettings/PolicySettings.js +46 -0
- package/dist/components/UNSTABLE_TimeOff/PolicySettings/PolicySettings.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/PolicyTypeSelector/PolicyTypeSelector.d.ts +7 -0
- package/dist/components/UNSTABLE_TimeOff/PolicyTypeSelector/PolicyTypeSelector.js +29 -0
- package/dist/components/UNSTABLE_TimeOff/PolicyTypeSelector/PolicyTypeSelector.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/PolicyTypeSelector/PolicyTypeSelectorPresentation.d.ts +2 -0
- package/dist/components/UNSTABLE_TimeOff/PolicyTypeSelector/PolicyTypeSelectorPresentation.js +66 -0
- package/dist/components/UNSTABLE_TimeOff/PolicyTypeSelector/PolicyTypeSelectorPresentation.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/PolicyTypeSelector/PolicyTypeSelectorTypes.d.ts +6 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffFlow/TimeOffFlow.d.ts +2 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffFlow/TimeOffFlow.js +25 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffFlow/TimeOffFlow.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffFlow/TimeOffFlowComponents.d.ts +29 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffFlow/TimeOffFlowComponents.js +103 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffFlow/TimeOffFlowComponents.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffFlow/index.d.ts +3 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffFlow/timeOffStateMachine.d.ts +14 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffFlow/timeOffStateMachine.js +290 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffFlow/timeOffStateMachine.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffFlow/timeOffStateMachine.test.d.ts +1 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationForm.d.ts +8 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationForm.js +71 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationForm.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationForm.module.scss.js +12 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationForm.module.scss.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationFormPresentation.d.ts +2 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationFormPresentation.js +206 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationFormPresentation.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationFormTypes.d.ts +20 -0
- package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/PolicyConfigurationForm/index.d.ts +6 -0
- package/dist/components/UNSTABLE_TimeOff/ViewHolidayEmployees/ViewHolidayEmployees.d.ts +5 -0
- package/dist/components/UNSTABLE_TimeOff/ViewHolidayEmployees/ViewHolidayEmployees.js +35 -0
- package/dist/components/UNSTABLE_TimeOff/ViewHolidayEmployees/ViewHolidayEmployees.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/ViewHolidaySchedule/ViewHolidaySchedule.d.ts +5 -0
- package/dist/components/UNSTABLE_TimeOff/ViewHolidaySchedule/ViewHolidaySchedule.js +35 -0
- package/dist/components/UNSTABLE_TimeOff/ViewHolidaySchedule/ViewHolidaySchedule.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/ViewPolicyDetails/ViewPolicyDetails.d.ts +5 -0
- package/dist/components/UNSTABLE_TimeOff/ViewPolicyDetails/ViewPolicyDetails.js +35 -0
- package/dist/components/UNSTABLE_TimeOff/ViewPolicyDetails/ViewPolicyDetails.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/ViewPolicyEmployees/ViewPolicyEmployees.d.ts +5 -0
- package/dist/components/UNSTABLE_TimeOff/ViewPolicyEmployees/ViewPolicyEmployees.js +35 -0
- package/dist/components/UNSTABLE_TimeOff/ViewPolicyEmployees/ViewPolicyEmployees.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/index.d.ts +25 -0
- package/dist/components/UNSTABLE_TimeOff/index.js +27 -0
- package/dist/components/UNSTABLE_TimeOff/index.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/shared/EmployeeTable/EmployeeTable.d.ts +2 -0
- package/dist/components/UNSTABLE_TimeOff/shared/EmployeeTable/EmployeeTableTypes.d.ts +26 -0
- package/dist/components/UNSTABLE_TimeOff/shared/EmployeeTable/index.d.ts +4 -0
- package/dist/components/UNSTABLE_TimeOff/shared/holidayHelpers.d.ts +30 -0
- package/dist/components/UNSTABLE_TimeOff/shared/holidayHelpers.js +97 -0
- package/dist/components/UNSTABLE_TimeOff/shared/holidayHelpers.js.map +1 -0
- package/dist/components/UNSTABLE_TimeOff/shared/holidayHelpers.test.d.ts +1 -0
- package/dist/components/index.d.ts +1 -0
- package/dist/contexts/ComponentAdapter/adapters/defaultComponentAdapter.js +66 -62
- package/dist/contexts/ComponentAdapter/adapters/defaultComponentAdapter.js.map +1 -1
- package/dist/contexts/ComponentAdapter/componentAdapterTypes.d.ts +1 -0
- package/dist/contexts/ComponentAdapter/createComponentsWithDefaults.d.ts +10 -0
- package/dist/contexts/ComponentAdapter/createComponentsWithDefaults.js +28 -21
- package/dist/contexts/ComponentAdapter/createComponentsWithDefaults.js.map +1 -1
- package/dist/contexts/ComponentAdapter/useComponentContext.d.ts +4 -0
- package/dist/contexts/ComponentAdapter/useComponentContext.js.map +1 -1
- package/dist/contexts/GustoProvider/GustoProviderCustomUIAdapter.js +10 -12
- package/dist/contexts/GustoProvider/GustoProviderCustomUIAdapter.js.map +1 -1
- package/dist/contexts/LoadingIndicatorProvider/useLoadingIndicator.d.ts +10 -2
- package/dist/contexts/LoadingIndicatorProvider/useLoadingIndicator.js.map +1 -1
- package/dist/contexts/ThemeProvider/theme.d.ts +2 -0
- package/dist/contexts/ThemeProvider/theme.js +4 -2
- package/dist/contexts/ThemeProvider/theme.js.map +1 -1
- package/dist/contexts/ThemeProvider/useTheme.js.map +1 -1
- package/dist/helpers/breadcrumbHelpers.d.ts +14 -0
- package/dist/helpers/breadcrumbHelpers.js +35 -26
- package/dist/helpers/breadcrumbHelpers.js.map +1 -1
- package/dist/helpers/buildQueryErrorHandling.d.ts +22 -0
- package/dist/helpers/buildQueryErrorHandling.js +11 -0
- package/dist/helpers/buildQueryErrorHandling.js.map +1 -0
- package/dist/{components/UNSTABLE_Hooks → helpers}/collectErrors.d.ts +1 -1
- package/dist/{components/UNSTABLE_Hooks → helpers}/collectErrors.js +1 -1
- package/dist/helpers/collectErrors.js.map +1 -0
- package/dist/helpers/dateFormatting.d.ts +2 -0
- package/dist/helpers/dateFormatting.js +38 -33
- package/dist/helpers/dateFormatting.js.map +1 -1
- package/dist/helpers/formattedStrings.js +40 -33
- package/dist/helpers/formattedStrings.js.map +1 -1
- package/dist/hooks/useCompanyPaymentSpeed.d.ts +6 -0
- package/dist/hooks/useCompanyPaymentSpeed.js +19 -0
- package/dist/hooks/useCompanyPaymentSpeed.js.map +1 -0
- package/dist/hooks/useCompanyPaymentSpeed.test.d.ts +1 -0
- package/dist/hooks/useDateRangeFilter/useDateRangeFilter.d.ts +20 -0
- package/dist/hooks/useDateRangeFilter/useDateRangeFilter.js +38 -0
- package/dist/hooks/useDateRangeFilter/useDateRangeFilter.js.map +1 -0
- package/dist/hooks/useDateRangeFilter/useDateRangeFilter.test.d.ts +1 -0
- package/dist/{components/UNSTABLE_Hooks → hooks}/useErrorHandling.d.ts +2 -2
- package/dist/{components/UNSTABLE_Hooks → hooks}/useErrorHandling.js +1 -1
- package/dist/hooks/useErrorHandling.js.map +1 -0
- package/dist/hooks/useErrorHandling.test.d.ts +1 -0
- package/dist/hooks/usePagination/usePagination.d.ts +2 -0
- package/dist/hooks/usePagination/usePagination.js +32 -29
- package/dist/hooks/usePagination/usePagination.js.map +1 -1
- package/dist/i18n/I18n.js +21 -21
- package/dist/i18n/I18n.js.map +1 -1
- package/dist/i18n/en/Company.PaySchedule.json.js +6 -6
- package/dist/i18n/en/Company.TimeOff.CreateTimeOffPolicy.json.js +24 -0
- package/dist/i18n/en/Company.TimeOff.CreateTimeOffPolicy.json.js.map +1 -0
- package/dist/i18n/en/Company.TimeOff.EmployeeTable.json.js +32 -0
- package/dist/i18n/en/Company.TimeOff.EmployeeTable.json.js.map +1 -0
- package/dist/i18n/en/Company.TimeOff.HolidayPolicy.json.js +28 -0
- package/dist/i18n/en/Company.TimeOff.HolidayPolicy.json.js.map +1 -0
- package/dist/i18n/en/Company.TimeOff.SelectPolicyType.json.js +28 -0
- package/dist/i18n/en/Company.TimeOff.SelectPolicyType.json.js.map +1 -0
- package/dist/i18n/en/Company.TimeOff.TimeOffPolicies.json.js +38 -0
- package/dist/i18n/en/Company.TimeOff.TimeOffPolicies.json.js.map +1 -0
- package/dist/i18n/en/Company.TimeOff.TimeOffPolicyDetails.json.js +52 -0
- package/dist/i18n/en/Company.TimeOff.TimeOffPolicyDetails.json.js.map +1 -0
- package/dist/i18n/en/Company.TimeOff.TimeOffRequests.json.js +21 -0
- package/dist/i18n/en/Company.TimeOff.TimeOffRequests.json.js.map +1 -0
- package/dist/i18n/en/Contractor.Payments.CreatePayment.json.js +36 -34
- package/dist/i18n/en/Contractor.Payments.CreatePayment.json.js.map +1 -1
- package/dist/i18n/en/Employee.Dashboard.json.js +26 -0
- package/dist/i18n/en/Employee.Dashboard.json.js.map +1 -0
- package/dist/i18n/en/Employee.EmployeeList.json.js +22 -20
- package/dist/i18n/en/Employee.EmployeeList.json.js.map +1 -1
- package/dist/i18n/en/Employee.ManagementEmployeeList.json.js +40 -0
- package/dist/i18n/en/Employee.ManagementEmployeeList.json.js.map +1 -0
- package/dist/i18n/en/Payroll.GrossUpModal.json.js +16 -14
- package/dist/i18n/en/Payroll.GrossUpModal.json.js.map +1 -1
- package/dist/i18n/en/Payroll.OffCycle.json.js +1 -1
- package/dist/i18n/en/Payroll.OffCyclePayPeriodDateForm.json.js +5 -5
- package/dist/i18n/en/Payroll.OffCycleTaxWithholding.json.js +5 -5
- package/dist/i18n/en/Payroll.PayrollConfiguration.json.js +38 -34
- package/dist/i18n/en/Payroll.PayrollConfiguration.json.js.map +1 -1
- package/dist/i18n/en/Payroll.PayrollEditEmployee.json.js +29 -25
- package/dist/i18n/en/Payroll.PayrollEditEmployee.json.js.map +1 -1
- package/dist/i18n/en/Payroll.PayrollHistory.json.js +12 -12
- package/dist/i18n/en/Payroll.PayrollList.json.js +30 -22
- package/dist/i18n/en/Payroll.PayrollList.json.js.map +1 -1
- package/dist/i18n/en/Payroll.PayrollOverview.json.js +64 -58
- package/dist/i18n/en/Payroll.PayrollOverview.json.js.map +1 -1
- package/dist/i18n/en/Payroll.TransitionCreation.json.js +9 -9
- package/dist/i18n/en/Payroll.TransitionPayrollAlert.json.js +8 -8
- package/dist/i18n/en/UNSTABLE.PayScheduleForm.json.js +24 -0
- package/dist/i18n/en/UNSTABLE.PayScheduleForm.json.js.map +1 -0
- package/dist/i18n/en/UNSTABLE.SignCompanyForm.json.js +20 -0
- package/dist/i18n/en/UNSTABLE.SignCompanyForm.json.js.map +1 -0
- package/dist/i18n/en/UNSTABLE.SignEmployeeForm.json.js +22 -0
- package/dist/i18n/en/UNSTABLE.SignEmployeeForm.json.js.map +1 -0
- package/dist/i18n/en/UNSTABLE.SignEmployeeI9Form.json.js +70 -0
- package/dist/i18n/en/UNSTABLE.SignEmployeeI9Form.json.js.map +1 -0
- package/dist/i18n/en/common.json.d.ts +3 -1
- package/dist/i18n/en/common.json.js +5 -5
- package/dist/index.js +18 -16
- package/dist/index.js.map +1 -1
- package/dist/shared/constants.d.ts +56 -0
- package/dist/shared/constants.js +100 -70
- package/dist/shared/constants.js.map +1 -1
- package/dist/style.css +1 -1
- package/dist/types/i18next.d.ts +817 -12
- package/dist/{components/UNSTABLE_Hooks/types.d.ts → types/sdkHooks.d.ts} +29 -5
- package/docs/reference/endpoint-inventory.json +659 -391
- package/package.json +33 -24
- package/dist/components/Employee/EmployeeList/Actions.d.ts +0 -1
- package/dist/components/Employee/EmployeeList/Actions.js +0 -16
- package/dist/components/Employee/EmployeeList/Actions.js.map +0 -1
- package/dist/components/Employee/EmployeeList/Head.d.ts +0 -1
- package/dist/components/Employee/EmployeeList/Head.js +0 -15
- package/dist/components/Employee/EmployeeList/Head.js.map +0 -1
- package/dist/components/Employee/EmployeeList/List.d.ts +0 -2
- package/dist/components/Employee/EmployeeList/List.js +0 -125
- package/dist/components/Employee/EmployeeList/List.js.map +0 -1
- package/dist/components/Employee/EmployeeList/List.module.scss.js +0 -8
- package/dist/components/Employee/EmployeeList/List.module.scss.js.map +0 -1
- package/dist/components/Payroll/PayrollHistory/PayrollHistoryPresentation.module.scss.js +0 -8
- package/dist/components/Payroll/PayrollHistory/PayrollHistoryPresentation.module.scss.js.map +0 -1
- package/dist/components/UNSTABLE_Hooks/collectErrors.js.map +0 -1
- package/dist/components/UNSTABLE_Hooks/form/composeFormSchema.d.ts +0 -26
- package/dist/components/UNSTABLE_Hooks/form/composeFormSchema.js +0 -24
- package/dist/components/UNSTABLE_Hooks/form/composeFormSchema.js.map +0 -1
- package/dist/components/UNSTABLE_Hooks/form/deriveFieldsMetadata.d.ts +0 -3
- package/dist/components/UNSTABLE_Hooks/form/deriveFieldsMetadata.js +0 -14
- package/dist/components/UNSTABLE_Hooks/form/deriveFieldsMetadata.js.map +0 -1
- package/dist/components/UNSTABLE_Hooks/form/resolveRequiredFields.d.ts +0 -6
- package/dist/components/UNSTABLE_Hooks/form/resolveRequiredFields.js +0 -14
- package/dist/components/UNSTABLE_Hooks/form/resolveRequiredFields.js.map +0 -1
- package/dist/components/UNSTABLE_Hooks/form/types.d.ts +0 -27
- package/dist/components/UNSTABLE_Hooks/form/useFieldsMetadata.d.ts +0 -4
- package/dist/components/UNSTABLE_Hooks/form/useFieldsMetadata.js +0 -9
- package/dist/components/UNSTABLE_Hooks/form/useFieldsMetadata.js.map +0 -1
- package/dist/components/UNSTABLE_Hooks/useErrorHandling.js.map +0 -1
- package/dist/helpers/requiredIf.d.ts +0 -13
- package/dist/helpers/requiredIf.js +0 -8
- package/dist/helpers/requiredIf.js.map +0 -1
- /package/dist/components/UNSTABLE_Hooks/form/{deriveFieldsMetadata.test.d.ts → buildFormSchema.test.d.ts} +0 -0
- /package/dist/components/UNSTABLE_Hooks/{useErrorHandling.test.d.ts → hooks/useCompensationForm/compensationSchemaParity.test.d.ts} +0 -0
package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatementPresentation.js
CHANGED
|
@@ -1,126 +1,114 @@
|
|
|
1
1
|
import { jsxs as a, jsx as e } from "react/jsx-runtime";
|
|
2
|
-
import { useTranslation as
|
|
3
|
-
import { useMemo as
|
|
4
|
-
import { getContractorDisplayName as
|
|
5
|
-
import
|
|
6
|
-
import { Flex as
|
|
7
|
-
import "
|
|
8
|
-
import "../../../../
|
|
9
|
-
import {
|
|
10
|
-
import
|
|
11
|
-
import {
|
|
12
|
-
import M from "../../../../hooks/useNumberFormatter.js";
|
|
13
|
-
import { useDateFormatter as j } from "../../../../hooks/useDateFormatter.js";
|
|
2
|
+
import { useTranslation as k, Trans as F } from "react-i18next";
|
|
3
|
+
import { useMemo as C } from "react";
|
|
4
|
+
import { getContractorDisplayName as v } from "../CreatePayment/helpers.js";
|
|
5
|
+
import l from "./PaymentStatementPresentation.module.scss.js";
|
|
6
|
+
import { Flex as c } from "../../../Common/Flex/Flex.js";
|
|
7
|
+
import { useComponentContext as H } from "../../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
8
|
+
import { useI18n as M } from "../../../../i18n/I18n.js";
|
|
9
|
+
import { formatHoursDisplay as A } from "../../../Payroll/helpers.js";
|
|
10
|
+
import j from "../../../../hooks/useNumberFormatter.js";
|
|
11
|
+
import { useDateFormatter as y } from "../../../../hooks/useDateFormatter.js";
|
|
14
12
|
import { addressInline as B, formatPhoneNumber as K } from "../../../../helpers/formattedStrings.js";
|
|
15
13
|
import O from "../../../../assets/icons/receipt-check.svg.js";
|
|
16
|
-
import { DataView as
|
|
14
|
+
import { DataView as U } from "../../../Common/DataView/DataView.js";
|
|
17
15
|
const re = ({
|
|
18
|
-
payment:
|
|
19
|
-
contractor:
|
|
20
|
-
checkDate:
|
|
16
|
+
payment: o,
|
|
17
|
+
contractor: m,
|
|
18
|
+
checkDate: w,
|
|
21
19
|
paymentReceipt: t
|
|
22
20
|
}) => {
|
|
23
|
-
const { Text: n, Heading:
|
|
24
|
-
|
|
25
|
-
const { t: r } =
|
|
21
|
+
const h = H(), { Text: n, Heading: b, Link: z } = h;
|
|
22
|
+
M("Contractor.Payments.PaymentStatement");
|
|
23
|
+
const { t: r } = k("Contractor.Payments.PaymentStatement"), i = j("currency"), { formatLongWithYear: u } = y(), f = v(m), p = o.wageType === "Hourly", d = Number(o.hours || 0), g = Number(o.hourlyRate || 0), D = Number(o.bonus || 0), N = Number(o.reimbursement || 0), x = Number(o.wageTotal || 0), I = !!(t && o.status === "Funded" && o.paymentMethod === "Direct Deposit"), S = t?.totals?.companyDebit || "0", L = C(() => t ? [
|
|
26
24
|
{
|
|
27
25
|
label: r("receipt.from"),
|
|
28
26
|
value: t.nameOfSender || ""
|
|
29
27
|
},
|
|
30
28
|
{
|
|
31
29
|
label: r("receipt.to"),
|
|
32
|
-
value:
|
|
30
|
+
value: v(m)
|
|
33
31
|
},
|
|
34
32
|
{
|
|
35
33
|
label: r("receipt.debitDate"),
|
|
36
34
|
value: t.debitDate ? u(String(t.debitDate)) : ""
|
|
37
35
|
}
|
|
38
|
-
] : [], [t,
|
|
39
|
-
const
|
|
36
|
+
] : [], [t, m, r, u]), P = C(() => {
|
|
37
|
+
const s = [
|
|
40
38
|
{
|
|
41
|
-
label:
|
|
42
|
-
amount:
|
|
39
|
+
label: o.paymentMethod || "",
|
|
40
|
+
amount: i(x)
|
|
43
41
|
}
|
|
44
42
|
];
|
|
45
|
-
return
|
|
43
|
+
return p && d > 0 ? s.push({
|
|
46
44
|
label: r("hoursLabel"),
|
|
47
45
|
amount: r("hoursAmount", {
|
|
48
|
-
hours:
|
|
49
|
-
rate:
|
|
46
|
+
hours: A(d),
|
|
47
|
+
rate: i(g)
|
|
50
48
|
})
|
|
51
|
-
}) :
|
|
49
|
+
}) : s.push({
|
|
52
50
|
label: r("wageLabel"),
|
|
53
|
-
amount:
|
|
54
|
-
}),
|
|
51
|
+
amount: i(Number(o.wage || 0))
|
|
52
|
+
}), s.push({
|
|
55
53
|
label: r("bonus"),
|
|
56
|
-
amount:
|
|
57
|
-
}),
|
|
54
|
+
amount: i(D)
|
|
55
|
+
}), s.push({
|
|
58
56
|
label: r("reimbursement"),
|
|
59
|
-
amount:
|
|
60
|
-
}),
|
|
57
|
+
amount: i(N)
|
|
58
|
+
}), s;
|
|
61
59
|
}, [
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
f,
|
|
65
|
-
d,
|
|
60
|
+
o.paymentMethod,
|
|
61
|
+
x,
|
|
66
62
|
p,
|
|
63
|
+
d,
|
|
67
64
|
g,
|
|
65
|
+
D,
|
|
68
66
|
N,
|
|
69
67
|
r,
|
|
70
|
-
|
|
71
|
-
|
|
68
|
+
i,
|
|
69
|
+
o.wage
|
|
72
70
|
]);
|
|
73
|
-
return /* @__PURE__ */ a(
|
|
74
|
-
/* @__PURE__ */ e(
|
|
75
|
-
/* @__PURE__ */ e(
|
|
76
|
-
/* @__PURE__ */ e(n, { children: u(
|
|
71
|
+
return /* @__PURE__ */ a(c, { flexDirection: "column", gap: 32, children: [
|
|
72
|
+
/* @__PURE__ */ e(c, { flexDirection: "column", gap: 16, children: /* @__PURE__ */ a(c, { flexDirection: "column", gap: 8, children: [
|
|
73
|
+
/* @__PURE__ */ e(b, { as: "h2", children: r("title", { contractorName: f }) }),
|
|
74
|
+
/* @__PURE__ */ e(n, { children: u(w) })
|
|
77
75
|
] }) }),
|
|
78
|
-
|
|
79
|
-
/* @__PURE__ */ a(
|
|
80
|
-
/* @__PURE__ */ e("div", { className:
|
|
81
|
-
/* @__PURE__ */ a(
|
|
76
|
+
I && /* @__PURE__ */ e("div", { className: l.receiptCard, children: /* @__PURE__ */ a(c, { flexDirection: "column", gap: 24, children: [
|
|
77
|
+
/* @__PURE__ */ a(c, { flexDirection: "column", alignItems: "center", gap: 16, children: [
|
|
78
|
+
/* @__PURE__ */ e("div", { className: l.receiptIcon, "aria-hidden": !0, children: /* @__PURE__ */ e(O, { className: l.checkmarkIcon }) }),
|
|
79
|
+
/* @__PURE__ */ a(c, { flexDirection: "column", alignItems: "center", gap: 8, children: [
|
|
82
80
|
/* @__PURE__ */ e(n, { size: "sm", variant: "supporting", children: r("receipt.totalLabel") }),
|
|
83
|
-
/* @__PURE__ */ e(
|
|
81
|
+
/* @__PURE__ */ e(b, { as: "h1", styledAs: "h2", className: l.totalAmount, children: i(Number(S)) })
|
|
84
82
|
] })
|
|
85
83
|
] }),
|
|
86
|
-
/* @__PURE__ */ e(
|
|
87
|
-
|
|
84
|
+
/* @__PURE__ */ e(
|
|
85
|
+
h.DescriptionList,
|
|
88
86
|
{
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
{
|
|
98
|
-
title: "",
|
|
99
|
-
render: (o) => /* @__PURE__ */ e(n, { size: "sm", variant: "supporting", children: o.label })
|
|
100
|
-
},
|
|
101
|
-
{
|
|
102
|
-
title: "",
|
|
103
|
-
render: (o) => /* @__PURE__ */ e(n, { size: "sm", children: o.value })
|
|
104
|
-
}
|
|
105
|
-
],
|
|
106
|
-
data: L
|
|
87
|
+
layout: "horizontal",
|
|
88
|
+
showSeparators: !1,
|
|
89
|
+
items: L.map(
|
|
90
|
+
({ label: s, value: T }) => ({
|
|
91
|
+
term: /* @__PURE__ */ e(n, { size: "sm", variant: "supporting", children: s }),
|
|
92
|
+
description: /* @__PURE__ */ e(n, { size: "sm", children: T })
|
|
93
|
+
})
|
|
94
|
+
)
|
|
107
95
|
}
|
|
108
|
-
)
|
|
96
|
+
),
|
|
109
97
|
/* @__PURE__ */ e("hr", {}),
|
|
110
|
-
/* @__PURE__ */ a(
|
|
111
|
-
/* @__PURE__ */ e(n, { size: "sm", variant: "supporting", className:
|
|
98
|
+
/* @__PURE__ */ a(c, { flexDirection: "column", alignItems: "center", gap: 12, children: [
|
|
99
|
+
/* @__PURE__ */ e(n, { size: "sm", variant: "supporting", className: l.disclaimer, children: /* @__PURE__ */ e(
|
|
112
100
|
F,
|
|
113
101
|
{
|
|
114
102
|
i18nKey: "receipt.disclaimer",
|
|
115
103
|
t: r,
|
|
116
104
|
components: {
|
|
117
|
-
licensesLink: /* @__PURE__ */ e(
|
|
105
|
+
licensesLink: /* @__PURE__ */ e(z, { href: t?.licenseUri || "", target: "_blank" })
|
|
118
106
|
}
|
|
119
107
|
}
|
|
120
108
|
) }),
|
|
121
109
|
/* @__PURE__ */ e("hr", {}),
|
|
122
|
-
/* @__PURE__ */ e(n, { size: "sm", variant: "supporting", className:
|
|
123
|
-
/* @__PURE__ */ a(n, { size: "sm", variant: "supporting", className:
|
|
110
|
+
/* @__PURE__ */ e(n, { size: "sm", variant: "supporting", className: l.companyInfo, children: t?.licensee?.name || "" }),
|
|
111
|
+
/* @__PURE__ */ a(n, { size: "sm", variant: "supporting", className: l.address, children: [
|
|
124
112
|
B({
|
|
125
113
|
street1: t?.licensee?.address || "",
|
|
126
114
|
city: t?.licensee?.city || "",
|
|
@@ -133,20 +121,20 @@ const re = ({
|
|
|
133
121
|
] })
|
|
134
122
|
] }) }),
|
|
135
123
|
/* @__PURE__ */ e(
|
|
136
|
-
|
|
124
|
+
U,
|
|
137
125
|
{
|
|
138
126
|
columns: [
|
|
139
127
|
{
|
|
140
128
|
title: r("debitedColumn"),
|
|
141
|
-
render: ({ label:
|
|
129
|
+
render: ({ label: s }) => /* @__PURE__ */ e(n, { children: s })
|
|
142
130
|
},
|
|
143
131
|
{
|
|
144
132
|
title: r("amountColumn"),
|
|
145
|
-
render: ({ amount:
|
|
133
|
+
render: ({ amount: s }) => /* @__PURE__ */ e(n, { children: s || "" })
|
|
146
134
|
}
|
|
147
135
|
],
|
|
148
136
|
data: P,
|
|
149
|
-
label: r("title", { contractorName:
|
|
137
|
+
label: r("title", { contractorName: f })
|
|
150
138
|
}
|
|
151
139
|
)
|
|
152
140
|
] });
|
package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatementPresentation.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PaymentStatementPresentation.js","sources":["../../../../../src/components/Contractor/Payments/PaymentStatement/PaymentStatementPresentation.tsx"],"sourcesContent":["import { Trans, useTranslation } from 'react-i18next'\nimport type { ContractorPaymentForGroup } from '@gusto/embedded-api/models/components/contractorpaymentforgroup'\nimport type { Contractor } from '@gusto/embedded-api/models/components/contractor'\nimport { useMemo } from 'react'\nimport type { ContractorPaymentReceipt } from '@gusto/embedded-api/models/components/contractorpaymentreceipt'\nimport { getContractorDisplayName } from '../CreatePayment/helpers'\nimport styles from './PaymentStatementPresentation.module.scss'\nimport { DataView, Flex } from '@/components/Common'\nimport { useComponentContext } from '@/contexts/ComponentAdapter/useComponentContext'\nimport { useI18n } from '@/i18n'\nimport { formatHoursDisplay } from '@/components/Payroll/helpers'\nimport useNumberFormatter from '@/hooks/useNumberFormatter'\nimport { useDateFormatter } from '@/hooks/useDateFormatter'\nimport { addressInline, formatPhoneNumber } from '@/helpers/formattedStrings'\nimport ReceiptCheck from '@/assets/icons/receipt-check.svg?react'\n\ninterface PaymentStatementPresentationProps {\n payment: ContractorPaymentForGroup\n contractor: Contractor\n paymentReceipt?: ContractorPaymentReceipt\n checkDate: string\n}\n\ntype PaymentStatementRow = {\n label: string\n amount: string | null\n}\n\nexport const PaymentStatementPresentation = ({\n payment,\n contractor,\n checkDate,\n paymentReceipt,\n}: PaymentStatementPresentationProps) => {\n const { Text, Heading } = useComponentContext()\n useI18n('Contractor.Payments.PaymentStatement')\n const { t } = useTranslation('Contractor.Payments.PaymentStatement')\n const currencyFormatter = useNumberFormatter('currency')\n const { formatLongWithYear } = useDateFormatter()\n const { Link } = useComponentContext()\n\n const contractorName = getContractorDisplayName(contractor)\n const isHourly = payment.wageType === 'Hourly'\n const hours = Number(payment.hours || 0)\n const hourlyRate = Number(payment.hourlyRate || 0)\n const bonus = Number(payment.bonus || 0)\n const reimbursement = Number(payment.reimbursement || 0)\n const wageTotal = Number(payment.wageTotal || 0)\n\n const shouldShowReceipt = Boolean(\n paymentReceipt && payment.status === 'Funded' && payment.paymentMethod === 'Direct Deposit',\n )\n\n const receiptTotal = paymentReceipt?.totals?.companyDebit || '0'\n\n const receiptDetailsConfig = useMemo(() => {\n if (!paymentReceipt) return []\n\n return [\n {\n label: t('receipt.from'),\n value: paymentReceipt.nameOfSender || '',\n },\n {\n label: t('receipt.to'),\n value: getContractorDisplayName(contractor),\n },\n {\n label: t('receipt.debitDate'),\n value: paymentReceipt.debitDate ? formatLongWithYear(String(paymentReceipt.debitDate)) : '',\n },\n ]\n }, [paymentReceipt, contractor, t, formatLongWithYear])\n\n const statementRows = useMemo<PaymentStatementRow[]>(() => {\n const rows: PaymentStatementRow[] = [\n {\n label: payment.paymentMethod || '',\n amount: currencyFormatter(wageTotal),\n },\n ]\n\n if (isHourly && hours > 0) {\n rows.push({\n label: t('hoursLabel'),\n amount: t('hoursAmount', {\n hours: formatHoursDisplay(hours),\n rate: currencyFormatter(hourlyRate),\n }),\n })\n } else {\n rows.push({\n label: t('wageLabel'),\n amount: currencyFormatter(Number(payment.wage || 0)),\n })\n }\n\n rows.push({\n label: t('bonus'),\n amount: currencyFormatter(bonus),\n })\n\n rows.push({\n label: t('reimbursement'),\n amount: currencyFormatter(reimbursement),\n })\n\n return rows\n }, [\n payment.paymentMethod,\n wageTotal,\n isHourly,\n hours,\n hourlyRate,\n bonus,\n reimbursement,\n t,\n currencyFormatter,\n payment.wage,\n ])\n\n return (\n <Flex flexDirection=\"column\" gap={32}>\n <Flex flexDirection=\"column\" gap={16}>\n <Flex flexDirection=\"column\" gap={8}>\n <Heading as=\"h2\">{t('title', { contractorName })}</Heading>\n <Text>{formatLongWithYear(checkDate)}</Text>\n </Flex>\n </Flex>\n\n {shouldShowReceipt && (\n <div className={styles.receiptCard}>\n <Flex flexDirection=\"column\" gap={24}>\n <Flex flexDirection=\"column\" alignItems=\"center\" gap={16}>\n <div className={styles.receiptIcon} aria-hidden>\n <ReceiptCheck className={styles.checkmarkIcon} />\n </div>\n\n <Flex flexDirection=\"column\" alignItems=\"center\" gap={8}>\n <Text size=\"sm\" variant=\"supporting\">\n {t('receipt.totalLabel')}\n </Text>\n <Heading as=\"h1\" styledAs=\"h2\" className={styles.totalAmount}>\n {currencyFormatter(Number(receiptTotal))}\n </Heading>\n </Flex>\n </Flex>\n\n <div className={styles.receiptDetailsTable}>\n <DataView\n label={t('receipt.detailsLabel')}\n variant=\"minimal\"\n breakAt=\"small\"\n breakpoints={{\n base: '0rem',\n small: '22rem',\n }}\n columns={[\n {\n title: '',\n render: (item: { label: string; value: string }) => (\n <Text size=\"sm\" variant=\"supporting\">\n {item.label}\n </Text>\n ),\n },\n {\n title: '',\n render: (item: { label: string; value: string }) => (\n <Text size=\"sm\">{item.value}</Text>\n ),\n },\n ]}\n data={receiptDetailsConfig}\n />\n </div>\n <hr />\n <Flex flexDirection=\"column\" alignItems=\"center\" gap={12}>\n <Text size=\"sm\" variant=\"supporting\" className={styles.disclaimer}>\n <Trans\n i18nKey=\"receipt.disclaimer\"\n t={t}\n components={{\n licensesLink: <Link href={paymentReceipt?.licenseUri || ''} target=\"_blank\" />,\n }}\n />\n </Text>\n <hr />\n\n <Text size=\"sm\" variant=\"supporting\" className={styles.companyInfo}>\n {paymentReceipt?.licensee?.name || ''}\n </Text>\n <Text size=\"sm\" variant=\"supporting\" className={styles.address}>\n {addressInline({\n street1: paymentReceipt?.licensee?.address || '',\n city: paymentReceipt?.licensee?.city || '',\n state: paymentReceipt?.licensee?.state || '',\n zip: paymentReceipt?.licensee?.postalCode || '',\n country: '',\n uuid: '',\n })}\n {' | '}\n {formatPhoneNumber(paymentReceipt?.licensee?.phoneNumber)}\n </Text>\n </Flex>\n </Flex>\n </div>\n )}\n\n <DataView\n columns={[\n {\n title: t('debitedColumn'),\n render: ({ label }) => <Text>{label}</Text>,\n },\n {\n title: t('amountColumn'),\n render: ({ amount }) => <Text>{amount || ''}</Text>,\n },\n ]}\n data={statementRows}\n label={t('title', { contractorName })}\n />\n </Flex>\n )\n}\n"],"names":["PaymentStatementPresentation","payment","contractor","checkDate","paymentReceipt","Text","Heading","useComponentContext","useI18n","t","useTranslation","currencyFormatter","useNumberFormatter","formatLongWithYear","useDateFormatter","Link","contractorName","getContractorDisplayName","isHourly","hours","hourlyRate","bonus","reimbursement","wageTotal","shouldShowReceipt","receiptTotal","receiptDetailsConfig","useMemo","statementRows","rows","formatHoursDisplay","jsxs","Flex","jsx","styles","ReceiptCheck","DataView","item","Trans","addressInline","formatPhoneNumber","label","amount"],"mappings":";;;;;;;;;;;;;;;;AA4BO,MAAMA,KAA+B,CAAC;AAAA,EAC3C,SAAAC;AAAA,EACA,YAAAC;AAAA,EACA,WAAAC;AAAA,EACA,gBAAAC;AACF,MAAyC;AACvC,QAAM,EAAE,MAAAC,GAAM,SAAAC,EAAA,IAAYC,EAAA;AAC1B,EAAAC,EAAQ,sCAAsC;AAC9C,QAAM,EAAE,GAAAC,EAAA,IAAMC,EAAe,sCAAsC,GAC7DC,IAAoBC,EAAmB,UAAU,GACjD,EAAE,oBAAAC,EAAA,IAAuBC,EAAA,GACzB,EAAE,MAAAC,EAAA,IAASR,EAAA,GAEXS,IAAiBC,EAAyBf,CAAU,GACpDgB,IAAWjB,EAAQ,aAAa,UAChCkB,IAAQ,OAAOlB,EAAQ,SAAS,CAAC,GACjCmB,IAAa,OAAOnB,EAAQ,cAAc,CAAC,GAC3CoB,IAAQ,OAAOpB,EAAQ,SAAS,CAAC,GACjCqB,IAAgB,OAAOrB,EAAQ,iBAAiB,CAAC,GACjDsB,IAAY,OAAOtB,EAAQ,aAAa,CAAC,GAEzCuB,IAAoB,GACxBpB,KAAkBH,EAAQ,WAAW,YAAYA,EAAQ,kBAAkB,mBAGvEwB,IAAerB,GAAgB,QAAQ,gBAAgB,KAEvDsB,IAAuBC,EAAQ,MAC9BvB,IAEE;AAAA,IACL;AAAA,MACE,OAAOK,EAAE,cAAc;AAAA,MACvB,OAAOL,EAAe,gBAAgB;AAAA,IAAA;AAAA,IAExC;AAAA,MACE,OAAOK,EAAE,YAAY;AAAA,MACrB,OAAOQ,EAAyBf,CAAU;AAAA,IAAA;AAAA,IAE5C;AAAA,MACE,OAAOO,EAAE,mBAAmB;AAA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ACC,SAAS;AAAA,UACP;AAAA,YACE,OAAO3B,EAAE,eAAe;AAAA,YACxB,QAAQ,CAAC,EAAE,OAAAgC,QAAY,gBAAAR,EAAC5B,KAAM,UAAAoC,EAAA,CAAM;AAAA,UAAA;AAAA,UAEtC;AAAA,YACE,OAAOhC,EAAE,cAAc;AAAA,YACvB,QAAQ,CAAC,EAAE,QAAAiC,QAAa,gBAAAT,EAAC5B,GAAA,EAAM,eAAU,GAAA,CAAG;AAAA,UAAA;AAAA,QAC9C;AAAA,QAEF,MAAMuB;AAAA,QACN,OAAOnB,EAAE,SAAS,EAAE,gBAAAO,GAAgB;AAAA,MAAA;AAAA,IAAA;AAAA,EACtC,GACF;AAEJ;"}
|
|
1
|
+
{"version":3,"file":"PaymentStatementPresentation.js","sources":["../../../../../src/components/Contractor/Payments/PaymentStatement/PaymentStatementPresentation.tsx"],"sourcesContent":["import { Trans, useTranslation } from 'react-i18next'\nimport type { ContractorPaymentForGroup } from '@gusto/embedded-api/models/components/contractorpaymentforgroup'\nimport type { Contractor } from '@gusto/embedded-api/models/components/contractor'\nimport { useMemo } from 'react'\nimport type { ContractorPaymentReceipt } from '@gusto/embedded-api/models/components/contractorpaymentreceipt'\nimport { getContractorDisplayName } from '../CreatePayment/helpers'\nimport styles from './PaymentStatementPresentation.module.scss'\nimport { DataView, Flex } from '@/components/Common'\nimport type { DescriptionListItem } from '@/components/Common/UI/DescriptionList/DescriptionListTypes'\nimport { useComponentContext } from '@/contexts/ComponentAdapter/useComponentContext'\nimport { useI18n } from '@/i18n'\nimport { formatHoursDisplay } from '@/components/Payroll/helpers'\nimport useNumberFormatter from '@/hooks/useNumberFormatter'\nimport { useDateFormatter } from '@/hooks/useDateFormatter'\nimport { addressInline, formatPhoneNumber } from '@/helpers/formattedStrings'\nimport ReceiptCheck from '@/assets/icons/receipt-check.svg?react'\n\ninterface PaymentStatementPresentationProps {\n payment: ContractorPaymentForGroup\n contractor: Contractor\n paymentReceipt?: ContractorPaymentReceipt\n checkDate: string\n}\n\ntype PaymentStatementRow = {\n label: string\n amount: string | null\n}\n\nexport const PaymentStatementPresentation = ({\n payment,\n contractor,\n checkDate,\n paymentReceipt,\n}: PaymentStatementPresentationProps) => {\n const Components = useComponentContext()\n const { Text, Heading, Link } = Components\n useI18n('Contractor.Payments.PaymentStatement')\n const { t } = useTranslation('Contractor.Payments.PaymentStatement')\n const currencyFormatter = useNumberFormatter('currency')\n const { formatLongWithYear } = useDateFormatter()\n\n const contractorName = getContractorDisplayName(contractor)\n const isHourly = payment.wageType === 'Hourly'\n const hours = Number(payment.hours || 0)\n const hourlyRate = Number(payment.hourlyRate || 0)\n const bonus = Number(payment.bonus || 0)\n const reimbursement = Number(payment.reimbursement || 0)\n const wageTotal = Number(payment.wageTotal || 0)\n\n const shouldShowReceipt = Boolean(\n paymentReceipt && payment.status === 'Funded' && payment.paymentMethod === 'Direct Deposit',\n )\n\n const receiptTotal = paymentReceipt?.totals?.companyDebit || '0'\n\n const receiptDetailsConfig = useMemo(() => {\n if (!paymentReceipt) return []\n\n return [\n {\n label: t('receipt.from'),\n value: paymentReceipt.nameOfSender || '',\n },\n {\n label: t('receipt.to'),\n value: getContractorDisplayName(contractor),\n },\n {\n label: t('receipt.debitDate'),\n value: paymentReceipt.debitDate ? formatLongWithYear(String(paymentReceipt.debitDate)) : '',\n },\n ]\n }, [paymentReceipt, contractor, t, formatLongWithYear])\n\n const statementRows = useMemo<PaymentStatementRow[]>(() => {\n const rows: PaymentStatementRow[] = [\n {\n label: payment.paymentMethod || '',\n amount: currencyFormatter(wageTotal),\n },\n ]\n\n if (isHourly && hours > 0) {\n rows.push({\n label: t('hoursLabel'),\n amount: t('hoursAmount', {\n hours: formatHoursDisplay(hours),\n rate: currencyFormatter(hourlyRate),\n }),\n })\n } else {\n rows.push({\n label: t('wageLabel'),\n amount: currencyFormatter(Number(payment.wage || 0)),\n })\n }\n\n rows.push({\n label: t('bonus'),\n amount: currencyFormatter(bonus),\n })\n\n rows.push({\n label: t('reimbursement'),\n amount: currencyFormatter(reimbursement),\n })\n\n return rows\n }, [\n payment.paymentMethod,\n wageTotal,\n isHourly,\n hours,\n hourlyRate,\n bonus,\n reimbursement,\n t,\n currencyFormatter,\n payment.wage,\n ])\n\n return (\n <Flex flexDirection=\"column\" gap={32}>\n <Flex flexDirection=\"column\" gap={16}>\n <Flex flexDirection=\"column\" gap={8}>\n <Heading as=\"h2\">{t('title', { contractorName })}</Heading>\n <Text>{formatLongWithYear(checkDate)}</Text>\n </Flex>\n </Flex>\n\n {shouldShowReceipt && (\n <div className={styles.receiptCard}>\n <Flex flexDirection=\"column\" gap={24}>\n <Flex flexDirection=\"column\" alignItems=\"center\" gap={16}>\n <div className={styles.receiptIcon} aria-hidden>\n <ReceiptCheck className={styles.checkmarkIcon} />\n </div>\n\n <Flex flexDirection=\"column\" alignItems=\"center\" gap={8}>\n <Text size=\"sm\" variant=\"supporting\">\n {t('receipt.totalLabel')}\n </Text>\n <Heading as=\"h1\" styledAs=\"h2\" className={styles.totalAmount}>\n {currencyFormatter(Number(receiptTotal))}\n </Heading>\n </Flex>\n </Flex>\n\n <Components.DescriptionList\n layout=\"horizontal\"\n showSeparators={false}\n items={receiptDetailsConfig.map(\n ({ label, value }): DescriptionListItem => ({\n term: (\n <Text size=\"sm\" variant=\"supporting\">\n {label}\n </Text>\n ),\n description: <Text size=\"sm\">{value}</Text>,\n }),\n )}\n />\n <hr />\n <Flex flexDirection=\"column\" alignItems=\"center\" gap={12}>\n <Text size=\"sm\" variant=\"supporting\" className={styles.disclaimer}>\n <Trans\n i18nKey=\"receipt.disclaimer\"\n t={t}\n components={{\n licensesLink: <Link href={paymentReceipt?.licenseUri || ''} target=\"_blank\" />,\n }}\n />\n </Text>\n <hr />\n\n <Text size=\"sm\" variant=\"supporting\" className={styles.companyInfo}>\n {paymentReceipt?.licensee?.name || ''}\n </Text>\n <Text size=\"sm\" variant=\"supporting\" className={styles.address}>\n {addressInline({\n street1: paymentReceipt?.licensee?.address || '',\n city: paymentReceipt?.licensee?.city || '',\n state: paymentReceipt?.licensee?.state || '',\n zip: paymentReceipt?.licensee?.postalCode || '',\n country: '',\n uuid: '',\n })}\n {' | '}\n {formatPhoneNumber(paymentReceipt?.licensee?.phoneNumber)}\n </Text>\n </Flex>\n </Flex>\n </div>\n )}\n\n <DataView\n columns={[\n {\n title: t('debitedColumn'),\n render: ({ label }) => <Text>{label}</Text>,\n },\n {\n title: t('amountColumn'),\n render: ({ amount }) => <Text>{amount || ''}</Text>,\n },\n ]}\n data={statementRows}\n label={t('title', { contractorName })}\n />\n </Flex>\n )\n}\n"],"names":["PaymentStatementPresentation","payment","contractor","checkDate","paymentReceipt","Components","useComponentContext","Text","Heading","Link","useI18n","t","useTranslation","currencyFormatter","useNumberFormatter","formatLongWithYear","useDateFormatter","contractorName","getContractorDisplayName","isHourly","hours","hourlyRate","bonus","reimbursement","wageTotal","shouldShowReceipt","receiptTotal","receiptDetailsConfig","useMemo","statementRows","rows","formatHoursDisplay","jsxs","Flex","jsx","styles","ReceiptCheck","label","value","Trans","addressInline","formatPhoneNumber","DataView","amount"],"mappings":";;;;;;;;;;;;;;AA6BO,MAAMA,KAA+B,CAAC;AAAA,EAC3C,SAAAC;AAAA,EACA,YAAAC;AAAA,EACA,WAAAC;AAAA,EACA,gBAAAC;AACF,MAAyC;AACvC,QAAMC,IAAaC,EAAA,GACb,EAAE,MAAAC,GAAM,SAAAC,GAAS,MAAAC,EAAA,IAASJ;AAChC,EAAAK,EAAQ,sCAAsC;AAC9C,QAAM,EAAE,GAAAC,EAAA,IAAMC,EAAe,sCAAsC,GAC7DC,IAAoBC,EAAmB,UAAU,GACjD,EAAE,oBAAAC,EAAA,IAAuBC,EAAA,GAEzBC,IAAiBC,EAAyBhB,CAAU,GACpDiB,IAAWlB,EAAQ,aAAa,UAChCmB,IAAQ,OAAOnB,EAAQ,SAAS,CAAC,GACjCoB,IAAa,OAAOpB,EAAQ,cAAc,CAAC,GAC3CqB,IAAQ,OAAOrB,E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YACxC,OAAOA,GAAgB,UAAU,SAAS;AAAA,YAC1C,KAAKA,GAAgB,UAAU,cAAc;AAAA,UAG/C,CAAC;AAAA,UACA;AAAA,UACAqC,EAAkBrC,GAAgB,UAAU,WAAW;AAAA,QAAA,EAAA,CAC1D;AAAA,MAAA,EAAA,CACF;AAAA,IAAA,EAAA,CACF,EAAA,CACF;AAAA,IAGF,gBAAA8B;AAAA,MAACQ;AAAA,MAAA;AAAA,QACC,SAAS;AAAA,UACP;AAAA,YACE,OAAO/B,EAAE,eAAe;AAAA,YACxB,QAAQ,CAAC,EAAE,OAAA0B,QAAY,gBAAAH,EAAC3B,KAAM,UAAA8B,EAAA,CAAM;AAAA,UAAA;AAAA,UAEtC;AAAA,YACE,OAAO1B,EAAE,cAAc;AAAA,YACvB,QAAQ,CAAC,EAAE,QAAAgC,QAAa,gBAAAT,EAAC3B,GAAA,EAAM,eAAU,GAAA,CAAG;AAAA,UAAA;AAAA,QAC9C;AAAA,QAEF,MAAMsB;AAAA,QACN,OAAOlB,EAAE,SAAS,EAAE,gBAAAM,GAAgB;AAAA,MAAA;AAAA,IAAA;AAAA,EACtC,GACF;AAEJ;"}
|
|
@@ -1,22 +1,20 @@
|
|
|
1
|
-
const c = "
|
|
1
|
+
const c = "_receiptCard_18x1n_1", n = "_receiptIcon_18x1n_12", o = "_checkmarkIcon_18x1n_23", t = "_totalAmount_18x1n_29", e = "_disclaimer_18x1n_34", _ = "_companyInfo_18x1n_39", a = "_address_18x1n_43", s = {
|
|
2
2
|
receiptCard: c,
|
|
3
|
-
receiptIcon:
|
|
3
|
+
receiptIcon: n,
|
|
4
4
|
checkmarkIcon: o,
|
|
5
5
|
totalAmount: t,
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
address: _
|
|
6
|
+
disclaimer: e,
|
|
7
|
+
companyInfo: _,
|
|
8
|
+
address: a
|
|
10
9
|
};
|
|
11
10
|
export {
|
|
12
|
-
|
|
11
|
+
a as address,
|
|
13
12
|
o as checkmarkIcon,
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
13
|
+
_ as companyInfo,
|
|
14
|
+
s as default,
|
|
15
|
+
e as disclaimer,
|
|
17
16
|
c as receiptCard,
|
|
18
|
-
|
|
19
|
-
e as receiptIcon,
|
|
17
|
+
n as receiptIcon,
|
|
20
18
|
t as totalAmount
|
|
21
19
|
};
|
|
22
20
|
//# sourceMappingURL=PaymentStatementPresentation.module.scss.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PaymentStatementPresentation.module.scss.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"PaymentStatementPresentation.module.scss.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;"}
|
|
@@ -1,35 +1,33 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as s, jsx as r } from "react/jsx-runtime";
|
|
2
2
|
import { useTranslation as T } from "react-i18next";
|
|
3
3
|
import { useMemo as x } from "react";
|
|
4
4
|
import { getContractorDisplayName as C } from "../CreatePayment/helpers.js";
|
|
5
|
-
import { Flex as
|
|
6
|
-
import "classnames";
|
|
7
|
-
import "../../../../shared/constants.js";
|
|
5
|
+
import { Flex as l } from "../../../Common/Flex/Flex.js";
|
|
8
6
|
import { useComponentContext as M } from "../../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
9
7
|
import { useI18n as S } from "../../../../i18n/I18n.js";
|
|
10
8
|
import { formatHoursDisplay as v } from "../../../Payroll/helpers.js";
|
|
11
9
|
import H from "../../../../hooks/useNumberFormatter.js";
|
|
12
10
|
import { ConfirmWireDetails as $ } from "../../../Payroll/ConfirmWireDetails/ConfirmWireDetails.js";
|
|
13
|
-
import { DataView as
|
|
14
|
-
const k = "0.000",
|
|
11
|
+
import { DataView as c } from "../../../Common/DataView/DataView.js";
|
|
12
|
+
const k = "0.000", U = ({
|
|
15
13
|
contractorPaymentGroup: m,
|
|
16
|
-
contractors:
|
|
14
|
+
contractors: h,
|
|
17
15
|
bankAccount: y,
|
|
18
16
|
companyId: g,
|
|
19
|
-
wireInRequestUuid:
|
|
17
|
+
wireInRequestUuid: a,
|
|
20
18
|
onEvent: A,
|
|
21
19
|
onDone: f,
|
|
22
|
-
alerts:
|
|
20
|
+
alerts: d = []
|
|
23
21
|
}) => {
|
|
24
|
-
const { Button: D, Text:
|
|
22
|
+
const { Button: D, Text: b, Heading: w, Alert: p } = M();
|
|
25
23
|
S("Contractor.Payments.PaymentSummary");
|
|
26
|
-
const { t } = T("Contractor.Payments.PaymentSummary"),
|
|
24
|
+
const { t } = T("Contractor.Payments.PaymentSummary"), n = H(), N = (e) => e.wageType === "Hourly" && e.hourlyRate ? `Hourly ${n(Number(e.hourlyRate))}/hr` : e.wageType, i = m.contractorPayments || [], u = x(() => i.length === 0 ? { wageAmount: 0, bonusAmount: 0, reimbursementAmount: 0, totalAmount: 0 } : i.reduce(
|
|
27
25
|
(e, o) => (e.wageAmount += Number(o.wage || "0"), e.bonusAmount += Number(o.bonus || "0"), e.reimbursementAmount += Number(o.reimbursement || "0"), e.totalAmount += Number(o.wageTotal || "0"), e),
|
|
28
26
|
{ wageAmount: 0, bonusAmount: 0, reimbursementAmount: 0, totalAmount: 0 }
|
|
29
|
-
), [
|
|
30
|
-
return /* @__PURE__ */
|
|
31
|
-
|
|
32
|
-
|
|
27
|
+
), [i]);
|
|
28
|
+
return /* @__PURE__ */ s(l, { flexDirection: "column", gap: 16, children: [
|
|
29
|
+
d.length > 0 && /* @__PURE__ */ r(l, { flexDirection: "column", gap: 16, children: d.map((e, o) => /* @__PURE__ */ r(
|
|
30
|
+
p,
|
|
33
31
|
{
|
|
34
32
|
label: t(`alerts.${e.title}`, e.translationParams),
|
|
35
33
|
status: e.type,
|
|
@@ -38,94 +36,94 @@ const k = "0.000", Y = ({
|
|
|
38
36
|
},
|
|
39
37
|
`${e.type}-${e.title}-${o}`
|
|
40
38
|
)) }),
|
|
41
|
-
/* @__PURE__ */
|
|
42
|
-
count:
|
|
39
|
+
/* @__PURE__ */ r(p, { status: "success", label: t("successTitle"), children: /* @__PURE__ */ r(b, { children: t("successMessage", {
|
|
40
|
+
count: i.length
|
|
43
41
|
}) }) }),
|
|
44
|
-
|
|
45
|
-
/* @__PURE__ */
|
|
46
|
-
/* @__PURE__ */
|
|
47
|
-
/* @__PURE__ */
|
|
48
|
-
/* @__PURE__ */
|
|
42
|
+
a && /* @__PURE__ */ r($, { companyId: g, wireInId: a, onEvent: A }),
|
|
43
|
+
/* @__PURE__ */ s(l, { justifyContent: "space-between", alignItems: "flex-start", children: [
|
|
44
|
+
/* @__PURE__ */ s(l, { flexDirection: "column", gap: 2, children: [
|
|
45
|
+
/* @__PURE__ */ r(w, { as: "h2", children: t("summaryTitle") }),
|
|
46
|
+
/* @__PURE__ */ r(b, { variant: "supporting", children: t("summarySubtitle", { debitDate: m.debitDate }) })
|
|
49
47
|
] }),
|
|
50
|
-
/* @__PURE__ */
|
|
48
|
+
/* @__PURE__ */ r(D, { onClick: f, variant: "primary", children: t("doneCta") })
|
|
51
49
|
] }),
|
|
52
|
-
/* @__PURE__ */
|
|
53
|
-
|
|
50
|
+
/* @__PURE__ */ r(
|
|
51
|
+
c,
|
|
54
52
|
{
|
|
55
53
|
columns: [
|
|
56
54
|
{
|
|
57
55
|
title: t("totalAmount"),
|
|
58
|
-
render: () =>
|
|
56
|
+
render: () => n(Number(m.totals?.amount || "0"))
|
|
59
57
|
},
|
|
60
58
|
{
|
|
61
59
|
title: t("debitAmount"),
|
|
62
|
-
render: () =>
|
|
60
|
+
render: () => n(Number(m.totals?.debitAmount || "0"))
|
|
63
61
|
},
|
|
64
62
|
{
|
|
65
63
|
title: t("debitAccount"),
|
|
66
|
-
render: () =>
|
|
64
|
+
render: () => y?.hiddenAccountNumber ?? t("notAvailable")
|
|
67
65
|
},
|
|
68
66
|
{
|
|
69
67
|
title: t("debitDate"),
|
|
70
|
-
render: () =>
|
|
68
|
+
render: () => m.debitDate || t("notAvailable")
|
|
71
69
|
},
|
|
72
70
|
{
|
|
73
71
|
title: t("contractorPayDate"),
|
|
74
|
-
render: () =>
|
|
72
|
+
render: () => m.checkDate || t("notAvailable")
|
|
75
73
|
}
|
|
76
74
|
],
|
|
77
75
|
data: [m],
|
|
78
76
|
label: t("paymentSummaryTitle")
|
|
79
77
|
}
|
|
80
78
|
),
|
|
81
|
-
|
|
82
|
-
|
|
79
|
+
i.length > 0 && /* @__PURE__ */ r(
|
|
80
|
+
c,
|
|
83
81
|
{
|
|
84
82
|
columns: [
|
|
85
83
|
{
|
|
86
84
|
title: t("contractor"),
|
|
87
|
-
render: (e) =>
|
|
88
|
-
|
|
85
|
+
render: (e) => C(
|
|
86
|
+
h.find(
|
|
89
87
|
(o) => o.uuid === e.contractorUuid
|
|
90
88
|
)
|
|
91
|
-
)
|
|
89
|
+
)
|
|
92
90
|
},
|
|
93
91
|
{
|
|
94
92
|
title: t("wageType"),
|
|
95
|
-
render: (e) =>
|
|
93
|
+
render: (e) => N(e)
|
|
96
94
|
},
|
|
97
95
|
{
|
|
98
96
|
title: t("paymentMethod"),
|
|
99
|
-
render: (e) =>
|
|
97
|
+
render: (e) => e.paymentMethod === "Direct Deposit" ? t("paymentMethods.directDeposit") : e.paymentMethod === "Check" ? t("paymentMethods.check") : e.paymentMethod || t("notAvailable")
|
|
100
98
|
},
|
|
101
99
|
{
|
|
102
100
|
title: t("hours"),
|
|
103
|
-
render: (e) =>
|
|
101
|
+
render: (e) => e.wageType === "Hourly" && e.hours ? v(parseFloat(e.hours)) : k
|
|
104
102
|
},
|
|
105
103
|
{
|
|
106
104
|
title: t("wage"),
|
|
107
|
-
render: (e) =>
|
|
105
|
+
render: (e) => n(Number(e.wage || "0"))
|
|
108
106
|
},
|
|
109
107
|
{
|
|
110
108
|
title: t("bonus"),
|
|
111
|
-
render: (e) =>
|
|
109
|
+
render: (e) => n(Number(e.bonus || "0"))
|
|
112
110
|
},
|
|
113
111
|
{
|
|
114
112
|
title: t("reimbursement"),
|
|
115
|
-
render: (e) =>
|
|
113
|
+
render: (e) => n(Number(e.reimbursement || "0"))
|
|
116
114
|
},
|
|
117
115
|
{
|
|
118
116
|
title: t("total"),
|
|
119
|
-
render: (e) =>
|
|
117
|
+
render: (e) => n(Number(e.wageTotal || "0"))
|
|
120
118
|
}
|
|
121
119
|
],
|
|
122
|
-
data:
|
|
120
|
+
data: i,
|
|
123
121
|
footer: () => ({
|
|
124
|
-
"column-0":
|
|
125
|
-
"column-4":
|
|
126
|
-
"column-5":
|
|
127
|
-
"column-6":
|
|
128
|
-
"column-7":
|
|
122
|
+
"column-0": t("totalsLabel"),
|
|
123
|
+
"column-4": n(u.wageAmount || 0),
|
|
124
|
+
"column-5": n(u.bonusAmount || 0),
|
|
125
|
+
"column-6": n(u.reimbursementAmount || 0),
|
|
126
|
+
"column-7": n(u.totalAmount || 0)
|
|
129
127
|
}),
|
|
130
128
|
label: t("contractorPaymentsTitle")
|
|
131
129
|
}
|
|
@@ -133,6 +131,6 @@ const k = "0.000", Y = ({
|
|
|
133
131
|
] });
|
|
134
132
|
};
|
|
135
133
|
export {
|
|
136
|
-
|
|
134
|
+
U as PaymentSummaryPresentation
|
|
137
135
|
};
|
|
138
136
|
//# sourceMappingURL=PaymentSummaryPresentation.js.map
|
package/dist/components/Contractor/Payments/PaymentSummary/PaymentSummaryPresentation.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PaymentSummaryPresentation.js","sources":["../../../../../src/components/Contractor/Payments/PaymentSummary/PaymentSummaryPresentation.tsx"],"sourcesContent":["import { useTranslation } from 'react-i18next'\nimport type { ContractorPaymentGroup } from '@gusto/embedded-api/models/components/contractorpaymentgroup'\nimport type { ContractorPaymentForGroup } from '@gusto/embedded-api/models/components/contractorpaymentforgroup'\nimport { useMemo } from 'react'\nimport type { Contractor } from '@gusto/embedded-api/models/components/contractor'\nimport type { CompanyBankAccount } from '@gusto/embedded-api/models/components/companybankaccount'\nimport type { InternalAlert } from '../types'\nimport { getContractorDisplayName } from '../CreatePayment/helpers'\nimport { DataView, Flex } from '@/components/Common'\nimport { useComponentContext } from '@/contexts/ComponentAdapter/useComponentContext'\nimport { useI18n } from '@/i18n'\nimport { formatHoursDisplay } from '@/components/Payroll/helpers'\nimport useNumberFormatter from '@/hooks/useNumberFormatter'\nimport { ConfirmWireDetails } from '@/components/Payroll/ConfirmWireDetails'\nimport type { EventType } from '@/shared/constants'\n\nconst ZERO_HOURS_DISPLAY = '0.000'\n\ninterface PaymentSummaryPresentationProps {\n contractorPaymentGroup: ContractorPaymentGroup\n contractors: Contractor[]\n bankAccount?: CompanyBankAccount\n companyId: string\n wireInRequestUuid?: string\n onEvent: (type: EventType, data?: unknown) => void\n onDone: () => void\n alerts?: InternalAlert[]\n}\n\nexport const PaymentSummaryPresentation = ({\n contractorPaymentGroup,\n contractors,\n bankAccount,\n companyId,\n wireInRequestUuid,\n onEvent,\n onDone,\n alerts = [],\n}: PaymentSummaryPresentationProps) => {\n const { Button, Text, Heading, Alert } = useComponentContext()\n useI18n('Contractor.Payments.PaymentSummary')\n const { t } = useTranslation('Contractor.Payments.PaymentSummary')\n const currencyFormatter = useNumberFormatter()\n\n const formatWageType = (contractor: ContractorPaymentForGroup) => {\n if (contractor.wageType === 'Hourly' && contractor.hourlyRate) {\n return `Hourly ${currencyFormatter(Number(contractor.hourlyRate))}/hr`\n }\n return contractor.wageType\n }\n\n const contractorPayments = contractorPaymentGroup.contractorPayments || []\n\n const totals = useMemo(() => {\n if (contractorPayments.length === 0) {\n return { wageAmount: 0, bonusAmount: 0, reimbursementAmount: 0, totalAmount: 0 }\n }\n return contractorPayments.reduce(\n (acc, contractor) => {\n acc.wageAmount += Number(contractor.wage || '0')\n acc.bonusAmount += Number(contractor.bonus || '0')\n acc.reimbursementAmount += Number(contractor.reimbursement || '0')\n acc.totalAmount += Number(contractor.wageTotal || '0')\n return acc\n },\n { wageAmount: 0, bonusAmount: 0, reimbursementAmount: 0, totalAmount: 0 },\n )\n }, [contractorPayments])\n\n return (\n <Flex flexDirection=\"column\" gap={32}>\n {alerts.length > 0 && (\n <Flex flexDirection=\"column\" gap={16}>\n {alerts.map((alert, index) => (\n <Alert\n key={`${alert.type}-${alert.title}-${index}`}\n label={t(`alerts.${alert.title}` as never, alert.translationParams)}\n status={alert.type}\n onDismiss={alert.onDismiss}\n >\n {typeof alert.content === 'string'\n ? t(`alerts.${alert.content}` as never)\n : (alert.content ?? null)}\n </Alert>\n ))}\n </Flex>\n )}\n\n <Alert status=\"success\" label={t('successTitle')}>\n <Text>\n {t('successMessage', {\n count: contractorPayments.length,\n })}\n </Text>\n </Alert>\n\n {wireInRequestUuid && (\n <ConfirmWireDetails companyId={companyId} wireInId={wireInRequestUuid} onEvent={onEvent} />\n )}\n\n <Flex justifyContent=\"space-between\" alignItems=\"flex-start\">\n <Flex flexDirection=\"column\" gap={2}>\n <Heading as=\"h2\">{t('summaryTitle')}</Heading>\n <Text variant=\"supporting\">\n {t('summarySubtitle', { debitDate: contractorPaymentGroup.debitDate })}\n </Text>\n </Flex>\n <Button onClick={onDone} variant=\"primary\">\n {t('doneCta')}\n </Button>\n </Flex>\n\n {/* Payment Summary Table */}\n <DataView\n columns={[\n {\n title: t('totalAmount'),\n render: () => (\n <Text>{currencyFormatter(Number(contractorPaymentGroup.totals?.amount || '0'))}</Text>\n ),\n },\n {\n title: t('debitAmount'),\n render: () => (\n <Text>\n {currencyFormatter(Number(contractorPaymentGroup.totals?.debitAmount || '0'))}\n </Text>\n ),\n },\n {\n title: t('debitAccount'),\n render: () => <Text>{bankAccount?.hiddenAccountNumber ?? t('notAvailable')}</Text>,\n },\n {\n title: t('debitDate'),\n render: () => <Text>{contractorPaymentGroup.debitDate || t('notAvailable')}</Text>,\n },\n {\n title: t('contractorPayDate'),\n render: () => <Text>{contractorPaymentGroup.checkDate || t('notAvailable')}</Text>,\n },\n ]}\n data={[contractorPaymentGroup]}\n label={t('paymentSummaryTitle')}\n />\n\n {/* Contractor Payments Table */}\n {contractorPayments.length > 0 && (\n <DataView\n columns={[\n {\n title: t('contractor'),\n render: contractorPayment => (\n <Text>\n {getContractorDisplayName(\n contractors.find(\n contractor => contractor.uuid === contractorPayment.contractorUuid,\n ),\n )}\n </Text>\n ),\n },\n {\n title: t('wageType'),\n render: contractorPayment => <Text>{formatWageType(contractorPayment)}</Text>,\n },\n {\n title: t('paymentMethod'),\n render: contractorPayment => (\n <Text>\n {contractorPayment.paymentMethod === 'Direct Deposit'\n ? t('paymentMethods.directDeposit')\n : contractorPayment.paymentMethod === 'Check'\n ? t('paymentMethods.check')\n : contractorPayment.paymentMethod || t('notAvailable')}\n </Text>\n ),\n },\n {\n title: t('hours'),\n render: contractorPayment => (\n <Text>\n {contractorPayment.wageType === 'Hourly' && contractorPayment.hours\n ? formatHoursDisplay(parseFloat(contractorPayment.hours))\n : ZERO_HOURS_DISPLAY}\n </Text>\n ),\n },\n {\n title: t('wage'),\n render: contractorPayment => (\n <Text>{currencyFormatter(Number(contractorPayment.wage || '0'))}</Text>\n ),\n },\n {\n title: t('bonus'),\n render: contractorPayment => (\n <Text>{currencyFormatter(Number(contractorPayment.bonus || '0'))}</Text>\n ),\n },\n {\n title: t('reimbursement'),\n render: contractorPayment => (\n <Text>{currencyFormatter(Number(contractorPayment.reimbursement || '0'))}</Text>\n ),\n },\n {\n title: t('total'),\n render: contractorPayment => (\n <Text>{currencyFormatter(Number(contractorPayment.wageTotal || '0'))}</Text>\n ),\n },\n ]}\n data={contractorPayments}\n footer={() => ({\n 'column-0': <Text weight=\"bold\">{t('totalsLabel')}</Text>,\n 'column-4': <Text>{currencyFormatter(totals.wageAmount || 0)}</Text>,\n 'column-5': <Text>{currencyFormatter(totals.bonusAmount || 0)}</Text>,\n 'column-6': <Text>{currencyFormatter(totals.reimbursementAmount || 0)}</Text>,\n 'column-7': <Text>{currencyFormatter(totals.totalAmount || 0)}</Text>,\n })}\n label={t('contractorPaymentsTitle')}\n />\n )}\n </Flex>\n )\n}\n"],"names":["ZERO_HOURS_DISPLAY","PaymentSummaryPresentation","contractorPaymentGroup","contractors","bankAccount","companyId","wireInRequestUuid","onEvent","onDone","alerts","Button","Text","Heading","Alert","useComponentContext","useI18n","useTranslation","currencyFormatter","useNumberFormatter","formatWageType","contractor","contractorPayments","totals","useMemo","acc","jsxs","Flex","jsx","alert","index","ConfirmWireDetails","DataView","contractorPayment","getContractorDisplayName","formatHoursDisplay"],"mappings":";;;;;;;;;;;;;AAgBA,MAAMA,IAAqB,SAadC,IAA6B,CAAC;AAAA,EACzC,wBAAAC;AAAA,EACA,aAAAC;AAAA,EACA,aAAAC;AAAA,EACA,WAAAC;AAAA,EACA,mBAAAC;AAAA,EACA,SAAAC;AAAA,EACA,QAAAC;AAAA,EACA,QAAAC,IAAS,CAAA;AACX,MAAuC;AACrC,QAAM,EAAE,QAAAC,GAAQ,MAAAC,GAAM,SAAAC,GAAS,OAAAC,EAAA,IAAUC,EAAA;AACzC,EAAAC,EAAQ,oCAAoC;AAC5C,QAAM,EAAE,EAAA,IAAMC,EAAe,oCAAoC,GAC3DC,IAAoBC,EAAA,GAEpBC,IAAiB,CAACC,MAClBA,EAAW,aAAa,YAAYA,EAAW,aAC1C,UAAUH,EAAkB,OAAOG,EAAW,UAAU,CAAC,CAAC,QAE5DA,EAAW,UAGdC,IAAqBnB,EAAuB,sBAAsB,CAAA,GAElEoB,IAASC,EAAQ,MACjBF,EAAmB,WAAW,IACzB,EAAE,YAAY,GAAG,aAAa,GAAG,qBAAqB,GAAG,aAAa,EAAA,IAExEA,EAAmB;AAAA,IACxB,CAACG,GAAKJ,OACJI,EAAI,cAAc,OAAOJ,EAAW,QAAQ,GAAG,GAC/CI,EAAI,eAAe,OAAOJ,EAAW,SAAS,GAAG,GACjDI,EAAI,uBAAuB,OAAOJ,EAAW,iBAAiB,GAAG,GACjEI,EAAI,eAAe,OAAOJ,EAAW,aAAa,GAAG,GAC9CI;AAAA,IAET,EAAE,YAAY,GAAG,aAAa,G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AAA,UAAA;AAAA,UAG7E;AAAA,YACE,OAAO,EAAE,OAAO;AAAA,YAChB,QAAQ,CAAAA,MACN,gBAAAL,EAAChB,GAAA,EAAM,UAAAM,EAAkB,OAAOe,EAAkB,aAAa,GAAG,CAAC,EAAA,CAAE;AAAA,UAAA;AAAA,QAEzE;AAAA,QAEF,MAAMX;AAAA,QACN,QAAQ,OAAO;AAAA,UACb,YAAY,gBAAAM,EAAChB,GAAA,EAAK,QAAO,QAAQ,UAAA,EAAE,aAAa,GAAE;AAAA,UAClD,YAAY,gBAAAgB,EAAChB,GAAA,EAAM,YAAkBW,EAAO,cAAc,CAAC,GAAE;AAAA,UAC7D,YAAY,gBAAAK,EAAChB,GAAA,EAAM,YAAkBW,EAAO,eAAe,CAAC,GAAE;AAAA,UAC9D,YAAY,gBAAAK,EAAChB,GAAA,EAAM,YAAkBW,EAAO,uBAAuB,CAAC,GAAE;AAAA,UACtE,YAAY,gBAAAK,EAAChB,GAAA,EAAM,YAAkBW,EAAO,eAAe,CAAC,EAAA,CAAE;AAAA,QAAA;AAAA,QAEhE,OAAO,EAAE,yBAAyB;AAAA,MAAA;AAAA,IAAA;AAAA,EACpC,GAEJ;AAEJ;"}
|
|
1
|
+
{"version":3,"file":"PaymentSummaryPresentation.js","sources":["../../../../../src/components/Contractor/Payments/PaymentSummary/PaymentSummaryPresentation.tsx"],"sourcesContent":["import { useTranslation } from 'react-i18next'\nimport type { ContractorPaymentGroup } from '@gusto/embedded-api/models/components/contractorpaymentgroup'\nimport type { ContractorPaymentForGroup } from '@gusto/embedded-api/models/components/contractorpaymentforgroup'\nimport { useMemo } from 'react'\nimport type { Contractor } from '@gusto/embedded-api/models/components/contractor'\nimport type { CompanyBankAccount } from '@gusto/embedded-api/models/components/companybankaccount'\nimport type { InternalAlert } from '../types'\nimport { getContractorDisplayName } from '../CreatePayment/helpers'\nimport { DataView, Flex } from '@/components/Common'\nimport { useComponentContext } from '@/contexts/ComponentAdapter/useComponentContext'\nimport { useI18n } from '@/i18n'\nimport { formatHoursDisplay } from '@/components/Payroll/helpers'\nimport useNumberFormatter from '@/hooks/useNumberFormatter'\nimport { ConfirmWireDetails } from '@/components/Payroll/ConfirmWireDetails'\nimport type { EventType } from '@/shared/constants'\n\nconst ZERO_HOURS_DISPLAY = '0.000'\n\ninterface PaymentSummaryPresentationProps {\n contractorPaymentGroup: ContractorPaymentGroup\n contractors: Contractor[]\n bankAccount?: CompanyBankAccount\n companyId: string\n wireInRequestUuid?: string\n onEvent: (type: EventType, data?: unknown) => void\n onDone: () => void\n alerts?: InternalAlert[]\n}\n\nexport const PaymentSummaryPresentation = ({\n contractorPaymentGroup,\n contractors,\n bankAccount,\n companyId,\n wireInRequestUuid,\n onEvent,\n onDone,\n alerts = [],\n}: PaymentSummaryPresentationProps) => {\n const { Button, Text, Heading, Alert } = useComponentContext()\n useI18n('Contractor.Payments.PaymentSummary')\n const { t } = useTranslation('Contractor.Payments.PaymentSummary')\n const currencyFormatter = useNumberFormatter()\n\n const formatWageType = (contractor: ContractorPaymentForGroup) => {\n if (contractor.wageType === 'Hourly' && contractor.hourlyRate) {\n return `Hourly ${currencyFormatter(Number(contractor.hourlyRate))}/hr`\n }\n return contractor.wageType\n }\n\n const contractorPayments = contractorPaymentGroup.contractorPayments || []\n\n const totals = useMemo(() => {\n if (contractorPayments.length === 0) {\n return { wageAmount: 0, bonusAmount: 0, reimbursementAmount: 0, totalAmount: 0 }\n }\n return contractorPayments.reduce(\n (acc, contractor) => {\n acc.wageAmount += Number(contractor.wage || '0')\n acc.bonusAmount += Number(contractor.bonus || '0')\n acc.reimbursementAmount += Number(contractor.reimbursement || '0')\n acc.totalAmount += Number(contractor.wageTotal || '0')\n return acc\n },\n { wageAmount: 0, bonusAmount: 0, reimbursementAmount: 0, totalAmount: 0 },\n )\n }, [contractorPayments])\n\n return (\n <Flex flexDirection=\"column\" gap={16}>\n {alerts.length > 0 && (\n <Flex flexDirection=\"column\" gap={16}>\n {alerts.map((alert, index) => (\n <Alert\n key={`${alert.type}-${alert.title}-${index}`}\n label={t(`alerts.${alert.title}` as never, alert.translationParams)}\n status={alert.type}\n onDismiss={alert.onDismiss}\n >\n {typeof alert.content === 'string'\n ? t(`alerts.${alert.content}` as never)\n : (alert.content ?? null)}\n </Alert>\n ))}\n </Flex>\n )}\n\n <Alert status=\"success\" label={t('successTitle')}>\n <Text>\n {t('successMessage', {\n count: contractorPayments.length,\n })}\n </Text>\n </Alert>\n\n {wireInRequestUuid && (\n <ConfirmWireDetails companyId={companyId} wireInId={wireInRequestUuid} onEvent={onEvent} />\n )}\n\n <Flex justifyContent=\"space-between\" alignItems=\"flex-start\">\n <Flex flexDirection=\"column\" gap={2}>\n <Heading as=\"h2\">{t('summaryTitle')}</Heading>\n <Text variant=\"supporting\">\n {t('summarySubtitle', { debitDate: contractorPaymentGroup.debitDate })}\n </Text>\n </Flex>\n <Button onClick={onDone} variant=\"primary\">\n {t('doneCta')}\n </Button>\n </Flex>\n\n {/* Payment Summary Table */}\n <DataView\n columns={[\n {\n title: t('totalAmount'),\n render: () => currencyFormatter(Number(contractorPaymentGroup.totals?.amount || '0')),\n },\n {\n title: t('debitAmount'),\n render: () =>\n currencyFormatter(Number(contractorPaymentGroup.totals?.debitAmount || '0')),\n },\n {\n title: t('debitAccount'),\n render: () => bankAccount?.hiddenAccountNumber ?? t('notAvailable'),\n },\n {\n title: t('debitDate'),\n render: () => contractorPaymentGroup.debitDate || t('notAvailable'),\n },\n {\n title: t('contractorPayDate'),\n render: () => contractorPaymentGroup.checkDate || t('notAvailable'),\n },\n ]}\n data={[contractorPaymentGroup]}\n label={t('paymentSummaryTitle')}\n />\n\n {/* Contractor Payments Table */}\n {contractorPayments.length > 0 && (\n <DataView\n columns={[\n {\n title: t('contractor'),\n render: contractorPayment =>\n getContractorDisplayName(\n contractors.find(\n contractor => contractor.uuid === contractorPayment.contractorUuid,\n ),\n ),\n },\n {\n title: t('wageType'),\n render: contractorPayment => formatWageType(contractorPayment),\n },\n {\n title: t('paymentMethod'),\n render: contractorPayment =>\n contractorPayment.paymentMethod === 'Direct Deposit'\n ? t('paymentMethods.directDeposit')\n : contractorPayment.paymentMethod === 'Check'\n ? t('paymentMethods.check')\n : contractorPayment.paymentMethod || t('notAvailable'),\n },\n {\n title: t('hours'),\n render: contractorPayment =>\n contractorPayment.wageType === 'Hourly' && contractorPayment.hours\n ? formatHoursDisplay(parseFloat(contractorPayment.hours))\n : ZERO_HOURS_DISPLAY,\n },\n {\n title: t('wage'),\n render: contractorPayment => currencyFormatter(Number(contractorPayment.wage || '0')),\n },\n {\n title: t('bonus'),\n render: contractorPayment =>\n currencyFormatter(Number(contractorPayment.bonus || '0')),\n },\n {\n title: t('reimbursement'),\n render: contractorPayment =>\n currencyFormatter(Number(contractorPayment.reimbursement || '0')),\n },\n {\n title: t('total'),\n render: contractorPayment =>\n currencyFormatter(Number(contractorPayment.wageTotal || '0')),\n },\n ]}\n data={contractorPayments}\n footer={() => ({\n 'column-0': t('totalsLabel'),\n 'column-4': currencyFormatter(totals.wageAmount || 0),\n 'column-5': currencyFormatter(totals.bonusAmount || 0),\n 'column-6': currencyFormatter(totals.reimbursementAmount || 0),\n 'column-7': currencyFormatter(totals.totalAmount || 0),\n })}\n label={t('contractorPaymentsTitle')}\n />\n )}\n </Flex>\n )\n}\n"],"names":["ZERO_HOURS_DISPLAY","PaymentSummaryPresentation","contractorPaymentGroup","contractors","bankAccount","companyId","wireInRequestUuid","onEvent","onDone","alerts","Button","Text","Heading","Alert","useComponentContext","useI18n","useTranslation","currencyFormatter","useNumberFormatter","formatWageType","contractor","contractorPayments","totals","useMemo","acc","jsxs","Flex","jsx","alert","index","ConfirmWireDetails","DataView","contractorPayment","getContractorDisplayName","formatHoursDisplay"],"mappings":";;;;;;;;;;;AAgBA,MAAMA,IAAqB,SAadC,IAA6B,CAAC;AAAA,EACzC,wBAAAC;AAAA,EACA,aAAAC;AAAA,EACA,aAAAC;AAAA,EACA,WAAAC;AAAA,EACA,mBAAAC;AA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