@gusto/embedded-react-sdk 0.43.0 → 0.44.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 (733) hide show
  1. package/CHANGELOG.md +100 -0
  2. package/README.md +23 -5
  3. package/dist/assets/icons/edit-02.svg.js +10 -0
  4. package/dist/assets/icons/edit-02.svg.js.map +1 -0
  5. package/dist/components/Common/DataView/DataTable/DataTable.js +86 -64
  6. package/dist/components/Common/DataView/DataTable/DataTable.js.map +1 -1
  7. package/dist/components/Common/DetailViewLayout/DetailViewLayout.js +52 -0
  8. package/dist/components/Common/DetailViewLayout/DetailViewLayout.js.map +1 -0
  9. package/dist/components/Common/DetailViewLayout/DetailViewLayout.module.scss.js +18 -0
  10. package/dist/components/Common/DetailViewLayout/DetailViewLayout.module.scss.js.map +1 -0
  11. package/dist/components/Common/Fields/hooks/FieldElementRegistryProvider.d.ts +13 -0
  12. package/dist/components/Common/Fields/hooks/FieldElementRegistryProvider.js +12 -0
  13. package/dist/components/Common/Fields/hooks/FieldElementRegistryProvider.js.map +1 -0
  14. package/dist/components/Common/Fields/hooks/fieldElementRegistry.d.ts +21 -0
  15. package/dist/components/Common/Fields/hooks/fieldElementRegistry.js +29 -0
  16. package/dist/components/Common/Fields/hooks/fieldElementRegistry.js.map +1 -0
  17. package/dist/components/Common/Fields/hooks/useField.js +43 -37
  18. package/dist/components/Common/Fields/hooks/useField.js.map +1 -1
  19. package/dist/components/Common/Flex/Flex.d.ts +2 -1
  20. package/dist/components/Common/Flex/Flex.js +14 -12
  21. package/dist/components/Common/Flex/Flex.js.map +1 -1
  22. package/dist/components/Common/Flex/Flex.module.scss.js +4 -4
  23. package/dist/components/Common/TaxInputs/TaxInputs.js +1 -1
  24. package/dist/components/Common/TaxInputs/TaxInputs.js.map +1 -1
  25. package/dist/components/Common/UI/Button/Button.module.scss.js +2 -2
  26. package/dist/components/Common/UI/Dialog/Dialog.js +35 -36
  27. package/dist/components/Common/UI/Dialog/Dialog.js.map +1 -1
  28. package/dist/components/Common/UI/Switch/SwitchTypes.d.ts +2 -2
  29. package/dist/components/Common/UI/Switch/SwitchTypes.js.map +1 -1
  30. package/dist/components/Company/AssignSignatory/AssignSignatory.js +6 -7
  31. package/dist/components/Company/AssignSignatory/AssignSignatory.js.map +1 -1
  32. package/dist/components/Company/AssignSignatory/AssignSignatorySelection.js +3 -2
  33. package/dist/components/Company/AssignSignatory/AssignSignatorySelection.js.map +1 -1
  34. package/dist/components/Company/AssignSignatory/CreateSignatory/Actions.js +3 -2
  35. package/dist/components/Company/AssignSignatory/CreateSignatory/Actions.js.map +1 -1
  36. package/dist/components/Company/AssignSignatory/CreateSignatory/CreateSignatory.js +6 -7
  37. package/dist/components/Company/AssignSignatory/CreateSignatory/CreateSignatory.js.map +1 -1
  38. package/dist/components/Company/AssignSignatory/CreateSignatory/CreateSignatoryForm.js +2 -3
  39. package/dist/components/Company/AssignSignatory/CreateSignatory/CreateSignatoryForm.js.map +1 -1
  40. package/dist/components/Company/AssignSignatory/CreateSignatory/useCreateSignatory.js +6 -3
  41. package/dist/components/Company/AssignSignatory/CreateSignatory/useCreateSignatory.js.map +1 -1
  42. package/dist/components/Company/AssignSignatory/InviteSignatory/Actions.js +3 -2
  43. package/dist/components/Company/AssignSignatory/InviteSignatory/Actions.js.map +1 -1
  44. package/dist/components/Company/AssignSignatory/InviteSignatory/InviteSignatory.js +5 -6
  45. package/dist/components/Company/AssignSignatory/InviteSignatory/InviteSignatory.js.map +1 -1
  46. package/dist/components/Company/AssignSignatory/InviteSignatory/InviteSignatoryForm.js +9 -10
  47. package/dist/components/Company/AssignSignatory/InviteSignatory/InviteSignatoryForm.js.map +1 -1
  48. package/dist/components/Company/AssignSignatory/InviteSignatory/useInviteSignatory.js +6 -3
  49. package/dist/components/Company/AssignSignatory/InviteSignatory/useInviteSignatory.js.map +1 -1
  50. package/dist/components/Company/AssignSignatory/TitleSelect.js +1 -1
  51. package/dist/components/Company/AssignSignatory/useAssignSignatory.js +8 -5
  52. package/dist/components/Company/AssignSignatory/useAssignSignatory.js.map +1 -1
  53. package/dist/components/Company/BankAccount/BankAccountForm/Actions.js +6 -6
  54. package/dist/components/Company/BankAccount/BankAccountForm/Form.js +9 -8
  55. package/dist/components/Company/BankAccount/BankAccountForm/Form.js.map +1 -1
  56. package/dist/components/Company/BankAccount/BankAccountForm/context.js +6 -3
  57. package/dist/components/Company/BankAccount/BankAccountForm/context.js.map +1 -1
  58. package/dist/components/Company/BankAccount/BankAccountList/Actions.js +9 -8
  59. package/dist/components/Company/BankAccount/BankAccountList/Actions.js.map +1 -1
  60. package/dist/components/Company/BankAccount/BankAccountVerify/Actions.js +8 -7
  61. package/dist/components/Company/BankAccount/BankAccountVerify/Actions.js.map +1 -1
  62. package/dist/components/Company/BankAccount/BankAccountVerify/Form.js +5 -4
  63. package/dist/components/Company/BankAccount/BankAccountVerify/Form.js.map +1 -1
  64. package/dist/components/Company/DocumentSigner/DocumentList/Actions.js +3 -2
  65. package/dist/components/Company/DocumentSigner/DocumentList/Actions.js.map +1 -1
  66. package/dist/components/Company/DocumentSigner/DocumentList/DocumentList.js +2 -3
  67. package/dist/components/Company/DocumentSigner/DocumentList/DocumentList.js.map +1 -1
  68. package/dist/components/Company/DocumentSigner/DocumentList/useDocumentList.js +6 -3
  69. package/dist/components/Company/DocumentSigner/DocumentList/useDocumentList.js.map +1 -1
  70. package/dist/components/Company/DocumentSigner/SignatureForm/SignatureForm.js +1 -1
  71. package/dist/components/Company/DocumentSigner/shared/useSignCompanyForm/useSignCompanyForm.js +26 -25
  72. package/dist/components/Company/DocumentSigner/shared/useSignCompanyForm/useSignCompanyForm.js.map +1 -1
  73. package/dist/components/Company/FederalTaxes/Actions.js +6 -5
  74. package/dist/components/Company/FederalTaxes/Actions.js.map +1 -1
  75. package/dist/components/Company/FederalTaxes/FederalTaxes.js +2 -3
  76. package/dist/components/Company/FederalTaxes/FederalTaxes.js.map +1 -1
  77. package/dist/components/Company/FederalTaxes/Form.js +3 -2
  78. package/dist/components/Company/FederalTaxes/Form.js.map +1 -1
  79. package/dist/components/Company/FederalTaxes/useFederalTaxes.js +11 -8
  80. package/dist/components/Company/FederalTaxes/useFederalTaxes.js.map +1 -1
  81. package/dist/components/Company/Industry/Actions.js +3 -2
  82. package/dist/components/Company/Industry/Actions.js.map +1 -1
  83. package/dist/components/Company/Industry/Context.js +9 -6
  84. package/dist/components/Company/Industry/Context.js.map +1 -1
  85. package/dist/components/Company/Industry/Edit.js +5 -4
  86. package/dist/components/Company/Industry/Edit.js.map +1 -1
  87. package/dist/components/Company/Locations/LocationForm/Actions.js +7 -6
  88. package/dist/components/Company/Locations/LocationForm/Actions.js.map +1 -1
  89. package/dist/components/Company/Locations/LocationForm/Form.js +4 -5
  90. package/dist/components/Company/Locations/LocationForm/Form.js.map +1 -1
  91. package/dist/components/Company/Locations/LocationForm/LocationForm.js +12 -13
  92. package/dist/components/Company/Locations/LocationForm/LocationForm.js.map +1 -1
  93. package/dist/components/Company/Locations/LocationForm/index.d.ts +2 -0
  94. package/dist/components/Company/Locations/LocationForm/useLocationForm.js +6 -3
  95. package/dist/components/Company/Locations/LocationForm/useLocationForm.js.map +1 -1
  96. package/dist/components/Company/Locations/LocationsList/Actions.js +7 -6
  97. package/dist/components/Company/Locations/LocationsList/Actions.js.map +1 -1
  98. package/dist/components/Company/Locations/LocationsList/List.js +8 -7
  99. package/dist/components/Company/Locations/LocationsList/List.js.map +1 -1
  100. package/dist/components/Company/Locations/LocationsList/LocationsList.js +6 -7
  101. package/dist/components/Company/Locations/LocationsList/LocationsList.js.map +1 -1
  102. package/dist/components/Company/Locations/LocationsList/useLocationsList.js +6 -3
  103. package/dist/components/Company/Locations/LocationsList/useLocationsList.js.map +1 -1
  104. package/dist/components/Company/OnboardingOverview/Completed.js +11 -10
  105. package/dist/components/Company/OnboardingOverview/Completed.js.map +1 -1
  106. package/dist/components/Company/OnboardingOverview/MissingRequirements.js +3 -2
  107. package/dist/components/Company/OnboardingOverview/MissingRequirements.js.map +1 -1
  108. package/dist/components/Company/OnboardingOverview/OnboardingOverview.js +2 -3
  109. package/dist/components/Company/OnboardingOverview/OnboardingOverview.js.map +1 -1
  110. package/dist/components/Company/OnboardingOverview/context.js +6 -3
  111. package/dist/components/Company/OnboardingOverview/context.js.map +1 -1
  112. package/dist/components/Company/PaySchedule/PayScheduleForm.js +2 -3
  113. package/dist/components/Company/PaySchedule/PayScheduleForm.js.map +1 -1
  114. package/dist/components/Company/PaySchedule/PayScheduleList.js +1 -1
  115. package/dist/components/Company/PaySchedule/shared/usePayScheduleForm/usePayScheduleForm.js +53 -52
  116. package/dist/components/Company/PaySchedule/shared/usePayScheduleForm/usePayScheduleForm.js.map +1 -1
  117. package/dist/components/Company/StateTaxes/StateTaxesForm/Actions.js +3 -2
  118. package/dist/components/Company/StateTaxes/StateTaxesForm/Actions.js.map +1 -1
  119. package/dist/components/Company/StateTaxes/StateTaxesForm/Form.js +12 -11
  120. package/dist/components/Company/StateTaxes/StateTaxesForm/Form.js.map +1 -1
  121. package/dist/components/Company/StateTaxes/StateTaxesForm/StateTaxesForm.js +67 -63
  122. package/dist/components/Company/StateTaxes/StateTaxesForm/StateTaxesForm.js.map +1 -1
  123. package/dist/components/Company/StateTaxes/StateTaxesForm/context.js +6 -3
  124. package/dist/components/Company/StateTaxes/StateTaxesForm/context.js.map +1 -1
  125. package/dist/components/Company/StateTaxes/StateTaxesForm/rhfKey.d.ts +2 -0
  126. package/dist/components/Company/StateTaxes/StateTaxesForm/rhfKey.js +6 -0
  127. package/dist/components/Company/StateTaxes/StateTaxesForm/rhfKey.js.map +1 -0
  128. package/dist/components/Company/StateTaxes/StateTaxesList/Actions.js +3 -2
  129. package/dist/components/Company/StateTaxes/StateTaxesList/Actions.js.map +1 -1
  130. package/dist/components/Company/StateTaxes/StateTaxesList/List.js +57 -26
  131. package/dist/components/Company/StateTaxes/StateTaxesList/List.js.map +1 -1
  132. package/dist/components/Company/StateTaxes/StateTaxesList/context.js +6 -3
  133. package/dist/components/Company/StateTaxes/StateTaxesList/context.js.map +1 -1
  134. package/dist/components/Company/exports/companyOnboarding.d.ts +3 -0
  135. package/dist/components/Company/exports/companyOnboarding.js +21 -15
  136. package/dist/components/Company/exports/companyOnboarding.js.map +1 -1
  137. package/dist/components/Company/index.d.ts +1 -0
  138. package/dist/components/Company/index.js +14 -12
  139. package/dist/components/Company/index.js.map +1 -1
  140. package/dist/components/Contractor/Address/Address.js +3 -4
  141. package/dist/components/Contractor/Address/Address.js.map +1 -1
  142. package/dist/components/Contractor/Address/Form.js +6 -7
  143. package/dist/components/Contractor/Address/Form.js.map +1 -1
  144. package/dist/components/Contractor/Address/Head.js +7 -6
  145. package/dist/components/Contractor/Address/Head.js.map +1 -1
  146. package/dist/components/Contractor/Address/useAddress.js +8 -5
  147. package/dist/components/Contractor/Address/useAddress.js.map +1 -1
  148. package/dist/components/Contractor/ContractorList/index.js +17 -17
  149. package/dist/components/Contractor/PaymentMethod/BankAccountForm.js +3 -2
  150. package/dist/components/Contractor/PaymentMethod/BankAccountForm.js.map +1 -1
  151. package/dist/components/Contractor/PaymentMethod/PaymentTypeForm.js +1 -1
  152. package/dist/components/Contractor/Payments/CreatePayment/CreatePaymentPresentation.js +3 -2
  153. package/dist/components/Contractor/Payments/CreatePayment/CreatePaymentPresentation.js.map +1 -1
  154. package/dist/components/Contractor/Payments/CreatePayment/EditContractorPaymentPresentation.js +2 -3
  155. package/dist/components/Contractor/Payments/CreatePayment/EditContractorPaymentPresentation.js.map +1 -1
  156. package/dist/components/Contractor/Payments/CreatePayment/FastAchSubmissionBlockerBanner.js +6 -5
  157. package/dist/components/Contractor/Payments/CreatePayment/FastAchSubmissionBlockerBanner.js.map +1 -1
  158. package/dist/components/Contractor/Payments/CreatePayment/PreviewPresentation.js +1 -1
  159. package/dist/components/Contractor/Payments/PaymentHistory/PaymentHistoryPresentation.js +3 -2
  160. package/dist/components/Contractor/Payments/PaymentHistory/PaymentHistoryPresentation.js.map +1 -1
  161. package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatementPresentation.js +3 -2
  162. package/dist/components/Contractor/Payments/PaymentStatement/PaymentStatementPresentation.js.map +1 -1
  163. package/dist/components/Contractor/Payments/PaymentSummary/PaymentSummaryPresentation.js +3 -2
  164. package/dist/components/Contractor/Payments/PaymentSummary/PaymentSummaryPresentation.js.map +1 -1
  165. package/dist/components/Contractor/Payments/PaymentsList/PaymentsListPresentation.js +8 -7
  166. package/dist/components/Contractor/Payments/PaymentsList/PaymentsListPresentation.js.map +1 -1
  167. package/dist/components/Contractor/Profile/useContractorProfile.js +34 -33
  168. package/dist/components/Contractor/Profile/useContractorProfile.js.map +1 -1
  169. package/dist/components/Contractor/Submit/Submit.js +1 -1
  170. package/dist/components/Employee/Compensation/Compensation.d.ts +7 -4
  171. package/dist/components/Employee/Compensation/Compensation.js +72 -179
  172. package/dist/components/Employee/Compensation/Compensation.js.map +1 -1
  173. package/dist/components/Employee/Compensation/CompensationFlowComponents.d.ts +27 -0
  174. package/dist/components/Employee/Compensation/CompensationFlowComponents.js +61 -0
  175. package/dist/components/Employee/Compensation/CompensationFlowComponents.js.map +1 -0
  176. package/dist/components/Employee/Compensation/EditCompensation/EditCompensation.d.ts +14 -0
  177. package/dist/components/Employee/Compensation/EditCompensation/EditCompensation.js +128 -0
  178. package/dist/components/Employee/Compensation/EditCompensation/EditCompensation.js.map +1 -0
  179. package/dist/components/Employee/Compensation/EditCompensation/EditCompensationPresentation.d.ts +17 -0
  180. package/dist/components/Employee/Compensation/EditCompensation/EditCompensationPresentation.js +224 -0
  181. package/dist/components/Employee/Compensation/EditCompensation/EditCompensationPresentation.js.map +1 -0
  182. package/dist/components/Employee/Compensation/EditCompensation/index.d.ts +5 -0
  183. package/dist/components/Employee/Compensation/JobsList/JobsList.d.ts +5 -0
  184. package/dist/components/Employee/Compensation/JobsList/JobsList.js +47 -0
  185. package/dist/components/Employee/Compensation/JobsList/JobsList.js.map +1 -0
  186. package/dist/components/Employee/Compensation/JobsList/JobsListPresentation.d.ts +11 -0
  187. package/dist/components/Employee/Compensation/JobsList/JobsListPresentation.js +98 -0
  188. package/dist/components/Employee/Compensation/JobsList/JobsListPresentation.js.map +1 -0
  189. package/dist/components/Employee/Compensation/JobsList/index.d.ts +5 -0
  190. package/dist/components/Employee/Compensation/{useCompensation.d.ts → compensationSchema.d.ts} +0 -22
  191. package/dist/components/Employee/Compensation/{useCompensation.js → compensationSchema.js} +9 -12
  192. package/dist/components/Employee/Compensation/compensationSchema.js.map +1 -0
  193. package/dist/components/Employee/Compensation/compensationStateMachine.d.ts +6 -0
  194. package/dist/components/Employee/Compensation/compensationStateMachine.js +73 -0
  195. package/dist/components/Employee/Compensation/compensationStateMachine.js.map +1 -0
  196. package/dist/components/Employee/Compensation/shared/useCompensationForm/compensationSchema.d.ts +62 -36
  197. package/dist/components/Employee/Compensation/shared/useCompensationForm/compensationSchema.js +81 -57
  198. package/dist/components/Employee/Compensation/shared/useCompensationForm/compensationSchema.js.map +1 -1
  199. package/dist/components/Employee/Compensation/shared/useCompensationForm/fields.d.ts +5 -12
  200. package/dist/components/Employee/Compensation/shared/useCompensationForm/fields.js +22 -35
  201. package/dist/components/Employee/Compensation/shared/useCompensationForm/fields.js.map +1 -1
  202. package/dist/components/Employee/Compensation/shared/useCompensationForm/index.d.ts +5 -3
  203. package/dist/components/Employee/Compensation/shared/useCompensationForm/useCompensationForm.d.ts +55 -13
  204. package/dist/components/Employee/Compensation/shared/useCompensationForm/useCompensationForm.js +216 -226
  205. package/dist/components/Employee/Compensation/shared/useCompensationForm/useCompensationForm.js.map +1 -1
  206. package/dist/components/Employee/Compensation/shared/useCompensationForm/useCurrentCompensationForm.d.ts +15 -0
  207. package/dist/components/Employee/Compensation/shared/useCompensationForm/useCurrentCompensationForm.js +27 -0
  208. package/dist/components/Employee/Compensation/shared/useCompensationForm/useCurrentCompensationForm.js.map +1 -0
  209. package/dist/components/Employee/Compensation/shared/useJobForm/fields.d.ts +19 -0
  210. package/dist/components/Employee/Compensation/shared/useJobForm/fields.js +29 -0
  211. package/dist/components/Employee/Compensation/shared/useJobForm/fields.js.map +1 -0
  212. package/dist/components/Employee/Compensation/shared/useJobForm/index.d.ts +7 -0
  213. package/dist/components/Employee/Compensation/shared/useJobForm/jobSchema.d.ts +43 -0
  214. package/dist/components/Employee/Compensation/shared/useJobForm/jobSchema.js +37 -0
  215. package/dist/components/Employee/Compensation/shared/useJobForm/jobSchema.js.map +1 -0
  216. package/dist/components/Employee/Compensation/shared/useJobForm/useCurrentJobForm.d.ts +13 -0
  217. package/dist/components/Employee/Compensation/shared/useJobForm/useCurrentJobForm.js +26 -0
  218. package/dist/components/Employee/Compensation/shared/useJobForm/useCurrentJobForm.js.map +1 -0
  219. package/dist/components/Employee/Compensation/shared/useJobForm/useJobForm.d.ts +56 -0
  220. package/dist/components/Employee/Compensation/shared/useJobForm/useJobForm.js +180 -0
  221. package/dist/components/Employee/Compensation/shared/useJobForm/useJobForm.js.map +1 -0
  222. package/dist/components/Employee/Dashboard/BasicDetailsView.js +15 -13
  223. package/dist/components/Employee/Dashboard/BasicDetailsView.js.map +1 -1
  224. package/dist/components/Employee/Dashboard/DashboardComponents.d.ts +3 -0
  225. package/dist/components/Employee/Dashboard/DashboardComponents.js +33 -15
  226. package/dist/components/Employee/Dashboard/DashboardComponents.js.map +1 -1
  227. package/dist/components/Employee/Dashboard/DocumentsView.js +13 -11
  228. package/dist/components/Employee/Dashboard/DocumentsView.js.map +1 -1
  229. package/dist/components/Employee/Dashboard/JobAndPayView.js +11 -9
  230. package/dist/components/Employee/Dashboard/JobAndPayView.js.map +1 -1
  231. package/dist/components/Employee/Dashboard/TaxesView.js +21 -19
  232. package/dist/components/Employee/Dashboard/TaxesView.js.map +1 -1
  233. package/dist/components/Employee/Dashboard/dashboardStateMachine.d.ts +3 -0
  234. package/dist/components/Employee/Dashboard/dashboardStateMachine.js +54 -33
  235. package/dist/components/Employee/Dashboard/dashboardStateMachine.js.map +1 -1
  236. package/dist/components/Employee/Deductions/DeductionsForm/ChildSupportForm.js +14 -11
  237. package/dist/components/Employee/Deductions/DeductionsForm/ChildSupportForm.js.map +1 -1
  238. package/dist/components/Employee/Deductions/DeductionsForm/CustomDeductionForm.js +36 -33
  239. package/dist/components/Employee/Deductions/DeductionsForm/CustomDeductionForm.js.map +1 -1
  240. package/dist/components/Employee/Deductions/DeductionsForm/GarnishmentForm.js +6 -3
  241. package/dist/components/Employee/Deductions/DeductionsForm/GarnishmentForm.js.map +1 -1
  242. package/dist/components/Employee/Deductions/DeductionsList/DeductionsList.js +1 -1
  243. package/dist/components/Employee/Deductions/IncludeDeductions/IncludeDeductions.js +2 -3
  244. package/dist/components/Employee/Deductions/IncludeDeductions/IncludeDeductions.js.map +1 -1
  245. package/dist/components/Employee/DocumentSigner/DocumentList/Actions.js +7 -6
  246. package/dist/components/Employee/DocumentSigner/DocumentList/Actions.js.map +1 -1
  247. package/dist/components/Employee/DocumentSigner/DocumentList/DocumentList.js +7 -8
  248. package/dist/components/Employee/DocumentSigner/DocumentList/DocumentList.js.map +1 -1
  249. package/dist/components/Employee/DocumentSigner/DocumentList/List.js +3 -2
  250. package/dist/components/Employee/DocumentSigner/DocumentList/List.js.map +1 -1
  251. package/dist/components/Employee/DocumentSigner/DocumentList/useDocumentList.js +6 -3
  252. package/dist/components/Employee/DocumentSigner/DocumentList/useDocumentList.js.map +1 -1
  253. package/dist/components/Employee/DocumentSigner/EmploymentEligibility/EmploymentEligibilityPresentation.js +3 -2
  254. package/dist/components/Employee/DocumentSigner/EmploymentEligibility/EmploymentEligibilityPresentation.js.map +1 -1
  255. package/dist/components/Employee/DocumentSigner/shared/useSignEmployeeForm/useSignEmployeeForm.js +69 -68
  256. package/dist/components/Employee/DocumentSigner/shared/useSignEmployeeForm/useSignEmployeeForm.js.map +1 -1
  257. package/dist/components/Employee/EmployeeDocuments/EmployeeDocumentsPresentation.js +3 -2
  258. package/dist/components/Employee/EmployeeDocuments/EmployeeDocumentsPresentation.js.map +1 -1
  259. package/dist/components/Employee/EmployeeList/management/ManagementEmployeeListView.js +8 -7
  260. package/dist/components/Employee/EmployeeList/management/ManagementEmployeeListView.js.map +1 -1
  261. package/dist/components/Employee/EmployeeList/onboarding/EmployeeListView.js +18 -17
  262. package/dist/components/Employee/EmployeeList/onboarding/EmployeeListView.js.map +1 -1
  263. package/dist/components/Employee/FederalTaxes/index.d.ts +3 -1
  264. package/dist/components/Employee/FederalTaxes/management/FederalTaxes.d.ts +8 -0
  265. package/dist/components/Employee/FederalTaxes/management/FederalTaxes.js +71 -0
  266. package/dist/components/Employee/FederalTaxes/management/FederalTaxes.js.map +1 -0
  267. package/dist/components/Employee/FederalTaxes/management/index.d.ts +2 -0
  268. package/dist/components/Employee/FederalTaxes/onboarding/FederalTaxes.d.ts +8 -0
  269. package/dist/components/Employee/FederalTaxes/onboarding/FederalTaxes.js +55 -0
  270. package/dist/components/Employee/FederalTaxes/onboarding/FederalTaxes.js.map +1 -0
  271. package/dist/components/Employee/FederalTaxes/onboarding/index.d.ts +2 -0
  272. package/dist/components/Employee/FederalTaxes/shared/FederalTaxesView.d.ts +15 -0
  273. package/dist/components/Employee/FederalTaxes/shared/FederalTaxesView.js +104 -0
  274. package/dist/components/Employee/FederalTaxes/shared/FederalTaxesView.js.map +1 -0
  275. package/dist/components/Employee/FederalTaxes/shared/index.d.ts +3 -0
  276. package/dist/components/Employee/FederalTaxes/shared/useFederalTaxesForm/federalTaxesSchema.d.ts +41 -0
  277. package/dist/components/Employee/FederalTaxes/shared/useFederalTaxesForm/federalTaxesSchema.js +40 -0
  278. package/dist/components/Employee/FederalTaxes/shared/useFederalTaxesForm/federalTaxesSchema.js.map +1 -0
  279. package/dist/components/Employee/FederalTaxes/shared/useFederalTaxesForm/fields.d.ts +18 -0
  280. package/dist/components/Employee/FederalTaxes/shared/useFederalTaxesForm/fields.js +31 -0
  281. package/dist/components/Employee/FederalTaxes/shared/useFederalTaxesForm/fields.js.map +1 -0
  282. package/dist/components/Employee/FederalTaxes/shared/useFederalTaxesForm/index.d.ts +5 -0
  283. package/dist/components/Employee/FederalTaxes/shared/useFederalTaxesForm/useFederalTaxesForm.d.ts +37 -0
  284. package/dist/components/Employee/FederalTaxes/shared/useFederalTaxesForm/useFederalTaxesForm.js +140 -0
  285. package/dist/components/Employee/FederalTaxes/shared/useFederalTaxesForm/useFederalTaxesForm.js.map +1 -0
  286. package/dist/components/Employee/HomeAddress/management/HomeAddressView.js +2 -3
  287. package/dist/components/Employee/HomeAddress/management/HomeAddressView.js.map +1 -1
  288. package/dist/components/Employee/Landing/Landing.js +8 -8
  289. package/dist/components/Employee/OnboardingFlow/OnboardingFlowComponents.d.ts +1 -1
  290. package/dist/components/Employee/OnboardingFlow/OnboardingFlowComponents.js +2 -2
  291. package/dist/components/Employee/OnboardingFlow/OnboardingFlowComponents.js.map +1 -1
  292. package/dist/components/Employee/OnboardingFlow/onboardingStateMachine.js +1 -1
  293. package/dist/components/Employee/OnboardingFlow/onboardingStateMachine.js.map +1 -1
  294. package/dist/components/Employee/OnboardingSummary/OnboardingSummary.js +7 -7
  295. package/dist/components/Employee/PaymentMethod/Actions.js +6 -5
  296. package/dist/components/Employee/PaymentMethod/Actions.js.map +1 -1
  297. package/dist/components/Employee/PaymentMethod/BankAccountEdit.js +1 -1
  298. package/dist/components/Employee/PaymentMethod/BankAccountsList.js +4 -4
  299. package/dist/components/Employee/PaymentMethod/PaymentTypeForm.js +1 -1
  300. package/dist/components/Employee/PaymentMethod/Split.js +1 -1
  301. package/dist/components/Employee/PaymentMethod/usePaymentMethod.js +8 -5
  302. package/dist/components/Employee/PaymentMethod/usePaymentMethod.js.map +1 -1
  303. package/dist/components/Employee/Profile/management/Profile.d.ts +6 -0
  304. package/dist/components/Employee/Profile/management/Profile.js +122 -0
  305. package/dist/components/Employee/Profile/management/Profile.js.map +1 -0
  306. package/dist/components/Employee/Profile/management/Profile.module.scss.js +8 -0
  307. package/dist/components/Employee/Profile/management/Profile.module.scss.js.map +1 -0
  308. package/dist/components/Employee/Profile/{AdminProfile.js → onboarding/AdminProfile.js} +15 -15
  309. package/dist/components/Employee/Profile/onboarding/AdminProfile.js.map +1 -0
  310. package/dist/components/Employee/Profile/{EmployeeProfile.js → onboarding/EmployeeProfile.js} +14 -14
  311. package/dist/components/Employee/Profile/onboarding/EmployeeProfile.js.map +1 -0
  312. package/dist/components/Employee/Profile/{Profile.d.ts → onboarding/Profile.d.ts} +2 -2
  313. package/dist/components/Employee/Profile/{Profile.js → onboarding/Profile.js} +4 -4
  314. package/dist/components/Employee/Profile/onboarding/Profile.js.map +1 -0
  315. package/dist/components/Employee/Profile/shared/useEmployeeDetailsForm/useEmployeeDetailsForm.d.ts +9 -4
  316. package/dist/components/Employee/Profile/shared/useEmployeeDetailsForm/useEmployeeDetailsForm.js +61 -58
  317. package/dist/components/Employee/Profile/shared/useEmployeeDetailsForm/useEmployeeDetailsForm.js.map +1 -1
  318. package/dist/components/Employee/Profile/shared/useHomeAddressForm/useHomeAddressForm.js +40 -39
  319. package/dist/components/Employee/Profile/shared/useHomeAddressForm/useHomeAddressForm.js.map +1 -1
  320. package/dist/components/Employee/Profile/shared/useWorkAddressForm/useWorkAddressForm.js +47 -46
  321. package/dist/components/Employee/Profile/shared/useWorkAddressForm/useWorkAddressForm.js.map +1 -1
  322. package/dist/components/Employee/SelfOnboardingFlow/SelfOnboardingComponents.js +14 -14
  323. package/dist/components/Employee/SelfOnboardingFlow/SelfOnboardingComponents.js.map +1 -1
  324. package/dist/components/Employee/StateTaxes/index.d.ts +2 -1
  325. package/dist/components/Employee/StateTaxes/management/StateTaxes.d.ts +6 -0
  326. package/dist/components/Employee/StateTaxes/management/StateTaxes.js +59 -0
  327. package/dist/components/Employee/StateTaxes/management/StateTaxes.js.map +1 -0
  328. package/dist/components/Employee/StateTaxes/management/index.d.ts +2 -0
  329. package/dist/components/Employee/StateTaxes/onboarding/StateTaxes.d.ts +8 -0
  330. package/dist/components/Employee/StateTaxes/onboarding/StateTaxes.js +49 -0
  331. package/dist/components/Employee/StateTaxes/onboarding/StateTaxes.js.map +1 -0
  332. package/dist/components/Employee/StateTaxes/onboarding/index.d.ts +2 -0
  333. package/dist/components/Employee/StateTaxes/shared/EmployeeStateTaxesView.d.ts +14 -0
  334. package/dist/components/Employee/StateTaxes/shared/EmployeeStateTaxesView.js +32 -0
  335. package/dist/components/Employee/StateTaxes/shared/EmployeeStateTaxesView.js.map +1 -0
  336. package/dist/components/Employee/StateTaxes/shared/index.d.ts +3 -0
  337. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/__fixtures__/stateTaxesFixtures.d.ts +8 -0
  338. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/__fixtures__/toWireFormat.d.ts +36 -0
  339. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/employeeStateTaxesSchema.d.ts +56 -0
  340. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/employeeStateTaxesSchema.js +116 -0
  341. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/employeeStateTaxesSchema.js.map +1 -0
  342. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/fieldComponents.d.ts +12 -0
  343. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/fieldComponents.js +76 -0
  344. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/fieldComponents.js.map +1 -0
  345. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/fieldMapping.d.ts +14 -0
  346. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/fieldMapping.js +23 -0
  347. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/fieldMapping.js.map +1 -0
  348. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/fieldMeta.d.ts +6 -0
  349. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/fieldProps.d.ts +39 -0
  350. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/fields.d.ts +46 -0
  351. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/fields.js +93 -0
  352. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/fields.js.map +1 -0
  353. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/index.d.ts +6 -0
  354. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/useEmployeeStateTaxesForm.d.ts +36 -0
  355. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/useEmployeeStateTaxesForm.js +159 -0
  356. package/dist/components/Employee/StateTaxes/shared/useEmployeeStateTaxesForm/useEmployeeStateTaxesForm.js.map +1 -0
  357. package/dist/components/Employee/Taxes/Actions.js +9 -8
  358. package/dist/components/Employee/Taxes/Actions.js.map +1 -1
  359. package/dist/components/Employee/Taxes/FederalForm.js +5 -4
  360. package/dist/components/Employee/Taxes/FederalForm.js.map +1 -1
  361. package/dist/components/Employee/Taxes/useTaxes.js +6 -3
  362. package/dist/components/Employee/Taxes/useTaxes.js.map +1 -1
  363. package/dist/components/Employee/Terminations/TerminateEmployee/TerminateEmployeePresentation.js +3 -2
  364. package/dist/components/Employee/Terminations/TerminateEmployee/TerminateEmployeePresentation.js.map +1 -1
  365. package/dist/components/Employee/Terminations/TerminationFlow/TerminationFlowComponents.js +4 -4
  366. package/dist/components/Employee/Terminations/TerminationSummary/TerminationSummaryPresentation.js +3 -2
  367. package/dist/components/Employee/Terminations/TerminationSummary/TerminationSummaryPresentation.js.map +1 -1
  368. package/dist/components/Employee/WorkAddress/management/WorkAddressView.js +2 -3
  369. package/dist/components/Employee/WorkAddress/management/WorkAddressView.js.map +1 -1
  370. package/dist/components/Employee/exports/employeeManagement.d.ts +3 -0
  371. package/dist/components/Employee/exports/employeeManagement.js +16 -10
  372. package/dist/components/Employee/exports/employeeManagement.js.map +1 -1
  373. package/dist/components/Employee/exports/employeeOnboarding.d.ts +3 -3
  374. package/dist/components/Employee/exports/employeeOnboarding.js +19 -19
  375. package/dist/components/Employee/index.d.ts +2 -1
  376. package/dist/components/Employee/index.js +37 -37
  377. package/dist/components/Flow/FlowHeader.js +8 -8
  378. package/dist/components/Flow/FlowHeader.js.map +1 -1
  379. package/dist/components/InformationRequests/InformationRequestForm/InformationRequestForm.js +47 -46
  380. package/dist/components/InformationRequests/InformationRequestForm/InformationRequestForm.js.map +1 -1
  381. package/dist/components/InformationRequests/InformationRequestList/InformationRequestList.js +4 -4
  382. package/dist/components/InformationRequests/InformationRequests.js +1 -1
  383. package/dist/components/Payroll/Dismissal/DismissalPayPeriodSelection/DismissalPayPeriodSelectionPresentation.js +3 -2
  384. package/dist/components/Payroll/Dismissal/DismissalPayPeriodSelection/DismissalPayPeriodSelectionPresentation.js.map +1 -1
  385. package/dist/components/Payroll/GrossUpModal/GrossUpModal.js +22 -20
  386. package/dist/components/Payroll/GrossUpModal/GrossUpModal.js.map +1 -1
  387. package/dist/components/Payroll/OffCycleCreation/OffCycleCreationPresentation.js +3 -2
  388. package/dist/components/Payroll/OffCycleCreation/OffCycleCreationPresentation.js.map +1 -1
  389. package/dist/components/Payroll/OffCyclePayPeriodDateForm/OffCyclePayPeriodDateFormPresentation.js +1 -0
  390. package/dist/components/Payroll/OffCyclePayPeriodDateForm/OffCyclePayPeriodDateFormPresentation.js.map +1 -1
  391. package/dist/components/Payroll/OffCycleReasonSelection/OffCycleReasonSelectionPresentation.js +7 -6
  392. package/dist/components/Payroll/OffCycleReasonSelection/OffCycleReasonSelectionPresentation.js.map +1 -1
  393. package/dist/components/Payroll/OffCycleTaxWithholdingModal/OffCycleTaxWithholdingModal.js +3 -2
  394. package/dist/components/Payroll/OffCycleTaxWithholdingModal/OffCycleTaxWithholdingModal.js.map +1 -1
  395. package/dist/components/Payroll/PayrollBlocker/components/PayrollBlockerAlerts.js +9 -8
  396. package/dist/components/Payroll/PayrollBlocker/components/PayrollBlockerAlerts.js.map +1 -1
  397. package/dist/components/Payroll/PayrollBlocker/components/PayrollBlockerList.js +12 -12
  398. package/dist/components/Payroll/PayrollConfiguration/PayrollConfigurationPresentation.js +2 -3
  399. package/dist/components/Payroll/PayrollConfiguration/PayrollConfigurationPresentation.js.map +1 -1
  400. package/dist/components/Payroll/PayrollEditEmployee/PayrollEditEmployeePresentation.js +2 -3
  401. package/dist/components/Payroll/PayrollEditEmployee/PayrollEditEmployeePresentation.js.map +1 -1
  402. package/dist/components/Payroll/PayrollEditEmployee/TimeOffField.js +17 -16
  403. package/dist/components/Payroll/PayrollEditEmployee/TimeOffField.js.map +1 -1
  404. package/dist/components/Payroll/PayrollHistory/PayrollHistoryPresentation.js +3 -2
  405. package/dist/components/Payroll/PayrollHistory/PayrollHistoryPresentation.js.map +1 -1
  406. package/dist/components/Payroll/PayrollList/PayrollListPresentation.js +3 -2
  407. package/dist/components/Payroll/PayrollList/PayrollListPresentation.js.map +1 -1
  408. package/dist/components/Payroll/PayrollOverview/PayrollOverviewPresentation.js +2 -3
  409. package/dist/components/Payroll/PayrollOverview/PayrollOverviewPresentation.js.map +1 -1
  410. package/dist/components/Payroll/PayrollOverview/SubmissionBlockers/FastAchSubmissionBlockerBanner.js +3 -2
  411. package/dist/components/Payroll/PayrollOverview/SubmissionBlockers/FastAchSubmissionBlockerBanner.js.map +1 -1
  412. package/dist/components/Payroll/PayrollReceipts/PayrollReceiptsPresentation.js +3 -2
  413. package/dist/components/Payroll/PayrollReceipts/PayrollReceiptsPresentation.js.map +1 -1
  414. package/dist/components/Payroll/RecoveryCases/RecoveryCasesList/RecoveryCasesList.js +4 -4
  415. package/dist/components/Payroll/RecoveryCases/RecoveryCasesResubmit/RecoveryCasesResubmit.js +6 -6
  416. package/dist/components/Payroll/RecoveryCases/useRecoveryCaseErrorCode.js +3 -2
  417. package/dist/components/Payroll/RecoveryCases/useRecoveryCaseErrorCode.js.map +1 -1
  418. package/dist/components/Payroll/TransitionCreation/TransitionCreationPresentation.js +3 -2
  419. package/dist/components/Payroll/TransitionCreation/TransitionCreationPresentation.js.map +1 -1
  420. package/dist/components/Payroll/usePreparedPayrollData.js +13 -10
  421. package/dist/components/Payroll/usePreparedPayrollData.js.map +1 -1
  422. package/dist/components/TimeOff/AddEmployeesHoliday/AddEmployeesHoliday.js.map +1 -0
  423. package/dist/components/{UNSTABLE_TimeOff → TimeOff}/AddEmployeesToPolicy/AddEmployeesToPolicy.d.ts +2 -0
  424. package/dist/components/{UNSTABLE_TimeOff → TimeOff}/AddEmployeesToPolicy/AddEmployeesToPolicy.js +3 -2
  425. package/dist/components/TimeOff/AddEmployeesToPolicy/AddEmployeesToPolicy.js.map +1 -0
  426. package/dist/components/TimeOff/HolidayPolicyDetail/HolidayPolicyDetail.d.ts +6 -0
  427. package/dist/components/TimeOff/HolidayPolicyDetail/HolidayPolicyDetail.js +149 -0
  428. package/dist/components/TimeOff/HolidayPolicyDetail/HolidayPolicyDetail.js.map +1 -0
  429. package/dist/components/TimeOff/HolidayPolicyDetail/HolidayPolicyDetailPresentation.d.ts +2 -0
  430. package/dist/components/TimeOff/HolidayPolicyDetail/HolidayPolicyDetailPresentation.js +80 -0
  431. package/dist/components/TimeOff/HolidayPolicyDetail/HolidayPolicyDetailPresentation.js.map +1 -0
  432. package/dist/components/TimeOff/HolidayPolicyDetail/HolidayPolicyDetailTypes.d.ts +21 -0
  433. package/dist/components/TimeOff/HolidayPolicyDetail/index.d.ts +5 -0
  434. package/dist/components/{UNSTABLE_TimeOff → TimeOff}/HolidaySelectionForm/HolidaySelectionForm.d.ts +1 -0
  435. package/dist/components/TimeOff/HolidaySelectionForm/HolidaySelectionForm.js +115 -0
  436. package/dist/components/TimeOff/HolidaySelectionForm/HolidaySelectionForm.js.map +1 -0
  437. package/dist/components/{UNSTABLE_TimeOff → TimeOff}/HolidaySelectionForm/HolidaySelectionFormPresentation.js +9 -7
  438. package/dist/components/TimeOff/HolidaySelectionForm/HolidaySelectionFormPresentation.js.map +1 -0
  439. package/dist/components/{UNSTABLE_TimeOff → TimeOff}/HolidaySelectionForm/HolidaySelectionFormTypes.d.ts +2 -0
  440. package/dist/components/TimeOff/PolicyList/PolicyList.js +103 -0
  441. package/dist/components/TimeOff/PolicyList/PolicyList.js.map +1 -0
  442. package/dist/components/TimeOff/PolicyList/PolicyListPresentation.js +135 -0
  443. package/dist/components/TimeOff/PolicyList/PolicyListPresentation.js.map +1 -0
  444. package/dist/components/{UNSTABLE_TimeOff → TimeOff}/PolicyList/PolicyListTypes.d.ts +1 -1
  445. package/dist/components/TimeOff/PolicySettings/PolicySettings.js +70 -0
  446. package/dist/components/TimeOff/PolicySettings/PolicySettings.js.map +1 -0
  447. package/dist/components/TimeOff/PolicySettings/PolicySettings.module.scss.js +16 -0
  448. package/dist/components/TimeOff/PolicySettings/PolicySettingsPresentation.js +164 -0
  449. package/dist/components/TimeOff/PolicySettings/PolicySettingsPresentation.js.map +1 -0
  450. package/dist/components/{UNSTABLE_TimeOff → TimeOff}/PolicySettings/PolicySettingsTypes.d.ts +1 -1
  451. package/dist/components/TimeOff/PolicyTypeSelector/PolicyTypeSelector.js +31 -0
  452. package/dist/components/TimeOff/PolicyTypeSelector/PolicyTypeSelector.js.map +1 -0
  453. package/dist/components/{UNSTABLE_TimeOff → TimeOff}/PolicyTypeSelector/PolicyTypeSelectorPresentation.d.ts +1 -1
  454. package/dist/components/TimeOff/PolicyTypeSelector/PolicyTypeSelectorPresentation.js +68 -0
  455. package/dist/components/TimeOff/PolicyTypeSelector/PolicyTypeSelectorPresentation.js.map +1 -0
  456. package/dist/components/{UNSTABLE_TimeOff → TimeOff}/PolicyTypeSelector/PolicyTypeSelectorTypes.d.ts +1 -0
  457. package/dist/components/TimeOff/TimeOffFlow/TimeOffFlow.js.map +1 -0
  458. package/dist/components/{UNSTABLE_TimeOff → TimeOff}/TimeOffFlow/TimeOffFlowComponents.d.ts +3 -3
  459. package/dist/components/TimeOff/TimeOffFlow/TimeOffFlowComponents.js +117 -0
  460. package/dist/components/TimeOff/TimeOffFlow/TimeOffFlowComponents.js.map +1 -0
  461. package/dist/components/TimeOff/TimeOffFlow/timeOffPolicyTypes.d.ts +9 -0
  462. package/dist/components/TimeOff/TimeOffFlow/timeOffPolicyTypes.js +25 -0
  463. package/dist/components/TimeOff/TimeOffFlow/timeOffPolicyTypes.js.map +1 -0
  464. package/dist/components/{UNSTABLE_TimeOff → TimeOff}/TimeOffFlow/timeOffStateMachine.d.ts +4 -2
  465. package/dist/components/TimeOff/TimeOffFlow/timeOffStateMachine.js +487 -0
  466. package/dist/components/TimeOff/TimeOffFlow/timeOffStateMachine.js.map +1 -0
  467. package/dist/components/{UNSTABLE_TimeOff → TimeOff}/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationForm.d.ts +1 -0
  468. package/dist/components/TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationForm.js +158 -0
  469. package/dist/components/TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationForm.js.map +1 -0
  470. package/dist/components/{UNSTABLE_TimeOff → TimeOff}/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationFormPresentation.js +85 -76
  471. package/dist/components/TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationFormPresentation.js.map +1 -0
  472. package/dist/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesHoliday.d.ts +6 -0
  473. package/dist/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesHoliday.js +143 -0
  474. package/dist/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesHoliday.js.map +1 -0
  475. package/dist/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesPresentation.d.ts +2 -0
  476. package/dist/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesPresentation.js +103 -0
  477. package/dist/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesPresentation.js.map +1 -0
  478. package/dist/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesPresentationTypes.d.ts +41 -0
  479. package/dist/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesTimeOff.d.ts +9 -0
  480. package/dist/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesTimeOff.js +216 -0
  481. package/dist/components/TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesTimeOff.js.map +1 -0
  482. package/dist/components/{UNSTABLE_TimeOff → TimeOff}/TimeOffManagement/SelectEmployees/useSelectEmployeesData.d.ts +2 -1
  483. package/dist/components/TimeOff/TimeOffManagement/SelectEmployees/useSelectEmployeesData.js +64 -0
  484. package/dist/components/TimeOff/TimeOffManagement/SelectEmployees/useSelectEmployeesData.js.map +1 -0
  485. package/dist/components/TimeOff/TimeOffPolicyDetail/EditEmployeeBalanceModal.d.ts +9 -0
  486. package/dist/components/TimeOff/TimeOffPolicyDetail/EditEmployeeBalanceModal.js +56 -0
  487. package/dist/components/TimeOff/TimeOffPolicyDetail/EditEmployeeBalanceModal.js.map +1 -0
  488. package/dist/components/TimeOff/TimeOffPolicyDetail/TimeOffPolicyDetail.d.ts +5 -0
  489. package/dist/components/TimeOff/TimeOffPolicyDetail/TimeOffPolicyDetail.js +251 -0
  490. package/dist/components/TimeOff/TimeOffPolicyDetail/TimeOffPolicyDetail.js.map +1 -0
  491. package/dist/components/TimeOff/TimeOffPolicyDetail/TimeOffPolicyDetail.module.scss.js +10 -0
  492. package/dist/components/TimeOff/TimeOffPolicyDetail/TimeOffPolicyDetail.module.scss.js.map +1 -0
  493. package/dist/components/TimeOff/TimeOffPolicyDetail/TimeOffPolicyDetailPresentation.d.ts +2 -0
  494. package/dist/components/TimeOff/TimeOffPolicyDetail/TimeOffPolicyDetailPresentation.js +143 -0
  495. package/dist/components/TimeOff/TimeOffPolicyDetail/TimeOffPolicyDetailPresentation.js.map +1 -0
  496. package/dist/components/TimeOff/TimeOffPolicyDetail/TimeOffPolicyDetailTypes.d.ts +52 -0
  497. package/dist/components/TimeOff/TimeOffPolicyDetail/index.d.ts +7 -0
  498. package/dist/components/TimeOff/ViewHolidayEmployees/ViewHolidayEmployees.js +9 -0
  499. package/dist/components/TimeOff/ViewHolidayEmployees/ViewHolidayEmployees.js.map +1 -0
  500. package/dist/components/TimeOff/ViewHolidayPolicyDetails/ViewHolidayPolicyDetails.d.ts +6 -0
  501. package/dist/components/TimeOff/ViewHolidayPolicyDetails/ViewHolidayPolicyDetails.js +9 -0
  502. package/dist/components/TimeOff/ViewHolidayPolicyDetails/ViewHolidayPolicyDetails.js.map +1 -0
  503. package/dist/components/TimeOff/ViewHolidaySchedule/ViewHolidaySchedule.js +9 -0
  504. package/dist/components/TimeOff/ViewHolidaySchedule/ViewHolidaySchedule.js.map +1 -0
  505. package/dist/components/{UNSTABLE_TimeOff → TimeOff}/index.d.ts +5 -4
  506. package/dist/components/TimeOff/index.js +27 -0
  507. package/dist/components/TimeOff/shared/EmployeeTable/EmployeeTable.d.ts +2 -0
  508. package/dist/components/TimeOff/shared/EmployeeTable/EmployeeTable.js +95 -0
  509. package/dist/components/TimeOff/shared/EmployeeTable/EmployeeTable.js.map +1 -0
  510. package/dist/components/{UNSTABLE_TimeOff → TimeOff}/shared/EmployeeTable/EmployeeTableTypes.d.ts +2 -0
  511. package/dist/components/TimeOff/shared/PolicyDetailLayout/PolicyDetailLayout.d.ts +3 -0
  512. package/dist/components/TimeOff/shared/PolicyDetailLayout/PolicyDetailLayout.js +86 -0
  513. package/dist/components/TimeOff/shared/PolicyDetailLayout/PolicyDetailLayout.js.map +1 -0
  514. package/dist/components/TimeOff/shared/PolicyDetailLayout/PolicyDetailLayoutTypes.d.ts +27 -0
  515. package/dist/components/TimeOff/shared/PolicyDetailLayout/index.d.ts +3 -0
  516. package/dist/components/{UNSTABLE_TimeOff → TimeOff}/shared/holidayHelpers.d.ts +1 -1
  517. package/dist/components/{UNSTABLE_TimeOff → TimeOff}/shared/holidayHelpers.js +8 -8
  518. package/dist/components/TimeOff/shared/holidayHelpers.js.map +1 -0
  519. package/dist/components/TimeOff/shared/holidayHelpers.test.d.ts +1 -0
  520. package/dist/components/index.d.ts +1 -1
  521. package/dist/contexts/GustoProvider/GustoProviderCustomUIAdapter.js +11 -10
  522. package/dist/contexts/GustoProvider/GustoProviderCustomUIAdapter.js.map +1 -1
  523. package/dist/helpers/dateFormatting.d.ts +2 -0
  524. package/dist/helpers/dateFormatting.js +4 -0
  525. package/dist/helpers/dateFormatting.js.map +1 -1
  526. package/dist/i18n/I18n.js +11 -10
  527. package/dist/i18n/I18n.js.map +1 -1
  528. package/dist/i18n/en/Company.StateTaxes.json.js +1 -1
  529. package/dist/i18n/en/Company.TimeOff.CreateTimeOffPolicy.json.js +12 -14
  530. package/dist/i18n/en/Company.TimeOff.CreateTimeOffPolicy.json.js.map +1 -1
  531. package/dist/i18n/en/Company.TimeOff.HolidayPolicy.json.js +18 -16
  532. package/dist/i18n/en/Company.TimeOff.HolidayPolicy.json.js.map +1 -1
  533. package/dist/i18n/en/Company.TimeOff.PolicyDetail.json.js +14 -0
  534. package/dist/i18n/en/Company.TimeOff.PolicyDetail.json.js.map +1 -0
  535. package/dist/i18n/en/Company.TimeOff.SelectEmployees.json.js +24 -16
  536. package/dist/i18n/en/Company.TimeOff.SelectEmployees.json.js.map +1 -1
  537. package/dist/i18n/en/Company.TimeOff.TimeOffPolicies.json.js +14 -14
  538. package/dist/i18n/en/Company.TimeOff.TimeOffPolicyDetails.json.js +46 -42
  539. package/dist/i18n/en/Company.TimeOff.TimeOffPolicyDetails.json.js.map +1 -1
  540. package/dist/i18n/en/Employee.FederalTaxes.json.js +16 -10
  541. package/dist/i18n/en/Employee.FederalTaxes.json.js.map +1 -1
  542. package/dist/i18n/en/Employee.Profile.json.js +24 -20
  543. package/dist/i18n/en/Employee.Profile.json.js.map +1 -1
  544. package/dist/i18n/en/Employee.StateTaxes.json.js +14 -6
  545. package/dist/i18n/en/Employee.StateTaxes.json.js.map +1 -1
  546. package/dist/i18n/en/Payroll.GrossUpModal.json.js +12 -10
  547. package/dist/i18n/en/Payroll.GrossUpModal.json.js.map +1 -1
  548. package/dist/index.d.ts +8 -2
  549. package/dist/index.js +118 -93
  550. package/dist/index.js.map +1 -1
  551. package/dist/partner-hook-utils/form/SDKFormProvider.js +18 -14
  552. package/dist/partner-hook-utils/form/SDKFormProvider.js.map +1 -1
  553. package/dist/partner-hook-utils/form/buildFormSchema.js +41 -41
  554. package/dist/partner-hook-utils/form/buildFormSchema.js.map +1 -1
  555. package/dist/partner-hook-utils/form/composeSubmitHandler.d.ts +10 -6
  556. package/dist/partner-hook-utils/form/composeSubmitHandler.js +49 -26
  557. package/dist/partner-hook-utils/form/composeSubmitHandler.js.map +1 -1
  558. package/dist/partner-hook-utils/form/fields/CheckboxHookField.d.ts +1 -1
  559. package/dist/partner-hook-utils/form/fields/CheckboxHookField.js +27 -23
  560. package/dist/partner-hook-utils/form/fields/CheckboxHookField.js.map +1 -1
  561. package/dist/partner-hook-utils/form/fields/DatePickerHookField.d.ts +1 -1
  562. package/dist/partner-hook-utils/form/fields/DatePickerHookField.js +33 -29
  563. package/dist/partner-hook-utils/form/fields/DatePickerHookField.js.map +1 -1
  564. package/dist/partner-hook-utils/form/fields/NumberInputHookField.d.ts +1 -1
  565. package/dist/partner-hook-utils/form/fields/NumberInputHookField.js +37 -33
  566. package/dist/partner-hook-utils/form/fields/NumberInputHookField.js.map +1 -1
  567. package/dist/partner-hook-utils/form/fields/RadioGroupHookField.d.ts +1 -1
  568. package/dist/partner-hook-utils/form/fields/RadioGroupHookField.js +32 -28
  569. package/dist/partner-hook-utils/form/fields/RadioGroupHookField.js.map +1 -1
  570. package/dist/partner-hook-utils/form/fields/SelectHookField.d.ts +1 -1
  571. package/dist/partner-hook-utils/form/fields/SelectHookField.js +34 -30
  572. package/dist/partner-hook-utils/form/fields/SelectHookField.js.map +1 -1
  573. package/dist/partner-hook-utils/form/fields/SwitchHookField.d.ts +1 -1
  574. package/dist/partner-hook-utils/form/fields/SwitchHookField.js +23 -19
  575. package/dist/partner-hook-utils/form/fields/SwitchHookField.js.map +1 -1
  576. package/dist/partner-hook-utils/form/fields/TextInputHookField.d.ts +1 -1
  577. package/dist/partner-hook-utils/form/fields/TextInputHookField.js +31 -27
  578. package/dist/partner-hook-utils/form/fields/TextInputHookField.js.map +1 -1
  579. package/dist/partner-hook-utils/form/fields/withFieldElementRegistry.d.ts +10 -0
  580. package/dist/partner-hook-utils/form/fields/withFieldElementRegistry.js +9 -0
  581. package/dist/partner-hook-utils/form/fields/withFieldElementRegistry.js.map +1 -0
  582. package/dist/partner-hook-utils/form/index.d.ts +3 -0
  583. package/dist/partner-hook-utils/form/resolveFieldError.js +10 -7
  584. package/dist/partner-hook-utils/form/resolveFieldError.js.map +1 -1
  585. package/dist/partner-hook-utils/form/useFieldErrorMessage.js +10 -7
  586. package/dist/partner-hook-utils/form/useFieldErrorMessage.js.map +1 -1
  587. package/dist/partner-hook-utils/form/useHookFieldResolution.d.ts +10 -3
  588. package/dist/partner-hook-utils/form/useHookFieldResolution.js +6 -6
  589. package/dist/partner-hook-utils/form/useHookFieldResolution.js.map +1 -1
  590. package/dist/partner-hook-utils/form/useHookFormInternals.d.ts +22 -0
  591. package/dist/partner-hook-utils/form/useHookFormInternals.js +12 -0
  592. package/dist/partner-hook-utils/form/useHookFormInternals.js.map +1 -0
  593. package/dist/partner-hook-utils/types.d.ts +15 -0
  594. package/dist/shared/constants.d.ts +22 -0
  595. package/dist/shared/constants.js +41 -30
  596. package/dist/shared/constants.js.map +1 -1
  597. package/dist/style.css +1 -1
  598. package/dist/types/i18next.d.ts +62 -14
  599. package/docs/reference/endpoint-inventory.json +313 -122
  600. package/package.json +18 -16
  601. package/dist/components/Employee/Compensation/Actions.d.ts +0 -1
  602. package/dist/components/Employee/Compensation/Actions.js +0 -39
  603. package/dist/components/Employee/Compensation/Actions.js.map +0 -1
  604. package/dist/components/Employee/Compensation/Edit.d.ts +0 -5
  605. package/dist/components/Employee/Compensation/Edit.js +0 -179
  606. package/dist/components/Employee/Compensation/Edit.js.map +0 -1
  607. package/dist/components/Employee/Compensation/Head.d.ts +0 -1
  608. package/dist/components/Employee/Compensation/Head.js +0 -22
  609. package/dist/components/Employee/Compensation/Head.js.map +0 -1
  610. package/dist/components/Employee/Compensation/List.d.ts +0 -1
  611. package/dist/components/Employee/Compensation/List.js +0 -72
  612. package/dist/components/Employee/Compensation/List.js.map +0 -1
  613. package/dist/components/Employee/Compensation/useCompensation.js.map +0 -1
  614. package/dist/components/Employee/FederalTaxes/Actions.d.ts +0 -1
  615. package/dist/components/Employee/FederalTaxes/Actions.js +0 -14
  616. package/dist/components/Employee/FederalTaxes/Actions.js.map +0 -1
  617. package/dist/components/Employee/FederalTaxes/FederalForm.d.ts +0 -12
  618. package/dist/components/Employee/FederalTaxes/FederalForm.js +0 -110
  619. package/dist/components/Employee/FederalTaxes/FederalForm.js.map +0 -1
  620. package/dist/components/Employee/FederalTaxes/FederalTaxes.d.ts +0 -6
  621. package/dist/components/Employee/FederalTaxes/FederalTaxes.js +0 -84
  622. package/dist/components/Employee/FederalTaxes/FederalTaxes.js.map +0 -1
  623. package/dist/components/Employee/FederalTaxes/Head.d.ts +0 -1
  624. package/dist/components/Employee/FederalTaxes/Head.js +0 -24
  625. package/dist/components/Employee/FederalTaxes/Head.js.map +0 -1
  626. package/dist/components/Employee/FederalTaxes/useFederalTaxes.d.ts +0 -5
  627. package/dist/components/Employee/FederalTaxes/useFederalTaxes.js +0 -21
  628. package/dist/components/Employee/FederalTaxes/useFederalTaxes.js.map +0 -1
  629. package/dist/components/Employee/Profile/AdminProfile.js.map +0 -1
  630. package/dist/components/Employee/Profile/EmployeeProfile.js.map +0 -1
  631. package/dist/components/Employee/Profile/Profile.js.map +0 -1
  632. package/dist/components/Employee/Profile/index.d.ts +0 -2
  633. package/dist/components/Employee/StateTaxes/Actions.d.ts +0 -1
  634. package/dist/components/Employee/StateTaxes/Actions.js +0 -14
  635. package/dist/components/Employee/StateTaxes/Actions.js.map +0 -1
  636. package/dist/components/Employee/StateTaxes/StateForm.d.ts +0 -6
  637. package/dist/components/Employee/StateTaxes/StateForm.js +0 -34
  638. package/dist/components/Employee/StateTaxes/StateForm.js.map +0 -1
  639. package/dist/components/Employee/StateTaxes/StateTaxes.d.ts +0 -7
  640. package/dist/components/Employee/StateTaxes/StateTaxes.js +0 -98
  641. package/dist/components/Employee/StateTaxes/StateTaxes.js.map +0 -1
  642. package/dist/components/Employee/StateTaxes/useStateTaxes.d.ts +0 -8
  643. package/dist/components/Employee/StateTaxes/useStateTaxes.js +0 -21
  644. package/dist/components/Employee/StateTaxes/useStateTaxes.js.map +0 -1
  645. package/dist/components/UNSTABLE_TimeOff/AddEmployeesHoliday/AddEmployeesHoliday.js.map +0 -1
  646. package/dist/components/UNSTABLE_TimeOff/AddEmployeesToPolicy/AddEmployeesToPolicy.js.map +0 -1
  647. package/dist/components/UNSTABLE_TimeOff/HolidaySelectionForm/HolidaySelectionForm.js +0 -49
  648. package/dist/components/UNSTABLE_TimeOff/HolidaySelectionForm/HolidaySelectionForm.js.map +0 -1
  649. package/dist/components/UNSTABLE_TimeOff/HolidaySelectionForm/HolidaySelectionFormPresentation.js.map +0 -1
  650. package/dist/components/UNSTABLE_TimeOff/PolicyList/PolicyList.js +0 -107
  651. package/dist/components/UNSTABLE_TimeOff/PolicyList/PolicyList.js.map +0 -1
  652. package/dist/components/UNSTABLE_TimeOff/PolicyList/PolicyListPresentation.js +0 -125
  653. package/dist/components/UNSTABLE_TimeOff/PolicyList/PolicyListPresentation.js.map +0 -1
  654. package/dist/components/UNSTABLE_TimeOff/PolicySettings/PolicySettings.js +0 -66
  655. package/dist/components/UNSTABLE_TimeOff/PolicySettings/PolicySettings.js.map +0 -1
  656. package/dist/components/UNSTABLE_TimeOff/PolicySettings/PolicySettings.module.scss.js +0 -16
  657. package/dist/components/UNSTABLE_TimeOff/PolicySettings/PolicySettingsPresentation.js +0 -154
  658. package/dist/components/UNSTABLE_TimeOff/PolicySettings/PolicySettingsPresentation.js.map +0 -1
  659. package/dist/components/UNSTABLE_TimeOff/PolicyTypeSelector/PolicyTypeSelector.js +0 -29
  660. package/dist/components/UNSTABLE_TimeOff/PolicyTypeSelector/PolicyTypeSelector.js.map +0 -1
  661. package/dist/components/UNSTABLE_TimeOff/PolicyTypeSelector/PolicyTypeSelectorPresentation.js +0 -67
  662. package/dist/components/UNSTABLE_TimeOff/PolicyTypeSelector/PolicyTypeSelectorPresentation.js.map +0 -1
  663. package/dist/components/UNSTABLE_TimeOff/TimeOffFlow/TimeOffFlow.js.map +0 -1
  664. package/dist/components/UNSTABLE_TimeOff/TimeOffFlow/TimeOffFlowComponents.js +0 -112
  665. package/dist/components/UNSTABLE_TimeOff/TimeOffFlow/TimeOffFlowComponents.js.map +0 -1
  666. package/dist/components/UNSTABLE_TimeOff/TimeOffFlow/timeOffStateMachine.js +0 -317
  667. package/dist/components/UNSTABLE_TimeOff/TimeOffFlow/timeOffStateMachine.js.map +0 -1
  668. package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationForm.js +0 -72
  669. package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationForm.js.map +0 -1
  670. package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationFormPresentation.js.map +0 -1
  671. package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/SelectEmployees/SelectEmployees.d.ts +0 -2
  672. package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesHoliday.d.ts +0 -6
  673. package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesHoliday.js +0 -66
  674. package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesHoliday.js.map +0 -1
  675. package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesPresentation.d.ts +0 -2
  676. package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesPresentation.js +0 -82
  677. package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesPresentation.js.map +0 -1
  678. package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesPresentationTypes.d.ts +0 -24
  679. package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesTimeOff.d.ts +0 -7
  680. package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesTimeOff.js +0 -70
  681. package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesTimeOff.js.map +0 -1
  682. package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/SelectEmployees/SelectEmployeesTypes.d.ts +0 -24
  683. package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/SelectEmployees/useSelectEmployeesData.js +0 -56
  684. package/dist/components/UNSTABLE_TimeOff/TimeOffManagement/SelectEmployees/useSelectEmployeesData.js.map +0 -1
  685. package/dist/components/UNSTABLE_TimeOff/ViewHolidayEmployees/ViewHolidayEmployees.js +0 -35
  686. package/dist/components/UNSTABLE_TimeOff/ViewHolidayEmployees/ViewHolidayEmployees.js.map +0 -1
  687. package/dist/components/UNSTABLE_TimeOff/ViewHolidaySchedule/ViewHolidaySchedule.js +0 -35
  688. package/dist/components/UNSTABLE_TimeOff/ViewHolidaySchedule/ViewHolidaySchedule.js.map +0 -1
  689. package/dist/components/UNSTABLE_TimeOff/ViewPolicyDetails/ViewPolicyDetails.d.ts +0 -5
  690. package/dist/components/UNSTABLE_TimeOff/ViewPolicyDetails/ViewPolicyDetails.js +0 -35
  691. package/dist/components/UNSTABLE_TimeOff/ViewPolicyDetails/ViewPolicyDetails.js.map +0 -1
  692. package/dist/components/UNSTABLE_TimeOff/ViewPolicyEmployees/ViewPolicyEmployees.d.ts +0 -5
  693. package/dist/components/UNSTABLE_TimeOff/ViewPolicyEmployees/ViewPolicyEmployees.js +0 -35
  694. package/dist/components/UNSTABLE_TimeOff/ViewPolicyEmployees/ViewPolicyEmployees.js.map +0 -1
  695. package/dist/components/UNSTABLE_TimeOff/index.js +0 -27
  696. package/dist/components/UNSTABLE_TimeOff/shared/EmployeeTable/EmployeeTable.d.ts +0 -2
  697. package/dist/components/UNSTABLE_TimeOff/shared/EmployeeTable/EmployeeTable.js +0 -90
  698. package/dist/components/UNSTABLE_TimeOff/shared/EmployeeTable/EmployeeTable.js.map +0 -1
  699. package/dist/components/UNSTABLE_TimeOff/shared/holidayHelpers.js.map +0 -1
  700. /package/dist/components/Employee/{Compensation/shared/useCompensationForm/compensationSchemaParity.test.d.ts → FederalTaxes/shared/useFederalTaxesForm/federalTaxesSchema.test.d.ts} +0 -0
  701. /package/dist/components/Employee/Profile/{AdminProfile.d.ts → onboarding/AdminProfile.d.ts} +0 -0
  702. /package/dist/components/Employee/Profile/{AdminProfile.module.scss.js → onboarding/AdminProfile.module.scss.js} +0 -0
  703. /package/dist/components/Employee/Profile/{AdminProfile.module.scss.js.map → onboarding/AdminProfile.module.scss.js.map} +0 -0
  704. /package/dist/components/Employee/Profile/{EmployeeProfile.d.ts → onboarding/EmployeeProfile.d.ts} +0 -0
  705. /package/dist/components/Employee/Profile/{EmployeeProfile.module.scss.js → onboarding/EmployeeProfile.module.scss.js} +0 -0
  706. /package/dist/components/Employee/Profile/{EmployeeProfile.module.scss.js.map → onboarding/EmployeeProfile.module.scss.js.map} +0 -0
  707. /package/dist/components/{UNSTABLE_TimeOff/TimeOffFlow/timeOffStateMachine.test.d.ts → Employee/StateTaxes/shared/useEmployeeStateTaxesForm/employeeStateTaxesSchema.test.d.ts} +0 -0
  708. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/AddEmployeesHoliday/AddEmployeesHoliday.d.ts +0 -0
  709. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/AddEmployeesHoliday/AddEmployeesHoliday.js +0 -0
  710. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/HolidaySelectionForm/HolidaySelectionFormPresentation.d.ts +0 -0
  711. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/PolicyList/PolicyList.d.ts +0 -0
  712. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/PolicyList/PolicyListPresentation.d.ts +0 -0
  713. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/PolicyList/PolicyListPresentation.module.scss.js +0 -0
  714. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/PolicyList/PolicyListPresentation.module.scss.js.map +0 -0
  715. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/PolicySettings/PolicySettings.d.ts +0 -0
  716. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/PolicySettings/PolicySettings.module.scss.js.map +0 -0
  717. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/PolicySettings/PolicySettingsPresentation.d.ts +0 -0
  718. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/PolicyTypeSelector/PolicyTypeSelector.d.ts +0 -0
  719. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/TimeOffFlow/TimeOffFlow.d.ts +0 -0
  720. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/TimeOffFlow/TimeOffFlow.js +0 -0
  721. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/TimeOffFlow/index.d.ts +0 -0
  722. /package/dist/components/{UNSTABLE_TimeOff/shared/holidayHelpers.test.d.ts → TimeOff/TimeOffFlow/timeOffStateMachine.test.d.ts} +0 -0
  723. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationForm.module.scss.js +0 -0
  724. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationForm.module.scss.js.map +0 -0
  725. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationFormPresentation.d.ts +0 -0
  726. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/TimeOffManagement/PolicyConfigurationForm/PolicyConfigurationFormTypes.d.ts +0 -0
  727. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/TimeOffManagement/PolicyConfigurationForm/index.d.ts +0 -0
  728. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/ViewHolidayEmployees/ViewHolidayEmployees.d.ts +0 -0
  729. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/ViewHolidaySchedule/ViewHolidaySchedule.d.ts +0 -0
  730. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/index.js.map +0 -0
  731. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/shared/EmployeeTable/EmployeeTable.module.scss.js +0 -0
  732. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/shared/EmployeeTable/EmployeeTable.module.scss.js.map +0 -0
  733. /package/dist/components/{UNSTABLE_TimeOff → TimeOff}/shared/EmployeeTable/index.d.ts +0 -0
@@ -1,90 +1,114 @@
1
1
  import { z as e } from "zod";
2
- import { buildFormSchema as d } from "../../../../../partner-hook-utils/form/buildFormSchema.js";
3
- import { coerceStringBoolean as i, coerceToISODate as N, coerceNaN as m } from "../../../../../partner-hook-utils/form/preprocessors.js";
4
- import { PAY_PERIODS as r, FlsaStatus as t, FLSA_OVERTIME_SALARY_LIMIT as O } from "../../../../../shared/constants.js";
5
- import { yearlyRate as T } from "../../../../../helpers/payRateCalculator.js";
6
- const E = {
2
+ import { buildFormSchema as _ } from "../../../../../partner-hook-utils/form/buildFormSchema.js";
3
+ import { coerceToISODate as N, coerceNaN as T } from "../../../../../partner-hook-utils/form/preprocessors.js";
4
+ import { PAY_PERIODS as I, FlsaStatus as E, FLSA_OVERTIME_SALARY_LIMIT as d } from "../../../../../shared/constants.js";
5
+ import { yearlyRate as O } from "../../../../../helpers/payRateCalculator.js";
6
+ const o = {
7
7
  REQUIRED: "REQUIRED",
8
8
  RATE_MINIMUM: "RATE_MINIMUM",
9
9
  RATE_EXEMPT_THRESHOLD: "RATE_EXEMPT_THRESHOLD",
10
10
  PAYMENT_UNIT_OWNER: "PAYMENT_UNIT_OWNER",
11
11
  PAYMENT_UNIT_COMMISSION: "PAYMENT_UNIT_COMMISSION",
12
- RATE_COMMISSION_ZERO: "RATE_COMMISSION_ZERO"
13
- }, n = {
14
- jobTitle: e.string(),
12
+ RATE_COMMISSION_ZERO: "RATE_COMMISSION_ZERO",
13
+ EFFECTIVE_DATE_BEFORE_HIRE: "EFFECTIVE_DATE_BEFORE_HIRE"
14
+ }, m = {
15
+ /**
16
+ * Optional in both modes. Setting title here scopes the change to this
17
+ * compensation's `effectiveDate` — pair it with a future-dated comp to
18
+ * schedule a promotion title alongside a rate change. Use
19
+ * `useJobForm.Fields.Title` instead when creating a job (title is required
20
+ * by the API on job creation) or when renaming the active role
21
+ * immediately, and avoid rendering both fields on the same screen.
22
+ */
23
+ title: e.string(),
24
+ // `flsaStatus` is `.optional()` so the field can render an empty placeholder
25
+ // until the user (or partner default) picks one. Requiredness is still
26
+ // enforced via `requiredFieldsConfig` on submit in `create` mode.
15
27
  flsaStatus: e.enum([
16
- t.EXEMPT,
17
- t.SALARIED_NONEXEMPT,
18
- t.NONEXEMPT,
19
- t.OWNER,
20
- t.COMMISSION_ONLY_EXEMPT,
21
- t.COMMISSION_ONLY_NONEXEMPT
22
- ]),
28
+ E.EXEMPT,
29
+ E.SALARIED_NONEXEMPT,
30
+ E.NONEXEMPT,
31
+ E.OWNER,
32
+ E.COMMISSION_ONLY_EXEMPT,
33
+ E.COMMISSION_ONLY_NONEXEMPT
34
+ ]).optional(),
23
35
  paymentUnit: e.enum([
24
- r.HOUR,
25
- r.WEEK,
26
- r.MONTH,
27
- r.YEAR,
28
- r.PAYCHECK
36
+ I.HOUR,
37
+ I.WEEK,
38
+ I.MONTH,
39
+ I.YEAR,
40
+ I.PAYCHECK
29
41
  ]),
30
- rate: e.preprocess(m(0), e.number()),
31
- startDate: e.preprocess(N, e.iso.date().nullable()),
42
+ rate: e.preprocess(T(0), e.number()),
43
+ /**
44
+ * The effective date a new compensation should take effect on.
45
+ *
46
+ * - **create mode (`compensationId` absent)**: required; partners typically default
47
+ * to the parent job's `hireDate` (onboarding stub-fill) or a future date
48
+ * (rate change). Must be on or after `hireDate`. Server-side this maps to
49
+ * POST /v1/jobs/:jobId/compensations.
50
+ * - **update mode (`compensationId` present)**: optional; if omitted the API
51
+ * keeps the existing effective date. The `hireDate` lower bound is **not**
52
+ * enforced — loaded values may legitimately predate the hire date. Maps to
53
+ * PUT /v1/compensations/:id.
54
+ */
55
+ effectiveDate: e.preprocess(N, e.iso.date().nullable()),
32
56
  adjustForMinimumWage: e.boolean(),
33
- minimumWageId: e.string(),
34
- // Radio group delivers 'true'/'false' strings; coerceStringBoolean converts to boolean
35
- stateWcCovered: e.preprocess(i, e.boolean()),
36
- stateWcClassCode: e.string(),
37
- twoPercentShareholder: e.boolean()
38
- }, u = {
39
- jobTitle: "create",
57
+ minimumWageId: e.string()
58
+ }, R = {
59
+ title: "never",
40
60
  flsaStatus: "create",
41
61
  paymentUnit: "create",
42
62
  rate: "create",
43
- startDate: "create",
44
- minimumWageId: (o) => o.adjustForMinimumWage,
45
- stateWcClassCode: (o) => String(o.stateWcCovered) === "true"
63
+ effectiveDate: "create",
64
+ minimumWageId: (i) => i.adjustForMinimumWage
46
65
  };
47
- function _(o, a) {
48
- const { flsaStatus: s, paymentUnit: I, rate: M } = o;
49
- s === t.EXEMPT || s === t.SALARIED_NONEXEMPT || s === t.NONEXEMPT ? M < 1 ? a.addIssue({
66
+ function u(i, s) {
67
+ const { flsaStatus: t, paymentUnit: M, rate: a } = i;
68
+ t === E.EXEMPT || t === E.SALARIED_NONEXEMPT || t === E.NONEXEMPT ? t === E.EXEMPT && O(a, M) < d ? s.addIssue({
50
69
  code: e.ZodIssueCode.custom,
51
70
  path: ["rate"],
52
- message: E.RATE_MINIMUM
53
- }) : s === t.EXEMPT && T(M, I) < O && a.addIssue({
71
+ message: o.RATE_EXEMPT_THRESHOLD
72
+ }) : a < 1 && s.addIssue({
54
73
  code: e.ZodIssueCode.custom,
55
74
  path: ["rate"],
56
- message: E.RATE_EXEMPT_THRESHOLD
57
- }) : s === t.OWNER ? (I !== r.PAYCHECK && a.addIssue({
75
+ message: o.RATE_MINIMUM
76
+ }) : t === E.OWNER ? (M !== I.PAYCHECK && s.addIssue({
58
77
  code: e.ZodIssueCode.custom,
59
78
  path: ["paymentUnit"],
60
- message: E.PAYMENT_UNIT_OWNER
61
- }), M < 1 && a.addIssue({
79
+ message: o.PAYMENT_UNIT_OWNER
80
+ }), a < 1 && s.addIssue({
62
81
  code: e.ZodIssueCode.custom,
63
82
  path: ["rate"],
64
- message: E.RATE_MINIMUM
65
- })) : (s === t.COMMISSION_ONLY_EXEMPT || s === t.COMMISSION_ONLY_NONEXEMPT) && (I !== r.YEAR && a.addIssue({
83
+ message: o.RATE_MINIMUM
84
+ })) : (t === E.COMMISSION_ONLY_EXEMPT || t === E.COMMISSION_ONLY_NONEXEMPT) && (M !== I.YEAR && s.addIssue({
66
85
  code: e.ZodIssueCode.custom,
67
86
  path: ["paymentUnit"],
68
- message: E.PAYMENT_UNIT_COMMISSION
69
- }), M !== 0 && a.addIssue({
87
+ message: o.PAYMENT_UNIT_COMMISSION
88
+ }), a !== 0 && s.addIssue({
70
89
  code: e.ZodIssueCode.custom,
71
90
  path: ["rate"],
72
- message: E.RATE_COMMISSION_ZERO
91
+ message: o.RATE_COMMISSION_ZERO
73
92
  }));
74
93
  }
75
- function A(o = {}) {
76
- const { mode: a = "create", optionalFieldsToRequire: s, withStartDateField: I = !0 } = o;
77
- return d(n, {
78
- requiredFieldsConfig: u,
79
- requiredErrorCode: E.REQUIRED,
80
- mode: a,
81
- optionalFieldsToRequire: s,
82
- excludeFields: I ? [] : ["startDate"],
83
- superRefine: _
94
+ function C(i = {}) {
95
+ const { mode: s = "create", optionalFieldsToRequire: t, hireDate: M } = i;
96
+ return _(m, {
97
+ requiredFieldsConfig: R,
98
+ requiredErrorCode: o.REQUIRED,
99
+ mode: s,
100
+ optionalFieldsToRequire: t,
101
+ superRefine: (a, r) => {
102
+ u(a, r), s === "create" && M && a.effectiveDate && a.effectiveDate < M && r.addIssue({
103
+ code: e.ZodIssueCode.custom,
104
+ path: ["effectiveDate"],
105
+ message: o.EFFECTIVE_DATE_BEFORE_HIRE
106
+ });
107
+ }
84
108
  });
85
109
  }
86
110
  export {
87
- E as CompensationErrorCodes,
88
- A as createCompensationSchema
111
+ o as CompensationErrorCodes,
112
+ C as createCompensationSchema
89
113
  };
90
114
  //# sourceMappingURL=compensationSchema.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"compensationSchema.js","sources":["../../../../../../src/components/Employee/Compensation/shared/useCompensationForm/compensationSchema.ts"],"sourcesContent":["import { z } from 'zod'\nimport {\n buildFormSchema,\n type RequiredFieldConfig,\n type OptionalFieldsToRequire,\n} from '@/partner-hook-utils/form/buildFormSchema'\nimport {\n coerceNaN,\n coerceToISODate,\n coerceStringBoolean,\n} from '@/partner-hook-utils/form/preprocessors'\nimport { FLSA_OVERTIME_SALARY_LIMIT, FlsaStatus, PAY_PERIODS } from '@/shared/constants'\nimport { yearlyRate } from '@/helpers/payRateCalculator'\n\n// ── Error codes ────────────────────────────────────────────────────────\n\nexport const CompensationErrorCodes = {\n REQUIRED: 'REQUIRED',\n RATE_MINIMUM: 'RATE_MINIMUM',\n RATE_EXEMPT_THRESHOLD: 'RATE_EXEMPT_THRESHOLD',\n PAYMENT_UNIT_OWNER: 'PAYMENT_UNIT_OWNER',\n PAYMENT_UNIT_COMMISSION: 'PAYMENT_UNIT_COMMISSION',\n RATE_COMMISSION_ZERO: 'RATE_COMMISSION_ZERO',\n} as const\n\nexport type CompensationErrorCode =\n (typeof CompensationErrorCodes)[keyof typeof CompensationErrorCodes]\n\nconst fieldValidators = {\n jobTitle: z.string(),\n flsaStatus: z.enum([\n FlsaStatus.EXEMPT,\n FlsaStatus.SALARIED_NONEXEMPT,\n FlsaStatus.NONEXEMPT,\n FlsaStatus.OWNER,\n FlsaStatus.COMMISSION_ONLY_EXEMPT,\n FlsaStatus.COMMISSION_ONLY_NONEXEMPT,\n ]),\n paymentUnit: z.enum([\n PAY_PERIODS.HOUR,\n PAY_PERIODS.WEEK,\n PAY_PERIODS.MONTH,\n PAY_PERIODS.YEAR,\n PAY_PERIODS.PAYCHECK,\n ]),\n rate: z.preprocess(coerceNaN(0), z.number()),\n startDate: z.preprocess(coerceToISODate, z.iso.date().nullable()),\n adjustForMinimumWage: z.boolean(),\n minimumWageId: z.string(),\n // Radio group delivers 'true'/'false' strings; coerceStringBoolean converts to boolean\n stateWcCovered: z.preprocess(coerceStringBoolean, z.boolean()),\n stateWcClassCode: z.string(),\n twoPercentShareholder: z.boolean(),\n}\n\nexport type CompensationFormData = {\n [K in keyof typeof fieldValidators]: z.infer<(typeof fieldValidators)[K]>\n}\n\n// ── Required fields config (requiredness rules per field) ────────────\n\nconst requiredFieldsConfig = {\n jobTitle: 'create',\n flsaStatus: 'create',\n paymentUnit: 'create',\n rate: 'create',\n startDate: 'create',\n minimumWageId: data => data.adjustForMinimumWage,\n stateWcClassCode: data => String(data.stateWcCovered) === 'true',\n} satisfies RequiredFieldConfig<typeof fieldValidators>\n\nfunction validateFlsaRules(data: CompensationFormData, ctx: z.RefinementCtx) {\n const { flsaStatus, paymentUnit, rate } = data\n\n if (\n flsaStatus === FlsaStatus.EXEMPT ||\n flsaStatus === FlsaStatus.SALARIED_NONEXEMPT ||\n flsaStatus === FlsaStatus.NONEXEMPT\n ) {\n if (rate < 1) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n path: ['rate'],\n message: CompensationErrorCodes.RATE_MINIMUM,\n })\n } else if (\n flsaStatus === FlsaStatus.EXEMPT &&\n yearlyRate(rate, paymentUnit) < FLSA_OVERTIME_SALARY_LIMIT\n ) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n path: ['rate'],\n message: CompensationErrorCodes.RATE_EXEMPT_THRESHOLD,\n })\n }\n } else if (flsaStatus === FlsaStatus.OWNER) {\n if (paymentUnit !== PAY_PERIODS.PAYCHECK) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n path: ['paymentUnit'],\n message: CompensationErrorCodes.PAYMENT_UNIT_OWNER,\n })\n }\n if (rate < 1) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n path: ['rate'],\n message: CompensationErrorCodes.RATE_MINIMUM,\n })\n }\n /* eslint-disable @typescript-eslint/no-unnecessary-condition -- explicit match prevents a future FLSA status from silently falling into commission rules */\n } else if (\n flsaStatus === FlsaStatus.COMMISSION_ONLY_EXEMPT ||\n flsaStatus === FlsaStatus.COMMISSION_ONLY_NONEXEMPT\n ) {\n /* eslint-enable @typescript-eslint/no-unnecessary-condition */\n if (paymentUnit !== PAY_PERIODS.YEAR) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n path: ['paymentUnit'],\n message: CompensationErrorCodes.PAYMENT_UNIT_COMMISSION,\n })\n }\n if (rate !== 0) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n path: ['rate'],\n message: CompensationErrorCodes.RATE_COMMISSION_ZERO,\n })\n }\n }\n}\n\n// ── Schema factory ───────────────────────────────────────────────────\n\nexport type CompensationOptionalFieldsToRequire = OptionalFieldsToRequire<\n typeof requiredFieldsConfig\n>\nexport type CompensationFormOutputs = CompensationFormData\n\ninterface CompensationSchemaOptions {\n mode?: 'create' | 'update'\n optionalFieldsToRequire?: CompensationOptionalFieldsToRequire\n withStartDateField?: boolean\n}\n\nexport function createCompensationSchema(options: CompensationSchemaOptions = {}) {\n const { mode = 'create', optionalFieldsToRequire, withStartDateField = true } = options\n\n return buildFormSchema(fieldValidators, {\n requiredFieldsConfig,\n requiredErrorCode: CompensationErrorCodes.REQUIRED,\n mode,\n optionalFieldsToRequire,\n excludeFields: withStartDateField ? [] : ['startDate'],\n superRefine: validateFlsaRules,\n })\n}\n"],"names":["CompensationErrorCodes","fieldValidators","z","FlsaStatus","PAY_PERIODS","coerceNaN","coerceToISODate","coerceStringBoolean","requiredFieldsConfig","data","validateFlsaRules","ctx","flsaStatus","paymentUnit","rate","yearlyRate","FLSA_OVERTIME_SALARY_LIMIT","createCompensationSchema","options","mode","optionalFieldsToRequire","withStartDateField","buildFormSchema"],"mappings":";;;;;AAgBO,MAAMA,IAAyB;AAAA,EACpC,UAAU;AAAA,EACV,cAAc;AAAA,EACd,uBAAuB;AAAA,EACvB,oBAAoB;AAAA,EACpB,yBAAyB;AAAA,EACzB,sBAAsB;AACxB,GAKMC,IAAkB;AAAA,EACtB,UAAUC,EAAE,OAAA;AAAA,EACZ,YAAYA,EAAE,KAAK;AAAA,IACjBC,EAAW;AAAA,IACXA,EAAW;AAAA,IACXA,EAAW;AAAA,IACXA,EAAW;AAAA,IACXA,EAAW;AAAA,IACXA,EAAW;AAAA,EAAA,CACZ;AAAA,EACD,aAAaD,EAAE,KAAK;AAAA,IAClBE,EAAY;AAAA,IACZA,EAAY;AAAA,IACZA,EAAY;AAAA,IACZA,EAAY;AAAA,IACZA,EAAY;AAAA,EAAA,CACb;AAAA,EACD,MAAMF,EAAE,WAAWG,EAAU,CAAC,GAAGH,EAAE,QAAQ;AAAA,EAC3C,WAAWA,EAAE,WAAWI,GAAiBJ,EAAE,IAAI,OAAO,UAAU;AAAA,EAChE,sBAAsBA,EAAE,QAAA;AAAA,EACxB,eAAeA,EAAE,OAAA;AAAA;AAAA,EAEjB,gBAAgBA,EAAE,WAAWK,GAAqBL,EAAE,SAAS;AAAA,EAC7D,kBAAkBA,EAAE,OAAA;AAAA,EACpB,uBAAuBA,EAAE,QAAA;AAC3B,GAQMM,IAAuB;AAAA,EAC3B,UAAU;AAAA,EACV,YAAY;AAAA,EACZ,aAAa;AAAA,EACb,MAAM;AAAA,EACN,WAAW;AAAA,EACX,eAAe,OAAQC,EAAK;AAAA,EAC5B,kBAAkB,CAAAA,MAAQ,OAAOA,EAAK,cAAc,MAAM;AAC5D;AAEA,SAASC,EAAkBD,GAA4BE,GAAsB;AAC3E,QAAM,EAAE,YAAAC,GAAY,aAAAC,GAAa,MAAAC,EAAA,IAASL;AAE1C,EACEG,MAAeT,EAAW,UAC1BS,MAAeT,EAAW,sBAC1BS,MAAeT,EAAW,YAEtBW,IAAO,IACTH,EAAI,SAAS;AAAA,IACX,MAAMT,EAAE,aAAa;AAAA,IACrB,MAAM,CAAC,MAAM;AAAA,IACb,SAASF,EAAuB;AAAA,EAAA,CACjC,IAEDY,MAAeT,EAAW,UAC1BY,EAAWD,GAAMD,CAAW,IAAIG,KAEhCL,EAAI,SAAS;AAAA,IACX,MAAMT,EAAE,aAAa;AAAA,IACrB,MAAM,CAAC,MAAM;AAAA,IACb,SAASF,EAAuB;AAAA,EAAA,CACjC,IAEMY,MAAeT,EAAW,SAC/BU,MAAgBT,EAAY,YAC9BO,EAAI,SAAS;AAAA,IACX,MAAMT,EAAE,aAAa;AAAA,IACrB,MAAM,CAAC,aAAa;AAAA,IACpB,SAASF,EAAuB;AAAA,EAAA,CACjC,GAECc,IAAO,KACTH,EAAI,SAAS;AAAA,IACX,MAAMT,EAAE,aAAa;AAAA,IACrB,MAAM,CAAC,MAAM;AAAA,IACb,SAASF,EAAuB;AAAA,EAAA,CACjC,MAIHY,MAAeT,EAAW,0BAC1BS,MAAeT,EAAW,+BAGtBU,MAAgBT,EAAY,QAC9BO,EAAI,SAAS;AAAA,IACX,MAAMT,EAAE,aAAa;AAAA,IACrB,MAAM,CAAC,aAAa;AAAA,IACpB,SAASF,EAAuB;AAAA,EAAA,CACjC,GAECc,MAAS,KACXH,EAAI,SAAS;AAAA,IACX,MAAMT,EAAE,aAAa;AAAA,IACrB,MAAM,CAAC,MAAM;AAAA,IACb,SAASF,EAAuB;AAAA,EAAA,CACjC;AAGP;AAeO,SAASiB,EAAyBC,IAAqC,IAAI;AAChF,QAAM,EAAE,MAAAC,IAAO,UAAU,yBAAAC,GAAyB,oBAAAC,IAAqB,OAASH;AAEhF,SAAOI,EAAgBrB,GAAiB;AAAA,IACtC,sBAAAO;AAAA,IACA,mBAAmBR,EAAuB;AAAA,IAC1C,MAAAmB;AAAA,IACA,yBAAAC;AAAA,IACA,eAAeC,IAAqB,KAAK,CAAC,WAAW;AAAA,IACrD,aAAaX;AAAA,EAAA,CACd;AACH;"}
1
+ {"version":3,"file":"compensationSchema.js","sources":["../../../../../../src/components/Employee/Compensation/shared/useCompensationForm/compensationSchema.ts"],"sourcesContent":["import { z } from 'zod'\nimport {\n buildFormSchema,\n type RequiredFieldConfig,\n type OptionalFieldsToRequire,\n} from '@/partner-hook-utils/form/buildFormSchema'\nimport { coerceNaN, coerceToISODate } from '@/partner-hook-utils/form/preprocessors'\nimport { FLSA_OVERTIME_SALARY_LIMIT, FlsaStatus, PAY_PERIODS } from '@/shared/constants'\nimport { yearlyRate } from '@/helpers/payRateCalculator'\n\n// ── Error codes ────────────────────────────────────────────────────────\n\nexport const CompensationErrorCodes = {\n REQUIRED: 'REQUIRED',\n RATE_MINIMUM: 'RATE_MINIMUM',\n RATE_EXEMPT_THRESHOLD: 'RATE_EXEMPT_THRESHOLD',\n PAYMENT_UNIT_OWNER: 'PAYMENT_UNIT_OWNER',\n PAYMENT_UNIT_COMMISSION: 'PAYMENT_UNIT_COMMISSION',\n RATE_COMMISSION_ZERO: 'RATE_COMMISSION_ZERO',\n EFFECTIVE_DATE_BEFORE_HIRE: 'EFFECTIVE_DATE_BEFORE_HIRE',\n} as const\n\nexport type CompensationErrorCode =\n (typeof CompensationErrorCodes)[keyof typeof CompensationErrorCodes]\n\nconst fieldValidators = {\n /**\n * Optional in both modes. Setting title here scopes the change to this\n * compensation's `effectiveDate` — pair it with a future-dated comp to\n * schedule a promotion title alongside a rate change. Use\n * `useJobForm.Fields.Title` instead when creating a job (title is required\n * by the API on job creation) or when renaming the active role\n * immediately, and avoid rendering both fields on the same screen.\n */\n title: z.string(),\n // `flsaStatus` is `.optional()` so the field can render an empty placeholder\n // until the user (or partner default) picks one. Requiredness is still\n // enforced via `requiredFieldsConfig` on submit in `create` mode.\n flsaStatus: z\n .enum([\n FlsaStatus.EXEMPT,\n FlsaStatus.SALARIED_NONEXEMPT,\n FlsaStatus.NONEXEMPT,\n FlsaStatus.OWNER,\n FlsaStatus.COMMISSION_ONLY_EXEMPT,\n FlsaStatus.COMMISSION_ONLY_NONEXEMPT,\n ])\n .optional(),\n paymentUnit: z.enum([\n PAY_PERIODS.HOUR,\n PAY_PERIODS.WEEK,\n PAY_PERIODS.MONTH,\n PAY_PERIODS.YEAR,\n PAY_PERIODS.PAYCHECK,\n ]),\n rate: z.preprocess(coerceNaN(0), z.number()),\n /**\n * The effective date a new compensation should take effect on.\n *\n * - **create mode (`compensationId` absent)**: required; partners typically default\n * to the parent job's `hireDate` (onboarding stub-fill) or a future date\n * (rate change). Must be on or after `hireDate`. Server-side this maps to\n * POST /v1/jobs/:jobId/compensations.\n * - **update mode (`compensationId` present)**: optional; if omitted the API\n * keeps the existing effective date. The `hireDate` lower bound is **not**\n * enforced loaded values may legitimately predate the hire date. Maps to\n * PUT /v1/compensations/:id.\n */\n effectiveDate: z.preprocess(coerceToISODate, z.iso.date().nullable()),\n adjustForMinimumWage: z.boolean(),\n minimumWageId: z.string(),\n}\n\nexport type CompensationFormData = {\n [K in keyof typeof fieldValidators]: z.infer<(typeof fieldValidators)[K]>\n}\n\nconst requiredFieldsConfig = {\n title: 'never',\n flsaStatus: 'create',\n paymentUnit: 'create',\n rate: 'create',\n effectiveDate: 'create',\n minimumWageId: data => data.adjustForMinimumWage,\n} satisfies RequiredFieldConfig<typeof fieldValidators>\n\nfunction validateFlsaRules(data: CompensationFormData, ctx: z.RefinementCtx) {\n const { flsaStatus, paymentUnit, rate } = data\n\n if (\n flsaStatus === FlsaStatus.EXEMPT ||\n flsaStatus === FlsaStatus.SALARIED_NONEXEMPT ||\n flsaStatus === FlsaStatus.NONEXEMPT\n ) {\n // Surface the EXEMPT salary-threshold issue *before* the generic minimum,\n // so a partner setting rate=0 with EXEMPT sees the more actionable\n // \"must meet salary threshold\" message rather than the generic\n // \"amount must be at least $1.00\".\n if (\n flsaStatus === FlsaStatus.EXEMPT &&\n yearlyRate(rate, paymentUnit) < FLSA_OVERTIME_SALARY_LIMIT\n ) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n path: ['rate'],\n message: CompensationErrorCodes.RATE_EXEMPT_THRESHOLD,\n })\n } else if (rate < 1) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n path: ['rate'],\n message: CompensationErrorCodes.RATE_MINIMUM,\n })\n }\n } else if (flsaStatus === FlsaStatus.OWNER) {\n if (paymentUnit !== PAY_PERIODS.PAYCHECK) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n path: ['paymentUnit'],\n message: CompensationErrorCodes.PAYMENT_UNIT_OWNER,\n })\n }\n if (rate < 1) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n path: ['rate'],\n message: CompensationErrorCodes.RATE_MINIMUM,\n })\n }\n } else if (\n flsaStatus === FlsaStatus.COMMISSION_ONLY_EXEMPT ||\n flsaStatus === FlsaStatus.COMMISSION_ONLY_NONEXEMPT\n ) {\n if (paymentUnit !== PAY_PERIODS.YEAR) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n path: ['paymentUnit'],\n message: CompensationErrorCodes.PAYMENT_UNIT_COMMISSION,\n })\n }\n if (rate !== 0) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n path: ['rate'],\n message: CompensationErrorCodes.RATE_COMMISSION_ZERO,\n })\n }\n }\n}\n\nexport type CompensationOptionalFieldsToRequire = OptionalFieldsToRequire<\n typeof requiredFieldsConfig\n>\nexport type CompensationFormOutputs = CompensationFormData\n\nexport interface CompensationSchemaOptions {\n mode?: 'create' | 'update'\n optionalFieldsToRequire?: CompensationOptionalFieldsToRequire\n /**\n * Lower bound for `effectiveDate` (typically the parent job's `hireDate`).\n * Only enforced in `create` mode — on `update` the loaded effective date\n * may legitimately predate the hire date and is left as-is. Surfaces an\n * `EFFECTIVE_DATE_BEFORE_HIRE` issue when violated.\n */\n hireDate?: string | null\n}\n\nexport function createCompensationSchema(options: CompensationSchemaOptions = {}) {\n const { mode = 'create', optionalFieldsToRequire, hireDate } = options\n\n return buildFormSchema(fieldValidators, {\n requiredFieldsConfig,\n requiredErrorCode: CompensationErrorCodes.REQUIRED,\n mode,\n optionalFieldsToRequire,\n superRefine: (data, ctx) => {\n validateFlsaRules(data, ctx)\n // Only enforce the hire-date lower bound when picking a brand-new\n // effective date (create mode). On update, the loaded effectiveDate\n // can legitimately predate the parent job's hireDate (e.g. carried\n // over from a stub or out-of-order data) and the API accepts the\n // unchanged value or omitting it entirely. Blocking the submit here\n // would trap partners whose flow doesn't render Fields.EffectiveDate.\n if (mode === 'create' && hireDate && data.effectiveDate && data.effectiveDate < hireDate) {\n ctx.addIssue({\n code: z.ZodIssueCode.custom,\n path: ['effectiveDate'],\n message: CompensationErrorCodes.EFFECTIVE_DATE_BEFORE_HIRE,\n })\n }\n },\n })\n}\n"],"names":["CompensationErrorCodes","fieldValidators","z","FlsaStatus","PAY_PERIODS","coerceNaN","coerceToISODate","requiredFieldsConfig","data","validateFlsaRules","ctx","flsaStatus","paymentUnit","rate","yearlyRate","FLSA_OVERTIME_SALARY_LIMIT","createCompensationSchema","options","mode","optionalFieldsToRequire","hireDate","buildFormSchema"],"mappings":";;;;;AAYO,MAAMA,IAAyB;AAAA,EACpC,UAAU;AAAA,EACV,cAAc;AAAA,EACd,uBAAuB;AAAA,EACvB,oBAAoB;AAAA,EACpB,yBAAyB;AAAA,EACzB,sBAAsB;AAAA,EACtB,4BAA4B;AAC9B,GAKMC,IAAkB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAStB,OAAOC,EAAE,OAAA;AAAA;AAAA;AAAA;AAAA,EAIT,YAAYA,EACT,KAAK;AAAA,IACJC,EAAW;AAAA,IACXA,EAAW;AAAA,IACXA,EAAW;AAAA,IACXA,EAAW;AAAA,IACXA,EAAW;AAAA,IACXA,EAAW;AAAA,EAAA,CACZ,EACA,SAAA;AAAA,EACH,aAAaD,EAAE,KAAK;AAAA,IAClBE,EAAY;AAAA,IACZA,EAAY;AAAA,IACZA,EAAY;AAAA,IACZA,EAAY;AAAA,IACZA,EAAY;AAAA,EAAA,CACb;AAAA,EACD,MAAMF,EAAE,WAAWG,EAAU,CAAC,GAAGH,EAAE,QAAQ;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAa3C,eAAeA,EAAE,WAAWI,GAAiBJ,EAAE,IAAI,OAAO,UAAU;AAAA,EACpE,sBAAsBA,EAAE,QAAA;AAAA,EACxB,eAAeA,EAAE,OAAA;AACnB,GAMMK,IAAuB;AAAA,EAC3B,OAAO;AAAA,EACP,YAAY;AAAA,EACZ,aAAa;AAAA,EACb,MAAM;AAAA,EACN,eAAe;AAAA,EACf,eAAe,OAAQC,EAAK;AAC9B;AAEA,SAASC,EAAkBD,GAA4BE,GAAsB;AAC3E,QAAM,EAAE,YAAAC,GAAY,aAAAC,GAAa,MAAAC,EAAA,IAASL;AAE1C,EACEG,MAAeR,EAAW,UAC1BQ,MAAeR,EAAW,sBAC1BQ,MAAeR,EAAW,YAOxBQ,MAAeR,EAAW,UAC1BW,EAAWD,GAAMD,CAAW,IAAIG,IAEhCL,EAAI,SAAS;AAAA,IACX,MAAMR,EAAE,aAAa;AAAA,IACrB,MAAM,CAAC,MAAM;AAAA,IACb,SAASF,EAAuB;AAAA,EAAA,CACjC,IACQa,IAAO,KAChBH,EAAI,SAAS;AAAA,IACX,MAAMR,EAAE,aAAa;AAAA,IACrB,MAAM,CAAC,MAAM;AAAA,IACb,SAASF,EAAuB;AAAA,EAAA,CACjC,IAEMW,MAAeR,EAAW,SAC/BS,MAAgBR,EAAY,YAC9BM,EAAI,SAAS;AAAA,IACX,MAAMR,EAAE,aAAa;AAAA,IACrB,MAAM,CAAC,aAAa;AAAA,IACpB,SAASF,EAAuB;AAAA,EAAA,CACjC,GAECa,IAAO,KACTH,EAAI,SAAS;AAAA,IACX,MAAMR,EAAE,aAAa;AAAA,IACrB,MAAM,CAAC,MAAM;AAAA,IACb,SAASF,EAAuB;AAAA,EAAA,CACjC,MAGHW,MAAeR,EAAW,0BAC1BQ,MAAeR,EAAW,+BAEtBS,MAAgBR,EAAY,QAC9BM,EAAI,SAAS;AAAA,IACX,MAAMR,EAAE,aAAa;AAAA,IACrB,MAAM,CAAC,aAAa;AAAA,IACpB,SAASF,EAAuB;AAAA,EAAA,CACjC,GAECa,MAAS,KACXH,EAAI,SAAS;AAAA,IACX,MAAMR,EAAE,aAAa;AAAA,IACrB,MAAM,CAAC,MAAM;AAAA,IACb,SAASF,EAAuB;AAAA,EAAA,CACjC;AAGP;AAmBO,SAASgB,EAAyBC,IAAqC,IAAI;AAChF,QAAM,EAAE,MAAAC,IAAO,UAAU,yBAAAC,GAAyB,UAAAC,MAAaH;AAE/D,SAAOI,EAAgBpB,GAAiB;AAAA,IACtC,sBAAAM;AAAA,IACA,mBAAmBP,EAAuB;AAAA,IAC1C,MAAAkB;AAAA,IACA,yBAAAC;AAAA,IACA,aAAa,CAACX,GAAME,MAAQ;AAC1B,MAAAD,EAAkBD,GAAME,CAAG,GAOvBQ,MAAS,YAAYE,KAAYZ,EAAK,iBAAiBA,EAAK,gBAAgBY,KAC9EV,EAAI,SAAS;AAAA,QACX,MAAMR,EAAE,aAAa;AAAA,QACrB,MAAM,CAAC,eAAe;AAAA,QACtB,SAASF,EAAuB;AAAA,MAAA,CACjC;AAAA,IAEL;AAAA,EAAA,CACD;AACH;"}
@@ -6,14 +6,13 @@ import { TextInputHookFieldProps } from '../../../../../partner-hook-utils/form/
6
6
  import { SelectHookFieldProps } from '../../../../../partner-hook-utils/form/fields/SelectHookField';
7
7
  import { NumberInputHookFieldProps } from '../../../../../partner-hook-utils/form/fields/NumberInputHookField';
8
8
  import { CheckboxHookFieldProps } from '../../../../../partner-hook-utils/form/fields/CheckboxHookField';
9
- import { RadioGroupHookFieldProps } from '../../../../../partner-hook-utils/form/fields/RadioGroupHookField';
10
9
  import { DatePickerHookFieldProps } from '../../../../../partner-hook-utils/form/fields/DatePickerHookField';
11
10
  import { HookFieldProps } from '../../../../../partner-hook-utils/types';
12
- import { WARiskClassCode } from '../../../../../models/WA_RISK_CODES';
13
11
  export type RequiredValidation = typeof CompensationErrorCodes.REQUIRED;
14
12
  export type RateValidation = (typeof CompensationErrorCodes)['REQUIRED' | 'RATE_MINIMUM' | 'RATE_EXEMPT_THRESHOLD'];
15
- export type JobTitleFieldProps = HookFieldProps<TextInputHookFieldProps<RequiredValidation>>;
16
- export declare function JobTitleField(props: JobTitleFieldProps): import("react/jsx-runtime").JSX.Element;
13
+ export type EffectiveDateValidation = (typeof CompensationErrorCodes)['REQUIRED' | 'EFFECTIVE_DATE_BEFORE_HIRE'];
14
+ export type TitleFieldProps = HookFieldProps<TextInputHookFieldProps<RequiredValidation>>;
15
+ export declare function TitleField(props: TitleFieldProps): import("react/jsx-runtime").JSX.Element;
17
16
  export type FlsaStatusFieldProps = HookFieldProps<SelectHookFieldProps<RequiredValidation, FlsaStatusType>>;
18
17
  export declare function FlsaStatusField(props: FlsaStatusFieldProps): import("react/jsx-runtime").JSX.Element;
19
18
  export type RateFieldProps = HookFieldProps<NumberInputHookFieldProps<RateValidation>>;
@@ -24,11 +23,5 @@ export type AdjustForMinimumWageFieldProps = HookFieldProps<CheckboxHookFieldPro
24
23
  export declare function AdjustForMinimumWageField(props: AdjustForMinimumWageFieldProps): import("react/jsx-runtime").JSX.Element;
25
24
  export type MinimumWageIdFieldProps = HookFieldProps<SelectHookFieldProps<RequiredValidation, MinimumWage>>;
26
25
  export declare function MinimumWageIdField(props: MinimumWageIdFieldProps): import("react/jsx-runtime").JSX.Element;
27
- export type TwoPercentShareholderFieldProps = HookFieldProps<CheckboxHookFieldProps>;
28
- export declare function TwoPercentShareholderField(props: TwoPercentShareholderFieldProps): import("react/jsx-runtime").JSX.Element;
29
- export type StateWcCoveredFieldProps = HookFieldProps<RadioGroupHookFieldProps<never, boolean>>;
30
- export declare function StateWcCoveredField(props: StateWcCoveredFieldProps): import("react/jsx-runtime").JSX.Element;
31
- export type StateWcClassCodeFieldProps = HookFieldProps<SelectHookFieldProps<RequiredValidation, WARiskClassCode>>;
32
- export declare function StateWcClassCodeField(props: StateWcClassCodeFieldProps): import("react/jsx-runtime").JSX.Element;
33
- export type StartDateFieldProps = HookFieldProps<DatePickerHookFieldProps<typeof CompensationErrorCodes.REQUIRED>>;
34
- export declare function StartDateField(props: StartDateFieldProps): import("react/jsx-runtime").JSX.Element;
26
+ export type EffectiveDateFieldProps = HookFieldProps<DatePickerHookFieldProps<EffectiveDateValidation>>;
27
+ export declare function EffectiveDateField(props: EffectiveDateFieldProps): import("react/jsx-runtime").JSX.Element;
@@ -1,50 +1,37 @@
1
1
  import { jsx as t } from "react/jsx-runtime";
2
- import { SelectHookField as n } from "../../../../../partner-hook-utils/form/fields/SelectHookField.js";
3
- import { RadioGroupHookField as o } from "../../../../../partner-hook-utils/form/fields/RadioGroupHookField.js";
2
+ import { DatePickerHookField as n } from "../../../../../partner-hook-utils/form/fields/DatePickerHookField.js";
3
+ import { SelectHookField as i } from "../../../../../partner-hook-utils/form/fields/SelectHookField.js";
4
4
  import { CheckboxHookField as r } from "../../../../../partner-hook-utils/form/fields/CheckboxHookField.js";
5
- import { NumberInputHookField as i } from "../../../../../partner-hook-utils/form/fields/NumberInputHookField.js";
6
- import { TextInputHookField as a } from "../../../../../partner-hook-utils/form/fields/TextInputHookField.js";
7
- import { DatePickerHookField as m } from "../../../../../partner-hook-utils/form/fields/DatePickerHookField.js";
5
+ import { NumberInputHookField as o } from "../../../../../partner-hook-utils/form/fields/NumberInputHookField.js";
6
+ import { TextInputHookField as m } from "../../../../../partner-hook-utils/form/fields/TextInputHookField.js";
7
+ function c(e) {
8
+ return /* @__PURE__ */ t(m, { ...e, name: "title" });
9
+ }
8
10
  function p(e) {
9
- return /* @__PURE__ */ t(a, { ...e, name: "jobTitle" });
11
+ return /* @__PURE__ */ t(i, { ...e, name: "flsaStatus" });
10
12
  }
11
13
  function k(e) {
12
- return /* @__PURE__ */ t(n, { ...e, name: "flsaStatus" });
13
- }
14
- function S(e) {
15
- return /* @__PURE__ */ t(i, { ...e, name: "rate", format: "currency", min: 0 });
14
+ return /* @__PURE__ */ t(o, { ...e, name: "rate", format: "currency", min: 0 });
16
15
  }
17
- function W(e) {
18
- return /* @__PURE__ */ t(n, { ...e, name: "paymentUnit" });
19
- }
20
- function C(e) {
21
- return /* @__PURE__ */ t(r, { ...e, name: "adjustForMinimumWage" });
16
+ function s(e) {
17
+ return /* @__PURE__ */ t(i, { ...e, name: "paymentUnit" });
22
18
  }
23
19
  function H(e) {
24
- return /* @__PURE__ */ t(n, { ...e, name: "minimumWageId" });
25
- }
26
- function h(e) {
27
- return /* @__PURE__ */ t(r, { ...e, name: "twoPercentShareholder" });
28
- }
29
- function b(e) {
30
- return /* @__PURE__ */ t(o, { ...e, name: "stateWcCovered" });
20
+ return /* @__PURE__ */ t(r, { ...e, name: "adjustForMinimumWage" });
31
21
  }
32
22
  function g(e) {
33
- return /* @__PURE__ */ t(n, { ...e, name: "stateWcClassCode" });
23
+ return /* @__PURE__ */ t(i, { ...e, name: "minimumWageId" });
34
24
  }
35
- function j(e) {
36
- return /* @__PURE__ */ t(m, { ...e, name: "startDate" });
25
+ function x(e) {
26
+ return /* @__PURE__ */ t(n, { ...e, name: "effectiveDate" });
37
27
  }
38
28
  export {
39
- C as AdjustForMinimumWageField,
40
- k as FlsaStatusField,
41
- p as JobTitleField,
42
- H as MinimumWageIdField,
43
- W as PaymentUnitField,
44
- S as RateField,
45
- j as StartDateField,
46
- g as StateWcClassCodeField,
47
- b as StateWcCoveredField,
48
- h as TwoPercentShareholderField
29
+ H as AdjustForMinimumWageField,
30
+ x as EffectiveDateField,
31
+ p as FlsaStatusField,
32
+ g as MinimumWageIdField,
33
+ s as PaymentUnitField,
34
+ k as RateField,
35
+ c as TitleField
49
36
  };
50
37
  //# sourceMappingURL=fields.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"fields.js","sources":["../../../../../../src/components/Employee/Compensation/shared/useCompensationForm/fields.tsx"],"sourcesContent":["import type { MinimumWage } from '@gusto/embedded-api/models/components/minimumwage'\nimport type { FlsaStatusType } from '@gusto/embedded-api/models/components/flsastatustype'\nimport type { PaymentUnit } from '@gusto/embedded-api/models/components/compensation'\nimport type { CompensationErrorCodes } from './compensationSchema'\nimport type { TextInputHookFieldProps } from '@/partner-hook-utils/form/fields/TextInputHookField'\nimport type { SelectHookFieldProps } from '@/partner-hook-utils/form/fields/SelectHookField'\nimport type { NumberInputHookFieldProps } from '@/partner-hook-utils/form/fields/NumberInputHookField'\nimport type { CheckboxHookFieldProps } from '@/partner-hook-utils/form/fields/CheckboxHookField'\nimport type { RadioGroupHookFieldProps } from '@/partner-hook-utils/form/fields/RadioGroupHookField'\nimport type { DatePickerHookFieldProps } from '@/partner-hook-utils/form/fields/DatePickerHookField'\nimport {\n TextInputHookField,\n SelectHookField,\n NumberInputHookField,\n CheckboxHookField,\n RadioGroupHookField,\n DatePickerHookField,\n} from '@/partner-hook-utils/form/fields'\nimport type { HookFieldProps } from '@/partner-hook-utils/types'\nimport type { WARiskClassCode } from '@/models/WA_RISK_CODES'\n\nexport type RequiredValidation = typeof CompensationErrorCodes.REQUIRED\nexport type RateValidation = (typeof CompensationErrorCodes)[\n | 'REQUIRED'\n | 'RATE_MINIMUM'\n | 'RATE_EXEMPT_THRESHOLD']\n\nexport type JobTitleFieldProps = HookFieldProps<TextInputHookFieldProps<RequiredValidation>>\n\nexport function JobTitleField(props: JobTitleFieldProps) {\n return <TextInputHookField {...props} name=\"jobTitle\" />\n}\n\nexport type FlsaStatusFieldProps = HookFieldProps<\n SelectHookFieldProps<RequiredValidation, FlsaStatusType>\n>\n\nexport function FlsaStatusField(props: FlsaStatusFieldProps) {\n return <SelectHookField {...props} name=\"flsaStatus\" />\n}\n\nexport type RateFieldProps = HookFieldProps<NumberInputHookFieldProps<RateValidation>>\n\nexport function RateField(props: RateFieldProps) {\n return <NumberInputHookField {...props} name=\"rate\" format=\"currency\" min={0} />\n}\n\nexport type PaymentUnitFieldProps = HookFieldProps<\n SelectHookFieldProps<RequiredValidation, PaymentUnit>\n>\n\nexport function PaymentUnitField(props: PaymentUnitFieldProps) {\n return <SelectHookField {...props} name=\"paymentUnit\" />\n}\n\nexport type AdjustForMinimumWageFieldProps = HookFieldProps<CheckboxHookFieldProps>\n\nexport function AdjustForMinimumWageField(props: AdjustForMinimumWageFieldProps) {\n return <CheckboxHookField {...props} name=\"adjustForMinimumWage\" />\n}\n\nexport type MinimumWageIdFieldProps = HookFieldProps<\n SelectHookFieldProps<RequiredValidation, MinimumWage>\n>\n\nexport function MinimumWageIdField(props: MinimumWageIdFieldProps) {\n return <SelectHookField {...props} name=\"minimumWageId\" />\n}\n\nexport type TwoPercentShareholderFieldProps = HookFieldProps<CheckboxHookFieldProps>\n\nexport function TwoPercentShareholderField(props: TwoPercentShareholderFieldProps) {\n return <CheckboxHookField {...props} name=\"twoPercentShareholder\" />\n}\n\nexport type StateWcCoveredFieldProps = HookFieldProps<RadioGroupHookFieldProps<never, boolean>>\n\nexport function StateWcCoveredField(props: StateWcCoveredFieldProps) {\n return <RadioGroupHookField {...props} name=\"stateWcCovered\" />\n}\n\nexport type StateWcClassCodeFieldProps = HookFieldProps<\n SelectHookFieldProps<RequiredValidation, WARiskClassCode>\n>\n\nexport function StateWcClassCodeField(props: StateWcClassCodeFieldProps) {\n return <SelectHookField {...props} name=\"stateWcClassCode\" />\n}\n\nexport type StartDateFieldProps = HookFieldProps<\n DatePickerHookFieldProps<typeof CompensationErrorCodes.REQUIRED>\n>\n\nexport function StartDateField(props: StartDateFieldProps) {\n return <DatePickerHookField {...props} name=\"startDate\" />\n}\n"],"names":["JobTitleField","props","jsx","TextInputHookField","FlsaStatusField","SelectHookField","RateField","NumberInputHookField","PaymentUnitField","AdjustForMinimumWageField","CheckboxHookField","MinimumWageIdField","TwoPercentShareholderField","StateWcCoveredField","RadioGroupHookField","StateWcClassCodeField","StartDateField","DatePickerHookField"],"mappings":";;;;;;;AA6BO,SAASA,EAAcC,GAA2B;AACvD,SAAO,gBAAAC,EAACC,GAAA,EAAoB,GAAGF,GAAO,MAAK,YAAW;AACxD;AAMO,SAASG,EAAgBH,GAA6B;AAC3D,SAAO,gBAAAC,EAACG,GAAA,EAAiB,GAAGJ,GAAO,MAAK,cAAa;AACvD;AAIO,SAASK,EAAUL,GAAuB;AAC/C,SAAO,gBAAAC,EAACK,KAAsB,GAAGN,GAAO,MAAK,QAAO,QAAO,YAAW,KAAK,EAAA,CAAG;AAChF;AAMO,SAASO,EAAiBP,GAA8B;AAC7D,SAAO,gBAAAC,EAACG,GAAA,EAAiB,GAAGJ,GAAO,MAAK,eAAc;AACxD;AAIO,SAASQ,EAA0BR,GAAuC;AAC/E,SAAO,gBAAAC,EAACQ,GAAA,EAAmB,GAAGT,GAAO,MAAK,wBAAuB;AACnE;AAMO,SAASU,EAAmBV,GAAgC;AACjE,SAAO,gBAAAC,EAACG,GAAA,EAAiB,GAAGJ,GAAO,MAAK,iBAAgB;AAC1D;AAIO,SAASW,EAA2BX,GAAwC;AACjF,SAAO,gBAAAC,EAACQ,GAAA,EAAmB,GAAGT,GAAO,MAAK,yBAAwB;AACpE;AAIO,SAASY,EAAoBZ,GAAiC;AACnE,SAAO,gBAAAC,EAACY,GAAA,EAAqB,GAAGb,GAAO,MAAK,kBAAiB;AAC/D;AAMO,SAASc,EAAsBd,GAAmC;AACvE,SAAO,gBAAAC,EAACG,GAAA,EAAiB,GAAGJ,GAAO,MAAK,oBAAmB;AAC7D;AAMO,SAASe,EAAef,GAA4B;AACzD,SAAO,gBAAAC,EAACe,GAAA,EAAqB,GAAGhB,GAAO,MAAK,aAAY;AAC1D;"}
1
+ {"version":3,"file":"fields.js","sources":["../../../../../../src/components/Employee/Compensation/shared/useCompensationForm/fields.tsx"],"sourcesContent":["import type { MinimumWage } from '@gusto/embedded-api/models/components/minimumwage'\nimport type { FlsaStatusType } from '@gusto/embedded-api/models/components/flsastatustype'\nimport type { PaymentUnit } from '@gusto/embedded-api/models/components/compensation'\nimport type { CompensationErrorCodes } from './compensationSchema'\nimport type { TextInputHookFieldProps } from '@/partner-hook-utils/form/fields/TextInputHookField'\nimport type { SelectHookFieldProps } from '@/partner-hook-utils/form/fields/SelectHookField'\nimport type { NumberInputHookFieldProps } from '@/partner-hook-utils/form/fields/NumberInputHookField'\nimport type { CheckboxHookFieldProps } from '@/partner-hook-utils/form/fields/CheckboxHookField'\nimport type { DatePickerHookFieldProps } from '@/partner-hook-utils/form/fields/DatePickerHookField'\nimport {\n TextInputHookField,\n SelectHookField,\n NumberInputHookField,\n CheckboxHookField,\n DatePickerHookField,\n} from '@/partner-hook-utils/form/fields'\nimport type { HookFieldProps } from '@/partner-hook-utils/types'\n\nexport type RequiredValidation = typeof CompensationErrorCodes.REQUIRED\nexport type RateValidation = (typeof CompensationErrorCodes)[\n | 'REQUIRED'\n | 'RATE_MINIMUM'\n | 'RATE_EXEMPT_THRESHOLD']\nexport type EffectiveDateValidation = (typeof CompensationErrorCodes)[\n | 'REQUIRED'\n | 'EFFECTIVE_DATE_BEFORE_HIRE']\n\nexport type TitleFieldProps = HookFieldProps<TextInputHookFieldProps<RequiredValidation>>\n\nexport function TitleField(props: TitleFieldProps) {\n return <TextInputHookField {...props} name=\"title\" />\n}\n\nexport type FlsaStatusFieldProps = HookFieldProps<\n SelectHookFieldProps<RequiredValidation, FlsaStatusType>\n>\n\nexport function FlsaStatusField(props: FlsaStatusFieldProps) {\n return <SelectHookField {...props} name=\"flsaStatus\" />\n}\n\nexport type RateFieldProps = HookFieldProps<NumberInputHookFieldProps<RateValidation>>\n\nexport function RateField(props: RateFieldProps) {\n return <NumberInputHookField {...props} name=\"rate\" format=\"currency\" min={0} />\n}\n\nexport type PaymentUnitFieldProps = HookFieldProps<\n SelectHookFieldProps<RequiredValidation, PaymentUnit>\n>\n\nexport function PaymentUnitField(props: PaymentUnitFieldProps) {\n return <SelectHookField {...props} name=\"paymentUnit\" />\n}\n\nexport type AdjustForMinimumWageFieldProps = HookFieldProps<CheckboxHookFieldProps>\n\nexport function AdjustForMinimumWageField(props: AdjustForMinimumWageFieldProps) {\n return <CheckboxHookField {...props} name=\"adjustForMinimumWage\" />\n}\n\nexport type MinimumWageIdFieldProps = HookFieldProps<\n SelectHookFieldProps<RequiredValidation, MinimumWage>\n>\n\nexport function MinimumWageIdField(props: MinimumWageIdFieldProps) {\n return <SelectHookField {...props} name=\"minimumWageId\" />\n}\n\nexport type EffectiveDateFieldProps = HookFieldProps<\n DatePickerHookFieldProps<EffectiveDateValidation>\n>\n\nexport function EffectiveDateField(props: EffectiveDateFieldProps) {\n return <DatePickerHookField {...props} name=\"effectiveDate\" />\n}\n"],"names":["TitleField","props","jsx","TextInputHookField","FlsaStatusField","SelectHookField","RateField","NumberInputHookField","PaymentUnitField","AdjustForMinimumWageField","CheckboxHookField","MinimumWageIdField","EffectiveDateField","DatePickerHookField"],"mappings":";;;;;;AA6BO,SAASA,EAAWC,GAAwB;AACjD,SAAO,gBAAAC,EAACC,GAAA,EAAoB,GAAGF,GAAO,MAAK,SAAQ;AACrD;AAMO,SAASG,EAAgBH,GAA6B;AAC3D,SAAO,gBAAAC,EAACG,GAAA,EAAiB,GAAGJ,GAAO,MAAK,cAAa;AACvD;AAIO,SAASK,EAAUL,GAAuB;AAC/C,SAAO,gBAAAC,EAACK,KAAsB,GAAGN,GAAO,MAAK,QAAO,QAAO,YAAW,KAAK,EAAA,CAAG;AAChF;AAMO,SAASO,EAAiBP,GAA8B;AAC7D,SAAO,gBAAAC,EAACG,GAAA,EAAiB,GAAGJ,GAAO,MAAK,eAAc;AACxD;AAIO,SAASQ,EAA0BR,GAAuC;AAC/E,SAAO,gBAAAC,EAACQ,GAAA,EAAmB,GAAGT,GAAO,MAAK,wBAAuB;AACnE;AAMO,SAASU,EAAmBV,GAAgC;AACjE,SAAO,gBAAAC,EAACG,GAAA,EAAiB,GAAGJ,GAAO,MAAK,iBAAgB;AAC1D;AAMO,SAASW,EAAmBX,GAAgC;AACjE,SAAO,gBAAAC,EAACW,GAAA,EAAqB,GAAGZ,GAAO,MAAK,iBAAgB;AAC9D;"}
@@ -1,5 +1,7 @@
1
1
  import "./types/i18next.d.ts"
2
2
  export { useCompensationForm } from './useCompensationForm';
3
- export type { CompensationSubmitCallbacks, CompensationSubmitOptions, UseCompensationFormProps, UseCompensationFormResult, UseCompensationFormReady, CompensationFieldsMetadata, CompensationFormFields, } from './useCompensationForm';
4
- export { createCompensationSchema, CompensationErrorCodes, type CompensationErrorCode, type CompensationOptionalFieldsToRequire, type CompensationFormData, type CompensationFormOutputs, } from './compensationSchema';
5
- export type { RequiredValidation, RateValidation, StartDateFieldProps, JobTitleFieldProps, FlsaStatusFieldProps, RateFieldProps, PaymentUnitFieldProps, AdjustForMinimumWageFieldProps, MinimumWageIdFieldProps, TwoPercentShareholderFieldProps, StateWcCoveredFieldProps, StateWcClassCodeFieldProps, } from './fields';
3
+ export { useCurrentCompensationForm } from './useCurrentCompensationForm';
4
+ export type { CompensationSubmitOptions, UseCompensationFormProps, UseCompensationFormResult, UseCompensationFormReady, CompensationFieldsMetadata, CompensationFormFields, } from './useCompensationForm';
5
+ export type { UseCurrentCompensationFormProps } from './useCurrentCompensationForm';
6
+ export { createCompensationSchema, CompensationErrorCodes, type CompensationErrorCode, type CompensationOptionalFieldsToRequire, type CompensationFormData, type CompensationFormOutputs, type CompensationSchemaOptions, } from './compensationSchema';
7
+ export type { RequiredValidation, RateValidation, EffectiveDateValidation, TitleFieldProps, EffectiveDateFieldProps, FlsaStatusFieldProps, RateFieldProps, PaymentUnitFieldProps, AdjustForMinimumWageFieldProps, MinimumWageIdFieldProps, } from './fields';
@@ -3,41 +3,83 @@ import { Compensation } from '@gusto/embedded-api/models/components/compensation
3
3
  import { Job } from '@gusto/embedded-api/models/components/job';
4
4
  import { MinimumWage } from '@gusto/embedded-api/models/components/minimumwage';
5
5
  import { CompensationOptionalFieldsToRequire, CompensationFormData } from './compensationSchema';
6
+ import { TitleField, FlsaStatusField, RateField, PaymentUnitField, AdjustForMinimumWageField, MinimumWageIdField, EffectiveDateField } from './fields';
6
7
  import { BaseFormHookReady, FieldsMetadata, HookLoadingResult, HookSubmitResult } from '../../../../../partner-hook-utils/types';
7
- export interface CompensationSubmitCallbacks {
8
- onJobCreated?: (job: Job) => void;
9
- onJobUpdated?: (job: Job) => void;
10
- onCompensationUpdated?: (compensation: Compensation | undefined) => void;
11
- }
12
8
  export interface CompensationSubmitOptions {
13
- employeeId?: string;
14
- startDate?: string;
9
+ /** Override jobId — required when creating a compensation if not configured at hook construction (e.g. when the parent job was just created in the same submit chain). */
10
+ jobId?: string;
11
+ /** Override compensationId — when present, forces update (PUT) routing regardless of hook construction. */
12
+ compensationId?: string;
13
+ /**
14
+ * Compensation version for optimistic locking on PUT. Required when forcing
15
+ * update routing post-create (e.g. updating the auto-created stub returned
16
+ * from `POST /v1/employees/:id/jobs`). When omitted, the hook reads the
17
+ * version from its cached `currentCompensation`.
18
+ */
19
+ compensationVersion?: string;
15
20
  }
16
21
  export interface UseCompensationFormProps {
17
22
  employeeId?: string;
18
- withStartDateField?: boolean;
23
+ /** When updating, the parent job's UUID. Used to scope minimum wages and to derive `status.willDeleteSecondaryJobs`. */
19
24
  jobId?: string;
25
+ /** Present → update mode (PUT /v1/compensations/:id). Omitted → create mode (POST /v1/jobs/:jobId/compensations). */
26
+ compensationId?: string;
20
27
  optionalFieldsToRequire?: CompensationOptionalFieldsToRequire;
21
28
  defaultValues?: Partial<CompensationFormData>;
22
29
  validationMode?: UseFormProps['mode'];
23
30
  shouldFocusError?: boolean;
24
31
  }
25
- export interface UseCompensationFormReady extends BaseFormHookReady<FieldsMetadata, CompensationFormData> {
32
+ export interface CompensationFormFields {
33
+ Title: typeof TitleField;
34
+ FlsaStatus: typeof FlsaStatusField | undefined;
35
+ Rate: typeof RateField;
36
+ PaymentUnit: typeof PaymentUnitField;
37
+ AdjustForMinimumWage: typeof AdjustForMinimumWageField | undefined;
38
+ MinimumWageId: typeof MinimumWageIdField | undefined;
39
+ EffectiveDate: typeof EffectiveDateField | undefined;
40
+ }
41
+ export interface UseCompensationFormReady extends BaseFormHookReady<FieldsMetadata, CompensationFormData, CompensationFormFields> {
26
42
  data: {
43
+ /** The compensation row loaded for update; `null` in create mode. */
27
44
  compensation: Compensation | null;
28
- jobs: Job[] | undefined;
45
+ /** The parent job (when `jobId` resolves), used for derived helpers. */
29
46
  currentJob: Job | null;
30
47
  minimumWages: MinimumWage[];
48
+ /** Lower bound for `effectiveDate` (typically the parent job's hire date). */
49
+ minimumEffectiveDate: string | null;
50
+ /** Upper bound for `effectiveDate` — the next scheduled future compensation's effective date, when one exists. */
51
+ maximumEffectiveDate: string | null;
52
+ /** True when at least one future-dated compensation already exists for this job. */
53
+ hasPendingFutureCompensation: boolean;
31
54
  };
32
55
  status: {
33
56
  isPending: boolean;
34
57
  mode: 'create' | 'update';
58
+ /**
59
+ * True when submitting the form right now would delete the employee's
60
+ * secondary jobs server-side (the "carve-out" branch). Reactive:
61
+ * derived from the current `flsaStatus` form value, the loaded
62
+ * compensation, and the other-jobs count, so this flips as you change
63
+ * inputs.
64
+ *
65
+ * Conditions: update mode, the loaded compensation is Nonexempt, the
66
+ * form's `flsaStatus` has been changed to a non-Nonexempt value, and
67
+ * the employee has at least one secondary job.
68
+ *
69
+ * While this flag is true the hook also takes the `effectiveDate`
70
+ * field over: it forces the form value to today (so submits route
71
+ * through a PUT that immediately deletes secondaries) and exposes
72
+ * `fieldsMetadata.effectiveDate.isDisabled = true` so `Fields.EffectiveDate`
73
+ * renders as disabled. On revert (FLSA back to Nonexempt) the prior
74
+ * `effectiveDate` is restored. Render an inline warning keyed off
75
+ * this flag — no separate confirmation step is needed.
76
+ */
77
+ willDeleteSecondaryJobs: boolean;
35
78
  };
36
79
  actions: {
37
- onSubmit: (callbacks?: CompensationSubmitCallbacks, options?: CompensationSubmitOptions) => Promise<HookSubmitResult<Compensation | undefined> | undefined>;
80
+ onSubmit: (options?: CompensationSubmitOptions) => Promise<HookSubmitResult<Compensation> | undefined>;
38
81
  };
39
82
  }
40
- export declare function useCompensationForm({ employeeId, withStartDateField, jobId, optionalFieldsToRequire, defaultValues: partnerDefaults, validationMode, shouldFocusError, }: UseCompensationFormProps): HookLoadingResult | UseCompensationFormReady;
83
+ export declare function useCompensationForm({ employeeId, jobId, compensationId, optionalFieldsToRequire, defaultValues: partnerDefaults, validationMode, shouldFocusError, }: UseCompensationFormProps): HookLoadingResult | UseCompensationFormReady;
41
84
  export type UseCompensationFormResult = HookLoadingResult | UseCompensationFormReady;
42
85
  export type CompensationFieldsMetadata = UseCompensationFormReady['form']['fieldsMetadata'];
43
- export type CompensationFormFields = UseCompensationFormReady['form']['Fields'];