@gusto/embedded-react-sdk 0.24.0 → 0.25.0
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 +80 -0
- package/dist/assets/icons/slash-circle.svg.js +10 -0
- package/dist/assets/icons/slash-circle.svg.js.map +1 -0
- package/dist/components/Base/Base.d.ts +1 -1
- package/dist/components/Base/Base.js.map +1 -1
- package/dist/components/Common/Fields/FileInputField/FileInputField.d.ts +5 -0
- package/dist/components/Common/Fields/FileInputField/FileInputField.js +34 -0
- package/dist/components/Common/Fields/FileInputField/FileInputField.js.map +1 -0
- package/dist/components/Common/Fields/FileInputField/index.d.ts +2 -0
- package/dist/components/Common/PaginationControl/PaginationControl.js +41 -40
- package/dist/components/Common/PaginationControl/PaginationControl.js.map +1 -1
- package/dist/components/Common/PaginationControl/PaginationControlTypes.d.ts +1 -0
- package/dist/components/Common/SignatureForm/SignatureFormFields.js +1 -1
- package/dist/components/Common/UI/Breadcrumbs/Breadcrumbs.js +1 -1
- package/dist/components/Common/UI/FileInput/FileInput.d.ts +2 -0
- package/dist/components/Common/UI/FileInput/FileInput.js +151 -0
- package/dist/components/Common/UI/FileInput/FileInput.js.map +1 -0
- package/dist/components/Common/UI/FileInput/FileInput.module.scss.js +34 -0
- package/dist/components/Common/UI/FileInput/FileInput.module.scss.js.map +1 -0
- package/dist/components/Common/UI/FileInput/FileInputTypes.d.ts +45 -0
- package/dist/components/Common/UI/FileInput/FileInputTypes.js +8 -0
- package/dist/components/Common/UI/FileInput/FileInputTypes.js.map +1 -0
- package/dist/components/Common/UI/FileInput/index.d.ts +4 -0
- package/dist/components/Common/UI/ProgressBar/ProgressBar.js +4 -4
- package/dist/components/Common/UI/TextInput/TextInput.js +27 -23
- package/dist/components/Common/UI/TextInput/TextInput.js.map +1 -1
- package/dist/components/Common/UI/TextInput/TextInputTypes.d.ts +1 -1
- package/dist/components/Common/UI/TextInput/TextInputTypes.js.map +1 -1
- package/dist/components/Company/AssignSignatory/AssignSignatorySelection.js +1 -1
- package/dist/components/Company/AssignSignatory/CreateSignatory/CreateSignatoryForm.js +12 -12
- package/dist/components/Company/AssignSignatory/CreateSignatory/useCreateSignatory.js +4 -3
- package/dist/components/Company/AssignSignatory/CreateSignatory/useCreateSignatory.js.map +1 -1
- package/dist/components/Company/AssignSignatory/InviteSignatory/InviteSignatoryForm.js +1 -1
- package/dist/components/Company/AssignSignatory/InviteSignatory/useInviteSignatory.js +4 -3
- package/dist/components/Company/AssignSignatory/InviteSignatory/useInviteSignatory.js.map +1 -1
- package/dist/components/Company/AssignSignatory/useAssignSignatory.js +6 -5
- package/dist/components/Company/AssignSignatory/useAssignSignatory.js.map +1 -1
- package/dist/components/Company/BankAccount/BankAccountForm/Form.js +1 -1
- package/dist/components/Company/BankAccount/BankAccountForm/context.js +4 -3
- package/dist/components/Company/BankAccount/BankAccountForm/context.js.map +1 -1
- package/dist/components/Company/BankAccount/BankAccountVerify/Form.js +1 -1
- package/dist/components/Company/DocumentSigner/DocumentList/useDocumentList.js +4 -3
- package/dist/components/Company/DocumentSigner/DocumentList/useDocumentList.js.map +1 -1
- package/dist/components/Company/DocumentSigner/SignatureForm/useSignatureForm.js +4 -3
- package/dist/components/Company/DocumentSigner/SignatureForm/useSignatureForm.js.map +1 -1
- package/dist/components/Company/FederalTaxes/Form.js +1 -1
- package/dist/components/Company/FederalTaxes/useFederalTaxes.js +9 -8
- package/dist/components/Company/FederalTaxes/useFederalTaxes.js.map +1 -1
- package/dist/components/Company/Industry/Context.js +7 -6
- package/dist/components/Company/Industry/Context.js.map +1 -1
- package/dist/components/Company/Locations/LocationForm/Form.js +1 -1
- package/dist/components/Company/Locations/LocationForm/useLocationForm.js +4 -3
- package/dist/components/Company/Locations/LocationForm/useLocationForm.js.map +1 -1
- package/dist/components/Company/Locations/LocationsList/List.js +35 -33
- package/dist/components/Company/Locations/LocationsList/List.js.map +1 -1
- package/dist/components/Company/Locations/LocationsList/LocationsList.js +29 -28
- package/dist/components/Company/Locations/LocationsList/LocationsList.js.map +1 -1
- package/dist/components/Company/Locations/LocationsList/useLocationsList.d.ts +1 -0
- package/dist/components/Company/Locations/LocationsList/useLocationsList.js +4 -3
- package/dist/components/Company/Locations/LocationsList/useLocationsList.js.map +1 -1
- package/dist/components/Company/OnboardingOverview/context.js +4 -3
- package/dist/components/Company/OnboardingOverview/context.js.map +1 -1
- package/dist/components/Company/PaySchedule/_parts/Edit.js +15 -15
- package/dist/components/Company/PaySchedule/usePaySchedule.js +6 -5
- package/dist/components/Company/PaySchedule/usePaySchedule.js.map +1 -1
- package/dist/components/Company/StateTaxes/StateTaxesForm/context.js +4 -3
- package/dist/components/Company/StateTaxes/StateTaxesForm/context.js.map +1 -1
- package/dist/components/Company/StateTaxes/StateTaxesList/context.js +4 -3
- package/dist/components/Company/StateTaxes/StateTaxesList/context.js.map +1 -1
- package/dist/components/Contractor/Address/Form.js +1 -1
- package/dist/components/Contractor/Address/useAddress.js +6 -5
- package/dist/components/Contractor/Address/useAddress.js.map +1 -1
- package/dist/components/Contractor/ContractorList/index.js +16 -15
- package/dist/components/Contractor/ContractorList/index.js.map +1 -1
- package/dist/components/Contractor/PaymentMethod/BankAccountForm.js +2 -2
- package/dist/components/Contractor/PaymentMethod/PaymentTypeForm.js +1 -1
- package/dist/components/Contractor/Payments/CreatePayment/CreatePayment.js +61 -59
- package/dist/components/Contractor/Payments/CreatePayment/CreatePayment.js.map +1 -1
- package/dist/components/Contractor/Payments/CreatePayment/CreatePaymentPresentation.js +24 -22
- package/dist/components/Contractor/Payments/CreatePayment/CreatePaymentPresentation.js.map +1 -1
- package/dist/components/Contractor/Payments/CreatePayment/EditContractorPaymentPresentation.js +38 -19
- package/dist/components/Contractor/Payments/CreatePayment/EditContractorPaymentPresentation.js.map +1 -1
- package/dist/components/Contractor/Payments/CreatePayment/PreviewPresentation.d.ts +3 -1
- package/dist/components/Contractor/Payments/CreatePayment/PreviewPresentation.js +26 -25
- package/dist/components/Contractor/Payments/CreatePayment/PreviewPresentation.js.map +1 -1
- package/dist/components/Contractor/Payments/PaymentFlow/PaymentFlowComponents.d.ts +2 -0
- package/dist/components/Contractor/Payments/PaymentFlow/PaymentFlowComponents.js +25 -19
- package/dist/components/Contractor/Payments/PaymentFlow/PaymentFlowComponents.js.map +1 -1
- package/dist/components/Contractor/Payments/PaymentFlow/paymentStateMachine.d.ts +1 -0
- package/dist/components/Contractor/Payments/PaymentFlow/paymentStateMachine.js +86 -56
- package/dist/components/Contractor/Payments/PaymentFlow/paymentStateMachine.js.map +1 -1
- package/dist/components/Contractor/Payments/PaymentHistory/PaymentHistory.d.ts +1 -2
- package/dist/components/Contractor/Payments/PaymentHistory/PaymentHistory.js +46 -21
- package/dist/components/Contractor/Payments/PaymentHistory/PaymentHistory.js.map +1 -1
- package/dist/components/Contractor/Payments/PaymentHistory/PaymentHistoryPresentation.d.ts +6 -15
- package/dist/components/Contractor/Payments/PaymentHistory/PaymentHistoryPresentation.js +115 -99
- package/dist/components/Contractor/Payments/PaymentHistory/PaymentHistoryPresentation.js.map +1 -1
- package/dist/components/Contractor/Payments/PaymentHistory/PaymentHistoryPresentation.module.scss.js +8 -0
- package/dist/components/Contractor/Payments/PaymentHistory/PaymentHistoryPresentation.module.scss.js.map +1 -0
- package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatement.d.ts +8 -0
- package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatement.js +51 -0
- package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatement.js.map +1 -0
- package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatementPresentation.d.ts +11 -0
- package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatementPresentation.js +157 -0
- package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatementPresentation.js.map +1 -0
- package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatementPresentation.module.scss.js +22 -0
- package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatementPresentation.module.scss.js.map +1 -0
- package/dist/components/Contractor/Payments/PaymentsList/PaymentsListPresentation.js +40 -43
- package/dist/components/Contractor/Payments/PaymentsList/PaymentsListPresentation.js.map +1 -1
- package/dist/components/Contractor/Profile/ContractorProfileForm.js +15 -15
- package/dist/components/Contractor/Profile/useContractorProfile.js +3 -2
- package/dist/components/Contractor/Profile/useContractorProfile.js.map +1 -1
- package/dist/components/Employee/Compensation/Edit.js +14 -14
- package/dist/components/Employee/Deductions/DeductionsForm/ChildSupportForm.js +10 -9
- package/dist/components/Employee/Deductions/DeductionsForm/ChildSupportForm.js.map +1 -1
- package/dist/components/Employee/Deductions/DeductionsForm/CustomDeductionForm.js +11 -10
- package/dist/components/Employee/Deductions/DeductionsForm/CustomDeductionForm.js.map +1 -1
- package/dist/components/Employee/Deductions/DeductionsForm/GarnishmentForm.js +11 -10
- package/dist/components/Employee/Deductions/DeductionsForm/GarnishmentForm.js.map +1 -1
- package/dist/components/Employee/DocumentSigner/DocumentList/useDocumentList.js +4 -3
- package/dist/components/Employee/DocumentSigner/DocumentList/useDocumentList.js.map +1 -1
- package/dist/components/Employee/DocumentSigner/SignatureForm/useSignatureForm.js +4 -3
- package/dist/components/Employee/DocumentSigner/SignatureForm/useSignatureForm.js.map +1 -1
- package/dist/components/Employee/EmployeeList/EmployeeList.js +57 -56
- package/dist/components/Employee/EmployeeList/EmployeeList.js.map +1 -1
- package/dist/components/Employee/EmployeeList/List.js +34 -32
- package/dist/components/Employee/EmployeeList/List.js.map +1 -1
- package/dist/components/Employee/EmployeeList/useEmployeeList.d.ts +1 -0
- package/dist/components/Employee/EmployeeList/useEmployeeList.js +4 -3
- package/dist/components/Employee/EmployeeList/useEmployeeList.js.map +1 -1
- package/dist/components/Employee/FederalTaxes/FederalForm.js +7 -7
- package/dist/components/Employee/FederalTaxes/useFederalTaxes.js +4 -3
- package/dist/components/Employee/FederalTaxes/useFederalTaxes.js.map +1 -1
- package/dist/components/Employee/PaymentMethod/BankAccountEdit.js +2 -2
- package/dist/components/Employee/PaymentMethod/PaymentTypeForm.js +1 -1
- package/dist/components/Employee/PaymentMethod/Split.js +8 -8
- package/dist/components/Employee/PaymentMethod/usePaymentMethod.js +6 -5
- package/dist/components/Employee/PaymentMethod/usePaymentMethod.js.map +1 -1
- package/dist/components/Employee/Profile/AdminPersonalDetails.js +1 -1
- package/dist/components/Employee/Profile/HomeAddress.js +1 -1
- package/dist/components/Employee/Profile/PersonalDetailsInputs.js +2 -2
- package/dist/components/Employee/Profile/useProfile.js +4 -3
- package/dist/components/Employee/Profile/useProfile.js.map +1 -1
- package/dist/components/Employee/StateTaxes/useStateTaxes.js +4 -3
- package/dist/components/Employee/StateTaxes/useStateTaxes.js.map +1 -1
- package/dist/components/Employee/Taxes/FederalForm.js +7 -7
- package/dist/components/Employee/Taxes/useTaxes.js +4 -3
- package/dist/components/Employee/Taxes/useTaxes.js.map +1 -1
- package/dist/components/Payroll/ConfirmWireDetails/ConfirmWireDetailsForm/ConfirmWireDetailsForm.js +9 -9
- package/dist/components/Payroll/InformationRequests/InformationRequestForm/InformationRequestForm.d.ts +15 -0
- package/dist/components/Payroll/InformationRequests/InformationRequestForm/InformationRequestForm.js +142 -0
- package/dist/components/Payroll/InformationRequests/InformationRequestForm/InformationRequestForm.js.map +1 -0
- package/dist/components/Payroll/InformationRequests/InformationRequestForm/InformationRequestForm.module.scss.js +18 -0
- package/dist/components/Payroll/InformationRequests/InformationRequestForm/InformationRequestForm.module.scss.js.map +1 -0
- package/dist/components/Payroll/InformationRequests/InformationRequestForm/index.d.ts +2 -0
- package/dist/components/Payroll/InformationRequests/InformationRequestList/InformationRequestList.d.ts +7 -0
- package/dist/components/Payroll/InformationRequests/InformationRequestList/InformationRequestList.js +88 -0
- package/dist/components/Payroll/InformationRequests/InformationRequestList/InformationRequestList.js.map +1 -0
- package/dist/components/Payroll/InformationRequests/InformationRequestList/index.d.ts +2 -0
- package/dist/components/Payroll/InformationRequests/InformationRequests.d.ts +6 -0
- package/dist/components/Payroll/InformationRequests/InformationRequests.js +55 -0
- package/dist/components/Payroll/InformationRequests/InformationRequests.js.map +1 -0
- package/dist/components/Payroll/InformationRequests/InformationRequestsComponents.d.ts +19 -0
- package/dist/components/Payroll/InformationRequests/InformationRequestsComponents.js +20 -0
- package/dist/components/Payroll/InformationRequests/InformationRequestsComponents.js.map +1 -0
- package/dist/components/Payroll/InformationRequests/index.d.ts +3 -0
- package/dist/components/Payroll/InformationRequests/informationRequestsStateMachine.d.ts +13 -0
- package/dist/components/Payroll/InformationRequests/informationRequestsStateMachine.js +47 -0
- package/dist/components/Payroll/InformationRequests/informationRequestsStateMachine.js.map +1 -0
- package/dist/components/Payroll/PayrollConfiguration/PayrollConfiguration.js +116 -130
- package/dist/components/Payroll/PayrollConfiguration/PayrollConfiguration.js.map +1 -1
- package/dist/components/Payroll/PayrollConfiguration/PayrollConfigurationPresentation.d.ts +5 -2
- package/dist/components/Payroll/PayrollConfiguration/PayrollConfigurationPresentation.js +107 -99
- package/dist/components/Payroll/PayrollConfiguration/PayrollConfigurationPresentation.js.map +1 -1
- package/dist/components/Payroll/PayrollConfiguration/PayrollConfigurationPresentation.module.scss.js +2 -4
- package/dist/components/Payroll/PayrollConfiguration/PayrollConfigurationPresentation.module.scss.js.map +1 -1
- package/dist/components/Payroll/PayrollConfiguration/usePayrollConfigurationData.d.ts +21 -0
- package/dist/components/Payroll/PayrollConfiguration/usePayrollConfigurationData.js +105 -0
- package/dist/components/Payroll/PayrollConfiguration/usePayrollConfigurationData.js.map +1 -0
- package/dist/components/Payroll/PayrollEditEmployee/PayrollEditEmployee.js +41 -37
- package/dist/components/Payroll/PayrollEditEmployee/PayrollEditEmployee.js.map +1 -1
- package/dist/components/Payroll/PayrollEditEmployee/PayrollEditEmployeePresentation.d.ts +5 -4
- package/dist/components/Payroll/PayrollEditEmployee/PayrollEditEmployeePresentation.js +137 -131
- package/dist/components/Payroll/PayrollEditEmployee/PayrollEditEmployeePresentation.js.map +1 -1
- package/dist/components/Payroll/PayrollEditEmployee/TimeOffField.js +16 -15
- package/dist/components/Payroll/PayrollEditEmployee/TimeOffField.js.map +1 -1
- package/dist/components/Payroll/PayrollFlow/payrollStateMachine.d.ts +2 -0
- package/dist/components/Payroll/PayrollFlow/payrollStateMachine.js +174 -106
- package/dist/components/Payroll/PayrollFlow/payrollStateMachine.js.map +1 -1
- package/dist/components/Payroll/PayrollHistory/PayrollHistory.js +28 -28
- package/dist/components/Payroll/PayrollHistory/PayrollHistory.js.map +1 -1
- package/dist/components/Payroll/PayrollHistory/PayrollHistoryPresentation.d.ts +2 -2
- package/dist/components/Payroll/PayrollHistory/PayrollHistoryPresentation.js +85 -104
- package/dist/components/Payroll/PayrollHistory/PayrollHistoryPresentation.js.map +1 -1
- package/dist/components/Payroll/PayrollLanding/PayrollLanding.js +24 -20
- package/dist/components/Payroll/PayrollLanding/PayrollLanding.js.map +1 -1
- package/dist/components/Payroll/PayrollLanding/PayrollLandingFlowComponents.d.ts +2 -0
- package/dist/components/Payroll/PayrollLanding/PayrollLandingFlowComponents.js +51 -46
- package/dist/components/Payroll/PayrollLanding/PayrollLandingFlowComponents.js.map +1 -1
- package/dist/components/Payroll/PayrollLanding/payrollLandingStateMachine.d.ts +2 -0
- package/dist/components/Payroll/PayrollLanding/payrollLandingStateMachine.js +111 -45
- package/dist/components/Payroll/PayrollLanding/payrollLandingStateMachine.js.map +1 -1
- package/dist/components/Payroll/PayrollList/PayrollListPresentation.js +136 -125
- package/dist/components/Payroll/PayrollList/PayrollListPresentation.js.map +1 -1
- package/dist/components/Payroll/PayrollList/PayrollListPresentation.module.scss.js +8 -4
- package/dist/components/Payroll/PayrollList/PayrollListPresentation.module.scss.js.map +1 -1
- package/dist/components/Payroll/PayrollOverview/PayrollOverview.js +117 -110
- package/dist/components/Payroll/PayrollOverview/PayrollOverview.js.map +1 -1
- package/dist/components/Payroll/PayrollOverview/PayrollOverviewPresentation.d.ts +4 -2
- package/dist/components/Payroll/PayrollOverview/PayrollOverviewPresentation.js +282 -278
- package/dist/components/Payroll/PayrollOverview/PayrollOverviewPresentation.js.map +1 -1
- package/dist/components/Payroll/PayrollOverview/PayrollOverviewTypes.d.ts +6 -0
- package/dist/components/Payroll/PayrollOverview/PayrollOverviewTypes.js +5 -0
- package/dist/components/Payroll/PayrollOverview/PayrollOverviewTypes.js.map +1 -0
- package/dist/components/Payroll/RecoveryCases/RecoveryCases.d.ts +6 -0
- package/dist/components/Payroll/RecoveryCases/RecoveryCases.js +55 -0
- package/dist/components/Payroll/RecoveryCases/RecoveryCases.js.map +1 -0
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesComponents.d.ts +19 -0
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesComponents.js +19 -0
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesComponents.js.map +1 -0
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesList/RecoveryCasesList.d.ts +7 -0
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesList/RecoveryCasesList.js +73 -0
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesList/RecoveryCasesList.js.map +1 -0
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesList/RecoveryCasesList.module.scss.js +10 -0
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesList/RecoveryCasesList.module.scss.js.map +1 -0
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesList/index.d.ts +2 -0
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesResubmit/RecoveryCasesResubmit.d.ts +14 -0
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesResubmit/RecoveryCasesResubmit.js +46 -0
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesResubmit/RecoveryCasesResubmit.js.map +1 -0
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesResubmit/index.d.ts +2 -0
- package/dist/components/Payroll/RecoveryCases/index.d.ts +3 -0
- package/dist/components/Payroll/RecoveryCases/recoveryCasesStateMachine.d.ts +13 -0
- package/dist/components/Payroll/RecoveryCases/recoveryCasesStateMachine.js +47 -0
- package/dist/components/Payroll/RecoveryCases/recoveryCasesStateMachine.js.map +1 -0
- package/dist/components/Payroll/helpers.d.ts +12 -0
- package/dist/components/Payroll/helpers.js +129 -117
- package/dist/components/Payroll/helpers.js.map +1 -1
- package/dist/components/Payroll/index.d.ts +2 -0
- package/dist/components/Payroll/index.js +18 -14
- package/dist/components/Payroll/index.js.map +1 -1
- package/dist/components/Payroll/usePreparedPayrollData.d.ts +4 -1
- package/dist/components/Payroll/usePreparedPayrollData.js +43 -31
- package/dist/components/Payroll/usePreparedPayrollData.js.map +1 -1
- package/dist/contexts/ComponentAdapter/adapters/defaultComponentAdapter.js +27 -25
- 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 +5 -0
- package/dist/contexts/ComponentAdapter/createComponentsWithDefaults.js +17 -15
- package/dist/contexts/ComponentAdapter/createComponentsWithDefaults.js.map +1 -1
- package/dist/contexts/ComponentAdapter/useComponentContext.d.ts +2 -0
- package/dist/contexts/ComponentAdapter/useComponentContext.js +3 -3
- package/dist/contexts/ComponentAdapter/useComponentContext.js.map +1 -1
- package/dist/helpers/dateFormatting.d.ts +1 -0
- package/dist/helpers/dateFormatting.js +1 -0
- package/dist/helpers/dateFormatting.js.map +1 -1
- package/dist/helpers/formattedStrings.d.ts +1 -0
- package/dist/helpers/formattedStrings.js +23 -18
- package/dist/helpers/formattedStrings.js.map +1 -1
- package/dist/helpers/responsive.js +1 -1
- package/dist/helpers/responsive.js.map +1 -1
- package/dist/i18n/I18n.js +3 -3
- package/dist/i18n/I18n.js.map +1 -1
- package/dist/i18n/en/Contractor.Payments.CreatePayment.json.js +36 -32
- package/dist/i18n/en/Contractor.Payments.CreatePayment.json.js.map +1 -1
- package/dist/i18n/en/Contractor.Payments.PaymentHistory.json.js +11 -11
- package/dist/i18n/en/Contractor.Payments.PaymentStatement.json.js +28 -0
- package/dist/i18n/en/Contractor.Payments.PaymentStatement.json.js.map +1 -0
- package/dist/i18n/en/Contractor.Payments.PaymentsList.json.js +14 -14
- package/dist/i18n/en/Payroll.InformationRequestForm.json.js +18 -0
- package/dist/i18n/en/Payroll.InformationRequestForm.json.js.map +1 -0
- package/dist/i18n/en/Payroll.InformationRequestList.json.js +18 -0
- package/dist/i18n/en/Payroll.InformationRequestList.json.js.map +1 -0
- package/dist/i18n/en/Payroll.PayrollConfiguration.json.js +27 -21
- package/dist/i18n/en/Payroll.PayrollConfiguration.json.js.map +1 -1
- package/dist/i18n/en/Payroll.PayrollHistory.json.js +6 -6
- package/dist/i18n/en/Payroll.PayrollLanding.json.js +5 -3
- package/dist/i18n/en/Payroll.PayrollLanding.json.js.map +1 -1
- package/dist/i18n/en/Payroll.PayrollOverview.json.js +32 -28
- package/dist/i18n/en/Payroll.PayrollOverview.json.js.map +1 -1
- package/dist/i18n/en/Payroll.RecoveryCasesList.json.js +14 -0
- package/dist/i18n/en/Payroll.RecoveryCasesList.json.js.map +1 -0
- package/dist/i18n/en/Payroll.RecoveryCasesResubmit.json.js +8 -0
- package/dist/i18n/en/Payroll.RecoveryCasesResubmit.json.js.map +1 -0
- package/dist/i18n/en/common.json.d.ts +6 -0
- package/dist/i18n/en/common.json.js +4 -2
- package/dist/i18n/en/common.json.js.map +1 -1
- package/dist/shared/constants.d.ts +25 -1
- package/dist/shared/constants.js +72 -55
- package/dist/shared/constants.js.map +1 -1
- package/dist/style.css +1 -1
- package/dist/types/i18next.d.ts +120 -3
- package/package.json +31 -20
|
@@ -5,11 +5,11 @@ import { zipValidation as n, phoneValidation as m } from "../../../../helpers/va
|
|
|
5
5
|
import { Flex as d } from "../../../Common/Flex/Flex.js";
|
|
6
6
|
import { Grid as p } from "../../../Common/Grid/Grid.js";
|
|
7
7
|
import "classnames";
|
|
8
|
-
import { TextInputField as s } from "../../../Common/Fields/TextInputField/TextInputField.js";
|
|
9
8
|
import "../../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
10
9
|
import "react";
|
|
11
10
|
import { STATES_ABBR as c } from "../../../../shared/constants.js";
|
|
12
11
|
import { useMaskedTransform as u, commonMasks as b } from "../../../../helpers/mask.js";
|
|
12
|
+
import { TextInputField as s } from "../../../Common/Fields/TextInputField/TextInputField.js";
|
|
13
13
|
import { SelectField as f } from "../../../Common/Fields/SelectField/SelectField.js";
|
|
14
14
|
import { CheckboxGroupField as g } from "../../../Common/Fields/CheckboxGroupField/CheckboxGroupField.js";
|
|
15
15
|
const j = i.object({
|
|
@@ -9,13 +9,14 @@ import "../../../Base/useBase.js";
|
|
|
9
9
|
import "../../../../shared/constants.js";
|
|
10
10
|
import "classnames";
|
|
11
11
|
import "../../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
12
|
+
import "../../../../contexts/LoadingIndicatorProvider/useLoadingIndicator.js";
|
|
12
13
|
import "dompurify";
|
|
13
14
|
import { createCompoundContext as o } from "../../../Base/createCompoundContext.js";
|
|
14
|
-
const [
|
|
15
|
+
const [d, L] = o(
|
|
15
16
|
"CompanyDocumentFormContext"
|
|
16
17
|
);
|
|
17
18
|
export {
|
|
18
|
-
|
|
19
|
-
|
|
19
|
+
L as LocationsFormProvider,
|
|
20
|
+
d as useLocationsForm
|
|
20
21
|
};
|
|
21
22
|
//# sourceMappingURL=useLocationForm.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useLocationForm.js","sources":["../../../../../src/components/Company/Locations/LocationForm/useLocationForm.ts"],"sourcesContent":["import { createCompoundContext } from '@/components/Base'\n\ntype LocationsFormContextType = {\n isPending: boolean\n handleCancel: () => void\n}\n\nconst [useLocationsForm, LocationsFormProvider] = createCompoundContext<LocationsFormContextType>(\n 'CompanyDocumentFormContext',\n)\n\nexport { useLocationsForm, LocationsFormProvider }\n"],"names":["useLocationsForm","LocationsFormProvider","createCompoundContext"],"mappings":"
|
|
1
|
+
{"version":3,"file":"useLocationForm.js","sources":["../../../../../src/components/Company/Locations/LocationForm/useLocationForm.ts"],"sourcesContent":["import { createCompoundContext } from '@/components/Base'\n\ntype LocationsFormContextType = {\n isPending: boolean\n handleCancel: () => void\n}\n\nconst [useLocationsForm, LocationsFormProvider] = createCompoundContext<LocationsFormContextType>(\n 'CompanyDocumentFormContext',\n)\n\nexport { useLocationsForm, LocationsFormProvider }\n"],"names":["useLocationsForm","LocationsFormProvider","createCompoundContext"],"mappings":";;;;;;;;;;;;;;AAOA,MAAM,CAACA,GAAkBC,CAAqB,IAAIC;AAAA,EAChD;AACF;"}
|
|
@@ -1,43 +1,44 @@
|
|
|
1
1
|
import { jsx as t, Fragment as r, jsxs as n } from "react/jsx-runtime";
|
|
2
2
|
import { useTranslation as P } from "react-i18next";
|
|
3
|
-
import { useLocationsList as
|
|
4
|
-
import
|
|
3
|
+
import { useLocationsList as y } from "./useLocationsList.js";
|
|
4
|
+
import b from "../../../../assets/icons/pencil.svg.js";
|
|
5
5
|
import "../../../../shared/constants.js";
|
|
6
6
|
import "classnames";
|
|
7
|
-
import { EmptyData as
|
|
8
|
-
import { HamburgerMenu as
|
|
9
|
-
import { useComponentContext as
|
|
10
|
-
import { getStreet as
|
|
11
|
-
import { VisuallyHidden as
|
|
12
|
-
import { useDataView as
|
|
13
|
-
import { DataView as
|
|
14
|
-
const
|
|
15
|
-
const a =
|
|
7
|
+
import { EmptyData as x } from "../../../Common/EmptyData/EmptyData.js";
|
|
8
|
+
import { HamburgerMenu as T } from "../../../Common/HamburgerMenu/HamburgerMenu.js";
|
|
9
|
+
import { useComponentContext as v } from "../../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
10
|
+
import { getStreet as A, getCityStateZip as k } from "../../../../helpers/formattedStrings.js";
|
|
11
|
+
import { VisuallyHidden as D } from "../../../Common/VisuallyHidden/VisuallyHidden.js";
|
|
12
|
+
import { useDataView as S } from "../../../Common/DataView/useDataView.js";
|
|
13
|
+
import { DataView as V } from "../../../Common/DataView/DataView.js";
|
|
14
|
+
const J = () => {
|
|
15
|
+
const a = v(), {
|
|
16
16
|
locationList: o,
|
|
17
17
|
handleEditLocation: s,
|
|
18
18
|
currentPage: d,
|
|
19
19
|
totalPages: l,
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
20
|
+
totalCount: m,
|
|
21
|
+
handleFirstPage: c,
|
|
22
|
+
handleItemsPerPageChange: p,
|
|
23
|
+
handleLastPage: g,
|
|
24
|
+
handleNextPage: u,
|
|
25
|
+
handlePreviousPage: h,
|
|
26
|
+
handleAddLocation: f,
|
|
27
|
+
itemsPerPage: L
|
|
28
|
+
} = y(), { t: e } = P("Company.Locations"), { ...C } = S({
|
|
28
29
|
data: o,
|
|
29
30
|
columns: [
|
|
30
31
|
{
|
|
31
32
|
key: "name",
|
|
32
33
|
title: e("locationListCol1"),
|
|
33
34
|
render: (i) => /* @__PURE__ */ t(r, { children: /* @__PURE__ */ n("address", { children: [
|
|
34
|
-
/* @__PURE__ */ t(a.Text, { as: "div", children:
|
|
35
|
-
/* @__PURE__ */ t(a.Text, { as: "div", size: "sm", children:
|
|
35
|
+
/* @__PURE__ */ t(a.Text, { as: "div", children: A(i) }),
|
|
36
|
+
/* @__PURE__ */ t(a.Text, { as: "div", size: "sm", children: k(i) })
|
|
36
37
|
] }) })
|
|
37
38
|
},
|
|
38
39
|
{
|
|
39
40
|
key: "status",
|
|
40
|
-
title: /* @__PURE__ */ t(
|
|
41
|
+
title: /* @__PURE__ */ t(D, { children: e("locationListCol2") }),
|
|
41
42
|
render: (i) => /* @__PURE__ */ n(r, { children: [
|
|
42
43
|
i.mailingAddress && /* @__PURE__ */ t(a.Badge, { status: "info", children: e("mailingAddress") }),
|
|
43
44
|
i.filingAddress && /* @__PURE__ */ n(r, { children: [
|
|
@@ -48,7 +49,7 @@ const G = () => {
|
|
|
48
49
|
}
|
|
49
50
|
],
|
|
50
51
|
itemMenu: (i) => /* @__PURE__ */ t(
|
|
51
|
-
|
|
52
|
+
T,
|
|
52
53
|
{
|
|
53
54
|
items: [
|
|
54
55
|
{
|
|
@@ -56,7 +57,7 @@ const G = () => {
|
|
|
56
57
|
onClick: () => {
|
|
57
58
|
s(i.uuid);
|
|
58
59
|
},
|
|
59
|
-
icon: /* @__PURE__ */ t(
|
|
60
|
+
icon: /* @__PURE__ */ t(b, { "aria-hidden": !0 }),
|
|
60
61
|
"data-testid": "edit-location"
|
|
61
62
|
}
|
|
62
63
|
],
|
|
@@ -65,20 +66,21 @@ const G = () => {
|
|
|
65
66
|
}
|
|
66
67
|
),
|
|
67
68
|
pagination: {
|
|
68
|
-
handleNextPage:
|
|
69
|
-
handleFirstPage:
|
|
70
|
-
handleLastPage:
|
|
71
|
-
handlePreviousPage:
|
|
72
|
-
handleItemsPerPageChange:
|
|
69
|
+
handleNextPage: u,
|
|
70
|
+
handleFirstPage: c,
|
|
71
|
+
handleLastPage: g,
|
|
72
|
+
handlePreviousPage: h,
|
|
73
|
+
handleItemsPerPageChange: p,
|
|
73
74
|
currentPage: d,
|
|
74
75
|
totalPages: l,
|
|
75
|
-
|
|
76
|
+
totalCount: m,
|
|
77
|
+
itemsPerPage: L
|
|
76
78
|
},
|
|
77
|
-
emptyState: () => /* @__PURE__ */ t(
|
|
79
|
+
emptyState: () => /* @__PURE__ */ t(x, { title: e("emptyTableTitle"), description: e("emptyTableDescription"), children: /* @__PURE__ */ t(a.Button, { variant: "secondary", onClick: f, children: e("addFirstLocationCta") }) })
|
|
78
80
|
});
|
|
79
|
-
return /* @__PURE__ */ t(
|
|
81
|
+
return /* @__PURE__ */ t(V, { label: e("locationListLabel"), ...C });
|
|
80
82
|
};
|
|
81
83
|
export {
|
|
82
|
-
|
|
84
|
+
J as List
|
|
83
85
|
};
|
|
84
86
|
//# sourceMappingURL=List.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"List.js","sources":["../../../../../src/components/Company/Locations/LocationsList/List.tsx"],"sourcesContent":["import { useTranslation } from 'react-i18next'\nimport { useLocationsList } from './useLocationsList'\nimport PencilSvg from '@/assets/icons/pencil.svg?react'\nimport { DataView, EmptyData, useDataView, VisuallyHidden } from '@/components/Common'\nimport { useComponentContext } from '@/contexts/ComponentAdapter/useComponentContext'\nimport { HamburgerMenu } from '@/components/Common/HamburgerMenu'\nimport { getCityStateZip, getStreet } from '@/helpers/formattedStrings'\n\n/**List of employees slot for EmployeeList component */\nexport const List = () => {\n const Components = useComponentContext()\n const {\n locationList,\n handleEditLocation,\n currentPage,\n totalPages,\n handleFirstPage,\n handleItemsPerPageChange,\n handleLastPage,\n handleNextPage,\n handlePreviousPage,\n handleAddLocation,\n itemsPerPage,\n } = useLocationsList()\n\n const { t } = useTranslation('Company.Locations')\n const { ...dataViewProps } = useDataView({\n data: locationList,\n columns: [\n {\n key: 'name',\n title: t('locationListCol1'),\n render: location => {\n return (\n <>\n <address>\n <Components.Text as=\"div\">{getStreet(location)}</Components.Text>\n <Components.Text as=\"div\" size=\"sm\">\n {getCityStateZip(location)}\n </Components.Text>\n </address>\n </>\n )\n },\n },\n {\n key: 'status',\n title: <VisuallyHidden>{t('locationListCol2')}</VisuallyHidden>,\n render: location => {\n return (\n <>\n {location.mailingAddress && (\n <Components.Badge status={'info'}>{t('mailingAddress')}</Components.Badge>\n )}\n {location.filingAddress && (\n <>\n {' '}\n <Components.Badge status={'info'}>{t('filingAddress')}</Components.Badge>\n </>\n )}\n </>\n )\n },\n },\n ],\n itemMenu: location => {\n return (\n <HamburgerMenu\n items={[\n {\n label: t('editCta'),\n onClick: () => {\n handleEditLocation(location.uuid)\n },\n icon: <PencilSvg aria-hidden />,\n 'data-testid': 'edit-location',\n },\n ]}\n data-testid=\"location-hamburger\"\n triggerLabel={t('hamburgerTitle')}\n />\n )\n },\n pagination: {\n handleNextPage,\n handleFirstPage,\n handleLastPage,\n handlePreviousPage,\n handleItemsPerPageChange,\n currentPage,\n totalPages,\n itemsPerPage,\n },\n emptyState: () => (\n <EmptyData title={t('emptyTableTitle')} description={t('emptyTableDescription')}>\n <Components.Button variant=\"secondary\" onClick={handleAddLocation}>\n {t('addFirstLocationCta')}\n </Components.Button>\n </EmptyData>\n ),\n })\n return <DataView label={t('locationListLabel')} {...dataViewProps} />\n}\n"],"names":["List","Components","useComponentContext","locationList","handleEditLocation","currentPage","totalPages","handleFirstPage","handleItemsPerPageChange","handleLastPage","handleNextPage","handlePreviousPage","handleAddLocation","itemsPerPage","useLocationsList","t","useTranslation","dataViewProps","useDataView","location","jsx","Fragment","getStreet","getCityStateZip","VisuallyHidden","jsxs","HamburgerMenu","PencilSvg","EmptyData","DataView"],"mappings":";;;;;;;;;;;;;AASO,MAAMA,IAAO,MAAM;AACxB,QAAMC,IAAaC,EAAA,GACb;AAAA,IACJ,cAAAC;AAAA,IACA,oBAAAC;AAAA,IACA,aAAAC;AAAA,IACA,YAAAC;AAAA,IACA,iBAAAC;AAAA,IACA,0BAAAC;AAAA,IACA,gBAAAC;AAAA,IACA,gBAAAC;AAAA,IACA,oBAAAC;AAAA,IACA,mBAAAC;AAAA,IACA,cAAAC;AAAA,EAAA,IACEC,EAAA,GAEE,EAAE,GAAAC,EAAA,IAAMC,EAAe,mBAAmB,GAC1C,EAAE,GAAGC,EAAA,IAAkBC,EAAY;AAAA,IACvC,
|
|
1
|
+
{"version":3,"file":"List.js","sources":["../../../../../src/components/Company/Locations/LocationsList/List.tsx"],"sourcesContent":["import { useTranslation } from 'react-i18next'\nimport { useLocationsList } from './useLocationsList'\nimport PencilSvg from '@/assets/icons/pencil.svg?react'\nimport { DataView, EmptyData, useDataView, VisuallyHidden } from '@/components/Common'\nimport { useComponentContext } from '@/contexts/ComponentAdapter/useComponentContext'\nimport { HamburgerMenu } from '@/components/Common/HamburgerMenu'\nimport { getCityStateZip, getStreet } from '@/helpers/formattedStrings'\n\n/**List of employees slot for EmployeeList component */\nexport const List = () => {\n const Components = useComponentContext()\n const {\n locationList,\n handleEditLocation,\n currentPage,\n totalPages,\n totalCount,\n handleFirstPage,\n handleItemsPerPageChange,\n handleLastPage,\n handleNextPage,\n handlePreviousPage,\n handleAddLocation,\n itemsPerPage,\n } = useLocationsList()\n\n const { t } = useTranslation('Company.Locations')\n const { ...dataViewProps } = useDataView({\n data: locationList,\n columns: [\n {\n key: 'name',\n title: t('locationListCol1'),\n render: location => {\n return (\n <>\n <address>\n <Components.Text as=\"div\">{getStreet(location)}</Components.Text>\n <Components.Text as=\"div\" size=\"sm\">\n {getCityStateZip(location)}\n </Components.Text>\n </address>\n </>\n )\n },\n },\n {\n key: 'status',\n title: <VisuallyHidden>{t('locationListCol2')}</VisuallyHidden>,\n render: location => {\n return (\n <>\n {location.mailingAddress && (\n <Components.Badge status={'info'}>{t('mailingAddress')}</Components.Badge>\n )}\n {location.filingAddress && (\n <>\n {' '}\n <Components.Badge status={'info'}>{t('filingAddress')}</Components.Badge>\n </>\n )}\n </>\n )\n },\n },\n ],\n itemMenu: location => {\n return (\n <HamburgerMenu\n items={[\n {\n label: t('editCta'),\n onClick: () => {\n handleEditLocation(location.uuid)\n },\n icon: <PencilSvg aria-hidden />,\n 'data-testid': 'edit-location',\n },\n ]}\n data-testid=\"location-hamburger\"\n triggerLabel={t('hamburgerTitle')}\n />\n )\n },\n pagination: {\n handleNextPage,\n handleFirstPage,\n handleLastPage,\n handlePreviousPage,\n handleItemsPerPageChange,\n currentPage,\n totalPages,\n totalCount,\n itemsPerPage,\n },\n emptyState: () => (\n <EmptyData title={t('emptyTableTitle')} description={t('emptyTableDescription')}>\n <Components.Button variant=\"secondary\" onClick={handleAddLocation}>\n {t('addFirstLocationCta')}\n </Components.Button>\n </EmptyData>\n ),\n })\n return <DataView label={t('locationListLabel')} {...dataViewProps} />\n}\n"],"names":["List","Components","useComponentContext","locationList","handleEditLocation","currentPage","totalPages","totalCount","handleFirstPage","handleItemsPerPageChange","handleLastPage","handleNextPage","handlePreviousPage","handleAddLocation","itemsPerPage","useLocationsList","t","useTranslation","dataViewProps","useDataView","location","jsx","Fragment","getStreet","getCityStateZip","VisuallyHidden","jsxs","HamburgerMenu","PencilSvg","EmptyData","DataView"],"mappings":";;;;;;;;;;;;;AASO,MAAMA,IAAO,MAAM;AACxB,QAAMC,IAAaC,EAAA,GACb;AAAA,IACJ,cAAAC;AAAA,IACA,oBAAAC;AAAA,IACA,aAAAC;AAAA,IACA,YAAAC;AAAA,IACA,YAAAC;AAAA,IACA,iBAAAC;AAAA,IACA,0BAAAC;AAAA,IACA,gBAAAC;AAAA,IACA,gBAAAC;AAAA,IACA,oBAAAC;AAAA,IACA,mBAAAC;AAAA,IACA,cAAAC;AAAA,EAAA,IACEC,EAAA,GAEE,EAAE,GAAAC,EAAA,IAAMC,EAAe,mBAAmB,GAC1C,EAAE,GAAGC,EAAA,IAAkBC,EAAY;AAAA,IACvC,MAAMhB;AAAA,IACN,SAAS;AAAA,MACP;AAAA,QACE,KAAK;AAAA,QACL,OAAOa,EAAE,kBAAkB;AAAA,QAC3B,QAAQ,CAAAI,MAEJ,gBAAAC,EAAAC,GAAA,EACE,4BAAC,WAAA,EACC,UAAA;AAAA,UAAA,gBAAAD,EAACpB,EAAW,MAAX,EAAgB,IAAG,OAAO,UAAAsB,EAAUH,CAAQ,GAAE;AAAA,UAC/C,gBAAAC,EAACpB,EAAW,MAAX,EAAgB,IAAG,OAAM,MAAK,MAC5B,UAAAuB,EAAgBJ,CAAQ,EAAA,CAC3B;AAAA,QAAA,EAAA,CACF,EAAA,CACF;AAAA,MAEJ;AAAA,MAEF;AAAA,QACE,KAAK;AAAA,QACL,OAAO,gBAAAC,EAACI,GAAA,EAAgB,UAAAT,EAAE,kBAAkB,GAAE;AAAA,QAC9C,QAAQ,CAAAI,MAEJ,gBAAAM,EAAAJ,GAAA,EACG,UAAA;AAAA,UAAAF,EAAS,oCACPnB,EAAW,OAAX,EAAiB,QAAQ,QAAS,UAAAe,EAAE,gBAAgB,EAAA,CAAE;AAAA,UAExDI,EAAS,iBACR,gBAAAM,EAAAJ,GAAA,EACG,UAAA;AAAA,YAAA;AAAA,YACD,gBAAAD,EAACpB,EAAW,OAAX,EAAiB,QAAQ,QAAS,UAAAe,EAAE,eAAe,EAAA,CAAE;AAAA,UAAA,EAAA,CACxD;AAAA,QAAA,GAEJ;AAAA,MAEJ;AAAA,IACF;AAAA,IAEF,UAAU,CAAAI,MAEN,gBAAAC;AAAA,MAACM;AAAA,MAAA;AAAA,QACC,OAAO;AAAA,UACL;AAAA,YACE,OAAOX,EAAE,SAAS;AAAA,YAClB,SAAS,MAAM;AACb,cAAAZ,EAAmBgB,EAAS,IAAI;AAAA,YAClC;AAAA,YACA,MAAM,gBAAAC,EAACO,GAAA,EAAU,eAAW,GAAA,CAAC;AAAA,YAC7B,eAAe;AAAA,UAAA;AAAA,QACjB;AAAA,QAEF,eAAY;AAAA,QACZ,cAAcZ,EAAE,gBAAgB;AAAA,MAAA;AAAA,IAAA;AAAA,IAItC,YAAY;AAAA,MACV,gBAAAL;AAAA,MACA,iBAAAH;AAAA,MACA,gBAAAE;AAAA,MACA,oBAAAE;AAAA,MACA,0BAAAH;AAAA,MACA,aAAAJ;AAAA,MACA,YAAAC;AAAA,MACA,YAAAC;AAAA,MACA,cAAAO;AAAA,IAAA;AAAA,IAEF,YAAY,MACV,gBAAAO,EAACQ,GAAA,EAAU,OAAOb,EAAE,iBAAiB,GAAG,aAAaA,EAAE,uBAAuB,GAC5E,UAAA,gBAAAK,EAACpB,EAAW,QAAX,EAAkB,SAAQ,aAAY,SAASY,GAC7C,UAAAG,EAAE,qBAAqB,EAAA,CAC1B,EAAA,CACF;AAAA,EAAA,CAEH;AACD,2BAAQc,GAAA,EAAS,OAAOd,EAAE,mBAAmB,GAAI,GAAGE,GAAe;AACrE;"}
|
|
@@ -1,33 +1,34 @@
|
|
|
1
|
-
import { jsx as e, jsxs as
|
|
2
|
-
import { useLocationsGetSuspense as
|
|
3
|
-
import { useState as
|
|
4
|
-
import { Head as
|
|
5
|
-
import { List as
|
|
6
|
-
import { Actions as
|
|
7
|
-
import { LocationsListProvider as
|
|
1
|
+
import { jsx as e, jsxs as u, Fragment as L } from "react/jsx-runtime";
|
|
2
|
+
import { useLocationsGetSuspense as f } from "@gusto/embedded-api/react-query/locationsGet";
|
|
3
|
+
import { useState as l } from "react";
|
|
4
|
+
import { Head as C } from "./Head.js";
|
|
5
|
+
import { List as N } from "./List.js";
|
|
6
|
+
import { Actions as x } from "./Actions.js";
|
|
7
|
+
import { LocationsListProvider as A } from "./useLocationsList.js";
|
|
8
8
|
import { useI18n as O } from "../../../../i18n/I18n.js";
|
|
9
|
-
import { BaseComponent as
|
|
10
|
-
import { useBase as
|
|
11
|
-
import { Flex as
|
|
9
|
+
import { BaseComponent as E } from "../../../Base/Base.js";
|
|
10
|
+
import { useBase as I } from "../../../Base/useBase.js";
|
|
11
|
+
import { Flex as v } from "../../../Common/Flex/Flex.js";
|
|
12
12
|
import "classnames";
|
|
13
|
-
import { companyEvents as
|
|
13
|
+
import { companyEvents as s } from "../../../../shared/constants.js";
|
|
14
14
|
import "react-i18next";
|
|
15
15
|
import "../../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
16
|
-
function
|
|
17
|
-
return /* @__PURE__ */ e(
|
|
16
|
+
function X(o) {
|
|
17
|
+
return /* @__PURE__ */ e(E, { ...o, children: /* @__PURE__ */ e(M, { ...o, children: o.children }) });
|
|
18
18
|
}
|
|
19
|
-
function
|
|
19
|
+
function M({ companyId: o, className: h, children: i }) {
|
|
20
20
|
O("Company.Locations");
|
|
21
|
-
const { onEvent: a } =
|
|
22
|
-
data: { locationList:
|
|
23
|
-
} =
|
|
24
|
-
return /* @__PURE__ */ e("section", { className:
|
|
25
|
-
|
|
21
|
+
const { onEvent: a } = I(), [m, n] = l(1), [c, P] = l(5), {
|
|
22
|
+
data: { locationList: g, httpMeta: d }
|
|
23
|
+
} = f({ companyId: o, page: m, per: c }), r = Number(d.response.headers.get("x-total-pages") ?? 1), p = Number(d.response.headers.get("x-total-count") ?? 0);
|
|
24
|
+
return /* @__PURE__ */ e("section", { className: h, children: /* @__PURE__ */ e(
|
|
25
|
+
A,
|
|
26
26
|
{
|
|
27
27
|
value: {
|
|
28
|
-
locationList:
|
|
28
|
+
locationList: g ?? [],
|
|
29
29
|
currentPage: m,
|
|
30
30
|
totalPages: r,
|
|
31
|
+
totalCount: p,
|
|
31
32
|
handleFirstPage: () => {
|
|
32
33
|
n(1);
|
|
33
34
|
},
|
|
@@ -41,28 +42,28 @@ function v({ companyId: o, className: l, children: s }) {
|
|
|
41
42
|
n(r);
|
|
42
43
|
},
|
|
43
44
|
handleItemsPerPageChange: (t) => {
|
|
44
|
-
|
|
45
|
+
P(t);
|
|
45
46
|
},
|
|
46
47
|
handleAddLocation: () => {
|
|
47
|
-
a(
|
|
48
|
+
a(s.COMPANY_LOCATION_CREATE);
|
|
48
49
|
},
|
|
49
50
|
handleEditLocation: (t) => {
|
|
50
|
-
a(
|
|
51
|
+
a(s.COMPANY_LOCATION_EDIT, { uuid: t });
|
|
51
52
|
},
|
|
52
53
|
handleContinue: () => {
|
|
53
|
-
a(
|
|
54
|
+
a(s.COMPANY_LOCATION_DONE);
|
|
54
55
|
},
|
|
55
56
|
itemsPerPage: c
|
|
56
57
|
},
|
|
57
|
-
children: /* @__PURE__ */ e(
|
|
58
|
-
/* @__PURE__ */ e(f, {}),
|
|
58
|
+
children: /* @__PURE__ */ e(v, { flexDirection: "column", gap: 32, children: i || /* @__PURE__ */ u(L, { children: [
|
|
59
59
|
/* @__PURE__ */ e(C, {}),
|
|
60
|
-
/* @__PURE__ */ e(
|
|
60
|
+
/* @__PURE__ */ e(N, {}),
|
|
61
|
+
/* @__PURE__ */ e(x, {})
|
|
61
62
|
] }) })
|
|
62
63
|
}
|
|
63
64
|
) });
|
|
64
65
|
}
|
|
65
66
|
export {
|
|
66
|
-
|
|
67
|
+
X as LocationsList
|
|
67
68
|
};
|
|
68
69
|
//# sourceMappingURL=LocationsList.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LocationsList.js","sources":["../../../../../src/components/Company/Locations/LocationsList/LocationsList.tsx"],"sourcesContent":["import { useLocationsGetSuspense } from '@gusto/embedded-api/react-query/locationsGet'\nimport { useState } from 'react'\nimport { Head } from './Head'\nimport { List } from './List'\nimport { Actions } from './Actions'\nimport { LocationsListProvider } from './useLocationsList'\nimport { useI18n } from '@/i18n'\nimport { BaseComponent, type BaseComponentInterface } from '@/components/Base/Base'\nimport { useBase } from '@/components/Base/useBase'\nimport { Flex } from '@/components/Common'\nimport { companyEvents } from '@/shared/constants'\nimport type { PaginationItemsPerPage } from '@/components/Common/PaginationControl/PaginationControlTypes'\n\ninterface LocationsListProps extends BaseComponentInterface {\n companyId: string\n}\n\nexport function LocationsList(props: LocationsListProps) {\n return (\n <BaseComponent {...props}>\n <Root {...props}>{props.children}</Root>\n </BaseComponent>\n )\n}\n\nfunction Root({ companyId, className, children }: LocationsListProps) {\n useI18n('Company.Locations')\n const { onEvent } = useBase()\n\n const [currentPage, setCurrentPage] = useState(1)\n const [itemsPerPage, setItemsPerPage] = useState<PaginationItemsPerPage>(5)\n\n const {\n data: { locationList, httpMeta },\n } = useLocationsGetSuspense({ companyId, page: currentPage, per: itemsPerPage })\n\n const totalPages = Number(httpMeta.response.headers.get('x-total-pages') ?? 1)\n\n const handleItemsPerPageChange = (newCount: PaginationItemsPerPage) => {\n setItemsPerPage(newCount)\n }\n const handleFirstPage = () => {\n setCurrentPage(1)\n }\n const handlePreviousPage = () => {\n setCurrentPage(prevPage => Math.max(prevPage - 1, 1))\n }\n const handleNextPage = () => {\n setCurrentPage(prevPage => Math.min(prevPage + 1, totalPages))\n }\n const handleLastPage = () => {\n setCurrentPage(totalPages)\n }\n\n const handleContinue = () => {\n onEvent(companyEvents.COMPANY_LOCATION_DONE)\n }\n const handleAddLocation = () => {\n onEvent(companyEvents.COMPANY_LOCATION_CREATE)\n }\n const handleEditLocation = (uuid: string) => {\n onEvent(companyEvents.COMPANY_LOCATION_EDIT, { uuid })\n }\n\n return (\n <section className={className}>\n <LocationsListProvider\n value={{\n locationList: locationList ?? [],\n currentPage,\n totalPages,\n handleFirstPage,\n handlePreviousPage,\n handleNextPage,\n handleLastPage,\n handleItemsPerPageChange,\n handleAddLocation,\n handleEditLocation,\n handleContinue,\n itemsPerPage,\n }}\n >\n <Flex flexDirection=\"column\" gap={32}>\n {children ? (\n children\n ) : (\n <>\n <Head />\n <List />\n <Actions />\n </>\n )}\n </Flex>\n </LocationsListProvider>\n </section>\n )\n}\n"],"names":["LocationsList","props","jsx","BaseComponent","Root","companyId","className","children","useI18n","onEvent","useBase","currentPage","setCurrentPage","useState","itemsPerPage","setItemsPerPage","locationList","httpMeta","useLocationsGetSuspense","totalPages","LocationsListProvider","prevPage","newCount","companyEvents","uuid","Flex","jsxs","Fragment","Head","List","Actions"],"mappings":";;;;;;;;;;;;;;;AAiBO,SAASA,EAAcC,GAA2B;AACvD,SACE,gBAAAC,EAACC,GAAA,EAAe,GAAGF,GACjB,UAAA,gBAAAC,EAACE,KAAM,GAAGH,GAAQ,UAAAA,EAAM,SAAA,CAAS,EAAA,CACnC;AAEJ;AAEA,SAASG,EAAK,EAAE,WAAAC,GAAW,WAAAC,GAAW,UAAAC,KAAgC;AACpE,EAAAC,EAAQ,mBAAmB;AAC3B,QAAM,EAAE,SAAAC,EAAA,IAAYC,EAAA,GAEd,CAACC,GAAaC,CAAc,IAAIC,EAAS,CAAC,GAC1C,CAACC,GAAcC,CAAe,IAAIF,EAAiC,CAAC,GAEpE;AAAA,IACJ,MAAM,EAAE,cAAAG,GAAc,UAAAC,EAAA;AAAA,EAAS,IAC7BC,EAAwB,EAAE,WAAAb,GAAW,MAAMM,GAAa,KAAKG,GAAc,GAEzEK,IAAa,OAAOF,EAAS,SAAS,QAAQ,IAAI,eAAe,KAAK,CAAC;AA4B7E,SACE,gBAAAf,EAAC,aAAQ,WAAAI,GACP,UAAA,gBAAAJ;AAAA,
|
|
1
|
+
{"version":3,"file":"LocationsList.js","sources":["../../../../../src/components/Company/Locations/LocationsList/LocationsList.tsx"],"sourcesContent":["import { useLocationsGetSuspense } from '@gusto/embedded-api/react-query/locationsGet'\nimport { useState } from 'react'\nimport { Head } from './Head'\nimport { List } from './List'\nimport { Actions } from './Actions'\nimport { LocationsListProvider } from './useLocationsList'\nimport { useI18n } from '@/i18n'\nimport { BaseComponent, type BaseComponentInterface } from '@/components/Base/Base'\nimport { useBase } from '@/components/Base/useBase'\nimport { Flex } from '@/components/Common'\nimport { companyEvents } from '@/shared/constants'\nimport type { PaginationItemsPerPage } from '@/components/Common/PaginationControl/PaginationControlTypes'\n\ninterface LocationsListProps extends BaseComponentInterface {\n companyId: string\n}\n\nexport function LocationsList(props: LocationsListProps) {\n return (\n <BaseComponent {...props}>\n <Root {...props}>{props.children}</Root>\n </BaseComponent>\n )\n}\n\nfunction Root({ companyId, className, children }: LocationsListProps) {\n useI18n('Company.Locations')\n const { onEvent } = useBase()\n\n const [currentPage, setCurrentPage] = useState(1)\n const [itemsPerPage, setItemsPerPage] = useState<PaginationItemsPerPage>(5)\n\n const {\n data: { locationList, httpMeta },\n } = useLocationsGetSuspense({ companyId, page: currentPage, per: itemsPerPage })\n\n const totalPages = Number(httpMeta.response.headers.get('x-total-pages') ?? 1)\n const totalCount = Number(httpMeta.response.headers.get('x-total-count') ?? 0)\n\n const handleItemsPerPageChange = (newCount: PaginationItemsPerPage) => {\n setItemsPerPage(newCount)\n }\n const handleFirstPage = () => {\n setCurrentPage(1)\n }\n const handlePreviousPage = () => {\n setCurrentPage(prevPage => Math.max(prevPage - 1, 1))\n }\n const handleNextPage = () => {\n setCurrentPage(prevPage => Math.min(prevPage + 1, totalPages))\n }\n const handleLastPage = () => {\n setCurrentPage(totalPages)\n }\n\n const handleContinue = () => {\n onEvent(companyEvents.COMPANY_LOCATION_DONE)\n }\n const handleAddLocation = () => {\n onEvent(companyEvents.COMPANY_LOCATION_CREATE)\n }\n const handleEditLocation = (uuid: string) => {\n onEvent(companyEvents.COMPANY_LOCATION_EDIT, { uuid })\n }\n\n return (\n <section className={className}>\n <LocationsListProvider\n value={{\n locationList: locationList ?? [],\n currentPage,\n totalPages,\n totalCount,\n handleFirstPage,\n handlePreviousPage,\n handleNextPage,\n handleLastPage,\n handleItemsPerPageChange,\n handleAddLocation,\n handleEditLocation,\n handleContinue,\n itemsPerPage,\n }}\n >\n <Flex flexDirection=\"column\" gap={32}>\n {children ? (\n children\n ) : (\n <>\n <Head />\n <List />\n <Actions />\n </>\n )}\n </Flex>\n </LocationsListProvider>\n </section>\n )\n}\n"],"names":["LocationsList","props","jsx","BaseComponent","Root","companyId","className","children","useI18n","onEvent","useBase","currentPage","setCurrentPage","useState","itemsPerPage","setItemsPerPage","locationList","httpMeta","useLocationsGetSuspense","totalPages","totalCount","LocationsListProvider","prevPage","newCount","companyEvents","uuid","Flex","jsxs","Fragment","Head","List","Actions"],"mappings":";;;;;;;;;;;;;;;AAiBO,SAASA,EAAcC,GAA2B;AACvD,SACE,gBAAAC,EAACC,GAAA,EAAe,GAAGF,GACjB,UAAA,gBAAAC,EAACE,KAAM,GAAGH,GAAQ,UAAAA,EAAM,SAAA,CAAS,EAAA,CACnC;AAEJ;AAEA,SAASG,EAAK,EAAE,WAAAC,GAAW,WAAAC,GAAW,UAAAC,KAAgC;AACpE,EAAAC,EAAQ,mBAAmB;AAC3B,QAAM,EAAE,SAAAC,EAAA,IAAYC,EAAA,GAEd,CAACC,GAAaC,CAAc,IAAIC,EAAS,CAAC,GAC1C,CAACC,GAAcC,CAAe,IAAIF,EAAiC,CAAC,GAEpE;AAAA,IACJ,MAAM,EAAE,cAAAG,GAAc,UAAAC,EAAA;AAAA,EAAS,IAC7BC,EAAwB,EAAE,WAAAb,GAAW,MAAMM,GAAa,KAAKG,GAAc,GAEzEK,IAAa,OAAOF,EAAS,SAAS,QAAQ,IAAI,eAAe,KAAK,CAAC,GACvEG,IAAa,OAAOH,EAAS,SAAS,QAAQ,IAAI,eAAe,KAAK,CAAC;AA4B7E,SACE,gBAAAf,EAAC,aAAQ,WAAAI,GACP,UAAA,gBAAAJ;AAAA,IAACmB;AAAA,IAAA;AAAA,MACC,OAAO;AAAA,QACL,cAAcL,KAAgB,CAAA;AAAA,QAC9B,aAAAL;AAAA,QACA,YAAAQ;AAAA,QACA,YAAAC;AAAA,QACA,iBA/BgB,MAAM;AAC5B,UAAAR,EAAe,CAAC;AAAA,QAClB;AAAA,QA8BQ,oBA7BmB,MAAM;AAC/B,UAAAA,EAAe,OAAY,KAAK,IAAIU,IAAW,GAAG,CAAC,CAAC;AAAA,QACtD;AAAA,QA4BQ,gBA3Be,MAAM;AAC3B,UAAAV,EAAe,OAAY,KAAK,IAAIU,IAAW,GAAGH,CAAU,CAAC;AAAA,QAC/D;AAAA,QA0BQ,gBAzBe,MAAM;AAC3B,UAAAP,EAAeO,CAAU;AAAA,QAC3B;AAAA,QAwBQ,0BAtCyB,CAACI,MAAqC;AACrE,UAAAR,EAAgBQ,CAAQ;AAAA,QAC1B;AAAA,QAqCQ,mBApBkB,MAAM;AAC9B,UAAAd,EAAQe,EAAc,uBAAuB;AAAA,QAC/C;AAAA,QAmBQ,oBAlBmB,CAACC,MAAiB;AAC3C,UAAAhB,EAAQe,EAAc,uBAAuB,EAAE,MAAAC,EAAA,CAAM;AAAA,QACvD;AAAA,QAiBQ,gBAzBe,MAAM;AAC3B,UAAAhB,EAAQe,EAAc,qBAAqB;AAAA,QAC7C;AAAA,QAwBQ,cAAAV;AAAA,MAAA;AAAA,MAGF,UAAA,gBAAAZ,EAACwB,KAAK,eAAc,UAAS,KAAK,IAC/B,UAAAnB,KAGC,gBAAAoB,EAAAC,GAAA,EACE,UAAA;AAAA,QAAA,gBAAA1B,EAAC2B,GAAA,EAAK;AAAA,0BACLC,GAAA,EAAK;AAAA,0BACLC,GAAA,CAAA,CAAQ;AAAA,MAAA,EAAA,CACX,EAAA,CAEJ;AAAA,IAAA;AAAA,EAAA,GAEJ;AAEJ;"}
|
|
@@ -3,6 +3,7 @@ import { PaginationItemsPerPage } from '../../../Common/PaginationControl/Pagina
|
|
|
3
3
|
type LocationsListContextType = {
|
|
4
4
|
locationList: Location[];
|
|
5
5
|
totalPages: number;
|
|
6
|
+
totalCount: number;
|
|
6
7
|
currentPage: number;
|
|
7
8
|
itemsPerPage: PaginationItemsPerPage;
|
|
8
9
|
handleItemsPerPageChange: (n: PaginationItemsPerPage) => void;
|
|
@@ -9,13 +9,14 @@ import "../../../Base/useBase.js";
|
|
|
9
9
|
import "../../../../shared/constants.js";
|
|
10
10
|
import "classnames";
|
|
11
11
|
import "../../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
12
|
+
import "../../../../contexts/LoadingIndicatorProvider/useLoadingIndicator.js";
|
|
12
13
|
import "dompurify";
|
|
13
14
|
import { createCompoundContext as o } from "../../../Base/createCompoundContext.js";
|
|
14
|
-
const [
|
|
15
|
+
const [d, f] = o(
|
|
15
16
|
"CompanyDocumentListContext"
|
|
16
17
|
);
|
|
17
18
|
export {
|
|
18
|
-
|
|
19
|
-
|
|
19
|
+
f as LocationsListProvider,
|
|
20
|
+
d as useLocationsList
|
|
20
21
|
};
|
|
21
22
|
//# sourceMappingURL=useLocationsList.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useLocationsList.js","sources":["../../../../../src/components/Company/Locations/LocationsList/useLocationsList.ts"],"sourcesContent":["import { type Location } from '@gusto/embedded-api/models/components/location'\nimport { createCompoundContext } from '@/components/Base'\nimport type { PaginationItemsPerPage } from '@/components/Common/PaginationControl/PaginationControlTypes'\n\ntype LocationsListContextType = {\n locationList: Location[]\n totalPages: number\n currentPage: number\n itemsPerPage: PaginationItemsPerPage\n handleItemsPerPageChange: (n: PaginationItemsPerPage) => void\n handleFirstPage: () => void\n handlePreviousPage: () => void\n handleNextPage: () => void\n handleLastPage: () => void\n handleEditLocation: (uuid: string) => void\n handleAddLocation: () => void\n handleContinue: () => void\n}\n\nconst [useLocationsList, LocationsListProvider] = createCompoundContext<LocationsListContextType>(\n 'CompanyDocumentListContext',\n)\n\nexport { useLocationsList, LocationsListProvider }\n"],"names":["useLocationsList","LocationsListProvider","createCompoundContext"],"mappings":"
|
|
1
|
+
{"version":3,"file":"useLocationsList.js","sources":["../../../../../src/components/Company/Locations/LocationsList/useLocationsList.ts"],"sourcesContent":["import { type Location } from '@gusto/embedded-api/models/components/location'\nimport { createCompoundContext } from '@/components/Base'\nimport type { PaginationItemsPerPage } from '@/components/Common/PaginationControl/PaginationControlTypes'\n\ntype LocationsListContextType = {\n locationList: Location[]\n totalPages: number\n totalCount: number\n currentPage: number\n itemsPerPage: PaginationItemsPerPage\n handleItemsPerPageChange: (n: PaginationItemsPerPage) => void\n handleFirstPage: () => void\n handlePreviousPage: () => void\n handleNextPage: () => void\n handleLastPage: () => void\n handleEditLocation: (uuid: string) => void\n handleAddLocation: () => void\n handleContinue: () => void\n}\n\nconst [useLocationsList, LocationsListProvider] = createCompoundContext<LocationsListContextType>(\n 'CompanyDocumentListContext',\n)\n\nexport { useLocationsList, LocationsListProvider }\n"],"names":["useLocationsList","LocationsListProvider","createCompoundContext"],"mappings":";;;;;;;;;;;;;;AAoBA,MAAM,CAACA,GAAkBC,CAAqB,IAAIC;AAAA,EAChD;AACF;"}
|
|
@@ -9,11 +9,12 @@ import "../../Base/useBase.js";
|
|
|
9
9
|
import "../../../shared/constants.js";
|
|
10
10
|
import "classnames";
|
|
11
11
|
import "../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
12
|
+
import "../../../contexts/LoadingIndicatorProvider/useLoadingIndicator.js";
|
|
12
13
|
import "dompurify";
|
|
13
14
|
import { createCompoundContext as o } from "../../Base/createCompoundContext.js";
|
|
14
|
-
const [
|
|
15
|
+
const [x, C] = o("OnboardingOverviewContext");
|
|
15
16
|
export {
|
|
16
|
-
|
|
17
|
-
|
|
17
|
+
C as OnboardingOverviewProvider,
|
|
18
|
+
x as useOnboardingOverview
|
|
18
19
|
};
|
|
19
20
|
//# sourceMappingURL=context.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"context.js","sources":["../../../../src/components/Company/OnboardingOverview/context.ts"],"sourcesContent":["import type { OnboardingStep } from '@gusto/embedded-api/models/components/companyonboardingstatus'\nimport { createCompoundContext } from '@/components/Base'\n\ntype OnboardingOverviewContextType = {\n onboardingCompleted?: boolean\n onboardingSteps?: OnboardingStep[]\n handleDone: () => void\n handleContinue: () => void\n}\n\nconst [useOnboardingOverview, OnboardingOverviewProvider] =\n createCompoundContext<OnboardingOverviewContextType>('OnboardingOverviewContext')\n\nexport { useOnboardingOverview, OnboardingOverviewProvider }\n"],"names":["useOnboardingOverview","OnboardingOverviewProvider","createCompoundContext"],"mappings":"
|
|
1
|
+
{"version":3,"file":"context.js","sources":["../../../../src/components/Company/OnboardingOverview/context.ts"],"sourcesContent":["import type { OnboardingStep } from '@gusto/embedded-api/models/components/companyonboardingstatus'\nimport { createCompoundContext } from '@/components/Base'\n\ntype OnboardingOverviewContextType = {\n onboardingCompleted?: boolean\n onboardingSteps?: OnboardingStep[]\n handleDone: () => void\n handleContinue: () => void\n}\n\nconst [useOnboardingOverview, OnboardingOverviewProvider] =\n createCompoundContext<OnboardingOverviewContextType>('OnboardingOverviewContext')\n\nexport { useOnboardingOverview, OnboardingOverviewProvider }\n"],"names":["useOnboardingOverview","OnboardingOverviewProvider","createCompoundContext"],"mappings":";;;;;;;;;;;;;;AAUA,MAAM,CAACA,GAAuBC,CAA0B,IACtDC,EAAqD,2BAA2B;"}
|
|
@@ -7,22 +7,22 @@ import l from "./Edit.module.scss.js";
|
|
|
7
7
|
import { Flex as y } from "../../../Common/Flex/Flex.js";
|
|
8
8
|
import { Grid as x } from "../../../Common/Grid/Grid.js";
|
|
9
9
|
import "classnames";
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
10
|
+
import { useComponentContext as E } from "../../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
11
|
+
import { useDateFormatter as N } from "../../../../hooks/useDateFormatter.js";
|
|
12
|
+
import { TextInputField as F } from "../../../Common/Fields/TextInputField/TextInputField.js";
|
|
13
|
+
import { SelectField as R } from "../../../Common/Fields/SelectField/SelectField.js";
|
|
14
|
+
import { RadioGroupField as O } from "../../../Common/Fields/RadioGroupField/RadioGroupField.js";
|
|
15
|
+
import { NumberInputField as h } from "../../../Common/Fields/NumberInputField/NumberInputField.js";
|
|
16
|
+
import { DatePickerField as f } from "../../../Common/Fields/DatePickerField/DatePickerField.js";
|
|
17
17
|
const K = () => {
|
|
18
|
-
const o =
|
|
18
|
+
const o = E(), { t: e } = C("Company.PaySchedule"), P = N(), { payPeriodPreview: r, mode: u, payPreviewLoading: D } = T(), { setValue: d } = q(), [a, v] = g(0), i = p({ name: "frequency" }), n = p({ name: "customTwicePerMonth" }), b = i === "Twice per month" && n === "custom" || i === "Monthly", w = i === "Twice per month" && n === "custom";
|
|
19
19
|
return S(() => {
|
|
20
20
|
i === "Twice per month" && n === "1st15th" && (d("day1", 15), d("day2", 31));
|
|
21
21
|
}, [i, n, d]), u !== "EDIT_PAY_SCHEDULE" && u !== "ADD_PAY_SCHEDULE" ? null : /* @__PURE__ */ t("div", { className: l.payScheduleContainer, children: /* @__PURE__ */ m(x, { gap: 32, gridTemplateColumns: { base: "1fr", small: "1fr 1fr" }, children: [
|
|
22
22
|
/* @__PURE__ */ t("div", { className: l.payScheduleForm, children: /* @__PURE__ */ m(y, { flexDirection: "column", children: [
|
|
23
|
-
/* @__PURE__ */ t(
|
|
23
|
+
/* @__PURE__ */ t(F, { name: "customName", label: e("labels.name"), isRequired: !0 }),
|
|
24
24
|
/* @__PURE__ */ t(
|
|
25
|
-
|
|
25
|
+
R,
|
|
26
26
|
{
|
|
27
27
|
name: "frequency",
|
|
28
28
|
label: e("labels.frequency"),
|
|
@@ -36,7 +36,7 @@ const K = () => {
|
|
|
36
36
|
}
|
|
37
37
|
),
|
|
38
38
|
i === "Twice per month" && /* @__PURE__ */ t(
|
|
39
|
-
|
|
39
|
+
O,
|
|
40
40
|
{
|
|
41
41
|
name: "customTwicePerMonth",
|
|
42
42
|
label: e("labels.frequencyOptions"),
|
|
@@ -48,7 +48,7 @@ const K = () => {
|
|
|
48
48
|
}
|
|
49
49
|
),
|
|
50
50
|
/* @__PURE__ */ t(
|
|
51
|
-
|
|
51
|
+
f,
|
|
52
52
|
{
|
|
53
53
|
name: "anchorPayDate",
|
|
54
54
|
label: e("labels.firstPayDate"),
|
|
@@ -57,7 +57,7 @@ const K = () => {
|
|
|
57
57
|
}
|
|
58
58
|
),
|
|
59
59
|
/* @__PURE__ */ t(
|
|
60
|
-
|
|
60
|
+
f,
|
|
61
61
|
{
|
|
62
62
|
name: "anchorEndOfPayPeriod",
|
|
63
63
|
label: e("labels.firstPayPeriodEndDate"),
|
|
@@ -65,8 +65,8 @@ const K = () => {
|
|
|
65
65
|
isRequired: !0
|
|
66
66
|
}
|
|
67
67
|
),
|
|
68
|
-
/* @__PURE__ */ t("div", { className: b ? "" : l.visuallyHidden, children: /* @__PURE__ */ t(
|
|
69
|
-
/* @__PURE__ */ t("div", { className: w ? "" : l.visuallyHidden, children: /* @__PURE__ */ t(
|
|
68
|
+
/* @__PURE__ */ t("div", { className: b ? "" : l.visuallyHidden, children: /* @__PURE__ */ t(h, { name: "day1", label: e("labels.firstPayDayOfTheMonth"), isRequired: !0 }) }),
|
|
69
|
+
/* @__PURE__ */ t("div", { className: w ? "" : l.visuallyHidden, children: /* @__PURE__ */ t(h, { name: "day2", label: e("labels.lastPayDayOfTheMonth"), isRequired: !0 }) })
|
|
70
70
|
] }) }),
|
|
71
71
|
/* @__PURE__ */ t(y, { flexDirection: "column", gap: 4, justifyContent: "center", alignItems: "center", children: r && r[a] ? /* @__PURE__ */ m("div", { className: l.calendarContainer, children: [
|
|
72
72
|
!D && /* @__PURE__ */ t(
|
|
@@ -10,9 +10,10 @@ import "../../Base/useBase.js";
|
|
|
10
10
|
import "../../../shared/constants.js";
|
|
11
11
|
import "classnames";
|
|
12
12
|
import "../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
13
|
+
import "../../../contexts/LoadingIndicatorProvider/useLoadingIndicator.js";
|
|
13
14
|
import "dompurify";
|
|
14
15
|
import { createCompoundContext as t } from "../../Base/createCompoundContext.js";
|
|
15
|
-
const
|
|
16
|
+
const x = o.object({
|
|
16
17
|
frequency: o.enum(["Every week", "Every other week", "Twice per month", "Monthly"]),
|
|
17
18
|
anchorPayDate: o.date().optional(),
|
|
18
19
|
anchorEndOfPayPeriod: o.date().optional(),
|
|
@@ -20,10 +21,10 @@ const s = o.object({
|
|
|
20
21
|
day2: o.number().min(1).max(31).optional(),
|
|
21
22
|
customName: o.string().optional(),
|
|
22
23
|
customTwicePerMonth: o.string().optional()
|
|
23
|
-
}), [
|
|
24
|
+
}), [S, f] = t("PayScheduleContext");
|
|
24
25
|
export {
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
26
|
+
f as PayScheduleProvider,
|
|
27
|
+
x as PayScheduleSchema,
|
|
28
|
+
S as usePaySchedule
|
|
28
29
|
};
|
|
29
30
|
//# sourceMappingURL=usePaySchedule.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"usePaySchedule.js","sources":["../../../../src/components/Company/PaySchedule/usePaySchedule.ts"],"sourcesContent":["import type { PayScheduleCreateUpdate } from '@gusto/embedded-api/models/components/payschedulecreateupdate'\nimport type { PayScheduleList } from '@gusto/embedded-api/models/components/payschedulelist'\nimport type { PayScheduleObject as PayScheduleType } from '@gusto/embedded-api/models/components/payscheduleobject'\nimport type { PayPeriods } from '@gusto/embedded-api/models/operations/getv1companiescompanyidpayschedulespreview'\nimport { z } from 'zod'\nimport type { RequireAtLeastOne } from '@/types/Helpers'\nimport { createCompoundContext } from '@/components/Base'\n\nexport type MODE =\n | 'LIST_PAY_SCHEDULES'\n | 'ADD_PAY_SCHEDULE'\n | 'EDIT_PAY_SCHEDULE'\n | 'PREVIEW_PAY_SCHEDULE'\n\ntype PayScheduleContextType = {\n companyId: string\n handleAdd: () => void\n handleEdit: (schedule: PayScheduleType) => void\n handleCancel: () => void\n handleContinue: () => void\n mode: MODE\n paySchedules: PayScheduleList[] | undefined | null\n currentPaySchedule: PayScheduleType | undefined | null\n payPeriodPreview?: PayPeriods[]\n payPreviewLoading?: boolean\n}\n\nexport const PayScheduleSchema = z.object({\n frequency: z.enum(['Every week', 'Every other week', 'Twice per month', 'Monthly']),\n anchorPayDate: z.date().optional(),\n anchorEndOfPayPeriod: z.date().optional(),\n day1: z.number().min(1).max(31).optional(),\n day2: z.number().min(1).max(31).optional(),\n customName: z.string().optional(),\n customTwicePerMonth: z.string().optional(),\n})\n\nexport type PayScheduleInputs = z.input<typeof PayScheduleSchema>\nexport type PayScheduleOutputs = z.output<typeof PayScheduleSchema>\n\nexport type PayScheduleDefaultValues = RequireAtLeastOne<\n Partial<\n Pick<\n PayScheduleCreateUpdate,\n 'anchorPayDate' | 'anchorEndOfPayPeriod' | 'day1' | 'day2' | 'customName' | 'frequency'\n >\n >\n>\n\nconst [usePaySchedule, PayScheduleProvider] =\n createCompoundContext<PayScheduleContextType>('PayScheduleContext')\nexport { usePaySchedule, PayScheduleProvider }\n"],"names":["PayScheduleSchema","z","usePaySchedule","PayScheduleProvider","createCompoundContext"],"mappings":"
|
|
1
|
+
{"version":3,"file":"usePaySchedule.js","sources":["../../../../src/components/Company/PaySchedule/usePaySchedule.ts"],"sourcesContent":["import type { PayScheduleCreateUpdate } from '@gusto/embedded-api/models/components/payschedulecreateupdate'\nimport type { PayScheduleList } from '@gusto/embedded-api/models/components/payschedulelist'\nimport type { PayScheduleObject as PayScheduleType } from '@gusto/embedded-api/models/components/payscheduleobject'\nimport type { PayPeriods } from '@gusto/embedded-api/models/operations/getv1companiescompanyidpayschedulespreview'\nimport { z } from 'zod'\nimport type { RequireAtLeastOne } from '@/types/Helpers'\nimport { createCompoundContext } from '@/components/Base'\n\nexport type MODE =\n | 'LIST_PAY_SCHEDULES'\n | 'ADD_PAY_SCHEDULE'\n | 'EDIT_PAY_SCHEDULE'\n | 'PREVIEW_PAY_SCHEDULE'\n\ntype PayScheduleContextType = {\n companyId: string\n handleAdd: () => void\n handleEdit: (schedule: PayScheduleType) => void\n handleCancel: () => void\n handleContinue: () => void\n mode: MODE\n paySchedules: PayScheduleList[] | undefined | null\n currentPaySchedule: PayScheduleType | undefined | null\n payPeriodPreview?: PayPeriods[]\n payPreviewLoading?: boolean\n}\n\nexport const PayScheduleSchema = z.object({\n frequency: z.enum(['Every week', 'Every other week', 'Twice per month', 'Monthly']),\n anchorPayDate: z.date().optional(),\n anchorEndOfPayPeriod: z.date().optional(),\n day1: z.number().min(1).max(31).optional(),\n day2: z.number().min(1).max(31).optional(),\n customName: z.string().optional(),\n customTwicePerMonth: z.string().optional(),\n})\n\nexport type PayScheduleInputs = z.input<typeof PayScheduleSchema>\nexport type PayScheduleOutputs = z.output<typeof PayScheduleSchema>\n\nexport type PayScheduleDefaultValues = RequireAtLeastOne<\n Partial<\n Pick<\n PayScheduleCreateUpdate,\n 'anchorPayDate' | 'anchorEndOfPayPeriod' | 'day1' | 'day2' | 'customName' | 'frequency'\n >\n >\n>\n\nconst [usePaySchedule, PayScheduleProvider] =\n createCompoundContext<PayScheduleContextType>('PayScheduleContext')\nexport { usePaySchedule, PayScheduleProvider }\n"],"names":["PayScheduleSchema","z","usePaySchedule","PayScheduleProvider","createCompoundContext"],"mappings":";;;;;;;;;;;;;;;AA2BO,MAAMA,IAAoBC,EAAE,OAAO;AAAA,EACxC,WAAWA,EAAE,KAAK,CAAC,cAAc,oBAAoB,mBAAmB,SAAS,CAAC;AAAA,EAClF,eAAeA,EAAE,KAAA,EAAO,SAAA;AAAA,EACxB,sBAAsBA,EAAE,KAAA,EAAO,SAAA;AAAA,EAC/B,MAAMA,EAAE,OAAA,EAAS,IAAI,CAAC,EAAE,IAAI,EAAE,EAAE,SAAA;AAAA,EAChC,MAAMA,EAAE,OAAA,EAAS,IAAI,CAAC,EAAE,IAAI,EAAE,EAAE,SAAA;AAAA,EAChC,YAAYA,EAAE,OAAA,EAAS,SAAA;AAAA,EACvB,qBAAqBA,EAAE,OAAA,EAAS,SAAA;AAClC,CAAC,GAcK,CAACC,GAAgBC,CAAmB,IACxCC,EAA8C,oBAAoB;"}
|
|
@@ -9,11 +9,12 @@ import "../../../Base/useBase.js";
|
|
|
9
9
|
import "../../../../shared/constants.js";
|
|
10
10
|
import "classnames";
|
|
11
11
|
import "../../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
12
|
+
import "../../../../contexts/LoadingIndicatorProvider/useLoadingIndicator.js";
|
|
12
13
|
import "dompurify";
|
|
13
14
|
import { createCompoundContext as t } from "../../../Base/createCompoundContext.js";
|
|
14
|
-
const [
|
|
15
|
+
const [c, d] = t("StateTaxesFormContext");
|
|
15
16
|
export {
|
|
16
|
-
|
|
17
|
-
|
|
17
|
+
d as StateTaxesFormProvider,
|
|
18
|
+
c as useStateTaxesForm
|
|
18
19
|
};
|
|
19
20
|
//# sourceMappingURL=context.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"context.js","sources":["../../../../../src/components/Company/StateTaxes/StateTaxesForm/context.ts"],"sourcesContent":["import type { TaxRequirementsState } from '@gusto/embedded-api/models/components/taxrequirementsstate'\nimport { createCompoundContext } from '@/components/Base'\n\ninterface StateTaxFormContext {\n isPending: boolean\n state: string\n stateTaxRequirements: TaxRequirementsState\n handleCancel: () => void\n}\n\nconst [useStateTaxesForm, StateTaxesFormProvider] =\n createCompoundContext<StateTaxFormContext>('StateTaxesFormContext')\n\nexport { useStateTaxesForm, StateTaxesFormProvider }\n"],"names":["useStateTaxesForm","StateTaxesFormProvider","createCompoundContext"],"mappings":"
|
|
1
|
+
{"version":3,"file":"context.js","sources":["../../../../../src/components/Company/StateTaxes/StateTaxesForm/context.ts"],"sourcesContent":["import type { TaxRequirementsState } from '@gusto/embedded-api/models/components/taxrequirementsstate'\nimport { createCompoundContext } from '@/components/Base'\n\ninterface StateTaxFormContext {\n isPending: boolean\n state: string\n stateTaxRequirements: TaxRequirementsState\n handleCancel: () => void\n}\n\nconst [useStateTaxesForm, StateTaxesFormProvider] =\n createCompoundContext<StateTaxFormContext>('StateTaxesFormContext')\n\nexport { useStateTaxesForm, StateTaxesFormProvider }\n"],"names":["useStateTaxesForm","StateTaxesFormProvider","createCompoundContext"],"mappings":";;;;;;;;;;;;;;AAUA,MAAM,CAACA,GAAmBC,CAAsB,IAC9CC,EAA2C,uBAAuB;"}
|
|
@@ -9,11 +9,12 @@ import "../../../Base/useBase.js";
|
|
|
9
9
|
import "../../../../shared/constants.js";
|
|
10
10
|
import "classnames";
|
|
11
11
|
import "../../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
12
|
+
import "../../../../contexts/LoadingIndicatorProvider/useLoadingIndicator.js";
|
|
12
13
|
import "dompurify";
|
|
13
14
|
import { createCompoundContext as t } from "../../../Base/createCompoundContext.js";
|
|
14
|
-
const [
|
|
15
|
+
const [c, d] = t("StateTaxesListContext");
|
|
15
16
|
export {
|
|
16
|
-
|
|
17
|
-
|
|
17
|
+
d as StateTaxesListProvider,
|
|
18
|
+
c as useStateTaxesList
|
|
18
19
|
};
|
|
19
20
|
//# sourceMappingURL=context.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"context.js","sources":["../../../../../src/components/Company/StateTaxes/StateTaxesList/context.ts"],"sourcesContent":["import type { ResponseBody } from '@gusto/embedded-api/models/operations/getv1companiescompanyuuidtaxrequirements'\nimport { createCompoundContext } from '@/components/Base'\n\ntype StateTaxesListContextType = {\n isPending: boolean\n stateTaxRequirements: ResponseBody[]\n handleContinue: () => void\n handleChange: (state: string) => void\n}\n\nconst [useStateTaxesList, StateTaxesListProvider] =\n createCompoundContext<StateTaxesListContextType>('StateTaxesListContext')\n\nexport { useStateTaxesList, StateTaxesListProvider }\n"],"names":["useStateTaxesList","StateTaxesListProvider","createCompoundContext"],"mappings":"
|
|
1
|
+
{"version":3,"file":"context.js","sources":["../../../../../src/components/Company/StateTaxes/StateTaxesList/context.ts"],"sourcesContent":["import type { ResponseBody } from '@gusto/embedded-api/models/operations/getv1companiescompanyuuidtaxrequirements'\nimport { createCompoundContext } from '@/components/Base'\n\ntype StateTaxesListContextType = {\n isPending: boolean\n stateTaxRequirements: ResponseBody[]\n handleContinue: () => void\n handleChange: (state: string) => void\n}\n\nconst [useStateTaxesList, StateTaxesListProvider] =\n createCompoundContext<StateTaxesListContextType>('StateTaxesListContext')\n\nexport { useStateTaxesList, StateTaxesListProvider }\n"],"names":["useStateTaxesList","StateTaxesListProvider","createCompoundContext"],"mappings":";;;;;;;;;;;;;;AAUA,MAAM,CAACA,GAAmBC,CAAsB,IAC9CC,EAAiD,uBAAuB;"}
|
|
@@ -3,9 +3,9 @@ import { useTranslation as s } from "react-i18next";
|
|
|
3
3
|
import { STATES_ABBR as o } from "../../../shared/constants.js";
|
|
4
4
|
import { Grid as l } from "../../Common/Grid/Grid.js";
|
|
5
5
|
import "classnames";
|
|
6
|
-
import { TextInputField as t } from "../../Common/Fields/TextInputField/TextInputField.js";
|
|
7
6
|
import "../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
8
7
|
import "react";
|
|
8
|
+
import { TextInputField as t } from "../../Common/Fields/TextInputField/TextInputField.js";
|
|
9
9
|
import { SelectField as m } from "../../Common/Fields/SelectField/SelectField.js";
|
|
10
10
|
function T() {
|
|
11
11
|
const { t: e } = s("Contractor.Address");
|
|
@@ -10,20 +10,21 @@ import "../../Base/useBase.js";
|
|
|
10
10
|
import "../../../shared/constants.js";
|
|
11
11
|
import "classnames";
|
|
12
12
|
import "../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
13
|
+
import "../../../contexts/LoadingIndicatorProvider/useLoadingIndicator.js";
|
|
13
14
|
import "dompurify";
|
|
14
15
|
import { createCompoundContext as r } from "../../Base/createCompoundContext.js";
|
|
15
|
-
const
|
|
16
|
+
const u = t.object({
|
|
16
17
|
street1: t.string().min(1),
|
|
17
18
|
street2: t.string().optional(),
|
|
18
19
|
city: t.string().min(1),
|
|
19
20
|
state: t.string().min(1),
|
|
20
21
|
zip: t.string().min(1)
|
|
21
|
-
}), [
|
|
22
|
+
}), [z, b] = r(
|
|
22
23
|
"ContractorAddressContext"
|
|
23
24
|
);
|
|
24
25
|
export {
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
26
|
+
u as AddressFormSchema,
|
|
27
|
+
b as AddressProvider,
|
|
28
|
+
z as useAddress
|
|
28
29
|
};
|
|
29
30
|
//# sourceMappingURL=useAddress.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useAddress.js","sources":["../../../../src/components/Contractor/Address/useAddress.ts"],"sourcesContent":["import type { Contractor, ContractorType } from '@gusto/embedded-api/models/components/contractor'\nimport type { ContractorAddress } from '@gusto/embedded-api/models/components/contractoraddress'\nimport { z } from 'zod'\nimport { createCompoundContext } from '@/components/Base'\nimport type { RequireAtLeastOne } from '@/types/Helpers'\n\nexport interface AddressContextType {\n contractor?: Contractor\n contractorType?: ContractorType\n address?: ContractorAddress\n isPending: boolean\n}\n\nexport type AddressDefaultValues = RequireAtLeastOne<\n Pick<ContractorAddress, 'street1' | 'street2' | 'city' | 'state' | 'zip'>\n>\n\nexport const AddressFormSchema = z.object({\n street1: z.string().min(1),\n street2: z.string().optional(),\n city: z.string().min(1),\n state: z.string().min(1),\n zip: z.string().min(1),\n})\n\nexport type AddressFormValues = z.infer<typeof AddressFormSchema>\n\nconst [useAddress, AddressProvider] = createCompoundContext<AddressContextType>(\n 'ContractorAddressContext',\n)\n\nexport { useAddress, AddressProvider }\n"],"names":["AddressFormSchema","z","useAddress","AddressProvider","createCompoundContext"],"mappings":"
|
|
1
|
+
{"version":3,"file":"useAddress.js","sources":["../../../../src/components/Contractor/Address/useAddress.ts"],"sourcesContent":["import type { Contractor, ContractorType } from '@gusto/embedded-api/models/components/contractor'\nimport type { ContractorAddress } from '@gusto/embedded-api/models/components/contractoraddress'\nimport { z } from 'zod'\nimport { createCompoundContext } from '@/components/Base'\nimport type { RequireAtLeastOne } from '@/types/Helpers'\n\nexport interface AddressContextType {\n contractor?: Contractor\n contractorType?: ContractorType\n address?: ContractorAddress\n isPending: boolean\n}\n\nexport type AddressDefaultValues = RequireAtLeastOne<\n Pick<ContractorAddress, 'street1' | 'street2' | 'city' | 'state' | 'zip'>\n>\n\nexport const AddressFormSchema = z.object({\n street1: z.string().min(1),\n street2: z.string().optional(),\n city: z.string().min(1),\n state: z.string().min(1),\n zip: z.string().min(1),\n})\n\nexport type AddressFormValues = z.infer<typeof AddressFormSchema>\n\nconst [useAddress, AddressProvider] = createCompoundContext<AddressContextType>(\n 'ContractorAddressContext',\n)\n\nexport { useAddress, AddressProvider }\n"],"names":["AddressFormSchema","z","useAddress","AddressProvider","createCompoundContext"],"mappings":";;;;;;;;;;;;;;;AAiBO,MAAMA,IAAoBC,EAAE,OAAO;AAAA,EACxC,SAASA,EAAE,SAAS,IAAI,CAAC;AAAA,EACzB,SAASA,EAAE,OAAA,EAAS,SAAA;AAAA,EACpB,MAAMA,EAAE,SAAS,IAAI,CAAC;AAAA,EACtB,OAAOA,EAAE,SAAS,IAAI,CAAC;AAAA,EACvB,KAAKA,EAAE,OAAA,EAAS,IAAI,CAAC;AACvB,CAAC,GAIK,CAACC,GAAYC,CAAe,IAAIC;AAAA,EACpC;AACF;"}
|