@remoteoss/remote-flows 1.10.0 → 1.11.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/dist/{CountryFieldDefault-KBZRYF4G.js → CountryFieldDefault-V7LUYGQV.js} +2 -2
- package/dist/DatePickerFieldDefault-OMSU42DG.js +2 -0
- package/dist/RadioGroupFieldDefault-4IA7HESJ.js +2 -0
- package/dist/{chunk-5SODYNW6.js → chunk-2RBFD5MM.js} +2 -2
- package/dist/{chunk-Y7GS2L2A.js → chunk-3JQROVRG.js} +2 -2
- package/dist/{chunk-3FF65KI3.js → chunk-3KD533T6.js} +2 -2
- package/dist/{chunk-PAUMTSGO.js → chunk-3LZR4D3V.js} +2 -2
- package/dist/{chunk-GC5QTPTM.js → chunk-4APMRCE7.js} +2 -2
- package/dist/{chunk-4W7VKUIW.js → chunk-4ECYU3L5.js} +2 -2
- package/dist/{chunk-YDIPBC4E.js → chunk-4YAFRXR5.js} +2 -2
- package/dist/{chunk-S2Z3B5C5.js → chunk-55QKFWY5.js} +2 -2
- package/dist/{chunk-DWXCRJ4V.js → chunk-5FUJICAO.js} +2 -2
- package/dist/{chunk-E5ZC6VG3.js → chunk-5PVNZ6VO.js} +2 -2
- package/dist/{chunk-QZIZVDJ3.js → chunk-64D4GLTO.js} +2 -2
- package/dist/{chunk-A7XZA2M3.js → chunk-6AXMBMQI.js} +2 -2
- package/dist/{chunk-AMJ7F55V.js → chunk-6SVKW2DC.js} +2 -2
- package/dist/{chunk-OCTTH4RR.js → chunk-7G4JI6ZU.js} +2 -2
- package/dist/chunk-BDJLITVT.js +2 -0
- package/dist/chunk-BDJLITVT.js.map +1 -0
- package/dist/{chunk-4UJJLD3R.js → chunk-BHXCYFC4.js} +2 -2
- package/dist/{chunk-P4IF2JG6.js → chunk-C36DEJTU.js} +2 -2
- package/dist/{chunk-HG7UJX4O.js → chunk-DAE2FMZ5.js} +2 -2
- package/dist/{chunk-TWCZHLHV.js → chunk-E7JOGKEV.js} +2 -2
- package/dist/{chunk-UMOL4GLZ.js → chunk-FC2V3NUT.js} +2 -2
- package/dist/{chunk-I4IRP6BK.js → chunk-FUPQCC4B.js} +2 -2
- package/dist/{chunk-Y4JWDS3R.js → chunk-G6BR4JI6.js} +2 -2
- package/dist/{chunk-2EYBWQJW.js → chunk-GK3QRXNY.js} +2 -2
- package/dist/{chunk-UTAMXYX4.js → chunk-GZ2JKPBY.js} +2 -2
- package/dist/{chunk-IXZS4AU4.js → chunk-H5LGAIMM.js} +2 -2
- package/dist/{chunk-EI4CEPXN.js → chunk-I3KFOOF6.js} +2 -2
- package/dist/{chunk-R3XRCGZN.js → chunk-IVUCPXEC.js} +2 -2
- package/dist/{chunk-SOXCGLMW.js → chunk-JZWOMKR3.js} +2 -2
- package/dist/chunk-KXOVDXNX.js +2 -0
- package/dist/chunk-KXOVDXNX.js.map +1 -0
- package/dist/{chunk-JD2OY7RW.js → chunk-LGIHVJA5.js} +2 -2
- package/dist/{chunk-B3KBDNWQ.js → chunk-N6XY7NC3.js} +2 -2
- package/dist/{chunk-PCNRQKOW.js → chunk-NB3TN7O3.js} +2 -2
- package/dist/{chunk-XCYBEX4H.js → chunk-NVX4O45S.js} +2 -2
- package/dist/chunk-O3G6HQ3B.js +2 -0
- package/dist/chunk-O3G6HQ3B.js.map +1 -0
- package/dist/{chunk-HBCFJ6PK.js → chunk-PJ6ZEFWD.js} +3 -3
- package/dist/{chunk-HBCFJ6PK.js.map → chunk-PJ6ZEFWD.js.map} +1 -1
- package/dist/{chunk-44SKGM3K.js → chunk-PKXMKBP4.js} +2 -2
- package/dist/{chunk-WUCPJPDB.js → chunk-Q445EJX6.js} +2 -2
- package/dist/{chunk-JK6ODZSU.js → chunk-QLB4FSLX.js} +2 -2
- package/dist/{chunk-R7V2KOW6.js → chunk-QSOCKFUS.js} +2 -2
- package/dist/{chunk-R4LTPU22.js → chunk-SBUJLXJH.js} +2 -2
- package/dist/{chunk-WNDVXLAQ.js → chunk-SIP2BFZJ.js} +2 -2
- package/dist/{chunk-JTJFG72J.js → chunk-SUWJZ3QR.js} +2 -2
- package/dist/chunk-TCLY24DF.js +2 -0
- package/dist/chunk-TCLY24DF.js.map +1 -0
- package/dist/{chunk-RKCZ5D42.js → chunk-THBDZR3D.js} +2 -2
- package/dist/{chunk-QVJD2C6W.js → chunk-U7MQPLGK.js} +2 -2
- package/dist/{chunk-EVOTA5WO.js → chunk-U7PGN7TL.js} +2 -2
- package/dist/{chunk-JCVKKCDH.js → chunk-UFTA5ATE.js} +2 -2
- package/dist/chunk-UYUPSPOE.js +1 -0
- package/dist/{chunk-FJ5RHLSJ.js → chunk-VNN6IP6P.js} +2 -2
- package/dist/{chunk-P3VO63JW.js → chunk-WOW74M7R.js} +2 -2
- package/dist/{chunk-U7SJPXRD.js → chunk-XJILW6K3.js} +2 -2
- package/dist/{chunk-MFFE3Q5U.js → chunk-XSUQM562.js} +2 -2
- package/dist/{chunk-A5PZOBR5.js → chunk-XYO67D3V.js} +2 -2
- package/dist/{chunk-3UNMOXCG.js → chunk-ZL6FKICW.js} +2 -2
- package/dist/{chunk-QAMANHN6.js → chunk-ZWO4HX27.js} +2 -2
- package/dist/default-components.d.ts +2 -2
- package/dist/default-components.js +1 -1
- package/dist/flows/ContractAmendment/ContractAmendmentConfirmationForm.d.ts +1 -1
- package/dist/flows/ContractAmendment/ContractAmendmentFlow.d.ts +3 -3
- package/dist/flows/ContractAmendment/ContractAmendmentFlow.js +1 -1
- package/dist/flows/ContractAmendment/ContractAmendmentForm.d.ts +1 -1
- package/dist/flows/ContractAmendment/ContractAmendmentForm.js +1 -1
- package/dist/flows/ContractAmendment/context.d.ts +3 -3
- package/dist/flows/ContractAmendment/hooks.d.ts +3 -3
- package/dist/flows/ContractAmendment/hooks.js +1 -1
- package/dist/flows/ContractAmendment/index.d.ts +3 -3
- package/dist/flows/ContractAmendment/index.js +1 -1
- package/dist/flows/ContractAmendment/types.d.ts +2 -2
- package/dist/flows/ContractAmendment/utils.d.ts +2 -2
- package/dist/flows/ContractorOnboarding/ContractorOnboarding.d.ts +5 -5
- package/dist/flows/ContractorOnboarding/ContractorOnboarding.js +1 -1
- package/dist/flows/ContractorOnboarding/api.d.ts +2 -2
- package/dist/flows/ContractorOnboarding/api.js +1 -1
- package/dist/flows/ContractorOnboarding/components/BasicInformationStep.d.ts +4 -4
- package/dist/flows/ContractorOnboarding/components/BasicInformationStep.js +1 -1
- package/dist/flows/ContractorOnboarding/components/ContractDetailsStep.d.ts +5 -5
- package/dist/flows/ContractorOnboarding/components/ContractDetailsStep.js +1 -1
- package/dist/flows/ContractorOnboarding/components/ContractPreviewHeader.d.ts +2 -2
- package/dist/flows/ContractorOnboarding/components/ContractPreviewStatement.d.ts +2 -2
- package/dist/flows/ContractorOnboarding/components/ContractPreviewStep.d.ts +5 -5
- package/dist/flows/ContractorOnboarding/components/ContractPreviewStep.js +1 -1
- package/dist/flows/ContractorOnboarding/components/ContractorOnboardingForm.d.ts +5 -5
- package/dist/flows/ContractorOnboarding/components/ContractorOnboardingForm.js +1 -1
- package/dist/flows/ContractorOnboarding/components/OnboardingInvite.d.ts +3 -3
- package/dist/flows/ContractorOnboarding/components/OnboardingInvite.js +1 -1
- package/dist/flows/ContractorOnboarding/components/PricingPlan.d.ts +5 -5
- package/dist/flows/ContractorOnboarding/components/PricingPlan.js +1 -1
- package/dist/flows/ContractorOnboarding/components/SelectCountryStep.d.ts +4 -4
- package/dist/flows/ContractorOnboarding/components/SelectCountryStep.js +1 -1
- package/dist/flows/ContractorOnboarding/components/StatementOfWorkDisclaimer.js +1 -1
- package/dist/flows/ContractorOnboarding/constants.d.ts +38 -1
- package/dist/flows/ContractorOnboarding/constants.js +1 -1
- package/dist/flows/ContractorOnboarding/context.d.ts +6 -5
- package/dist/flows/ContractorOnboarding/hooks.d.ts +5 -5
- package/dist/flows/ContractorOnboarding/hooks.js +1 -1
- package/dist/flows/ContractorOnboarding/index.d.ts +6 -5
- package/dist/flows/ContractorOnboarding/index.js +1 -1
- package/dist/flows/ContractorOnboarding/jsfModify.d.ts +5 -5
- package/dist/flows/ContractorOnboarding/jsfModify.js +1 -1
- package/dist/flows/ContractorOnboarding/types.d.ts +5 -5
- package/dist/flows/ContractorOnboarding/utils.js +1 -1
- package/dist/flows/CostCalculator/CostCalculatorFlow.d.ts +3 -3
- package/dist/flows/CostCalculator/CostCalculatorFlow.js +1 -1
- package/dist/flows/CostCalculator/CostCalculatorForm.d.ts +3 -3
- package/dist/flows/CostCalculator/CostCalculatorForm.js +1 -1
- package/dist/flows/CostCalculator/EstimationResults/EstimationResults.d.ts +2 -2
- package/dist/flows/CostCalculator/EstimationResults/EstimationResults.js +1 -1
- package/dist/flows/CostCalculator/SummaryResults/SummaryResults.d.ts +2 -2
- package/dist/flows/CostCalculator/api.d.ts +2 -2
- package/dist/flows/CostCalculator/api.js +1 -1
- package/dist/flows/CostCalculator/components/SalaryField.d.ts +2 -2
- package/dist/flows/CostCalculator/components/SalaryField.js +1 -1
- package/dist/flows/CostCalculator/context.d.ts +3 -3
- package/dist/flows/CostCalculator/hooks.d.ts +3 -3
- package/dist/flows/CostCalculator/hooks.js +1 -1
- package/dist/flows/CostCalculator/index.d.ts +3 -3
- package/dist/flows/CostCalculator/index.js +1 -1
- package/dist/flows/CostCalculator/types.d.ts +2 -2
- package/dist/flows/CostCalculator/utils.d.ts +3 -3
- package/dist/flows/CostCalculator/utils.js +1 -1
- package/dist/flows/Onboarding/OnboardingFlow.d.ts +4 -4
- package/dist/flows/Onboarding/OnboardingFlow.js +1 -1
- package/dist/flows/Onboarding/api.d.ts +4 -4
- package/dist/flows/Onboarding/api.js +1 -1
- package/dist/flows/Onboarding/components/AnnualGrossSalary.d.ts +2 -2
- package/dist/flows/Onboarding/components/AnnualGrossSalary.js +1 -1
- package/dist/flows/Onboarding/components/BasicInformationStep.d.ts +4 -4
- package/dist/flows/Onboarding/components/BasicInformationStep.js +1 -1
- package/dist/flows/Onboarding/components/BenefitsStep.d.ts +4 -4
- package/dist/flows/Onboarding/components/BenefitsStep.js +1 -1
- package/dist/flows/Onboarding/components/ContractDetailsStep.d.ts +4 -4
- package/dist/flows/Onboarding/components/ContractDetailsStep.js +1 -1
- package/dist/flows/Onboarding/components/OnboardingForm.d.ts +4 -4
- package/dist/flows/Onboarding/components/OnboardingForm.js +1 -1
- package/dist/flows/Onboarding/components/OnboardingInvite.d.ts +3 -3
- package/dist/flows/Onboarding/components/OnboardingInvite.js +1 -1
- package/dist/flows/Onboarding/components/ReviewStep.d.ts +4 -4
- package/dist/flows/Onboarding/components/SaveDraftButton.d.ts +3 -3
- package/dist/flows/Onboarding/components/SelectCountryStep.d.ts +4 -4
- package/dist/flows/Onboarding/components/SelectCountryStep.js +1 -1
- package/dist/flows/Onboarding/context.d.ts +4 -4
- package/dist/flows/Onboarding/hooks.d.ts +4 -4
- package/dist/flows/Onboarding/hooks.js +1 -1
- package/dist/flows/Onboarding/index.d.ts +4 -4
- package/dist/flows/Onboarding/index.js +1 -1
- package/dist/flows/Onboarding/types.d.ts +4 -4
- package/dist/flows/Onboarding/utils.d.ts +4 -4
- package/dist/flows/Termination/AdditionalDetailsForm.d.ts +4 -4
- package/dist/flows/Termination/AdditionalDetailsForm.js +1 -1
- package/dist/flows/Termination/EmployeeComunicationForm.d.ts +4 -4
- package/dist/flows/Termination/EmployeeComunicationForm.js +1 -1
- package/dist/flows/Termination/PaidTimeOffForm.d.ts +4 -4
- package/dist/flows/Termination/PaidTimeOffForm.js +1 -1
- package/dist/flows/Termination/TerminationDetailsForm.d.ts +4 -4
- package/dist/flows/Termination/TerminationDetailsForm.js +1 -1
- package/dist/flows/Termination/TerminationFlow.d.ts +4 -4
- package/dist/flows/Termination/TerminationFlow.js +1 -1
- package/dist/flows/Termination/TerminationForm.d.ts +4 -4
- package/dist/flows/Termination/TerminationForm.js +1 -1
- package/dist/flows/Termination/api.d.ts +5 -5
- package/dist/flows/Termination/api.js +1 -1
- package/dist/flows/Termination/components/AcknowledgeInformation/AcknowledgeInformationFees.js +1 -1
- package/dist/flows/Termination/components/PaidTimeOff/PaidTimeOff.d.ts +6 -6
- package/dist/flows/Termination/components/PaidTimeOff/PaidTimeOffContainer.d.ts +6 -6
- package/dist/flows/Termination/components/PaidTimeOff/PaidTimeOffContainer.js +1 -1
- package/dist/flows/Termination/components/PaidTimeOff/types.d.ts +6 -6
- package/dist/flows/Termination/components/TerminationDialogInfoContent/TerminationDialogInfoContent.js +1 -1
- package/dist/flows/Termination/context.d.ts +4 -4
- package/dist/flows/Termination/hooks.d.ts +4 -4
- package/dist/flows/Termination/hooks.js +1 -1
- package/dist/flows/Termination/index.d.ts +6 -6
- package/dist/flows/Termination/index.js +1 -1
- package/dist/flows/Termination/json-schemas/schema.d.ts +4 -4
- package/dist/flows/Termination/types.d.ts +4 -4
- package/dist/flows/Termination/utils.d.ts +4 -4
- package/dist/flows/types.d.ts +2 -2
- package/dist/index.css +1 -1
- package/dist/index.css.map +1 -1
- package/dist/index.d.ts +23 -10
- package/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/dist/internals.d.ts +3 -3
- package/dist/{mutations-CgUg7bFI.d.ts → mutations-CSKL2ADz.d.ts} +1 -1
- package/dist/{remoteFlows-COBpPFTc.d.ts → remoteFlows-8JqicJKg.d.ts} +23 -2
- package/dist/styles.css +1 -1
- package/dist/styles.css.map +1 -1
- package/dist/{types-Dji2W0_p.d.ts → types-BL_cUn9Q.d.ts} +10 -5
- package/dist/{types-DNR15SYE.d.ts → types-Ch9BHKQe.d.ts} +1 -1
- package/dist/{types-B_vHCmBi.d.ts → types-P-Kidj6s.d.ts} +3 -3
- package/dist/{types-cehPGDYr.d.ts → types-ixtOeG_U.d.ts} +2 -2
- package/dist/{types.gen-BvDfbEiE.d.ts → types.gen-BBKMFRSu.d.ts} +20 -1
- package/dist/{utils-CB_t8bzu.d.ts → utils-Cfo-6z-L.d.ts} +1 -1
- package/package.json +1 -1
- package/dist/DatePickerFieldDefault-RY6QSSE7.js +0 -2
- package/dist/RadioGroupFieldDefault-KAAFWDFJ.js +0 -2
- package/dist/chunk-BJAX4PPR.js +0 -2
- package/dist/chunk-BJAX4PPR.js.map +0 -1
- package/dist/chunk-DKFUZO5P.js +0 -1
- package/dist/chunk-DSH4GKP3.js +0 -2
- package/dist/chunk-DSH4GKP3.js.map +0 -1
- package/dist/chunk-FX4KYXGM.js +0 -2
- package/dist/chunk-FX4KYXGM.js.map +0 -1
- package/dist/chunk-N4W7JU2D.js +0 -2
- package/dist/chunk-N4W7JU2D.js.map +0 -1
- /package/dist/{CountryFieldDefault-KBZRYF4G.js.map → CountryFieldDefault-V7LUYGQV.js.map} +0 -0
- /package/dist/{DatePickerFieldDefault-RY6QSSE7.js.map → DatePickerFieldDefault-OMSU42DG.js.map} +0 -0
- /package/dist/{RadioGroupFieldDefault-KAAFWDFJ.js.map → RadioGroupFieldDefault-4IA7HESJ.js.map} +0 -0
- /package/dist/{chunk-5SODYNW6.js.map → chunk-2RBFD5MM.js.map} +0 -0
- /package/dist/{chunk-Y7GS2L2A.js.map → chunk-3JQROVRG.js.map} +0 -0
- /package/dist/{chunk-3FF65KI3.js.map → chunk-3KD533T6.js.map} +0 -0
- /package/dist/{chunk-PAUMTSGO.js.map → chunk-3LZR4D3V.js.map} +0 -0
- /package/dist/{chunk-GC5QTPTM.js.map → chunk-4APMRCE7.js.map} +0 -0
- /package/dist/{chunk-4W7VKUIW.js.map → chunk-4ECYU3L5.js.map} +0 -0
- /package/dist/{chunk-YDIPBC4E.js.map → chunk-4YAFRXR5.js.map} +0 -0
- /package/dist/{chunk-S2Z3B5C5.js.map → chunk-55QKFWY5.js.map} +0 -0
- /package/dist/{chunk-DWXCRJ4V.js.map → chunk-5FUJICAO.js.map} +0 -0
- /package/dist/{chunk-E5ZC6VG3.js.map → chunk-5PVNZ6VO.js.map} +0 -0
- /package/dist/{chunk-QZIZVDJ3.js.map → chunk-64D4GLTO.js.map} +0 -0
- /package/dist/{chunk-A7XZA2M3.js.map → chunk-6AXMBMQI.js.map} +0 -0
- /package/dist/{chunk-AMJ7F55V.js.map → chunk-6SVKW2DC.js.map} +0 -0
- /package/dist/{chunk-OCTTH4RR.js.map → chunk-7G4JI6ZU.js.map} +0 -0
- /package/dist/{chunk-4UJJLD3R.js.map → chunk-BHXCYFC4.js.map} +0 -0
- /package/dist/{chunk-P4IF2JG6.js.map → chunk-C36DEJTU.js.map} +0 -0
- /package/dist/{chunk-HG7UJX4O.js.map → chunk-DAE2FMZ5.js.map} +0 -0
- /package/dist/{chunk-TWCZHLHV.js.map → chunk-E7JOGKEV.js.map} +0 -0
- /package/dist/{chunk-UMOL4GLZ.js.map → chunk-FC2V3NUT.js.map} +0 -0
- /package/dist/{chunk-I4IRP6BK.js.map → chunk-FUPQCC4B.js.map} +0 -0
- /package/dist/{chunk-Y4JWDS3R.js.map → chunk-G6BR4JI6.js.map} +0 -0
- /package/dist/{chunk-2EYBWQJW.js.map → chunk-GK3QRXNY.js.map} +0 -0
- /package/dist/{chunk-UTAMXYX4.js.map → chunk-GZ2JKPBY.js.map} +0 -0
- /package/dist/{chunk-IXZS4AU4.js.map → chunk-H5LGAIMM.js.map} +0 -0
- /package/dist/{chunk-EI4CEPXN.js.map → chunk-I3KFOOF6.js.map} +0 -0
- /package/dist/{chunk-R3XRCGZN.js.map → chunk-IVUCPXEC.js.map} +0 -0
- /package/dist/{chunk-SOXCGLMW.js.map → chunk-JZWOMKR3.js.map} +0 -0
- /package/dist/{chunk-JD2OY7RW.js.map → chunk-LGIHVJA5.js.map} +0 -0
- /package/dist/{chunk-B3KBDNWQ.js.map → chunk-N6XY7NC3.js.map} +0 -0
- /package/dist/{chunk-PCNRQKOW.js.map → chunk-NB3TN7O3.js.map} +0 -0
- /package/dist/{chunk-XCYBEX4H.js.map → chunk-NVX4O45S.js.map} +0 -0
- /package/dist/{chunk-44SKGM3K.js.map → chunk-PKXMKBP4.js.map} +0 -0
- /package/dist/{chunk-WUCPJPDB.js.map → chunk-Q445EJX6.js.map} +0 -0
- /package/dist/{chunk-JK6ODZSU.js.map → chunk-QLB4FSLX.js.map} +0 -0
- /package/dist/{chunk-R7V2KOW6.js.map → chunk-QSOCKFUS.js.map} +0 -0
- /package/dist/{chunk-R4LTPU22.js.map → chunk-SBUJLXJH.js.map} +0 -0
- /package/dist/{chunk-WNDVXLAQ.js.map → chunk-SIP2BFZJ.js.map} +0 -0
- /package/dist/{chunk-JTJFG72J.js.map → chunk-SUWJZ3QR.js.map} +0 -0
- /package/dist/{chunk-RKCZ5D42.js.map → chunk-THBDZR3D.js.map} +0 -0
- /package/dist/{chunk-QVJD2C6W.js.map → chunk-U7MQPLGK.js.map} +0 -0
- /package/dist/{chunk-EVOTA5WO.js.map → chunk-U7PGN7TL.js.map} +0 -0
- /package/dist/{chunk-JCVKKCDH.js.map → chunk-UFTA5ATE.js.map} +0 -0
- /package/dist/{chunk-DKFUZO5P.js.map → chunk-UYUPSPOE.js.map} +0 -0
- /package/dist/{chunk-FJ5RHLSJ.js.map → chunk-VNN6IP6P.js.map} +0 -0
- /package/dist/{chunk-P3VO63JW.js.map → chunk-WOW74M7R.js.map} +0 -0
- /package/dist/{chunk-U7SJPXRD.js.map → chunk-XJILW6K3.js.map} +0 -0
- /package/dist/{chunk-MFFE3Q5U.js.map → chunk-XSUQM562.js.map} +0 -0
- /package/dist/{chunk-A5PZOBR5.js.map → chunk-XYO67D3V.js.map} +0 -0
- /package/dist/{chunk-3UNMOXCG.js.map → chunk-ZL6FKICW.js.map} +0 -0
- /package/dist/{chunk-QAMANHN6.js.map → chunk-ZWO4HX27.js.map} +0 -0
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as R,b as x,c as N,d as A}from"./chunk-XZLVP6EN.js";import{a as w,b as f}from"./chunk-DSH4GKP3.js";import{a as C}from"./chunk-KESYJ5QG.js";import{b as B}from"./chunk-YUYHK6WD.js";import{a as i,b as t,e as F}from"./chunk-J63QA2JC.js";import{a as m}from"./chunk-P37U34EQ.js";import{MoreHorizontal as P}from"lucide-react";import{useState as U}from"react";import{Fragment as $,jsx as g,jsxs as T}from"react/jsx-runtime";function E({actions:e=[],className:n,label:a,"data-testid":l}){let[_,d]=U(!1);return T("div",{className:i("relative",n),children:[g(B,{"data-testid":l,variant:"ghost","aria-label":a,className:"h-8 w-8 p-0",onClick:()=>d(!_),children:g(P,{className:"h-4 w-4"})}),_&&T($,{children:[g("div",{className:"fixed inset-0 z-40",onClick:()=>d(!1)}),g("div",{className:"absolute right-0 top-1/2 mt-1 bg-white border border-gray-200 rounded-md shadow-lg z-50 min-w-[120px]",children:e.map((c,u)=>g("button",{"data-testid":`${l}-${c.label.toLowerCase().replace(" ","-")}`,className:i("w-full text-left px-2 py-1.5 text-sm hover:bg-gray-100",c.disabled&&"opacity-50 cursor-not-allowed"),onClick:()=>{c.onClick(),d(!1)},disabled:c.disabled,children:c.label},u))})]})]})}m(E,"ActionsDropdown");import{ChevronDown as O,Info as Z}from"lucide-react";import K from"react-flagpack";import{useState as z}from"react";import{jsx as j,jsxs as L}from"react/jsx-runtime";var I=m(({children:e,content:n})=>L("div",{className:"relative inline-block group",children:[e,L("div",{className:"absolute bottom-full right-0 mb-2 px-3 py-2 bg-gray-900 text-white text-xs rounded-md opacity-0 invisible group-hover:opacity-100 group-hover:visible transition-all duration-200 z-50 w-64 whitespace-normal break-words",children:[n,j("div",{className:"absolute top-full right-3 border-4 border-transparent border-t-gray-900"})]})]}),"BasicTooltip");import{Fragment as b,jsx as o,jsxs as r}from"react/jsx-runtime";var V={GB:"GB-UKM"},Y=m(({title:e,country:n,region:a,annualGrossSalary:l,onDelete:_,onExportPdf:d,onEdit:c})=>{let u=[{label:"Edit",onClick:c},{label:"Export",onClick:d},{label:"Delete",onClick:_}];return r("div",{className:"RemoteFlows__EstimationResults__Header flex justify-between",children:[r("div",{className:"flex flex-row items-center gap-6",children:[o("div",{className:"RemoteFlows__EstimationResultsHeader__FlagContainer flex h-16 w-16 items-center justify-center rounded-lg bg-[#F4F4F5]",children:o(K,{code:V[n.alpha_2_code]||n.alpha_2_code})}),r("div",{className:"space-y-1",children:[o("h2",{"data-testid":"estimation-results-header-title",className:"RemoteFlows__EstimationResultsHeader__Title text-lg font-medium leading-none text-[#181818]",children:e}),r("p",{className:"RemoteFlows__EstimationResultsHeader__Country text-xs text-[#71717A]",children:[n.name," ",a?` (${a.name})`:""]}),r("p",{"data-testid":"estimation-results-header-annual-gross-salary",className:"RemoteFlows__EstimationResultsHeader__AnnualGrossSalary text-xs text-[#71717A]",children:[o("span",{className:"text-[#181818]",children:"Employee annual gross salary:"})," ",l]})]})]}),o(E,{label:"Actions",className:"RemoteFlows__EstimationResults__ActionsDropdown",actions:u})]})},"EstimationResultsHeader"),q=m(()=>({steps:[{id:"add-employment-details",title:"Add employment details",description:"You add employee employments details."},{id:"invite-employee",title:"Invite employee",description:"Hire receives an email invitation from Remote to start the self-enrollment process."},{id:"verify-information",title:"Verify information",description:"Remote prepares the Employment Agreement and verifies all the information."},{id:"sign-contract",title:"Sign contract",description:"All parties sign the Employment Agreement and are ready to start. \u{1F389}"}],helpText:"For customers who accept Remote's Terms of Service (ToS), the employee onboarding timeline starts once the employee has been invited to the platform and completed self enrollment.",zendeskArticleId:w.employeeOnboardingTimeline}),"getOnboardingTimelineData");function J({minimumOnboardingDays:e,data:n,className:a}){return o(R,{type:"single",collapsible:!0,className:i("RemoteFlows__EstimationResults__OnboardingTimeline w-full",a),children:r(x,{value:"timeline",className:"RemoteFlows__OnboardingTimeline__AccordionItem border-border",children:[o(N,{className:"RemoteFlows__OnboardingTimeline__AccordionTrigger hover:no-underline px-0 py-4",children:r("div",{className:"flex items-center justify-between w-full",children:[o("span",{className:"RemoteFlows__OnboardingTimeline__Title text-base font-medium text-[#0F172A]",children:"Onboarding timeline"}),e!=null&&r("span",{className:"RemoteFlows__OnboardingTimeline__Description text-base text-muted-foreground mr-4",children:[e," days"]})]})}),r(A,{className:"px-0 pb-4",children:[o("ul",{className:"RemoteFlows__OnboardingTimeline__List list-disc list-inside space-y-2",children:n.steps.map(l=>r("li",{children:[o("strong",{className:"font-medium text-[#09090B]",children:l.title})," ","- ",l.description]},l.id))}),r("p",{className:"RemoteFlows__OnboardingTimeline__HelpText text-xs text-muted-foreground mt-4",children:[n.helpText,n.zendeskArticleId&&o(f,{zendeskId:n.zendeskArticleId,children:"Learn more"})]})]})]})})}m(J,"OnboardingTimeline");function Q({className:e,countryBenefitsUrl:n,countryGuideUrl:a,country:l}){return o(R,{type:"single",collapsible:!0,className:i("RemoteFlows__EstimationResults__HiringSection w-full",e),children:r(x,{value:"timeline",className:"RemoteFlows__HiringSection__AccordionItem border-border",children:[o(N,{className:"RemoteFlows__HiringSection__AccordionTrigger hover:no-underline px-0 py-4",children:o("div",{className:"flex items-center justify-between w-full",children:r("span",{className:"text-base font-medium text-[#0F172A]",children:["Hiring in ",l.name]})})}),o(A,{children:r("div",{className:"flex flex-col gap-1",children:[a&&o("a",{href:a,target:"_blank",className:"RemoteFlows__Link",children:"Explore our complete guide \u2197"}),n&&o("a",{href:n,target:"_blank",className:"RemoteFlows__Link",children:"Explore our available benefits \u2197"})]})})]})})}m(Q,"HiringSection");function W({isMultipleCurrency:e,className:n}){return r("div",{className:i("RemoteFlows__EstimationResults__Headers grid grid-cols-3 items-center",n),children:[o("span",{"aria-hidden":!0}),e?r(b,{children:[o("span",{className:"RemoteFlows__EstimationResults__Headers__Label",children:"Employee currency"}),o("span",{className:"RemoteFlows__EstimationResults__Headers__Label",children:"Employer currency"})]}):r(b,{children:[o("span",{}),o("span",{className:"RemoteFlows__EstimationResults__Headers__Label",children:"Amount"})]})]})}m(W,"EstimationHeaders");function S({label:e,amounts:n,className:a,children:l}){let[_,d]=z(!0);return r("div",{className:i("RemoteFlows__EstimationResults__Row",a),children:[r("div",{className:"RemoteFlows__EstimationRow__Grid grid grid-cols-3 items-center",children:[r("div",{className:"RemoteFlows__EstimationRow__LabelContainer flex items-center gap-2",children:[o("span",{className:i("RemoteFlows__EstimationRow__Title min-w-[140px] font-medium text-[#09090B]"),children:e}),o("button",{onClick:()=>d(!_),className:"RemoteFlows__EstimationRow__CollapseButton p-1 hover:bg-gray-100 rounded",children:o(O,{className:`h-4 w-4 text-muted-foreground transition-transform ${_?"rotate-180":""}`})})]}),Array.isArray(n)?n.map((c,u)=>o("span",{className:i("RemoteFlows__EstimationRow__RegionalAmount text-right font-medium text-[#09090B]"),children:c},u)):r(b,{children:[o("span",{}),o("span",{className:i("RemoteFlows__EstimationRow__EmployerAmount text-right font-medium text-[#09090B]"),children:n})]})]}),_&&l&&o("div",{className:"RemoteFlows__EstimationRow__CollapsibleContent mt-4",children:l})]})}m(S,"EstimationRow");function X({item:e,isMultipleCurrency:n,level:a=0}){let[l,_]=z(!1),d=e.children&&e.children.length>0,c=a>0,u=e.isCollapsible||d;return r("li",{className:i("RemoteFlows__BreakdownList__Item pb-3",c&&"pb-1"),children:[r("div",{className:i(n?"RemoteFlows__BreakdownList__Grid grid grid-cols-3 items-center justify-between":"RemoteFlows__BreakdownList__Grid grid grid-cols-2 items-center justify-between"),children:[r("div",{className:i("RemoteFlows__BreakdownList__LabelContainer flex items-center gap-2",c&&"pl-3"),children:[!c&&o("span",{className:"RemoteFlows__BreakdownList__Bullet w-1 h-1 bg-[#09090B] rounded-full flex-shrink-0","aria-hidden":"true"}),u?r("button",{onClick:()=>_(!l),className:"RemoteFlows__BreakdownList__CollapseButton flex items-center gap-2 hover:bg-gray-100 rounded p-1",children:[o("span",{className:i(c?"RemoteFlows__BreakdownList__Text--Nested text-xs text-[#71717A]":"RemoteFlows__BreakdownList__Text--NotNested text-sm text-[#09090B]"),children:e.label}),o(O,{className:`RemoteFlows__BreakdownList__ChevronDown h-3 w-3 text-muted-foreground transition-transform ${l?"rotate-180":""}`})]}):o("span",{className:i(c?"RemoteFlows__BreakdownList__Text--Nested text-xs text-[#71717A]":"RemoteFlows__BreakdownList__Text--NotNested text-sm text-[#09090B] p-1"),children:e.label}),e.tooltip&&o(I,{content:r(b,{children:[o("span",{dangerouslySetInnerHTML:{__html:F(e.tooltip)}})," ",e.zendeskId&&o(f,{zendeskId:Number(e.zendeskId),children:"Learn more"})]}),children:o("button",{className:"RemoteFlows__BreakdownList__InfoButton p-1 hover:bg-gray-100 rounded",children:o(Z,{className:i("RemoteFlows__BreakdownList__InfoButton__Icon text-muted-foreground",c?"h-3 w-3":"h-4 w-4")})})})]}),n?r(b,{children:[o("span",{"data-testid":e.dataSelector&&e.dataSelector+"-employee-amount",className:i("RemoteFlows__BreakdownList__RegionalAmountText text-sm text-right",c?"RemoteFlows__BreakdownList__RegionalAmountText--Nested text-[#71717A]":"RemoteFlows__BreakdownList__RegionalAmountText--NotNested text-[#09090B]"),children:e.regionalAmount||"\u2014"}),o("span",{"data-testid":e.dataSelector&&e.dataSelector+"-employer-amount",className:i("RemoteFlows__BreakdownList__EmployerAmountText text-sm text-right",c?"RemoteFlows__BreakdownList__EmployerAmountText--Nested text-[#71717A]":"RemoteFlows__BreakdownList__EmployerAmountText--NotNested text-[#09090B]"),children:e.employerAmount||"\u2014"})]}):o("span",{"data-testid":e.dataSelector,className:i("RemoteFlows__BreakdownList__RegionalAmountText text-sm text-right",c?"RemoteFlows__BreakdownList__RegionalAmountText--Nested text-[#71717A]":"RemoteFlows__BreakdownList__RegionalAmountText--NotNested text-[#09090B]"),children:e.regionalAmount||"\u2014"})]}),d&&l&&o("div",{className:"mt-1",children:o(h,{items:e.children,isMultipleCurrency:n,level:a+1})})]})}m(X,"BreakdownListItem");function h({items:e,isMultipleCurrency:n,className:a,level:l}){return o("ul",{className:i("RemoteFlows__BreakdownList list-none",a),children:e.map((_,d)=>o(X,{item:_,isMultipleCurrency:n,level:l},d))})}m(h,"BreakdownList");var Re=m(({estimation:e,title:n,components:a,onDelete:l,onExportPdf:_,onEdit:d})=>{let c=a?.HiringSection||Q,u=a?.OnboardingTimeline||J,H=a?.Header||Y,v=a?.Footer,D=q(),p=e.employer_currency_costs.currency.code!==e.regional_currency_costs.currency.code,k=e.employer_currency_costs.monthly_management_fee,M=e.region.code!==e.country.code,G=t(e.regional_currency_costs.annual_gross_salary,e.regional_currency_costs.currency.code);return r(C,{className:"RemoteFlows__EstimationResults__Card p-10",children:[o("div",{className:"RemoteFlows__Separator",children:o(H,{title:n,annualGrossSalary:G,region:M?e.region:void 0,country:e.country,onDelete:l,onExportPdf:_,onEdit:d})}),r("div",{className:"RemoteFlows__Separator",children:[o(W,{isMultipleCurrency:p,className:"mb-3"}),o(S,{label:"Monthly total cost",amounts:p?[t(e.regional_currency_costs.monthly_total,e.regional_currency_costs.currency.code),t(e.employer_currency_costs.monthly_total,e.employer_currency_costs.currency.code)]:t(e.regional_currency_costs.monthly_total,e.regional_currency_costs.currency.code),children:o(h,{items:[{label:"Gross monthly salary",regionalAmount:t(e.regional_currency_costs.monthly_gross_salary,e.regional_currency_costs.currency.code),employerAmount:t(e.employer_currency_costs.monthly_gross_salary,e.employer_currency_costs.currency.code),zendeskId:w.extraPayments.toString(),tooltip:"This country respects extra payments on top of the gross salary."},{label:"Mandatory employer costs",regionalAmount:t(e.regional_currency_costs.monthly_contributions_total,e.regional_currency_costs.currency.code),employerAmount:t(e.employer_currency_costs.monthly_contributions_total,e.employer_currency_costs.currency.code),children:e.employer_currency_costs.monthly_contributions_breakdown?.map((s,y)=>({label:s.name,regionalAmount:t(e.regional_currency_costs.monthly_contributions_breakdown?.[y]?.amount,e.regional_currency_costs.currency.code),employerAmount:t(s.amount,e.employer_currency_costs.currency.code),zendeskId:s.zendesk_article_id||void 0,tooltip:s.description||void 0}))||[]},{label:"Benefits",regionalAmount:t(e.regional_currency_costs.monthly_benefits_total,e.regional_currency_costs.currency.code),employerAmount:t(e.employer_currency_costs.monthly_benefits_total,e.employer_currency_costs.currency.code),children:e.employer_currency_costs.monthly_benefits_breakdown?.map((s,y)=>({label:s.name,regionalAmount:t(e.regional_currency_costs.monthly_benefits_breakdown?.[y]?.amount,e.regional_currency_costs.currency.code),employerAmount:t(s.amount,e.employer_currency_costs.currency.code),zendeskId:s.zendesk_article_id||void 0,tooltip:s.description||void 0}))||[]},...k?[{label:"Monthly fee",regionalAmount:t(e.regional_currency_costs.monthly_management_fee,e.regional_currency_costs.currency.code),employerAmount:t(e.employer_currency_costs.monthly_management_fee,e.employer_currency_costs.currency.code),tooltip:"Discounts may be available based on your commitment and team size. Speak to your account or customer success manager to learn more."}]:[]],isMultipleCurrency:p})})]}),o("div",{className:"RemoteFlows__Separator",children:o(S,{label:"Annual total cost",amounts:p?[t(e.regional_currency_costs.annual_total,e.regional_currency_costs.currency.code),t(e.employer_currency_costs.annual_total,e.employer_currency_costs.currency.code)]:t(e.regional_currency_costs.annual_total,e.regional_currency_costs.currency.code),children:o(h,{items:[{label:"Gross annual salary",dataSelector:"annual-gross-salary",regionalAmount:t(e.regional_currency_costs.annual_gross_salary,e.regional_currency_costs.currency.code),employerAmount:t(e.employer_currency_costs.annual_gross_salary,e.employer_currency_costs.currency.code)},{label:"Mandatory employer costs",regionalAmount:t(e.regional_currency_costs.annual_contributions_total,e.regional_currency_costs.currency.code),employerAmount:t(e.employer_currency_costs.annual_contributions_total,e.employer_currency_costs.currency.code),children:e.employer_currency_costs.annual_contributions_breakdown?.map((s,y)=>({label:s.name,regionalAmount:t(e.regional_currency_costs.annual_contributions_breakdown?.[y]?.amount,e.regional_currency_costs.currency.code),employerAmount:t(s.amount,e.employer_currency_costs.currency.code),zendeskId:s.zendesk_article_id||void 0,tooltip:s.description||void 0}))||[]},{label:"Benefits",regionalAmount:t(e.regional_currency_costs.annual_benefits_total,e.regional_currency_costs.currency.code),employerAmount:t(e.employer_currency_costs.annual_benefits_total,e.employer_currency_costs.currency.code),children:e.employer_currency_costs.annual_benefits_breakdown?.map((s,y)=>({label:s.name,regionalAmount:t(e.regional_currency_costs.annual_benefits_breakdown?.[y]?.amount,e.regional_currency_costs.currency.code),employerAmount:t(s.amount,e.employer_currency_costs.currency.code),zendeskId:s.zendesk_article_id||void 0,tooltip:s.description||void 0}))||[]},{label:"Extra statutory payments",regionalAmount:t(e.regional_currency_costs.extra_statutory_payments_total,e.regional_currency_costs.currency.code),employerAmount:t(e.employer_currency_costs.extra_statutory_payments_total,e.employer_currency_costs.currency.code),children:e.employer_currency_costs.extra_statutory_payments_breakdown?.map((s,y)=>({label:s.name,regionalAmount:t(e.regional_currency_costs.extra_statutory_payments_breakdown?.[y]?.amount,e.regional_currency_costs.currency.code),employerAmount:t(s.amount,e.employer_currency_costs.currency.code),zendeskId:s.zendesk_article_id||void 0,tooltip:s.description||void 0}))||[]},...k?[{label:"Annual fee",regionalAmount:t(e.regional_currency_costs.annual_management_fee,e.regional_currency_costs.currency.code),employerAmount:t(e.employer_currency_costs.annual_management_fee,e.employer_currency_costs.currency.code),tooltip:"Discounts may be available based on your commitment and team size. Speak to your account or customer success manager to learn more."}]:[]],isMultipleCurrency:p})})}),o("div",{className:"RemoteFlows__Separator",children:o(u,{minimumOnboardingDays:e.minimum_onboarding_time,data:D})}),o(c,{countryBenefitsUrl:e.country_benefits_details_url,countryGuideUrl:e.country_guide_url,country:e.country}),v&&o(v,{})]})},"EstimationResults");export{Re as a};
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as R,b as x,c as N,d as A}from"./chunk-XZLVP6EN.js";import{a as w,b as f}from"./chunk-BDJLITVT.js";import{a as C}from"./chunk-KESYJ5QG.js";import{b as B}from"./chunk-YUYHK6WD.js";import{a as i,b as t,e as F}from"./chunk-J63QA2JC.js";import{a as m}from"./chunk-P37U34EQ.js";import{MoreHorizontal as P}from"lucide-react";import{useState as U}from"react";import{Fragment as $,jsx as g,jsxs as T}from"react/jsx-runtime";function E({actions:e=[],className:n,label:a,"data-testid":l}){let[_,d]=U(!1);return T("div",{className:i("relative",n),children:[g(B,{"data-testid":l,variant:"ghost","aria-label":a,className:"h-8 w-8 p-0",onClick:()=>d(!_),children:g(P,{className:"h-4 w-4"})}),_&&T($,{children:[g("div",{className:"fixed inset-0 z-40",onClick:()=>d(!1)}),g("div",{className:"absolute right-0 top-1/2 mt-1 bg-white border border-gray-200 rounded-md shadow-lg z-50 min-w-[120px]",children:e.map((c,u)=>g("button",{"data-testid":`${l}-${c.label.toLowerCase().replace(" ","-")}`,className:i("w-full text-left px-2 py-1.5 text-sm hover:bg-gray-100",c.disabled&&"opacity-50 cursor-not-allowed"),onClick:()=>{c.onClick(),d(!1)},disabled:c.disabled,children:c.label},u))})]})]})}m(E,"ActionsDropdown");import{ChevronDown as O,Info as Z}from"lucide-react";import K from"react-flagpack";import{useState as z}from"react";import{jsx as j,jsxs as L}from"react/jsx-runtime";var I=m(({children:e,content:n})=>L("div",{className:"relative inline-block group",children:[e,L("div",{className:"absolute bottom-full right-0 mb-2 px-3 py-2 bg-gray-900 text-white text-xs rounded-md opacity-0 invisible group-hover:opacity-100 group-hover:visible transition-all duration-200 z-50 w-64 whitespace-normal break-words",children:[n,j("div",{className:"absolute top-full right-3 border-4 border-transparent border-t-gray-900"})]})]}),"BasicTooltip");import{Fragment as b,jsx as o,jsxs as r}from"react/jsx-runtime";var V={GB:"GB-UKM"},Y=m(({title:e,country:n,region:a,annualGrossSalary:l,onDelete:_,onExportPdf:d,onEdit:c})=>{let u=[{label:"Edit",onClick:c},{label:"Export",onClick:d},{label:"Delete",onClick:_}];return r("div",{className:"RemoteFlows__EstimationResults__Header flex justify-between",children:[r("div",{className:"flex flex-row items-center gap-6",children:[o("div",{className:"RemoteFlows__EstimationResultsHeader__FlagContainer flex h-16 w-16 items-center justify-center rounded-lg bg-[#F4F4F5]",children:o(K,{code:V[n.alpha_2_code]||n.alpha_2_code})}),r("div",{className:"space-y-1",children:[o("h2",{"data-testid":"estimation-results-header-title",className:"RemoteFlows__EstimationResultsHeader__Title text-lg font-medium leading-none text-[#181818]",children:e}),r("p",{className:"RemoteFlows__EstimationResultsHeader__Country text-xs text-[#71717A]",children:[n.name," ",a?` (${a.name})`:""]}),r("p",{"data-testid":"estimation-results-header-annual-gross-salary",className:"RemoteFlows__EstimationResultsHeader__AnnualGrossSalary text-xs text-[#71717A]",children:[o("span",{className:"text-[#181818]",children:"Employee annual gross salary:"})," ",l]})]})]}),o(E,{label:"Actions",className:"RemoteFlows__EstimationResults__ActionsDropdown",actions:u})]})},"EstimationResultsHeader"),q=m(()=>({steps:[{id:"add-employment-details",title:"Add employment details",description:"You add employee employments details."},{id:"invite-employee",title:"Invite employee",description:"Hire receives an email invitation from Remote to start the self-enrollment process."},{id:"verify-information",title:"Verify information",description:"Remote prepares the Employment Agreement and verifies all the information."},{id:"sign-contract",title:"Sign contract",description:"All parties sign the Employment Agreement and are ready to start. \u{1F389}"}],helpText:"For customers who accept Remote's Terms of Service (ToS), the employee onboarding timeline starts once the employee has been invited to the platform and completed self enrollment.",zendeskArticleId:w.employeeOnboardingTimeline}),"getOnboardingTimelineData");function J({minimumOnboardingDays:e,data:n,className:a}){return o(R,{type:"single",collapsible:!0,className:i("RemoteFlows__EstimationResults__OnboardingTimeline w-full",a),children:r(x,{value:"timeline",className:"RemoteFlows__OnboardingTimeline__AccordionItem border-border",children:[o(N,{className:"RemoteFlows__OnboardingTimeline__AccordionTrigger hover:no-underline px-0 py-4",children:r("div",{className:"flex items-center justify-between w-full",children:[o("span",{className:"RemoteFlows__OnboardingTimeline__Title text-base font-medium text-[#0F172A]",children:"Onboarding timeline"}),e!=null&&r("span",{className:"RemoteFlows__OnboardingTimeline__Description text-base text-muted-foreground mr-4",children:[e," days"]})]})}),r(A,{className:"px-0 pb-4",children:[o("ul",{className:"RemoteFlows__OnboardingTimeline__List list-disc list-inside space-y-2",children:n.steps.map(l=>r("li",{children:[o("strong",{className:"font-medium text-[#09090B]",children:l.title})," ","- ",l.description]},l.id))}),r("p",{className:"RemoteFlows__OnboardingTimeline__HelpText text-xs text-muted-foreground mt-4",children:[n.helpText,n.zendeskArticleId&&o(f,{zendeskId:n.zendeskArticleId,children:"Learn more"})]})]})]})})}m(J,"OnboardingTimeline");function Q({className:e,countryBenefitsUrl:n,countryGuideUrl:a,country:l}){return o(R,{type:"single",collapsible:!0,className:i("RemoteFlows__EstimationResults__HiringSection w-full",e),children:r(x,{value:"timeline",className:"RemoteFlows__HiringSection__AccordionItem border-border",children:[o(N,{className:"RemoteFlows__HiringSection__AccordionTrigger hover:no-underline px-0 py-4",children:o("div",{className:"flex items-center justify-between w-full",children:r("span",{className:"text-base font-medium text-[#0F172A]",children:["Hiring in ",l.name]})})}),o(A,{children:r("div",{className:"flex flex-col gap-1",children:[a&&o("a",{href:a,target:"_blank",className:"RemoteFlows__Link",children:"Explore our complete guide \u2197"}),n&&o("a",{href:n,target:"_blank",className:"RemoteFlows__Link",children:"Explore our available benefits \u2197"})]})})]})})}m(Q,"HiringSection");function W({isMultipleCurrency:e,className:n}){return r("div",{className:i("RemoteFlows__EstimationResults__Headers grid grid-cols-3 items-center",n),children:[o("span",{"aria-hidden":!0}),e?r(b,{children:[o("span",{className:"RemoteFlows__EstimationResults__Headers__Label",children:"Employee currency"}),o("span",{className:"RemoteFlows__EstimationResults__Headers__Label",children:"Employer currency"})]}):r(b,{children:[o("span",{}),o("span",{className:"RemoteFlows__EstimationResults__Headers__Label",children:"Amount"})]})]})}m(W,"EstimationHeaders");function S({label:e,amounts:n,className:a,children:l}){let[_,d]=z(!0);return r("div",{className:i("RemoteFlows__EstimationResults__Row",a),children:[r("div",{className:"RemoteFlows__EstimationRow__Grid grid grid-cols-3 items-center",children:[r("div",{className:"RemoteFlows__EstimationRow__LabelContainer flex items-center gap-2",children:[o("span",{className:i("RemoteFlows__EstimationRow__Title min-w-[140px] font-medium text-[#09090B]"),children:e}),o("button",{onClick:()=>d(!_),className:"RemoteFlows__EstimationRow__CollapseButton p-1 hover:bg-gray-100 rounded",children:o(O,{className:`h-4 w-4 text-muted-foreground transition-transform ${_?"rotate-180":""}`})})]}),Array.isArray(n)?n.map((c,u)=>o("span",{className:i("RemoteFlows__EstimationRow__RegionalAmount text-right font-medium text-[#09090B]"),children:c},u)):r(b,{children:[o("span",{}),o("span",{className:i("RemoteFlows__EstimationRow__EmployerAmount text-right font-medium text-[#09090B]"),children:n})]})]}),_&&l&&o("div",{className:"RemoteFlows__EstimationRow__CollapsibleContent mt-4",children:l})]})}m(S,"EstimationRow");function X({item:e,isMultipleCurrency:n,level:a=0}){let[l,_]=z(!1),d=e.children&&e.children.length>0,c=a>0,u=e.isCollapsible||d;return r("li",{className:i("RemoteFlows__BreakdownList__Item pb-3",c&&"pb-1"),children:[r("div",{className:i(n?"RemoteFlows__BreakdownList__Grid grid grid-cols-3 items-center justify-between":"RemoteFlows__BreakdownList__Grid grid grid-cols-2 items-center justify-between"),children:[r("div",{className:i("RemoteFlows__BreakdownList__LabelContainer flex items-center gap-2",c&&"pl-3"),children:[!c&&o("span",{className:"RemoteFlows__BreakdownList__Bullet w-1 h-1 bg-[#09090B] rounded-full flex-shrink-0","aria-hidden":"true"}),u?r("button",{onClick:()=>_(!l),className:"RemoteFlows__BreakdownList__CollapseButton flex items-center gap-2 hover:bg-gray-100 rounded p-1",children:[o("span",{className:i(c?"RemoteFlows__BreakdownList__Text--Nested text-xs text-[#71717A]":"RemoteFlows__BreakdownList__Text--NotNested text-sm text-[#09090B]"),children:e.label}),o(O,{className:`RemoteFlows__BreakdownList__ChevronDown h-3 w-3 text-muted-foreground transition-transform ${l?"rotate-180":""}`})]}):o("span",{className:i(c?"RemoteFlows__BreakdownList__Text--Nested text-xs text-[#71717A]":"RemoteFlows__BreakdownList__Text--NotNested text-sm text-[#09090B] p-1"),children:e.label}),e.tooltip&&o(I,{content:r(b,{children:[o("span",{dangerouslySetInnerHTML:{__html:F(e.tooltip)}})," ",e.zendeskId&&o(f,{zendeskId:Number(e.zendeskId),children:"Learn more"})]}),children:o("button",{className:"RemoteFlows__BreakdownList__InfoButton p-1 hover:bg-gray-100 rounded",children:o(Z,{className:i("RemoteFlows__BreakdownList__InfoButton__Icon text-muted-foreground",c?"h-3 w-3":"h-4 w-4")})})})]}),n?r(b,{children:[o("span",{"data-testid":e.dataSelector&&e.dataSelector+"-employee-amount",className:i("RemoteFlows__BreakdownList__RegionalAmountText text-sm text-right",c?"RemoteFlows__BreakdownList__RegionalAmountText--Nested text-[#71717A]":"RemoteFlows__BreakdownList__RegionalAmountText--NotNested text-[#09090B]"),children:e.regionalAmount||"\u2014"}),o("span",{"data-testid":e.dataSelector&&e.dataSelector+"-employer-amount",className:i("RemoteFlows__BreakdownList__EmployerAmountText text-sm text-right",c?"RemoteFlows__BreakdownList__EmployerAmountText--Nested text-[#71717A]":"RemoteFlows__BreakdownList__EmployerAmountText--NotNested text-[#09090B]"),children:e.employerAmount||"\u2014"})]}):o("span",{"data-testid":e.dataSelector,className:i("RemoteFlows__BreakdownList__RegionalAmountText text-sm text-right",c?"RemoteFlows__BreakdownList__RegionalAmountText--Nested text-[#71717A]":"RemoteFlows__BreakdownList__RegionalAmountText--NotNested text-[#09090B]"),children:e.regionalAmount||"\u2014"})]}),d&&l&&o("div",{className:"mt-1",children:o(h,{items:e.children,isMultipleCurrency:n,level:a+1})})]})}m(X,"BreakdownListItem");function h({items:e,isMultipleCurrency:n,className:a,level:l}){return o("ul",{className:i("RemoteFlows__BreakdownList list-none",a),children:e.map((_,d)=>o(X,{item:_,isMultipleCurrency:n,level:l},d))})}m(h,"BreakdownList");var Re=m(({estimation:e,title:n,components:a,onDelete:l,onExportPdf:_,onEdit:d})=>{let c=a?.HiringSection||Q,u=a?.OnboardingTimeline||J,H=a?.Header||Y,v=a?.Footer,D=q(),p=e.employer_currency_costs.currency.code!==e.regional_currency_costs.currency.code,k=e.employer_currency_costs.monthly_management_fee,M=e.region.code!==e.country.code,G=t(e.regional_currency_costs.annual_gross_salary,e.regional_currency_costs.currency.code);return r(C,{className:"RemoteFlows__EstimationResults__Card p-10",children:[o("div",{className:"RemoteFlows__Separator",children:o(H,{title:n,annualGrossSalary:G,region:M?e.region:void 0,country:e.country,onDelete:l,onExportPdf:_,onEdit:d})}),r("div",{className:"RemoteFlows__Separator",children:[o(W,{isMultipleCurrency:p,className:"mb-3"}),o(S,{label:"Monthly total cost",amounts:p?[t(e.regional_currency_costs.monthly_total,e.regional_currency_costs.currency.code),t(e.employer_currency_costs.monthly_total,e.employer_currency_costs.currency.code)]:t(e.regional_currency_costs.monthly_total,e.regional_currency_costs.currency.code),children:o(h,{items:[{label:"Gross monthly salary",regionalAmount:t(e.regional_currency_costs.monthly_gross_salary,e.regional_currency_costs.currency.code),employerAmount:t(e.employer_currency_costs.monthly_gross_salary,e.employer_currency_costs.currency.code),zendeskId:w.extraPayments.toString(),tooltip:"This country respects extra payments on top of the gross salary."},{label:"Mandatory employer costs",regionalAmount:t(e.regional_currency_costs.monthly_contributions_total,e.regional_currency_costs.currency.code),employerAmount:t(e.employer_currency_costs.monthly_contributions_total,e.employer_currency_costs.currency.code),children:e.employer_currency_costs.monthly_contributions_breakdown?.map((s,y)=>({label:s.name,regionalAmount:t(e.regional_currency_costs.monthly_contributions_breakdown?.[y]?.amount,e.regional_currency_costs.currency.code),employerAmount:t(s.amount,e.employer_currency_costs.currency.code),zendeskId:s.zendesk_article_id||void 0,tooltip:s.description||void 0}))||[]},{label:"Benefits",regionalAmount:t(e.regional_currency_costs.monthly_benefits_total,e.regional_currency_costs.currency.code),employerAmount:t(e.employer_currency_costs.monthly_benefits_total,e.employer_currency_costs.currency.code),children:e.employer_currency_costs.monthly_benefits_breakdown?.map((s,y)=>({label:s.name,regionalAmount:t(e.regional_currency_costs.monthly_benefits_breakdown?.[y]?.amount,e.regional_currency_costs.currency.code),employerAmount:t(s.amount,e.employer_currency_costs.currency.code),zendeskId:s.zendesk_article_id||void 0,tooltip:s.description||void 0}))||[]},...k?[{label:"Monthly fee",regionalAmount:t(e.regional_currency_costs.monthly_management_fee,e.regional_currency_costs.currency.code),employerAmount:t(e.employer_currency_costs.monthly_management_fee,e.employer_currency_costs.currency.code),tooltip:"Discounts may be available based on your commitment and team size. Speak to your account or customer success manager to learn more."}]:[]],isMultipleCurrency:p})})]}),o("div",{className:"RemoteFlows__Separator",children:o(S,{label:"Annual total cost",amounts:p?[t(e.regional_currency_costs.annual_total,e.regional_currency_costs.currency.code),t(e.employer_currency_costs.annual_total,e.employer_currency_costs.currency.code)]:t(e.regional_currency_costs.annual_total,e.regional_currency_costs.currency.code),children:o(h,{items:[{label:"Gross annual salary",dataSelector:"annual-gross-salary",regionalAmount:t(e.regional_currency_costs.annual_gross_salary,e.regional_currency_costs.currency.code),employerAmount:t(e.employer_currency_costs.annual_gross_salary,e.employer_currency_costs.currency.code)},{label:"Mandatory employer costs",regionalAmount:t(e.regional_currency_costs.annual_contributions_total,e.regional_currency_costs.currency.code),employerAmount:t(e.employer_currency_costs.annual_contributions_total,e.employer_currency_costs.currency.code),children:e.employer_currency_costs.annual_contributions_breakdown?.map((s,y)=>({label:s.name,regionalAmount:t(e.regional_currency_costs.annual_contributions_breakdown?.[y]?.amount,e.regional_currency_costs.currency.code),employerAmount:t(s.amount,e.employer_currency_costs.currency.code),zendeskId:s.zendesk_article_id||void 0,tooltip:s.description||void 0}))||[]},{label:"Benefits",regionalAmount:t(e.regional_currency_costs.annual_benefits_total,e.regional_currency_costs.currency.code),employerAmount:t(e.employer_currency_costs.annual_benefits_total,e.employer_currency_costs.currency.code),children:e.employer_currency_costs.annual_benefits_breakdown?.map((s,y)=>({label:s.name,regionalAmount:t(e.regional_currency_costs.annual_benefits_breakdown?.[y]?.amount,e.regional_currency_costs.currency.code),employerAmount:t(s.amount,e.employer_currency_costs.currency.code),zendeskId:s.zendesk_article_id||void 0,tooltip:s.description||void 0}))||[]},{label:"Extra statutory payments",regionalAmount:t(e.regional_currency_costs.extra_statutory_payments_total,e.regional_currency_costs.currency.code),employerAmount:t(e.employer_currency_costs.extra_statutory_payments_total,e.employer_currency_costs.currency.code),children:e.employer_currency_costs.extra_statutory_payments_breakdown?.map((s,y)=>({label:s.name,regionalAmount:t(e.regional_currency_costs.extra_statutory_payments_breakdown?.[y]?.amount,e.regional_currency_costs.currency.code),employerAmount:t(s.amount,e.employer_currency_costs.currency.code),zendeskId:s.zendesk_article_id||void 0,tooltip:s.description||void 0}))||[]},...k?[{label:"Annual fee",regionalAmount:t(e.regional_currency_costs.annual_management_fee,e.regional_currency_costs.currency.code),employerAmount:t(e.employer_currency_costs.annual_management_fee,e.employer_currency_costs.currency.code),tooltip:"Discounts may be available based on your commitment and team size. Speak to your account or customer success manager to learn more."}]:[]],isMultipleCurrency:p})})}),o("div",{className:"RemoteFlows__Separator",children:o(u,{minimumOnboardingDays:e.minimum_onboarding_time,data:D})}),o(c,{countryBenefitsUrl:e.country_benefits_details_url,countryGuideUrl:e.country_guide_url,country:e.country}),v&&o(v,{})]})},"EstimationResults");export{Re as a};
|
|
2
|
+
//# sourceMappingURL=chunk-GZ2JKPBY.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as p}from"./chunk-EUSCQL4H.js";import{C as m,
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as p}from"./chunk-EUSCQL4H.js";import{C as m,G as C,L as d,j as l,r as u,x as c}from"./chunk-PJ6ZEFWD.js";import{d as o}from"./chunk-KQPDXXG3.js";import{a as t}from"./chunk-P37U34EQ.js";import{useMutation as a,useQuery as r}from"@tanstack/react-query";var h=t(({includePremiumBenefits:e})=>{let{client:i}=o();return r({queryKey:["cost-calculator-countries",e],queryFn:t(()=>c({client:i,query:{include_premium_benefits:e}}),"queryFn"),select:t(s=>s.data?.data.filter(n=>n.availability==="active").map(n=>({value:n.region_slug,label:n.name,childRegions:n.child_regions,hasAdditionalFields:n.has_additional_fields,regionSlug:n.region_slug,currency:n.currency.code})),"select")})},"useCostCalculatorCountries"),q=t(()=>{let{client:e}=o();return r({queryKey:["company-currencies"],queryFn:t(()=>d({client:e}),"queryFn"),select:t(i=>i.data?.data?.company_currencies.map(s=>({value:s.slug,label:s.code})),"select")})},"useCompanyCurrencies"),x=t(()=>{let{client:e}=o();return a({mutationFn:t(i=>l({client:e,body:i}),"mutationFn")})},"useCostCalculatorEstimation"),P=t(()=>{let{client:e}=o();return a({mutationFn:t(i=>u({client:e,body:i}),"mutationFn")})},"useCostCalculatorEstimationPdf"),v=t(()=>{let{client:e}=o();return a({mutationFn:t(i=>C({client:e,body:i}),"mutationFn")})},"useCostCalculatorEstimationCsv"),S=t((e,{includePremiumBenefits:i,options:s})=>{let{client:n}=o();return r({queryKey:["cost-calculator-region-fields",e,i],queryFn:t(()=>m({client:n,path:{slug:e},query:{include_premium_benefits:i}}),"queryFn"),enabled:!!e,select:t(({data:f})=>{let y=f?.data?.schema||{};return p(y,void 0,s)},"select")})},"useRegionFields");export{h as a,q as b,x as c,P as d,v as e,S as f};
|
|
2
|
+
//# sourceMappingURL=chunk-H5LGAIMM.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as o,b as r}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as o,b as r}from"./chunk-O3G6HQ3B.js";import{a as t}from"./chunk-UAACHXXX.js";import{a as e}from"./chunk-P37U34EQ.js";import{jsx as a}from"react/jsx-runtime";var n={[o]:" Remote provides its Contractor Services Agreement (CSA) \u201Cas is\u201D; it does not constitute legal advice or create an attorney-client relationship with Remote. Remote is not liable for the content You enter herein and You are encouraged to seek independent legal advice tailored to the specific relationship between You and Your Contractor. By use of the CSA, You release Remote from liability for any claim for damages or losses which may arise related to Your use thereof.",[r]:"Remote provides its Contractor Services Agreement (CSA) \u201Cas is\u201D; it does not constitute legal advice or create an attorney-client relationship with Remote. Remote is not liable for the content You enter herein and You are encouraged to seek independent legal advice tailored to the specific relationship between You and Your Contractor."},d=e(({subscription:i})=>a(t,{title:"Contractor Services Agreement",description:n[i],severity:"info"}),"StatementOfWorkDisclaimer");export{d as a};
|
|
2
|
+
//# sourceMappingURL=chunk-I3KFOOF6.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{c as d,d as S}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{c as d,d as S}from"./chunk-PKXMKBP4.js";import{a as u}from"./chunk-HN5HLFTB.js";import{a as f}from"./chunk-KSHK3ZPX.js";import{b as C}from"./chunk-LNV36S6D.js";import{f as y}from"./chunk-H5CNWMEM.js";import{a as o}from"./chunk-P37U34EQ.js";import{useEffect as T,useId as U,useState as I}from"react";import{jsx as k}from"react/jsx-runtime";var l=o((n,e,r)=>r&&r[e]?r[e]:n[e]?n[e]/100:0,"getDefaultManagementFee"),A=o((n,e,r,g)=>!e&&!r?.management_fee&&n?l(u,n,g):e&&!r?.management_fee?"":r?.management_fee,"getManagementFee"),W=o(({estimationOptions:n=d,defaultValues:e={countryRegionSlug:"",regionSlug:"",currencySlug:"",salary:"",benefits:{},management:{management_fee:""}},options:r,render:g,version:_="standard"})=>{let p=U(),[R,m]=I("USD"),F=o(s=>{m(s);let a=l(u,s,n.managementFees);a&&c.setValue("management.management_fee",a.toString())},"onCurrencyChange"),t=S({defaultRegion:e.countryRegionSlug,defaultCurrency:e.currencySlug,defaultSalary:e.salary,estimationOptions:n,version:_,options:{...r,onCurrencyChange:F}}),K=C(t.handleValidation),b=A(R,e.currencySlug,e.management,n.managementFees),{countryRegionSlug:v,currencySlug:h,salary:D,benefits:P,hiringBudget:B,age:E,contractDurationType:M,regionSlug:w,...x}=e,c=y({resolver:K,defaultValues:{country:v,currency:h,region:w,salary:D,salary_conversion:"",salary_converted:void 0,hiring_budget:B||"employee_annual_salary",age:E,contract_duration_type:M,management:{management_fee:b?.toString()||""},benefits:P,estimation_title:n.title,...x},shouldUnregister:!1,mode:"onBlur"});return T(()=>{if(e.currencySlug&&t.currencies&&n.includeManagementFee&&!e.management?.management_fee){let a=t.currencies.find(i=>i.value===e.currencySlug)?.label;if(a){m(a);let i=l(u,a,n.managementFees);c.setValue("management.management_fee",i?.toString()||"")}}},[e.currencySlug,t.currencies,n.includeManagementFee,n.managementFees,e.management?.management_fee,c]),k(f.Provider,{value:{form:c,formId:p,costCalculatorBag:t},children:g(t)})},"CostCalculatorFlow");export{W as a};
|
|
2
|
+
//# sourceMappingURL=chunk-IVUCPXEC.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{b as u}from"./chunk-Q3ALCPJN.js";import{d}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{b as u}from"./chunk-Q3ALCPJN.js";import{d}from"./chunk-4ECYU3L5.js";import{a as m}from"./chunk-3X36ZFNP.js";import{b as a}from"./chunk-KQPDXXG3.js";import{a as n}from"./chunk-P37U34EQ.js";import{jsx as v}from"react/jsx-runtime";function R({onSubmit:c,onSuccess:p,onError:e,render:l,...o}){let{components:E}=a(),{contractorOnboardingBag:t}=u(),i=d(),{mutateAsync:f}=m(i),y=n(async()=>{try{if(await c?.(),t.employmentId){let r=await f({employment_id:t.employmentId});if(r.data){await p?.({data:r.data,employmentStatus:"invited"}),t.refetchEmployment();return}r.error&&e?.({error:r.error,rawError:r.rawError,fieldErrors:[]})}}catch(r){e?.({error:r,rawError:r,fieldErrors:[]})}},"handleSubmit"),s=E?.button;if(!s)throw new Error("Button component not found");return v(s,{...o,disabled:i.isPending||o.disabled,onClick:r=>{y(),o.onClick?.(r)},children:l({employmentStatus:"invited"})})}n(R,"OnboardingInvite");export{R as a};
|
|
2
|
+
//# sourceMappingURL=chunk-JZWOMKR3.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a as xt,b as Ut,c as Nt}from"./chunk-4APMRCE7.js";import{a as qt,b as At,c as jt}from"./chunk-FC2V3NUT.js";import{a as Vt,b as It,c as Dt,d as Ot,f as Mt,g as Tt,h as Lt,i as Rt,j as Bt,k as Jt,l as kt}from"./chunk-TCLY24DF.js";import{a as x,b as Z,c as vt}from"./chunk-O3G6HQ3B.js";import{f as Ct,h as wt,i as ht,k as Ft}from"./chunk-4ECYU3L5.js";import{c as St,d as bt}from"./chunk-STF3NTPS.js";import{a as Pt}from"./chunk-Q445EJX6.js";import{a as gt,e as f,f as v}from"./chunk-T7O3YYOG.js";import{F as yt,P as _t}from"./chunk-PJ6ZEFWD.js";import{h as w,i as R}from"./chunk-J63QA2JC.js";import{a as E}from"./chunk-3X36ZFNP.js";import{a as Et}from"./chunk-5BRMLRS7.js";import{d as j}from"./chunk-KQPDXXG3.js";import{a}from"./chunk-P37U34EQ.js";import{useEffect as Qt,useMemo as l,useRef as Re,useState as $}from"react";import Ht from"lodash.omit";import{useQuery as Me}from"@tanstack/react-query";import{useQuery as Oe}from"@tanstack/react-query";var Gt=a(()=>{let{client:d}=j();return Oe({queryKey:["identity"],queryFn:a(()=>_t({client:d,headers:{Authorization:""}}),"queryFn"),select:a(y=>y.data?.data,"select")})},"useIdentity");function Te(d){return d!=null&&"company"in d}a(Te,"hasCompany");var Le=a(()=>{let{client:d}=j(),{data:y}=Gt(),r=Te(y)?y?.company?.id??"":"";return Me({queryKey:["legal-entities",r],queryFn:a(()=>yt({client:d,path:{company_id:r}}),"queryFn"),select:a(U=>U.data?.data?.legal_entities,"select"),enabled:!!r})},"useLegalEntities"),Kt=a(()=>{let{data:d}=Le();return d?.find(y=>y.is_default)},"useDefaultLegalEntity");var Be={select_country:null,basic_information:"employment_basic_information",contract_details:null,pricing_plan:null,contract_preview:null,review:null},Je={employment_basic_information:"basic_information"},ke=new Date().toISOString().split("T")[0],yn=a(({countryCode:d,externalId:y,employmentId:r,skipSteps:U,options:h,initialValues:u})=>{let[s,tt]=$(d||null),[c,Wt]=$(r),[S,et]=$(void 0),B=Re({select_country:{},basic_information:{},contract_details:{},contract_preview:{},pricing_plan:{}}),zt=U?.includes("select_country")?At:qt,{fieldValues:m,stepState:n,setFieldValues:Yt,previousStep:Xt,nextStep:Zt,goToStep:N,setStepValues:nt}=Et(zt),{data:i,isLoading:$t,refetch:te}=Pt({employmentId:c,queryParams:{exclude_files:!0}}),ee=Kt(),{status:F}=i||{},V=F&&St.includes(F),ne=F&&!bt.includes(F),oe=l(()=>F==="invited"?"invited":"not_invited",[F]),ot=wt(),it=ht(s,h),G=Tt(),at=Vt(),{mutateAsync:rt}=Bt(G,at,m),{mutateAsyncOrThrow:ie}=E(it),st=Dt(),ct=Mt(),{mutateAsyncOrThrow:ae}=E(ot),{mutateAsyncOrThrow:re}=E(G),{mutateAsyncOrThrow:se}=E(st),{mutateAsyncOrThrow:lt}=E(ct);r&&i?.country?.code&&!s&&tt(i.country.code);let{selectCountryForm:J,isLoading:ce}=Ft({jsfModify:h?.jsfModify?.select_country,queryOptions:{enabled:n.currentStep.name==="select_country"}}),{form:b,isLoading:le}=Rt(c,{jsonSchemaVersion:h?.jsonSchemaVersion,queryOptions:{enabled:n.currentStep.name==="pricing_plan"||!!r&&V}}),de=Be[n.currentStep.name]||"contractor_basic_information",ue=Je[de],me=i?.[ue]||{},pe=a(({form:t,options:o={},query:p={}})=>{let P=Object.keys(m).length>0?{...u,...n.values?.[n.currentStep.name],...m}:{...u,...me};return Ct({countryCode:s,form:t,fieldValues:P,query:p,options:{...o,queryOptions:{enabled:o.queryOptions?.enabled??!0}}})},"useJSONSchema"),fe=!!(s&&(n.currentStep.name==="basic_information"||r)),ye=!!(s&&(n.currentStep.name==="contract_details"||r)),_e=!!(s==="GBR"&&r&&n.currentStep.name==="basic_information"),{data:I,isLoading:ge}=Jt(r,{enabled:_e}),{data:k,isLoading:Se}=kt(r,{enabled:!!r});Qt(()=>{k&&k.length>0&&!S&&et(k[0].id)},[k,S]);let{data:_,isLoading:be}=pe({form:"contractor_basic_information",options:{jsfModify:Ut(s,h),queryOptions:{enabled:fe}}}),Ce=l(()=>jt(i?.basic_information?.provisional_start_date,m?.service_duration?.provisional_start_date),[i?.basic_information?.provisional_start_date,m?.service_duration?.provisional_start_date]),K=l(()=>i?.contractor_type?{standard:x,plus:Z,cor:vt}[i?.contractor_type]||x:void 0,[i]),{data:g,isLoading:we}=Lt({countryCode:s,fieldValues:m,options:{queryOptions:{enabled:ye},jsfModify:xt(h?.jsfModify?.contract_details,Ce,K,m)}}),he=l(()=>n.currentStep.name==="contract_preview"||!!r&&V,[n.currentStep.name,r,V]),{data:C}=It({fieldValues:m,options:{queryOptions:{enabled:he},jsfModify:Nt(h,m)}}),{data:Q,isLoading:Fe}=Ot({employmentId:c,contractDocumentId:S,options:{queryOptions:{enabled:!!S}}}),e=l(()=>({select_country:J?.fields||[],basic_information:_?.fields||[],pricing_plan:b?.fields||[],contract_details:g?.fields||[],contract_preview:C?.fields||[],review:[]}),[J?.fields,_?.fields,b?.fields,g?.fields,C?.fields]),Pe={select_country:null,basic_information:_?.meta["x-jsf-fieldsets"],pricing_plan:null,contract_details:g?.meta["x-jsf-fieldsets"],contract_preview:null,review:null},{country:Ee,basic_information:q={},contract_details:dt={}}=i||{},ut=Ee?.code,D=l(()=>v(e.select_country,{country:s||ut||""}),[e.select_country,s,ut]),H=l(()=>I?.content?gt(I.content,I.name):null,[I?.content,I?.name]),O=l(()=>{let t={provisional_start_date:ke,...u,...q,ir35:i?.contract_details?.ir_35,saudi_nationality_status:i?.contract_details?.nationality,...H&&{ir35_sds_file:[H]}};return v(e.basic_information,t)},[u,q,i?.contract_details?.ir_35,i?.contract_details?.nationality,H,e.basic_information]),M=l(()=>{let o={...{service_duration:{provisional_start_date:q.provisional_start_date}},...u,...dt};return v(e.contract_details,o)},[e.contract_details,dt,u,q]),A=l(()=>{let t=Q?.contract_document?.signatories?.find(p=>p.type==="company"),o={...u,signature:t?.signature};return v(e.contract_preview,o)},[e.contract_preview,u,Q]),T=l(()=>{let o={...{subscription:K},...u};return v(e.pricing_plan,o)},[e.pricing_plan,u,K]),ve=l(()=>({select_country:D,basic_information:O,contract_details:M,contract_preview:A,pricing_plan:T}),[D,O,M,A,T]),W=!!(r&&V&&n.currentStep.name!=="review"),z=ce||be||$t||we||le||Fe||ge||Se,mt=l(()=>!!(W&&!z&&S&&e.basic_information.length>0&&e.contract_details.length>0&&e.contract_preview.length>0),[W,z,S,e.basic_information.length,e.contract_details.length,e.contract_preview.length]);Qt(()=>{mt&&(B.current={select_country:w(D,e.select_country),basic_information:w(O,e.basic_information),contract_details:w(M,e.contract_details),contract_preview:w(A,e.contract_preview),pricing_plan:w(T,e.pricing_plan)},nt({select_country:D,basic_information:O,contract_details:M,contract_preview:{},pricing_plan:T,review:{}}),N("review"))},[mt,N,D,O,M,nt,e.select_country,e.basic_information,e.contract_details,e.pricing_plan,T,e.contract_preview,A]);let Ve=a(t=>{N(t)},"goTo"),pt=a(async t=>J&&n.currentStep.name==="select_country"?t:_&&n.currentStep.name==="basic_information"?await f(t,_?.fields,{isPartialValidation:!1}):g&&n.currentStep.name==="contract_details"?await f(t,g?.fields,{isPartialValidation:!1}):C&&n.currentStep.name==="contract_preview"?await f(t,C?.fields,{isPartialValidation:!1}):b&&n.currentStep.name==="pricing_plan"?await f(t,b?.fields,{isPartialValidation:!1}):{},"parseFormValues");async function Ie(t){let o=n.currentStep.name;o in B.current&&(B.current[o]=w(t,e[o]));let p=await pt(t);switch(n.currentStep.name){case"select_country":return tt(p.country),Promise.resolve({data:{countryCode:p.country}});case"basic_information":{let Y=!c&&s,P=c&&s&&i?.country&&i?.country.code!==s;if(Y||P){let De={basic_information:Ht(p,"saudi_nationality_status","ir35","ir35_sds_file"),type:"contractor",country_code:s,external_id:y},ft=await ae(De),X=ft?.data?.employment?.id;if(!X)throw R("Employment ID not found");return Wt(X),await rt({employmentId:X}),ft}else if(c){let L=Ht(p,"saudi_nationality_status","ir35","ir35_sds_file");return await rt({employmentId:c}),ie({employmentId:c,basic_information:L})}return}case"contract_details":{let P=await re({employmentId:c,payload:{contract_document:p}}),L=P?.data?.contract_document?.id;if(!L)throw R("Contract document ID not found");return et(L),P}case"contract_preview":return se({employmentId:c,contractDocumentId:S,payload:{signature:t.signature}});case"pricing_plan":{if(t.subscription==x)return lt({employmentId:c,payload:{operation:"downgrade"}});if(t.subscription==Z)return lt({employmentId:c,payload:{operation:"upgrade"}});throw R("invalid selection")}default:throw R("Invalid step state")}}return a(Ie,"onSubmit"),{isLoading:z||W,fieldValues:m,stepState:n,checkFieldUpdates:Yt,back:Xt,next:Zt,goTo:Ve,onSubmit:Ie,fields:e[n.currentStep.name],meta:{fields:B.current,fieldsets:Pe[n.currentStep.name]},parseFormValues:pt,handleValidation:a(async t=>{if(n.currentStep.name==="select_country")return J.handleValidation(t);if(_&&n.currentStep.name==="basic_information"){let o=await f(t,_?.fields,{isPartialValidation:!1});return _?.handleValidation(o)}if(g&&n.currentStep.name==="contract_details"){let o=await f(t,g?.fields,{isPartialValidation:!1});return g?.handleValidation(o)}if(C&&n.currentStep.name==="contract_preview"){let o=await f(t,C?.fields,{isPartialValidation:!0});return C?.handleValidation(o)}if(b&&n.currentStep.name==="pricing_plan"){let o=await f(t,b?.fields,{isPartialValidation:!1});return b?.handleValidation(o)}return null},"handleValidation"),initialValues:ve,employmentId:c,refetchEmployment:te,isSubmitting:ot.isPending||it.isPending||G.isPending||st.isPending||ct.isPending||at.isPending,documentPreviewPdf:Q,canInvite:ne,isEmploymentReadOnly:V,invitedStatus:oe,employment:i,defaultLegalEntity:ee}},"useContractorOnboarding");export{yn as a};
|
|
2
|
+
//# sourceMappingURL=chunk-KXOVDXNX.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/flows/ContractorOnboarding/hooks.tsx","../src/common/api/legal-entities.ts","../src/common/api/identity.ts"],"sourcesContent":["import { useEffect, useMemo, useRef, useState } from 'react';\nimport { FieldValues } from 'react-hook-form';\nimport omit from 'lodash.omit';\nimport { JSFFields } from '@/src/types/remoteFlows';\nimport {\n CreateContractDocument,\n Employment,\n EmploymentCreateParams,\n} from '@/src/client/types.gen';\nimport {\n getInitialValues,\n parseJSFToValidate,\n} from '@/src/components/form/utils';\nimport { ValidationResult } from '@remoteoss/remote-json-schema-form-kit';\nimport {\n useContractorOnboardingDetailsSchema,\n useCreateContractorContractDocument,\n useGetContractDocumentSignatureSchema,\n usePostManageContractorSubscriptions,\n useContractorSubscriptionSchemaField,\n useGetShowContractDocument,\n useSignContractDocument,\n useUpdateUKandSaudiFields,\n useGetIR35File,\n useGetContractDocuments,\n} from '@/src/flows/ContractorOnboarding/api';\nimport { ContractorOnboardingFlowProps } from '@/src/flows/ContractorOnboarding/types';\nimport {\n STEPS,\n STEPS_WITHOUT_SELECT_COUNTRY,\n calculateProvisionalStartDateDescription,\n} from '@/src/flows/ContractorOnboarding/utils';\nimport {\n useCountriesSchemaField,\n useCreateEmployment,\n useJSONSchemaForm,\n useUpdateEmployment,\n} from '@/src/flows/Onboarding/api';\nimport {\n disabledInviteButtonEmploymentStatus,\n reviewStepAllowedEmploymentStatus,\n} from '@/src/flows/Onboarding/utils';\nimport { FlowOptions, JSFModify, JSONSchemaFormType } from '@/src/flows/types';\nimport { Step, useStepState } from '@/src/flows/useStepState';\nimport { mutationToPromise } from '@/src/lib/mutations';\nimport { createStructuredError, prettifyFormValues } from '@/src/lib/utils';\nimport { JSFFieldset, Meta } from '@/src/types/remoteFlows';\nimport {\n contractorStandardProductIdentifier,\n contractorPlusProductIdentifier,\n corProductIdentifier,\n} from '@/src/flows/ContractorOnboarding/constants';\nimport {\n buildBasicInformationJsfModify,\n buildContractDetailsJsfModify,\n buildContractPreviewJsfModify,\n} from '@/src/flows/ContractorOnboarding/jsfModify';\nimport { useUploadFile } from '@/src/common/api/files';\nimport { dataURLtoFile } from '@/src/lib/files';\nimport { useEmploymentQuery } from '@/src/common/api/employment';\nimport { useDefaultLegalEntity } from '@/src/common/api/legal-entities';\n\ntype useContractorOnboardingProps = Omit<\n ContractorOnboardingFlowProps,\n 'render'\n>;\n\nconst stepToFormSchemaMap: Record<\n keyof typeof STEPS,\n JSONSchemaFormType | null\n> = {\n select_country: null,\n basic_information: 'employment_basic_information',\n contract_details: null,\n pricing_plan: null,\n contract_preview: null,\n review: null,\n};\n\nconst jsonSchemaToEmployment: Partial<\n Record<JSONSchemaFormType, keyof Employment>\n> = {\n employment_basic_information: 'basic_information',\n};\n\nconst provisionalStartDate = new Date().toISOString().split('T')[0];\n\nexport const useContractorOnboarding = ({\n countryCode,\n externalId,\n employmentId,\n skipSteps,\n options,\n initialValues: onboardingInitialValues,\n}: useContractorOnboardingProps) => {\n const [internalCountryCode, setInternalCountryCode] = useState<string | null>(\n countryCode || null,\n );\n const [internalEmploymentId, setInternalEmploymentId] = useState<\n string | undefined\n >(employmentId);\n const [internalContractDocumentId, setInternalContractDocumentId] = useState<\n string | undefined\n >(undefined);\n const fieldsMetaRef = useRef<{\n select_country: Meta;\n basic_information: Meta;\n contract_details: Meta;\n contract_preview: Meta;\n pricing_plan: Meta;\n }>({\n select_country: {},\n basic_information: {},\n contract_details: {},\n contract_preview: {},\n pricing_plan: {},\n });\n\n const stepsToUse = skipSteps?.includes('select_country')\n ? STEPS_WITHOUT_SELECT_COUNTRY\n : STEPS;\n\n const {\n fieldValues,\n stepState,\n setFieldValues,\n previousStep,\n nextStep,\n goToStep,\n setStepValues,\n } = useStepState(\n stepsToUse as Record<keyof typeof STEPS, Step<keyof typeof STEPS>>,\n );\n\n const {\n data: employment,\n isLoading: isLoadingEmployment,\n refetch: refetchEmployment,\n } = useEmploymentQuery({\n employmentId: internalEmploymentId as string,\n queryParams: { exclude_files: true },\n });\n\n const defaultLegalEntity = useDefaultLegalEntity();\n\n const { status: employmentStatus } = employment || {};\n\n const isEmploymentReadOnly =\n employmentStatus &&\n reviewStepAllowedEmploymentStatus.includes(employmentStatus);\n\n const canInvite =\n employmentStatus &&\n !disabledInviteButtonEmploymentStatus.includes(employmentStatus);\n\n const invitedStatus: 'invited' | 'not_invited' = useMemo(() => {\n const isInvited = employmentStatus === 'invited';\n\n return isInvited ? 'invited' : 'not_invited';\n }, [employmentStatus]);\n\n const createEmploymentMutation = useCreateEmployment();\n const updateEmploymentMutation = useUpdateEmployment(\n internalCountryCode as string,\n options,\n );\n const createContractorContractDocumentMutation =\n useCreateContractorContractDocument();\n const uploadFileMutation = useUploadFile();\n const { mutateAsync: updateUKandSaudiFieldsMutation } =\n useUpdateUKandSaudiFields(\n createContractorContractDocumentMutation,\n uploadFileMutation,\n fieldValues,\n );\n\n const { mutateAsyncOrThrow: updateEmploymentMutationAsync } =\n mutationToPromise(updateEmploymentMutation);\n const signContractDocumentMutation = useSignContractDocument();\n const manageContractorSubscriptionMutation =\n usePostManageContractorSubscriptions();\n\n const { mutateAsyncOrThrow: createEmploymentMutationAsync } =\n mutationToPromise(createEmploymentMutation);\n\n const { mutateAsyncOrThrow: createContractorContractDocumentMutationAsync } =\n mutationToPromise(createContractorContractDocumentMutation);\n\n const { mutateAsyncOrThrow: signContractDocumentMutationAsync } =\n mutationToPromise(signContractDocumentMutation);\n\n const { mutateAsyncOrThrow: manageContractorSubscriptionMutationAsync } =\n mutationToPromise(manageContractorSubscriptionMutation);\n\n // if the employment is loaded, country code has not been set yet\n // we set the internal country code with the employment country code\n if (employmentId && employment?.country?.code && !internalCountryCode) {\n setInternalCountryCode(employment.country.code);\n }\n\n const { selectCountryForm, isLoading: isLoadingCountries } =\n useCountriesSchemaField({\n jsfModify: options?.jsfModify?.select_country,\n queryOptions: {\n enabled: stepState.currentStep.name === 'select_country',\n },\n });\n\n const {\n form: selectContractorSubscriptionForm,\n isLoading: isLoadingContractorSubscriptions,\n } = useContractorSubscriptionSchemaField(internalEmploymentId as string, {\n jsonSchemaVersion: options?.jsonSchemaVersion,\n queryOptions: {\n enabled:\n stepState.currentStep.name === 'pricing_plan' ||\n (Boolean(employmentId) && isEmploymentReadOnly),\n },\n });\n\n const formType =\n stepToFormSchemaMap[stepState.currentStep.name] ||\n 'contractor_basic_information';\n const employmentKey = jsonSchemaToEmployment[formType] as keyof Employment;\n const serverEmploymentData = (employment?.[employmentKey] || {}) as Record<\n string,\n unknown\n >;\n\n const useJSONSchema = ({\n form,\n options: jsonSchemaOptions = {},\n query = {},\n }: {\n form: JSONSchemaFormType;\n options?: {\n jsfModify?: JSFModify;\n queryOptions?: { enabled?: boolean };\n jsonSchemaVersion?: FlowOptions['jsonSchemaVersion'];\n };\n query?: Record<string, string>;\n }) => {\n const hasUserEnteredAnyValues = Object.keys(fieldValues).length > 0;\n // when you write on the fields, the values are stored in the fieldValues state\n // when values are stored in the stepState is when the user has navigated to the step\n // and then we have the values from the server and the onboardingInitialValues that the user can inject,\n const mergedFormValues = hasUserEnteredAnyValues\n ? {\n ...onboardingInitialValues,\n ...stepState.values?.[stepState.currentStep.name], // Restore values for the current step\n ...fieldValues,\n }\n : {\n ...onboardingInitialValues,\n ...serverEmploymentData,\n };\n\n return useJSONSchemaForm({\n countryCode: internalCountryCode as string,\n form: form,\n fieldValues: mergedFormValues,\n query,\n options: {\n ...jsonSchemaOptions,\n queryOptions: {\n enabled: jsonSchemaOptions.queryOptions?.enabled ?? true,\n },\n },\n });\n };\n\n const isBasicInformationDetailsEnabled = Boolean(\n internalCountryCode &&\n (stepState.currentStep.name === 'basic_information' ||\n Boolean(employmentId)),\n );\n\n const isContractorOnboardingDetailsEnabled = Boolean(\n internalCountryCode &&\n (stepState.currentStep.name === 'contract_details' ||\n Boolean(employmentId)),\n );\n\n const isIR35FileEnabled = Boolean(\n internalCountryCode === 'GBR' &&\n employmentId &&\n stepState.currentStep.name === 'basic_information',\n );\n\n const { data: ir35File, isLoading: isLoadingIR35File } = useGetIR35File(\n employmentId as string,\n {\n enabled: isIR35FileEnabled,\n },\n );\n\n const { data: contractDocuments, isLoading: isLoadingContractDocuments } =\n useGetContractDocuments(employmentId as string, {\n enabled: Boolean(employmentId),\n });\n\n useEffect(() => {\n if (\n contractDocuments &&\n contractDocuments.length > 0 &&\n !internalContractDocumentId\n ) {\n setInternalContractDocumentId(contractDocuments[0].id);\n }\n }, [contractDocuments, internalContractDocumentId]);\n\n const {\n data: basicInformationForm,\n isLoading: isLoadingBasicInformationForm,\n } = useJSONSchema({\n form: 'contractor_basic_information',\n options: {\n jsfModify: buildBasicInformationJsfModify(\n internalCountryCode as string,\n options,\n ),\n queryOptions: {\n enabled: isBasicInformationDetailsEnabled,\n },\n },\n });\n\n const descriptionProvisionalStartDate = useMemo(() => {\n return calculateProvisionalStartDateDescription(\n employment?.basic_information?.provisional_start_date as string,\n fieldValues?.service_duration?.provisional_start_date as string,\n );\n }, [\n employment?.basic_information?.provisional_start_date,\n fieldValues?.service_duration?.provisional_start_date,\n ]);\n\n const selectedPricingPlan = useMemo(() => {\n if (!employment?.contractor_type) {\n return undefined;\n }\n const subscriptions = {\n standard: contractorStandardProductIdentifier,\n plus: contractorPlusProductIdentifier,\n cor: corProductIdentifier,\n };\n return (\n subscriptions[\n employment?.contractor_type as keyof typeof subscriptions\n ] || contractorStandardProductIdentifier\n );\n }, [employment]);\n\n const {\n data: contractorOnboardingDetailsForm,\n isLoading: isLoadingContractorOnboardingDetailsForm,\n } = useContractorOnboardingDetailsSchema({\n countryCode: internalCountryCode as string,\n fieldValues: fieldValues,\n options: {\n queryOptions: {\n enabled: isContractorOnboardingDetailsEnabled,\n },\n jsfModify: buildContractDetailsJsfModify(\n options?.jsfModify?.contract_details,\n descriptionProvisionalStartDate,\n selectedPricingPlan,\n fieldValues,\n ),\n },\n });\n\n const isSignatureSchemaEnabled = useMemo(() => {\n return (\n stepState.currentStep.name === 'contract_preview' ||\n (Boolean(employmentId) && isEmploymentReadOnly)\n );\n }, [stepState.currentStep.name, employmentId, isEmploymentReadOnly]);\n\n const { data: signatureSchemaForm } = useGetContractDocumentSignatureSchema({\n fieldValues: fieldValues,\n options: {\n queryOptions: {\n enabled: isSignatureSchemaEnabled,\n },\n jsfModify: buildContractPreviewJsfModify(options, fieldValues),\n },\n });\n\n const { data: documentPreviewPdf, isLoading: isLoadingDocumentPreviewForm } =\n useGetShowContractDocument({\n employmentId: internalEmploymentId as string,\n contractDocumentId: internalContractDocumentId as string,\n options: {\n queryOptions: {\n enabled: Boolean(internalContractDocumentId),\n },\n },\n });\n\n const stepFields: Record<keyof typeof STEPS, JSFFields> = useMemo(\n () => ({\n select_country: selectCountryForm?.fields || [],\n basic_information: basicInformationForm?.fields || [],\n pricing_plan: selectContractorSubscriptionForm?.fields || [],\n contract_details: contractorOnboardingDetailsForm?.fields || [],\n contract_preview: signatureSchemaForm?.fields || [],\n review: [],\n }),\n [\n selectCountryForm?.fields,\n basicInformationForm?.fields,\n selectContractorSubscriptionForm?.fields,\n contractorOnboardingDetailsForm?.fields,\n signatureSchemaForm?.fields,\n ],\n );\n\n const stepFieldsWithFlatFieldsets: Record<\n keyof typeof STEPS,\n JSFFieldset | null | undefined\n > = {\n select_country: null,\n basic_information: basicInformationForm?.meta['x-jsf-fieldsets'],\n pricing_plan: null,\n contract_details: contractorOnboardingDetailsForm?.meta['x-jsf-fieldsets'],\n contract_preview: null,\n review: null,\n };\n\n const {\n country,\n basic_information: employmentBasicInformation = {},\n contract_details: employmentContractDetails = {},\n } = employment || {};\n\n const employmentCountryCode = country?.code;\n\n const selectCountryInitialValues = useMemo(\n () =>\n getInitialValues(stepFields.select_country, {\n country: internalCountryCode || employmentCountryCode || '',\n }),\n [stepFields.select_country, internalCountryCode, employmentCountryCode],\n );\n\n // memoize file conversion to avoid re-converting the file on every render\n // noticed performance issues when not doing memoizing individually\n const convertedIr35File = useMemo(() => {\n if (!ir35File?.content) return null;\n return dataURLtoFile(ir35File.content as unknown as string, ir35File.name);\n }, [ir35File?.content, ir35File?.name]);\n\n const basicInformationInitialValues = useMemo(() => {\n const initialValues = {\n provisional_start_date: provisionalStartDate,\n ...onboardingInitialValues,\n ...employmentBasicInformation,\n ir35: employment?.contract_details?.ir_35,\n saudi_nationality_status: employment?.contract_details?.nationality,\n ...(convertedIr35File && {\n ir35_sds_file: [convertedIr35File],\n }),\n };\n\n return getInitialValues(stepFields.basic_information, initialValues);\n }, [\n onboardingInitialValues,\n employmentBasicInformation,\n employment?.contract_details?.ir_35,\n employment?.contract_details?.nationality,\n convertedIr35File,\n stepFields.basic_information,\n ]);\n\n const contractDetailsInitialValues = useMemo(() => {\n const hardcodedValues = {\n service_duration: {\n provisional_start_date:\n employmentBasicInformation.provisional_start_date,\n },\n };\n const initialValues = {\n ...hardcodedValues,\n ...onboardingInitialValues,\n ...employmentContractDetails,\n };\n\n return getInitialValues(stepFields.contract_details, initialValues);\n }, [\n stepFields.contract_details,\n employmentContractDetails,\n onboardingInitialValues,\n employmentBasicInformation,\n ]);\n\n const contractPreviewInitialValues = useMemo(() => {\n const signature = documentPreviewPdf?.contract_document?.signatories?.find(\n (signatory) => signatory.type === 'company',\n );\n const initialValues = {\n ...onboardingInitialValues,\n signature: signature?.signature,\n };\n\n return getInitialValues(stepFields.contract_preview, initialValues);\n }, [\n stepFields.contract_preview,\n onboardingInitialValues,\n documentPreviewPdf,\n ]);\n\n const pricingPlanInitialValues = useMemo(() => {\n const preselectedPricingPlan = {\n subscription: selectedPricingPlan,\n };\n const initialValues = {\n ...preselectedPricingPlan,\n ...onboardingInitialValues,\n };\n\n return getInitialValues(stepFields.pricing_plan, initialValues);\n }, [stepFields.pricing_plan, onboardingInitialValues, selectedPricingPlan]);\n\n const initialValues = useMemo(() => {\n return {\n select_country: selectCountryInitialValues,\n basic_information: basicInformationInitialValues,\n contract_details: contractDetailsInitialValues,\n contract_preview: contractPreviewInitialValues,\n pricing_plan: pricingPlanInitialValues,\n };\n }, [\n selectCountryInitialValues,\n basicInformationInitialValues,\n contractDetailsInitialValues,\n contractPreviewInitialValues,\n pricingPlanInitialValues,\n ]);\n\n const shouldHandleReadOnlyEmployment = Boolean(\n employmentId &&\n isEmploymentReadOnly &&\n stepState.currentStep.name !== 'review',\n );\n\n const initialLoading =\n isLoadingCountries ||\n isLoadingBasicInformationForm ||\n isLoadingEmployment ||\n isLoadingContractorOnboardingDetailsForm ||\n isLoadingContractorSubscriptions ||\n isLoadingDocumentPreviewForm ||\n isLoadingIR35File ||\n isLoadingContractDocuments;\n\n const isNavigatingToReview = useMemo(() => {\n return Boolean(\n shouldHandleReadOnlyEmployment &&\n !initialLoading &&\n Boolean(internalContractDocumentId) &&\n stepFields.basic_information.length > 0 &&\n stepFields.contract_details.length > 0 &&\n stepFields.contract_preview.length > 0,\n );\n }, [\n shouldHandleReadOnlyEmployment,\n initialLoading,\n internalContractDocumentId,\n stepFields.basic_information.length,\n stepFields.contract_details.length,\n stepFields.contract_preview.length,\n ]);\n\n useEffect(() => {\n if (isNavigatingToReview) {\n fieldsMetaRef.current = {\n select_country: prettifyFormValues(\n selectCountryInitialValues,\n stepFields.select_country,\n ),\n basic_information: prettifyFormValues(\n basicInformationInitialValues,\n stepFields.basic_information,\n ),\n contract_details: prettifyFormValues(\n contractDetailsInitialValues,\n stepFields.contract_details,\n ),\n contract_preview: prettifyFormValues(\n contractPreviewInitialValues,\n stepFields.contract_preview,\n ),\n pricing_plan: prettifyFormValues(\n pricingPlanInitialValues,\n stepFields.pricing_plan,\n ),\n };\n\n setStepValues({\n select_country: selectCountryInitialValues,\n basic_information: basicInformationInitialValues,\n contract_details: contractDetailsInitialValues,\n contract_preview: {},\n pricing_plan: pricingPlanInitialValues,\n review: {},\n });\n goToStep('review');\n }\n }, [\n isNavigatingToReview,\n goToStep,\n selectCountryInitialValues,\n basicInformationInitialValues,\n contractDetailsInitialValues,\n setStepValues,\n stepFields.select_country,\n stepFields.basic_information,\n stepFields.contract_details,\n stepFields.pricing_plan,\n pricingPlanInitialValues,\n stepFields.contract_preview,\n contractPreviewInitialValues,\n ]);\n\n const goTo = (step: keyof typeof STEPS) => {\n goToStep(step);\n };\n\n const parseFormValues = async (values: FieldValues) => {\n if (selectCountryForm && stepState.currentStep.name === 'select_country') {\n return values;\n }\n\n if (\n basicInformationForm &&\n stepState.currentStep.name === 'basic_information'\n ) {\n return await parseJSFToValidate(values, basicInformationForm?.fields, {\n isPartialValidation: false,\n });\n }\n\n if (\n contractorOnboardingDetailsForm &&\n stepState.currentStep.name === 'contract_details'\n ) {\n return await parseJSFToValidate(\n values,\n contractorOnboardingDetailsForm?.fields,\n {\n isPartialValidation: false,\n },\n );\n }\n\n if (\n signatureSchemaForm &&\n stepState.currentStep.name === 'contract_preview'\n ) {\n return await parseJSFToValidate(values, signatureSchemaForm?.fields, {\n isPartialValidation: false,\n });\n }\n\n if (\n selectContractorSubscriptionForm &&\n stepState.currentStep.name === 'pricing_plan'\n ) {\n return await parseJSFToValidate(\n values,\n selectContractorSubscriptionForm?.fields,\n {\n isPartialValidation: false,\n },\n );\n }\n\n return {};\n };\n\n async function onSubmit(values: FieldValues) {\n const currentStepName = stepState.currentStep.name;\n if (currentStepName in fieldsMetaRef.current) {\n fieldsMetaRef.current[\n currentStepName as keyof typeof fieldsMetaRef.current\n ] = prettifyFormValues(values, stepFields[currentStepName]);\n }\n const parsedValues = await parseFormValues(values);\n switch (stepState.currentStep.name) {\n case 'select_country': {\n setInternalCountryCode(parsedValues.country);\n return Promise.resolve({ data: { countryCode: parsedValues.country } });\n }\n case 'basic_information': {\n const isEmploymentNotLoaded =\n !internalEmploymentId && internalCountryCode;\n const hasChangedCountry =\n internalEmploymentId &&\n internalCountryCode &&\n employment?.country &&\n employment?.country.code !== internalCountryCode;\n\n if (isEmploymentNotLoaded || hasChangedCountry) {\n const basicInformationParsedValues = omit(\n parsedValues,\n 'saudi_nationality_status',\n 'ir35',\n 'ir35_sds_file',\n );\n const basicInformationPayload: EmploymentCreateParams = {\n basic_information: basicInformationParsedValues,\n type: 'contractor',\n country_code: internalCountryCode,\n external_id: externalId,\n };\n const response = await createEmploymentMutationAsync(\n basicInformationPayload,\n );\n const employmentId = response?.data?.employment?.id;\n if (!employmentId) {\n throw createStructuredError('Employment ID not found');\n }\n\n setInternalEmploymentId(employmentId);\n await updateUKandSaudiFieldsMutation({\n employmentId: employmentId as string,\n });\n\n return response;\n } else if (internalEmploymentId) {\n const basicInformationParsedValues = omit(\n parsedValues,\n 'saudi_nationality_status',\n 'ir35',\n 'ir35_sds_file',\n );\n\n await updateUKandSaudiFieldsMutation({\n employmentId: internalEmploymentId,\n });\n return updateEmploymentMutationAsync({\n employmentId: internalEmploymentId,\n basic_information: basicInformationParsedValues,\n });\n }\n\n return;\n }\n case 'contract_details': {\n const payload: CreateContractDocument = {\n contract_document: parsedValues,\n };\n const response = await createContractorContractDocumentMutationAsync({\n employmentId: internalEmploymentId as string,\n payload,\n });\n const contractDocumentId = response?.data?.contract_document?.id;\n if (!contractDocumentId) {\n throw createStructuredError('Contract document ID not found');\n }\n setInternalContractDocumentId(contractDocumentId);\n return response;\n }\n\n case 'contract_preview': {\n return signContractDocumentMutationAsync({\n employmentId: internalEmploymentId as string,\n contractDocumentId: internalContractDocumentId as string,\n payload: {\n signature: values.signature,\n },\n });\n }\n case 'pricing_plan': {\n if (values.subscription == contractorStandardProductIdentifier) {\n return manageContractorSubscriptionMutationAsync({\n employmentId: internalEmploymentId as string,\n payload: {\n operation: 'downgrade',\n },\n });\n } else if (values.subscription == contractorPlusProductIdentifier) {\n return manageContractorSubscriptionMutationAsync({\n employmentId: internalEmploymentId as string,\n payload: {\n operation: 'upgrade',\n },\n });\n }\n\n throw createStructuredError('invalid selection');\n }\n\n default: {\n throw createStructuredError('Invalid step state');\n }\n }\n }\n\n const isLoading = initialLoading || shouldHandleReadOnlyEmployment;\n\n return {\n /**\n * Loading state indicating if the flow is loading data\n */\n isLoading,\n\n /**\n * Current state of the form fields for the current step.\n */\n fieldValues,\n\n /**\n * Current step state containing the current step and total number of steps\n */\n stepState,\n\n /**\n * Function to update the current form field values\n * @param values - New form values to set\n */\n checkFieldUpdates: setFieldValues,\n\n /**\n * Function to handle going back to the previous step\n * @returns {void}\n */\n back: previousStep,\n\n /**\n * Function to handle going to the next step\n * @returns {void}\n */\n next: nextStep,\n\n /**\n * Function to handle going to a specific step\n * @param step The step to go to.\n * @returns {void}\n */\n goTo: goTo,\n\n /**\n * Function to handle form submission\n * @param values - Form values to submit\n * @returns Promise resolving to the mutation result\n */\n onSubmit,\n\n /**\n * Array of form fields from the onboarding schema\n */\n fields: stepFields[stepState.currentStep.name],\n\n /**\n * Fields metadata for each step\n */\n meta: {\n fields: fieldsMetaRef.current,\n fieldsets: stepFieldsWithFlatFieldsets[stepState.currentStep.name],\n },\n\n /**\n * Function to parse form values before submission\n * @param values - Form values to parse\n * @returns Parsed form values\n */\n parseFormValues,\n\n /**\n * Function to validate form values against the onboarding schema\n * @param values - Form values to validate\n * @returns Validation result or null if no schema is available\n */\n handleValidation: async (\n values: FieldValues,\n ): Promise<ValidationResult | null> => {\n if (stepState.currentStep.name === 'select_country') {\n return selectCountryForm.handleValidation(values);\n }\n\n if (\n basicInformationForm &&\n stepState.currentStep.name === 'basic_information'\n ) {\n const parsedValues = await parseJSFToValidate(\n values,\n basicInformationForm?.fields,\n { isPartialValidation: false },\n );\n return basicInformationForm?.handleValidation(parsedValues);\n }\n\n if (\n contractorOnboardingDetailsForm &&\n stepState.currentStep.name === 'contract_details'\n ) {\n const parsedValues = await parseJSFToValidate(\n values,\n contractorOnboardingDetailsForm?.fields,\n { isPartialValidation: false },\n );\n return contractorOnboardingDetailsForm?.handleValidation(parsedValues);\n }\n\n if (\n signatureSchemaForm &&\n stepState.currentStep.name === 'contract_preview'\n ) {\n const parsedValues = await parseJSFToValidate(\n values,\n signatureSchemaForm?.fields,\n { isPartialValidation: true },\n );\n return signatureSchemaForm?.handleValidation(parsedValues);\n }\n\n if (\n selectContractorSubscriptionForm &&\n stepState.currentStep.name === 'pricing_plan'\n ) {\n const parsedValues = await parseJSFToValidate(\n values,\n selectContractorSubscriptionForm?.fields,\n { isPartialValidation: false },\n );\n return selectContractorSubscriptionForm?.handleValidation(parsedValues);\n }\n\n return null;\n },\n\n /**\n * Initial form values\n */\n initialValues,\n\n /**\n * Employment id\n */\n employmentId: internalEmploymentId,\n\n /**\n * Function to refetch the employment data\n * @returns {void}\n */\n refetchEmployment: refetchEmployment,\n\n /**\n * Loading state indicating if the onboarding mutation is in progress\n */\n isSubmitting:\n createEmploymentMutation.isPending ||\n updateEmploymentMutation.isPending ||\n createContractorContractDocumentMutation.isPending ||\n signContractDocumentMutation.isPending ||\n manageContractorSubscriptionMutation.isPending ||\n uploadFileMutation.isPending,\n\n /**\n * Document preview PDF data\n */\n documentPreviewPdf,\n\n /**\n * let's the user know if the company can invite employees\n * @returns {boolean}\n */\n canInvite,\n\n /**\n * let's the user know that the employment cannot be edited, happens when employment.status is invited\n * @returns {boolean}\n */\n isEmploymentReadOnly,\n /**\n * let's the user know if the employment is invited or not\n * @returns {'invited' | 'not_invited'}\n */\n invitedStatus,\n\n /**\n * Employment data\n * @returns {Employment}\n */\n employment,\n\n /**\n * Default legal entity\n * @returns {CompanyLegalEntity}\n */\n defaultLegalEntity,\n };\n};\n","import { useQuery } from '@tanstack/react-query';\nimport {\n getIndexCompanyLegalEntities,\n IdentityCurrentResponse,\n} from '@/src/client';\nimport { Client } from '@/src/client/client';\nimport { useClient } from '@/src/context';\nimport { useIdentity } from '@/src/common/api/identity';\n\nfunction hasCompany(\n identity: IdentityCurrentResponse['data'] | undefined,\n): identity is Extract<\n IdentityCurrentResponse['data'],\n { company: { id: string } }\n> {\n return identity != null && 'company' in identity;\n}\n\n/**\n * Hook to get the legal entities for a company\n * @param companyId - The company ID\n * @returns The legal entities\n */\nexport const useLegalEntities = () => {\n const { client } = useClient();\n const { data: identity } = useIdentity();\n const companyId = hasCompany(identity) ? (identity?.company?.id ?? '') : '';\n\n return useQuery({\n queryKey: ['legal-entities', companyId],\n queryFn: () =>\n getIndexCompanyLegalEntities({\n client: client as Client,\n path: {\n company_id: companyId,\n },\n }),\n select: (data) => data.data?.data?.legal_entities,\n enabled: !!companyId,\n });\n};\n\nexport const useDefaultLegalEntity = () => {\n const { data: legalEntities } = useLegalEntities();\n return legalEntities?.find((legalEntity) => legalEntity.is_default);\n};\n","import { useQuery } from '@tanstack/react-query';\nimport { getCurrentIdentity } from '@/src/client';\nimport { useClient } from '@/src/context';\nimport { Client } from '@/src/client/client';\n\nexport const useIdentity = () => {\n const { client } = useClient();\n return useQuery({\n queryKey: ['identity'],\n queryFn: () =>\n getCurrentIdentity({\n client: client as Client,\n headers: { Authorization: `` },\n }),\n select: (data) => data.data?.data,\n });\n};\n"],"mappings":"gvBAAA,OAAS,aAAAA,GAAW,WAAAC,EAAS,UAAAC,GAAQ,YAAAC,MAAgB,QAErD,O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nC,GAAiC,OACjC,CAAE,oBAAqB,EAAM,CAC/B,EACA,OAAOA,GAAiC,iBAAiBuC,CAAY,CACvE,CAEA,GACElC,GACA/E,EAAU,YAAY,OAAS,mBAC/B,CACA,IAAMiH,EAAe,MAAMH,EACzBD,EACA9B,GAAqB,OACrB,CAAE,oBAAqB,EAAK,CAC9B,EACA,OAAOA,GAAqB,iBAAiBkC,CAAY,CAC3D,CAEA,GACEtE,GACA3C,EAAU,YAAY,OAAS,eAC/B,CACA,IAAMiH,EAAe,MAAMH,EACzBD,EACAlE,GAAkC,OAClC,CAAE,oBAAqB,EAAM,CAC/B,EACA,OAAOA,GAAkC,iBAAiBsE,CAAY,CACxE,CAEA,OAAO,IACT,EAxDkB,oBA6DlB,cAAAjB,GAKA,aAAc1G,EAMd,kBAAmBmB,GAKnB,aACEW,GAAyB,WACzBE,GAAyB,WACzBE,EAAyC,WACzCQ,GAA6B,WAC7BE,GAAqC,WACrCR,GAAmB,UAKrB,mBAAAwD,EAMA,UAAAlE,GAMA,qBAAAF,EAKA,cAAAI,GAMA,WAAAX,EAMA,mBAAAI,EACF,CACF,EA34BuC","names":["useEffect","useMemo","useRef","useState","omit","useQuery","useQuery","useIdentity","__name","client","useClient","useQuery","getCurrentIdentity","data","hasCompany","identity","__name","useLegalEntities","client","useClient","useIdentity","companyId","useQuery","getIndexCompanyLegalEntities","data","useDefaultLegalEntity","legalEntities","legalEntity","stepToFormSchemaMap","jsonSchemaToEmployment","provisionalStartDate","useContractorOnboarding","__name","countryCode","externalId","employmentId","skipSteps","options","onboardingInitialValues","internalCountryCode","setInternalCountryCode","useState","internalEmploymentId","setInternalEmploymentId","internalContractDocumentId","setInternalContractDocumentId","fieldsMetaRef","useRef","stepsToUse","STEPS_WITHOUT_SELECT_COUNTRY","STEPS","fieldValues","stepState","setFieldValues","previousStep","nextStep","goToStep","setStepValues","useStepState","employment","isLoadingEmployment","refetchEmployment","useEmploymentQuery","defaultLegalEntity","useDefaultLegalEntity","employmentStatus","isEmploymentReadOnly","reviewStepAllowedEmploymentStatus","canInvite","disabledInviteButtonEmploymentStatus","invitedStatus","useMemo","createEmploymentMutation","useCreateEmployment","updateEmploymentMutation","useUpdateEmployment","createContractorContractDocumentMutation","useCreateContractorContractDocument","uploadFileMutation","useUploadFile","updateUKandSaudiFieldsMutation","useUpdateUKandSaudiFields","updateEmploymentMutationAsync","mutationToPromise","signContractDocumentMutation","useSignContractDocument","manageContractorSubscriptionMutation","usePostManageContractorSubscriptions","createEmploymentMutationAsync","createContractorContractDocumentMutationAsync","signContractDocumentMutationAsync","manageContractorSubscriptionMutationAsync","selectCountryForm","isLoadingCountries","useCountriesSchemaField","selectContractorSubscriptionForm","isLoadingContractorSubscriptions","useContractorSubscriptionSchemaField","formType","employmentKey","serverEmploymentData","useJSONSchema","form","jsonSchemaOptions","query","mergedFormValues","useJSONSchemaForm","isBasicInformationDetailsEnabled","isContractorOnboardingDetailsEnabled","isIR35FileEnabled","ir35File","isLoadingIR35File","useGetIR35File","contractDocuments","isLoadingContractDocuments","useGetContractDocuments","useEffect","basicInformationForm","isLoadingBasicInformationForm","buildBasicInformationJsfModify","descriptionProvisionalStartDate","calculateProvisionalStartDateDescription","selectedPricingPlan","contractorStandardProductIdentifier","contractorPlusProductIdentifier","corProductIdentifier","contractorOnboardingDetailsForm","isLoadingContractorOnboardingDetailsForm","useContractorOnboardingDetailsSchema","buildContractDetailsJsfModify","isSignatureSchemaEnabled","signatureSchemaForm","useGetContractDocumentSignatureSchema","buildContractPreviewJsfModify","documentPreviewPdf","isLoadingDocumentPreviewForm","useGetShowContractDocument","stepFields","stepFieldsWithFlatFieldsets","country","employmentBasicInformation","employmentContractDetails","employmentCountryCode","selectCountryInitialValues","getInitialValues","convertedIr35File","dataURLtoFile","basicInformationInitialValues","initialValues","contractDetailsInitialValues","contractPreviewInitialValues","signature","signatory","pricingPlanInitialValues","shouldHandleReadOnlyEmployment","initialLoading","isNavigatingToReview","prettifyFormValues","goTo","step","parseFormValues","values","parseJSFToValidate","onSubmit","currentStepName","parsedValues","isEmploymentNotLoaded","hasChangedCountry","basicInformationPayload","omit","response","createStructuredError","basicInformationParsedValues","contractDocumentId"]}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a}from"./chunk-THBDZR3D.js";import{b as i}from"./chunk-PGWKJ6FK.js";import{a as e}from"./chunk-P37U34EQ.js";import{jsx as d}from"react/jsx-runtime";function y({onSubmit:s,onSuccess:c,onError:t}){let{onboardingBag:o}=i(),u=e(async n=>{try{await s?.({countryCode:n.country});let r=await o.onSubmit(n);if(r?.data){await c?.(r?.data),o?.next();return}r?.error&&t?.({error:r.error,rawError:r.rawError,fieldErrors:[]})}catch(r){t?.({error:r,rawError:r,fieldErrors:[]})}},"handleSubmit"),l=o.stepState.values?.select_country||o.initialValues.select_country;return d(a,{defaultValues:l,onSubmit:u})}e(y,"SelectCountryStep");export{y as a};
|
|
2
|
+
//# sourceMappingURL=chunk-LGIHVJA5.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as n,b as i}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as n,b as i}from"./chunk-BDJLITVT.js";import{a as e}from"./chunk-J63QA2JC.js";import{a as o}from"./chunk-P37U34EQ.js";import{Fragment as s,jsx as t,jsxs as r}from"react/jsx-runtime";var l=["You submit your termination request.","Remote reviews your request along with the employment agreement, local labor laws, and any collective bargaining agreements in place.","A lifecycle specialist contacts you if they need additional details. Sometimes they will request a call.","Depending on the country-specific laws and the terms of the employment agreement, Remote may need to seek additional legal advice. We\u2019ll let you know if there are additional charges before proceeding.","Terms and conditions for the termination are finalized.","You verbally communicate the termination to the employee.","Remote shares termination documents with the employee.","The employee signs the termination documents if required.","Remote processes the final salary and offboards the employee."],f=o(()=>r(s,{children:[t("h3",{className:e("RemoteFlows__TerminationDialogInfoContent__Title"),children:"Please read carefully before you continue"}),t("p",{className:e("RemoteFlows__TerminationDialogInfoContent__Description"),children:"Please do not inform the employee of the termination. Remote will lead communication with them after you submit this form and they finalize the termination terms."}),t("p",{className:e("RemoteFlows__TerminationDialogInfoContent__Description RemoteFlows__TerminationDialogInfoContent__FollowUpDescription"),children:"If you already informed them, that's okay. Remote will ask for the details regarding that communication and they'll take it from there."}),t(i,{className:e("RemoteFlows__TerminationDialogInfoContent__ZendeskTriggerButton text-sm"),zendeskId:n.terminationEmployeeCommunication,children:"Learn more about employee communication"}),t("h3",{className:e("RemoteFlows__TerminationDialogInfoContent__ProcessTitle"),children:"The termination process"}),t("ul",{className:e("RemoteFlows__TerminationDialogInfoContent__ProcessList list-disc list-inside"),children:l.map((a,m)=>t("li",{className:e("RemoteFlows__TerminationDialogInfoContent__ProcessListItem"),children:a},m))})]}),"TerminationDialogInfoContent");export{f as a};
|
|
2
|
+
//# sourceMappingURL=chunk-N6XY7NC3.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as n}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as n}from"./chunk-SBUJLXJH.js";import{b as e}from"./chunk-MRYRNB7Y.js";import{a as r}from"./chunk-P37U34EQ.js";import{jsx as u}from"react/jsx-runtime";function F({onSubmit:t,onSuccess:s,onError:m}){let{terminationBag:o}=e(),d=r(async a=>{let l=await o?.parseFormValues(a,!0);await t?.(l);let i=await o?.onSubmit(a);i?.error?m?.(i.rawError):i?.data&&await s?.(i.data)},"handleSubmit");return u(n,{defaultValues:o.fieldValues,fields:o?.fields,onSubmit:d})}r(F,"AdditionalDetailsForm");export{F as a};
|
|
2
|
+
//# sourceMappingURL=chunk-NB3TN7O3.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as e}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as e}from"./chunk-SBUJLXJH.js";import{b as a}from"./chunk-MRYRNB7Y.js";import{a as i}from"./chunk-P37U34EQ.js";import{jsx as s}from"react/jsx-runtime";function d({onSubmit:m}){let{terminationBag:o}=a(),r=i(async t=>{let n=await o?.parseFormValues(t);await m?.(n),o?.next()},"handleSubmit");return s(e,{defaultValues:o.fieldValues,onSubmit:r})}i(d,"PaidTimeOffForm");export{d as a};
|
|
2
|
+
//# sourceMappingURL=chunk-NVX4O45S.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
var e="urn:remotecom:resource:product:contractor:standard:monthly",o="urn:remotecom:resource:product:contractor:plus:monthly",r="urn:remotecom:resource:product:contractor:aor:monthly",i="ir_35",t=[{title:"You add a new contractor and their details in Remote.",id:"add-contractor-details"},{title:"Contractor accepts invite to join Remote.",id:"contractor-accepts-invite"},{title:"Ask your contractor to sign their agreement with your company.",id:"ask-contractor-to-sign-agreement"},{title:"Once the agreement is signed, the contractor can begin work.",id:"agreement-signed-begin-work"},{title:"The contractor will submit invoices on a date specified by you.",id:"contractor-submits-invoices"},{title:"You will pay the contractor according to the agreed-upon terms.",id:"pay-contractor"}],n=[{title:"You add a new contractor and their details in Remote, and reconfirm our Terms of Service.",description:"Review all details carefully, as we'll use this information to draft the contract.",id:"add-contractor-details-and-reconfirm-terms"},{title:"You pay the reserve amount required to add the contractor.",id:"pay-reserve-amount"},{title:"The contractor is invited to the platform.",id:"contractor-invited-to-platform"},{title:"The contractor completes onboarding on Remote.",id:"contractor-completes-onboarding"},{title:"The contractor signs the services agreement with Remote.",id:"contractor-signs-services-agreement"},{title:"Contractor begins working.",id:"contractor-begins-working"},{title:"Contractor submits an invoice to Remote.",id:"contractor-submits-invoice"},{title:"You review and approve the invoice.",id:"review-and-approve-invoice"},{title:"A COR contractor payment invoice is generated, which you pay.",id:"cor-contractor-payment-invoice-generated"},{title:"Remote receives payment and pays contractor.",id:"remote-receives-payment-and-pays-contractor"},{title:"Contractor receives payment.",id:"contractor-receives-payment"}],a={[e]:t,[o]:t,[r]:n},c={[e]:{title:"Contractor Management",subtitle:"Engage and pay contractors compliantly",listItems:["Ideal for businesses wanting a straightforward solution to manage and pay contractors directly.","Helps with everything from contractor onboarding, invoicing, payments, and compliance.","Full control remains with you."],contractPillText:"Contract between you and contractor"},[o]:{title:"Contractor Management Plus",subtitle:"Engage and pay contractors with indemnity coverage",listItems:["Great for businesses concerned about contractor classification risks.","Helps with everything from contractor onboarding, invoicing, payments, and compliance.","Offers a warranty on Remote's localized, compliant contracts.","Control remains with you"],contractPillText:"Contract between you and contractor"},[r]:{title:"Contractor of Record",subtitle:"Remote reduces liability by directly engaging the contractor",listItems:["Ideal for businesses who want admin relief and have low risk tolerance.","No need to be experts in local labor laws; Remote manages its compliance with contractors.","Indemnity protection, Remote backs its compliance in administering and paying contractors"],contractPillText:"Contract between Remote and contractor"}};export{e as a,o as b,r as c,i as d,n as e,a as f,c as g};
|
|
2
|
+
//# sourceMappingURL=chunk-O3G6HQ3B.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/flows/ContractorOnboarding/constants.ts"],"sourcesContent":["export const contractorStandardProductIdentifier =\n 'urn:remotecom:resource:product:contractor:standard:monthly';\nexport const contractorPlusProductIdentifier =\n 'urn:remotecom:resource:product:contractor:plus:monthly';\nexport const corProductIdentifier =\n 'urn:remotecom:resource:product:contractor:aor:monthly';\n\nexport const IR35_FILE_SUBTYPE = 'ir_35';\n\nconst standardOnboardingWorkflow = [\n {\n title: 'You add a new contractor and their details in Remote.',\n id: 'add-contractor-details',\n },\n {\n title: 'Contractor accepts invite to join Remote.',\n id: 'contractor-accepts-invite',\n },\n {\n title: 'Ask your contractor to sign their agreement with your company.',\n id: 'ask-contractor-to-sign-agreement',\n },\n {\n title: 'Once the agreement is signed, the contractor can begin work.',\n id: 'agreement-signed-begin-work',\n },\n {\n title: 'The contractor will submit invoices on a date specified by you.',\n id: 'contractor-submits-invoices',\n },\n {\n title: 'You will pay the contractor according to the agreed-upon terms.',\n id: 'pay-contractor',\n },\n];\n\nexport const corOnboardingWorkflow = [\n {\n title:\n 'You add a new contractor and their details in Remote, and reconfirm our Terms of Service.',\n description:\n \"Review all details carefully, as we'll use this information to draft the contract.\",\n id: 'add-contractor-details-and-reconfirm-terms',\n },\n {\n title: 'You pay the reserve amount required to add the contractor.',\n id: 'pay-reserve-amount',\n },\n {\n title: 'The contractor is invited to the platform.',\n id: 'contractor-invited-to-platform',\n },\n {\n title: 'The contractor completes onboarding on Remote.',\n id: 'contractor-completes-onboarding',\n },\n {\n title: 'The contractor signs the services agreement with Remote.',\n id: 'contractor-signs-services-agreement',\n },\n {\n title: 'Contractor begins working.',\n id: 'contractor-begins-working',\n },\n {\n title: 'Contractor submits an invoice to Remote.',\n id: 'contractor-submits-invoice',\n },\n {\n title: 'You review and approve the invoice.',\n id: 'review-and-approve-invoice',\n },\n {\n title: 'A COR contractor payment invoice is generated, which you pay.',\n id: 'cor-contractor-payment-invoice-generated',\n },\n {\n title: 'Remote receives payment and pays contractor.',\n id: 'remote-receives-payment-and-pays-contractor',\n },\n {\n title: 'Contractor receives payment.',\n id: 'contractor-receives-payment',\n },\n];\n\n/**\n * Onboarding workflows for each pricing plan\n */\nexport const onboardingWorkflows: Record<\n string,\n { title: string; id: string; description?: string }[]\n> = {\n [contractorStandardProductIdentifier]: standardOnboardingWorkflow,\n // we assign the same workflow as its the same for standard and plus\n [contractorPlusProductIdentifier]: standardOnboardingWorkflow,\n [corProductIdentifier]: corOnboardingWorkflow,\n};\n\nexport const pricingPlanDetails = {\n [contractorStandardProductIdentifier]: {\n title: 'Contractor Management',\n subtitle: 'Engage and pay contractors compliantly',\n listItems: [\n 'Ideal for businesses wanting a straightforward solution to manage and pay contractors directly.',\n 'Helps with everything from contractor onboarding, invoicing, payments, and compliance.',\n 'Full control remains with you.',\n ],\n contractPillText: 'Contract between you and contractor',\n },\n [contractorPlusProductIdentifier]: {\n title: 'Contractor Management Plus',\n subtitle: 'Engage and pay contractors with indemnity coverage',\n listItems: [\n 'Great for businesses concerned about contractor classification risks.',\n 'Helps with everything from contractor onboarding, invoicing, payments, and compliance.',\n \"Offers a warranty on Remote's localized, compliant contracts.\",\n 'Control remains with you',\n ],\n contractPillText: 'Contract between you and contractor',\n },\n [corProductIdentifier]: {\n title: 'Contractor of Record',\n subtitle: 'Remote reduces liability by directly engaging the contractor',\n listItems: [\n 'Ideal for businesses who want admin relief and have low risk tolerance.',\n 'No need to be experts in local labor laws; Remote manages its compliance with contractors.',\n 'Indemnity protection, Remote backs its compliance in administering and paying contractors',\n ],\n contractPillText: 'Contract between Remote and contractor',\n },\n};\n"],"mappings":"AAAO,IAAMA,EACX,6DACWC,EACX,yDACWC,EACX,wDAEWC,EAAoB,QAE3BC,EAA6B,CACjC,CACE,MAAO,wDACP,GAAI,wBACN,EACA,CACE,MAAO,4CACP,GAAI,2BACN,EACA,CACE,MAAO,iEACP,GAAI,kCACN,EACA,CACE,MAAO,+DACP,GAAI,6BACN,EACA,CACE,MAAO,kEACP,GAAI,6BACN,EACA,CACE,MAAO,kEACP,GAAI,gBACN,CACF,EAEaC,EAAwB,CACnC,CACE,MACE,4FACF,YACE,qFACF,GAAI,4CACN,EACA,CACE,MAAO,6DACP,GAAI,oBACN,EACA,CACE,MAAO,6CACP,GAAI,gCACN,EACA,CACE,MAAO,iDACP,GAAI,iCACN,EACA,CACE,MAAO,2DACP,GAAI,qCACN,EACA,CACE,MAAO,6BACP,GAAI,2BACN,EACA,CACE,MAAO,2CACP,GAAI,4BACN,EACA,CACE,MAAO,sCACP,GAAI,4BACN,EACA,CACE,MAAO,gEACP,GAAI,0CACN,EACA,CACE,MAAO,+CACP,GAAI,6CACN,EACA,CACE,MAAO,+BACP,GAAI,6BACN,CACF,EAKaC,EAGT,CACF,CAACN,CAAmC,EAAGI,EAEvC,CAACH,CAA+B,EAAGG,EACnC,CAACF,CAAoB,EAAGG,CAC1B,EAEaE,EAAqB,CAChC,CAACP,CAAmC,EAAG,CACrC,MAAO,wBACP,SAAU,yCACV,UAAW,CACT,kGACA,yFACA,gCACF,EACA,iBAAkB,qCACpB,EACA,CAACC,CAA+B,EAAG,CACjC,MAAO,6BACP,SAAU,qDACV,UAAW,CACT,wEACA,yFACA,gEACA,0BACF,EACA,iBAAkB,qCACpB,EACA,CAACC,CAAoB,EAAG,CACtB,MAAO,uBACP,SAAU,+DACV,UAAW,CACT,0EACA,6FACA,2FACF,EACA,iBAAkB,wCACpB,CACF","names":["contractorStandardProductIdentifier","contractorPlusProductIdentifier","corProductIdentifier","IR35_FILE_SUBTYPE","standardOnboardingWorkflow","corOnboardingWorkflow","onboardingWorkflows","pricingPlanDetails"]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import{a as t}from"./chunk-P37U34EQ.js";var N=t((e,r,o)=>{typeof o=="string"||o instanceof Blob?e.append(r,o):o instanceof Date?e.append(r,o.toISOString()):e.append(r,JSON.stringify(o))},"serializeFormDataPair");var B={bodySerializer:t(e=>{let r=new FormData;return Object.entries(e).forEach(([o,s])=>{s!=null&&(Array.isArray(s)?s.forEach(a=>N(r,o,a)):N(r,o,s))}),r},"bodySerializer")},j={bodySerializer:t(e=>JSON.stringify(e,(r,o)=>typeof o=="bigint"?o.toString():o),"bodySerializer")};var Q=t(({onRequest:e,onSseError:r,onSseEvent:o,responseTransformer:s,responseValidator:a,sseDefaultRetryDelay:h,sseMaxRetryAttempts:
|
|
1
|
+
import{a as t}from"./chunk-P37U34EQ.js";var N=t((e,r,o)=>{typeof o=="string"||o instanceof Blob?e.append(r,o):o instanceof Date?e.append(r,o.toISOString()):e.append(r,JSON.stringify(o))},"serializeFormDataPair");var B={bodySerializer:t(e=>{let r=new FormData;return Object.entries(e).forEach(([o,s])=>{s!=null&&(Array.isArray(s)?s.forEach(a=>N(r,o,a)):N(r,o,s))}),r},"bodySerializer")},j={bodySerializer:t(e=>JSON.stringify(e,(r,o)=>typeof o=="bigint"?o.toString():o),"bodySerializer")};var Q=t(({onRequest:e,onSseError:r,onSseEvent:o,responseTransformer:s,responseValidator:a,sseDefaultRetryDelay:h,sseMaxRetryAttempts:c,sseMaxRetryDelay:p,sseSleepFn:l,url:d,...n})=>{let E,g=l??(m=>new Promise(C=>setTimeout(C,m)));return{stream:t(async function*(){let m=h??3e3,C=0,T=n.signal??new AbortController().signal;for(;!T.aborted;){C++;let D=n.headers instanceof Headers?n.headers:new Headers(n.headers);E!==void 0&&D.set("Last-Event-ID",E);try{let x={redirect:"follow",...n,body:n.serializedBody,headers:D,signal:T},O=new Request(d,x);e&&(O=await e(d,x));let u=await(n.fetch??globalThis.fetch)(O);if(!u.ok)throw new Error(`SSE failed: ${u.status} ${u.statusText}`);if(!u.body)throw new Error("No body in SSE response");let w=u.body.pipeThrough(new TextDecoderStream).getReader(),A="",L=t(()=>{try{w.cancel()}catch{}},"abortHandler");T.addEventListener("abort",L);try{for(;;){let{done:te,value:re}=await w.read();if(te)break;A+=re;let F=A.split(`
|
|
2
2
|
|
|
3
3
|
`);A=F.pop()??"";for(let oe of F){let ne=oe.split(`
|
|
4
4
|
`),I=[],V;for(let b of ne)if(b.startsWith("data:"))I.push(b.replace(/^data:\s*/,""));else if(b.startsWith("event:"))V=b.replace(/^event:\s*/,"");else if(b.startsWith("id:"))E=b.replace(/^id:\s*/,"");else if(b.startsWith("retry:")){let H=Number.parseInt(b.replace(/^retry:\s*/,""),10);Number.isNaN(H)||(m=H)}let P,M=!1;if(I.length){let b=I.join(`
|
|
5
|
-
`);try{P=JSON.parse(b),M=!0}catch{P=b}}M&&(a&&await a(P),s&&(P=await s(P))),o?.({data:P,event:V,id:E,retry:m}),I.length&&(yield P)}}}finally{T.removeEventListener("abort",L),w.releaseLock()}break}catch(x){if(r?.(x),p!==void 0&&C>=p)break;let O=Math.min(m*2**(C-1),i??3e4);await g(O)}}},"createStream")()}},"createSseClient");var se=t(e=>{switch(e){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},"separatorArrayExplode"),ae=t(e=>{switch(e){case"form":return",";case"pipeDelimited":return"|";case"spaceDelimited":return"%20";default:return","}},"separatorArrayNoExplode"),ie=t(e=>{switch(e){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},"separatorObjectExplode"),k=t(({allowReserved:e,explode:r,name:o,style:s,value:a})=>{if(!r){let i=(e?a:a.map(l=>encodeURIComponent(l))).join(ae(s));switch(s){case"label":return`.${i}`;case"matrix":return`;${o}=${i}`;case"simple":return i;default:return`${o}=${i}`}}let h=se(s),p=a.map(i=>s==="label"||s==="simple"?e?i:encodeURIComponent(i):R({allowReserved:e,name:o,value:i})).join(h);return s==="label"||s==="matrix"?h+p:p},"serializeArrayParam"),R=t(({allowReserved:e,name:r,value:o})=>{if(o==null)return"";if(typeof o=="object")throw new Error("Deeply-nested arrays/objects aren\u2019t supported. Provide your own `querySerializer()` to handle these.");return`${r}=${e?o:encodeURIComponent(o)}`},"serializePrimitiveParam"),U=t(({allowReserved:e,explode:r,name:o,style:s,value:a,valueOnly:h})=>{if(a instanceof Date)return h?a.toISOString():`${o}=${a.toISOString()}`;if(s!=="deepObject"&&!r){let l=[];Object.entries(a).forEach(([n,E])=>{l=[...l,n,e?E:encodeURIComponent(E)]});let d=l.join(",");switch(s){case"form":return`${o}=${d}`;case"label":return`.${d}`;case"matrix":return`;${o}=${d}`;default:return d}}let p=ie(s),i=Object.entries(a).map(([l,d])=>R({allowReserved:e,name:s==="deepObject"?`${o}[${l}]`:l,value:d})).join(p);return s==="label"||s==="matrix"?p+i:i},"serializeObjectParam");var pe=/\{[^{}]+\}/g,ce=t(({path:e,url:r})=>{let o=r,s=r.match(pe);if(s)for(let a of s){let h=!1,p=a.substring(1,a.length-1),i="simple";p.endsWith("*")&&(h=!0,p=p.substring(0,p.length-1)),p.startsWith(".")?(p=p.substring(1),i="label"):p.startsWith(";")&&(p=p.substring(1),i="matrix");let l=e[p];if(l==null)continue;if(Array.isArray(l)){o=o.replace(a,k({explode:h,name:p,style:i,value:l}));continue}if(typeof l=="object"){o=o.replace(a,U({explode:h,name:p,style:i,value:l,valueOnly:!0}));continue}if(i==="matrix"){o=o.replace(a,`;${R({name:p,value:l})}`);continue}let d=encodeURIComponent(i==="label"?`.${l}`:l);o=o.replace(a,d)}return o},"defaultPathSerializer"),$=t(({baseUrl:e,path:r,query:o,querySerializer:s,url:a})=>{let h=a.startsWith("/")?a:`/${a}`,p=(e??"")+h;r&&(p=ce({path:r,url:p}));let i=o?s(o):"";return i.startsWith("?")&&(i=i.substring(1)),i&&(p+=`?${i}`),p},"getUrl");function J(e){let r=e.body!==void 0;if(r&&e.bodySerializer)return"serializedBody"in e?e.serializedBody!==void 0&&e.serializedBody!==""?e.serializedBody:null:e.body!==""?e.body:null;if(r)return e.body}t(J,"getValidRequestBody");var K=t(async(e,r)=>{let o=typeof r=="function"?await r(e):r;if(o)return e.scheme==="bearer"?`Bearer ${o}`:e.scheme==="basic"?`Basic ${btoa(o)}`:o},"getAuthToken");var X=t(({parameters:e={},...r}={})=>t(s=>{let a=[];if(s&&typeof s=="object")for(let h in s){let p=s[h];if(p==null)continue;let i=e[h]||r;if(Array.isArray(p)){let l=k({allowReserved:i.allowReserved,explode:!0,name:h,style:"form",value:p,...i.array});l&&a.push(l)}else if(typeof p=="object"){let l=U({allowReserved:i.allowReserved,explode:!0,name:h,style:"deepObject",value:p,...i.object});l&&a.push(l)}else{let l=R({allowReserved:i.allowReserved,name:h,value:p});l&&a.push(l)}}return a.join("&")},"querySerializer"),"createQuerySerializer"),Y=t(e=>{if(!e)return"stream";let r=e.split(";")[0]?.trim();if(r){if(r.startsWith("application/json")||r.endsWith("+json"))return"json";if(r==="multipart/form-data")return"formData";if(["application/","audio/","image/","video/"].some(o=>r.startsWith(o)))return"blob";if(r.startsWith("text/"))return"text"}},"getParseAs"),le=t((e,r)=>r?!!(e.headers.has(r)||e.query?.[r]||e.headers.get("Cookie")?.includes(`${r}=`)):!1,"checkForExistence"),Z=t(async({security:e,...r})=>{for(let o of e){if(le(r,o.name))continue;let s=await K(o,r.auth);if(!s)continue;let a=o.name??"Authorization";switch(o.in){case"query":r.query||(r.query={}),r.query[a]=s;break;case"cookie":r.headers.append("Cookie",`${a}=${s}`);break;case"header":default:r.headers.set(a,s);break}}},"setAuthParams"),z=t(e=>$({baseUrl:e.baseUrl,path:e.path,query:e.query,querySerializer:typeof e.querySerializer=="function"?e.querySerializer:X(e.querySerializer),url:e.url}),"buildUrl"),W=t((e,r)=>{let o={...e,...r};return o.baseUrl?.endsWith("/")&&(o.baseUrl=o.baseUrl.substring(0,o.baseUrl.length-1)),o.headers=q(e.headers,r.headers),o},"mergeConfigs"),he=t(e=>{let r=[];return e.forEach((o,s)=>{r.push([s,o])}),r},"headersEntries"),q=t((...e)=>{let r=new Headers;for(let o of e){if(!o)continue;let s=o instanceof Headers?he(o):Object.entries(o);for(let[a,h]of s)if(h===null)r.delete(a);else if(Array.isArray(h))for(let p of h)r.append(a,p);else h!==void 0&&r.set(a,typeof h=="object"?JSON.stringify(h):h)}return r},"mergeHeaders"),G=class{static{t(this,"Interceptors")}fns=[];clear(){this.fns=[]}eject(r){let o=this.getInterceptorIndex(r);this.fns[o]&&(this.fns[o]=null)}exists(r){let o=this.getInterceptorIndex(r);return!!this.fns[o]}getInterceptorIndex(r){return typeof r=="number"?this.fns[r]?r:-1:this.fns.indexOf(r)}update(r,o){let s=this.getInterceptorIndex(r);return this.fns[s]?(this.fns[s]=o,r):!1}use(r){return this.fns.push(r),this.fns.length-1}},ee=t(()=>({error:new G,request:new G,response:new G}),"createInterceptors"),me=X({allowReserved:!1,array:{explode:!0,style:"form"},object:{explode:!0,style:"deepObject"}}),de={"Content-Type":"application/json"},S=t((e={})=>({...j,headers:de,parseAs:"auto",querySerializer:me,...e}),"createConfig");var _=t((e={})=>{let r=W(S(),e),o=t(()=>({...r}),"getConfig"),s=t(d=>(r=W(r,d),o()),"setConfig"),a=ee(),h=t(async d=>{let n={...r,...d,fetch:d.fetch??r.fetch??globalThis.fetch,headers:q(r.headers,d.headers),serializedBody:void 0};n.security&&await Z({...n,security:n.security}),n.requestValidator&&await n.requestValidator(n),n.body!==void 0&&n.bodySerializer&&(n.serializedBody=n.bodySerializer(n.body)),(n.body===void 0||n.serializedBody==="")&&n.headers.delete("Content-Type");let E=z(n);return{opts:n,url:E}},"beforeRequest"),p=t(async d=>{let{opts:n,url:E}=await h(d),g={redirect:"follow",...n,body:J(n)},f=new Request(E,g);for(let y of a.request.fns)y&&(f=await y(f,n));let v=n.fetch,m;try{m=await v(f)}catch(y){let u=y;for(let w of a.error.fns)w&&(u=await w(y,void 0,f,n));if(u=u||{},n.throwOnError)throw u;return n.responseStyle==="data"?void 0:{error:u,request:f,response:void 0}}for(let y of a.response.fns)y&&(m=await y(m,f,n));let C={request:f,response:m};if(m.ok){let y=(n.parseAs==="auto"?Y(m.headers.get("Content-Type")):n.parseAs)??"json";if(m.status===204||m.headers.get("Content-Length")==="0"){let w;switch(y){case"arrayBuffer":case"blob":case"text":w=await m[y]();break;case"formData":w=new FormData;break;case"stream":w=m.body;break;case"json":default:w={};break}return n.responseStyle==="data"?w:{data:w,...C}}let u;switch(y){case"arrayBuffer":case"blob":case"formData":case"json":case"text":u=await m[y]();break;case"stream":return n.responseStyle==="data"?m.body:{data:m.body,...C}}return y==="json"&&(n.responseValidator&&await n.responseValidator(u),n.responseTransformer&&(u=await n.responseTransformer(u))),n.responseStyle==="data"?u:{data:u,...C}}let T=await m.text(),D;try{D=JSON.parse(T)}catch{}let x=D??T,O=x;for(let y of a.error.fns)y&&(O=await y(x,m,f,n));if(O=O||{},n.throwOnError)throw O;return n.responseStyle==="data"?void 0:{error:O,...C}},"request"),i=t(d=>n=>p({...n,method:d}),"makeMethodFn"),l=t(d=>async n=>{let{opts:E,url:g}=await h(n);return Q({...E,body:E.body,headers:E.headers,method:d,onRequest:t(async(f,v)=>{let m=new Request(f,v);for(let C of a.request.fns)C&&(m=await C(m,E));return m},"onRequest"),url:g})},"makeSseFn");return{buildUrl:z,connect:i("CONNECT"),delete:i("DELETE"),get:i("GET"),getConfig:o,head:i("HEAD"),interceptors:a,options:i("OPTIONS"),patch:i("PATCH"),post:i("POST"),put:i("PUT"),request:p,setConfig:s,sse:{connect:l("CONNECT"),delete:l("DELETE"),get:l("GET"),head:l("HEAD"),options:l("OPTIONS"),patch:l("PATCH"),post:l("POST"),put:l("PUT"),trace:l("TRACE")},trace:i("TRACE")}},"createClient");var c=_(S({baseUrl:"https://gateway.remote.com/"}));var He=t(e=>(e?.client??c).post({security:[{scheme:"bearer",type:"http"}],url:"/v1/offboardings",...e,headers:{"Content-Type":"application/json",...e?.headers}}),"postCreateOffboarding");var Ne=t(e=>(e.client??c).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/contract-amendments/schema",...e}),"getShowContractAmendmentSchema");var Qe=t(e=>(e.client??c).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/currency-converter/raw",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postConvertRawCurrencyConverter"),$e=t(e=>(e.client??c).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/countries/{country_code}/contractor-contract-details",...e}),"getShowContractorContractDetailsCountry");var Je=t(e=>(e.client??c).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/employments",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postCreateEmployment2"),Ke=t(e=>(e.client??c).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/help-center-articles/{id}",...e}),"getShowHelpCenterArticle");var Xe=t(e=>(e.client??c).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/sdk/telemetry-errors",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postReportErrorsTelemetry");var Ye=t(e=>(e.client??c).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/cost-calculator/estimation",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postCreateEstimation");var Ze=t(e=>(e.client??c).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/employments/{employment_id}/benefit-offers",...e}),"getIndexBenefitOffer"),et=t(e=>(e.client??c).put({security:[{scheme:"bearer",type:"http"}],url:"/v1/employments/{employment_id}/benefit-offers",...e,headers:{"Content-Type":"application/json",...e.headers}}),"putUpdateBenefitOffer");var tt=t(e=>(e.client??c).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/contractors/employments/{employment_id}/contractor-subscriptions",...e}),"getIndexSubscription");var rt=t(e=>(e?.client??c).get({security:[{scheme:"bearer",type:"http"}],url:"/v1/payroll-calendars",...e}),"getIndexEorPayrollCalendar");var ot=t(e=>(e.client??c).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/contractors/employments/{employment_id}/contract-documents/{id}",...e}),"getShowContractDocument"),nt=t(e=>(e.client??c).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/employments/{employment_id}/contract-documents",...e}),"getIndexEmploymentContractDocument");var st=t(e=>(e.client??c).post({security:[{scheme:"bearer",type:"http"}],url:"/v1/magic-link",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postGenerateMagicLink");var at=t(e=>(e?.client??c).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/cost-calculator/estimation-pdf",...e,headers:{"Content-Type":"application/json",...e?.headers}}),"postCreateEstimationPdf");var it=t(e=>(e.client??c).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/risk-reserve",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postCreateRiskReserve");var pt=t(e=>(e.client??c).get({security:[{scheme:"bearer",type:"http"}],url:"/v1/companies/{company_id}",...e}),"getShowCompany");var ct=t(e=>(e.client??c).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/contract-amendments",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postCreateContractAmendment");var lt=t(e=>(e.client??c).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/countries/{country_code}/{form}",...e}),"getShowFormCountry"),ht=t(e=>(e.client??c).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/files/{id}",...e}),"getShowFile");var mt=t(e=>(e?.client??c).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/cost-calculator/countries",...e}),"getIndexCountry");var dt=t(e=>(e.client??c).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/leave-policies/summary/{employment_id}",...e}),"getIndexLeavePoliciesSummary");var yt=t(e=>(e.client??c).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/employments/{employment_id}/benefit-offers/schema",...e}),"getShowSchema");var ut=t(e=>(e.client??c).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/employments/{employment_id}",...e}),"getShowEmployment"),Et=t(e=>(e.client??c).patch({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/employments/{employment_id}",...e,headers:{"Content-Type":"application/json",...e.headers}}),"patchUpdateEmployment2");var Ct=t(e=>(e.client??c).get({security:[{scheme:"bearer",type:"http"}],url:"/v1/cost-calculator/regions/{slug}/fields",...e}),"getShowRegionField");var wt=t(e=>(e.client??c).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/employments/{employment_id}/contract-eligibility",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postCreateContractEligibility"),ft=t(e=>(e.client??c).get({security:[{scheme:"bearer",type:"http"}],url:"/v1/countries",...e}),"getSupportedCountry");var bt=t(e=>(e?.client??c).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/cost-calculator/estimation-csv",...e,headers:{"Content-Type":"application/json",...e?.headers}}),"postCreateEstimationCsv"),Ot=t(e=>(e.client??c).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/contractors/employments/{employment_id}/contract-documents",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postCreateContractDocument");var Tt=t(e=>(e.client??c).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/currency-converter/effective",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postConvertWithSpreadCurrencyConverter");var xt=t(e=>(e.client??c).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/contract-amendments/automatable",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postAutomatableContractAmendment");var Pt=t(e=>(e.client??c).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/employments/{employment_id}/files",...e}),"getIndexEmploymentFile");var Rt=t(e=>(e?.client??c).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/company-currencies",...e}),"getIndexCompanyCurrency");var gt=t(e=>(e.client??c).post({...B,security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/documents",...e,headers:{"Content-Type":null,...e.headers}}),"postUploadEmployeeFileFile"),Dt=t(e=>(e.client??c).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/employments/{employment_id}/invite",...e}),"postInviteEmploymentInvitation");var Gt=t(e=>(e.client??c).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/contractors/employments/{employment_id}/contract-documents/{contract_document_id}/sign",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postSignContractDocument");var St=t(e=>(e.client??c).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/contractors/employments/{employment_id}/contractor-plus-subscription",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postManageContractorPlusSubscriptionSubscription"),vt=t(e=>(e.client??c).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/timeoff",...e}),"getIndexTimeoff");export{_ as a,c as b,He as c,Ne as d,Qe as e,$e as f,Je as g,Ke as h,Xe as i,Ye as j,Ze as k,et as l,tt as m,rt as n,ot as o,nt as p,st as q,at as r,it as s,pt as t,ct as u,lt as v,ht as w,mt as x,dt as y,yt as z,ut as A,Et as B,Ct as C,wt as D,ft as E,bt as F,Ot as G,Tt as H,xt as I,Pt as J,Rt as K,gt as L,Dt as M,Gt as N,St as O,vt as P};
|
|
6
|
-
//# sourceMappingURL=chunk-
|
|
5
|
+
`);try{P=JSON.parse(b),M=!0}catch{P=b}}M&&(a&&await a(P),s&&(P=await s(P))),o?.({data:P,event:V,id:E,retry:m}),I.length&&(yield P)}}}finally{T.removeEventListener("abort",L),w.releaseLock()}break}catch(x){if(r?.(x),c!==void 0&&C>=c)break;let O=Math.min(m*2**(C-1),p??3e4);await g(O)}}},"createStream")()}},"createSseClient");var se=t(e=>{switch(e){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},"separatorArrayExplode"),ae=t(e=>{switch(e){case"form":return",";case"pipeDelimited":return"|";case"spaceDelimited":return"%20";default:return","}},"separatorArrayNoExplode"),ie=t(e=>{switch(e){case"label":return".";case"matrix":return";";case"simple":return",";default:return"&"}},"separatorObjectExplode"),k=t(({allowReserved:e,explode:r,name:o,style:s,value:a})=>{if(!r){let p=(e?a:a.map(l=>encodeURIComponent(l))).join(ae(s));switch(s){case"label":return`.${p}`;case"matrix":return`;${o}=${p}`;case"simple":return p;default:return`${o}=${p}`}}let h=se(s),c=a.map(p=>s==="label"||s==="simple"?e?p:encodeURIComponent(p):R({allowReserved:e,name:o,value:p})).join(h);return s==="label"||s==="matrix"?h+c:c},"serializeArrayParam"),R=t(({allowReserved:e,name:r,value:o})=>{if(o==null)return"";if(typeof o=="object")throw new Error("Deeply-nested arrays/objects aren\u2019t supported. Provide your own `querySerializer()` to handle these.");return`${r}=${e?o:encodeURIComponent(o)}`},"serializePrimitiveParam"),U=t(({allowReserved:e,explode:r,name:o,style:s,value:a,valueOnly:h})=>{if(a instanceof Date)return h?a.toISOString():`${o}=${a.toISOString()}`;if(s!=="deepObject"&&!r){let l=[];Object.entries(a).forEach(([n,E])=>{l=[...l,n,e?E:encodeURIComponent(E)]});let d=l.join(",");switch(s){case"form":return`${o}=${d}`;case"label":return`.${d}`;case"matrix":return`;${o}=${d}`;default:return d}}let c=ie(s),p=Object.entries(a).map(([l,d])=>R({allowReserved:e,name:s==="deepObject"?`${o}[${l}]`:l,value:d})).join(c);return s==="label"||s==="matrix"?c+p:p},"serializeObjectParam");var pe=/\{[^{}]+\}/g,ce=t(({path:e,url:r})=>{let o=r,s=r.match(pe);if(s)for(let a of s){let h=!1,c=a.substring(1,a.length-1),p="simple";c.endsWith("*")&&(h=!0,c=c.substring(0,c.length-1)),c.startsWith(".")?(c=c.substring(1),p="label"):c.startsWith(";")&&(c=c.substring(1),p="matrix");let l=e[c];if(l==null)continue;if(Array.isArray(l)){o=o.replace(a,k({explode:h,name:c,style:p,value:l}));continue}if(typeof l=="object"){o=o.replace(a,U({explode:h,name:c,style:p,value:l,valueOnly:!0}));continue}if(p==="matrix"){o=o.replace(a,`;${R({name:c,value:l})}`);continue}let d=encodeURIComponent(p==="label"?`.${l}`:l);o=o.replace(a,d)}return o},"defaultPathSerializer"),$=t(({baseUrl:e,path:r,query:o,querySerializer:s,url:a})=>{let h=a.startsWith("/")?a:`/${a}`,c=(e??"")+h;r&&(c=ce({path:r,url:c}));let p=o?s(o):"";return p.startsWith("?")&&(p=p.substring(1)),p&&(c+=`?${p}`),c},"getUrl");function J(e){let r=e.body!==void 0;if(r&&e.bodySerializer)return"serializedBody"in e?e.serializedBody!==void 0&&e.serializedBody!==""?e.serializedBody:null:e.body!==""?e.body:null;if(r)return e.body}t(J,"getValidRequestBody");var K=t(async(e,r)=>{let o=typeof r=="function"?await r(e):r;if(o)return e.scheme==="bearer"?`Bearer ${o}`:e.scheme==="basic"?`Basic ${btoa(o)}`:o},"getAuthToken");var X=t(({parameters:e={},...r}={})=>t(s=>{let a=[];if(s&&typeof s=="object")for(let h in s){let c=s[h];if(c==null)continue;let p=e[h]||r;if(Array.isArray(c)){let l=k({allowReserved:p.allowReserved,explode:!0,name:h,style:"form",value:c,...p.array});l&&a.push(l)}else if(typeof c=="object"){let l=U({allowReserved:p.allowReserved,explode:!0,name:h,style:"deepObject",value:c,...p.object});l&&a.push(l)}else{let l=R({allowReserved:p.allowReserved,name:h,value:c});l&&a.push(l)}}return a.join("&")},"querySerializer"),"createQuerySerializer"),Y=t(e=>{if(!e)return"stream";let r=e.split(";")[0]?.trim();if(r){if(r.startsWith("application/json")||r.endsWith("+json"))return"json";if(r==="multipart/form-data")return"formData";if(["application/","audio/","image/","video/"].some(o=>r.startsWith(o)))return"blob";if(r.startsWith("text/"))return"text"}},"getParseAs"),le=t((e,r)=>r?!!(e.headers.has(r)||e.query?.[r]||e.headers.get("Cookie")?.includes(`${r}=`)):!1,"checkForExistence"),Z=t(async({security:e,...r})=>{for(let o of e){if(le(r,o.name))continue;let s=await K(o,r.auth);if(!s)continue;let a=o.name??"Authorization";switch(o.in){case"query":r.query||(r.query={}),r.query[a]=s;break;case"cookie":r.headers.append("Cookie",`${a}=${s}`);break;case"header":default:r.headers.set(a,s);break}}},"setAuthParams"),z=t(e=>$({baseUrl:e.baseUrl,path:e.path,query:e.query,querySerializer:typeof e.querySerializer=="function"?e.querySerializer:X(e.querySerializer),url:e.url}),"buildUrl"),W=t((e,r)=>{let o={...e,...r};return o.baseUrl?.endsWith("/")&&(o.baseUrl=o.baseUrl.substring(0,o.baseUrl.length-1)),o.headers=q(e.headers,r.headers),o},"mergeConfigs"),he=t(e=>{let r=[];return e.forEach((o,s)=>{r.push([s,o])}),r},"headersEntries"),q=t((...e)=>{let r=new Headers;for(let o of e){if(!o)continue;let s=o instanceof Headers?he(o):Object.entries(o);for(let[a,h]of s)if(h===null)r.delete(a);else if(Array.isArray(h))for(let c of h)r.append(a,c);else h!==void 0&&r.set(a,typeof h=="object"?JSON.stringify(h):h)}return r},"mergeHeaders"),G=class{static{t(this,"Interceptors")}fns=[];clear(){this.fns=[]}eject(r){let o=this.getInterceptorIndex(r);this.fns[o]&&(this.fns[o]=null)}exists(r){let o=this.getInterceptorIndex(r);return!!this.fns[o]}getInterceptorIndex(r){return typeof r=="number"?this.fns[r]?r:-1:this.fns.indexOf(r)}update(r,o){let s=this.getInterceptorIndex(r);return this.fns[s]?(this.fns[s]=o,r):!1}use(r){return this.fns.push(r),this.fns.length-1}},ee=t(()=>({error:new G,request:new G,response:new G}),"createInterceptors"),me=X({allowReserved:!1,array:{explode:!0,style:"form"},object:{explode:!0,style:"deepObject"}}),de={"Content-Type":"application/json"},S=t((e={})=>({...j,headers:de,parseAs:"auto",querySerializer:me,...e}),"createConfig");var _=t((e={})=>{let r=W(S(),e),o=t(()=>({...r}),"getConfig"),s=t(d=>(r=W(r,d),o()),"setConfig"),a=ee(),h=t(async d=>{let n={...r,...d,fetch:d.fetch??r.fetch??globalThis.fetch,headers:q(r.headers,d.headers),serializedBody:void 0};n.security&&await Z({...n,security:n.security}),n.requestValidator&&await n.requestValidator(n),n.body!==void 0&&n.bodySerializer&&(n.serializedBody=n.bodySerializer(n.body)),(n.body===void 0||n.serializedBody==="")&&n.headers.delete("Content-Type");let E=z(n);return{opts:n,url:E}},"beforeRequest"),c=t(async d=>{let{opts:n,url:E}=await h(d),g={redirect:"follow",...n,body:J(n)},f=new Request(E,g);for(let y of a.request.fns)y&&(f=await y(f,n));let v=n.fetch,m;try{m=await v(f)}catch(y){let u=y;for(let w of a.error.fns)w&&(u=await w(y,void 0,f,n));if(u=u||{},n.throwOnError)throw u;return n.responseStyle==="data"?void 0:{error:u,request:f,response:void 0}}for(let y of a.response.fns)y&&(m=await y(m,f,n));let C={request:f,response:m};if(m.ok){let y=(n.parseAs==="auto"?Y(m.headers.get("Content-Type")):n.parseAs)??"json";if(m.status===204||m.headers.get("Content-Length")==="0"){let w;switch(y){case"arrayBuffer":case"blob":case"text":w=await m[y]();break;case"formData":w=new FormData;break;case"stream":w=m.body;break;case"json":default:w={};break}return n.responseStyle==="data"?w:{data:w,...C}}let u;switch(y){case"arrayBuffer":case"blob":case"formData":case"json":case"text":u=await m[y]();break;case"stream":return n.responseStyle==="data"?m.body:{data:m.body,...C}}return y==="json"&&(n.responseValidator&&await n.responseValidator(u),n.responseTransformer&&(u=await n.responseTransformer(u))),n.responseStyle==="data"?u:{data:u,...C}}let T=await m.text(),D;try{D=JSON.parse(T)}catch{}let x=D??T,O=x;for(let y of a.error.fns)y&&(O=await y(x,m,f,n));if(O=O||{},n.throwOnError)throw O;return n.responseStyle==="data"?void 0:{error:O,...C}},"request"),p=t(d=>n=>c({...n,method:d}),"makeMethodFn"),l=t(d=>async n=>{let{opts:E,url:g}=await h(n);return Q({...E,body:E.body,headers:E.headers,method:d,onRequest:t(async(f,v)=>{let m=new Request(f,v);for(let C of a.request.fns)C&&(m=await C(m,E));return m},"onRequest"),url:g})},"makeSseFn");return{buildUrl:z,connect:p("CONNECT"),delete:p("DELETE"),get:p("GET"),getConfig:o,head:p("HEAD"),interceptors:a,options:p("OPTIONS"),patch:p("PATCH"),post:p("POST"),put:p("PUT"),request:c,setConfig:s,sse:{connect:l("CONNECT"),delete:l("DELETE"),get:l("GET"),head:l("HEAD"),options:l("OPTIONS"),patch:l("PATCH"),post:l("POST"),put:l("PUT"),trace:l("TRACE")},trace:p("TRACE")}},"createClient");var i=_(S({baseUrl:"https://gateway.remote.com/"}));var He=t(e=>(e?.client??i).post({security:[{scheme:"bearer",type:"http"}],url:"/v1/offboardings",...e,headers:{"Content-Type":"application/json",...e?.headers}}),"postCreateOffboarding");var Ne=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/contract-amendments/schema",...e}),"getShowContractAmendmentSchema");var Qe=t(e=>(e.client??i).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/currency-converter/raw",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postConvertRawCurrencyConverter"),$e=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/countries/{country_code}/contractor-contract-details",...e}),"getShowContractorContractDetailsCountry");var Je=t(e=>(e.client??i).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/employments",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postCreateEmployment2"),Ke=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/help-center-articles/{id}",...e}),"getShowHelpCenterArticle");var Xe=t(e=>(e.client??i).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/sdk/telemetry-errors",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postReportErrorsTelemetry");var Ye=t(e=>(e.client??i).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/cost-calculator/estimation",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postCreateEstimation");var Ze=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/employments/{employment_id}/benefit-offers",...e}),"getIndexBenefitOffer"),et=t(e=>(e.client??i).put({security:[{scheme:"bearer",type:"http"}],url:"/v1/employments/{employment_id}/benefit-offers",...e,headers:{"Content-Type":"application/json",...e.headers}}),"putUpdateBenefitOffer");var tt=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/contractors/employments/{employment_id}/contractor-subscriptions",...e}),"getIndexSubscription");var rt=t(e=>(e?.client??i).get({security:[{scheme:"bearer",type:"http"}],url:"/v1/payroll-calendars",...e}),"getIndexEorPayrollCalendar");var ot=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/contractors/employments/{employment_id}/contract-documents/{id}",...e}),"getShowContractDocument"),nt=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/employments/{employment_id}/contract-documents",...e}),"getIndexEmploymentContractDocument");var st=t(e=>(e.client??i).post({security:[{scheme:"bearer",type:"http"}],url:"/v1/magic-link",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postGenerateMagicLink");var at=t(e=>(e?.client??i).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/cost-calculator/estimation-pdf",...e,headers:{"Content-Type":"application/json",...e?.headers}}),"postCreateEstimationPdf");var it=t(e=>(e.client??i).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/risk-reserve",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postCreateRiskReserve");var pt=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"}],url:"/v1/companies/{company_id}",...e}),"getShowCompany");var ct=t(e=>(e.client??i).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/contract-amendments",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postCreateContractAmendment");var lt=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/countries/{country_code}/{form}",...e}),"getShowFormCountry"),ht=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/files/{id}",...e}),"getShowFile");var mt=t(e=>(e?.client??i).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/cost-calculator/countries",...e}),"getIndexCountry");var dt=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/leave-policies/summary/{employment_id}",...e}),"getIndexLeavePoliciesSummary");var yt=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/employments/{employment_id}/benefit-offers/schema",...e}),"getShowSchema");var ut=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/employments/{employment_id}",...e}),"getShowEmployment"),Et=t(e=>(e.client??i).patch({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/employments/{employment_id}",...e,headers:{"Content-Type":"application/json",...e.headers}}),"patchUpdateEmployment2");var Ct=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"}],url:"/v1/cost-calculator/regions/{slug}/fields",...e}),"getShowRegionField");var wt=t(e=>(e.client??i).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/employments/{employment_id}/contract-eligibility",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postCreateContractEligibility"),ft=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"}],url:"/v1/countries",...e}),"getSupportedCountry");var bt=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"}],url:"/v1/companies/{company_id}/legal-entities",...e}),"getIndexCompanyLegalEntities");var Ot=t(e=>(e?.client??i).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/cost-calculator/estimation-csv",...e,headers:{"Content-Type":"application/json",...e?.headers}}),"postCreateEstimationCsv"),Tt=t(e=>(e.client??i).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/contractors/employments/{employment_id}/contract-documents",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postCreateContractDocument");var xt=t(e=>(e.client??i).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/currency-converter/effective",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postConvertWithSpreadCurrencyConverter");var Pt=t(e=>(e.client??i).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/contract-amendments/automatable",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postAutomatableContractAmendment");var Rt=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/employments/{employment_id}/files",...e}),"getIndexEmploymentFile");var gt=t(e=>(e?.client??i).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/company-currencies",...e}),"getIndexCompanyCurrency");var Dt=t(e=>(e.client??i).post({...B,security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/documents",...e,headers:{"Content-Type":null,...e.headers}}),"postUploadEmployeeFileFile"),Gt=t(e=>(e.client??i).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/employments/{employment_id}/invite",...e}),"postInviteEmploymentInvitation");var St=t(e=>(e.client??i).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/contractors/employments/{employment_id}/contract-documents/{contract_document_id}/sign",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postSignContractDocument"),vt=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"}],url:"/v1/identity/current",...e}),"getCurrentIdentity");var It=t(e=>(e.client??i).post({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/contractors/employments/{employment_id}/contractor-plus-subscription",...e,headers:{"Content-Type":"application/json",...e.headers}}),"postManageContractorPlusSubscriptionSubscription"),kt=t(e=>(e.client??i).get({security:[{scheme:"bearer",type:"http"},{scheme:"bearer",type:"http"}],url:"/v1/timeoff",...e}),"getIndexTimeoff");export{_ as a,i as b,He as c,Ne as d,Qe as e,$e as f,Je as g,Ke as h,Xe as i,Ye as j,Ze as k,et as l,tt as m,rt as n,ot as o,nt as p,st as q,at as r,it as s,pt as t,ct as u,lt as v,ht as w,mt as x,dt as y,yt as z,ut as A,Et as B,Ct as C,wt as D,ft as E,bt as F,Ot as G,Tt as H,xt as I,Pt as J,Rt as K,gt as L,Dt as M,Gt as N,St as O,vt as P,It as Q,kt as R};
|
|
6
|
+
//# sourceMappingURL=chunk-PJ6ZEFWD.js.map
|