@gusto/embedded-react-sdk 0.47.0 → 0.47.1

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 (215) hide show
  1. package/CHANGELOG.md +23 -0
  2. package/dist/components/Common/ActionsLayout/ActionsLayout.d.ts +1 -0
  3. package/dist/components/Common/ActionsLayout/ActionsLayout.js.map +1 -1
  4. package/dist/components/Common/Alert/Alert.d.ts +2 -0
  5. package/dist/components/Common/DataView/DataCards/DataCards.d.ts +2 -0
  6. package/dist/components/Common/DataView/DataCards/DataCards.js.map +1 -1
  7. package/dist/components/Common/DataView/DataTable/DataTable.d.ts +2 -0
  8. package/dist/components/Common/DataView/DataTable/DataTable.js.map +1 -1
  9. package/dist/components/Common/DataView/DataView.d.ts +2 -0
  10. package/dist/components/Common/DataView/DataView.js.map +1 -1
  11. package/dist/components/Common/DataView/useDataView.d.ts +4 -0
  12. package/dist/components/Common/DataView/useDataView.js.map +1 -1
  13. package/dist/components/Common/DataView/useSelectionState.d.ts +1 -0
  14. package/dist/components/Common/DataView/useSelectionState.js.map +1 -1
  15. package/dist/components/Common/DateRangeFilter/DateRangeFilter.d.ts +1 -0
  16. package/dist/components/Common/DateRangeFilter/DateRangeFilter.js.map +1 -1
  17. package/dist/components/Common/DetailViewLayout/DetailViewLayout.d.ts +1 -0
  18. package/dist/components/Common/DetailViewLayout/DetailViewLayout.js.map +1 -1
  19. package/dist/components/Common/DetailViewLayout/DetailViewLayoutTypes.d.ts +1 -0
  20. package/dist/components/Common/DocumentList/DocumentList.d.ts +6 -0
  21. package/dist/components/Common/DocumentList/DocumentList.js.map +1 -1
  22. package/dist/components/Common/DocumentViewer/DocumentViewer.d.ts +1 -0
  23. package/dist/components/Common/DocumentViewer/DocumentViewer.js.map +1 -1
  24. package/dist/components/Common/EmptyData/EmptyData.d.ts +1 -0
  25. package/dist/components/Common/EmptyData/EmptyData.js.map +1 -1
  26. package/dist/components/Common/FadeIn/FadeIn.d.ts +1 -0
  27. package/dist/components/Common/FadeIn/FadeIn.js.map +1 -1
  28. package/dist/components/Common/FieldCaption/FieldCaption.d.ts +8 -0
  29. package/dist/components/Common/FieldCaption/FieldCaption.js.map +1 -1
  30. package/dist/components/Common/FieldDescription/FieldDescription.d.ts +5 -0
  31. package/dist/components/Common/FieldDescription/FieldDescription.js.map +1 -1
  32. package/dist/components/Common/FieldErrorMessage/FieldErrorMessage.d.ts +5 -0
  33. package/dist/components/Common/FieldErrorMessage/FieldErrorMessage.js.map +1 -1
  34. package/dist/components/Common/FieldLayout/FieldLayout.d.ts +5 -0
  35. package/dist/components/Common/FieldLayout/FieldLayout.js.map +1 -1
  36. package/dist/components/Common/FieldLayout/FieldLayoutTypes.d.ts +15 -0
  37. package/dist/components/Common/Fieldset/Fieldset.d.ts +2 -0
  38. package/dist/components/Common/Fieldset/Fieldset.js.map +1 -1
  39. package/dist/components/Common/Flex/Flex.d.ts +4 -0
  40. package/dist/components/Common/Flex/Flex.js.map +1 -1
  41. package/dist/components/Common/FlowBreadcrumbs/FlowBreadcrumbs.d.ts +20 -0
  42. package/dist/components/Common/FlowBreadcrumbs/FlowBreadcrumbs.js.map +1 -1
  43. package/dist/components/Common/FlowBreadcrumbs/FlowBreadcrumbsTypes.d.ts +33 -7
  44. package/dist/components/Common/FlowBreadcrumbs/breadcrumbTransitionHelpers.d.ts +16 -0
  45. package/dist/components/Common/FlowBreadcrumbs/breadcrumbTransitionHelpers.js.map +1 -1
  46. package/dist/components/Common/Form/Form.d.ts +2 -0
  47. package/dist/components/Common/Form/Form.js.map +1 -1
  48. package/dist/components/Common/Grid/Grid.d.ts +2 -0
  49. package/dist/components/Common/Grid/Grid.js.map +1 -1
  50. package/dist/components/Common/HamburgerMenu/HamburgerMenu.d.ts +7 -0
  51. package/dist/components/Common/HamburgerMenu/HamburgerMenu.js.map +1 -1
  52. package/dist/components/Common/HamburgerMenu/HamburgerMenuTypes.d.ts +11 -0
  53. package/dist/components/Common/HorizontalFieldLayout/HorizontalFieldLayout.d.ts +7 -0
  54. package/dist/components/Common/HorizontalFieldLayout/HorizontalFieldLayout.js.map +1 -1
  55. package/dist/components/Common/HorizontalFieldLayout/HorizontalFieldLayoutTypes.d.ts +14 -0
  56. package/dist/components/Common/InlineSpinner/InlineSpinner.d.ts +1 -0
  57. package/dist/components/Common/InlineSpinner/InlineSpinner.js.map +1 -1
  58. package/dist/components/Common/InternalError/InternalError.d.ts +1 -0
  59. package/dist/components/Common/InternalError/InternalError.js.map +1 -1
  60. package/dist/components/Common/Loading/Loading.d.ts +2 -0
  61. package/dist/components/Common/Loading/Loading.js.map +1 -1
  62. package/dist/components/Common/OnboardingStatusBadge/index.d.ts +3 -0
  63. package/dist/components/Common/OnboardingStatusBadge/index.js.map +1 -1
  64. package/dist/components/Common/ReorderableList/DropZone.d.ts +1 -0
  65. package/dist/components/Common/ReorderableList/DropZone.js.map +1 -1
  66. package/dist/components/Common/ReorderableList/ReorderableItem.d.ts +1 -3
  67. package/dist/components/Common/ReorderableList/ReorderableItem.js.map +1 -1
  68. package/dist/components/Common/ReorderableList/ReorderableList.d.ts +1 -0
  69. package/dist/components/Common/ReorderableList/ReorderableList.js.map +1 -1
  70. package/dist/components/Common/ReorderableList/ReorderableListTypes.d.ts +4 -0
  71. package/dist/components/Common/ReorderableList/constants.d.ts +1 -3
  72. package/dist/components/Common/ReorderableList/constants.js.map +1 -1
  73. package/dist/components/Common/RequirementsList/RequirementsList.d.ts +1 -0
  74. package/dist/components/Common/RequirementsList/RequirementsList.js.map +1 -1
  75. package/dist/components/Common/TaxInputs/TaxInputs.d.ts +7 -0
  76. package/dist/components/Common/TaxInputs/TaxInputs.js.map +1 -1
  77. package/dist/components/Common/Toast/Toast.d.ts +1 -0
  78. package/dist/components/Common/VisuallyHidden/VisuallyHidden.d.ts +2 -0
  79. package/dist/components/Common/VisuallyHidden/VisuallyHidden.js.map +1 -1
  80. package/dist/components/Company/AssignSignatory/AssignSignatorySelection.js +6 -7
  81. package/dist/components/Company/AssignSignatory/AssignSignatorySelection.js.map +1 -1
  82. package/dist/components/Company/AssignSignatory/CreateSignatory/Actions.js +8 -9
  83. package/dist/components/Company/AssignSignatory/CreateSignatory/Actions.js.map +1 -1
  84. package/dist/components/Company/AssignSignatory/CreateSignatory/useCreateSignatory.js +3 -5
  85. package/dist/components/Company/AssignSignatory/CreateSignatory/useCreateSignatory.js.map +1 -1
  86. package/dist/components/Company/AssignSignatory/InviteSignatory/Actions.js +6 -7
  87. package/dist/components/Company/AssignSignatory/InviteSignatory/Actions.js.map +1 -1
  88. package/dist/components/Company/AssignSignatory/InviteSignatory/useInviteSignatory.js +3 -5
  89. package/dist/components/Company/AssignSignatory/InviteSignatory/useInviteSignatory.js.map +1 -1
  90. package/dist/components/Company/AssignSignatory/useAssignSignatory.js +5 -7
  91. package/dist/components/Company/AssignSignatory/useAssignSignatory.js.map +1 -1
  92. package/dist/components/Company/BankAccount/BankAccountForm/Actions.js +6 -6
  93. package/dist/components/Company/BankAccount/BankAccountForm/context.js +3 -5
  94. package/dist/components/Company/BankAccount/BankAccountForm/context.js.map +1 -1
  95. package/dist/components/Company/BankAccount/BankAccountList/Actions.js +6 -7
  96. package/dist/components/Company/BankAccount/BankAccountList/Actions.js.map +1 -1
  97. package/dist/components/Company/BankAccount/BankAccountVerify/Actions.js +7 -8
  98. package/dist/components/Company/BankAccount/BankAccountVerify/Actions.js.map +1 -1
  99. package/dist/components/Company/DocumentSigner/DocumentList/Actions.js +5 -6
  100. package/dist/components/Company/DocumentSigner/DocumentList/Actions.js.map +1 -1
  101. package/dist/components/Company/DocumentSigner/DocumentList/useDocumentList.js +3 -5
  102. package/dist/components/Company/DocumentSigner/DocumentList/useDocumentList.js.map +1 -1
  103. package/dist/components/Company/FederalTaxes/Actions.js +6 -7
  104. package/dist/components/Company/FederalTaxes/Actions.js.map +1 -1
  105. package/dist/components/Company/FederalTaxes/Form.js +1 -1
  106. package/dist/components/Company/FederalTaxes/Form.js.map +1 -1
  107. package/dist/components/Company/FederalTaxes/useFederalTaxes.js +8 -10
  108. package/dist/components/Company/FederalTaxes/useFederalTaxes.js.map +1 -1
  109. package/dist/components/Company/Industry/Actions.js +5 -6
  110. package/dist/components/Company/Industry/Actions.js.map +1 -1
  111. package/dist/components/Company/Industry/Context.js +6 -8
  112. package/dist/components/Company/Industry/Context.js.map +1 -1
  113. package/dist/components/Company/Industry/Edit.js +10 -11
  114. package/dist/components/Company/Industry/Edit.js.map +1 -1
  115. package/dist/components/Company/Locations/LocationForm/Actions.js +2 -3
  116. package/dist/components/Company/Locations/LocationForm/Actions.js.map +1 -1
  117. package/dist/components/Company/Locations/LocationForm/useLocationForm.js +3 -5
  118. package/dist/components/Company/Locations/LocationForm/useLocationForm.js.map +1 -1
  119. package/dist/components/Company/Locations/LocationsList/Actions.js +2 -3
  120. package/dist/components/Company/Locations/LocationsList/Actions.js.map +1 -1
  121. package/dist/components/Company/Locations/LocationsList/List.js +2 -3
  122. package/dist/components/Company/Locations/LocationsList/List.js.map +1 -1
  123. package/dist/components/Company/Locations/LocationsList/useLocationsList.js +3 -5
  124. package/dist/components/Company/Locations/LocationsList/useLocationsList.js.map +1 -1
  125. package/dist/components/Company/OnboardingOverview/context.js +3 -5
  126. package/dist/components/Company/OnboardingOverview/context.js.map +1 -1
  127. package/dist/components/Company/StateTaxes/StateTaxesForm/Actions.js +5 -6
  128. package/dist/components/Company/StateTaxes/StateTaxesForm/Actions.js.map +1 -1
  129. package/dist/components/Company/StateTaxes/StateTaxesForm/context.js +3 -5
  130. package/dist/components/Company/StateTaxes/StateTaxesForm/context.js.map +1 -1
  131. package/dist/components/Company/StateTaxes/StateTaxesList/Actions.js +6 -7
  132. package/dist/components/Company/StateTaxes/StateTaxesList/Actions.js.map +1 -1
  133. package/dist/components/Company/StateTaxes/StateTaxesList/context.js +3 -5
  134. package/dist/components/Company/StateTaxes/StateTaxesList/context.js.map +1 -1
  135. package/dist/components/Contractor/Address/Form.js +4 -4
  136. package/dist/components/Contractor/Address/useAddress.js +5 -7
  137. package/dist/components/Contractor/Address/useAddress.js.map +1 -1
  138. package/dist/components/Employee/Deductions/management/DeductionsCard/DeductionsCard.js +1 -1
  139. package/dist/components/Employee/Documents/management/DocumentsCard/DocumentsCard.js +12 -12
  140. package/dist/components/Employee/Documents/onboarding/DocumentSigner/DocumentList/Actions.js +4 -5
  141. package/dist/components/Employee/Documents/onboarding/DocumentSigner/DocumentList/Actions.js.map +1 -1
  142. package/dist/components/Employee/Documents/onboarding/DocumentSigner/DocumentList/useDocumentList.js +3 -5
  143. package/dist/components/Employee/Documents/onboarding/DocumentSigner/DocumentList/useDocumentList.js.map +1 -1
  144. package/dist/components/Employee/FederalTaxes/management/FederalTaxesEditForm.js +1 -1
  145. package/dist/components/Employee/FederalTaxes/onboarding/FederalTaxes.js +1 -1
  146. package/dist/components/Employee/OnboardingSummary/OnboardingSummary.js +4 -4
  147. package/dist/components/Employee/PaymentMethod/onboarding/ListView.js +13 -13
  148. package/dist/components/Employee/PaymentMethod/shared/BankFormBody/BankFormBody.js +2 -3
  149. package/dist/components/Employee/PaymentMethod/shared/BankFormBody/BankFormBody.js.map +1 -1
  150. package/dist/components/Employee/PaymentMethod/shared/SplitPaymentsFormBody/SplitPaymentsFormBody.js +1 -1
  151. package/dist/components/Employee/Paystubs/management/PaystubsCard/PaystubsCard.js +6 -6
  152. package/dist/components/Employee/Profile/management/ProfileCard/ProfileCard.js +12 -12
  153. package/dist/components/Employee/Profile/management/ProfileEditForm.js +1 -1
  154. package/dist/components/Employee/Profile/onboarding/EmployeeProfile.js +1 -1
  155. package/dist/components/Employee/StateTaxes/management/StateTaxesEditForm.js +1 -1
  156. package/dist/components/Employee/StateTaxes/onboarding/StateTaxes.js +1 -1
  157. package/dist/components/Employee/Taxes/Actions.js +7 -8
  158. package/dist/components/Employee/Taxes/Actions.js.map +1 -1
  159. package/dist/components/Employee/Taxes/useTaxes.js +3 -5
  160. package/dist/components/Employee/Taxes/useTaxes.js.map +1 -1
  161. package/dist/components/Employee/exports/employeeManagement.d.ts +0 -2
  162. package/dist/components/Employee/exports/employeeManagement.js +50 -52
  163. package/dist/components/Employee/exports/employeeManagement.js.map +1 -1
  164. package/dist/components/Employee/exports/employeeOnboarding.d.ts +1 -0
  165. package/dist/components/Employee/exports/employeeOnboarding.js +20 -18
  166. package/dist/components/Employee/exports/employeeOnboarding.js.map +1 -1
  167. package/dist/components/Payroll/OffCyclePayPeriodDateForm/OffCyclePayPeriodDateFormPresentation.js +10 -11
  168. package/dist/components/Payroll/OffCyclePayPeriodDateForm/OffCyclePayPeriodDateFormPresentation.js.map +1 -1
  169. package/dist/components/Payroll/OffCycleReasonSelection/OffCycleReasonSelectionPresentation.js +0 -1
  170. package/dist/components/Payroll/OffCycleReasonSelection/OffCycleReasonSelectionPresentation.js.map +1 -1
  171. package/dist/components/Payroll/OffCycleTaxWithholdingModal/OffCycleTaxWithholdingModal.js +2 -3
  172. package/dist/components/Payroll/OffCycleTaxWithholdingModal/OffCycleTaxWithholdingModal.js.map +1 -1
  173. package/dist/components/Payroll/usePreparedPayrollData.js +8 -10
  174. package/dist/components/Payroll/usePreparedPayrollData.js.map +1 -1
  175. package/dist/components/TimeOff/HolidayPolicyDetail/HolidayPolicyDetailPresentation.js +2 -3
  176. package/dist/components/TimeOff/HolidayPolicyDetail/HolidayPolicyDetailPresentation.js.map +1 -1
  177. package/dist/components/TimeOff/shared/PolicyDetailLayout/PolicyDetailLayout.js +24 -25
  178. package/dist/components/TimeOff/shared/PolicyDetailLayout/PolicyDetailLayout.js.map +1 -1
  179. package/dist/contexts/GustoProvider/GustoProvider.d.ts +34 -1
  180. package/dist/contexts/GustoProvider/GustoProvider.js.map +1 -1
  181. package/dist/contexts/GustoProvider/GustoProviderCustomUIAdapter.d.ts +42 -2
  182. package/dist/contexts/GustoProvider/GustoProviderCustomUIAdapter.js +2 -3
  183. package/dist/contexts/GustoProvider/GustoProviderCustomUIAdapter.js.map +1 -1
  184. package/dist/contexts/GustoProvider/SDKI18next.d.ts +1 -1
  185. package/dist/contexts/GustoProvider/SDKI18next.js.map +1 -1
  186. package/dist/contexts/GustoProvider/index.d.ts +0 -2
  187. package/dist/contexts/ThemeProvider/ThemeProvider.d.ts +5 -1
  188. package/dist/contexts/ThemeProvider/ThemeProvider.js.map +1 -1
  189. package/dist/contexts/ThemeProvider/customRender.d.ts +1 -0
  190. package/dist/contexts/ThemeProvider/index.d.ts +0 -1
  191. package/dist/contexts/ThemeProvider/theme.d.ts +7 -101
  192. package/dist/contexts/ThemeProvider/theme.js +58 -64
  193. package/dist/contexts/ThemeProvider/theme.js.map +1 -1
  194. package/dist/contexts/ThemeProvider/types.d.ts +181 -0
  195. package/dist/contexts/ThemeProvider/useTheme.d.ts +4 -0
  196. package/dist/contexts/ThemeProvider/useTheme.js.map +1 -1
  197. package/dist/contexts/index.d.ts +1 -0
  198. package/dist/index.d.ts +3 -2
  199. package/dist/index.js +145 -141
  200. package/dist/partner-hook-utils/form/fields/CheckboxHookField.js +6 -7
  201. package/dist/partner-hook-utils/form/fields/CheckboxHookField.js.map +1 -1
  202. package/dist/partner-hook-utils/form/fields/NumberInputHookField.js +6 -7
  203. package/dist/partner-hook-utils/form/fields/NumberInputHookField.js.map +1 -1
  204. package/dist/partner-hook-utils/form/fields/RadioGroupHookField.js +8 -9
  205. package/dist/partner-hook-utils/form/fields/RadioGroupHookField.js.map +1 -1
  206. package/dist/partner-hook-utils/form/fields/SelectHookField.js +2 -3
  207. package/dist/partner-hook-utils/form/fields/SelectHookField.js.map +1 -1
  208. package/dist/partner-hook-utils/form/fields/SwitchHookField.js +12 -13
  209. package/dist/partner-hook-utils/form/fields/SwitchHookField.js.map +1 -1
  210. package/dist/partner-hook-utils/form/fields/TextInputHookField.js +8 -9
  211. package/dist/partner-hook-utils/form/fields/TextInputHookField.js.map +1 -1
  212. package/dist/partner-hook-utils/form/fields/index.d.ts +2 -0
  213. package/dist/partner-hook-utils/form/index.d.ts +1 -1
  214. package/docs/reference/endpoint-inventory.json +16 -16
  215. package/package.json +7 -6
@@ -1 +1 @@
1
- {"version":3,"file":"SwitchHookField.js","sources":["../../../../src/partner-hook-utils/form/fields/SwitchHookField.tsx"],"sourcesContent":["import type { ComponentType } from 'react'\nimport { useHookFieldResolution } from '../useHookFieldResolution'\nimport type { BaseFieldProps, ValidationMessages, FormHookResult } from '../../types'\nimport { withFieldElementRegistry } from './withFieldElementRegistry'\nimport { SwitchField } from '@/components/Common'\nimport type { SwitchProps } from '@/components/Common/UI/Switch/SwitchTypes'\n\n/**\n * Props accepted by a toggle switch field surfaced through a form hook.\n * Exposes `validationMessages` for custom error text alongside the shared base\n * field attributes (`label`, `description`).\n *\n * @typeParam TErrorCode - Validation error code keys mapped via `validationMessages`.\n * @public\n */\nexport interface SwitchHookFieldProps<TErrorCode extends string = never> extends BaseFieldProps {\n /** The field name; must match the corresponding key in the form schema. */\n name: string\n /** Form hook result to connect to; falls back to the nearest `SDKFormProvider` when omitted. */\n formHookResult?: FormHookResult\n /** Custom error text keyed by validation error code. */\n validationMessages?: ValidationMessages<TErrorCode>\n /** Replaces the default toggle switch UI component; must accept the same props as `SwitchProps`. */\n FieldComponent?: ComponentType<SwitchProps>\n}\n\n/**\n * Switch field connected to a partner form hook result via `useHookFieldResolution`.\n *\n * @typeParam TErrorCode - Validation error code keys mapped via `validationMessages`.\n * @param props - Field configuration including `name`, `formHookResult`, and label content.\n * @returns The rendered switch field wrapped in the field element registry.\n * @internal\n */\nexport function SwitchHookField<TErrorCode extends string>({\n name,\n formHookResult,\n label,\n description,\n validationMessages,\n FieldComponent,\n}: SwitchHookFieldProps<TErrorCode>) {\n const { metadata, control, errorMessage, fieldElementRegistry } = useHookFieldResolution(\n name,\n formHookResult,\n validationMessages,\n )\n const fieldMetadata = metadata[name]\n\n return withFieldElementRegistry(\n fieldElementRegistry,\n <SwitchField\n name={name}\n control={control}\n label={label}\n description={description}\n errorMessage={errorMessage}\n isRequired={fieldMetadata?.isRequired}\n isDisabled={fieldMetadata?.isDisabled}\n FieldComponent={FieldComponent}\n />,\n )\n}\n"],"names":["SwitchHookField","name","formHookResult","label","description","validationMessages","FieldComponent","metadata","control","errorMessage","fieldElementRegistry","useHookFieldResolution","fieldMetadata","withFieldElementRegistry","jsx","SwitchField"],"mappings":";;;;;AAkCO,SAASA,EAA2C;AAAA,EACzD,MAAAC;AAAA,EACA,gBAAAC;AAAA,EACA,OAAAC;AAAA,EACA,aAAAC;AAAA,EACA,oBAAAC;AAAA,EACA,gBAAAC;AACF,GAAqC;AACnC,QAAM,EAAE,UAAAC,GAAU,SAAAC,GAAS,cAAAC,GAAc,sBAAAC,MAAyBC;AAAA,IAChEV;AAAA,IACAC;AAAA,IACAG;AAAA,EAAA,GAEIO,IAAgBL,EAASN,CAAI;AAEnC,SAAOY;AAAA,IACLH;AAAA,IACA,gBAAAI;AAAA,MAACC;AAAA,MAAA;AAAA,QACC,MAAAd;AAAA,QACA,SAAAO;AAAA,QACA,OAAAL;AAAA,QACA,aAAAC;AAAA,QACA,cAAAK;AAAA,QACA,YAAYG,GAAe;AAAA,QAC3B,YAAYA,GAAe;AAAA,QAC3B,gBAAAN;AAAA,MAAA;AAAA,IAAA;AAAA,EACF;AAEJ;"}
1
+ {"version":3,"file":"SwitchHookField.js","sources":["../../../../src/partner-hook-utils/form/fields/SwitchHookField.tsx"],"sourcesContent":["import type { ComponentType } from 'react'\nimport { useHookFieldResolution } from '../useHookFieldResolution'\nimport type { BaseFieldProps, ValidationMessages, FormHookResult } from '../../types'\nimport { withFieldElementRegistry } from './withFieldElementRegistry'\nimport { SwitchField } from '@/components/Common'\nimport type { SwitchProps } from '@/components/Common/UI/Switch/SwitchTypes'\n\n/**\n * Props accepted by a toggle switch field surfaced through a form hook.\n * Exposes `validationMessages` for custom error text alongside the shared base\n * field attributes (`label`, `description`).\n *\n * @typeParam TErrorCode - Validation error code keys mapped via `validationMessages`.\n * @public\n */\nexport interface SwitchHookFieldProps<TErrorCode extends string = never> extends BaseFieldProps {\n /** The field name; must match the corresponding key in the form schema. */\n name: string\n /** Form hook result to connect to; falls back to the nearest `SDKFormProvider` when omitted. */\n formHookResult?: FormHookResult\n /** Custom error text keyed by validation error code. */\n validationMessages?: ValidationMessages<TErrorCode>\n /** Replaces the default toggle switch UI component; must accept the same props as `SwitchProps`. */\n FieldComponent?: ComponentType<SwitchProps>\n}\n\n/**\n * Switch field connected to a partner form hook result via `useHookFieldResolution`.\n *\n * @typeParam TErrorCode - Validation error code keys mapped via `validationMessages`.\n * @param props - Field configuration including `name`, `formHookResult`, and label content.\n * @returns The rendered switch field wrapped in the field element registry.\n * @internal\n */\nexport function SwitchHookField<TErrorCode extends string>({\n name,\n formHookResult,\n label,\n description,\n validationMessages,\n FieldComponent,\n}: SwitchHookFieldProps<TErrorCode>) {\n const { metadata, control, errorMessage, fieldElementRegistry } = useHookFieldResolution(\n name,\n formHookResult,\n validationMessages,\n )\n const fieldMetadata = metadata[name]\n\n return withFieldElementRegistry(\n fieldElementRegistry,\n <SwitchField\n name={name}\n control={control}\n label={label}\n description={description}\n errorMessage={errorMessage}\n isRequired={fieldMetadata?.isRequired}\n isDisabled={fieldMetadata?.isDisabled}\n FieldComponent={FieldComponent}\n />,\n )\n}\n"],"names":["SwitchHookField","name","formHookResult","label","description","validationMessages","FieldComponent","metadata","control","errorMessage","fieldElementRegistry","useHookFieldResolution","fieldMetadata","withFieldElementRegistry","jsx","SwitchField"],"mappings":";;;;AAkCO,SAASA,EAA2C;AAAA,EACzD,MAAAC;AAAA,EACA,gBAAAC;AAAA,EACA,OAAAC;AAAA,EACA,aAAAC;AAAA,EACA,oBAAAC;AAAA,EACA,gBAAAC;AACF,GAAqC;AACnC,QAAM,EAAE,UAAAC,GAAU,SAAAC,GAAS,cAAAC,GAAc,sBAAAC,MAAyBC;AAAA,IAChEV;AAAA,IACAC;AAAA,IACAG;AAAA,EAAA,GAEIO,IAAgBL,EAASN,CAAI;AAEnC,SAAOY;AAAA,IACLH;AAAA,IACA,gBAAAI;AAAA,MAACC;AAAA,MAAA;AAAA,QACC,MAAAd;AAAA,QACA,SAAAO;AAAA,QACA,OAAAL;AAAA,QACA,aAAAC;AAAA,QACA,cAAAK;AAAA,QACA,YAAYG,GAAe;AAAA,QAC3B,YAAYA,GAAe;AAAA,QAC3B,gBAAAN;AAAA,MAAA;AAAA,IAAA;AAAA,EACF;AAEJ;"}
@@ -1,9 +1,8 @@
1
- import { jsx as f } from "react/jsx-runtime";
1
+ import { jsx as p } from "react/jsx-runtime";
2
2
  import { useHookFieldResolution as R } from "../useHookFieldResolution.js";
3
3
  import { withFieldElementRegistry as c } from "./withFieldElementRegistry.js";
4
- import "../../../shared/constants.js";
5
4
  import { TextInputField as x } from "../../../components/Common/Fields/TextInputField/TextInputField.js";
6
- function y({
5
+ function q({
7
6
  name: e,
8
7
  formHookResult: i,
9
8
  label: o,
@@ -13,21 +12,21 @@ function y({
13
12
  placeholder: l,
14
13
  FieldComponent: m
15
14
  }) {
16
- const { metadata: n, control: p, errorMessage: u, fieldElementRegistry: a } = R(
15
+ const { metadata: n, control: u, errorMessage: a, fieldElementRegistry: f } = R(
17
16
  e,
18
17
  i,
19
18
  s
20
19
  ), t = n[e];
21
20
  return c(
22
- a,
23
- /* @__PURE__ */ f(
21
+ f,
22
+ /* @__PURE__ */ p(
24
23
  x,
25
24
  {
26
25
  name: e,
27
- control: p,
26
+ control: u,
28
27
  label: o,
29
28
  description: r,
30
- errorMessage: u,
29
+ errorMessage: a,
31
30
  isRequired: t?.isRequired,
32
31
  isDisabled: t?.isDisabled,
33
32
  transform: d,
@@ -38,6 +37,6 @@ function y({
38
37
  );
39
38
  }
40
39
  export {
41
- y as TextInputHookField
40
+ q as TextInputHookField
42
41
  };
43
42
  //# sourceMappingURL=TextInputHookField.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"TextInputHookField.js","sources":["../../../../src/partner-hook-utils/form/fields/TextInputHookField.tsx"],"sourcesContent":["import type { ComponentType } from 'react'\nimport { useHookFieldResolution } from '../useHookFieldResolution'\nimport type { BaseFieldProps, ValidationMessages, FormHookResult } from '../../types'\nimport { withFieldElementRegistry } from './withFieldElementRegistry'\nimport { TextInputField } from '@/components/Common'\nimport type { TextInputProps } from '@/components/Common/UI/TextInput/TextInputTypes'\n\n/**\n * Props accepted by a text input field surfaced through a form hook.\n * Exposes a `transform` function for preprocessing raw input, `placeholder` text,\n * and `validationMessages` for custom error text alongside the shared base field\n * attributes (`label`, `description`).\n *\n * @typeParam TErrorCode - Required validation error code keys mapped via `validationMessages`.\n * @typeParam TOptionalErrorCode - Optional validation error code keys mapped via `validationMessages`.\n * @public\n */\nexport interface TextInputHookFieldProps<\n TErrorCode extends string = never,\n TOptionalErrorCode extends string = never,\n> extends BaseFieldProps {\n /** The field name; must match the corresponding key in the form schema. */\n name: string\n /** Form hook result to connect to; falls back to the nearest `SDKFormProvider` when omitted. */\n formHookResult?: FormHookResult\n /** Custom error text keyed by validation error code. */\n validationMessages?: ValidationMessages<TErrorCode, TOptionalErrorCode>\n /** Transforms the raw string value on every change before storing it; use for normalization such as trimming or changing case. */\n transform?: (value: string) => string\n /** Placeholder text displayed when the field has no value. */\n placeholder?: string\n /** Replaces the default text input UI component; must accept the same props as `TextInputProps`. */\n FieldComponent?: ComponentType<TextInputProps>\n}\n\n/**\n * Text input field connected to a partner form hook result via `useHookFieldResolution`.\n *\n * @typeParam TErrorCode - Required validation error code keys mapped via `validationMessages`.\n * @typeParam TOptionalErrorCode - Optional validation error code keys mapped via `validationMessages`.\n * @param props - Field configuration including `name`, `formHookResult`, `transform`, `placeholder`, and label content.\n * @returns The rendered text input field wrapped in the field element registry.\n * @internal\n */\nexport function TextInputHookField<\n TErrorCode extends string,\n TOptionalErrorCode extends string = never,\n>({\n name,\n formHookResult,\n label,\n description,\n validationMessages,\n transform,\n placeholder,\n FieldComponent,\n}: TextInputHookFieldProps<TErrorCode, TOptionalErrorCode>) {\n const { metadata, control, errorMessage, fieldElementRegistry } = useHookFieldResolution(\n name,\n formHookResult,\n validationMessages,\n )\n const fieldMetadata = metadata[name]\n\n return withFieldElementRegistry(\n fieldElementRegistry,\n <TextInputField\n name={name}\n control={control}\n label={label}\n description={description}\n errorMessage={errorMessage}\n isRequired={fieldMetadata?.isRequired}\n isDisabled={fieldMetadata?.isDisabled}\n transform={transform}\n placeholder={placeholder}\n FieldComponent={FieldComponent}\n />,\n )\n}\n"],"names":["TextInputHookField","name","formHookResult","label","description","validationMessages","transform","placeholder","FieldComponent","metadata","control","errorMessage","fieldElementRegistry","useHookFieldResolution","fieldMetadata","withFieldElementRegistry","jsx","TextInputField"],"mappings":";;;;;AA4CO,SAASA,EAGd;AAAA,EACA,MAAAC;AAAA,EACA,gBAAAC;AAAA,EACA,OAAAC;AAAA,EACA,aAAAC;AAAA,EACA,oBAAAC;AAAA,EACA,WAAAC;AAAA,EACA,aAAAC;AAAA,EACA,gBAAAC;AACF,GAA4D;AAC1D,QAAM,EAAE,UAAAC,GAAU,SAAAC,GAAS,cAAAC,GAAc,sBAAAC,MAAyBC;AAAA,IAChEZ;AAAA,IACAC;AAAA,IACAG;AAAA,EAAA,GAEIS,IAAgBL,EAASR,CAAI;AAEnC,SAAOc;AAAA,IACLH;AAAA,IACA,gBAAAI;AAAA,MAACC;AAAA,MAAA;AAAA,QACC,MAAAhB;AAAA,QACA,SAAAS;AAAA,QACA,OAAAP;AAAA,QACA,aAAAC;AAAA,QACA,cAAAO;AAAA,QACA,YAAYG,GAAe;AAAA,QAC3B,YAAYA,GAAe;AAAA,QAC3B,WAAAR;AAAA,QACA,aAAAC;AAAA,QACA,gBAAAC;AAAA,MAAA;AAAA,IAAA;AAAA,EACF;AAEJ;"}
1
+ {"version":3,"file":"TextInputHookField.js","sources":["../../../../src/partner-hook-utils/form/fields/TextInputHookField.tsx"],"sourcesContent":["import type { ComponentType } from 'react'\nimport { useHookFieldResolution } from '../useHookFieldResolution'\nimport type { BaseFieldProps, ValidationMessages, FormHookResult } from '../../types'\nimport { withFieldElementRegistry } from './withFieldElementRegistry'\nimport { TextInputField } from '@/components/Common'\nimport type { TextInputProps } from '@/components/Common/UI/TextInput/TextInputTypes'\n\n/**\n * Props accepted by a text input field surfaced through a form hook.\n * Exposes a `transform` function for preprocessing raw input, `placeholder` text,\n * and `validationMessages` for custom error text alongside the shared base field\n * attributes (`label`, `description`).\n *\n * @typeParam TErrorCode - Required validation error code keys mapped via `validationMessages`.\n * @typeParam TOptionalErrorCode - Optional validation error code keys mapped via `validationMessages`.\n * @public\n */\nexport interface TextInputHookFieldProps<\n TErrorCode extends string = never,\n TOptionalErrorCode extends string = never,\n> extends BaseFieldProps {\n /** The field name; must match the corresponding key in the form schema. */\n name: string\n /** Form hook result to connect to; falls back to the nearest `SDKFormProvider` when omitted. */\n formHookResult?: FormHookResult\n /** Custom error text keyed by validation error code. */\n validationMessages?: ValidationMessages<TErrorCode, TOptionalErrorCode>\n /** Transforms the raw string value on every change before storing it; use for normalization such as trimming or changing case. */\n transform?: (value: string) => string\n /** Placeholder text displayed when the field has no value. */\n placeholder?: string\n /** Replaces the default text input UI component; must accept the same props as `TextInputProps`. */\n FieldComponent?: ComponentType<TextInputProps>\n}\n\n/**\n * Text input field connected to a partner form hook result via `useHookFieldResolution`.\n *\n * @typeParam TErrorCode - Required validation error code keys mapped via `validationMessages`.\n * @typeParam TOptionalErrorCode - Optional validation error code keys mapped via `validationMessages`.\n * @param props - Field configuration including `name`, `formHookResult`, `transform`, `placeholder`, and label content.\n * @returns The rendered text input field wrapped in the field element registry.\n * @internal\n */\nexport function TextInputHookField<\n TErrorCode extends string,\n TOptionalErrorCode extends string = never,\n>({\n name,\n formHookResult,\n label,\n description,\n validationMessages,\n transform,\n placeholder,\n FieldComponent,\n}: TextInputHookFieldProps<TErrorCode, TOptionalErrorCode>) {\n const { metadata, control, errorMessage, fieldElementRegistry } = useHookFieldResolution(\n name,\n formHookResult,\n validationMessages,\n )\n const fieldMetadata = metadata[name]\n\n return withFieldElementRegistry(\n fieldElementRegistry,\n <TextInputField\n name={name}\n control={control}\n label={label}\n description={description}\n errorMessage={errorMessage}\n isRequired={fieldMetadata?.isRequired}\n isDisabled={fieldMetadata?.isDisabled}\n transform={transform}\n placeholder={placeholder}\n FieldComponent={FieldComponent}\n />,\n )\n}\n"],"names":["TextInputHookField","name","formHookResult","label","description","validationMessages","transform","placeholder","FieldComponent","metadata","control","errorMessage","fieldElementRegistry","useHookFieldResolution","fieldMetadata","withFieldElementRegistry","jsx","TextInputField"],"mappings":";;;;AA4CO,SAASA,EAGd;AAAA,EACA,MAAAC;AAAA,EACA,gBAAAC;AAAA,EACA,OAAAC;AAAA,EACA,aAAAC;AAAA,EACA,oBAAAC;AAAA,EACA,WAAAC;AAAA,EACA,aAAAC;AAAA,EACA,gBAAAC;AACF,GAA4D;AAC1D,QAAM,EAAE,UAAAC,GAAU,SAAAC,GAAS,cAAAC,GAAc,sBAAAC,MAAyBC;AAAA,IAChEZ;AAAA,IACAC;AAAA,IACAG;AAAA,EAAA,GAEIS,IAAgBL,EAASR,CAAI;AAEnC,SAAOc;AAAA,IACLH;AAAA,IACA,gBAAAI;AAAA,MAACC;AAAA,MAAA;AAAA,QACC,MAAAhB;AAAA,QACA,SAAAS;AAAA,QACA,OAAAP;AAAA,QACA,aAAAC;AAAA,QACA,cAAAO;AAAA,QACA,YAAYG,GAAe;AAAA,QAC3B,YAAYA,GAAe;AAAA,QAC3B,WAAAR;AAAA,QACA,aAAAC;AAAA,QACA,gBAAAC;AAAA,MAAA;AAAA,IAAA;AAAA,EACF;AAEJ;"}
@@ -6,6 +6,8 @@ export { NumberInputHookField, type NumberInputHookFieldProps } from './NumberIn
6
6
  export { DatePickerHookField, type DatePickerHookFieldProps } from './DatePickerHookField';
7
7
  export { RadioGroupHookField, type RadioGroupHookFieldProps } from './RadioGroupHookField';
8
8
  export { SwitchHookField, type SwitchHookFieldProps } from './SwitchHookField';
9
+ export type { SharedFieldLayoutProps } from '../../../components/Common/FieldLayout/FieldLayoutTypes';
10
+ export type { SharedHorizontalFieldLayoutProps } from '../../../components/Common/HorizontalFieldLayout/HorizontalFieldLayoutTypes';
9
11
  export type { TextInputProps } from '../../../components/Common/UI/TextInput/TextInputTypes';
10
12
  export type { SelectProps, SelectOption } from '../../../components/Common/UI/Select/SelectTypes';
11
13
  export type { CheckboxProps } from '../../../components/Common/UI/Checkbox/CheckboxTypes';
@@ -7,4 +7,4 @@ export { SDKFormProvider } from './SDKFormProvider';
7
7
  export { useDeriveFieldsMetadata } from './useDeriveFieldsMetadata';
8
8
  export { useFieldErrorMessage } from './useFieldErrorMessage';
9
9
  export { composeSubmitHandler } from './composeSubmitHandler';
10
- export { TextInputHookField, type TextInputHookFieldProps, SelectHookField, type SelectHookFieldProps, CheckboxHookField, type CheckboxHookFieldProps, NumberInputHookField, type NumberInputHookFieldProps, DatePickerHookField, type DatePickerHookFieldProps, RadioGroupHookField, type RadioGroupHookFieldProps, type TextInputProps, type SelectProps, type SelectOption, type CheckboxProps, type NumberInputProps, type DatePickerProps, type RadioGroupProps, type RadioGroupOption, SwitchHookField, type SwitchHookFieldProps, type SwitchProps, } from './fields';
10
+ export { TextInputHookField, type TextInputHookFieldProps, SelectHookField, type SelectHookFieldProps, CheckboxHookField, type CheckboxHookFieldProps, NumberInputHookField, type NumberInputHookFieldProps, DatePickerHookField, type DatePickerHookFieldProps, RadioGroupHookField, type RadioGroupHookFieldProps, type SharedFieldLayoutProps, type SharedHorizontalFieldLayoutProps, type TextInputProps, type SelectProps, type SelectOption, type CheckboxProps, type NumberInputProps, type DatePickerProps, type RadioGroupProps, type RadioGroupOption, SwitchHookField, type SwitchHookFieldProps, type SwitchProps, } from './fields';
@@ -1717,6 +1717,21 @@
1717
1717
  "employeeId"
1718
1718
  ]
1719
1719
  },
1720
+ "EmployeeOnboarding.EmployeeDocuments": {
1721
+ "endpoints": [
1722
+ {
1723
+ "method": "GET",
1724
+ "path": "/v1/employees/:employeeId"
1725
+ },
1726
+ {
1727
+ "method": "PUT",
1728
+ "path": "/v1/employees/:employeeId/onboarding_documents_config"
1729
+ }
1730
+ ],
1731
+ "variables": [
1732
+ "employeeId"
1733
+ ]
1734
+ },
1720
1735
  "EmployeeOnboarding.Profile": {
1721
1736
  "endpoints": [
1722
1737
  {
@@ -1901,21 +1916,6 @@
1901
1916
  "employeeId"
1902
1917
  ]
1903
1918
  },
1904
- "EmployeeManagement.EmployeeDocuments": {
1905
- "endpoints": [
1906
- {
1907
- "method": "GET",
1908
- "path": "/v1/employees/:employeeId"
1909
- },
1910
- {
1911
- "method": "PUT",
1912
- "path": "/v1/employees/:employeeId/onboarding_documents_config"
1913
- }
1914
- ],
1915
- "variables": [
1916
- "employeeId"
1917
- ]
1918
- },
1919
1919
  "EmployeeManagement.Documents": {
1920
1920
  "endpoints": [
1921
1921
  {
@@ -2666,10 +2666,10 @@
2666
2666
  },
2667
2667
  "EmployeeOnboarding.OnboardingExecutionFlow": {
2668
2668
  "blocks": [
2669
- "Employee.EmployeeDocuments",
2670
2669
  "Employee.PaymentMethod",
2671
2670
  "EmployeeOnboarding.Compensation",
2672
2671
  "EmployeeOnboarding.Deductions",
2672
+ "EmployeeOnboarding.EmployeeDocuments",
2673
2673
  "EmployeeOnboarding.FederalTaxes",
2674
2674
  "EmployeeOnboarding.OnboardingSummary",
2675
2675
  "EmployeeOnboarding.Profile",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gusto/embedded-react-sdk",
3
- "version": "0.47.0",
3
+ "version": "0.47.1",
4
4
  "homepage": "https://github.com/Gusto/embedded-react-sdk",
5
5
  "bugs": {
6
6
  "url": "https://github.com/Gusto/embedded-react-sdk/issues"
@@ -92,11 +92,11 @@
92
92
  "@commitlint/cli": "^21.0.2",
93
93
  "@commitlint/config-conventional": "^21.0.2",
94
94
  "@eslint/js": "^9.39.2",
95
- "@microsoft/api-extractor": "^7.58.7",
95
+ "@microsoft/api-extractor": "^7.58.8",
96
96
  "@playwright/test": "^1.60.0",
97
97
  "@release-it/conventional-changelog": "^11.0.1",
98
98
  "@storybook/addon-a11y": "^10.4.2",
99
- "@storybook/addon-docs": "^10.4.1",
99
+ "@storybook/addon-docs": "^10.4.2",
100
100
  "@storybook/addon-onboarding": "^10.4.2",
101
101
  "@storybook/react-vite": "^10.4.2",
102
102
  "@storybook/test-runner": "^0.24.4",
@@ -109,8 +109,9 @@
109
109
  "@types/pngjs": "^6.0.5",
110
110
  "@types/react": "^19.2.16",
111
111
  "@types/react-dom": "^19.2.3",
112
- "@typescript-eslint/rule-tester": "^8.60.1",
113
- "@typescript-eslint/utils": "^8.60.0",
112
+ "@typescript-eslint/parser": "^8.61.0",
113
+ "@typescript-eslint/rule-tester": "^8.61.0",
114
+ "@typescript-eslint/utils": "^8.61.0",
114
115
  "@vitejs/plugin-react-swc": "^4.3.1",
115
116
  "@vitest/coverage-v8": "^4.1.8",
116
117
  "ajv": "^8.20.0",
@@ -147,7 +148,7 @@
147
148
  "stylelint-config-standard": "^40.0.0",
148
149
  "ts-morph": "^28.0.0",
149
150
  "tsx": "^4.22.4",
150
- "typescript-eslint": "^8.60.1",
151
+ "typescript-eslint": "^8.61.0",
151
152
  "vite": "^6.4.3",
152
153
  "vite-plugin-checker": "^0.14.1",
153
154
  "vite-plugin-circular-dependency": "^0.6.0",