@remoteoss/remote-flows 0.12.0 → 0.14.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.
Files changed (279) hide show
  1. package/README.md +3 -3
  2. package/dist/{chunk-GAOBYAJE.js → chunk-3BREUYLG.js} +2 -2
  3. package/dist/{chunk-GAOBYAJE.js.map → chunk-3BREUYLG.js.map} +1 -1
  4. package/dist/{chunk-LT4ALDRM.js → chunk-4R3ITKOA.js} +2 -2
  5. package/dist/chunk-4R3ITKOA.js.map +1 -0
  6. package/dist/{chunk-T3L72MV6.js → chunk-4RULC3AZ.js} +1 -1
  7. package/dist/chunk-4RULC3AZ.js.map +1 -0
  8. package/dist/chunk-4XFRZVAL.js +2 -0
  9. package/dist/{chunk-DVQO5MHI.js.map → chunk-4XFRZVAL.js.map} +1 -1
  10. package/dist/{chunk-SEAC3H45.js → chunk-5EDFVFNU.js} +2 -2
  11. package/dist/chunk-5EDFVFNU.js.map +1 -0
  12. package/dist/{chunk-7TOZZQQJ.js → chunk-5KHLOGTR.js} +1 -1
  13. package/dist/{chunk-7TOZZQQJ.js.map → chunk-5KHLOGTR.js.map} +1 -1
  14. package/dist/{chunk-EE54SK65.js → chunk-63HVO7J5.js} +2 -2
  15. package/dist/{chunk-7TIIT23F.js → chunk-6NKUEDYP.js} +2 -2
  16. package/dist/chunk-6NKUEDYP.js.map +1 -0
  17. package/dist/{chunk-NPZ5QJSG.js → chunk-6YKL7EOK.js} +2 -2
  18. package/dist/chunk-6YKL7EOK.js.map +1 -0
  19. package/dist/{chunk-2AUKMWRF.js → chunk-6YN2XQWR.js} +2 -2
  20. package/dist/{chunk-LIGRV2J5.js → chunk-7JQPHRUK.js} +2 -2
  21. package/dist/{chunk-GBD3OCAW.js → chunk-7P5B6XHM.js} +2 -2
  22. package/dist/{chunk-CSK44J23.js → chunk-7VUILYZ3.js} +1 -1
  23. package/dist/{chunk-CSK44J23.js.map → chunk-7VUILYZ3.js.map} +1 -1
  24. package/dist/{chunk-52NPLMW3.js → chunk-A3OEOVEH.js} +2 -2
  25. package/dist/chunk-A3OEOVEH.js.map +1 -0
  26. package/dist/{chunk-SQICIS7B.js → chunk-A4KEKMEQ.js} +2 -2
  27. package/dist/{chunk-SQICIS7B.js.map → chunk-A4KEKMEQ.js.map} +1 -1
  28. package/dist/{chunk-77AF2QOD.js → chunk-ANXYPRBG.js} +1 -1
  29. package/dist/chunk-ANXYPRBG.js.map +1 -0
  30. package/dist/{chunk-BY5S6EQJ.js → chunk-ARKAW4ZP.js} +2 -2
  31. package/dist/{chunk-EW24LQRE.js → chunk-BI6U55BD.js} +1 -1
  32. package/dist/chunk-BI6U55BD.js.map +1 -0
  33. package/dist/{chunk-GCVZ4AY2.js → chunk-CRXPRR3R.js} +1 -1
  34. package/dist/chunk-CRXPRR3R.js.map +1 -0
  35. package/dist/{chunk-ZSBWDLBS.js → chunk-DCRLPAJL.js} +2 -2
  36. package/dist/{chunk-EOJJ4IWJ.js → chunk-DXABU6DZ.js} +2 -2
  37. package/dist/{chunk-BDZEPXIS.js → chunk-E5YN6OT3.js} +1 -1
  38. package/dist/chunk-E5YN6OT3.js.map +1 -0
  39. package/dist/{chunk-LLY7VPXS.js → chunk-F3BSJIHU.js} +2 -2
  40. package/dist/{chunk-JKYTL5QY.js → chunk-GBN2V7QZ.js} +2 -2
  41. package/dist/chunk-GBN2V7QZ.js.map +1 -0
  42. package/dist/{chunk-G7WJUXZU.js → chunk-GP237GUO.js} +1 -1
  43. package/dist/{chunk-G7WJUXZU.js.map → chunk-GP237GUO.js.map} +1 -1
  44. package/dist/{chunk-QI6LLU2N.js → chunk-H4KE45NG.js} +2 -2
  45. package/dist/chunk-H4KE45NG.js.map +1 -0
  46. package/dist/{chunk-N7PSO5ZD.js → chunk-HEKQK6TK.js} +2 -2
  47. package/dist/{chunk-N7PSO5ZD.js.map → chunk-HEKQK6TK.js.map} +1 -1
  48. package/dist/chunk-HN5HLFTB.js +2 -0
  49. package/dist/chunk-HN5HLFTB.js.map +1 -0
  50. package/dist/chunk-HQI6W7PR.js +2 -0
  51. package/dist/chunk-HQI6W7PR.js.map +1 -0
  52. package/dist/chunk-HSW5HMHH.js +2 -0
  53. package/dist/{chunk-ZHL2SULA.js → chunk-I2A4EFDY.js} +2 -2
  54. package/dist/chunk-I2A4EFDY.js.map +1 -0
  55. package/dist/{chunk-R7L6CI5J.js → chunk-ITSQE6EW.js} +2 -2
  56. package/dist/{chunk-VUQOVQ5L.js → chunk-J4GIUQ4E.js} +2 -2
  57. package/dist/chunk-J4GIUQ4E.js.map +1 -0
  58. package/dist/{chunk-DOILOCWU.js → chunk-JI5BE2MZ.js} +2 -2
  59. package/dist/{chunk-DOILOCWU.js.map → chunk-JI5BE2MZ.js.map} +1 -1
  60. package/dist/{chunk-JUM2HAIK.js → chunk-JJHGVDPO.js} +2 -2
  61. package/dist/{chunk-XI3AQ3RM.js → chunk-KHNAQRGE.js} +1 -1
  62. package/dist/chunk-KHNAQRGE.js.map +1 -0
  63. package/dist/chunk-LBUNJ5J3.js +2 -0
  64. package/dist/chunk-LBUNJ5J3.js.map +1 -0
  65. package/dist/chunk-LK4XMOCE.js +2 -0
  66. package/dist/chunk-LK4XMOCE.js.map +1 -0
  67. package/dist/chunk-LPFDPXCW.js +2 -0
  68. package/dist/chunk-LPFDPXCW.js.map +1 -0
  69. package/dist/{chunk-GJQ33XQ4.js → chunk-MLB2I27G.js} +2 -2
  70. package/dist/chunk-MLB2I27G.js.map +1 -0
  71. package/dist/{chunk-2JWANM25.js → chunk-MYB6Y5FC.js} +2 -2
  72. package/dist/chunk-N5I33LIN.js +2 -0
  73. package/dist/chunk-N5I33LIN.js.map +1 -0
  74. package/dist/{chunk-SFZSHBWM.js → chunk-N7QHEESE.js} +2 -2
  75. package/dist/{chunk-SJHGFMVF.js → chunk-NH4EITYM.js} +2 -2
  76. package/dist/{chunk-CS3U6LJU.js → chunk-NQCSU6FR.js} +2 -2
  77. package/dist/{chunk-WYXN7WW6.js → chunk-NVMZDPMF.js} +2 -2
  78. package/dist/chunk-NVMZDPMF.js.map +1 -0
  79. package/dist/{chunk-ZMENI53L.js → chunk-NVQBJCNL.js} +2 -2
  80. package/dist/{chunk-ZMENI53L.js.map → chunk-NVQBJCNL.js.map} +1 -1
  81. package/dist/{chunk-Y22Q3UYU.js → chunk-OPCY3UYH.js} +2 -2
  82. package/dist/{chunk-GK3OO5SX.js → chunk-OZ63OC3N.js} +2 -2
  83. package/dist/chunk-OZ63OC3N.js.map +1 -0
  84. package/dist/{chunk-J2SFMADD.js → chunk-QDYQEQ3C.js} +2 -2
  85. package/dist/chunk-QYJQNWPB.js +2 -0
  86. package/dist/chunk-QYJQNWPB.js.map +1 -0
  87. package/dist/{chunk-3F7QLHMP.js → chunk-RXVVLN7R.js} +2 -2
  88. package/dist/{chunk-CHSULXMN.js → chunk-TXSJL3HC.js} +1 -1
  89. package/dist/chunk-TXSJL3HC.js.map +1 -0
  90. package/dist/{chunk-5I6VWJSC.js → chunk-UHS3QRA3.js} +1 -1
  91. package/dist/chunk-UHS3QRA3.js.map +1 -0
  92. package/dist/{chunk-2A5R3YN2.js → chunk-VAIBLWOY.js} +1 -1
  93. package/dist/chunk-VAIBLWOY.js.map +1 -0
  94. package/dist/{chunk-R2SDR47E.js → chunk-XCZYKOZU.js} +2 -2
  95. package/dist/{chunk-4OEBYZLZ.js → chunk-XGEKV3FC.js} +2 -2
  96. package/dist/{chunk-MDSGLUUB.js → chunk-XJVYASHX.js} +1 -1
  97. package/dist/chunk-XJVYASHX.js.map +1 -0
  98. package/dist/chunk-XZRGLKXU.js +2 -0
  99. package/dist/{chunk-CSLZUVU4.js.map → chunk-XZRGLKXU.js.map} +1 -1
  100. package/dist/{chunk-AXU5ZCUE.js → chunk-ZCYSBG7R.js} +2 -2
  101. package/dist/chunk-ZD644MH3.js +2 -0
  102. package/dist/chunk-ZD644MH3.js.map +1 -0
  103. package/dist/{chunk-ILMVHOL2.js → chunk-ZE3YT3Q6.js} +1 -1
  104. package/dist/chunk-ZE3YT3Q6.js.map +1 -0
  105. package/dist/chunk-ZTDKPUB5.js +2 -0
  106. package/dist/chunk-ZTDKPUB5.js.map +1 -0
  107. package/dist/flows/ContractAmendment/ContractAmendmentBack.js +1 -1
  108. package/dist/flows/ContractAmendment/ContractAmendmentConfirmationForm.d.ts +1 -1
  109. package/dist/flows/ContractAmendment/ContractAmendmentConfirmationForm.js +1 -1
  110. package/dist/flows/ContractAmendment/ContractAmendmentFlow.d.ts +1 -1
  111. package/dist/flows/ContractAmendment/ContractAmendmentFlow.js +1 -1
  112. package/dist/flows/ContractAmendment/ContractAmendmentForm.d.ts +1 -1
  113. package/dist/flows/ContractAmendment/ContractAmendmentForm.js +1 -1
  114. package/dist/flows/ContractAmendment/ContractAmendmentSubmit.js +1 -1
  115. package/dist/flows/ContractAmendment/context.d.ts +3 -3
  116. package/dist/flows/ContractAmendment/hooks.d.ts +1 -1
  117. package/dist/flows/ContractAmendment/index.d.ts +1 -1
  118. package/dist/flows/ContractAmendment/index.js +1 -1
  119. package/dist/flows/ContractAmendment/utils.d.ts +1 -1
  120. package/dist/flows/CostCalculator/CostCalculatorDisclaimer.js +1 -1
  121. package/dist/flows/CostCalculator/CostCalculatorFlow.d.ts +3 -2
  122. package/dist/flows/CostCalculator/CostCalculatorFlow.js +1 -1
  123. package/dist/flows/CostCalculator/CostCalculatorForm.d.ts +2 -1
  124. package/dist/flows/CostCalculator/CostCalculatorForm.js +1 -1
  125. package/dist/flows/CostCalculator/CostCalculatorResetButton.js +1 -1
  126. package/dist/flows/CostCalculator/CostCalculatorSubmitButton.js +1 -1
  127. package/dist/flows/CostCalculator/EstimationResults/EstimationResults.d.ts +1 -1
  128. package/dist/flows/CostCalculator/EstimationResults/EstimationResults.js +1 -1
  129. package/dist/flows/CostCalculator/Results/CostCalculatorBenefitsBreakdown.js +1 -1
  130. package/dist/flows/CostCalculator/Results/CostCalculatorContributionsBreakdown.js +1 -1
  131. package/dist/flows/CostCalculator/Results/CostCalculatorExtraStatutoryPaymentsBreakdown.js +1 -1
  132. package/dist/flows/CostCalculator/Results/CostCalculatorGrossSalary.js +1 -1
  133. package/dist/flows/CostCalculator/Results/CostCalculatorIndirectTax.js +1 -1
  134. package/dist/flows/CostCalculator/Results/CostCalculatorResults.d.ts +1 -1
  135. package/dist/flows/CostCalculator/Results/CostCalculatorResults.js +1 -1
  136. package/dist/flows/CostCalculator/Results/CostCalculatorResultsChart.js +1 -1
  137. package/dist/flows/CostCalculator/Results/CostCalculatorResultsChart.js.map +1 -1
  138. package/dist/flows/CostCalculator/Results/CostCalculatorTotalCost.js +1 -1
  139. package/dist/flows/CostCalculator/SummaryResults/SummaryResults.d.ts +1 -1
  140. package/dist/flows/CostCalculator/SummaryResults/SummaryResults.js +1 -1
  141. package/dist/flows/CostCalculator/api.d.ts +2 -1
  142. package/dist/flows/CostCalculator/components/SalaryField.d.ts +3 -2
  143. package/dist/flows/CostCalculator/components/SalaryField.js +1 -1
  144. package/dist/flows/CostCalculator/constants.d.ts +16 -0
  145. package/dist/flows/CostCalculator/constants.js +2 -0
  146. package/dist/flows/CostCalculator/constants.js.map +1 -0
  147. package/dist/flows/CostCalculator/context.d.ts +8 -3
  148. package/dist/flows/CostCalculator/hooks.d.ts +40 -1
  149. package/dist/flows/CostCalculator/hooks.js +1 -1
  150. package/dist/flows/CostCalculator/index.d.ts +3 -2
  151. package/dist/flows/CostCalculator/index.js +1 -1
  152. package/dist/flows/CostCalculator/jsonSchema.d.ts +17 -0
  153. package/dist/flows/CostCalculator/jsonSchema.js +1 -1
  154. package/dist/flows/CostCalculator/types.d.ts +15 -2
  155. package/dist/flows/CostCalculator/utils.d.ts +5 -4
  156. package/dist/flows/CostCalculator/utils.js +1 -1
  157. package/dist/flows/Onboarding/OnboardingFlow.d.ts +2 -2
  158. package/dist/flows/Onboarding/OnboardingFlow.js +1 -1
  159. package/dist/flows/Onboarding/api.d.ts +2 -2
  160. package/dist/flows/Onboarding/components/AnnualGrossSalary.d.ts +3 -2
  161. package/dist/flows/Onboarding/components/AnnualGrossSalary.js +1 -1
  162. package/dist/flows/Onboarding/components/BasicInformationStep.d.ts +1 -1
  163. package/dist/flows/Onboarding/components/BasicInformationStep.js +1 -1
  164. package/dist/flows/Onboarding/components/BenefitsStep.d.ts +3 -3
  165. package/dist/flows/Onboarding/components/BenefitsStep.js +1 -1
  166. package/dist/flows/Onboarding/components/ContractDetailsStep.d.ts +1 -1
  167. package/dist/flows/Onboarding/components/ContractDetailsStep.js +1 -1
  168. package/dist/flows/Onboarding/components/EquityPriceDetails.js +1 -1
  169. package/dist/flows/Onboarding/components/OnboardingBack.js +1 -1
  170. package/dist/flows/Onboarding/components/OnboardingForm.d.ts +3 -3
  171. package/dist/flows/Onboarding/components/OnboardingForm.js +1 -1
  172. package/dist/flows/Onboarding/components/OnboardingInvite.d.ts +1 -1
  173. package/dist/flows/Onboarding/components/OnboardingInvite.js +1 -1
  174. package/dist/flows/Onboarding/components/OnboardingSubmit.js +1 -1
  175. package/dist/flows/Onboarding/components/ReviewStep.d.ts +1 -1
  176. package/dist/flows/Onboarding/components/SaveDraftButton.js +1 -1
  177. package/dist/flows/Onboarding/components/SelectCountryStep.d.ts +1 -1
  178. package/dist/flows/Onboarding/components/SelectCountryStep.js +1 -1
  179. package/dist/flows/Onboarding/context.d.ts +3 -3
  180. package/dist/flows/Onboarding/hooks.d.ts +2 -2
  181. package/dist/flows/Onboarding/hooks.js +1 -1
  182. package/dist/flows/Onboarding/index.d.ts +2 -2
  183. package/dist/flows/Onboarding/index.js +1 -1
  184. package/dist/flows/Onboarding/types.d.ts +1 -1
  185. package/dist/flows/Onboarding/utils.d.ts +1 -1
  186. package/dist/flows/Termination/AdditionalDetailsForm.d.ts +1 -1
  187. package/dist/flows/Termination/AdditionalDetailsForm.js +1 -1
  188. package/dist/flows/Termination/EmployeeComunicationForm.d.ts +1 -1
  189. package/dist/flows/Termination/EmployeeComunicationForm.js +1 -1
  190. package/dist/flows/Termination/PaidTimeOffForm.d.ts +1 -1
  191. package/dist/flows/Termination/PaidTimeOffForm.js +1 -1
  192. package/dist/flows/Termination/TerminationBack.js +1 -1
  193. package/dist/flows/Termination/TerminationDetailsForm.d.ts +1 -1
  194. package/dist/flows/Termination/TerminationDetailsForm.js +1 -1
  195. package/dist/flows/Termination/TerminationFlow.d.ts +1 -1
  196. package/dist/flows/Termination/TerminationFlow.js +1 -1
  197. package/dist/flows/Termination/TerminationForm.d.ts +1 -1
  198. package/dist/flows/Termination/TerminationForm.js +1 -1
  199. package/dist/flows/Termination/TerminationSubmit.js +1 -1
  200. package/dist/flows/Termination/TimeOff.d.ts +1 -1
  201. package/dist/flows/Termination/context.d.ts +3 -3
  202. package/dist/flows/Termination/hooks.d.ts +1 -1
  203. package/dist/flows/Termination/hooks.js +1 -1
  204. package/dist/flows/Termination/index.d.ts +1 -1
  205. package/dist/flows/Termination/index.js +1 -1
  206. package/dist/flows/Termination/json-schemas/schema.js +1 -1
  207. package/dist/flows/Termination/types.d.ts +1 -1
  208. package/dist/index.css +1 -1
  209. package/dist/index.css.map +1 -1
  210. package/dist/index.d.ts +6 -5
  211. package/dist/index.js +1 -1
  212. package/dist/index.js.map +1 -1
  213. package/dist/internals.d.ts +4 -1
  214. package/dist/internals.js +1 -1
  215. package/dist/internals.js.map +1 -1
  216. package/dist/{remoteFlows-Zmw9pCN3.d.ts → remoteFlows-Clat4nYN.d.ts} +13 -2
  217. package/dist/{types.gen-_c0f1E7h.d.ts → types.gen-C9Y1S1pc.d.ts} +22 -1
  218. package/package.json +2 -2
  219. package/dist/chunk-2A5R3YN2.js.map +0 -1
  220. package/dist/chunk-52NPLMW3.js.map +0 -1
  221. package/dist/chunk-5CUF63YR.js +0 -2
  222. package/dist/chunk-5CUF63YR.js.map +0 -1
  223. package/dist/chunk-5I6VWJSC.js.map +0 -1
  224. package/dist/chunk-77AF2QOD.js.map +0 -1
  225. package/dist/chunk-7TIIT23F.js.map +0 -1
  226. package/dist/chunk-BDZEPXIS.js.map +0 -1
  227. package/dist/chunk-CHSULXMN.js.map +0 -1
  228. package/dist/chunk-CSLZUVU4.js +0 -2
  229. package/dist/chunk-DR7VGNO2.js +0 -2
  230. package/dist/chunk-DVQO5MHI.js +0 -2
  231. package/dist/chunk-EW24LQRE.js.map +0 -1
  232. package/dist/chunk-GCVZ4AY2.js.map +0 -1
  233. package/dist/chunk-GJQ33XQ4.js.map +0 -1
  234. package/dist/chunk-GK3OO5SX.js.map +0 -1
  235. package/dist/chunk-ILMVHOL2.js.map +0 -1
  236. package/dist/chunk-JKYTL5QY.js.map +0 -1
  237. package/dist/chunk-LT4ALDRM.js.map +0 -1
  238. package/dist/chunk-MCPVKP6Q.js +0 -2
  239. package/dist/chunk-MCPVKP6Q.js.map +0 -1
  240. package/dist/chunk-MDSGLUUB.js.map +0 -1
  241. package/dist/chunk-NPZ5QJSG.js.map +0 -1
  242. package/dist/chunk-NVJYAX22.js +0 -2
  243. package/dist/chunk-NVJYAX22.js.map +0 -1
  244. package/dist/chunk-P4C2MI7X.js +0 -2
  245. package/dist/chunk-P4C2MI7X.js.map +0 -1
  246. package/dist/chunk-QI6LLU2N.js.map +0 -1
  247. package/dist/chunk-SEAC3H45.js.map +0 -1
  248. package/dist/chunk-SUQURI2J.js +0 -2
  249. package/dist/chunk-SUQURI2J.js.map +0 -1
  250. package/dist/chunk-T3L72MV6.js.map +0 -1
  251. package/dist/chunk-VD65AUOI.js +0 -2
  252. package/dist/chunk-VD65AUOI.js.map +0 -1
  253. package/dist/chunk-VUQOVQ5L.js.map +0 -1
  254. package/dist/chunk-WYXN7WW6.js.map +0 -1
  255. package/dist/chunk-XI3AQ3RM.js.map +0 -1
  256. package/dist/chunk-Y4VNFI7K.js +0 -2
  257. package/dist/chunk-Y4VNFI7K.js.map +0 -1
  258. package/dist/chunk-ZHL2SULA.js.map +0 -1
  259. /package/dist/{chunk-EE54SK65.js.map → chunk-63HVO7J5.js.map} +0 -0
  260. /package/dist/{chunk-2AUKMWRF.js.map → chunk-6YN2XQWR.js.map} +0 -0
  261. /package/dist/{chunk-LIGRV2J5.js.map → chunk-7JQPHRUK.js.map} +0 -0
  262. /package/dist/{chunk-GBD3OCAW.js.map → chunk-7P5B6XHM.js.map} +0 -0
  263. /package/dist/{chunk-BY5S6EQJ.js.map → chunk-ARKAW4ZP.js.map} +0 -0
  264. /package/dist/{chunk-ZSBWDLBS.js.map → chunk-DCRLPAJL.js.map} +0 -0
  265. /package/dist/{chunk-EOJJ4IWJ.js.map → chunk-DXABU6DZ.js.map} +0 -0
  266. /package/dist/{chunk-LLY7VPXS.js.map → chunk-F3BSJIHU.js.map} +0 -0
  267. /package/dist/{chunk-DR7VGNO2.js.map → chunk-HSW5HMHH.js.map} +0 -0
  268. /package/dist/{chunk-R7L6CI5J.js.map → chunk-ITSQE6EW.js.map} +0 -0
  269. /package/dist/{chunk-JUM2HAIK.js.map → chunk-JJHGVDPO.js.map} +0 -0
  270. /package/dist/{chunk-2JWANM25.js.map → chunk-MYB6Y5FC.js.map} +0 -0
  271. /package/dist/{chunk-SFZSHBWM.js.map → chunk-N7QHEESE.js.map} +0 -0
  272. /package/dist/{chunk-SJHGFMVF.js.map → chunk-NH4EITYM.js.map} +0 -0
  273. /package/dist/{chunk-CS3U6LJU.js.map → chunk-NQCSU6FR.js.map} +0 -0
  274. /package/dist/{chunk-Y22Q3UYU.js.map → chunk-OPCY3UYH.js.map} +0 -0
  275. /package/dist/{chunk-J2SFMADD.js.map → chunk-QDYQEQ3C.js.map} +0 -0
  276. /package/dist/{chunk-3F7QLHMP.js.map → chunk-RXVVLN7R.js.map} +0 -0
  277. /package/dist/{chunk-R2SDR47E.js.map → chunk-XCZYKOZU.js.map} +0 -0
  278. /package/dist/{chunk-4OEBYZLZ.js.map → chunk-XGEKV3FC.js.map} +0 -0
  279. /package/dist/{chunk-AXU5ZCUE.js.map → chunk-ZCYSBG7R.js.map} +0 -0
@@ -1,2 +1,2 @@
1
- import{a}from"./chunk-MDSGLUUB.js";import{b as e}from"./chunk-3LOVCTCN.js";import{a as t}from"./chunk-P37U34EQ.js";import{jsx as r,jsxs as o}from"react/jsx-runtime";function m({indirectTax:i,currency:n}){return o("div",{children:[o("div",{className:"flex justify-between items-center mb-2",children:[r("h3",{className:"font-medium text-primary-foreground",children:"Indirect Tax"}),r("span",{className:"font-semibold text-lg",children:e(i,n)})]}),r(a,{})]})}t(m,"CostCalculatorIndirectTax");export{m as a};
2
- //# sourceMappingURL=chunk-WYXN7WW6.js.map
1
+ import{a}from"./chunk-XJVYASHX.js";import{b as e}from"./chunk-3LOVCTCN.js";import{a as t}from"./chunk-P37U34EQ.js";import{jsx as r,jsxs as o}from"react/jsx-runtime";function m({indirectTax:i,currency:n}){return o("div",{children:[o("div",{className:"flex justify-between items-center mb-2",children:[r("h3",{className:"font-medium text-primary-foreground",children:"Indirect Tax"}),r("span",{className:"font-semibold text-lg",children:e(i,n)})]}),r(a,{})]})}t(m,"CostCalculatorIndirectTax");export{m as a};
2
+ //# sourceMappingURL=chunk-NVMZDPMF.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/flows/CostCalculator/Results/CostCalculatorIndirectTax.tsx"],"sourcesContent":["import { Separator } from '@/src/components/ui/separator';\nimport { formatCurrency } from '@/src/lib/utils';\n\ntype CostCalculatorIndirectTaxProps = {\n indirectTax: number;\n currency: string;\n};\n\nexport function CostCalculatorIndirectTax({\n indirectTax,\n currency,\n}: CostCalculatorIndirectTaxProps) {\n return (\n <div>\n <div className='flex justify-between items-center mb-2'>\n <h3 className='font-medium text-primary-foreground'>Indirect Tax</h3>\n <span className='font-semibold text-lg'>\n {formatCurrency(indirectTax, currency)}\n </span>\n </div>\n <Separator />\n </div>\n );\n}\n"],"mappings":"mHAcM,OACE,OAAAA,EADF,QAAAC,MAAA,oBANC,SAASC,EAA0B,CACxC,YAAAC,EACA,SAAAC,CACF,EAAmC,CACjC,OACEH,EAAC,OACC,UAAAA,EAAC,OAAI,UAAU,yCACb,UAAAD,EAAC,MAAG,UAAU,sCAAsC,wBAAY,EAChEA,EAAC,QAAK,UAAU,wBACb,SAAAK,EAAeF,EAAaC,CAAQ,EACvC,GACF,EACAJ,EAACM,EAAA,EAAU,GACb,CAEJ,CAfgBC,EAAAL,EAAA","names":["jsx","jsxs","CostCalculatorIndirectTax","indirectTax","currency","formatCurrency","Separator","__name"]}
@@ -1,2 +1,2 @@
1
- import{b as c}from"./chunk-KSHK3ZPX.js";import{a as C}from"./chunk-SUQURI2J.js";import{g as n}from"./chunk-GAOBYAJE.js";import{a as l}from"./chunk-P37U34EQ.js";import{useEffect as F}from"react";import{jsx as m}from"react/jsx-runtime";function P({onSubmit:f,onError:d,onSuccess:p,shouldResetForm:i,resetFields:s}){let{form:o,formId:E,costCalculatorBag:t}=c(),{formState:{isSubmitSuccessful:e}}=o;F(()=>{if(e&&i){t?.resetForm(),o.reset();return}if(e&&s){let a={...o.getValues()};s.forEach(r=>{a[r]=""}),t?.resetForm(),o.reset(a)}},[e,o,i,t,s]);let S=l(async u=>{let a=t?.parseFormValues(u),r=await t?.onSubmit(a);await f?.(a),r?.error?d?.(r.error):r?.data&&await p?.(r?.data)},"handleSubmit");return m(n,{...o,children:m("form",{id:E,onSubmit:o.handleSubmit(S),className:"space-y-4 RemoteFlows__CostCalculatorForm",children:m(C,{fields:t?.fields??[]})})})}l(P,"CostCalculatorForm");export{P as a};
2
- //# sourceMappingURL=chunk-ZMENI53L.js.map
1
+ import{b as c}from"./chunk-KSHK3ZPX.js";import{a as C}from"./chunk-LK4XMOCE.js";import{g as n}from"./chunk-3BREUYLG.js";import{a as l}from"./chunk-P37U34EQ.js";import{useEffect as F}from"react";import{jsx as m}from"react/jsx-runtime";function P({onSubmit:f,onError:d,onSuccess:p,shouldResetForm:i,resetFields:s}){let{form:o,formId:E,costCalculatorBag:t}=c(),{formState:{isSubmitSuccessful:e}}=o;F(()=>{if(e&&i){t?.resetForm(),o.reset();return}if(e&&s){let a={...o.getValues()};s.forEach(r=>{a[r]=""}),t?.resetForm(),o.reset(a)}},[e,o,i,t,s]);let S=l(async u=>{let a=t?.parseFormValues(u),r=await t?.onSubmit(a);await f?.(a),r?.error?d?.(r.error):r?.data&&await p?.(r?.data)},"handleSubmit");return m(n,{...o,children:m("form",{id:E,onSubmit:o.handleSubmit(S),className:"space-y-4 RemoteFlows__CostCalculatorForm",children:m(C,{fields:t?.fields??[]})})})}l(P,"CostCalculatorForm");export{P as a};
2
+ //# sourceMappingURL=chunk-NVQBJCNL.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/flows/CostCalculator/CostCalculatorForm.tsx"],"sourcesContent":["import { useEffect } from 'react';\nimport { CostCalculatorEstimateResponse } from '@/src/client';\nimport { JSONSchemaFormFields } from '@/src/components/form/JSONSchemaForm';\nimport { Form } from '@/src/components/ui/form';\nimport { useCostCalculatorContext } from '@/src/flows/CostCalculator/context';\nimport {\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: CostCalculatorEstimateResponse) => 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 const parsedValues = costCalculatorBag?.parseFormValues(\n values,\n ) as CostCalculatorEstimationSubmitValues;\n const costCalculatorResults =\n await costCalculatorBag?.onSubmit(parsedValues);\n\n await onSubmit?.(parsedValues);\n\n if (costCalculatorResults?.error) {\n onError?.(costCalculatorResults.error);\n } else if (costCalculatorResults?.data) {\n await onSuccess?.(costCalculatorResults?.data);\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,OAAS,aAAAA,MAAiB,QAwGlB,cAAAC,MAAA,oBAhED,SAASC,EAAmB,CACjC,SAAAC,EACA,QAAAC,EACA,UAAAC,EACA,gBAAAC,EACA,YAAAC,CACF,EAA4B,CAC1B,GAAM,CAAE,KAAAC,EAAM,OAAAC,EAAQ,kBAAAC,CAAkB,EAAIC,EAAyB,EAE/D,CACJ,UAAW,CAAE,mBAAAC,CAAmB,CAClC,EAAIJ,EAEJK,EAAU,IAAM,CAEd,GAAID,GAAsBN,EAAiB,CACzCI,GAAmB,UAAU,EAC7BF,EAAK,MAAM,EACX,MACF,CAGA,GAAII,GAAsBL,EAAa,CAGrC,IAAMO,EAAc,CAAE,GADAN,EAAK,UAAU,CACE,EACvCD,EAAY,QAASQ,GAAU,CAC7BD,EAAYC,CAAK,EAAI,EACvB,CAAC,EAEDL,GAAmB,UAAU,EAC7BF,EAAK,MAAMM,CAAW,CACxB,CACF,EAAG,CACDF,EACAJ,EACAF,EACAI,EACAH,CACF,CAAC,EAED,IAAMS,EAAeC,EAAA,MAAOC,GAA+C,CACzE,IAAMC,EAAeT,GAAmB,gBACtCQ,CACF,EACME,EACJ,MAAMV,GAAmB,SAASS,CAAY,EAEhD,MAAMhB,IAAWgB,CAAY,EAEzBC,GAAuB,MACzBhB,IAAUgB,EAAsB,KAAK,EAC5BA,GAAuB,MAChC,MAAMf,IAAYe,GAAuB,IAAI,CAEjD,EAdqB,gBAgBrB,OACEnB,EAACoB,EAAA,CAAM,GAAGb,EACR,SAAAP,EAAC,QACC,GAAIQ,EACJ,SAAUD,EAAK,aAAaQ,CAAY,EACxC,UAAU,4CAEV,SAAAf,EAACqB,EAAA,CAAqB,OAAQZ,GAAmB,QAAU,CAAC,EAAG,EACjE,EACF,CAEJ,CApEgBO,EAAAf,EAAA","names":["useEffect","jsx","CostCalculatorForm","onSubmit","onError","onSuccess","shouldResetForm","resetFields","form","formId","costCalculatorBag","useCostCalculatorContext","isSubmitSuccessful","useEffect","resetValues","field","handleSubmit","__name","values","parsedValues","costCalculatorResults","Form","JSONSchemaFormFields"]}
1
+ {"version":3,"sources":["../src/flows/CostCalculator/CostCalculatorForm.tsx"],"sourcesContent":["import { useEffect } from 'react';\nimport { CostCalculatorEstimateResponse } from '@/src/client';\nimport { JSONSchemaFormFields } from '@/src/components/form/JSONSchemaForm';\nimport { Form } from '@/src/components/ui/form';\nimport { useCostCalculatorContext } from '@/src/flows/CostCalculator/context';\nimport {\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: CostCalculatorEstimateResponse) => 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 const parsedValues = costCalculatorBag?.parseFormValues(\n values,\n ) as CostCalculatorEstimationSubmitValues;\n const costCalculatorResults =\n await costCalculatorBag?.onSubmit(parsedValues);\n\n await onSubmit?.(parsedValues);\n\n if (costCalculatorResults?.error) {\n onError?.(costCalculatorResults.error);\n } else if (costCalculatorResults?.data) {\n await onSuccess?.(costCalculatorResults?.data);\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,OAAS,aAAAA,MAAiB,QAwGlB,cAAAC,MAAA,oBAhED,SAASC,EAAmB,CACjC,SAAAC,EACA,QAAAC,EACA,UAAAC,EACA,gBAAAC,EACA,YAAAC,CACF,EAA4B,CAC1B,GAAM,CAAE,KAAAC,EAAM,OAAAC,EAAQ,kBAAAC,CAAkB,EAAIC,EAAyB,EAE/D,CACJ,UAAW,CAAE,mBAAAC,CAAmB,CAClC,EAAIJ,EAEJK,EAAU,IAAM,CAEd,GAAID,GAAsBN,EAAiB,CACzCI,GAAmB,UAAU,EAC7BF,EAAK,MAAM,EACX,MACF,CAGA,GAAII,GAAsBL,EAAa,CAGrC,IAAMO,EAAc,CAAE,GADAN,EAAK,UAAU,CACE,EACvCD,EAAY,QAASQ,GAAU,CAC7BD,EAAYC,CAAK,EAAI,EACvB,CAAC,EAEDL,GAAmB,UAAU,EAC7BF,EAAK,MAAMM,CAAW,CACxB,CACF,EAAG,CACDF,EACAJ,EACAF,EACAI,EACAH,CACF,CAAC,EAED,IAAMS,EAAeC,EAAA,MAAOC,GAA+C,CACzE,IAAMC,EAAeT,GAAmB,gBACtCQ,CACF,EACME,EACJ,MAAMV,GAAmB,SAASS,CAAY,EAEhD,MAAMhB,IAAWgB,CAAY,EAEzBC,GAAuB,MACzBhB,IAAUgB,EAAsB,KAAK,EAC5BA,GAAuB,MAChC,MAAMf,IAAYe,GAAuB,IAAI,CAEjD,EAdqB,gBAgBrB,OACEnB,EAACoB,EAAA,CAAM,GAAGb,EACR,SAAAP,EAAC,QACC,GAAIQ,EACJ,SAAUD,EAAK,aAAaQ,CAAY,EACxC,UAAU,4CAEV,SAAAf,EAACqB,EAAA,CAAqB,OAAQZ,GAAmB,QAAU,CAAC,EAAG,EACjE,EACF,CAEJ,CApEgBO,EAAAf,EAAA","names":["useEffect","jsx","CostCalculatorForm","onSubmit","onError","onSuccess","shouldResetForm","resetFields","form","formId","costCalculatorBag","useCostCalculatorContext","isSubmitSuccessful","useEffect","resetValues","field","handleSubmit","__name","values","parsedValues","costCalculatorResults","Form","JSONSchemaFormFields"]}
@@ -1,2 +1,2 @@
1
- import{a}from"./chunk-EE54SK65.js";import{a as p}from"./chunk-BY5S6EQJ.js";import{a as i}from"./chunk-LIGRV2J5.js";import{a as S}from"./chunk-Z7WBY27D.js";import{a as c}from"./chunk-7TOZZQQJ.js";import{a as m}from"./chunk-3F7QLHMP.js";import{a as r}from"./chunk-CS3U6LJU.js";import{a as f}from"./chunk-SJHGFMVF.js";import{a as s}from"./chunk-EOJJ4IWJ.js";import{a as n}from"./chunk-PGWKJ6FK.js";import{a as e}from"./chunk-J2SFMADD.js";import{a as t}from"./chunk-P37U34EQ.js";import{useId as R,useState as D}from"react";import{jsx as P}from"react/jsx-runtime";var K=t(({employmentId:d,companyId:b,countryCode:u,type:g="employee",externalId:B,skipSteps:l,initialValues:v,render:O,options:y})=>{let I=R(),o=e({companyId:b,countryCode:u,employmentId:d,type:g,options:y,skipSteps:l,externalId:B,initialValues:v}),[w,C]=D({showReserveInvoice:!1,showInviteSuccessful:!1});return P(n.Provider,{value:{formId:I,onboardingBag:o,creditScore:w,setCreditScore:C},children:O({onboardingBag:o,components:{BasicInformationStep:r,ContractDetailsStep:s,BenefitsStep:f,SubmitButton:i,SaveDraftButton:c,BackButton:a,OnboardingInvite:p,SelectCountryStep:m,ReviewStep:S}})})},"OnboardingFlow");export{K as a};
2
- //# sourceMappingURL=chunk-Y22Q3UYU.js.map
1
+ import{a as m}from"./chunk-RXVVLN7R.js";import{a as s}from"./chunk-DXABU6DZ.js";import{a}from"./chunk-63HVO7J5.js";import{a as p}from"./chunk-ARKAW4ZP.js";import{a as i}from"./chunk-7JQPHRUK.js";import{a as S}from"./chunk-Z7WBY27D.js";import{a as c}from"./chunk-5KHLOGTR.js";import{a as r}from"./chunk-NQCSU6FR.js";import{a as f}from"./chunk-NH4EITYM.js";import{a as e}from"./chunk-QDYQEQ3C.js";import{a as n}from"./chunk-PGWKJ6FK.js";import{a as t}from"./chunk-P37U34EQ.js";import{useId as R,useState as D}from"react";import{jsx as P}from"react/jsx-runtime";var K=t(({employmentId:d,companyId:b,countryCode:u,type:g="employee",externalId:B,skipSteps:l,initialValues:v,render:O,options:y})=>{let I=R(),o=e({companyId:b,countryCode:u,employmentId:d,type:g,options:y,skipSteps:l,externalId:B,initialValues:v}),[w,C]=D({showReserveInvoice:!1,showInviteSuccessful:!1});return P(n.Provider,{value:{formId:I,onboardingBag:o,creditScore:w,setCreditScore:C},children:O({onboardingBag:o,components:{BasicInformationStep:r,ContractDetailsStep:s,BenefitsStep:f,SubmitButton:i,SaveDraftButton:c,BackButton:a,OnboardingInvite:p,SelectCountryStep:m,ReviewStep:S}})})},"OnboardingFlow");export{K as a};
2
+ //# sourceMappingURL=chunk-OPCY3UYH.js.map
@@ -1,2 +1,2 @@
1
- import{b as l}from"./chunk-KSHK3ZPX.js";import{b as i}from"./chunk-3ZWDIEEM.js";import{b as C}from"./chunk-CSK44J23.js";import{a as c}from"./chunk-3LOVCTCN.js";import{a as u}from"./chunk-P37U34EQ.js";import{jsx as a}from"react/jsx-runtime";function R({children:e,...t}){let{form:r,formId:n,costCalculatorBag:s}=l(),{components:f}=i(),m=f?.button;return m?a(m,{...t,type:"reset",form:n,onClick:o=>{s?.resetForm(),r.reset(),t.onClick?.(o)},children:e}):a(C,{...t,type:"reset",className:c("RemoteFlows__CostCalculatorForm__ResetButton",t.className),form:n,onClick:o=>{s?.resetForm(),r.reset(),t.onClick?.(o)},children:e})}u(R,"CostCalculatorResetButton");export{R as a};
2
- //# sourceMappingURL=chunk-GK3OO5SX.js.map
1
+ import{b as l}from"./chunk-KSHK3ZPX.js";import{b as i}from"./chunk-3ZWDIEEM.js";import{b as C}from"./chunk-7VUILYZ3.js";import{a as c}from"./chunk-3LOVCTCN.js";import{a as u}from"./chunk-P37U34EQ.js";import{jsx as a}from"react/jsx-runtime";function R({children:e,...t}){let{form:r,formId:n,costCalculatorBag:s}=l(),{components:f}=i(),m=f?.button;return m?a(m,{...t,type:"reset",form:n,onClick:o=>{s?.resetForm(),r.reset(),t.onClick?.(o)},children:e}):a(C,{...t,type:"reset",className:c("RemoteFlows__CostCalculatorForm__ResetButton",t.className),form:n,onClick:o=>{s?.resetForm(),r.reset(),t.onClick?.(o)},children:e})}u(R,"CostCalculatorResetButton");export{R as a};
2
+ //# sourceMappingURL=chunk-OZ63OC3N.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/flows/CostCalculator/CostCalculatorResetButton.tsx"],"sourcesContent":["import { Button } from '@/src/components/ui/button';\nimport { ButtonHTMLAttributes, PropsWithChildren } from 'react';\nimport { useCostCalculatorContext } from './context';\nimport { cn } from '@/src/lib/utils';\nimport { useFormFields } from '@/src/context';\n\nexport function CostCalculatorResetButton({\n children,\n ...props\n}: PropsWithChildren<ButtonHTMLAttributes<HTMLButtonElement>> &\n Record<string, unknown>) {\n const { form, formId, costCalculatorBag } = useCostCalculatorContext();\n const { components } = useFormFields();\n\n const CustomButton = components?.button;\n if (CustomButton) {\n return (\n <CustomButton\n {...props}\n type='reset'\n form={formId}\n onClick={(evt) => {\n costCalculatorBag?.resetForm();\n form.reset();\n props.onClick?.(evt);\n }}\n >\n {children}\n </CustomButton>\n );\n }\n\n return (\n <Button\n {...props}\n type='reset'\n className={cn(\n 'RemoteFlows__CostCalculatorForm__ResetButton',\n props.className,\n )}\n form={formId}\n onClick={(evt) => {\n costCalculatorBag?.resetForm();\n form.reset();\n props.onClick?.(evt);\n }}\n >\n {children}\n </Button>\n );\n}\n"],"mappings":"wMAiBM,cAAAA,MAAA,oBAXC,SAASC,EAA0B,CACxC,SAAAC,EACA,GAAGC,CACL,EAC2B,CACzB,GAAM,CAAE,KAAAC,EAAM,OAAAC,EAAQ,kBAAAC,CAAkB,EAAIC,EAAyB,EAC/D,CAAE,WAAAC,CAAW,EAAIC,EAAc,EAE/BC,EAAeF,GAAY,OACjC,OAAIE,EAEAV,EAACU,EAAA,CACE,GAAGP,EACJ,KAAK,QACL,KAAME,EACN,QAAUM,GAAQ,CAChBL,GAAmB,UAAU,EAC7BF,EAAK,MAAM,EACXD,EAAM,UAAUQ,CAAG,CACrB,EAEC,SAAAT,EACH,EAKFF,EAACY,EAAA,CACE,GAAGT,EACJ,KAAK,QACL,UAAWU,EACT,+CACAV,EAAM,SACR,EACA,KAAME,EACN,QAAUM,GAAQ,CAChBL,GAAmB,UAAU,EAC7BF,EAAK,MAAM,EACXD,EAAM,UAAUQ,CAAG,CACrB,EAEC,SAAAT,EACH,CAEJ,CA5CgBY,EAAAb,EAAA","names":["jsx","CostCalculatorResetButton","children","props","form","formId","costCalculatorBag","useCostCalculatorContext","components","useFormFields","CustomButton","evt","Button","cn","__name"]}
@@ -1,2 +1,2 @@
1
- import{a as Te}from"./chunk-2A5R3YN2.js";import{a as Me}from"./chunk-VUQOVQ5L.js";import{a as Ce,b as Oe,c as O,d as Ve,e as Pe}from"./chunk-F66G33YT.js";import{a as fe,b as ue,c as ye,f as pe,g as _e,h as Se,i as be,j as ge,l as Fe,n as Ee}from"./chunk-47VYBPE2.js";import{a as j}from"./chunk-QW4JPW6J.js";import{a as he}from"./chunk-PJBAQZ6G.js";import{c as C,d as L,f as H}from"./chunk-MXFDOIUA.js";import{a as l}from"./chunk-P37U34EQ.js";import{useEffect as nt,useMemo as d,useRef as ot,useState as Le}from"react";import it from"lodash.mergewith";import{jsx as ke}from"react/jsx-runtime";var at={employment_basic_information:"basic_information",contract_details:"contract_details"},st={select_country:null,basic_information:"employment_basic_information",contract_details:"contract_details",benefits:null,review:null},rt=l(({isLoadingBasicInformationForm:y,isLoadingContractDetailsForm:I,isLoadingEmployment:J,isLoadingBenefitsOffersSchema:N,isLoadingBenefitOffers:a,isLoadingCompany:D,isLoadingCountries:V,employmentStatus:s,employmentId:_,currentStepName:r,basicInformationFields:A,contractDetailsFields:c})=>{let P=y||I||J||N||a||D||V,o=s&&Ve.includes(s),k=s&&!Pe.includes(s),B=!!(_&&o&&r!=="review"),q=P||B,w=!!(B&&!P&&A.length>0&&c.length>0);return{isLoading:q,isNavigatingToReview:w,isEmploymentReadOnly:o,canInvite:k}},"getLoadingStates"),bt=l(({employmentId:y,companyId:I,countryCode:J,type:N,options:a,skipSteps:D,externalId:V,initialValues:s})=>{let _=ot({select_country:{},basic_information:{},contract_details:{},benefits:{}}),[r,A]=Le(y),[c,P]=Le(J||null),{data:o,isLoading:k,refetch:B}=fe(r);o?.country?.code&&c!==o.country.code&&P(o.country.code);let{data:q,isLoading:w}=ye(r),{data:v,isLoading:W,refetch:Be}=ue(I),qe=D?.includes("select_country")?Oe:Ce,{fieldValues:S,stepState:n,setFieldValues:we,previousStep:ve,nextStep:Re,goToStep:x,setStepValues:z}=he(qe),{selectCountryForm:R,isLoading:G}=Fe({jsfModify:a?.jsfModify?.select_country,jsonSchemaVersion:a?.jsonSchemaVersion,queryOptions:{enabled:n.currentStep.name==="select_country"}}),$=Se(a),K=be(a),Y=ge(a),je=Ee(),{mutateAsync:Ie}=j($),{mutateAsync:Q}=j(K),{mutateAsync:Je}=j(Y),Ne=st[n.currentStep.name]||"employment_basic_information",De=at[Ne],Ae=o?.[De]||{},X=l(({form:e,options:i={},query:m={}})=>{let h=Object.keys(S).length>0?{...s,...n.values?.[n.currentStep.name],...S}:{...s,...Ae};return pe({countryCode:c,form:e,fieldValues:h,query:m,options:{...i,queryOptions:{enabled:i.queryOptions?.enabled??!0}}})},"useJSONSchema"),xe=!!(c&&(n.currentStep.name==="basic_information"||y)),Ue=!!(c&&(n.currentStep.name==="contract_details"||y)),{data:f,isLoading:Z}=X({form:"employment_basic_information",options:{jsfModify:a?.jsfModify?.basic_information,queryOptions:{enabled:xe}}}),b=a?.jsfModify?.contract_details?.fields?.annual_gross_salary,U=b&&typeof b=="object"&&"presentation"in b?b.presentation:void 0,ee=a?.jsfModify?.contract_details?.fields?.equity_compensation,He=d(()=>({fields:{annual_gross_salary:{...b,presentation:{annual_gross_salary_conversion_properties:{label:U?.annual_gross_salary_conversion_properties?.label,description:U?.annual_gross_salary_conversion_properties?.description},desiredCurrency:v?.desired_currency,Component:l(e=>ke(Me,{desiredCurrency:v?.desired_currency||"",...e}),"Component")}},equity_compensation:{...ee,presentation:{calculateDynamicProperties:l((e,i)=>{let m=e.equity_compensation?.offer_equity_compensation,h=i?.meta?.cost;return{extra:ke(Te,{offerEquity:m,equityCost:h})}},"calculateDynamicProperties")}}}}),[b,U,v?.desired_currency,ee]),{data:u,isLoading:te}=X({form:"contract_details",query:{employment_id:r},options:{jsfModify:{...a?.jsfModify?.contract_details,fields:{...a?.jsfModify?.contract_details?.fields,...He.fields}},queryOptions:{enabled:Ue}}}),{data:M,isLoading:ne}=_e(r,S,a),oe=d(()=>{if(n.currentStep.name==="benefits"){let e={...n.values?.[n.currentStep.name],...S};return it({},q,e)}return{}},[n.currentStep.name,q,n.values,S]),t=d(()=>({select_country:R?.fields||[],basic_information:f?.fields||[],contract_details:u?.fields||[],benefits:M?.fields||[],review:[]}),[R?.fields,f?.fields,u?.fields,M?.fields]),We={select_country:null,basic_information:f?.meta["x-jsf-fieldsets"],contract_details:u?.meta["x-jsf-fieldsets"],benefits:null,review:null},{country:{code:ie}={},basic_information:ae={},contract_details:se={},status:re}=o||{},ce=n.currentStep.name,g=d(()=>L(t.select_country,{country:c||ie||""}),[t.select_country,c,ie]),F=d(()=>{let e={...s,...ae};return L(t.basic_information,e)},[t.basic_information,ae,s]),p=d(()=>{let e={...s,...se};return L(t.contract_details,e)},[t.contract_details,se,s]),E=d(()=>{let e={...s,...oe};return L(t.benefits,e)},[t.benefits,oe,s]),ze=d(()=>o?{select_country:g,basic_information:H(t.basic_information,F),contract_details:o?.contract_details!==null?H(t.contract_details,p):p,benefits:E}:{select_country:g,basic_information:F,contract_details:p,benefits:E},[g,F,p,E,o,t]),{isLoading:Ge,isNavigatingToReview:le,isEmploymentReadOnly:$e,canInvite:Ke}=d(()=>rt({isLoadingBasicInformationForm:Z,isLoadingContractDetailsForm:te,isLoadingEmployment:k,isLoadingBenefitsOffersSchema:ne,isLoadingBenefitOffers:w,isLoadingCompany:W,isLoadingCountries:G,employmentId:y,employmentStatus:re,basicInformationFields:t.basic_information,contractDetailsFields:t.contract_details,currentStepName:ce}),[Z,te,k,ne,w,W,G,y,re,t.basic_information,t.contract_details,ce]);nt(()=>{le&&(_.current={select_country:O(g,t.select_country),basic_information:O(F,t.basic_information),contract_details:O(p,t.contract_details),benefits:O(E,t.benefits)},z({select_country:g,basic_information:F,contract_details:p,benefits:E,review:{}}),x("review"))},[F,E,p,x,le,g,z,t.basic_information,t.benefits,t.contract_details,t.select_country]);let me=l(e=>R&&n.currentStep.name==="select_country"?e:f&&n.currentStep.name==="basic_information"?C(e,f?.fields,{isPartialValidation:!1}):u&&n.currentStep.name==="contract_details"?C(e,u?.fields,{isPartialValidation:!1}):{},"parseFormValues");async function Ye(e){let i=n.currentStep.name;i in _.current&&(_.current[i]=O(e,t[i]));let m=me(e);switch(Be(),n.currentStep.name){case"select_country":return P(m.country),Promise.resolve({data:{countryCode:m.country}});case"basic_information":{let h=!r&&c,et=r&&c&&o?.country&&o?.country.code!==c;if(h||et){let tt={basic_information:m,type:N,country_code:c,external_id:V};try{let T=await Ie(tt),de=T.data?.data?.employment?.id;return A(de),await je.mutateAsync({employmentId:de,eligible_to_work_in_residing_country:"citizen",employer_or_work_restrictions:!1}),T}catch(T){throw console.error("Error creating onboarding:",T),T}}else if(r)return Q({employmentId:r,basic_information:m,pricing_plan_details:{frequency:"monthly"},external_id:V});return}case"contract_details":return Q({employmentId:r,external_id:V,...{contract_details:m,pricing_plan_details:{frequency:"monthly"}}});case"benefits":return Je({employmentId:r,...e})}}l(Ye,"onSubmit");function Qe(){ve()}l(Qe,"back");function Xe(){Re()}l(Xe,"next");function Ze(e){x(e)}return l(Ze,"goTo"),{employmentId:r,creditRiskStatus:v?.default_legal_entity_credit_risk_status,fieldValues:S,stepState:n,fields:t[n.currentStep.name],isLoading:Ge,isSubmitting:$.isPending||K.isPending||Y.isPending,initialValues:ze,handleValidation:l(e=>{if(n.currentStep.name==="select_country")return R.handleValidation(e);if(n.currentStep.name==="benefits"&&M){let i=C(e,M?.fields,{isPartialValidation:!1});return M?.handleValidation(i)}if(f&&n.currentStep.name==="basic_information"){let i=C(e,f?.fields,{isPartialValidation:!1});return f?.handleValidation(i)}if(u&&n.currentStep.name==="contract_details"){let i=C(e,u?.fields,{isPartialValidation:!1});return u?.handleValidation(i)}return null},"handleValidation"),checkFieldUpdates:we,parseFormValues:me,onSubmit:Ye,back:Qe,next:Xe,goTo:Ze,meta:{fields:_.current,fieldsets:We[n.currentStep.name]},refetchEmployment:B,employment:o,isEmploymentReadOnly:$e,canInvite:Ke}},"useOnboarding");export{bt as a};
2
- //# sourceMappingURL=chunk-J2SFMADD.js.map
1
+ import{a as Te}from"./chunk-VAIBLWOY.js";import{a as Me}from"./chunk-J4GIUQ4E.js";import{a as Ce,b as Oe,c as O,d as Ve,e as Pe}from"./chunk-F66G33YT.js";import{a as fe,b as ue,c as ye,f as pe,g as _e,h as Se,i as be,j as ge,l as Fe,n as Ee}from"./chunk-47VYBPE2.js";import{a as j}from"./chunk-QW4JPW6J.js";import{a as he}from"./chunk-PJBAQZ6G.js";import{c as C,d as L,f as H}from"./chunk-MXFDOIUA.js";import{a as l}from"./chunk-P37U34EQ.js";import{useEffect as nt,useMemo as d,useRef as ot,useState as Le}from"react";import it from"lodash.mergewith";import{jsx as ke}from"react/jsx-runtime";var at={employment_basic_information:"basic_information",contract_details:"contract_details"},st={select_country:null,basic_information:"employment_basic_information",contract_details:"contract_details",benefits:null,review:null},rt=l(({isLoadingBasicInformationForm:y,isLoadingContractDetailsForm:I,isLoadingEmployment:J,isLoadingBenefitsOffersSchema:N,isLoadingBenefitOffers:a,isLoadingCompany:D,isLoadingCountries:V,employmentStatus:s,employmentId:_,currentStepName:r,basicInformationFields:A,contractDetailsFields:c})=>{let P=y||I||J||N||a||D||V,o=s&&Ve.includes(s),k=s&&!Pe.includes(s),B=!!(_&&o&&r!=="review"),q=P||B,w=!!(B&&!P&&A.length>0&&c.length>0);return{isLoading:q,isNavigatingToReview:w,isEmploymentReadOnly:o,canInvite:k}},"getLoadingStates"),bt=l(({employmentId:y,companyId:I,countryCode:J,type:N,options:a,skipSteps:D,externalId:V,initialValues:s})=>{let _=ot({select_country:{},basic_information:{},contract_details:{},benefits:{}}),[r,A]=Le(y),[c,P]=Le(J||null),{data:o,isLoading:k,refetch:B}=fe(r);o?.country?.code&&c!==o.country.code&&P(o.country.code);let{data:q,isLoading:w}=ye(r),{data:v,isLoading:W,refetch:Be}=ue(I),qe=D?.includes("select_country")?Oe:Ce,{fieldValues:S,stepState:n,setFieldValues:we,previousStep:ve,nextStep:Re,goToStep:x,setStepValues:z}=he(qe),{selectCountryForm:R,isLoading:G}=Fe({jsfModify:a?.jsfModify?.select_country,jsonSchemaVersion:a?.jsonSchemaVersion,queryOptions:{enabled:n.currentStep.name==="select_country"}}),$=Se(a),K=be(a),Y=ge(a),je=Ee(),{mutateAsync:Ie}=j($),{mutateAsync:Q}=j(K),{mutateAsync:Je}=j(Y),Ne=st[n.currentStep.name]||"employment_basic_information",De=at[Ne],Ae=o?.[De]||{},X=l(({form:e,options:i={},query:m={}})=>{let h=Object.keys(S).length>0?{...s,...n.values?.[n.currentStep.name],...S}:{...s,...Ae};return pe({countryCode:c,form:e,fieldValues:h,query:m,options:{...i,queryOptions:{enabled:i.queryOptions?.enabled??!0}}})},"useJSONSchema"),xe=!!(c&&(n.currentStep.name==="basic_information"||y)),Ue=!!(c&&(n.currentStep.name==="contract_details"||y)),{data:f,isLoading:Z}=X({form:"employment_basic_information",options:{jsfModify:a?.jsfModify?.basic_information,queryOptions:{enabled:xe}}}),b=a?.jsfModify?.contract_details?.fields?.annual_gross_salary,U=b&&typeof b=="object"&&"presentation"in b?b.presentation:void 0,ee=a?.jsfModify?.contract_details?.fields?.equity_compensation,He=d(()=>({fields:{annual_gross_salary:{...b,presentation:{annual_gross_salary_conversion_properties:{label:U?.annual_gross_salary_conversion_properties?.label,description:U?.annual_gross_salary_conversion_properties?.description},desiredCurrency:v?.desired_currency,Component:l(e=>ke(Me,{desiredCurrency:v?.desired_currency||"",...e}),"Component")}},equity_compensation:{...ee,presentation:{calculateDynamicProperties:l((e,i)=>{let m=e.equity_compensation?.offer_equity_compensation,h=i?.meta?.cost;return{extra:ke(Te,{offerEquity:m,equityCost:h})}},"calculateDynamicProperties")}}}}),[b,U,v?.desired_currency,ee]),{data:u,isLoading:te}=X({form:"contract_details",query:{employment_id:r},options:{jsfModify:{...a?.jsfModify?.contract_details,fields:{...a?.jsfModify?.contract_details?.fields,...He.fields}},queryOptions:{enabled:Ue}}}),{data:M,isLoading:ne}=_e(r,S,a),oe=d(()=>{if(n.currentStep.name==="benefits"){let e={...n.values?.[n.currentStep.name],...S};return it({},q,e)}return{}},[n.currentStep.name,q,n.values,S]),t=d(()=>({select_country:R?.fields||[],basic_information:f?.fields||[],contract_details:u?.fields||[],benefits:M?.fields||[],review:[]}),[R?.fields,f?.fields,u?.fields,M?.fields]),We={select_country:null,basic_information:f?.meta["x-jsf-fieldsets"],contract_details:u?.meta["x-jsf-fieldsets"],benefits:null,review:null},{country:{code:ie}={},basic_information:ae={},contract_details:se={},status:re}=o||{},ce=n.currentStep.name,g=d(()=>L(t.select_country,{country:c||ie||""}),[t.select_country,c,ie]),F=d(()=>{let e={...s,...ae};return L(t.basic_information,e)},[t.basic_information,ae,s]),p=d(()=>{let e={...s,...se};return L(t.contract_details,e)},[t.contract_details,se,s]),E=d(()=>{let e={...s,...oe};return L(t.benefits,e)},[t.benefits,oe,s]),ze=d(()=>o?{select_country:g,basic_information:H(t.basic_information,F),contract_details:o?.contract_details!==null?H(t.contract_details,p):p,benefits:E}:{select_country:g,basic_information:F,contract_details:p,benefits:E},[g,F,p,E,o,t]),{isLoading:Ge,isNavigatingToReview:le,isEmploymentReadOnly:$e,canInvite:Ke}=d(()=>rt({isLoadingBasicInformationForm:Z,isLoadingContractDetailsForm:te,isLoadingEmployment:k,isLoadingBenefitsOffersSchema:ne,isLoadingBenefitOffers:w,isLoadingCompany:W,isLoadingCountries:G,employmentId:y,employmentStatus:re,basicInformationFields:t.basic_information,contractDetailsFields:t.contract_details,currentStepName:ce}),[Z,te,k,ne,w,W,G,y,re,t.basic_information,t.contract_details,ce]);nt(()=>{le&&(_.current={select_country:O(g,t.select_country),basic_information:O(F,t.basic_information),contract_details:O(p,t.contract_details),benefits:O(E,t.benefits)},z({select_country:g,basic_information:F,contract_details:p,benefits:E,review:{}}),x("review"))},[F,E,p,x,le,g,z,t.basic_information,t.benefits,t.contract_details,t.select_country]);let me=l(e=>R&&n.currentStep.name==="select_country"?e:f&&n.currentStep.name==="basic_information"?C(e,f?.fields,{isPartialValidation:!1}):u&&n.currentStep.name==="contract_details"?C(e,u?.fields,{isPartialValidation:!1}):{},"parseFormValues");async function Ye(e){let i=n.currentStep.name;i in _.current&&(_.current[i]=O(e,t[i]));let m=me(e);switch(Be(),n.currentStep.name){case"select_country":return P(m.country),Promise.resolve({data:{countryCode:m.country}});case"basic_information":{let h=!r&&c,et=r&&c&&o?.country&&o?.country.code!==c;if(h||et){let tt={basic_information:m,type:N,country_code:c,external_id:V};try{let T=await Ie(tt),de=T.data?.data?.employment?.id;return A(de),await je.mutateAsync({employmentId:de,eligible_to_work_in_residing_country:"citizen",employer_or_work_restrictions:!1}),T}catch(T){throw console.error("Error creating onboarding:",T),T}}else if(r)return Q({employmentId:r,basic_information:m,pricing_plan_details:{frequency:"monthly"},external_id:V});return}case"contract_details":return Q({employmentId:r,external_id:V,...{contract_details:m,pricing_plan_details:{frequency:"monthly"}}});case"benefits":return Je({employmentId:r,...e})}}l(Ye,"onSubmit");function Qe(){ve()}l(Qe,"back");function Xe(){Re()}l(Xe,"next");function Ze(e){x(e)}return l(Ze,"goTo"),{employmentId:r,creditRiskStatus:v?.default_legal_entity_credit_risk_status,fieldValues:S,stepState:n,fields:t[n.currentStep.name],isLoading:Ge,isSubmitting:$.isPending||K.isPending||Y.isPending,initialValues:ze,handleValidation:l(e=>{if(n.currentStep.name==="select_country")return R.handleValidation(e);if(n.currentStep.name==="benefits"&&M){let i=C(e,M?.fields,{isPartialValidation:!1});return M?.handleValidation(i)}if(f&&n.currentStep.name==="basic_information"){let i=C(e,f?.fields,{isPartialValidation:!1});return f?.handleValidation(i)}if(u&&n.currentStep.name==="contract_details"){let i=C(e,u?.fields,{isPartialValidation:!1});return u?.handleValidation(i)}return null},"handleValidation"),checkFieldUpdates:we,parseFormValues:me,onSubmit:Ye,back:Qe,next:Xe,goTo:Ze,meta:{fields:_.current,fieldsets:We[n.currentStep.name]},refetchEmployment:B,employment:o,isEmploymentReadOnly:$e,canInvite:Ke}},"useOnboarding");export{bt as a};
2
+ //# sourceMappingURL=chunk-QDYQEQ3C.js.map
@@ -0,0 +1,2 @@
1
+ import{a as w,b as R,c as x,d as A}from"./chunk-4RULC3AZ.js";import{a as C}from"./chunk-ZE3YT3Q6.js";import{a as f}from"./chunk-NBCZF2FO.js";import{a as F}from"./chunk-UHS3QRA3.js";import{a as b}from"./chunk-N5I33LIN.js";import{b as k}from"./chunk-7VUILYZ3.js";import{a as c,b as n}from"./chunk-3LOVCTCN.js";import{a as m}from"./chunk-P37U34EQ.js";import{MoreHorizontal as D}from"lucide-react";import{useState as H}from"react";import{Fragment as M,jsx as y,jsxs as T}from"react/jsx-runtime";function B({actions:e=[],className:s}){let[a,l]=H(!1);return T("div",{className:c("relative",s),children:[y(k,{variant:"ghost",className:"h-8 w-8 p-0",onClick:()=>l(!a),children:y(D,{className:"h-4 w-4"})}),a&&T(M,{children:[y("div",{className:"fixed inset-0 z-40",onClick:()=>l(!1)}),y("div",{className:"absolute right-0 top-1/2 mt-1 bg-white border border-gray-200 rounded-md shadow-lg z-50 min-w-[120px]",children:e.map((i,_)=>y("button",{className:c("w-full text-left px-2 py-1.5 text-sm hover:bg-gray-100",i.disabled&&"opacity-50 cursor-not-allowed"),onClick:()=>{i.onClick(),l(!1)},disabled:i.disabled,children:i.label},_))})]})]})}m(B,"ActionsDropdown");import{ChevronDown as I,Info as S}from"lucide-react";import P from"react-flagpack";import{useState as O}from"react";import{Fragment as p,jsx as o,jsxs as t}from"react/jsx-runtime";var U=m(({title:e,country:s,region:a,onDelete:l,onExportPdf:i})=>{let _=[{label:"Edit",onClick:m(()=>{},"onClick"),disabled:!0},{label:"Export",onClick:i},{label:"Delete",onClick:l}];return t("div",{className:"RemoteFlows__EstimationResults__Header flex justify-between",children:[t("div",{className:"flex flex-row items-center gap-6",children:[o("div",{className:"RemoteFlows__EstimationResultsHeader__FlagContainer flex h-12 w-12 items-center justify-center rounded-lg bg-[#F4F4F5]",children:o(P,{code:s.alpha_2_code})}),t("div",{className:"space-y-1",children:[o("h2",{className:"RemoteFlows__EstimationResultsHeader__Title text-lg font-medium leading-none text-[#181818]",children:e}),t("p",{className:"RemoteFlows__EstimationResultsHeader__Country text-xs text-[#71717A]",children:[s.name," ",a?` (${a.name})`:""]})]})]}),o(B,{className:"RemoteFlows__EstimationResults__ActionsDropdown",actions:_})]})},"EstimationResultsHeader"),j=m(()=>({steps:[{id:"add-employment-details",title:"Add employment details",description:"You add employee employments details."},{id:"invite-employee",title:"Invite employee",description:"Hire receives an email invitation from Remote to start the self-enrollment process."},{id:"verify-information",title:"Verify information",description:"Remote prepares the Employment Agreement and verifies all the information."},{id:"sign-contract",title:"Sign contract",description:"All parties sign the Employment Agreement and are ready to start. \u{1F389}"}],helpText:"For customers who accept our Terms of Service (ToS), the employee onboarding timeline starts once the employee has been invited to the platform and completed self enrolment.",zendeskArticleId:f.employeeOnboardingTimeline}),"getOnboardingTimelineData");function G({minimumOnboardingDays:e,data:s,className:a}){return o(w,{type:"single",collapsible:!0,className:c("RemoteFlows__EstimationResults__OnboardingTimeline w-full",a),children:t(R,{value:"timeline",className:"RemoteFlows__OnboardingTimeline__AccordionItem border-border",children:[o(x,{className:"RemoteFlows__OnboardingTimeline__AccordionTrigger hover:no-underline px-0 py-4",children:t("div",{className:"flex items-center justify-between w-full",children:[o("span",{className:"RemoteFlows__OnboardingTimeline__Title text-base font-medium text-[#0F172A]",children:"Onboarding timeline"}),t("span",{className:"RemoteFlows__OnboardingTimeline__Description text-base text-muted-foreground mr-4",children:[e," days"]})]})}),t(A,{className:"px-0 pb-4",children:[o("ul",{className:"RemoteFlows__OnboardingTimeline__List list-disc list-inside space-y-2",children:s.steps.map(l=>t("li",{children:[o("strong",{className:"font-medium text-[#09090B]",children:l.title})," ","- ",l.description]},l.id))}),t("p",{className:"RemoteFlows__OnboardingTimeline__HelpText text-xs text-muted-foreground mt-4",children:[s.helpText,s.zendeskArticleId&&o(b,{zendeskId:s.zendeskArticleId,children:"Learn more"})]})]})]})})}m(G,"OnboardingTimeline");function Z({className:e,countryBenefitsUrl:s,countryGuideUrl:a,country:l}){return o(w,{type:"single",collapsible:!0,className:c("RemoteFlows__EstimationResults__HiringSection w-full",e),children:t(R,{value:"timeline",className:"RemoteFlows__HiringSection__AccordionItem border-border",children:[o(x,{className:"RemoteFlows__HiringSection__AccordionTrigger hover:no-underline px-0 py-4",children:o("div",{className:"flex items-center justify-between w-full",children:t("span",{className:"text-base font-medium text-[#0F172A]",children:["Hiring in ",l.name]})})}),o(A,{children:t("div",{className:"flex flex-col gap-1",children:[o("a",{href:a,target:"_blank",className:"RemoteFlows__Link",children:"Explore our complete guide \u2197"}),o("a",{href:s,target:"_blank",className:"RemoteFlows__Link",children:"Explore our available benefits \u2197"})]})})]})})}m(Z,"HiringSection");function $({isMultipleCurrency:e,className:s}){return t("div",{className:c("RemoteFlows__EstimationResults__Headers grid grid-cols-3 items-center",s),children:[o("span",{"aria-hidden":!0}),e?t(p,{children:[o("span",{className:"RemoteFlows__EstimationResults__Headers__Label",children:"Employee currency"}),o("span",{className:"RemoteFlows__EstimationResults__Headers__Label",children:"Employer currency"})]}):t(p,{children:[o("span",{}),o("span",{className:"RemoteFlows__EstimationResults__Headers__Label",children:"Amount"})]})]})}m($,"EstimationHeaders");function E({label:e,amounts:s,className:a,children:l}){let[i,_]=O(!0);return t("div",{className:c("RemoteFlows__EstimationResults__Row",a),children:[t("div",{className:"grid grid-cols-3 items-center",children:[t("div",{className:"flex items-center gap-2",children:[o("span",{className:c("RemoteFlows__EstimationRow__Title min-w-[140px] font-medium text-[#09090B]"),children:e}),o("button",{onClick:()=>_(!i),className:"RemoteFlows__EstimationRow__CollapseButton p-1 hover:bg-gray-100 rounded",children:o(I,{className:`h-4 w-4 text-muted-foreground transition-transform ${i?"rotate-180":""}`})})]}),Array.isArray(s)?s.map((u,g)=>o("span",{className:c("RemoteFlows__EstimationRow__RegionalAmount text-right font-medium text-[#09090B]"),children:u},g)):t(p,{children:[o("span",{}),o("span",{className:c("RemoteFlows__EstimationRow__EmployerAmount text-right font-medium text-[#09090B]"),children:s})]})]}),i&&l&&o("div",{className:"RemoteFlows__EstimationRow__CollapsibleContent mt-4",children:l})]})}m(E,"EstimationRow");function V({item:e,isMultipleCurrency:s,level:a=0}){let[l,i]=O(!1),_=e.children&&e.children.length>0,u=a>0;return t("li",{className:c("RemoteFlows__BreakdownList__Item pb-3",u&&"pb-1"),children:[t("div",{className:c(s?"grid grid-cols-3 items-center justify-between":"grid grid-cols-2 items-center justify-between"),children:[t("div",{className:c("flex items-center gap-2",u&&"pl-3"),children:[!u&&o("span",{className:"RemoteFlows__BreakdownList__Bullet w-1 h-1 bg-[#09090B] rounded-full flex-shrink-0","aria-hidden":"true"}),o("span",{className:c(u?"RemoteFlows__BreakdownList__Text--Nested text-xs text-[#71717A]":"RemoteFlows__BreakdownList__Text--NotNested text-sm text-[#09090B]"),children:e.label}),e.tooltip&&o(C,{content:t(p,{children:[o("span",{children:e.tooltip})," ",e.zendeskId&&o(b,{zendeskId:Number(e.zendeskId),children:"Learn more"})]}),children:o("button",{className:"RemoteFlows__BreakdownList__InfoButton p-1 hover:bg-gray-100 rounded",children:o(S,{className:c("text-muted-foreground",u?"h-3 w-3":"h-4 w-4")})})}),(e.isCollapsible||_)&&o("button",{onClick:()=>i(!l),className:"RemoteFlows__BreakdownList__CollapsibleButton p-1 hover:bg-gray-100 rounded",children:o(I,{className:`h-3 w-3 text-muted-foreground transition-transform ${l?"rotate-180":""}`})})]}),s?t(p,{children:[o("span",{className:c("RemoteFlows__BreakdownList__RegionalAmountText text-sm text-right",u?"RemoteFlows__BreakdownList__RegionalAmountText--Nested text-[#71717A]":"RemoteFlows__BreakdownList__RegionalAmountText--NotNested text-[#09090B]"),children:e.regionalAmount||"\u2014"}),o("span",{className:c("RemoteFlows__BreakdownList__EmployerAmountText text-sm text-right",u?"RemoteFlows__BreakdownList__EmployerAmountText--Nested text-[#71717A]":"RemoteFlows__BreakdownList__EmployerAmountText--NotNested text-[#09090B]"),children:e.employerAmount||"\u2014"})]}):o("span",{className:c("RemoteFlows__BreakdownList__RegionalAmountText text-sm text-right",u?"RemoteFlows__BreakdownList__RegionalAmountText--Nested text-[#71717A]":"RemoteFlows__BreakdownList__RegionalAmountText--NotNested text-[#09090B]"),children:e.regionalAmount||"\u2014"})]}),_&&l&&o("div",{className:"mt-1",children:o(N,{items:e.children,isMultipleCurrency:s,level:a+1})})]})}m(V,"BreakdownListItem");function N({items:e,isMultipleCurrency:s,className:a,level:l}){return o("ul",{className:c("RemoteFlows__BreakdownList list-none",a),children:e.map((i,_)=>o(V,{item:i,isMultipleCurrency:s,level:l},_))})}m(N,"BreakdownList");var me=m(({estimation:e,title:s,components:a,onDelete:l,onExportPdf:i})=>{let _=a?.HiringSection||Z,u=a?.OnboardingTimeline||G,g=a?.Header||U,h=a?.Footer,L=j(),d=e.employer_currency_costs.currency.code!==e.regional_currency_costs.currency.code,v=e.employer_currency_costs.monthly_management_fee,z=e.region.code!==e.country.code;return t(F,{className:"RemoteFlows__EstimationResults__Card p-10",children:[o("div",{className:"RemoteFlows__Separator",children:o(g,{title:s,region:z?e.region:void 0,country:e.country,onDelete:l,onExportPdf:i})}),t("div",{className:"RemoteFlows__Separator",children:[o($,{isMultipleCurrency:d,className:"mb-3"}),o(E,{label:"Monthly total cost",amounts:d?[n(e.regional_currency_costs.monthly_total,e.regional_currency_costs.currency.symbol),n(e.employer_currency_costs.monthly_total,e.employer_currency_costs.currency.symbol)]:n(e.regional_currency_costs.monthly_total,e.regional_currency_costs.currency.symbol),children:o(N,{items:[{label:"Gross monthly salary",regionalAmount:n(e.regional_currency_costs.monthly_gross_salary,e.regional_currency_costs.currency.symbol),employerAmount:n(e.employer_currency_costs.monthly_gross_salary,e.employer_currency_costs.currency.symbol),zendeskId:f.extraPayments.toString(),tooltip:"This country respects extra payments on top of the gross salary."},{label:"Mandatory employer costs",regionalAmount:n(e.regional_currency_costs.monthly_contributions_total,e.regional_currency_costs.currency.symbol),employerAmount:n(e.employer_currency_costs.monthly_contributions_total,e.employer_currency_costs.currency.symbol),children:e.employer_currency_costs.monthly_contributions_breakdown?.map(r=>({label:r.name,regionalAmount:n(r.amount,e.regional_currency_costs.currency.symbol),employerAmount:n(r.amount,e.employer_currency_costs.currency.symbol),zendeskId:r.zendesk_article_id||void 0,tooltip:r.description||void 0}))||[]},{label:"Core benefits",regionalAmount:n(e.regional_currency_costs.monthly_benefits_total,e.regional_currency_costs.currency.symbol),employerAmount:n(e.employer_currency_costs.monthly_benefits_total,e.employer_currency_costs.currency.symbol),children:e.employer_currency_costs.monthly_benefits_breakdown?.map(r=>({label:r.name,regionalAmount:n(r.amount,e.regional_currency_costs.currency.symbol),employerAmount:n(r.amount,e.employer_currency_costs.currency.symbol),zendeskId:r.zendesk_article_id||void 0,tooltip:r.description||void 0}))||[]},...v?[{label:"Management fee",regionalAmount:n(e.regional_currency_costs.monthly_management_fee,e.regional_currency_costs.currency.symbol),employerAmount:n(e.employer_currency_costs.monthly_management_fee,e.employer_currency_costs.currency.symbol),tooltip:"Discounts may be available based on your commitment and team size. Speak to your account or customer success manager to learn more."}]:[]],isMultipleCurrency:d})})]}),o("div",{className:"RemoteFlows__Separator",children:o(E,{label:"Annual total cost",amounts:d?[n(e.regional_currency_costs.annual_total,e.regional_currency_costs.currency.symbol),n(e.employer_currency_costs.annual_total,e.employer_currency_costs.currency.symbol)]:n(e.regional_currency_costs.annual_total,e.regional_currency_costs.currency.symbol),children:o(N,{items:[{label:"Annual gross salary",regionalAmount:n(e.regional_currency_costs.annual_gross_salary,e.regional_currency_costs.currency.symbol),employerAmount:n(e.employer_currency_costs.annual_gross_salary,e.employer_currency_costs.currency.symbol)},{label:"Mandatory employer costs",regionalAmount:n(e.regional_currency_costs.annual_contributions_total,e.regional_currency_costs.currency.symbol),employerAmount:n(e.employer_currency_costs.annual_contributions_total,e.employer_currency_costs.currency.symbol),children:e.employer_currency_costs.annual_contributions_breakdown?.map(r=>({label:r.name,regionalAmount:n(r.amount,e.regional_currency_costs.currency.symbol),employerAmount:n(r.amount,e.employer_currency_costs.currency.symbol),zendeskId:r.zendesk_article_id||void 0,tooltip:r.description||void 0}))||[]},{label:"Core benefits",regionalAmount:n(e.regional_currency_costs.annual_benefits_total,e.regional_currency_costs.currency.symbol),employerAmount:n(e.employer_currency_costs.annual_benefits_total,e.employer_currency_costs.currency.symbol),children:e.employer_currency_costs.annual_benefits_breakdown?.map(r=>({label:r.name,regionalAmount:n(r.amount,e.regional_currency_costs.currency.symbol),employerAmount:n(r.amount,e.employer_currency_costs.currency.symbol),zendeskId:r.zendesk_article_id||void 0,tooltip:r.description||void 0}))||[]},{label:"Extra statutory payments",regionalAmount:n(e.regional_currency_costs.extra_statutory_payments_total,e.regional_currency_costs.currency.symbol),employerAmount:n(e.employer_currency_costs.extra_statutory_payments_total,e.employer_currency_costs.currency.symbol),children:e.employer_currency_costs.extra_statutory_payments_breakdown?.map(r=>({label:r.name,regionalAmount:n(r.amount,e.regional_currency_costs.currency.symbol),employerAmount:n(r.amount,e.employer_currency_costs.currency.symbol),zendeskId:r.zendesk_article_id||void 0,tooltip:r.description||void 0}))||[]},...v?[{label:"Management fee",regionalAmount:n(e.regional_currency_costs.annual_management_fee,e.regional_currency_costs.currency.symbol),employerAmount:n(e.employer_currency_costs.annual_management_fee,e.employer_currency_costs.currency.symbol),tooltip:"Discounts may be available based on your commitment and team size. Speak to your account or customer success manager to learn more."}]:[]],isMultipleCurrency:d})})}),o("div",{className:"RemoteFlows__Separator",children:o(u,{minimumOnboardingDays:e.minimum_onboarding_time,data:L})}),o(_,{countryBenefitsUrl:e.country_benefits_details_url,countryGuideUrl:e.country_guide_url,country:e.country}),h&&o(h,{})]})},"EstimationResults");export{me as a};
2
+ //# sourceMappingURL=chunk-QYJQNWPB.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/components/shared/actions-dropdown/ActionsDropdown.tsx","../src/flows/CostCalculator/EstimationResults/EstimationResults.tsx"],"sourcesContent":["import { Button } from '@/src/components/ui/button';\nimport { cn } from '@/src/lib/utils';\nimport { MoreHorizontal } from 'lucide-react';\nimport { useState, type ReactNode } from 'react';\n\nexport interface DropdownAction {\n label: string;\n icon?: ReactNode;\n onClick: () => void;\n separator?: boolean;\n disabled?: boolean;\n}\n\ninterface ActionsDropdownProps {\n actions?: DropdownAction[];\n className?: string;\n}\n\nexport function ActionsDropdown({\n actions = [],\n className,\n}: ActionsDropdownProps) {\n const [isOpen, setIsOpen] = useState(false);\n\n return (\n <div className={cn('relative', className)}>\n <Button\n variant='ghost'\n className='h-8 w-8 p-0'\n onClick={() => setIsOpen(!isOpen)}\n >\n <MoreHorizontal className='h-4 w-4' />\n </Button>\n\n {isOpen && (\n <>\n <div\n className='fixed inset-0 z-40'\n onClick={() => setIsOpen(false)}\n />\n <div className='absolute right-0 top-1/2 mt-1 bg-white border border-gray-200 rounded-md shadow-lg z-50 min-w-[120px]'>\n {actions.map((action, index) => (\n <button\n key={index}\n className={cn(\n 'w-full text-left px-2 py-1.5 text-sm hover:bg-gray-100',\n action.disabled && 'opacity-50 cursor-not-allowed',\n )}\n onClick={() => {\n action.onClick();\n setIsOpen(false);\n }}\n disabled={action.disabled}\n >\n {action.label}\n </button>\n ))}\n </div>\n </>\n )}\n </div>\n );\n}\n","import {\n CostCalculatorEmployment,\n MinimalCountry,\n MinimalRegion,\n} from '@/src/client';\nimport { ActionsDropdown } from '@/src/components/shared/actions-dropdown/ActionsDropdown';\nimport { Card } from '@/src/components/ui/card';\nimport { ChevronDown, Info } from 'lucide-react';\nimport Flag from 'react-flagpack';\nimport { useState } from 'react';\nimport {\n Accordion,\n AccordionContent,\n AccordionItem,\n AccordionTrigger,\n} from '@/src/components/ui/accordion';\nimport { cn, formatCurrency } from '@/src/lib/utils';\nimport { ZendeskTriggerButton } from '@/src/components/shared/zendesk-drawer/ZendeskTriggerButton';\nimport { zendeskArticles } from '@/src/components/shared/zendesk-drawer/utils';\nimport { BasicTooltip } from '@/src/components/ui/basic-tooltip';\n\nconst EstimationResultsHeader = ({\n title,\n country,\n region,\n onDelete,\n onExportPdf,\n}: {\n title: string;\n country: MinimalCountry;\n region?: MinimalRegion;\n onDelete: () => void;\n onExportPdf: () => void;\n}) => {\n const actions = [\n {\n label: 'Edit',\n onClick: () => {},\n disabled: true,\n },\n {\n label: 'Export',\n onClick: onExportPdf,\n },\n {\n label: 'Delete',\n onClick: onDelete,\n },\n ];\n return (\n <div className='RemoteFlows__EstimationResults__Header flex justify-between'>\n <div className='flex flex-row items-center gap-6'>\n <div className='RemoteFlows__EstimationResultsHeader__FlagContainer flex h-12 w-12 items-center justify-center rounded-lg bg-[#F4F4F5]'>\n <Flag code={country.alpha_2_code} />\n </div>\n <div className='space-y-1'>\n <h2 className='RemoteFlows__EstimationResultsHeader__Title text-lg font-medium leading-none text-[#181818]'>\n {title}\n </h2>\n <p className='RemoteFlows__EstimationResultsHeader__Country text-xs text-[#71717A]'>\n {country.name} {region ? ` (${region.name})` : ''}\n </p>\n </div>\n </div>\n <ActionsDropdown\n className='RemoteFlows__EstimationResults__ActionsDropdown'\n actions={actions}\n />\n </div>\n );\n};\n\ninterface OnboardingTimelineStep {\n title: string;\n description: string;\n id: string;\n}\n\ninterface OnboardingTimelineData {\n steps: OnboardingTimelineStep[];\n helpText: string;\n zendeskArticleId?: number;\n}\n\nconst getOnboardingTimelineData = (): OnboardingTimelineData => {\n return {\n steps: [\n {\n id: 'add-employment-details',\n title: 'Add employment details',\n description: 'You add employee employments details.',\n },\n {\n id: 'invite-employee',\n title: 'Invite employee',\n description:\n 'Hire receives an email invitation from Remote to start the self-enrollment process.',\n },\n {\n id: 'verify-information',\n title: 'Verify information',\n description:\n 'Remote prepares the Employment Agreement and verifies all the information.',\n },\n {\n id: 'sign-contract',\n title: 'Sign contract',\n description:\n 'All parties sign the Employment Agreement and are ready to start. 🎉',\n },\n ],\n helpText:\n 'For customers who accept our Terms of Service (ToS), the employee onboarding timeline starts once the employee has been invited to the platform and completed self enrolment.',\n zendeskArticleId: zendeskArticles.employeeOnboardingTimeline,\n };\n};\n\nfunction OnboardingTimeline({\n minimumOnboardingDays,\n data,\n className,\n}: {\n minimumOnboardingDays: number | null;\n data: OnboardingTimelineData;\n className?: string;\n}) {\n return (\n <Accordion\n type='single'\n collapsible\n className={cn(\n 'RemoteFlows__EstimationResults__OnboardingTimeline w-full',\n className,\n )}\n >\n <AccordionItem\n value='timeline'\n className='RemoteFlows__OnboardingTimeline__AccordionItem border-border'\n >\n <AccordionTrigger className='RemoteFlows__OnboardingTimeline__AccordionTrigger hover:no-underline px-0 py-4'>\n <div className='flex items-center justify-between w-full'>\n <span className='RemoteFlows__OnboardingTimeline__Title text-base font-medium text-[#0F172A]'>\n Onboarding timeline\n </span>\n <span className='RemoteFlows__OnboardingTimeline__Description text-base text-muted-foreground mr-4'>\n {minimumOnboardingDays} days\n </span>\n </div>\n </AccordionTrigger>\n <AccordionContent className='px-0 pb-4'>\n <ul className='RemoteFlows__OnboardingTimeline__List list-disc list-inside space-y-2'>\n {data.steps.map((step) => (\n <li key={step.id}>\n <strong className='font-medium text-[#09090B]'>\n {step.title}\n </strong>{' '}\n - {step.description}\n </li>\n ))}\n </ul>\n <p className='RemoteFlows__OnboardingTimeline__HelpText text-xs text-muted-foreground mt-4'>\n {data.helpText}\n {data.zendeskArticleId && (\n <ZendeskTriggerButton zendeskId={data.zendeskArticleId}>\n Learn more\n </ZendeskTriggerButton>\n )}\n </p>\n </AccordionContent>\n </AccordionItem>\n </Accordion>\n );\n}\n\nfunction HiringSection({\n className,\n countryBenefitsUrl,\n countryGuideUrl,\n country,\n}: {\n className?: string;\n countryBenefitsUrl: string;\n countryGuideUrl: string;\n country: MinimalCountry;\n}) {\n return (\n <Accordion\n type='single'\n collapsible\n className={cn(\n 'RemoteFlows__EstimationResults__HiringSection w-full',\n className,\n )}\n >\n <AccordionItem\n value='timeline'\n className='RemoteFlows__HiringSection__AccordionItem border-border'\n >\n <AccordionTrigger className='RemoteFlows__HiringSection__AccordionTrigger hover:no-underline px-0 py-4'>\n <div className='flex items-center justify-between w-full'>\n <span className='text-base font-medium text-[#0F172A]'>\n Hiring in {country.name}\n </span>\n </div>\n </AccordionTrigger>\n <AccordionContent>\n <div className='flex flex-col gap-1'>\n <a\n href={countryGuideUrl}\n target='_blank'\n className='RemoteFlows__Link'\n >\n Explore our complete guide ↗\n </a>\n <a\n href={countryBenefitsUrl}\n target='_blank'\n className='RemoteFlows__Link'\n >\n Explore our available benefits ↗\n </a>\n </div>\n </AccordionContent>\n </AccordionItem>\n </Accordion>\n );\n}\n\nfunction EstimationHeaders({\n isMultipleCurrency,\n className,\n}: {\n isMultipleCurrency: boolean;\n className?: string;\n}) {\n return (\n <div\n className={cn(\n 'RemoteFlows__EstimationResults__Headers grid grid-cols-3 items-center',\n className,\n )}\n >\n <span aria-hidden />\n {isMultipleCurrency ? (\n <>\n <span className='RemoteFlows__EstimationResults__Headers__Label'>\n Employee currency\n </span>\n <span className='RemoteFlows__EstimationResults__Headers__Label'>\n Employer currency\n </span>\n </>\n ) : (\n <>\n <span></span>\n <span className='RemoteFlows__EstimationResults__Headers__Label'>\n Amount\n </span>\n </>\n )}\n </div>\n );\n}\n\nfunction EstimationRow({\n label,\n amounts,\n className,\n children,\n}: {\n label: string | React.ReactNode;\n amounts: string | string[];\n className?: string;\n children?: React.ReactNode;\n}) {\n const [isOpen, setIsOpen] = useState(true);\n\n return (\n <div className={cn('RemoteFlows__EstimationResults__Row', className)}>\n <div className='grid grid-cols-3 items-center'>\n <div className='flex items-center gap-2'>\n <span\n className={cn(\n 'RemoteFlows__EstimationRow__Title min-w-[140px] font-medium text-[#09090B]',\n )}\n >\n {label}\n </span>\n <button\n onClick={() => setIsOpen(!isOpen)}\n className='RemoteFlows__EstimationRow__CollapseButton p-1 hover:bg-gray-100 rounded'\n >\n <ChevronDown\n className={`h-4 w-4 text-muted-foreground transition-transform ${\n isOpen ? 'rotate-180' : ''\n }`}\n />\n </button>\n </div>\n\n {Array.isArray(amounts) ? (\n amounts.map((amount, index) => (\n <span\n key={index}\n className={cn(\n 'RemoteFlows__EstimationRow__RegionalAmount text-right font-medium text-[#09090B]',\n )}\n >\n {amount}\n </span>\n ))\n ) : (\n <>\n <span></span>\n <span\n className={cn(\n 'RemoteFlows__EstimationRow__EmployerAmount text-right font-medium text-[#09090B]',\n )}\n >\n {amounts}\n </span>\n </>\n )}\n </div>\n\n {/* Collapsible content */}\n {isOpen && children && (\n <div className='RemoteFlows__EstimationRow__CollapsibleContent mt-4'>\n {children}\n </div>\n )}\n </div>\n );\n}\n\ninterface BreakdownItem {\n label: string;\n tooltip?: string;\n regionalAmount?: string;\n employerAmount?: string;\n description?: string;\n zendeskId?: string;\n isCollapsible?: boolean;\n children?: BreakdownItem[];\n}\n\nfunction BreakdownListItem({\n item,\n isMultipleCurrency,\n level = 0,\n}: {\n item: BreakdownItem;\n isMultipleCurrency: boolean;\n level?: number;\n}) {\n const [isOpen, setIsOpen] = useState(false);\n const hasChildren = item.children && item.children.length > 0;\n const isNested = level > 0;\n\n return (\n <li\n className={cn(\n 'RemoteFlows__BreakdownList__Item pb-3',\n isNested && 'pb-1',\n )}\n >\n <div\n className={cn(\n isMultipleCurrency\n ? 'grid grid-cols-3 items-center justify-between'\n : 'grid grid-cols-2 items-center justify-between',\n )}\n >\n <div className={cn('flex items-center gap-2', isNested && 'pl-3')}>\n {!isNested && (\n <span\n className='RemoteFlows__BreakdownList__Bullet w-1 h-1 bg-[#09090B] rounded-full flex-shrink-0'\n aria-hidden='true'\n />\n )}\n\n <span\n className={cn(\n isNested\n ? 'RemoteFlows__BreakdownList__Text--Nested text-xs text-[#71717A]'\n : 'RemoteFlows__BreakdownList__Text--NotNested text-sm text-[#09090B]',\n )}\n >\n {item.label}\n </span>\n\n {item.tooltip && (\n <BasicTooltip\n content={\n <>\n <span>{item.tooltip}</span>{' '}\n {item.zendeskId && (\n <ZendeskTriggerButton zendeskId={Number(item.zendeskId)}>\n Learn more\n </ZendeskTriggerButton>\n )}\n </>\n }\n >\n <button className='RemoteFlows__BreakdownList__InfoButton p-1 hover:bg-gray-100 rounded'>\n <Info\n className={cn(\n 'text-muted-foreground',\n isNested ? 'h-3 w-3' : 'h-4 w-4',\n )}\n />\n </button>\n </BasicTooltip>\n )}\n\n {(item.isCollapsible || hasChildren) && (\n <button\n onClick={() => setIsOpen(!isOpen)}\n className='RemoteFlows__BreakdownList__CollapsibleButton p-1 hover:bg-gray-100 rounded'\n >\n <ChevronDown\n className={`h-3 w-3 text-muted-foreground transition-transform ${\n isOpen ? 'rotate-180' : ''\n }`}\n />\n </button>\n )}\n </div>\n\n {isMultipleCurrency ? (\n <>\n <span\n className={cn(\n 'RemoteFlows__BreakdownList__RegionalAmountText text-sm text-right',\n isNested\n ? 'RemoteFlows__BreakdownList__RegionalAmountText--Nested text-[#71717A]'\n : 'RemoteFlows__BreakdownList__RegionalAmountText--NotNested text-[#09090B]',\n )}\n >\n {item.regionalAmount || '—'}\n </span>\n <span\n className={cn(\n 'RemoteFlows__BreakdownList__EmployerAmountText text-sm text-right',\n isNested\n ? 'RemoteFlows__BreakdownList__EmployerAmountText--Nested text-[#71717A]'\n : 'RemoteFlows__BreakdownList__EmployerAmountText--NotNested text-[#09090B]',\n )}\n >\n {item.employerAmount || '—'}\n </span>\n </>\n ) : (\n <span\n className={cn(\n 'RemoteFlows__BreakdownList__RegionalAmountText text-sm text-right',\n isNested\n ? 'RemoteFlows__BreakdownList__RegionalAmountText--Nested text-[#71717A]'\n : 'RemoteFlows__BreakdownList__RegionalAmountText--NotNested text-[#09090B]',\n )}\n >\n {item.regionalAmount || '—'}\n </span>\n )}\n </div>\n\n {hasChildren && isOpen && (\n <div className='mt-1'>\n <BreakdownList\n items={item.children!}\n isMultipleCurrency={isMultipleCurrency}\n level={level + 1}\n />\n </div>\n )}\n </li>\n );\n}\n\ninterface BreakdownListProps {\n items: BreakdownItem[];\n isMultipleCurrency: boolean;\n className?: string;\n level?: number;\n}\n\nfunction BreakdownList({\n items,\n isMultipleCurrency,\n className,\n level,\n}: BreakdownListProps) {\n return (\n <ul className={cn('RemoteFlows__BreakdownList list-none', className)}>\n {items.map((item, index) => (\n <BreakdownListItem\n key={index}\n item={item}\n isMultipleCurrency={isMultipleCurrency}\n level={level}\n />\n ))}\n </ul>\n );\n}\n\ntype EstimationResultsComponents = {\n HiringSection?: React.ComponentType<{\n country: MinimalCountry;\n countryBenefitsUrl: string;\n countryGuideUrl: string;\n }>;\n OnboardingTimeline?: React.ComponentType<{\n minimumOnboardingDays: number | null;\n data: OnboardingTimelineData;\n }>;\n Header?: React.ComponentType<{\n title: string;\n region?: MinimalRegion;\n country: MinimalCountry;\n onDelete: () => void;\n onExportPdf: () => void;\n }>;\n Footer?: React.ComponentType;\n};\n\ntype EstimationResultsProps = {\n estimation: CostCalculatorEmployment;\n title: string;\n components?: EstimationResultsComponents;\n onDelete: () => void;\n onExportPdf: () => void;\n};\n\nexport const EstimationResults = ({\n estimation,\n title,\n components,\n onDelete,\n onExportPdf,\n}: EstimationResultsProps) => {\n const CustomHiringSection = components?.HiringSection || HiringSection;\n const CustomOnboardingTimeline =\n components?.OnboardingTimeline || OnboardingTimeline;\n const CustomHeader = components?.Header || EstimationResultsHeader;\n const CustomFooter = components?.Footer;\n\n const onboardingTimelineData = getOnboardingTimelineData();\n\n const isMultipleCurrency =\n estimation.employer_currency_costs.currency.code !==\n estimation.regional_currency_costs.currency.code;\n\n const hasManagementFee =\n estimation.employer_currency_costs.monthly_management_fee;\n\n const hasRegion = estimation.region.code !== estimation.country.code;\n\n return (\n <Card className='RemoteFlows__EstimationResults__Card p-10'>\n <div className='RemoteFlows__Separator'>\n <CustomHeader\n title={title}\n region={hasRegion ? estimation.region : undefined}\n country={estimation.country}\n onDelete={onDelete}\n onExportPdf={onExportPdf}\n />\n </div>\n <div className='RemoteFlows__Separator'>\n <EstimationHeaders\n isMultipleCurrency={isMultipleCurrency}\n className='mb-3'\n />\n <EstimationRow\n label='Monthly total cost'\n amounts={\n isMultipleCurrency\n ? [\n formatCurrency(\n estimation.regional_currency_costs.monthly_total,\n estimation.regional_currency_costs.currency.symbol,\n ),\n formatCurrency(\n estimation.employer_currency_costs.monthly_total,\n estimation.employer_currency_costs.currency.symbol,\n ),\n ]\n : formatCurrency(\n estimation.regional_currency_costs.monthly_total,\n estimation.regional_currency_costs.currency.symbol,\n )\n }\n >\n <BreakdownList\n items={[\n {\n label: 'Gross monthly salary',\n regionalAmount: formatCurrency(\n estimation.regional_currency_costs.monthly_gross_salary,\n estimation.regional_currency_costs.currency.symbol,\n ),\n employerAmount: formatCurrency(\n estimation.employer_currency_costs.monthly_gross_salary,\n estimation.employer_currency_costs.currency.symbol,\n ),\n zendeskId: zendeskArticles.extraPayments.toString(),\n tooltip:\n 'This country respects extra payments on top of the gross salary.',\n },\n {\n label: 'Mandatory employer costs',\n regionalAmount: formatCurrency(\n estimation.regional_currency_costs\n .monthly_contributions_total,\n estimation.regional_currency_costs.currency.symbol,\n ),\n employerAmount: formatCurrency(\n estimation.employer_currency_costs\n .monthly_contributions_total,\n estimation.employer_currency_costs.currency.symbol,\n ),\n children:\n estimation.employer_currency_costs.monthly_contributions_breakdown?.map(\n (item) => ({\n label: item.name,\n regionalAmount: formatCurrency(\n item.amount,\n estimation.regional_currency_costs.currency.symbol,\n ),\n employerAmount: formatCurrency(\n item.amount,\n estimation.employer_currency_costs.currency.symbol,\n ),\n zendeskId: item.zendesk_article_id || undefined,\n tooltip: item.description || undefined,\n }),\n ) || [],\n },\n {\n label: 'Core benefits',\n regionalAmount: formatCurrency(\n estimation.regional_currency_costs.monthly_benefits_total,\n estimation.regional_currency_costs.currency.symbol,\n ),\n employerAmount: formatCurrency(\n estimation.employer_currency_costs.monthly_benefits_total,\n estimation.employer_currency_costs.currency.symbol,\n ),\n children:\n estimation.employer_currency_costs.monthly_benefits_breakdown?.map(\n (item) => ({\n label: item.name,\n regionalAmount: formatCurrency(\n item.amount,\n estimation.regional_currency_costs.currency.symbol,\n ),\n employerAmount: formatCurrency(\n item.amount,\n estimation.employer_currency_costs.currency.symbol,\n ),\n zendeskId: item.zendesk_article_id || undefined,\n tooltip: item.description || undefined,\n }),\n ) || [],\n },\n ...(hasManagementFee\n ? [\n {\n label: 'Management fee',\n regionalAmount: formatCurrency(\n estimation.regional_currency_costs\n .monthly_management_fee,\n estimation.regional_currency_costs.currency.symbol,\n ),\n employerAmount: formatCurrency(\n estimation.employer_currency_costs\n .monthly_management_fee,\n estimation.employer_currency_costs.currency.symbol,\n ),\n tooltip:\n 'Discounts may be available based on your commitment and team size. Speak to your account or customer success manager to learn more.',\n },\n ]\n : []),\n ]}\n isMultipleCurrency={isMultipleCurrency}\n />\n </EstimationRow>\n </div>\n <div className='RemoteFlows__Separator'>\n <EstimationRow\n label='Annual total cost'\n amounts={\n isMultipleCurrency\n ? [\n formatCurrency(\n estimation.regional_currency_costs.annual_total,\n estimation.regional_currency_costs.currency.symbol,\n ),\n formatCurrency(\n estimation.employer_currency_costs.annual_total,\n estimation.employer_currency_costs.currency.symbol,\n ),\n ]\n : formatCurrency(\n estimation.regional_currency_costs.annual_total,\n estimation.regional_currency_costs.currency.symbol,\n )\n }\n >\n <BreakdownList\n items={[\n {\n label: 'Annual gross salary',\n regionalAmount: formatCurrency(\n estimation.regional_currency_costs.annual_gross_salary,\n estimation.regional_currency_costs.currency.symbol,\n ),\n employerAmount: formatCurrency(\n estimation.employer_currency_costs.annual_gross_salary,\n estimation.employer_currency_costs.currency.symbol,\n ),\n },\n {\n label: 'Mandatory employer costs',\n regionalAmount: formatCurrency(\n estimation.regional_currency_costs.annual_contributions_total,\n estimation.regional_currency_costs.currency.symbol,\n ),\n employerAmount: formatCurrency(\n estimation.employer_currency_costs.annual_contributions_total,\n estimation.employer_currency_costs.currency.symbol,\n ),\n children:\n estimation.employer_currency_costs.annual_contributions_breakdown?.map(\n (item) => ({\n label: item.name,\n regionalAmount: formatCurrency(\n item.amount,\n estimation.regional_currency_costs.currency.symbol,\n ),\n employerAmount: formatCurrency(\n item.amount,\n estimation.employer_currency_costs.currency.symbol,\n ),\n zendeskId: item.zendesk_article_id || undefined,\n tooltip: item.description || undefined,\n }),\n ) || [],\n },\n {\n label: 'Core benefits',\n regionalAmount: formatCurrency(\n estimation.regional_currency_costs.annual_benefits_total,\n estimation.regional_currency_costs.currency.symbol,\n ),\n employerAmount: formatCurrency(\n estimation.employer_currency_costs.annual_benefits_total,\n estimation.employer_currency_costs.currency.symbol,\n ),\n children:\n estimation.employer_currency_costs.annual_benefits_breakdown?.map(\n (item) => ({\n label: item.name,\n regionalAmount: formatCurrency(\n item.amount,\n estimation.regional_currency_costs.currency.symbol,\n ),\n employerAmount: formatCurrency(\n item.amount,\n estimation.employer_currency_costs.currency.symbol,\n ),\n zendeskId: item.zendesk_article_id || undefined,\n tooltip: item.description || undefined,\n }),\n ) || [],\n },\n {\n label: 'Extra statutory payments',\n regionalAmount: formatCurrency(\n estimation.regional_currency_costs\n .extra_statutory_payments_total,\n estimation.regional_currency_costs.currency.symbol,\n ),\n employerAmount: formatCurrency(\n estimation.employer_currency_costs\n .extra_statutory_payments_total,\n estimation.employer_currency_costs.currency.symbol,\n ),\n children:\n estimation.employer_currency_costs.extra_statutory_payments_breakdown?.map(\n (item) => ({\n label: item.name,\n regionalAmount: formatCurrency(\n item.amount,\n estimation.regional_currency_costs.currency.symbol,\n ),\n employerAmount: formatCurrency(\n item.amount,\n estimation.employer_currency_costs.currency.symbol,\n ),\n zendeskId: item.zendesk_article_id || undefined,\n tooltip: item.description || undefined,\n }),\n ) || [],\n },\n ...(hasManagementFee\n ? [\n {\n label: 'Management fee',\n regionalAmount: formatCurrency(\n estimation.regional_currency_costs\n .annual_management_fee,\n estimation.regional_currency_costs.currency.symbol,\n ),\n employerAmount: formatCurrency(\n estimation.employer_currency_costs\n .annual_management_fee,\n estimation.employer_currency_costs.currency.symbol,\n ),\n tooltip:\n 'Discounts may be available based on your commitment and team size. Speak to your account or customer success manager to learn more.',\n },\n ]\n : []),\n ]}\n isMultipleCurrency={isMultipleCurrency}\n />\n </EstimationRow>\n </div>\n <div className='RemoteFlows__Separator'>\n <CustomOnboardingTimeline\n minimumOnboardingDays={estimation.minimum_onboarding_time}\n data={onboardingTimelineData}\n />\n </div>\n\n <CustomHiringSection\n countryBenefitsUrl={estimation.country_benefits_details_url as string}\n countryGuideUrl={estimation.country_guide_url as string}\n country={estimation.country}\n />\n\n {CustomFooter && <CustomFooter />}\n </Card>\n );\n};\n"],"mappings":"4VAEA,OAAS,kBAAAA,MAAsB,eAC/B,OAAS,YAAAC,MAAgC,QA4BjC,OAIA,YAAAC,EAJA,OAAAC,EAIA,QAAAC,MAJA,oBAbD,SAASC,EAAgB,CAC9B,QAAAC,EAAU,CAAC,EACX,UAAAC,CACF,EAAyB,CACvB,GAAM,CAACC,EAAQC,CAAS,EAAIC,EAAS,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EAAW,wBAAwB,SAAS,MAC9C,EACA,UAAWT,EAAK,oBAAsB,OACtC,QAASA,EAAK,aAAe,MAC/B,EACF,GAAK,CAAC,CACV,EACA,GAAIgB,EACA,CACE,CACE,MAAO,iBACP,eAAgBG,EACdV,EAAW,wBACR,sBACHA,EAAW,wBAAwB,SAAS,MAC9C,EACA,eAAgBU,EACdV,EAAW,wBACR,sBACHA,EAAW,wBAAwB,SAAS,MAC9C,EACA,QACE,qIACJ,CACF,EACA,CAAC,CACP,EACA,mBAAoBrB,EACtB,EACF,EACF,EACA7B,EAAC,OAAI,UAAU,yBACb,SAAAA,EAACqD,EAAA,CACC,sBAAuBH,EAAW,wBAClC,KAAMM,EACR,EACF,EAEAxD,EAACoD,EAAA,CACC,mBAAoBF,EAAW,6BAC/B,gBAAiBA,EAAW,kBAC5B,QAASA,EAAW,QACtB,EAECK,GAAgBvD,EAACuD,EAAA,EAAa,GACjC,CAEJ,EAzTiC","names":["MoreHorizontal","useState","Fragment","jsx","jsxs","ActionsDropdown","actions","className","isOpen","setIsOpen","useState","cn","Button","MoreHorizontal","action","index","__name","ChevronDown","Info","Flag","useState","Fragment","jsx","jsxs","EstimationResultsHeader","__name","title","country","region","onDelete","onExportPdf","actions","Flag","ActionsDropdown","getOnboardingTimelineData","zendeskArticles","OnboardingTimeline","minimumOnboardingDays","data","className","Accordion","cn","AccordionItem","AccordionTrigger","AccordionContent","step","ZendeskTriggerButton","HiringSection","countryBenefitsUrl","countryGuideUrl","EstimationHeaders","isMultipleCurrency","EstimationRow","label","amounts","children","isOpen","setIsOpen","useState","ChevronDown","amount","index","BreakdownListItem","item","level","hasChildren","isNested","BasicTooltip","Info","BreakdownList","items","EstimationResults","estimation","components","CustomHiringSection","CustomOnboardingTimeline","CustomHeader","CustomFooter","onboardingTimelineData","hasManagementFee","hasRegion","Card","formatCurrency"]}
@@ -1,2 +1,2 @@
1
- import{a}from"./chunk-DVQO5MHI.js";import{b as i}from"./chunk-PGWKJ6FK.js";import{a as e}from"./chunk-P37U34EQ.js";import{jsx as d}from"react/jsx-runtime";function y({onSubmit:s,onSuccess:c,onError:t}){let{onboardingBag:o}=i(),u=e(async n=>{try{await s?.({countryCode:n.country});let r=await o.onSubmit(n);if(r?.data){await c?.(r?.data),o?.next();return}r?.error&&t?.({error:r.error,rawError:r.rawError,fieldErrors:[]})}catch(r){t?.({error:r,rawError:r,fieldErrors:[]})}},"handleSubmit"),l=o.stepState.values?.select_country||o.initialValues.select_country;return d(a,{defaultValues:l,onSubmit:u})}e(y,"SelectCountryStep");export{y as a};
2
- //# sourceMappingURL=chunk-3F7QLHMP.js.map
1
+ import{a}from"./chunk-4XFRZVAL.js";import{b as i}from"./chunk-PGWKJ6FK.js";import{a as e}from"./chunk-P37U34EQ.js";import{jsx as d}from"react/jsx-runtime";function y({onSubmit:s,onSuccess:c,onError:t}){let{onboardingBag:o}=i(),u=e(async n=>{try{await s?.({countryCode:n.country});let r=await o.onSubmit(n);if(r?.data){await c?.(r?.data),o?.next();return}r?.error&&t?.({error:r.error,rawError:r.rawError,fieldErrors:[]})}catch(r){t?.({error:r,rawError:r,fieldErrors:[]})}},"handleSubmit"),l=o.stepState.values?.select_country||o.initialValues.select_country;return d(a,{defaultValues:l,onSubmit:u})}e(y,"SelectCountryStep");export{y as a};
2
+ //# sourceMappingURL=chunk-RXVVLN7R.js.map
@@ -1,2 +1,2 @@
1
1
  import{a as t}from"./chunk-3LOVCTCN.js";import{a as e}from"./chunk-P37U34EQ.js";import{jsx as o}from"react/jsx-runtime";function a({className:i,type:r,...n}){return o("input",{type:r,"data-slot":"input",className:t("shadow-xs border-input file:text-foreground placeholder:text-muted-foreground flex h-9 w-full min-w-0 rounded-xl border bg-transparent px-4 py-7 text-sm transition-[color] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm","focus-visible:border-focused","aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",i),...n})}e(a,"Input");export{a};
2
- //# sourceMappingURL=chunk-CHSULXMN.js.map
2
+ //# sourceMappingURL=chunk-TXSJL3HC.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/components/ui/input.tsx"],"sourcesContent":["import * as React from 'react';\n\nimport { cn } from '@/src/lib/utils';\n\nfunction Input({ className, type, ...props }: React.ComponentProps<'input'>) {\n return (\n <input\n type={type}\n data-slot='input'\n className={cn(\n 'shadow-xs border-input file:text-foreground placeholder:text-muted-foreground flex h-9 w-full min-w-0 rounded-xl border bg-transparent px-4 py-7 text-sm transition-[color] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm',\n 'focus-visible:border-focused',\n 'aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive',\n className,\n )}\n {...props}\n />\n );\n}\n\nexport { Input };\n"],"mappings":"gFAMI,cAAAA,MAAA,oBAFJ,SAASC,EAAM,CAAE,UAAAC,EAAW,KAAAC,EAAM,GAAGC,CAAM,EAAkC,CAC3E,OACEJ,EAAC,SACC,KAAMG,EACN,YAAU,QACV,UAAWE,EACT,6WACA,+BACA,yGACAH,CACF,EACC,GAAGE,EACN,CAEJ,CAdSE,EAAAL,EAAA","names":["jsx","Input","className","type","props","cn","__name"]}
@@ -1,2 +1,2 @@
1
1
  import{a as r}from"./chunk-3LOVCTCN.js";import{a as t}from"./chunk-P37U34EQ.js";import{jsx as a}from"react/jsx-runtime";function c({className:e,direction:o="col",...d}){return a("div",{"data-slot":"card",className:r("RemoteFlows__Card bg-white text-card-foreground rounded-[10px] gap-4 border border-gray-200 px-10 py-14",o==="row"?"flex flex-row":"flex flex-col",e),...d})}t(c,"Card");function s({className:e,...o}){return a("div",{"data-slot":"card-header",className:r("flex flex-col gap-1.5 px-6",e),...o})}t(s,"CardHeader");function i({className:e,...o}){return a("div",{"data-slot":"card-title",className:r("leading-none font-semibold",e),...o})}t(i,"CardTitle");function l({className:e,...o}){return a("div",{"data-slot":"card-description",className:r("text-sm",e),...o})}t(l,"CardDescription");function p({className:e,...o}){return a("div",{"data-slot":"card-content",className:r("px-6",e),...o})}t(p,"CardContent");function f({className:e,...o}){return a("div",{"data-slot":"card-footer",className:r("flex items-center px-6",e),...o})}t(f,"CardFooter");export{c as a,s as b,i as c,l as d,p as e,f};
2
- //# sourceMappingURL=chunk-5I6VWJSC.js.map
2
+ //# sourceMappingURL=chunk-UHS3QRA3.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/components/ui/card.tsx"],"sourcesContent":["import * as React from 'react';\n\nimport { cn } from '@/src/lib/utils';\n\ninterface CardProps extends React.ComponentProps<'div'> {\n direction?: 'row' | 'col';\n}\n\nfunction Card({ className, direction = 'col', ...props }: CardProps) {\n return (\n <div\n data-slot='card'\n className={cn(\n 'RemoteFlows__Card bg-white text-card-foreground rounded-[10px] gap-4 border border-gray-200 px-10 py-14',\n direction === 'row' ? 'flex flex-row' : 'flex flex-col',\n className,\n )}\n {...props}\n />\n );\n}\n\nfunction CardHeader({ className, ...props }: React.ComponentProps<'div'>) {\n return (\n <div\n data-slot='card-header'\n className={cn('flex flex-col gap-1.5 px-6', className)}\n {...props}\n />\n );\n}\n\nfunction CardTitle({ className, ...props }: React.ComponentProps<'div'>) {\n return (\n <div\n data-slot='card-title'\n className={cn('leading-none font-semibold', className)}\n {...props}\n />\n );\n}\n\nfunction CardDescription({ className, ...props }: React.ComponentProps<'div'>) {\n return (\n <div\n data-slot='card-description'\n className={cn('text-sm', className)}\n {...props}\n />\n );\n}\n\nfunction CardContent({ className, ...props }: React.ComponentProps<'div'>) {\n return (\n <div\n data-slot='card-content'\n className={cn('px-6', className)}\n {...props}\n />\n );\n}\n\nfunction CardFooter({ className, ...props }: React.ComponentProps<'div'>) {\n return (\n <div\n data-slot='card-footer'\n className={cn('flex items-center px-6', className)}\n {...props}\n />\n );\n}\n\nexport {\n Card,\n CardHeader,\n CardFooter,\n CardTitle,\n CardDescription,\n CardContent,\n};\n"],"mappings":"gFAUI,cAAAA,MAAA,oBAFJ,SAASC,EAAK,CAAE,UAAAC,EAAW,UAAAC,EAAY,MAAO,GAAGC,CAAM,EAAc,CACnE,OACEJ,EAAC,OACC,YAAU,OACV,UAAWK,EACT,0GACAF,IAAc,MAAQ,gBAAkB,gBACxCD,CACF,EACC,GAAGE,EACN,CAEJ,CAZSE,EAAAL,EAAA,QAcT,SAASM,EAAW,CAAE,UAAAL,EAAW,GAAGE,CAAM,EAAgC,CACxE,OACEJ,EAAC,OACC,YAAU,cACV,UAAWK,EAAG,6BAA8BH,CAAS,EACpD,GAAGE,EACN,CAEJ,CARSE,EAAAC,EAAA,cAUT,SAASC,EAAU,CAAE,UAAAN,EAAW,GAAGE,CAAM,EAAgC,CACvE,OACEJ,EAAC,OACC,YAAU,aACV,UAAWK,EAAG,6BAA8BH,CAAS,EACpD,GAAGE,EACN,CAEJ,CARSE,EAAAE,EAAA,aAUT,SAASC,EAAgB,CAAE,UAAAP,EAAW,GAAGE,CAAM,EAAgC,CAC7E,OACEJ,EAAC,OACC,YAAU,mBACV,UAAWK,EAAG,UAAWH,CAAS,EACjC,GAAGE,EACN,CAEJ,CARSE,EAAAG,EAAA,mBAUT,SAASC,EAAY,CAAE,UAAAR,EAAW,GAAGE,CAAM,EAAgC,CACzE,OACEJ,EAAC,OACC,YAAU,eACV,UAAWK,EAAG,OAAQH,CAAS,EAC9B,GAAGE,EACN,CAEJ,CARSE,EAAAI,EAAA,eAUT,SAASC,EAAW,CAAE,UAAAT,EAAW,GAAGE,CAAM,EAAgC,CACxE,OACEJ,EAAC,OACC,YAAU,cACV,UAAWK,EAAG,yBAA0BH,CAAS,EAChD,GAAGE,EACN,CAEJ,CARSE,EAAAK,EAAA","names":["jsx","Card","className","direction","props","cn","__name","CardHeader","CardTitle","CardDescription","CardContent","CardFooter"]}
@@ -1,2 +1,2 @@
1
1
  import{a as t}from"./chunk-P37U34EQ.js";import{Fragment as u,jsx as s,jsxs as n}from"react/jsx-runtime";var i=t((a,e)=>`${a} ${e}`,"formatMoney"),m=t(({offerEquity:a,equityCost:e})=>{let l=a==="yes",r=!!e?.discount,c=e&&e.original?i(e.original.amount,e.original.currency):null,o=e&&e.calculated?i(e.calculated.amount,e.calculated.currency):null;return!l||!e?null:n("div",{className:"RemoteFlows__EquityPriceDetails",children:[n("span",{className:"RemoteFlows__Equity__Price",children:["A monthly fee of"," ",n("strong",{children:[r?n(u,{children:[s("s",{children:c})," ",o]}):o," ","will apply."]})]}),s("span",{className:"RemoteFlows__Equity__Fee",children:"This is a fee for managing equity through Remote."}),s("span",{className:"RemoteFlows__Equity__Reporting",children:"To fulfill local reporting obligations, Remote must note any equity grants made and any related taxable events, such as exercising stock options and RSU vesting."})]})},"EquityPriceDetails");export{m as a};
2
- //# sourceMappingURL=chunk-2A5R3YN2.js.map
2
+ //# sourceMappingURL=chunk-VAIBLWOY.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/flows/Onboarding/components/EquityPriceDetails.tsx"],"sourcesContent":["const formatMoney = (amount: number, currency: string) => {\n return `${amount} ${currency}`;\n};\n\ntype Cost = {\n currency: string;\n amount: number;\n};\n\ntype EquityPriceDetailsProps = {\n offerEquity: 'yes' | 'no' | null;\n equityCost?: {\n original: Cost;\n discount?: Cost;\n\n calculated?: Cost;\n };\n};\n\nexport const EquityPriceDetails = ({\n offerEquity,\n equityCost,\n}: EquityPriceDetailsProps) => {\n const offersEquity = offerEquity === 'yes';\n const isFeeWaived = !!equityCost?.discount;\n const formattedWaivedPrice =\n equityCost && equityCost.original\n ? formatMoney(equityCost.original.amount, equityCost.original.currency)\n : null;\n const formattedPrice =\n equityCost && equityCost.calculated\n ? formatMoney(\n equityCost.calculated.amount,\n equityCost.calculated.currency,\n )\n : null;\n\n if (!offersEquity || !equityCost) {\n return null;\n }\n\n return (\n <div className='RemoteFlows__EquityPriceDetails'>\n <span className='RemoteFlows__Equity__Price'>\n A monthly fee of{' '}\n <strong>\n {isFeeWaived ? (\n <>\n <s>{formattedWaivedPrice}</s> {formattedPrice}\n </>\n ) : (\n formattedPrice\n )}{' '}\n will apply.\n </strong>\n </span>\n <span className='RemoteFlows__Equity__Fee'>\n This is a fee for managing equity through Remote.\n </span>\n <span className='RemoteFlows__Equity__Reporting'>\n To fulfill local reporting obligations, Remote must note any equity\n grants made and any related taxable events, such as exercising stock\n options and RSU vesting.\n </span>\n </div>\n );\n};\n"],"mappings":"wCA+CY,mBAAAA,EACE,OAAAC,EADF,QAAAC,MAAA,oBA/CZ,IAAMC,EAAcC,EAAA,CAACC,EAAgBC,IAC5B,GAAGD,CAAM,IAAIC,CAAQ,GADV,eAmBPC,EAAqBH,EAAA,CAAC,CACjC,YAAAI,EACA,WAAAC,CACF,IAA+B,CAC7B,IAAMC,EAAeF,IAAgB,MAC/BG,EAAc,CAAC,CAACF,GAAY,SAC5BG,EACJH,GAAcA,EAAW,SACrBN,EAAYM,EAAW,SAAS,OAAQA,EAAW,SAAS,QAAQ,EACpE,KACAI,EACJJ,GAAcA,EAAW,WACrBN,EACEM,EAAW,WAAW,OACtBA,EAAW,WAAW,QACxB,EACA,KAEN,MAAI,CAACC,GAAgB,CAACD,EACb,KAIPP,EAAC,OAAI,UAAU,kCACb,UAAAA,EAAC,QAAK,UAAU,6BAA6B,6BAC1B,IACjBA,EAAC,UACE,UAAAS,EACCT,EAAAF,EAAA,CACE,UAAAC,EAAC,KAAG,SAAAW,EAAqB,EAAI,IAAEC,GACjC,EAEAA,EACC,IAAI,eAET,GACF,EACAZ,EAAC,QAAK,UAAU,2BAA2B,6DAE3C,EACAA,EAAC,QAAK,UAAU,iCAAiC,6KAIjD,GACF,CAEJ,EA/CkC","names":["Fragment","jsx","jsxs","formatMoney","__name","amount","currency","EquityPriceDetails","offerEquity","equityCost","offersEquity","isFeeWaived","formattedWaivedPrice","formattedPrice"]}
@@ -1,2 +1,2 @@
1
- import{a as S}from"./chunk-XFD3ULUF.js";import{a as g}from"./chunk-WWANHPT7.js";import{a as P}from"./chunk-DR7VGNO2.js";import{a as F}from"./chunk-S4XU4SE7.js";import{a as y}from"./chunk-Z5WMKCRJ.js";import{a as V}from"./chunk-QW4JPW6J.js";import{b as p}from"./chunk-EGQJ7UBR.js";import{a as T}from"./chunk-PJBAQZ6G.js";import{d as _}from"./chunk-3ZWDIEEM.js";import{c as s}from"./chunk-MXFDOIUA.js";import{a as e}from"./chunk-P37U34EQ.js";import{createHeadlessForm as h,modify as x}from"@remoteoss/json-schema-form";import{useMutation as K,useQuery as L}from"@tanstack/react-query";import q from"lodash.omitby";import A from"lodash.isnull";import R from"lodash.omit";function z(o){return{confidential:"",customer_informed_employee:"",customer_informed_employee_date:"",customer_informed_employee_description:"",personal_email:"",termination_reason:void 0,reason_description:"",termination_reason_files:[],will_challenge_termination:"",will_challenge_termination_description:null,agrees_to_pto_amount:"",agrees_to_pto_amount_notes:null,acknowledge_termination_procedure:!1,additional_comments:"",proposed_termination_date:"",risk_assessment_reasons:[],timesheet_file:void 0,...o}}e(z,"buildInitialValues");var B=e(()=>{let{client:o}=_();return K({mutationFn:e(n=>p({client:o,body:n}),"mutationFn")})},"useCreateTermination"),I=e(({formValues:o,jsfModify:n,step:m})=>L({queryKey:["rmt-flows-termination-schema",m],queryFn:e(()=>P[m]??S,"queryFn"),select:e(({data:u})=>{let i=u?.schema||{};if(n){let{schema:d}=x(i,n);i=d}return h(i||{},{initialValues:o||{}})},"select")}),"useTerminationSchema"),ue=e(({employmentId:o,options:n})=>{let{fieldValues:m,setFieldValues:u,stepState:i,previousStep:f,nextStep:d}=T(F),k={...i.values?.[i.currentStep.name],...m},{data:r,isLoading:w}=I({formValues:k,jsfModify:n?.jsfModify,step:i.currentStep.name}),l=h(g.data.schema),c=B(),{mutateAsync:b}=V(c);async function C(a){if(!o)throw new Error("Employment id is missing");if(r){let t=s(a,l.fields,{isPartialValidation:!0}),{customer_informed_employee:j}=t,D=j==="yes"?{employee_awareness:{date:t.customer_informed_employee_date,note:t.customer_informed_employee_description}}:void 0,H=y(t,["agrees_to_pto_amount","confidential","customer_informed_employee","will_challenge_termination"]),J=R(H,"customer_informed_employee_date","customer_informed_employee_description"),O=q({...J,...D},A);return b({employment_id:o,termination_details:O,type:"termination"})}}e(C,"onSubmit");function M(){f()}e(M,"back");function v(){d()}e(v,"next");let E=z({...i.values?.employee_communication,...i.values?.termination_details,...i.values?.paid_time_off,...i.values?.additional_information});return{employmentId:o,stepState:i,fields:r?.fields||[],isLoading:w,isSubmitting:c.isPending,initialValues:E,handleValidation:e(a=>{if(r){let t=s(a,r?.fields);return r?.handleValidation(t)}return null},"handleValidation"),checkFieldUpdates:e(a=>{if(l){let t=s(a,l?.fields,{isPartialValidation:!0});u(t)}},"checkFieldUpdates"),parseFormValues:e(a=>s(a,l.fields,{isPartialValidation:!0}),"parseFormValues"),onSubmit:C,back:M,next:v}},"useTermination");export{ue as a};
2
- //# sourceMappingURL=chunk-R2SDR47E.js.map
1
+ import{a as S}from"./chunk-XFD3ULUF.js";import{a as g}from"./chunk-WWANHPT7.js";import{a as P}from"./chunk-HSW5HMHH.js";import{a as F}from"./chunk-S4XU4SE7.js";import{a as y}from"./chunk-Z5WMKCRJ.js";import{a as V}from"./chunk-QW4JPW6J.js";import{b as p}from"./chunk-EGQJ7UBR.js";import{a as T}from"./chunk-PJBAQZ6G.js";import{d as _}from"./chunk-3ZWDIEEM.js";import{c as s}from"./chunk-MXFDOIUA.js";import{a as e}from"./chunk-P37U34EQ.js";import{createHeadlessForm as h,modify as x}from"@remoteoss/json-schema-form";import{useMutation as K,useQuery as L}from"@tanstack/react-query";import q from"lodash.omitby";import A from"lodash.isnull";import R from"lodash.omit";function z(o){return{confidential:"",customer_informed_employee:"",customer_informed_employee_date:"",customer_informed_employee_description:"",personal_email:"",termination_reason:void 0,reason_description:"",termination_reason_files:[],will_challenge_termination:"",will_challenge_termination_description:null,agrees_to_pto_amount:"",agrees_to_pto_amount_notes:null,acknowledge_termination_procedure:!1,additional_comments:"",proposed_termination_date:"",risk_assessment_reasons:[],timesheet_file:void 0,...o}}e(z,"buildInitialValues");var B=e(()=>{let{client:o}=_();return K({mutationFn:e(n=>p({client:o,body:n}),"mutationFn")})},"useCreateTermination"),I=e(({formValues:o,jsfModify:n,step:m})=>L({queryKey:["rmt-flows-termination-schema",m],queryFn:e(()=>P[m]??S,"queryFn"),select:e(({data:u})=>{let i=u?.schema||{};if(n){let{schema:d}=x(i,n);i=d}return h(i||{},{initialValues:o||{}})},"select")}),"useTerminationSchema"),ue=e(({employmentId:o,options:n})=>{let{fieldValues:m,setFieldValues:u,stepState:i,previousStep:f,nextStep:d}=T(F),k={...i.values?.[i.currentStep.name],...m},{data:r,isLoading:w}=I({formValues:k,jsfModify:n?.jsfModify,step:i.currentStep.name}),l=h(g.data.schema),c=B(),{mutateAsync:b}=V(c);async function C(a){if(!o)throw new Error("Employment id is missing");if(r){let t=s(a,l.fields,{isPartialValidation:!0}),{customer_informed_employee:j}=t,D=j==="yes"?{employee_awareness:{date:t.customer_informed_employee_date,note:t.customer_informed_employee_description}}:void 0,H=y(t,["agrees_to_pto_amount","confidential","customer_informed_employee","will_challenge_termination"]),J=R(H,"customer_informed_employee_date","customer_informed_employee_description"),O=q({...J,...D},A);return b({employment_id:o,termination_details:O,type:"termination"})}}e(C,"onSubmit");function M(){f()}e(M,"back");function v(){d()}e(v,"next");let E=z({...i.values?.employee_communication,...i.values?.termination_details,...i.values?.paid_time_off,...i.values?.additional_information});return{employmentId:o,stepState:i,fields:r?.fields||[],isLoading:w,isSubmitting:c.isPending,initialValues:E,handleValidation:e(a=>{if(r){let t=s(a,r?.fields);return r?.handleValidation(t)}return null},"handleValidation"),checkFieldUpdates:e(a=>{if(l){let t=s(a,l?.fields,{isPartialValidation:!0});u(t)}},"checkFieldUpdates"),parseFormValues:e(a=>s(a,l.fields,{isPartialValidation:!0}),"parseFormValues"),onSubmit:C,back:M,next:v}},"useTermination");export{ue as a};
2
+ //# sourceMappingURL=chunk-XCZYKOZU.js.map
@@ -1,2 +1,2 @@
1
- import{b as c}from"./chunk-MRYRNB7Y.js";import{b as e}from"./chunk-3ZWDIEEM.js";import{b as m}from"./chunk-CSK44J23.js";import{a as u}from"./chunk-P37U34EQ.js";import{jsx as s}from"react/jsx-runtime";function f({children:n,...t}){let{terminationBag:{back:i}}=c(),{components:B}=e(),r=B?.button;return r?s(r,{...t,onClick:o=>{i(),t.onClick?.(o)},children:n}):s(m,{...t,onClick:o=>{i(),t.onClick?.(o)},children:n})}u(f,"TerminationBack");export{f as a};
2
- //# sourceMappingURL=chunk-4OEBYZLZ.js.map
1
+ import{b as c}from"./chunk-MRYRNB7Y.js";import{b as e}from"./chunk-3ZWDIEEM.js";import{b as m}from"./chunk-7VUILYZ3.js";import{a as u}from"./chunk-P37U34EQ.js";import{jsx as s}from"react/jsx-runtime";function f({children:n,...t}){let{terminationBag:{back:i}}=c(),{components:B}=e(),r=B?.button;return r?s(r,{...t,onClick:o=>{i(),t.onClick?.(o)},children:n}):s(m,{...t,onClick:o=>{i(),t.onClick?.(o)},children:n})}u(f,"TerminationBack");export{f as a};
2
+ //# sourceMappingURL=chunk-XGEKV3FC.js.map
@@ -1,2 +1,2 @@
1
1
  import{a as t}from"./chunk-3LOVCTCN.js";import{a as o}from"./chunk-P37U34EQ.js";import*as r from"@radix-ui/react-separator";import{jsx as p}from"react/jsx-runtime";function m({className:a,orientation:i="horizontal",decorative:e=!0,...n}){return p(r.Root,{"data-slot":"separator-root",decorative:e,orientation:i,className:t("bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px",a),...n})}o(m,"Separator");export{m as a};
2
- //# sourceMappingURL=chunk-MDSGLUUB.js.map
2
+ //# sourceMappingURL=chunk-XJVYASHX.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/components/ui/separator.tsx"],"sourcesContent":["import * as React from 'react';\nimport * as SeparatorPrimitive from '@radix-ui/react-separator';\n\nimport { cn } from '@/src/lib/utils';\n\nfunction Separator({\n className,\n orientation = 'horizontal',\n decorative = true,\n ...props\n}: React.ComponentProps<typeof SeparatorPrimitive.Root>) {\n return (\n <SeparatorPrimitive.Root\n data-slot='separator-root'\n decorative={decorative}\n orientation={orientation}\n className={cn(\n 'bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px',\n className,\n )}\n {...props}\n />\n );\n}\n\nexport { Separator };\n"],"mappings":"gFACA,UAAYA,MAAwB,4BAWhC,cAAAC,MAAA,oBAPJ,SAASC,EAAU,CACjB,UAAAC,EACA,YAAAC,EAAc,aACd,WAAAC,EAAa,GACb,GAAGC,CACL,EAAyD,CACvD,OACEL,EAAoB,OAAnB,CACC,YAAU,iBACV,WAAYI,EACZ,YAAaD,EACb,UAAWG,EACT,iKACAJ,CACF,EACC,GAAGG,EACN,CAEJ,CAlBSE,EAAAN,EAAA","names":["SeparatorPrimitive","jsx","Separator","className","orientation","decorative","props","cn","__name"]}
@@ -0,0 +1,2 @@
1
+ import{b as u}from"./chunk-CFIJKJXD.js";import{a as F}from"./chunk-LK4XMOCE.js";import{f as l,g as p}from"./chunk-3BREUYLG.js";import{c as f}from"./chunk-MXFDOIUA.js";import{b as _}from"./chunk-TVZAFTPT.js";import{a as r}from"./chunk-P37U34EQ.js";import{useEffect as R}from"react";import{jsx as a}from"react/jsx-runtime";var w=["effective_date","reason_for_change","reason_for_change_description","additional_comments","additional_comments_toggle"];function x({onSubmit:b,onError:m,onSuccess:A}){let{formId:C,contractAmendment:{checkFieldUpdates:h,fields:s,onSubmit:S,stepState:g,initialValues:i,handleValidation:y}}=_(),V=u(y),e=l({resolver:V,defaultValues:g.values?.form||i,shouldUnregister:!0,mode:"onBlur"});R(()=>{let t=e?.watch(o=>{(Object.keys(e.formState.dirtyFields).length>0||e.formState.isDirty)&&h(o)});return()=>t?.unsubscribe()},[]);let v=r(async t=>{let o=!1;for(let[c,P]of Object.entries(t))if(!w.includes(c)&&i[c]!==P){o=!0;break}if(!o)return m?.({message:"no_changes_detected_contract_details"});let d=f(t,s,{isPartialValidation:!1});await b?.(d);let n=await S(t);n.error?m?.(n.error):await A?.(n.data)},"handleSubmit");return a(p,{...e,children:a("form",{id:C,"data-testid":"contract-amendment-form",onSubmit:e.handleSubmit(v),className:"space-y-4 RemoteFlows__ContractAmendmentForm",children:a(F,{fields:s})})})}r(x,"ContractAmendmentForm");export{x as a};
2
+ //# sourceMappingURL=chunk-XZRGLKXU.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/flows/ContractAmendment/ContractAmendmentForm.tsx"],"sourcesContent":["import {\n ContractAmendmentAutomatableResponse,\n PostAutomatableContractAmendmentError,\n} from '@/src/client';\nimport { JSONSchemaFormFields } from '@/src/components/form/JSONSchemaForm';\nimport { parseJSFToValidate } from '@/src/components/form/utils';\nimport { useJsonSchemasValidationFormResolver } from '@/src/components/form/yupValidationResolver';\nimport { Form } from '@/src/components/ui/form';\nimport { useEffect } from 'react';\nimport { FieldValues, useForm } from 'react-hook-form';\nimport { useContractAmendmentContext } from './context';\n\ntype ContractAmendmentFormProps = {\n /**\n * Callback function to be called when the contract amendment form is submitted.\n * This function is called before the contract amendment is submitted.\n * It can be used to perform any additional validation or processing before\n * the contract amendment is submitted.\n * @param values\n * @returns\n */\n onSubmit?: (values: FieldValues) => void | Promise<void>;\n /**\n * Callback function to be called when the contract amendment fails.\n * @param error\n * @returns\n */\n onError?: (\n error:\n | PostAutomatableContractAmendmentError\n | { message: 'no_changes_detected_contract_details' },\n ) => void;\n /**\n * Callback function to be called when the contract amendment is successfully submitted.\n * This function is called after the contract amendment is submitted.\n * @param data\n * @returns\n */\n onSuccess?: (\n data: ContractAmendmentAutomatableResponse,\n ) => void | Promise<void>;\n};\n\nconst commonFields = [\n 'effective_date',\n 'reason_for_change',\n 'reason_for_change_description',\n 'additional_comments',\n 'additional_comments_toggle',\n] as const;\n\ntype CommonFields = (typeof commonFields)[number];\n\nexport function ContractAmendmentForm({\n onSubmit,\n onError,\n onSuccess,\n}: ContractAmendmentFormProps) {\n const {\n formId,\n contractAmendment: {\n checkFieldUpdates,\n fields,\n onSubmit: submitContractAmendment,\n stepState,\n initialValues,\n handleValidation,\n },\n } = useContractAmendmentContext();\n\n const resolver = useJsonSchemasValidationFormResolver(\n // @ts-expect-error no matching type\n handleValidation,\n );\n\n const form = useForm({\n resolver,\n defaultValues:\n // stepState.values is used as defaultValues for the form when the form is\n // rendered when clicking on the back button after the user has submitted the form\n // and the confirmation form is displayed.\n // This is because the form is unmounted when the user submits the form.\n stepState.values?.form || initialValues,\n shouldUnregister: true,\n mode: 'onBlur',\n });\n\n useEffect(() => {\n const subscription = form?.watch((values) => {\n const isFormDirty =\n Object.keys(form.formState.dirtyFields).length > 0 ||\n form.formState.isDirty;\n if (isFormDirty) {\n checkFieldUpdates(values);\n }\n });\n return () => subscription?.unsubscribe();\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n\n const handleSubmit = async (values: FieldValues) => {\n let hasContractDetailsChanges = false;\n for (const [key, value] of Object.entries(values)) {\n if (\n !commonFields.includes(key as CommonFields) &&\n // @ts-expect-error error\n initialValues[key] !== value\n ) {\n hasContractDetailsChanges = true;\n break;\n }\n }\n\n if (!hasContractDetailsChanges) {\n return onError?.({\n message: 'no_changes_detected_contract_details',\n });\n }\n\n const parsedValues = parseJSFToValidate(values, fields, {\n isPartialValidation: false,\n });\n\n await onSubmit?.(parsedValues);\n\n const contractAmendmentResult = await submitContractAmendment(values);\n\n if (contractAmendmentResult.error) {\n onError?.(contractAmendmentResult.error);\n } else {\n await onSuccess?.(\n contractAmendmentResult.data as ContractAmendmentAutomatableResponse,\n );\n }\n };\n\n return (\n <Form {...form}>\n <form\n id={formId}\n data-testid=\"contract-amendment-form\"\n onSubmit={form.handleSubmit(handleSubmit)}\n className=\"space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MAAMvB,IACJuB,EAAwB,IAC1B,CAEJ,EAlCqB,gBAoCrB,OACE5B,EAAC6B,EAAA,CAAM,GAAGb,EACR,SAAAhB,EAAC,QACC,GAAIM,EACJ,cAAY,0BACZ,SAAUU,EAAK,aAAaK,CAAY,EACxC,UAAU,+CAEV,SAAArB,EAAC8B,EAAA,CAAqB,OAAQtB,EAAQ,EACxC,EACF,CAEJ,CA/FgBc,EAAApB,EAAA","names":["useEffect","jsx","commonFields","ContractAmendmentForm","onSubmit","onError","onSuccess","formId","checkFieldUpdates","fields","submitContractAmendment","stepState","initialValues","handleValidation","useContractAmendmentContext","resolver","useJsonSchemasValidationFormResolver","form","useForm","useEffect","subscription","values","handleSubmit","__name","hasContractDetailsChanges","key","value","parsedValues","parseJSFToValidate","contractAmendmentResult","Form","JSONSchemaFormFields"]}
1
+ {"version":3,"sources":["../src/flows/ContractAmendment/ContractAmendmentForm.tsx"],"sourcesContent":["import {\n ContractAmendmentAutomatableResponse,\n PostAutomatableContractAmendmentError,\n} from '@/src/client';\nimport { JSONSchemaFormFields } from '@/src/components/form/JSONSchemaForm';\nimport { parseJSFToValidate } from '@/src/components/form/utils';\nimport { useJsonSchemasValidationFormResolver } from '@/src/components/form/yupValidationResolver';\nimport { Form } from '@/src/components/ui/form';\nimport { useEffect } from 'react';\nimport { FieldValues, useForm } from 'react-hook-form';\nimport { useContractAmendmentContext } from './context';\n\ntype ContractAmendmentFormProps = {\n /**\n * Callback function to be called when the contract amendment form is submitted.\n * This function is called before the contract amendment is submitted.\n * It can be used to perform any additional validation or processing before\n * the contract amendment is submitted.\n * @param values\n * @returns\n */\n onSubmit?: (values: FieldValues) => void | Promise<void>;\n /**\n * Callback function to be called when the contract amendment fails.\n * @param error\n * @returns\n */\n onError?: (\n error:\n | PostAutomatableContractAmendmentError\n | { message: 'no_changes_detected_contract_details' },\n ) => void;\n /**\n * Callback function to be called when the contract amendment is successfully submitted.\n * This function is called after the contract amendment is submitted.\n * @param data\n * @returns\n */\n onSuccess?: (\n data: ContractAmendmentAutomatableResponse,\n ) => void | Promise<void>;\n};\n\nconst commonFields = [\n 'effective_date',\n 'reason_for_change',\n 'reason_for_change_description',\n 'additional_comments',\n 'additional_comments_toggle',\n] as const;\n\ntype CommonFields = (typeof commonFields)[number];\n\nexport function ContractAmendmentForm({\n onSubmit,\n onError,\n onSuccess,\n}: ContractAmendmentFormProps) {\n const {\n formId,\n contractAmendment: {\n checkFieldUpdates,\n fields,\n onSubmit: submitContractAmendment,\n stepState,\n initialValues,\n handleValidation,\n },\n } = useContractAmendmentContext();\n\n const resolver = useJsonSchemasValidationFormResolver(\n // @ts-expect-error no matching type\n handleValidation,\n );\n\n const form = useForm({\n resolver,\n defaultValues:\n // stepState.values is used as defaultValues for the form when the form is\n // rendered when clicking on the back button after the user has submitted the form\n // and the confirmation form is displayed.\n // This is because the form is unmounted when the user submits the form.\n stepState.values?.form || initialValues,\n shouldUnregister: true,\n mode: 'onBlur',\n });\n\n useEffect(() => {\n const subscription = form?.watch((values) => {\n const isFormDirty =\n Object.keys(form.formState.dirtyFields).length > 0 ||\n form.formState.isDirty;\n if (isFormDirty) {\n checkFieldUpdates(values);\n }\n });\n return () => subscription?.unsubscribe();\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n\n const handleSubmit = async (values: FieldValues) => {\n let hasContractDetailsChanges = false;\n for (const [key, value] of Object.entries(values)) {\n if (\n !commonFields.includes(key as CommonFields) &&\n // @ts-expect-error error\n initialValues[key] !== value\n ) {\n hasContractDetailsChanges = true;\n break;\n }\n }\n\n if (!hasContractDetailsChanges) {\n return onError?.({\n message: 'no_changes_detected_contract_details',\n });\n }\n\n const parsedValues = parseJSFToValidate(values, fields, {\n isPartialValidation: false,\n });\n\n await onSubmit?.(parsedValues);\n\n const contractAmendmentResult = await submitContractAmendment(values);\n\n if (contractAmendmentResult.error) {\n onError?.(contractAmendmentResult.error);\n } else {\n await onSuccess?.(\n contractAmendmentResult.data as ContractAmendmentAutomatableResponse,\n );\n }\n };\n\n return (\n <Form {...form}>\n <form\n id={formId}\n data-testid='contract-amendment-form'\n onSubmit={form.handleSubmit(handleSubmit)}\n className='space-y-4 RemoteFlows__ContractAmendmentForm'\n >\n <JSONSchemaFormFields fields={fields} />\n </form>\n </Form>\n );\n}\n"],"mappings":"uPAQA,OAAS,aAAAA,MAAiB,QAwIlB,cAAAC,MAAA,oBArGR,IAAMC,EAAe,CACnB,iBACA,oBACA,gCACA,sBACA,4BACF,EAIO,SAASC,EAAsB,CACpC,SAAAC,EACA,QAAAC,EACA,UAAAC,CACF,EAA+B,CAC7B,GAAM,CACJ,OAAAC,EACA,kBAAmB,CACjB,kBAAAC,EACA,OAAAC,EACA,SAAUC,EACV,UAAAC,EACA,cAAAC,EACA,iBAAAC,CACF,CACF,EAAIC,EAA4B,EAE1BC,EAAWC,EAEfH,CACF,EAEMI,EAAOC,EAAQ,CACnB,SAAAH,EACA,cAKEJ,EAAU,QAAQ,MAAQC,EAC5B,iBAAkB,GAClB,KAAM,QACR,CAAC,EAEDO,EAAU,IAAM,CACd,IAAMC,EAAeH,GAAM,MAAOI,GAAW,EAEzC,OAAO,KAAKJ,EAAK,UAAU,WAAW,EAAE,OAAS,GACjDA,EAAK,UAAU,UAEfT,EAAkBa,CAAM,CAE5B,CAAC,EACD,MAAO,IAAMD,GAAc,YAAY,CAEzC,EAAG,CAAC,CAAC,EAEL,IAAME,EAAeC,EAAA,MAAOF,GAAwB,CAClD,IAAIG,EAA4B,GAChC,OAAW,CAACC,EAAKC,CAAK,IAAK,OAAO,QAAQL,CAAM,EAC9C,GACE,CAACnB,EAAa,SAASuB,CAAmB,GAE1Cb,EAAca,CAAG,IAAMC,EACvB,CACAF,EAA4B,GAC5B,KACF,CAGF,GAAI,CAACA,EACH,OAAOnB,IAAU,CACf,QAAS,sCACX,CAAC,EAGH,IAAMsB,EAAeC,EAAmBP,EAAQZ,EAAQ,CACtD,oBAAqB,EACvB,CAAC,EAED,MAAML,IAAWuB,CAAY,EAE7B,IAAME,EAA0B,MAAMnB,EAAwBW,CAAM,EAEhEQ,EAAwB,MAC1BxB,IAAUwB,EAAwB,KAAK,EAEvC,MAAMvB,IACJuB,EAAwB,IAC1B,CAEJ,EAlCqB,gBAoCrB,OACE5B,EAAC6B,EAAA,CAAM,GAAGb,EACR,SAAAhB,EAAC,QACC,GAAIM,EACJ,cAAY,0BACZ,SAAUU,EAAK,aAAaK,CAAY,EACxC,UAAU,+CAEV,SAAArB,EAAC8B,EAAA,CAAqB,OAAQtB,EAAQ,EACxC,EACF,CAEJ,CA/FgBc,EAAApB,EAAA","names":["useEffect","jsx","commonFields","ContractAmendmentForm","onSubmit","onError","onSuccess","formId","checkFieldUpdates","fields","submitContractAmendment","stepState","initialValues","handleValidation","useContractAmendmentContext","resolver","useJsonSchemasValidationFormResolver","form","useForm","useEffect","subscription","values","handleSubmit","__name","hasContractDetailsChanges","key","value","parsedValues","parseJSFToValidate","contractAmendmentResult","Form","JSONSchemaFormFields"]}
@@ -1,2 +1,2 @@
1
- import{a as r}from"./chunk-CSLZUVU4.js";import{a}from"./chunk-R7L6CI5J.js";import{a as c}from"./chunk-DHT7HDHC.js";import{a as e}from"./chunk-GBD3OCAW.js";import{a as m}from"./chunk-N7PSO5ZD.js";import{a as o}from"./chunk-TVZAFTPT.js";import{a as n}from"./chunk-P37U34EQ.js";import{useId as f}from"react";import{jsx as s}from"react/jsx-runtime";function k({employmentId:d,countryCode:C,options:p,render:A}){let t=c({employmentId:d,countryCode:C,options:p}),i=f();return s(o.Provider,{value:{formId:i,contractAmendmentBag:t},children:A({contractAmendmentBag:t,components:{Form:r,SubmitButton:a,ConfirmationForm:m,BackButton:e}})})}n(k,"ContractAmendmentFlow");export{k as a};
2
- //# sourceMappingURL=chunk-AXU5ZCUE.js.map
1
+ import{a as r}from"./chunk-XZRGLKXU.js";import{a}from"./chunk-ITSQE6EW.js";import{a as c}from"./chunk-DHT7HDHC.js";import{a as e}from"./chunk-7P5B6XHM.js";import{a as m}from"./chunk-HEKQK6TK.js";import{a as o}from"./chunk-TVZAFTPT.js";import{a as n}from"./chunk-P37U34EQ.js";import{useId as f}from"react";import{jsx as s}from"react/jsx-runtime";function k({employmentId:d,countryCode:C,options:p,render:A}){let t=c({employmentId:d,countryCode:C,options:p}),i=f();return s(o.Provider,{value:{formId:i,contractAmendmentBag:t},children:A({contractAmendmentBag:t,components:{Form:r,SubmitButton:a,ConfirmationForm:m,BackButton:e}})})}n(k,"ContractAmendmentFlow");export{k as a};
2
+ //# sourceMappingURL=chunk-ZCYSBG7R.js.map
@@ -0,0 +1,2 @@
1
+ import{c as f,d}from"./chunk-LPFDPXCW.js";import{a as u}from"./chunk-HN5HLFTB.js";import{a as i}from"./chunk-KSHK3ZPX.js";import{b as g}from"./chunk-CFIJKJXD.js";import{f as m}from"./chunk-3BREUYLG.js";import{a as c}from"./chunk-P37U34EQ.js";import{useEffect as P,useId as _,useState as h}from"react";import{jsx as M}from"react/jsx-runtime";var y=c((r,e,t)=>t&&t[e]?t[e]:r[e]?r[e]/100:0,"getDefaultManagementFee"),T=c(({estimationOptions:r=f,defaultValues:e={countryRegionSlug:"",currencySlug:"",salary:""},options:t,render:S,version:p="standard"})=>{let F=_(),[R,C]=h("USD"),v=c(l=>{C(l);let o=y(u,l,r.managementFees);o&&a.setValue("management.management_fee",o)},"onCurrencyChange"),n=d({defaultRegion:e.countryRegionSlug,defaultCurrency:e.currencySlug,defaultSalary:e.salary,estimationOptions:r,version:p,options:{...t,onCurrencyChange:v}}),K=g(n.handleValidation),E=e.currencySlug?"":y(u,R,r.managementFees),a=m({resolver:K,defaultValues:{country:e?.countryRegionSlug,currency:e?.currencySlug,region:"",salary:e?.salary,salary_conversion:"",salary_converted:"",management:{management_fee:E}},shouldUnregister:!1,mode:"onBlur"});return P(()=>{if(e.currencySlug&&n.currencies&&r.includeManagementFee){let o=n.currencies.find(s=>s.value===e.currencySlug)?.label;if(o){C(o);let s=y(u,o,r.managementFees);a.setValue("management.management_fee",s)}}},[e.currencySlug,n.currencies,r.includeManagementFee,r.managementFees,a]),M(i.Provider,{value:{form:a,formId:F,costCalculatorBag:n},children:S(n)})},"CostCalculatorFlow");export{T as a};
2
+ //# sourceMappingURL=chunk-ZD644MH3.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/flows/CostCalculator/CostCalculatorFlow.tsx"],"sourcesContent":["import React, { useEffect, useId, useState } from 'react';\nimport { useForm } from 'react-hook-form';\nimport { useJsonSchemasValidationFormResolver } from '@/src/components/form/yupValidationResolver';\nimport { CostCalculatorContext } from '@/src/flows/CostCalculator/context';\nimport {\n CostCalculatorVersion,\n defaultEstimationOptions,\n useCostCalculator,\n} from '@/src/flows/CostCalculator/hooks';\nimport {\n CostCalculatorEstimationOptions,\n CurrencyKey,\n UseCostCalculatorOptions,\n} from '@/src/flows/CostCalculator/types';\nimport { BASE_RATES } from '@/src/flows/CostCalculator/constants';\n\nexport type CostCalculatorFlowProps = {\n /**\n * Estimation params allows you to customize the parameters sent to the /cost-calculator/estimation endpoint.\n */\n estimationOptions?: CostCalculatorEstimationOptions;\n /**\n * Default values for the form fields.\n */\n defaultValues?: Partial<{\n /**\n * Default value for the country field.\n */\n countryRegionSlug: string;\n /**\n * Default value for the currency field.\n */\n currencySlug: string;\n /**\n * Default value for the salary field.\n */\n salary: string;\n }>;\n options?: UseCostCalculatorOptions;\n render: (\n costCalculatorBag: ReturnType<typeof useCostCalculator>,\n ) => React.ReactNode;\n /**\n * Whether to include annual_gross_salary in the estimation payload\n */\n version?: CostCalculatorVersion;\n};\n\nconst getDefaultManagementFee = (\n baseRates: Record<CurrencyKey, number>,\n currency: CurrencyKey,\n managementFees?: Partial<Record<CurrencyKey, number>>,\n) => {\n if (managementFees && managementFees[currency]) {\n return managementFees[currency];\n }\n if (baseRates[currency]) {\n return baseRates[currency] / 100;\n }\n return 0;\n};\n\nexport const CostCalculatorFlow = ({\n estimationOptions = defaultEstimationOptions,\n defaultValues = {\n countryRegionSlug: '',\n currencySlug: '',\n salary: '',\n },\n options,\n render,\n version = 'standard',\n}: CostCalculatorFlowProps) => {\n const formId = useId();\n const [currency, setCurrency] = useState<CurrencyKey>('USD');\n const onCurrencyChange = (currency: string) => {\n setCurrency(currency as CurrencyKey);\n const managementFee = getDefaultManagementFee(\n BASE_RATES,\n currency as CurrencyKey,\n estimationOptions.managementFees,\n );\n if (managementFee) {\n form.setValue('management.management_fee', managementFee);\n }\n };\n const costCalculatorBag = useCostCalculator({\n defaultRegion: defaultValues.countryRegionSlug,\n defaultCurrency: defaultValues.currencySlug,\n defaultSalary: defaultValues.salary,\n estimationOptions,\n version,\n options: {\n ...options,\n onCurrencyChange: onCurrencyChange,\n },\n });\n const resolver = useJsonSchemasValidationFormResolver(\n // @ts-expect-error no matching type\n costCalculatorBag.handleValidation,\n );\n\n const defaultManagementFee = defaultValues.currencySlug\n ? ''\n : getDefaultManagementFee(\n BASE_RATES,\n currency,\n estimationOptions.managementFees,\n );\n\n const form = useForm({\n resolver,\n defaultValues: {\n country: defaultValues?.countryRegionSlug,\n currency: defaultValues?.currencySlug,\n region: '',\n salary: defaultValues?.salary,\n salary_conversion: '',\n salary_converted: '',\n management: {\n management_fee: defaultManagementFee,\n },\n },\n shouldUnregister: false,\n mode: 'onBlur',\n });\n\n useEffect(() => {\n if (\n defaultValues.currencySlug &&\n costCalculatorBag.currencies &&\n estimationOptions.includeManagementFee\n ) {\n const currencyData = costCalculatorBag.currencies.find(\n (currency) => currency.value === defaultValues.currencySlug,\n );\n const currencyCode = currencyData?.label;\n if (currencyCode) {\n setCurrency(currencyCode as CurrencyKey);\n const defaultManagementFee = getDefaultManagementFee(\n BASE_RATES,\n currencyCode as CurrencyKey,\n estimationOptions.managementFees,\n );\n form.setValue('management.management_fee', defaultManagementFee);\n }\n }\n }, [\n defaultValues.currencySlug,\n costCalculatorBag.currencies,\n estimationOptions.includeManagementFee,\n estimationOptions.managementFees,\n form,\n ]);\n\n return (\n <CostCalculatorContext.Provider\n value={{\n form,\n formId: formId,\n costCalculatorBag,\n }}\n >\n {render(costCalculatorBag)}\n </CostCalculatorContext.Provider>\n );\n};\n"],"mappings":"kPAAA,OAAgB,aAAAA,EAAW,SAAAC,EAAO,YAAAC,MAAgB,QA4J9C,cAAAC,MAAA,oBA5GJ,IAAMC,EAA0BC,EAAA,CAC9BC,EACAC,EACAC,IAEIA,GAAkBA,EAAeD,CAAQ,EACpCC,EAAeD,CAAQ,EAE5BD,EAAUC,CAAQ,EACbD,EAAUC,CAAQ,EAAI,IAExB,EAXuB,2BAcnBE,EAAqBJ,EAAA,CAAC,CACjC,kBAAAK,EAAoBC,EACpB,cAAAC,EAAgB,CACd,kBAAmB,GACnB,aAAc,GACd,OAAQ,EACV,EACA,QAAAC,EACA,OAAAC,EACA,QAAAC,EAAU,UACZ,IAA+B,CAC7B,IAAMC,EAASC,EAAM,EACf,CAACV,EAAUW,CAAW,EAAIC,EAAsB,KAAK,EACrDC,EAAmBf,EAACE,GAAqB,CAC7CW,EAAYX,CAAuB,EACnC,IAAMc,EAAgBjB,EACpBkB,EACAf,EACAG,EAAkB,cACpB,EACIW,GACFE,EAAK,SAAS,4BAA6BF,CAAa,CAE5D,EAVyB,oBAWnBG,EAAoBC,EAAkB,CAC1C,cAAeb,EAAc,kBAC7B,gBAAiBA,EAAc,aAC/B,cAAeA,EAAc,OAC7B,kBAAAF,EACA,QAAAK,EACA,QAAS,CACP,GAAGF,EACH,iBAAkBO,CACpB,CACF,CAAC,EACKM,EAAWC,EAEfH,EAAkB,gBACpB,EAEMI,EAAuBhB,EAAc,aACvC,GACAR,EACEkB,EACAf,EACAG,EAAkB,cACpB,EAEEa,EAAOM,EAAQ,CACnB,SAAAH,EACA,cAAe,CACb,QAASd,GAAe,kBACxB,SAAUA,GAAe,aACzB,OAAQ,GACR,OAAQA,GAAe,OACvB,kBAAmB,GACnB,iBAAkB,GAClB,WAAY,CACV,eAAgBgB,CAClB,CACF,EACA,iBAAkB,GAClB,KAAM,QACR,CAAC,EAED,OAAAE,EAAU,IAAM,CACd,GACElB,EAAc,cACdY,EAAkB,YAClBd,EAAkB,qBAClB,CAIA,IAAMqB,EAHeP,EAAkB,WAAW,KAC/CjB,GAAaA,EAAS,QAAUK,EAAc,YACjD,GACmC,MACnC,GAAImB,EAAc,CAChBb,EAAYa,CAA2B,EACvC,IAAMH,EAAuBxB,EAC3BkB,EACAS,EACArB,EAAkB,cACpB,EACAa,EAAK,SAAS,4BAA6BK,CAAoB,CACjE,CACF,CACF,EAAG,CACDhB,EAAc,aACdY,EAAkB,WAClBd,EAAkB,qBAClBA,EAAkB,eAClBa,CACF,CAAC,EAGCpB,EAAC6B,EAAsB,SAAtB,CACC,MAAO,CACL,KAAAT,EACA,OAAQP,EACR,kBAAAQ,CACF,EAEC,SAAAV,EAAOU,CAAiB,EAC3B,CAEJ,EAxGkC","names":["useEffect","useId","useState","jsx","getDefaultManagementFee","__name","baseRates","currency","managementFees","CostCalculatorFlow","estimationOptions","defaultEstimationOptions","defaultValues","options","render","version","formId","useId","setCurrency","useState","onCurrencyChange","managementFee","BASE_RATES","form","costCalculatorBag","useCostCalculator","resolver","useJsonSchemasValidationFormResolver","defaultManagementFee","useForm","useEffect","currencyCode","CostCalculatorContext"]}
@@ -1,2 +1,2 @@
1
1
  import{a as e}from"./chunk-P37U34EQ.js";import{jsx as a,jsxs as t}from"react/jsx-runtime";var i=e(({children:o,content:r})=>t("div",{className:"relative inline-block group",children:[o,t("div",{className:"absolute bottom-full right-0 mb-2 px-3 py-2 bg-gray-900 text-white text-xs rounded-md opacity-0 invisible group-hover:opacity-100 group-hover:visible transition-all duration-200 z-50 w-64 whitespace-normal break-words",children:[r,a("div",{className:"absolute top-full right-3 border-4 border-transparent border-t-gray-900"})]})]}),"BasicTooltip");export{i as a};
2
- //# sourceMappingURL=chunk-ILMVHOL2.js.map
2
+ //# sourceMappingURL=chunk-ZE3YT3Q6.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/components/ui/basic-tooltip.tsx"],"sourcesContent":["export const BasicTooltip = ({\n children,\n content,\n}: {\n children: React.ReactNode;\n content: React.ReactNode;\n}) => {\n return (\n <div className='relative inline-block group'>\n {children}\n <div className='absolute bottom-full right-0 mb-2 px-3 py-2 bg-gray-900 text-white text-xs rounded-md opacity-0 invisible group-hover:opacity-100 group-hover:visible transition-all duration-200 z-50 w-64 whitespace-normal break-words'>\n {content}\n <div className='absolute top-full right-3 border-4 border-transparent border-t-gray-900'></div>\n </div>\n </div>\n );\n};\n"],"mappings":"wCAUM,OAEE,OAAAA,EAFF,QAAAC,MAAA,oBAVC,IAAMC,EAAeC,EAAA,CAAC,CAC3B,SAAAC,EACA,QAAAC,CACF,IAKIJ,EAAC,OAAI,UAAU,8BACZ,UAAAG,EACDH,EAAC,OAAI,UAAU,4NACZ,UAAAI,EACDL,EAAC,OAAI,UAAU,0EAA0E,GAC3F,GACF,EAdwB","names":["jsx","jsxs","BasicTooltip","__name","children","content"]}
@@ -0,0 +1,2 @@
1
+ import{a as g}from"./chunk-TXSJL3HC.js";import{b as c}from"./chunk-3ZWDIEEM.js";import{c as _,h as d,i as u,j as x,k as C,l as T,m as R}from"./chunk-3BREUYLG.js";import{a}from"./chunk-P37U34EQ.js";import{jsx as o,jsxs as E}from"react/jsx-runtime";function J({name:t,description:m,label:r,type:f,onChange:s,component:w,includeErrorMessage:I=!0,additionalProps:P={},maxLength:l,...h}){let{components:N}=c(),{control:D}=_();return o(d,{control:D,name:t,render:({field:e,fieldState:F})=>{let i=w||N?.text;if(i){let n={name:t,description:m,label:r,type:f,onChange:s,metadata:P,maxLength:l,...h};return o(i,{field:{...e,onChange:a(p=>{e.onChange(p),s?.(p)},"onChange")},fieldState:F,fieldData:n})}return E(u,{"data-field":t,className:`RemoteFlows__TextField__Item__${t}`,children:[r&&o(x,{className:"RemoteFlows__TextField__Label",children:r}),o(C,{children:o(g,{...e,value:e.value??"",onChange:n=>{e.onChange(n),s?.(n)},className:"RemoteFlows__TextField__Input",placeholder:r,maxLength:l})}),m&&o(T,{className:"RemoteFlows__TextField__Description",children:m}),I&&F.error&&o(R,{className:"RemoteFlows__TextField__Error"})]})}})}a(J,"TextField");export{J as a};
2
+ //# sourceMappingURL=chunk-ZTDKPUB5.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/components/form/fields/TextField.tsx"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-explicit-any */\nimport * as React from 'react';\n\nimport { useFormFields } from '@/src/context';\nimport { Components, JSFField } from '@/src/types/remoteFlows';\nimport { useFormContext } from 'react-hook-form';\nimport {\n FormControl,\n FormDescription,\n FormField,\n FormItem,\n FormLabel,\n FormMessage,\n} from '../../ui/form';\nimport { Input } from '../../ui/input';\n\nexport type TextFieldProps = React.ComponentProps<'input'> & {\n name: string;\n} & Partial<\n JSFField & {\n onChange?: (value: any) => void;\n component?: Components['text'];\n includeErrorMessage?: boolean;\n additionalProps?: Record<string, unknown>;\n }\n >;\n\nexport function TextField({\n name,\n description,\n label,\n type,\n onChange,\n component,\n includeErrorMessage = true,\n additionalProps = {},\n maxLength,\n ...rest\n}: TextFieldProps) {\n const { components } = useFormFields();\n const { control } = useFormContext();\n\n return (\n <FormField\n control={control}\n name={name}\n render={({ field, fieldState }) => {\n const CustomTextField = component || components?.text;\n if (CustomTextField) {\n const customTextFieldProps = {\n name,\n description,\n label,\n type,\n onChange,\n metadata: additionalProps,\n maxLength,\n ...rest,\n };\n return (\n <CustomTextField\n field={{\n ...field,\n onChange: (value: any) => {\n field.onChange(value);\n onChange?.(value);\n },\n }}\n fieldState={fieldState}\n fieldData={customTextFieldProps}\n />\n );\n }\n\n return (\n <FormItem\n data-field={name}\n className={`RemoteFlows__TextField__Item__${name}`}\n >\n {label && (\n <FormLabel className='RemoteFlows__TextField__Label'>\n {label}\n </FormLabel>\n )}\n <FormControl>\n <Input\n {...field}\n value={field.value ?? ''}\n onChange={(event: React.ChangeEvent<HTMLInputElement>) => {\n field.onChange(event);\n onChange?.(event);\n }}\n className='RemoteFlows__TextField__Input'\n placeholder={label}\n maxLength={maxLength}\n />\n </FormControl>\n {description && (\n <FormDescription className='RemoteFlows__TextField__Description'>\n {description}\n </FormDescription>\n )}\n {includeErrorMessage && fieldState.error && (\n <FormMessage className='RemoteFlows__TextField__Error' />\n )}\n </FormItem>\n );\n }}\n />\n );\n}\n"],"mappings":"qMA4DY,cAAAA,EAeF,QAAAC,MAfE,oBAjCL,SAASC,EAAU,CACxB,KAAAC,EACA,YAAAC,EACA,MAAAC,EACA,KAAAC,EACA,SAAAC,EACA,UAAAC,EACA,oBAAAC,EAAsB,GACtB,gBAAAC,EAAkB,CAAC,EACnB,UAAAC,EACA,GAAGC,CACL,EAAmB,CACjB,GAAM,CAAE,WAAAC,CAAW,EAAIC,EAAc,EAC/B,CAAE,QAAAC,CAAQ,EAAIC,EAAe,EAEnC,OACEhB,EAACiB,EAAA,CACC,QAASF,EACT,KAAMZ,EACN,OAAQ,CAAC,CAAE,MAAAe,EAAO,WAAAC,CAAW,IAAM,CACjC,IAAMC,EAAkBZ,GAAaK,GAAY,KACjD,GAAIO,EAAiB,CACnB,IAAMC,EAAuB,CAC3B,KAAAlB,EACA,YAAAC,EACA,MAAAC,EACA,KAAAC,EACA,SAAAC,EACA,SAAUG,EACV,UAAAC,EACA,GAAGC,CACL,EACA,OACEZ,EAACoB,EAAA,CACC,MAAO,CACL,GAAGF,EACH,SAAUI,EAACC,GAAe,CACxBL,EAAM,SAASK,CAAK,EACpBhB,IAAWgB,CAAK,CAClB,EAHU,WAIZ,EACA,WAAYJ,EACZ,UAAWE,EACb,CAEJ,CAEA,OACEpB,EAACuB,EAAA,CACC,aAAYrB,EACZ,UAAW,iCAAiCA,CAAI,GAE/C,UAAAE,GACCL,EAACyB,EAAA,CAAU,UAAU,gCAClB,SAAApB,EACH,EAEFL,EAAC0B,EAAA,CACC,SAAA1B,EAAC2B,EAAA,CACE,GAAGT,EACJ,MAAOA,EAAM,OAAS,GACtB,SAAWU,GAA+C,CACxDV,EAAM,SAASU,CAAK,EACpBrB,IAAWqB,CAAK,CAClB,EACA,UAAU,gCACV,YAAavB,EACb,UAAWM,EACb,EACF,EACCP,GACCJ,EAAC6B,EAAA,CAAgB,UAAU,sCACxB,SAAAzB,EACH,EAEDK,GAAuBU,EAAW,OACjCnB,EAAC8B,EAAA,CAAY,UAAU,gCAAgC,GAE3D,CAEJ,EACF,CAEJ,CAnFgBR,EAAApB,EAAA","names":["jsx","jsxs","TextField","name","description","label","type","onChange","component","includeErrorMessage","additionalProps","maxLength","rest","components","useFormFields","control","useFormContext","FormField","field","fieldState","CustomTextField","customTextFieldProps","__name","value","FormItem","FormLabel","FormControl","Input","event","FormDescription","FormMessage"]}
@@ -1,2 +1,2 @@
1
- import{a}from"../../chunk-GBD3OCAW.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-CSK44J23.js";import"../../chunk-TVZAFTPT.js";import"../../chunk-3LOVCTCN.js";import"../../chunk-P37U34EQ.js";export{a as ContractAmendmentBack};
1
+ import{a}from"../../chunk-7P5B6XHM.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-7VUILYZ3.js";import"../../chunk-TVZAFTPT.js";import"../../chunk-3LOVCTCN.js";import"../../chunk-P37U34EQ.js";export{a as ContractAmendmentBack};
2
2
  //# sourceMappingURL=ContractAmendmentBack.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-_c0f1E7h.js';
2
+ import { b as PostCreateContractAmendmentError, a as ContractAmendmentResponse } from '../../types.gen-C9Y1S1pc.js';
3
3
  import { FieldValues } from 'react-hook-form';
4
4
 
5
5
  type ContractAmendmentConfirmationFormProps = {
@@ -1,2 +1,2 @@
1
- import{a}from"../../chunk-N7PSO5ZD.js";import"../../chunk-GAOBYAJE.js";import"../../chunk-MXFDOIUA.js";import"../../chunk-EW24LQRE.js";import"../../chunk-TVZAFTPT.js";import"../../chunk-3LOVCTCN.js";import"../../chunk-P37U34EQ.js";export{a as ContractAmendmentConfirmationForm};
1
+ import{a}from"../../chunk-HEKQK6TK.js";import"../../chunk-3BREUYLG.js";import"../../chunk-MXFDOIUA.js";import"../../chunk-BI6U55BD.js";import"../../chunk-TVZAFTPT.js";import"../../chunk-3LOVCTCN.js";import"../../chunk-P37U34EQ.js";export{a as ContractAmendmentConfirmationForm};
2
2
  //# sourceMappingURL=ContractAmendmentConfirmationForm.js.map
@@ -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-_c0f1E7h.js';
8
+ import '../../types.gen-C9Y1S1pc.js';
9
9
  import 'react-hook-form';
10
10
  import 'react';
11
11
  import '../../mutations-B6HWH-rZ.js';
@@ -1,2 +1,2 @@
1
- import{a}from"../../chunk-AXU5ZCUE.js";import"../../chunk-CSLZUVU4.js";import"../../chunk-SUQURI2J.js";import"../../chunk-CFIJKJXD.js";import"../../chunk-NVJYAX22.js";import"../../chunk-R7L6CI5J.js";import"../../chunk-DHT7HDHC.js";import"../../chunk-GGBEM452.js";import"../../chunk-QW4JPW6J.js";import"../../chunk-AYJ63EZH.js";import"../../chunk-XI3AQ3RM.js";import"../../chunk-G7WJUXZU.js";import"../../chunk-CHSULXMN.js";import"../../chunk-EGQJ7UBR.js";import"../../chunk-PJBAQZ6G.js";import"../../chunk-GBD3OCAW.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-CSK44J23.js";import"../../chunk-N7PSO5ZD.js";import"../../chunk-GAOBYAJE.js";import"../../chunk-MXFDOIUA.js";import"../../chunk-EW24LQRE.js";import"../../chunk-TVZAFTPT.js";import"../../chunk-3LOVCTCN.js";import"../../chunk-P37U34EQ.js";export{a as ContractAmendmentFlow};
1
+ import{a}from"../../chunk-ZCYSBG7R.js";import"../../chunk-XZRGLKXU.js";import"../../chunk-CFIJKJXD.js";import"../../chunk-LK4XMOCE.js";import"../../chunk-ZTDKPUB5.js";import"../../chunk-ITSQE6EW.js";import"../../chunk-DHT7HDHC.js";import"../../chunk-GGBEM452.js";import"../../chunk-QW4JPW6J.js";import"../../chunk-AYJ63EZH.js";import"../../chunk-KHNAQRGE.js";import"../../chunk-GP237GUO.js";import"../../chunk-TXSJL3HC.js";import"../../chunk-EGQJ7UBR.js";import"../../chunk-PJBAQZ6G.js";import"../../chunk-7P5B6XHM.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-7VUILYZ3.js";import"../../chunk-HEKQK6TK.js";import"../../chunk-3BREUYLG.js";import"../../chunk-MXFDOIUA.js";import"../../chunk-BI6U55BD.js";import"../../chunk-TVZAFTPT.js";import"../../chunk-3LOVCTCN.js";import"../../chunk-P37U34EQ.js";export{a as ContractAmendmentFlow};
2
2
  //# sourceMappingURL=ContractAmendmentFlow.js.map
@@ -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-_c0f1E7h.js';
2
+ import { P as PostAutomatableContractAmendmentError, C as ContractAmendmentAutomatableResponse } from '../../types.gen-C9Y1S1pc.js';
3
3
  import { FieldValues } from 'react-hook-form';
4
4
 
5
5
  type ContractAmendmentFormProps = {
@@ -1,2 +1,2 @@
1
- import{a}from"../../chunk-CSLZUVU4.js";import"../../chunk-SUQURI2J.js";import"../../chunk-CFIJKJXD.js";import"../../chunk-NVJYAX22.js";import"../../chunk-XI3AQ3RM.js";import"../../chunk-G7WJUXZU.js";import"../../chunk-CHSULXMN.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-CSK44J23.js";import"../../chunk-GAOBYAJE.js";import"../../chunk-MXFDOIUA.js";import"../../chunk-EW24LQRE.js";import"../../chunk-TVZAFTPT.js";import"../../chunk-3LOVCTCN.js";import"../../chunk-P37U34EQ.js";export{a as ContractAmendmentForm};
1
+ import{a}from"../../chunk-XZRGLKXU.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-3ZWDIEEM.js";import"../../chunk-7VUILYZ3.js";import"../../chunk-3BREUYLG.js";import"../../chunk-MXFDOIUA.js";import"../../chunk-BI6U55BD.js";import"../../chunk-TVZAFTPT.js";import"../../chunk-3LOVCTCN.js";import"../../chunk-P37U34EQ.js";export{a as ContractAmendmentForm};
2
2
  //# sourceMappingURL=ContractAmendmentForm.js.map
@@ -1,2 +1,2 @@
1
- import{a}from"../../chunk-R7L6CI5J.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-CSK44J23.js";import"../../chunk-TVZAFTPT.js";import"../../chunk-3LOVCTCN.js";import"../../chunk-P37U34EQ.js";export{a as ContractAmendmentSubmit};
1
+ import{a}from"../../chunk-ITSQE6EW.js";import"../../chunk-3ZWDIEEM.js";import"../../chunk-7VUILYZ3.js";import"../../chunk-TVZAFTPT.js";import"../../chunk-3LOVCTCN.js";import"../../chunk-P37U34EQ.js";export{a as ContractAmendmentSubmit};
2
2
  //# sourceMappingURL=ContractAmendmentSubmit.js.map