@remoteoss/remote-flows 0.4.0-alpha.22 → 0.4.0-alpha.24
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/chunk-276MJCIE.js +2 -0
- package/dist/chunk-276MJCIE.js.map +1 -0
- package/dist/{chunk-7ZH23EMZ.js → chunk-2XB53D4F.js} +2 -2
- package/dist/chunk-3M333MY5.js +2 -0
- package/dist/chunk-3M333MY5.js.map +1 -0
- package/dist/chunk-44JKZZZV.js +2 -0
- package/dist/chunk-44JKZZZV.js.map +1 -0
- package/dist/{chunk-EPLIVM3Y.js → chunk-4TJM5BGM.js} +2 -2
- package/dist/{chunk-5SMMQQXP.js → chunk-5B53X4DT.js} +2 -2
- package/dist/{chunk-3QGKRPQ6.js → chunk-5MCOAQZT.js} +2 -2
- package/dist/{chunk-DOLJU76M.js → chunk-5RNC6C3X.js} +2 -2
- package/dist/{chunk-SIC7BRJ2.js → chunk-6AVZ2OMN.js} +2 -2
- package/dist/chunk-6ID67VGK.js +2 -0
- package/dist/chunk-6ID67VGK.js.map +1 -0
- package/dist/chunk-ERFMX2SZ.js +2 -0
- package/dist/chunk-ERFMX2SZ.js.map +1 -0
- package/dist/{chunk-AIEAUPO6.js → chunk-FBH65XSW.js} +2 -2
- package/dist/{chunk-O53436KO.js → chunk-FO63W3K4.js} +2 -2
- package/dist/{chunk-ETMTVNOU.js → chunk-FPPBJKEX.js} +2 -2
- package/dist/{chunk-TNF6DNGM.js → chunk-FZXLDWTF.js} +2 -2
- package/dist/chunk-G42IXTZ3.js +2 -0
- package/dist/{chunk-MH6KKP6K.js.map → chunk-G42IXTZ3.js.map} +1 -1
- package/dist/chunk-GFLZSZAF.js +2 -0
- package/dist/chunk-GFLZSZAF.js.map +1 -0
- package/dist/{chunk-ISOKYXYN.js → chunk-HH6XQXFS.js} +2 -2
- package/dist/{chunk-LPR2D3EY.js → chunk-IFBRXDZN.js} +2 -2
- package/dist/chunk-IWLUIA2A.js +2 -0
- package/dist/chunk-IWLUIA2A.js.map +1 -0
- package/dist/{chunk-Q23DM4O3.js → chunk-MC6FNME3.js} +2 -2
- package/dist/{chunk-FCHRSRS6.js → chunk-MLQPWWXF.js} +2 -2
- package/dist/{chunk-CSU6IQX3.js → chunk-OQKQUCGJ.js} +2 -2
- package/dist/{chunk-CEIK7DGY.js → chunk-QMLY7L2K.js} +2 -2
- package/dist/{chunk-JXCJLQRA.js → chunk-SYEPIESJ.js} +2 -2
- package/dist/{chunk-WASEFJAE.js → chunk-TDUDSH4U.js} +2 -2
- package/dist/{chunk-YNQVZYFG.js → chunk-UXTAEC55.js} +2 -2
- package/dist/{chunk-LX7QBDSF.js → chunk-VTNGEN34.js} +2 -2
- package/dist/{chunk-63BYEK44.js → chunk-WJCUOG2K.js} +2 -2
- package/dist/{chunk-63BYEK44.js.map → chunk-WJCUOG2K.js.map} +1 -1
- package/dist/{chunk-3R33SVSF.js → chunk-XYY3IAQ3.js} +2 -2
- package/dist/{chunk-ARYI3WUN.js → chunk-Y7WTP3MZ.js} +2 -2
- package/dist/{chunk-MO7KC4HE.js → chunk-ZBVJJCAF.js} +2 -2
- package/dist/{chunk-LFIQVLFK.js → chunk-ZELM2RXE.js} +2 -2
- package/dist/flows/ContractAmendment/ContractAmendmentConfirmationForm.d.ts +1 -1
- package/dist/flows/ContractAmendment/ContractAmendmentConfirmationForm.js +1 -1
- package/dist/flows/ContractAmendment/ContractAmendmentFlow.d.ts +1 -1
- 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 +1 -1
- package/dist/flows/ContractAmendment/hooks.d.ts +1 -1
- package/dist/flows/ContractAmendment/hooks.js +1 -1
- package/dist/flows/ContractAmendment/index.d.ts +1 -1
- package/dist/flows/ContractAmendment/index.js +1 -1
- package/dist/flows/ContractAmendment/utils.d.ts +1 -1
- package/dist/flows/ContractAmendment/utils.js +1 -1
- package/dist/flows/CostCalculator/CostCalculatorFlow.d.ts +7 -3
- package/dist/flows/CostCalculator/CostCalculatorFlow.js +1 -1
- package/dist/flows/CostCalculator/CostCalculatorForm.d.ts +1 -1
- package/dist/flows/CostCalculator/CostCalculatorForm.js +1 -1
- package/dist/flows/CostCalculator/Results/CostCalculatorResults.d.ts +1 -1
- package/dist/flows/CostCalculator/api.d.ts +1 -1
- 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 +5 -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 +1 -1
- package/dist/flows/CostCalculator/utils.d.ts +7 -4
- package/dist/flows/CostCalculator/utils.js +1 -1
- package/dist/flows/Onboarding/OnboardingFlow.d.ts +3 -3
- package/dist/flows/Onboarding/OnboardingFlow.js +1 -1
- package/dist/flows/Onboarding/api.d.ts +30 -3
- 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 +1 -1
- package/dist/flows/Onboarding/components/BasicInformationStep.js +1 -1
- package/dist/flows/Onboarding/components/BenefitsStep.d.ts +3 -3
- package/dist/flows/Onboarding/components/BenefitsStep.js +1 -1
- package/dist/flows/Onboarding/components/ContractDetailsStep.d.ts +1 -1
- package/dist/flows/Onboarding/components/ContractDetailsStep.js +1 -1
- package/dist/flows/Onboarding/components/OnboardingForm.d.ts +3 -3
- package/dist/flows/Onboarding/components/OnboardingForm.js +1 -1
- package/dist/flows/Onboarding/components/OnboardingInvite.d.ts +1 -1
- package/dist/flows/Onboarding/components/OnboardingInvite.js +1 -1
- package/dist/flows/Onboarding/components/ReviewStep.d.ts +1 -1
- package/dist/flows/Onboarding/components/SelectCountryStep.d.ts +1 -1
- package/dist/flows/Onboarding/components/SelectCountryStep.js +1 -1
- package/dist/flows/Onboarding/context.d.ts +5 -1
- package/dist/flows/Onboarding/hooks.d.ts +5 -1
- 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 +1 -1
- package/dist/flows/Onboarding/utils.d.ts +1 -1
- package/dist/flows/Termination/AdditionalDetailsForm.d.ts +1 -1
- package/dist/flows/Termination/AdditionalDetailsForm.js +1 -1
- package/dist/flows/Termination/EmployeeComunicationForm.d.ts +1 -1
- package/dist/flows/Termination/EmployeeComunicationForm.js +1 -1
- package/dist/flows/Termination/PaidTimeOffForm.d.ts +1 -1
- package/dist/flows/Termination/PaidTimeOffForm.js +1 -1
- package/dist/flows/Termination/TerminationDetailsForm.d.ts +1 -1
- package/dist/flows/Termination/TerminationDetailsForm.js +1 -1
- package/dist/flows/Termination/TerminationFlow.d.ts +1 -1
- package/dist/flows/Termination/TerminationFlow.js +1 -1
- package/dist/flows/Termination/TerminationForm.d.ts +1 -1
- package/dist/flows/Termination/TerminationForm.js +1 -1
- package/dist/flows/Termination/TimeOff.d.ts +1 -1
- package/dist/flows/Termination/TimeOff.js +1 -1
- package/dist/flows/Termination/context.d.ts +1 -1
- package/dist/flows/Termination/hooks.d.ts +1 -1
- package/dist/flows/Termination/hooks.js +1 -1
- package/dist/flows/Termination/index.d.ts +1 -1
- package/dist/flows/Termination/index.js +1 -1
- package/dist/flows/Termination/types.d.ts +1 -1
- package/dist/flows/utils.d.ts +1 -1
- package/dist/index.d.ts +5 -5
- package/dist/index.js +1 -1
- package/dist/{remoteFlows-DFkKjnDe.d.ts → remoteFlows-DsgyOm1z.d.ts} +8 -2
- package/dist/types-Zg1n_9wh.d.ts +3 -0
- package/dist/{types.gen-DL1ycXOS.d.ts → types.gen-DSJsKiNm.d.ts} +26 -1
- package/package.json +1 -1
- package/dist/chunk-3BIRQAED.js +0 -2
- package/dist/chunk-3BIRQAED.js.map +0 -1
- package/dist/chunk-7NBID3JL.js +0 -2
- package/dist/chunk-7NBID3JL.js.map +0 -1
- package/dist/chunk-LFLO2IJA.js +0 -2
- package/dist/chunk-LFLO2IJA.js.map +0 -1
- package/dist/chunk-MH6KKP6K.js +0 -2
- package/dist/chunk-MNFM2TNK.js +0 -2
- package/dist/chunk-MNFM2TNK.js.map +0 -1
- package/dist/chunk-WKK63LAY.js +0 -2
- package/dist/chunk-WKK63LAY.js.map +0 -1
- package/dist/chunk-XKSOWDLS.js +0 -2
- package/dist/chunk-XKSOWDLS.js.map +0 -1
- package/dist/chunk-XMDNHTKE.js +0 -2
- package/dist/chunk-XMDNHTKE.js.map +0 -1
- package/dist/types-CxSFjQw5.d.ts +0 -3
- /package/dist/{chunk-7ZH23EMZ.js.map → chunk-2XB53D4F.js.map} +0 -0
- /package/dist/{chunk-EPLIVM3Y.js.map → chunk-4TJM5BGM.js.map} +0 -0
- /package/dist/{chunk-5SMMQQXP.js.map → chunk-5B53X4DT.js.map} +0 -0
- /package/dist/{chunk-3QGKRPQ6.js.map → chunk-5MCOAQZT.js.map} +0 -0
- /package/dist/{chunk-DOLJU76M.js.map → chunk-5RNC6C3X.js.map} +0 -0
- /package/dist/{chunk-SIC7BRJ2.js.map → chunk-6AVZ2OMN.js.map} +0 -0
- /package/dist/{chunk-AIEAUPO6.js.map → chunk-FBH65XSW.js.map} +0 -0
- /package/dist/{chunk-O53436KO.js.map → chunk-FO63W3K4.js.map} +0 -0
- /package/dist/{chunk-ETMTVNOU.js.map → chunk-FPPBJKEX.js.map} +0 -0
- /package/dist/{chunk-TNF6DNGM.js.map → chunk-FZXLDWTF.js.map} +0 -0
- /package/dist/{chunk-ISOKYXYN.js.map → chunk-HH6XQXFS.js.map} +0 -0
- /package/dist/{chunk-LPR2D3EY.js.map → chunk-IFBRXDZN.js.map} +0 -0
- /package/dist/{chunk-Q23DM4O3.js.map → chunk-MC6FNME3.js.map} +0 -0
- /package/dist/{chunk-FCHRSRS6.js.map → chunk-MLQPWWXF.js.map} +0 -0
- /package/dist/{chunk-CSU6IQX3.js.map → chunk-OQKQUCGJ.js.map} +0 -0
- /package/dist/{chunk-CEIK7DGY.js.map → chunk-QMLY7L2K.js.map} +0 -0
- /package/dist/{chunk-JXCJLQRA.js.map → chunk-SYEPIESJ.js.map} +0 -0
- /package/dist/{chunk-WASEFJAE.js.map → chunk-TDUDSH4U.js.map} +0 -0
- /package/dist/{chunk-YNQVZYFG.js.map → chunk-UXTAEC55.js.map} +0 -0
- /package/dist/{chunk-LX7QBDSF.js.map → chunk-VTNGEN34.js.map} +0 -0
- /package/dist/{chunk-3R33SVSF.js.map → chunk-XYY3IAQ3.js.map} +0 -0
- /package/dist/{chunk-ARYI3WUN.js.map → chunk-Y7WTP3MZ.js.map} +0 -0
- /package/dist/{chunk-MO7KC4HE.js.map → chunk-ZBVJJCAF.js.map} +0 -0
- /package/dist/{chunk-LFIQVLFK.js.map → chunk-ZELM2RXE.js.map} +0 -0
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import"../../chunk-GULCZWSK.js";import{a}from"../../chunk-
|
|
1
|
+
import"../../chunk-GULCZWSK.js";import{a}from"../../chunk-UXTAEC55.js";import"../../chunk-7TOZZQQJ.js";import"../../chunk-QMLY7L2K.js";import"../../chunk-XYY3IAQ3.js";import"../../chunk-HH6XQXFS.js";import"../../chunk-IFBRXDZN.js";import"../../chunk-MSBG52WO.js";import"../../chunk-WJCUOG2K.js";import"../../chunk-2XB53D4F.js";import"../../chunk-FUIQ7D6L.js";import"../../chunk-KFVOK5X5.js";import"../../chunk-PGWKJ6FK.js";import"../../chunk-44JKZZZV.js";import"../../chunk-ZBVJJCAF.js";import"../../chunk-XIPPSRO6.js";import"../../chunk-IWLUIA2A.js";import"../../chunk-3M333MY5.js";import"../../chunk-WVJDCDGZ.js";import"../../chunk-PWUYHFON.js";import"../../chunk-QW4JPW6J.js";import"../../chunk-276MJCIE.js";import"../../chunk-PJBAQZ6G.js";import"../../chunk-ERFMX2SZ.js";import"../../chunk-XO3JWN33.js";import"../../chunk-CFIJKJXD.js";import"../../chunk-N6NYXAXH.js";import"../../chunk-GEYFQVQI.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-VNSF5IOL.js";import"../../chunk-G42IXTZ3.js";import"../../chunk-KPHSEIR3.js";import"../../chunk-P37U34EQ.js";export{a as OnboardingFlow};
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { o as EmploymentCreateParams, i as Employment$1 } from '../../types.gen-
|
|
1
|
+
import { o as EmploymentCreateParams, i as Employment$1 } from '../../types.gen-DSJsKiNm.js';
|
|
2
2
|
import { FlowOptions, JSFModify } from '../types.js';
|
|
3
3
|
import '@remoteoss/json-schema-form';
|
|
4
4
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Employment } from './types.js';
|
|
2
2
|
import { Step } from '../useStepState.js';
|
|
3
3
|
import { Fields } from '@remoteoss/json-schema-form';
|
|
4
|
-
import '../../types.gen-
|
|
4
|
+
import '../../types.gen-DSJsKiNm.js';
|
|
5
5
|
import '../types.js';
|
|
6
6
|
import 'react';
|
|
7
7
|
import 'react-hook-form';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { TerminationFormValues } from './types.js';
|
|
3
|
-
import { O as OffboardingResponse } from '../../types.gen-
|
|
3
|
+
import { O as OffboardingResponse } from '../../types.gen-DSJsKiNm.js';
|
|
4
4
|
|
|
5
5
|
type AdditionalDetailsFormProps = {
|
|
6
6
|
requesterName: string;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../chunk-
|
|
1
|
+
import{a}from"../../chunk-ZELM2RXE.js";import"../../chunk-6AVZ2OMN.js";import"../../chunk-MRYRNB7Y.js";import"../../chunk-ERFMX2SZ.js";import"../../chunk-XO3JWN33.js";import"../../chunk-CFIJKJXD.js";import"../../chunk-N6NYXAXH.js";import"../../chunk-GEYFQVQI.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-VNSF5IOL.js";import"../../chunk-G42IXTZ3.js";import"../../chunk-KPHSEIR3.js";import"../../chunk-P37U34EQ.js";export{a as AdditionalDetailsForm};
|
|
2
2
|
//# sourceMappingURL=AdditionalDetailsForm.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { TerminationFormValues } from './types.js';
|
|
3
|
-
import '../../types.gen-
|
|
3
|
+
import '../../types.gen-DSJsKiNm.js';
|
|
4
4
|
|
|
5
5
|
type EmployeeComunicationProps = {
|
|
6
6
|
onSubmit?: (payload: TerminationFormValues) => void | Promise<void>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../chunk-
|
|
1
|
+
import{a}from"../../chunk-FZXLDWTF.js";import"../../chunk-6AVZ2OMN.js";import"../../chunk-MRYRNB7Y.js";import"../../chunk-ERFMX2SZ.js";import"../../chunk-XO3JWN33.js";import"../../chunk-CFIJKJXD.js";import"../../chunk-N6NYXAXH.js";import"../../chunk-GEYFQVQI.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-VNSF5IOL.js";import"../../chunk-G42IXTZ3.js";import"../../chunk-KPHSEIR3.js";import"../../chunk-P37U34EQ.js";export{a as EmployeeCommunicationForm};
|
|
2
2
|
//# sourceMappingURL=EmployeeComunicationForm.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { TerminationFormValues } from './types.js';
|
|
3
|
-
import '../../types.gen-
|
|
3
|
+
import '../../types.gen-DSJsKiNm.js';
|
|
4
4
|
|
|
5
5
|
type PaidTimeOffFormProps = {
|
|
6
6
|
onSubmit?: (payload: TerminationFormValues) => void | Promise<void>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../chunk-
|
|
1
|
+
import{a}from"../../chunk-MLQPWWXF.js";import"../../chunk-6AVZ2OMN.js";import"../../chunk-MRYRNB7Y.js";import"../../chunk-ERFMX2SZ.js";import"../../chunk-XO3JWN33.js";import"../../chunk-CFIJKJXD.js";import"../../chunk-N6NYXAXH.js";import"../../chunk-GEYFQVQI.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-VNSF5IOL.js";import"../../chunk-G42IXTZ3.js";import"../../chunk-KPHSEIR3.js";import"../../chunk-P37U34EQ.js";export{a as PaidTimeOffForm};
|
|
2
2
|
//# sourceMappingURL=PaidTimeOffForm.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { TerminationFormValues } from './types.js';
|
|
3
|
-
import '../../types.gen-
|
|
3
|
+
import '../../types.gen-DSJsKiNm.js';
|
|
4
4
|
|
|
5
5
|
type TerminationDetailsFormProps = {
|
|
6
6
|
onSubmit?: (payload: TerminationFormValues) => void | Promise<void>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../chunk-
|
|
1
|
+
import{a}from"../../chunk-FO63W3K4.js";import"../../chunk-6AVZ2OMN.js";import"../../chunk-MRYRNB7Y.js";import"../../chunk-ERFMX2SZ.js";import"../../chunk-XO3JWN33.js";import"../../chunk-CFIJKJXD.js";import"../../chunk-N6NYXAXH.js";import"../../chunk-GEYFQVQI.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-VNSF5IOL.js";import"../../chunk-G42IXTZ3.js";import"../../chunk-KPHSEIR3.js";import"../../chunk-P37U34EQ.js";export{a as TerminationDetailsForm};
|
|
2
2
|
//# sourceMappingURL=TerminationDetailsForm.js.map
|
|
@@ -10,7 +10,7 @@ import { PaidTimeOffForm } from './PaidTimeOffForm.js';
|
|
|
10
10
|
import { AdditionalDetailsForm } from './AdditionalDetailsForm.js';
|
|
11
11
|
import { JSFModify } from '../types.js';
|
|
12
12
|
import './types.js';
|
|
13
|
-
import '../../types.gen-
|
|
13
|
+
import '../../types.gen-DSJsKiNm.js';
|
|
14
14
|
import '../../mutations-B6HWH-rZ.js';
|
|
15
15
|
import '@remoteoss/json-schema-form';
|
|
16
16
|
import '../useStepState.js';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../chunk-
|
|
1
|
+
import{a}from"../../chunk-FPPBJKEX.js";import"../../chunk-LLIGZSYY.js";import"../../chunk-SYEPIESJ.js";import"../../chunk-TDUDSH4U.js";import"../../chunk-HSW5HMHH.js";import"../../chunk-VX2UC3HG.js";import"../../chunk-XSHHMBMT.js";import"../../chunk-XFD3ULUF.js";import"../../chunk-JODJFARP.js";import"../../chunk-WWANHPT7.js";import"../../chunk-W5DG5WWJ.js";import"../../chunk-S4XU4SE7.js";import"../../chunk-ZELM2RXE.js";import"../../chunk-FZXLDWTF.js";import"../../chunk-MLQPWWXF.js";import"../../chunk-BF7QENCN.js";import"../../chunk-FO63W3K4.js";import"../../chunk-6AVZ2OMN.js";import"../../chunk-MRYRNB7Y.js";import"../../chunk-PWUYHFON.js";import"../../chunk-VTNGEN34.js";import"../../chunk-QW4JPW6J.js";import"../../chunk-276MJCIE.js";import"../../chunk-PJBAQZ6G.js";import"../../chunk-ERFMX2SZ.js";import"../../chunk-XO3JWN33.js";import"../../chunk-CFIJKJXD.js";import"../../chunk-N6NYXAXH.js";import"../../chunk-GEYFQVQI.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-VNSF5IOL.js";import"../../chunk-G42IXTZ3.js";import"../../chunk-KPHSEIR3.js";import"../../chunk-P37U34EQ.js";export{a as TerminationFlow};
|
|
2
2
|
//# sourceMappingURL=TerminationFlow.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import { TerminationFormValues } from './types.js';
|
|
3
3
|
import { Fields } from '@remoteoss/json-schema-form';
|
|
4
|
-
import '../../types.gen-
|
|
4
|
+
import '../../types.gen-DSJsKiNm.js';
|
|
5
5
|
|
|
6
6
|
type TerminationFormProps = {
|
|
7
7
|
onSubmit: (payload: TerminationFormValues) => void;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../chunk-
|
|
1
|
+
import{a}from"../../chunk-6AVZ2OMN.js";import"../../chunk-MRYRNB7Y.js";import"../../chunk-ERFMX2SZ.js";import"../../chunk-XO3JWN33.js";import"../../chunk-CFIJKJXD.js";import"../../chunk-N6NYXAXH.js";import"../../chunk-GEYFQVQI.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-VNSF5IOL.js";import"../../chunk-G42IXTZ3.js";import"../../chunk-KPHSEIR3.js";import"../../chunk-P37U34EQ.js";export{a as TerminationForm};
|
|
2
2
|
//# sourceMappingURL=TerminationForm.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { E as EmploymentShowResponse, L as ListTimeoffResponse } from '../../types.gen-
|
|
1
|
+
import { E as EmploymentShowResponse, L as ListTimeoffResponse } from '../../types.gen-DSJsKiNm.js';
|
|
2
2
|
import react__default from 'react';
|
|
3
3
|
|
|
4
4
|
declare const TimeOff: ({ render, }: {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../chunk-
|
|
1
|
+
import{a}from"../../chunk-SYEPIESJ.js";import"../../chunk-MRYRNB7Y.js";import"../../chunk-VTNGEN34.js";import"../../chunk-276MJCIE.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-P37U34EQ.js";export{a as TimeOff};
|
|
2
2
|
//# sourceMappingURL=TimeOff.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { O as OffboardingResponse,
|
|
1
|
+
import { O as OffboardingResponse, B as PostCreateOffboardingError } from '../../types.gen-DSJsKiNm.js';
|
|
2
2
|
import * as _remoteoss_json_schema_form from '@remoteoss/json-schema-form';
|
|
3
3
|
import * as react from 'react';
|
|
4
4
|
import { E as ErrorResponse, S as SuccessResponse } from '../../mutations-B6HWH-rZ.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { O as OffboardingResponse,
|
|
1
|
+
import { O as OffboardingResponse, B as PostCreateOffboardingError } from '../../types.gen-DSJsKiNm.js';
|
|
2
2
|
import { E as ErrorResponse, S as SuccessResponse } from '../../mutations-B6HWH-rZ.js';
|
|
3
3
|
import * as _remoteoss_json_schema_form from '@remoteoss/json-schema-form';
|
|
4
4
|
import { Step } from '../useStepState.js';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../chunk-
|
|
1
|
+
import{a}from"../../chunk-TDUDSH4U.js";import"../../chunk-HSW5HMHH.js";import"../../chunk-VX2UC3HG.js";import"../../chunk-XSHHMBMT.js";import"../../chunk-XFD3ULUF.js";import"../../chunk-JODJFARP.js";import"../../chunk-WWANHPT7.js";import"../../chunk-W5DG5WWJ.js";import"../../chunk-S4XU4SE7.js";import"../../chunk-PWUYHFON.js";import"../../chunk-QW4JPW6J.js";import"../../chunk-276MJCIE.js";import"../../chunk-PJBAQZ6G.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-G42IXTZ3.js";import"../../chunk-P37U34EQ.js";export{a as useTermination};
|
|
2
2
|
//# sourceMappingURL=hooks.js.map
|
|
@@ -3,7 +3,7 @@ export { TerminationFormValues } from './types.js';
|
|
|
3
3
|
import 'react/jsx-runtime';
|
|
4
4
|
import 'react';
|
|
5
5
|
import './hooks.js';
|
|
6
|
-
import '../../types.gen-
|
|
6
|
+
import '../../types.gen-DSJsKiNm.js';
|
|
7
7
|
import '../../mutations-B6HWH-rZ.js';
|
|
8
8
|
import '@remoteoss/json-schema-form';
|
|
9
9
|
import '../useStepState.js';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import"../../chunk-M22FKNEY.js";import{a}from"../../chunk-
|
|
1
|
+
import"../../chunk-M22FKNEY.js";import{a}from"../../chunk-FPPBJKEX.js";import"../../chunk-LLIGZSYY.js";import"../../chunk-SYEPIESJ.js";import"../../chunk-TDUDSH4U.js";import"../../chunk-HSW5HMHH.js";import"../../chunk-VX2UC3HG.js";import"../../chunk-XSHHMBMT.js";import"../../chunk-XFD3ULUF.js";import"../../chunk-JODJFARP.js";import"../../chunk-WWANHPT7.js";import"../../chunk-W5DG5WWJ.js";import"../../chunk-S4XU4SE7.js";import"../../chunk-ZELM2RXE.js";import"../../chunk-FZXLDWTF.js";import"../../chunk-MLQPWWXF.js";import"../../chunk-BF7QENCN.js";import"../../chunk-FO63W3K4.js";import"../../chunk-6AVZ2OMN.js";import"../../chunk-MRYRNB7Y.js";import"../../chunk-PWUYHFON.js";import"../../chunk-VTNGEN34.js";import"../../chunk-QW4JPW6J.js";import"../../chunk-276MJCIE.js";import"../../chunk-PJBAQZ6G.js";import"../../chunk-ERFMX2SZ.js";import"../../chunk-XO3JWN33.js";import"../../chunk-CFIJKJXD.js";import"../../chunk-N6NYXAXH.js";import"../../chunk-GEYFQVQI.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-VNSF5IOL.js";import"../../chunk-G42IXTZ3.js";import"../../chunk-KPHSEIR3.js";import"../../chunk-P37U34EQ.js";export{a as TerminationFlow};
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
package/dist/flows/utils.d.ts
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -20,19 +20,19 @@ export { OnboardingInviteProps } from './flows/Onboarding/components/OnboardingI
|
|
|
20
20
|
export { BasicInformationFormPayload, BenefitsFormPayload, ContractDetailsFormPayload, CreditRiskState, CreditRiskStatus, Employment, Meta, SelectCountryFormPayload, SelectCountrySuccess } from './flows/Onboarding/types.js';
|
|
21
21
|
export { CostCalculatorEstimationFormValues, CostCalculatorEstimationOptions, CostCalculatorEstimationSubmitValues } from './flows/CostCalculator/types.js';
|
|
22
22
|
import * as _tanstack_react_query from '@tanstack/react-query';
|
|
23
|
-
import { E as EmploymentShowResponse,
|
|
24
|
-
export { j as Company, C as ContractAmendmentAutomatableResponse,
|
|
23
|
+
import { E as EmploymentShowResponse, D as TimeoffStatus, L as ListTimeoffResponse } from './types.gen-DSJsKiNm.js';
|
|
24
|
+
export { j as Company, C as ContractAmendmentAutomatableResponse, F as CostCalculatorEmployment, c as CostCalculatorEstimateResponse, G as Currency, m as EmploymentCreationResponse, p as EmploymentResponse, O as OffboardingResponse, S as SuccessResponse } from './types.gen-DSJsKiNm.js';
|
|
25
25
|
import { ContractAmendmentParams } from './flows/ContractAmendment/types.js';
|
|
26
26
|
import { ValidationError } from 'yup';
|
|
27
27
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
28
28
|
import { PropsWithChildren } from 'react';
|
|
29
|
-
import { R as RemoteFlowsSDKProps } from './remoteFlows-
|
|
30
|
-
export { $ as $TSFixMe, B as ButtonComponentProps, C as Components, F as FieldComponentProps, S as StatementComponentProps } from './remoteFlows-
|
|
29
|
+
import { R as RemoteFlowsSDKProps } from './remoteFlows-DsgyOm1z.js';
|
|
30
|
+
export { $ as $TSFixMe, B as ButtonComponentProps, C as Components, F as FieldComponentProps, S as StatementComponentProps } from './remoteFlows-DsgyOm1z.js';
|
|
31
31
|
export { F as FieldError, N as NormalizedFieldError } from './mutations-B6HWH-rZ.js';
|
|
32
32
|
import './flows/types.js';
|
|
33
33
|
import '@remoteoss/json-schema-form';
|
|
34
34
|
import 'react-hook-form';
|
|
35
|
-
import './types-
|
|
35
|
+
import './types-Zg1n_9wh.js';
|
|
36
36
|
import './flows/ContractAmendment/ContractAmendmentBack.js';
|
|
37
37
|
import './flows/useStepState.js';
|
|
38
38
|
import './flows/Termination/hooks.js';
|
package/dist/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import"./chunk-M22FKNEY.js";import{a as tr}from"./chunk-
|
|
1
|
+
import"./chunk-M22FKNEY.js";import{a as tr}from"./chunk-FPPBJKEX.js";import"./chunk-LLIGZSYY.js";import"./chunk-SYEPIESJ.js";import"./chunk-TDUDSH4U.js";import"./chunk-HSW5HMHH.js";import"./chunk-VX2UC3HG.js";import"./chunk-XSHHMBMT.js";import"./chunk-XFD3ULUF.js";import"./chunk-JODJFARP.js";import"./chunk-WWANHPT7.js";import"./chunk-W5DG5WWJ.js";import"./chunk-S4XU4SE7.js";import"./chunk-ZELM2RXE.js";import"./chunk-FZXLDWTF.js";import"./chunk-MLQPWWXF.js";import"./chunk-BF7QENCN.js";import"./chunk-FO63W3K4.js";import"./chunk-6AVZ2OMN.js";import"./chunk-MRYRNB7Y.js";import"./chunk-GULCZWSK.js";import{a as or}from"./chunk-UXTAEC55.js";import"./chunk-7TOZZQQJ.js";import"./chunk-QMLY7L2K.js";import"./chunk-XYY3IAQ3.js";import"./chunk-HH6XQXFS.js";import"./chunk-IFBRXDZN.js";import"./chunk-MSBG52WO.js";import"./chunk-WJCUOG2K.js";import"./chunk-2XB53D4F.js";import"./chunk-FUIQ7D6L.js";import"./chunk-KFVOK5X5.js";import"./chunk-PGWKJ6FK.js";import"./chunk-44JKZZZV.js";import"./chunk-ZBVJJCAF.js";import"./chunk-XIPPSRO6.js";import"./chunk-YJXRJTOH.js";import{a as E}from"./chunk-MNO47WC2.js";import"./chunk-WIRFNWEU.js";import"./chunk-3NZ6PO4D.js";import"./chunk-YO4OQIFP.js";import"./chunk-32RYPLZK.js";import"./chunk-PJCUSCO4.js";import"./chunk-EEAMZPP6.js";import"./chunk-FB5J7SRP.js";import{a as R}from"./chunk-5RNC6C3X.js";import{a as z}from"./chunk-3HPG2L62.js";import{a as T}from"./chunk-KM4XVL2X.js";import"./chunk-A7ZJQCNU.js";import{a as B}from"./chunk-EV5YPN4F.js";import{a as _}from"./chunk-DYB3RWP7.js";import{a as F}from"./chunk-GFLZSZAF.js";import"./chunk-KSHK3ZPX.js";import{b as y,d as P}from"./chunk-6ID67VGK.js";import"./chunk-Y7WTP3MZ.js";import"./chunk-UPRUP24B.js";import"./chunk-IWLUIA2A.js";import"./chunk-3M333MY5.js";import"./chunk-WVJDCDGZ.js";import{d as k}from"./chunk-MC6FNME3.js";import"./chunk-PWUYHFON.js";import{a as er}from"./chunk-4TJM5BGM.js";import{a as H}from"./chunk-RXK4RLF6.js";import{a as ar}from"./chunk-FBH65XSW.js";import{a as J,b as rr}from"./chunk-VTNGEN34.js";import"./chunk-QW4JPW6J.js";import"./chunk-5B53X4DT.js";import{a as p}from"./chunk-276MJCIE.js";import"./chunk-PJBAQZ6G.js";import"./chunk-CTTXXEWI.js";import{a as G}from"./chunk-OQKQUCGJ.js";import{a as Z}from"./chunk-5MCOAQZT.js";import"./chunk-ERFMX2SZ.js";import"./chunk-XO3JWN33.js";import"./chunk-CFIJKJXD.js";import"./chunk-N6NYXAXH.js";import"./chunk-GEYFQVQI.js";import{a as g,c as v}from"./chunk-3ZWDIEEM.js";import"./chunk-VNSF5IOL.js";import"./chunk-G42IXTZ3.js";import"./chunk-TVZAFTPT.js";import{c as C}from"./chunk-KPHSEIR3.js";import{a as e}from"./chunk-P37U34EQ.js";import{QueryClient as L,QueryClientProvider as q}from"@tanstack/react-query";function l(r){let a=document.documentElement;Object.keys(r).forEach(t=>{let o=r[t];o&&a.style.setProperty(t,o)})}e(l,"setCssProperties");function S(r){let a={};return Object.keys(r).forEach(t=>{a[`--${t}`]=r[t]}),a}e(S,"mapThemeColors");function N(r){return{"--spacing":r}}e(N,"mapThemeSpacing");function O(r){return{"--radius":r}}e(O,"mapThemeBorderRadius");function j(r){return{"--fontSizeBase":r.fontSizeBase}}e(j,"mapThemeFont");function h(r){r?.colors&&l(S(r.colors)),r?.spacing&&l(N(r.spacing)),r?.borderRadius&&l(O(r.borderRadius)),r?.font&&l(j(r.font))}e(h,"applyTheme");import{createContext as D,useEffect as I,useMemo as A}from"react";import{jsx as V}from"react/jsx-runtime";var K=D({theme:{}});function u(r){I(()=>{r.theme&&Object.keys(r.theme).length>0&&h(r.theme)},[r.theme]);let a=A(()=>({theme:r.theme}),[r.theme]);return V(K.Provider,{value:a,children:r.children})}e(u,"ThemeProvider");var m={partners:"https://gateway.partners.remote-sandbox.com",production:"https://gateway.remote.com",sandbox:"https://gateway.remote-sandbox.com",staging:"https://gateway.niceremote.com"};import{createClient as U}from"@hey-api/client-fetch";import{useQuery as W}from"@tanstack/react-query";import{useRef as w}from"react";function M(r){try{return new URL(r),!0}catch{return!1}}e(M,"isValidUrl");var f=e(({auth:r,options:a})=>{let t=w(null),{refetch:o}=W({queryKey:["auth"],queryFn:r,enabled:!1}),c=a?.environment?m[a?.environment]:"https://gateway.remote.com",s=p.getConfig(),x="0.4.0-alpha.24",d=!!a?.proxy&&M(a.proxy.url);return a?.proxy&&!d&&console.error("Invalid proxy URL provided. Using default base URL."),w(U({...s,headers:{...s.headers,...d?a?.proxy?.headers:{},"X-Client-Name":"remote-flows-sdk","X-Client-Version":x},baseUrl:d?a.proxy?.url:c,auth:e(async()=>{function b(i){return!i||Date.now()+6e4>i}if(e(b,"hasTokenExpired"),!t.current||b(t.current.expiresAt)){let{data:i}=await o();i&&(t.current={accessToken:i.accessToken,expiresAt:Date.now()+i.expiresIn*1e3})}return t.current?.accessToken},"auth")}))},"useAuth");import{jsx as n}from"react/jsx-runtime";var Q=new L;function X({children:r,auth:a,proxy:t,environment:o}){let c=f({auth:a,options:{proxy:t,environment:o}});return n(v.Provider,{value:{client:c.current},children:r})}e(X,"RemoteFlowContextWrapper");function Y({children:r,components:a}){return n(g.Provider,{value:a?{components:a}:{components:{}},children:r})}e(Y,"FormFieldsProvider");function $({auth:r,children:a,components:t,theme:o,proxy:c,environment:s}){return n(q,{client:Q,children:n(Y,{components:t,children:n(X,{auth:r,proxy:c,environment:s,children:n(u,{theme:o,children:a})})})})}e($,"RemoteFlows");export{G as ContractAmendmentConfirmationForm,er as ContractAmendmentFlow,Z as ContractAmendmentForm,H as ContractAmendmentSubmit,B as CostCalculatorDisclaimer,F as CostCalculatorFlow,R as CostCalculatorForm,z as CostCalculatorResetButton,E as CostCalculatorResults,T as CostCalculatorSubmitButton,or as OnboardingFlow,$ as RemoteFlows,tr as TerminationFlow,y as buildCostCalculatorEstimationPayload,_ as disclaimerData,C as transformYupErrorsIntoObject,ar as useContractAmendment,P as useCostCalculator,k as useCostCalculatorEstimationPdf,J as useEmploymentQuery,rr as useTimeOffQuery};
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { PropsWithChildren, ReactNode } from 'react';
|
|
2
2
|
import { ControllerRenderProps, FieldValues, ControllerFieldState } from 'react-hook-form';
|
|
3
3
|
import { AnySchema } from 'yup';
|
|
4
|
-
import { S as SupportedTypes } from './types-
|
|
4
|
+
import { S as SupportedTypes } from './types-Zg1n_9wh.js';
|
|
5
5
|
|
|
6
6
|
type ThemeProviderProps = PropsWithChildren<{
|
|
7
7
|
theme?: Partial<{
|
|
@@ -42,6 +42,12 @@ type AuthResponse = {
|
|
|
42
42
|
accessToken: string;
|
|
43
43
|
expiresIn: number;
|
|
44
44
|
};
|
|
45
|
+
type JSFFieldset = {
|
|
46
|
+
[x: string]: {
|
|
47
|
+
propertiesByName: string[];
|
|
48
|
+
title: string;
|
|
49
|
+
};
|
|
50
|
+
};
|
|
45
51
|
type JSFField = {
|
|
46
52
|
computedAttributes: Record<string, unknown>;
|
|
47
53
|
description: ReactNode;
|
|
@@ -146,4 +152,4 @@ type RemoteFlowsSDKProps = Omit<ThemeProviderProps, 'children'> & {
|
|
|
146
152
|
};
|
|
147
153
|
type $TSFixMe = any;
|
|
148
154
|
|
|
149
|
-
export type { $TSFixMe as $, ButtonComponentProps as B, Components as C, FieldComponentProps as F,
|
|
155
|
+
export type { $TSFixMe as $, ButtonComponentProps as B, Components as C, FieldComponentProps as F, JSFFieldset as J, RemoteFlowsSDKProps as R, StatementComponentProps as S, JSFField as a };
|
|
@@ -984,6 +984,16 @@ type ParameterError = {
|
|
|
984
984
|
param: string;
|
|
985
985
|
};
|
|
986
986
|
type GenericFile = Blob | File;
|
|
987
|
+
type CreateContractEligibilityParams = {
|
|
988
|
+
/**
|
|
989
|
+
* type of employment eligibility to work in residing country
|
|
990
|
+
*/
|
|
991
|
+
eligible_to_work_in_residing_country: 'citizen' | 'permanent_resident' | 'temporary_resident';
|
|
992
|
+
/**
|
|
993
|
+
* whether the employer or work restrictions apply
|
|
994
|
+
*/
|
|
995
|
+
employer_or_work_restrictions: boolean;
|
|
996
|
+
};
|
|
987
997
|
type TimeoffType = 'time_off' | 'sick_leave' | 'public_holiday' | 'unpaid_leave' | 'extended_leave' | 'in_lieu_time' | 'maternity_leave' | 'paternity_leave' | 'parental_leave' | 'bereavement' | 'military_leave' | 'other' | 'paid_time_off' | 'custom_company_leave' | 'rtt' | 'casual_leave' | 'rol' | 'ex_festivita';
|
|
988
998
|
/**
|
|
989
999
|
* The details of the salary decrease request if there is one
|
|
@@ -1227,6 +1237,21 @@ type PatchUpdateEmployment2Errors = {
|
|
|
1227
1237
|
429: TooManyRequestsResponse;
|
|
1228
1238
|
};
|
|
1229
1239
|
type PatchUpdateEmployment2Error = PatchUpdateEmployment2Errors[keyof PatchUpdateEmployment2Errors];
|
|
1240
|
+
type PostCreateContractEligibilityErrors = {
|
|
1241
|
+
/**
|
|
1242
|
+
* Bad Request
|
|
1243
|
+
*/
|
|
1244
|
+
400: BadRequestResponse;
|
|
1245
|
+
/**
|
|
1246
|
+
* Unprocessable Entity
|
|
1247
|
+
*/
|
|
1248
|
+
422: UnprocessableEntityResponse;
|
|
1249
|
+
/**
|
|
1250
|
+
* Unprocessable Entity
|
|
1251
|
+
*/
|
|
1252
|
+
429: TooManyRequestsResponse;
|
|
1253
|
+
};
|
|
1254
|
+
type PostCreateContractEligibilityError = PostCreateContractEligibilityErrors[keyof PostCreateContractEligibilityErrors];
|
|
1230
1255
|
type PostAutomatableContractAmendmentErrors = {
|
|
1231
1256
|
/**
|
|
1232
1257
|
* Unauthorized
|
|
@@ -1277,4 +1302,4 @@ type PostConvertCurrencyConverterErrors = {
|
|
|
1277
1302
|
};
|
|
1278
1303
|
type PostConvertCurrencyConverterError = PostConvertCurrencyConverterErrors[keyof PostConvertCurrencyConverterErrors];
|
|
1279
1304
|
|
|
1280
|
-
export type {
|
|
1305
|
+
export type { CreateContractEligibilityParams as A, PostCreateOffboardingError as B, ContractAmendmentAutomatableResponse as C, TimeoffStatus as D, EmploymentShowResponse as E, CostCalculatorEmployment as F, Currency as G, ListTimeoffResponse as L, MinimalRegion as M, OffboardingResponse as O, PostAutomatableContractAmendmentError as P, SuccessResponse as S, TerminationDetailsParams as T, UnifiedEmploymentUpsertBenefitOffersRequest as U, ContractAmendmentResponse as a, PostCreateContractAmendmentError as b, CostCalculatorEstimateResponse as c, CostCalculatorEstimatePdfResponse as d, PostCreateEstimationPdfError as e, CostCalculatorEstimateParams as f, PostCreateEstimationError as g, EmploymentTermType as h, Employment as i, Company as j, PostInviteEmploymentInvitationError as k, PostCreateRiskReserveError as l, EmploymentCreationResponse as m, PostCreateEmployment2Error as n, EmploymentCreateParams as o, EmploymentResponse as p, PatchUpdateEmployment2Error as q, EmploymentFullParams as r, PutUpdateBenefitOfferError as s, MagicLinkResponse as t, UnprocessableEntityResponse as u, MagicLinkParams as v, ConvertCurrencyResponse as w, PostConvertCurrencyConverterError as x, ConvertCurrencyParams as y, PostCreateContractEligibilityError as z };
|
package/package.json
CHANGED
package/dist/chunk-3BIRQAED.js
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a as $e}from"./chunk-XO3JWN33.js";import{a as A}from"./chunk-N6NYXAXH.js";import{a as ge,b as B}from"./chunk-GEYFQVQI.js";import{b as x}from"./chunk-3ZWDIEEM.js";import{a as Me,b as C,c as R,d as S,e as N,f as w,g as T}from"./chunk-VNSF5IOL.js";import{a as m}from"./chunk-KPHSEIR3.js";import{a as o}from"./chunk-P37U34EQ.js";import{Fragment as zo}from"react";import*as He from"react";import*as ee from"@radix-ui/react-checkbox";import{Check as Dt}from"lucide-react";import{jsx as ve}from"react/jsx-runtime";var te=He.forwardRef(({className:e,...t},r)=>ve(ee.Root,{ref:r,className:m("peer h-4 w-4 shrink-0 rounded-sm border border-input ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-checkbox data-[state=checked]:text-primary",e),...t,children:ve(ee.Indicator,{className:m("flex items-center justify-center text-current"),children:ve(Dt,{className:"h-4 w-4"})})}));te.displayName=ee.Root.displayName;import{useFormContext as Tt}from"react-hook-form";import{Fragment as It,jsx as z,jsxs as oe}from"react/jsx-runtime";function re({name:e,defaultValue:t,description:r,label:a,onChange:i,multiple:d,options:p,component:g,...v}){let{components:n}=x(),{control:c}=Tt(),u=o((s,l,h)=>{let f=h.value?[...h.value]:[];l?f.includes(s)||h.onChange([...f,s]):h.onChange(f.filter(_=>_!==s))},"handleCheckboxChange");return z(C,{control:c,name:e,defaultValue:t,render:({field:s,fieldState:l})=>{let h=g||n?.checkbox;if(h){let f={name:e,description:r,label:a,defaultValue:t,multiple:d,options:p,...v};return z(h,{field:{...s,onChange:o(_=>{if(d){let{checked:k,value:b}=_.target;u(b,k,s),i?.(k);return}s.onChange(_),i?.(_)},"onChange")},fieldState:l,fieldData:f})}return oe(R,{"data-field":e,className:m(`RemoteFlows__CheckBoxField__Item__${e}`),children:[z(N,{children:oe(It,{children:[p&&d?z(S,{children:a}):null,p&&d?p.map(f=>oe("div",{className:"flex space-x-2",children:[z(te,{id:f.value,onCheckedChange:_=>{u(f.value,_===!0,s),i?.(_,f.value)},checked:s.value?.includes(f.value),className:"RemoteFlows__CheckBox__Input"}),z(S,{htmlFor:f.value,className:"mb-0 RemoteFlows__CheckBox__Label",children:f.label})]},f.value)):oe("div",{className:"flex space-x-2",children:[z(te,{id:e,onCheckedChange:f=>{s.onChange(f),i?.(f)},checked:s.value,className:"RemoteFlows__CheckBox__Input"}),z(S,{htmlFor:e,className:"mb-0 RemoteFlows__CheckBox__Label",children:a})]})]})}),r&&z(w,{children:r}),l.error&&z(T,{})]})}})}o(re,"CheckBoxField");import{CalendarIcon as $t}from"lucide-react";import{useFormContext as Ht}from"react-hook-form";import{ChevronLeft as Wt,ChevronRight as Lt}from"lucide-react";import{DayPicker as Mt}from"react-day-picker";import{jsx as Fe}from"react/jsx-runtime";function Ee({className:e,classNames:t,showOutsideDays:r=!0,...a}){return Fe(Mt,{showOutsideDays:r,className:m("p-3",e),classNames:{months:"flex flex-col sm:flex-row gap-2",month:"flex flex-col gap-4",caption:"flex justify-center pt-1 relative items-center w-full",caption_label:"text-sm font-medium",nav:"flex items-center gap-1",nav_button:m(ge({variant:"outline"}),"size-7 bg-transparent p-0 opacity-50 hover:opacity-100"),nav_button_previous:"absolute left-1",nav_button_next:"absolute right-1",table:"w-full border-collapse space-x-1",head_row:"flex",head_cell:"text-muted-foreground rounded-md w-8 font-normal text-[0.8rem]",row:"flex w-full mt-2",cell:m("relative p-0 text-center text-sm focus-within:relative focus-within:z-20 [&:has([aria-selected])]:bg-accent [&:has([aria-selected].day-range-end)]:rounded-r-md",a.mode==="range"?"[&:has(>.day-range-end)]:rounded-r-md [&:has(>.day-range-start)]:rounded-l-md first:[&:has([aria-selected])]:rounded-l-md last:[&:has([aria-selected])]:rounded-r-md":"[&:has([aria-selected])]:rounded-md"),day:m(ge({variant:"ghost"}),"size-8 p-0 font-normal aria-selected:opacity-100"),day_range_start:"day-range-start aria-selected:bg-primary aria-selected:text-primary-foreground",day_range_end:"day-range-end aria-selected:bg-primary aria-selected:text-primary-foreground",day_selected:"bg-primary text-primary-foreground hover:bg-primary hover:text-primary-foreground focus:bg-primary focus:text-primary-foreground",day_today:"bg-accent text-accent-foreground",day_outside:"day-outside text-muted-foreground aria-selected:text-muted-foreground",day_disabled:"text-muted-foreground opacity-50",day_range_middle:"aria-selected:bg-accent aria-selected:text-accent-foreground",day_hidden:"invisible",...t},components:{IconLeft:o(({className:i,...d})=>Fe(Wt,{className:m("size-4",i),...d}),"IconLeft"),IconRight:o(({className:i,...d})=>Fe(Lt,{className:m("size-4",i),...d}),"IconRight")},...a})}o(Ee,"Calendar");import*as O from"@radix-ui/react-popover";import{jsx as ae}from"react/jsx-runtime";function ne({...e}){return ae(O.Root,{"data-slot":"popover",...e})}o(ne,"Popover");function ie({...e}){return ae(O.Trigger,{"data-slot":"popover-trigger",...e})}o(ie,"PopoverTrigger");function se({className:e,align:t="center",sideOffset:r=4,...a}){return ae(O.Portal,{children:ae(O.Content,{"data-slot":"popover-content",align:t,sideOffset:r,className:m("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 w-72 origin-(--radix-popover-content-transform-origin) rounded-md border p-4 shadow-md outline-hidden",e),...a})})}o(se,"PopoverContent");import{PopoverClose as Et}from"@radix-ui/react-popover";import{format as Be}from"date-fns";import{Fragment as Bt,jsx as W,jsxs as he}from"react/jsx-runtime";function Ae({description:e,label:t,name:r,minDate:a,onChange:i,component:d,...p}){let{components:g}=x(),{control:v}=Ht();return W(C,{control:v,name:r,render:({field:n,fieldState:c})=>{let u=d||g?.date;if(u){let s={description:e,label:t,name:r,minDate:a,onChange:i,...p};return W(u,{field:{...n,onChange:o(l=>{n.onChange(l),i?.(l)},"onChange")},fieldState:c,fieldData:s})}return he(R,{"data-field":r,className:`flex flex-col RemoteFlows__DatePickerField__Item__${r}`,children:[W(S,{className:"RemoteFlows__DatePickerField__Label",children:t}),he(ne,{children:[W(ie,{asChild:!0,children:W(N,{children:W("div",{children:he(B,{type:"button",variant:"outline",className:m("w-full pl-3 text-left font-normal",!n.value&&"text-muted-foreground"),"data-testid":`date-picker-button-${r}`,children:[n.value&&W(Bt,{children:Be(n.value,"yyyy-MM-dd")}),W($t,{className:"ml-auto h-4 w-4 opacity-50"})]})})})}),W(se,{className:"w-auto p-0 RemoteFlows__DatepickerField__PopoverContent",align:"start",children:W(Ee,{mode:"single",className:"RemoteFlows__DatepickerField__Calendar",selected:n.value?new Date(n.value):void 0,onSelect:s=>{n.onChange(s?Be(s,"yyyy-MM-dd"):null),i?.(s)},defaultMonth:a?new Date(a):void 0,components:{DayContent:o(s=>W(Et,{children:s.date.getDate()}),"DayContent")},...a&&{disabled:o(s=>s<new Date(a),"disabled")}})})]}),e?W(w,{children:e}):null,c.error&&W(T,{className:"RemoteFlows__DatePickerField__Error"})]})}})}o(Ae,"DatePickerField");import{cva as At}from"class-variance-authority";import{jsx as ye}from"react/jsx-runtime";var zt=At("relative w-full rounded-lg border px-4 py-3 text-sm grid has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] grid-cols-[0_1fr] has-[>svg]:gap-x-3 gap-y-0.5 items-start [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",{variants:{variant:{default:"bg-card text-card-foreground",destructive:"text-destructive bg-card [&>svg]:text-current *:data-[slot=alert-description]:text-destructive/90",warning:"bg-card bg-warning border-warning-border [&>svg]:text-current"}},defaultVariants:{variant:"default"}});function ze({className:e,variant:t,...r}){return ye("div",{"data-slot":"alert",role:"alert",className:m(zt({variant:t}),e),...r})}o(ze,"Alert");function Oe({className:e,...t}){return ye("div",{"data-slot":"alert-title",className:m("col-start-2 line-clamp-1 min-h-4 font-medium tracking-tight",e),...t})}o(Oe,"AlertTitle");function Ge({className:e,...t}){return ye("div",{"data-slot":"alert-description",className:m("text-muted-foreground col-start-2 grid justify-items-start gap-1 text-sm [&_p]:leading-relaxed",e),...t})}o(Ge,"AlertDescription");import{AlertCircle as Ot}from"lucide-react";import{jsx as le,jsxs as Gt}from"react/jsx-runtime";function me({title:e,description:t,severity:r}){let{components:a}=x();if(a?.statement){let i=a?.statement;return le(i,{data:{title:e,description:t,severity:r}})}return Gt(ze,{variant:"warning",children:[le(Ot,{className:"h-4 w-4"}),e&&le(Oe,{children:e}),le(Ge,{children:t})]})}o(me,"Statement");import{jsx as _e,jsxs as Ve}from"react/jsx-runtime";import{createElement as Vt}from"react";function Ue({label:e,name:t,fields:r,description:a,components:i,statement:d}){return Ve("fieldset",{className:m("border-1 border-input p-4 rounded-xl",`RemoteFlows__FieldSetField__${t}`),children:[_e("legend",{className:"text-sm font-semibold px-2",children:e}),a?_e("div",{className:"mb-5 RemoteFlows__FieldSetField__Description",dangerouslySetInnerHTML:{__html:a}}):null,Ve("div",{className:"grid gap-4",children:[r.map(p=>{let g=ce[p.type];return p.isVisible===!1||p.deprecated?null:Vt(g,{...p,key:p.name,name:`${t}.${p.name}`,component:i?.[p.type]})}),d?_e(me,{...d}):null]})]})}o(Ue,"FieldSetField");import{useFormContext as Yt}from"react-hook-form";import{useState as Ut,useRef as Jt}from"react";import{Upload as qt,X as Kt}from"lucide-react";import{jsx as V,jsxs as xe}from"react/jsx-runtime";function Je({onChange:e,className:t,multiple:r}){let[a,i]=Ut([]),d=Jt(null),p=o(n=>{n.preventDefault(),d.current?.click()},"handleClick"),g=o(n=>{if(n.target.files&&n.target.files.length>0){let c=Array.from(n.target.files);i(c),e(n)}},"handleChange"),v=o(n=>{i(c=>c.filter(u=>u!==n))},"onRemoveFile");return xe("div",{className:m("flex flex-col items-start gap-4",t),children:[V("input",{type:"file",ref:d,onChange:g,className:"hidden","aria-label":"File upload",multiple:r}),xe(B,{type:"button",onClick:p,className:"gap-2",children:[V(qt,{className:"h-4 w-4"}),"Choose File"]}),a.length===0&&V("div",{className:"text-sm",children:r?V("span",{className:"font-medium",children:"No files selected. You can select multiple files"}):V("span",{className:"font-medium",children:"No file selected."})}),a.length>0&&a.map((n,c)=>xe("div",{className:"text-sm flex items-center gap-2",children:["Selected file: ",V("span",{className:"font-medium",children:n.name})," (",Math.round(n.size/1024)," KB)",V(B,{variant:"ghost",onClick:()=>v(n),children:V(Kt,{})})]},c))]})}o(Je,"FileUploader");import{jsx as U,jsxs as Qt}from"react/jsx-runtime";var Xt=o(e=>new Promise((t,r)=>{let a=new FileReader;a.readAsDataURL(e),a.onload=()=>t(a.result),a.onerror=i=>r(i)}),"toBase64"),qe=o(async e=>{let t=e.target.files?Array.from(e.target.files):[];return await Promise.all(t.map(async a=>{let i=await Xt(a);return{name:a.name,content:i.split(",")[1]}}))},"convertFilesToBase64");function Ke({name:e,description:t,label:r,multiple:a,onChange:i,component:d,...p}){let{components:g}=x(),{control:v}=Yt();return U(C,{control:v,name:e,render:({field:n,fieldState:c})=>{let u=d||g?.file;if(u){let s={name:e,description:t,label:r,multiple:a,...p};return U(u,{field:{...n,value:null,onChange:o(async l=>{let h=await qe(l);n.onChange(h),i?.(h)},"onChange")},fieldState:c,fieldData:s})}return Qt(R,{"data-field":e,className:`RemoteFlows__FileUpload__Item__${e}`,children:[U(S,{className:"RemoteFlows__FileUpload__Label",children:r}),U(N,{children:U(Je,{onChange:async s=>{let l=await qe(s);n.onChange(l),i?.(l)},multiple:a,className:m("RemoteFlows__FileUpload__Input")})}),t&&U("div",{className:"flex items-center justify-between",children:U(w,{className:"RemoteFlows__FileUpload__Description",children:t})}),c.error&&U(T,{className:"RemoteFlows__FileUpload__Error"})]})}})}o(Ke,"FileUploadField");import{useFormContext as Zt}from"react-hook-form";import{jsx as Ce}from"react/jsx-runtime";function be(e){let{components:t}=x(),{control:r}=Zt(),a=e.component||t?.number;return a?Ce(C,{control:r,name:e.name,render:({field:i,fieldState:d})=>Ce(a,{field:{...i,onChange:o(p=>{i.onChange(p),e.onChange?.(p)},"onChange")},fieldState:d,fieldData:e})}):Ce(A,{...e,type:"text",inputMode:"decimal",pattern:"^[0-9.]*$"})}o(be,"NumberField");import*as K from"@radix-ui/react-radio-group";import{CircleIcon as jt}from"lucide-react";import{jsx as de}from"react/jsx-runtime";function Ye({className:e,...t}){return de(K.Root,{"data-slot":"radio-group",className:m("grid gap-3",e),...t})}o(Ye,"RadioGroup");function Xe({className:e,...t}){return de(K.Item,{"data-slot":"radio-group-item",className:m("border-input text-primary focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive aspect-square size-4 shrink-0 rounded-full border shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50",e),...t,children:de(K.Indicator,{"data-slot":"radio-group-indicator",className:"relative flex items-center justify-center",children:de(jt,{className:"fill-radio absolute top-1/2 left-1/2 size-2 -translate-x-1/2 -translate-y-1/2"})})})}o(Xe,"RadioGroupItem");import{useFormContext as eo}from"react-hook-form";import{Fragment as to,jsx as $,jsxs as Se}from"react/jsx-runtime";function Qe({name:e,defaultValue:t,description:r,label:a,options:i,onChange:d,component:p,...g}){let{components:v}=x(),{control:n}=eo();return $(C,{control:n,name:e,defaultValue:t,render:({field:c,fieldState:u})=>{let s=p||v?.radio;if(s){let l={name:e,defaultValue:t,description:r,label:a,options:i,...g};return $(s,{field:{...c,onChange:o(h=>{c.onChange(h),d?.(h)},"onChange")},fieldState:u,fieldData:l})}return Se(R,{className:m("space-y-3",`RemoteFlows__RadioGroupField__Item__${e}`),"data-field":e,children:[$(S,{children:a}),$(N,{children:$(Ye,{"aria-label":a||e,onValueChange:l=>{c.onChange(l),d?.(l)},value:c.value,className:"flex flex-col space-y-3",children:i?.map(l=>$(to,{children:Se(R,{"data-field":e,className:"flex items-start space-x-3 space-y-0 gap-0 RemoteFlows__RadioField__Item",children:[$(N,{children:$(Xe,{value:l.value,className:"RemoteFlows__RadioField__Input"})}),Se("div",{children:[$(S,{className:"font-normal mb-0 RemoteFlows__RadioField__Label",children:l.label}),l.description&&$(w,{className:"mt-2",children:l.description})]})]},l.value)}))})}),r&&$(w,{children:r}),u.error&&$(T,{})]})}})}o(Qe,"RadioGroupField");import*as y from"@radix-ui/react-select";import{CheckIcon as oo,ChevronDownIcon as Ze,ChevronUpIcon as ro}from"lucide-react";import{jsx as P,jsxs as Pe}from"react/jsx-runtime";function je({...e}){return P(y.Root,{"data-slot":"select",...e})}o(je,"Select");function et({...e}){return P(y.Group,{"data-slot":"select-group",...e})}o(et,"SelectGroup");function tt({...e}){return P(y.Value,{"data-slot":"select-value",...e})}o(tt,"SelectValue");function ot({className:e,children:t,...r}){return Pe(y.Trigger,{"data-slot":"select-trigger",className:m("border-input data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive flex w-full items-center justify-between rounded-xl border bg-transparent px-4 py-7 text-sm whitespace-nowrap transition-[color] outline-none disabled:cursor-not-allowed disabled:opacity-50 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4","focus-visible:border-focused",e),...r,children:[t,P(y.Icon,{asChild:!0,className:"absolute right-4",children:P(Ze,{className:"size-4"})})]})}o(ot,"SelectTrigger");function rt({className:e,children:t,position:r="popper",...a}){return P(y.Portal,{children:Pe(y.Content,{"data-slot":"select-content",className:m("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-xl border",r==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",e),position:r,...a,children:[P(ao,{}),P(y.Viewport,{className:m(r==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1"),children:t}),P(no,{})]})})}o(rt,"SelectContent");function at({className:e,children:t,...r}){return Pe(y.Item,{"data-slot":"select-item",className:m("focus:bg-accent focus:text-accent-foreground min-h-11 justify-between [&_svg:not([class*='text-'])]:text-muted-foreground flex w-full cursor-default items-center gap-2 py-2 px-4 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",e),...r,children:[P(y.ItemText,{children:t}),P("span",{className:"flex size-3.5 items-center justify-center",children:P(y.ItemIndicator,{children:P(oo,{className:"size-4"})})})]})}o(at,"SelectItem");function ao({className:e,...t}){return P(y.ScrollUpButton,{"data-slot":"select-scroll-up-button",className:m("flex cursor-default items-center justify-center py-1",e),...t,children:P(ro,{className:"size-4"})})}o(ao,"SelectScrollUpButton");function no({className:e,...t}){return P(y.ScrollDownButton,{"data-slot":"select-scroll-down-button",className:m("flex cursor-default items-center justify-center py-1",e),...t,children:P(Ze,{className:"size-4"})})}o(no,"SelectScrollDownButton");import{useFormContext as io}from"react-hook-form";import{jsx as L,jsxs as nt}from"react/jsx-runtime";function it({label:e,name:t,options:r,defaultValue:a,description:i,onChange:d,component:p,...g}){let{control:v}=io(),{components:n}=x();return L(C,{defaultValue:a,control:v,name:t,render:({field:c,fieldState:u})=>{let s=p||n?.select;if(s){let l={label:e,name:t,options:r,defaultValue:a,description:i,onChange:d,...g};return L(s,{field:{...c,onChange:o(h=>{c.onChange(h),d?.(h)},"onChange")},fieldState:u,fieldData:l})}return nt(R,{"data-field":t,className:`RemoteFlows__SelectField__Item__${t}`,children:[L(S,{className:"RemoteFlows__SelectField__Label",children:e}),L(N,{children:L("div",{className:"relative",children:nt(je,{value:c.value||"",onValueChange:l=>{c.onChange(l),d?.(l)},children:[L(ot,{className:"RemoteFlows__SelectField__Trigger","aria-invalid":!!u.error,"aria-label":e,children:L("span",{className:"absolute",children:L(tt,{placeholder:e})})}),L(rt,{className:"RemoteFlows__SelectField__Content",children:L(et,{className:"RemoteFlows__SelectField__Group",children:r.map(l=>L(at,{value:l.value,className:"RemoteFlows__SelectField__SelectItem",children:l.label},l.value))})})]})})}),i&&L(w,{children:i}),u.error&&L(T,{})]})}})}o(it,"SelectField");import{useState as vo}from"react";import{useFormContext as Fo}from"react-hook-form";import{Fragment as co,useState as po}from"react";import{Check as uo,ChevronDownIcon as fo,X as go}from"lucide-react";import{Command as Y}from"cmdk";import{SearchIcon as Xa}from"lucide-react";import*as D from"@radix-ui/react-dialog";import{XIcon as so}from"lucide-react";import{jsx as G,jsxs as ke}from"react/jsx-runtime";function Re({...e}){return G(D.Root,{"data-slot":"dialog",...e})}o(Re,"Dialog");function st({...e}){return G(D.Trigger,{"data-slot":"dialog-trigger",...e})}o(st,"DialogTrigger");function lo({...e}){return G(D.Portal,{"data-slot":"dialog-portal",...e})}o(lo,"DialogPortal");function mo({className:e,...t}){return G(D.Overlay,{"data-slot":"dialog-overlay",className:m("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",e),...t})}o(mo,"DialogOverlay");function Ne({className:e,children:t,...r}){return ke(lo,{"data-slot":"dialog-portal",children:[G(mo,{}),ke(D.Content,{"data-slot":"dialog-content",className:m("bg-background data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border p-6 shadow-lg duration-200 sm:max-w-lg",e),...r,children:[t,ke(D.Close,{className:"ring-offset-background focus:ring-ring data-[state=open]:bg-accent data-[state=open]:text-muted-foreground absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 RemoteFlows__Dialog__Close",children:[G(so,{}),G("span",{className:"sr-only",children:"Close"})]})]})]})}o(Ne,"DialogContent");function we({className:e,...t}){return G("div",{"data-slot":"dialog-header",className:m("flex flex-col gap-2 text-center sm:text-left",e),...t})}o(we,"DialogHeader");function De({className:e,...t}){return G(D.Title,{"data-slot":"dialog-title",className:m("text-lg leading-none font-semibold",e),...t})}o(De,"DialogTitle");import{jsx as X,jsxs as en}from"react/jsx-runtime";function lt({className:e,...t}){return X(Y,{"data-slot":"command",className:m("bg-popover text-popover-foreground flex h-full w-full flex-col overflow-hidden rounded-md",e),...t})}o(lt,"Command");function mt({className:e,...t}){return X(Y.List,{"data-slot":"command-list",className:m("max-h-[300px] scroll-py-1 overflow-x-hidden overflow-y-auto",e),...t})}o(mt,"CommandList");function ct({...e}){return X(Y.Empty,{"data-slot":"command-empty",className:"py-6 text-center text-sm",...e})}o(ct,"CommandEmpty");function dt({className:e,...t}){return X(Y.Group,{"data-slot":"command-group",className:m("text-foreground [&_[cmdk-group-heading]]:text-muted-foreground overflow-hidden p-1 [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium",e),...t})}o(dt,"CommandGroup");function pt({className:e,...t}){return X(Y.Separator,{"data-slot":"command-separator",className:m("bg-border -mx-1 h-px",e),...t})}o(pt,"CommandSeparator");function ut({className:e,...t}){return X(Y.Item,{"data-slot":"command-item",className:m("data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),...t})}o(ut,"CommandItem");import{jsx as H,jsxs as Q}from"react/jsx-runtime";function ft({options:e,selected:t,onChange:r,placeholder:a,...i}){let[d,p]=po(!1),g=o(n=>{r(t.filter(c=>c.value!==n.value))},"handleUnselect"),v=e.reduce((n,c)=>{let u=c.category||"Uncategorized";return n[u]||(n[u]=[]),n[u].push(c),n},{});return Q(ne,{open:d,onOpenChange:p,...i,children:[H(ie,{children:Q(B,{variant:"outline",role:"combobox","aria-expanded":d,className:"w-full justify-between font-normal",type:"button",children:[H("div",{className:"flex gap-1 flex-wrap overflow-x-auto max-h-[2.5rem] items-center",children:t.length>0?t.map(n=>Q($e,{variant:"secondary",className:"mr-1 mb-1",children:[n.label,H("div",{role:"button",tabIndex:0,"aria-label":`remove ${n.label}`,className:"ml-1 ring-offset-background rounded-full outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 cursor-pointer",onKeyDown:c=>{c.key==="Enter"&&g(n)},onMouseDown:c=>{c.preventDefault(),c.stopPropagation()},onClick:()=>g(n),children:H(go,{className:"h-3 w-3 text-muted-foreground hover:text-foreground"})})]},n.label)):H("span",{className:"text-foreground",children:a})}),H(fo,{className:"size-4"})]})}),H(se,{align:"start",className:"w-full p-0",children:H(lt,{children:Q(mt,{children:[H(ct,{children:"No item found."}),Object.entries(v).map(([n,c],u)=>Q(co,{children:[u>0&&H(pt,{}),H(dt,{heading:n,children:c.map(s=>{let l=t.some(h=>h.value===s.value);return Q(ut,{onSelect:()=>{r(l?t.filter(h=>h.value!==s.value):[...t,s])},children:[H(uo,{className:m("mr-2 h-4 w-4",l?"opacity-100":"opacity-0")}),s.label]},s.label)})})]},n))]})})})]})}o(ft,"MultiSelect");import{jsx as J,jsxs as ho}from"react/jsx-runtime";function gt({label:e,name:t,options:r,defaultValue:a,description:i,onChange:d,$meta:p,component:g,...v}){let{control:n}=Fo(),{components:c}=x(),[u,s]=vo([]);return J(C,{defaultValue:a,control:n,name:t,render:({field:l,fieldState:h})=>{let f=g||c?.countries;if(f){let b={label:e,name:t,options:r,defaultValue:a,description:i,onChange:d,$meta:p,...v};return J(f,{field:{...l,onChange:o(M=>{l.onChange(M),d?.(M)},"onChange")},fieldState:h,fieldData:b})}let _=[...Object.entries(p?.regions||{}).map(([b,M])=>({value:M,label:b,category:"Regions"})),...Object.entries(p?.subregions||{}).map(([b,M])=>({value:M,label:b,category:"Subregions"})),...r.map(b=>({...b,value:b.value,label:b.label,category:"Countries"}))],k=o(b=>{let M=b.map(({value:wt})=>wt);l.onChange(M),d?.(M),s(b)},"handleChange");return ho(R,{"data-field":t,className:`RemoteFlows__CountryField__Item__${t}`,children:[J(S,{className:"RemoteFlows__CountryField__Label",children:e}),J(N,{children:J(ft,{options:_,selected:u,onChange:k,...v})}),i&&J(w,{children:i}),h.error&&J(T,{})]})}})}o(gt,"CountryField");import{useFormContext as _o}from"react-hook-form";import*as vt from"react";import{jsx as yo}from"react/jsx-runtime";var Te=vt.forwardRef(({className:e,...t},r)=>yo("textarea",{className:m("flex min-h-[80px] w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:r,...t}));Te.displayName="Textarea";import{jsx as q,jsxs as Ie}from"react/jsx-runtime";function Ft({name:e,description:t,label:r,onChange:a,maxLength:i,component:d,...p}){let{components:g}=x(),{control:v}=_o();return q(C,{control:v,name:e,render:({field:n,fieldState:c})=>{let u=d||g?.textarea;if(u){let l={name:e,description:t,label:r,maxLength:i,...p};return q(u,{field:{...n,onChange:o(h=>{n.onChange(h),a?.(h)},"onChange")},fieldState:c,fieldData:l})}let s=n.value?.length??0;return Ie(R,{"data-field":e,className:`RemoteFlows__TextArea__Item__${e}`,children:[q(S,{className:"RemoteFlows__TextArea__Label",children:r}),q(N,{children:q(Te,{...n,value:n.value??"",onChange:l=>{n.onChange(l),a?.(l)},className:m(c.error&&"border-red-500 focus-visible:ring-red-500","RemoteFlows__TextArea__Input"),placeholder:r})}),(t||i)&&Ie("div",{className:"flex items-center justify-between",children:[t&&q(w,{className:"RemoteFlows__TextArea__Description",children:t}),i&&Ie("span",{className:"text-sm ml-auto RemoteFlows__TextArea__MaxLength",children:[s,"/",i]})]}),c.error&&q(T,{className:"RemoteFlows__TextArea__Error"})]})}})}o(Ft,"TextAreaField");import{useFormContext as xo}from"react-hook-form";import{jsx as We}from"react/jsx-runtime";function ht(e){let{components:t}=x(),{control:r}=xo(),a=e.component||t?.email;return a?We(C,{control:r,name:e.name,render:({field:i,fieldState:d})=>We(a,{field:{...i,onChange:o(p=>{i.onChange(p),e.onChange?.(p)},"onChange")},fieldState:d,fieldData:e})}):We(A,{...e,type:"email"})}o(ht,"EmailField");import{useFormContext as Co}from"react-hook-form";import{jsx as yt}from"react/jsx-runtime";function _t(e){let{control:t}=Co();return yt(C,{control:t,name:e.name,render:({field:r})=>yt("input",{...r,type:"hidden"})})}o(_t,"HiddenField");import No,{useEffect as wo,useState as Pt}from"react";import{yupResolver as Do}from"@hookform/resolvers/yup";import{useForm as To,useFormContext as Io,useFieldArray as Wo}from"react-hook-form";import*as I from"yup";import xt from"lodash.groupby";import Z from"lodash.capitalize";var Ct=60,pe=["monday","tuesday","wednesday","thursday","friday","saturday","sunday"];function bo(e){if(e<60)return`${e}m`;let t=Math.floor(e/Ct),r=e%Ct;return r>0?`${t}h${r}m`:`${t}h`}o(bo,"convertBreakDurationToHours");function bt(e){let t=e.reduce((r,a)=>a.hours+r,0);return Number(t.toFixed(2))}o(bt,"calculateTotalWorkHours");function So(e,t){let r=t.map(({day:d})=>d.toLowerCase()),a=r.indexOf(e),i=null;for(;a<r.length&&!i;){let d=r[a],p=r[a+1],g=pe.indexOf(d)+1;pe[g]===p||(i=d),a+=1}return i}o(So,"findLastConsecutiveDay");function Po(e){return e.start_time&&e.end_time&&(typeof e.hours=="number"?e.hours:Number.parseInt(e.hours))>0}o(Po,"shouldSummarizeSchedule");function ko(e){return Number.parseInt(e.break_duration_minutes)>0}o(ko,"shouldSummarizeBreaks");function St(e){let t=e.filter(Po),r=xt(t,g=>`${g.start_time}|${g.end_time}`),a=e.filter(ko),i=xt(a,"break_duration_minutes"),d=Object.keys(r).map(g=>{let v=r[g],n=v[0].day,[c,u]=g.split("|"),s=`from <span>${c.replace(":","h")}</span> to <span>${u.replace(":","h")}</span>`,l=So(n,v),f=(l?v.findIndex(_=>_.day===l):-1)===v.length-1;return v.length===1?`${Z(n)}, ${s}`:!f||!l?v.reduce((_,k,b)=>{let M=Z(k.day);return b===v.length-1?`${_}and ${M}, ${s}`:`${_}<span>${M}</span>, `},""):`<span>${Z(n)}</span> to <span>${Z(l)}</span>, ${s}`}),p=Object.keys(i).reverse().map((g,v)=>{let n=v===0,c=i[g],u=bo(parseInt(g,10));if(Object.keys(i).length===1)return`With ${u} daily breaks`;if(c.length===1){let s=`${u} break on ${Z(c[0].day)}.`;return n?`With ${s}`:s}return c.reduce((s,l,h)=>{let f=Z(l.day);return h===0?`${s} ${f}`:h===c.length-1?`${s}, and ${f}.`:`${s}, ${f}`},n?`With ${u} break on`:`${u} break on`)});return{workHoursSummary:d,breakSummary:p}}o(St,"buildWorkScheduleSummary");function Le(e){let{checked:t,start_time:r,end_time:a,break_duration_minutes:i}=e;if(!t)return 0;let[d,p]=r.split(":").map(Number),[g,v]=a.split(":").map(Number),n=d*60+p,s=(g*60+v-n-Number.parseInt(i||"0"))/60;return s===Math.floor(s)?s:Number(s.toFixed(2))}o(Le,"calculateHours");var Ro={monday:"Mon",tuesday:"Tue",wednesday:"Wed",thursday:"Thu",friday:"Fri",saturday:"Sat",sunday:"Sun"};function ue(e){return Ro[e]}o(ue,"getShortWeekday");import{jsx as F,jsxs as E}from"react/jsx-runtime";var Lo=I.object({day:I.string().required(),checked:I.boolean().required(),start_time:I.string().matches(/^([01]\d|2[0-3]):([0-5]\d)$/,"Invalid time format (HH:mm)").when("checked",{is:!0,then:o(e=>e.required("Required"),"then"),otherwise:o(e=>e.optional().nullable(),"otherwise")}),end_time:I.string().matches(/^([01]\d|2[0-3]):([0-5]\d)$/,"Invalid time format (HH:mm)").when("checked",{is:!0,then:o(e=>e.required("Required"),"then"),otherwise:o(e=>e.optional().nullable(),"otherwise")}),hours:I.number().default(0),break_duration_minutes:I.string().default("0")}),Mo=I.object({schedule:I.array(Lo)});function $o({defaultSchedule:e,onSubmit:t}){let[r,a]=Pt(!1),i=pe.map(f=>{let _=e.find(k=>k.day.toLowerCase()===ue(f).toLowerCase()||k.day.toLowerCase()===f.toLowerCase());return _?{..._,day:ue(f),checked:!0}:{...e[0],checked:!1,day:ue(f)}}),d=To({defaultValues:{schedule:i},resolver:Do(Mo)}),{handleSubmit:p,watch:g,reset:v,control:n,formState:c}=d,{fields:u}=Wo({name:"schedule",control:n}),s=g("schedule");function l(f){let _=f.schedule.filter(({checked:k})=>k).map(k=>({...k,hours:Le(k)}));t(_),a(!1)}o(l,"handleSubmitWorkingHours");function h(){v(),a(!1)}return o(h,"handleCancel"),F("div",{className:"flex items-center justify-between",children:E(Re,{open:r,onOpenChange:a,children:[F(st,{asChild:!0,children:F(B,{variant:"link",className:"flex items-center p-0 RemoteFlows__WorkScheduleSelectionForm__Trigger",children:"Edit Schedule"})}),E(Ne,{className:"max-w-5xl max-h-[90vh] overflow-y-auto px-8 py-4 RemoteFlows__WorkScheduleSelectionForm__Content",children:[F(we,{children:F(De,{className:"RemoteFlows__WorkScheduleSelectionForm__Title",children:"Edit employee working hours"})}),F(Me,{...d,children:E("form",{className:"space-y-4 RemoteFlows__WorkScheduleSelectionForm__Form",children:[E("div",{className:"rounded-lg",children:[F("p",{className:"text-gray-600 text-sm mb-4 RemoteFlows__WorkScheduleSelectionForm__Description",children:"The times displayed are in the employee's time zone in the 24-hour format."}),E("div",{className:"grid grid-cols-12 gap-4 text-sm font-medium text-gray-500 uppercase tracking-wide RemoteFlows__WorkScheduleSelectionForm__Header",children:[F("div",{className:"col-span-2"}),F("div",{className:"col-span-3 text-center",children:"START"}),F("div",{className:"col-span-1 text-center"}),F("div",{className:"col-span-3 text-center",children:"END"}),F("div",{className:"col-span-2 text-center",children:"HOURS"})]}),F("div",{className:"RemoteFlows__WorkScheduleSelectionForm__Rows",children:u.map((f,_)=>{let k=s[_],b=Le(k);return E(No.Fragment,{children:[E("div",{className:"grid grid-cols-12 gap-4 items-center py-2 RemoteFlows__WorkScheduleSelectionForm__Row-Hours",children:[F("div",{className:"col-span-2 flex items-center gap-3",children:F(re,{label:f.day,name:`schedule.${_}.checked`})}),F("div",{className:"col-span-3",children:F(A,{name:`schedule.${_}.start_time`,includeErrorMessage:!1})}),F("div",{className:"col-span-1 text-center text-gray-500",children:"to"}),F("div",{className:"col-span-3",children:F(A,{name:`schedule.${_}.end_time`,includeErrorMessage:!1})}),F("div",{className:"col-span-2 text-center text-gray-600",children:isNaN(b)?"-":`${b} hours`})]}),E("div",{className:"grid grid-cols-12 gap-4 items-center py-2 RemoteFlows__WorkScheduleSelectionForm__Row-Break",children:[F("div",{className:"col-span-2 text-gray-500",children:"Break"}),F("div",{className:"col-span-2",children:F(A,{name:`schedule.${_}.break_duration_minutes`,includeErrorMessage:!1})}),F("div",{className:"col-span-2 text-gray-500",children:"minutes"}),F("div",{className:"col-span-4"})]})]},f.id)})})]}),Object.keys(c.errors).length>0&&F("p",{className:"text-destructive text-sm mb-0",children:"Invalid time format (HH:mm)"}),E("div",{className:"flex gap-4 pt-4",children:[F(B,{type:"button",className:"reset-button",variant:"outline",onClick:h,children:"Cancel"}),F(B,{type:"button",className:"submit-button",onClick:p(l),children:"Save Schedule"})]})]})})]})]})})}o($o,"WorkScheduleSelectionForm");function kt(e){let{components:t}=x(),{setValue:r,control:a,watch:i}=Io(),d=i(e.name),[p,g]=Pt(d),{workHoursSummary:v,breakSummary:n}=St(p),c=bt(p);wo(()=>{r(e.name,p)},[p,e.name,r]);function u(l){g(l)}o(u,"onSubmit");let s=e.component||t?.["work-schedule"];return s?F(C,{control:a,name:e.name,render:({field:l,fieldState:h})=>F(s,{field:{...l,onChange:o(f=>{l.onChange(f),e.onChange?.(f)},"onChange")},fieldState:h,fieldData:{...e,defaultFormattedValue:{workHoursSummary:v,breakSummary:n,totalWorkHours:c}}})}):E("div",{className:"flex flex-col gap-3 RemoteFlows__WorkScheduleField",children:[F("p",{className:"text-sm RemoteFlows__WorkScheduleField__Title",children:"Work hours"}),E("div",{className:"flex flex-col gap-1 RemoteFlows__WorkScheduleField__Summary",children:[F("p",{className:"text-sm text-gray-500 RemoteFlows__WorkScheduleField__Summary__WorkHours",dangerouslySetInnerHTML:{__html:v.join(", ")}}),F("p",{className:"text-sm text-gray-500 RemoteFlows__WorkScheduleField__Summary__Break",children:n.join()}),E("p",{className:"text-sm text-gray-500 RemoteFlows__WorkScheduleField__Summary__Total",children:["Total of ",F("span",{children:c})," hours per week"]}),F($o,{defaultSchedule:p,onSubmit:u})]})]})}o(kt,"WorkScheduleField");var ce={checkbox:re,text:A,email:ht,money:be,select:it,radio:Qe,number:be,file:Ke,fieldset:Ue,date:Ae,textarea:Ft,countries:gt,hidden:_t,"work-schedule":kt};import{useEffect as Ho}from"react";import{useFormContext as Eo}from"react-hook-form";import{Fragment as Bo,jsx as fe,jsxs as Ao}from"react/jsx-runtime";function Rt({name:e,value:t,description:r,statement:a}){let{setValue:i}=Eo();return Ho(()=>{i(e,t)},[]),fe("div",{children:a?Ao(Bo,{children:[fe("p",{className:`text-sm RemoteFlows__ForcedValue__Title__${e}`,dangerouslySetInnerHTML:{__html:a?.title}}),fe("p",{className:`text-xs RemoteFlows__ForcedValue__Description__${e}`,dangerouslySetInnerHTML:{__html:a?.description}})]}):fe("p",{className:`text-xs RemoteFlows__ForcedValue__Description__${e}`,dangerouslySetInnerHTML:{__html:r}})})}o(Rt,"ForcedValueField");import{Fragment as Go,jsx as j,jsxs as Nt}from"react/jsx-runtime";function Oo(e){return e.const!==void 0&&e.const===e.default&&e.inputType!=="checkbox"&&e.inputType!=="hidden"}o(Oo,"checkFieldHasForcedValue");var Mi=o(({fields:e,components:t})=>!e||e.length===0?null:j(Go,{children:e.map(r=>{if(r.isVisible===!1||r.deprecated)return null;if(Oo(r))return j(Rt,{name:r.name,description:r.description,value:r.const,statement:r.statement},r.name);if(r.Component){let{Component:i}=r;return j(i,{...r},r.name)}let a=ce[r.inputType];return r.inputType==="fieldset"?j(a,{...r,components:t}):a?Nt(zo,{children:[j(a,{...r,component:t&&t[r.inputType]}),r.statement?j(me,{...r.statement}):null]},r.name):Nt("p",{className:"error",children:["Field type ",r.inputType," not supported"]})})}),"JSONSchemaFormFields");export{Mi as a};
|
|
2
|
-
//# sourceMappingURL=chunk-3BIRQAED.js.map
|