@remoteoss/remote-flows 0.14.0 → 0.16.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/chunk-34JNRT23.js +2 -0
- package/dist/chunk-34JNRT23.js.map +1 -0
- package/dist/{chunk-DXABU6DZ.js → chunk-776QJKX5.js} +2 -2
- package/dist/{chunk-J4GIUQ4E.js → chunk-C4RJTN2F.js} +2 -2
- package/dist/{chunk-QDYQEQ3C.js → chunk-DSTM5RRQ.js} +2 -2
- package/dist/{chunk-47VYBPE2.js → chunk-DTGFQMCE.js} +2 -2
- package/dist/{chunk-47VYBPE2.js.map → chunk-DTGFQMCE.js.map} +1 -1
- package/dist/{chunk-RXVVLN7R.js → chunk-GNXVMZY7.js} +2 -2
- package/dist/{chunk-OPCY3UYH.js → chunk-HAL2L237.js} +2 -2
- package/dist/chunk-HBQDXOAG.js +2 -0
- package/dist/{chunk-4XFRZVAL.js.map → chunk-HBQDXOAG.js.map} +1 -1
- package/dist/chunk-HVTGLVLT.js +2 -0
- package/dist/chunk-HVTGLVLT.js.map +1 -0
- package/dist/chunk-IEYBG2G5.js +2 -0
- package/dist/chunk-IEYBG2G5.js.map +1 -0
- package/dist/chunk-IHPLMALI.js +2 -0
- package/dist/chunk-IHPLMALI.js.map +1 -0
- package/dist/{chunk-5EDFVFNU.js → chunk-JQDP6SAT.js} +2 -2
- package/dist/{chunk-GBN2V7QZ.js → chunk-JUGNVM2R.js} +2 -2
- package/dist/{chunk-NH4EITYM.js → chunk-KOPJY6WW.js} +2 -2
- package/dist/{chunk-ARKAW4ZP.js → chunk-O4F6PGGV.js} +2 -2
- package/dist/chunk-QURYMQUD.js +2 -0
- package/dist/chunk-QURYMQUD.js.map +1 -0
- package/dist/{chunk-A3OEOVEH.js → chunk-R2UI3WAJ.js} +2 -2
- package/dist/chunk-R2UI3WAJ.js.map +1 -0
- package/dist/chunk-V2YORDAL.js +2 -0
- package/dist/chunk-V2YORDAL.js.map +1 -0
- package/dist/{chunk-NQCSU6FR.js → chunk-ZZOY6KD4.js} +2 -2
- package/dist/flows/ContractAmendment/ContractAmendmentConfirmationForm.d.ts +1 -1
- package/dist/flows/ContractAmendment/ContractAmendmentFlow.d.ts +1 -1
- package/dist/flows/ContractAmendment/ContractAmendmentForm.d.ts +1 -1
- package/dist/flows/ContractAmendment/context.d.ts +2 -2
- package/dist/flows/ContractAmendment/hooks.d.ts +1 -1
- package/dist/flows/ContractAmendment/index.d.ts +1 -1
- package/dist/flows/ContractAmendment/utils.d.ts +1 -1
- package/dist/flows/CostCalculator/CostCalculatorFlow.d.ts +5 -1
- 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 +8 -3
- package/dist/flows/CostCalculator/EstimationResults/EstimationResults.js +1 -1
- package/dist/flows/CostCalculator/Results/CostCalculatorResults.d.ts +1 -1
- package/dist/flows/CostCalculator/SummaryResults/SummaryResults.d.ts +6 -2
- package/dist/flows/CostCalculator/SummaryResults/SummaryResults.js +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 +2 -2
- package/dist/flows/CostCalculator/hooks.d.ts +1 -1
- 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/jsonSchema.d.ts +21 -0
- package/dist/flows/CostCalculator/jsonSchema.js +1 -1
- package/dist/flows/CostCalculator/types.d.ts +19 -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 +2 -2
- package/dist/flows/Onboarding/OnboardingFlow.js +1 -1
- package/dist/flows/Onboarding/api.d.ts +2 -2
- 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 +2 -2
- 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 +2 -2
- 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 +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 +2 -2
- 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/EmployeeComunicationForm.d.ts +1 -1
- package/dist/flows/Termination/PaidTimeOffForm.d.ts +1 -1
- package/dist/flows/Termination/TerminationDetailsForm.d.ts +1 -1
- package/dist/flows/Termination/TerminationFlow.d.ts +1 -1
- package/dist/flows/Termination/TerminationForm.d.ts +1 -1
- package/dist/flows/Termination/TimeOff.d.ts +1 -1
- package/dist/flows/Termination/context.d.ts +2 -2
- package/dist/flows/Termination/hooks.d.ts +1 -1
- package/dist/flows/Termination/index.d.ts +1 -1
- package/dist/flows/Termination/types.d.ts +1 -1
- package/dist/index.css +1 -1
- package/dist/index.css.map +1 -1
- package/dist/index.d.ts +9 -7
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/{remoteFlows-Clat4nYN.d.ts → remoteFlows-CBNrcwGZ.d.ts} +2 -1
- package/dist/{types.gen-C9Y1S1pc.d.ts → types.gen-CaXCWhlP.d.ts} +1 -1
- package/package.json +1 -1
- package/dist/chunk-4XFRZVAL.js +0 -2
- package/dist/chunk-5E44DBDD.js +0 -2
- package/dist/chunk-5E44DBDD.js.map +0 -1
- package/dist/chunk-6YKL7EOK.js +0 -2
- package/dist/chunk-6YKL7EOK.js.map +0 -1
- package/dist/chunk-A3OEOVEH.js.map +0 -1
- package/dist/chunk-LPFDPXCW.js +0 -2
- package/dist/chunk-LPFDPXCW.js.map +0 -1
- package/dist/chunk-NVQBJCNL.js +0 -2
- package/dist/chunk-NVQBJCNL.js.map +0 -1
- package/dist/chunk-QYJQNWPB.js +0 -2
- package/dist/chunk-QYJQNWPB.js.map +0 -1
- package/dist/chunk-ZD644MH3.js +0 -2
- package/dist/chunk-ZD644MH3.js.map +0 -1
- /package/dist/{chunk-DXABU6DZ.js.map → chunk-776QJKX5.js.map} +0 -0
- /package/dist/{chunk-J4GIUQ4E.js.map → chunk-C4RJTN2F.js.map} +0 -0
- /package/dist/{chunk-QDYQEQ3C.js.map → chunk-DSTM5RRQ.js.map} +0 -0
- /package/dist/{chunk-RXVVLN7R.js.map → chunk-GNXVMZY7.js.map} +0 -0
- /package/dist/{chunk-OPCY3UYH.js.map → chunk-HAL2L237.js.map} +0 -0
- /package/dist/{chunk-5EDFVFNU.js.map → chunk-JQDP6SAT.js.map} +0 -0
- /package/dist/{chunk-GBN2V7QZ.js.map → chunk-JUGNVM2R.js.map} +0 -0
- /package/dist/{chunk-NH4EITYM.js.map → chunk-KOPJY6WW.js.map} +0 -0
- /package/dist/{chunk-ARKAW4ZP.js.map → chunk-O4F6PGGV.js.map} +0 -0
- /package/dist/{chunk-NQCSU6FR.js.map → chunk-ZZOY6KD4.js.map} +0 -0
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
var e={data:{version:7,schema:{additionalProperties:!1,properties:{country:{title:"Country",description:"",type:"string",oneOf:[],"x-jsf-presentation":{inputType:"select"}},region:{title:"Region",description:"",type:"string",oneOf:[],"x-jsf-presentation":{inputType:"select"}},currency:{title:"Currency",description:"",type:"string",oneOf:[],"x-jsf-presentation":{inputType:"select"}},hiring_budget:{title:"How would you like to estimate the cost of hiring?",enum:["employee_annual_salary","my_hiring_budget"],type:"string",oneOf:[{title:"With the employee's annual salary",const:"employee_annual_salary"},{title:"With my hiring budget for this role",const:"my_hiring_budget"}],"x-jsf-presentation":{inputType:"radio"}},salary:{description:"",title:"Salary",type:"integer","x-jsf-presentation":{inputType:"money"}},estimation_title:{title:"Estimation title",description:'Employee title. e.g; "Software Engineer".',type:"string","x-jsf-presentation":{inputType:"text",hidden:!0}},salary_conversion:{description:"",title:"Salary",type:"integer","x-jsf-presentation":{inputType:"money",hidden:!0}},salary_converted:{description:"Whether the salary is expressed in regional or employer currency",title:"Salary in employer currency",type:"string","x-jsf-presentation":{inputType:"hidden",hidden:!0}},management:{title:"Management fee",type:"object",properties:{management_fee:{title:"Desired monthly management fee",type:"integer","x-jsf-presentation":{inputType:"money"}}},"x-jsf-presentation":{inputType:"fieldset",hidden:!0}}},required:["country","currency","salary","salary_conversion","salary_converted"],type:"object","x-jsf-order":["country","region","currency","salary","estimation_title","management"]}}};export{e as a};
|
|
2
|
+
//# sourceMappingURL=chunk-IHPLMALI.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/flows/CostCalculator/jsonSchema.ts"],"sourcesContent":["export const jsonSchema = {\n data: {\n version: 7,\n schema: {\n additionalProperties: false,\n properties: {\n country: {\n title: 'Country',\n description: '',\n type: 'string',\n oneOf: [],\n 'x-jsf-presentation': {\n inputType: 'select',\n },\n },\n region: {\n title: 'Region',\n description: '',\n type: 'string',\n oneOf: [],\n 'x-jsf-presentation': {\n inputType: 'select',\n },\n },\n currency: {\n title: 'Currency',\n description: '',\n type: 'string',\n oneOf: [],\n 'x-jsf-presentation': {\n inputType: 'select',\n },\n },\n hiring_budget: {\n title: 'How would you like to estimate the cost of hiring?',\n enum: ['employee_annual_salary', 'my_hiring_budget'],\n type: 'string',\n oneOf: [\n {\n title: \"With the employee's annual salary\",\n const: 'employee_annual_salary',\n },\n {\n title: 'With my hiring budget for this role',\n const: 'my_hiring_budget',\n },\n ],\n 'x-jsf-presentation': {\n inputType: 'radio',\n },\n },\n salary: {\n description: '',\n title: 'Salary',\n type: 'integer',\n 'x-jsf-presentation': {\n inputType: 'money',\n },\n },\n estimation_title: {\n title: 'Estimation title',\n description: 'Employee title. e.g; \"Software Engineer\".',\n type: 'string',\n 'x-jsf-presentation': {\n inputType: 'text',\n hidden: true,\n },\n },\n salary_conversion: {\n description: '',\n title: 'Salary',\n type: 'integer',\n 'x-jsf-presentation': {\n inputType: 'money',\n hidden: true,\n },\n },\n salary_converted: {\n description:\n 'Whether the salary is expressed in regional or employer currency',\n title: 'Salary in employer currency',\n type: 'string',\n 'x-jsf-presentation': {\n inputType: 'hidden',\n hidden: true,\n },\n },\n management: {\n title: 'Management fee',\n type: 'object',\n properties: {\n management_fee: {\n title: 'Desired monthly management fee',\n type: 'integer',\n 'x-jsf-presentation': {\n inputType: 'money',\n },\n },\n },\n 'x-jsf-presentation': {\n inputType: 'fieldset',\n hidden: true,\n },\n },\n },\n required: [\n 'country',\n 'currency',\n 'salary',\n 'salary_conversion',\n 'salary_converted',\n ],\n type: 'object',\n 'x-jsf-order': [\n 'country',\n 'region',\n 'currency',\n 'salary',\n 'estimation_title',\n 'management',\n ],\n },\n },\n};\n"],"mappings":"AAAO,IAAMA,EAAa,CACxB,KAAM,CACJ,QAAS,EACT,OAAQ,CACN,qBAAsB,GACtB,WAAY,CACV,QAAS,CACP,MAAO,UACP,YAAa,GACb,KAAM,SACN,MAAO,CAAC,EACR,qBAAsB,CACpB,UAAW,QACb,CACF,EACA,OAAQ,CACN,MAAO,SACP,YAAa,GACb,KAAM,SACN,MAAO,CAAC,EACR,qBAAsB,CACpB,UAAW,QACb,CACF,EACA,SAAU,CACR,MAAO,WACP,YAAa,GACb,KAAM,SACN,MAAO,CAAC,EACR,qBAAsB,CACpB,UAAW,QACb,CACF,EACA,cAAe,CACb,MAAO,qDACP,KAAM,CAAC,yBAA0B,kBAAkB,EACnD,KAAM,SACN,MAAO,CACL,CACE,MAAO,oCACP,MAAO,wBACT,EACA,CACE,MAAO,sCACP,MAAO,kBACT,CACF,EACA,qBAAsB,CACpB,UAAW,OACb,CACF,EACA,OAAQ,CACN,YAAa,GACb,MAAO,SACP,KAAM,UACN,qBAAsB,CACpB,UAAW,OACb,CACF,EACA,iBAAkB,CAChB,MAAO,mBACP,YAAa,4CACb,KAAM,SACN,qBAAsB,CACpB,UAAW,OACX,OAAQ,EACV,CACF,EACA,kBAAmB,CACjB,YAAa,GACb,MAAO,SACP,KAAM,UACN,qBAAsB,CACpB,UAAW,QACX,OAAQ,EACV,CACF,EACA,iBAAkB,CAChB,YACE,mEACF,MAAO,8BACP,KAAM,SACN,qBAAsB,CACpB,UAAW,SACX,OAAQ,EACV,CACF,EACA,WAAY,CACV,MAAO,iBACP,KAAM,SACN,WAAY,CACV,eAAgB,CACd,MAAO,iCACP,KAAM,UACN,qBAAsB,CACpB,UAAW,OACb,CACF,CACF,EACA,qBAAsB,CACpB,UAAW,WACX,OAAQ,EACV,CACF,CACF,EACA,SAAU,CACR,UACA,WACA,SACA,oBACA,kBACF,EACA,KAAM,SACN,cAAe,CACb,UACA,SACA,WACA,SACA,mBACA,YACF,CACF,CACF,CACF","names":["jsonSchema"]}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{m as K}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{m as K}from"./chunk-DTGFQMCE.js";import{a as w}from"./chunk-ZTDKPUB5.js";import{b as J}from"./chunk-3ZWDIEEM.js";import{c as G}from"./chunk-3BREUYLG.js";import{a as t,b as d,c as Me}from"./chunk-P37U34EQ.js";var L=d((Et,U)=>{"use strict";function Pe(e){var n=typeof e;return e!=null&&(n=="object"||n=="function")}t(Pe,"isObject");U.exports=Pe});var X=d(($t,V)=>{"use strict";var _e=typeof global=="object"&&global&&global.Object===Object&&global;V.exports=_e});var F=d((qt,z)=>{"use strict";var ke=X(),we=typeof self=="object"&&self&&self.Object===Object&&self,Le=ke||we||Function("return this")();z.exports=Le});var Y=d((It,Q)=>{"use strict";var Fe=F(),Ae=t(function(){return Fe.Date.now()},"now");Q.exports=Ae});var ee=d((Pt,Z)=>{"use strict";var We=/\s/;function De(e){for(var n=e.length;n--&&We.test(e.charAt(n)););return n}t(De,"trimmedEndIndex");Z.exports=De});var ne=d((kt,te)=>{"use strict";var Be=ee(),Ne=/^\s+/;function He(e){return e&&e.slice(0,Be(e)+1).replace(Ne,"")}t(He,"baseTrim");te.exports=He});var A=d((Lt,re)=>{"use strict";var Ge=F(),Je=Ge.Symbol;re.exports=Je});var ae=d((Ft,se)=>{"use strict";var oe=A(),ie=Object.prototype,Ke=ie.hasOwnProperty,Ue=ie.toString,O=oe?oe.toStringTag:void 0;function Ve(e){var n=Ke.call(e,O),r=e[O];try{e[O]=void 0;var o=!0}catch{}var s=Ue.call(e);return o&&(n?e[O]=r:delete e[O]),s}t(Ve,"getRawTag");se.exports=Ve});var ue=d((Wt,ce)=>{"use strict";var Xe=Object.prototype,ze=Xe.toString;function Qe(e){return ze.call(e)}t(Qe,"objectToString");ce.exports=Qe});var me=d((Bt,le)=>{"use strict";var fe=A(),Ye=ae(),Ze=ue(),et="[object Null]",tt="[object Undefined]",de=fe?fe.toStringTag:void 0;function nt(e){return e==null?e===void 0?tt:et:de&&de in Object(e)?Ye(e):Ze(e)}t(nt,"baseGetTag");le.exports=nt});var pe=d((Ht,ge)=>{"use strict";function rt(e){return e!=null&&typeof e=="object"}t(rt,"isObjectLike");ge.exports=rt});var ve=d((Jt,be)=>{"use strict";var ot=me(),it=pe(),st="[object Symbol]";function at(e){return typeof e=="symbol"||it(e)&&ot(e)==st}t(at,"isSymbol");be.exports=at});var Te=d((Ut,xe)=>{"use strict";var ct=ne(),ye=L(),ut=ve(),he=NaN,ft=/^[-+]0x[0-9a-f]+$/i,dt=/^0b[01]+$/i,lt=/^0o[0-7]+$/i,mt=parseInt;function gt(e){if(typeof e=="number")return e;if(ut(e))return he;if(ye(e)){var n=typeof e.valueOf=="function"?e.valueOf():e;e=ye(n)?n+"":n}if(typeof e!="string")return e===0?e:+e;e=ct(e);var r=dt.test(e);return r||lt.test(e)?mt(e.slice(2),r?2:8):ft.test(e)?he:+e}t(gt,"toNumber");xe.exports=gt});var je=d((Xt,Se)=>{"use strict";var pt=L(),W=Y(),Ce=Te(),bt="Expected a function",vt=Math.max,yt=Math.min;function ht(e,n,r){var o,s,p,l,a,c,m=0,E=!1,u=!1,h=!0;if(typeof e!="function")throw new TypeError(bt);n=Ce(n)||0,pt(r)&&(E=!!r.leading,u="maxWait"in r,p=u?vt(Ce(r.maxWait)||0,n):p,h="trailing"in r?!!r.trailing:h);function x(i){var g=o,y=s;return o=s=void 0,m=i,l=e.apply(y,g),l}t(x,"invokeFunc");function R(i){return m=i,a=setTimeout(v,n),E?x(i):l}t(R,"leadingEdge");function C(i){var g=i-c,y=i-m,M=n-g;return u?yt(M,p-y):M}t(C,"remainingWait");function $(i){var g=i-c,y=i-m;return c===void 0||g>=n||g<0||u&&y>=p}t($,"shouldInvoke");function v(){var i=W();if($(i))return b(i);a=setTimeout(v,C(i))}t(v,"timerExpired");function b(i){return a=void 0,h&&o?x(i):(o=s=void 0,l)}t(b,"trailingEdge");function q(){a!==void 0&&clearTimeout(a),m=0,o=c=s=a=void 0}t(q,"cancel");function I(){return a===void 0?l:b(W())}t(I,"flush");function S(){var i=W(),g=$(i);if(o=arguments,s=this,c=i,g){if(a===void 0)return R(c);if(u)return clearTimeout(a),a=setTimeout(v,n),x(c)}return a===void 0&&(a=setTimeout(v,n)),l}return t(S,"debounced"),S.cancel=q,S.flush=I,S}t(ht,"debounce");Se.exports=ht});import{useState as Ct,useCallback as St,useEffect as Re,useRef as $e}from"react";var Ee=Me(je(),1);import{useCallback as xt,useEffect as Tt,useRef as Oe}from"react";function D(e,n){let r=Oe(e);Tt(()=>{r.current=e},[e]);let o=Oe((0,Ee.default)(s=>{r.current(s)},n)).current;return xt(s=>{o(s)},[o])}t(D,"useDebounce");import{Fragment as Ot,jsx as T,jsxs as qe}from"react/jsx-runtime";var jt=t(({description:e,showConversion:n,targetCurrency:r,className:o,onClick:s})=>{let{components:p}=J(),l=n?`Hide ${r} conversion`:`Show ${r} conversion`,a=p?.button;return qe("span",{className:o,children:[e," ",a?T(a,{className:`${o.replace("-description","-button")}`,"data-type":"inline",onClick:s,children:l}):T("button",{className:`${o.replace("-description","-button")}`,onClick:s,children:l})]})},"DescriptionWithConversion"),cn=t(({sourceCurrency:e,targetCurrency:n,mainFieldName:r,conversionFieldName:o,conversionProperties:s,classNamePrefix:p,description:l,conversionType:a="spread",...c})=>{let[m,E]=Ct(!1),{setValue:u,watch:h}=G(),x=h(r||c.name),R=$e(!0),C=$e(new Map),$=e&&n&&e!==n,{mutateAsync:v}=K({type:a}),b=`${c.name}_converted`;Re(()=>{u(b,r||c.name)},[u,r,c.name,b]),Re(()=>{if(R.current){R.current=!1;return}u(o,"")},[e,o,u]);let q=St(async(f,j,k,B)=>{if(!f)return;let N=`${j}_${k}_${f}`,H=C.current.get(N);if(H){u(B,H.targetAmount);return}try{let P=await v({source_currency:j,target_currency:k,amount:Number(f)});if(P.data?.data?.conversion_data?.target_amount){let _=P.data.data.conversion_data.target_amount;if(_){u(B,_?.toString()),C.current.set(N,{targetAmount:_.toString()});let Ie=`${k}_${j}_${_}`;C.current.set(Ie,{targetAmount:f.toString()})}}}catch(P){console.error("Error converting currency:",P)}},[v,u]),I=D(f=>q(f,e,n,o),500),S=D(f=>q(f,n,e,r||c.name),500),i=t(f=>{u(b,r||c.name),m&&I(f.target.value)},"handleMainFieldChange"),g=t(f=>{u(b,o),S(f.target.value)},"handleConversionFieldChange"),y=t(f=>{f.preventDefault(),E(j=>!j),!m&&x&&I(x)},"toggleConversion"),M=$?T(jt,{targetCurrency:n,description:l,showConversion:m,className:`${p}-description`,onClick:y}):l;return qe(Ot,{children:[T(w,{...c,name:r||c.name,additionalProps:{currency:e},description:M,type:"text",inputMode:"decimal",pattern:"^[0-9.]*$",maxLength:15,onChange:i}),m&&T(w,{additionalProps:{currency:n},name:o,label:s?.label||"Conversion",description:s?.description,type:"text",inputMode:"decimal",pattern:"^[0-9.]*$",maxLength:15,onChange:g}),T("input",{type:"hidden",name:b,value:h(b)||r||c.name})]})},"CurrencyConversionField");export{cn as a};
|
|
2
|
+
//# sourceMappingURL=chunk-JQDP6SAT.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as l}from"./chunk-NBCZF2FO.js";import{a}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as l}from"./chunk-NBCZF2FO.js";import{a}from"./chunk-JQDP6SAT.js";import{a as c}from"./chunk-N5I33LIN.js";import{c as t}from"./chunk-3BREUYLG.js";import{a as i}from"./chunk-P37U34EQ.js";import{useEffect as u}from"react";import{Fragment as _,jsx as m,jsxs as N}from"react/jsx-runtime";var k=i(({currencies:{from:d,to:y},shouldSwapOrder:e,salary_conversion_properties:s,conversionType:F="no_spread",defaultValue:r,...o})=>{let{setValue:n,getValues:p}=t(),v={label:s?.label||"Salary conversion",description:s?.description||N(_,{children:["The conversion is based on the Remote FX rate."," ",m(c,{className:"text-sm",zendeskId:l.remoteFxRate,children:"Learn more \u2197"})]})},g=e?"salary_conversion":o.name,f=e?o.name:"salary_conversion";return u(()=>{e&&r&&(n("salary_conversion",r),n("salary_converted","salary_conversion"))},[e,r,n,p]),m(a,{...o,sourceCurrency:d,targetCurrency:y,mainFieldName:g,conversionFieldName:f,conversionProperties:v,classNamePrefix:"RemoteFlows-Salary",conversionType:F})},"SalaryField");export{k as a};
|
|
2
|
+
//# sourceMappingURL=chunk-JUGNVM2R.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as m}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as m}from"./chunk-HBQDXOAG.js";import{b as a}from"./chunk-PGWKJ6FK.js";import{b as t}from"./chunk-QW4JPW6J.js";import{d as s}from"./chunk-MXFDOIUA.js";import{a as e}from"./chunk-P37U34EQ.js";import{jsx as E}from"react/jsx-runtime";function P({components:d,onSubmit:l,onError:i,onSuccess:f}){let{onboardingBag:o}=a(),p=o.fields??[],c=s(p,o.initialValues.benefits);return E(m,{defaultValues:c,components:d,onSubmit:e(async n=>{try{await l?.(n);let r=await o.onSubmit(n);if(r?.data){await f?.(r.data),o?.next();return}if(r?.error){let u=t(r?.fieldErrors||[],o.meta?.fields?.benefits);i?.({error:r.error,rawError:r.rawError,fieldErrors:u})}}catch(r){i?.({error:r,rawError:r,fieldErrors:[]})}},"handleSubmit")})}e(P,"BenefitsStep");export{P as a};
|
|
2
|
+
//# sourceMappingURL=chunk-KOPJY6WW.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{b as g}from"./chunk-PGWKJ6FK.js";import{d as f,e as w}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{b as g}from"./chunk-PGWKJ6FK.js";import{d as f,e as w}from"./chunk-DTGFQMCE.js";import{a as m}from"./chunk-QW4JPW6J.js";import{b as y}from"./chunk-3ZWDIEEM.js";import{b as E}from"./chunk-7VUILYZ3.js";import{a}from"./chunk-P37U34EQ.js";import{jsx as R}from"react/jsx-runtime";function A({onSubmit:S,onSuccess:d,onError:o,render:u,...r}){let{components:I}=y(),{onboardingBag:t,setCreditScore:c}=g(),n=f(),i=w(),{mutateAsync:b}=m(n),{mutateAsync:_}=m(i),l=a(async()=>{try{if(await S?.(),t.creditRiskStatus==="deposit_required"&&t.employmentId&&t.employment?.status&&!t.isEmploymentReadOnly){let e=await _({employment_slug:t.employmentId});if(e.data){await d?.({data:e.data,employmentStatus:"created_awaiting_reserve"}),c?.(s=>({...s,showReserveInvoice:!0})),t.refetchEmployment();return}e.error&&o?.({error:e.error,rawError:e.rawError,fieldErrors:[]})}else if(t.employmentId){let e=await b({employment_id:t.employmentId});if(e.data){await d?.({data:e.data,employmentStatus:"invited"}),c?.(s=>({...s,showInviteSuccessful:!0})),t.refetchEmployment();return}e.error&&o?.({error:e.error,rawError:e.rawError,fieldErrors:[]})}}catch(e){o?.({error:e,rawError:e,fieldErrors:[]})}},"handleSubmit"),p=t.creditRiskStatus==="deposit_required"&&t.employment?.status&&!t.isEmploymentReadOnly,v=I?.button;return v?R(v,{...r,disabled:n.isPending||i.isPending||r.disabled,onClick:e=>{l(),r.onClick?.(e)},children:u({employmentStatus:p?"created_awaiting_reserve":"invited"})}):R(E,{...r,disabled:n.isPending||i.isPending||r.disabled,onClick:()=>{l()},children:u({employmentStatus:p?"created_awaiting_reserve":"invited"})})}a(A,"OnboardingInvite");export{A as a};
|
|
2
|
+
//# sourceMappingURL=chunk-O4F6PGGV.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{b as n}from"./chunk-KSHK3ZPX.js";import{a as f}from"./chunk-LK4XMOCE.js";import{g as C}from"./chunk-3BREUYLG.js";import{a as i}from"./chunk-P37U34EQ.js";import{useEffect as b}from"react";import{jsx as l}from"react/jsx-runtime";function w({onSubmit:d,onError:m,onSuccess:p,shouldResetForm:u,resetFields:s}){let{form:o,formId:E,costCalculatorBag:r}=n(),{formState:{isSubmitSuccessful:e}}=o;b(()=>{if(e&&u){r?.resetForm(),o.reset();return}if(e&&s){let t={...o.getValues()};s.forEach(a=>{t[a]=""}),r?.resetForm(),o.reset(t)}},[e,o,u,r,s]);let S=i(async c=>{try{let t=r?.parseFormValues(c),a=await r?.onSubmit(t);if(await d?.(t),a?.error)m?.(a.error);else if(a?.data){let F={data:{...a.data.data,employments:a.data.data.employments?.map(V=>({...V,title:t.estimation_title}))}};await p?.(F)}}catch(t){m?.(t)}},"handleSubmit");return l(C,{...o,children:l("form",{id:E,onSubmit:o.handleSubmit(S),className:"space-y-4 RemoteFlows__CostCalculatorForm",children:l(f,{fields:r?.fields??[]})})})}i(w,"CostCalculatorForm");export{w as a};
|
|
2
|
+
//# sourceMappingURL=chunk-QURYMQUD.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/flows/CostCalculator/CostCalculatorForm.tsx"],"sourcesContent":["import { useEffect } from 'react';\nimport { JSONSchemaFormFields } from '@/src/components/form/JSONSchemaForm';\nimport { Form } from '@/src/components/ui/form';\nimport { useCostCalculatorContext } from '@/src/flows/CostCalculator/context';\nimport {\n CostCalculatorEstimationResponse,\n CostCalculatorEstimationFormValues,\n CostCalculatorEstimationSubmitValues,\n EstimationError,\n} from '@/src/flows/CostCalculator/types';\n\ntype CostCalculatorFormProps = Partial<{\n /**\n * Callback function that handles form submission. When form is submit, the form values are sent to the consumer app before behind submitted to Remote.\n * @param data - The payload sent to the /cost-calculator/estimation endpoint.\n */\n onSubmit: (\n data: CostCalculatorEstimationSubmitValues,\n ) => Promise<void> | void;\n /**\n * Callback function to handle the success when the estimation succeeds. The CostCalculatorEstimateResponse is sent back to you.\n * @param data - The response data from the /cost-calculator/estimation endpoint.\n */\n onSuccess: (data: CostCalculatorEstimationResponse) => Promise<void> | void;\n /**\n * Callback function to handle the error when the estimation fails.\n * @param error - The error object.\n */\n onError: (error: EstimationError) => void;\n /**\n * Whether to reset the form when the form is successfully submitted.\n */\n shouldResetForm?: boolean;\n\n /**\n * Fields to reset when the form is successfully submitted.\n */\n resetFields?: ('country' | 'currency' | 'salary')[];\n}>;\n\nexport function CostCalculatorForm({\n onSubmit,\n onError,\n onSuccess,\n shouldResetForm,\n resetFields,\n}: CostCalculatorFormProps) {\n const { form, formId, costCalculatorBag } = useCostCalculatorContext();\n\n const {\n formState: { isSubmitSuccessful },\n } = form;\n\n useEffect(() => {\n // resets the entire form if the form is successfully submitted and the shouldResetForm prop is true\n if (isSubmitSuccessful && shouldResetForm) {\n costCalculatorBag?.resetForm();\n form.reset();\n return;\n }\n\n // resets the specified fields if the form is successfully submitted and the resetFields prop is provided\n if (isSubmitSuccessful && resetFields) {\n // Reset only the specified fields\n const currentValues = form.getValues();\n const resetValues = { ...currentValues };\n resetFields.forEach((field) => {\n resetValues[field] = '';\n });\n\n costCalculatorBag?.resetForm();\n form.reset(resetValues);\n }\n }, [\n isSubmitSuccessful,\n form,\n shouldResetForm,\n costCalculatorBag,\n resetFields,\n ]);\n\n const handleSubmit = async (values: CostCalculatorEstimationFormValues) => {\n try {\n const parsedValues = costCalculatorBag?.parseFormValues(\n values,\n ) as CostCalculatorEstimationSubmitValues;\n\n const costCalculatorResults =\n await costCalculatorBag?.onSubmit(parsedValues);\n\n // if this rejects, catch will handle it\n await onSubmit?.(parsedValues);\n\n if (costCalculatorResults?.error) {\n onError?.(costCalculatorResults.error);\n } else if (costCalculatorResults?.data) {\n const responseWithTitle = {\n data: {\n ...costCalculatorResults.data.data,\n employments: costCalculatorResults.data.data.employments?.map(\n (employment) => ({\n ...employment,\n title: parsedValues.estimation_title,\n }),\n ),\n },\n };\n await onSuccess?.(responseWithTitle);\n }\n } catch (err) {\n onError?.(err as EstimationError);\n }\n };\n\n return (\n <Form {...form}>\n <form\n id={formId}\n onSubmit={form.handleSubmit(handleSubmit)}\n className='space-y-4 RemoteFlows__CostCalculatorForm'\n >\n <JSONSchemaFormFields fields={costCalculatorBag?.fields ?? []} />\n </form>\n </Form>\n );\n}\n"],"mappings":"gKAAA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4CAEV,SAAAf,EAACwB,EAAA,CAAqB,OAAQf,GAAmB,QAAU,CAAC,EAAG,EACjE,EACF,CAEJ,CArFgBO,EAAAf,EAAA","names":["useEffect","jsx","CostCalculatorForm","onSubmit","onError","onSuccess","shouldResetForm","resetFields","form","formId","costCalculatorBag","useCostCalculatorContext","isSubmitSuccessful","useEffect","resetValues","field","handleSubmit","__name","values","parsedValues","costCalculatorResults","responseWithTitle","employment","err","Form","JSONSchemaFormFields"]}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as d,b as p,c as g,d as x}from"./chunk-4RULC3AZ.js";import{a as N}from"./chunk-UHS3QRA3.js";import{a as i,b as y}from"./chunk-3LOVCTCN.js";import{a as c}from"./chunk-P37U34EQ.js";import{ChevronDown as b,Globe as _}from"lucide-react";import{useState as A}from"react";import{Fragment as C,jsx as e,jsxs as r}from"react/jsx-runtime";var w=c(s=>{if(s.length<2)return{currency:null,costsPerCountry:[],employeesCost:null};let t=s[0]?.employer_currency_costs.currency,m=s.reduce((o,a)=>{let l=a.country.name;return o[l]={country:a.country,monthlyTotal:(o[l]?.monthlyTotal||0)+a.employer_currency_costs.monthly_total,annualTotal:(o[l]?.annualTotal||0)+a.employer_currency_costs.annual_total},o},{}),n=Object.values(m).map(({country:o,monthlyTotal:a,annualTotal:l})=>({country:o,monthlyCost:y(a,t.symbol),annualCost:y(l,t.symbol)})),u={monthlyTotal:y(s.reduce((o,a)=>o+a.employer_currency_costs.monthly_total,0),t.symbol),annualTotal:y(s.reduce((o,a)=>o+a.employer_currency_costs.annual_total,0),t.symbol)};return{currency:t,costsPerCountry:n,employeesCost:u}},"useSummaryResults"),T=c(({currency:s,title:t})=>e("div",{className:"flex items-center justify-between w-full",children:r("div",{className:"flex flex-row items-center gap-6",children:[e("div",{className:"flex h-12 w-12 items-center justify-center rounded-lg bg-[#F4F4F5]",children:e(_,{className:"h-6 w-6 text-[#000000]"})}),r("div",{className:"space-y-1",children:[e("h2",{className:"text-lg font-medium leading-none text-[#181818]",children:t}),r("p",{className:"text-xs text-[#71717A]",children:["Employer billing currency: ",s.code]})]})]})}),"SummaryHeader"),
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as d,b as p,c as g,d as x}from"./chunk-4RULC3AZ.js";import{a as N}from"./chunk-UHS3QRA3.js";import{a as i,b as y}from"./chunk-3LOVCTCN.js";import{a as c}from"./chunk-P37U34EQ.js";import{ChevronDown as b,Globe as _}from"lucide-react";import{useState as A}from"react";import{Fragment as C,jsx as e,jsxs as r}from"react/jsx-runtime";var w=c(s=>{if(s.length<2)return{currency:null,costsPerCountry:[],employeesCost:null};let t=s[0]?.employer_currency_costs.currency,m=s.reduce((o,a)=>{let l=a.country.name;return o[l]={country:a.country,monthlyTotal:(o[l]?.monthlyTotal||0)+a.employer_currency_costs.monthly_total,annualTotal:(o[l]?.annualTotal||0)+a.employer_currency_costs.annual_total},o},{}),n=Object.values(m).map(({country:o,monthlyTotal:a,annualTotal:l})=>({country:o,monthlyCost:y(a,t.symbol),annualCost:y(l,t.symbol)})),u={monthlyTotal:y(s.reduce((o,a)=>o+a.employer_currency_costs.monthly_total,0),t.symbol),annualTotal:y(s.reduce((o,a)=>o+a.employer_currency_costs.annual_total,0),t.symbol)};return{currency:t,costsPerCountry:n,employeesCost:u}},"useSummaryResults"),T=c(({currency:s,title:t})=>e("div",{className:"flex items-center justify-between w-full",children:r("div",{className:"flex flex-row items-center gap-6",children:[e("div",{className:"flex h-12 w-12 items-center justify-center rounded-lg bg-[#F4F4F5]",children:e(_,{className:"h-6 w-6 text-[#000000]"})}),r("div",{className:"space-y-1",children:[e("h2",{className:"text-lg font-medium leading-none text-[#181818]",children:t}),r("p",{className:"text-xs text-[#71717A]",children:["Employer billing currency: ",s.code]})]})]})}),"SummaryHeader"),f=c(({label:s,columns:t,rows:m,defaultValue:n="accordion",className:u})=>{let o=t.length===1?"grid-cols-2":"grid-cols-3";return e(d,{type:"single",collapsible:!0,defaultValue:n,className:i("w-full",u),children:r(p,{value:n,className:"border-none",children:[e(g,{className:"hover:no-underline px-0 py-3 [&>svg]:hidden group",children:r("div",{className:i("grid items-center w-full",o),children:[r("div",{className:"flex items-center gap-2",children:[s,e(b,{className:"h-4 w-4 text-muted-foreground transition-transform group-data-[state=open]:rotate-180"})]}),t.length===1?e("span",{className:"text-xs text-[#27272A] text-right",children:t[0]}):t.map((a,l)=>e("span",{className:"text-xs text-[#27272A] text-right",children:a},l))]})}),e(x,{className:"px-0 pb-4",children:e("div",{className:"space-y-3",children:m.map((a,l)=>r("div",{className:i("grid items-center",o),children:[e("div",{className:"flex items-center gap-2",children:a.label}),t.length===1?e("span",{className:"text-sm text-[#09090B] text-right",children:a.values[0]}):a.values.map((h,v)=>e("span",{className:"text-sm text-[#09090B] text-right",children:h},v))]},l))})})]})})},"MultiColumnAccordion"),R=c(({employeesCost:s})=>e(f,{label:e("span",{className:"text-sm font-medium text-[#0F172A]",children:"Cost for all employees"}),columns:["Total cost"],rows:[{label:r(C,{children:[e("span",{className:"w-1 h-1 bg-[#09090B] rounded-full flex-shrink-0"}),e("span",{className:"text-sm text-[#09090B]",children:"Monthly cost"})]}),values:[s.monthlyTotal]},{label:r(C,{children:[e("span",{className:"w-1 h-1 bg-[#09090B] rounded-full flex-shrink-0"}),e("span",{className:"text-sm text-[#09090B]",children:"Annual cost"})]}),values:[s.annualTotal]}],defaultValue:"cost-breakdown"}),"CostForAllEmployees"),S=c(({costsPerCountry:s})=>e(f,{label:e("span",{className:"text-sm font-medium text-[#0F172A]",children:"Cost per country"}),columns:["Monthly cost","Annual cost"],rows:s.map(t=>({label:r(C,{children:[e("span",{className:"w-1 h-1 bg-[#09090B] rounded-full flex-shrink-0"}),e("span",{className:"text-sm text-[#09090B]",children:t.country.name})]}),values:[t.monthlyCost,t.annualCost]})),defaultValue:"country-breakdown"}),"CostsPerCountry"),E=c(({estimations:s})=>{let{currency:t,costsPerCountry:m,employeesCost:n}=w(s),[u,o]=A("summary");return!t||m.length===0||Object.keys(n).length===0?null:e(N,{className:"RemoteFlows__SummaryResults__Card p-10",children:e(d,{type:"single",collapsible:!0,defaultValue:u,onValueChange:o,className:"RemoteFlows__SummaryResults__Accordion w-full",children:r(p,{value:"summary",className:"border-border",children:[e("div",{className:i({RemoteFlows__Separator:u==="summary"}),children:e(g,{iconClassName:"size-6",className:"hover:no-underline px-0 py-4",children:e(T,{currency:t,title:"Summary Overview"})})}),r(x,{className:"px-0 pb-4 mt-6",children:[e("div",{className:"RemoteFlows__Separator",children:e(R,{employeesCost:n})}),e("div",{className:"mt-6",children:e(S,{costsPerCountry:m})})]})]})})})},"SummaryResults");export{E as a};
|
|
2
|
+
//# sourceMappingURL=chunk-R2UI3WAJ.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/flows/CostCalculator/SummaryResults/SummaryResults.tsx"],"sourcesContent":["import { Currency } from '@/src/client';\nimport {\n Accordion,\n AccordionContent,\n AccordionItem,\n AccordionTrigger,\n} from '@/src/components/ui/accordion';\nimport { Card } from '@/src/components/ui/card';\nimport { CostCalculatorEstimation } from '@/src/flows/CostCalculator/types';\nimport { cn, formatCurrency } from '@/src/lib/utils';\nimport { ChevronDown, Globe } from 'lucide-react';\nimport { useState } from 'react';\n\nconst useSummaryResults = (estimations: CostCalculatorEstimation[]) => {\n if (estimations.length < 2) {\n return {\n currency: null,\n costsPerCountry: [],\n employeesCost: null,\n };\n }\n const currency = estimations[0]?.employer_currency_costs.currency;\n const costsPerCountry = estimations.reduce(\n (acc, estimation) => {\n const countryName = estimation.country.name;\n\n acc[countryName] = {\n country: estimation.country,\n monthlyTotal:\n (acc[countryName]?.monthlyTotal || 0) +\n estimation.employer_currency_costs.monthly_total,\n annualTotal:\n (acc[countryName]?.annualTotal || 0) +\n estimation.employer_currency_costs.annual_total,\n };\n\n return acc;\n },\n {} as Record<\n string,\n {\n country: (typeof estimations)[0]['country'];\n monthlyTotal: number;\n annualTotal: number;\n }\n >,\n );\n\n const groupedCostsPerCountry = Object.values(costsPerCountry).map(\n ({ country, monthlyTotal, annualTotal }) => ({\n country,\n monthlyCost: formatCurrency(monthlyTotal, currency.symbol),\n annualCost: formatCurrency(annualTotal, currency.symbol),\n }),\n );\n\n const employeesCost = {\n monthlyTotal: formatCurrency(\n estimations.reduce((acc, estimation) => {\n return acc + estimation.employer_currency_costs.monthly_total;\n }, 0),\n currency.symbol,\n ),\n annualTotal: formatCurrency(\n estimations.reduce((acc, estimation) => {\n return acc + estimation.employer_currency_costs.annual_total;\n }, 0),\n currency.symbol,\n ),\n };\n return { currency, costsPerCountry: groupedCostsPerCountry, employeesCost };\n};\n\nconst SummaryHeader = ({\n currency,\n title,\n}: {\n currency: Currency;\n title: string;\n}) => {\n return (\n <div className='flex items-center justify-between w-full'>\n <div className='flex flex-row items-center gap-6'>\n <div className='flex h-12 w-12 items-center justify-center rounded-lg bg-[#F4F4F5]'>\n <Globe className='h-6 w-6 text-[#000000]' />\n </div>\n <div className='space-y-1'>\n <h2 className='text-lg font-medium leading-none text-[#181818]'>\n {title}\n </h2>\n <p className='text-xs text-[#71717A]'>\n Employer billing currency: {currency.code}\n </p>\n </div>\n </div>\n </div>\n );\n};\n\nconst MultiColumnAccordion = ({\n label,\n columns,\n rows,\n defaultValue = 'accordion',\n className,\n}: {\n label: React.ReactNode;\n columns: string[];\n rows: Array<{\n label: React.ReactNode;\n values: string[];\n }>;\n defaultValue?: string;\n className?: string;\n}) => {\n const gridCols = columns.length === 1 ? 'grid-cols-2' : 'grid-cols-3';\n\n return (\n <Accordion\n type='single'\n collapsible\n defaultValue={defaultValue}\n className={cn('w-full', className)}\n >\n <AccordionItem value={defaultValue} className='border-none'>\n <AccordionTrigger className='hover:no-underline px-0 py-3 [&>svg]:hidden group'>\n <div className={cn('grid items-center w-full', gridCols)}>\n <div className='flex items-center gap-2'>\n {label}\n <ChevronDown className='h-4 w-4 text-muted-foreground transition-transform group-data-[state=open]:rotate-180' />\n </div>\n {columns.length === 1 ? (\n <span className='text-xs text-[#27272A] text-right'>\n {columns[0]}\n </span>\n ) : (\n columns.map((column, index) => (\n <span key={index} className='text-xs text-[#27272A] text-right'>\n {column}\n </span>\n ))\n )}\n </div>\n </AccordionTrigger>\n\n <AccordionContent className='px-0 pb-4'>\n <div className='space-y-3'>\n {rows.map((row, index) => (\n <div key={index} className={cn('grid items-center', gridCols)}>\n <div className='flex items-center gap-2'>{row.label}</div>\n {columns.length === 1 ? (\n <span className='text-sm text-[#09090B] text-right'>\n {row.values[0]}\n </span>\n ) : (\n row.values.map((value, valueIndex) => (\n <span\n key={valueIndex}\n className='text-sm text-[#09090B] text-right'\n >\n {value}\n </span>\n ))\n )}\n </div>\n ))}\n </div>\n </AccordionContent>\n </AccordionItem>\n </Accordion>\n );\n};\n\nconst CostForAllEmployees = ({\n employeesCost,\n}: {\n employeesCost: { monthlyTotal: string; annualTotal: string };\n}) => {\n return (\n <MultiColumnAccordion\n label={\n <span className='text-sm font-medium text-[#0F172A]'>\n Cost for all employees\n </span>\n }\n columns={['Total cost']}\n rows={[\n {\n label: (\n <>\n <span className='w-1 h-1 bg-[#09090B] rounded-full flex-shrink-0' />\n <span className='text-sm text-[#09090B]'>Monthly cost</span>\n </>\n ),\n values: [employeesCost.monthlyTotal],\n },\n {\n label: (\n <>\n <span className='w-1 h-1 bg-[#09090B] rounded-full flex-shrink-0' />\n <span className='text-sm text-[#09090B]'>Annual cost</span>\n </>\n ),\n values: [employeesCost.annualTotal],\n },\n ]}\n defaultValue='cost-breakdown'\n />\n );\n};\n\nconst CostsPerCountry = ({\n costsPerCountry,\n}: {\n costsPerCountry: Array<{\n country: { name: string };\n monthlyCost: string;\n annualCost: string;\n }>;\n}) => {\n return (\n <MultiColumnAccordion\n label={\n <span className='text-sm font-medium text-[#0F172A]'>\n Cost per country\n </span>\n }\n columns={['Monthly cost', 'Annual cost']}\n rows={costsPerCountry.map((cost) => ({\n label: (\n <>\n <span className='w-1 h-1 bg-[#09090B] rounded-full flex-shrink-0' />\n <span className='text-sm text-[#09090B]'>{cost.country.name}</span>\n </>\n ),\n values: [cost.monthlyCost, cost.annualCost],\n }))}\n defaultValue='country-breakdown'\n />\n );\n};\n\ntype SummaryResultsProps = {\n /**\n * Array of employments to compare costs for.\n * 2 estimations required for the component to render\n */\n estimations: CostCalculatorEstimation[];\n};\n\n/**\n * Displays a summary comparison of costs across multiple estimations.\n * The component will return null if you pass less than 2 estimations.\n */\nexport const SummaryResults = ({ estimations }: SummaryResultsProps) => {\n const { currency, costsPerCountry, employeesCost } =\n useSummaryResults(estimations);\n\n const [accordionValue, setAccordionValue] = useState('summary');\n\n if (\n !currency ||\n costsPerCountry.length === 0 ||\n Object.keys(employeesCost).length === 0\n ) {\n return null;\n }\n\n return (\n <Card className='RemoteFlows__SummaryResults__Card p-10'>\n <Accordion\n type='single'\n collapsible\n defaultValue={accordionValue}\n onValueChange={setAccordionValue}\n className='RemoteFlows__SummaryResults__Accordion w-full'\n >\n <AccordionItem value='summary' className='border-border'>\n <div\n className={cn({\n RemoteFlows__Separator: accordionValue === 'summary',\n })}\n >\n <AccordionTrigger\n iconClassName='size-6'\n className='hover:no-underline px-0 py-4'\n >\n <SummaryHeader currency={currency} title='Summary Overview' />\n </AccordionTrigger>\n </div>\n <AccordionContent className='px-0 pb-4 mt-6'>\n <div className='RemoteFlows__Separator'>\n <CostForAllEmployees employeesCost={employeesCost} />\n </div>\n <div className='mt-6'>\n <CostsPerCountry costsPerCountry={costsPerCountry} />\n </div>\n </AccordionContent>\n </AccordionItem>\n </Accordion>\n </Card>\n );\n};\n"],"mappings":"4LAUA,OAAS,eAAAA,EAAa,SAAAC,MAAa,eACnC,OAAS,YAAAC,MAAgB,QAyEf,OAyGE,YAAAC,EAzGF,OAAAC,EAMA,QAAAC,MANA,oBAvEV,IAAMC,EAAoBC,EAACC,GAA4C,CACrE,GAAIA,EAAY,OAAS,EACvB,MAAO,CACL,SAAU,KACV,gBAAiB,CAAC,EAClB,cAAe,IACjB,EAEF,IAAMC,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ACC,UAAW2B,EAAG,CACZ,uBAAwBc,IAAmB,SAC7C,CAAC,EAED,SAAAzC,EAAC6B,EAAA,CACC,cAAc,SACd,UAAU,+BAEV,SAAA7B,EAACgB,EAAA,CAAc,SAAUX,EAAU,MAAM,mBAAmB,EAC9D,EACF,EACAJ,EAACgC,EAAA,CAAiB,UAAU,iBAC1B,UAAAjC,EAAC,OAAI,UAAU,yBACb,SAAAA,EAACqC,EAAA,CAAoB,cAAetB,EAAe,EACrD,EACAf,EAAC,OAAI,UAAU,OACb,SAAAA,EAACsC,EAAA,CAAgB,gBAAiBhC,EAAiB,EACrD,GACF,GACF,EACF,EACF,CAEJ,EAhD8B","names":["ChevronDown","Globe","useState","Fragment","jsx","jsxs","useSummaryResults","__name","estimations","currency","costsPerCountry","acc","estimation","countryName","groupedCostsPerCountry","country","monthlyTotal","annualTotal","formatCurrency","employeesCost","SummaryHeader","title","Globe","MultiColumnAccordion","label","columns","rows","defaultValue","className","gridCols","Accordion","cn","AccordionItem","AccordionTrigger","ChevronDown","column","index","AccordionContent","row","value","valueIndex","CostForAllEmployees","CostsPerCountry","cost","SummaryResults","accordionValue","setAccordionValue","useState","Card"]}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{g as l,k as u,p as c,t as m,y as d}from"./chunk-EGQJ7UBR.js";import{d as s}from"./chunk-3ZWDIEEM.js";import{a as e}from"./chunk-P37U34EQ.js";import{useMutation as C,useQuery as r}from"@tanstack/react-query";import{createHeadlessForm as y,modify as g}from"@remoteoss/json-schema-form";var q=e(({includePremiumBenefits:t})=>{let{client:i}=s();return r({queryKey:["cost-calculator-countries",t],queryFn:e(()=>c({client:i,query:{include_premium_benefits:t}}),"queryFn"),select:e(o=>o.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"),x=e(()=>{let{client:t}=s();return r({queryKey:["company-currencies"],queryFn:e(()=>d({client:t}),"queryFn"),select:e(i=>i.data?.data?.company_currencies.map(o=>({value:o.slug,label:o.code})),"select")})},"useCompanyCurrencies"),P=e(()=>{let{client:t}=s();return C({mutationFn:e(i=>l({client:t,body:i}),"mutationFn")})},"useCostCalculatorEstimation"),M=e(()=>{let{client:t}=s();return C({mutationFn:e(i=>u({client:t,body:i}),"mutationFn")})},"useCostCalculatorEstimationPdf"),S=e((t,{includePremiumBenefits:i,options:o})=>{let{client:n}=s();return r({queryKey:["cost-calculator-region-fields",t,i],queryFn:e(()=>m({client:n,path:{slug:t},query:{include_premium_benefits:i}}),"queryFn"),enabled:!!t,select:e(({data:f})=>{let a=f?.data?.schema||{};if(o&&o.jsfModify){let{schema:p}=g(a,o.jsfModify);a=p}return y(a)},"select")})},"useRegionFields");export{q as a,x as b,P as c,M as d,S as e};
|
|
2
|
+
//# sourceMappingURL=chunk-V2YORDAL.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/flows/CostCalculator/api.ts"],"sourcesContent":["import {\n CostCalculatorEstimateParams,\n getIndexCompanyCurrency,\n getIndexCountry,\n getShowRegionField,\n postCreateEstimation,\n postCreateEstimationPdf,\n} from '@/src/client';\nimport { Client } from '@hey-api/client-fetch';\nimport { useClient } from '@/src/context';\nimport { useMutation, useQuery } from '@tanstack/react-query';\nimport { CostCalculatorEstimationOptions } from '@/src/flows/CostCalculator/types';\nimport { JSFModify } from '@/src/flows/types';\nimport { createHeadlessForm, modify } from '@remoteoss/json-schema-form';\n\n/**\n * Hook to fetch the countries for the cost calculator.\n * @returns\n */\nexport const useCostCalculatorCountries = ({\n includePremiumBenefits,\n}: {\n includePremiumBenefits: CostCalculatorEstimationOptions['includePremiumBenefits'];\n}) => {\n const { client } = useClient();\n return useQuery({\n queryKey: ['cost-calculator-countries', includePremiumBenefits],\n queryFn: () => {\n return getIndexCountry({\n client: client as Client,\n query: {\n include_premium_benefits: includePremiumBenefits,\n },\n });\n },\n select: (data) =>\n data.data?.data\n .filter((country) => country.availability === 'active')\n .map((country) => ({\n value: country.region_slug,\n label: country.name,\n childRegions: country.child_regions,\n hasAdditionalFields: country.has_additional_fields,\n regionSlug: country.region_slug,\n currency: country.currency.code,\n })),\n });\n};\n\n/**\n * Hook to fetch the company currencies.\n * @returns\n */\nexport const useCompanyCurrencies = () => {\n const { client } = useClient();\n\n return useQuery({\n queryKey: ['company-currencies'],\n queryFn: () => {\n return getIndexCompanyCurrency({\n client: client as Client,\n });\n },\n select: (data) =>\n data.data?.data?.company_currencies.map((currency) => ({\n value: currency.slug,\n label: currency.code,\n })),\n });\n};\n\n/**\n * Hook to create an estimation.\n * @returns\n */\nexport const useCostCalculatorEstimation = () => {\n const { client } = useClient();\n\n return useMutation({\n mutationFn: (payload: CostCalculatorEstimateParams) => {\n return postCreateEstimation({\n client: client as Client,\n body: payload,\n });\n },\n });\n};\n\n/**\n * Custom hook to create a PDF estimation.\n *\n * @returns\n */\nexport const useCostCalculatorEstimationPdf = () => {\n const { client } = useClient();\n\n return useMutation({\n mutationFn: (payload: CostCalculatorEstimateParams) => {\n return postCreateEstimationPdf({\n client: client as Client,\n body: payload,\n });\n },\n });\n};\n\n/**\n * Hook to fetch the region fields.\n * @param region\n * @returns\n */\nexport const useRegionFields = (\n region: string | undefined,\n {\n includePremiumBenefits,\n options,\n }: {\n includePremiumBenefits: CostCalculatorEstimationOptions['includePremiumBenefits'];\n options?: {\n jsfModify?: JSFModify;\n };\n },\n) => {\n const { client } = useClient();\n\n return useQuery({\n queryKey: ['cost-calculator-region-fields', region, includePremiumBenefits],\n queryFn: () => {\n return getShowRegionField({\n client: client as Client,\n path: { slug: region as string },\n query: {\n include_premium_benefits: includePremiumBenefits,\n },\n });\n },\n enabled: !!region,\n select: ({ data }) => {\n let jsfSchema = data?.data?.schema || {};\n if (options && options.jsfModify) {\n const { schema } = modify(jsfSchema, options.jsfModify);\n jsfSchema = schema;\n }\n return createHeadlessForm(jsfSch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EAAIC,EAAU,EAE7B,OAAOS,EAAY,CACjB,WAAYZ,EAACa,GACJG,EAAwB,CAC7B,OAAQd,EACR,KAAMW,CACR,CAAC,EAJS,aAMd,CAAC,CACH,EAX8C,kCAkBjCI,EAAkBjB,EAAA,CAC7BkB,EACA,CACE,uBAAAjB,EACA,QAAAkB,CACF,IAMG,CACH,GAAM,CAAE,OAAAjB,CAAO,EAAIC,EAAU,EAE7B,OAAOC,EAAS,CACd,SAAU,CAAC,gCAAiCc,EAAQjB,CAAsB,EAC1E,QAASD,EAAA,IACAoB,EAAmB,CACxB,OAAQlB,EACR,KAAM,CAAE,KAAMgB,CAAiB,EAC/B,MAAO,CACL,yBAA0BjB,CAC5B,CACF,CAAC,EAPM,WAST,QAAS,CAAC,CAACiB,EACX,OAAQlB,EAAA,CAAC,CAAE,KAAAM,CAAK,IAAM,CACpB,IAAIe,EAAYf,GAAM,MAAM,QAAU,CAAC,EACvC,GAAIa,GAAWA,EAAQ,UAAW,CAChC,GAAM,CAAE,OAAAG,CAAO,EAAIC,EAAOF,EAAWF,EAAQ,SAAS,EACtDE,EAAYC,CACd,CACA,OAAOE,EAAmBH,CAAS,CACrC,EAPQ,SAQV,CAAC,CACH,EAnC+B","names":["useMutation","useQuery","createHeadlessForm","modify","useCostCalculatorCountries","__name","includePremiumBenefits","client","useClient","useQuery","getIndexCountry","data","country","useCompanyCurrencies","getIndexCompanyCurrency","currency","useCostCalculatorEstimation","useMutation","payload","postCreateEstimation","useCostCalculatorEstimationPdf","postCreateEstimationPdf","useRegionFields","region","options","getShowRegionField","jsfSchema","schema","modify","createHeadlessForm"]}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as s}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as s}from"./chunk-HBQDXOAG.js";import{b as t}from"./chunk-PGWKJ6FK.js";import{b as e}from"./chunk-QW4JPW6J.js";import{a as i}from"./chunk-P37U34EQ.js";import{jsx as c}from"react/jsx-runtime";function S({onSubmit:m,onSuccess:d,onError:a}){let{onboardingBag:o}=t(),l=i(async n=>{try{await m?.(o.parseFormValues(n));let r=await o.onSubmit(n);if(r?.data){await d?.(r?.data),o?.next();return}if(r?.error){let p=e(r?.fieldErrors||[],o.meta?.fields?.basic_information);a?.({error:r?.error,rawError:r?.rawError,fieldErrors:p})}}catch(r){a?.({error:r,rawError:r,fieldErrors:[]})}},"handleSubmit"),f=o.stepState.values?.basic_information||o.initialValues.basic_information;return c(s,{defaultValues:f,onSubmit:l})}i(S,"BasicInformationStep");export{S as a};
|
|
2
|
+
//# sourceMappingURL=chunk-ZZOY6KD4.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import { b as PostCreateContractAmendmentError, a as ContractAmendmentResponse } from '../../types.gen-
|
|
2
|
+
import { b as PostCreateContractAmendmentError, a as ContractAmendmentResponse } from '../../types.gen-CaXCWhlP.js';
|
|
3
3
|
import { FieldValues } from 'react-hook-form';
|
|
4
4
|
|
|
5
5
|
type ContractAmendmentConfirmationFormProps = {
|
|
@@ -5,7 +5,7 @@ import { ContractAmendmentForm } from './ContractAmendmentForm.js';
|
|
|
5
5
|
import { ContractAmendmentSubmit } from './ContractAmendmentSubmit.js';
|
|
6
6
|
import { useContractAmendment } from './hooks.js';
|
|
7
7
|
import { ContractAmendmentParams } from './types.js';
|
|
8
|
-
import '../../types.gen-
|
|
8
|
+
import '../../types.gen-CaXCWhlP.js';
|
|
9
9
|
import 'react-hook-form';
|
|
10
10
|
import 'react';
|
|
11
11
|
import '../../mutations-B6HWH-rZ.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import { P as PostAutomatableContractAmendmentError, C as ContractAmendmentAutomatableResponse } from '../../types.gen-
|
|
2
|
+
import { P as PostAutomatableContractAmendmentError, C as ContractAmendmentAutomatableResponse } from '../../types.gen-CaXCWhlP.js';
|
|
3
3
|
import { FieldValues } from 'react-hook-form';
|
|
4
4
|
|
|
5
5
|
type ContractAmendmentFormProps = {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { S as SuccessResponse, E as ErrorResponse } from '../../mutations-B6HWH-rZ.js';
|
|
2
|
-
import { C as ContractAmendmentAutomatableResponse, P as PostAutomatableContractAmendmentError, a as ContractAmendmentResponse, b as PostCreateContractAmendmentError } from '../../types.gen-
|
|
2
|
+
import { C as ContractAmendmentAutomatableResponse, P as PostAutomatableContractAmendmentError, a as ContractAmendmentResponse, b as PostCreateContractAmendmentError } from '../../types.gen-CaXCWhlP.js';
|
|
3
3
|
import * as React from 'react';
|
|
4
4
|
import * as _remoteoss_json_schema_form from '@remoteoss/json-schema-form';
|
|
5
|
-
import '../../remoteFlows-
|
|
5
|
+
import '../../remoteFlows-CBNrcwGZ.js';
|
|
6
6
|
import * as react_hook_form from 'react-hook-form';
|
|
7
7
|
import { useContractAmendment } from './hooks.js';
|
|
8
8
|
import { Step } from '../useStepState.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { S as SuccessResponse, E as ErrorResponse } from '../../mutations-B6HWH-rZ.js';
|
|
2
|
-
import { C as ContractAmendmentAutomatableResponse, P as PostAutomatableContractAmendmentError, a as ContractAmendmentResponse, b as PostCreateContractAmendmentError } from '../../types.gen-
|
|
2
|
+
import { C as ContractAmendmentAutomatableResponse, P as PostAutomatableContractAmendmentError, a as ContractAmendmentResponse, b as PostCreateContractAmendmentError } from '../../types.gen-CaXCWhlP.js';
|
|
3
3
|
import * as React from 'react';
|
|
4
4
|
import * as _remoteoss_json_schema_form from '@remoteoss/json-schema-form';
|
|
5
5
|
import { Step } from '../useStepState.js';
|
|
@@ -4,7 +4,7 @@ export { ContractAmendmentForm } from './ContractAmendmentForm.js';
|
|
|
4
4
|
export { ContractAmendmentSubmit } from './ContractAmendmentSubmit.js';
|
|
5
5
|
export { useContractAmendment } from './hooks.js';
|
|
6
6
|
import 'react/jsx-runtime';
|
|
7
|
-
import '../../types.gen-
|
|
7
|
+
import '../../types.gen-CaXCWhlP.js';
|
|
8
8
|
import 'react-hook-form';
|
|
9
9
|
import './ContractAmendmentBack.js';
|
|
10
10
|
import 'react';
|
|
@@ -3,7 +3,7 @@ import React__default from 'react';
|
|
|
3
3
|
import { useCostCalculator, CostCalculatorVersion } from './hooks.js';
|
|
4
4
|
import { CostCalculatorEstimationOptions, UseCostCalculatorOptions } from './types.js';
|
|
5
5
|
import 'yup';
|
|
6
|
-
import '../../types.gen-
|
|
6
|
+
import '../../types.gen-CaXCWhlP.js';
|
|
7
7
|
import '../types.js';
|
|
8
8
|
import '@remoteoss/json-schema-form';
|
|
9
9
|
import './constants.js';
|
|
@@ -29,6 +29,10 @@ type CostCalculatorFlowProps = {
|
|
|
29
29
|
* Default value for the salary field.
|
|
30
30
|
*/
|
|
31
31
|
salary: string;
|
|
32
|
+
/**
|
|
33
|
+
* Default value for the benefits field.
|
|
34
|
+
*/
|
|
35
|
+
benefits: Record<string, string>;
|
|
32
36
|
}>;
|
|
33
37
|
options?: UseCostCalculatorOptions;
|
|
34
38
|
render: (costCalculatorBag: ReturnType<typeof useCostCalculator>) => React__default.ReactNode;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../chunk-
|
|
1
|
+
import{a}from"../../chunk-IEYBG2G5.js";import"../../chunk-34JNRT23.js";import"../../chunk-JUGNVM2R.js";import"../../chunk-NBCZF2FO.js";import"../../chunk-IHPLMALI.js";import"../../chunk-JQDP6SAT.js";import"../../chunk-DTGFQMCE.js";import"../../chunk-WVJDCDGZ.js";import"../../chunk-V2YORDAL.js";import"../../chunk-HN5HLFTB.js";import"../../chunk-KSHK3ZPX.js";import"../../chunk-N5I33LIN.js";import"../../chunk-ANXYPRBG.js";import"../../chunk-Z5WMKCRJ.js";import"../../chunk-CFIJKJXD.js";import"../../chunk-ZTDKPUB5.js";import"../../chunk-TXSJL3HC.js";import"../../chunk-EGQJ7UBR.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-3BREUYLG.js";import"../../chunk-MXFDOIUA.js";import"../../chunk-BI6U55BD.js";import"../../chunk-3LOVCTCN.js";import"../../chunk-P37U34EQ.js";export{a as CostCalculatorFlow};
|
|
2
2
|
//# sourceMappingURL=CostCalculatorFlow.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
2
|
+
import { CostCalculatorEstimationSubmitValues, CostCalculatorEstimationResponse, EstimationError } from './types.js';
|
|
3
|
+
import '../../types.gen-CaXCWhlP.js';
|
|
4
4
|
import './constants.js';
|
|
5
5
|
import '../types.js';
|
|
6
6
|
import '@remoteoss/json-schema-form';
|
|
@@ -15,7 +15,7 @@ type CostCalculatorFormProps = Partial<{
|
|
|
15
15
|
* Callback function to handle the success when the estimation succeeds. The CostCalculatorEstimateResponse is sent back to you.
|
|
16
16
|
* @param data - The response data from the /cost-calculator/estimation endpoint.
|
|
17
17
|
*/
|
|
18
|
-
onSuccess: (data:
|
|
18
|
+
onSuccess: (data: CostCalculatorEstimationResponse) => Promise<void> | void;
|
|
19
19
|
/**
|
|
20
20
|
* Callback function to handle the error when the estimation fails.
|
|
21
21
|
* @param error - The error object.
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../chunk-
|
|
1
|
+
import{a}from"../../chunk-QURYMQUD.js";import"../../chunk-KSHK3ZPX.js";import"../../chunk-LK4XMOCE.js";import"../../chunk-ZTDKPUB5.js";import"../../chunk-KHNAQRGE.js";import"../../chunk-GP237GUO.js";import"../../chunk-TXSJL3HC.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-7VUILYZ3.js";import"../../chunk-3BREUYLG.js";import"../../chunk-MXFDOIUA.js";import"../../chunk-BI6U55BD.js";import"../../chunk-3LOVCTCN.js";import"../../chunk-P37U34EQ.js";export{a as CostCalculatorForm};
|
|
2
2
|
//# sourceMappingURL=CostCalculatorForm.js.map
|
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import {
|
|
2
|
+
import { A as MinimalCountry, M as MinimalRegion } from '../../../types.gen-CaXCWhlP.js';
|
|
3
|
+
import { CostCalculatorEstimation } from '../types.js';
|
|
4
|
+
import '../constants.js';
|
|
5
|
+
import '../../types.js';
|
|
6
|
+
import '@remoteoss/json-schema-form';
|
|
3
7
|
|
|
4
8
|
interface OnboardingTimelineStep {
|
|
5
9
|
title: string;
|
|
@@ -31,12 +35,13 @@ type EstimationResultsComponents = {
|
|
|
31
35
|
Footer?: React.ComponentType;
|
|
32
36
|
};
|
|
33
37
|
type EstimationResultsProps = {
|
|
34
|
-
estimation:
|
|
38
|
+
estimation: CostCalculatorEstimation;
|
|
35
39
|
title: string;
|
|
36
40
|
components?: EstimationResultsComponents;
|
|
37
41
|
onDelete: () => void;
|
|
38
42
|
onExportPdf: () => void;
|
|
43
|
+
onEdit: () => void;
|
|
39
44
|
};
|
|
40
|
-
declare const EstimationResults: ({ estimation, title, components, onDelete, onExportPdf, }: EstimationResultsProps) => react_jsx_runtime.JSX.Element;
|
|
45
|
+
declare const EstimationResults: ({ estimation, title, components, onDelete, onExportPdf, onEdit, }: EstimationResultsProps) => react_jsx_runtime.JSX.Element;
|
|
41
46
|
|
|
42
47
|
export { EstimationResults };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../../chunk-
|
|
1
|
+
import{a}from"../../../chunk-HVTGLVLT.js";import"../../../chunk-4RULC3AZ.js";import"../../../chunk-ZE3YT3Q6.js";import"../../../chunk-NBCZF2FO.js";import"../../../chunk-UHS3QRA3.js";import"../../../chunk-N5I33LIN.js";import"../../../chunk-ANXYPRBG.js";import"../../../chunk-EGQJ7UBR.js";import"../../../chunk-3ZWDIEEM.js";import"../../../chunk-7VUILYZ3.js";import"../../../chunk-3LOVCTCN.js";import"../../../chunk-P37U34EQ.js";export{a as EstimationResults};
|
|
2
2
|
//# sourceMappingURL=EstimationResults.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import { c as CostCalculatorEstimateResponse } from '../../../types.gen-
|
|
2
|
+
import { c as CostCalculatorEstimateResponse } from '../../../types.gen-CaXCWhlP.js';
|
|
3
3
|
|
|
4
4
|
interface CostCalculatorResultProps {
|
|
5
5
|
employmentData: CostCalculatorEstimateResponse['data'];
|
|
@@ -1,12 +1,16 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import {
|
|
2
|
+
import { CostCalculatorEstimation } from '../types.js';
|
|
3
|
+
import '../../../types.gen-CaXCWhlP.js';
|
|
4
|
+
import '../constants.js';
|
|
5
|
+
import '../../types.js';
|
|
6
|
+
import '@remoteoss/json-schema-form';
|
|
3
7
|
|
|
4
8
|
type SummaryResultsProps = {
|
|
5
9
|
/**
|
|
6
10
|
* Array of employments to compare costs for.
|
|
7
11
|
* 2 estimations required for the component to render
|
|
8
12
|
*/
|
|
9
|
-
estimations:
|
|
13
|
+
estimations: CostCalculatorEstimation[];
|
|
10
14
|
};
|
|
11
15
|
/**
|
|
12
16
|
* Displays a summary comparison of costs across multiple estimations.
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../../chunk-
|
|
1
|
+
import{a}from"../../../chunk-R2UI3WAJ.js";import"../../../chunk-4RULC3AZ.js";import"../../../chunk-UHS3QRA3.js";import"../../../chunk-3LOVCTCN.js";import"../../../chunk-P37U34EQ.js";export{a as SummaryResults};
|
|
2
2
|
//# sourceMappingURL=SummaryResults.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as _remoteoss_json_schema_form from '@remoteoss/json-schema-form';
|
|
2
2
|
import * as _tanstack_react_query from '@tanstack/react-query';
|
|
3
|
-
import { d as CostCalculatorEstimatePdfResponse, e as PostCreateEstimationPdfError, f as CostCalculatorEstimateParams, M as MinimalRegion, c as CostCalculatorEstimateResponse, g as PostCreateEstimationError } from '../../types.gen-
|
|
3
|
+
import { d as CostCalculatorEstimatePdfResponse, e as PostCreateEstimationPdfError, f as CostCalculatorEstimateParams, M as MinimalRegion, c as CostCalculatorEstimateResponse, g as PostCreateEstimationError } from '../../types.gen-CaXCWhlP.js';
|
|
4
4
|
import { CostCalculatorEstimationOptions } from './types.js';
|
|
5
5
|
import { JSFModify } from '../types.js';
|
|
6
6
|
import './constants.js';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a,b,c,d,e}from"../../chunk-
|
|
1
|
+
import{a,b,c,d,e}from"../../chunk-V2YORDAL.js";import"../../chunk-EGQJ7UBR.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-P37U34EQ.js";export{b as useCompanyCurrencies,a as useCostCalculatorCountries,c as useCostCalculatorEstimation,d as useCostCalculatorEstimationPdf,e as useRegionFields};
|
|
2
2
|
//# sourceMappingURL=api.js.map
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import { a as JSFField } from '../../../remoteFlows-
|
|
2
|
+
import { a as JSFField } from '../../../remoteFlows-CBNrcwGZ.js';
|
|
3
3
|
import 'react-hook-form';
|
|
4
4
|
import 'react';
|
|
5
5
|
import 'yup';
|
|
6
|
-
import '../../../types.gen-
|
|
6
|
+
import '../../../types.gen-CaXCWhlP.js';
|
|
7
7
|
import '../../../types-Zg1n_9wh.js';
|
|
8
8
|
|
|
9
9
|
type SalaryFieldProps = JSFField & {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../../chunk-
|
|
1
|
+
import{a}from"../../../chunk-JUGNVM2R.js";import"../../../chunk-NBCZF2FO.js";import"../../../chunk-JQDP6SAT.js";import"../../../chunk-DTGFQMCE.js";import"../../../chunk-WVJDCDGZ.js";import"../../../chunk-N5I33LIN.js";import"../../../chunk-ANXYPRBG.js";import"../../../chunk-Z5WMKCRJ.js";import"../../../chunk-ZTDKPUB5.js";import"../../../chunk-TXSJL3HC.js";import"../../../chunk-EGQJ7UBR.js";import"../../../chunk-3ZWDIEEM.js";import"../../../chunk-3BREUYLG.js";import"../../../chunk-MXFDOIUA.js";import"../../../chunk-BI6U55BD.js";import"../../../chunk-3LOVCTCN.js";import"../../../chunk-P37U34EQ.js";export{a as SalaryField};
|
|
2
2
|
//# sourceMappingURL=SalaryField.js.map
|
|
@@ -2,8 +2,8 @@ import { Result } from '../types.js';
|
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import { useCostCalculator } from './hooks.js';
|
|
4
4
|
import { CostCalculatorEstimationFormValues, CostCalculatorEstimationSubmitValues, EstimationError } from './types.js';
|
|
5
|
-
import { c as CostCalculatorEstimateResponse } from '../../types.gen-
|
|
6
|
-
import { $ as $TSFixMe } from '../../remoteFlows-
|
|
5
|
+
import { c as CostCalculatorEstimateResponse } from '../../types.gen-CaXCWhlP.js';
|
|
6
|
+
import { $ as $TSFixMe } from '../../remoteFlows-CBNrcwGZ.js';
|
|
7
7
|
import * as yup from 'yup';
|
|
8
8
|
import { UseFormReturn } from 'react-hook-form';
|
|
9
9
|
import '@remoteoss/json-schema-form';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as yup from 'yup';
|
|
2
2
|
import { ValidationError } from 'yup';
|
|
3
|
-
import { c as CostCalculatorEstimateResponse } from '../../types.gen-
|
|
3
|
+
import { c as CostCalculatorEstimateResponse } from '../../types.gen-CaXCWhlP.js';
|
|
4
4
|
import { CostCalculatorEstimationOptions, UseCostCalculatorOptions, CostCalculatorEstimationFormValues, CostCalculatorEstimationSubmitValues, EstimationError } from './types.js';
|
|
5
5
|
import { Result } from '../types.js';
|
|
6
6
|
import './constants.js';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{c as a,d as b}from"../../chunk-
|
|
1
|
+
import{c as a,d as b}from"../../chunk-34JNRT23.js";import"../../chunk-JUGNVM2R.js";import"../../chunk-NBCZF2FO.js";import"../../chunk-IHPLMALI.js";import"../../chunk-JQDP6SAT.js";import"../../chunk-DTGFQMCE.js";import"../../chunk-WVJDCDGZ.js";import"../../chunk-V2YORDAL.js";import"../../chunk-HN5HLFTB.js";import"../../chunk-N5I33LIN.js";import"../../chunk-ANXYPRBG.js";import"../../chunk-Z5WMKCRJ.js";import"../../chunk-CFIJKJXD.js";import"../../chunk-ZTDKPUB5.js";import"../../chunk-TXSJL3HC.js";import"../../chunk-EGQJ7UBR.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-3BREUYLG.js";import"../../chunk-MXFDOIUA.js";import"../../chunk-BI6U55BD.js";import"../../chunk-3LOVCTCN.js";import"../../chunk-P37U34EQ.js";export{a as defaultEstimationOptions,b as useCostCalculator};
|
|
2
2
|
//# sourceMappingURL=hooks.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { CostCalculatorFlow } from './CostCalculatorFlow.js';
|
|
1
|
+
export { CostCalculatorFlow, CostCalculatorFlowProps } from './CostCalculatorFlow.js';
|
|
2
2
|
export { CostCalculatorForm } from './CostCalculatorForm.js';
|
|
3
3
|
export { CostCalculatorSubmitButton } from './CostCalculatorSubmitButton.js';
|
|
4
4
|
export { CostCalculatorResetButton } from './CostCalculatorResetButton.js';
|
|
@@ -13,12 +13,12 @@ export { buildPayload as buildCostCalculatorEstimationPayload } from './utils.js
|
|
|
13
13
|
export { EstimationError } from './types.js';
|
|
14
14
|
import 'react/jsx-runtime';
|
|
15
15
|
import 'react';
|
|
16
|
-
import '../../types.gen-C9Y1S1pc.js';
|
|
17
16
|
import 'yup';
|
|
17
|
+
import '../../types.gen-CaXCWhlP.js';
|
|
18
18
|
import '../types.js';
|
|
19
19
|
import '@remoteoss/json-schema-form';
|
|
20
20
|
import '@tanstack/react-query';
|
|
21
|
-
import '../../remoteFlows-
|
|
21
|
+
import '../../remoteFlows-CBNrcwGZ.js';
|
|
22
22
|
import 'react-hook-form';
|
|
23
23
|
import '../../types-Zg1n_9wh.js';
|
|
24
24
|
import './constants.js';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import"../../chunk-Z3BMF4BO.js";import{a as l}from"../../chunk-MLB2I27G.js";import"../../chunk-E5YN6OT3.js";import{a as k}from"../../chunk-
|
|
1
|
+
import"../../chunk-Z3BMF4BO.js";import{a as l}from"../../chunk-MLB2I27G.js";import"../../chunk-E5YN6OT3.js";import{a as k}from"../../chunk-R2UI3WAJ.js";import{a as j}from"../../chunk-HVTGLVLT.js";import"../../chunk-4RULC3AZ.js";import"../../chunk-H4KE45NG.js";import"../../chunk-6NKUEDYP.js";import"../../chunk-I2A4EFDY.js";import"../../chunk-4R3ITKOA.js";import"../../chunk-ZE3YT3Q6.js";import"../../chunk-NVMZDPMF.js";import"../../chunk-XJVYASHX.js";import{a as d}from"../../chunk-IEYBG2G5.js";import{b as a,d as c}from"../../chunk-34JNRT23.js";import"../../chunk-JUGNVM2R.js";import"../../chunk-NBCZF2FO.js";import"../../chunk-IHPLMALI.js";import"../../chunk-JQDP6SAT.js";import"../../chunk-DTGFQMCE.js";import"../../chunk-WVJDCDGZ.js";import{a as e}from"../../chunk-QURYMQUD.js";import{a as g}from"../../chunk-OZ63OC3N.js";import{a as f}from"../../chunk-A4KEKMEQ.js";import{d as b}from"../../chunk-V2YORDAL.js";import"../../chunk-HN5HLFTB.js";import"../../chunk-KSHK3ZPX.js";import{a as i}from"../../chunk-HQI6W7PR.js";import{a as h}from"../../chunk-DYB3RWP7.js";import"../../chunk-CRXPRR3R.js";import"../../chunk-UHS3QRA3.js";import"../../chunk-N5I33LIN.js";import"../../chunk-LBUNJ5J3.js";import"../../chunk-ANXYPRBG.js";import"../../chunk-Z5WMKCRJ.js";import"../../chunk-CFIJKJXD.js";import"../../chunk-LK4XMOCE.js";import"../../chunk-ZTDKPUB5.js";import"../../chunk-KHNAQRGE.js";import"../../chunk-GP237GUO.js";import"../../chunk-TXSJL3HC.js";import"../../chunk-EGQJ7UBR.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-7VUILYZ3.js";import"../../chunk-3BREUYLG.js";import"../../chunk-MXFDOIUA.js";import"../../chunk-BI6U55BD.js";import"../../chunk-3LOVCTCN.js";import"../../chunk-P37U34EQ.js";export{i as CostCalculatorDisclaimer,d as CostCalculatorFlow,e as CostCalculatorForm,g as CostCalculatorResetButton,l as CostCalculatorResults,f as CostCalculatorSubmitButton,j as EstimationResults,k as SummaryResults,a as buildCostCalculatorEstimationPayload,h as disclaimerData,c as useCostCalculator,b as useCostCalculatorEstimationPdf};
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -31,6 +31,18 @@ declare const jsonSchema: {
|
|
|
31
31
|
inputType: string;
|
|
32
32
|
};
|
|
33
33
|
};
|
|
34
|
+
hiring_budget: {
|
|
35
|
+
title: string;
|
|
36
|
+
enum: string[];
|
|
37
|
+
type: string;
|
|
38
|
+
oneOf: {
|
|
39
|
+
title: string;
|
|
40
|
+
const: string;
|
|
41
|
+
}[];
|
|
42
|
+
'x-jsf-presentation': {
|
|
43
|
+
inputType: string;
|
|
44
|
+
};
|
|
45
|
+
};
|
|
34
46
|
salary: {
|
|
35
47
|
description: string;
|
|
36
48
|
title: string;
|
|
@@ -39,6 +51,15 @@ declare const jsonSchema: {
|
|
|
39
51
|
inputType: string;
|
|
40
52
|
};
|
|
41
53
|
};
|
|
54
|
+
estimation_title: {
|
|
55
|
+
title: string;
|
|
56
|
+
description: string;
|
|
57
|
+
type: string;
|
|
58
|
+
'x-jsf-presentation': {
|
|
59
|
+
inputType: string;
|
|
60
|
+
hidden: boolean;
|
|
61
|
+
};
|
|
62
|
+
};
|
|
42
63
|
salary_conversion: {
|
|
43
64
|
description: string;
|
|
44
65
|
title: string;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../chunk-
|
|
1
|
+
import{a}from"../../chunk-IHPLMALI.js";import"../../chunk-P37U34EQ.js";export{a as jsonSchema};
|
|
2
2
|
//# sourceMappingURL=jsonSchema.js.map
|