@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,14 +1,15 @@
1
1
  import { jsx as t } from "react/jsx-runtime";
2
2
  import { useTranslation as i } from "react-i18next";
3
3
  import { useIndustryApiState as s } from "./Context.js";
4
+ import "../../../shared/constants.js";
4
5
  import "classnames";
5
6
  import { ActionsLayout as m } from "../../Common/ActionsLayout/ActionsLayout.js";
6
7
  import { useComponentContext as e } from "../../../contexts/ComponentAdapter/useComponentContext.js";
7
- const y = () => {
8
+ const C = () => {
8
9
  const { t: o } = i("Company.Industry"), { isPending: n } = s(), r = e();
9
10
  return /* @__PURE__ */ t(m, { children: /* @__PURE__ */ t(r.Button, { type: "submit", isLoading: n, children: o("submitCta") }) });
10
11
  };
11
12
  export {
12
- y as Actions
13
+ C as Actions
13
14
  };
14
15
  //# sourceMappingURL=Actions.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Actions.js","sources":["../../../../src/components/Company/Industry/Actions.tsx"],"sourcesContent":["import { useTranslation } from 'react-i18next'\nimport { useIndustryApiState } from './Context'\nimport { ActionsLayout } from '@/components/Common'\nimport { useComponentContext } from '@/contexts/ComponentAdapter/useComponentContext'\n\nexport const Actions = () => {\n const { t } = useTranslation('Company.Industry')\n const { isPending } = useIndustryApiState()\n const Components = useComponentContext()\n\n return (\n <ActionsLayout>\n <Components.Button type=\"submit\" isLoading={isPending}>\n {t('submitCta')}\n </Components.Button>\n </ActionsLayout>\n )\n}\n"],"names":["Actions","t","useTranslation","isPending","useIndustryApiState","Components","useComponentContext","jsx","ActionsLayout"],"mappings":";;;;;;AAKO,MAAMA,IAAU,MAAM;AAC3B,QAAM,EAAE,GAAAC,EAAA,IAAMC,EAAe,kBAAkB,GACzC,EAAE,WAAAC,EAAA,IAAcC,EAAA,GAChBC,IAAaC,EAAA;AAEnB,SACE,gBAAAC,EAACC,GAAA,EACC,UAAA,gBAAAD,EAACF,EAAW,QAAX,EAAkB,MAAK,UAAS,WAAWF,GACzC,UAAAF,EAAE,WAAW,GAChB,GACF;AAEJ;"}
1
+ {"version":3,"file":"Actions.js","sources":["../../../../src/components/Company/Industry/Actions.tsx"],"sourcesContent":["import { useTranslation } from 'react-i18next'\nimport { useIndustryApiState } from './Context'\nimport { ActionsLayout } from '@/components/Common'\nimport { useComponentContext } from '@/contexts/ComponentAdapter/useComponentContext'\n\nexport const Actions = () => {\n const { t } = useTranslation('Company.Industry')\n const { isPending } = useIndustryApiState()\n const Components = useComponentContext()\n\n return (\n <ActionsLayout>\n <Components.Button type=\"submit\" isLoading={isPending}>\n {t('submitCta')}\n </Components.Button>\n </ActionsLayout>\n )\n}\n"],"names":["Actions","t","useTranslation","isPending","useIndustryApiState","Components","useComponentContext","jsx","ActionsLayout"],"mappings":";;;;;;;AAKO,MAAMA,IAAU,MAAM;AAC3B,QAAM,EAAE,GAAAC,EAAA,IAAMC,EAAe,kBAAkB,GACzC,EAAE,WAAAC,EAAA,IAAcC,EAAA,GAChBC,IAAaC,EAAA;AAEnB,SACE,gBAAAC,EAACC,GAAA,EACC,UAAA,gBAAAD,EAACF,EAAW,QAAX,EAAkB,MAAK,UAAS,WAAWF,GACzC,UAAAF,EAAE,WAAW,GAChB,GACF;AAEJ;"}
@@ -9,19 +9,22 @@ import "@gusto/embedded-api/models/errors/gustoembeddederror";
9
9
  import "@gusto/embedded-api/models/errors/sdkvalidationerror";
10
10
  import "@gusto/embedded-api/models/errors/unprocessableentityerrorobject";
11
11
  import "@gusto/embedded-api/models/errors/httpclienterrors";
12
+ import "dompurify";
13
+ import "../../../contexts/LocaleProvider/useLocale.js";
12
14
  import "../../../shared/constants.js";
13
15
  import "classnames";
14
16
  import "../../../contexts/ComponentAdapter/useComponentContext.js";
17
+ import "../../../contexts/LoadingIndicatorProvider/useLoadingIndicator.js";
15
18
  import { createCompoundContext as t } from "../../Base/createCompoundContext.js";
16
- const [P, f] = t("IndustryItems", {
19
+ const [x, C] = t("IndustryItems", {
17
20
  items: []
18
- }), [v, x] = t("IndustryApi", {
21
+ }), [S, g] = t("IndustryApi", {
19
22
  isPending: !1
20
23
  });
21
24
  export {
22
- x as IndustryApiStateProvider,
23
- f as IndustryItemsProvider,
24
- v as useIndustryApiState,
25
- P as useIndustryItems
25
+ g as IndustryApiStateProvider,
26
+ C as IndustryItemsProvider,
27
+ S as useIndustryApiState,
28
+ x as useIndustryItems
26
29
  };
27
30
  //# sourceMappingURL=Context.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Context.js","sources":["../../../../src/components/Company/Industry/Context.ts"],"sourcesContent":["import { createCompoundContext } from '@/components/Base'\nimport type { ComboBoxOption } from '@/components/Common/UI/ComboBox/ComboBoxTypes'\n\nconst [useIndustryItems, IndustryItemsProvider] = createCompoundContext('IndustryItems', {\n items: [] as ComboBoxOption[],\n})\n\nconst [useIndustryApiState, IndustryApiStateProvider] = createCompoundContext('IndustryApi', {\n isPending: false,\n})\n\nexport { IndustryApiStateProvider, IndustryItemsProvider, useIndustryItems, useIndustryApiState }\n"],"names":["useIndustryItems","IndustryItemsProvider","createCompoundContext","useIndustryApiState","IndustryApiStateProvider"],"mappings":";;;;;;;;;;;;;;;AAGA,MAAM,CAACA,GAAkBC,CAAqB,IAAIC,EAAsB,iBAAiB;AAAA,EACvF,OAAO,CAAA;AACT,CAAC,GAEK,CAACC,GAAqBC,CAAwB,IAAIF,EAAsB,eAAe;AAAA,EAC3F,WAAW;AACb,CAAC;"}
1
+ {"version":3,"file":"Context.js","sources":["../../../../src/components/Company/Industry/Context.ts"],"sourcesContent":["import { createCompoundContext } from '@/components/Base'\nimport type { ComboBoxOption } from '@/components/Common/UI/ComboBox/ComboBoxTypes'\n\nconst [useIndustryItems, IndustryItemsProvider] = createCompoundContext('IndustryItems', {\n items: [] as ComboBoxOption[],\n})\n\nconst [useIndustryApiState, IndustryApiStateProvider] = createCompoundContext('IndustryApi', {\n isPending: false,\n})\n\nexport { IndustryApiStateProvider, IndustryItemsProvider, useIndustryItems, useIndustryApiState }\n"],"names":["useIndustryItems","IndustryItemsProvider","createCompoundContext","useIndustryApiState","IndustryApiStateProvider"],"mappings":";;;;;;;;;;;;;;;;;;AAGA,MAAM,CAACA,GAAkBC,CAAqB,IAAIC,EAAsB,iBAAiB;AAAA,EACvF,OAAO,CAAA;AACT,CAAC,GAEK,CAACC,GAAqBC,CAAwB,IAAIF,EAAsB,eAAe;AAAA,EAC3F,WAAW;AACb,CAAC;"}
@@ -1,12 +1,13 @@
1
1
  import { jsx as t } from "react/jsx-runtime";
2
2
  import { useTranslation as e } from "react-i18next";
3
3
  import { useIndustryItems as m } from "./Context.js";
4
+ import "../../../shared/constants.js";
4
5
  import "classnames";
5
- import { ComboBoxField as s } from "../../Common/Fields/ComboBoxField/ComboBoxField.js";
6
- const d = () => {
6
+ import { ComboBoxField as i } from "../../Common/Fields/ComboBoxField/ComboBoxField.js";
7
+ const c = () => {
7
8
  const { t: o } = e("Company.Industry"), { items: r } = m();
8
9
  return /* @__PURE__ */ t(
9
- s,
10
+ i,
10
11
  {
11
12
  isRequired: !0,
12
13
  options: r,
@@ -17,6 +18,6 @@ const d = () => {
17
18
  );
18
19
  };
19
20
  export {
20
- d as Edit
21
+ c as Edit
21
22
  };
22
23
  //# sourceMappingURL=Edit.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Edit.js","sources":["../../../../src/components/Company/Industry/Edit.tsx"],"sourcesContent":["import { useTranslation } from 'react-i18next'\nimport { useIndustryItems } from './Context'\nimport { ComboBoxField } from '@/components/Common'\n\nexport interface IndustryFormFields {\n naics_code: string\n}\n\nexport const Edit = () => {\n const { t } = useTranslation('Company.Industry')\n const { items } = useIndustryItems()\n\n return (\n <ComboBoxField\n isRequired\n options={items}\n label={t('label')}\n name=\"naics_code\"\n placeholder={t('placeholder')}\n />\n )\n}\n"],"names":["Edit","t","useTranslation","items","useIndustryItems","jsx","ComboBoxField"],"mappings":";;;;;AAQO,MAAMA,IAAO,MAAM;AACxB,QAAM,EAAE,GAAAC,EAAA,IAAMC,EAAe,kBAAkB,GACzC,EAAE,OAAAC,EAAA,IAAUC,EAAA;AAElB,SACE,gBAAAC;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,YAAU;AAAA,MACV,SAASH;AAAA,MACT,OAAOF,EAAE,OAAO;AAAA,MAChB,MAAK;AAAA,MACL,aAAaA,EAAE,aAAa;AAAA,IAAA;AAAA,EAAA;AAGlC;"}
1
+ {"version":3,"file":"Edit.js","sources":["../../../../src/components/Company/Industry/Edit.tsx"],"sourcesContent":["import { useTranslation } from 'react-i18next'\nimport { useIndustryItems } from './Context'\nimport { ComboBoxField } from '@/components/Common'\n\nexport interface IndustryFormFields {\n naics_code: string\n}\n\nexport const Edit = () => {\n const { t } = useTranslation('Company.Industry')\n const { items } = useIndustryItems()\n\n return (\n <ComboBoxField\n isRequired\n options={items}\n label={t('label')}\n name=\"naics_code\"\n placeholder={t('placeholder')}\n />\n )\n}\n"],"names":["Edit","t","useTranslation","items","useIndustryItems","jsx","ComboBoxField"],"mappings":";;;;;;AAQO,MAAMA,IAAO,MAAM;AACxB,QAAM,EAAE,GAAAC,EAAA,IAAMC,EAAe,kBAAkB,GACzC,EAAE,OAAAC,EAAA,IAAUC,EAAA;AAElB,SACE,gBAAAC;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,YAAU;AAAA,MACV,SAASH;AAAA,MACT,OAAOF,EAAE,OAAO;AAAA,MAChB,MAAK;AAAA,MACL,aAAaA,EAAE,aAAa;AAAA,IAAA;AAAA,EAAA;AAGlC;"}
@@ -1,17 +1,18 @@
1
1
  import { jsxs as r, jsx as n } from "react/jsx-runtime";
2
2
  import { useTranslation as a } from "react-i18next";
3
3
  import { useLocationsForm as e } from "./useLocationForm.js";
4
+ import "../../../../shared/constants.js";
4
5
  import "classnames";
5
- import { ActionsLayout as c } from "../../../Common/ActionsLayout/ActionsLayout.js";
6
- import { useComponentContext as m } from "../../../../contexts/ComponentAdapter/useComponentContext.js";
7
- const h = () => {
8
- const { t: o } = a("Company.Locations"), { handleCancel: i, isPending: s } = e(), t = m();
9
- return /* @__PURE__ */ r(c, { children: [
6
+ import { ActionsLayout as m } from "../../../Common/ActionsLayout/ActionsLayout.js";
7
+ import { useComponentContext as c } from "../../../../contexts/ComponentAdapter/useComponentContext.js";
8
+ const x = () => {
9
+ const { t: o } = a("Company.Locations"), { handleCancel: i, isPending: s } = e(), t = c();
10
+ return /* @__PURE__ */ r(m, { children: [
10
11
  /* @__PURE__ */ n(t.Button, { variant: "secondary", onClick: i, children: o("cancelCta") }),
11
12
  /* @__PURE__ */ n(t.Button, { type: "submit", isLoading: s, "data-testid": "location-submit", children: o("saveCta") })
12
13
  ] });
13
14
  };
14
15
  export {
15
- h as Actions
16
+ x as Actions
16
17
  };
17
18
  //# sourceMappingURL=Actions.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Actions.js","sources":["../../../../../src/components/Company/Locations/LocationForm/Actions.tsx"],"sourcesContent":["import { useTranslation } from 'react-i18next'\nimport { useLocationsForm } from './useLocationForm'\nimport { ActionsLayout } from '@/components/Common'\nimport { useComponentContext } from '@/contexts/ComponentAdapter/useComponentContext'\n\nexport const Actions = () => {\n const { t } = useTranslation('Company.Locations')\n const { handleCancel, isPending } = useLocationsForm()\n const Components = useComponentContext()\n\n return (\n <ActionsLayout>\n <Components.Button variant=\"secondary\" onClick={handleCancel}>\n {t('cancelCta')}\n </Components.Button>\n <Components.Button type=\"submit\" isLoading={isPending} data-testid=\"location-submit\">\n {t('saveCta')}\n </Components.Button>\n </ActionsLayout>\n )\n}\n"],"names":["Actions","t","useTranslation","handleCancel","isPending","useLocationsForm","Components","useComponentContext","ActionsLayout","jsx"],"mappings":";;;;;;AAKO,MAAMA,IAAU,MAAM;AAC3B,QAAM,EAAE,GAAAC,EAAA,IAAMC,EAAe,mBAAmB,GAC1C,EAAE,cAAAC,GAAc,WAAAC,EAAA,IAAcC,EAAA,GAC9BC,IAAaC,EAAA;AAEnB,2BACGC,GAAA,EACC,UAAA;AAAA,IAAA,gBAAAC,EAACH,EAAW,QAAX,EAAkB,SAAQ,aAAY,SAASH,GAC7C,UAAAF,EAAE,WAAW,EAAA,CAChB;AAAA,IACA,gBAAAQ,EAACH,EAAW,QAAX,EAAkB,MAAK,UAAS,WAAWF,GAAW,eAAY,mBAChE,UAAAH,EAAE,SAAS,EAAA,CACd;AAAA,EAAA,GACF;AAEJ;"}
1
+ {"version":3,"file":"Actions.js","sources":["../../../../../src/components/Company/Locations/LocationForm/Actions.tsx"],"sourcesContent":["import { useTranslation } from 'react-i18next'\nimport { useLocationsForm } from './useLocationForm'\nimport { ActionsLayout } from '@/components/Common'\nimport { useComponentContext } from '@/contexts/ComponentAdapter/useComponentContext'\n\nexport const Actions = () => {\n const { t } = useTranslation('Company.Locations')\n const { handleCancel, isPending } = useLocationsForm()\n const Components = useComponentContext()\n\n return (\n <ActionsLayout>\n <Components.Button variant=\"secondary\" onClick={handleCancel}>\n {t('cancelCta')}\n </Components.Button>\n <Components.Button type=\"submit\" isLoading={isPending} data-testid=\"location-submit\">\n {t('saveCta')}\n </Components.Button>\n </ActionsLayout>\n )\n}\n"],"names":["Actions","t","useTranslation","handleCancel","isPending","useLocationsForm","Components","useComponentContext","ActionsLayout","jsx"],"mappings":";;;;;;;AAKO,MAAMA,IAAU,MAAM;AAC3B,QAAM,EAAE,GAAAC,EAAA,IAAMC,EAAe,mBAAmB,GAC1C,EAAE,cAAAC,GAAc,WAAAC,EAAA,IAAcC,EAAA,GAC9BC,IAAaC,EAAA;AAEnB,2BACGC,GAAA,EACC,UAAA;AAAA,IAAA,gBAAAC,EAACH,EAAW,QAAX,EAAkB,SAAQ,aAAY,SAASH,GAC7C,UAAAF,EAAE,WAAW,EAAA,CAChB;AAAA,IACA,gBAAAQ,EAACH,EAAW,QAAX,EAAkB,MAAK,UAAS,WAAWF,GAAW,eAAY,mBAChE,UAAAH,EAAE,SAAS,EAAA,CACd;AAAA,EAAA,GACF;AAEJ;"}
@@ -4,13 +4,12 @@ import { useTranslation as m } from "react-i18next";
4
4
  import { zipValidation as d, phoneValidation as p } from "../../../../helpers/validations.js";
5
5
  import { Flex as c } from "../../../Common/Flex/Flex.js";
6
6
  import { Grid as b } from "../../../Common/Grid/Grid.js";
7
- import "classnames";
8
7
  import { STATES_ABBR as f } from "../../../../shared/constants.js";
9
8
  import { useMaskedTransform as u, commonMasks as g } from "../../../../helpers/mask.js";
10
9
  import { TextInputField as s } from "../../../Common/Fields/TextInputField/TextInputField.js";
11
10
  import { SelectField as h } from "../../../Common/Fields/SelectField/SelectField.js";
12
11
  import { CheckboxGroupField as A } from "../../../Common/Fields/CheckboxGroupField/CheckboxGroupField.js";
13
- const S = i.object({
12
+ const k = i.object({
14
13
  phoneNumber: p,
15
14
  street1: i.string().min(1),
16
15
  street2: i.string().optional(),
@@ -19,7 +18,7 @@ const S = i.object({
19
18
  zip: d,
20
19
  addressType: i.array(i.enum(["mailingAddress", "filingAddress"])).optional()
21
20
  });
22
- function j({ isMailingLocked: a = !1, isFilingLocked: t = !1 } = {}) {
21
+ function S({ isMailingLocked: a = !1, isFilingLocked: t = !1 } = {}) {
23
22
  const { t: e } = m("Company.Locations"), n = u(g.phoneMask);
24
23
  return /* @__PURE__ */ l(c, { flexDirection: "column", gap: 20, children: [
25
24
  /* @__PURE__ */ l(
@@ -107,7 +106,7 @@ function j({ isMailingLocked: a = !1, isFilingLocked: t = !1 } = {}) {
107
106
  ] });
108
107
  }
109
108
  export {
110
- j as Form,
111
- S as LocationFormSchema
109
+ S as Form,
110
+ k as LocationFormSchema
112
111
  };
113
112
  //# sourceMappingURL=Form.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Form.js","sources":["../../../../../src/components/Company/Locations/LocationForm/Form.tsx"],"sourcesContent":["import { z } from 'zod'\nimport { useTranslation } from 'react-i18next'\nimport { phoneValidation, zipValidation } from '@/helpers/validations'\nimport { CheckboxGroupField, Flex, Grid, SelectField, TextInputField } from '@/components/Common'\nimport { STATES_ABBR } from '@/shared/constants'\nimport { commonMasks, useMaskedTransform } from '@/helpers/mask'\n\nexport const LocationFormSchema = z.object({\n phoneNumber: phoneValidation,\n street1: z.string().min(1),\n street2: z.string().optional(),\n city: z.string().min(1),\n state: z.string().min(1),\n zip: zipValidation,\n addressType: z.array(z.enum(['mailingAddress', 'filingAddress'])).optional(),\n})\n\nexport type LocationFormInputs = z.infer<typeof LocationFormSchema>\n\ninterface FormProps {\n isMailingLocked?: boolean\n isFilingLocked?: boolean\n}\n\nexport function Form({ isMailingLocked = false, isFilingLocked = false }: FormProps = {}) {\n const { t } = useTranslation('Company.Locations')\n const transform = useMaskedTransform(commonMasks.phoneMask)\n\n return (\n <Flex flexDirection=\"column\" gap={20}>\n <Grid\n gap={{ base: 20, small: 8 }}\n gridTemplateColumns={{ base: '1fr', small: ['1fr', '1fr'] }}\n >\n <TextInputField\n name=\"street1\"\n isRequired\n label={t('street1Label')}\n errorMessage={t('validations.street1')}\n />\n <TextInputField name=\"street2\" label={t('street2Label')} />\n <TextInputField\n name=\"city\"\n label={t('cityLabel')}\n isRequired\n errorMessage={t('validations.city')}\n />\n <SelectField\n name=\"state\"\n options={STATES_ABBR.map((stateAbbr: (typeof STATES_ABBR)[number]) => ({\n label: t(`statesHash.${stateAbbr}`, { ns: 'common' }),\n value: stateAbbr,\n }))}\n label={t('stateLabel')}\n placeholder={t('statePlaceholder')}\n errorMessage={t('validations.state')}\n isRequired\n />\n <TextInputField\n name=\"zip\"\n isRequired\n label={t('zipLabel')}\n errorMessage={t('validations.zip')}\n />\n <TextInputField\n name=\"phoneNumber\"\n isRequired\n label={t('phoneNumberLabel')}\n errorMessage={t('validations.phone')}\n transform={transform}\n />\n </Grid>\n <CheckboxGroupField\n name=\"addressType\"\n label={t('addressTypeLabel')}\n options={[\n {\n value: 'mailingAddress',\n label: t('mailingAddressLabel'),\n description: isMailingLocked\n ? t('mailingAddressDescriptionLocked')\n : t('mailingAddressDescription'),\n isDisabled: isMailingLocked,\n },\n {\n value: 'filingAddress',\n label: t('filingAddressLabel'),\n description: isFilingLocked\n ? t('filingAddressDescriptionLocked')\n : t('filingAddressDescription'),\n isDisabled: isFilingLocked,\n },\n ]}\n />\n </Flex>\n )\n}\n"],"names":["LocationFormSchema","z","phoneValidation","zipValidation","Form","isMailingLocked","isFilingLocked","t","useTranslation","transform","useMaskedTransform","commonMasks","jsxs","Flex","Grid","jsx","TextInputField","SelectField","STATES_ABBR","stateAbbr","CheckboxGroupField"],"mappings":"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"}
1
+ {"version":3,"file":"Form.js","sources":["../../../../../src/components/Company/Locations/LocationForm/Form.tsx"],"sourcesContent":["import { z } from 'zod'\nimport { useTranslation } from 'react-i18next'\nimport { phoneValidation, zipValidation } from '@/helpers/validations'\nimport { CheckboxGroupField, Flex, Grid, SelectField, TextInputField } from '@/components/Common'\nimport { STATES_ABBR } from '@/shared/constants'\nimport { commonMasks, useMaskedTransform } from '@/helpers/mask'\n\nexport const LocationFormSchema = z.object({\n phoneNumber: phoneValidation,\n street1: z.string().min(1),\n street2: z.string().optional(),\n city: z.string().min(1),\n state: z.string().min(1),\n zip: zipValidation,\n addressType: z.array(z.enum(['mailingAddress', 'filingAddress'])).optional(),\n})\n\nexport type LocationFormInputs = z.infer<typeof LocationFormSchema>\n\ninterface FormProps {\n isMailingLocked?: boolean\n isFilingLocked?: boolean\n}\n\nexport function Form({ isMailingLocked = false, isFilingLocked = false }: FormProps = {}) {\n const { t } = useTranslation('Company.Locations')\n const transform = useMaskedTransform(commonMasks.phoneMask)\n\n return (\n <Flex flexDirection=\"column\" gap={20}>\n <Grid\n gap={{ base: 20, small: 8 }}\n gridTemplateColumns={{ base: '1fr', small: ['1fr', '1fr'] }}\n >\n <TextInputField\n name=\"street1\"\n isRequired\n label={t('street1Label')}\n errorMessage={t('validations.street1')}\n />\n <TextInputField name=\"street2\" label={t('street2Label')} />\n <TextInputField\n name=\"city\"\n label={t('cityLabel')}\n isRequired\n errorMessage={t('validations.city')}\n />\n <SelectField\n name=\"state\"\n options={STATES_ABBR.map((stateAbbr: (typeof STATES_ABBR)[number]) => ({\n label: t(`statesHash.${stateAbbr}`, { ns: 'common' }),\n value: stateAbbr,\n }))}\n label={t('stateLabel')}\n placeholder={t('statePlaceholder')}\n errorMessage={t('validations.state')}\n isRequired\n />\n <TextInputField\n name=\"zip\"\n isRequired\n label={t('zipLabel')}\n errorMessage={t('validations.zip')}\n />\n <TextInputField\n name=\"phoneNumber\"\n isRequired\n label={t('phoneNumberLabel')}\n errorMessage={t('validations.phone')}\n transform={transform}\n />\n </Grid>\n <CheckboxGroupField\n name=\"addressType\"\n label={t('addressTypeLabel')}\n options={[\n {\n value: 'mailingAddress',\n label: t('mailingAddressLabel'),\n description: isMailingLocked\n ? t('mailingAddressDescriptionLocked')\n : t('mailingAddressDescription'),\n isDisabled: isMailingLocked,\n },\n {\n value: 'filingAddress',\n label: t('filingAddressLabel'),\n description: isFilingLocked\n ? t('filingAddressDescriptionLocked')\n : t('filingAddressDescription'),\n isDisabled: isFilingLocked,\n },\n ]}\n />\n </Flex>\n )\n}\n"],"names":["LocationFormSchema","z","phoneValidation","zipValidation","Form","isMailingLocked","isFilingLocked","t","useTranslation","transform","useMaskedTransform","commonMasks","jsxs","Flex","Grid","jsx","TextInputField","SelectField","STATES_ABBR","stateAbbr","CheckboxGroupField"],"mappings":"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"}
@@ -11,12 +11,11 @@ import { Actions as U } from "./Actions.js";
11
11
  import { LocationsFormProvider as j } from "./useLocationForm.js";
12
12
  import { Form as k } from "../../../Common/Form/Form.js";
13
13
  import { Flex as H } from "../../../Common/Flex/Flex.js";
14
- import "react-i18next";
15
14
  import "classnames";
15
+ import { componentEvents as m } from "../../../../shared/constants.js";
16
16
  import { BaseComponent as Q } from "../../../Base/Base.js";
17
17
  import { useBase as Y } from "../../../Base/useBase.js";
18
18
  import { useI18n as K } from "../../../../i18n/I18n.js";
19
- import { componentEvents as m } from "../../../../shared/constants.js";
20
19
  function V(o) {
21
20
  const {
22
21
  data: { location: e }
@@ -26,11 +25,11 @@ function V(o) {
26
25
  function y({
27
26
  companyId: o,
28
27
  location: e,
29
- className: s,
28
+ className: i,
30
29
  children: r
31
30
  }) {
32
31
  K("Company.Locations");
33
- const { onEvent: i, baseSubmitHandler: g } = Y(), A = B(), { mutateAsync: L, isPending: h } = M(), { mutateAsync: C, isPending: v } = w(), F = ["mailingAddress", "filingAddress"], d = e?.mailingAddress === !0, c = e?.filingAddress === !0, { control: P, ...u } = O({
32
+ const { onEvent: s, baseSubmitHandler: g } = Y(), A = B(), { mutateAsync: L, isPending: h } = M(), { mutateAsync: C, isPending: v } = w(), F = ["mailingAddress", "filingAddress"], d = e?.mailingAddress === !0, c = e?.filingAddress === !0, { control: P, ...u } = O({
34
33
  resolver: S(_),
35
34
  defaultValues: {
36
35
  city: e?.city ?? "",
@@ -42,7 +41,7 @@ function y({
42
41
  addressType: F.filter((n) => e?.[n] ?? !1)
43
42
  }
44
43
  }), T = () => {
45
- i(m.CANCEL);
44
+ s(m.CANCEL);
46
45
  }, b = async (n) => {
47
46
  await g(n, async (q) => {
48
47
  const { addressType: p, ...D } = q, f = {
@@ -60,7 +59,7 @@ function y({
60
59
  requestBody: { ...f, version: e.version }
61
60
  }
62
61
  });
63
- await l(), i(m.COMPANY_LOCATION_UPDATED, a);
62
+ await l(), s(m.COMPANY_LOCATION_UPDATED, a);
64
63
  } else {
65
64
  const { location: a } = await L({
66
65
  request: {
@@ -68,11 +67,11 @@ function y({
68
67
  companyLocationRequest: f
69
68
  }
70
69
  });
71
- await l(), i(m.COMPANY_LOCATION_CREATED, a);
70
+ await l(), s(m.COMPANY_LOCATION_CREATED, a);
72
71
  }
73
72
  });
74
73
  };
75
- return /* @__PURE__ */ t("section", { className: s, children: /* @__PURE__ */ t(R, { ...u, control: P, children: /* @__PURE__ */ t(k, { onSubmit: u.handleSubmit(b), children: /* @__PURE__ */ t(
74
+ return /* @__PURE__ */ t("section", { className: i, children: /* @__PURE__ */ t(R, { ...u, control: P, children: /* @__PURE__ */ t(k, { onSubmit: u.handleSubmit(b), children: /* @__PURE__ */ t(
76
75
  j,
77
76
  {
78
77
  value: { handleCancel: T, isPending: h || v },
@@ -84,16 +83,16 @@ function y({
84
83
  }
85
84
  ) }) }) });
86
85
  }
87
- function fe({
86
+ function pe({
88
87
  companyId: o,
89
88
  locationId: e,
90
- className: s,
89
+ className: i,
91
90
  children: r,
92
- ...i
91
+ ...s
93
92
  }) {
94
- return /* @__PURE__ */ t(Q, { ...i, children: e ? /* @__PURE__ */ t(V, { companyId: o, locationId: e, className: s, children: r }) : /* @__PURE__ */ t(y, { companyId: o, className: s, children: r }) });
93
+ return /* @__PURE__ */ t(Q, { ...s, children: e ? /* @__PURE__ */ t(V, { companyId: o, locationId: e, className: i, children: r }) : /* @__PURE__ */ t(y, { companyId: o, className: i, children: r }) });
95
94
  }
96
95
  export {
97
- fe as LocationForm
96
+ pe as LocationForm
98
97
  };
99
98
  //# sourceMappingURL=LocationForm.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"LocationForm.js","sources":["../../../../../src/components/Company/Locations/LocationForm/LocationForm.tsx"],"sourcesContent":["import { FormProvider, useForm } from 'react-hook-form'\nimport { zodResolver } from '@hookform/resolvers/zod'\nimport { useLocationsUpdateMutation } from '@gusto/embedded-api/react-query/locationsUpdate'\nimport { useLocationsRetrieveSuspense } from '@gusto/embedded-api/react-query/locationsRetrieve'\nimport { useLocationsCreateMutation } from '@gusto/embedded-api/react-query/locationsCreate'\nimport { type Location } from '@gusto/embedded-api/models/components/location'\nimport { useQueryClient } from '@tanstack/react-query'\nimport { Head } from './Head'\nimport type { LocationFormInputs } from './Form'\nimport { Form, LocationFormSchema } from './Form'\nimport { Actions } from './Actions'\nimport { LocationsFormProvider } from './useLocationForm'\nimport { Form as HtmlForm } from '@/components/Common/Form'\nimport { Flex } from '@/components/Common'\nimport type { BaseComponentInterface, CommonComponentInterface } from '@/components/Base'\nimport { BaseComponent, useBase } from '@/components/Base'\nimport { useI18n } from '@/i18n'\nimport { componentEvents } from '@/shared/constants'\nimport type { WithRequired } from '@/types/Helpers'\n\ninterface LocationFormProps extends CommonComponentInterface {\n companyId: string\n locationId?: string\n}\n\n/**Accounting for conditional logic where location data needs to be fetched only if locationId is present */\nfunction RootWithLocation(props: WithRequired<LocationFormProps, 'locationId'>) {\n const {\n data: { location },\n } = useLocationsRetrieveSuspense({ locationId: props.locationId })\n return <Root {...props} location={location} />\n}\n\nfunction Root({\n companyId,\n location,\n className,\n children,\n}: LocationFormProps & { location?: Location }) {\n useI18n('Company.Locations')\n const { onEvent, baseSubmitHandler } = useBase()\n\n const queryClient = useQueryClient()\n const { mutateAsync: createLocation, isPending: isPendingCreate } = useLocationsCreateMutation()\n const { mutateAsync: updateLocation, isPending: isPendingUpdate } = useLocationsUpdateMutation()\n const addressType = ['mailingAddress', 'filingAddress'] as const\n const isMailingLocked = location?.mailingAddress === true\n const isFilingLocked = location?.filingAddress === true\n\n const { control, ...methods } = useForm<LocationFormInputs>({\n resolver: zodResolver(LocationFormSchema),\n defaultValues: {\n city: location?.city ?? '',\n phoneNumber: location?.phoneNumber ?? '',\n street1: location?.street1 ?? '',\n street2: location?.street2 ?? '',\n state: location?.state ?? '',\n zip: location?.zip ?? '',\n addressType: addressType.filter(key => location?.[key] ?? false),\n },\n })\n\n const handleCancel = () => {\n onEvent(componentEvents.CANCEL)\n }\n const onSubmit = async (data: LocationFormInputs) => {\n await baseSubmitHandler(data, async innerData => {\n const { addressType, ...payload } = innerData\n\n // The PUT /v1/locations/:id endpoint treats mailing_address and filing_address\n // as set-only flags: once a location is the company's mailing/filing address,\n // sending false is silently ignored (a company must always have one of each).\n // We mirror this contract by omitting locked fields from the request body.\n const requestBody = {\n ...payload,\n ...(isMailingLocked ? {} : { mailingAddress: addressType?.includes('mailingAddress') }),\n ...(isFilingLocked ? {} : { filingAddress: addressType?.includes('filingAddress') }),\n }\n\n // Setting mailing_address or filing_address on one location silently\n // flips the previous holder's flag server-side, so cached data for every\n // location (and the list) is potentially stale. We must await refetches\n // of *inactive* queries too (refetchType: 'all') because the next form\n // mount initializes useForm defaults synchronously from cache; otherwise\n // useSuspenseQuery returns the stale cached value without re-suspending\n // and the form seeds with a stale addressType on first open.\n const refreshLocationsCache = () =>\n queryClient.invalidateQueries({\n queryKey: ['@gusto/embedded-api', 'Locations'],\n refetchType: 'all',\n })\n\n if (location && location.version !== undefined) {\n const { location: responseData } = await updateLocation({\n request: {\n locationId: location.uuid,\n requestBody: { ...requestBody, version: location.version },\n },\n })\n await refreshLocationsCache()\n onEvent(componentEvents.COMPANY_LOCATION_UPDATED, responseData)\n } else {\n const { location: responseData } = await createLocation({\n request: {\n companyId,\n companyLocationRequest: requestBody,\n },\n })\n await refreshLocationsCache()\n onEvent(componentEvents.COMPANY_LOCATION_CREATED, responseData)\n }\n })\n }\n\n return (\n <section className={className}>\n <FormProvider {...methods} control={control}>\n <HtmlForm onSubmit={methods.handleSubmit(onSubmit)}>\n <LocationsFormProvider\n value={{ handleCancel, isPending: isPendingCreate || isPendingUpdate }}\n >\n <Flex flexDirection=\"column\" gap={32}>\n {children ? (\n children\n ) : (\n <>\n <Head />\n <Form isMailingLocked={isMailingLocked} isFilingLocked={isFilingLocked} />\n <Actions />\n </>\n )}\n </Flex>\n </LocationsFormProvider>\n </HtmlForm>\n </FormProvider>\n </section>\n )\n}\n\nexport function LocationForm({\n companyId,\n locationId,\n className,\n children,\n ...props\n}: LocationFormProps & BaseComponentInterface) {\n return (\n <BaseComponent {...props}>\n {locationId ? (\n <RootWithLocation companyId={companyId} locationId={locationId} className={className}>\n {children}\n </RootWithLocation>\n ) : (\n <Root companyId={companyId} className={className}>\n {children}\n </Root>\n )}\n </BaseComponent>\n )\n}\n"],"names":["RootWithLocation","props","location","useLocationsRetrieveSuspense","jsx","Root","companyId","className","children","useI18n","onEvent","baseSubmitHandler","useBase","queryClient","useQueryClient","createLocation","isPendingCreate","useLocationsCreateMutation","updateLocation","isPendingUpdate","useLocationsUpdateMutation","addressType","isMailingLocked","isFilingLocked","control","methods","useForm","zodResolver","LocationFormSchema","key","handleCancel","componentEvents","onSubmit","data","innerData","payload","requestBody","refreshLocationsCache","responseData","FormProvider","HtmlForm","LocationsFormProvider","Flex","jsxs","Fragment","Head","Form","Actions","LocationForm","locationId","BaseComponent"],"mappings":"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"}
1
+ {"version":3,"file":"LocationForm.js","sources":["../../../../../src/components/Company/Locations/LocationForm/LocationForm.tsx"],"sourcesContent":["import { FormProvider, useForm } from 'react-hook-form'\nimport { zodResolver } from '@hookform/resolvers/zod'\nimport { useLocationsUpdateMutation } from '@gusto/embedded-api/react-query/locationsUpdate'\nimport { useLocationsRetrieveSuspense } from '@gusto/embedded-api/react-query/locationsRetrieve'\nimport { useLocationsCreateMutation } from '@gusto/embedded-api/react-query/locationsCreate'\nimport { type Location } from '@gusto/embedded-api/models/components/location'\nimport { useQueryClient } from '@tanstack/react-query'\nimport { Head } from './Head'\nimport type { LocationFormInputs } from './Form'\nimport { Form, LocationFormSchema } from './Form'\nimport { Actions } from './Actions'\nimport { LocationsFormProvider } from './useLocationForm'\nimport { Form as HtmlForm } from '@/components/Common/Form'\nimport { Flex } from '@/components/Common'\nimport type { BaseComponentInterface, CommonComponentInterface } from '@/components/Base'\nimport { BaseComponent, useBase } from '@/components/Base'\nimport { useI18n } from '@/i18n'\nimport { componentEvents } from '@/shared/constants'\nimport type { WithRequired } from '@/types/Helpers'\n\ninterface LocationFormProps extends CommonComponentInterface {\n companyId: string\n locationId?: string\n}\n\n/**Accounting for conditional logic where location data needs to be fetched only if locationId is present */\nfunction RootWithLocation(props: WithRequired<LocationFormProps, 'locationId'>) {\n const {\n data: { location },\n } = useLocationsRetrieveSuspense({ locationId: props.locationId })\n return <Root {...props} location={location} />\n}\n\nfunction Root({\n companyId,\n location,\n className,\n children,\n}: LocationFormProps & { location?: Location }) {\n useI18n('Company.Locations')\n const { onEvent, baseSubmitHandler } = useBase()\n\n const queryClient = useQueryClient()\n const { mutateAsync: createLocation, isPending: isPendingCreate } = useLocationsCreateMutation()\n const { mutateAsync: updateLocation, isPending: isPendingUpdate } = useLocationsUpdateMutation()\n const addressType = ['mailingAddress', 'filingAddress'] as const\n const isMailingLocked = location?.mailingAddress === true\n const isFilingLocked = location?.filingAddress === true\n\n const { control, ...methods } = useForm<LocationFormInputs>({\n resolver: zodResolver(LocationFormSchema),\n defaultValues: {\n city: location?.city ?? '',\n phoneNumber: location?.phoneNumber ?? '',\n street1: location?.street1 ?? '',\n street2: location?.street2 ?? '',\n state: location?.state ?? '',\n zip: location?.zip ?? '',\n addressType: addressType.filter(key => location?.[key] ?? false),\n },\n })\n\n const handleCancel = () => {\n onEvent(componentEvents.CANCEL)\n }\n const onSubmit = async (data: LocationFormInputs) => {\n await baseSubmitHandler(data, async innerData => {\n const { addressType, ...payload } = innerData\n\n // The PUT /v1/locations/:id endpoint treats mailing_address and filing_address\n // as set-only flags: once a location is the company's mailing/filing address,\n // sending false is silently ignored (a company must always have one of each).\n // We mirror this contract by omitting locked fields from the request body.\n const requestBody = {\n ...payload,\n ...(isMailingLocked ? {} : { mailingAddress: addressType?.includes('mailingAddress') }),\n ...(isFilingLocked ? {} : { filingAddress: addressType?.includes('filingAddress') }),\n }\n\n // Setting mailing_address or filing_address on one location silently\n // flips the previous holder's flag server-side, so cached data for every\n // location (and the list) is potentially stale. We must await refetches\n // of *inactive* queries too (refetchType: 'all') because the next form\n // mount initializes useForm defaults synchronously from cache; otherwise\n // useSuspenseQuery returns the stale cached value without re-suspending\n // and the form seeds with a stale addressType on first open.\n const refreshLocationsCache = () =>\n queryClient.invalidateQueries({\n queryKey: ['@gusto/embedded-api', 'Locations'],\n refetchType: 'all',\n })\n\n if (location && location.version !== undefined) {\n const { location: responseData } = await updateLocation({\n request: {\n locationId: location.uuid,\n requestBody: { ...requestBody, version: location.version },\n },\n })\n await refreshLocationsCache()\n onEvent(componentEvents.COMPANY_LOCATION_UPDATED, responseData)\n } else {\n const { location: responseData } = await createLocation({\n request: {\n companyId,\n companyLocationRequest: requestBody,\n },\n })\n await refreshLocationsCache()\n onEvent(componentEvents.COMPANY_LOCATION_CREATED, responseData)\n }\n })\n }\n\n return (\n <section className={className}>\n <FormProvider {...methods} control={control}>\n <HtmlForm onSubmit={methods.handleSubmit(onSubmit)}>\n <LocationsFormProvider\n value={{ handleCancel, isPending: isPendingCreate || isPendingUpdate }}\n >\n <Flex flexDirection=\"column\" gap={32}>\n {children ? (\n children\n ) : (\n <>\n <Head />\n <Form isMailingLocked={isMailingLocked} isFilingLocked={isFilingLocked} />\n <Actions />\n </>\n )}\n </Flex>\n </LocationsFormProvider>\n </HtmlForm>\n </FormProvider>\n </section>\n )\n}\n\nexport function LocationForm({\n companyId,\n locationId,\n className,\n children,\n ...props\n}: LocationFormProps & BaseComponentInterface) {\n return (\n <BaseComponent {...props}>\n {locationId ? (\n <RootWithLocation companyId={companyId} locationId={locationId} className={className}>\n {children}\n </RootWithLocation>\n ) : (\n <Root companyId={companyId} className={className}>\n {children}\n </Root>\n )}\n </BaseComponent>\n )\n}\n"],"names":["RootWithLocation","props","location","useLocationsRetrieveSuspense","jsx","Root","companyId","className","children","useI18n","onEvent","baseSubmitHandler","useBase","queryClient","useQueryClient","createLocation","isPendingCreate","useLocationsCreateMutation","updateLocation","isPendingUpdate","useLocationsUpdateMutation","addressType","isMailingLocked","isFilingLocked","control","methods","useForm","zodResolver","LocationFormSchema","key","handleCancel","componentEvents","onSubmit","data","innerData","payload","requestBody","refreshLocationsCache","responseData","FormProvider","HtmlForm","LocationsFormProvider","Flex","jsxs","Fragment","Head","Form","Actions","LocationForm","locationId","BaseComponent"],"mappings":"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"}
@@ -0,0 +1,2 @@
1
+ import "./types/i18next.d.ts"
2
+ export { LocationForm } from './LocationForm';
@@ -9,15 +9,18 @@ import "@gusto/embedded-api/models/errors/gustoembeddederror";
9
9
  import "@gusto/embedded-api/models/errors/sdkvalidationerror";
10
10
  import "@gusto/embedded-api/models/errors/unprocessableentityerrorobject";
11
11
  import "@gusto/embedded-api/models/errors/httpclienterrors";
12
+ import "dompurify";
13
+ import "../../../../contexts/LocaleProvider/useLocale.js";
12
14
  import "../../../../shared/constants.js";
13
15
  import "classnames";
14
16
  import "../../../../contexts/ComponentAdapter/useComponentContext.js";
17
+ import "../../../../contexts/LoadingIndicatorProvider/useLoadingIndicator.js";
15
18
  import { createCompoundContext as o } from "../../../Base/createCompoundContext.js";
16
- const [L, f] = o(
19
+ const [y, D] = o(
17
20
  "CompanyDocumentFormContext"
18
21
  );
19
22
  export {
20
- f as LocationsFormProvider,
21
- L as useLocationsForm
23
+ D as LocationsFormProvider,
24
+ y as useLocationsForm
22
25
  };
23
26
  //# sourceMappingURL=useLocationForm.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"useLocationForm.js","sources":["../../../../../src/components/Company/Locations/LocationForm/useLocationForm.ts"],"sourcesContent":["import { createCompoundContext } from '@/components/Base'\n\ntype LocationsFormContextType = {\n isPending: boolean\n handleCancel: () => void\n}\n\nconst [useLocationsForm, LocationsFormProvider] = createCompoundContext<LocationsFormContextType>(\n 'CompanyDocumentFormContext',\n)\n\nexport { useLocationsForm, LocationsFormProvider }\n"],"names":["useLocationsForm","LocationsFormProvider","createCompoundContext"],"mappings":";;;;;;;;;;;;;;;AAOA,MAAM,CAACA,GAAkBC,CAAqB,IAAIC;AAAA,EAChD;AACF;"}
1
+ {"version":3,"file":"useLocationForm.js","sources":["../../../../../src/components/Company/Locations/LocationForm/useLocationForm.ts"],"sourcesContent":["import { createCompoundContext } from '@/components/Base'\n\ntype LocationsFormContextType = {\n isPending: boolean\n handleCancel: () => void\n}\n\nconst [useLocationsForm, LocationsFormProvider] = createCompoundContext<LocationsFormContextType>(\n 'CompanyDocumentFormContext',\n)\n\nexport { useLocationsForm, LocationsFormProvider }\n"],"names":["useLocationsForm","LocationsFormProvider","createCompoundContext"],"mappings":";;;;;;;;;;;;;;;;;;AAOA,MAAM,CAACA,GAAkBC,CAAqB,IAAIC;AAAA,EAChD;AACF;"}
@@ -1,17 +1,18 @@
1
- import { jsxs as c, jsx as t } from "react/jsx-runtime";
1
+ import { jsxs as c, jsx as n } from "react/jsx-runtime";
2
2
  import { useTranslation as s } from "react-i18next";
3
3
  import { useLocationsList as a } from "./useLocationsList.js";
4
+ import "../../../../shared/constants.js";
4
5
  import "classnames";
5
6
  import { ActionsLayout as e } from "../../../Common/ActionsLayout/ActionsLayout.js";
6
7
  import { useComponentContext as m } from "../../../../contexts/ComponentAdapter/useComponentContext.js";
7
- function L() {
8
- const { t: o } = s("Company.Locations"), { handleAddLocation: i, handleContinue: r } = a(), n = m();
8
+ function h() {
9
+ const { t: o } = s("Company.Locations"), { handleAddLocation: i, handleContinue: r } = a(), t = m();
9
10
  return /* @__PURE__ */ c(e, { children: [
10
- /* @__PURE__ */ t(n.Button, { variant: "secondary", onClick: i, children: o("addLocationCta") }),
11
- /* @__PURE__ */ t(n.Button, { onClick: r, children: o("continueCta") })
11
+ /* @__PURE__ */ n(t.Button, { variant: "secondary", onClick: i, children: o("addLocationCta") }),
12
+ /* @__PURE__ */ n(t.Button, { onClick: r, children: o("continueCta") })
12
13
  ] });
13
14
  }
14
15
  export {
15
- L as Actions
16
+ h as Actions
16
17
  };
17
18
  //# sourceMappingURL=Actions.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Actions.js","sources":["../../../../../src/components/Company/Locations/LocationsList/Actions.tsx"],"sourcesContent":["import { useTranslation } from 'react-i18next'\nimport { useLocationsList } from './useLocationsList'\nimport { ActionsLayout } from '@/components/Common'\nimport { useComponentContext } from '@/contexts/ComponentAdapter/useComponentContext'\n\nexport function Actions() {\n const { t } = useTranslation('Company.Locations')\n const { handleAddLocation, handleContinue } = useLocationsList()\n const Components = useComponentContext()\n\n return (\n <ActionsLayout>\n <Components.Button variant=\"secondary\" onClick={handleAddLocation}>\n {t('addLocationCta')}\n </Components.Button>\n <Components.Button onClick={handleContinue}>{t('continueCta')}</Components.Button>\n </ActionsLayout>\n )\n}\n"],"names":["Actions","t","useTranslation","handleAddLocation","handleContinue","useLocationsList","Components","useComponentContext","ActionsLayout","jsx"],"mappings":";;;;;;AAKO,SAASA,IAAU;AACxB,QAAM,EAAE,GAAAC,EAAA,IAAMC,EAAe,mBAAmB,GAC1C,EAAE,mBAAAC,GAAmB,gBAAAC,EAAA,IAAmBC,EAAA,GACxCC,IAAaC,EAAA;AAEnB,2BACGC,GAAA,EACC,UAAA;AAAA,IAAA,gBAAAC,EAACH,EAAW,QAAX,EAAkB,SAAQ,aAAY,SAASH,GAC7C,UAAAF,EAAE,gBAAgB,EAAA,CACrB;AAAA,IACA,gBAAAQ,EAACH,EAAW,QAAX,EAAkB,SAASF,GAAiB,UAAAH,EAAE,aAAa,EAAA,CAAE;AAAA,EAAA,GAChE;AAEJ;"}
1
+ {"version":3,"file":"Actions.js","sources":["../../../../../src/components/Company/Locations/LocationsList/Actions.tsx"],"sourcesContent":["import { useTranslation } from 'react-i18next'\nimport { useLocationsList } from './useLocationsList'\nimport { ActionsLayout } from '@/components/Common'\nimport { useComponentContext } from '@/contexts/ComponentAdapter/useComponentContext'\n\nexport function Actions() {\n const { t } = useTranslation('Company.Locations')\n const { handleAddLocation, handleContinue } = useLocationsList()\n const Components = useComponentContext()\n\n return (\n <ActionsLayout>\n <Components.Button variant=\"secondary\" onClick={handleAddLocation}>\n {t('addLocationCta')}\n </Components.Button>\n <Components.Button onClick={handleContinue}>{t('continueCta')}</Components.Button>\n </ActionsLayout>\n )\n}\n"],"names":["Actions","t","useTranslation","handleAddLocation","handleContinue","useLocationsList","Components","useComponentContext","ActionsLayout","jsx"],"mappings":";;;;;;;AAKO,SAASA,IAAU;AACxB,QAAM,EAAE,GAAAC,EAAA,IAAMC,EAAe,mBAAmB,GAC1C,EAAE,mBAAAC,GAAmB,gBAAAC,EAAA,IAAmBC,EAAA,GACxCC,IAAaC,EAAA;AAEnB,2BACGC,GAAA,EACC,UAAA;AAAA,IAAA,gBAAAC,EAACH,EAAW,QAAX,EAAkB,SAAQ,aAAY,SAASH,GAC7C,UAAAF,EAAE,gBAAgB,EAAA,CACrB;AAAA,IACA,gBAAAQ,EAACH,EAAW,QAAX,EAAkB,SAASF,GAAiB,UAAAH,EAAE,aAAa,EAAA,CAAE;AAAA,EAAA,GAChE;AAEJ;"}
@@ -1,8 +1,9 @@
1
- import { jsxs as r, jsx as e, Fragment as n } from "react/jsx-runtime";
1
+ import { jsxs as r, jsx as e, Fragment as o } from "react/jsx-runtime";
2
2
  import { useTranslation as P } from "react-i18next";
3
3
  import { useLocationsList as y } from "./useLocationsList.js";
4
4
  import b from "./List.module.scss.js";
5
5
  import x from "../../../../assets/icons/pencil.svg.js";
6
+ import "../../../../shared/constants.js";
6
7
  import "classnames";
7
8
  import { EmptyData as T } from "../../../Common/EmptyData/EmptyData.js";
8
9
  import { useComponentContext as A } from "../../../../contexts/ComponentAdapter/useComponentContext.js";
@@ -11,9 +12,9 @@ import { VisuallyHidden as S } from "../../../Common/VisuallyHidden/VisuallyHidd
11
12
  import { HamburgerMenu as V } from "../../../Common/HamburgerMenu/HamburgerMenu.js";
12
13
  import { useDataView as v } from "../../../Common/DataView/useDataView.js";
13
14
  import { DataView as w } from "../../../Common/DataView/DataView.js";
14
- const K = () => {
15
+ const O = () => {
15
16
  const a = A(), {
16
- locationList: o,
17
+ locationList: n,
17
18
  handleEditLocation: s,
18
19
  currentPage: d,
19
20
  totalPages: l,
@@ -26,7 +27,7 @@ const K = () => {
26
27
  handleAddLocation: f,
27
28
  itemsPerPage: C
28
29
  } = y(), { t } = P("Company.Locations"), { ...L } = v({
29
- data: o,
30
+ data: n,
30
31
  columns: [
31
32
  {
32
33
  key: "name",
@@ -39,9 +40,9 @@ const K = () => {
39
40
  {
40
41
  key: "status",
41
42
  title: /* @__PURE__ */ e(S, { children: t("locationListCol2") }),
42
- render: (i) => /* @__PURE__ */ r(n, { children: [
43
+ render: (i) => /* @__PURE__ */ r(o, { children: [
43
44
  i.mailingAddress && /* @__PURE__ */ e(a.Badge, { status: "info", children: t("mailingAddress") }),
44
- i.filingAddress && /* @__PURE__ */ r(n, { children: [
45
+ i.filingAddress && /* @__PURE__ */ r(o, { children: [
45
46
  " ",
46
47
  /* @__PURE__ */ e(a.Badge, { status: "info", children: t("filingAddress") })
47
48
  ] })
@@ -81,6 +82,6 @@ const K = () => {
81
82
  return /* @__PURE__ */ e(w, { label: t("locationListLabel"), ...L });
82
83
  };
83
84
  export {
84
- K as List
85
+ O as List
85
86
  };
86
87
  //# sourceMappingURL=List.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"List.js","sources":["../../../../../src/components/Company/Locations/LocationsList/List.tsx"],"sourcesContent":["import { useTranslation } from 'react-i18next'\nimport { useLocationsList } from './useLocationsList'\nimport styles from './List.module.scss'\nimport PencilSvg from '@/assets/icons/pencil.svg?react'\nimport { DataView, EmptyData, useDataView, VisuallyHidden } from '@/components/Common'\nimport { useComponentContext } from '@/contexts/ComponentAdapter/useComponentContext'\nimport { HamburgerMenu } from '@/components/Common/HamburgerMenu'\nimport { getCityStateZip, getStreet } from '@/helpers/formattedStrings'\n\n/**List of employees slot for EmployeeList component */\nexport const List = () => {\n const Components = useComponentContext()\n const {\n locationList,\n handleEditLocation,\n currentPage,\n totalPages,\n totalCount,\n handleFirstPage,\n handleItemsPerPageChange,\n handleLastPage,\n handleNextPage,\n handlePreviousPage,\n handleAddLocation,\n itemsPerPage,\n } = useLocationsList()\n\n const { t } = useTranslation('Company.Locations')\n const { ...dataViewProps } = useDataView({\n data: locationList,\n columns: [\n {\n key: 'name',\n title: t('locationListCol1'),\n render: location => {\n return (\n <address className={styles.addressCell}>\n <Components.Text as=\"span\">{getStreet(location)}</Components.Text>\n <Components.Text as=\"span\">{getCityStateZip(location)}</Components.Text>\n </address>\n )\n },\n },\n {\n key: 'status',\n title: <VisuallyHidden>{t('locationListCol2')}</VisuallyHidden>,\n render: location => {\n return (\n <>\n {location.mailingAddress && (\n <Components.Badge status={'info'}>{t('mailingAddress')}</Components.Badge>\n )}\n {location.filingAddress && (\n <>\n {' '}\n <Components.Badge status={'info'}>{t('filingAddress')}</Components.Badge>\n </>\n )}\n </>\n )\n },\n },\n ],\n itemMenu: location => {\n return (\n <HamburgerMenu\n items={[\n {\n label: t('editCta'),\n onClick: () => {\n handleEditLocation(location.uuid)\n },\n icon: <PencilSvg aria-hidden />,\n 'data-testid': 'edit-location',\n },\n ]}\n data-testid=\"location-hamburger\"\n triggerLabel={t('hamburgerTitle')}\n />\n )\n },\n pagination: {\n handleNextPage,\n handleFirstPage,\n handleLastPage,\n handlePreviousPage,\n handleItemsPerPageChange,\n currentPage,\n totalPages,\n totalCount,\n itemsPerPage,\n },\n emptyState: () => (\n <EmptyData title={t('emptyTableTitle')} description={t('emptyTableDescription')}>\n <Components.Button variant=\"secondary\" onClick={handleAddLocation}>\n {t('addFirstLocationCta')}\n </Components.Button>\n </EmptyData>\n ),\n })\n return <DataView label={t('locationListLabel')} {...dataViewProps} />\n}\n"],"names":["List","Components","useComponentContext","locationList","handleEditLocation","currentPage","totalPages","totalCount","handleFirstPage","handleItemsPerPageChange","handleLastPage","handleNextPage","handlePreviousPage","handleAddLocation","itemsPerPage","useLocationsList","useTranslation","dataViewProps","useDataView","location","jsxs","styles","jsx","getStreet","getCityStateZip","VisuallyHidden","Fragment","HamburgerMenu","PencilSvg","EmptyData","DataView"],"mappings":";;;;;;;;;;;;;AAUO,MAAMA,IAAO,MAAM;AACxB,QAAMC,IAAaC,EAAA,GACb;AAAA,IACJ,cAAAC;AAAA,IACA,oBAAAC;AAAA,IACA,aAAAC;AAAA,IACA,YAAAC;AAAA,IACA,YAAAC;AAAA,IACA,iBAAAC;AAAA,IACA,0BAAAC;AAAA,IACA,gBAAAC;AAAA,IACA,gBAAAC;AAAA,IACA,oBAAAC;AAAA,IACA,mBAAAC;AAAA,IACA,cAAAC;AAAA,EAAA,IACEC,EAAA,GAEE,EAAE,EAAA,IAAMC,EAAe,mBAAmB,GAC1C,EAAE,GAAGC,EAAA,IAAkBC,EAAY;AAAA,IACvC,MAAMf;AAAA,IACN,SAAS;AAAA,MACP;AAAA,QACE,KAAK;AAAA,QACL,OAAO,EAAE,kBAAkB;AAAA,QAC3B,QAAQ,CAAAgB,MAEJ,gBAAAC,EAAC,WAAA,EAAQ,WAAWC,EAAO,aACzB,UAAA;AAAA,UAAA,gBAAAC,EAACrB,EAAW,MAAX,EAAgB,IAAG,QAAQ,UAAAsB,EAAUJ,CAAQ,GAAE;AAAA,UAChD,gBAAAG,EAACrB,EAAW,MAAX,EAAgB,IAAG,QAAQ,UAAAuB,EAAgBL,CAAQ,EAAA,CAAE;AAAA,QAAA,GACxD;AAAA,MAEJ;AAAA,MAEF;AAAA,QACE,KAAK;AAAA,QACL,OAAO,gBAAAG,EAACG,GAAA,EAAgB,UAAA,EAAE,kBAAkB,GAAE;AAAA,QAC9C,QAAQ,CAAAN,MAEJ,gBAAAC,EAAAM,GAAA,EACG,UAAA;AAAA,UAAAP,EAAS,oCACPlB,EAAW,OAAX,EAAiB,QAAQ,QAAS,UAAA,EAAE,gBAAgB,EAAA,CAAE;AAAA,UAExDkB,EAAS,iBACR,gBAAAC,EAAAM,GAAA,EACG,UAAA;AAAA,YAAA;AAAA,YACD,gBAAAJ,EAACrB,EAAW,OAAX,EAAiB,QAAQ,QAAS,UAAA,EAAE,eAAe,EAAA,CAAE;AAAA,UAAA,EAAA,CACxD;AAAA,QAAA,GAEJ;AAAA,MAEJ;AAAA,IACF;AAAA,IAEF,UAAU,CAAAkB,MAEN,gBAAAG;AAAA,MAACK;AAAA,MAAA;AAAA,QACC,OAAO;AAAA,UACL;AAAA,YACE,OAAO,EAAE,SAAS;AAAA,YAClB,SAAS,MAAM;AACb,cAAAvB,EAAmBe,EAAS,IAAI;AAAA,YAClC;AAAA,YACA,MAAM,gBAAAG,EAACM,GAAA,EAAU,eAAW,GAAA,CAAC;AAAA,YAC7B,eAAe;AAAA,UAAA;AAAA,QACjB;AAAA,QAEF,eAAY;AAAA,QACZ,cAAc,EAAE,gBAAgB;AAAA,MAAA;AAAA,IAAA;AAAA,IAItC,YAAY;AAAA,MACV,gBAAAjB;AAAA,MACA,iBAAAH;AAAA,MACA,gBAAAE;AAAA,MACA,oBAAAE;AAAA,MACA,0BAAAH;AAAA,MACA,aAAAJ;AAAA,MACA,YAAAC;AAAA,MACA,YAAAC;AAAA,MACA,cAAAO;AAAA,IAAA;AAAA,IAEF,YAAY,MACV,gBAAAQ,EAACO,GAAA,EAAU,OAAO,EAAE,iBAAiB,GAAG,aAAa,EAAE,uBAAuB,GAC5E,UAAA,gBAAAP,EAACrB,EAAW,QAAX,EAAkB,SAAQ,aAAY,SAASY,GAC7C,UAAA,EAAE,qBAAqB,EAAA,CAC1B,EAAA,CACF;AAAA,EAAA,CAEH;AACD,2BAAQiB,GAAA,EAAS,OAAO,EAAE,mBAAmB,GAAI,GAAGb,GAAe;AACrE;"}
1
+ {"version":3,"file":"List.js","sources":["../../../../../src/components/Company/Locations/LocationsList/List.tsx"],"sourcesContent":["import { useTranslation } from 'react-i18next'\nimport { useLocationsList } from './useLocationsList'\nimport styles from './List.module.scss'\nimport PencilSvg from '@/assets/icons/pencil.svg?react'\nimport { DataView, EmptyData, useDataView, VisuallyHidden } from '@/components/Common'\nimport { useComponentContext } from '@/contexts/ComponentAdapter/useComponentContext'\nimport { HamburgerMenu } from '@/components/Common/HamburgerMenu'\nimport { getCityStateZip, getStreet } from '@/helpers/formattedStrings'\n\n/**List of employees slot for EmployeeList component */\nexport const List = () => {\n const Components = useComponentContext()\n const {\n locationList,\n handleEditLocation,\n currentPage,\n totalPages,\n totalCount,\n handleFirstPage,\n handleItemsPerPageChange,\n handleLastPage,\n handleNextPage,\n handlePreviousPage,\n handleAddLocation,\n itemsPerPage,\n } = useLocationsList()\n\n const { t } = useTranslation('Company.Locations')\n const { ...dataViewProps } = useDataView({\n data: locationList,\n columns: [\n {\n key: 'name',\n title: t('locationListCol1'),\n render: location => {\n return (\n <address className={styles.addressCell}>\n <Components.Text as=\"span\">{getStreet(location)}</Components.Text>\n <Components.Text as=\"span\">{getCityStateZip(location)}</Components.Text>\n </address>\n )\n },\n },\n {\n key: 'status',\n title: <VisuallyHidden>{t('locationListCol2')}</VisuallyHidden>,\n render: location => {\n return (\n <>\n {location.mailingAddress && (\n <Components.Badge status={'info'}>{t('mailingAddress')}</Components.Badge>\n )}\n {location.filingAddress && (\n <>\n {' '}\n <Components.Badge status={'info'}>{t('filingAddress')}</Components.Badge>\n </>\n )}\n </>\n )\n },\n },\n ],\n itemMenu: location => {\n return (\n <HamburgerMenu\n items={[\n {\n label: t('editCta'),\n onClick: () => {\n handleEditLocation(location.uuid)\n },\n icon: <PencilSvg aria-hidden />,\n 'data-testid': 'edit-location',\n },\n ]}\n data-testid=\"location-hamburger\"\n triggerLabel={t('hamburgerTitle')}\n />\n )\n },\n pagination: {\n handleNextPage,\n handleFirstPage,\n handleLastPage,\n handlePreviousPage,\n handleItemsPerPageChange,\n currentPage,\n totalPages,\n totalCount,\n itemsPerPage,\n },\n emptyState: () => (\n <EmptyData title={t('emptyTableTitle')} description={t('emptyTableDescription')}>\n <Components.Button variant=\"secondary\" onClick={handleAddLocation}>\n {t('addFirstLocationCta')}\n </Components.Button>\n </EmptyData>\n ),\n })\n return <DataView label={t('locationListLabel')} {...dataViewProps} />\n}\n"],"names":["List","Components","useComponentContext","locationList","handleEditLocation","currentPage","totalPages","totalCount","handleFirstPage","handleItemsPerPageChange","handleLastPage","handleNextPage","handlePreviousPage","handleAddLocation","itemsPerPage","useLocationsList","useTranslation","dataViewProps","useDataView","location","jsxs","styles","jsx","getStreet","getCityStateZip","VisuallyHidden","Fragment","HamburgerMenu","PencilSvg","EmptyData","DataView"],"mappings":";;;;;;;;;;;;;;AAUO,MAAMA,IAAO,MAAM;AACxB,QAAMC,IAAaC,EAAA,GACb;AAAA,IACJ,cAAAC;AAAA,IACA,oBAAAC;AAAA,IACA,aAAAC;AAAA,IACA,YAAAC;AAAA,IACA,YAAAC;AAAA,IACA,iBAAAC;AAAA,IACA,0BAAAC;AAAA,IACA,gBAAAC;AAAA,IACA,gBAAAC;AAAA,IACA,oBAAAC;AAAA,IACA,mBAAAC;AAAA,IACA,cAAAC;AAAA,EAAA,IACEC,EAAA,GAEE,EAAE,EAAA,IAAMC,EAAe,mBAAmB,GAC1C,EAAE,GAAGC,EAAA,IAAkBC,EAAY;AAAA,IACvC,MAAMf;AAAA,IACN,SAAS;AAAA,MACP;AAAA,QACE,KAAK;AAAA,QACL,OAAO,EAAE,kBAAkB;AAAA,QAC3B,QAAQ,CAAAgB,MAEJ,gBAAAC,EAAC,WAAA,EAAQ,WAAWC,EAAO,aACzB,UAAA;AAAA,UAAA,gBAAAC,EAACrB,EAAW,MAAX,EAAgB,IAAG,QAAQ,UAAAsB,EAAUJ,CAAQ,GAAE;AAAA,UAChD,gBAAAG,EAACrB,EAAW,MAAX,EAAgB,IAAG,QAAQ,UAAAuB,EAAgBL,CAAQ,EAAA,CAAE;AAAA,QAAA,GACxD;AAAA,MAEJ;AAAA,MAEF;AAAA,QACE,KAAK;AAAA,QACL,OAAO,gBAAAG,EAACG,GAAA,EAAgB,UAAA,EAAE,kBAAkB,GAAE;AAAA,QAC9C,QAAQ,CAAAN,MAEJ,gBAAAC,EAAAM,GAAA,EACG,UAAA;AAAA,UAAAP,EAAS,oCACPlB,EAAW,OAAX,EAAiB,QAAQ,QAAS,UAAA,EAAE,gBAAgB,EAAA,CAAE;AAAA,UAExDkB,EAAS,iBACR,gBAAAC,EAAAM,GAAA,EACG,UAAA;AAAA,YAAA;AAAA,YACD,gBAAAJ,EAACrB,EAAW,OAAX,EAAiB,QAAQ,QAAS,UAAA,EAAE,eAAe,EAAA,CAAE;AAAA,UAAA,EAAA,CACxD;AAAA,QAAA,GAEJ;AAAA,MAEJ;AAAA,IACF;AAAA,IAEF,UAAU,CAAAkB,MAEN,gBAAAG;AAAA,MAACK;AAAA,MAAA;AAAA,QACC,OAAO;AAAA,UACL;AAAA,YACE,OAAO,EAAE,SAAS;AAAA,YAClB,SAAS,MAAM;AACb,cAAAvB,EAAmBe,EAAS,IAAI;AAAA,YAClC;AAAA,YACA,MAAM,gBAAAG,EAACM,GAAA,EAAU,eAAW,GAAA,CAAC;AAAA,YAC7B,eAAe;AAAA,UAAA;AAAA,QACjB;AAAA,QAEF,eAAY;AAAA,QACZ,cAAc,EAAE,gBAAgB;AAAA,MAAA;AAAA,IAAA;AAAA,IAItC,YAAY;AAAA,MACV,gBAAAjB;AAAA,MACA,iBAAAH;AAAA,MACA,gBAAAE;AAAA,MACA,oBAAAE;AAAA,MACA,0BAAAH;AAAA,MACA,aAAAJ;AAAA,MACA,YAAAC;AAAA,MACA,YAAAC;AAAA,MACA,cAAAO;AAAA,IAAA;AAAA,IAEF,YAAY,MACV,gBAAAQ,EAACO,GAAA,EAAU,OAAO,EAAE,iBAAiB,GAAG,aAAa,EAAE,uBAAuB,GAC5E,UAAA,gBAAAP,EAACrB,EAAW,QAAX,EAAkB,SAAQ,aAAY,SAASY,GAC7C,UAAA,EAAE,qBAAqB,EAAA,CAC1B,EAAA,CACF;AAAA,EAAA,CAEH;AACD,2BAAQiB,GAAA,EAAS,OAAO,EAAE,mBAAmB,GAAI,GAAGb,GAAe;AACrE;"}
@@ -8,17 +8,16 @@ import { useI18n as E } from "../../../../i18n/I18n.js";
8
8
  import { BaseComponent as N } from "../../../Base/Base.js";
9
9
  import { useBase as P } from "../../../Base/useBase.js";
10
10
  import { Flex as _ } from "../../../Common/Flex/Flex.js";
11
- import "react-i18next";
12
11
  import "classnames";
13
12
  import { companyEvents as i } from "../../../../shared/constants.js";
14
13
  import { usePagination as g } from "../../../../hooks/usePagination/usePagination.js";
15
- function b(t) {
14
+ function S(t) {
16
15
  return /* @__PURE__ */ o(N, { ...t, children: /* @__PURE__ */ o(x, { ...t, children: t.children }) });
17
16
  }
18
17
  function x({ companyId: t, className: e, children: r }) {
19
18
  E("Company.Locations");
20
- const { onEvent: n } = P(), { getPaginationProps: m } = g(), {
21
- data: { companyLocationsList: s, httpMeta: a }
19
+ const { onEvent: n } = P(), { getPaginationProps: s } = g(), {
20
+ data: { companyLocationsList: m, httpMeta: a }
22
21
  } = u({ companyId: t }), c = () => {
23
22
  n(i.COMPANY_LOCATION_DONE);
24
23
  }, p = () => {
@@ -30,8 +29,8 @@ function x({ companyId: t, className: e, children: r }) {
30
29
  A,
31
30
  {
32
31
  value: {
33
- ...m(a.response.headers),
34
- locationList: s ?? [],
32
+ ...s(a.response.headers),
33
+ locationList: m ?? [],
35
34
  handleAddLocation: p,
36
35
  handleEditLocation: d,
37
36
  handleContinue: c
@@ -45,6 +44,6 @@ function x({ companyId: t, className: e, children: r }) {
45
44
  ) });
46
45
  }
47
46
  export {
48
- b as LocationsList
47
+ S as LocationsList
49
48
  };
50
49
  //# sourceMappingURL=LocationsList.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"LocationsList.js","sources":["../../../../../src/components/Company/Locations/LocationsList/LocationsList.tsx"],"sourcesContent":["import { useLocationsGetSuspense } from '@gusto/embedded-api/react-query/locationsGet'\nimport { Head } from './Head'\nimport { List } from './List'\nimport { Actions } from './Actions'\nimport { LocationsListProvider } from './useLocationsList'\nimport { useI18n } from '@/i18n'\nimport { BaseComponent, type BaseComponentInterface } from '@/components/Base/Base'\nimport { useBase } from '@/components/Base/useBase'\nimport { Flex } from '@/components/Common'\nimport { companyEvents } from '@/shared/constants'\nimport { usePagination } from '@/hooks/usePagination/usePagination'\n\ninterface LocationsListProps extends BaseComponentInterface {\n companyId: string\n}\n\nexport function LocationsList(props: LocationsListProps) {\n return (\n <BaseComponent {...props}>\n <Root {...props}>{props.children}</Root>\n </BaseComponent>\n )\n}\n\nfunction Root({ companyId, className, children }: LocationsListProps) {\n useI18n('Company.Locations')\n const { onEvent } = useBase()\n\n const { getPaginationProps } = usePagination()\n\n const {\n data: { companyLocationsList, httpMeta },\n } = useLocationsGetSuspense({ companyId })\n\n const handleContinue = () => {\n onEvent(companyEvents.COMPANY_LOCATION_DONE)\n }\n const handleAddLocation = () => {\n onEvent(companyEvents.COMPANY_LOCATION_CREATE)\n }\n const handleEditLocation = (uuid: string) => {\n onEvent(companyEvents.COMPANY_LOCATION_EDIT, { uuid })\n }\n\n return (\n <section className={className}>\n <LocationsListProvider\n value={{\n ...getPaginationProps(httpMeta.response.headers),\n locationList: companyLocationsList ?? [],\n handleAddLocation,\n handleEditLocation,\n handleContinue,\n }}\n >\n <Flex flexDirection=\"column\" gap={32}>\n {children ? (\n children\n ) : (\n <>\n <Head />\n <List />\n <Actions />\n </>\n )}\n </Flex>\n </LocationsListProvider>\n </section>\n )\n}\n"],"names":["LocationsList","props","jsx","BaseComponent","Root","companyId","className","children","useI18n","onEvent","useBase","getPaginationProps","usePagination","companyLocationsList","httpMeta","useLocationsGetSuspense","handleContinue","companyEvents","handleAddLocation","handleEditLocation","uuid","LocationsListProvider","Flex","jsxs","Fragment","Head","List","Actions"],"mappings":";;;;;;;;;;;;;;AAgBO,SAASA,EAAcC,GAA2B;AACvD,SACE,gBAAAC,EAACC,GAAA,EAAe,GAAGF,GACjB,UAAA,gBAAAC,EAACE,KAAM,GAAGH,GAAQ,UAAAA,EAAM,SAAA,CAAS,EAAA,CACnC;AAEJ;AAEA,SAASG,EAAK,EAAE,WAAAC,GAAW,WAAAC,GAAW,UAAAC,KAAgC;AACpE,EAAAC,EAAQ,mBAAmB;AAC3B,QAAM,EAAE,SAAAC,EAAA,IAAYC,EAAA,GAEd,EAAE,oBAAAC,EAAA,IAAuBC,EAAA,GAEzB;AAAA,IACJ,MAAM,EAAE,sBAAAC,GAAsB,UAAAC,EAAA;AAAA,EAAS,IACrCC,EAAwB,EAAE,WAAAV,GAAW,GAEnCW,IAAiB,MAAM;AAC3B,IAAAP,EAAQQ,EAAc,qBAAqB;AAAA,EAC7C,GACMC,IAAoB,MAAM;AAC9B,IAAAT,EAAQQ,EAAc,uBAAuB;AAAA,EAC/C,GACME,IAAqB,CAACC,MAAiB;AAC3C,IAAAX,EAAQQ,EAAc,uBAAuB,EAAE,MAAAG,EAAA,CAAM;AAAA,EACvD;AAEA,SACE,gBAAAlB,EAAC,aAAQ,WAAAI,GACP,UAAA,gBAAAJ;AAAA,IAACmB;AAAA,IAAA;AAAA,MACC,OAAO;AAAA,QACL,GAAGV,EAAmBG,EAAS,SAAS,OAAO;AAAA,QAC/C,cAAcD,KAAwB,CAAA;AAAA,QACtC,mBAAAK;AAAA,QACA,oBAAAC;AAAA,QACA,gBAAAH;AAAA,MAAA;AAAA,MAGF,UAAA,gBAAAd,EAACoB,KAAK,eAAc,UAAS,KAAK,IAC/B,UAAAf,KAGC,gBAAAgB,EAAAC,GAAA,EACE,UAAA;AAAA,QAAA,gBAAAtB,EAACuB,GAAA,EAAK;AAAA,0BACLC,GAAA,EAAK;AAAA,0BACLC,GAAA,CAAA,CAAQ;AAAA,MAAA,EAAA,CACX,EAAA,CAEJ;AAAA,IAAA;AAAA,EAAA,GAEJ;AAEJ;"}
1
+ {"version":3,"file":"LocationsList.js","sources":["../../../../../src/components/Company/Locations/LocationsList/LocationsList.tsx"],"sourcesContent":["import { useLocationsGetSuspense } from '@gusto/embedded-api/react-query/locationsGet'\nimport { Head } from './Head'\nimport { List } from './List'\nimport { Actions } from './Actions'\nimport { LocationsListProvider } from './useLocationsList'\nimport { useI18n } from '@/i18n'\nimport { BaseComponent, type BaseComponentInterface } from '@/components/Base/Base'\nimport { useBase } from '@/components/Base/useBase'\nimport { Flex } from '@/components/Common'\nimport { companyEvents } from '@/shared/constants'\nimport { usePagination } from '@/hooks/usePagination/usePagination'\n\ninterface LocationsListProps extends BaseComponentInterface {\n companyId: string\n}\n\nexport function LocationsList(props: LocationsListProps) {\n return (\n <BaseComponent {...props}>\n <Root {...props}>{props.children}</Root>\n </BaseComponent>\n )\n}\n\nfunction Root({ companyId, className, children }: LocationsListProps) {\n useI18n('Company.Locations')\n const { onEvent } = useBase()\n\n const { getPaginationProps } = usePagination()\n\n const {\n data: { companyLocationsList, httpMeta },\n } = useLocationsGetSuspense({ companyId })\n\n const handleContinue = () => {\n onEvent(companyEvents.COMPANY_LOCATION_DONE)\n }\n const handleAddLocation = () => {\n onEvent(companyEvents.COMPANY_LOCATION_CREATE)\n }\n const handleEditLocation = (uuid: string) => {\n onEvent(companyEvents.COMPANY_LOCATION_EDIT, { uuid })\n }\n\n return (\n <section className={className}>\n <LocationsListProvider\n value={{\n ...getPaginationProps(httpMeta.response.headers),\n locationList: companyLocationsList ?? [],\n handleAddLocation,\n handleEditLocation,\n handleContinue,\n }}\n >\n <Flex flexDirection=\"column\" gap={32}>\n {children ? (\n children\n ) : (\n <>\n <Head />\n <List />\n <Actions />\n </>\n )}\n </Flex>\n </LocationsListProvider>\n </section>\n )\n}\n"],"names":["LocationsList","props","jsx","BaseComponent","Root","companyId","className","children","useI18n","onEvent","useBase","getPaginationProps","usePagination","companyLocationsList","httpMeta","useLocationsGetSuspense","handleContinue","companyEvents","handleAddLocation","handleEditLocation","uuid","LocationsListProvider","Flex","jsxs","Fragment","Head","List","Actions"],"mappings":";;;;;;;;;;;;;AAgBO,SAASA,EAAcC,GAA2B;AACvD,SACE,gBAAAC,EAACC,GAAA,EAAe,GAAGF,GACjB,UAAA,gBAAAC,EAACE,KAAM,GAAGH,GAAQ,UAAAA,EAAM,SAAA,CAAS,EAAA,CACnC;AAEJ;AAEA,SAASG,EAAK,EAAE,WAAAC,GAAW,WAAAC,GAAW,UAAAC,KAAgC;AACpE,EAAAC,EAAQ,mBAAmB;AAC3B,QAAM,EAAE,SAAAC,EAAA,IAAYC,EAAA,GAEd,EAAE,oBAAAC,EAAA,IAAuBC,EAAA,GAEzB;AAAA,IACJ,MAAM,EAAE,sBAAAC,GAAsB,UAAAC,EAAA;AAAA,EAAS,IACrCC,EAAwB,EAAE,WAAAV,GAAW,GAEnCW,IAAiB,MAAM;AAC3B,IAAAP,EAAQQ,EAAc,qBAAqB;AAAA,EAC7C,GACMC,IAAoB,MAAM;AAC9B,IAAAT,EAAQQ,EAAc,uBAAuB;AAAA,EAC/C,GACME,IAAqB,CAACC,MAAiB;AAC3C,IAAAX,EAAQQ,EAAc,uBAAuB,EAAE,MAAAG,EAAA,CAAM;AAAA,EACvD;AAEA,SACE,gBAAAlB,EAAC,aAAQ,WAAAI,GACP,UAAA,gBAAAJ;AAAA,IAACmB;AAAA,IAAA;AAAA,MACC,OAAO;AAAA,QACL,GAAGV,EAAmBG,EAAS,SAAS,OAAO;AAAA,QAC/C,cAAcD,KAAwB,CAAA;AAAA,QACtC,mBAAAK;AAAA,QACA,oBAAAC;AAAA,QACA,gBAAAH;AAAA,MAAA;AAAA,MAGF,UAAA,gBAAAd,EAACoB,KAAK,eAAc,UAAS,KAAK,IAC/B,UAAAf,KAGC,gBAAAgB,EAAAC,GAAA,EACE,UAAA;AAAA,QAAA,gBAAAtB,EAACuB,GAAA,EAAK;AAAA,0BACLC,GAAA,EAAK;AAAA,0BACLC,GAAA,CAAA,CAAQ;AAAA,MAAA,EAAA,CACX,EAAA,CAEJ;AAAA,IAAA;AAAA,EAAA,GAEJ;AAEJ;"}
@@ -9,15 +9,18 @@ import "@gusto/embedded-api/models/errors/gustoembeddederror";
9
9
  import "@gusto/embedded-api/models/errors/sdkvalidationerror";
10
10
  import "@gusto/embedded-api/models/errors/unprocessableentityerrorobject";
11
11
  import "@gusto/embedded-api/models/errors/httpclienterrors";
12
+ import "dompurify";
13
+ import "../../../../contexts/LocaleProvider/useLocale.js";
12
14
  import "../../../../shared/constants.js";
13
15
  import "classnames";
14
16
  import "../../../../contexts/ComponentAdapter/useComponentContext.js";
17
+ import "../../../../contexts/LoadingIndicatorProvider/useLoadingIndicator.js";
15
18
  import { createCompoundContext as o } from "../../../Base/createCompoundContext.js";
16
- const [f, v] = o(
19
+ const [D, P] = o(
17
20
  "CompanyDocumentListContext"
18
21
  );
19
22
  export {
20
- v as LocationsListProvider,
21
- f as useLocationsList
23
+ P as LocationsListProvider,
24
+ D as useLocationsList
22
25
  };
23
26
  //# sourceMappingURL=useLocationsList.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"useLocationsList.js","sources":["../../../../../src/components/Company/Locations/LocationsList/useLocationsList.ts"],"sourcesContent":["import { type Location } from '@gusto/embedded-api/models/components/location'\nimport { createCompoundContext } from '@/components/Base'\nimport type { PaginationItemsPerPage } from '@/components/Common/PaginationControl/PaginationControlTypes'\n\ntype LocationsListContextType = {\n locationList: Location[]\n totalPages: number\n totalCount: number\n currentPage: number\n itemsPerPage: PaginationItemsPerPage\n handleItemsPerPageChange: (n: PaginationItemsPerPage) => void\n handleFirstPage: () => void\n handlePreviousPage: () => void\n handleNextPage: () => void\n handleLastPage: () => void\n handleEditLocation: (uuid: string) => void\n handleAddLocation: () => void\n handleContinue: () => void\n}\n\nconst [useLocationsList, LocationsListProvider] = createCompoundContext<LocationsListContextType>(\n 'CompanyDocumentListContext',\n)\n\nexport { useLocationsList, LocationsListProvider }\n"],"names":["useLocationsList","LocationsListProvider","createCompoundContext"],"mappings":";;;;;;;;;;;;;;;AAoBA,MAAM,CAACA,GAAkBC,CAAqB,IAAIC;AAAA,EAChD;AACF;"}
1
+ {"version":3,"file":"useLocationsList.js","sources":["../../../../../src/components/Company/Locations/LocationsList/useLocationsList.ts"],"sourcesContent":["import { type Location } from '@gusto/embedded-api/models/components/location'\nimport { createCompoundContext } from '@/components/Base'\nimport type { PaginationItemsPerPage } from '@/components/Common/PaginationControl/PaginationControlTypes'\n\ntype LocationsListContextType = {\n locationList: Location[]\n totalPages: number\n totalCount: number\n currentPage: number\n itemsPerPage: PaginationItemsPerPage\n handleItemsPerPageChange: (n: PaginationItemsPerPage) => void\n handleFirstPage: () => void\n handlePreviousPage: () => void\n handleNextPage: () => void\n handleLastPage: () => void\n handleEditLocation: (uuid: string) => void\n handleAddLocation: () => void\n handleContinue: () => void\n}\n\nconst [useLocationsList, LocationsListProvider] = createCompoundContext<LocationsListContextType>(\n 'CompanyDocumentListContext',\n)\n\nexport { useLocationsList, LocationsListProvider }\n"],"names":["useLocationsList","LocationsListProvider","createCompoundContext"],"mappings":";;;;;;;;;;;;;;;;;;AAoBA,MAAM,CAACA,GAAkBC,CAAqB,IAAIC;AAAA,EAChD;AACF;"}