@justifi/webcomponents 5.3.5 → 5.3.6

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 (415) hide show
  1. package/dist/cjs/{SubAccount-f9069337.js → SubAccount-df3d28dc.js} +3 -3
  2. package/dist/cjs/additional-questions-details_5.cjs.entry.js +2 -2
  3. package/dist/cjs/{badge-6abf6ed3.js → badge-79e56b99.js} +1 -1
  4. package/dist/cjs/bank-account-document-form-inputs_4.cjs.entry.js +6 -6
  5. package/dist/cjs/bank-account-form_9.cjs.entry.js +4 -4
  6. package/dist/cjs/billing-form_3.cjs.entry.js +6 -6
  7. package/dist/cjs/business-details-core.cjs.entry.js +3 -3
  8. package/dist/cjs/{button-aed2ce1a.js → button-797bb3cc.js} +1 -1
  9. package/dist/cjs/{Analytics-e91a5523.js → check-pkg-version-1f8b660c.js} +21 -1
  10. package/dist/cjs/{checkout.service-0643396e.js → checkout.service-c01e2cd7.js} +1 -1
  11. package/dist/cjs/checkouts-list-core.cjs.entry.js +8 -9
  12. package/dist/cjs/{checkouts-table-f88ad3c8.js → checkouts-table-61543249.js} +2 -2
  13. package/dist/cjs/custom-popper.cjs.entry.js +2 -2
  14. package/dist/cjs/{dispute.service-53c80520.js → dispute.service-399de502.js} +1 -1
  15. package/dist/cjs/{table-ad35ff09.js → event-types-666f1f22.js} +9 -2
  16. package/dist/cjs/form-alert_5.cjs.entry.js +1 -1
  17. package/dist/cjs/form-control-checkbox.cjs.entry.js +5 -5
  18. package/dist/cjs/form-control-date.cjs.entry.js +4 -4
  19. package/dist/cjs/{form-control-error-text-74fb8498.js → form-control-error-text-b782cdd0.js} +1 -1
  20. package/dist/cjs/form-control-file-v2_2.cjs.entry.js +5 -5
  21. package/dist/cjs/{form-control-help-text-3cffd918.js → form-control-help-text-ca3c8155.js} +1 -1
  22. package/dist/cjs/form-control-monetary.cjs.entry.js +5 -5
  23. package/dist/cjs/form-control-number-masked_2.cjs.entry.js +4 -4
  24. package/dist/cjs/form-control-number.cjs.entry.js +5 -5
  25. package/dist/cjs/form-control-radio.cjs.entry.js +3 -3
  26. package/dist/cjs/form-control-select_3.cjs.entry.js +4 -4
  27. package/dist/cjs/{get-payout-csv-bdd7d9c0.js → get-payout-csv-11a983a0.js} +1 -1
  28. package/dist/cjs/{get-subaccounts-40c4a0b6.js → get-subaccounts-224f9497.js} +1 -1
  29. package/dist/cjs/gross-payment-chart-core.cjs.entry.js +3 -3
  30. package/dist/cjs/{header-1-cc98bae2.js → header-1-ff669f3f.js} +1 -1
  31. package/dist/cjs/{header-3-05ce2ad0.js → header-3-f6642390.js} +1 -1
  32. package/dist/cjs/{insurance-state-211cd636.js → insurance-state-66c9bea7.js} +1 -1
  33. package/dist/cjs/justifi-additional-questions-form-step-core_6.cjs.entry.js +4 -4
  34. package/dist/cjs/justifi-additional-questions-form-step_9.cjs.entry.js +3 -3
  35. package/dist/cjs/justifi-additional-statement_8.cjs.entry.js +1 -1
  36. package/dist/cjs/justifi-business-details.cjs.entry.js +5 -6
  37. package/dist/cjs/justifi-business-form.cjs.entry.js +8 -9
  38. package/dist/cjs/justifi-business-representative-form-inputs.cjs.entry.js +1 -1
  39. package/dist/cjs/justifi-checkout-core.cjs.entry.js +5 -5
  40. package/dist/cjs/justifi-checkout.cjs.entry.js +6 -7
  41. package/dist/cjs/justifi-checkouts-list-filters.cjs.entry.js +2 -2
  42. package/dist/cjs/justifi-checkouts-list.cjs.entry.js +9 -10
  43. package/dist/cjs/justifi-details.cjs.entry.js +2 -2
  44. package/dist/cjs/justifi-dispute-management.cjs.entry.js +5 -6
  45. package/dist/cjs/justifi-dispute-notification_3.cjs.entry.js +8 -9
  46. package/dist/cjs/justifi-gross-payment-chart.cjs.entry.js +5 -6
  47. package/dist/cjs/justifi-order-terminals.cjs.entry.js +106 -53
  48. package/dist/cjs/justifi-owner-form_3.cjs.entry.js +2 -2
  49. package/dist/cjs/justifi-payment-details.cjs.entry.js +7 -8
  50. package/dist/cjs/justifi-payment-provisioning-core.cjs.entry.js +4 -4
  51. package/dist/cjs/justifi-payment-provisioning.cjs.entry.js +3 -4
  52. package/dist/cjs/justifi-payments-list-filters.cjs.entry.js +3 -3
  53. package/dist/cjs/justifi-payments-list.cjs.entry.js +10 -11
  54. package/dist/cjs/justifi-payout-details.cjs.entry.js +7 -8
  55. package/dist/cjs/justifi-payouts-list-filters.cjs.entry.js +3 -3
  56. package/dist/cjs/justifi-payouts-list.cjs.entry.js +11 -12
  57. package/dist/cjs/justifi-refund-form.cjs.entry.js +2 -2
  58. package/dist/cjs/justifi-season-interruption-insurance-core.cjs.entry.js +3 -3
  59. package/dist/cjs/justifi-season-interruption-insurance.cjs.entry.js +4 -5
  60. package/dist/cjs/justifi-terminal-orders-list.cjs.entry.js +78 -14
  61. package/dist/cjs/justifi-terminals-list-filters.cjs.entry.js +3 -3
  62. package/dist/cjs/justifi-terminals-list.cjs.entry.js +10 -11
  63. package/dist/cjs/justifi-tokenize-payment-method.cjs.entry.js +8 -9
  64. package/dist/cjs/loader.cjs.js +1 -1
  65. package/dist/cjs/{package-82b16c28.js → package-d34fcfa5.js} +1 -1
  66. package/dist/cjs/pagination-menu.cjs.entry.js +1 -1
  67. package/dist/cjs/{parts-63f60e81.js → parts-1fb925c2.js} +0 -5
  68. package/dist/cjs/payment-details-core.cjs.entry.js +12 -12
  69. package/dist/cjs/{payment.service-23b0dcb8.js → payment.service-f369b33c.js} +1 -1
  70. package/dist/cjs/payments-list-core.cjs.entry.js +9 -10
  71. package/dist/cjs/{payments-status-b9192db7.js → payments-status-ffdc54ff.js} +1 -1
  72. package/dist/cjs/{payments-table-dba2f145.js → payments-table-98b4e5e3.js} +2 -2
  73. package/dist/cjs/payout-details-core.cjs.entry.js +7 -7
  74. package/dist/cjs/payouts-list-core.cjs.entry.js +9 -10
  75. package/dist/cjs/{payouts-status-385a794d.js → payouts-status-64fd0c68.js} +1 -1
  76. package/dist/cjs/{payouts-table-8cd537de.js → payouts-table-ecfb826b.js} +2 -2
  77. package/dist/cjs/{skeleton-65afa2f5.js → skeleton-2ae76f16.js} +1 -1
  78. package/dist/cjs/{spinner-a95e9b8d.js → spinner-15764f3c.js} +1 -1
  79. package/dist/cjs/table-filters-menu.cjs.entry.js +2 -2
  80. package/dist/cjs/terminal-orders-list-core.cjs.entry.js +31 -64
  81. package/dist/cjs/{terminal-orders-table-8baa5461.js → terminal-orders-table-f1bed365.js} +8 -3
  82. package/dist/cjs/terminal-quantity-selector.cjs.entry.js +2 -2
  83. package/dist/cjs/{terminal.service-2f41898f.js → terminal.service-4fd34835.js} +6 -1
  84. package/dist/cjs/terminals-list-core.cjs.entry.js +8 -9
  85. package/dist/cjs/{terminals-table-c4c01dc3.js → terminals-table-30298ce4.js} +2 -2
  86. package/dist/cjs/{utils-f752bd45.js → utils-3e3b8061.js} +1 -1
  87. package/dist/cjs/webcomponents.cjs.js +1 -1
  88. package/dist/collection/actions/terminal/get-terminal-orders.js +34 -0
  89. package/dist/collection/actions/terminal/order-terminals.js +29 -0
  90. package/dist/collection/api/TerminalOrder.js +2 -2
  91. package/dist/collection/api/services/terminal.service.js +5 -0
  92. package/dist/collection/api/services/terminal_orders.service.js +9 -0
  93. package/dist/collection/collection-manifest.json +1 -1
  94. package/dist/collection/components/business-forms/payment-provisioning/payment-provisioning-core.js +2 -2
  95. package/dist/collection/components/order-terminals/order-terminals-loading.js +1 -1
  96. package/dist/collection/components/order-terminals/order-terminals.js +109 -48
  97. package/dist/collection/components/{terminal-quantity-selector → order-terminals/terminal-quantity-selector}/terminal-quantity-selector-loading.js +1 -1
  98. package/dist/collection/components/{terminal-quantity-selector → order-terminals/terminal-quantity-selector}/terminal-quantity-selector.js +4 -4
  99. package/dist/collection/components/payment-details/payment-details-core.js +7 -7
  100. package/dist/collection/components/payments-list/payments-list-core.js +1 -1
  101. package/dist/collection/components/payments-list/payments-list-filters.js +2 -2
  102. package/dist/collection/components/payments-list/payments-list.js +1 -1
  103. package/dist/collection/components/payout-details/payout-details-core.js +1 -1
  104. package/dist/collection/components/payouts-list/payouts-list-core.js +1 -1
  105. package/dist/collection/components/payouts-list/payouts-list-filters.js +2 -2
  106. package/dist/collection/components/payouts-list/payouts-list.js +1 -1
  107. package/dist/collection/components/refund-form/refund-form.js +1 -1
  108. package/dist/collection/components/terminal-orders-list/terminal-order-status.js +6 -1
  109. package/dist/collection/components/terminal-orders-list/terminal-orders-list-core.js +54 -9
  110. package/dist/collection/components/terminal-orders-list/terminal-orders-list.js +52 -11
  111. package/dist/collection/components/terminals-list/terminals-list-core.js +1 -1
  112. package/dist/collection/components/terminals-list/terminals-list-filters.js +1 -1
  113. package/dist/collection/components/terminals-list/terminals-list.js +1 -1
  114. package/dist/collection/components/tokenize-payment-method/tokenize-payment-method.js +1 -1
  115. package/dist/collection/ui-components/custom-popper/custom-popper.js +2 -2
  116. package/dist/collection/ui-components/form/form-control-checkbox.js +2 -2
  117. package/dist/collection/ui-components/form/form-control-date.js +2 -2
  118. package/dist/collection/ui-components/form/form-control-file-v2.js +1 -1
  119. package/dist/collection/ui-components/form/form-control-file.js +2 -2
  120. package/dist/collection/ui-components/form/form-control-monetary.js +2 -2
  121. package/dist/collection/ui-components/form/form-control-number-masked.js +2 -2
  122. package/dist/collection/ui-components/form/form-control-number.js +2 -2
  123. package/dist/collection/ui-components/form/form-control-radio.js +2 -2
  124. package/dist/collection/ui-components/form/form-control-text.js +2 -2
  125. package/dist/collection/ui-components/form/form-control-textarea.js +2 -2
  126. package/dist/collection/ui-components/form/hidden-input.js +1 -1
  127. package/dist/collection/ui-components/form/iframe-input.js +3 -3
  128. package/dist/docs.json +106 -18
  129. package/dist/esm/{SubAccount-f31bdeb4.js → SubAccount-dbd4e50c.js} +2 -2
  130. package/dist/esm/additional-questions-details_5.entry.js +2 -2
  131. package/dist/esm/{badge-7768a2b1.js → badge-6f5acf30.js} +1 -1
  132. package/dist/esm/bank-account-document-form-inputs_4.entry.js +6 -6
  133. package/dist/esm/bank-account-form_9.entry.js +4 -4
  134. package/dist/esm/billing-form_3.entry.js +6 -6
  135. package/dist/esm/business-details-core.entry.js +3 -3
  136. package/dist/esm/{button-b3d07089.js → button-79dcea75.js} +1 -1
  137. package/dist/esm/{Analytics-d0f79dc3.js → check-pkg-version-8e7e585e.js} +21 -2
  138. package/dist/esm/{checkout.service-020aaf97.js → checkout.service-382a16ec.js} +1 -1
  139. package/dist/esm/checkouts-list-core.entry.js +6 -7
  140. package/dist/esm/{checkouts-table-974c57ba.js → checkouts-table-8a53cef9.js} +2 -2
  141. package/dist/esm/custom-popper.entry.js +2 -2
  142. package/dist/esm/{dispute.service-b234b5c7.js → dispute.service-97887804.js} +1 -1
  143. package/dist/esm/{table-03e4dfc0.js → event-types-82515a49.js} +10 -3
  144. package/dist/esm/form-alert_5.entry.js +1 -1
  145. package/dist/esm/form-control-checkbox.entry.js +5 -5
  146. package/dist/esm/form-control-date.entry.js +4 -4
  147. package/dist/esm/{form-control-error-text-923afdfa.js → form-control-error-text-466c252b.js} +1 -1
  148. package/dist/esm/form-control-file-v2_2.entry.js +5 -5
  149. package/dist/esm/{form-control-help-text-c7bdd493.js → form-control-help-text-242916e3.js} +1 -1
  150. package/dist/esm/form-control-monetary.entry.js +5 -5
  151. package/dist/esm/form-control-number-masked_2.entry.js +4 -4
  152. package/dist/esm/form-control-number.entry.js +5 -5
  153. package/dist/esm/form-control-radio.entry.js +3 -3
  154. package/dist/esm/form-control-select_3.entry.js +4 -4
  155. package/dist/esm/{get-payout-csv-9528b0a2.js → get-payout-csv-6826271a.js} +1 -1
  156. package/dist/esm/{get-subaccounts-212c162d.js → get-subaccounts-f21220dc.js} +1 -1
  157. package/dist/esm/gross-payment-chart-core.entry.js +3 -3
  158. package/dist/esm/{header-1-649109a3.js → header-1-b43590e5.js} +1 -1
  159. package/dist/esm/{header-3-ca7bb57b.js → header-3-b90e161e.js} +1 -1
  160. package/dist/esm/{insurance-state-e3b48bb2.js → insurance-state-9e4a3359.js} +1 -1
  161. package/dist/esm/justifi-additional-questions-form-step-core_6.entry.js +4 -4
  162. package/dist/esm/justifi-additional-questions-form-step_9.entry.js +3 -3
  163. package/dist/esm/justifi-additional-statement_8.entry.js +1 -1
  164. package/dist/esm/justifi-business-details.entry.js +4 -5
  165. package/dist/esm/justifi-business-form.entry.js +7 -8
  166. package/dist/esm/justifi-business-representative-form-inputs.entry.js +1 -1
  167. package/dist/esm/justifi-checkout-core.entry.js +5 -5
  168. package/dist/esm/justifi-checkout.entry.js +5 -6
  169. package/dist/esm/justifi-checkouts-list-filters.entry.js +2 -2
  170. package/dist/esm/justifi-checkouts-list.entry.js +8 -9
  171. package/dist/esm/justifi-details.entry.js +2 -2
  172. package/dist/esm/justifi-dispute-management.entry.js +4 -5
  173. package/dist/esm/justifi-dispute-notification_3.entry.js +7 -8
  174. package/dist/esm/justifi-gross-payment-chart.entry.js +4 -5
  175. package/dist/esm/justifi-order-terminals.entry.js +105 -52
  176. package/dist/esm/justifi-owner-form_3.entry.js +2 -2
  177. package/dist/esm/justifi-payment-details.entry.js +6 -7
  178. package/dist/esm/justifi-payment-provisioning-core.entry.js +4 -4
  179. package/dist/esm/justifi-payment-provisioning.entry.js +2 -3
  180. package/dist/esm/justifi-payments-list-filters.entry.js +3 -3
  181. package/dist/esm/justifi-payments-list.entry.js +9 -10
  182. package/dist/esm/justifi-payout-details.entry.js +6 -7
  183. package/dist/esm/justifi-payouts-list-filters.entry.js +3 -3
  184. package/dist/esm/justifi-payouts-list.entry.js +10 -11
  185. package/dist/esm/justifi-refund-form.entry.js +2 -2
  186. package/dist/esm/justifi-season-interruption-insurance-core.entry.js +3 -3
  187. package/dist/esm/justifi-season-interruption-insurance.entry.js +3 -4
  188. package/dist/esm/justifi-terminal-orders-list.entry.js +79 -15
  189. package/dist/esm/justifi-terminals-list-filters.entry.js +3 -3
  190. package/dist/esm/justifi-terminals-list.entry.js +9 -10
  191. package/dist/esm/justifi-tokenize-payment-method.entry.js +7 -8
  192. package/dist/esm/loader.js +1 -1
  193. package/dist/esm/{package-b9d805ae.js → package-46c7f3a6.js} +1 -1
  194. package/dist/esm/pagination-menu.entry.js +1 -1
  195. package/dist/esm/{parts-18c966b1.js → parts-2c5c609b.js} +1 -4
  196. package/dist/esm/payment-details-core.entry.js +12 -12
  197. package/dist/esm/{payment.service-81752187.js → payment.service-a8aa5be7.js} +1 -1
  198. package/dist/esm/payments-list-core.entry.js +8 -9
  199. package/dist/esm/{payments-status-f451caf6.js → payments-status-6e203ce4.js} +1 -1
  200. package/dist/esm/{payments-table-a7836555.js → payments-table-4c6093e1.js} +2 -2
  201. package/dist/esm/payout-details-core.entry.js +7 -7
  202. package/dist/esm/payouts-list-core.entry.js +8 -9
  203. package/dist/esm/{payouts-status-bfae9f42.js → payouts-status-66e830f1.js} +1 -1
  204. package/dist/esm/{payouts-table-55f1a8a3.js → payouts-table-46fbedb6.js} +2 -2
  205. package/dist/esm/{skeleton-ca37b248.js → skeleton-122648e6.js} +1 -1
  206. package/dist/esm/{spinner-30abb9b0.js → spinner-14cd9ac7.js} +1 -1
  207. package/dist/esm/table-filters-menu.entry.js +2 -2
  208. package/dist/esm/terminal-orders-list-core.entry.js +30 -63
  209. package/dist/esm/{terminal-orders-table-a340c409.js → terminal-orders-table-83b905fd.js} +8 -3
  210. package/dist/esm/terminal-quantity-selector.entry.js +2 -2
  211. package/dist/esm/{terminal.service-3c3f2c3f.js → terminal.service-20445fc1.js} +6 -1
  212. package/dist/esm/terminals-list-core.entry.js +7 -8
  213. package/dist/esm/{terminals-table-88549e54.js → terminals-table-dbbf9a99.js} +2 -2
  214. package/dist/esm/{utils-e7df4815.js → utils-4cb0d852.js} +1 -1
  215. package/dist/esm/webcomponents.js +1 -1
  216. package/dist/module/SubAccount.js +2 -2
  217. package/dist/module/check-pkg-version.js +80 -1
  218. package/dist/module/checkouts-list-core2.js +1 -2
  219. package/dist/module/custom-popper2.js +2 -2
  220. package/dist/module/dispute-response.js +1 -2
  221. package/dist/module/event-types2.js +55 -1
  222. package/dist/module/form-control-checkbox2.js +2 -2
  223. package/dist/module/form-control-date2.js +2 -2
  224. package/dist/module/form-control-file-v22.js +1 -1
  225. package/dist/module/form-control-file2.js +2 -2
  226. package/dist/module/form-control-monetary2.js +2 -2
  227. package/dist/module/form-control-number-masked2.js +2 -2
  228. package/dist/module/form-control-number.js +2 -2
  229. package/dist/module/form-control-radio2.js +2 -2
  230. package/dist/module/form-control-text2.js +2 -2
  231. package/dist/module/form-control-textarea2.js +2 -2
  232. package/dist/module/hidden-input2.js +1 -1
  233. package/dist/module/iframe-input2.js +3 -3
  234. package/dist/module/justifi-business-details.js +1 -2
  235. package/dist/module/justifi-business-form.js +1 -2
  236. package/dist/module/justifi-checkout.js +2 -3
  237. package/dist/module/justifi-checkouts-list.js +1 -2
  238. package/dist/module/justifi-dispute-management.js +1 -2
  239. package/dist/module/justifi-gross-payment-chart.js +1 -2
  240. package/dist/module/justifi-order-terminals.js +105 -51
  241. package/dist/module/justifi-payment-details.js +1 -2
  242. package/dist/module/justifi-payment-provisioning.js +1 -2
  243. package/dist/module/justifi-payments-list-filters.js +3 -3
  244. package/dist/module/justifi-payments-list.js +2 -3
  245. package/dist/module/justifi-payout-details.js +1 -2
  246. package/dist/module/justifi-payouts-list-filters.js +3 -3
  247. package/dist/module/justifi-payouts-list.js +2 -3
  248. package/dist/module/justifi-refund-form.js +1 -1
  249. package/dist/module/justifi-season-interruption-insurance.js +1 -2
  250. package/dist/module/justifi-terminal-orders-list.js +75 -12
  251. package/dist/module/justifi-terminals-list-filters.js +2 -2
  252. package/dist/module/justifi-terminals-list.js +3 -4
  253. package/dist/module/justifi-tokenize-payment-method.js +3 -4
  254. package/dist/module/package.js +1 -1
  255. package/dist/module/parts.js +1 -4
  256. package/dist/module/payment-details-core2.js +7 -7
  257. package/dist/module/payment-provisioning-core.js +2 -2
  258. package/dist/module/payments-list-core2.js +2 -3
  259. package/dist/module/payout-details-core2.js +1 -1
  260. package/dist/module/payouts-list-core2.js +2 -3
  261. package/dist/module/terminal-orders-list-core2.js +31 -59
  262. package/dist/module/terminal-quantity-selector2.js +2 -2
  263. package/dist/module/terminal.service.js +5 -0
  264. package/dist/module/terminals-list-core2.js +2 -3
  265. package/dist/types/actions/terminal/get-terminal-orders.d.ts +11 -0
  266. package/dist/types/actions/terminal/order-terminals.d.ts +8 -0
  267. package/dist/types/api/TerminalOrder.d.ts +2 -2
  268. package/dist/types/api/services/terminal.service.d.ts +2 -0
  269. package/dist/types/api/services/terminal_orders.service.d.ts +7 -0
  270. package/dist/types/components/business-forms/payment-provisioning/payment-provisioning-core.d.ts +0 -1
  271. package/dist/types/components/order-terminals/order-terminals.d.ts +20 -3
  272. package/dist/types/components/{terminal-quantity-selector → order-terminals/terminal-quantity-selector}/terminal-quantity-selector.d.ts +2 -2
  273. package/dist/types/components/terminal-orders-list/terminal-orders-list-core.d.ts +3 -2
  274. package/dist/types/components/terminal-orders-list/terminal-orders-list.d.ts +8 -2
  275. package/dist/types/components.d.ts +28 -6
  276. package/dist/webcomponents/{p-1e3cc191.entry.js → p-0137575f.entry.js} +1 -1
  277. package/dist/webcomponents/{p-4a580682.entry.js → p-030a8806.entry.js} +1 -1
  278. package/dist/webcomponents/p-039a09b8.entry.js +1 -0
  279. package/dist/webcomponents/{p-dd535097.js → p-046ecd01.js} +1 -1
  280. package/dist/webcomponents/{p-3744006f.js → p-087758d3.js} +1 -1
  281. package/dist/webcomponents/{p-adf30888.entry.js → p-0a60d356.entry.js} +1 -1
  282. package/dist/webcomponents/p-0ba77d53.entry.js +1 -0
  283. package/dist/webcomponents/p-0c22225c.entry.js +1 -0
  284. package/dist/webcomponents/{p-566883fb.entry.js → p-0cefd846.entry.js} +1 -1
  285. package/dist/webcomponents/{p-ec3f9d80.entry.js → p-10a14943.entry.js} +1 -1
  286. package/dist/webcomponents/p-10e32428.entry.js +1 -0
  287. package/dist/webcomponents/p-1705af62.js +1 -0
  288. package/dist/webcomponents/{p-0ef25316.entry.js → p-19b8c3c8.entry.js} +1 -1
  289. package/dist/webcomponents/{p-7d43c1d6.entry.js → p-1a48d917.entry.js} +1 -1
  290. package/dist/webcomponents/{p-913d51b9.js → p-1e300d41.js} +1 -1
  291. package/dist/webcomponents/p-2027145a.entry.js +1 -0
  292. package/dist/webcomponents/p-222fa126.entry.js +1 -0
  293. package/dist/webcomponents/{p-6501cb6e.entry.js → p-33a17e80.entry.js} +1 -1
  294. package/dist/webcomponents/p-34e18d17.entry.js +1 -0
  295. package/dist/webcomponents/{p-54502491.entry.js → p-36edba41.entry.js} +1 -1
  296. package/dist/webcomponents/{p-4c4a2c48.js → p-3732aa87.js} +1 -1
  297. package/dist/webcomponents/p-382ab4e8.js +1 -0
  298. package/dist/webcomponents/p-3947a309.entry.js +1 -0
  299. package/dist/webcomponents/p-3cbdca1b.js +1 -0
  300. package/dist/webcomponents/{p-b075211e.entry.js → p-4d5c553d.entry.js} +1 -1
  301. package/dist/webcomponents/{p-b40bcf59.js → p-547b51e9.js} +1 -1
  302. package/dist/webcomponents/p-5ee67fad.js +1 -0
  303. package/dist/webcomponents/p-5efe9572.entry.js +1 -0
  304. package/dist/webcomponents/p-638b91ff.entry.js +1 -0
  305. package/dist/webcomponents/{p-7dc34297.entry.js → p-685c7028.entry.js} +1 -1
  306. package/dist/webcomponents/{p-9ffed802.js → p-694078d2.js} +1 -1
  307. package/dist/webcomponents/p-69ac2640.entry.js +1 -0
  308. package/dist/webcomponents/p-6a2d6298.entry.js +1 -0
  309. package/dist/webcomponents/{p-0a271654.entry.js → p-6ef3de11.entry.js} +1 -1
  310. package/dist/webcomponents/p-71897cbc.js +1 -0
  311. package/dist/webcomponents/{p-1a9d60b1.entry.js → p-759f25a1.entry.js} +1 -1
  312. package/dist/webcomponents/p-7dc9fb75.js +1 -0
  313. package/dist/webcomponents/{p-c1af1fdb.entry.js → p-7e93eac9.entry.js} +1 -1
  314. package/dist/webcomponents/p-7ed52fbc.entry.js +1 -0
  315. package/dist/webcomponents/{p-77245638.js → p-8066b866.js} +1 -1
  316. package/dist/webcomponents/p-830f0971.entry.js +1 -0
  317. package/dist/webcomponents/{p-d37d20ca.entry.js → p-833ef79e.entry.js} +1 -1
  318. package/dist/webcomponents/p-8971f9da.entry.js +1 -0
  319. package/dist/webcomponents/p-8c461ebc.entry.js +1 -0
  320. package/dist/webcomponents/p-8fad4359.entry.js +1 -0
  321. package/dist/webcomponents/{p-69ae193c.js → p-9dc9aaba.js} +1 -1
  322. package/dist/webcomponents/{p-8548d8de.js → p-9f1a3199.js} +1 -1
  323. package/dist/webcomponents/{p-f48dd1ef.entry.js → p-a07afdcc.entry.js} +1 -1
  324. package/dist/webcomponents/p-a173ccd5.entry.js +1 -0
  325. package/dist/webcomponents/p-a3d75257.js +1 -0
  326. package/dist/webcomponents/p-a957612b.entry.js +1 -0
  327. package/dist/webcomponents/p-aa21cdb1.entry.js +1 -0
  328. package/dist/webcomponents/p-aa923138.entry.js +1 -0
  329. package/dist/webcomponents/p-ad473d5c.entry.js +1 -0
  330. package/dist/webcomponents/p-b11468b5.entry.js +1 -0
  331. package/dist/webcomponents/{p-d019b800.js → p-b5addd78.js} +1 -1
  332. package/dist/webcomponents/p-b62403c2.entry.js +1 -0
  333. package/dist/webcomponents/{p-6776df16.js → p-b69beb1c.js} +1 -1
  334. package/dist/webcomponents/p-b76f755a.entry.js +1 -0
  335. package/dist/webcomponents/{p-834c12a0.entry.js → p-b8ee505d.entry.js} +1 -1
  336. package/dist/webcomponents/p-b92aac9b.entry.js +1 -0
  337. package/dist/webcomponents/{p-420d6572.entry.js → p-b92f125b.entry.js} +1 -1
  338. package/dist/webcomponents/{p-57ddf983.entry.js → p-bd2340f7.entry.js} +1 -1
  339. package/dist/webcomponents/{p-121e9167.entry.js → p-bd2d9d29.entry.js} +1 -1
  340. package/dist/webcomponents/p-bdf0ab42.js +1 -0
  341. package/dist/webcomponents/{p-f1580c62.js → p-c406c0fa.js} +1 -1
  342. package/dist/webcomponents/{p-808f61aa.js → p-c54f54ed.js} +1 -1
  343. package/dist/webcomponents/p-c5cc443e.entry.js +1 -0
  344. package/dist/webcomponents/p-cd68707b.entry.js +1 -0
  345. package/dist/webcomponents/p-d5a481e4.entry.js +1 -0
  346. package/dist/webcomponents/p-e366ef1e.js +1 -0
  347. package/dist/webcomponents/p-e400e31f.entry.js +1 -0
  348. package/dist/webcomponents/{p-49fc12b2.entry.js → p-e4514af8.entry.js} +1 -1
  349. package/dist/webcomponents/{p-66cdd475.js → p-e60867c6.js} +1 -1
  350. package/dist/webcomponents/{p-4014d084.entry.js → p-e754d8e7.entry.js} +1 -1
  351. package/dist/webcomponents/p-eb05bd1e.entry.js +1 -0
  352. package/dist/webcomponents/p-ede13cc8.js +1 -0
  353. package/dist/webcomponents/{p-ca19fd2e.js → p-ee9d433f.js} +1 -1
  354. package/dist/webcomponents/{p-29988e8f.entry.js → p-f04dbd80.entry.js} +1 -1
  355. package/dist/webcomponents/p-f2111e68.js +1 -0
  356. package/dist/webcomponents/p-f3061f2a.entry.js +1 -0
  357. package/dist/webcomponents/{p-930e2e05.js → p-fa987dcf.js} +1 -1
  358. package/dist/webcomponents/{p-348fc9b1.js → p-fae67ab3.js} +1 -1
  359. package/dist/webcomponents/p-fd4607f9.entry.js +1 -0
  360. package/dist/webcomponents/{p-ffbd95d0.entry.js → p-ffd0c24b.entry.js} +1 -1
  361. package/dist/webcomponents/webcomponents.esm.js +1 -1
  362. package/package.json +1 -1
  363. package/dist/cjs/check-pkg-version-d19c6fdb.js +0 -24
  364. package/dist/cjs/event-types-b6d34593.js +0 -8
  365. package/dist/esm/check-pkg-version-2e9f961e.js +0 -22
  366. package/dist/esm/event-types-0a83d0b4.js +0 -8
  367. package/dist/module/Analytics.js +0 -82
  368. package/dist/module/table.js +0 -55
  369. package/dist/webcomponents/p-0ef50c81.js +0 -1
  370. package/dist/webcomponents/p-0f85fde5.entry.js +0 -1
  371. package/dist/webcomponents/p-0faaae79.entry.js +0 -1
  372. package/dist/webcomponents/p-140836f1.entry.js +0 -1
  373. package/dist/webcomponents/p-1d019dda.entry.js +0 -1
  374. package/dist/webcomponents/p-1f99a902.js +0 -1
  375. package/dist/webcomponents/p-1fcde0de.entry.js +0 -1
  376. package/dist/webcomponents/p-229c841e.entry.js +0 -1
  377. package/dist/webcomponents/p-2481c1d3.entry.js +0 -1
  378. package/dist/webcomponents/p-31507b3a.entry.js +0 -1
  379. package/dist/webcomponents/p-36060c36.entry.js +0 -1
  380. package/dist/webcomponents/p-418ab812.entry.js +0 -1
  381. package/dist/webcomponents/p-45bed1b7.js +0 -1
  382. package/dist/webcomponents/p-4bb0d6fd.js +0 -1
  383. package/dist/webcomponents/p-4f9a2f1f.js +0 -1
  384. package/dist/webcomponents/p-55a6599a.entry.js +0 -1
  385. package/dist/webcomponents/p-5bf5f7d7.entry.js +0 -1
  386. package/dist/webcomponents/p-5dc767d8.js +0 -1
  387. package/dist/webcomponents/p-6815a6cb.entry.js +0 -1
  388. package/dist/webcomponents/p-76d1036b.entry.js +0 -1
  389. package/dist/webcomponents/p-77e3ed67.js +0 -1
  390. package/dist/webcomponents/p-7e4c84f7.entry.js +0 -1
  391. package/dist/webcomponents/p-867e34b8.entry.js +0 -1
  392. package/dist/webcomponents/p-8a3f1a56.entry.js +0 -1
  393. package/dist/webcomponents/p-8a9debac.entry.js +0 -1
  394. package/dist/webcomponents/p-8b3842ce.js +0 -1
  395. package/dist/webcomponents/p-96a491aa.js +0 -1
  396. package/dist/webcomponents/p-9a6eacd0.entry.js +0 -1
  397. package/dist/webcomponents/p-9d8cf927.entry.js +0 -1
  398. package/dist/webcomponents/p-b0335a17.entry.js +0 -1
  399. package/dist/webcomponents/p-b7a407fb.entry.js +0 -1
  400. package/dist/webcomponents/p-b894423f.js +0 -1
  401. package/dist/webcomponents/p-bc6e3e59.entry.js +0 -1
  402. package/dist/webcomponents/p-bc73a554.entry.js +0 -1
  403. package/dist/webcomponents/p-c17af2a4.entry.js +0 -1
  404. package/dist/webcomponents/p-ca55be58.js +0 -1
  405. package/dist/webcomponents/p-d979d9ea.entry.js +0 -1
  406. package/dist/webcomponents/p-d981a599.entry.js +0 -1
  407. package/dist/webcomponents/p-da415c08.entry.js +0 -1
  408. package/dist/webcomponents/p-e0befd51.js +0 -1
  409. package/dist/webcomponents/p-e7d2eba7.entry.js +0 -1
  410. package/dist/webcomponents/p-e895bc2a.entry.js +0 -1
  411. package/dist/webcomponents/p-ee991c9e.entry.js +0 -1
  412. package/dist/webcomponents/p-fe0399a1.js +0 -1
  413. package/dist/webcomponents/p-fe439eb2.entry.js +0 -1
  414. package/dist/webcomponents/p-fe8be5fa.entry.js +0 -1
  415. /package/dist/types/components/{terminal-quantity-selector → order-terminals/terminal-quantity-selector}/terminal-quantity-selector-loading.d.ts +0 -0
@@ -1 +1 @@
1
- import{r as t,c as s,h as e,H as i,g as a}from"./p-2783e363.js";import{l as o,c as h,b as r,a3 as l,a as c,ag as d,ah as n,ai as f}from"./p-8b3842ce.js";import{F as b}from"./p-77e3ed67.js";const p=class{constructor(e){t(this,e),this.formControlInput=s(this,"formControlInput",7),this.formControlBlur=s(this,"formControlBlur",7),this.handleFormControlInput=t=>{const s=t.target,e=s.getAttribute("name");this.inputHandler(e,s.value),this.formControlInput.emit(s.value)},this.updateInput=t=>{this.selectElement.value=t},this.isFocused=!1,this.name=void 0,this.label=void 0,this.options=void 0,this.inputHandler=void 0,this.defaultValue=void 0,this.helpText=void 0,this.errorText=void 0,this.disabled=void 0}handleDefaultValueChange(t){this.updateInput(t)}componentDidLoad(){this.updateInput(this.defaultValue)}get part(){let t=h;return this.errorText&&(t=r),this.disabled&&(t=l),this.isFocused&&(t=c),t}render(){var t;return e(i,{key:"f55283c73225466b10cec78e6e5ff1c268142d1b"},e("div",{key:"48beb377ca664b867598f8e472a3bb4825aecf9b",class:"form-group d-flex flex-column"},e("div",{key:"13debfb6a725d7f247eb5601e3361a3964b826e9",class:"d-flex align-items-start gap-2"},e("label",{key:"15ac64fb03a5c1cb8f55c18bd7eb41d66328e599",part:o,class:"form-label",htmlFor:this.name},this.label),e("form-control-tooltip",{key:"3d8b43ed6e997234f7c64daf41b2286bec93340e",helpText:this.helpText})),e("select",{key:"1c3eb5699a0b76c694a02fe50e8070483b2960e6",ref:t=>this.selectElement=t,id:this.name,name:this.name,onFocus:()=>this.isFocused=!0,onBlur:()=>{this.isFocused=!1,this.formControlBlur.emit()},onInput:this.handleFormControlInput,part:this.part,class:this.errorText?"form-select is-invalid":"form-select",disabled:this.disabled},null===(t=this.options)||void 0===t?void 0:t.map((t=>e("option",{value:t.value},t.label)))),e(b,{key:"d223fd1fad44de99812b0e3a3429e3931b798c2c",errorText:this.errorText,name:this.name})))}static get watchers(){return{defaultValue:["handleDefaultValueChange"]}}},u=class{constructor(e){t(this,e),this.formControlInput=s(this,"formControlInput",7),this.formControlBlur=s(this,"formControlBlur",7),this.handleFormControlInput=t=>{const s=t.target,e=s.getAttribute("name");this.inputHandler(e,s.value),this.formControlInput.emit({name:e,value:s.value})},this.updateInput=t=>{const s=this.el.querySelector("input");s&&(s.value=t||"")},this.isFocused=!1,this.name=void 0,this.label=void 0,this.inputHandler=void 0,this.defaultValue=void 0,this.helpText=void 0,this.errorText=void 0,this.maxLength=void 0,this.keyDownHandler=void 0,this.disabled=void 0}handleDefaultValueChange(t){this.updateInput(t)}componentDidLoad(){this.updateInput(this.defaultValue)}get part(){return this.errorText?r:this.disabled?l:this.isFocused?c:h}render(){return e(i,{key:"5fd5420403a86c3a3cd1051bc195ce2aad1efce1"},e("div",{key:"d145ef0c3ef1ac6e5d5bce4faf6dd19a6e96b34a",class:"form-group d-flex flex-column"},e("div",{key:"a4f8efe5b6d8862388ac3a564ebe7522e3b5643a",class:"d-flex align-items-start gap-2"},e("label",{key:"3e3d0f3d8ba2e32e9b18002e5884ccadd2ca8194",part:o,class:"form-label",htmlFor:this.name},this.label),e("form-control-tooltip",{key:"199ddd92c25bfa7ac6cde94bfe40087645ee3370",helpText:this.helpText})),e("input",{key:"f960d4968f7c71b7eaa69610b16462ee84e62b91",id:this.name,name:this.name,onFocus:()=>this.isFocused=!0,onBlur:()=>{this.isFocused=!1,this.formControlBlur.emit()},onInput:this.handleFormControlInput,onKeyDown:this.keyDownHandler,onPaste:this.keyDownHandler,maxLength:this.maxLength,part:this.part,class:this.errorText?"form-control is-invalid":"form-control",type:"text",disabled:this.disabled}),e(b,{key:"9eda3817d987fac142a584d95b6242950658eb5f",errorText:this.errorText,name:this.name})))}get el(){return a(this)}static get watchers(){return{defaultValue:["handleDefaultValueChange"]}}},m=class{constructor(s){t(this,s),this.anchorIcon=void 0,this.tooltip=void 0,this.helpText=void 0}show(){this.tooltip.classList.add("show")}hide(){this.tooltip.classList.remove("show")}render(){return this.helpText?e("div",{class:"tooltip-container"},e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",fill:"currentColor",class:"bi bi-question-square tooltip-icon",viewBox:"0 0 16 16",ref:t=>this.anchorIcon=t,part:f},e("path",{d:"M14 1a1 1 0 0 1 1 1v12a1 1 0 0 1-1 1H2a1 1 0 0 1-1-1V2a1 1 0 0 1 1-1zM2 0a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V2a2 2 0 0 0-2-2z"}),e("path",{d:"M5.255 5.786a.237.237 0 0 0 .241.247h.825c.138 0 .248-.113.266-.25.09-.656.54-1.134 1.342-1.134.686 0 1.314.343 1.314 1.168 0 .635-.374.927-.965 1.371-.673.489-1.206 1.06-1.168 1.987l.003.217a.25.25 0 0 0 .25.246h.811a.25.25 0 0 0 .25-.25v-.105c0-.718.273-.927 1.01-1.486.609-.463 1.244-.977 1.244-2.056 0-1.511-1.276-2.241-2.673-2.241-1.267 0-2.655.59-2.75 2.286m1.557 5.763c0 .533.425.927 1.01.927.609 0 1.028-.394 1.028-.927 0-.552-.42-.94-1.029-.94-.584 0-1.009.388-1.009.94"})),e("custom-popper",{trigger:"hover",placement:"top",anchorRef:this.anchorIcon},e("div",{class:"tooltip bs-tooltip-top",part:d,role:"tooltip",ref:t=>this.tooltip=t},e("div",{class:"tooltip-inner",part:n},this.helpText)))):null}};export{p as form_control_select,u as form_control_text,m as form_control_tooltip}
1
+ import{r as t,c as s,h as i,H as e,g as a}from"./p-2783e363.js";import{l as o,c as h,b as r,a1 as l,a as c,ae as d,af as n,ag as f}from"./p-f2111e68.js";import{F as p}from"./p-5ee67fad.js";const b=class{constructor(i){t(this,i),this.formControlInput=s(this,"formControlInput",7),this.formControlBlur=s(this,"formControlBlur",7),this.handleFormControlInput=t=>{const s=t.target,i=s.getAttribute("name");this.inputHandler(i,s.value),this.formControlInput.emit(s.value)},this.updateInput=t=>{this.selectElement.value=t},this.isFocused=!1,this.name=void 0,this.label=void 0,this.options=void 0,this.inputHandler=void 0,this.defaultValue=void 0,this.helpText=void 0,this.errorText=void 0,this.disabled=void 0}handleDefaultValueChange(t){this.updateInput(t)}componentDidLoad(){this.updateInput(this.defaultValue)}get part(){let t=h;return this.errorText&&(t=r),this.disabled&&(t=l),this.isFocused&&(t=c),t}render(){var t;return i(e,{key:"f55283c73225466b10cec78e6e5ff1c268142d1b"},i("div",{key:"48beb377ca664b867598f8e472a3bb4825aecf9b",class:"form-group d-flex flex-column"},i("div",{key:"13debfb6a725d7f247eb5601e3361a3964b826e9",class:"d-flex align-items-start gap-2"},i("label",{key:"15ac64fb03a5c1cb8f55c18bd7eb41d66328e599",part:o,class:"form-label",htmlFor:this.name},this.label),i("form-control-tooltip",{key:"3d8b43ed6e997234f7c64daf41b2286bec93340e",helpText:this.helpText})),i("select",{key:"1c3eb5699a0b76c694a02fe50e8070483b2960e6",ref:t=>this.selectElement=t,id:this.name,name:this.name,onFocus:()=>this.isFocused=!0,onBlur:()=>{this.isFocused=!1,this.formControlBlur.emit()},onInput:this.handleFormControlInput,part:this.part,class:this.errorText?"form-select is-invalid":"form-select",disabled:this.disabled},null===(t=this.options)||void 0===t?void 0:t.map((t=>i("option",{value:t.value},t.label)))),i(p,{key:"d223fd1fad44de99812b0e3a3429e3931b798c2c",errorText:this.errorText,name:this.name})))}static get watchers(){return{defaultValue:["handleDefaultValueChange"]}}},u=class{constructor(i){t(this,i),this.formControlInput=s(this,"formControlInput",7),this.formControlBlur=s(this,"formControlBlur",7),this.handleFormControlInput=t=>{const s=t.target,i=s.getAttribute("name");this.inputHandler(i,s.value),this.formControlInput.emit({name:i,value:s.value})},this.updateInput=t=>{const s=this.el.querySelector("input");s&&(s.value=t||"")},this.isFocused=!1,this.name=void 0,this.label=void 0,this.inputHandler=void 0,this.defaultValue=void 0,this.helpText=void 0,this.errorText=void 0,this.maxLength=void 0,this.keyDownHandler=void 0,this.disabled=void 0}handleDefaultValueChange(t){this.updateInput(t)}componentDidLoad(){this.updateInput(this.defaultValue)}get part(){return this.errorText?r:this.disabled?l:this.isFocused?c:h}render(){return i(e,{key:"58d3e4003254d47d57421a2b98c4c3c4ae1ad7d7"},i("div",{key:"ef490c45923857d072b54511d28289231843d6d4",class:"form-group d-flex flex-column"},i("div",{key:"4554059b6543dee11f4baf897161a0403067d9fc",class:"d-flex align-items-start gap-2"},i("label",{key:"c9aac34dbea8460850416432b26c341de0fd709f",part:o,class:"form-label",htmlFor:this.name},this.label),i("form-control-tooltip",{key:"9c71653212fc53843f7ef0ab99c7b4458a0c54cc",helpText:this.helpText})),i("input",{key:"c014ebd061185484c91229bbe0b0dc89e66c7b03",id:this.name,name:this.name,onFocus:()=>this.isFocused=!0,onBlur:()=>{this.isFocused=!1,this.formControlBlur.emit()},onInput:this.handleFormControlInput,onKeyDown:this.keyDownHandler,onPaste:this.keyDownHandler,maxLength:this.maxLength,part:this.part,class:this.errorText?"form-control is-invalid":"form-control",type:"text",disabled:this.disabled}),i(p,{key:"a885a023a35e3801365d97e22c54615b77d45863",errorText:this.errorText,name:this.name})))}get el(){return a(this)}static get watchers(){return{defaultValue:["handleDefaultValueChange"]}}},m=class{constructor(s){t(this,s),this.anchorIcon=void 0,this.tooltip=void 0,this.helpText=void 0}show(){this.tooltip.classList.add("show")}hide(){this.tooltip.classList.remove("show")}render(){return this.helpText?i("div",{class:"tooltip-container"},i("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",fill:"currentColor",class:"bi bi-question-square tooltip-icon",viewBox:"0 0 16 16",ref:t=>this.anchorIcon=t,part:f},i("path",{d:"M14 1a1 1 0 0 1 1 1v12a1 1 0 0 1-1 1H2a1 1 0 0 1-1-1V2a1 1 0 0 1 1-1zM2 0a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V2a2 2 0 0 0-2-2z"}),i("path",{d:"M5.255 5.786a.237.237 0 0 0 .241.247h.825c.138 0 .248-.113.266-.25.09-.656.54-1.134 1.342-1.134.686 0 1.314.343 1.314 1.168 0 .635-.374.927-.965 1.371-.673.489-1.206 1.06-1.168 1.987l.003.217a.25.25 0 0 0 .25.246h.811a.25.25 0 0 0 .25-.25v-.105c0-.718.273-.927 1.01-1.486.609-.463 1.244-.977 1.244-2.056 0-1.511-1.276-2.241-2.673-2.241-1.267 0-2.655.59-2.75 2.286m1.557 5.763c0 .533.425.927 1.01.927.609 0 1.028-.394 1.028-.927 0-.552-.42-.94-1.029-.94-.584 0-1.009.388-1.009.94"})),i("custom-popper",{trigger:"hover",placement:"top",anchorRef:this.anchorIcon},i("div",{class:"tooltip bs-tooltip-top",part:d,role:"tooltip",ref:t=>this.tooltip=t},i("div",{class:"tooltip-inner",part:n},this.helpText)))):null}};export{b as form_control_select,u as form_control_text,m as form_control_tooltip}
@@ -1 +1 @@
1
- import{h as t}from"./p-2783e363.js";import{c as a}from"./p-2ca5b5e4.js";import{M as e}from"./p-77245638.js";import{m as o,k as s}from"./p-8b3842ce.js";const p="created_at,amount,status,payments_total,refunds_total,fees_total,other_total,csv",c={created_at:()=>t("th",{part:s,scope:"col",title:"The date the payout was deposited"},"Created"),sub_account_name:()=>t("th",{part:s,scope:"col",title:"The sub account associated with the payout"},"Sub Account"),payments_total:()=>t("th",{part:s,scope:"col",title:"The total payments amount associated with the payout"},"Payments"),refunds_total:()=>t("th",{part:s,scope:"col",title:"The total refunds amount associated with the payout"},"Refunds"),fees_total:()=>t("th",{part:s,scope:"col",title:"The total fees amount associated with the payout"},"Fees"),other_total:()=>t("th",{part:s,scope:"col",title:"The total other amount"},"Other"),amount:()=>t("th",{part:s,scope:"col",title:"The total amount of the payout"},"Amount"),status:()=>t("th",{part:s,scope:"col",title:"The real-time status of each payout"},"Status"),csv:()=>t("th",{part:s,scope:"col",title:"Export CSV"})},r=s=>({created_at:(e,s)=>t("td",{part:o(s)},t("div",{class:"fw-bold"},a(e.created_at,{showDisplayDate:!0}))),sub_account_name:(a,e)=>t("td",{part:o(e)},a.sub_account_name),payments_total:(a,e)=>t("td",{part:o(e)},a.formattedPaymentAmount(a.payments_total)),refunds_total:(a,e)=>t("td",{part:o(e)},a.formattedPaymentAmount(a.refunds_total)),fees_total:(a,e)=>t("td",{part:o(e)},a.formattedPaymentAmount(a.fees_total)),other_total:(a,e)=>t("td",{part:o(e)},a.formattedPaymentAmount(a.other_total)),amount:(a,e)=>t("td",{part:o(e)},a.formattedPaymentAmount(a.amount)),status:(a,s)=>t("td",{part:o(s)},e(a.status)),csv:(a,e)=>t("td",{part:o(e)},t("a",{href:"#",onClick:t=>{t.preventDefault(),s(a.id)}},"CSV"))});export{r as a,p as d,c as p}
1
+ import{h as t}from"./p-2783e363.js";import{c as a}from"./p-2ca5b5e4.js";import{M as e}from"./p-8066b866.js";import{m as o,k as s}from"./p-f2111e68.js";const p="created_at,amount,status,payments_total,refunds_total,fees_total,other_total,csv",r={created_at:()=>t("th",{part:s,scope:"col",title:"The date the payout was deposited"},"Created"),sub_account_name:()=>t("th",{part:s,scope:"col",title:"The sub account associated with the payout"},"Sub Account"),payments_total:()=>t("th",{part:s,scope:"col",title:"The total payments amount associated with the payout"},"Payments"),refunds_total:()=>t("th",{part:s,scope:"col",title:"The total refunds amount associated with the payout"},"Refunds"),fees_total:()=>t("th",{part:s,scope:"col",title:"The total fees amount associated with the payout"},"Fees"),other_total:()=>t("th",{part:s,scope:"col",title:"The total other amount"},"Other"),amount:()=>t("th",{part:s,scope:"col",title:"The total amount of the payout"},"Amount"),status:()=>t("th",{part:s,scope:"col",title:"The real-time status of each payout"},"Status"),csv:()=>t("th",{part:s,scope:"col",title:"Export CSV"})},c=s=>({created_at:(e,s)=>t("td",{part:o(s)},t("div",{class:"fw-bold"},a(e.created_at,{showDisplayDate:!0}))),sub_account_name:(a,e)=>t("td",{part:o(e)},a.sub_account_name),payments_total:(a,e)=>t("td",{part:o(e)},a.formattedPaymentAmount(a.payments_total)),refunds_total:(a,e)=>t("td",{part:o(e)},a.formattedPaymentAmount(a.refunds_total)),fees_total:(a,e)=>t("td",{part:o(e)},a.formattedPaymentAmount(a.fees_total)),other_total:(a,e)=>t("td",{part:o(e)},a.formattedPaymentAmount(a.other_total)),amount:(a,e)=>t("td",{part:o(e)},a.formattedPaymentAmount(a.amount)),status:(a,s)=>t("td",{part:o(s)},e(a.status)),csv:(a,e)=>t("td",{part:o(e)},t("a",{href:"#",onClick:t=>{t.preventDefault(),s(a.id)}},"CSV"))});export{c as a,p as d,r as p}
@@ -0,0 +1 @@
1
+ import{r as t,c as s,h as i,H as a}from"./p-2783e363.js";import{a3 as e,a4 as h,a5 as o,a6 as r,a7 as c,l as f}from"./p-f2111e68.js";const d=class{constructor(i){t(this,i),this.formControlInput=s(this,"formControlInput",7),this.formControlBlur=s(this,"formControlBlur",7),this.handleFormControlInput=t=>{const s=t.target.getAttribute("name");this.inputHandler(s,this.value),this.formControlInput.emit({name:s,value:this.value})},this.isFocused=!1,this.label=void 0,this.name=void 0,this.value=void 0,this.helpText=void 0,this.inputHandler=void 0,this.disabled=void 0,this.errorText=void 0,this.checked=void 0}get part(){return this.errorText?e:this.isFocused&&this.checked?h:this.checked?o:this.isFocused?r:c}render(){return i(a,{key:"e82324f1559f95c0de0b7ccfea3e0d24cf7b111f",class:"form-group d-flex flex-column"},i("div",{key:"aa98c0018d8e29075fba54ee97a8890a478d8008",class:"form-check"},i("input",{key:"ca3f39c4882bc580992d99382b577131b2ebf8d2",ref:t=>this.radioElement=t,type:"radio",id:`${this.name}-${this.value}`,name:this.name,onFocus:()=>this.isFocused=!0,onBlur:()=>{this.isFocused=!1,this.formControlBlur.emit()},onChange:this.handleFormControlInput,part:this.part,class:this.errorText?"form-check-input is-invalid":"form-check-input",disabled:this.disabled,value:this.value,checked:this.checked}),i("label",{key:"b54b032ae6fcb6220f113a5959a4faa5869d2085",class:"form-check-label",htmlFor:`${this.name}-${this.value}`,part:f},this.label)),i("form-control-help-text",{key:"97508e5f8e25714f661bf3f5633a144fedf116a6",helpText:this.helpText,name:this.name}),i("form-control-error-text",{key:"7ea160cc96a71a87fa77d6d0a3012340b6dc8a3f",errorText:this.errorText,name:this.name}))}};export{d as form_control_radio}
@@ -0,0 +1 @@
1
+ import{r as t,c as s,h as e}from"./p-2783e363.js";import"./p-9dd8685c.js";import"./p-daf0303f.js";import{p as a}from"./p-56f6ce4c.js";import"./p-9894484a.js";import"./p-382ab4e8.js";import"./p-61f0a2ce.js";import{P as i,Q as r}from"./p-f2111e68.js";import{T as c,a as h,b as o,c as d,d as b}from"./p-71897cbc.js";import{c as n,a as p}from"./p-fa987dcf.js";import{o as f,g as m}from"./p-092515e0.js";import"./p-2ca5b5e4.js";import"./p-abdbcd8e.js";import"./p-3cbdca1b.js";import"./p-b5addd78.js";import"./p-f20b6ce1.js";const u=class{constructor(e){t(this,e),this.clickEvent=s(this,"click-event",7),this.errorEvent=s(this,"error-event",7),this.handleClickPrevious=t=>{this.pagingParams={before_cursor:t},this.clickEvent.emit({name:c.previous})},this.handleClickNext=t=>{this.pagingParams={after_cursor:t},this.clickEvent.emit({name:c.next})},this.rowClickHandler=t=>{const s=t.target.closest("tr").dataset.rowEntityId;if(!s)return;const e=this.checkouts.find((t=>t.id===s));this.clickEvent.emit({name:c.row,data:e})},this.getCheckouts=void 0,this.getSubAccounts=void 0,this.columns=void 0,this.checkouts=[],this.checkoutsTable=void 0,this.subAccounts=[],this.loading=!0,this.errorMessage=void 0,this.paging=a,this.pagingParams={}}updateOnPropChange(){this.fetchData()}componentWillLoad(){this.checkoutsTable=new h(this.checkouts,this.columns,n,p),this.getCheckouts&&this.getSubAccounts&&this.fetchData(),f("set",(()=>{this.pagingParams={}})),f("reset",(()=>{this.pagingParams={},this.errorMessage=""}))}fetchData(){this.loading=!0,this.getCheckouts({params:this.checkoutParams,onSuccess:async({checkouts:t,pagingInfo:s})=>{this.checkouts=t,this.paging=s,this.checkoutsTable.collectionData=this.checkouts,this.checkoutsTable.columnKeys.includes("sub_account_name")?await this.fetchSubAccounts():this.loading=!1},onError:({error:t,code:s,severity:e})=>{this.errorMessage=t,this.errorEvent.emit({errorCode:s,message:t,severity:e}),this.loading=!1}})}async fetchSubAccounts(){this.getSubAccounts({params:this.subAccountParams,onSuccess:({subAccounts:t})=>{this.subAccounts=t,this.checkouts=this.checkouts.map((t=>{var s;return t.sub_account_name=null===(s=this.subAccounts.find((s=>s.id===t.account_id)))||void 0===s?void 0:s.name,t})),this.loading=!1},onError:({error:t,code:s,severity:e})=>{this.errorMessage=t,this.errorEvent.emit({errorCode:s,message:t,severity:e}),this.loading=!1}})}get checkoutParams(){const t=m();return Object.assign(Object.assign({},t),this.pagingParams)}get subAccountParams(){let t=this.checkouts.map((t=>t.account_id));return{sub_account_id:[...new Set(t)].join(",")}}get entityId(){return this.checkouts.map((t=>t.id))}get showEmptyState(){return!this.loading&&!this.errorMessage&&this.checkoutsTable.rowData.length<1}get showErrorState(){return!this.loading&&!!this.errorMessage}get showRowData(){return!this.showEmptyState&&!this.showErrorState&&!this.loading}render(){return e("div",{key:"ae6d3dfefad89fcd28b2ad883a1d1172fffd2218"},e("div",{key:"91329a7880cd774c71cf30722b7be49b8a0109e9",class:"table-wrapper"},e("table",{key:"75f974cc2140089a7a42738ef0cd3bd67729ca8d",class:"table table-hover",part:i},e("thead",{key:"6aaaee8db285ca1b94cea662f62a51040f2a0f06",class:"table-head sticky-top"},e("tr",{key:"68215e0698b97a8389083a521bd8a493c410a196",class:"table-light text-nowrap"},this.checkoutsTable.columnData.map((t=>t)))),e("tbody",{key:"b3aa9bd464fda772fae2e191e1cc4f4612bd514b",class:"table-body"},e(o,{key:"a874602fb597ee55def35b80474bd2228b918200",columnSpan:this.checkoutsTable.columnKeys.length,isLoading:this.loading}),e(d,{key:"8c30048e8766be8ca14fbbd6f990aac019904b26",isEmpty:this.showEmptyState,columnSpan:this.checkoutsTable.columnKeys.length}),e(b,{key:"c567bbca2ebbdc42dcfa6c07ae2c61b538643cb7",columnSpan:this.checkoutsTable.columnKeys.length,errorMessage:this.errorMessage}),this.showRowData&&this.checkoutsTable.rowData.map(((t,s)=>e("tr",{"data-test-id":"table-row","data-row-entity-id":this.entityId[s],onClick:this.rowClickHandler},t)))),this.paging&&e("tfoot",{key:"f02cd5b963f2c087b1a8ab60f25f6b1081e735aa",class:"sticky-bottom"},e("tr",{key:"a651ab932931db6a4ad42888a9b43e7b89a58495",class:"table-light align-middle"},e("td",{key:"1fde503bccc4e79454d5786fac8f82bea67618e1",part:r,colSpan:this.checkoutsTable.columnData.length},e("pagination-menu",{key:"6237a008bc148f44aa7e159d530470c5114b32e4",paging:Object.assign(Object.assign({},this.paging),{handleClickPrevious:this.handleClickPrevious,handleClickNext:this.handleClickNext})})))))))}static get watchers(){return{pagingParams:["updateOnPropChange"],getCheckouts:["updateOnPropChange"],getSubAccounts:["updateOnPropChange"],columns:["updateOnPropChange"]}}};export{u as checkouts_list_core}
@@ -1 +1 @@
1
- import{r as s,c as i,h as t}from"./p-2783e363.js";import{f as e}from"./p-2ca5b5e4.js";import{C as d}from"./p-daf0303f.js";import{a as o}from"./p-9dd8685c.js";import{i as a,v as c,H as r,a as h}from"./p-45bed1b7.js";import{B as n}from"./p-66cdd475.js";import{S as l}from"./p-bfe9748b.js";import{t as v,W as f}from"./p-8b3842ce.js";import{S as m}from"./p-fe0399a1.js";import{H as p}from"./p-5dc767d8.js";import"./p-f20b6ce1.js";const b=class{constructor(t){s(this,t),this.submitEvent=i(this,"submit-event",7),this.errorEvent=i(this,"error-event",7),this.loaded=i(this,"loaded",7),this.completeCheckout=async s=>{this.complete({payment:s,onSuccess:this.onSubmitted,onError:this.onError})},this.onSubmitted=s=>{this.submitEvent.emit({response:s}),this.renderState="success"},this.onError=({error:s,code:i,severity:t})=>{this.serverError=s,this.errorEvent.emit({errorCode:i,message:s,severity:t}),this.renderState="error"},this.authToken=void 0,this.getCheckout=void 0,this.complete=void 0,this.checkoutId=void 0,this.iframeOrigin=void 0,this.disableCreditCard=void 0,this.disableBankAccount=void 0,this.disableBnpl=void 0,this.disablePaymentMethodGroup=void 0,this.hideCardBillingForm=void 0,this.hasLoadedFonts=!1,this.checkout=void 0,this.serverError=void 0,this.renderState="loading",this.creatingNewPaymentMethod=!1,this.insuranceToggled=!1}async fillBillingForm(s){this.paymentMethodOptionsRef.fillBillingForm(s)}componentWillLoad(){this.getCheckout&&(this.fetchData(),a("set",(s=>{const i=h[s];void 0!==i&&(this.insuranceToggled=i,this.fetchData())})))}fetchData(){this.renderState="loading",this.getCheckout({onSuccess:({checkout:s})=>{this.checkout=new d(s);const{status:i}=this.checkout;this.loaded.emit({checkout_status:i}),this.renderState="success"},onError:({error:s,code:i,severity:t})=>{this.serverError=s,this.renderState="error",this.errorEvent.emit({errorCode:i,message:s,severity:t})}})}async submit(s){var i;s.preventDefault(),this.renderState="loading";const t=c(),e=await this.paymentMethodOptionsRef.resolvePaymentMethod(t);e.validationError?this.renderState="error":e.error?(this.renderState="error",this.serverError=e.error.message,this.onError({code:e.error.code,error:e.error.message,severity:o.ERROR})):e.token?this.completeCheckout({payment_mode:"ecom",payment_token:e.token}):"success"===(null===(i=e.bnpl)||void 0===i?void 0:i.status)?this.completeCheckout({payment_mode:"bnpl"}):this.renderState="error"}get isLoading(){return"loading"===this.renderState}get isError(){return"error"===this.renderState}get paymentType(){var s,i,e,d,o;return t("section",null,t("div",{class:!this.isLoading&&"visually-hidden"},t(m,{height:"300px"})),t("div",{class:this.isLoading&&"visually-hidden"},t("justifi-payment-method-options",{ref:s=>this.paymentMethodOptionsRef=s,"show-card":!this.disableCreditCard,"show-ach":!this.disableBankAccount,"show-bnpl":!this.disableBnpl,paymentMethodGroupId:null===(s=this.checkout)||void 0===s?void 0:s.payment_method_group_id,"show-saved-payment-methods":!this.disablePaymentMethodGroup,hideCardBillingForm:this.hideCardBillingForm,bnpl:null===(i=this.checkout)||void 0===i?void 0:i.bnpl,authToken:this.authToken,"account-id":null===(e=this.checkout)||void 0===e?void 0:e.account_id,savedPaymentMethods:(null===(d=this.checkout)||void 0===d?void 0:d.payment_methods)||[],paymentAmount:null===(o=this.checkout)||void 0===o?void 0:o.payment_amount,insuranceToggled:this.insuranceToggled,iframeOrigin:this.iframeOrigin})))}get summary(){var s,i;return t("section",null,t("div",{class:!this.isLoading&&"visually-hidden"},t(m,{height:"24px"})),t("div",{class:this.isLoading&&"visually-hidden"},t("div",{part:v},null===(s=this.checkout)||void 0===s?void 0:s.payment_description),t("div",null,t("span",{part:v},"Total")," ",t("span",{part:v},e(+(null===(i=this.checkout)||void 0===i?void 0:i.total_amount))))))}render(){return t(l,{key:"8f7bb796cec8a51b3a871ecc6f1d040636103503"},t("div",{key:"f616c1705dd8d9da854b496d5b028cebb4c88ce5",class:"row gy-3 jfi-checkout-core"},t("div",{key:"e374110371f020c9de996f4ca3932f7535e208ee",class:"col-12",part:f},t(r,{key:"aa9227b3ff49dc43c6a42d1988ec0669b298cef0",text:"Summary",class:"fs-5 fw-bold pb-3"}),this.summary),t("div",{key:"e8e9cddcc4cb11c6d7c020c1dc18d7b5bfe457c3",class:"col-12"},t("slot",{key:"69e623e8c23aec6f49430b395f86d7134ceeddc9",name:"insurance"})),t("div",{key:"fea072a50acb658433a36d8234b27c1fd8415dc4",class:"col-12 mt-4"},t(r,{key:"9b0a5c9e5e7db31a6d6cfda87cad18786d638bd9",text:"Payment",class:"fs-5 fw-bold pb-3"}),t(p,{key:"2eeae1935b2b238573be4bf1edfc5d80700d9c80",text:"Select payment type",class:"fs-6 fw-bold lh-lg"}),t("div",{key:"5c9fd0558a37ff903ec7137beeb3c49d406bcd1d",class:"d-flex flex-column"},this.paymentType)),t("div",{key:"2538670c227dc2e96c43d878ae09357a72a7e267",class:"col-12"},t("div",{key:"b51e39da64972578815a2cf0cf5342d292edaa45",class:"d-flex justify-content-end"},t(n,{key:"abcb099a4ad152a38d05d99781e02292efd246e0",type:"submit",variant:"primary",onClick:s=>this.submit(s),disabled:this.isLoading,isLoading:this.isLoading,style:{width:"100%"}},"Pay")))))}};export{b as justifi_checkout_core}
1
+ import{r as s,c as i,h as t}from"./p-2783e363.js";import{f as e}from"./p-2ca5b5e4.js";import{C as d}from"./p-daf0303f.js";import{a as o}from"./p-9dd8685c.js";import{i as a,v as c,H as r,a as h}from"./p-e366ef1e.js";import{B as n}from"./p-e60867c6.js";import{S as l}from"./p-bfe9748b.js";import{t as v,V as f}from"./p-f2111e68.js";import{S as m}from"./p-a3d75257.js";import{H as p}from"./p-bdf0ab42.js";import"./p-f20b6ce1.js";const u=class{constructor(t){s(this,t),this.submitEvent=i(this,"submit-event",7),this.errorEvent=i(this,"error-event",7),this.loaded=i(this,"loaded",7),this.completeCheckout=async s=>{this.complete({payment:s,onSuccess:this.onSubmitted,onError:this.onError})},this.onSubmitted=s=>{this.submitEvent.emit({response:s}),this.renderState="success"},this.onError=({error:s,code:i,severity:t})=>{this.serverError=s,this.errorEvent.emit({errorCode:i,message:s,severity:t}),this.renderState="error"},this.authToken=void 0,this.getCheckout=void 0,this.complete=void 0,this.checkoutId=void 0,this.iframeOrigin=void 0,this.disableCreditCard=void 0,this.disableBankAccount=void 0,this.disableBnpl=void 0,this.disablePaymentMethodGroup=void 0,this.hideCardBillingForm=void 0,this.hasLoadedFonts=!1,this.checkout=void 0,this.serverError=void 0,this.renderState="loading",this.creatingNewPaymentMethod=!1,this.insuranceToggled=!1}async fillBillingForm(s){this.paymentMethodOptionsRef.fillBillingForm(s)}componentWillLoad(){this.getCheckout&&(this.fetchData(),a("set",(s=>{const i=h[s];void 0!==i&&(this.insuranceToggled=i,this.fetchData())})))}fetchData(){this.renderState="loading",this.getCheckout({onSuccess:({checkout:s})=>{this.checkout=new d(s);const{status:i}=this.checkout;this.loaded.emit({checkout_status:i}),this.renderState="success"},onError:({error:s,code:i,severity:t})=>{this.serverError=s,this.renderState="error",this.errorEvent.emit({errorCode:i,message:s,severity:t})}})}async submit(s){var i;s.preventDefault(),this.renderState="loading";const t=c(),e=await this.paymentMethodOptionsRef.resolvePaymentMethod(t);e.validationError?this.renderState="error":e.error?(this.renderState="error",this.serverError=e.error.message,this.onError({code:e.error.code,error:e.error.message,severity:o.ERROR})):e.token?this.completeCheckout({payment_mode:"ecom",payment_token:e.token}):"success"===(null===(i=e.bnpl)||void 0===i?void 0:i.status)?this.completeCheckout({payment_mode:"bnpl"}):this.renderState="error"}get isLoading(){return"loading"===this.renderState}get isError(){return"error"===this.renderState}get paymentType(){var s,i,e,d,o;return t("section",null,t("div",{class:!this.isLoading&&"visually-hidden"},t(m,{height:"300px"})),t("div",{class:this.isLoading&&"visually-hidden"},t("justifi-payment-method-options",{ref:s=>this.paymentMethodOptionsRef=s,"show-card":!this.disableCreditCard,"show-ach":!this.disableBankAccount,"show-bnpl":!this.disableBnpl,paymentMethodGroupId:null===(s=this.checkout)||void 0===s?void 0:s.payment_method_group_id,"show-saved-payment-methods":!this.disablePaymentMethodGroup,hideCardBillingForm:this.hideCardBillingForm,bnpl:null===(i=this.checkout)||void 0===i?void 0:i.bnpl,authToken:this.authToken,"account-id":null===(e=this.checkout)||void 0===e?void 0:e.account_id,savedPaymentMethods:(null===(d=this.checkout)||void 0===d?void 0:d.payment_methods)||[],paymentAmount:null===(o=this.checkout)||void 0===o?void 0:o.payment_amount,insuranceToggled:this.insuranceToggled,iframeOrigin:this.iframeOrigin})))}get summary(){var s,i;return t("section",null,t("div",{class:!this.isLoading&&"visually-hidden"},t(m,{height:"24px"})),t("div",{class:this.isLoading&&"visually-hidden"},t("div",{part:v},null===(s=this.checkout)||void 0===s?void 0:s.payment_description),t("div",null,t("span",{part:v},"Total")," ",t("span",{part:v},e(+(null===(i=this.checkout)||void 0===i?void 0:i.total_amount))))))}render(){return t(l,{key:"8f7bb796cec8a51b3a871ecc6f1d040636103503"},t("div",{key:"f616c1705dd8d9da854b496d5b028cebb4c88ce5",class:"row gy-3 jfi-checkout-core"},t("div",{key:"e374110371f020c9de996f4ca3932f7535e208ee",class:"col-12",part:f},t(r,{key:"aa9227b3ff49dc43c6a42d1988ec0669b298cef0",text:"Summary",class:"fs-5 fw-bold pb-3"}),this.summary),t("div",{key:"e8e9cddcc4cb11c6d7c020c1dc18d7b5bfe457c3",class:"col-12"},t("slot",{key:"69e623e8c23aec6f49430b395f86d7134ceeddc9",name:"insurance"})),t("div",{key:"fea072a50acb658433a36d8234b27c1fd8415dc4",class:"col-12 mt-4"},t(r,{key:"9b0a5c9e5e7db31a6d6cfda87cad18786d638bd9",text:"Payment",class:"fs-5 fw-bold pb-3"}),t(p,{key:"2eeae1935b2b238573be4bf1edfc5d80700d9c80",text:"Select payment type",class:"fs-6 fw-bold lh-lg"}),t("div",{key:"5c9fd0558a37ff903ec7137beeb3c49d406bcd1d",class:"d-flex flex-column"},this.paymentType)),t("div",{key:"2538670c227dc2e96c43d878ae09357a72a7e267",class:"col-12"},t("div",{key:"b51e39da64972578815a2cf0cf5342d292edaa45",class:"d-flex justify-content-end"},t(n,{key:"abcb099a4ad152a38d05d99781e02292efd246e0",type:"submit",variant:"primary",onClick:s=>this.submit(s),disabled:this.isLoading,isLoading:this.isLoading,style:{width:"100%"}},"Pay")))))}};export{u as justifi_checkout_core}
@@ -0,0 +1 @@
1
+ import{r as t,c as s,h as i,H as e,g as a}from"./p-2783e363.js";import{i as c,a as o,b as h,c as r,l as n}from"./p-f2111e68.js";import{F as d}from"./p-ede13cc8.js";import{F as f}from"./p-5ee67fad.js";const l=class{constructor(i){t(this,i),this.formControlInput=s(this,"formControlInput",7),this.formControlBlur=s(this,"formControlBlur",7),this.handleFormControlInput=t=>{const s=t.target,i=s.getAttribute("name");this.inputHandler(i,s.value),this.formControlInput.emit({name:i,value:s.value})},this.updateInput=t=>{const s=this.el.querySelector("input");s&&(s.value=t||"")},this.isFocused=!1,this.label=void 0,this.name=void 0,this.helpText=void 0,this.errorText=void 0,this.defaultValue=void 0,this.inputHandler=void 0,this.disabled=void 0}handleDefaultValueChange(t){this.updateInput(t)}componentDidLoad(){this.updateInput(this.defaultValue)}get part(){return this.isFocused&&this.errorText?c:this.isFocused?o:this.errorText?h:r}render(){return i(e,{key:"2384acdb57de4385cc807c1c8de78460018168b7"},i("div",{key:"abcba3127958fcd7a01b0a3f16cc20072e5fbc3f",class:"form-group d-flex flex-column"},i("label",{key:"5bee8f69bfbcdb66e4f9b80b1bfccdcfd22f6a9a",part:n,class:"form-label",htmlFor:this.name},this.label),i("input",{key:"1d232c2c0b07af9faaacb1fcc926e8c7838f6769",id:this.name,name:this.name,onFocus:()=>this.isFocused=!0,onBlur:()=>{this.isFocused=!1,this.formControlBlur.emit()},onInput:this.handleFormControlInput,part:this.part,class:this.errorText?"form-control is-invalid":"form-control",type:"number",disabled:this.disabled}),i(d,{key:"d03c05c82aec034fd0d7d72b3ccb00527bbf8559",helpText:this.helpText,name:this.name}),i(f,{key:"6da5711c44b703bcb72257206c3b0b308890db47",errorText:this.errorText,name:this.name})))}get el(){return a(this)}static get watchers(){return{defaultValue:["handleDefaultValueChange"]}}};export{l as form_control_number}
@@ -1 +1 @@
1
- import{h as s,r as t,c as e}from"./p-2783e363.js";import{a as i,b as r}from"./p-4acf8ca2.js";import{F as o,c as n}from"./p-5844a0f0.js";import{A as a,C as l,R as h,c}from"./p-5d1d2fd7.js";import{C as d,P as u}from"./p-525db3e8.js";import{h as m}from"./p-8b3842ce.js";import{S as p}from"./p-fe0399a1.js";import{a as v,r as f,s as b,b as y}from"./p-c9b78275.js";import{a as g,B as w}from"./p-73f9be7c.js";import{z as _,A as x,u as j,B as S,C as T,D as O,E as k,F as C}from"./p-95e55bb1.js";import{C as L,a as H}from"./p-9dd8685c.js";import"./p-daf0303f.js";import"./p-56f6ce4c.js";import"./p-9894484a.js";import"./p-e0befd51.js";import{a as E,b as D}from"./p-61f0a2ce.js";import{n as V}from"./p-e3c22aa9.js";import{B as A}from"./p-66cdd475.js";import{i as P,a as B}from"./p-d43a38a4.js";import{S as I}from"./p-6078a370.js";import"./p-1ff8810b.js";import"./p-2ca5b5e4.js";import"./p-abdbcd8e.js";class W{constructor(s){this.id=s.id,this.account_owner_name=s.account_owner_name,this.full_name=s.full_name,this.account_type=s.account_type,this.account_number=s.account_number,this.acct_last_four=s.acct_last_four,this.account_number_last4=s.account_number_last4,this.routing_number=s.routing_number,this.bank_name=s.bank_name,this.country=s.country,this.currency=s.currency,this.nickname=s.nickname,this.metadata=s.metadata,this.business_id=s.business_id,this.platform_account_id=s.platform_account_id,this.created_at=s.created_at,this.updated_at=s.updated_at}get payload(){return{account_owner_name:this.account_owner_name||"",account_type:this.account_type||"",account_number:this.account_number||"",routing_number:this.routing_number||"",bank_name:this.bank_name||"",nickname:this.nickname||"",business_id:this.business_id||""}}}const F=()=>s("div",{class:"row gap-3"},s("div",{class:"col-12"},s(p,{width:"25%"})),s("div",{class:"col-12"},s(p,{width:"100%"})),s("div",{class:"col-12 d-flex gap-3"},s(p,{width:"50%"}),s(p,{width:"50%"})),s("div",{class:"col-12 d-flex gap-3"},s(p,{width:"65%"}),s(p,{width:"35%"}))),N=()=>s("div",{class:"row gap-5"},s("div",{class:"col-12"},s(p,{width:"40%",height:"40px"})),s(F,null),s(F,null),s(F,null)),U=class{constructor(s){t(this,s),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.errorEvent=e(this,"error-event",7),this.formLoading=e(this,"formLoading",7),this.getData=()=>{this.formLoading.emit(!0),this.isLoading=!0,this.getBusiness({onSuccess:s=>{this.additional_questions=new a(s.data.additional_questions||{}),this.formController.setInitialValues(Object.assign({},this.additional_questions))},onError:({error:s,code:t,severity:e})=>{this.errorEvent.emit({message:s,errorCode:t,severity:e})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1}})},this.sendData=s=>{let t;this.formLoading.emit(!0),this.patchBusiness({payload:this.patchPayload,onSuccess:e=>{t=e,s()},onError:({error:s,code:e,severity:i})=>{t=s,this.errorEvent.emit({message:s,errorCode:e,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:t,formStep:g.additionalQuestions}),this.formLoading.emit(!1)}})},this.inputHandler=(s,t)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[s]:t})),this.additional_questions=new a(Object.assign(Object.assign({},this.formController.values.getValue()),{[s]:t}))},this.formController=void 0,this.errors={},this.additional_questions={},this.recurringPayments=!1,this.isLoading=!1,this.getBusiness=void 0,this.patchBusiness=void 0,this.allowOptionalFields=void 0}recurringPaymentsWatcher(s){this.recurringPayments="Yes"===(null==s?void 0:s.business_recurring_payments)}async validateAndSubmit({onSuccess:s}){this.formController.validateAndSubmit((()=>this.sendData(s)))}get patchPayload(){return{additional_questions:new a(this.formController.values.getValue()).payload}}componentWillLoad(){this.getBusiness&&this.getData(),this.formController=new o(i(this.allowOptionalFields))}componentDidLoad(){this.formController.errors.subscribe((s=>{this.errors=Object.assign({},s)}))}render(){var t,e,i,r,o,n,a;const l=this.formController.getInitialValues();return this.isLoading?s(N,null):s("form",null,s("fieldset",null,s("div",{class:"d-flex align-items-center gap-2"},s("legend",{class:"mb-0",part:m},"Additional Questions"),s("form-control-tooltip",{helpText:"This information helps us understand the business and identify and monitor trends to safeguard you and your customers."})),s("hr",{class:"mt-2"}),s("div",{class:"row gy-3"},s("div",{class:"col-12 col-md-6"},s("form-control-monetary",{name:"business_revenue",label:"What is your business’ estimated annual revenue from its primary business activities?",inputHandler:this.inputHandler,errorText:null===(t=this.errors)||void 0===t?void 0:t.business_revenue,defaultValue:null==l?void 0:l.business_revenue,maskOptions:d.WHOLE})),s("div",{class:"col-12 col-md-6"},s("form-control-monetary",{name:"business_payment_volume",label:"What is your business' annual credit card & ACH volume anticipated to process?",inputHandler:this.inputHandler,errorText:null===(e=this.errors)||void 0===e?void 0:e.business_payment_volume,defaultValue:null==l?void 0:l.business_payment_volume,maskOptions:d.WHOLE})),s("div",{class:"col-12"},s("form-control-select",{name:"business_when_service_received",label:"On average, how long after paying will your customers typically receive their goods or services?",inputHandler:this.inputHandler,errorText:null===(i=this.errors)||void 0===i?void 0:i.business_when_service_received,options:v,defaultValue:null==l?void 0:l.business_when_service_received})),s("div",{class:"col-12"},s("form-control-select",{name:"business_recurring_payments",label:"Does your business offer recurring payments?",inputHandler:this.inputHandler,errorText:null===(r=this.errors)||void 0===r?void 0:r.business_recurring_payments,options:f,defaultValue:null==l?void 0:l.business_recurring_payments})),s("div",{class:"col-12",hidden:!this.recurringPayments},s("form-control-text",{name:"business_recurring_payments_percentage",label:"What percent of revenue is generated from each recurring payment type offered?",inputHandler:this.inputHandler,errorText:null===(o=this.errors)||void 0===o?void 0:o.business_recurring_payments_percentage,defaultValue:null==l?void 0:l.business_recurring_payments_percentage,helpText:"For example: 50% monthly, 50% annual."})),s("div",{class:"col-12"},s("form-control-select",{name:"business_seasonal",label:"Is this business seasonal?",inputHandler:this.inputHandler,errorText:null===(n=this.errors)||void 0===n?void 0:n.business_seasonal,options:b,defaultValue:null==l?void 0:l.business_seasonal})),s("div",{class:"col-12"},s("form-control-text",{name:"business_other_payment_details",label:"Is there anything else you would like us to know about how your customers pay the business? (optional)",inputHandler:this.inputHandler,errorText:null===(a=this.errors)||void 0===a?void 0:a.business_other_payment_details,defaultValue:null==l?void 0:l.business_other_payment_details})))))}static get watchers(){return{additional_questions:["recurringPaymentsWatcher"]}}},q=(s,t)=>{const e=n({bank_name:_.required("Enter bank name"),nickname:x.required("Enter nickname"),account_owner_name:j.required("Enter account owner name"),account_type:S.required("Select account type"),account_number:T.required("Enter account number"),routing_number:O.required("Enter routing number"),voided_check:k(s,t),bank_statement:C(s,t)}),i=n({bank_name:_.nullable(),nickname:x.nullable(),account_owner_name:j.nullable(),account_type:S.nullable(),account_number:T.nullable(),routing_number:O.nullable(),voided_check:k(s,t),bank_statement:C(s,t)});return t?i:e},R=class{constructor(s){t(this,s),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.errorEvent=e(this,"error-event",7),this.formLoading=e(this,"formLoading",7),this.initializeFormController=()=>{this.formController=new o(q(this.existingDocuments,this.allowOptionalFields)),this.formController.setInitialValues(Object.assign({},this.bankAccount)),this.formController.errors.subscribe((s=>{this.errors=Object.assign({},s)}))},this.inputHandler=(s,t)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[s]:t}))},this.storeFiles=s=>{const t=Array.from(s.detail.fileList),e=s.detail.document_type,i=t.map((s=>new E({file:s,document_type:e},this.businessId)));this.documentData[e]=i},this.getData=()=>{this.isLoading=!0,this.getBusiness({onSuccess:s=>{s.data.bank_accounts.length>0?this.bankAccount=new W(s.data.bank_accounts[0]):(this.bankAccount=new W({}),this.bankAccount.business_id=this.businessId),this.existingDocuments=s.data.documents},onError:({error:s,code:t,severity:e})=>{this.errorEvent.emit({message:s,errorCode:t,severity:e})},final:()=>{this.initializeFormController(),this.isLoading=!1}})},this.postDocumentRecordData=async s=>{this.isLoading=!0;const t=s.record_data;return new Promise((e=>{this.postDocumentRecord({payload:t,onSuccess:t=>{e(this.handleDocRecordResponse(s,t))},onError:({error:s,code:t,severity:i})=>{this.errorEvent.emit({message:s,errorCode:t,severity:i}),e(!1)}})}))},this.handleDocRecordResponse=(s,t)=>t.error?(this.errorEvent.emit({errorCode:L.POST_ERROR,message:t.error.message,severity:H.ERROR,data:t.error}),!1):(s.setPresignedUrl(t.data.presigned_url),!0),this.uploadDocument=async s=>{if(!s.presigned_url)throw new Error("Presigned URL is not set");const t=await fetch(s.presigned_url,{method:"PUT",body:s.fileString});return this.handleUploadResponse(t)},this.handleUploadResponse=s=>!s.error||(this.errorEvent.emit({errorCode:L.POST_ERROR,message:s.error.message,severity:H.ERROR,data:s.error}),!1),this.formController=void 0,this.errors={},this.bankAccount={},this.existingDocuments=[],this.documentData=new D,this.isLoading=!1,this.businessId=void 0,this.getBusiness=void 0,this.postBankAccount=void 0,this.postDocumentRecord=void 0,this.allowOptionalFields=void 0}watchHandler(s){this.formLoading.emit(s)}async validateAndSubmit({onSuccess:s}){this.existingBankAccount?this.sendData(s):this.formController.validateAndSubmit((()=>this.sendData(s)))}componentWillLoad(){this.getBusiness&&this.getData(),this.formController=new o(q(this.existingDocuments,this.allowOptionalFields))}componentDidLoad(){this.formController.errors.subscribe((s=>{this.errors=Object.assign({},s)}))}get postPayload(){return new W(this.formController.values.getValue()).payload}get existingBankAccount(){var s;return!!(null===(s=this.bankAccount)||void 0===s?void 0:s.id)}async sendData(s){try{if(!this.existingBankAccount&&!await this.postBankAccountData())return;if(!await this.postBusinessDocuments())return;s()}catch(s){this.errorEvent.emit({message:s,errorCode:L.POST_ERROR,severity:H.ERROR})}}async postBankAccountData(){let s;return this.isLoading=!0,new Promise((t=>{let e=!1;this.postBankAccount({payload:this.postPayload,onSuccess:t=>{s=t,e=!0},onError:({error:s,code:t,severity:i})=>{e=!1,this.errorEvent.emit({message:s,errorCode:t,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:s,formStep:g.bankAccount}),this.isLoading=!1,t(e)}})}))}async postBusinessDocuments(){this.isLoading=!0;try{const s=Object.values(this.documentData).flat();return!s.length||!(await Promise.all(s.map((s=>this.postDocumentRecordData(s))))).includes(!1)&&!(await Promise.all(s.map((s=>this.uploadDocument(s))))).includes(!1)}finally{this.isLoading=!1}}render(){const t=this.formController.getInitialValues();return this.isLoading?s(N,null):s("form",null,s("fieldset",{class:"mb-4"},s("div",{class:"d-flex align-items-center gap-2"},s("legend",{class:"mb-0",part:m},"Bank Account Info"),s("form-control-tooltip",{helpText:"This direct deposit account is the designated bank account where incoming funds will be deposited. The name of this account must match the registered business name exactly. We are not able to accept personal accounts unless your business is a registered sole proprietorship."})),s("hr",{class:"mt-2"}),s("bank-account-form-inputs",{defaultValue:t,errors:this.errors,inputHandler:this.inputHandler,formDisabled:this.existingBankAccount})),s("fieldset",{class:"mt-4"},s("div",{class:"d-flex align-items-center gap-2"},s("legend",{class:"mb-0",part:m},"Document Uploads"),s("form-control-tooltip",{helpText:"These documents are required for underwriting purposes. Various file formats such as PDF, DOC, DOCX, JPEG, and others are accepted. Multiple files can be uploaded for each document category."})),s("hr",{class:"mt-2"}),s("business-documents-on-file",{documents:this.existingDocuments,isLoading:this.isLoading}),s("bank-account-document-form-inputs",{inputHandler:this.inputHandler,errors:this.errors,storeFiles:this.storeFiles})))}static get watchers(){return{isLoading:["watchHandler"]}}},Y=class{constructor(s){t(this,s),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.errorEvent=e(this,"error-event",7),this.formLoading=e(this,"formLoading",7),this.getData=()=>{this.formLoading.emit(!0),this.isLoading=!0,this.getBusiness({onSuccess:s=>{this.coreInfo=new l(s.data),this.formController.setInitialValues(Object.assign({},this.coreInfo))},onError:({error:s,code:t,severity:e})=>{this.errorEvent.emit({message:s,errorCode:t,severity:e})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1}})},this.sendData=s=>{let t;this.formLoading.emit(!0),this.patchBusiness({payload:this.patchPayload,onSuccess:e=>{t=e,s()},onError:({error:s,code:e,severity:i})=>{t=s,this.errorEvent.emit({message:s,errorCode:e,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:t,formStep:g.businessInfo}),this.formLoading.emit(!1)}})},this.inputHandler=(s,t)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[s]:t}))},this.formController=void 0,this.errors={},this.coreInfo={},this.isLoading=!1,this.businessId=void 0,this.getBusiness=void 0,this.patchBusiness=void 0,this.allowOptionalFields=void 0}async validateAndSubmit({onSuccess:s}){this.formController.validateAndSubmit((()=>this.sendData(s)))}get patchPayload(){return new l(this.formController.values.getValue()).payload}componentWillLoad(){this.getBusiness&&this.getData(),this.formController=new o(r(this.allowOptionalFields))}componentDidLoad(){this.formController.errors.subscribe((s=>{this.errors=Object.assign({},s)}))}render(){const t=this.formController.getInitialValues();return this.isLoading?s(N,null):s("form",null,s("fieldset",null,s("div",{class:"d-flex align-items-center gap-2"},s("legend",{class:"mb-0",part:m},"Business Information")),s("hr",{class:"mt-2"}),s("div",{class:"row gy-3"},s("div",{class:"col-12"},s("form-control-text",{name:"legal_name",label:"Business Name",defaultValue:t.legal_name,errorText:this.errors.legal_name,inputHandler:this.inputHandler,helpText:"Enter this exactly as it appears on your tax records (don't use acronyms or abbreviations unless you registered that way)."})),s("div",{class:"col-12"},s("form-control-text",{name:"doing_business_as",label:"Doing Business As (DBA)",defaultValue:t.doing_business_as,errorText:this.errors.doing_business_as,inputHandler:this.inputHandler,helpText:"Enter this exactly as it appears on your tax records (leave blank if you don't have a registered DBA/trade name)"})),s("div",{class:"col-12 col-md-8"},s("form-control-select",{name:"classification",label:"Business Classification",options:y,defaultValue:t.classification,errorText:this.errors.classification,inputHandler:this.inputHandler})),s("div",{class:"col-12 col-md-4"},s("form-control-date",{name:"date_of_incorporation",label:"Date of Incorporation",defaultValue:t.date_of_incorporation,errorText:this.errors.date_of_incorporation,inputHandler:this.inputHandler})),s("div",{class:"col-12 col-md-6"},s("form-control-text",{name:"industry",label:"Industry",defaultValue:t.industry,errorText:this.errors.industry,inputHandler:this.inputHandler,helpText:"Describe what you sell"})),s("div",{class:"col-12 col-md-6"},s("form-control-text",{name:"tax_id",label:"Tax ID (EIN or SSN)",defaultValue:t.tax_id,errorText:this.errors.tax_id,inputHandler:this.inputHandler,keyDownHandler:V,maxLength:9,helpText:"Employer Identification Numbers (EINs) are nine digits. The federal tax identification number/EIN issued to you by the IRS. It can be found on your tax returns."})),s("div",{class:"col-12"},s("form-control-text",{name:"website_url",label:"Business Website URL",defaultValue:t.website_url,errorText:this.errors.website_url,inputHandler:this.inputHandler,helpText:"Don't have a live website? You can use your social media business page, app store link, or staging site URL."})),s("div",{class:"col-12 col-md-6"},s("form-control-text",{name:"email",label:"Business Email Address",defaultValue:t.email,errorText:this.errors.email,inputHandler:this.inputHandler})),s("div",{class:"col-12 col-md-6"},s("form-control-number-masked",{name:"phone",label:"Business Phone Number",defaultValue:t.phone,errorText:this.errors.phone,inputHandler:this.inputHandler,mask:u.US})))))}},z=class{constructor(s){t(this,s),this.clickEvent=e(this,"click-event",7),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.errorEvent=e(this,"error-event",7),this.formLoading=e(this,"formLoading",7),this.matchRef=(s,t)=>{const e=this.refs.findIndex((s=>s===t));-1!==e&&(this.refs[e]=s)},this.getData=()=>{this.formLoading.emit(!0),this.isLoading=!0,this.getBusiness({onSuccess:s=>{s.data.owners.length?this.ownersPayload=s.data.owners.map((s=>({id:s.id}))):this.addOwnerForm()},onError:({error:s,code:t,severity:e})=>{this.errorEvent.emit({message:s,errorCode:t,severity:e})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1,this.manageRefs()}})},this.sendData=async s=>{let t;this.formLoading.emit(!0),this.patchBusiness({payload:{owners:this.ownersPayload},onSuccess:e=>{t=e,s()},onError:({error:s,code:e,severity:i})=>{t=s,this.errorEvent.emit({message:s,errorCode:e,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:t,formStep:g.owners}),this.formLoading.emit(!1)}})},this.addOwnerForm=s=>{this.newFormOpen=!0,this.ownersPayload=[...this.ownersPayload,{id:""}],s&&this.clickEvent.emit({name:w.addOwnerForm})},this.removeOwnerForm=s=>{this.ownersPayload=this.ownersPayload.filter((t=>t.id!==s)),this.newFormOpen&&(this.newFormOpen=!1)},this.ownersPayload=[],this.refs=[],this.newFormOpen=void 0,this.isLoading=!1,this.authToken=void 0,this.businessId=void 0,this.getBusiness=void 0,this.patchBusiness=void 0,this.allowOptionalFields=void 0}get showAddOwnerButton(){return this.ownersPayload.length<4&&!this.newFormOpen}manageRefs(){this.refs=this.ownersPayload.map((s=>s.id))}async validateAndSubmit({onSuccess:s}){const t=this.refs.map((s=>s.validate()));if(!(await Promise.all(t)).every((s=>s)))return;const e=this.refs.map((s=>s.submit()));(await Promise.all(e)).every((s=>s))&&this.sendData(s)}componentWillLoad(){this.getBusiness&&this.getData()}ownersWatcher(){this.manageRefs()}handleOwnerSubmit(s){const t=s.detail,e=this.ownersPayload.map((s=>s.id===t.id?t:s));e.includes(t)||(e[this.ownersPayload.findIndex((s=>!s.id))]=t,this.newFormOpen&&(this.newFormOpen=!1)),this.ownersPayload=e}render(){return this.isLoading?s(N,null):s("div",null,s("div",{class:"d-flex align-items-center gap-2"},s("legend",{class:"mb-0",part:m},"Owners"),s("form-control-tooltip",{helpText:"For partnerships, LLCs or privately held corporations, the business is required to apply with all individuals with 25% or more ownership to the application. For charities and registered non-profits, the business is required to apply with 1 individual with substantial control over the entity, such as a board member or director."})),s("hr",{class:"mt-2"}),s("div",{class:"row gy-3"},this.ownersPayload.map((t=>s("justifi-owner-form",{key:t.id,authToken:this.authToken,businessId:this.businessId,ownerId:t.id,removeOwner:this.removeOwnerForm,newFormOpen:this.newFormOpen,ownersLength:this.ownersPayload.length,allowOptionalFields:this.allowOptionalFields,ref:s=>this.matchRef(s,t.id)})))),s("div",{class:"d-flex justify-content-start"},s("div",{class:"gap-2"},s(A,{variant:"primary",onClick:()=>this.addOwnerForm(!0),hidden:!this.showAddOwnerButton},"Add Owner"))))}static get watchers(){return{ownersPayload:["ownersWatcher"]}}},G=class{constructor(s){t(this,s),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.errorEvent=e(this,"error-event",7),this.formLoading=e(this,"formLoading",7),this.getData=()=>{this.formLoading.emit(!0),this.isLoading=!0,this.getBusiness({onSuccess:s=>{this.representative=new h(s.data.representative||{}),this.formController.setInitialValues(Object.assign({},this.representative))},onError:({error:s,code:t,severity:e})=>{this.errorEvent.emit({message:s,errorCode:t,severity:e})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1}})},this.sendData=s=>{let t;this.formLoading.emit(!0),this.patchBusiness({payload:this.patchPayload,onSuccess:e=>{t=e,s()},onError:({error:s,code:e,severity:i})=>{t=s,this.errorEvent.emit({message:s,errorCode:e,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:t,formStep:g.representative}),this.formLoading.emit(!1)}})},this.formController=void 0,this.errors={},this.representative={},this.isLoading=!1,this.getBusiness=void 0,this.patchBusiness=void 0,this.allowOptionalFields=void 0}async validateAndSubmit({onSuccess:s}){this.formController.validateAndSubmit((()=>this.sendData(s)))}get patchPayload(){return{representative:new h(this.formController.values.getValue()).payload}}componentWillLoad(){this.getBusiness&&this.getData(),this.formController=new o(P("representative",this.allowOptionalFields))}componentDidLoad(){this.formController.errors.subscribe((s=>{this.errors=Object.assign({},s)}))}render(){return this.isLoading?s(N,null):s("justifi-business-representative-form-inputs",{representativeDefaultValue:this.formController.getInitialValues(),errors:this.errors,formController:this.formController})}},J=class{constructor(s){t(this,s),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.errorEvent=e(this,"error-event",7),this.formLoading=e(this,"formLoading",7),this.getData=()=>{this.formLoading.emit(!0),this.isLoading=!0,this.getBusiness({onSuccess:s=>{this.legal_address=new c(s.data.legal_address||{}),this.formController.setInitialValues(Object.assign({},this.legal_address))},onError:({error:s,code:t,severity:e})=>{this.errorEvent.emit({message:s,errorCode:t,severity:e})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1}})},this.sendData=s=>{let t;this.formLoading.emit(!0),this.patchBusiness({payload:this.patchPayload,onSuccess:e=>{t=e,s()},onError:({error:s,code:e,severity:i})=>{t=s,this.errorEvent.emit({message:s,errorCode:e,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:t,formStep:g.legalAddress}),this.formLoading.emit(!1)}})},this.inputHandler=(s,t)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[s]:t}))},this.formController=void 0,this.errors={},this.legal_address={},this.isLoading=!1,this.getBusiness=void 0,this.patchBusiness=void 0,this.allowOptionalFields=void 0}async validateAndSubmit({onSuccess:s}){this.formController.validateAndSubmit((()=>this.sendData(s)))}get patchPayload(){return{legal_address:new c(this.formController.values.getValue()).payload}}componentWillLoad(){this.getBusiness&&this.getData(),this.formController=new o(B(this.allowOptionalFields))}componentDidLoad(){this.formController.errors.subscribe((s=>{this.errors=Object.assign({},s)}))}render(){var t,e,i,r,o,n;const a=this.formController.getInitialValues();return this.isLoading?s(N,null):s("form",null,s("fieldset",null,s("div",{class:"d-flex align-items-center gap-2"},s("legend",{class:"mb-0",part:m},"Legal Address of your Business"),s("form-control-tooltip",{helpText:"No PO Boxes."})),s("hr",{class:"mt-2"}),s("div",{class:"row gy-3"},s("div",{class:"col-12"},s("form-control-text",{name:"line1",label:"Legal Address",inputHandler:this.inputHandler,defaultValue:null==a?void 0:a.line1,errorText:null===(t=this.errors)||void 0===t?void 0:t.line1})),s("div",{class:"col-12"},s("form-control-text",{name:"line2",label:"Address Line 2 (optional)",inputHandler:this.inputHandler,defaultValue:null==a?void 0:a.line2,errorText:null===(e=this.errors)||void 0===e?void 0:e.line2})),s("div",{class:"col-12"},s("form-control-text",{name:"city",label:"City",inputHandler:this.inputHandler,defaultValue:null==a?void 0:a.city,errorText:null===(i=this.errors)||void 0===i?void 0:i.city})),s("div",{class:"col-12"},s("form-control-select",{name:"state",label:"State",options:I,inputHandler:this.inputHandler,defaultValue:null==a?void 0:a.state,errorText:null===(r=this.errors)||void 0===r?void 0:r.state})),s("div",{class:"col-12"},s("form-control-text",{name:"postal_code",label:"Postal Code",inputHandler:this.inputHandler,defaultValue:null==a?void 0:a.postal_code,errorText:null===(o=this.errors)||void 0===o?void 0:o.postal_code,maxLength:5,keyDownHandler:V})),s("div",{class:"col-12"},s("form-control-select",{name:"country",label:"Country",options:[{label:"United States",value:"USA"}],inputHandler:this.inputHandler,defaultValue:null==a?void 0:a.country,errorText:null===(n=this.errors)||void 0===n?void 0:n.country,disabled:!0})))))}};export{U as justifi_additional_questions_form_step_core,R as justifi_business_bank_account_form_step_core,Y as justifi_business_core_info_form_step_core,z as justifi_business_owners_form_step_core,G as justifi_business_representative_form_step_core,J as justifi_legal_address_form_step_core}
1
+ import{h as s,r as t,c as e}from"./p-2783e363.js";import{a as i,b as r}from"./p-4acf8ca2.js";import{F as o,c as n}from"./p-5844a0f0.js";import{A as a,C as l,R as h,c}from"./p-5d1d2fd7.js";import{C as d,P as u}from"./p-525db3e8.js";import{h as m}from"./p-f2111e68.js";import{S as p}from"./p-a3d75257.js";import{a as v,r as f,s as b,b as y}from"./p-c9b78275.js";import{a as g,B as w}from"./p-73f9be7c.js";import{z as _,A as x,u as j,B as S,C as T,D as O,E as k,F as C}from"./p-95e55bb1.js";import{C as L,a as H}from"./p-9dd8685c.js";import"./p-daf0303f.js";import"./p-56f6ce4c.js";import"./p-9894484a.js";import"./p-382ab4e8.js";import{a as E,b as D}from"./p-61f0a2ce.js";import{n as V}from"./p-e3c22aa9.js";import{B as A}from"./p-e60867c6.js";import{i as P,a as B}from"./p-d43a38a4.js";import{S as I}from"./p-6078a370.js";import"./p-1ff8810b.js";import"./p-2ca5b5e4.js";import"./p-abdbcd8e.js";class W{constructor(s){this.id=s.id,this.account_owner_name=s.account_owner_name,this.full_name=s.full_name,this.account_type=s.account_type,this.account_number=s.account_number,this.acct_last_four=s.acct_last_four,this.account_number_last4=s.account_number_last4,this.routing_number=s.routing_number,this.bank_name=s.bank_name,this.country=s.country,this.currency=s.currency,this.nickname=s.nickname,this.metadata=s.metadata,this.business_id=s.business_id,this.platform_account_id=s.platform_account_id,this.created_at=s.created_at,this.updated_at=s.updated_at}get payload(){return{account_owner_name:this.account_owner_name||"",account_type:this.account_type||"",account_number:this.account_number||"",routing_number:this.routing_number||"",bank_name:this.bank_name||"",nickname:this.nickname||"",business_id:this.business_id||""}}}const F=()=>s("div",{class:"row gap-3"},s("div",{class:"col-12"},s(p,{width:"25%"})),s("div",{class:"col-12"},s(p,{width:"100%"})),s("div",{class:"col-12 d-flex gap-3"},s(p,{width:"50%"}),s(p,{width:"50%"})),s("div",{class:"col-12 d-flex gap-3"},s(p,{width:"65%"}),s(p,{width:"35%"}))),N=()=>s("div",{class:"row gap-5"},s("div",{class:"col-12"},s(p,{width:"40%",height:"40px"})),s(F,null),s(F,null),s(F,null)),U=class{constructor(s){t(this,s),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.errorEvent=e(this,"error-event",7),this.formLoading=e(this,"formLoading",7),this.getData=()=>{this.formLoading.emit(!0),this.isLoading=!0,this.getBusiness({onSuccess:s=>{this.additional_questions=new a(s.data.additional_questions||{}),this.formController.setInitialValues(Object.assign({},this.additional_questions))},onError:({error:s,code:t,severity:e})=>{this.errorEvent.emit({message:s,errorCode:t,severity:e})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1}})},this.sendData=s=>{let t;this.formLoading.emit(!0),this.patchBusiness({payload:this.patchPayload,onSuccess:e=>{t=e,s()},onError:({error:s,code:e,severity:i})=>{t=s,this.errorEvent.emit({message:s,errorCode:e,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:t,formStep:g.additionalQuestions}),this.formLoading.emit(!1)}})},this.inputHandler=(s,t)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[s]:t})),this.additional_questions=new a(Object.assign(Object.assign({},this.formController.values.getValue()),{[s]:t}))},this.formController=void 0,this.errors={},this.additional_questions={},this.recurringPayments=!1,this.isLoading=!1,this.getBusiness=void 0,this.patchBusiness=void 0,this.allowOptionalFields=void 0}recurringPaymentsWatcher(s){this.recurringPayments="Yes"===(null==s?void 0:s.business_recurring_payments)}async validateAndSubmit({onSuccess:s}){this.formController.validateAndSubmit((()=>this.sendData(s)))}get patchPayload(){return{additional_questions:new a(this.formController.values.getValue()).payload}}componentWillLoad(){this.getBusiness&&this.getData(),this.formController=new o(i(this.allowOptionalFields))}componentDidLoad(){this.formController.errors.subscribe((s=>{this.errors=Object.assign({},s)}))}render(){var t,e,i,r,o,n,a;const l=this.formController.getInitialValues();return this.isLoading?s(N,null):s("form",null,s("fieldset",null,s("div",{class:"d-flex align-items-center gap-2"},s("legend",{class:"mb-0",part:m},"Additional Questions"),s("form-control-tooltip",{helpText:"This information helps us understand the business and identify and monitor trends to safeguard you and your customers."})),s("hr",{class:"mt-2"}),s("div",{class:"row gy-3"},s("div",{class:"col-12 col-md-6"},s("form-control-monetary",{name:"business_revenue",label:"What is your business’ estimated annual revenue from its primary business activities?",inputHandler:this.inputHandler,errorText:null===(t=this.errors)||void 0===t?void 0:t.business_revenue,defaultValue:null==l?void 0:l.business_revenue,maskOptions:d.WHOLE})),s("div",{class:"col-12 col-md-6"},s("form-control-monetary",{name:"business_payment_volume",label:"What is your business' annual credit card & ACH volume anticipated to process?",inputHandler:this.inputHandler,errorText:null===(e=this.errors)||void 0===e?void 0:e.business_payment_volume,defaultValue:null==l?void 0:l.business_payment_volume,maskOptions:d.WHOLE})),s("div",{class:"col-12"},s("form-control-select",{name:"business_when_service_received",label:"On average, how long after paying will your customers typically receive their goods or services?",inputHandler:this.inputHandler,errorText:null===(i=this.errors)||void 0===i?void 0:i.business_when_service_received,options:v,defaultValue:null==l?void 0:l.business_when_service_received})),s("div",{class:"col-12"},s("form-control-select",{name:"business_recurring_payments",label:"Does your business offer recurring payments?",inputHandler:this.inputHandler,errorText:null===(r=this.errors)||void 0===r?void 0:r.business_recurring_payments,options:f,defaultValue:null==l?void 0:l.business_recurring_payments})),s("div",{class:"col-12",hidden:!this.recurringPayments},s("form-control-text",{name:"business_recurring_payments_percentage",label:"What percent of revenue is generated from each recurring payment type offered?",inputHandler:this.inputHandler,errorText:null===(o=this.errors)||void 0===o?void 0:o.business_recurring_payments_percentage,defaultValue:null==l?void 0:l.business_recurring_payments_percentage,helpText:"For example: 50% monthly, 50% annual."})),s("div",{class:"col-12"},s("form-control-select",{name:"business_seasonal",label:"Is this business seasonal?",inputHandler:this.inputHandler,errorText:null===(n=this.errors)||void 0===n?void 0:n.business_seasonal,options:b,defaultValue:null==l?void 0:l.business_seasonal})),s("div",{class:"col-12"},s("form-control-text",{name:"business_other_payment_details",label:"Is there anything else you would like us to know about how your customers pay the business? (optional)",inputHandler:this.inputHandler,errorText:null===(a=this.errors)||void 0===a?void 0:a.business_other_payment_details,defaultValue:null==l?void 0:l.business_other_payment_details})))))}static get watchers(){return{additional_questions:["recurringPaymentsWatcher"]}}},q=(s,t)=>{const e=n({bank_name:_.required("Enter bank name"),nickname:x.required("Enter nickname"),account_owner_name:j.required("Enter account owner name"),account_type:S.required("Select account type"),account_number:T.required("Enter account number"),routing_number:O.required("Enter routing number"),voided_check:k(s,t),bank_statement:C(s,t)}),i=n({bank_name:_.nullable(),nickname:x.nullable(),account_owner_name:j.nullable(),account_type:S.nullable(),account_number:T.nullable(),routing_number:O.nullable(),voided_check:k(s,t),bank_statement:C(s,t)});return t?i:e},R=class{constructor(s){t(this,s),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.errorEvent=e(this,"error-event",7),this.formLoading=e(this,"formLoading",7),this.initializeFormController=()=>{this.formController=new o(q(this.existingDocuments,this.allowOptionalFields)),this.formController.setInitialValues(Object.assign({},this.bankAccount)),this.formController.errors.subscribe((s=>{this.errors=Object.assign({},s)}))},this.inputHandler=(s,t)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[s]:t}))},this.storeFiles=s=>{const t=Array.from(s.detail.fileList),e=s.detail.document_type,i=t.map((s=>new E({file:s,document_type:e},this.businessId)));this.documentData[e]=i},this.getData=()=>{this.isLoading=!0,this.getBusiness({onSuccess:s=>{s.data.bank_accounts.length>0?this.bankAccount=new W(s.data.bank_accounts[0]):(this.bankAccount=new W({}),this.bankAccount.business_id=this.businessId),this.existingDocuments=s.data.documents},onError:({error:s,code:t,severity:e})=>{this.errorEvent.emit({message:s,errorCode:t,severity:e})},final:()=>{this.initializeFormController(),this.isLoading=!1}})},this.postDocumentRecordData=async s=>{this.isLoading=!0;const t=s.record_data;return new Promise((e=>{this.postDocumentRecord({payload:t,onSuccess:t=>{e(this.handleDocRecordResponse(s,t))},onError:({error:s,code:t,severity:i})=>{this.errorEvent.emit({message:s,errorCode:t,severity:i}),e(!1)}})}))},this.handleDocRecordResponse=(s,t)=>t.error?(this.errorEvent.emit({errorCode:L.POST_ERROR,message:t.error.message,severity:H.ERROR,data:t.error}),!1):(s.setPresignedUrl(t.data.presigned_url),!0),this.uploadDocument=async s=>{if(!s.presigned_url)throw new Error("Presigned URL is not set");const t=await fetch(s.presigned_url,{method:"PUT",body:s.fileString});return this.handleUploadResponse(t)},this.handleUploadResponse=s=>!s.error||(this.errorEvent.emit({errorCode:L.POST_ERROR,message:s.error.message,severity:H.ERROR,data:s.error}),!1),this.formController=void 0,this.errors={},this.bankAccount={},this.existingDocuments=[],this.documentData=new D,this.isLoading=!1,this.businessId=void 0,this.getBusiness=void 0,this.postBankAccount=void 0,this.postDocumentRecord=void 0,this.allowOptionalFields=void 0}watchHandler(s){this.formLoading.emit(s)}async validateAndSubmit({onSuccess:s}){this.existingBankAccount?this.sendData(s):this.formController.validateAndSubmit((()=>this.sendData(s)))}componentWillLoad(){this.getBusiness&&this.getData(),this.formController=new o(q(this.existingDocuments,this.allowOptionalFields))}componentDidLoad(){this.formController.errors.subscribe((s=>{this.errors=Object.assign({},s)}))}get postPayload(){return new W(this.formController.values.getValue()).payload}get existingBankAccount(){var s;return!!(null===(s=this.bankAccount)||void 0===s?void 0:s.id)}async sendData(s){try{if(!this.existingBankAccount&&!await this.postBankAccountData())return;if(!await this.postBusinessDocuments())return;s()}catch(s){this.errorEvent.emit({message:s,errorCode:L.POST_ERROR,severity:H.ERROR})}}async postBankAccountData(){let s;return this.isLoading=!0,new Promise((t=>{let e=!1;this.postBankAccount({payload:this.postPayload,onSuccess:t=>{s=t,e=!0},onError:({error:s,code:t,severity:i})=>{e=!1,this.errorEvent.emit({message:s,errorCode:t,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:s,formStep:g.bankAccount}),this.isLoading=!1,t(e)}})}))}async postBusinessDocuments(){this.isLoading=!0;try{const s=Object.values(this.documentData).flat();return!s.length||!(await Promise.all(s.map((s=>this.postDocumentRecordData(s))))).includes(!1)&&!(await Promise.all(s.map((s=>this.uploadDocument(s))))).includes(!1)}finally{this.isLoading=!1}}render(){const t=this.formController.getInitialValues();return this.isLoading?s(N,null):s("form",null,s("fieldset",{class:"mb-4"},s("div",{class:"d-flex align-items-center gap-2"},s("legend",{class:"mb-0",part:m},"Bank Account Info"),s("form-control-tooltip",{helpText:"This direct deposit account is the designated bank account where incoming funds will be deposited. The name of this account must match the registered business name exactly. We are not able to accept personal accounts unless your business is a registered sole proprietorship."})),s("hr",{class:"mt-2"}),s("bank-account-form-inputs",{defaultValue:t,errors:this.errors,inputHandler:this.inputHandler,formDisabled:this.existingBankAccount})),s("fieldset",{class:"mt-4"},s("div",{class:"d-flex align-items-center gap-2"},s("legend",{class:"mb-0",part:m},"Document Uploads"),s("form-control-tooltip",{helpText:"These documents are required for underwriting purposes. Various file formats such as PDF, DOC, DOCX, JPEG, and others are accepted. Multiple files can be uploaded for each document category."})),s("hr",{class:"mt-2"}),s("business-documents-on-file",{documents:this.existingDocuments,isLoading:this.isLoading}),s("bank-account-document-form-inputs",{inputHandler:this.inputHandler,errors:this.errors,storeFiles:this.storeFiles})))}static get watchers(){return{isLoading:["watchHandler"]}}},Y=class{constructor(s){t(this,s),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.errorEvent=e(this,"error-event",7),this.formLoading=e(this,"formLoading",7),this.getData=()=>{this.formLoading.emit(!0),this.isLoading=!0,this.getBusiness({onSuccess:s=>{this.coreInfo=new l(s.data),this.formController.setInitialValues(Object.assign({},this.coreInfo))},onError:({error:s,code:t,severity:e})=>{this.errorEvent.emit({message:s,errorCode:t,severity:e})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1}})},this.sendData=s=>{let t;this.formLoading.emit(!0),this.patchBusiness({payload:this.patchPayload,onSuccess:e=>{t=e,s()},onError:({error:s,code:e,severity:i})=>{t=s,this.errorEvent.emit({message:s,errorCode:e,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:t,formStep:g.businessInfo}),this.formLoading.emit(!1)}})},this.inputHandler=(s,t)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[s]:t}))},this.formController=void 0,this.errors={},this.coreInfo={},this.isLoading=!1,this.businessId=void 0,this.getBusiness=void 0,this.patchBusiness=void 0,this.allowOptionalFields=void 0}async validateAndSubmit({onSuccess:s}){this.formController.validateAndSubmit((()=>this.sendData(s)))}get patchPayload(){return new l(this.formController.values.getValue()).payload}componentWillLoad(){this.getBusiness&&this.getData(),this.formController=new o(r(this.allowOptionalFields))}componentDidLoad(){this.formController.errors.subscribe((s=>{this.errors=Object.assign({},s)}))}render(){const t=this.formController.getInitialValues();return this.isLoading?s(N,null):s("form",null,s("fieldset",null,s("div",{class:"d-flex align-items-center gap-2"},s("legend",{class:"mb-0",part:m},"Business Information")),s("hr",{class:"mt-2"}),s("div",{class:"row gy-3"},s("div",{class:"col-12"},s("form-control-text",{name:"legal_name",label:"Business Name",defaultValue:t.legal_name,errorText:this.errors.legal_name,inputHandler:this.inputHandler,helpText:"Enter this exactly as it appears on your tax records (don't use acronyms or abbreviations unless you registered that way)."})),s("div",{class:"col-12"},s("form-control-text",{name:"doing_business_as",label:"Doing Business As (DBA)",defaultValue:t.doing_business_as,errorText:this.errors.doing_business_as,inputHandler:this.inputHandler,helpText:"Enter this exactly as it appears on your tax records (leave blank if you don't have a registered DBA/trade name)"})),s("div",{class:"col-12 col-md-8"},s("form-control-select",{name:"classification",label:"Business Classification",options:y,defaultValue:t.classification,errorText:this.errors.classification,inputHandler:this.inputHandler})),s("div",{class:"col-12 col-md-4"},s("form-control-date",{name:"date_of_incorporation",label:"Date of Incorporation",defaultValue:t.date_of_incorporation,errorText:this.errors.date_of_incorporation,inputHandler:this.inputHandler})),s("div",{class:"col-12 col-md-6"},s("form-control-text",{name:"industry",label:"Industry",defaultValue:t.industry,errorText:this.errors.industry,inputHandler:this.inputHandler,helpText:"Describe what you sell"})),s("div",{class:"col-12 col-md-6"},s("form-control-text",{name:"tax_id",label:"Tax ID (EIN or SSN)",defaultValue:t.tax_id,errorText:this.errors.tax_id,inputHandler:this.inputHandler,keyDownHandler:V,maxLength:9,helpText:"Employer Identification Numbers (EINs) are nine digits. The federal tax identification number/EIN issued to you by the IRS. It can be found on your tax returns."})),s("div",{class:"col-12"},s("form-control-text",{name:"website_url",label:"Business Website URL",defaultValue:t.website_url,errorText:this.errors.website_url,inputHandler:this.inputHandler,helpText:"Don't have a live website? You can use your social media business page, app store link, or staging site URL."})),s("div",{class:"col-12 col-md-6"},s("form-control-text",{name:"email",label:"Business Email Address",defaultValue:t.email,errorText:this.errors.email,inputHandler:this.inputHandler})),s("div",{class:"col-12 col-md-6"},s("form-control-number-masked",{name:"phone",label:"Business Phone Number",defaultValue:t.phone,errorText:this.errors.phone,inputHandler:this.inputHandler,mask:u.US})))))}},z=class{constructor(s){t(this,s),this.clickEvent=e(this,"click-event",7),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.errorEvent=e(this,"error-event",7),this.formLoading=e(this,"formLoading",7),this.matchRef=(s,t)=>{const e=this.refs.findIndex((s=>s===t));-1!==e&&(this.refs[e]=s)},this.getData=()=>{this.formLoading.emit(!0),this.isLoading=!0,this.getBusiness({onSuccess:s=>{s.data.owners.length?this.ownersPayload=s.data.owners.map((s=>({id:s.id}))):this.addOwnerForm()},onError:({error:s,code:t,severity:e})=>{this.errorEvent.emit({message:s,errorCode:t,severity:e})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1,this.manageRefs()}})},this.sendData=async s=>{let t;this.formLoading.emit(!0),this.patchBusiness({payload:{owners:this.ownersPayload},onSuccess:e=>{t=e,s()},onError:({error:s,code:e,severity:i})=>{t=s,this.errorEvent.emit({message:s,errorCode:e,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:t,formStep:g.owners}),this.formLoading.emit(!1)}})},this.addOwnerForm=s=>{this.newFormOpen=!0,this.ownersPayload=[...this.ownersPayload,{id:""}],s&&this.clickEvent.emit({name:w.addOwnerForm})},this.removeOwnerForm=s=>{this.ownersPayload=this.ownersPayload.filter((t=>t.id!==s)),this.newFormOpen&&(this.newFormOpen=!1)},this.ownersPayload=[],this.refs=[],this.newFormOpen=void 0,this.isLoading=!1,this.authToken=void 0,this.businessId=void 0,this.getBusiness=void 0,this.patchBusiness=void 0,this.allowOptionalFields=void 0}get showAddOwnerButton(){return this.ownersPayload.length<4&&!this.newFormOpen}manageRefs(){this.refs=this.ownersPayload.map((s=>s.id))}async validateAndSubmit({onSuccess:s}){const t=this.refs.map((s=>s.validate()));if(!(await Promise.all(t)).every((s=>s)))return;const e=this.refs.map((s=>s.submit()));(await Promise.all(e)).every((s=>s))&&this.sendData(s)}componentWillLoad(){this.getBusiness&&this.getData()}ownersWatcher(){this.manageRefs()}handleOwnerSubmit(s){const t=s.detail,e=this.ownersPayload.map((s=>s.id===t.id?t:s));e.includes(t)||(e[this.ownersPayload.findIndex((s=>!s.id))]=t,this.newFormOpen&&(this.newFormOpen=!1)),this.ownersPayload=e}render(){return this.isLoading?s(N,null):s("div",null,s("div",{class:"d-flex align-items-center gap-2"},s("legend",{class:"mb-0",part:m},"Owners"),s("form-control-tooltip",{helpText:"For partnerships, LLCs or privately held corporations, the business is required to apply with all individuals with 25% or more ownership to the application. For charities and registered non-profits, the business is required to apply with 1 individual with substantial control over the entity, such as a board member or director."})),s("hr",{class:"mt-2"}),s("div",{class:"row gy-3"},this.ownersPayload.map((t=>s("justifi-owner-form",{key:t.id,authToken:this.authToken,businessId:this.businessId,ownerId:t.id,removeOwner:this.removeOwnerForm,newFormOpen:this.newFormOpen,ownersLength:this.ownersPayload.length,allowOptionalFields:this.allowOptionalFields,ref:s=>this.matchRef(s,t.id)})))),s("div",{class:"d-flex justify-content-start"},s("div",{class:"gap-2"},s(A,{variant:"primary",onClick:()=>this.addOwnerForm(!0),hidden:!this.showAddOwnerButton},"Add Owner"))))}static get watchers(){return{ownersPayload:["ownersWatcher"]}}},G=class{constructor(s){t(this,s),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.errorEvent=e(this,"error-event",7),this.formLoading=e(this,"formLoading",7),this.getData=()=>{this.formLoading.emit(!0),this.isLoading=!0,this.getBusiness({onSuccess:s=>{this.representative=new h(s.data.representative||{}),this.formController.setInitialValues(Object.assign({},this.representative))},onError:({error:s,code:t,severity:e})=>{this.errorEvent.emit({message:s,errorCode:t,severity:e})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1}})},this.sendData=s=>{let t;this.formLoading.emit(!0),this.patchBusiness({payload:this.patchPayload,onSuccess:e=>{t=e,s()},onError:({error:s,code:e,severity:i})=>{t=s,this.errorEvent.emit({message:s,errorCode:e,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:t,formStep:g.representative}),this.formLoading.emit(!1)}})},this.formController=void 0,this.errors={},this.representative={},this.isLoading=!1,this.getBusiness=void 0,this.patchBusiness=void 0,this.allowOptionalFields=void 0}async validateAndSubmit({onSuccess:s}){this.formController.validateAndSubmit((()=>this.sendData(s)))}get patchPayload(){return{representative:new h(this.formController.values.getValue()).payload}}componentWillLoad(){this.getBusiness&&this.getData(),this.formController=new o(P("representative",this.allowOptionalFields))}componentDidLoad(){this.formController.errors.subscribe((s=>{this.errors=Object.assign({},s)}))}render(){return this.isLoading?s(N,null):s("justifi-business-representative-form-inputs",{representativeDefaultValue:this.formController.getInitialValues(),errors:this.errors,formController:this.formController})}},J=class{constructor(s){t(this,s),this.stepCompleteEvent=e(this,"complete-form-step-event",7),this.errorEvent=e(this,"error-event",7),this.formLoading=e(this,"formLoading",7),this.getData=()=>{this.formLoading.emit(!0),this.isLoading=!0,this.getBusiness({onSuccess:s=>{this.legal_address=new c(s.data.legal_address||{}),this.formController.setInitialValues(Object.assign({},this.legal_address))},onError:({error:s,code:t,severity:e})=>{this.errorEvent.emit({message:s,errorCode:t,severity:e})},final:()=>{this.formLoading.emit(!1),this.isLoading=!1}})},this.sendData=s=>{let t;this.formLoading.emit(!0),this.patchBusiness({payload:this.patchPayload,onSuccess:e=>{t=e,s()},onError:({error:s,code:e,severity:i})=>{t=s,this.errorEvent.emit({message:s,errorCode:e,severity:i})},final:()=>{this.stepCompleteEvent.emit({response:t,formStep:g.legalAddress}),this.formLoading.emit(!1)}})},this.inputHandler=(s,t)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[s]:t}))},this.formController=void 0,this.errors={},this.legal_address={},this.isLoading=!1,this.getBusiness=void 0,this.patchBusiness=void 0,this.allowOptionalFields=void 0}async validateAndSubmit({onSuccess:s}){this.formController.validateAndSubmit((()=>this.sendData(s)))}get patchPayload(){return{legal_address:new c(this.formController.values.getValue()).payload}}componentWillLoad(){this.getBusiness&&this.getData(),this.formController=new o(B(this.allowOptionalFields))}componentDidLoad(){this.formController.errors.subscribe((s=>{this.errors=Object.assign({},s)}))}render(){var t,e,i,r,o,n;const a=this.formController.getInitialValues();return this.isLoading?s(N,null):s("form",null,s("fieldset",null,s("div",{class:"d-flex align-items-center gap-2"},s("legend",{class:"mb-0",part:m},"Legal Address of your Business"),s("form-control-tooltip",{helpText:"No PO Boxes."})),s("hr",{class:"mt-2"}),s("div",{class:"row gy-3"},s("div",{class:"col-12"},s("form-control-text",{name:"line1",label:"Legal Address",inputHandler:this.inputHandler,defaultValue:null==a?void 0:a.line1,errorText:null===(t=this.errors)||void 0===t?void 0:t.line1})),s("div",{class:"col-12"},s("form-control-text",{name:"line2",label:"Address Line 2 (optional)",inputHandler:this.inputHandler,defaultValue:null==a?void 0:a.line2,errorText:null===(e=this.errors)||void 0===e?void 0:e.line2})),s("div",{class:"col-12"},s("form-control-text",{name:"city",label:"City",inputHandler:this.inputHandler,defaultValue:null==a?void 0:a.city,errorText:null===(i=this.errors)||void 0===i?void 0:i.city})),s("div",{class:"col-12"},s("form-control-select",{name:"state",label:"State",options:I,inputHandler:this.inputHandler,defaultValue:null==a?void 0:a.state,errorText:null===(r=this.errors)||void 0===r?void 0:r.state})),s("div",{class:"col-12"},s("form-control-text",{name:"postal_code",label:"Postal Code",inputHandler:this.inputHandler,defaultValue:null==a?void 0:a.postal_code,errorText:null===(o=this.errors)||void 0===o?void 0:o.postal_code,maxLength:5,keyDownHandler:V})),s("div",{class:"col-12"},s("form-control-select",{name:"country",label:"Country",options:[{label:"United States",value:"USA"}],inputHandler:this.inputHandler,defaultValue:null==a?void 0:a.country,errorText:null===(n=this.errors)||void 0===n?void 0:n.country,disabled:!0})))))}};export{U as justifi_additional_questions_form_step_core,R as justifi_business_bank_account_form_step_core,Y as justifi_business_core_info_form_step_core,z as justifi_business_owners_form_step_core,G as justifi_business_representative_form_step_core,J as justifi_legal_address_form_step_core}
@@ -1 +1 @@
1
- import{A as t}from"./p-0e180654.js";import"./p-9dd8685c.js";import"./p-daf0303f.js";import"./p-56f6ce4c.js";import"./p-9894484a.js";import"./p-e0befd51.js";import"./p-61f0a2ce.js";class c{async fetchCheckout(c,o){const p=`checkouts/${o}`;return t({authToken:c,apiOrigin:"https://wc-proxy.justifi.ai"}).get(p)}async fetchCheckouts(c,o,p,s){s||(s="https://wc-proxy.justifi.ai");const e={Account:c};return t({authToken:o,apiOrigin:s}).get("checkouts",p,null,e)}async complete(c,o,p){const s=`checkouts/${o}/complete`,e={payment_mode:p.payment_mode};return p.payment_token&&(e.payment_token=p.payment_token),t({authToken:c,apiOrigin:"https://wc-proxy.justifi.ai"}).post(s,e)}}export{c as C}
1
+ import{A as t}from"./p-0e180654.js";import"./p-9dd8685c.js";import"./p-daf0303f.js";import"./p-56f6ce4c.js";import"./p-9894484a.js";import"./p-382ab4e8.js";import"./p-61f0a2ce.js";class c{async fetchCheckout(c,o){const p=`checkouts/${o}`;return t({authToken:c,apiOrigin:"https://wc-proxy.justifi.ai"}).get(p)}async fetchCheckouts(c,o,p,s){s||(s="https://wc-proxy.justifi.ai");const i={Account:c};return t({authToken:o,apiOrigin:s}).get("checkouts",p,null,i)}async complete(c,o,p){const s=`checkouts/${o}/complete`,i={payment_mode:p.payment_mode};return p.payment_token&&(i.payment_token=p.payment_token),t({authToken:c,apiOrigin:"https://wc-proxy.justifi.ai"}).post(s,i)}}export{c as C}
@@ -0,0 +1 @@
1
+ import{f as t}from"./p-2ca5b5e4.js";var i,s,h,n,e,a,o,c,r;!function(t){t.paid="paid",t.failed="failed",t.forwarded="forwarded",t.scheduled="scheduled",t.in_transit="in_transit",t.canceled="canceled"}(i||(i={})),function(t){t.paid="Paid",t.failed="Failed",t.forwarded="Forwarded",t.scheduled="Scheduled",t.in_transit="In Transit",t.canceled="Canceled"}(s||(s={}));class d{constructor(t){this.id=t.id,this.account_id=t.account_id,this.currency=t.currency,this.amount=t.amount,this.bank_account=t.bank_account,this.delivery_method=t.delivery_method||"standard",this.description=t.description,this.deposits_at=t.deposits_at,this.fees_total=t.fees_total,this.refunds_count=t.refunds_count,this.refunds_total=t.refunds_total,this.payments_count=t.payments_count,this.payments_total=t.payments_total,this.payout_type=t.payout_type,this.other_total=t.other_total,this.status=t.status,this.metadata=t.metadata,this.created_at=t.created_at,this.updated_at=t.updated_at}formattedPaymentAmount(i){return t(i,this.currency)}}!function(t){t.connected="connected",t.disconnected="disconnected",t.unknown="unknown"}(h||(h={})),function(t){t.verifone="verifone"}(n||(n={}));class u{constructor(t){this.id=t.id||"",this.status=t.status,this.account_id=t.account_id||"",this.platform_account_id=t.platform_account_id||"",this.provider=t.provider||"",this.provider_id=t.provider_id||"",this.provider_serial_number=t.provider_serial_number||"",this.created_at=t.created_at||"",this.updated_at=t.updated_at||"",this.verified_at=t.verified_at||"",this.nickname=t.nickname||""}}!function(t){t.boardingOnly="boarding_only",t.boardingShipping="boarding_shipping"}(e||(e={})),function(t){t.created="created",t.submitted="submitted",t.completed="completed"}(a||(a={}));class l{constructor(t){this.id=t.id,this.business_id=t.business_id,this.account_id=t.account_id,this.provider=t.provider||n.verifone,this.order_items=[],this.order_type=t.order_type,this.order_status=t.order_status,this.terminals=t.terminals,this.created_at=t.created_at,this.updated_at=t.updated_at}get payload(){return{business_id:this.business_id,account_id:this.account_id,order_type:this.order_type,order_items:this.order_items}}get totalQuantity(){return this.order_items.reduce(((t,i)=>t+i.quantity),0)}updateTerminal(t,i){if(0===i)return void(this.order_items=this.order_items.filter((i=>i.model_name!==t)));const s=this.order_items.find((i=>i.model_name===t));s?s.quantity=i:this.order_items.push({model_name:t,quantity:i})}}!function(t){t.v400="v400",t.p400="p400+",t.e285="e285"}(o||(o={}));class f{constructor(t){this.id=t.id,this.model_name=t.model_name,this.description=t.description,this.image_url=t.image_url,this.help_url=t.help_url}}!function(t){t.test="test",t.live="live"}(c||(c={})),function(t){t.created="created",t.submitted="submitted",t.information_needed="information_needed",t.rejected="rejected",t.enabled="enabled",t.disabled="disabled",t.archived="archived"}(r||(r={}));class m{constructor(t){this.id=t.id,this.name=t.name,this.account_type=t.account_type,this.status=t.status,this.currency=t.currency,this.platform_account_id=t.platform_account_id,this.payout_account_id=t.payout_account_id,this.business_id=t.business_id,this.application_fee_rates=t.application_fee_rates,this.processing_ready=t.processing_ready,this.payout_ready=t.payout_ready,this.related_accounts=t.related_accounts,this.created_at=t.created_at,this.updated_at=t.updated_at}}export{h as I,d as P,m as S,f as T,l as a,e as b,u as c}
@@ -0,0 +1 @@
1
+ import{r as e,h as a}from"./p-2783e363.js";import{c as i,a as t,F as c}from"./p-5844a0f0.js";import{B as d}from"./p-f2111e68.js";const s=i({additional_statement:t().nullable()});var o,l;!function(e){e.disputeReason="dispute_reason",e.productOrService="product_or_service",e.customerDetails="customer_details",e.cancellationPolicy="cancellation_policy",e.refundPolicy="refund_policy",e.duplicateCharge="duplicate_charge",e.electronicEvidence="electronic_evidence",e.shippingDetails="shipping_details",e.additionalStatement="additional_statement"}(o||(o={})),function(e){e.activity_log="activity_log",e.cancellationPolicy="cancellation_policy",e.customerCommunication="customer_communication",e.customerSignature="customer_signature",e.duplicateChargeDocumentation="duplicate_charge_documentation",e.receipt="receipt",e.refundPolicy="refund_policy",e.serviceDocumentation="service_documentation",e.shippingDocumentation="shipping_documentation",e.uncategorizedFile="uncategorized_file"}(l||(l={}));class n{set presignedUrl(e){this._presignedUrl=e}get presignedUrl(){return this._presignedUrl}async getFileString(){let e="";const a=new Promise(((a,i)=>{const t=new FileReader;t.onload=i=>{e=i.target.result,a(e)},t.onerror=()=>{i(new Error("Error reading file"))},t.readAsDataURL(this._file)}));return await a,e}constructor(e,a){this._file=e,this.file_name=e.name,this.file_type=e.type,this.dispute_evidence_type=a}}const r=(e,a)=>{const i=e.target,t=i.name,c=i.files;a[t]=[];for(const e of c)a[t].push(new n(e,t))},f=class{constructor(a){e(this,a),this.inputHandler=(e,a)=>{this.form.setValues(Object.assign(Object.assign({},this.form.values.getValue()),{[e]:a}))},this.disputeResponse=void 0,this.documentErrors={},this.form=void 0,this.errors={},this.acceptedTerms=!1,this.acceptedTermsErrorText=void 0,this.documents={uncategorized_file:[]}}async validateAndSubmit(e){const a=Object.values(this.documents).flat();this.form.validateAndSubmit((i=>e(i,a,o.additionalStatement)))}componentWillLoad(){this.form=new c(s)}componentDidLoad(){this.form.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}render(){var e,i;return a("div",{key:"5e572a30ed53b4fbcf3808ba545ce2fdf5b988aa"},a("div",{key:"90870dc58e0eab72e64ae03bdaa25bb1749d8e23",class:"row gy-3"},a("div",{key:"cc3b6f19687d02e047744e8a53d22a2f91a8b968",class:"col-12"},a("h2",{key:"230c20dc3f75e48afa4008369374fd8c175cb7ea",class:"h5",part:d},"Additional Evidence")),a("div",{key:"7b49c8012cfc07c44399969f8505db786389b38b",class:"col-12"},a("form-control-textarea",{key:"349a8a2ebda338e170c90266801ae93b6f9482ea",label:"Is there anything else you would like to say about this dispute?",name:"additional_statement",defaultValue:null===(e=this.disputeResponse)||void 0===e?void 0:e.additional_statement,inputHandler:this.inputHandler,errorText:this.errors.additional_statement})),a("div",{key:"01cd368a2278c5de462f0998a50ba4ca5889be26",class:"col-12"},a("form-control-file-v2",{key:"f95d0b78704f9a1fd154003edbbffb062659ae27",label:"Additional files",name:"uncategorized_file",multiple:!0,helpText:"Upload any additional pieces of evidence that have not already been provided.",onChange:e=>r(e,this.documents),errorText:null===(i=this.documentErrors)||void 0===i?void 0:i.uncategorized_file}))))}},b=i({cancellation_policy_disclosure:t().nullable(),cancellation_rebuttal:t().nullable()}),h=class{constructor(a){e(this,a),this.inputHandler=(e,a)=>{this.form.setValues(Object.assign(Object.assign({},this.form.values.getValue()),{[e]:a}))},this.disputeResponse=void 0,this.documentErrors={},this.form=void 0,this.errors={},this.documents={cancellation_policy:[]}}async validateAndSubmit(e){const a=Object.values(this.documents).flat();this.form.validateAndSubmit((i=>e(i,a,o.cancellationPolicy)))}componentWillLoad(){this.form=new c(b)}componentDidLoad(){this.form.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}render(){var e,i,t;return a("div",{key:"6dc5100426e8e4124d19a375250f85f8e15b28d4"},a("div",{key:"fb950108be5fd4096a7717c88943938261787f99",class:"row gy-3"},a("div",{key:"08f85a06288e19939a16d3fa52ef3b3199c56f36",class:"col-12"},a("h2",{key:"a585b93921814b1ffbb95c6f9c1de37d4104049b",class:"h5",part:d},"Cancellation Policy")),a("div",{key:"3b7c620518006738d2e36863b62a72142f167733",class:"col-12"},a("form-control-textarea",{key:"70a76160b0d29648a9e0598dd5b867a382935e03",label:"Cancellation Policy Disclosure",name:"cancellation_policy_disclosure",defaultValue:null===(e=this.disputeResponse)||void 0===e?void 0:e.cancellation_policy_disclosure,inputHandler:this.inputHandler,errorText:this.errors.cancellation_policy_disclosure})),a("div",{key:"e06d4c794bad47e366ca702e764307fdab5e33a8",class:"col-12"},a("form-control-textarea",{key:"1b783920c5a5b94bff60d4b061cc7cc6666cc184",label:"Cancellation Rebuttal",name:"cancellation_rebuttal",defaultValue:null===(i=this.disputeResponse)||void 0===i?void 0:i.cancellation_rebuttal,inputHandler:this.inputHandler,errorText:this.errors.cancellation_rebuttal})),a("div",{key:"3cb3371c1d3727e55140ea60a0cff96bc0f42702",class:"col-12"},a("form-control-file-v2",{key:"738a456bf4653240180963fa7e5ab20a7a4add7c",label:"Upload Cancellation Policy",name:"cancellation_policy",onChange:e=>r(e,this.documents),errorText:null===(t=this.documentErrors)||void 0===t?void 0:t.cancellation_policy}))))}},u=i({customer_name:t().nullable(),customer_email_address:t().nullable(),customer_billing_address:t().nullable()}),v=class{constructor(a){e(this,a),this.inputHandler=(e,a)=>{this.form.setValues(Object.assign(Object.assign({},this.form.values.getValue()),{[e]:a}))},this.disputeResponse=void 0,this.documentErrors={},this.form=void 0,this.errors={},this.documents={customer_signature:[],customer_communication:[]}}async validateAndSubmit(e){const a=Object.values(this.documents).flat();this.form.validateAndSubmit((i=>e(i,a,o.customerDetails)))}componentWillLoad(){this.form=new c(u)}componentDidLoad(){this.form.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}render(){var e,i,t,c,s;return a("div",{key:"70e29d650d5304522f927c15b4eb5e62e203c5e0"},a("div",{key:"f50422b29cb2a4f3bca911ced94dc681adb3fc41",class:"row gy-3"},a("div",{key:"f29816d9281ea4c4db5018d3b7edb1600569357a",class:"col-12"},a("h2",{key:"a2889c95c293bf0bbf97c16e4486e307ca87729c",class:"h5",part:d},"Customer Details")),a("div",{key:"9cd45719434a1740f67b73c13fd08e0fe562168e",class:"col-12"},a("form-control-text",{key:"5a30a3aef7fbe2d3013c46e43a437724dae41213",label:"Full Name",name:"customer_name",defaultValue:null===(e=this.disputeResponse)||void 0===e?void 0:e.customer_name,inputHandler:this.inputHandler,errorText:this.errors.customer_name})),a("div",{key:"9812e1f9f6df949b9f15b2c3f28857db7dcf5cb7",class:"col-12"},a("form-control-text",{key:"10b146053a399039e8dbd42c3cab53b4b55c0ec3",label:"Email",name:"customer_email_address",defaultValue:null===(i=this.disputeResponse)||void 0===i?void 0:i.customer_email_address,inputHandler:this.inputHandler,errorText:this.errors.customer_email_address})),a("div",{key:"2742a0922a223bd60d6e3d08a55190742ecf5112",class:"col-12"},a("form-control-textarea",{key:"41491e238c75716520d747cbf9f1bcc329a2d686",label:"Billing Address",name:"customer_billing_address",defaultValue:null===(t=this.disputeResponse)||void 0===t?void 0:t.customer_billing_address,inputHandler:this.inputHandler,errorText:this.errors.customer_billing_address})),a("div",{key:"71074f31e565c24107b91b04d9aa16da77ba618c",class:"col-12"},a("form-control-file-v2",{key:"17f70cf96927b01e65430e13c2d21209e9170603",label:"Customer Signature",name:"customer_signature",onChange:e=>r(e,this.documents),errorText:null===(c=this.documentErrors)||void 0===c?void 0:c.customer_signature})),a("div",{key:"ec696695191e68c7ceb0cc41f99f9e53f2d59da1",class:"col-12"},a("form-control-file-v2",{key:"562ff8b3819f536d491f2e2e55a85a55fcda0e1c",label:"Customer Communication",name:"customer_communication",onChange:e=>r(e,this.documents),errorText:null===(s=this.documentErrors)||void 0===s?void 0:s.customer_communication}))))}},p=i({duplicate_charge_original_payment_id:t().nullable(),duplicate_charge_explanation:t().nullable()}),m=class{constructor(a){e(this,a),this.inputHandler=(e,a)=>{this.form.setValues(Object.assign(Object.assign({},this.form.values.getValue()),{[e]:a}))},this.disputeResponse=void 0,this.documentErrors={},this.form=void 0,this.errors={},this.documents={duplicate_charge_documentation:[]}}async validateAndSubmit(e){const a=Object.values(this.documents).flat();this.form.validateAndSubmit((i=>e(i,a,o.duplicateCharge)))}componentWillLoad(){this.form=new c(p)}componentDidLoad(){this.form.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}render(){var e,i,t;return a("div",{key:"0b0d73b396b32f29fa389d3981d48c3f30f96fd7"},a("div",{key:"2fd16a4cf964c863a59789a2be60d94b27a95de8",class:"row gy-3"},a("div",{key:"48c15f7db3285caa9164d815615b82a84283fbfe",class:"col-12"},a("h2",{key:"397b3026311bf57588b172146fc9822f99ede63e",class:"h5",part:d},"Duplicate Charge")),a("div",{key:"c825b6efd428bee298b9b0ddf2265378cf999de9",class:"col-12"},a("form-control-text",{key:"b43283087a10826bf8e582a1e863ed4982b5c000",label:"Original Payment ID",name:"duplicate_charge_original_payment_id",defaultValue:null===(e=this.disputeResponse)||void 0===e?void 0:e.duplicate_charge_original_payment_id,inputHandler:this.inputHandler,errorText:this.errors.duplicate_charge_original_payment_id})),a("div",{key:"66d5cefa16c341f5c523eaa46de5c11f5b16e619",class:"col-12"},a("form-control-textarea",{key:"f83573136fc2ce108f186f9434f46a3f157bd102",label:"Duplicate Charge Explanation",name:"duplicate_charge_explanation",defaultValue:null===(i=this.disputeResponse)||void 0===i?void 0:i.duplicate_charge_explanation,inputHandler:this.inputHandler,errorText:this.errors.duplicate_charge_explanation})),a("div",{key:"cc47dc1d9dbac962d27494b5ff3fef572c98c7b4",class:"col-12"},a("form-control-file-v2",{key:"3cf06b6d61edd6ac96d02b12639d040f698b2526",label:"Duplicate Charge Documentation",name:"duplicate_charge_documentation",onChange:e=>r(e,this.documents),errorText:null===(t=this.documentErrors)||void 0===t?void 0:t.duplicate_charge_documentation}))))}},y=i({customer_purchase_ip_address:t().nullable()}),_=class{constructor(a){e(this,a),this.inputHandler=(e,a)=>{this.form.setValues(Object.assign(Object.assign({},this.form.values.getValue()),{[e]:a}))},this.disputeResponse=void 0,this.documentErrors={},this.form=void 0,this.errors={},this.documents={activity_log:[]}}async validateAndSubmit(e){const a=Object.values(this.documents).flat();this.form.validateAndSubmit((i=>e(i,a,o.electronicEvidence)))}componentWillLoad(){this.form=new c(y)}componentDidLoad(){this.form.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}render(){var e,i;return a("div",{key:"1a4a1d78529c48b8f32029a3efa05b4430c6d271"},a("div",{key:"593d167f4e6b610ac3cdb8a04b4eee30a1cb4f91",class:"row gy-3"},a("div",{key:"39440c3a2802b823c85f251c4393ba76bad287c0",class:"col-12"},a("h2",{key:"f5ec8cce1bbadb772ac6dbe668cf54187d2690d7",class:"h5",part:d},"Electronic Evidence")),a("div",{key:"b9020a773c45a8f59a31ffef44b32253fdb4a551",class:"col-12"},a("form-control-text",{key:"56122eafb7f138f4472a5818cddd32cb0e17fc7e",label:"Purchase IP Address",name:"customer_purchase_ip_address",helpText:"The IP address used by the customer during the purchase.",defaultValue:null===(e=this.disputeResponse)||void 0===e?void 0:e.customer_purchase_ip_address,inputHandler:this.inputHandler,errorText:this.errors.customer_purchase_ip_address})),a("div",{key:"0737f585271838dd60ab9ee1e6ac83d0c6362b96",class:"col-12"},a("form-control-file-v2",{key:"63590d574ee151cbf82638002dfe513cea471035",label:"Activity Logs",name:"activity_log",helpText:"Any server or activity logs that provide evidence of the customer's access to or download of the purchased digital product. This information should encompass IP addresses, relevant timestamps, and any detailed records of activity.",onChange:e=>r(e,this.documents),errorText:null===(i=this.documentErrors)||void 0===i?void 0:i.activity_log}))))}},k=i({product_description:t().nullable(),service_date:t().nullable()}),g=class{constructor(a){e(this,a),this.inputHandler=(e,a)=>{this.form.setValues(Object.assign(Object.assign({},this.form.values.getValue()),{[e]:a}))},this.disputeResponse=void 0,this.documentErrors={},this.form=void 0,this.errors={},this.documents={service_documentation:[]}}async validateAndSubmit(e){const a=Object.values(this.documents).flat();this.form.validateAndSubmit((i=>e(i,a,o.productOrService)))}componentWillLoad(){this.form=new c(k)}componentDidLoad(){this.form.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}render(){var e,i,t;return a("div",{key:"0e2648d399af18f7959bed2e0fff56fd63b541df"},a("div",{key:"4322c227617147721ab7cf33a5e75a09bc370a0c",class:"row gy-3"},a("div",{key:"e2bc9f0642356a864e7fa323262ead13d4825fdc",class:"col-12"},a("h2",{key:"88af660c9add83da7edc7758d4645db796c80fdf",class:"h5",part:d},"Product & Service Details")),a("div",{key:"dcfb0f64e1b611eb8d53f97950d5922f7358a64c",class:"col-12"},a("form-control-text",{key:"42959d4b7c03d14fdef29a656a5f18d0d89d3b2e",label:"Product Description",name:"product_description",defaultValue:null===(e=this.disputeResponse)||void 0===e?void 0:e.product_description,inputHandler:this.inputHandler,errorText:this.errors.product_description})),a("div",{key:"1f4173e79f10a6ac32b860ecbd62fe5c612cc5b2",class:"col-12"},a("form-control-date",{key:"6e8bab228b3a23655cbf71fe6dc72a850b38947c",label:"Service Date",name:"service_date",defaultValue:null===(i=this.disputeResponse)||void 0===i?void 0:i.service_date,inputHandler:this.inputHandler,errorText:this.errors.service_date})),a("div",{key:"2e32f65cc5388302d067fb1a8db34e3e529435c2",class:"col-12"},a("form-control-file-v2",{key:"f9fb2ac0c6a2f37a7584eeda2460702b1e0d6cc0",label:"Service Documentation",name:"service_documentation",onChange:e=>r(e,this.documents),errorText:null===(t=this.documentErrors)||void 0===t?void 0:t.service_documentation}))))}},x=i({refund_policy_disclosure:t().nullable(),refund_refusal_explanation:t().nullable()}),j=class{constructor(a){e(this,a),this.inputHandler=(e,a)=>{this.form.setValues(Object.assign(Object.assign({},this.form.values.getValue()),{[e]:a}))},this.disputeResponse=void 0,this.documentErrors={},this.form=void 0,this.errors={},this.documents={refund_policy:[],receipt:[]}}async validateAndSubmit(e){const a=Object.values(this.documents).flat();this.form.validateAndSubmit((i=>e(i,a,o.refundPolicy)))}componentWillLoad(){this.form=new c(x)}componentDidLoad(){this.form.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}render(){var e,i,t,c;return a("div",{key:"882eb01880bcfdde30abe10465fecd7390654ed6"},a("div",{key:"de2f238310e4b80976888d147e90047688ad5ada",class:"row gy-3"},a("div",{key:"305af62aa762ae6abff0678998132e8f56707550",class:"col-12"},a("h2",{key:"6e224996b82639c426d129bfd28633f3d3839f6f",class:"h5",part:d},"Refund Policy and Receipt")),a("div",{key:"b2b8d444c594bf92d04fed6640230745c5fb49ba",class:"col-12"},a("form-control-textarea",{key:"f75c6c360c485ac5253164be5d4941d859deb902",label:"Refund Policy Disclosure",name:"refund_policy_disclosure",defaultValue:null===(e=this.disputeResponse)||void 0===e?void 0:e.refund_policy_disclosure,inputHandler:this.inputHandler})),a("div",{key:"1788d1e6ba1ddbe82795ce1a41b901a81c055f6d",class:"col-12"},a("form-control-textarea",{key:"f47fac9b8e0d6b9766311b13c760129bb6335ddd",label:"Refund Refusal Explanation",name:"refund_refusal_explanation",defaultValue:null===(i=this.disputeResponse)||void 0===i?void 0:i.refund_refusal_explanation,inputHandler:this.inputHandler})),a("div",{key:"d96552fee8b4cdddf31148b2d3783a4e1dfb031b",class:"col-12"},a("form-control-file-v2",{key:"3c6c06201ef3a730aed41ab6b8cb62d5ee8d8128",label:"Upload Refund Policy",name:"refund_policy",onChange:e=>r(e,this.documents),errorText:null===(t=this.documentErrors)||void 0===t?void 0:t.refund_policy})),a("div",{key:"ec2271dd9646596df3106f56c6e96f618196046a",class:"col-12"},a("form-control-file-v2",{key:"48f956f2580187fc7baecc5426d5ed0a1050150b",label:"Upload Receipt",name:"receipt",onChange:e=>r(e,this.documents),errorText:null===(c=this.documentErrors)||void 0===c?void 0:c.receipt}))))}},O=i({shipping_carrier:t().nullable(),shipping_tracking_number:t().nullable(),shipping_date:t().nullable(),shipping_address:t().nullable()}),T=class{constructor(a){e(this,a),this.inputHandler=(e,a)=>{this.form.setValues(Object.assign(Object.assign({},this.form.values.getValue()),{[e]:a}))},this.disputeResponse=void 0,this.documentErrors={},this.form=void 0,this.errors={},this.documents={shipping_documentation:[]},this.documentList=[]}async validateAndSubmit(e){const a=Object.values(this.documents).flat();this.form.validateAndSubmit((i=>e(i,a,o.shippingDetails)))}componentWillLoad(){this.form=new c(O)}componentDidLoad(){this.form.errors.subscribe((e=>{this.errors=Object.assign({},e)}))}render(){var e,i,t,c,s;return a("div",{key:"90641cea619de697d7a90e6e397790f79ceb9376"},a("div",{key:"52d939e26bd26e99240d100897a530b89553e727",class:"row gy-3"},a("div",{key:"01755fbca3430bd3066377e9481038370c49b2d8",class:"col-12"},a("h2",{key:"d273fbe6ff8b7815ba5c2369748a3a20548b0a4d",class:"h5",part:d},"Shipping Details")),a("div",{key:"595f4e63dff85591713a4c895acb6628c8ef8214",class:"col-12"},a("form-control-text",{key:"958169d07544237a72facdc016d4d12ac64a4c48",label:"Shipping Carrier Name",name:"shipping_carrier",defaultValue:null===(e=this.disputeResponse)||void 0===e?void 0:e.shipping_carrier,inputHandler:this.inputHandler,errorText:this.errors.shipping_carrier})),a("div",{key:"1d3020a30f95c5ced652871a635aba0152bbc4e3",class:"col-12"},a("form-control-text",{key:"088af20353ec2efcb65a4e597a1fb4aec23cfcbb",label:"Tracking Number",name:"shipping_tracking_number",defaultValue:null===(i=this.disputeResponse)||void 0===i?void 0:i.shipping_tracking_number,inputHandler:this.inputHandler,errorText:this.errors.shipping_tracking_number})),a("div",{key:"536ee74c42d326d7f7f698274c846bfebf0d34dd",class:"col-12"},a("form-control-date",{key:"71ef44bd4c810a567162b7fe92199eceff9be470",label:"Date Shipped",name:"shipping_date",defaultValue:null===(t=this.disputeResponse)||void 0===t?void 0:t.shipping_date,inputHandler:this.inputHandler,errorText:this.errors.shipping_date})),a("div",{key:"8887e0daf44be31486563e85cd989eef1da5f5ce",class:"col-12"},a("form-control-textarea",{key:"c34093bc4ee65f4fb092c377a98e01cd69bdbc7c",label:"Shipping Address",name:"shipping_address",defaultValue:null===(c=this.disputeResponse)||void 0===c?void 0:c.shipping_address,inputHandler:this.inputHandler,errorText:this.errors.shipping_address})),a("div",{key:"469a5d8c7e28fa2ad430f104f08f387448f70048",class:"col-12"},a("form-control-file-v2",{key:"a2b6c6c0c1cf32430582b97efe6bcc1d4c47147d",label:"Shipping Documentation",name:"shipping_documentation",onChange:e=>r(e,this.documents),errorText:null===(s=this.documentErrors)||void 0===s?void 0:s.shipping_documentation}))))}};export{f as justifi_additional_statement,h as justifi_cancellation_policy,v as justifi_customer_details,m as justifi_duplicate_charge,_ as justifi_electronic_evidence,g as justifi_product_or_service,j as justifi_refund_policy,T as justifi_shipping_details}
@@ -0,0 +1 @@
1
+ import{h as s}from"./p-2783e363.js";import{T as e}from"./p-f2111e68.js";const r=()=>s("div",{class:"d-flex justify-content-center"},s("div",{class:"spinner-border",role:"status",part:e},s("span",{class:"visually-hidden"},"Loading...")));export{r as S}
@@ -1 +1 @@
1
- import{r as e,h as t,H as a,c as s,g as i}from"./p-2783e363.js";import"./p-9dd8685c.js";import"./p-daf0303f.js";import"./p-56f6ce4c.js";import"./p-9894484a.js";import"./p-e0befd51.js";import{E as c}from"./p-61f0a2ce.js";import{c as o}from"./p-c9b78275.js";import"./p-73f9be7c.js";import{n as r}from"./p-e3c22aa9.js";import{s as d,b as l,k as n}from"./p-2ca5b5e4.js";import{a2 as f,h,Q as b,k as p,R as m,l as u,c as y,b as k,a3 as v,a as x}from"./p-8b3842ce.js";import{S as _}from"./p-fe0399a1.js";import{F as g}from"./p-77e3ed67.js";import"./p-abdbcd8e.js";import"./p-5d1d2fd7.js";import"./p-1ff8810b.js";import"./p-6078a370.js";const j=class{constructor(t){e(this,t),this.inputHandler=void 0,this.errors=void 0,this.storeFiles=void 0}render(){return t("div",{key:"9e04de8ad0e4a1d83f6d8fd1e5a2a5e92c670b92",class:"row gy-3"},t("div",{key:"af8875e58677a94873d548c35e9d2859725058e5",class:"col-12"},t("form-control-file",{key:"030c461b2c2a3da9acf5fcf761f537ea9f6cfcc9",name:"voided_check",label:"Voided Check",documentType:c.voidedCheck,inputHandler:this.inputHandler,onFileSelected:this.storeFiles,errorText:this.errors.voided_check,multiple:!0})),t("div",{key:"0b6650097a7c6810d9ab9dc76484b49dfe0c7e11",class:"col-12"},t("form-control-file",{key:"cd030043373cc6759022b9c23c674830ceffaff3",name:"bank_statement",label:"Bank Statement",documentType:c.bankStatement,inputHandler:this.inputHandler,onFileSelected:this.storeFiles,errorText:this.errors.bank_statement,multiple:!0})))}},T=class{constructor(t){e(this,t),this.defaultValue=void 0,this.errors=void 0,this.inputHandler=void 0,this.formDisabled=void 0}render(){return t("div",{key:"c4420b1e4396ac065b3674f52b124c0d25359435",class:"row gy-3"},t("div",{key:"40e5f2d54a6f60558ec5aa50ff47e6adcf66276b",class:"col-12"},t("form-control-text",{key:"9052ecb4597ecc96841d65929f1d8e5dbf662343",name:"bank_name",label:"Bank Name",defaultValue:this.defaultValue.bank_name,errorText:this.errors.bank_name,inputHandler:this.inputHandler,disabled:this.formDisabled})),t("div",{key:"c32bbaf4fe2155f49cb35ee4500016e7f97f24b3",class:"col-12"},t("form-control-text",{key:"3527553824fb36ea616836bf8e9435fc33a2365a",name:"nickname",label:"Nickname",defaultValue:this.defaultValue.nickname,errorText:this.errors.nickname,inputHandler:this.inputHandler,disabled:this.formDisabled})),t("div",{key:"c203663fad98052567b34cbffe316606c963ff23",class:"col-12"},t("form-control-text",{key:"db95259c41fa10b6af2cbc4c9bd7340d609312ee",name:"account_owner_name",label:"Account Owner Name",defaultValue:this.defaultValue.account_owner_name,errorText:this.errors.account_owner_name,inputHandler:this.inputHandler,disabled:this.formDisabled})),t("div",{key:"3228e30c418210556e4e9f99f4f87f753876072d",class:"col-12"},t("form-control-select",{key:"6dde33c0e9a2ac76051e01af836ea372f30d8fbb",name:"account_type",label:"Account Type",options:o,defaultValue:this.defaultValue.account_type,errorText:this.errors.account_type,inputHandler:this.inputHandler,disabled:this.formDisabled})),t("div",{key:"266005f1bba23068fc0be35416f5fd8cf3fc7c7c",class:"col-12"},t("form-control-text",{key:"34caa85c53b457de98a524a2eb151899e5bcf21a",name:"account_number",label:"Account Number",defaultValue:this.defaultValue.account_number,maxLength:17,errorText:this.errors.account_number,inputHandler:this.inputHandler,keyDownHandler:r,disabled:this.formDisabled,helpText:"Please copy the account number as shown on your statement/check. Do not include spaces or dashes."})),t("div",{key:"69d2e72cf588518e4fe310c2ad5cb37c72fab8c6",class:"col-12"},t("form-control-text",{key:"bc4353e36c9d982aa55f5e933975c4020c316ad0",name:"routing_number",label:"Routing Number",defaultValue:this.defaultValue.routing_number,maxLength:9,errorText:this.errors.routing_number,inputHandler:this.inputHandler,keyDownHandler:r,disabled:this.formDisabled,helpText:"A valid routing number is nine digits. Please include any leading or trailing zeroes."})))}},w=class{constructor(t){e(this,t),this.documents=[],this.isLoading=!1}render(){return this.isLoading?t(_,{height:"50px"}):this.documents.length?t(a,null,t("div",{class:"card",part:f},t("div",{class:"card-body"},t("h5",{class:"card-title",part:h},"Documents Already on File"),t("div",{class:"table-responsive"},t("table",{class:"table table-sm table-borderless",part:b},t("thead",null,t("tr",null,t("th",{style:{width:"25%"},part:p,scope:"col"},"File Name"),t("th",{style:{width:"25%"},part:p,scope:"col"},"File Type"),t("th",{style:{width:"25%"},part:p,scope:"col"},"Document Type"),t("th",{style:{width:"25%"},part:p,scope:"col"},"Date Uploaded"))),t("tbody",null,this.documents.sort(((e,t)=>e.document_type.localeCompare(t.document_type))).map(((e,a)=>t("tr",{class:0===a?"border-bottom border-top":"border-bottom"},t("td",{part:m},e.file_name),t("td",{part:m},e.file_type),t("td",{part:m},d(e.document_type)),t("td",{part:m},`${l(e.created_at)} - ${n(e.created_at)}`))))))))),t("hr",null)):null}},H=class{constructor(t){e(this,t),this.formControlInput=s(this,"formControlInput",7),this.formControlBlur=s(this,"formControlBlur",7),this.fileSelected=s(this,"fileSelected",7),this.handleFormControlInput=e=>{const t=e.target,a=t.getAttribute("name");this.inputHandler(a,t.value),this.formControlInput.emit({name:a,value:t.value})},this.changeHandler=()=>{const e=this.fileInput.files;e&&this.fileSelected.emit({fileList:e,document_type:this.documentType})},this.files=void 0,this.fileString=void 0,this.isFocused=!1,this.label=void 0,this.name=void 0,this.helpText=void 0,this.errorText=void 0,this.multiple=void 0,this.documentType=void 0,this.inputHandler=void 0,this.disabled=void 0}componentDidLoad(){this.fileInput=this.el.querySelector("input")}get part(){let e=y;return this.errorText&&(e=k),this.disabled&&(e=v),this.isFocused&&(e=x),e}render(){return t(a,{key:"b42a36acdd4b1ccbe38d3f990c1ad75dcdca427c"},t("div",{key:"b77e933e6ec75850cd4f81136ed6c7b1e9d4eab8",class:"form-group d-flex flex-column"},t("div",{key:"1d106fa3f984f9339be5d532e9909e802506a070",class:"d-flex align-items-start gap-2"},t("label",{key:"015b1ec3a10e9e6085a07d82a6f50049b33ca72a",part:u,class:"form-label",htmlFor:this.name},this.label),t("form-control-tooltip",{key:"7b1920d7910a8cdea94f2264f4525abd6ce12b04",helpText:this.helpText})),t("input",{key:"7fd8b89dc312b0fa773ca3f1286146906dcbcbc9",ref:e=>this.fileInput=e,type:"file",name:this.name,part:this.part,class:this.errorText?"form-control is-invalid":"form-control",multiple:this.multiple,disabled:this.disabled,onChange:this.changeHandler,onInput:this.handleFormControlInput,onFocus:()=>this.isFocused=!0,onBlur:()=>{this.isFocused=!1,this.formControlBlur.emit()}}),t(g,{key:"5747821abcfedb2bf33a65907f333ea48478c37a",errorText:this.errorText,name:this.name})))}get el(){return i(this)}};export{j as bank_account_document_form_inputs,T as bank_account_form_inputs,w as business_documents_on_file,H as form_control_file}
1
+ import{r as e,h as t,H as s,c as a,g as i}from"./p-2783e363.js";import"./p-9dd8685c.js";import"./p-daf0303f.js";import"./p-56f6ce4c.js";import"./p-9894484a.js";import"./p-382ab4e8.js";import{E as c}from"./p-61f0a2ce.js";import{c as o}from"./p-c9b78275.js";import"./p-73f9be7c.js";import{n as r}from"./p-e3c22aa9.js";import{s as l,b as d,k as n}from"./p-2ca5b5e4.js";import{a0 as f,h,P as b,k as p,Q as m,l as u,c as y,b as k,a1 as v,a as x}from"./p-f2111e68.js";import{S as _}from"./p-a3d75257.js";import{F as g}from"./p-5ee67fad.js";import"./p-abdbcd8e.js";import"./p-5d1d2fd7.js";import"./p-1ff8810b.js";import"./p-6078a370.js";const j=class{constructor(t){e(this,t),this.inputHandler=void 0,this.errors=void 0,this.storeFiles=void 0}render(){return t("div",{key:"9e04de8ad0e4a1d83f6d8fd1e5a2a5e92c670b92",class:"row gy-3"},t("div",{key:"af8875e58677a94873d548c35e9d2859725058e5",class:"col-12"},t("form-control-file",{key:"030c461b2c2a3da9acf5fcf761f537ea9f6cfcc9",name:"voided_check",label:"Voided Check",documentType:c.voidedCheck,inputHandler:this.inputHandler,onFileSelected:this.storeFiles,errorText:this.errors.voided_check,multiple:!0})),t("div",{key:"0b6650097a7c6810d9ab9dc76484b49dfe0c7e11",class:"col-12"},t("form-control-file",{key:"cd030043373cc6759022b9c23c674830ceffaff3",name:"bank_statement",label:"Bank Statement",documentType:c.bankStatement,inputHandler:this.inputHandler,onFileSelected:this.storeFiles,errorText:this.errors.bank_statement,multiple:!0})))}},T=class{constructor(t){e(this,t),this.defaultValue=void 0,this.errors=void 0,this.inputHandler=void 0,this.formDisabled=void 0}render(){return t("div",{key:"c4420b1e4396ac065b3674f52b124c0d25359435",class:"row gy-3"},t("div",{key:"40e5f2d54a6f60558ec5aa50ff47e6adcf66276b",class:"col-12"},t("form-control-text",{key:"9052ecb4597ecc96841d65929f1d8e5dbf662343",name:"bank_name",label:"Bank Name",defaultValue:this.defaultValue.bank_name,errorText:this.errors.bank_name,inputHandler:this.inputHandler,disabled:this.formDisabled})),t("div",{key:"c32bbaf4fe2155f49cb35ee4500016e7f97f24b3",class:"col-12"},t("form-control-text",{key:"3527553824fb36ea616836bf8e9435fc33a2365a",name:"nickname",label:"Nickname",defaultValue:this.defaultValue.nickname,errorText:this.errors.nickname,inputHandler:this.inputHandler,disabled:this.formDisabled})),t("div",{key:"c203663fad98052567b34cbffe316606c963ff23",class:"col-12"},t("form-control-text",{key:"db95259c41fa10b6af2cbc4c9bd7340d609312ee",name:"account_owner_name",label:"Account Owner Name",defaultValue:this.defaultValue.account_owner_name,errorText:this.errors.account_owner_name,inputHandler:this.inputHandler,disabled:this.formDisabled})),t("div",{key:"3228e30c418210556e4e9f99f4f87f753876072d",class:"col-12"},t("form-control-select",{key:"6dde33c0e9a2ac76051e01af836ea372f30d8fbb",name:"account_type",label:"Account Type",options:o,defaultValue:this.defaultValue.account_type,errorText:this.errors.account_type,inputHandler:this.inputHandler,disabled:this.formDisabled})),t("div",{key:"266005f1bba23068fc0be35416f5fd8cf3fc7c7c",class:"col-12"},t("form-control-text",{key:"34caa85c53b457de98a524a2eb151899e5bcf21a",name:"account_number",label:"Account Number",defaultValue:this.defaultValue.account_number,maxLength:17,errorText:this.errors.account_number,inputHandler:this.inputHandler,keyDownHandler:r,disabled:this.formDisabled,helpText:"Please copy the account number as shown on your statement/check. Do not include spaces or dashes."})),t("div",{key:"69d2e72cf588518e4fe310c2ad5cb37c72fab8c6",class:"col-12"},t("form-control-text",{key:"bc4353e36c9d982aa55f5e933975c4020c316ad0",name:"routing_number",label:"Routing Number",defaultValue:this.defaultValue.routing_number,maxLength:9,errorText:this.errors.routing_number,inputHandler:this.inputHandler,keyDownHandler:r,disabled:this.formDisabled,helpText:"A valid routing number is nine digits. Please include any leading or trailing zeroes."})))}},w=class{constructor(t){e(this,t),this.documents=[],this.isLoading=!1}render(){return this.isLoading?t(_,{height:"50px"}):this.documents.length?t(s,null,t("div",{class:"card",part:f},t("div",{class:"card-body"},t("h5",{class:"card-title",part:h},"Documents Already on File"),t("div",{class:"table-responsive"},t("table",{class:"table table-sm table-borderless",part:b},t("thead",null,t("tr",null,t("th",{style:{width:"25%"},part:p,scope:"col"},"File Name"),t("th",{style:{width:"25%"},part:p,scope:"col"},"File Type"),t("th",{style:{width:"25%"},part:p,scope:"col"},"Document Type"),t("th",{style:{width:"25%"},part:p,scope:"col"},"Date Uploaded"))),t("tbody",null,this.documents.sort(((e,t)=>e.document_type.localeCompare(t.document_type))).map(((e,s)=>t("tr",{class:0===s?"border-bottom border-top":"border-bottom"},t("td",{part:m},e.file_name),t("td",{part:m},e.file_type),t("td",{part:m},l(e.document_type)),t("td",{part:m},`${d(e.created_at)} - ${n(e.created_at)}`))))))))),t("hr",null)):null}},H=class{constructor(t){e(this,t),this.formControlInput=a(this,"formControlInput",7),this.formControlBlur=a(this,"formControlBlur",7),this.fileSelected=a(this,"fileSelected",7),this.handleFormControlInput=e=>{const t=e.target,s=t.getAttribute("name");this.inputHandler(s,t.value),this.formControlInput.emit({name:s,value:t.value})},this.changeHandler=()=>{const e=this.fileInput.files;e&&this.fileSelected.emit({fileList:e,document_type:this.documentType})},this.files=void 0,this.fileString=void 0,this.isFocused=!1,this.label=void 0,this.name=void 0,this.helpText=void 0,this.errorText=void 0,this.multiple=void 0,this.documentType=void 0,this.inputHandler=void 0,this.disabled=void 0}componentDidLoad(){this.fileInput=this.el.querySelector("input")}get part(){let e=y;return this.errorText&&(e=k),this.disabled&&(e=v),this.isFocused&&(e=x),e}render(){return t(s,{key:"459b414fc9afaa62d0160d32fecd5c63df91ec8a"},t("div",{key:"7ad619feb3c181f49c56a36613e0379f39811ce8",class:"form-group d-flex flex-column"},t("div",{key:"0314577aa1bd7b28405960156b80800c6fcbc560",class:"d-flex align-items-start gap-2"},t("label",{key:"0745c59386189944bc564aa20c86a7f6e5be384d",part:u,class:"form-label",htmlFor:this.name},this.label),t("form-control-tooltip",{key:"e8fed0f244df3f854a1e9f8c1e0bab6f73371c4c",helpText:this.helpText})),t("input",{key:"d03436b3841e8be14852fb156698441806658bf6",ref:e=>this.fileInput=e,type:"file",name:this.name,part:this.part,class:this.errorText?"form-control is-invalid":"form-control",multiple:this.multiple,disabled:this.disabled,onChange:this.changeHandler,onInput:this.handleFormControlInput,onFocus:()=>this.isFocused=!0,onBlur:()=>{this.isFocused=!1,this.formControlBlur.emit()}}),t(g,{key:"2b3f070c8793027a9c64b2572c21d150ba387979",errorText:this.errorText,name:this.name})))}get el(){return i(this)}};export{j as bank_account_document_form_inputs,T as bank_account_form_inputs,w as business_documents_on_file,H as form_control_file}
@@ -1 +1 @@
1
- import{h as a}from"./p-2783e363.js";import{t as s,h as l,e as t}from"./p-8b3842ce.js";const e=l=>a("main",{class:"p-4 d-flex justify-content-center text-center",style:{fontSize:"1.2rem"}},a("p",{part:s},l)),p=s=>a("h2",{part:l,class:"mt-4 fs-5 border-bottom pb-3"},s.sectionTitle),r=({title:l,value:t})=>l&&t?a("div",{class:"d-table-row gap-2"},a("span",{class:"fw-bold d-table-cell px-2",part:s},l),a("span",{class:"flex-1 d-table-cell px-2 text-wrap",part:s},t)):null,c=({title:t,value:e,classes:p})=>a("div",{class:`d-flex flex-column ${p}`},a("span",{class:"fw-bold border-1 border-bottom ps-2 pe-2",part:l},t),a("span",{class:"pt-2 ps-2 pe-2",part:s},e)),o=({title:l,slot:e,badge:p},r)=>a("div",{slot:e,class:"p-2"},a("div",{class:"d-flex flex-row align-items-center gap-2 mb-2"},a("h1",{class:"m-0",part:t},l),p),a("div",{class:"d-flex flex-row align-items-top",part:s},r)),d=({metadata:s})=>s&&Object.keys(s).length?a("div",{class:"mt-4"},a("pre",{class:"p-2","aria-label":"metadata content"},a("code",null,JSON.stringify(s,null,2)))):null;export{d as C,p as D,e as E,o as a,c as b,r as c}
1
+ import{h as a}from"./p-2783e363.js";import{t as s,h as l,e as t}from"./p-f2111e68.js";const e=l=>a("main",{class:"p-4 d-flex justify-content-center text-center",style:{fontSize:"1.2rem"}},a("p",{part:s},l)),p=s=>a("h2",{part:l,class:"mt-4 fs-5 border-bottom pb-3"},s.sectionTitle),r=({title:l,value:t})=>l&&t?a("div",{class:"d-table-row gap-2"},a("span",{class:"fw-bold d-table-cell px-2",part:s},l),a("span",{class:"flex-1 d-table-cell px-2 text-wrap",part:s},t)):null,c=({title:t,value:e,classes:p})=>a("div",{class:`d-flex flex-column ${p}`},a("span",{class:"fw-bold border-1 border-bottom ps-2 pe-2",part:l},t),a("span",{class:"pt-2 ps-2 pe-2",part:s},e)),o=({title:l,slot:e,badge:p},r)=>a("div",{slot:e,class:"p-2"},a("div",{class:"d-flex flex-row align-items-center gap-2 mb-2"},a("h1",{class:"m-0",part:t},l),p),a("div",{class:"d-flex flex-row align-items-top",part:s},r)),d=({metadata:s})=>s&&Object.keys(s).length?a("div",{class:"mt-4"},a("pre",{class:"p-2","aria-label":"metadata content"},a("code",null,JSON.stringify(s,null,2)))):null;export{d as C,p as D,e as E,o as a,c as b,r as c}
@@ -0,0 +1 @@
1
+ import{h as r}from"./p-2783e363.js";import{d as t}from"./p-f2111e68.js";const e=e=>{const{errorText:o,name:s}=e;return o?r("small",{class:"form-text text-danger",id:`form-error-text-${s}`,part:t},o):null};export{e as F}
@@ -0,0 +1 @@
1
+ import{r as e,c as t,h as s}from"./p-2783e363.js";import{f as i}from"./p-2ca5b5e4.js";import{t as a,C as r}from"./p-f2111e68.js";import{B as d}from"./p-e60867c6.js";import{S as o}from"./p-bfe9748b.js";import{S as c}from"./p-a3d75257.js";import{a as n,C as h}from"./p-9dd8685c.js";import{g as p,a as f}from"./p-87f8c596.js";import{D as l}from"./p-694078d2.js";import{D as u}from"./p-667ebd79.js";import{c as b,J as y}from"./p-ee9d433f.js";import"./p-0e180654.js";import"./p-daf0303f.js";import"./p-56f6ce4c.js";import"./p-9894484a.js";import"./p-abdbcd8e.js";import"./p-382ab4e8.js";import"./p-61f0a2ce.js";import"./p-046ecd01.js";const v=({authToken:e,disputeId:t,service:s})=>async({payload:i,onSuccess:a,onError:r,final:d=(()=>{})})=>{var o;try{const d=await s.submitDisputeResponse(t,e,i);if(d.error){return r({error:p(d.error),code:f(null===(o=d.error)||void 0===o?void 0:o.code),severity:n.ERROR})}a(d)}catch(e){const t=f(null==e?void 0:e.code);return r({error:e.message||e,code:t,severity:n.ERROR})}finally{return d()}},m=class{constructor(s){e(this,s),this.clickEvent=t(this,"click-event",7),this.errorEvent=t(this,"error-event",7),this.submitEvent=t(this,"submit-event",7),this.dispute=void 0,this.authToken=void 0,this.isLoading=void 0}acceptDispute(){v({disputeId:this.dispute.id,authToken:this.authToken,service:new l})({payload:{forfeit:!0},onSuccess:e=>{this.submitEvent.emit({response:e})},onError:({error:e,code:t,severity:s})=>{this.errorEvent.emit({errorCode:t,message:e,severity:s})}})}initiateRespondToDispute(){this.clickEvent.emit({name:u.respondToDispute})}render(){var e,t,n,h,p,f,l;return s(o,{key:"77119b1227200909f4742e24df0a45e1f631c65c"},this.isLoading&&s("div",{key:"f0766ff057fb2f4b75b34c7d4a386bde43e49652",style:{marginBottom:"8px"}},s(c,{key:"d7268194dea5ac2a3b87aea8e17573b4768e308f",height:"28px",width:"70%",styles:{marginBottom:"16px"}}),s(c,{key:"f8863e45a917f56be302ca1b0b3d472119f6465c",height:"18px",styles:{marginBottom:"8px"}}),s(c,{key:"c7b8c9c89d9488eea3be8ea0b4536f98a8151487",height:"18px",styles:{marginBottom:"8px"}})),(null===(e=this.dispute)||void 0===e?void 0:e.needsResponse)&&s("div",{key:"875fe7def317ce1c4547e04e83baf2b232209058",part:a},s("h1",{key:"09646afc2aac3bf4ef9737bc12442660bbafb2dd",class:"h4",part:r},"This payment is disputed"),s("p",{key:"14224cffb16726eaa589118be954e0f844ffaee8"},"The cardholder is disputing this payment. You may accept this dispute, or proceed to provide evidence in a counter dispute."),s("h2",{key:"415028b91872a2391796872fdffdbee837a2a511",class:"h5"},"Dispute details"),s("div",{key:"c2b8c6be3132f98eb8c686ab88a5a6a68f92a60e",class:"d-table gap-2"},s("div",{key:"d11bd8b3bc680183e8bee40281cc2c294aedbd5a",class:"d-table-row gap-2"},s("span",{key:"d77796c0d2764329c3b482ae49ceb8b4cac03d37",part:"detail-section-item-title",class:"fw-bold d-table-cell pe-4"},"Amount"),s("span",{key:"716d8af2a250c3237af6e23b43bf50e032e9f203",part:"detail-section-item-data",class:"flex-1 d-table-cell text-wrap"},i(null===(t=this.dispute)||void 0===t?void 0:t.amount))),s("div",{key:"daba4379197533d2a4b246e81139d81cd15761c6",class:"d-table-row gap-2"},s("span",{key:"a039fbf47aff16445e3411c33a7b53716c42866d",part:"detail-section-item-title",class:"fw-bold d-table-cell pe-4"},"Reason"),s("span",{key:"19087aba5c516d0c71e9f84e8b3323a044ae532a",part:"detail-section-item-data",class:"flex-1 d-table-cell text-wrap"},null===(n=this.dispute)||void 0===n?void 0:n.reason)),s("div",{key:"68ef78b15627df3b22bcde4b90f7c216466e7468",class:"d-table-row gap-2"},s("span",{key:"9463c281d76b5e201a55c2993253fc22d04168dc",part:"detail-section-item-title",class:"fw-bold d-table-cell pe-4"},"Dispute ID"),s("span",{key:"5cffed27038f5571f37377c5023a88c8b7773a59",part:"detail-section-item-data",class:"flex-1 d-table-cell text-wrap"},null===(h=this.dispute)||void 0===h?void 0:h.id))),s("div",{key:"e856d924edac10116781425f6d7c4c8c6b26ced2",class:"d-flex gap-2 mt-4 justify-content-end"},s(d,{key:"6d5278a91f79c2fe8fbdd9e391b109a6491b13b6",variant:"secondary",onClick:()=>this.acceptDispute()},"Accept dispute"),s(d,{key:"242b9076b482aae731ab6bedc1592a1a826e24c5",variant:"primary",onClick:()=>this.initiateRespondToDispute()},"Counter dispute"))),(null===(p=this.dispute)||void 0===p?void 0:p.underReview)&&s("div",{key:"f3711546ce5bf8b6a4a8689f5db3fdbf58f45bf4"},s("h1",{key:"06e39be43cfacf667919adbd2f4f8c596702c340",class:"h4"},"This payment is disputed and under review"),s("p",{key:"b3bfef2d40e197f8dc9df6f71d9f13017a4b923d"},"The cardholder is disputing this payment. A counter dispute has been submitted and is under review.")),(null===(f=this.dispute)||void 0===f?void 0:f.won)&&s("div",{key:"580144b1439d6e017726b9731b7bb15e71900092"},s("h1",{key:"42d74d215d23409672449af86e25c945aac33ea1",class:"h4"},"This payment was disputed"),s("p",{key:"4c337e89a32f62c8f03a53eb84737785f4b0bdb4"},"The cardholder disputed this payment and the card issuer has settled it in your favor.")),(null===(l=this.dispute)||void 0===l?void 0:l.lost)&&s("div",{key:"66c0f7bbada42053683dd25776a7c0abdb708315"},s("h1",{key:"273f2d82dbe73a15da3186946763579be2801aa4",class:"h4"},"This payment was disputed"),s("p",{key:"22172d1c6833eb5407c19dd31b85db805d07d177"},"The cardholder disputed this payment and the card issuer has settled it in their favor.")))}},k=class{constructor(s){e(this,s),this.errorEvent=t(this,"error-event",7),this.handleErrorEvent=e=>{this.errorMessage=e.detail.message,this.errorEvent.emit(e.detail)},this.updateDisputeResponse=void 0,this.submitDisputeResponse=void 0,this.createDisputeEvidence=void 0,this.errorMessage=null,this.authToken=void 0,this.disputeId=void 0,this.disputeResponse=void 0,this.apiOrigin="https://wc-proxy.justifi.ai"}componentWillLoad(){b(),this.analytics=new y(this),this.initializeDisputeServiceMethods()}disconnectedCallback(){this.analytics.cleanup()}propChanged(){this.initializeDisputeServiceMethods()}initializeDisputeServiceMethods(){this.disputeId&&this.authToken?(this.updateDisputeResponse=(({authToken:e,disputeId:t,service:s})=>async({payload:i,onSuccess:a,onError:r,final:d=(()=>{})})=>{var o;try{const d=await s.updateDisputeResponse(t,e,i);if(d.error)return r({error:p(d.error),code:f(null===(o=d.error)||void 0===o?void 0:o.code),severity:n.ERROR});a(d)}catch(e){const t=f(null==e?void 0:e.code);return r({error:e.message||e,code:t,severity:n.ERROR})}finally{return d()}})({disputeId:this.disputeId,authToken:this.authToken,service:new l}),this.createDisputeEvidence=(({authToken:e,disputeId:t,service:s})=>async({payload:i,onSuccess:a,onError:r,final:d=(()=>{})})=>{var o;try{const d=await s.createDisputeEvidence(t,e,i);if(d.error)return r({error:p(d.error),code:f(null===(o=d.error)||void 0===o?void 0:o.code),severity:n.ERROR});a(d)}catch(e){const t=f(null==e?void 0:e.code);return r({error:e.message||e,code:t,severity:n.ERROR})}finally{return d()}})({disputeId:this.disputeId,authToken:this.authToken,service:new l}),this.submitDisputeResponse=v({disputeId:this.disputeId,authToken:this.authToken,service:new l})):(this.errorMessage="Account ID and Auth Token are required",this.errorEvent.emit({errorCode:h.MISSING_PROPS,message:this.errorMessage,severity:n.ERROR}))}render(){return s(o,{key:"4c0cd0b8a082d9f2f4428868d88cbb9bde2a3a5d"},s("justifi-dispute-response-core",{key:"58bbf7f5b2ce8efea0467efddfeffe3c752a3402","onError-event":this.handleErrorEvent,"dispute-id":this.disputeId,disputeResponse:this.disputeResponse,createDisputeEvidence:this.createDisputeEvidence,updateDisputeResponse:this.updateDisputeResponse,submitDisputeResponse:this.submitDisputeResponse}))}static get watchers(){return{accountId:["propChanged"],authToken:["propChanged"]}}},j=class{constructor(i){e(this,i),this.clickEvent=t(this,"click-event",7),this.errorEvent=t(this,"error-event",7),this.stepCompleteEvent=t(this,"complete-form-step-event",7),this.submitEvent=t(this,"submit-event",7),this.componentStepMapping=[()=>s("justifi-product-or-service",{ref:e=>this.currentStepComponentRef=e,disputeResponse:this.disputeResponse,documentErrors:this.documentErrors}),()=>s("justifi-customer-details",{ref:e=>this.currentStepComponentRef=e,disputeResponse:this.disputeResponse,documentErrors:this.documentErrors}),()=>s("justifi-cancellation-policy",{ref:e=>this.currentStepComponentRef=e,disputeResponse:this.disputeResponse,documentErrors:this.documentErrors}),()=>s("justifi-refund-policy",{ref:e=>this.currentStepComponentRef=e,disputeResponse:this.disputeResponse,documentErrors:this.documentErrors}),()=>s("justifi-duplicate-charge",{ref:e=>this.currentStepComponentRef=e,disputeResponse:this.disputeResponse,documentErrors:this.documentErrors}),()=>s("justifi-electronic-evidence",{ref:e=>this.currentStepComponentRef=e,disputeResponse:this.disputeResponse,documentErrors:this.documentErrors}),()=>s("justifi-shipping-details",{ref:e=>this.currentStepComponentRef=e,disputeResponse:this.disputeResponse,documentErrors:this.documentErrors}),()=>s("justifi-additional-statement",{ref:e=>this.currentStepComponentRef=e,disputeResponse:this.disputeResponse,documentErrors:this.documentErrors})],this.saveData=async(e,t)=>{if(Object.keys(e).length)return this.isLastStep?this.submitDisputeResponse({payload:e,onSuccess:e=>{this.submitEvent.emit({response:e}),this.stepCompleteEvent.emit({response:e,formStep:t})},onError:({error:e,code:t,severity:s})=>{this.errorEvent.emit({errorCode:t,message:e,severity:s})}}):this.updateDisputeResponse({payload:e,onSuccess:e=>{this.disputeResponse=Object.assign({},e.data),this.stepCompleteEvent.emit({response:e,formStep:t})},onError:({error:e,code:t,severity:s})=>{this.errorEvent.emit({errorCode:t,message:e,severity:s})}});this.stepCompleteEvent.emit({response:null,formStep:t})},this.initializeMakePresignedURLs=async()=>{const e=this.documentList.map((e=>this.getPresignedFileUrl(e)));return await Promise.all(e)},this.initializeFileUploads=async()=>{const e=this.documentList.map((e=>this.uploadDocument(e)));return Promise.all(e)},this.getPresignedFileUrl=async e=>this.createDisputeEvidence({payload:{file_name:e.file_name,file_type:e.file_type,dispute_evidence_type:e.dispute_evidence_type},onSuccess:t=>{e.presignedUrl=t.data.presigned_url},onError:({error:t,code:s,severity:i})=>{const a={[e.dispute_evidence_type]:t};this.documentErrors=Object.assign(Object.assign({},this.documentErrors),a),this.errorEvent.emit({errorCode:s,message:t,severity:i})}}),this.uploadDocument=async e=>{const t=await e.getFileString();if(!e.presignedUrl)throw new Error("Presigned URL is not set");return await fetch(e.presignedUrl,{method:"PUT",body:t})},this.handleSubmit=async(e,t,s)=>{if(this.isLoading=!0,t.length){if(this.documentErrors={},this.documentList=t,await this.initializeMakePresignedURLs(),Object.keys(this.documentErrors).length)throw this.isLoading=!1,new Error("Could not presign all documents");await this.initializeFileUploads()}await this.saveData(e,s),this.isLoading=!1},this.onCancel=()=>{this.clickEvent.emit({name:u.cancelDispute})},this.onBack=async()=>{await this.currentStepComponentRef.validateAndSubmit((async(e,t,s)=>{this.clickEvent.emit({name:u.previousStep}),await this.handleSubmit(e,t,s),this.currentStep--}))},this.onNext=async()=>{await this.currentStepComponentRef.validateAndSubmit((async(e,t,s)=>{this.clickEvent.emit({name:u.nextStep}),await this.handleSubmit(e,t,s),this.currentStep++}))},this.onSubmit=async()=>{await this.currentStepComponentRef.validateAndSubmit((async(e,t,s)=>{this.clickEvent.emit({name:u.submit});const i=Object.assign(Object.assign({},e),{forfeit:!1});await this.handleSubmit(i,t,s)}))},this.updateDisputeResponse=void 0,this.submitDisputeResponse=void 0,this.createDisputeEvidence=void 0,this.disputeResponse={},this.isLoading=!1,this.documentList=[],this.documentErrors={},this.currentStep=0,this.currentStepComponentRef=void 0}get currentStepComponent(){return this.componentStepMapping[this.currentStep]()}get isLastStep(){return this.currentStep===this.componentStepMapping.length-1}get isFirstStep(){return 0===this.currentStep}render(){return s("div",{key:"452cfcf106f40c27f34df05ae2923c0909de9245",class:"row gy-3"},s("div",{key:"d9b608a8d880310b96e98cd4a00cabfcca77dc79",class:"col-12"},s("h1",{key:"050aef1fa636d09880edc7d738d56eab2cf62e52",class:"h4",part:r},"Counter dispute")),s("div",{key:"4e6094f9240d4db3d4bc03c59754ab3d04fed5bc",class:"col-12"},this.currentStepComponent),s("div",{key:"9c1739bc4ed1a9104fd04531a11e02cbbb4f11cc",class:"col-12"},s("div",{key:"d37cda5a7689d8bf9263283eb24e1074ee3d97a0",class:"d-flex gap-2 mt-4 justify-content-end"},this.isFirstStep?s(d,{variant:"secondary",onClick:()=>this.onCancel(),disabled:this.isLoading,isLoading:this.isLoading},"Cancel"):s(d,{variant:"secondary",onClick:()=>this.onBack(),disabled:this.isLoading,isLoading:this.isLoading},"Back"),this.isLastStep?s(d,{variant:"primary",onClick:()=>this.onSubmit(),disabled:this.isLoading,isLoading:this.isLoading},"Submit Counter Dispute"):s(d,{variant:"primary",onClick:()=>this.onNext(),disabled:this.isLoading,isLoading:this.isLoading},"Next"))))}};export{m as justifi_dispute_notification,k as justifi_dispute_response,j as justifi_dispute_response_core}
@@ -0,0 +1 @@
1
+ import{r as e,h as a}from"./p-2783e363.js";import{l as t}from"./p-c6be72b0.js";import{f as s,p as i,c as r}from"./p-f4739d31.js";import{M as l,N as c,O as o}from"./p-f2111e68.js";import{S as p}from"./p-bfe9748b.js";import"./p-9dd8685c.js";import"./p-daf0303f.js";import"./p-56f6ce4c.js";import"./p-9894484a.js";import{I as f}from"./p-382ab4e8.js";import"./p-61f0a2ce.js";import"./p-f20b6ce1.js";import"./p-2ca5b5e4.js";import"./p-abdbcd8e.js";const d=class{constructor(a){e(this,a),this.setParamsOnChange=(e,a)=>{s[e]=a},this.terminalId=void 0,this.terminalStatus=void 0}componentWillLoad(){this.debouncedSetParamsOnChange=t.exports.debounce(this.setParamsOnChange,300),Object.entries({terminal_id:this.terminalId,status:this.terminalStatus}).forEach((([e,a])=>{a&&(i[e]=a)}))}get terminalStatusOptions(){return[{label:"All",value:""},{label:"Connected",value:f.connected},{label:"Disconnected",value:f.disconnected},{label:"Unknown",value:f.unknown}]}render(){const e=Object.assign({},s);return a(p,{key:"2fc002da23470b942ac8885ba0ee205478a3e975"},a("table-filters-menu",{key:"8591f53c5e105d26955940ae7e0be64b084f31ec",params:e,clearParams:r,part:l},a("div",{key:"e2f0de98ac031d768529654d3b8a5ba43e62269b",class:"grid-cols-2 gap-3 p-1"},a("div",{key:"a62823375c9f3b214f5ceff4163468fa91136cf6",class:"p-2"},a("form-control-text",{key:"8a314678ce052a5f59e2c590d73df72a46caf0db",name:"terminal_id",label:"Terminal ID",inputHandler:this.debouncedSetParamsOnChange,defaultValue:this.terminalId||s.terminal_id,disabled:!!this.terminalId,part:c})),a("div",{key:"8462f83b1ba4f76044567f7c8da4fb84a8b932f7",class:"p-2"},a("form-control-select",{key:"40cc106e9a37f76d4e072ede96b0633e5fb7c1e9",name:"status",label:"Status",options:this.terminalStatusOptions,inputHandler:this.setParamsOnChange,defaultValue:this.terminalStatus||s.status,disabled:!!this.terminalStatus,part:o})))))}};export{d as justifi_terminals_list_filters}
@@ -1 +1 @@
1
- import{r as s,c as t,h as i}from"./p-2783e363.js";import{C as e,a as r}from"./p-9dd8685c.js";import{a as o}from"./p-1ff8810b.js";import{t as h}from"./p-8b3842ce.js";import{S as n}from"./p-bfe9748b.js";import{H as a}from"./p-ca55be58.js";import{B as c}from"./p-73f9be7c.js";import"./p-6078a370.js";const d=class{constructor(i){s(this,i),this.clickEvent=t(this,"click-event",7),this.errorEvent=t(this,"error-event",7),this.submitEvent=t(this,"submit-event",7),this.setBusinessProvisioned=()=>{this.getBusiness({onSuccess:s=>{this.businessProvisioned=o(s.data),this.businessProvisioned&&this.errorEvent.emit({message:"A request to provision payments for this business has already been submitted.",errorCode:e.PROVISIONING_REQUESTED,severity:r.INFO})},onError:({error:s,code:t,severity:i})=>{this.errorEvent.emit({message:s,errorCode:t,severity:i})}})},this.postProvisioningData=()=>{this.postProvisioning({onSuccess:s=>{this.submitEvent.emit({response:s})},onError:({error:s,code:t,severity:i})=>{this.submitEvent.emit({response:{error:s}}),this.errorEvent.emit({message:s,errorCode:t,severity:i})}})},this.refs=[],this.incrementSteps=()=>{if(this.currentStep<this.totalSteps)return this.currentStep++},this.decrementSteps=()=>this.currentStep--,this.previousStepButtonOnClick=()=>{this.clickEvent.emit({name:c.previousStep}),this.decrementSteps()},this.nextStepButtonOnClick=(s,t)=>{s.preventDefault(),this.clickEvent.emit({name:t}),this.refs[this.currentStep].validateAndSubmit({onSuccess:this.incrementSteps})},this.loading=!1,this.businessProvisioned=!1,this.currentStep=0,this.errorMessage=void 0,this.businessId=void 0,this.authToken=void 0,this.allowOptionalFields=!1,this.formTitle=void 0,this.getBusiness=void 0,this.postProvisioning=void 0}handleFormCompleted(){this.postProvisioningData()}componentWillLoad(){this.getBusiness&&this.setBusinessProvisioned(),this.refs=[this.coreInfoRef,this.legalAddressRef,this.additionalQuestionsRef,this.representativeRef,this.ownersRef,this.bankAccountRef,this.documentUploadRef,this.termsRef]}get businessEndpoint(){return`entities/business/${this.businessId}`}get formDisabled(){return this.loading||this.businessProvisioned}get totalSteps(){return this.refs.length-1}get stepCounter(){return`${this.currentStep+1} of ${this.totalSteps+1}`}handleFormLoading(s){this.loading=s.detail}render(){return i(n,{key:"03dc39eadbac2f9a9a4326bab1355bfc300c392e"},i("div",{key:"86e6e57fc104c87696c5825119a15c0a642c4bd2",class:"row gap-3"},i(a,{key:"d4df3ead1037464624fb8cc465427c6b90bd0e36",text:this.formTitle}),i("justifi-payment-provisioning-form-steps",{key:"7f3d977b8dfbb29c03125c173e9d41558de08322",businessId:this.businessId,authToken:this.authToken,refs:this.refs,currentStep:this.currentStep,allowOptionalFields:this.allowOptionalFields,handleFormLoading:this.handleFormLoading}),i("div",{key:"283568d94267850b0eb41fa6a52dbc6b0abf4642",class:"d-flex justify-content-between align-items-center"},i("div",{key:"6abf09f174e71767087b57180e976546c057499f",class:"d-flex align-items-center",part:h},this.stepCounter),i("justifi-payment-provisioning-form-buttons",{key:"b38ed082d216556c6ae93bde3ec1324e69f8fcee",currentStep:this.currentStep,totalSteps:this.totalSteps,formLoading:this.loading,formDisabled:this.formDisabled,previousStepButtonOnClick:this.previousStepButtonOnClick,nextStepButtonOnClick:this.nextStepButtonOnClick}))))}};export{d as justifi_payment_provisioning_core}
1
+ import{r as s,c as t,h as i}from"./p-2783e363.js";import{C as e,a as r}from"./p-9dd8685c.js";import{a as o}from"./p-1ff8810b.js";import{t as h}from"./p-f2111e68.js";import{S as n}from"./p-bfe9748b.js";import{H as a}from"./p-7dc9fb75.js";import{B as c}from"./p-73f9be7c.js";import"./p-6078a370.js";const d=class{constructor(i){s(this,i),this.clickEvent=t(this,"click-event",7),this.errorEvent=t(this,"error-event",7),this.submitEvent=t(this,"submit-event",7),this.setBusinessProvisioned=()=>{this.getBusiness({onSuccess:s=>{this.businessProvisioned=o(s.data),this.businessProvisioned&&this.errorEvent.emit({message:"A request to provision payments for this business has already been submitted.",errorCode:e.PROVISIONING_REQUESTED,severity:r.INFO})},onError:({error:s,code:t,severity:i})=>{this.errorEvent.emit({message:s,errorCode:t,severity:i})}})},this.postProvisioningData=()=>{this.postProvisioning({onSuccess:s=>{this.submitEvent.emit({response:s})},onError:({error:s,code:t,severity:i})=>{this.submitEvent.emit({response:{error:s}}),this.errorEvent.emit({message:s,errorCode:t,severity:i})}})},this.refs=[],this.incrementSteps=()=>{if(this.currentStep<this.totalSteps)return this.currentStep++},this.decrementSteps=()=>this.currentStep--,this.previousStepButtonOnClick=()=>{this.clickEvent.emit({name:c.previousStep}),this.decrementSteps()},this.nextStepButtonOnClick=(s,t)=>{s.preventDefault(),this.clickEvent.emit({name:t}),this.refs[this.currentStep].validateAndSubmit({onSuccess:this.incrementSteps})},this.loading=!1,this.businessProvisioned=!1,this.currentStep=0,this.errorMessage=void 0,this.businessId=void 0,this.authToken=void 0,this.allowOptionalFields=!1,this.formTitle=void 0,this.getBusiness=void 0,this.postProvisioning=void 0}handleFormCompleted(){this.postProvisioningData()}componentWillLoad(){this.getBusiness&&this.setBusinessProvisioned(),this.refs=[this.coreInfoRef,this.legalAddressRef,this.additionalQuestionsRef,this.representativeRef,this.ownersRef,this.bankAccountRef,this.termsRef]}get businessEndpoint(){return`entities/business/${this.businessId}`}get formDisabled(){return this.loading||this.businessProvisioned}get totalSteps(){return this.refs.length-1}get stepCounter(){return`${this.currentStep+1} of ${this.totalSteps+1}`}handleFormLoading(s){this.loading=s.detail}render(){return i(n,{key:"498b6e0a593808dd761b9cefdb7e94124d445348"},i("div",{key:"d746caba6329ac82e75978bd19fbc09c8a43d60f",class:"row gap-3"},i(a,{key:"439425337ed7767ce4fc8c94e31f6997aa1b62d8",text:this.formTitle}),i("justifi-payment-provisioning-form-steps",{key:"fd95a40c0a72c94cbb146cbc866d6b057cbfc5c0",businessId:this.businessId,authToken:this.authToken,refs:this.refs,currentStep:this.currentStep,allowOptionalFields:this.allowOptionalFields,handleFormLoading:this.handleFormLoading}),i("div",{key:"350fc615685f872cb6ba5537dc2de5d2a205e5cc",class:"d-flex justify-content-between align-items-center"},i("div",{key:"3f9a36bc1d58efdfe81b4d7022647b0c1fbc1911",class:"d-flex align-items-center",part:h},this.stepCounter),i("justifi-payment-provisioning-form-buttons",{key:"e1c061aa840b3b8ac1bad472d763fcd54c902681",currentStep:this.currentStep,totalSteps:this.totalSteps,formLoading:this.loading,formDisabled:this.formDisabled,previousStepButtonOnClick:this.previousStepButtonOnClick,nextStepButtonOnClick:this.nextStepButtonOnClick}))))}};export{d as justifi_payment_provisioning_core}
@@ -1 +1 @@
1
- import{A as s}from"./p-0e180654.js";import"./p-9dd8685c.js";import"./p-daf0303f.js";import"./p-56f6ce4c.js";import"./p-9894484a.js";import"./p-e0befd51.js";import"./p-61f0a2ce.js";class t{async fetchDispute(t,i){const p=`disputes/${t}`;return s({authToken:i,apiOrigin:"https://wc-proxy.justifi.ai"}).get(p)}async updateDisputeResponse(t,i,p){const e=`disputes/${t}/response`;return s({authToken:i,apiOrigin:"https://wc-proxy.justifi.ai"}).patch(e,p)}async submitDisputeResponse(t,i,p){const e=`disputes/${t}/response`;return s({authToken:i,apiOrigin:"https://wc-proxy.justifi.ai"}).post(e,p)}async createDisputeEvidence(t,i,p){const e=`disputes/${t}/evidence`;return s({authToken:i,apiOrigin:"https://wc-proxy.justifi.ai"}).put(e,p)}}export{t as D}
1
+ import{A as s}from"./p-0e180654.js";import"./p-9dd8685c.js";import"./p-daf0303f.js";import"./p-56f6ce4c.js";import"./p-9894484a.js";import"./p-382ab4e8.js";import"./p-61f0a2ce.js";class t{async fetchDispute(t,i){const p=`disputes/${t}`;return s({authToken:i,apiOrigin:"https://wc-proxy.justifi.ai"}).get(p)}async updateDisputeResponse(t,i,p){const e=`disputes/${t}/response`;return s({authToken:i,apiOrigin:"https://wc-proxy.justifi.ai"}).patch(e,p)}async submitDisputeResponse(t,i,p){const e=`disputes/${t}/response`;return s({authToken:i,apiOrigin:"https://wc-proxy.justifi.ai"}).post(e,p)}async createDisputeEvidence(t,i,p){const e=`disputes/${t}/evidence`;return s({authToken:i,apiOrigin:"https://wc-proxy.justifi.ai"}).put(e,p)}}export{t as D}
@@ -0,0 +1 @@
1
+ import{r as t,c as s,h as i}from"./p-2783e363.js";import{m as o,P as e}from"./p-b69beb1c.js";import{a as r,C as a}from"./p-9dd8685c.js";import"./p-daf0303f.js";import"./p-56f6ce4c.js";import"./p-9894484a.js";import{P as p}from"./p-382ab4e8.js";import"./p-61f0a2ce.js";import{g as h,a as c}from"./p-87f8c596.js";import{E as d}from"./p-547b51e9.js";import{c as n,J as m}from"./p-ee9d433f.js";import"./p-0e180654.js";import"./p-2ca5b5e4.js";import"./p-abdbcd8e.js";import"./p-f2111e68.js";import"./p-046ecd01.js";const u=class{constructor(i){t(this,i),this.errorEvent=s(this,"error-event",7),this.handleErrorEvent=t=>{this.errorMessage=t.detail.message,this.errorEvent.emit(t.detail)},this.payoutId=void 0,this.authToken=void 0,this.apiOrigin="https://wc-proxy.justifi.ai",this.getPayout=void 0,this.getPayoutCSV=void 0,this.errorMessage=null}componentWillLoad(){n(),this.analytics=new m(this),this.initializeServices()}disconnectedCallback(){this.analytics.cleanup()}propChanged(){this.initializeServices()}initializeServices(){this.payoutId&&this.authToken?(this.getPayout=(({id:t,authToken:s,service:i})=>async({onSuccess:o,onError:e})=>{var a;try{const d=await i.fetchPayout(t,s);d.error?e({error:h(d.error),code:c(null===(a=d.error)||void 0===a?void 0:a.code),severity:r.ERROR}):o(new p(d.data))}catch(t){e({error:h(t),code:c(null==t?void 0:t.code),severity:r.ERROR})}})({id:this.payoutId,authToken:this.authToken,service:new e}),this.getPayoutCSV=o({authToken:this.authToken,service:new e,apiOrigin:this.apiOrigin})):(this.errorMessage="Failed to load payout details. payoutId or authToken is not provided.",this.errorEvent.emit({message:this.errorMessage,errorCode:a.MISSING_PROPS,severity:r.ERROR}))}render(){return this.errorMessage?d(this.errorMessage):i("payout-details-core",{getPayout:this.getPayout,getPayoutCSV:this.getPayoutCSV,"onError-event":this.handleErrorEvent})}static get watchers(){return{payoutId:["propChanged"],authToken:["propChanged"]}}};export{u as justifi_payout_details}
@@ -0,0 +1 @@
1
+ import{r as s,c as t,h as e,H as i}from"./p-2783e363.js";import{a8 as a,a9 as h,aa as c,ab as o,ac as f,l as r}from"./p-f2111e68.js";import{F as d}from"./p-ede13cc8.js";import{F as b}from"./p-5ee67fad.js";const n=class{constructor(e){s(this,e),this.formControlInput=t(this,"formControlInput",7),this.formControlBlur=t(this,"formControlBlur",7),this.handleFormControlInput=s=>{s.preventDefault();const t=s.target,e=t.getAttribute("name");this.inputHandler(e,t.checked),this.formControlInput.emit({name:e,value:t.value})},this.updateInput=s=>{this.checkboxElement.checked=s},this.isFocused=!1,this.label=void 0,this.name=void 0,this.helpText=void 0,this.errorText=void 0,this.checked=void 0,this.inputHandler=void 0,this.disabled=void 0}get part(){return this.errorText?a:this.isFocused&&this.checked?h:this.isFocused?c:this.checked?o:f}render(){return e(i,{key:"d146f375ba008939c5e363b3efba27348d0bf257"},e("div",{key:"f4933418e2e9a5dcfbc787de2b677c1bcfa44b5e",class:"form-group d-flex flex-column"},e("div",{key:"d62db927ea6b2f5be2bd1072218fda5bd2f433b6",class:"form-check"},e("input",{key:"a9e5db3a7f3db488315f30a0fda045eebb22ddc2",ref:s=>this.checkboxElement=s,type:"checkbox",id:this.name,name:this.name,onFocus:()=>this.isFocused=!0,onBlur:()=>{this.isFocused=!1,this.formControlBlur.emit()},onInput:this.handleFormControlInput,part:this.part,class:this.errorText?"form-check-input is-invalid":"form-check-input",disabled:this.disabled,checked:this.checked}),e("label",{key:"4cf2646f1be3744b7163e7c36a9dce11c99f95f6",class:"form-check-label",htmlFor:this.name,part:r},this.label)),e(d,{key:"875972d4db5afbc3b4043ca81f788701ce50dc31",helpText:this.helpText,name:this.name}),e(b,{key:"94f31bd03af9ff027d75c3fab81dfc28aaae8ea8",errorText:this.errorText,name:this.name})))}};export{n as form_control_checkbox}
@@ -1 +1 @@
1
- import{r as s,c as i,h as t,H as e}from"./p-2783e363.js";import{C as o,a as h}from"./p-9dd8685c.js";import{m as n,b as r,c as a,d}from"./p-b84ee6d8.js";import{B as c,a as u,D as p}from"./p-b4ed5a2c.js";import"./p-daf0303f.js";import"./p-56f6ce4c.js";import"./p-9894484a.js";import"./p-e0befd51.js";import"./p-61f0a2ce.js";import{c as f,e as l,F as b}from"./p-5844a0f0.js";import{A as m}from"./p-0e180654.js";import{h as v}from"./p-8b3842ce.js";import"./p-5d1d2fd7.js";import{a as g,B as k}from"./p-73f9be7c.js";import{B as y}from"./p-66cdd475.js";import"./p-87f8c596.js";import"./p-2ca5b5e4.js";import"./p-abdbcd8e.js";import"./p-1ff8810b.js";import"./p-6078a370.js";const j=class{constructor(t){s(this,t),this.errorEvent=i(this,"error-event",7),this.getBusiness=void 0,this.patchBusiness=void 0,this.authToken=void 0,this.businessId=void 0,this.allowOptionalFields=void 0}propChanged(){this.initializeApi()}async validateAndSubmit({onSuccess:s}){this.coreComponent.validateAndSubmit({onSuccess:s})}componentWillLoad(){this.initializeApi()}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=n({authToken:this.authToken,businessId:this.businessId,service:new c}),this.patchBusiness=r({authToken:this.authToken,businessId:this.businessId,service:new c})):this.errorEvent.emit({message:"Missing required props",errorCode:o.MISSING_PROPS,severity:h.ERROR})}render(){return t("justifi-additional-questions-form-step-core",{key:"ecc4bb3b51a4b6cb48e38230826784c5af623d88",getBusiness:this.getBusiness,patchBusiness:this.patchBusiness,allowOptionalFields:this.allowOptionalFields,ref:s=>this.coreComponent=s})}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"]}}},w=class{constructor(t){s(this,t),this.errorEvent=i(this,"error-event",7),this.getBusiness=void 0,this.postBankAccount=void 0,this.postDocumentRecord=void 0,this.postDocument=void 0,this.authToken=void 0,this.businessId=void 0,this.allowOptionalFields=void 0}propChanged(){this.initializeApi()}async validateAndSubmit({onSuccess:s}){this.coreComponent.validateAndSubmit({onSuccess:s})}componentWillLoad(){this.initializeApi()}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=n({authToken:this.authToken,businessId:this.businessId,service:new c}),this.postBankAccount=a({authToken:this.authToken,service:new u}),this.postDocumentRecord=d({authToken:this.authToken,service:new p})):this.errorEvent.emit({message:"Missing required props",errorCode:o.MISSING_PROPS,severity:h.ERROR})}render(){return t("justifi-business-bank-account-form-step-core",{key:"e60dff98e072aeb0eb351cd746c9c05e0adf903c",businessId:this.businessId,getBusiness:this.getBusiness,postBankAccount:this.postBankAccount,postDocumentRecord:this.postDocumentRecord,allowOptionalFields:this.allowOptionalFields,ref:s=>this.coreComponent=s})}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"]}}},_=class{constructor(t){s(this,t),this.errorEvent=i(this,"error-event",7),this.getBusiness=void 0,this.patchBusiness=void 0,this.authToken=void 0,this.businessId=void 0,this.allowOptionalFields=void 0}propChanged(){this.initializeApi()}async validateAndSubmit({onSuccess:s}){this.coreComponent.validateAndSubmit({onSuccess:s})}componentWillLoad(){this.initializeApi()}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=n({authToken:this.authToken,businessId:this.businessId,service:new c}),this.patchBusiness=r({authToken:this.authToken,businessId:this.businessId,service:new c})):this.errorEvent.emit({message:"Missing required props",errorCode:o.MISSING_PROPS,severity:h.ERROR})}render(){return t("justifi-business-core-info-form-step-core",{key:"c9f93be3e48527f5ae799cf736fc9ca86ece736c",businessId:this.businessId,getBusiness:this.getBusiness,patchBusiness:this.patchBusiness,allowOptionalFields:this.allowOptionalFields,ref:s=>this.coreComponent=s})}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"]}}},C=class{constructor(t){s(this,t),this.errorEvent=i(this,"error-event",7),this.getBusiness=void 0,this.patchBusiness=void 0,this.authToken=void 0,this.businessId=void 0,this.allowOptionalFields=void 0}propChanged(){this.initializeApi()}async validateAndSubmit({onSuccess:s}){this.coreComponent.validateAndSubmit({onSuccess:s})}componentWillLoad(){this.initializeApi()}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=n({authToken:this.authToken,businessId:this.businessId,service:new c}),this.patchBusiness=r({authToken:this.authToken,businessId:this.businessId,service:new c})):this.errorEvent.emit({message:"Missing required props",errorCode:o.MISSING_PROPS,severity:h.ERROR})}render(){return t(e,{key:"d3010f8f811d93d7ee0983e92aa3c87a1fab0466"},t("justifi-business-owners-form-step-core",{key:"7eed1a3ebda94badba81f22011efbb23cee7bf12",authToken:this.authToken,businessId:this.businessId,getBusiness:this.getBusiness,patchBusiness:this.patchBusiness,allowOptionalFields:this.allowOptionalFields,ref:s=>this.coreComponent=s}))}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"]}}},T=class{constructor(t){s(this,t),this.errorEvent=i(this,"error-event",7),this.getBusiness=void 0,this.patchBusiness=void 0,this.authToken=void 0,this.businessId=void 0,this.allowOptionalFields=void 0}propChanged(){this.initializeApi()}async validateAndSubmit({onSuccess:s}){this.coreComponent.validateAndSubmit({onSuccess:s})}componentWillLoad(){this.initializeApi()}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=n({authToken:this.authToken,businessId:this.businessId,service:new c}),this.patchBusiness=r({authToken:this.authToken,businessId:this.businessId,service:new c})):this.errorEvent.emit({message:"Missing required props",errorCode:o.MISSING_PROPS,severity:h.ERROR})}render(){return t("justifi-business-representative-form-step-core",{key:"1a7dc9bc4901d5a2bb3da7a06c63952ee45b7843",getBusiness:this.getBusiness,patchBusiness:this.patchBusiness,allowOptionalFields:this.allowOptionalFields,ref:s=>this.coreComponent=s})}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"]}}},I=class{constructor(t){s(this,t),this.stepCompleteEvent=i(this,"complete-form-step-event",7),this.errorEvent=i(this,"error-event",7),this.formLoading=i(this,"formLoading",7),this.formCompleted=i(this,"formCompleted",7),this.fetchData=async()=>{this.formLoading.emit(!0);try{const s=await this.api.get(this.businessEndpoint);this.acceptedTermsBefore=s.data.terms_conditions_accepted}catch(s){this.errorEvent.emit({errorCode:o.FETCH_ERROR,message:s.message,severity:h.ERROR,data:s})}finally{this.formLoading.emit(!1)}},this.sendData=async s=>{this.formLoading.emit(!0);try{const i=this.termsPayload,t=await this.api.post(this.termsConditionsEndpoint,i);this.handleResponse(t,s)}catch(s){this.errorEvent.emit({errorCode:o.POST_ERROR,message:s.message,severity:h.ERROR,data:s})}finally{this.formLoading.emit(!1)}},this.inputHandler=(s,i)=>{this.acceptedTerms=i,this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[s]:i}))},this.formController=void 0,this.errors={},this.acceptedTermsBefore=void 0,this.acceptedTerms=void 0,this.authToken=void 0,this.businessId=void 0,this.allowOptionalFields=void 0}get businessEndpoint(){return`entities/business/${this.businessId}`}get termsConditionsEndpoint(){return"entities/terms_and_conditions"}get formHelperText(){return this.acceptedTermsBefore?"You have already accepted the terms and conditions.":null}get termsPayload(){return{business_id:this.businessId,accepted:this.formController.values.getValue().accepted,user_agent:window.navigator.userAgent}}async componentWillLoad(){this.api=m({authToken:this.authToken,apiOrigin:"https://wc-proxy.justifi.ai"}),this.formController=new b((s=>{const i=f({accepted:l().oneOf([!0],"You must agree to the terms and conditions to continue").required("You must agree to the terms and conditions to continue")}),t=f({accepted:l().nullable()});return s?t:i})(this.allowOptionalFields)),this.businessId&&this.authToken&&this.fetchData()}handleResponse(s,i){s.error?this.errorEvent.emit({errorCode:o.POST_ERROR,message:s.error.message,severity:h.ERROR,data:s.error}):i(),this.stepCompleteEvent.emit({response:s,formStep:g.termsAndConditions}),this.formCompleted.emit()}async validateAndSubmit({onSuccess:s}){this.acceptedTermsBefore?(this.stepCompleteEvent.emit({response:null,formStep:g.termsAndConditions,metadata:"no data submitted"}),this.formCompleted.emit(),s()):this.formController.validateAndSubmit((()=>this.sendData(s)))}componentDidLoad(){this.formController.errors.subscribe((s=>{this.errors=Object.assign({},s)}))}get merchantAgreementLink(){return t("a",{href:"https://justifi.tech/merchant-agreement/",target:"_blank",rel:"noopener noreferrer"},"merchant agreement")}render(){return t("form",{key:"37500e35233a820f521ee503fc638335a2f4866c"},t("fieldset",{key:"e2d1005578397a07b9e876c9a5996e515831c61b"},t("legend",{key:"46918bc1bd20bb56d4e4882ae3ad9b29e3f6e319",part:v},"Terms and Conditions"),t("hr",{key:"904dc58480d9e879fcb462c861a3e398d4dd88b7"}),t("div",{key:"aad73d0a9beddf3487a19bf2af65684309b411aa"},t("p",{key:"10d9f2ff569e4426aaf1563a98838d89636029fd"},"Please read and accept the ",this.merchantAgreementLink," to submit your provisioning request.")),t("br",{key:"dfb6de0078ebbbed103e7b901da879d5ee4195a4"}),t("div",{key:"4899d9b2a0c85e6d26bfd6e3d35ec1dd38f814e2",class:"row-gy-3"},t("div",{key:"011ea552aa484fc1d6a159fb58a8fe7383887584",class:"col-12"},t("form-control-checkbox",{key:"461b491715ed88e92795c7383af3e351e4d9d046",name:"accepted",label:"I agree to the terms and conditions",inputHandler:this.inputHandler,errorText:this.errors.accepted,disabled:this.acceptedTermsBefore,helpText:this.formHelperText,checked:this.acceptedTerms})))))}},S=class{constructor(t){s(this,t),this.errorEvent=i(this,"error-event",7),this.getBusiness=void 0,this.patchBusiness=void 0,this.authToken=void 0,this.businessId=void 0,this.allowOptionalFields=void 0}propChanged(){this.initializeApi()}async validateAndSubmit({onSuccess:s}){this.coreComponent.validateAndSubmit({onSuccess:s})}componentWillLoad(){this.initializeApi()}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=n({authToken:this.authToken,businessId:this.businessId,service:new c}),this.patchBusiness=r({authToken:this.authToken,businessId:this.businessId,service:new c})):this.errorEvent.emit({message:"Missing required props",errorCode:o.MISSING_PROPS,severity:h.ERROR})}render(){return t("justifi-legal-address-form-step-core",{key:"70241ec94d2519d675e3831dfb13840e0f9ea6ca",getBusiness:this.getBusiness,patchBusiness:this.patchBusiness,allowOptionalFields:this.allowOptionalFields,ref:s=>this.coreComponent=s})}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"]}}},B=class{constructor(i){s(this,i),this.currentStep=void 0,this.totalSteps=void 0,this.formLoading=void 0,this.formDisabled=void 0,this.previousStepButtonOnClick=void 0,this.nextStepButtonOnClick=void 0}get showPreviousStepButton(){return this.currentStep>0}get showNextStepButton(){return this.currentStep<this.totalSteps}get showSubmitButton(){return this.currentStep===this.totalSteps}render(){return t("div",{key:"f5b14768cd97673e77c1ee2d9d73221cdee885e6",class:"d-flex gap-2"},t(y,{key:"4726571002718d036c292a41dc216955ba5ec687",variant:"secondary",type:"button",onClick:()=>this.previousStepButtonOnClick(),disabled:this.formDisabled,hidden:!this.showPreviousStepButton},"Previous"),t(y,{key:"3852cfcd4704f5509f22a5c457526fe8475df096",variant:"primary",type:"button",onClick:s=>this.nextStepButtonOnClick(s,k.nextStep),disabled:this.formDisabled,isLoading:this.formLoading,hidden:!this.showNextStepButton},"Next"),t(y,{key:"d62830b61932581071a1a44d872760be0823215a",variant:"primary",type:"submit",onClick:s=>this.nextStepButtonOnClick(s,k.submit),disabled:this.formDisabled,isLoading:this.formLoading,hidden:!this.showSubmitButton},"Submit"))}},O=class{constructor(i){s(this,i),this.componentStepMapping={0:()=>t("justifi-business-core-info-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[0]=s,allowOptionalFields:this.allowOptionalFields}),1:()=>t("justifi-legal-address-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[1]=s,allowOptionalFields:this.allowOptionalFields}),2:()=>t("justifi-additional-questions-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[2]=s,allowOptionalFields:this.allowOptionalFields}),3:()=>t("justifi-business-representative-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[3]=s,allowOptionalFields:this.allowOptionalFields}),4:()=>t("justifi-business-owners-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[4]=s,allowOptionalFields:this.allowOptionalFields}),5:()=>t("justifi-business-bank-account-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[5]=s,allowOptionalFields:this.allowOptionalFields}),6:()=>t("justifi-business-terms-conditions-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[6]=s,onFormLoading:this.handleFormLoading,allowOptionalFields:this.allowOptionalFields})},this.businessId=void 0,this.authToken=void 0,this.refs=void 0,this.currentStep=void 0,this.allowOptionalFields=!1,this.handleFormLoading=void 0}get currentStepComponent(){return this.componentStepMapping[this.currentStep]()}render(){return t("div",{key:"a83b5ef4442783fe771eef6d6418c97aa0a9026d",class:"col-12 mb-4"},this.currentStepComponent)}};export{j as justifi_additional_questions_form_step,w as justifi_business_bank_account_form_step,_ as justifi_business_core_info_form_step,C as justifi_business_owners_form_step,T as justifi_business_representative_form_step,I as justifi_business_terms_conditions_form_step,S as justifi_legal_address_form_step,B as justifi_payment_provisioning_form_buttons,O as justifi_payment_provisioning_form_steps}
1
+ import{r as s,c as i,h as t,H as e}from"./p-2783e363.js";import{C as o,a as h}from"./p-9dd8685c.js";import{m as n,b as r,c as a,d}from"./p-b84ee6d8.js";import{B as c,a as u,D as p}from"./p-b4ed5a2c.js";import"./p-daf0303f.js";import"./p-56f6ce4c.js";import"./p-9894484a.js";import"./p-382ab4e8.js";import"./p-61f0a2ce.js";import{c as f,e as l,F as b}from"./p-5844a0f0.js";import{A as m}from"./p-0e180654.js";import{h as v}from"./p-f2111e68.js";import"./p-5d1d2fd7.js";import{a as g,B as k}from"./p-73f9be7c.js";import{B as y}from"./p-e60867c6.js";import"./p-87f8c596.js";import"./p-2ca5b5e4.js";import"./p-abdbcd8e.js";import"./p-1ff8810b.js";import"./p-6078a370.js";const j=class{constructor(t){s(this,t),this.errorEvent=i(this,"error-event",7),this.getBusiness=void 0,this.patchBusiness=void 0,this.authToken=void 0,this.businessId=void 0,this.allowOptionalFields=void 0}propChanged(){this.initializeApi()}async validateAndSubmit({onSuccess:s}){this.coreComponent.validateAndSubmit({onSuccess:s})}componentWillLoad(){this.initializeApi()}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=n({authToken:this.authToken,businessId:this.businessId,service:new c}),this.patchBusiness=r({authToken:this.authToken,businessId:this.businessId,service:new c})):this.errorEvent.emit({message:"Missing required props",errorCode:o.MISSING_PROPS,severity:h.ERROR})}render(){return t("justifi-additional-questions-form-step-core",{key:"ecc4bb3b51a4b6cb48e38230826784c5af623d88",getBusiness:this.getBusiness,patchBusiness:this.patchBusiness,allowOptionalFields:this.allowOptionalFields,ref:s=>this.coreComponent=s})}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"]}}},w=class{constructor(t){s(this,t),this.errorEvent=i(this,"error-event",7),this.getBusiness=void 0,this.postBankAccount=void 0,this.postDocumentRecord=void 0,this.postDocument=void 0,this.authToken=void 0,this.businessId=void 0,this.allowOptionalFields=void 0}propChanged(){this.initializeApi()}async validateAndSubmit({onSuccess:s}){this.coreComponent.validateAndSubmit({onSuccess:s})}componentWillLoad(){this.initializeApi()}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=n({authToken:this.authToken,businessId:this.businessId,service:new c}),this.postBankAccount=a({authToken:this.authToken,service:new u}),this.postDocumentRecord=d({authToken:this.authToken,service:new p})):this.errorEvent.emit({message:"Missing required props",errorCode:o.MISSING_PROPS,severity:h.ERROR})}render(){return t("justifi-business-bank-account-form-step-core",{key:"e60dff98e072aeb0eb351cd746c9c05e0adf903c",businessId:this.businessId,getBusiness:this.getBusiness,postBankAccount:this.postBankAccount,postDocumentRecord:this.postDocumentRecord,allowOptionalFields:this.allowOptionalFields,ref:s=>this.coreComponent=s})}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"]}}},_=class{constructor(t){s(this,t),this.errorEvent=i(this,"error-event",7),this.getBusiness=void 0,this.patchBusiness=void 0,this.authToken=void 0,this.businessId=void 0,this.allowOptionalFields=void 0}propChanged(){this.initializeApi()}async validateAndSubmit({onSuccess:s}){this.coreComponent.validateAndSubmit({onSuccess:s})}componentWillLoad(){this.initializeApi()}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=n({authToken:this.authToken,businessId:this.businessId,service:new c}),this.patchBusiness=r({authToken:this.authToken,businessId:this.businessId,service:new c})):this.errorEvent.emit({message:"Missing required props",errorCode:o.MISSING_PROPS,severity:h.ERROR})}render(){return t("justifi-business-core-info-form-step-core",{key:"c9f93be3e48527f5ae799cf736fc9ca86ece736c",businessId:this.businessId,getBusiness:this.getBusiness,patchBusiness:this.patchBusiness,allowOptionalFields:this.allowOptionalFields,ref:s=>this.coreComponent=s})}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"]}}},C=class{constructor(t){s(this,t),this.errorEvent=i(this,"error-event",7),this.getBusiness=void 0,this.patchBusiness=void 0,this.authToken=void 0,this.businessId=void 0,this.allowOptionalFields=void 0}propChanged(){this.initializeApi()}async validateAndSubmit({onSuccess:s}){this.coreComponent.validateAndSubmit({onSuccess:s})}componentWillLoad(){this.initializeApi()}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=n({authToken:this.authToken,businessId:this.businessId,service:new c}),this.patchBusiness=r({authToken:this.authToken,businessId:this.businessId,service:new c})):this.errorEvent.emit({message:"Missing required props",errorCode:o.MISSING_PROPS,severity:h.ERROR})}render(){return t(e,{key:"d3010f8f811d93d7ee0983e92aa3c87a1fab0466"},t("justifi-business-owners-form-step-core",{key:"7eed1a3ebda94badba81f22011efbb23cee7bf12",authToken:this.authToken,businessId:this.businessId,getBusiness:this.getBusiness,patchBusiness:this.patchBusiness,allowOptionalFields:this.allowOptionalFields,ref:s=>this.coreComponent=s}))}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"]}}},T=class{constructor(t){s(this,t),this.errorEvent=i(this,"error-event",7),this.getBusiness=void 0,this.patchBusiness=void 0,this.authToken=void 0,this.businessId=void 0,this.allowOptionalFields=void 0}propChanged(){this.initializeApi()}async validateAndSubmit({onSuccess:s}){this.coreComponent.validateAndSubmit({onSuccess:s})}componentWillLoad(){this.initializeApi()}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=n({authToken:this.authToken,businessId:this.businessId,service:new c}),this.patchBusiness=r({authToken:this.authToken,businessId:this.businessId,service:new c})):this.errorEvent.emit({message:"Missing required props",errorCode:o.MISSING_PROPS,severity:h.ERROR})}render(){return t("justifi-business-representative-form-step-core",{key:"1a7dc9bc4901d5a2bb3da7a06c63952ee45b7843",getBusiness:this.getBusiness,patchBusiness:this.patchBusiness,allowOptionalFields:this.allowOptionalFields,ref:s=>this.coreComponent=s})}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"]}}},I=class{constructor(t){s(this,t),this.stepCompleteEvent=i(this,"complete-form-step-event",7),this.errorEvent=i(this,"error-event",7),this.formLoading=i(this,"formLoading",7),this.formCompleted=i(this,"formCompleted",7),this.fetchData=async()=>{this.formLoading.emit(!0);try{const s=await this.api.get(this.businessEndpoint);this.acceptedTermsBefore=s.data.terms_conditions_accepted}catch(s){this.errorEvent.emit({errorCode:o.FETCH_ERROR,message:s.message,severity:h.ERROR,data:s})}finally{this.formLoading.emit(!1)}},this.sendData=async s=>{this.formLoading.emit(!0);try{const i=this.termsPayload,t=await this.api.post(this.termsConditionsEndpoint,i);this.handleResponse(t,s)}catch(s){this.errorEvent.emit({errorCode:o.POST_ERROR,message:s.message,severity:h.ERROR,data:s})}finally{this.formLoading.emit(!1)}},this.inputHandler=(s,i)=>{this.acceptedTerms=i,this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[s]:i}))},this.formController=void 0,this.errors={},this.acceptedTermsBefore=void 0,this.acceptedTerms=void 0,this.authToken=void 0,this.businessId=void 0,this.allowOptionalFields=void 0}get businessEndpoint(){return`entities/business/${this.businessId}`}get termsConditionsEndpoint(){return"entities/terms_and_conditions"}get formHelperText(){return this.acceptedTermsBefore?"You have already accepted the terms and conditions.":null}get termsPayload(){return{business_id:this.businessId,accepted:this.formController.values.getValue().accepted,user_agent:window.navigator.userAgent}}async componentWillLoad(){this.api=m({authToken:this.authToken,apiOrigin:"https://wc-proxy.justifi.ai"}),this.formController=new b((s=>{const i=f({accepted:l().oneOf([!0],"You must agree to the terms and conditions to continue").required("You must agree to the terms and conditions to continue")}),t=f({accepted:l().nullable()});return s?t:i})(this.allowOptionalFields)),this.businessId&&this.authToken&&this.fetchData()}handleResponse(s,i){s.error?this.errorEvent.emit({errorCode:o.POST_ERROR,message:s.error.message,severity:h.ERROR,data:s.error}):i(),this.stepCompleteEvent.emit({response:s,formStep:g.termsAndConditions}),this.formCompleted.emit()}async validateAndSubmit({onSuccess:s}){this.acceptedTermsBefore?(this.stepCompleteEvent.emit({response:null,formStep:g.termsAndConditions,metadata:"no data submitted"}),this.formCompleted.emit(),s()):this.formController.validateAndSubmit((()=>this.sendData(s)))}componentDidLoad(){this.formController.errors.subscribe((s=>{this.errors=Object.assign({},s)}))}get merchantAgreementLink(){return t("a",{href:"https://justifi.tech/merchant-agreement/",target:"_blank",rel:"noopener noreferrer"},"merchant agreement")}render(){return t("form",{key:"37500e35233a820f521ee503fc638335a2f4866c"},t("fieldset",{key:"e2d1005578397a07b9e876c9a5996e515831c61b"},t("legend",{key:"46918bc1bd20bb56d4e4882ae3ad9b29e3f6e319",part:v},"Terms and Conditions"),t("hr",{key:"904dc58480d9e879fcb462c861a3e398d4dd88b7"}),t("div",{key:"aad73d0a9beddf3487a19bf2af65684309b411aa"},t("p",{key:"10d9f2ff569e4426aaf1563a98838d89636029fd"},"Please read and accept the ",this.merchantAgreementLink," to submit your provisioning request.")),t("br",{key:"dfb6de0078ebbbed103e7b901da879d5ee4195a4"}),t("div",{key:"4899d9b2a0c85e6d26bfd6e3d35ec1dd38f814e2",class:"row-gy-3"},t("div",{key:"011ea552aa484fc1d6a159fb58a8fe7383887584",class:"col-12"},t("form-control-checkbox",{key:"461b491715ed88e92795c7383af3e351e4d9d046",name:"accepted",label:"I agree to the terms and conditions",inputHandler:this.inputHandler,errorText:this.errors.accepted,disabled:this.acceptedTermsBefore,helpText:this.formHelperText,checked:this.acceptedTerms})))))}},S=class{constructor(t){s(this,t),this.errorEvent=i(this,"error-event",7),this.getBusiness=void 0,this.patchBusiness=void 0,this.authToken=void 0,this.businessId=void 0,this.allowOptionalFields=void 0}propChanged(){this.initializeApi()}async validateAndSubmit({onSuccess:s}){this.coreComponent.validateAndSubmit({onSuccess:s})}componentWillLoad(){this.initializeApi()}initializeApi(){this.authToken&&this.businessId?(this.getBusiness=n({authToken:this.authToken,businessId:this.businessId,service:new c}),this.patchBusiness=r({authToken:this.authToken,businessId:this.businessId,service:new c})):this.errorEvent.emit({message:"Missing required props",errorCode:o.MISSING_PROPS,severity:h.ERROR})}render(){return t("justifi-legal-address-form-step-core",{key:"70241ec94d2519d675e3831dfb13840e0f9ea6ca",getBusiness:this.getBusiness,patchBusiness:this.patchBusiness,allowOptionalFields:this.allowOptionalFields,ref:s=>this.coreComponent=s})}static get watchers(){return{authToken:["propChanged"],businessId:["propChanged"]}}},B=class{constructor(i){s(this,i),this.currentStep=void 0,this.totalSteps=void 0,this.formLoading=void 0,this.formDisabled=void 0,this.previousStepButtonOnClick=void 0,this.nextStepButtonOnClick=void 0}get showPreviousStepButton(){return this.currentStep>0}get showNextStepButton(){return this.currentStep<this.totalSteps}get showSubmitButton(){return this.currentStep===this.totalSteps}render(){return t("div",{key:"f5b14768cd97673e77c1ee2d9d73221cdee885e6",class:"d-flex gap-2"},t(y,{key:"4726571002718d036c292a41dc216955ba5ec687",variant:"secondary",type:"button",onClick:()=>this.previousStepButtonOnClick(),disabled:this.formDisabled,hidden:!this.showPreviousStepButton},"Previous"),t(y,{key:"3852cfcd4704f5509f22a5c457526fe8475df096",variant:"primary",type:"button",onClick:s=>this.nextStepButtonOnClick(s,k.nextStep),disabled:this.formDisabled,isLoading:this.formLoading,hidden:!this.showNextStepButton},"Next"),t(y,{key:"d62830b61932581071a1a44d872760be0823215a",variant:"primary",type:"submit",onClick:s=>this.nextStepButtonOnClick(s,k.submit),disabled:this.formDisabled,isLoading:this.formLoading,hidden:!this.showSubmitButton},"Submit"))}},O=class{constructor(i){s(this,i),this.componentStepMapping={0:()=>t("justifi-business-core-info-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[0]=s,allowOptionalFields:this.allowOptionalFields}),1:()=>t("justifi-legal-address-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[1]=s,allowOptionalFields:this.allowOptionalFields}),2:()=>t("justifi-additional-questions-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[2]=s,allowOptionalFields:this.allowOptionalFields}),3:()=>t("justifi-business-representative-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[3]=s,allowOptionalFields:this.allowOptionalFields}),4:()=>t("justifi-business-owners-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[4]=s,allowOptionalFields:this.allowOptionalFields}),5:()=>t("justifi-business-bank-account-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[5]=s,allowOptionalFields:this.allowOptionalFields}),6:()=>t("justifi-business-terms-conditions-form-step",{businessId:this.businessId,authToken:this.authToken,ref:s=>this.refs[6]=s,onFormLoading:this.handleFormLoading,allowOptionalFields:this.allowOptionalFields})},this.businessId=void 0,this.authToken=void 0,this.refs=void 0,this.currentStep=void 0,this.allowOptionalFields=!1,this.handleFormLoading=void 0}get currentStepComponent(){return this.componentStepMapping[this.currentStep]()}render(){return t("div",{key:"a83b5ef4442783fe771eef6d6418c97aa0a9026d",class:"col-12 mb-4"},this.currentStepComponent)}};export{j as justifi_additional_questions_form_step,w as justifi_business_bank_account_form_step,_ as justifi_business_core_info_form_step,C as justifi_business_owners_form_step,T as justifi_business_representative_form_step,I as justifi_business_terms_conditions_form_step,S as justifi_legal_address_form_step,B as justifi_payment_provisioning_form_buttons,O as justifi_payment_provisioning_form_steps}
@@ -0,0 +1 @@
1
+ import{h as t}from"./p-2783e363.js";import{R as s,S as e,Q as r}from"./p-f2111e68.js";import{S as a}from"./p-3cbdca1b.js";const n=e=>{const{columnSpan:r,isEmpty:a}=e;return r&&a?t("tr",null,t("td",{class:"empty-state",part:s,colSpan:r,style:{textAlign:"center"}},"No results")):null},l=s=>{const{columnSpan:r,errorMessage:a}=s;return r&&a?t("tr",null,t("td",{class:"error-state",part:e,colSpan:r,"data-test-id":"table-error-state",style:{textAlign:"center"}},"An unexpected error occurred: ",a)):null},o=s=>{const{columnSpan:e,isLoading:n}=s;return e&&n?t("tr",null,t("td",{class:"loading-state",part:r,colSpan:e,style:{textAlign:"center"}},t(a,null))):null};class c{get columnData(){return this.columnKeys.map((t=>this.tableColumns[t]()))}get rowData(){return this.collection.map(((t,s)=>this.columnKeys.map((e=>this.tableCells[e](t,s)))))}set collectionData(t){this.collection=t}constructor(t,s,e,r){this.columnKeys=s.split(","),this.collection=t,this.tableColumns=e,this.tableCells=r}}var i;!function(t){t.row="tableRow",t.next="nextPage",t.previous="previousPage"}(i||(i={}));export{i as T,c as a,o as b,n as c,l as d}