@gusto/embedded-react-sdk 0.55.7 → 0.55.8
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 +23 -0
- package/dist/components/Common/FadeIn/FadeIn.module.scss.js +4 -4
- package/dist/components/Common/FieldCaption/FieldCaption.js +22 -18
- package/dist/components/Common/FieldCaption/FieldCaption.js.map +1 -1
- package/dist/components/Common/Flex/Flex.js +17 -15
- package/dist/components/Common/Flex/Flex.js.map +1 -1
- package/dist/components/Common/UI/Breadcrumbs/Breadcrumbs.js +1 -1
- package/dist/components/Common/UI/FileInput/FileInput.js +1 -1
- package/dist/components/Common/UI/Heading/Heading.module.scss.js +7 -7
- package/dist/components/Common/UI/ProgressBar/ProgressBar.js +4 -4
- package/dist/components/Company/AssignSignatory/CreateSignatory/useCreateSignatory.js +5 -4
- package/dist/components/Company/AssignSignatory/CreateSignatory/useCreateSignatory.js.map +1 -1
- package/dist/components/Company/AssignSignatory/InviteSignatory/useInviteSignatory.js +5 -4
- package/dist/components/Company/AssignSignatory/InviteSignatory/useInviteSignatory.js.map +1 -1
- package/dist/components/Company/AssignSignatory/useAssignSignatory.js +7 -6
- package/dist/components/Company/AssignSignatory/useAssignSignatory.js.map +1 -1
- package/dist/components/Company/BankAccount/BankAccountForm/context.js +5 -4
- package/dist/components/Company/BankAccount/BankAccountForm/context.js.map +1 -1
- package/dist/components/Company/DocumentSigner/DocumentList/useDocumentList.js +5 -4
- package/dist/components/Company/DocumentSigner/DocumentList/useDocumentList.js.map +1 -1
- package/dist/components/Company/DocumentSigner/SignatureForm/SignatureForm.js +27 -27
- package/dist/components/Company/DocumentSigner/SignatureForm/SignatureForm.js.map +1 -1
- package/dist/components/Company/FederalTaxes/useFederalTaxes.js +10 -9
- package/dist/components/Company/FederalTaxes/useFederalTaxes.js.map +1 -1
- package/dist/components/Company/Industry/Context.js +8 -7
- package/dist/components/Company/Industry/Context.js.map +1 -1
- package/dist/components/Company/Locations/LocationForm/useLocationForm.js +5 -4
- package/dist/components/Company/Locations/LocationForm/useLocationForm.js.map +1 -1
- package/dist/components/Company/Locations/LocationsList/useLocationsList.js +5 -4
- package/dist/components/Company/Locations/LocationsList/useLocationsList.js.map +1 -1
- package/dist/components/Company/OnboardingOverview/context.js +5 -4
- package/dist/components/Company/OnboardingOverview/context.js.map +1 -1
- package/dist/components/Company/PaySchedule/PaySchedule.js +45 -30
- package/dist/components/Company/PaySchedule/PaySchedule.js.map +1 -1
- package/dist/components/Company/PaySchedule/PayScheduleComponents.js +12 -11
- package/dist/components/Company/PaySchedule/PayScheduleComponents.js.map +1 -1
- package/dist/components/Company/PaySchedule/PayScheduleForm.js +72 -55
- package/dist/components/Company/PaySchedule/PayScheduleForm.js.map +1 -1
- package/dist/components/Company/PaySchedule/shared/usePayScheduleForm/fields.js +24 -20
- package/dist/components/Company/PaySchedule/shared/usePayScheduleForm/fields.js.map +1 -1
- package/dist/components/Company/PaySchedule/shared/usePayScheduleForm/payScheduleSchema.js +33 -29
- package/dist/components/Company/PaySchedule/shared/usePayScheduleForm/payScheduleSchema.js.map +1 -1
- package/dist/components/Company/PaySchedule/shared/usePayScheduleForm/usePayScheduleForm.js +131 -115
- package/dist/components/Company/PaySchedule/shared/usePayScheduleForm/usePayScheduleForm.js.map +1 -1
- package/dist/components/Company/StateTaxes/StateTaxesForm/context.js +5 -4
- package/dist/components/Company/StateTaxes/StateTaxesForm/context.js.map +1 -1
- package/dist/components/Company/StateTaxes/StateTaxesList/context.js +5 -4
- package/dist/components/Company/StateTaxes/StateTaxesList/context.js.map +1 -1
- package/dist/components/Company/StateTaxes/TaxRateManagement/context.js +5 -4
- package/dist/components/Company/StateTaxes/TaxRateManagement/context.js.map +1 -1
- package/dist/components/Contractor/ContractorList/management/ManagementContractorList.js +31 -29
- package/dist/components/Contractor/ContractorList/management/ManagementContractorList.js.map +1 -1
- package/dist/components/Contractor/ContractorList/management/ManagementContractorListView.js +110 -109
- package/dist/components/Contractor/ContractorList/management/ManagementContractorListView.js.map +1 -1
- package/dist/components/Contractor/ContractorList/onboarding/ContractorList.js +21 -19
- package/dist/components/Contractor/ContractorList/onboarding/ContractorList.js.map +1 -1
- package/dist/components/Contractor/ContractorList/onboarding/ContractorListView.js +56 -55
- package/dist/components/Contractor/ContractorList/onboarding/ContractorListView.js.map +1 -1
- package/dist/components/Contractor/Dashboard/Dashboard.js +34 -33
- package/dist/components/Contractor/Dashboard/Dashboard.js.map +1 -1
- package/dist/components/Contractor/Payments/CreateHistoricalPayment/CreateHistoricalPayment.js +117 -115
- package/dist/components/Contractor/Payments/CreateHistoricalPayment/CreateHistoricalPayment.js.map +1 -1
- package/dist/components/Contractor/Payments/CreatePayment/CreatePayment.js +77 -75
- package/dist/components/Contractor/Payments/CreatePayment/CreatePayment.js.map +1 -1
- package/dist/components/Contractor/Payments/CreatePayment/CreatePaymentPresentation.js +44 -43
- package/dist/components/Contractor/Payments/CreatePayment/CreatePaymentPresentation.js.map +1 -1
- package/dist/components/Contractor/Payments/CreatePayment/PreviewPresentation.js +40 -39
- package/dist/components/Contractor/Payments/CreatePayment/PreviewPresentation.js.map +1 -1
- package/dist/components/Contractor/Payments/HistoricalPaymentSummary/HistoricalPaymentSummary.js +35 -29
- package/dist/components/Contractor/Payments/HistoricalPaymentSummary/HistoricalPaymentSummary.js.map +1 -1
- package/dist/components/Contractor/Payments/PaymentHistory/PaymentHistory.js +21 -20
- package/dist/components/Contractor/Payments/PaymentHistory/PaymentHistory.js.map +1 -1
- package/dist/components/Contractor/Payments/PaymentHistory/PaymentHistoryPresentation.js +41 -40
- package/dist/components/Contractor/Payments/PaymentHistory/PaymentHistoryPresentation.js.map +1 -1
- package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatement.js +21 -20
- package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatement.js.map +1 -1
- package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatementPresentation.js +33 -32
- package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatementPresentation.js.map +1 -1
- package/dist/components/Contractor/Payments/PaymentsList/PaymentsList.js +80 -78
- package/dist/components/Contractor/Payments/PaymentsList/PaymentsList.js.map +1 -1
- package/dist/components/Contractor/Payments/PaymentsList/PaymentsListPresentation.js +44 -43
- package/dist/components/Contractor/Payments/PaymentsList/PaymentsListPresentation.js.map +1 -1
- package/dist/components/Contractor/Submit/Submit.js +113 -105
- package/dist/components/Contractor/Submit/Submit.js.map +1 -1
- package/dist/components/Contractor/Submit/SubmitDone.js +11 -11
- package/dist/components/Contractor/Submit/SubmitDone.js.map +1 -1
- package/dist/components/Employee/Compensation/management/CompensationAddJobForm/CompensationAddJobForm.js +20 -18
- package/dist/components/Employee/Compensation/management/CompensationAddJobForm/CompensationAddJobForm.js.map +1 -1
- package/dist/components/Employee/Compensation/management/CompensationEditForm/CompensationEditForm.js +18 -15
- package/dist/components/Employee/Compensation/management/CompensationEditForm/CompensationEditForm.js.map +1 -1
- package/dist/components/Employee/Dashboard/Dashboard.js +33 -32
- package/dist/components/Employee/Dashboard/Dashboard.js.map +1 -1
- package/dist/components/Employee/Deductions/management/DeductionsEditForm/DeductionsEditForm.js +21 -19
- package/dist/components/Employee/Deductions/management/DeductionsEditForm/DeductionsEditForm.js.map +1 -1
- package/dist/components/Employee/Documents/management/DocumentManager.js +34 -26
- package/dist/components/Employee/Documents/management/DocumentManager.js.map +1 -1
- package/dist/components/Employee/Documents/onboarding/DocumentSigner/DocumentList/useDocumentList.js +5 -4
- package/dist/components/Employee/Documents/onboarding/DocumentSigner/DocumentList/useDocumentList.js.map +1 -1
- package/dist/components/Employee/Documents/onboarding/DocumentSigner/EmploymentEligibility/EmploymentEligibility.js +30 -29
- package/dist/components/Employee/Documents/onboarding/DocumentSigner/EmploymentEligibility/EmploymentEligibility.js.map +1 -1
- package/dist/components/Employee/Documents/onboarding/DocumentSigner/EmploymentEligibility/EmploymentEligibilityPresentation.js +54 -53
- package/dist/components/Employee/Documents/onboarding/DocumentSigner/EmploymentEligibility/EmploymentEligibilityPresentation.js.map +1 -1
- package/dist/components/Employee/Documents/onboarding/EmployeeDocuments/EmployeeDocuments.js +29 -28
- package/dist/components/Employee/Documents/onboarding/EmployeeDocuments/EmployeeDocuments.js.map +1 -1
- package/dist/components/Employee/Documents/onboarding/EmployeeDocuments/EmployeeDocumentsPresentation.js +16 -15
- package/dist/components/Employee/Documents/onboarding/EmployeeDocuments/EmployeeDocumentsPresentation.js.map +1 -1
- package/dist/components/Employee/EmployeeList/management/ManagementEmployeeList.js +27 -25
- package/dist/components/Employee/EmployeeList/management/ManagementEmployeeList.js.map +1 -1
- package/dist/components/Employee/EmployeeList/management/ManagementEmployeeListView.js +89 -80
- package/dist/components/Employee/EmployeeList/management/ManagementEmployeeListView.js.map +1 -1
- package/dist/components/Employee/EmployeeList/onboarding/EmployeeList.js +22 -20
- package/dist/components/Employee/EmployeeList/onboarding/EmployeeList.js.map +1 -1
- package/dist/components/Employee/EmployeeList/onboarding/EmployeeListView.js +25 -24
- package/dist/components/Employee/EmployeeList/onboarding/EmployeeListView.js.map +1 -1
- package/dist/components/Employee/EmployeeList/shared/useEmployeeList.js +1 -1
- package/dist/components/Employee/EmployeeList/shared/useEmployeeList.js.map +1 -1
- package/dist/components/Employee/FederalTaxes/shared/FederalTaxesView.js +1 -1
- package/dist/components/Employee/HomeAddress/management/HomeAddressEditForm.js +19 -17
- package/dist/components/Employee/HomeAddress/management/HomeAddressEditForm.js.map +1 -1
- package/dist/components/Employee/HomeAddress/management/HomeAddressView.js +80 -79
- package/dist/components/Employee/HomeAddress/management/HomeAddressView.js.map +1 -1
- package/dist/components/Employee/PaymentMethod/management/PaymentMethodBankForm.js +4 -4
- package/dist/components/Employee/PaymentMethod/onboarding/BankForm.js +4 -4
- package/dist/components/Employee/Terminations/TerminateEmployee/TerminateEmployee.js +40 -39
- package/dist/components/Employee/Terminations/TerminateEmployee/TerminateEmployee.js.map +1 -1
- package/dist/components/Employee/Terminations/TerminateEmployee/TerminateEmployeePresentation.js +34 -33
- package/dist/components/Employee/Terminations/TerminateEmployee/TerminateEmployeePresentation.js.map +1 -1
- package/dist/components/Employee/Terminations/TerminationSummary/TerminationSummary.js +43 -41
- package/dist/components/Employee/Terminations/TerminationSummary/TerminationSummary.js.map +1 -1
- package/dist/components/Employee/Terminations/TerminationSummary/TerminationSummaryPresentation.js +22 -21
- package/dist/components/Employee/Terminations/TerminationSummary/TerminationSummaryPresentation.js.map +1 -1
- package/dist/components/Employee/WorkAddress/management/WorkAddressEditForm.js +19 -17
- package/dist/components/Employee/WorkAddress/management/WorkAddressEditForm.js.map +1 -1
- package/dist/components/Employee/WorkAddress/management/WorkAddressView.js +120 -116
- package/dist/components/Employee/WorkAddress/management/WorkAddressView.js.map +1 -1
- package/dist/components/Flow/Flow.js +1 -1
- package/dist/components/InformationRequests/InformationRequestList/InformationRequestList.js +29 -29
- package/dist/components/InformationRequests/InformationRequestList/InformationRequestList.js.map +1 -1
- package/dist/components/Payroll/ConfirmWireDetails/ConfirmWireDetails.js +37 -36
- package/dist/components/Payroll/ConfirmWireDetails/ConfirmWireDetails.js.map +1 -1
- package/dist/components/Payroll/ConfirmWireDetails/ConfirmWireDetailsBanner/ConfirmWireDetailsBanner.js +37 -36
- package/dist/components/Payroll/ConfirmWireDetails/ConfirmWireDetailsBanner/ConfirmWireDetailsBanner.js.map +1 -1
- package/dist/components/Payroll/Dismissal/DismissalPayPeriodSelection/DismissalPayPeriodSelection.js +35 -28
- package/dist/components/Payroll/Dismissal/DismissalPayPeriodSelection/DismissalPayPeriodSelection.js.map +1 -1
- package/dist/components/Payroll/Dismissal/DismissalPayPeriodSelection/DismissalPayPeriodSelectionPresentation.js +27 -26
- package/dist/components/Payroll/Dismissal/DismissalPayPeriodSelection/DismissalPayPeriodSelectionPresentation.js.map +1 -1
- package/dist/components/Payroll/GrossUpModal/GrossUpModal.js +2 -3
- package/dist/components/Payroll/GrossUpModal/GrossUpModal.js.map +1 -1
- package/dist/components/Payroll/OffCycleCreation/OffCycleCreation.js +52 -51
- package/dist/components/Payroll/OffCycleCreation/OffCycleCreation.js.map +1 -1
- package/dist/components/Payroll/OffCycleCreation/OffCycleCreationPresentation.js +34 -33
- package/dist/components/Payroll/OffCycleCreation/OffCycleCreationPresentation.js.map +1 -1
- package/dist/components/Payroll/OffCycleDeductionsSetting/OffCycleDeductionsSetting.js +23 -21
- package/dist/components/Payroll/OffCycleDeductionsSetting/OffCycleDeductionsSetting.js.map +1 -1
- package/dist/components/Payroll/OffCycleReasonSelection/OffCycleReasonSelection.js +26 -19
- package/dist/components/Payroll/OffCycleReasonSelection/OffCycleReasonSelection.js.map +1 -1
- package/dist/components/Payroll/OffCycleReasonSelection/OffCycleReasonSelectionPresentation.js +14 -12
- package/dist/components/Payroll/OffCycleReasonSelection/OffCycleReasonSelectionPresentation.js.map +1 -1
- package/dist/components/Payroll/PayrollConfiguration/PayrollConfiguration.js +112 -109
- package/dist/components/Payroll/PayrollConfiguration/PayrollConfiguration.js.map +1 -1
- package/dist/components/Payroll/PayrollConfiguration/PayrollConfigurationPresentation.js +67 -65
- package/dist/components/Payroll/PayrollConfiguration/PayrollConfigurationPresentation.js.map +1 -1
- package/dist/components/Payroll/PayrollEditEmployee/PayrollEditEmployee.js +43 -41
- package/dist/components/Payroll/PayrollEditEmployee/PayrollEditEmployee.js.map +1 -1
- package/dist/components/Payroll/PayrollEditEmployee/PayrollEditEmployeePresentation.js +225 -223
- package/dist/components/Payroll/PayrollEditEmployee/PayrollEditEmployeePresentation.js.map +1 -1
- package/dist/components/Payroll/PayrollEditEmployee/shared/usePayrollEditEmployeeForm/fields.js +78 -75
- package/dist/components/Payroll/PayrollEditEmployee/shared/usePayrollEditEmployeeForm/fields.js.map +1 -1
- package/dist/components/Payroll/PayrollEditEmployee/shared/usePayrollEditEmployeeForm/payrollEditEmployeeHelpers.js +27 -27
- package/dist/components/Payroll/PayrollEditEmployee/shared/usePayrollEditEmployeeForm/payrollEditEmployeeHelpers.js.map +1 -1
- package/dist/components/Payroll/PayrollEditEmployee/shared/usePayrollEditEmployeeForm/payrollEditEmployeeSchema.js +19 -19
- package/dist/components/Payroll/PayrollEditEmployee/shared/usePayrollEditEmployeeForm/payrollEditEmployeeSchema.js.map +1 -1
- package/dist/components/Payroll/PayrollEditEmployee/shared/usePayrollEditEmployeeForm/usePayrollEditEmployeeForm.js +51 -48
- package/dist/components/Payroll/PayrollEditEmployee/shared/usePayrollEditEmployeeForm/usePayrollEditEmployeeForm.js.map +1 -1
- package/dist/components/Payroll/PayrollHistory/PayrollHistory.js +58 -48
- package/dist/components/Payroll/PayrollHistory/PayrollHistory.js.map +1 -1
- package/dist/components/Payroll/PayrollHistory/PayrollHistoryPresentation.js +58 -57
- package/dist/components/Payroll/PayrollHistory/PayrollHistoryPresentation.js.map +1 -1
- package/dist/components/Payroll/PayrollLanding/PayrollLandingFlowComponents.js +83 -69
- package/dist/components/Payroll/PayrollLanding/PayrollLandingFlowComponents.js.map +1 -1
- package/dist/components/Payroll/PayrollList/PayrollList.js +62 -60
- package/dist/components/Payroll/PayrollList/PayrollList.js.map +1 -1
- package/dist/components/Payroll/PayrollList/PayrollListPresentation.js +119 -117
- package/dist/components/Payroll/PayrollList/PayrollListPresentation.js.map +1 -1
- package/dist/components/Payroll/PayrollOverview/PayrollOverview.js +101 -99
- package/dist/components/Payroll/PayrollOverview/PayrollOverview.js.map +1 -1
- package/dist/components/Payroll/PayrollOverview/PayrollOverviewPresentation.js +120 -110
- package/dist/components/Payroll/PayrollOverview/PayrollOverviewPresentation.js.map +1 -1
- package/dist/components/Payroll/PayrollReceipts/PayrollReceipts.js +20 -14
- package/dist/components/Payroll/PayrollReceipts/PayrollReceipts.js.map +1 -1
- package/dist/components/Payroll/PayrollReceipts/PayrollReceiptsPresentation.js +39 -38
- package/dist/components/Payroll/PayrollReceipts/PayrollReceiptsPresentation.js.map +1 -1
- package/dist/components/Payroll/PrintChecks/PrintChecksBanner/PrintChecksBanner.js +24 -17
- package/dist/components/Payroll/PrintChecks/PrintChecksBanner/PrintChecksBanner.js.map +1 -1
- package/dist/components/Payroll/PrintChecks/PrintChecksFailure/PrintChecksFailure.js +17 -17
- package/dist/components/Payroll/PrintChecks/PrintChecksFailure/PrintChecksFailure.js.map +1 -1
- package/dist/components/Payroll/PrintChecks/PrintChecksForm/PrintChecksForm.js +88 -80
- package/dist/components/Payroll/PrintChecks/PrintChecksForm/PrintChecksForm.js.map +1 -1
- package/dist/components/Payroll/PrintChecks/PrintChecksSummary/PrintChecksSummary.js +26 -26
- package/dist/components/Payroll/PrintChecks/PrintChecksSummary/PrintChecksSummary.js.map +1 -1
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesResubmit/RecoveryCasesResubmit.js +32 -32
- package/dist/components/Payroll/RecoveryCases/RecoveryCasesResubmit/RecoveryCasesResubmit.js.map +1 -1
- package/dist/components/Payroll/TransitionCreation/TransitionCreation.js +50 -48
- package/dist/components/Payroll/TransitionCreation/TransitionCreation.js.map +1 -1
- package/dist/components/Payroll/TransitionCreation/TransitionCreationPresentation.js +34 -33
- package/dist/components/Payroll/TransitionCreation/TransitionCreationPresentation.js.map +1 -1
- package/dist/components/Payroll/TransitionCreation/TransitionCreationTypes.js.map +1 -1
- package/dist/components/Payroll/TransitionPayrollAlert/TransitionPayrollAlert.js +28 -24
- package/dist/components/Payroll/TransitionPayrollAlert/TransitionPayrollAlert.js.map +1 -1
- package/dist/components/Payroll/UNSTABLE_PayrollEditEmployee/UNSTABLE_PayrollEditEmployee.js +255 -228
- package/dist/components/Payroll/UNSTABLE_PayrollEditEmployee/UNSTABLE_PayrollEditEmployee.js.map +1 -1
- package/dist/components/Payroll/UNSTABLE_PayrollEditEmployee/UNSTABLE_PayrollEditEmployee.module.scss.js +8 -4
- package/dist/components/Payroll/UNSTABLE_PayrollEditEmployee/UNSTABLE_PayrollEditEmployee.module.scss.js.map +1 -1
- package/dist/components/Payroll/usePreparedPayrollData.js +4 -3
- package/dist/components/Payroll/usePreparedPayrollData.js.map +1 -1
- package/dist/components/TimeOff/AddEmployeesHoliday/AddEmployeesHoliday.js +5 -5
- package/dist/components/TimeOff/AddEmployeesHoliday/AddEmployeesHoliday.js.map +1 -1
- package/dist/components/TimeOff/AddEmployeesToPolicy/AddEmployeesToPolicy.js +8 -7
- package/dist/components/TimeOff/AddEmployeesToPolicy/AddEmployeesToPolicy.js.map +1 -1
- package/dist/components/TimeOff/HolidayPolicyDetail/HolidayPolicyDetail.js +51 -50
- package/dist/components/TimeOff/HolidayPolicyDetail/HolidayPolicyDetail.js.map +1 -1
- package/dist/components/TimeOff/HolidayPolicyDetail/HolidayPolicyDetailPresentation.js +20 -18
- package/dist/components/TimeOff/HolidayPolicyDetail/HolidayPolicyDetailPresentation.js.map +1 -1
- package/dist/components/TimeOff/HolidaySelectionForm/HolidaySelectionForm.js +51 -49
- package/dist/components/TimeOff/HolidaySelectionForm/HolidaySelectionForm.js.map +1 -1
- package/dist/components/TimeOff/HolidaySelectionForm/HolidaySelectionFormPresentation.js +20 -20
- package/dist/components/TimeOff/HolidaySelectionForm/HolidaySelectionFormPresentation.js.map +1 -1
- package/dist/components/TimeOff/PolicyList/PolicyList.js +50 -49
- package/dist/components/TimeOff/PolicyList/PolicyList.js.map +1 -1
- package/dist/components/TimeOff/PolicyList/PolicyListPresentation.js +34 -33
- package/dist/components/TimeOff/PolicyList/PolicyListPresentation.js.map +1 -1
- package/dist/components/TimeOff/PolicySettings/PolicySettings.js +46 -45
- package/dist/components/TimeOff/PolicySettings/PolicySettings.js.map +1 -1
- package/dist/components/TimeOff/PolicySettings/PolicySettingsPresentation.js +152 -143
- package/dist/components/TimeOff/PolicySettings/PolicySettingsPresentation.js.map +1 -1
- package/dist/components/TimeOff/PolicyTypeSelector/PolicyTypeSelector.js +14 -13
- package/dist/components/TimeOff/PolicyTypeSelector/PolicyTypeSelector.js.map +1 -1
- package/dist/components/TimeOff/PolicyTypeSelector/PolicyTypeSelectorPresentation.js +44 -35
- package/dist/components/TimeOff/PolicyTypeSelector/PolicyTypeSelectorPresentation.js.map +1 -1
- package/dist/components/TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationForm.js +88 -71
- package/dist/components/TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationForm.js.map +1 -1
- package/dist/components/TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationFormPresentation.js +164 -155
- package/dist/components/TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationFormPresentation.js.map +1 -1
- package/dist/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesHoliday.js +57 -55
- package/dist/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesHoliday.js.map +1 -1
- package/dist/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesPresentation.js +25 -24
- package/dist/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesPresentation.js.map +1 -1
- package/dist/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesTimeOff.js +94 -92
- package/dist/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesTimeOff.js.map +1 -1
- package/dist/components/TimeOff/TimeOffPolicyDetail/TimeOffPolicyDetail.js +156 -155
- package/dist/components/TimeOff/TimeOffPolicyDetail/TimeOffPolicyDetail.js.map +1 -1
- package/dist/components/TimeOff/TimeOffPolicyDetail/TimeOffPolicyDetailPresentation.js +21 -19
- package/dist/components/TimeOff/TimeOffPolicyDetail/TimeOffPolicyDetailPresentation.js.map +1 -1
- package/dist/components/TimeOff/shared/PolicyDetailLayout/PolicyDetailLayout.js +28 -26
- package/dist/components/TimeOff/shared/PolicyDetailLayout/PolicyDetailLayout.js.map +1 -1
- package/dist/contexts/ComponentAdapter/useComponentContext.js.map +1 -1
- package/dist/contexts/UnstableFeaturesProvider/useUnstableFeature.js.map +1 -1
- package/dist/i18n/en/Company.PaySchedule.json.js +22 -20
- package/dist/i18n/en/Company.PaySchedule.json.js.map +1 -1
- package/dist/i18n/en/Payroll.UNSTABLE_PayrollEditEmployee.json.js +62 -58
- package/dist/i18n/en/Payroll.UNSTABLE_PayrollEditEmployee.json.js.map +1 -1
- package/dist/package.json.js +1 -1
- package/dist/src/components/Common/FieldCaption/FieldCaption.d.ts +2 -16
- package/dist/src/components/Common/FieldCaption/FieldCaptionTypes.d.ts +22 -0
- package/dist/src/components/Common/FieldCaption/index.d.ts +1 -0
- package/dist/src/components/Common/Flex/Flex.d.ts +3 -1
- package/dist/src/components/Company/PaySchedule/PaySchedule.d.ts +10 -2
- package/dist/src/components/Company/PaySchedule/PayScheduleComponents.d.ts +1 -0
- package/dist/src/components/Company/PaySchedule/shared/usePayScheduleForm/fields.d.ts +9 -1
- package/dist/src/components/Company/PaySchedule/shared/usePayScheduleForm/index.d.ts +2 -2
- package/dist/src/components/Company/PaySchedule/shared/usePayScheduleForm/payScheduleSchema.d.ts +21 -5
- package/dist/src/components/Company/PaySchedule/shared/usePayScheduleForm/usePayScheduleForm.d.ts +21 -3
- package/dist/src/components/Contractor/ContractorList/management/ManagementContractorListView.d.ts +3 -1
- package/dist/src/components/Contractor/ContractorList/onboarding/ContractorListView.d.ts +3 -1
- package/dist/src/components/Contractor/Payments/CreatePayment/CreatePaymentPresentation.d.ts +3 -1
- package/dist/src/components/Contractor/Payments/CreatePayment/PreviewPresentation.d.ts +3 -1
- package/dist/src/components/Contractor/Payments/PaymentHistory/PaymentHistoryPresentation.d.ts +3 -1
- package/dist/src/components/Contractor/Payments/PaymentStatement/PaymentStatementPresentation.d.ts +3 -1
- package/dist/src/components/Contractor/Payments/PaymentsList/PaymentsListPresentation.d.ts +3 -1
- package/dist/src/components/Contractor/Submit/SubmitDone.d.ts +3 -1
- package/dist/src/components/Employee/Compensation/management/CompensationEditForm/CompensationEditForm.d.ts +1 -1
- package/dist/src/components/Employee/Documents/onboarding/DocumentSigner/EmploymentEligibility/EmploymentEligibilityPresentation.d.ts +3 -1
- package/dist/src/components/Employee/Documents/onboarding/EmployeeDocuments/EmployeeDocumentsPresentation.d.ts +3 -1
- package/dist/src/components/Employee/EmployeeList/management/ManagementEmployeeListView.d.ts +3 -1
- package/dist/src/components/Employee/EmployeeList/onboarding/EmployeeListView.d.ts +3 -1
- package/dist/src/components/Employee/EmployeeList/shared/useEmployeeList.d.ts +4 -0
- package/dist/src/components/Employee/HomeAddress/management/HomeAddressView.d.ts +3 -1
- package/dist/src/components/Employee/Terminations/TerminateEmployee/TerminateEmployeePresentation.d.ts +3 -1
- package/dist/src/components/Employee/Terminations/TerminationSummary/TerminationSummaryPresentation.d.ts +3 -1
- package/dist/src/components/Employee/WorkAddress/management/WorkAddressView.d.ts +3 -1
- package/dist/src/components/Payroll/Dismissal/DismissalPayPeriodSelection/DismissalPayPeriodSelectionPresentation.d.ts +3 -1
- package/dist/src/components/Payroll/OffCycleCreation/OffCycleCreationPresentation.d.ts +1 -1
- package/dist/src/components/Payroll/OffCycleCreation/OffCycleCreationTypes.d.ts +2 -0
- package/dist/src/components/Payroll/OffCycleReasonSelection/OffCycleReasonSelectionPresentation.d.ts +3 -1
- package/dist/src/components/Payroll/PayrollConfiguration/PayrollConfigurationPresentation.d.ts +3 -1
- package/dist/src/components/Payroll/PayrollEditEmployee/PayrollEditEmployeePresentation.d.ts +3 -1
- package/dist/src/components/Payroll/PayrollEditEmployee/shared/usePayrollEditEmployeeForm/fields.d.ts +9 -9
- package/dist/src/components/Payroll/PayrollEditEmployee/shared/usePayrollEditEmployeeForm/payrollEditEmployeeHelpers.d.ts +2 -2
- package/dist/src/components/Payroll/PayrollEditEmployee/shared/usePayrollEditEmployeeForm/payrollEditEmployeeSchema.d.ts +4 -4
- package/dist/src/components/Payroll/PayrollHistory/PayrollHistoryPresentation.d.ts +3 -1
- package/dist/src/components/Payroll/PayrollList/PayrollListPresentation.d.ts +3 -1
- package/dist/src/components/Payroll/PayrollOverview/PayrollOverviewPresentation.d.ts +2 -1
- package/dist/src/components/Payroll/PayrollReceipts/PayrollReceiptsPresentation.d.ts +2 -1
- package/dist/src/components/Payroll/TransitionCreation/TransitionCreationPresentation.d.ts +1 -1
- package/dist/src/components/Payroll/TransitionCreation/TransitionCreationTypes.d.ts +2 -0
- package/dist/src/components/Payroll/TransitionPayrollAlert/TransitionPayrollAlert.d.ts +3 -1
- package/dist/src/components/Payroll/UNSTABLE_PayrollEditEmployee/UNSTABLE_PayrollEditEmployee.d.ts +1 -1
- package/dist/src/components/TimeOff/AddEmployeesHoliday/AddEmployeesHoliday.d.ts +1 -1
- package/dist/src/components/TimeOff/AddEmployeesToPolicy/AddEmployeesToPolicy.d.ts +1 -1
- package/dist/src/components/TimeOff/HolidayPolicyDetail/HolidayPolicyDetailPresentation.d.ts +1 -1
- package/dist/src/components/TimeOff/HolidayPolicyDetail/HolidayPolicyDetailTypes.d.ts +2 -0
- package/dist/src/components/TimeOff/HolidaySelectionForm/HolidaySelectionFormTypes.d.ts +2 -0
- package/dist/src/components/TimeOff/PolicyList/PolicyListPresentation.d.ts +1 -1
- package/dist/src/components/TimeOff/PolicyList/PolicyListTypes.d.ts +2 -0
- package/dist/src/components/TimeOff/PolicySettings/PolicySettingsPresentation.d.ts +1 -1
- package/dist/src/components/TimeOff/PolicySettings/PolicySettingsTypes.d.ts +2 -0
- package/dist/src/components/TimeOff/PolicyTypeSelector/PolicyTypeSelectorPresentation.d.ts +1 -1
- package/dist/src/components/TimeOff/PolicyTypeSelector/PolicyTypeSelectorTypes.d.ts +2 -0
- package/dist/src/components/TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationFormPresentation.d.ts +1 -1
- package/dist/src/components/TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationFormTypes.d.ts +2 -0
- package/dist/src/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesHoliday.d.ts +2 -0
- package/dist/src/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesPresentation.d.ts +1 -1
- package/dist/src/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesPresentationTypes.d.ts +2 -0
- package/dist/src/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesTimeOff.d.ts +2 -0
- package/dist/src/components/TimeOff/TimeOffPolicyDetail/TimeOffPolicyDetailPresentation.d.ts +1 -1
- package/dist/src/components/TimeOff/TimeOffPolicyDetail/TimeOffPolicyDetailTypes.d.ts +3 -0
- package/dist/src/components/TimeOff/shared/PolicyDetailLayout/PolicyDetailLayout.d.ts +1 -1
- package/dist/src/components/TimeOff/shared/PolicyDetailLayout/PolicyDetailLayoutTypes.d.ts +2 -0
- package/dist/src/contexts/ComponentAdapter/componentAdapterTypes.d.ts +1 -0
- package/dist/src/contexts/ComponentAdapter/useComponentContext.d.ts +4 -1
- package/dist/src/contexts/UnstableFeaturesProvider/useUnstableFeature.d.ts +4 -1
- package/dist/src/i18n/types.d.ts +28 -2
- package/dist/src/index.d.ts +1 -1
- package/dist/src/models/external.d.ts +1 -0
- package/dist/style.css +1 -1
- package/package.json +16 -15
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z as o } from "zod";
|
|
2
|
-
import { FilingForm as r, TaxPayerType as
|
|
2
|
+
import { FilingForm as r, TaxPayerType as t } from "@gusto/embedded-api/models/components/federaltaxdetails";
|
|
3
3
|
import "react/jsx-runtime";
|
|
4
4
|
import "react";
|
|
5
5
|
import "react-error-boundary";
|
|
@@ -11,21 +11,22 @@ import "@gusto/embedded-api/models/errors/gustoembeddederror";
|
|
|
11
11
|
import "@gusto/embedded-api/models/errors/sdkvalidationerror";
|
|
12
12
|
import "@gusto/embedded-api/models/errors/unprocessableentityerror";
|
|
13
13
|
import "@gusto/embedded-api/models/errors/httpclienterrors";
|
|
14
|
+
import "dompurify";
|
|
15
|
+
import "../../../contexts/LocaleProvider/useLocale.js";
|
|
14
16
|
import "../../../shared/constants.js";
|
|
15
17
|
import "../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
16
|
-
import "
|
|
17
|
-
|
|
18
|
-
const b = o.object({
|
|
18
|
+
import { createCompoundContext as e } from "../../Base/createCompoundContext.js";
|
|
19
|
+
const j = o.object({
|
|
19
20
|
federalEin: o.string().optional(),
|
|
20
|
-
taxPayerType: o.enum(Object.values(
|
|
21
|
+
taxPayerType: o.enum(Object.values(t)).optional(),
|
|
21
22
|
filingForm: o.enum(Object.values(r)).optional(),
|
|
22
23
|
legalName: o.string().min(1)
|
|
23
|
-
}), [
|
|
24
|
+
}), [v, P] = e(
|
|
24
25
|
"CompanyFederalTaxesContext"
|
|
25
26
|
);
|
|
26
27
|
export {
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
28
|
+
j as FederalTaxFormSchema,
|
|
29
|
+
P as FederalTaxesProvider,
|
|
30
|
+
v as useFederalTaxes
|
|
30
31
|
};
|
|
31
32
|
//# sourceMappingURL=useFederalTaxes.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useFederalTaxes.js","sources":["../../../../src/components/Company/FederalTaxes/useFederalTaxes.ts"],"sourcesContent":["import { z } from 'zod'\nimport type { FederalTaxDetails } from '@gusto/embedded-api/models/components/federaltaxdetails'\nimport { FilingForm, TaxPayerType } from '@gusto/embedded-api/models/components/federaltaxdetails'\nimport { createCompoundContext } from '@/components/Base'\nimport type { RequireAtLeastOne } from '@/types/Helpers'\n\n/** @internal */\nexport const FederalTaxFormSchema = z.object({\n federalEin: z.string().optional(),\n taxPayerType: z.enum(Object.values(TaxPayerType) as [string, ...string[]]).optional(),\n filingForm: z.enum(Object.values(FilingForm) as [string, ...string[]]).optional(),\n legalName: z.string().min(1),\n})\n\n/** @internal */\nexport type FederalTaxFormInputs = z.input<typeof FederalTaxFormSchema>\n\n/**\n * Pre-populated values for the company federal tax form, supplied via {@link FederalTaxesProps}.\n * At least one of `taxPayerType`, `filingForm`, or `legalName` must be provided.\n *\n * @public\n */\nexport type FederalTaxesDefaultValues = RequireAtLeastOne<{\n taxPayerType?: FederalTaxFormInputs['taxPayerType']\n filingForm?: FederalTaxFormInputs['filingForm']\n legalName?: FederalTaxFormInputs['legalName']\n}>\n\ntype FederalTaxesContextType = {\n isPending: boolean\n federalTaxDetails?: FederalTaxDetails\n}\n\nconst [useFederalTaxes, FederalTaxesProvider] = createCompoundContext<FederalTaxesContextType>(\n 'CompanyFederalTaxesContext',\n)\n\nexport { useFederalTaxes, FederalTaxesProvider }\n"],"names":["FederalTaxFormSchema","z","TaxPayerType","FilingForm","useFederalTaxes","FederalTaxesProvider","createCompoundContext"],"mappings":"
|
|
1
|
+
{"version":3,"file":"useFederalTaxes.js","sources":["../../../../src/components/Company/FederalTaxes/useFederalTaxes.ts"],"sourcesContent":["import { z } from 'zod'\nimport type { FederalTaxDetails } from '@gusto/embedded-api/models/components/federaltaxdetails'\nimport { FilingForm, TaxPayerType } from '@gusto/embedded-api/models/components/federaltaxdetails'\nimport { createCompoundContext } from '@/components/Base'\nimport type { RequireAtLeastOne } from '@/types/Helpers'\n\n/** @internal */\nexport const FederalTaxFormSchema = z.object({\n federalEin: z.string().optional(),\n taxPayerType: z.enum(Object.values(TaxPayerType) as [string, ...string[]]).optional(),\n filingForm: z.enum(Object.values(FilingForm) as [string, ...string[]]).optional(),\n legalName: z.string().min(1),\n})\n\n/** @internal */\nexport type FederalTaxFormInputs = z.input<typeof FederalTaxFormSchema>\n\n/**\n * Pre-populated values for the company federal tax form, supplied via {@link FederalTaxesProps}.\n * At least one of `taxPayerType`, `filingForm`, or `legalName` must be provided.\n *\n * @public\n */\nexport type FederalTaxesDefaultValues = RequireAtLeastOne<{\n taxPayerType?: FederalTaxFormInputs['taxPayerType']\n filingForm?: FederalTaxFormInputs['filingForm']\n legalName?: FederalTaxFormInputs['legalName']\n}>\n\ntype FederalTaxesContextType = {\n isPending: boolean\n federalTaxDetails?: FederalTaxDetails\n}\n\nconst [useFederalTaxes, FederalTaxesProvider] = createCompoundContext<FederalTaxesContextType>(\n 'CompanyFederalTaxesContext',\n)\n\nexport { useFederalTaxes, FederalTaxesProvider }\n"],"names":["FederalTaxFormSchema","z","TaxPayerType","FilingForm","useFederalTaxes","FederalTaxesProvider","createCompoundContext"],"mappings":";;;;;;;;;;;;;;;;;;AAOO,MAAMA,IAAuBC,EAAE,OAAO;AAAA,EAC3C,YAAYA,EAAE,OAAA,EAAS,SAAA;AAAA,EACvB,cAAcA,EAAE,KAAK,OAAO,OAAOC,CAAY,CAA0B,EAAE,SAAA;AAAA,EAC3E,YAAYD,EAAE,KAAK,OAAO,OAAOE,CAAU,CAA0B,EAAE,SAAA;AAAA,EACvE,WAAWF,EAAE,OAAA,EAAS,IAAI,CAAC;AAC7B,CAAC,GAsBK,CAACG,GAAiBC,CAAoB,IAAIC;AAAA,EAC9C;AACF;"}
|
|
@@ -9,19 +9,20 @@ import "@gusto/embedded-api/models/errors/gustoembeddederror";
|
|
|
9
9
|
import "@gusto/embedded-api/models/errors/sdkvalidationerror";
|
|
10
10
|
import "@gusto/embedded-api/models/errors/unprocessableentityerror";
|
|
11
11
|
import "@gusto/embedded-api/models/errors/httpclienterrors";
|
|
12
|
+
import "dompurify";
|
|
13
|
+
import "../../../contexts/LocaleProvider/useLocale.js";
|
|
12
14
|
import "../../../shared/constants.js";
|
|
13
15
|
import "../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
14
|
-
import "../../../contexts/LoadingIndicatorProvider/useLoadingIndicator.js";
|
|
15
16
|
import { createCompoundContext as t } from "../../Base/createCompoundContext.js";
|
|
16
|
-
const [
|
|
17
|
+
const [f, v] = t("IndustryItems", {
|
|
17
18
|
items: []
|
|
18
|
-
}), [
|
|
19
|
+
}), [x, C] = t("IndustryApi", {
|
|
19
20
|
isPending: !1
|
|
20
21
|
});
|
|
21
22
|
export {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
23
|
+
C as IndustryApiStateProvider,
|
|
24
|
+
v as IndustryItemsProvider,
|
|
25
|
+
x as useIndustryApiState,
|
|
26
|
+
f as useIndustryItems
|
|
26
27
|
};
|
|
27
28
|
//# sourceMappingURL=Context.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Context.js","sources":["../../../../src/components/Company/Industry/Context.ts"],"sourcesContent":["import { createCompoundContext } from '@/components/Base'\nimport type { ComboBoxOption } from '@/components/Common/UI/ComboBox/ComboBoxTypes'\n\nconst [useIndustryItems, IndustryItemsProvider] = createCompoundContext('IndustryItems', {\n items: [] as ComboBoxOption[],\n})\n\nconst [useIndustryApiState, IndustryApiStateProvider] = createCompoundContext('IndustryApi', {\n isPending: false,\n})\n\nexport { IndustryApiStateProvider, IndustryItemsProvider, useIndustryItems, useIndustryApiState }\n"],"names":["useIndustryItems","IndustryItemsProvider","createCompoundContext","useIndustryApiState","IndustryApiStateProvider"],"mappings":"
|
|
1
|
+
{"version":3,"file":"Context.js","sources":["../../../../src/components/Company/Industry/Context.ts"],"sourcesContent":["import { createCompoundContext } from '@/components/Base'\nimport type { ComboBoxOption } from '@/components/Common/UI/ComboBox/ComboBoxTypes'\n\nconst [useIndustryItems, IndustryItemsProvider] = createCompoundContext('IndustryItems', {\n items: [] as ComboBoxOption[],\n})\n\nconst [useIndustryApiState, IndustryApiStateProvider] = createCompoundContext('IndustryApi', {\n isPending: false,\n})\n\nexport { IndustryApiStateProvider, IndustryItemsProvider, useIndustryItems, useIndustryApiState }\n"],"names":["useIndustryItems","IndustryItemsProvider","createCompoundContext","useIndustryApiState","IndustryApiStateProvider"],"mappings":";;;;;;;;;;;;;;;;AAGA,MAAM,CAACA,GAAkBC,CAAqB,IAAIC,EAAsB,iBAAiB;AAAA,EACvF,OAAO,CAAA;AACT,CAAC,GAEK,CAACC,GAAqBC,CAAwB,IAAIF,EAAsB,eAAe;AAAA,EAC3F,WAAW;AACb,CAAC;"}
|
|
@@ -9,15 +9,16 @@ import "@gusto/embedded-api/models/errors/gustoembeddederror";
|
|
|
9
9
|
import "@gusto/embedded-api/models/errors/sdkvalidationerror";
|
|
10
10
|
import "@gusto/embedded-api/models/errors/unprocessableentityerror";
|
|
11
11
|
import "@gusto/embedded-api/models/errors/httpclienterrors";
|
|
12
|
+
import "dompurify";
|
|
13
|
+
import "../../../../contexts/LocaleProvider/useLocale.js";
|
|
12
14
|
import "../../../../shared/constants.js";
|
|
13
15
|
import "../../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
14
|
-
import "../../../../contexts/LoadingIndicatorProvider/useLoadingIndicator.js";
|
|
15
16
|
import { createCompoundContext as o } from "../../../Base/createCompoundContext.js";
|
|
16
|
-
const [
|
|
17
|
+
const [f, v] = o(
|
|
17
18
|
"CompanyDocumentFormContext"
|
|
18
19
|
);
|
|
19
20
|
export {
|
|
20
|
-
|
|
21
|
-
|
|
21
|
+
v as LocationsFormProvider,
|
|
22
|
+
f as useLocationsForm
|
|
22
23
|
};
|
|
23
24
|
//# 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;"}
|
|
@@ -9,15 +9,16 @@ import "@gusto/embedded-api/models/errors/gustoembeddederror";
|
|
|
9
9
|
import "@gusto/embedded-api/models/errors/sdkvalidationerror";
|
|
10
10
|
import "@gusto/embedded-api/models/errors/unprocessableentityerror";
|
|
11
11
|
import "@gusto/embedded-api/models/errors/httpclienterrors";
|
|
12
|
+
import "dompurify";
|
|
13
|
+
import "../../../../contexts/LocaleProvider/useLocale.js";
|
|
12
14
|
import "../../../../shared/constants.js";
|
|
13
15
|
import "../../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
14
|
-
import "../../../../contexts/LoadingIndicatorProvider/useLoadingIndicator.js";
|
|
15
16
|
import { createCompoundContext as o } from "../../../Base/createCompoundContext.js";
|
|
16
|
-
const [
|
|
17
|
+
const [v, y] = o(
|
|
17
18
|
"CompanyDocumentListContext"
|
|
18
19
|
);
|
|
19
20
|
export {
|
|
20
|
-
|
|
21
|
-
|
|
21
|
+
y as LocationsListProvider,
|
|
22
|
+
v as useLocationsList
|
|
22
23
|
};
|
|
23
24
|
//# 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 totalCount: number\n currentPage: number\n itemsPerPage: PaginationItemsPerPage\n isFetching?: boolean\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 isFetching?: boolean\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":";;;;;;;;;;;;;;;;AAqBA,MAAM,CAACA,GAAkBC,CAAqB,IAAIC;AAAA,EAChD;AACF;"}
|
|
@@ -9,13 +9,14 @@ import "@gusto/embedded-api/models/errors/gustoembeddederror";
|
|
|
9
9
|
import "@gusto/embedded-api/models/errors/sdkvalidationerror";
|
|
10
10
|
import "@gusto/embedded-api/models/errors/unprocessableentityerror";
|
|
11
11
|
import "@gusto/embedded-api/models/errors/httpclienterrors";
|
|
12
|
+
import "dompurify";
|
|
13
|
+
import "../../../contexts/LocaleProvider/useLocale.js";
|
|
12
14
|
import "../../../shared/constants.js";
|
|
13
15
|
import "../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
14
|
-
import "../../../contexts/LoadingIndicatorProvider/useLoadingIndicator.js";
|
|
15
16
|
import { createCompoundContext as o } from "../../Base/createCompoundContext.js";
|
|
16
|
-
const [
|
|
17
|
+
const [c, s] = o("OnboardingOverviewContext");
|
|
17
18
|
export {
|
|
18
|
-
|
|
19
|
-
|
|
19
|
+
s as OnboardingOverviewProvider,
|
|
20
|
+
c as useOnboardingOverview
|
|
20
21
|
};
|
|
21
22
|
//# 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;"}
|
|
@@ -1,43 +1,58 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { useState as
|
|
3
|
-
import { createMachine as
|
|
4
|
-
import { usePaySchedulesGetAllSuspense as
|
|
5
|
-
import { payScheduleStateMachine as
|
|
6
|
-
import { PayScheduleListContextual as
|
|
7
|
-
import { BaseComponent as
|
|
8
|
-
import { useBase as
|
|
9
|
-
import { useI18n as
|
|
10
|
-
import { Flow as
|
|
11
|
-
const
|
|
1
|
+
import { jsx as m } from "react/jsx-runtime";
|
|
2
|
+
import { useState as l, useMemo as p } from "react";
|
|
3
|
+
import { createMachine as h } from "robot3";
|
|
4
|
+
import { usePaySchedulesGetAllSuspense as S } from "@gusto/embedded-api/react-query/paySchedulesGetAll";
|
|
5
|
+
import { payScheduleStateMachine as d } from "./payScheduleStateMachine.js";
|
|
6
|
+
import { PayScheduleListContextual as f, PayScheduleFormContextual as y } from "./PayScheduleComponents.js";
|
|
7
|
+
import { BaseComponent as C } from "../../Base/Base.js";
|
|
8
|
+
import { useBase as P } from "../../Base/useBase.js";
|
|
9
|
+
import { useI18n as x, useComponentDictionary as M } from "../../../i18n/I18n.js";
|
|
10
|
+
import { Flow as B } from "../../Flow/Flow.js";
|
|
11
|
+
const D = ({
|
|
12
12
|
companyId: e,
|
|
13
|
-
defaultValues:
|
|
14
|
-
|
|
13
|
+
defaultValues: o,
|
|
14
|
+
disableWorkweekStartDayEditing: t,
|
|
15
|
+
dictionary: r,
|
|
15
16
|
...i
|
|
16
|
-
}) => /* @__PURE__ */
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
17
|
+
}) => /* @__PURE__ */ m(C, { ...i, children: /* @__PURE__ */ m(
|
|
18
|
+
F,
|
|
19
|
+
{
|
|
20
|
+
companyId: e,
|
|
21
|
+
defaultValues: o,
|
|
22
|
+
disableWorkweekStartDayEditing: t,
|
|
23
|
+
dictionary: r
|
|
24
|
+
}
|
|
25
|
+
) });
|
|
26
|
+
function F({
|
|
27
|
+
companyId: e,
|
|
28
|
+
defaultValues: o,
|
|
29
|
+
disableWorkweekStartDayEditing: t,
|
|
30
|
+
dictionary: r
|
|
31
|
+
}) {
|
|
32
|
+
x("Company.PaySchedule"), M("Company.PaySchedule", r);
|
|
33
|
+
const { onEvent: i } = P(), { data: s } = S({ companyId: e }), [{ initialState: a, initialComponent: c }] = l(() => {
|
|
34
|
+
const n = (s.payScheduleShowResponse?.length ?? 0) > 0;
|
|
21
35
|
return {
|
|
22
|
-
initialState:
|
|
23
|
-
initialComponent:
|
|
36
|
+
initialState: n ? "listSchedules" : "addSchedule",
|
|
37
|
+
initialComponent: n ? f : y
|
|
24
38
|
};
|
|
25
|
-
}),
|
|
26
|
-
() =>
|
|
39
|
+
}), u = p(
|
|
40
|
+
() => h(
|
|
27
41
|
a,
|
|
28
|
-
|
|
29
|
-
(
|
|
30
|
-
...
|
|
31
|
-
component:
|
|
42
|
+
d,
|
|
43
|
+
(n) => ({
|
|
44
|
+
...n,
|
|
45
|
+
component: c,
|
|
32
46
|
companyId: e,
|
|
33
|
-
defaultValues:
|
|
47
|
+
defaultValues: o,
|
|
48
|
+
disableWorkweekStartDayEditing: t
|
|
34
49
|
})
|
|
35
50
|
),
|
|
36
|
-
[e, t, a,
|
|
51
|
+
[e, o, t, a, c]
|
|
37
52
|
);
|
|
38
|
-
return /* @__PURE__ */
|
|
53
|
+
return /* @__PURE__ */ m(B, { machine: u, onEvent: i });
|
|
39
54
|
}
|
|
40
55
|
export {
|
|
41
|
-
|
|
56
|
+
D as PaySchedule
|
|
42
57
|
};
|
|
43
58
|
//# sourceMappingURL=PaySchedule.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PaySchedule.js","sources":["../../../../src/components/Company/PaySchedule/PaySchedule.tsx"],"sourcesContent":["import { useMemo, useState } from 'react'\nimport { createMachine } from 'robot3'\nimport { usePaySchedulesGetAllSuspense } from '@gusto/embedded-api/react-query/paySchedulesGetAll'\nimport { payScheduleStateMachine } from './payScheduleStateMachine'\nimport type { PayScheduleContextInterface } from './PayScheduleComponents'\nimport { PayScheduleFormContextual, PayScheduleListContextual } from './PayScheduleComponents'\nimport type { PayScheduleFormData } from './shared/usePayScheduleForm/payScheduleSchema'\nimport type { BaseComponentInterface } from '@/components/Base'\nimport { BaseComponent, useBase } from '@/components/Base'\nimport type { BaseComponentKeys } from '@/components/Base/Base'\nimport { useI18n } from '@/i18n'\nimport { useComponentDictionary } from '@/i18n/I18n'\nimport { Flow } from '@/components/Flow/Flow'\nimport type { RequireAtLeastOne } from '@/types/Helpers'\n\n/**\n * The full set of fields that may be pre-filled on the {@link PaySchedule} create form.\n *\n * @public\n */\nexport type PayScheduleDefaultFields = {\n [\n K in keyof Pick<\n PayScheduleFormData,\n 'anchorPayDate'
|
|
1
|
+
{"version":3,"file":"PaySchedule.js","sources":["../../../../src/components/Company/PaySchedule/PaySchedule.tsx"],"sourcesContent":["import { useMemo, useState } from 'react'\nimport { createMachine } from 'robot3'\nimport { usePaySchedulesGetAllSuspense } from '@gusto/embedded-api/react-query/paySchedulesGetAll'\nimport { payScheduleStateMachine } from './payScheduleStateMachine'\nimport type { PayScheduleContextInterface } from './PayScheduleComponents'\nimport { PayScheduleFormContextual, PayScheduleListContextual } from './PayScheduleComponents'\nimport type { PayScheduleFormData } from './shared/usePayScheduleForm/payScheduleSchema'\nimport type { BaseComponentInterface } from '@/components/Base'\nimport { BaseComponent, useBase } from '@/components/Base'\nimport type { BaseComponentKeys } from '@/components/Base/Base'\nimport { useI18n } from '@/i18n'\nimport { useComponentDictionary } from '@/i18n/I18n'\nimport { Flow } from '@/components/Flow/Flow'\nimport type { RequireAtLeastOne } from '@/types/Helpers'\n\n/**\n * The full set of fields that may be pre-filled on the {@link PaySchedule} create form.\n *\n * @public\n */\nexport type PayScheduleDefaultFields = {\n [\n K in keyof Pick<\n PayScheduleFormData,\n | 'anchorPayDate'\n | 'anchorEndOfPayPeriod'\n | 'day1'\n | 'day2'\n | 'customName'\n | 'frequency'\n | 'workweekStartDay'\n >\n ]: NonNullable<PayScheduleFormData[K]>\n}\n\n/**\n * Default values for the {@link PaySchedule} form fields. Server data for an existing pay schedule\n * takes precedence over these defaults when editing.\n *\n * @public\n */\nexport type PayScheduleDefaultValues = RequireAtLeastOne<Partial<PayScheduleDefaultFields>>\n\n/**\n * Props for the {@link PaySchedule} component.\n *\n * @public\n */\nexport interface PayScheduleProps extends BaseComponentInterface<'Company.PaySchedule'> {\n /** Identifier of the company whose pay schedules are managed. */\n companyId: string\n /** Default values used to pre-fill the create form. Ignored fields not listed in {@link PayScheduleDefaultValues}. */\n defaultValues?: PayScheduleDefaultValues\n /**\n * Renders the workweek start day field disabled while still submitting its current value,\n * for partners that compute the workweek start day themselves and don't want end users\n * editing it directly. Defaults to `false`.\n *\n * @alpha\n */\n disableWorkweekStartDayEditing?: boolean\n}\n\n/**\n * Manages a company's pay schedules, including listing existing schedules and creating or editing one.\n *\n * @remarks\n * Renders the schedule list when at least one pay schedule exists and the create form otherwise.\n * Emits the following events through `onEvent`:\n *\n * @events\n * | Event | Description | Data |\n * | ----- | ----------- | ---- |\n * | `paySchedule/created` | A new pay schedule was created | The created pay schedule entity |\n * | `paySchedule/updated` | An existing pay schedule was updated | The updated pay schedule entity |\n *\n * @param props - {@link PayScheduleProps} plus the standard base component props.\n * @returns The pay schedule list or form depending on whether any schedules exist.\n * @public\n */\nexport const PaySchedule = ({\n companyId,\n defaultValues,\n disableWorkweekStartDayEditing,\n dictionary,\n ...props\n}: PayScheduleProps) => {\n return (\n <BaseComponent {...props}>\n <Root\n companyId={companyId}\n defaultValues={defaultValues}\n disableWorkweekStartDayEditing={disableWorkweekStartDayEditing}\n dictionary={dictionary}\n />\n </BaseComponent>\n )\n}\n\nfunction Root({\n companyId,\n defaultValues,\n disableWorkweekStartDayEditing,\n dictionary,\n}: Omit<PayScheduleProps, BaseComponentKeys>) {\n useI18n('Company.PaySchedule')\n useComponentDictionary('Company.PaySchedule', dictionary)\n const { onEvent } = useBase()\n const { data: paySchedules } = usePaySchedulesGetAllSuspense({ companyId })\n\n // Freeze the initial routing decision. Recomputing it after a later refetch (e.g. once\n // the first schedule is created) would re-seat the machine and orphan its interpreter.\n const [{ initialState, initialComponent }] = useState<{\n initialState: keyof typeof payScheduleStateMachine\n initialComponent: typeof PayScheduleListContextual | typeof PayScheduleFormContextual\n }>(() => {\n const hasSchedules = (paySchedules.payScheduleShowResponse?.length ?? 0) > 0\n return {\n initialState: hasSchedules ? 'listSchedules' : 'addSchedule',\n initialComponent: hasSchedules ? PayScheduleListContextual : PayScheduleFormContextual,\n }\n })\n\n const machine = useMemo(\n () =>\n createMachine(\n initialState,\n payScheduleStateMachine,\n (initialContext: PayScheduleContextInterface) => ({\n ...initialContext,\n component: initialComponent,\n companyId,\n defaultValues,\n disableWorkweekStartDayEditing,\n }),\n ),\n [companyId, defaultValues, disableWorkweekStartDayEditing, initialState, initialComponent],\n )\n\n return <Flow machine={machine} onEvent={onEvent} />\n}\n"],"names":["PaySchedule","companyId","defaultValues","disableWorkweekStartDayEditing","dictionary","props","jsx","BaseComponent","Root","useI18n","useComponentDictionary","onEvent","useBase","paySchedules","usePaySchedulesGetAllSuspense","initialState","initialComponent","useState","hasSchedules","PayScheduleListContextual","PayScheduleFormContextual","machine","useMemo","createMachine","payScheduleStateMachine","initialContext","Flow"],"mappings":";;;;;;;;;;AAgFO,MAAMA,IAAc,CAAC;AAAA,EAC1B,WAAAC;AAAA,EACA,eAAAC;AAAA,EACA,gCAAAC;AAAA,EACA,YAAAC;AAAA,EACA,GAAGC;AACL,MAEI,gBAAAC,EAACC,GAAA,EAAe,GAAGF,GACjB,UAAA,gBAAAC;AAAA,EAACE;AAAA,EAAA;AAAA,IACC,WAAAP;AAAA,IACA,eAAAC;AAAA,IACA,gCAAAC;AAAA,IACA,YAAAC;AAAA,EAAA;AAAA,GAEJ;AAIJ,SAASI,EAAK;AAAA,EACZ,WAAAP;AAAA,EACA,eAAAC;AAAA,EACA,gCAAAC;AAAA,EACA,YAAAC;AACF,GAA8C;AAC5C,EAAAK,EAAQ,qBAAqB,GAC7BC,EAAuB,uBAAuBN,CAAU;AACxD,QAAM,EAAE,SAAAO,EAAA,IAAYC,EAAA,GACd,EAAE,MAAMC,EAAA,IAAiBC,EAA8B,EAAE,WAAAb,GAAW,GAIpE,CAAC,EAAE,cAAAc,GAAc,kBAAAC,GAAkB,IAAIC,EAG1C,MAAM;AACP,UAAMC,KAAgBL,EAAa,yBAAyB,UAAU,KAAK;AAC3E,WAAO;AAAA,MACL,cAAcK,IAAe,kBAAkB;AAAA,MAC/C,kBAAkBA,IAAeC,IAA4BC;AAAA,IAAA;AAAA,EAEjE,CAAC,GAEKC,IAAUC;AAAA,IACd,MACEC;AAAA,MACER;AAAA,MACAS;AAAA,MACA,CAACC,OAAiD;AAAA,QAChD,GAAGA;AAAA,QACH,WAAWT;AAAA,QACX,WAAAf;AAAA,QACA,eAAAC;AAAA,QACA,gCAAAC;AAAA,MAAA;AAAA,IACF;AAAA,IAEJ,CAACF,GAAWC,GAAeC,GAAgCY,GAAcC,CAAgB;AAAA,EAAA;AAG3F,SAAO,gBAAAV,EAACoB,GAAA,EAAK,SAAAL,GAAkB,SAAAV,EAAA,CAAkB;AACnD;"}
|
|
@@ -1,26 +1,27 @@
|
|
|
1
1
|
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
-
import { PayScheduleList as
|
|
2
|
+
import { PayScheduleList as d } from "./PayScheduleList.js";
|
|
3
3
|
import { PayScheduleForm as c } from "./PayScheduleForm.js";
|
|
4
|
-
import { useFlow as
|
|
5
|
-
import { ensureRequired as
|
|
4
|
+
import { useFlow as r } from "../../Flow/useFlow.js";
|
|
5
|
+
import { ensureRequired as n } from "../../../helpers/ensureRequired.js";
|
|
6
6
|
function f() {
|
|
7
|
-
const { companyId:
|
|
8
|
-
return /* @__PURE__ */ t(
|
|
7
|
+
const { companyId: e, onEvent: o } = r();
|
|
8
|
+
return /* @__PURE__ */ t(d, { onEvent: o, companyId: n(e) });
|
|
9
9
|
}
|
|
10
|
-
function
|
|
11
|
-
const { companyId:
|
|
10
|
+
function S() {
|
|
11
|
+
const { companyId: e, payScheduleId: o, defaultValues: a, disableWorkweekStartDayEditing: m, onEvent: u } = r();
|
|
12
12
|
return /* @__PURE__ */ t(
|
|
13
13
|
c,
|
|
14
14
|
{
|
|
15
|
-
companyId:
|
|
16
|
-
payScheduleId:
|
|
17
|
-
defaultValues:
|
|
15
|
+
companyId: n(e),
|
|
16
|
+
payScheduleId: o,
|
|
17
|
+
defaultValues: a,
|
|
18
|
+
disableWorkweekStartDayEditing: m,
|
|
18
19
|
onEvent: u
|
|
19
20
|
}
|
|
20
21
|
);
|
|
21
22
|
}
|
|
22
23
|
export {
|
|
23
|
-
|
|
24
|
+
S as PayScheduleFormContextual,
|
|
24
25
|
f as PayScheduleListContextual
|
|
25
26
|
};
|
|
26
27
|
//# sourceMappingURL=PayScheduleComponents.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PayScheduleComponents.js","sources":["../../../../src/components/Company/PaySchedule/PayScheduleComponents.tsx"],"sourcesContent":["import type { PayScheduleDefaultValues } from './PaySchedule'\nimport { PayScheduleList } from './PayScheduleList'\nimport { PayScheduleForm } from './PayScheduleForm'\nimport { useFlow, type FlowContextInterface } from '@/components/Flow/useFlow'\nimport { ensureRequired } from '@/helpers/ensureRequired'\n\n/** @internal */\nexport interface PayScheduleContextInterface extends FlowContextInterface {\n companyId: string\n payScheduleId?: string\n defaultValues?: PayScheduleDefaultValues\n component: React.ComponentType | null\n}\n\n/** @internal */\nexport function PayScheduleListContextual() {\n const { companyId, onEvent } = useFlow<PayScheduleContextInterface>()\n return <PayScheduleList onEvent={onEvent} companyId={ensureRequired(companyId)} />\n}\n\n/** @internal */\nexport function PayScheduleFormContextual() {\n const { companyId, payScheduleId, defaultValues, onEvent } =\n useFlow<PayScheduleContextInterface>()\n\n return (\n <PayScheduleForm\n companyId={ensureRequired(companyId)}\n payScheduleId={payScheduleId}\n defaultValues={defaultValues}\n onEvent={onEvent}\n />\n )\n}\n"],"names":["PayScheduleListContextual","companyId","onEvent","useFlow","PayScheduleList","ensureRequired","PayScheduleFormContextual","payScheduleId","defaultValues","jsx","PayScheduleForm"],"mappings":";;;;;
|
|
1
|
+
{"version":3,"file":"PayScheduleComponents.js","sources":["../../../../src/components/Company/PaySchedule/PayScheduleComponents.tsx"],"sourcesContent":["import type { PayScheduleDefaultValues } from './PaySchedule'\nimport { PayScheduleList } from './PayScheduleList'\nimport { PayScheduleForm } from './PayScheduleForm'\nimport { useFlow, type FlowContextInterface } from '@/components/Flow/useFlow'\nimport { ensureRequired } from '@/helpers/ensureRequired'\n\n/** @internal */\nexport interface PayScheduleContextInterface extends FlowContextInterface {\n companyId: string\n payScheduleId?: string\n defaultValues?: PayScheduleDefaultValues\n disableWorkweekStartDayEditing?: boolean\n component: React.ComponentType | null\n}\n\n/** @internal */\nexport function PayScheduleListContextual() {\n const { companyId, onEvent } = useFlow<PayScheduleContextInterface>()\n return <PayScheduleList onEvent={onEvent} companyId={ensureRequired(companyId)} />\n}\n\n/** @internal */\nexport function PayScheduleFormContextual() {\n const { companyId, payScheduleId, defaultValues, disableWorkweekStartDayEditing, onEvent } =\n useFlow<PayScheduleContextInterface>()\n\n return (\n <PayScheduleForm\n companyId={ensureRequired(companyId)}\n payScheduleId={payScheduleId}\n defaultValues={defaultValues}\n disableWorkweekStartDayEditing={disableWorkweekStartDayEditing}\n onEvent={onEvent}\n />\n )\n}\n"],"names":["PayScheduleListContextual","companyId","onEvent","useFlow","PayScheduleList","ensureRequired","PayScheduleFormContextual","payScheduleId","defaultValues","disableWorkweekStartDayEditing","jsx","PayScheduleForm"],"mappings":";;;;;AAgBO,SAASA,IAA4B;AAC1C,QAAM,EAAE,WAAAC,GAAW,SAAAC,EAAA,IAAYC,EAAA;AAC/B,2BAAQC,GAAA,EAAgB,SAAAF,GAAkB,WAAWG,EAAeJ,CAAS,GAAG;AAClF;AAGO,SAASK,IAA4B;AAC1C,QAAM,EAAE,WAAAL,GAAW,eAAAM,GAAe,eAAAC,GAAe,gCAAAC,GAAgC,SAAAP,EAAA,IAC/EC,EAAA;AAEF,SACE,gBAAAO;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,WAAWN,EAAeJ,CAAS;AAAA,MACnC,eAAAM;AAAA,MACA,eAAAC;AAAA,MACA,gCAAAC;AAAA,MACA,SAAAP;AAAA,IAAA;AAAA,EAAA;AAGN;"}
|
|
@@ -1,55 +1,63 @@
|
|
|
1
1
|
import { jsx as a, jsxs as c } from "react/jsx-runtime";
|
|
2
|
-
import { useState as
|
|
3
|
-
import { useTranslation as
|
|
4
|
-
import { usePayScheduleForm as
|
|
5
|
-
import
|
|
6
|
-
import { BaseBoundaries as
|
|
2
|
+
import { useState as R } from "react";
|
|
3
|
+
import { useTranslation as C } from "react-i18next";
|
|
4
|
+
import { usePayScheduleForm as O } from "./shared/usePayScheduleForm/usePayScheduleForm.js";
|
|
5
|
+
import m from "./PayScheduleForm.module.scss.js";
|
|
6
|
+
import { BaseBoundaries as M, BaseLayout as f } from "../../Base/Base.js";
|
|
7
7
|
import "../../Base/useBase.js";
|
|
8
|
-
import { SDKFormProvider as
|
|
9
|
-
import { Form as
|
|
10
|
-
import { Flex as
|
|
8
|
+
import { SDKFormProvider as q } from "../../../partner-hook-utils/form/SDKFormProvider.js";
|
|
9
|
+
import { Form as A } from "../../Common/Form/Form.js";
|
|
10
|
+
import { Flex as u } from "../../Common/Flex/Flex.js";
|
|
11
11
|
import { Grid as L } from "../../Common/Grid/Grid.js";
|
|
12
12
|
import { ActionsLayout as T } from "../../Common/ActionsLayout/ActionsLayout.js";
|
|
13
|
-
import { useComponentContext as
|
|
14
|
-
import { useDateFormatter as
|
|
15
|
-
import { componentEvents as
|
|
13
|
+
import { useComponentContext as F } from "../../../contexts/ComponentAdapter/useComponentContext.js";
|
|
14
|
+
import { useDateFormatter as x } from "../../../hooks/useDateFormatter.js";
|
|
15
|
+
import { componentEvents as D } from "../../../shared/constants.js";
|
|
16
16
|
import { normalizeToDate as N } from "../../../helpers/dateFormatting.js";
|
|
17
|
-
const
|
|
18
|
-
function
|
|
19
|
-
return /* @__PURE__ */ a(
|
|
17
|
+
const p = (l) => N(l.toString());
|
|
18
|
+
function ee({ onEvent: l, LoaderComponent: d, ...h }) {
|
|
19
|
+
return /* @__PURE__ */ a(M, { componentName: "Company.PayScheduleForm", LoaderComponent: d, children: /* @__PURE__ */ a(I, { onEvent: l, LoaderComponent: d, ...h }) });
|
|
20
20
|
}
|
|
21
|
-
function I({ onEvent:
|
|
22
|
-
const { t: e } =
|
|
23
|
-
if (
|
|
21
|
+
function I({ onEvent: l, LoaderComponent: d, ...h }) {
|
|
22
|
+
const { t: e } = C("Company.PaySchedule"), i = F(), P = x(), o = O(h), [n, w] = R(0);
|
|
23
|
+
if (o.isLoading)
|
|
24
24
|
return /* @__PURE__ */ a(
|
|
25
|
-
|
|
25
|
+
f,
|
|
26
26
|
{
|
|
27
27
|
isLoading: !0,
|
|
28
|
-
error:
|
|
28
|
+
error: o.errorHandling.errors,
|
|
29
29
|
LoaderComponent: d
|
|
30
30
|
}
|
|
31
31
|
);
|
|
32
|
-
const
|
|
33
|
-
const t = await
|
|
34
|
-
t &&
|
|
35
|
-
t.mode === "create" ?
|
|
32
|
+
const v = async () => {
|
|
33
|
+
const t = await o.actions.onSubmit();
|
|
34
|
+
t && l(
|
|
35
|
+
t.mode === "create" ? D.PAY_SCHEDULE_CREATED : D.PAY_SCHEDULE_UPDATED,
|
|
36
36
|
{ paySchedule: t.data }
|
|
37
37
|
);
|
|
38
|
-
}, { Fields: r } =
|
|
38
|
+
}, { Fields: r } = o.form, { paymentSpeedDays: S, payPreviewLoading: g } = o.data, s = o.data.payPeriodPreview, b = {
|
|
39
39
|
"Every week": e("frequencies.everyWeek"),
|
|
40
40
|
"Every other week": e("frequencies.everyOtherWeek"),
|
|
41
41
|
"Twice per month": e("frequencies.twicePerMonth"),
|
|
42
42
|
Monthly: e("frequencies.monthly")
|
|
43
|
-
},
|
|
43
|
+
}, k = {
|
|
44
44
|
"1st15th": e("frequencyOptions.15thAndLast"),
|
|
45
45
|
custom: e("frequencyOptions.custom")
|
|
46
|
+
}, E = {
|
|
47
|
+
Sunday: e("workweekStartDayOptions.sunday"),
|
|
48
|
+
Monday: e("workweekStartDayOptions.monday"),
|
|
49
|
+
Tuesday: e("workweekStartDayOptions.tuesday"),
|
|
50
|
+
Wednesday: e("workweekStartDayOptions.wednesday"),
|
|
51
|
+
Thursday: e("workweekStartDayOptions.thursday"),
|
|
52
|
+
Friday: e("workweekStartDayOptions.friday"),
|
|
53
|
+
Saturday: e("workweekStartDayOptions.saturday")
|
|
46
54
|
};
|
|
47
|
-
return /* @__PURE__ */ a(
|
|
48
|
-
|
|
49
|
-
}, children: /* @__PURE__ */ c(
|
|
50
|
-
/* @__PURE__ */ a(
|
|
51
|
-
/* @__PURE__ */ a("div", { className:
|
|
52
|
-
/* @__PURE__ */ a("div", { className:
|
|
55
|
+
return /* @__PURE__ */ a(f, { error: o.errorHandling.errors, LoaderComponent: d, children: /* @__PURE__ */ a(q, { formHookResult: o, children: /* @__PURE__ */ a(A, { onSubmit: () => {
|
|
56
|
+
v();
|
|
57
|
+
}, children: /* @__PURE__ */ c(u, { flexDirection: "column", children: [
|
|
58
|
+
/* @__PURE__ */ a(u, { justifyContent: "space-between", flexDirection: "column", gap: 4, children: /* @__PURE__ */ a("header", { children: /* @__PURE__ */ a(i.Heading, { as: "h2", children: o.status.mode === "create" ? e("headings.addPaySchedule") : e("headings.editPaySchedule") }) }) }),
|
|
59
|
+
/* @__PURE__ */ a("div", { className: m.payScheduleContainer, children: /* @__PURE__ */ c(L, { gap: 32, gridTemplateColumns: { base: "1fr", small: "1fr 1fr" }, children: [
|
|
60
|
+
/* @__PURE__ */ a("div", { className: m.payScheduleForm, children: /* @__PURE__ */ c(u, { flexDirection: "column", children: [
|
|
53
61
|
/* @__PURE__ */ a(
|
|
54
62
|
r.CustomName,
|
|
55
63
|
{
|
|
@@ -62,7 +70,7 @@ function I({ onEvent: s, LoaderComponent: d, ...p }) {
|
|
|
62
70
|
{
|
|
63
71
|
label: e("labels.frequency"),
|
|
64
72
|
placeholder: e("labels.frequencyPlaceholder"),
|
|
65
|
-
getOptionLabel: (t) =>
|
|
73
|
+
getOptionLabel: (t) => b[t],
|
|
66
74
|
validationMessages: { REQUIRED: e("validations.frequency") }
|
|
67
75
|
}
|
|
68
76
|
),
|
|
@@ -71,7 +79,7 @@ function I({ onEvent: s, LoaderComponent: d, ...p }) {
|
|
|
71
79
|
{
|
|
72
80
|
label: e("labels.frequencyOptions"),
|
|
73
81
|
description: e("descriptions.frequencyOptionsDescription"),
|
|
74
|
-
getOptionLabel: (t) =>
|
|
82
|
+
getOptionLabel: (t) => k[t] ?? t,
|
|
75
83
|
validationMessages: { REQUIRED: e("validations.frequencyOptions") }
|
|
76
84
|
}
|
|
77
85
|
),
|
|
@@ -80,7 +88,7 @@ function I({ onEvent: s, LoaderComponent: d, ...p }) {
|
|
|
80
88
|
{
|
|
81
89
|
label: e("labels.firstPayDate"),
|
|
82
90
|
description: e("descriptions.anchorPayDateDescription", {
|
|
83
|
-
count:
|
|
91
|
+
count: S
|
|
84
92
|
}),
|
|
85
93
|
validationMessages: { REQUIRED: e("validations.firstPayDate") },
|
|
86
94
|
minDate: /* @__PURE__ */ new Date()
|
|
@@ -113,46 +121,55 @@ function I({ onEvent: s, LoaderComponent: d, ...p }) {
|
|
|
113
121
|
DAY_RANGE: e("validations.dayRange")
|
|
114
122
|
}
|
|
115
123
|
}
|
|
124
|
+
),
|
|
125
|
+
r.WorkweekStartDay && /* @__PURE__ */ a(
|
|
126
|
+
r.WorkweekStartDay,
|
|
127
|
+
{
|
|
128
|
+
label: e("labels.workweekStartDay"),
|
|
129
|
+
placeholder: e("labels.workweekStartDayPlaceholder"),
|
|
130
|
+
description: e("descriptions.workweekStartDayDescription"),
|
|
131
|
+
getOptionLabel: (t) => E[t]
|
|
132
|
+
}
|
|
116
133
|
)
|
|
117
134
|
] }) }),
|
|
118
|
-
/* @__PURE__ */ a(
|
|
119
|
-
!
|
|
120
|
-
|
|
135
|
+
/* @__PURE__ */ a(u, { flexDirection: "column", gap: 4, justifyContent: "center", alignItems: "center", children: s && s[n] ? /* @__PURE__ */ c("div", { className: m.calendarContainer, children: [
|
|
136
|
+
!g && /* @__PURE__ */ a(
|
|
137
|
+
i.Select,
|
|
121
138
|
{
|
|
122
139
|
label: e("labels.preview"),
|
|
123
140
|
placeholder: "",
|
|
124
141
|
isRequired: !0,
|
|
125
|
-
options:
|
|
126
|
-
value: String(
|
|
127
|
-
label:
|
|
142
|
+
options: s.map((t, y) => ({
|
|
143
|
+
value: String(y),
|
|
144
|
+
label: P.formatPayPeriodRange(
|
|
128
145
|
t.startDate.toString(),
|
|
129
146
|
t.endDate.toString()
|
|
130
147
|
)
|
|
131
148
|
})),
|
|
132
149
|
value: String(n),
|
|
133
150
|
onChange: (t) => {
|
|
134
|
-
const
|
|
135
|
-
isNaN(
|
|
151
|
+
const y = Number(t);
|
|
152
|
+
isNaN(y) || w(y);
|
|
136
153
|
}
|
|
137
154
|
}
|
|
138
155
|
),
|
|
139
156
|
/* @__PURE__ */ a(
|
|
140
|
-
|
|
157
|
+
i.CalendarPreview,
|
|
141
158
|
{
|
|
142
159
|
dateRange: {
|
|
143
|
-
start:
|
|
144
|
-
end:
|
|
160
|
+
start: p(s[n].startDate),
|
|
161
|
+
end: p(s[n].endDate),
|
|
145
162
|
label: e("payPreview.payPeriod") || "Pay Period"
|
|
146
163
|
},
|
|
147
164
|
highlightDates: [
|
|
148
165
|
{
|
|
149
|
-
date:
|
|
166
|
+
date: p(s[n].checkDate),
|
|
150
167
|
highlightColor: "primary",
|
|
151
168
|
label: e("payPreview.payday") || "Payday"
|
|
152
169
|
},
|
|
153
170
|
{
|
|
154
|
-
date:
|
|
155
|
-
|
|
171
|
+
date: p(
|
|
172
|
+
s[n].runPayrollBy
|
|
156
173
|
),
|
|
157
174
|
highlightColor: "secondary",
|
|
158
175
|
label: e("payPreview.payrollDeadline") || "Payroll Deadline"
|
|
@@ -161,12 +178,12 @@ function I({ onEvent: s, LoaderComponent: d, ...p }) {
|
|
|
161
178
|
},
|
|
162
179
|
n
|
|
163
180
|
)
|
|
164
|
-
] }) : /* @__PURE__ */ a("div", { className:
|
|
165
|
-
|
|
181
|
+
] }) : /* @__PURE__ */ a("div", { className: m.calendarContainer, children: /* @__PURE__ */ a(
|
|
182
|
+
i.Alert,
|
|
166
183
|
{
|
|
167
184
|
status: "info",
|
|
168
185
|
label: e("previewAlert.title", "Pay Schedule Preview"),
|
|
169
|
-
children: /* @__PURE__ */ a(
|
|
186
|
+
children: /* @__PURE__ */ a(i.Text, { children: e(
|
|
170
187
|
"previewAlert.description",
|
|
171
188
|
"Complete all the required fields on the left to see a preview of your pay schedule."
|
|
172
189
|
) })
|
|
@@ -175,20 +192,20 @@ function I({ onEvent: s, LoaderComponent: d, ...p }) {
|
|
|
175
192
|
] }) }),
|
|
176
193
|
/* @__PURE__ */ c(T, { children: [
|
|
177
194
|
/* @__PURE__ */ a(
|
|
178
|
-
|
|
195
|
+
i.Button,
|
|
179
196
|
{
|
|
180
197
|
variant: "secondary",
|
|
181
198
|
onClick: () => {
|
|
182
|
-
|
|
199
|
+
l(D.CANCEL);
|
|
183
200
|
},
|
|
184
201
|
children: e("actions.cancel")
|
|
185
202
|
}
|
|
186
203
|
),
|
|
187
|
-
/* @__PURE__ */ a(
|
|
204
|
+
/* @__PURE__ */ a(i.Button, { type: "submit", isLoading: o.status.isPending, children: e("actions.save") })
|
|
188
205
|
] })
|
|
189
206
|
] }) }) }) });
|
|
190
207
|
}
|
|
191
208
|
export {
|
|
192
|
-
|
|
209
|
+
ee as PayScheduleForm
|
|
193
210
|
};
|
|
194
211
|
//# sourceMappingURL=PayScheduleForm.js.map
|