@justifi/webcomponents 6.0.2 → 6.1.0-rc.2
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.
- package/dist/cjs/{Api-DdNOMYxI.js → Api-CwTLkFY4.js} +1 -1
- package/dist/cjs/additional-questions-details_5.cjs.entry.js +2 -2
- package/dist/cjs/{badge-Cp5ap9Ge.js → badge-BmOSt4gS.js} +1 -1
- package/dist/cjs/bank-account-document-form-inputs_4.cjs.entry.js +7 -7
- package/dist/cjs/bank-account-form.cjs.entry.js +6 -6
- package/dist/cjs/{business-additional-questions-schema-b8P-0T0O.js → business-additional-questions-schema-DNbSH3E-.js} +2 -2
- package/dist/cjs/business-details-core.cjs.entry.js +4 -4
- package/dist/cjs/{business-identity-schema-aFUle0C9.js → business-identity-schema-CclzWSOn.js} +2 -2
- package/dist/cjs/{business.service-CjsXJOgZ.js → business.service-Dkhqyggm.js} +1 -1
- package/dist/cjs/{button-BMKiDxGa.js → button-7c2RN2yp.js} +1 -1
- package/dist/cjs/card-form.cjs.entry.js +6 -6
- package/dist/cjs/{check-pkg-version-CMjNMgW8.js → check-pkg-version-DUDlLDCJ.js} +2 -2
- package/dist/cjs/{checkout.service-o7fi8Z05.js → checkout.service-LwZVVgP5.js} +1 -1
- package/dist/cjs/{checkout.store-DrFb05Vr.js → checkout.store-C3f3E24L.js} +1 -1
- package/dist/cjs/checkouts-list-core.cjs.entry.js +9 -9
- package/dist/cjs/{checkouts-list-params-state-CKeoLpqm.js → checkouts-list-params-state-C4c8UZtP.js} +1 -1
- package/dist/cjs/{checkouts-table-Ckpk4UMS.js → checkouts-table-BQUhZZd_.js} +2 -2
- package/dist/cjs/{config-state-BXCZx6K8.js → config-state-B_gyIchD.js} +1 -1
- package/dist/cjs/custom-popper_2.cjs.entry.js +1 -1
- package/dist/cjs/{dispute.service-BANG6pry.js → dispute.service-927Gzb0N.js} +1 -1
- package/dist/cjs/form-alert_5.cjs.entry.js +5 -5
- package/dist/cjs/form-control-checkbox.cjs.entry.js +5 -5
- package/dist/cjs/form-control-date.cjs.entry.js +2 -2
- package/dist/cjs/{form-control-error-text-CA6tsCwq.js → form-control-error-text-DD0dHGu8.js} +1 -1
- package/dist/cjs/form-control-file-v2_2.cjs.entry.js +2 -2
- package/dist/cjs/{form-control-help-text-sYroVd4u.js → form-control-help-text-2QwKi78M.js} +1 -1
- package/dist/cjs/form-control-help-text.cjs.entry.js +1 -1
- package/dist/cjs/form-control-monetary-provisioning.cjs.entry.js +5 -5
- package/dist/cjs/form-control-monetary.cjs.entry.js +3 -3
- package/dist/cjs/form-control-number-masked_2.cjs.entry.js +3 -3
- package/dist/cjs/form-control-number.cjs.entry.js +3 -3
- package/dist/cjs/form-control-radio.cjs.entry.js +1 -1
- package/dist/cjs/form-control-select_2.cjs.entry.js +2 -2
- package/dist/cjs/{get-payment-details-CqsEtJTg.js → get-payment-details-BSxp1HX0.js} +1 -1
- package/dist/cjs/{get-subaccounts-BfiiwPTB.js → get-subaccounts-B31f95PR.js} +2 -2
- package/dist/cjs/gross-payment-chart-core.cjs.entry.js +3 -3
- package/dist/cjs/{header-1-IQ1fI7he.js → header-1-DMsp0XM7.js} +1 -1
- package/dist/cjs/{header-3-CACJFFMS.js → header-3-BSvFq_IF.js} +1 -1
- package/dist/cjs/hidden-input_2.cjs.entry.js +4 -4
- package/dist/cjs/{index-BGUnWLse.js → index-D1Ba20gi.js} +1 -1
- package/dist/cjs/{index-8Prcj64P.js → index-Dyzl8Hn6.js} +13 -2
- package/dist/cjs/{index.esm-ByC0D4sJ.js → index.esm-BleZSAc0.js} +17 -18
- package/dist/cjs/{insurance-state-De4RWYBC.js → insurance-state-uWOl6jJN.js} +2 -2
- package/dist/cjs/justifi-additional-questions-form-step-core_6.cjs.entry.js +9 -9
- package/dist/cjs/justifi-additional-questions-form-step_9.cjs.entry.js +16 -16
- package/dist/cjs/justifi-additional-statement_8.cjs.entry.js +2 -2
- package/dist/cjs/justifi-apple-pay.cjs.entry.js +14 -10
- package/dist/cjs/justifi-bank-account-billing-form-simple_9.cjs.entry.js +17 -17
- package/dist/cjs/justifi-business-details.cjs.entry.js +8 -8
- package/dist/cjs/justifi-business-form.cjs.entry.js +15 -15
- package/dist/cjs/justifi-business-representative-form-inputs.cjs.entry.js +2 -2
- package/dist/cjs/justifi-checkout-summary_7.cjs.entry.js +12 -12
- package/dist/cjs/justifi-checkout.cjs.entry.js +10 -10
- package/dist/cjs/justifi-checkouts-list-filters.cjs.entry.js +6 -6
- package/dist/cjs/justifi-checkouts-list.cjs.entry.js +12 -12
- package/dist/cjs/justifi-config-provider.cjs.entry.js +3 -3
- package/dist/cjs/justifi-details.cjs.entry.js +3 -3
- package/dist/cjs/justifi-dispute-management-core.cjs.entry.js +1 -1
- package/dist/cjs/justifi-dispute-management.cjs.entry.js +7 -7
- package/dist/cjs/justifi-dispute-notification_3.cjs.entry.js +10 -10
- package/dist/cjs/justifi-gross-payment-chart.cjs.entry.js +7 -7
- package/dist/cjs/justifi-order-terminals.cjs.entry.js +10 -10
- package/dist/cjs/justifi-owner-form_3.cjs.entry.js +12 -12
- package/dist/cjs/justifi-payment-details.cjs.entry.js +9 -9
- package/dist/cjs/justifi-payment-provisioning-core.cjs.entry.js +4 -4
- package/dist/cjs/justifi-payment-provisioning.cjs.entry.js +8 -8
- package/dist/cjs/justifi-payment-transactions-list.cjs.entry.js +10 -10
- package/dist/cjs/justifi-payments-list-filters.cjs.entry.js +4 -4
- package/dist/cjs/justifi-payments-list.cjs.entry.js +11 -11
- package/dist/cjs/justifi-payout-details.cjs.entry.js +8 -8
- package/dist/cjs/justifi-payout-transactions-list.cjs.entry.js +10 -10
- package/dist/cjs/justifi-payouts-list-filters.cjs.entry.js +4 -4
- package/dist/cjs/justifi-payouts-list.cjs.entry.js +12 -12
- package/dist/cjs/justifi-refund-payment.cjs.entry.js +12 -12
- package/dist/cjs/justifi-saved-payment-method.cjs.entry.js +2 -2
- package/dist/cjs/justifi-season-interruption-insurance.cjs.entry.js +10 -10
- package/dist/cjs/justifi-skeleton.cjs.entry.js +3 -3
- package/dist/cjs/justifi-terminal-orders-list-filters.cjs.entry.js +5 -5
- package/dist/cjs/justifi-terminal-orders-list.cjs.entry.js +9 -9
- package/dist/cjs/justifi-terminals-list-filters.cjs.entry.js +5 -5
- package/dist/cjs/justifi-terminals-list.cjs.entry.js +11 -11
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/{package-DL-_SIgW.js → package-CFCy2fBx.js} +1 -1
- package/dist/cjs/pagination-menu.cjs.entry.js +4 -4
- package/dist/cjs/payment-details-core.cjs.entry.js +6 -6
- package/dist/cjs/payment-method-option.cjs.entry.js +2 -2
- package/dist/cjs/{payment.service-Bk5f4yNM.js → payment.service-DUq-W7tS.js} +1 -1
- package/dist/cjs/payments-list-core.cjs.entry.js +9 -9
- package/dist/cjs/{payments-list-params-state-CKeoLpqm.js → payments-list-params-state-C4c8UZtP.js} +1 -1
- package/dist/cjs/{payments-status-B0mynjDF.js → payments-status-3iIQkoov.js} +2 -2
- package/dist/cjs/{payments-table-Dt_B6-wz.js → payments-table-BSHUQhM-.js} +2 -2
- package/dist/cjs/payout-details-core.cjs.entry.js +7 -7
- package/dist/cjs/{payout.service-DYm731Kq.js → payout.service-DoKMr8Xw.js} +1 -1
- package/dist/cjs/payouts-list-core.cjs.entry.js +9 -9
- package/dist/cjs/{payouts-list-params-state-CKeoLpqm.js → payouts-list-params-state-C4c8UZtP.js} +1 -1
- package/dist/cjs/{payouts-status-MC0n0N1x.js → payouts-status-DoQbxIms.js} +2 -2
- package/dist/cjs/{payouts-table-CjJEGkLL.js → payouts-table-BD_Fhz_j.js} +2 -2
- package/dist/cjs/{schema-validations-Bj7eYNO8.js → schema-validations-jek_iZ9W.js} +1 -1
- package/dist/cjs/{skeleton-CMESEszj.js → skeleton-CuIMC98G.js} +1 -1
- package/dist/cjs/{spinner-BePlCbOD.js → spinner-CMZXdrPe.js} +1 -1
- package/dist/cjs/{styled-host-CvM9RrsT.js → styled-host-2KXbjOFw.js} +1 -1
- package/dist/cjs/{table-1JBgqBkL.js → table-DlQCUVag.js} +2 -2
- package/dist/cjs/table-filters-menu.cjs.entry.js +2 -2
- package/dist/cjs/terminal-orders-list-core.cjs.entry.js +8 -8
- package/dist/cjs/{terminal-orders-list-params-state-CKeoLpqm.js → terminal-orders-list-params-state-C4c8UZtP.js} +1 -1
- package/dist/cjs/{terminal-orders-table-DuvYC2f1.js → terminal-orders-table-t6XxNy_K.js} +3 -3
- package/dist/cjs/terminal-quantity-selector.cjs.entry.js +1 -1
- package/dist/cjs/{terminal.service-B4FQ6roy.js → terminal.service-Iyje71vN.js} +1 -1
- package/dist/cjs/terminals-list-core.cjs.entry.js +8 -8
- package/dist/cjs/terminals-list-params-state-C4c8UZtP.js +22 -0
- package/dist/cjs/{terminals-table--d49kyCn.js → terminals-table-BTdKRiBN.js} +2 -2
- package/dist/cjs/{utils-BNjLFSUk.js → utils-FFP5ZHyE.js} +1 -1
- package/dist/cjs/webcomponents.cjs.js +3 -3
- package/dist/collection/collection-manifest.json +2 -2
- package/dist/collection/components/business-forms/business-form/additional-questions/additional-questions.js +6 -6
- package/dist/collection/components/business-forms/business-form/business-core-info/business-core-info.js +1 -1
- package/dist/collection/components/business-forms/business-form/business-representative/business-representative.js +6 -6
- package/dist/collection/components/business-forms/business-form/legal-address-form/legal-address-form.js +6 -6
- package/dist/collection/components/business-forms/owner-form/identity-address/identity-address-form.js +1 -1
- package/dist/collection/components/business-forms/owner-form/owner-form-core.js +1 -1
- package/dist/collection/components/business-forms/owner-form/owner-form-inputs.js +6 -6
- package/dist/collection/components/business-forms/owner-form/owner-form.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/additional-questions/business-additional-questions-form-step.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/bank-account/bank-account-document-inputs.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/bank-account/bank-account-form-inputs.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/bank-account/business-bank-account-form-step.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/business-core-info/business-core-info-form-step.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/business-owners/business-owners-form-step.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/business-representative/business-representative-form-inputs.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/business-representative/business-representative-form-step.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/form-control-monetary-provisioning.js +2 -2
- package/dist/collection/components/business-forms/payment-provisioning/legal-address-form/legal-address-form-step.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/payment-provisioning-core.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/payment-provisioning-form-buttons.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/payment-provisioning-form-steps.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/payment-provisioning.js +1 -1
- package/dist/collection/components/business-forms/payment-provisioning/terms-and-conditions/business-terms-conditions-form-step.js +1 -1
- package/dist/collection/components/checkout/bank-account-form/bank-account-form.js +2 -2
- package/dist/collection/components/checkout/card-form/card-form.js +2 -2
- package/dist/collection/components/checkout/checkout.js +2 -2
- package/dist/collection/components/checkout/save-new-payment-method.js +1 -1
- package/dist/collection/components/checkout/saved-payment-method.js +1 -1
- package/dist/collection/components/checkouts-list/checkouts-list-core.js +1 -1
- package/dist/collection/components/checkouts-list/checkouts-list-filters.js +1 -1
- package/dist/collection/components/checkouts-list/checkouts-list.js +1 -1
- package/dist/collection/components/modular-checkout/modular-checkout.js +2 -3
- package/dist/collection/components/modular-checkout/sub-components/apple-pay.js +8 -4
- package/dist/collection/components/modular-checkout/sub-components/bank-account-billing-form-simple.js +1 -1
- package/dist/collection/components/modular-checkout/sub-components/card-billing-form-simple.js +1 -1
- package/dist/collection/components/tokenize-payment-method/tokenize-payment-method.js +2 -3
- package/dist/collection/ui-components/details/details.js +1 -1
- package/dist/collection/ui-components/form/form-control-checkbox.js +2 -2
- package/dist/collection/ui-components/pagination-menu/pagination-menu.js +3 -3
- package/dist/collection/ui-components/shadow-dom-components/justifi-radio-list-item.js +1 -1
- package/dist/docs.json +19 -98
- package/dist/esm/{Api-CO0DBcUT.js → Api-D4tj-h4P.js} +1 -1
- package/dist/esm/additional-questions-details_5.entry.js +2 -2
- package/dist/esm/{badge-CRAuWlVu.js → badge-ChwzCNAF.js} +1 -1
- package/dist/esm/bank-account-document-form-inputs_4.entry.js +7 -7
- package/dist/esm/bank-account-form.entry.js +6 -6
- package/dist/esm/{business-additional-questions-schema-9FAJSx_D.js → business-additional-questions-schema-C6NRHWEL.js} +2 -2
- package/dist/esm/business-details-core.entry.js +4 -4
- package/dist/esm/{business-identity-schema-CDJzknbg.js → business-identity-schema-D8n5dyLX.js} +2 -2
- package/dist/esm/{business.service-D2tRoPny.js → business.service-CsbtEDNi.js} +1 -1
- package/dist/esm/{button-B2XlI-Uy.js → button-SAIS_5os.js} +1 -1
- package/dist/esm/card-form.entry.js +6 -6
- package/dist/esm/{check-pkg-version-D3jZp8cz.js → check-pkg-version-B_Pl1uAE.js} +2 -2
- package/dist/esm/{checkout.service-BPYdgahN.js → checkout.service-BCkQ9pOA.js} +1 -1
- package/dist/esm/{checkout.store-DPOk5eUh.js → checkout.store-DBvS7cVB.js} +1 -1
- package/dist/esm/checkouts-list-core.entry.js +9 -9
- package/dist/esm/{checkouts-list-params-state-DmevqV6O.js → checkouts-list-params-state-C2_GlMKR.js} +1 -1
- package/dist/esm/{checkouts-table-DoHp51it.js → checkouts-table-CItEo0DU.js} +2 -2
- package/dist/esm/{config-state-Wdyw1F-s.js → config-state-Blo0ywwc.js} +1 -1
- package/dist/esm/custom-popper_2.entry.js +1 -1
- package/dist/esm/{dispute.service-Ct6DFjKt.js → dispute.service-CyLtJREK.js} +1 -1
- package/dist/esm/form-alert_5.entry.js +5 -5
- package/dist/esm/form-control-checkbox.entry.js +5 -5
- package/dist/esm/form-control-date.entry.js +2 -2
- package/dist/esm/{form-control-error-text-Bn_rq8AC.js → form-control-error-text-IXJJ4JpV.js} +1 -1
- package/dist/esm/form-control-file-v2_2.entry.js +2 -2
- package/dist/esm/{form-control-help-text-CuFo8IR5.js → form-control-help-text-CuhIsM3v.js} +1 -1
- package/dist/esm/form-control-help-text.entry.js +1 -1
- package/dist/esm/form-control-monetary-provisioning.entry.js +5 -5
- package/dist/esm/form-control-monetary.entry.js +3 -3
- package/dist/esm/form-control-number-masked_2.entry.js +3 -3
- package/dist/esm/form-control-number.entry.js +3 -3
- package/dist/esm/form-control-radio.entry.js +1 -1
- package/dist/esm/form-control-select_2.entry.js +2 -2
- package/dist/esm/{get-payment-details-BGQmxhRw.js → get-payment-details-BuT0QNOo.js} +1 -1
- package/dist/esm/{get-subaccounts-CYgVR2mk.js → get-subaccounts-VjY6-x_9.js} +2 -2
- package/dist/esm/gross-payment-chart-core.entry.js +3 -3
- package/dist/esm/{header-1-DWse7nuo.js → header-1-zXsamUS3.js} +1 -1
- package/dist/esm/{header-3-CSgiRXQA.js → header-3-DVtaUAlf.js} +1 -1
- package/dist/esm/hidden-input_2.entry.js +4 -4
- package/dist/esm/{index-DSUeaNWH.js → index-ZfXl6Xrm.js} +1 -1
- package/dist/esm/{index-CHdklybh.js → index-qipqIMyC.js} +13 -2
- package/dist/esm/{index.esm-IWS0494Y.js → index.esm-cYgKOXtz.js} +17 -18
- package/dist/esm/{insurance-state-DD0YD6c0.js → insurance-state-Dh9f36Qh.js} +2 -2
- package/dist/esm/justifi-additional-questions-form-step-core_6.entry.js +9 -9
- package/dist/esm/justifi-additional-questions-form-step_9.entry.js +16 -16
- package/dist/esm/justifi-additional-statement_8.entry.js +2 -2
- package/dist/esm/justifi-apple-pay.entry.js +14 -10
- package/dist/esm/justifi-bank-account-billing-form-simple_9.entry.js +17 -17
- package/dist/esm/justifi-business-details.entry.js +8 -8
- package/dist/esm/justifi-business-form.entry.js +15 -15
- package/dist/esm/justifi-business-representative-form-inputs.entry.js +2 -2
- package/dist/esm/justifi-checkout-summary_7.entry.js +12 -12
- package/dist/esm/justifi-checkout.entry.js +10 -10
- package/dist/esm/justifi-checkouts-list-filters.entry.js +6 -6
- package/dist/esm/justifi-checkouts-list.entry.js +12 -12
- package/dist/esm/justifi-config-provider.entry.js +3 -3
- package/dist/esm/justifi-details.entry.js +3 -3
- package/dist/esm/justifi-dispute-management-core.entry.js +1 -1
- package/dist/esm/justifi-dispute-management.entry.js +7 -7
- package/dist/esm/justifi-dispute-notification_3.entry.js +10 -10
- package/dist/esm/justifi-gross-payment-chart.entry.js +7 -7
- package/dist/esm/justifi-order-terminals.entry.js +10 -10
- package/dist/esm/justifi-owner-form_3.entry.js +12 -12
- package/dist/esm/justifi-payment-details.entry.js +9 -9
- package/dist/esm/justifi-payment-provisioning-core.entry.js +4 -4
- package/dist/esm/justifi-payment-provisioning.entry.js +8 -8
- package/dist/esm/justifi-payment-transactions-list.entry.js +10 -10
- package/dist/esm/justifi-payments-list-filters.entry.js +4 -4
- package/dist/esm/justifi-payments-list.entry.js +11 -11
- package/dist/esm/justifi-payout-details.entry.js +8 -8
- package/dist/esm/justifi-payout-transactions-list.entry.js +10 -10
- package/dist/esm/justifi-payouts-list-filters.entry.js +4 -4
- package/dist/esm/justifi-payouts-list.entry.js +12 -12
- package/dist/esm/justifi-refund-payment.entry.js +12 -12
- package/dist/esm/justifi-saved-payment-method.entry.js +2 -2
- package/dist/esm/justifi-season-interruption-insurance.entry.js +10 -10
- package/dist/esm/justifi-skeleton.entry.js +3 -3
- package/dist/esm/justifi-terminal-orders-list-filters.entry.js +5 -5
- package/dist/esm/justifi-terminal-orders-list.entry.js +9 -9
- package/dist/esm/justifi-terminals-list-filters.entry.js +5 -5
- package/dist/esm/justifi-terminals-list.entry.js +11 -11
- package/dist/esm/loader.js +3 -3
- package/dist/esm/{package-C5FfYVaH.js → package-pXjOPQhG.js} +1 -1
- package/dist/esm/pagination-menu.entry.js +4 -4
- package/dist/esm/payment-details-core.entry.js +6 -6
- package/dist/esm/payment-method-option.entry.js +2 -2
- package/dist/esm/{payment.service-D3ze0Zdq.js → payment.service-QJEmd6Nl.js} +1 -1
- package/dist/esm/payments-list-core.entry.js +9 -9
- package/dist/esm/{payments-list-params-state-DmevqV6O.js → payments-list-params-state-C2_GlMKR.js} +1 -1
- package/dist/esm/{payments-status-DTmQyPO9.js → payments-status-DDafc8Yr.js} +2 -2
- package/dist/esm/{payments-table-CavY9USC.js → payments-table-De3Jb6rY.js} +2 -2
- package/dist/esm/payout-details-core.entry.js +7 -7
- package/dist/esm/{payout.service-WXSktQvI.js → payout.service-XxyEr0rj.js} +1 -1
- package/dist/esm/payouts-list-core.entry.js +9 -9
- package/dist/esm/{payouts-list-params-state-DmevqV6O.js → payouts-list-params-state-C2_GlMKR.js} +1 -1
- package/dist/esm/{payouts-status-DTXrGUWw.js → payouts-status-u1eSRz3Q.js} +2 -2
- package/dist/esm/{payouts-table-3_J-SXvD.js → payouts-table-BO-MCzXj.js} +2 -2
- package/dist/esm/{schema-validations-B9dmY7ME.js → schema-validations-DcR1ujuX.js} +1 -1
- package/dist/esm/{skeleton-rMJsZa0a.js → skeleton-DtpkgjZ6.js} +1 -1
- package/dist/esm/{spinner-8n0qh4tK.js → spinner-CIXUVK4F.js} +1 -1
- package/dist/esm/{styled-host-DQq-l92c.js → styled-host-CbizlfAU.js} +1 -1
- package/dist/esm/{table-BUJMzXYe.js → table-DcRHK_sm.js} +2 -2
- package/dist/esm/table-filters-menu.entry.js +2 -2
- package/dist/esm/terminal-orders-list-core.entry.js +8 -8
- package/dist/esm/{terminal-orders-list-params-state-DmevqV6O.js → terminal-orders-list-params-state-C2_GlMKR.js} +1 -1
- package/dist/esm/{terminal-orders-table-gBU8rU8X.js → terminal-orders-table-9nsnrAq8.js} +3 -3
- package/dist/esm/terminal-quantity-selector.entry.js +1 -1
- package/dist/esm/{terminal.service-DihXdEs3.js → terminal.service-D2oETGnk.js} +1 -1
- package/dist/esm/terminals-list-core.entry.js +8 -8
- package/dist/esm/terminals-list-params-state-C2_GlMKR.js +16 -0
- package/dist/esm/{terminals-table-64XluocE.js → terminals-table-C6NO2m-t.js} +2 -2
- package/dist/esm/{utils-BvJW0VpC.js → utils-_ckvHjSW.js} +1 -1
- package/dist/esm/webcomponents.js +4 -4
- package/dist/module/additional-questions.js +2 -2
- package/dist/module/bank-account-billing-form-simple.js +1 -1
- package/dist/module/bank-account-document-inputs.js +1 -1
- package/dist/module/bank-account-form-inputs2.js +1 -1
- package/dist/module/bank-account-form.js +2 -2
- package/dist/module/business-additional-questions-form-step.js +1 -1
- package/dist/module/business-bank-account-form-step.js +1 -1
- package/dist/module/business-core-info-form-step.js +1 -1
- package/dist/module/business-core-info.js +1 -1
- package/dist/module/business-owners-form-step.js +1 -1
- package/dist/module/business-representative-form-inputs.js +1 -1
- package/dist/module/business-representative-form-step.js +1 -1
- package/dist/module/business-representative.js +2 -2
- package/dist/module/business-terms-conditions-form-step.js +1 -1
- package/dist/module/card-billing-form-simple.js +1 -1
- package/dist/module/card-form.js +2 -2
- package/dist/module/checkouts-list-core2.js +1 -1
- package/dist/module/details.js +1 -1
- package/dist/module/form-control-checkbox2.js +2 -2
- package/dist/module/form-control-monetary-provisioning2.js +2 -2
- package/dist/module/form.js +17 -18
- package/dist/module/identity-address-form.js +1 -1
- package/dist/module/justifi-apple-pay.js +7 -3
- package/dist/module/justifi-checkout.js +2 -2
- package/dist/module/justifi-checkouts-list-filters.js +1 -1
- package/dist/module/justifi-checkouts-list.js +1 -1
- package/dist/module/justifi-payment-provisioning.js +1 -1
- package/dist/module/justifi-radio-list-item2.js +1 -1
- package/dist/module/justifi-saved-payment-method.js +1 -1
- package/dist/module/legal-address-form-step.js +1 -1
- package/dist/module/legal-address-form.js +2 -2
- package/dist/module/owner-form-core2.js +1 -1
- package/dist/module/owner-form-inputs2.js +2 -2
- package/dist/module/owner-form.js +1 -1
- package/dist/module/package.js +1 -1
- package/dist/module/pagination-menu2.js +3 -3
- package/dist/module/payment-provisioning-core.js +1 -1
- package/dist/module/payment-provisioning-form-buttons.js +1 -1
- package/dist/module/payment-provisioning-form-steps.js +1 -1
- package/dist/module/save-new-payment-method.js +1 -1
- package/dist/types/components/business-forms/schemas/business-form-schema.d.ts +1 -1
- package/dist/types/components.d.ts +8 -10
- package/dist/types/stencil-public-runtime.d.ts +4 -6
- package/dist/webcomponents/{p-8d45e30b.entry.js → p-06b6b61e.entry.js} +1 -1
- package/dist/webcomponents/{p-e01fe757.entry.js → p-0801324e.entry.js} +1 -1
- package/dist/webcomponents/{p-9c110f7a.entry.js → p-10278c48.entry.js} +1 -1
- package/dist/webcomponents/p-19ccbeee.entry.js +1 -0
- package/dist/webcomponents/p-1b3b6956.entry.js +1 -0
- package/dist/webcomponents/{p-4c7622ed.entry.js → p-1b7926f6.entry.js} +1 -1
- package/dist/webcomponents/p-1c433962.entry.js +1 -0
- package/dist/webcomponents/{p-60d59291.entry.js → p-1f9f6bdc.entry.js} +1 -1
- package/dist/webcomponents/{p-fa53a04f.entry.js → p-2246aa69.entry.js} +1 -1
- package/dist/webcomponents/{p-0c25d57b.entry.js → p-246ef4ff.entry.js} +1 -1
- package/dist/webcomponents/{p-0e85331b.entry.js → p-27fc3ef0.entry.js} +4 -4
- package/dist/webcomponents/{p-870cee9b.entry.js → p-2abfee08.entry.js} +1 -1
- package/dist/webcomponents/{p-1a5f53f4.entry.js → p-30147031.entry.js} +1 -1
- package/dist/webcomponents/{p-c7291c13.entry.js → p-3546a5aa.entry.js} +1 -1
- package/dist/webcomponents/{p-1835e531.entry.js → p-3621a429.entry.js} +1 -1
- package/dist/webcomponents/p-3c1d950d.entry.js +1 -0
- package/dist/webcomponents/{p-d817d7e4.entry.js → p-3d37045d.entry.js} +1 -1
- package/dist/webcomponents/p-406ba650.entry.js +1 -0
- package/dist/webcomponents/{p-755fa2b3.entry.js → p-4332962a.entry.js} +1 -1
- package/dist/webcomponents/{p-57d30e26.entry.js → p-4466d28d.entry.js} +1 -1
- package/dist/webcomponents/{p-c85cc2ca.entry.js → p-44d1341c.entry.js} +1 -1
- package/dist/webcomponents/p-46db49dd.entry.js +1 -0
- package/dist/webcomponents/p-4d5c71c4.entry.js +1 -0
- package/dist/webcomponents/{p-80feb885.entry.js → p-4ea83bfd.entry.js} +1 -1
- package/dist/webcomponents/{p-8b42eee7.entry.js → p-558f7967.entry.js} +1 -1
- package/dist/webcomponents/{p-7576e449.entry.js → p-5c477f08.entry.js} +1 -1
- package/dist/webcomponents/{p-29964705.entry.js → p-629c1d75.entry.js} +1 -1
- package/dist/webcomponents/p-68329f16.entry.js +1 -0
- package/dist/webcomponents/p-6fe79f16.entry.js +1 -0
- package/dist/webcomponents/{p-8cc80cda.entry.js → p-718f8b2c.entry.js} +1 -1
- package/dist/webcomponents/{p-0ad7a361.entry.js → p-73f88870.entry.js} +1 -1
- package/dist/webcomponents/{p-6f6e17cf.entry.js → p-760a5b4f.entry.js} +1 -1
- package/dist/webcomponents/{p-0aa2e1f9.entry.js → p-779e4467.entry.js} +1 -1
- package/dist/webcomponents/{p-318a95e7.entry.js → p-7aeb20d2.entry.js} +1 -1
- package/dist/webcomponents/{p-528300cf.entry.js → p-7c5cd118.entry.js} +1 -1
- package/dist/webcomponents/{p-74b96d25.entry.js → p-7ef3cb23.entry.js} +1 -1
- package/dist/webcomponents/{p-4de4598e.entry.js → p-84043580.entry.js} +1 -1
- package/dist/webcomponents/{p-0f4ea94a.entry.js → p-868ed3b6.entry.js} +1 -1
- package/dist/webcomponents/{p-c65afd95.entry.js → p-87f598ef.entry.js} +1 -1
- package/dist/webcomponents/p-8975bf93.entry.js +1 -0
- package/dist/webcomponents/{p-5f4b95f4.entry.js → p-906fdf0c.entry.js} +1 -1
- package/dist/webcomponents/{p-1a41c6ee.entry.js → p-90e43440.entry.js} +1 -1
- package/dist/webcomponents/{p-cf78e63a.entry.js → p-914e168d.entry.js} +1 -1
- package/dist/webcomponents/p-91c1e2ac.entry.js +1 -0
- package/dist/webcomponents/{p-664c9b1b.entry.js → p-95348ff6.entry.js} +1 -1
- package/dist/webcomponents/p-9f04cac4.entry.js +1 -0
- package/dist/webcomponents/p-B4idKqyn.js +1 -0
- package/dist/webcomponents/{p-ZWhv_80v.js → p-BB5-CJF-.js} +1 -1
- package/dist/webcomponents/{p-mxgDrK6T.js → p-BIPdn2VU.js} +1 -1
- package/dist/webcomponents/{p-Dph3Ao9s.js → p-BUa0YOaw.js} +1 -1
- package/dist/webcomponents/p-BY2p6Sxk.js +1 -0
- package/dist/webcomponents/{p-UmoEDufy.js → p-BZ7C9duj.js} +1 -1
- package/dist/webcomponents/{p-c3Fl3YIP.js → p-BdLLGV9t.js} +1 -1
- package/dist/webcomponents/p-BguBT6Hn.js +1 -0
- package/dist/webcomponents/{p-BuWHmUFx.js → p-Bp_QFeog.js} +1 -1
- package/dist/webcomponents/p-Bvp7uul3.js +1 -0
- package/dist/webcomponents/{p-BGRyC6Jk.js → p-C1xGBPma.js} +1 -1
- package/dist/webcomponents/p-C3n7-tlg.js +1 -0
- package/dist/webcomponents/{p-CXEvc-gI.js → p-CLQx9p9q.js} +1 -1
- package/dist/webcomponents/{p-CZjKnrRR.js → p-CPVN4dXS.js} +1 -1
- package/dist/webcomponents/p-CQeex56P.js +1 -0
- package/dist/webcomponents/{p-DiJD6Iqx.js → p-CR9D6mKt.js} +1 -1
- package/dist/webcomponents/p-CU4XQ3fO.js +1 -0
- package/dist/webcomponents/{p-PSJOKMWp.js → p-CYBR4K2p.js} +1 -1
- package/dist/webcomponents/{p-hzzlBrP2.js → p-C_3N7nqh.js} +1 -1
- package/dist/webcomponents/{p-BY5BgAd3.js → p-CaxjN6Uo.js} +1 -1
- package/dist/webcomponents/{p-CIN-y_rT.js → p-CpKvg1ok.js} +1 -1
- package/dist/webcomponents/{p-BVHUyJdS.js → p-CrQgyTRz.js} +1 -1
- package/dist/webcomponents/{p-BSa0NCli.js → p-CxzFvTgf.js} +1 -1
- package/dist/webcomponents/{p-DFNk_DP8.js → p-CzPUMw00.js} +1 -1
- package/dist/webcomponents/{p-D8uar3Ri.js → p-D--yCspA.js} +1 -1
- package/dist/webcomponents/{p-DbpL6AJS.js → p-D-JYHdJ7.js} +1 -1
- package/dist/webcomponents/{p-BB-9jeDZ.js → p-D6XirF21.js} +1 -1
- package/dist/webcomponents/{p-BDGiGASo.js → p-DCMrHeJI.js} +1 -1
- package/dist/webcomponents/{p-C9iide2W.js → p-DSP8qjHL.js} +1 -1
- package/dist/webcomponents/p-DbX0g1WF.js +1 -0
- package/dist/webcomponents/{p-f0Mcy7rH.js → p-De8UloOS.js} +1 -1
- package/dist/webcomponents/{p-DwBh6VCY.js → p-DsAwPf2y.js} +1 -1
- package/dist/webcomponents/p-DvZcI6pC.js +1 -0
- package/dist/webcomponents/p-DyDHaG6n.js +1 -0
- package/dist/webcomponents/{p-DWMITBje.js → p-DyOgQlh2.js} +1 -1
- package/dist/webcomponents/p-IG_KR8zP.js +1 -0
- package/dist/webcomponents/{p-tYuXMkCd.js → p-PgEzcvI6.js} +1 -1
- package/dist/webcomponents/p-Xv8DuU3Y.js +1 -0
- package/dist/webcomponents/p-a57c1400.entry.js +1 -0
- package/dist/webcomponents/{p-2ca59580.entry.js → p-a71a5e64.entry.js} +1 -1
- package/dist/webcomponents/{p-3bb7b07f.entry.js → p-a90b8b93.entry.js} +1 -1
- package/dist/webcomponents/{p-3d6e54cb.entry.js → p-b4e673fe.entry.js} +1 -1
- package/dist/webcomponents/{p-d16a348c.entry.js → p-bc902ec2.entry.js} +1 -1
- package/dist/webcomponents/p-bf82201a.entry.js +1 -0
- package/dist/webcomponents/{p-4d60eadc.entry.js → p-c16c0cbc.entry.js} +1 -1
- package/dist/webcomponents/{p-ba579b93.entry.js → p-c685fc33.entry.js} +1 -1
- package/dist/webcomponents/p-d0f93668.entry.js +1 -0
- package/dist/webcomponents/{p-c9863f5a.entry.js → p-d34befd7.entry.js} +1 -1
- package/dist/webcomponents/{p-6b56543b.entry.js → p-d3f5ff95.entry.js} +1 -1
- package/dist/webcomponents/p-df7f36aa.entry.js +1 -0
- package/dist/webcomponents/p-e035a92e.entry.js +1 -0
- package/dist/webcomponents/{p-27f20ccf.entry.js → p-e2a38ad0.entry.js} +1 -1
- package/dist/webcomponents/p-e628a0c8.entry.js +1 -0
- package/dist/webcomponents/{p-dccdcac8.entry.js → p-e6516014.entry.js} +1 -1
- package/dist/webcomponents/{p-3013484d.entry.js → p-e6e96be2.entry.js} +1 -1
- package/dist/webcomponents/{p-357c355e.entry.js → p-e79338f9.entry.js} +1 -1
- package/dist/webcomponents/p-eafd179b.entry.js +1 -0
- package/dist/webcomponents/{p-25344f42.entry.js → p-f5c3f489.entry.js} +1 -1
- package/dist/webcomponents/{p-cba326c0.entry.js → p-f6cf3e2b.entry.js} +1 -1
- package/dist/webcomponents/p-fUtq2xDs.js +1 -0
- package/dist/webcomponents/{p-152436e2.entry.js → p-ffe01f1b.entry.js} +1 -1
- package/dist/webcomponents/{p-DrXVtFfH.js → p-oGKW57R8.js} +1 -1
- package/dist/webcomponents/p-pXjOPQhG.js +1 -0
- package/dist/webcomponents/p-qipqIMyC.js +2 -0
- package/dist/webcomponents/{p-CkX-nM5d.js → p-xY5RkFuA.js} +1 -1
- package/dist/webcomponents/webcomponents.esm.js +1 -1
- package/package.json +13 -13
- package/LICENSE +0 -21
- package/dist/cjs/terminals-list-params-state-CKeoLpqm.js +0 -22
- package/dist/esm/terminals-list-params-state-DmevqV6O.js +0 -16
- package/dist/webcomponents/p-15e47d22.entry.js +0 -1
- package/dist/webcomponents/p-1a198ab4.entry.js +0 -1
- package/dist/webcomponents/p-2242b349.entry.js +0 -1
- package/dist/webcomponents/p-2f7ff817.entry.js +0 -1
- package/dist/webcomponents/p-33c5f41b.entry.js +0 -1
- package/dist/webcomponents/p-38Vv0Nju.js +0 -1
- package/dist/webcomponents/p-3b01c9c4.entry.js +0 -1
- package/dist/webcomponents/p-5170419e.entry.js +0 -1
- package/dist/webcomponents/p-61980e9a.entry.js +0 -1
- package/dist/webcomponents/p-78c17caf.entry.js +0 -1
- package/dist/webcomponents/p-7cd28a8b.entry.js +0 -1
- package/dist/webcomponents/p-85a1f152.entry.js +0 -1
- package/dist/webcomponents/p-85d82d77.entry.js +0 -1
- package/dist/webcomponents/p-8b414739.entry.js +0 -1
- package/dist/webcomponents/p-9fec7ff1.entry.js +0 -1
- package/dist/webcomponents/p-BC2AKcRD.js +0 -1
- package/dist/webcomponents/p-BffoVWib.js +0 -1
- package/dist/webcomponents/p-C5FfYVaH.js +0 -1
- package/dist/webcomponents/p-CHdklybh.js +0 -2
- package/dist/webcomponents/p-CVm_PxHa.js +0 -1
- package/dist/webcomponents/p-CZ27xhGU.js +0 -1
- package/dist/webcomponents/p-DFEjrRhP.js +0 -1
- package/dist/webcomponents/p-DcDYb1RC.js +0 -1
- package/dist/webcomponents/p-DhUrfS4M.js +0 -1
- package/dist/webcomponents/p-Dk0xo1G9.js +0 -1
- package/dist/webcomponents/p-DrRpEAef.js +0 -1
- package/dist/webcomponents/p-DsL9brW-.js +0 -1
- package/dist/webcomponents/p-WJLXezN2.js +0 -1
- package/dist/webcomponents/p-ab0e20cd.entry.js +0 -1
- package/dist/webcomponents/p-b40aa9da.entry.js +0 -1
- package/dist/webcomponents/p-bc5698fe.entry.js +0 -1
- package/dist/webcomponents/p-c53099b1.entry.js +0 -1
- package/dist/webcomponents/p-c96feb00.entry.js +0 -1
- package/dist/webcomponents/p-oIQjnSZa.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./p-Bp_QFeog.js";import"./p-HXpYMWUU.js";import{C as o}from"./p-Cjcsf8ku.js";import{P as r}from"./p-c4Mh3ZZ_.js";import"./p-CLHwhyvu.js";import"./p-BlJnA265.js";import"./p-BH0Xfn-F.js";import{g as s,a as p}from"./p-D2muobcE.js";const i=({id:i,authToken:t,service:e})=>async({onSuccess:a,onError:n,final:c})=>{var m;try{const c=await e.fetchPayment(i,t);if(c.error){n({error:p(c.error),code:s(null===(m=c.error)||void 0===m?void 0:m.code),severity:o.ERROR})}else a({payment:new r(c.data)})}catch(r){const i=s(null==r?void 0:r.code);n({error:p(r),code:i,severity:o.ERROR})}finally{c()}};export{i as m}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e}from"./p-
|
|
1
|
+
import{a as e}from"./p-CR9D6mKt.js";import{S as a}from"./p-BX8GieXu.js";import{b as t,a as s,r,s as n,c as i}from"./p-yH3TC3ZQ.js";const c=e=>""===e?null:e,u=/^\d+$/,l=/P\.?\s?O\.?\s?Box|Postal\sBox/i,m=e().email("Enter valid email").transform(c),o=e().matches(/^\d{10}$/,"Enter valid phone number").transform(c),d=e().min(2,"Name must be at least 2 characters").max(100,"Name must be less than 100 characters").transform(c),b=e().min(2,"Name must be at least 2 characters").max(100,"Name must be less than 100 characters").transform(c),h=e().matches(/^(?:http(s)?:\/\/)?(?:www\.)?[-a-zA-Z0-9@:%._\+~#=]{2,256}\.[a-z]{2,6}\b([-a-zA-Z0-9@:%_\+.~#?&//=]*)$/,"Enter valid website url").transform(c),v=e().oneOf(t.map((e=>e.value)),"Select business classification").transform(c),p=e().min(2,"Industry must be at least 2 characters").max(50,"Industry must be less than 50 characters").transform(c),E=e().matches(u,"Enter valid tax id, SSN, or EIN").test("not-repeat","Enter valid tax id, SSN, or EIN",(e=>!/^(\d)\1+$/.test(e))).test("not-seq","Enter valid tax id, SSN, or EIN",(e=>"123456789"!==e)).transform(c),N=e().test("not-future","Date of incorporation cannot be in the future",(e=>new Date(e)<=new Date)).transform(c),S=e().min(2,"Name must be at least 2 characters").max(100,"Name must be less than 100 characters").transform(c),y=e().min(2,"Title must be at least 2 characters").max(50,"Title must be less than 50 characters").transform(c),g=a=>e().test("min","Enter a valid date",(e=>new Date(e)>=new Date("1902-01-01"))).test("age",`${a} must be at least 18 years old`,(e=>{const a=new Date(e),t=new Date;return t.setFullYear(t.getFullYear()-18),a<=t})).transform(c),w=e().matches(/^(?!000|666|9\d{2})\d{3}(?!00)\d{2}(?!0000)\d{4}$/,"Enter valid SSN").when("ssn_last4",{is:e=>!e||0===e.length,then:e=>e.required("Enter SSN"),otherwise:e=>e.nullable()}).test("not-repeat","Enter valid SSN",(e=>!/^(\d)\1+$/.test(e))).test("not-seq","Enter valid SSN",(e=>"123456789"!==e)).transform(c),A=e().min(5,"Address must be at least 5 characters").max(100,"Address must be less than 100 characters").test("not-po-box","A PO Box is not a valid address entry",(e=>!l.test(e))).transform(c),x=e().max(100,"Address must be less than 100 characters").test("not-po-box","A PO Box is not a valid address entry",(e=>!l.test(e))).transform(c),$=e().min(2,"City must be at least 2 characters").max(50,"City must be less than 50 characters").transform(c),f=e().oneOf(a.map((e=>e.value)),"Enter a 2-letter state abbreviation, such as CA").transform(c),D=e().matches(/^[0-9]{5}$/,"Enter valid postal code").transform(c),B=e().matches(u,"Enter valid revenue").transform(c),C=e().matches(u,"Enter valid payment volume").transform(c),I=e().oneOf(s.map((e=>e.value)),"Select when service is received").transform(c),_=e().oneOf(r.map((e=>e.value)),"Select recurring payments").transform(c),j=e().when("business_recurring_payments",{is:e=>"Yes"===e,then:e=>e.required("Enter recurring payments percentage"),otherwise:e=>e.nullable()}).transform(c),z=e().oneOf(n.map((e=>e.value)),"Select seasonal business").transform(c),P=e().transform(c),q=e().min(2,"Name must be at least 2 characters").max(50,"Name must be less than 50 characters").transform(c),O=e().min(2,"Name must be at least 2 characters").max(50,"Name must be less than 50 characters").transform(c),T=e().oneOf(i.map((e=>e.value)),"Select account type").transform(c),Z=e().min(4,"Account number must be at least 4 digits").max(17,"Account number must be less than 17 digits").matches(u,"Enter valid account number").test("not-repeat","Enter valid account number",(e=>!/^(\d)\1+$/.test(e))).transform(c),R=e().length(9,"Routing number must be 9 digits").matches(u,"Enter valid routing number").test("not-repeat","Enter valid routing number",(e=>!/^(\d)\1+$/.test(e))).test("valid","Enter valid routing number",(e=>(e=>{if(!e)return!1;const a=Array.from(String(e),Number);return 9===a.length&&0==(3*(a[0]+a[3]+a[6])+7*(a[1]+a[4]+a[7])+(a[2]+a[5]+a[8]))%10})(e))).transform(c);export{Z as A,T as B,O as C,q as D,b as a,v as b,d as c,N as d,m as e,_ as f,I as g,C as h,p as i,B as j,D as k,f as l,$ as m,x as n,P as o,o as p,A as q,j as r,z as s,E as t,w as u,g as v,h as w,y as x,S as y,R as z}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{h as e}from"./p-
|
|
1
|
+
import{h as e}from"./p-qipqIMyC.js";import{B as t,a}from"./p-D--yCspA.js";const i=i=>e(a,Object.assign({},{succeeded:{variant:t.SUCCESS,title:"This payment was successfully captured",text:"Succeeded"},authorized:{variant:t.PRIMARY,title:"This card payment was authorized, but not captured. It could still succeed or fail.",text:"Authorized"},pending:{variant:t.PRIMARY,title:"This ACH payment was processed, but the funds have not settled. It could still succeed or fail.",text:"Pending"},achFailed:{variant:t.DANGER,title:"The funds couldn't be collected for this ACH payment (in addition to the original payment, an ACH return and fee will appear in a payout)",text:"ACH Failed"},failed:{variant:t.DANGER,title:"This card payment did not go through (it will not appear in a payout)",text:"Failed"},canceled:{variant:t.DANGER,title:"This payment was canceled",text:"Canceled"},disputed:{variant:t.SECONDARY,title:"The account holder disputed this payment. The amount has been returned and a fee assessed.",text:"Disputed"},fully_refunded:{variant:t.SECONDARY,title:"The full amount of this payment has been refunded",text:"Fully Refunded"},partially_refunded:{variant:t.SECONDARY,title:"A portion of this payment has been refunded",text:"Partially Refunded"}}[i]));export{i as M}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{h as t}from"./p-
|
|
1
|
+
import{h as t}from"./p-qipqIMyC.js";import{N as e,O as r}from"./p-RvUQ__Pq.js";import{a}from"./p-BHf9IqGw.js";import"./p-Bp_QFeog.js";import"./p-Cjcsf8ku.js";import{b as s}from"./p-c4Mh3ZZ_.js";import"./p-CLHwhyvu.js";import"./p-BlJnA265.js";import"./p-BH0Xfn-F.js";import{B as o,a as i}from"./p-D--yCspA.js";const d="created_at,updated_at,order_status,quantity",p={created_at:()=>t("th",{part:e,scope:"col",title:"The date and time the order was created"},"Created At"),updated_at:()=>t("th",{part:e,scope:"col",title:"The date and time the order was last updated"},"Updated At"),order_status:()=>t("th",{part:e,scope:"col",title:"The current status of the order"},"Order Status"),business_id:()=>t("th",{part:e,scope:"col",title:"The business ID associated with the order"},"Business ID"),company_name:()=>t("th",{part:e,scope:"col",title:"The business name associated with the order"},"Business Name"),provider:()=>t("th",{part:e,scope:"col",title:"The provider associated with the order"},"Provider"),order_type:()=>t("th",{part:e,scope:"col",title:"The type of order"},"Order Type"),quantity:()=>t("th",{part:e,scope:"col",title:"The number of terminals associated with the order"},"Order Quantity")},l={created_at:(e,s)=>t("td",{part:r(s)},t("div",{class:"fw-bold"},a(e.created_at,{showDisplayDate:!0})),t("div",{class:"fw-bold"},a(e.created_at,{showTime:!0}))),updated_at:(e,s)=>t("td",{part:r(s)},t("div",{class:"fw-bold"},a(e.updated_at,{showDisplayDate:!0})),t("div",{class:"fw-bold"},a(e.updated_at,{showTime:!0}))),order_status:(e,a)=>t("td",{part:r(a)},t(i,Object.assign({},{submitted:{variant:o.PRIMARY,title:"This order is submitted",text:"Submitted"},completed:{variant:o.SUCCESS,title:"This order has been completed",text:"Completed"},created:{variant:o.SECONDARY,title:"This order is created",text:"Created"},in_progress:{variant:o.PRIMARY,title:"This order is in progress",text:"In Progress"},on_hold:{variant:o.WARNING,title:"This order is on hold",text:"On Hold"},canceled:{variant:o.DANGER,title:"This order is canceled",text:"Canceled"}}[e.order_status]))),business_id:(e,a)=>t("td",{part:r(a)},e.business_id),company_name:(e,a)=>t("td",{part:r(a)},e.company_name),provider:(e,a)=>t("td",{part:r(a)},e.provider),order_type:(e,a)=>{let o;return e.order_type===s.boardingOnly?o="Boarding Only":e.order_type===s.boardingShipping&&(o="Boarding & Shipping"),t("td",{part:r(a)},o)},quantity:(e,a)=>t("td",{part:r(a)},e.terminals.length)};export{l as a,d,p as t}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{A as n}from"./p-
|
|
1
|
+
import{A as n}from"./p-BUa0YOaw.js";import"./p-Cjcsf8ku.js";import"./p-c4Mh3ZZ_.js";import"./p-CLHwhyvu.js";import"./p-BlJnA265.js";import"./p-BH0Xfn-F.js";const t=n();class a{async fetchPayments(n,a,s){return t.get({endpoint:`account/${n}/payments`,params:s,authToken:a})}async fetchPayment(n,a){return t.get({endpoint:`payments/${n}`,authToken:a})}async fetchPaymentTransactions(n,a,s){return t.get({endpoint:`payments/${n}/payment_balance_transactions`,params:s,authToken:a})}}export{a as P}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as e}from"./p-
|
|
1
|
+
import{c as e}from"./p-DsAwPf2y.js";import{P as o}from"./p-DCIW8z1f.js";const n={accountId:"",authToken:"",billingFormFields:{address_postal_code:""},bnplEnabled:!1,insuranceEnabled:!1,bnplProviderApiVersion:"",bnplProviderCheckoutUrl:"",bnplProviderClientId:"",bnplProviderMode:"",checkoutId:"",checkoutLoaded:!1,bankAccountVerification:void 0,disableBankAccount:!1,disableBnpl:!1,disableCreditCard:!1,disablePaymentMethodGroup:!1,paymentAmount:0,paymentCurrency:"USD",paymentDescription:"",paymentMethodGroupId:void 0,paymentMethods:[],paymentToken:void 0,savePaymentMethod:!1,selectedPaymentMethod:void 0,totalAmount:0,plaidPublicToken:void 0,plaidLinkTokenId:void 0},{state:t,onChange:d}=e(n);function a(){var e;const n=[];if(!t.disablePaymentMethodGroup&&(null===(e=t.paymentMethods)||void 0===e?void 0:e.length)){const e=t.paymentMethods.some((e=>e.type===o.SAVED_CARD)),d=t.paymentMethods.some((e=>e.type===o.SAVED_BANK_ACCOUNT));e&&!t.disableCreditCard&&n.push(o.SAVED_CARD),d&&!t.disableBankAccount&&n.push(o.SAVED_BANK_ACCOUNT)}return t.disableCreditCard||n.push(o.NEW_CARD),t.disableBankAccount||n.push(o.NEW_BANK_ACCOUNT),t.bnplEnabled&&!t.disableBnpl&&n.push(o.SEZZLE),!0!==t.bankAccountVerification||t.disableBankAccount||n.push(o.PLAID),n}function i(e){Object.keys(n).forEach((o=>{d(o,(n=>e(o,n)))}))}Object.keys(n).forEach((e=>{d(e,(o=>{t[e]=o}))}));export{d as a,t as c,a as g,i as o}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{A as e}from"./p-
|
|
1
|
+
import{A as e}from"./p-BUa0YOaw.js";import"./p-Cjcsf8ku.js";import"./p-c4Mh3ZZ_.js";import"./p-CLHwhyvu.js";import"./p-BlJnA265.js";import"./p-BH0Xfn-F.js";const n=e();class r{async fetchTerminals(e,r,s){return n.get({endpoint:"terminals",params:s,headers:{Account:e},authToken:r})}async fetchTerminal(e,r){return n.get({endpoint:`terminals/${e}`,authToken:r})}async fetchTerminalModels(e,r){return n.get({endpoint:"terminals/order_models",headers:{"sub-account":e},authToken:r})}async orderTerminals(e,r){return n.post({endpoint:"terminals/orders",body:r,headers:{"sub-account":r.sub_account_id},authToken:e})}}export{r as T}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{h as t}from"./p-
|
|
1
|
+
import{h as t}from"./p-qipqIMyC.js";import{d as e,e as a}from"./p-BHf9IqGw.js";import{B as c,a as o}from"./p-D--yCspA.js";import{N as p,O as s}from"./p-RvUQ__Pq.js";const r="created_at,payment_amount,payment_description,payment_mode,status",d={created_at:()=>t("th",{part:p,scope:"col",title:"The date each checkout occurred"},"Processed On"),payment_amount:()=>t("th",{part:p,scope:"col",title:"The dollar amount of each checkout"},"Payment Amount"),payment_description:()=>t("th",{part:p,scope:"col",title:"The description of each checkout"},"Payment Description"),sub_account_name:()=>t("th",{part:p,scope:"col",title:"The sub account associated with the checkout"},"Sub Account"),payment_mode:()=>t("th",{part:p,scope:"col",title:"The payment mode of each checkout"},"Payment Mode"),status:()=>t("th",{part:p,scope:"col",title:"The current status of each checkout"},"Status")},n={created_at:(c,o)=>t("td",{part:s(o)},t("div",{class:"fw-bold"},a(c.created_at)),t("div",{class:"fw-bold"},e(c.created_at))),payment_amount:(e,a)=>t("td",{part:s(a)},e.formattedPaymentAmount(e.payment_amount)),payment_description:(e,a)=>t("td",{part:s(a)},e.payment_description),sub_account_name:(e,a)=>t("td",{part:s(a)},e.sub_account_name),payment_mode:(e,a)=>t("td",{part:s(a)},e.payment_mode),status:(e,a)=>t("td",{part:s(a)},t(o,Object.assign({},{created:{variant:c.PRIMARY,title:"The checkout has been created",text:"Created"},completed:{variant:c.SUCCESS,title:"The checkout has been completed",text:"Completed"},attempted:{variant:c.SECONDARY,title:"The checkout has been attempted",text:"Attempted"},expired:{variant:c.DANGER,title:"The checkout has expired",text:"Expired"}}[e.status])))};export{n as a,d as c,r as d}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{h as a}from"./p-
|
|
1
|
+
import{h as a}from"./p-qipqIMyC.js";import{D as r,E as s,F as g,G as e,H as n,I as d,J as i,K as t,L as b}from"./p-RvUQ__Pq.js";var c;!function(a){a.PRIMARY="primary",a.SECONDARY="secondary",a.SUCCESS="success",a.DANGER="danger",a.WARNING="warning",a.INFO="info",a.LIGHT="light",a.DARK="dark"}(c||(c={}));const o=c=>{const{variant:o,text:p,title:f}=c,l={default:"badge",primary:"badge bg-primary",secondary:"badge bg-secondary",success:"badge bg-success",danger:"badge bg-danger",warning:"badge bg-warning",info:"badge bg-info",light:"badge bg-light",dark:"badge bg-dark"},y={default:b,primary:t,secondary:i,success:d,danger:n,warning:e,info:g,light:s,dark:r};return a("span",{class:l[o]||l.default,part:y[o]||y.default,title:f},p)};export{c as B,o as a}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{h as t}from"./p-
|
|
1
|
+
import{h as t}from"./p-qipqIMyC.js";import{a}from"./p-BHf9IqGw.js";import{M as e}from"./p-fUtq2xDs.js";import{N as o,O as s}from"./p-RvUQ__Pq.js";const p="created_at,amount,status,payments_total,refunds_total,fees_total,other_total,csv",r={created_at:()=>t("th",{part:o,scope:"col",title:"The date the payout was deposited"},"Created"),sub_account_name:()=>t("th",{part:o,scope:"col",title:"The sub account associated with the payout"},"Sub Account"),payments_total:()=>t("th",{part:o,scope:"col",title:"The total payments amount associated with the payout"},"Payments"),refunds_total:()=>t("th",{part:o,scope:"col",title:"The total refunds amount associated with the payout"},"Refunds"),fees_total:()=>t("th",{part:o,scope:"col",title:"The total fees amount associated with the payout"},"Fees"),other_total:()=>t("th",{part:o,scope:"col",title:"The total other amount"},"Other"),amount:()=>t("th",{part:o,scope:"col",title:"The total amount of the payout"},"Amount"),status:()=>t("th",{part:o,scope:"col",title:"The real-time status of each payout"},"Status"),csv:()=>t("th",{part:o,scope:"col",title:"Export CSV"})},c=o=>({created_at:(e,o)=>t("td",{part:s(o)},t("div",{class:"fw-bold"},a(e.created_at,{showDisplayDate:!0}))),sub_account_name:(a,e)=>t("td",{part:s(e)},a.sub_account_name),payments_total:(a,e)=>t("td",{part:s(e)},a.formattedPaymentAmount(a.payments_total)),refunds_total:(a,e)=>t("td",{part:s(e)},a.formattedPaymentAmount(a.refunds_total)),fees_total:(a,e)=>t("td",{part:s(e)},a.formattedPaymentAmount(a.fees_total)),other_total:(a,e)=>t("td",{part:s(e)},a.formattedPaymentAmount(a.other_total)),amount:(a,e)=>t("td",{part:s(e)},a.formattedPaymentAmount(a.amount)),status:(a,o)=>t("td",{part:s(o)},e(a.status)),csv:(a,e)=>t("td",{part:s(e)},t("a",{href:"#",onClick:t=>{t.preventDefault(),o(a.id)}},"CSV"))});export{c as a,p as d,r as p}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{h as s}from"./p-
|
|
1
|
+
import{h as s}from"./p-qipqIMyC.js";import{ad as a,ae as r,af as n}from"./p-RvUQ__Pq.js";const t=(t,o)=>s("button",Object.assign({class:`btn btn-${t.variant}`,onClick:t.clickHandler,part:`${{primary:r,secondary:a}[t.variant]} ${t.isLoading?n:""}`},t),t.isLoading?s("div",{class:"spinner-border spinner-border-sm",role:"status",part:"button-spinner"},s("span",{class:"visually-hidden"},"Loading...")):o);export{t as B}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{h as r}from"./p-
|
|
1
|
+
import{h as r}from"./p-qipqIMyC.js";import{A as t}from"./p-RvUQ__Pq.js";const o=o=>{const{errorText:e,name:s}=o;return e?r("small",{class:"form-text text-danger",id:`form-error-text-${s}`,part:t},e):null};export{o as F}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as e}from"./p-
|
|
1
|
+
import{c as e}from"./p-CR9D6mKt.js";import{d as s,t as n,i as a,b as i,a as r,p as t,e as u,w as _,c as o,o as c,s as l,r as b,f as m,g as p,h as d,j as g}from"./p-CYBR4K2p.js";const v=c=>{const l=e({legal_name:o.required("Enter legal name"),website_url:_.required("Enter business website url"),email:u.required("Enter business email"),phone:t.required("Enter phone number"),doing_business_as:r.nullable(),classification:i.required("Select business classification"),industry:a.required("Enter a business industry"),tax_id:n.required("Enter valid tax ID (SSN or EIN) without dashes"),date_of_incorporation:s.required("Enter date of incorporation")}),b=e({legal_name:o.required("Enter legal name"),website_url:_.nullable(),email:u.nullable(),phone:t.nullable(),doing_business_as:r.nullable(),classification:i.nullable(),industry:a.nullable(),tax_id:n.nullable(),date_of_incorporation:s.nullable()});return c?b:l},y=s=>{const n=e({business_revenue:g.required("Enter business revenue"),business_payment_volume:d.required("Enter business payment volume"),business_when_service_received:p.required("Select when service is received"),business_recurring_payments:m.required("Select recurring payments"),business_recurring_payments_percentage:b,business_seasonal:l.required("Select business seasonal"),business_other_payment_details:c.nullable()}),a=e({business_revenue:g.nullable(),business_payment_volume:d.nullable(),business_when_service_received:p.nullable(),business_recurring_payments:m.nullable(),business_recurring_payments_percentage:b,business_seasonal:l.nullable(),business_other_payment_details:c.nullable()});return s?a:n};export{y as a,v as b}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{c as s}from"./p-DsAwPf2y.js";const t={},a={},o=s((()=>t)),{state:c,on:e}=o,p=s((()=>a)),{state:f}=p,j=()=>Object.assign(Object.assign({},c),f),r=()=>{o.reset()};export{r as c,c as f,j as g,e as o,f as p}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{A as t}from"./p-
|
|
1
|
+
import{A as t}from"./p-BUa0YOaw.js";import"./p-Cjcsf8ku.js";import"./p-c4Mh3ZZ_.js";import"./p-CLHwhyvu.js";import"./p-BlJnA265.js";import"./p-BH0Xfn-F.js";const a=t();class n{async fetchPayouts(t,n,s){return a.get({authToken:n,endpoint:`account/${t}/payouts`,params:s})}async fetchPayout(t,n){return a.get({authToken:n,endpoint:`payouts/${t}`})}async fetchCSV(t,n){return a.get({authToken:n,endpoint:`reports/payouts/${t}`})}async fetchPayoutTransactions(t,n,s){return a.get({authToken:n,endpoint:"balance_transactions",params:s,headers:{"sub-account":t}})}}export{n as P}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e,f as t}from"./p-
|
|
1
|
+
import{a as e,f as t}from"./p-qipqIMyC.js";const s=e=>!("isConnected"in e)||e.isConnected,n=(()=>{let e;return(...t)=>{e&&clearTimeout(e),e=setTimeout((()=>{e=0,(e=>{for(let t of e.keys())e.set(t,e.get(t).filter(s))})(...t)}),2e3)}})(),o=e=>"function"==typeof e?e():e,r=(e,t)=>{const s=e.indexOf(t);s>=0&&(e[s]=e[e.length-1],e.length--)},c=(s,c)=>{const p=((e,t=(e,t)=>e!==t)=>{const s=o(e);let n=new Map(Object.entries(s??{}));const c={dispose:[],get:[],set:[],reset:[]},p=new Map,a=()=>{n=new Map(Object.entries(o(e)??{})),c.reset.forEach((e=>e()))},i=e=>(c.get.forEach((t=>t(e))),n.get(e)),u=(e,s)=>{const o=n.get(e);t(s,o,e)&&(n.set(e,s),c.set.forEach((t=>t(e,s,o))))},f="undefined"==typeof Proxy?{}:new Proxy(s,{get:(e,t)=>i(t),ownKeys:()=>Array.from(n.keys()),getOwnPropertyDescriptor:()=>({enumerable:!0,configurable:!0}),has:(e,t)=>n.has(t),set:(e,t,s)=>(u(t,s),!0)}),d=(e,t)=>(c[e].push(t),()=>{r(c[e],t)});return{state:f,get:i,set:u,on:d,onChange:(t,s)=>{const n=(e,n)=>{e===t&&s(n)},r=()=>s(o(e)[t]),c=d("set",n),a=d("reset",r);return p.set(s,{setHandler:n,resetHandler:r,propName:t}),()=>{c(),a(),p.delete(s)}},use:(...e)=>{const t=e.reduce(((e,t)=>(t.set&&e.push(d("set",t.set)),t.get&&e.push(d("get",t.get)),t.reset&&e.push(d("reset",t.reset)),t.dispose&&e.push(d("dispose",t.dispose)),e)),[]);return()=>t.forEach((e=>e()))},dispose:()=>{c.dispose.forEach((e=>e())),a()},reset:a,forceUpdate:e=>{const t=n.get(e);c.set.forEach((s=>s(e,t,t)))},removeListener:(e,t)=>{const s=p.get(t);s&&s.propName===e&&(r(c.set,s.setHandler),r(c.reset,s.resetHandler),p.delete(t))}}})(s,c);return p.use((()=>{if("function"!=typeof e)return{};const s=new Map;return{dispose:()=>s.clear(),get:t=>{const n=e();n&&((e,t,s)=>{const n=e.get(t);n?n.includes(s)||n.push(s):e.set(t,[s])})(s,t,n)},set:e=>{const o=s.get(e);o&&s.set(e,o.filter(t)),n(s)},reset:()=>{s.forEach((e=>e.forEach(t))),n(s)}}})()),p};export{c}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{c as s}from"./p-DsAwPf2y.js";const t={},a={},o=s((()=>t)),{state:c,on:e}=o,p=s((()=>a)),{state:f}=p,j=()=>Object.assign(Object.assign({},c),f),r=()=>{o.reset()};export{r as c,c as f,j as g,e as o,f as p}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{c as s}from"./p-DsAwPf2y.js";const t={},a={},o=s((()=>t)),{state:c,on:e}=o,p=s((()=>a)),{state:f}=p,j=()=>Object.assign(Object.assign({},c),f),r=()=>{o.reset()};export{r as c,c as f,j as g,e as o,f as p}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{A as e}from"./p-
|
|
1
|
+
import{A as e}from"./p-BUa0YOaw.js";import"./p-Cjcsf8ku.js";import"./p-c4Mh3ZZ_.js";import"./p-CLHwhyvu.js";import"./p-BlJnA265.js";import"./p-BH0Xfn-F.js";const s=e();class t{async fetchDispute(e,t){return s.get({endpoint:`disputes/${e}`,authToken:t})}async updateDisputeResponse(e,t,p){return s.patch({endpoint:`disputes/${e}/response`,body:p,authToken:t})}async submitDisputeResponse(e,t,p){return s.post({endpoint:`disputes/${e}/response`,body:p,authToken:t})}async createDisputeEvidence(e,t,p){return s.put({endpoint:`disputes/${e}/evidence`,body:p,authToken:t})}}export{t as D}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{c as s}from"./p-DsAwPf2y.js";const t={},a={},o=s((()=>t)),{state:c,on:e}=o,p=s((()=>a)),{state:f}=p,j=()=>Object.assign(Object.assign({},c),f),r=()=>{o.reset()};export{r as c,c as f,j as g,e as o,f as p}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as e,a as t}from"./p-
|
|
1
|
+
import{c as e,a as t}from"./p-CR9D6mKt.js";import{k as n,l as s,m as a,n as r,q as o,u as i,v as l,p as c,e as m,x as d,y as p}from"./p-CYBR4K2p.js";const u=i=>{const l=e({line1:o.required("Enter street address"),line2:r.nullable(),city:a.required("Enter city"),state:s.required("Select state"),postal_code:n.required("Enter postal code"),country:t().required("Select country")}),c=e({line1:o.nullable(),line2:r.nullable(),city:a.nullable(),state:s.nullable(),postal_code:n.nullable(),country:t().required("Select country")});return i?c:l},E=(n,s)=>{const a=e({name:p.required(`Enter ${n} name`),title:d.required(`Enter ${n} title`),email:m.required(`Enter ${n} email`),phone:c.required("Enter phone number"),dob_full:l(n).required("Enter date of birth"),ssn_last4:t().nullable(),identification_number:i,address:u(s)}),r=e({name:p.required(`Enter ${n} name`),title:d.nullable(),email:m.nullable(),phone:c.nullable(),dob_full:l(n).nullable(),ssn_last4:t().nullable(),identification_number:i.nullable(),address:u(s)});return s?r:a};export{u as a,E as i}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{h as t}from"./p-qipqIMyC.js";import{y as e}from"./p-RvUQ__Pq.js";const s=({component:s="div",height:i,width:o,className:r,styles:a={}})=>{const p=Object.assign(Object.assign({},a),{width:o,height:i});return t(s,{class:`${r} skeleton`,style:p,part:e,"aria-hidden":"true"})};export{s as S}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e,h as a}from"./p-qipqIMyC.js";import{u as d,a as t,b as c}from"./p-1ydcg9ti.js";import{P as s,S as i}from"./p-B-iV5cYd.js";import{C as l}from"./p-RvUQ__Pq.js";import"./p-Dt-vy9Le.js";import"./p-BX8GieXu.js";const o=class{constructor(a){e(this,a),this.inputHandler=(e,a)=>{d(this.formController,{[e]:a})},this.onAddressFormUpdate=e=>{t(this.formController,Object.assign(Object.assign({},this.formController.values.getValue().address),e))}}render(){var e,d,t,o,r,f,n;return a("form",{key:"a2c558b8a6b66d7257fa86ef5f9c1d56a7a273db"},a("fieldset",{key:"23cb7f2debd4692c39cfe2311ce0d2549ca94ebc"},a("div",{key:"0c6e94b6a9da6924673f5ebeed93f237ff22a013",class:"d-flex align-items-center gap-2"},a("legend",{key:"a165d7dc17dddde2d6ce35af9d836a989f02ffaf",class:"mb-0",part:l},"Representative"),a("form-control-tooltip",{key:"5c2c29ae9ea82acc6c923c870f4ece5db5e7afb9",helpText:"The representative for your business needs to be someone who has significant control over managing your business’s finance. You will have an opportunity to add owners later in the form."})),a("hr",{key:"bc481e820461c6ec2088f2879cb9a5837ed02884",class:"mt-2"}),a("div",{key:"ff4b0731213ddc42ebabb79d49984b83d376f742",class:"row gy-3"},a("div",{key:"99cac91d3657bce68ce97028342d49cb8a2bb314",class:"col-12 col-md-8"},a("form-control-text",{key:"534e81b075f732ae3953d8f904199d61a43de4bb",name:"name",label:"Full Name",defaultValue:null===(e=this.representativeDefaultValue)||void 0===e?void 0:e.name,errorText:this.errors.name,inputHandler:this.inputHandler})),a("div",{key:"6070fdff99a868b50deb59c9d006d3c4775a50bd",class:"col-12 col-md-4"},a("form-control-text",{key:"c92477cc30c5a9c7d99842dff2855edce67185f9",name:"title",label:"Title",defaultValue:null===(d=this.representativeDefaultValue)||void 0===d?void 0:d.title,errorText:this.errors.title,inputHandler:this.inputHandler,helpText:"Role at your business, e.g. President, CEO, Treasurer."})),a("div",{key:"14d953417a1ec0292d75251b37b580361def0fb3",class:"col-12 col-md-6"},a("form-control-text",{key:"42562735066b104619b8aa4da966aaec462f177b",name:"email",label:"Email Address",defaultValue:null===(t=this.representativeDefaultValue)||void 0===t?void 0:t.email,errorText:this.errors.email,inputHandler:this.inputHandler})),a("div",{key:"cb7f6173a31fac67edf74844f0807ea94446c59b",class:"col-12 col-md-6"},a("form-control-number-masked",{key:"42b0833d545243c11f515d320aac5408bb744e89",name:"phone",label:"Phone Number",defaultValue:null===(o=this.representativeDefaultValue)||void 0===o?void 0:o.phone,errorText:this.errors.phone,inputHandler:this.inputHandler,mask:s.US})),a("div",{key:"a9468f20a7d832ae44d771c3b8913c32cf0ef2ab",class:"col-12 col-md-4"},a("form-control-date",{key:"1f739c1d3bb814710ee159740e459bde72a0e790",name:"dob_full",label:"Birth Date",defaultValue:null===(r=this.representativeDefaultValue)||void 0===r?void 0:r.dob_full,errorText:this.errors.dob_full,inputHandler:this.inputHandler,onFormControlInput:e=>c(e,this.formController),helpText:"Must be 18 or older."})),a("div",{key:"e2ecd87320422e1712138115291016f8c1c61ac2",class:"col-12 col-md-8"},a("form-control-number-masked",{key:"dd91ffa7877d84cfe315849d18c7cec5bf79b1de",name:"identification_number",label:"SSN",defaultValue:null===(f=this.representativeDefaultValue)||void 0===f?void 0:f.identification_number,errorText:this.errors.identification_number,inputHandler:this.inputHandler,mask:i,helpText:"Enter your full Social Security Number. It is required for Federal OFAC check."})),a("div",{key:"ef502c55424287c5c81ca88593f5836d21a2f945",class:"col-12"},a("justifi-identity-address-form",{key:"26295cbccf0ca23415b4d7c12dc42eb2dbb0d229",errors:this.errors.address,defaultValues:null===(n=this.representativeDefaultValue)||void 0===n?void 0:n.address,handleFormUpdate:this.onAddressFormUpdate})))))}};export{o as justifi_business_representative_form_inputs}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,h as r}from"./p-
|
|
1
|
+
import{r as t,h as r}from"./p-qipqIMyC.js";const s=class{constructor(r){t(this,r)}render(){return this.helpText?r("small",{class:"form-text text-muted",id:`form-help-text-${this.name}`},this.helpText):null}};export{s as form_control_help_text}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,c as s,h as e}from"./p-
|
|
1
|
+
import{r as t,c as s,h as e}from"./p-qipqIMyC.js";import"./p-Bp_QFeog.js";import"./p-HXpYMWUU.js";import"./p-Cjcsf8ku.js";import"./p-c4Mh3ZZ_.js";import{p as i}from"./p-CLHwhyvu.js";import"./p-BlJnA265.js";import"./p-BH0Xfn-F.js";import{T as a,a as r,b as h,c as o,d as c,e as n,f as p,g as d,h as f,i as b,j as m,k as u,l as g}from"./p-BZ7C9duj.js";import{T as y}from"./p-CZfYo5-1.js";import{t as j,a as l}from"./p-BdLLGV9t.js";import{o as k,g as C}from"./p-DvZcI6pC.js";import"./p-DsAwPf2y.js";import"./p-BHf9IqGw.js";import"./p-Dt-vy9Le.js";import"./p-BX8GieXu.js";import"./p-RvUQ__Pq.js";import"./p-xY5RkFuA.js";import"./p-D--yCspA.js";const v=class{constructor(e){t(this,e),this.clickEvent=s(this,"click-event"),this.errorEvent=s(this,"error-event"),this.terminals=[],this.subAccounts=[],this.loading=!0,this.paging=i,this.pagingParams={},this.handleClickPrevious=t=>{this.pagingParams={before_cursor:t},this.clickEvent.emit({name:y.previous})},this.handleClickNext=t=>{this.pagingParams={after_cursor:t},this.clickEvent.emit({name:y.next})},this.rowClickHandler=t=>{const s=t.target.closest("tr").dataset.rowEntityId;if(!s)return;const e=this.terminals.find((t=>t.id===s));this.clickEvent.emit({name:y.row,data:e})}}updateOnPropChange(){this.fetchData()}componentWillLoad(){this.terminalsTable=new a(this.terminals,this.columns,j,l),this.getTerminals&&this.getSubAccounts&&this.fetchData(),k("set",(()=>{this.pagingParams={}})),k("reset",(()=>{this.pagingParams={},this.errorMessage=""}))}fetchData(){this.loading=!0,this.getTerminals({params:this.terminalParams,onSuccess:async({terminals:t,pagingInfo:s})=>{this.terminals=t,this.paging=s,this.terminalsTable.collectionData=this.terminals,this.terminalsTable.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.terminals=this.terminals.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 terminalParams(){const t=C();return Object.assign(Object.assign({},t),this.pagingParams)}get subAccountParams(){let t=this.terminals.map((t=>t.account_id));return{sub_account_id:[...new Set(t)].join(",")}}get entityId(){return this.terminals.map((t=>t.id))}get showEmptyState(){return!this.loading&&!this.errorMessage&&this.terminalsTable.rowData.length<1}get showErrorState(){return!this.loading&&!!this.errorMessage}get showRowData(){return!this.showEmptyState&&!this.showErrorState&&!this.loading}render(){return e(g,{key:"27022f23dcede378c6a6d16bffb040aa6448f4be"},e(r,{key:"5d369cf93698adb50b843f65c747672abeb74cb4"},e(h,{key:"21173a74ccb82d7c3278157dae4ef3d471dbee5f"},e(o,{key:"43e425567500ff324fd6ed68647a9504df812bf6"},this.terminalsTable.columnData.map((t=>t)))),e(c,{key:"1151ee93144161308f8b27b0172acb32d2096d25"},e(n,{key:"353fb24dfbd941e8bba6f62799e0feea42d05c53",columnSpan:this.terminalsTable.columnKeys.length,isLoading:this.loading}),e(p,{key:"daa19b965b5519e766ba8bbb63cfc4327128bf22",isEmpty:this.showEmptyState,columnSpan:this.terminalsTable.columnKeys.length}),e(d,{key:"ee44061fa93cd20a59040a7b3faaeac10a925810",columnSpan:this.terminalsTable.columnKeys.length,errorMessage:this.errorMessage}),this.showRowData&&this.terminalsTable.rowData.map(((t,s)=>e(f,{"data-test-id":"table-row","data-row-entity-id":this.entityId[s],onClick:this.rowClickHandler},t)))),this.paging&&e(b,{key:"12cb09495ba8d416fd3593ccae4f205735226ecf"},e(m,{key:"da2e2695e6101193db9f67a0a76ce1ce8abdc646"},e(u,{key:"bffd81b4e90e668caa47813f96ab1a7764fa0f1b",colSpan:this.terminalsTable.columnData.length},e("pagination-menu",{key:"61c268da3402e0675f54515617a6bd2d58834e17",paging:Object.assign(Object.assign({},this.paging),{handleClickPrevious:this.handleClickPrevious,handleClickNext:this.handleClickNext})}))))))}static get watchers(){return{pagingParams:["updateOnPropChange"],getTerminals:["updateOnPropChange"],getSubAccounts:["updateOnPropChange"],columns:["updateOnPropChange"]}}};export{v as terminals_list_core}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{h as t,r as s,c as e}from"./p-
|
|
1
|
+
import{h as t,r as s,c as e}from"./p-qipqIMyC.js";import{c as r,a as i,F as o}from"./p-CR9D6mKt.js";import{f as n}from"./p-BHf9IqGw.js";import"./p-Bp_QFeog.js";import{C as a,a as u}from"./p-Cjcsf8ku.js";import{R as l,j as m}from"./p-c4Mh3ZZ_.js";import"./p-CLHwhyvu.js";import"./p-BlJnA265.js";import"./p-BH0Xfn-F.js";import{B as h}from"./p-D6XirF21.js";import{S as p}from"./p-CLQx9p9q.js";import"./p-CZfYo5-1.js";import{P as c}from"./p-CpKvg1ok.js";import{m as d}from"./p-CU4XQ3fO.js";import{c as f,J as v}from"./p-BB5-CJF-.js";import{g as j,a as y}from"./p-D2muobcE.js";import{A as b}from"./p-BUa0YOaw.js";import{S as w}from"./p-Xv8DuU3Y.js";import"./p-BFTU3MAI.js";import"./p-HXpYMWUU.js";import"./p-DsAwPf2y.js";import"./p-Dt-vy9Le.js";import"./p-BX8GieXu.js";import"./p-RvUQ__Pq.js";import"./p-pXjOPQhG.js";const C=t=>{const s=+t;return i().required("Amount is required").test("max-amount",`Refund amount cannot be more than payment amount: ${n(s)}`,(function(t){return+t<=+s})).test("min-amount","Refund amount must be greater than 0",(function(t){return+t>0}))},g=t=>{if(t)return r({amount:C(t),description:i().optional(),reason:i().optional().oneOf([l.customerRequest,l.duplicate,l.fraudulent],"Select a reason")})},B=[{label:"Select a reason",value:""},{label:"Customer requested a refund",value:"customer_request"},{label:"Customer was double-charged",value:"duplicate"},{label:"Payment was reported as fraud",value:"fraudulent"}],x=b();class A{async postRefund(t,s,e,r){return x.post({endpoint:`payments/${t}/refunds`,headers:{"Sub-Account":s},body:r,authToken:e})}}const R=()=>t("div",{class:"row gap-3"},t("div",{class:"col-12"},t(w,{width:"100%",height:"40px"}))),k=()=>t(p,null,t("div",{class:"row gap-5"},t(R,null),t(R,null),t(R,null))),q=class{constructor(t){s(this,t),this.errorEvent=e(this,"error-event"),this.submitEvent=e(this,"submit-event"),this.refundPayload={},this.displayAmount="",this.errors={},this.paymentLoading=!0,this.refundLoading=!1,this.hideSubmitButton=!1,this.inputHandler=(t,s)=>{this.formController.setValues(Object.assign(Object.assign({},this.formController.values.getValue()),{[t]:s}))}}componentWillLoad(){f(),this.analytics=new v(this),this.initializeApi(),this.formController=new o(g())}handleError(t,s,e){this.errorEvent.emit({errorCode:t,message:s,severity:e})}checkAmount(t){return t>0}handleInvalidAmount(){this.submitDisabled=!0,this.handleError(u.INVALID_REFUND_AMOUNT,"Refund amount must be greater than 0",a.ERROR)}initializeFormController(){const t=this.refundPayload.amount,s=t?t.toString():"0";this.formController=new o(g(s)),this.formController.setInitialValues({amount:s}),this.formController.values.subscribe((t=>{this.refundPayload=Object.assign({},t)})),this.formController.errors.subscribe((t=>{this.errors=Object.assign({},t)}))}initializeApi(){this.paymentId&&this.authToken?d({id:this.paymentId,authToken:this.authToken,service:new c})({onSuccess:({payment:t})=>{this.refundPayload=new m({amount:t.amount_refundable})},onError:({error:t,code:s,severity:e})=>{this.handleError(s,t,e)},final:()=>{this.checkAmount(this.refundPayload.amount)?this.initializeFormController():this.handleInvalidAmount(),this.paymentLoading=!1}}):this.handleError(u.MISSING_PROPS,"Payment ID and Auth Token are required",a.ERROR)}async refundPayment(t){if(t&&t.preventDefault(),!await this.formController.validate())return;const s=(({authToken:t,accountId:s,paymentId:e,service:r})=>async({refundBody:i,onSuccess:o,onError:n,final:u})=>{var l;try{const u=await r.postRefund(e,s,t,i);if(u.error)return n({error:y(u.error),code:j(null===(l=u.error)||void 0===l?void 0:l.code),severity:a.ERROR});o(u)}catch(t){const s=j(null==t?void 0:t.code);return n({error:t.message||t,code:s,severity:a.ERROR})}finally{return u()}})({authToken:this.authToken,accountId:this.accountId,paymentId:this.paymentId,service:new A}),e=this.formController.values.getValue();return this.refundLoading=!0,new Promise((t=>{let r;s({refundBody:e,onSuccess:t=>{r=t},onError:({error:t,code:s,severity:e})=>{r=t,this.handleError(t,s,e)},final:()=>{this.submitEvent.emit({response:r}),this.submitDisabled=!0,this.refundLoading=!1,t(r.data)}})}))}render(){if(this.paymentLoading)return t(k,null);const s=this.formController.getInitialValues(),e=this.refundPayload.amount;return t(p,null,t("form",null,t("fieldset",null,t("div",{class:"row gy-3"},t("div",{class:"col-12"},t("form-control-monetary",{name:"amount",label:"Refund Amount",defaultValue:s.amount,inputHandler:this.inputHandler,errorText:this.errors.amount})),t("div",{class:"col-12"},t("form-control-select",{name:"reason",label:"Reason for refund (optional)",defaultValue:s.reason,inputHandler:this.inputHandler,options:B,errorText:this.errors.reason})),t("div",{class:"col-12"},t("form-control-textarea",{name:"description",label:"Note (optional)",defaultValue:s.description,inputHandler:this.inputHandler,maxLength:250,errorText:this.errors.description})),t("div",{class:"form-group d-flex flex-row-reverse"},t(h,{variant:"primary",type:"submit",onClick:this.refundPayment.bind(this),isLoading:this.paymentLoading||this.refundLoading,hidden:this.hideSubmitButton,disabled:this.submitDisabled},`Refund ${n(+e)}`))))))}};export{q as justifi_refund_payment}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as s,c as t,h as r}from"./p-
|
|
1
|
+
import{r as s,c as t,h as r}from"./p-qipqIMyC.js";import{P as i}from"./p-CpKvg1ok.js";import"./p-Bp_QFeog.js";import"./p-HXpYMWUU.js";import{C as o,a as e}from"./p-Cjcsf8ku.js";import{P as p}from"./p-c4Mh3ZZ_.js";import"./p-CLHwhyvu.js";import"./p-BlJnA265.js";import"./p-BH0Xfn-F.js";import{g as a,a as n}from"./p-D2muobcE.js";import{c as m,J as c}from"./p-BB5-CJF-.js";import{S as h}from"./p-CLQx9p9q.js";import"./p-CZfYo5-1.js";import{d}from"./p-CPVN4dXS.js";import"./p-BUa0YOaw.js";import"./p-BHf9IqGw.js";import"./p-DsAwPf2y.js";import"./p-Dt-vy9Le.js";import"./p-BX8GieXu.js";import"./p-pXjOPQhG.js";import"./p-C_3N7nqh.js";import"./p-D--yCspA.js";import"./p-RvUQ__Pq.js";const j=class{constructor(r){s(this,r),this.errorEvent=t(this,"error-event"),this.errorMessage=null,this.columns=d,this.handleErrorEvent=s=>{this.errorMessage=s.detail.message,this.errorEvent.emit(s.detail)}}componentWillLoad(){m(),this.analytics=new c(this),this.initializeGetPayments()}disconnectedCallback(){var s;null===(s=this.analytics)||void 0===s||s.cleanup()}propChanged(){this.initializeGetPayments()}initializeGetPayments(){this.accountId&&this.authToken?this.getPayments=(({id:s,authToken:t,service:r})=>async({params:i,onSuccess:e,onError:m,final:c})=>{var h,d;try{const c=await r.fetchPayments(s,t,i);if(c.error)return m({error:n(c.error),code:a(null===(d=c.error)||void 0===d?void 0:d.code),severity:o.ERROR});{const s=Object.assign({},c.page_info);e({payments:(null===(h=c.data)||void 0===h?void 0:h.map((s=>new p(s))))||[],pagingInfo:s})}}catch(s){const t=a(null==s?void 0:s.code);return m({error:s.message||s,code:t,severity:o.ERROR})}finally{return c()}})({id:this.accountId,authToken:this.authToken,service:new i}):(this.errorMessage="Account ID and Auth Token are required",this.errorEvent.emit({errorCode:e.MISSING_PROPS,message:this.errorMessage,severity:o.ERROR}))}render(){return r(h,{key:"4cdd2e9a318226408d47198bf2de40a750a71d01"},r("payments-list-core",{key:"87964c5dd33fd3b716964227cd990539d5d13fc4",getPayments:this.getPayments,"onError-event":this.handleErrorEvent,columns:this.columns}))}static get watchers(){return{accountId:["propChanged"],authToken:["propChanged"]}}};export{j as justifi_payments_list}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as s,c as t,h as r}from"./p-qipqIMyC.js";import{A as o}from"./p-BUa0YOaw.js";import{C as i,a as e}from"./p-Cjcsf8ku.js";import"./p-c4Mh3ZZ_.js";import"./p-CLHwhyvu.js";import"./p-BlJnA265.js";import"./p-BH0Xfn-F.js";import{g as p,a}from"./p-D2muobcE.js";import{E as n}from"./p-BIPdn2VU.js";import{c as h,J as c}from"./p-BB5-CJF-.js";import"./p-Bp_QFeog.js";import"./p-DsAwPf2y.js";import"./p-BHf9IqGw.js";import"./p-HXpYMWUU.js";import"./p-Dt-vy9Le.js";import"./p-BX8GieXu.js";import"./p-RvUQ__Pq.js";import"./p-pXjOPQhG.js";const m=o();class u{async fetchGrossVolumeChartData(s,t){return m.get({endpoint:`account/${s}/reports/gross_volume`,authToken:t})}}const d=class{constructor(r){s(this,r),this.errorEvent=t(this,"error-event"),this.errorMessage=null,this.handleErrorEvent=s=>{this.errorMessage=s.detail.message,this.errorEvent.emit(s.detail)}}componentWillLoad(){h(),this.analytics=new c(this),this.initializeGetGrossPayment()}disconnectedCallback(){var s;null===(s=this.analytics)||void 0===s||s.cleanup()}propChanged(){this.initializeGetGrossPayment()}initializeGetGrossPayment(){this.accountId&&this.authToken?this.getGrossPayment=(({id:s,authToken:t,service:r})=>async({onSuccess:o,onError:e})=>{var n;try{const h=await r.fetchGrossVolumeChartData(s,t);h.error?e({error:a(h.error),code:p(null===(n=h.error)||void 0===n?void 0:n.code),severity:i.ERROR}):o(h.data)}catch(s){const t=p(null==s?void 0:s.code);e({error:a(s),code:t,severity:i.ERROR})}})({id:this.accountId,authToken:this.authToken,service:new u}):(this.errorMessage="Account ID and Auth Token are required",this.errorEvent.emit({errorCode:e.MISSING_PROPS,message:this.errorMessage,severity:i.ERROR}))}render(){return this.errorMessage?n(this.errorMessage):r("gross-payment-chart-core",{getGrossPayment:this.getGrossPayment,"onError-event":this.handleErrorEvent})}static get watchers(){return{accountId:["propChanged"],authToken:["propChanged"]}}};export{d as justifi_gross_payment_chart}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e,h as a}from"./p-
|
|
1
|
+
import{r as e,h as a}from"./p-qipqIMyC.js";import{l as t}from"./p-Bde7dY9t.js";import{f as s,p as i,c as r}from"./p-DvZcI6pC.js";import{P as l,Q as p,R as o,S as f}from"./p-RvUQ__Pq.js";import{S as c}from"./p-CLQx9p9q.js";import"./p-CZfYo5-1.js";import"./p-Bp_QFeog.js";import"./p-HXpYMWUU.js";import"./p-Cjcsf8ku.js";import{c as d}from"./p-c4Mh3ZZ_.js";import"./p-CLHwhyvu.js";import"./p-BlJnA265.js";import"./p-BH0Xfn-F.js";import"./p-BFTU3MAI.js";import"./p-DsAwPf2y.js";import"./p-BHf9IqGw.js";import"./p-Dt-vy9Le.js";import"./p-BX8GieXu.js";const n=class{constructor(a){e(this,a),this.setParamsOnChange=(e,a)=>{s[e]=a}}componentWillLoad(){this.debouncedSetParamsOnChange=t.debounce(this.setParamsOnChange,300),Object.entries({terminal_id:this.terminalId,status:this.terminalStatus,terminal_order_id:this.terminalOrderId}).forEach((([e,a])=>{a&&(i[e]=a)}))}get terminalStatusOptions(){return[{label:"All",value:""},{label:"Connected",value:d.connected},{label:"Disconnected",value:d.disconnected},{label:"Unknown",value:d.unknown},{label:"Pending Configuration",value:d.pending_configuration}]}render(){const e=Object.assign({},s);return a(c,{key:"5e6f1e8abcc7cffc26c101160bff40ff5092ff90"},a("table-filters-menu",{key:"6a57cb7deeb0c6927ee557402ef2618a3d3d8a29",params:e,clearParams:r,part:l},a("div",{key:"aaa63156c9603aafbe1b9dd4d4f87670b4e0ab66",class:"grid-cols-2 gap-3 p-1"},a("div",{key:"f76ca827834a98595a98d6bb6f982807506fe240",class:"p-2"},a("form-control-text",{key:"f9acf97e42e3e5f5ee216a10e116ab1aff2e6390",name:"terminal_id",label:"Terminal ID",inputHandler:this.debouncedSetParamsOnChange,defaultValue:this.terminalId||s.terminal_id,disabled:!!this.terminalId,part:p})),a("div",{key:"c4ac977f7433193e7a9c52be483c65cb5f96f214",class:"p-2"},a("form-control-text",{key:"035fc59523056240eea5da7b63d75028278d3102",name:"terminal_order_id",label:"Terminal Order ID",inputHandler:this.debouncedSetParamsOnChange,defaultValue:this.terminalOrderId||s.terminal_order_id,disabled:!!this.terminalOrderId,part:o})),a("div",{key:"ab72f5ef8a0191b1726cd84c36a7cca28a78ecf0",class:"p-2"},a("form-control-select",{key:"4a684c87e04e11f55c59d45a281f7c258fae4f0d",name:"status",label:"Status",options:this.terminalStatusOptions,inputHandler:this.setParamsOnChange,defaultValue:this.terminalStatus||s.status,disabled:!!this.terminalStatus,part:f})))))}};export{n as justifi_terminals_list_filters}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e,c as t,h as s}from"./p-CHdklybh.js";import{f as i}from"./p-BHf9IqGw.js";import{z as a,ai as r}from"./p-RvUQ__Pq.js";import{B as d}from"./p-BB-9jeDZ.js";import{S as c}from"./p-CXEvc-gI.js";import{S as o}from"./p-CVm_PxHa.js";import"./p-CZfYo5-1.js";import{C as n,a as h}from"./p-Cjcsf8ku.js";import{g as p,a as f}from"./p-D2muobcE.js";import{D as l}from"./p-DWMITBje.js";import{D as u}from"./p-Bg2SZArf.js";import{c as b,J as y}from"./p-ZWhv_80v.js";import"./p-HXpYMWUU.js";import"./p-Dph3Ao9s.js";import"./p-BuWHmUFx.js";import"./p-DwBh6VCY.js";import"./p-c4Mh3ZZ_.js";import"./p-BH0Xfn-F.js";import"./p-CLHwhyvu.js";import"./p-BlJnA265.js";import"./p-Dt-vy9Le.js";import"./p-BX8GieXu.js";import"./p-C5FfYVaH.js";const m=({authToken:e,disputeId:t,service:s})=>async({payload:i,onSuccess:a,onError:r,final:d=()=>{}})=>{var c;try{const d=await s.submitDisputeResponse(t,e,i);if(d.error){return r({error:f(d.error),code:p(null===(c=d.error)||void 0===c?void 0:c.code),severity:n.ERROR})}a(d)}catch(e){const t=p(null==e?void 0:e.code);return r({error:e.message||e,code:t,severity:n.ERROR})}finally{return d()}},v=class{constructor(s){e(this,s),this.clickEvent=t(this,"click-event"),this.errorEvent=t(this,"error-event"),this.submitEvent=t(this,"submit-event")}acceptDispute(){m({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(c,{key:"0f1028825a7a96a06e7219518ffed54bc0db1b2b"},this.isLoading&&s("div",{key:"f4b704182a5a7085827854634d38c56423cc2e1b",style:{marginBottom:"8px"}},s(o,{key:"b2062d8b683ab110c26fc30f1600c4500f668d87",height:"28px",width:"70%",styles:{marginBottom:"16px"}}),s(o,{key:"b5d2afe1fdd2e5ee0ec60048a48778bcfa6c78d3",height:"18px",styles:{marginBottom:"8px"}}),s(o,{key:"1e87c8936b3f2e26e680786927c5a4609aca0b83",height:"18px",styles:{marginBottom:"8px"}})),(null===(e=this.dispute)||void 0===e?void 0:e.needsResponse)&&s("div",{key:"49090493e3921353b7a830397795496bb234d112",part:a},s("h1",{key:"fd7b56a7cfeaa6820bf2cc121575314d075b5a83",class:"h4",part:r},"This payment is disputed"),s("p",{key:"72ba296695928baca8f7c5c3b1f858c596efedb2"},"The cardholder is disputing this payment. You may accept this dispute, or proceed to provide evidence in a counter dispute."),s("h2",{key:"cce733ff1bbca7a9530a442035cbae2995e018e7",class:"h5"},"Dispute details"),s("div",{key:"28b7f081e345112d99c52d05f205734995617253",class:"d-table gap-2"},s("div",{key:"d9476d8d0adfa3c6eccad229e94cd3824a720c7d",class:"d-table-row gap-2"},s("span",{key:"4d9e0714eee778c326ee1d70a32f79d90d3d4b09",part:"detail-section-item-title",class:"fw-bold d-table-cell pe-4"},"Amount"),s("span",{key:"b227edcf9b4b65b790d8aa98021d2662a12855bc",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:"b1b1cdaac5482f565a6f26af71c0b526b8c19f4e",class:"d-table-row gap-2"},s("span",{key:"0a479a9de96cce6e42bec90a17affe2c93ced44f",part:"detail-section-item-title",class:"fw-bold d-table-cell pe-4"},"Reason"),s("span",{key:"5d5020dda571f4465e2a358880ad5f20bc6171ea",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:"a5f42c3fcbb5d14f8479d0a576d31a50f8fc6441",class:"d-table-row gap-2"},s("span",{key:"280fca5a101eb0e823eb9ccc13c746ac7ed62069",part:"detail-section-item-title",class:"fw-bold d-table-cell pe-4"},"Dispute ID"),s("span",{key:"4dfc0b9a295ffc804b708d3590358256009e5376",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:"654e7baccd08628bc90d050bad108011b49f9972",class:"d-flex gap-2 mt-4 justify-content-end"},s(d,{key:"d0817cdb23bf33086c6ce5122f4ed5388027d96c",variant:"secondary",onClick:()=>this.acceptDispute()},"Accept dispute"),s(d,{key:"5446bef44a0ca747692d59fd5490409d00a9e285",variant:"primary",onClick:()=>this.initiateRespondToDispute()},"Counter dispute"))),(null===(p=this.dispute)||void 0===p?void 0:p.underReview)&&s("div",{key:"17fbc5902badc4230c5485b326f480180c844768"},s("h1",{key:"fefa0234306588d9e7f56733872bf8c9793f51dd",class:"h4"},"This payment is disputed and under review"),s("p",{key:"eaad72aa8d9f65ca296379a2800180878ec8a7e5"},"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:"ec1b0d728a7518f913c2a69976fa1f5fc8f76c74"},s("h1",{key:"9d42fad15fbeee507e2f364c3a35f143ff7599e2",class:"h4"},"This payment was disputed"),s("p",{key:"3b728a5544fe17a6c58c12f7e8eef290022945b6"},"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:"6d1813508a657265546fbef00bd1e8f46ffaf740"},s("h1",{key:"de981fc2e06e860f47146647975965a903a39b55",class:"h4"},"This payment was disputed"),s("p",{key:"4e57ab86518bd678a3a5402b712d40d573b3a970"},"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"),this.errorMessage=null,this.apiOrigin="https://wc-proxy.justifi.ai",this.handleErrorEvent=e=>{this.errorMessage=e.detail.message,this.errorEvent.emit(e.detail)}}componentWillLoad(){b(),this.analytics=new y(this),this.initializeDisputeServiceMethods()}disconnectedCallback(){var e;null===(e=this.analytics)||void 0===e||e.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 c;try{const d=await s.updateDisputeResponse(t,e,i);if(d.error)return r({error:f(d.error),code:p(null===(c=d.error)||void 0===c?void 0:c.code),severity:n.ERROR});a(d)}catch(e){const t=p(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 c;try{const d=await s.createDisputeEvidence(t,e,i);if(d.error)return r({error:f(d.error),code:p(null===(c=d.error)||void 0===c?void 0:c.code),severity:n.ERROR});a(d)}catch(e){const t=p(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=m({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(c,{key:"dbdfd59a21c7e8ea4dfdaecb91f885f82540a27c"},s("justifi-dispute-response-core",{key:"3cff38e5995f0033c45c54fa195ffeebc27e189e","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"),this.errorEvent=t(this,"error-event"),this.stepCompleteEvent=t(this,"complete-form-step-event"),this.submitEvent=t(this,"submit-event"),this.disputeResponse={},this.isLoading=!1,this.documentList=[],this.documentErrors={},this.currentStep=0,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)}))}}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:"20d075178a9d88cd73be32e52f8df6d3d360f8d7",class:"row gy-3"},s("div",{key:"6c1bc735f1a15709c596b5bea7cc3ce50e9a73f5",class:"col-12"},s("h1",{key:"27a0804924937ee7a8d01265bd0da2d9dd31d301",class:"h4",part:r},"Counter dispute")),s("div",{key:"b60822e91425c5c4af003169f47fd725daf9fb0f",class:"col-12"},this.currentStepComponent),s("div",{key:"d1be3f6be53de37836275067070cf4b5a2eb3e4a",class:"col-12"},s("div",{key:"48c8725d8de8b658e59ccfa851a6af6638e19ca5",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{v as justifi_dispute_notification,k as justifi_dispute_response,j as justifi_dispute_response_core}
|
|
1
|
+
import{r as e,c as t,h as s}from"./p-qipqIMyC.js";import{f as i}from"./p-BHf9IqGw.js";import{z as a,ai as r}from"./p-RvUQ__Pq.js";import{B as d}from"./p-D6XirF21.js";import{S as c}from"./p-CLQx9p9q.js";import{S as o}from"./p-Xv8DuU3Y.js";import"./p-CZfYo5-1.js";import{C as n,a as h}from"./p-Cjcsf8ku.js";import{g as p,a as f}from"./p-D2muobcE.js";import{D as l}from"./p-DyOgQlh2.js";import{D as u}from"./p-Bg2SZArf.js";import{c as y,J as b}from"./p-BB5-CJF-.js";import"./p-HXpYMWUU.js";import"./p-BUa0YOaw.js";import"./p-Bp_QFeog.js";import"./p-DsAwPf2y.js";import"./p-c4Mh3ZZ_.js";import"./p-BH0Xfn-F.js";import"./p-CLHwhyvu.js";import"./p-BlJnA265.js";import"./p-Dt-vy9Le.js";import"./p-BX8GieXu.js";import"./p-pXjOPQhG.js";const m=({authToken:e,disputeId:t,service:s})=>async({payload:i,onSuccess:a,onError:r,final:d=()=>{}})=>{var c;try{const d=await s.submitDisputeResponse(t,e,i);if(d.error){return r({error:f(d.error),code:p(null===(c=d.error)||void 0===c?void 0:c.code),severity:n.ERROR})}a(d)}catch(e){const t=p(null==e?void 0:e.code);return r({error:e.message||e,code:t,severity:n.ERROR})}finally{return d()}},v=class{constructor(s){e(this,s),this.clickEvent=t(this,"click-event"),this.errorEvent=t(this,"error-event"),this.submitEvent=t(this,"submit-event")}acceptDispute(){m({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(c,{key:"0f1028825a7a96a06e7219518ffed54bc0db1b2b"},this.isLoading&&s("div",{key:"f4b704182a5a7085827854634d38c56423cc2e1b",style:{marginBottom:"8px"}},s(o,{key:"b2062d8b683ab110c26fc30f1600c4500f668d87",height:"28px",width:"70%",styles:{marginBottom:"16px"}}),s(o,{key:"b5d2afe1fdd2e5ee0ec60048a48778bcfa6c78d3",height:"18px",styles:{marginBottom:"8px"}}),s(o,{key:"1e87c8936b3f2e26e680786927c5a4609aca0b83",height:"18px",styles:{marginBottom:"8px"}})),(null===(e=this.dispute)||void 0===e?void 0:e.needsResponse)&&s("div",{key:"49090493e3921353b7a830397795496bb234d112",part:a},s("h1",{key:"fd7b56a7cfeaa6820bf2cc121575314d075b5a83",class:"h4",part:r},"This payment is disputed"),s("p",{key:"72ba296695928baca8f7c5c3b1f858c596efedb2"},"The cardholder is disputing this payment. You may accept this dispute, or proceed to provide evidence in a counter dispute."),s("h2",{key:"cce733ff1bbca7a9530a442035cbae2995e018e7",class:"h5"},"Dispute details"),s("div",{key:"28b7f081e345112d99c52d05f205734995617253",class:"d-table gap-2"},s("div",{key:"d9476d8d0adfa3c6eccad229e94cd3824a720c7d",class:"d-table-row gap-2"},s("span",{key:"4d9e0714eee778c326ee1d70a32f79d90d3d4b09",part:"detail-section-item-title",class:"fw-bold d-table-cell pe-4"},"Amount"),s("span",{key:"b227edcf9b4b65b790d8aa98021d2662a12855bc",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:"b1b1cdaac5482f565a6f26af71c0b526b8c19f4e",class:"d-table-row gap-2"},s("span",{key:"0a479a9de96cce6e42bec90a17affe2c93ced44f",part:"detail-section-item-title",class:"fw-bold d-table-cell pe-4"},"Reason"),s("span",{key:"5d5020dda571f4465e2a358880ad5f20bc6171ea",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:"a5f42c3fcbb5d14f8479d0a576d31a50f8fc6441",class:"d-table-row gap-2"},s("span",{key:"280fca5a101eb0e823eb9ccc13c746ac7ed62069",part:"detail-section-item-title",class:"fw-bold d-table-cell pe-4"},"Dispute ID"),s("span",{key:"4dfc0b9a295ffc804b708d3590358256009e5376",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:"654e7baccd08628bc90d050bad108011b49f9972",class:"d-flex gap-2 mt-4 justify-content-end"},s(d,{key:"d0817cdb23bf33086c6ce5122f4ed5388027d96c",variant:"secondary",onClick:()=>this.acceptDispute()},"Accept dispute"),s(d,{key:"5446bef44a0ca747692d59fd5490409d00a9e285",variant:"primary",onClick:()=>this.initiateRespondToDispute()},"Counter dispute"))),(null===(p=this.dispute)||void 0===p?void 0:p.underReview)&&s("div",{key:"17fbc5902badc4230c5485b326f480180c844768"},s("h1",{key:"fefa0234306588d9e7f56733872bf8c9793f51dd",class:"h4"},"This payment is disputed and under review"),s("p",{key:"eaad72aa8d9f65ca296379a2800180878ec8a7e5"},"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:"ec1b0d728a7518f913c2a69976fa1f5fc8f76c74"},s("h1",{key:"9d42fad15fbeee507e2f364c3a35f143ff7599e2",class:"h4"},"This payment was disputed"),s("p",{key:"3b728a5544fe17a6c58c12f7e8eef290022945b6"},"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:"6d1813508a657265546fbef00bd1e8f46ffaf740"},s("h1",{key:"de981fc2e06e860f47146647975965a903a39b55",class:"h4"},"This payment was disputed"),s("p",{key:"4e57ab86518bd678a3a5402b712d40d573b3a970"},"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"),this.errorMessage=null,this.apiOrigin="https://wc-proxy.justifi.ai",this.handleErrorEvent=e=>{this.errorMessage=e.detail.message,this.errorEvent.emit(e.detail)}}componentWillLoad(){y(),this.analytics=new b(this),this.initializeDisputeServiceMethods()}disconnectedCallback(){var e;null===(e=this.analytics)||void 0===e||e.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 c;try{const d=await s.updateDisputeResponse(t,e,i);if(d.error)return r({error:f(d.error),code:p(null===(c=d.error)||void 0===c?void 0:c.code),severity:n.ERROR});a(d)}catch(e){const t=p(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 c;try{const d=await s.createDisputeEvidence(t,e,i);if(d.error)return r({error:f(d.error),code:p(null===(c=d.error)||void 0===c?void 0:c.code),severity:n.ERROR});a(d)}catch(e){const t=p(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=m({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(c,{key:"dbdfd59a21c7e8ea4dfdaecb91f885f82540a27c"},s("justifi-dispute-response-core",{key:"3cff38e5995f0033c45c54fa195ffeebc27e189e","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"),this.errorEvent=t(this,"error-event"),this.stepCompleteEvent=t(this,"complete-form-step-event"),this.submitEvent=t(this,"submit-event"),this.disputeResponse={},this.isLoading=!1,this.documentList=[],this.documentErrors={},this.currentStep=0,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)}))}}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:"20d075178a9d88cd73be32e52f8df6d3d360f8d7",class:"row gy-3"},s("div",{key:"6c1bc735f1a15709c596b5bea7cc3ce50e9a73f5",class:"col-12"},s("h1",{key:"27a0804924937ee7a8d01265bd0da2d9dd31d301",class:"h4",part:r},"Counter dispute")),s("div",{key:"b60822e91425c5c4af003169f47fd725daf9fb0f",class:"col-12"},this.currentStepComponent),s("div",{key:"d1be3f6be53de37836275067070cf4b5a2eb3e4a",class:"col-12"},s("div",{key:"48c8725d8de8b658e59ccfa851a6af6638e19ca5",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{v as justifi_dispute_notification,k as justifi_dispute_response,j as justifi_dispute_response_core}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{h as s,r as t,c as i}from"./p-qipqIMyC.js";import{A as e}from"./p-BUa0YOaw.js";import{C as r,a as o}from"./p-Cjcsf8ku.js";import"./p-c4Mh3ZZ_.js";import"./p-CLHwhyvu.js";import"./p-BlJnA265.js";import"./p-BH0Xfn-F.js";import{g as a,a as n}from"./p-D2muobcE.js";import{c,J as l}from"./p-BB5-CJF-.js";import{c as h}from"./p-CrQgyTRz.js";import{p,f as d,r as u,i as v}from"./p-BHf9IqGw.js";import{v as m,i as y,a as f,H as j}from"./p-Bvp7uul3.js";import{z as _,A as g}from"./p-RvUQ__Pq.js";import{S as w}from"./p-CLQx9p9q.js";import"./p-CZfYo5-1.js";import{S as C}from"./p-Xv8DuU3Y.js";import"./p-Bp_QFeog.js";import"./p-DsAwPf2y.js";import"./p-Dt-vy9Le.js";import"./p-BX8GieXu.js";import"./p-pXjOPQhG.js";import"./p-DCIW8z1f.js";import"./p-HXpYMWUU.js";const k=e();class b{async fetchQuote(s,t){return k.post({endpoint:"insurance/quotes",body:t,authToken:s})}async toggleCoverage(s,t,i){return k.post({endpoint:`insurance/quotes/${t}/toggle`,body:i,authToken:s})}}const q=()=>s("div",{class:"row gap-3"},s("div",{class:"col-12"},s(C,{width:"35%",height:"30px"})),s("div",{class:"col-12"},s(C,{width:"70%"})),s("div",{class:"col-12"},s(C,{width:"40%"})),s("div",{class:"col-12"},s(C,{width:"40%"})),s("div",{class:"col-12"},s(C,{width:"100%"})),s("div",{class:"col-12"},s(C,{width:"80%"}))),T=class{constructor(s){t(this,s),this.insuranceUpdated=i(this,"insurance-updated"),this.errorEvent=i(this,"error-event"),this.isLoading=!0}async validate(){return m()}processHTMLContent(s){return p(s,[s=>u(s,"style"),s=>v(s,"a","part",_),s=>v(s,"p","part",_)])}componentWillLoad(){c(),this.analytics=new l(this),this.initializeServiceMethods(),this.getQuote&&this.fetchData()}disconnectedCallback(){var s;null===(s=this.analytics)||void 0===s||s.cleanup()}initializeServiceMethods(){const s=this.authToken||h.authToken;if(!s)return void this.errorEvent.emit({errorCode:o.MISSING_PROPS,message:"Missing authToken",severity:r.ERROR});const t={authToken:s,service:new b};this.getQuote=(({authToken:s,service:t})=>async({payload:i,onSuccess:e,onError:o})=>{var c;try{const l=await t.fetchQuote(s,i);if(l.error)return o({error:n(l.error),code:a(null===(c=l.error)||void 0===c?void 0:c.code),severity:r.ERROR});e({quote:l.data})}catch(s){const t=a(null==s?void 0:s.code);return o({error:s.message||s,code:t,severity:r.ERROR})}})(t),this.toggleCoverage=(({authToken:s,service:t})=>async({quoteId:i,payload:e,onSuccess:o,onError:c})=>{var l;try{const h=await t.toggleCoverage(s,i,e);if(h.error)return c({error:n(h.error),code:a(null===(l=h.error)||void 0===l?void 0:l.code),severity:r.ERROR});o({quote:h.data})}catch(s){const t=a(null==s?void 0:s.code);return c({error:s.message||s,code:t,severity:r.ERROR})}})(t)}fetchData(){this.isLoading=!0,this.getQuote({payload:{checkout_id:this.checkoutId||h.checkoutId,policy_type:"season_interruption",primary_identity:{state:this.primaryIdentityState,email:this.primaryIdentityEmailAddress,first_name:this.primaryIdentityFirstName,last_name:this.primaryIdentityLastName,postal_code:this.primaryIdentityPostalCode,country:this.primaryIdentityCountry},policy_attributes:{insurable_amount:this.policyAttributesInsurableAmount,start_date:this.policyAttributesStartDate,end_date:this.policyAttributesEndDate,covered_identity:{first_name:this.coveredIdentityFirstName,last_name:this.coveredIdentityLastName}}},onSuccess:({quote:s})=>{this.quote=s,this.quote.product.description=this.processHTMLContent(this.quote.product.description),this.quote.product.legal_disclaimer=this.processHTMLContent(this.quote.product.legal_disclaimer),y[s.policy_type]=s.accepted,this.isLoading=!1},onError:({error:s,code:t,severity:i})=>{this.isLoading=!1,this.errorEvent.emit({errorCode:t,message:s,severity:i})}})}onChangeHandler(s,t){this.accepted=t,f[this.quote.policy_type]=!1,this.toggleCoverage({quoteId:this.quote.id,payload:{accepted:this.accepted},onSuccess:()=>{this.insuranceUpdated.emit(),y[this.quote.policy_type]=this.accepted},onError:({error:s,code:t,severity:i})=>{this.errorEvent.emit({errorCode:t,message:s,severity:i})}})}get error(){var s;return f[null===(s=this.quote)||void 0===s?void 0:s.policy_type]}render(){var t,i,e,r;return h&&!1===h.insuranceEnabled?(console.warn("[justifi-season-interruption-insurance] Insurance is disabled for this checkout (payment_settings.insurance_payments=false)."),null):s(w,null,this.isLoading?s(q,null):s("div",null,s(j,{text:null===(t=this.quote)||void 0===t?void 0:t.product.title,class:"fs-5 fw-bold pb-3"}),s("small",{part:_,innerHTML:null===(i=this.quote)||void 0===i?void 0:i.product.description}),s("form-control-radio",{label:`Accept coverage for ${d(null===(e=this.quote)||void 0===e?void 0:e.total_cents)}`,name:"opt-in",value:"true",checked:"true"===this.accepted,inputHandler:this.onChangeHandler.bind(this),errorText:this.error?" ":void 0}),s("form-control-radio",{label:"Decline coverage",name:"opt-in",value:"false",checked:"false"===this.accepted,inputHandler:this.onChangeHandler.bind(this),errorText:this.error?" ":void 0}),s("div",{class:"invalid-feedback",style:{display:this.error?"block":"none"},part:g},"Please select an option"),s("small",{part:_,innerHTML:null===(r=this.quote)||void 0===r?void 0:r.product.legal_disclaimer})))}};export{T as justifi_season_interruption_insurance}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as e,h as n,H as t,c as i,g as o}from"./p-CHdklybh.js";import{c as r}from"./p-DwBh6VCY.js";import{i as a,b as s,a as c,c as d,l as u}from"./p-RvUQ__Pq.js";import{g as f}from"./p-BFTU3MAI.js";import{F as l}from"./p-BDGiGASo.js";import{p as h}from"./p-C5FfYVaH.js";const m=r({focused:{boxShadow:"",border:""},focusedAndInvalid:{boxShadow:"",border:""},fontStyles:{fontFamily:"",fontSize:"",fontWeight:"",lineHeight:"",margin:"",padding:""}}),{state:w,set:b}=m,g=class{constructor(n){e(this,n),this.isFocused=!1,this.errorText=""}async componentDidLoad(){const e=await this.getBaseFontStyles();b("fontStyles",e);const n=await this.getFocusedStyles();b("focused",n);const t=await this.getFocusedAndInvalidStyles();b("focusedAndInvalid",t)}async getBaseFontStyles(){return new Promise((e=>{setTimeout((()=>{const n=getComputedStyle(this.hiddenInput);e({fontFamily:n.fontFamily,fontSize:n.fontSize,fontWeight:n.fontWeight,lineHeight:n.lineHeight,margin:n.margin,padding:n.padding,color:n.color})}),500)}))}async getFocusedStyles(){return new Promise((e=>{this.hiddenInput.focus(),setTimeout((()=>{this.hiddenInput.blur();let n=getComputedStyle(this.hiddenInput);e({boxShadow:n.boxShadow,border:n.border})}),500)}))}async getFocusedAndInvalidStyles(){return new Promise((e=>{this.hiddenInput.focus(),this.errorText="Error",setTimeout((()=>{const n=getComputedStyle(this.hiddenInput),t={boxShadow:n.boxShadow,border:n.border};this.hiddenInput.blur(),e(t)}),500)}))}get part(){return this.isFocused&&this.errorText?a:this.errorText?s:this.isFocused?c:d}render(){return n(t,{key:"bf8fcd89cdc8fcd1bfd8b9af5a7211c877e482ba"},n("input",{key:"f202d9252b60195b193a8203f750730fcf2e271b",ref:e=>this.hiddenInput=e,type:"text",class:this.errorText?"form-control is-invalid":"form-control",onFocus:()=>this.isFocused=!0,onBlur:()=>this.isFocused=!1,part:this.part,tabindex:"-1",style:{height:"0",opacity:"0",pointerEvents:"none",animation:"none"}}))}};var p,y,v={exports:{}},k=f((p||(p=1,y=v,console.info("\nIFRAME-RESIZER\n\nIframe-Resizer 5 is now available via the following two packages:\n\n * @iframe-resizer/parent\n * @iframe-resizer/child\n\nAdditionally their are also new versions of iframe-resizer for React, Vue, and jQuery.\n\nVersion 5 of iframe-resizer has been extensively rewritten to use modern browser APIs, which has enabled significantly better performance and greater accuracy in the detection of content resizing events.\n\nPlease see https://iframe-resizer.com/upgrade for more details.\n"),function(e){if("undefined"!=typeof window){var n,t,i=0,o=!1,r=!1,a="[iFrameSizer]",s=null,c=window.requestAnimationFrame,d=Object.freeze({max:1,scroll:1,bodyScroll:1,documentElementScroll:1}),u={},f=null,l=Object.freeze({autoResize:!0,bodyBackground:null,bodyMargin:null,bodyMarginV1:8,bodyPadding:null,checkOrigin:!0,inPageLinks:!1,enablePublicMethods:!0,heightCalculationMethod:"bodyOffset",id:"iFrameResizer",interval:32,license:"1jqr0si6pnt",log:!1,maxHeight:1/0,maxWidth:1/0,minHeight:0,minWidth:0,mouseEvents:!0,resizeFrom:"parent",scrolling:!1,sizeHeight:!0,sizeWidth:!1,warningTimeout:5e3,tolerance:0,widthCalculationMethod:"scroll",onClose:function(){return!0},onClosed:function(){},onInit:function(){},onMessage:function(){k("onMessage function not defined")},onMouseEnter:function(){},onMouseLeave:function(){},onResized:function(){},onScroll:function(){return!0}}),h={};window.jQuery!==e&&((t=window.jQuery).fn?t.fn.iFrameResize||(t.fn.iFrameResize=function(e){return this.filter("iframe").each((function(n,t){A(t,e)})).end()}):v("","Unable to bind to jQuery, it is not fully loaded.")),y.exports=P(),window.iFrameResize=window.iFrameResize||P()}function m(){return window.MutationObserver||window.WebKitMutationObserver||window.MozMutationObserver}function w(e,n,t){e.addEventListener(n,t,!1)}function b(e,n,t){e.removeEventListener(n,t,!1)}function g(e){return u[e]?u[e].log:o}function p(e,n){x("log",e,n,g(e))}function v(e,n){x("info",e,n,g(e))}function k(e,n){x("warn",e,n,!0)}function x(e,n,t,i){!0===i&&"object"==typeof window.console&&console[e](function(e){return a+"["+function(e){var n="Host page: "+e;return window.top!==window.self&&(n=window.parentIFrame&&window.parentIFrame.getId?window.parentIFrame.getId()+": "+e:"Nested host page: "+e),n}(e)+"]"}(n),t)}function F(e){function n(){t("Height"),t("Width"),C((function(){R(H),T(W),l("onResized",H)}),H,"init")}function t(e){var n=Number(u[W]["max"+e]),t=Number(u[W]["min"+e]),i=e.toLowerCase(),o=Number(H[i]);p(W,"Checking "+i+" is in range "+t+"-"+n),o<t&&(o=t,p(W,"Set "+i+" to min value")),o>n&&(o=n,p(W,"Set "+i+" to max value")),H[i]=""+o}function i(e){return A.slice(A.indexOf(":")+7+e)}function o(e,n){var t,i;t=function(){var t,i;E("Send Page Info","pageInfo:"+(t=document.body.getBoundingClientRect(),i=H.iframe.getBoundingClientRect(),JSON.stringify({iframeHeight:i.height,iframeWidth:i.width,clientHeight:Math.max(document.documentElement.clientHeight,window.innerHeight||0),clientWidth:Math.max(document.documentElement.clientWidth,window.innerWidth||0),offsetTop:parseInt(i.top-t.top,10),offsetLeft:parseInt(i.left-t.left,10),scrollTop:window.pageYOffset,scrollLeft:window.pageXOffset,documentHeight:document.documentElement.clientHeight,documentWidth:document.documentElement.clientWidth,windowHeight:window.innerHeight,windowWidth:window.innerWidth})),e,n)},h[i=n]||(h[i]=setTimeout((function(){h[i]=null,t()}),32))}function r(e){var n=e.getBoundingClientRect();return M(W),{x:Math.floor(Number(n.left)+Number(s.x)),y:Math.floor(Number(n.top)+Number(s.y))}}function c(e){var n=e?r(H.iframe):{x:0,y:0},t={x:Number(H.width)+n.x,y:Number(H.height)+n.y};p(W,"Reposition requested from iFrame (offset x:"+n.x+" y:"+n.y+")"),window.top===window.self?(s=t,d(),p(W,"--")):window.parentIFrame?window.parentIFrame["scrollTo"+(e?"Offset":"")](t.x,t.y):k(W,"Unable to scroll to requested position, window.parentIFrame not found")}function d(){!1===l("onScroll",s)?j():T(W)}function f(e){var n={};if(0===Number(H.width)&&0===Number(H.height)){var t=i(9).split(":");n={x:t[1],y:t[0]}}else n={x:H.width,y:H.height};l(e,{iframe:H.iframe,screenX:Number(n.x),screenY:Number(n.y),type:H.type})}function l(e,n){return I(W,e,n)}var m,g,y,x,F,z,A=e.data,H={},W=null;"[iFrameResizerChild]Ready"===A?function(){for(var e in u)E("iFrame requested init",N(e),u[e].iframe,e)}():a===(""+A).slice(0,13)&&A.slice(13).split(":")[0]in u?(x=(y=A.slice(13).split(":"))[1]?parseInt(y[1],10):0,F=u[y[0]]&&u[y[0]].iframe,z=getComputedStyle(F),H={iframe:F,id:y[0],height:x+function(e){return"border-box"!==e.boxSizing?0:(e.paddingTop?parseInt(e.paddingTop,10):0)+(e.paddingBottom?parseInt(e.paddingBottom,10):0)}(z)+function(e){return"border-box"!==e.boxSizing?0:(e.borderTopWidth?parseInt(e.borderTopWidth,10):0)+(e.borderBottomWidth?parseInt(e.borderBottomWidth,10):0)}(z),width:y[2],type:y[3]},u[W=H.id]&&(u[W].loaded=!0),(g=H.type in{true:1,false:1,undefined:1})&&p(W,"Ignoring init message from meta parent page"),!g&&function(e){var n=!0;return u[e]||(n=!1,k(H.type+" No settings for "+e+". Message was: "+A)),n}(W)&&(p(W,"Received: "+A),m=!0,null===H.iframe&&(k(W,"IFrame ("+H.id+") not found"),m=!1),m&&function(){var n,t=e.origin,i=u[W]&&u[W].checkOrigin;if(i&&""+t!="null"&&!(i.constructor===Array?function(){var e=0,n=!1;for(p(W,"Checking connection is from allowed list of origins: "+i);e<i.length;e++)if(i[e]===t){n=!0;break}return n}():(p(W,"Checking connection is from: "+(n=u[W]&&u[W].remoteHost)),t===n)))throw new Error("Unexpected message received from: "+t+" for "+H.iframe.id+". Message was: "+e.data+". This error can be disabled by setting the checkOrigin: false option or by providing of array of trusted domains.");return!0}()&&function(){switch(u[W]&&u[W].firstRun&&u[W]&&(u[W].firstRun=!1),H.type){case"close":S(H.iframe);break;case"message":m=i(6),p(W,"onMessage passed: {iframe: "+H.iframe.id+", message: "+m+"}"),l("onMessage",{iframe:H.iframe,message:JSON.parse(m)}),p(W,"--");break;case"mouseenter":f("onMouseEnter");break;case"mouseleave":f("onMouseLeave");break;case"autoResize":u[W].autoResize=JSON.parse(i(9));break;case"scrollTo":c(!1);break;case"scrollToOffset":c(!0);break;case"pageInfo":o(u[W]&&u[W].iframe,W),function(){function e(e,i){function r(){u[t]?o(u[t].iframe,t):n()}["scroll","resize"].forEach((function(n){p(t,e+n+" listener for sendPageInfo"),i(window,n,r)}))}function n(){e("Remove ",b)}var t=W;e("Add ",w),u[t]&&(u[t].stopPageInfo=n)}();break;case"pageInfoStop":u[W]&&u[W].stopPageInfo&&(u[W].stopPageInfo(),delete u[W].stopPageInfo);break;case"inPageLink":t=i(9).split("#")[1]||"",a=decodeURIComponent(t),(h=document.getElementById(a)||document.getElementsByName(a)[0])?(e=r(h),p(W,"Moving to in page link (#"+t+") at x: "+e.x+" y: "+e.y),s={x:e.x,y:e.y},d(),p(W,"--")):window.top===window.self?p(W,"In page link #"+t+" not found"):window.parentIFrame?window.parentIFrame.moveToAnchor(t):p(W,"In page link #"+t+" not found and window.parentIFrame not found");break;case"reset":O(H);break;case"init":n(),l("onInit",H.iframe);break;default:0===Number(H.width)&&0===Number(H.height)?k("Unsupported message received ("+H.type+"), this is likely due to the iframe containing a later version of iframe-resizer than the parent page"):n()}var e,t,a,h,m}())):v(W,"Ignored: "+A)}function I(e,n,t){var i=null,o=null;if(u[e]){if("function"!=typeof(i=u[e][n]))throw new TypeError(n+" on iFrame["+e+"] is not a function");o=i(t)}return o}function z(e){delete u[e.id]}function S(e){var t=e.id;if(!1!==I(t,"onClose",t)){p(t,"Removing iFrame: "+t);try{e.parentNode&&e.parentNode.removeChild(e)}catch(e){k(e)}I(t,"onClosed",t),p(t,"--"),z(e),n&&(n.disconnect(),n=null)}else p(t,"Close iframe cancelled by onClose event")}function M(n){null===s&&p(n,"Get page position: "+(s={x:window.pageXOffset===e?document.documentElement.scrollLeft:window.pageXOffset,y:window.pageYOffset===e?document.documentElement.scrollTop:window.pageYOffset}).x+","+s.y)}function T(e){null!==s&&(window.scrollTo(s.x,s.y),p(e,"Set page position: "+s.x+","+s.y),j())}function j(){s=null}function O(e){p(e.id,"Size reset requested by "+("init"===e.type?"host page":"iFrame")),M(e.id),C((function(){R(e),E("reset","reset",e.iframe,e.id)}),e,"reset")}function R(e){function n(n){r||"0"!==e[n]||(r=!0,p(i,"Hidden iFrame detected, creating visibility listener"),function(){function e(){Object.keys(u).forEach((function(e){!function(e){function n(n){return"0px"===(u[e]&&u[e].iframe.style[n])}u[e]&&null!==u[e].iframe.offsetParent&&(n("height")||n("width"))&&E("Visibility change","resize",u[e].iframe,e)}(e)}))}function n(n){p("window","Mutation observed: "+n[0].target+" "+n[0].type),H(e,16)}var t,i=m();i&&(t=document.querySelector("body"),new i(n).observe(t,{attributes:!0,attributeOldValue:!1,characterData:!0,characterDataOldValue:!1,childList:!0,subtree:!0}))}())}function t(t){!function(n){e.id?(e.iframe.style[n]=e[n]+"px",p(e.id,"IFrame ("+i+") "+n+" set to "+e[n]+"px")):p("undefined","messageData id not set")}(t),n(t)}var i=e.iframe.id;u[i]&&(u[i].sizeHeight&&t("height"),u[i].sizeWidth&&t("width"))}function C(e,n,t){t!==n.type&&c&&!window.jasmine?(p(n.id,"Requesting animation frame"),c(e)):e()}function E(e,n,t,i,o){var r,s=!1;u[i=i||t.id]&&(t&&"contentWindow"in t&&null!==t.contentWindow?(p(i,"["+e+"] Sending msg to iframe["+i+"] ("+n+") targetOrigin: "+(r=u[i]&&u[i].targetOrigin)),t.contentWindow.postMessage(a+n,r)):k(i,"["+e+"] IFrame("+i+") not found"),o&&u[i]&&u[i].warningTimeout&&(u[i].msgTimeout=setTimeout((function(){!u[i]||u[i].loaded||s||(s=!0,k(i,"IFrame has not responded within "+u[i].warningTimeout/1e3+" seconds. Check iFrameResizer.contentWindow.js has been loaded in iFrame. This message can be ignored if everything is working, or you can set the warningTimeout option to a higher value or zero to suppress this warning."))}),u[i].warningTimeout)))}function N(e){return e+":"+u[e].bodyMarginV1+":"+u[e].sizeWidth+":"+u[e].log+":"+u[e].interval+":"+u[e].enablePublicMethods+":"+u[e].autoResize+":"+u[e].bodyMargin+":"+u[e].heightCalculationMethod+":"+u[e].bodyBackground+":"+u[e].bodyPadding+":"+u[e].tolerance+":"+u[e].inPageLinks+":"+u[e].resizeFrom+":"+u[e].widthCalculationMethod+":"+u[e].mouseEvents}function A(t,r){function a(e){var n=e.split("Callback");if(2===n.length){var t="on"+n[0].charAt(0).toUpperCase()+n[0].slice(1);this[t]=this[e],delete this[e],k(f,"Deprecated: '"+e+"' has been renamed '"+t+"'. The old method will be removed in the next major version.")}}var s,c,f=function(e){if("string"!=typeof e)throw new TypeError("Invaild id for iFrame. Expected String");var n;return""===e&&(t.id=(n=r&&r.id||l.id+i++,null!==document.getElementById(n)&&(n+=i++),e=n),o=(r||{}).log,p(e,"Added missing iframe ID: "+e+" ("+t.src+")")),e}(t.id);f in u&&"iFrameResizer"in t?k(f,"Ignored iFrame, already setup."):(function(e){var n;e=e||{},u[f]=Object.create(null),u[f].iframe=t,u[f].firstRun=!0,u[f].remoteHost=t.src&&t.src.split("/").slice(0,3).join("/"),function(e){if("object"!=typeof e)throw new TypeError("Options is not an object")}(e),Object.keys(e).forEach(a,e),function(e){for(var n in l)Object.prototype.hasOwnProperty.call(l,n)&&(u[f][n]=Object.prototype.hasOwnProperty.call(e,n)?e[n]:l[n])}(e),u[f]&&(u[f].targetOrigin=!0===u[f].checkOrigin?""===(n=u[f].remoteHost)||null!==n.match(/^(about:blank|javascript:|file:\/\/)/)?"*":n:"*")}(r),function(){switch(p(f,"IFrame scrolling "+(u[f]&&u[f].scrolling?"enabled":"disabled")+" for "+f),t.style.overflow=!1===(u[f]&&u[f].scrolling)?"hidden":"auto",u[f]&&u[f].scrolling){case"omit":break;case!0:t.scrolling="yes";break;case!1:t.scrolling="no";break;default:t.scrolling=u[f]?u[f].scrolling:"no"}}(),function(){function e(e){var n=u[f][e];1/0!==n&&0!==n&&(t.style[e]="number"==typeof n?n+"px":n,p(f,"Set "+e+" = "+t.style[e]))}function n(e){if(u[f]["min"+e]>u[f]["max"+e])throw new Error("Value for min"+e+" can not be greater than max"+e)}n("Height"),n("Width"),e("maxHeight"),e("minHeight"),e("maxWidth"),e("minWidth")}(),"number"!=typeof(u[f]&&u[f].bodyMargin)&&"0"!==(u[f]&&u[f].bodyMargin)||(u[f].bodyMarginV1=u[f].bodyMargin,u[f].bodyMargin=u[f].bodyMargin+"px"),s=N(f),(c=m())&&(n=function(e){if(!t.parentNode)return null;var n=new e((function(e){e.forEach((function(e){Array.prototype.slice.call(e.removedNodes).forEach((function(e){e===t&&S(t)}))}))}));return n.observe(t.parentNode,{childList:!0}),n}(c)),w(t,"load",(function(){E("iFrame.onload",s,t,e,!0),(!u[f]||!u[f].firstRun)&&u[f]&&u[f].heightCalculationMethod in d&&O({iframe:t,height:0,width:0,type:"init"})})),E("init",s,t,e,!0),u[f]&&(u[f].iframe.iFrameResizer={close:S.bind(null,u[f].iframe),removeListeners:z.bind(null,u[f].iframe),resize:E.bind(null,"Window resize","resize",u[f].iframe),moveToAnchor:function(e){E("Move to anchor","moveToAnchor:"+e,u[f].iframe,f)},sendMessage:function(e){E("Send Message","message:"+(e=JSON.stringify(e)),u[f].iframe,f)}}))}function H(e,n){null===f&&(f=setTimeout((function(){f=null,e()}),n))}function W(){"hidden"!==document.visibilityState&&(p("document","Trigger event: Visibility change"),H((function(){L("Tab Visible","resize")}),16))}function L(e,n){Object.keys(u).forEach((function(t){(function(e){return u[e]&&"parent"===u[e].resizeFrom&&u[e].autoResize&&!u[e].firstRun})(t)&&E(e,n,u[t].iframe,t)}))}function P(){function n(e,n){n&&(function(){if(!n.tagName)throw new TypeError("Object is not a valid DOM element");if("IFRAME"!==n.tagName.toUpperCase())throw new TypeError("Expected <IFRAME> tag, found <"+n.tagName+">")}(),A(n,e),t.push(n))}var t;return function(){var e,n=["moz","webkit","o","ms"];for(e=0;e<n.length&&!c;e+=1)c=window[n[e]+"RequestAnimationFrame"];c?c=c.bind(window):p("setup","RequestAnimationFrame not supported")}(),w(window,"message",F),w(window,"resize",(function(){p("window","Trigger event: resize"),H((function(){L("Window resize","resize")}),16)})),w(document,"visibilitychange",W),w(document,"-webkit-visibilitychange",W),function(i,o){switch(t=[],function(e){e&&e.enablePublicMethods&&k("enablePublicMethods option has been removed, public methods are now always available in the iFrame")}(i),typeof o){case"undefined":case"string":Array.prototype.forEach.call(document.querySelectorAll(o||"iframe"),n.bind(e,i));break;case"object":n(i,o);break;default:throw new TypeError("Unexpected data type ("+typeof o+")")}return t}}}()),v.exports));class x{constructor(e,n){this.iframe=e,this.iframeOrigin=n}postMessage(e,n){const t=Object.assign({eventType:e},n);this.iframe.contentWindow.postMessage(t,this.iframeOrigin)}addMessageListener(e){window.addEventListener("message",e)}removeMessageListener(e){window.removeEventListener("message",e)}postMessageWithResponseListener(e,n){return new Promise((t=>{const i=n=>{n.data.eventType===e&&(window.removeEventListener("message",i),t(n.data.data))};window.addEventListener("message",i),this.postMessage(e,n)}))}}const F=class{constructor(n){e(this,n),this.iframeLoaded=i(this,"iframeLoaded"),this.isFocused=!1,this.isValid=!0,this.dispatchMessageEvent=e=>{const{eventType:n,data:t}=e.data;(null==t?void 0:t.id)===this.inputId&&("focused"===n&&(this.isFocused=!0),"blurred"===n&&(this.isFocused=!1))}}disconnectedCallback(){this.frameService.removeMessageListener(this.dispatchMessageEvent)}async validate(){const e=await this.frameService.postMessageWithResponseListener("validate");return this.isValid=e.isValid,this.errorText=e.error.message,e}async tokenize(e,n,t){return this.frameService.postMessageWithResponseListener("tokenize",{clientId:e,paymentMethodMetadata:n,account:t,componentVersion:h.version})}initializeFrameCommunicationService(){var e;this.frameService=new x(this.iframeElement,this.iframeOrigin),null===(e=this.frameService)||void 0===e||e.addMessageListener(this.dispatchMessageEvent)}get part(){return this.isFocused&&!this.isValid?a:this.isValid?this.isFocused?c:d:s}get style(){return this.isFocused?this.isValid?w.focused:w.focusedAndInvalid:null}get urlParams(){const e=Object.fromEntries(Object.entries(w.fontStyles).map((([e,n])=>[e,btoa(String(n))])));return new URLSearchParams(e).toString()}render(){return n(t,{key:"c8a36a456afdfd883ae2ad8e05de98d307615b4c",class:"form-group d-flex flex-column"},n("div",{key:"580cdd90dd76289f78b688fcdb1486ecb7fe6c5a",style:{visibility:this.iframeLoaded?"visible":"hidden",height:this.iframeLoaded?"auto":"0"}},n("label",{key:"7df8c29c720b5edf85553e5667c14eeb0ad6e2b6",class:"form-label",htmlFor:"",part:u},this.label||""),n("div",{key:"3caeb47ddf3940e1b1a7fe08d8bd50b8123eb2c5",class:"p-0 d-flex form-control "+(this.isValid?"":"is-invalid"),part:this.part,style:Object.assign(Object.assign({},this.style),{overflow:"hidden"})},n("iframe",{key:"2fdff0682753d32292431a8d62d30a1647fa62ef",id:this.inputId,name:this.inputId,src:`${this.iframeOrigin}?${this.urlParams}`,ref:e=>{this.iframeElement=e,this.initializeFrameCommunicationService()},width:"100%",onLoad:()=>{k({log:!1,onResized:()=>{this.iframeLoaded.emit()}},this.iframeElement)}})),n(l,{key:"075ca2ca25623703280fda84ff119e4820f9a5cb",errorText:this.errorText,name:this.inputId})))}get el(){return o(this)}};export{g as hidden_input,F as iframe_input}
|
|
1
|
+
import{r as e,h as n,H as t,c as i,g as o}from"./p-qipqIMyC.js";import{c as r}from"./p-DsAwPf2y.js";import{i as a,b as s,a as c,c as d,l as u}from"./p-RvUQ__Pq.js";import{g as f}from"./p-BFTU3MAI.js";import{F as l}from"./p-DCMrHeJI.js";import{p as h}from"./p-pXjOPQhG.js";const m=r({focused:{boxShadow:"",border:""},focusedAndInvalid:{boxShadow:"",border:""},fontStyles:{fontFamily:"",fontSize:"",fontWeight:"",lineHeight:"",margin:"",padding:""}}),{state:w,set:b}=m,g=class{constructor(n){e(this,n),this.isFocused=!1,this.errorText=""}async componentDidLoad(){const e=await this.getBaseFontStyles();b("fontStyles",e);const n=await this.getFocusedStyles();b("focused",n);const t=await this.getFocusedAndInvalidStyles();b("focusedAndInvalid",t)}async getBaseFontStyles(){return new Promise((e=>{setTimeout((()=>{const n=getComputedStyle(this.hiddenInput);e({fontFamily:n.fontFamily,fontSize:n.fontSize,fontWeight:n.fontWeight,lineHeight:n.lineHeight,margin:n.margin,padding:n.padding,color:n.color})}),500)}))}async getFocusedStyles(){return new Promise((e=>{this.hiddenInput.focus(),setTimeout((()=>{this.hiddenInput.blur();let n=getComputedStyle(this.hiddenInput);e({boxShadow:n.boxShadow,border:n.border})}),500)}))}async getFocusedAndInvalidStyles(){return new Promise((e=>{this.hiddenInput.focus(),this.errorText="Error",setTimeout((()=>{const n=getComputedStyle(this.hiddenInput),t={boxShadow:n.boxShadow,border:n.border};this.hiddenInput.blur(),e(t)}),500)}))}get part(){return this.isFocused&&this.errorText?a:this.errorText?s:this.isFocused?c:d}render(){return n(t,{key:"bf8fcd89cdc8fcd1bfd8b9af5a7211c877e482ba"},n("input",{key:"f202d9252b60195b193a8203f750730fcf2e271b",ref:e=>this.hiddenInput=e,type:"text",class:this.errorText?"form-control is-invalid":"form-control",onFocus:()=>this.isFocused=!0,onBlur:()=>this.isFocused=!1,part:this.part,tabindex:"-1",style:{height:"0",opacity:"0",pointerEvents:"none",animation:"none"}}))}};var p,y,v={exports:{}},k=f((p||(p=1,y=v,console.info("\nIFRAME-RESIZER\n\nIframe-Resizer 5 is now available via the following two packages:\n\n * @iframe-resizer/parent\n * @iframe-resizer/child\n\nAdditionally their are also new versions of iframe-resizer for React, Vue, and jQuery.\n\nVersion 5 of iframe-resizer has been extensively rewritten to use modern browser APIs, which has enabled significantly better performance and greater accuracy in the detection of content resizing events.\n\nPlease see https://iframe-resizer.com/upgrade for more details.\n"),function(e){if("undefined"!=typeof window){var n,t,i=0,o=!1,r=!1,a="[iFrameSizer]",s=null,c=window.requestAnimationFrame,d=Object.freeze({max:1,scroll:1,bodyScroll:1,documentElementScroll:1}),u={},f=null,l=Object.freeze({autoResize:!0,bodyBackground:null,bodyMargin:null,bodyMarginV1:8,bodyPadding:null,checkOrigin:!0,inPageLinks:!1,enablePublicMethods:!0,heightCalculationMethod:"bodyOffset",id:"iFrameResizer",interval:32,license:"1jqr0si6pnt",log:!1,maxHeight:1/0,maxWidth:1/0,minHeight:0,minWidth:0,mouseEvents:!0,resizeFrom:"parent",scrolling:!1,sizeHeight:!0,sizeWidth:!1,warningTimeout:5e3,tolerance:0,widthCalculationMethod:"scroll",onClose:function(){return!0},onClosed:function(){},onInit:function(){},onMessage:function(){k("onMessage function not defined")},onMouseEnter:function(){},onMouseLeave:function(){},onResized:function(){},onScroll:function(){return!0}}),h={};window.jQuery!==e&&((t=window.jQuery).fn?t.fn.iFrameResize||(t.fn.iFrameResize=function(e){return this.filter("iframe").each((function(n,t){A(t,e)})).end()}):v("","Unable to bind to jQuery, it is not fully loaded.")),y.exports=L(),window.iFrameResize=window.iFrameResize||L()}function m(){return window.MutationObserver||window.WebKitMutationObserver||window.MozMutationObserver}function w(e,n,t){e.addEventListener(n,t,!1)}function b(e,n,t){e.removeEventListener(n,t,!1)}function g(e){return u[e]?u[e].log:o}function p(e,n){x("log",e,n,g(e))}function v(e,n){x("info",e,n,g(e))}function k(e,n){x("warn",e,n,!0)}function x(e,n,t,i){!0===i&&"object"==typeof window.console&&console[e](function(e){return a+"["+function(e){var n="Host page: "+e;return window.top!==window.self&&(n=window.parentIFrame&&window.parentIFrame.getId?window.parentIFrame.getId()+": "+e:"Nested host page: "+e),n}(e)+"]"}(n),t)}function I(e){function n(){t("Height"),t("Width"),C((function(){R(P),j(W),l("onResized",P)}),P,"init")}function t(e){var n=Number(u[W]["max"+e]),t=Number(u[W]["min"+e]),i=e.toLowerCase(),o=Number(P[i]);p(W,"Checking "+i+" is in range "+t+"-"+n),o<t&&(o=t,p(W,"Set "+i+" to min value")),o>n&&(o=n,p(W,"Set "+i+" to max value")),P[i]=""+o}function i(e){return A.slice(A.indexOf(":")+7+e)}function o(e,n){var t,i;t=function(){var t,i;E("Send Page Info","pageInfo:"+(t=document.body.getBoundingClientRect(),i=P.iframe.getBoundingClientRect(),JSON.stringify({iframeHeight:i.height,iframeWidth:i.width,clientHeight:Math.max(document.documentElement.clientHeight,window.innerHeight||0),clientWidth:Math.max(document.documentElement.clientWidth,window.innerWidth||0),offsetTop:parseInt(i.top-t.top,10),offsetLeft:parseInt(i.left-t.left,10),scrollTop:window.pageYOffset,scrollLeft:window.pageXOffset,documentHeight:document.documentElement.clientHeight,documentWidth:document.documentElement.clientWidth,windowHeight:window.innerHeight,windowWidth:window.innerWidth})),e,n)},h[i=n]||(h[i]=setTimeout((function(){h[i]=null,t()}),32))}function r(e){var n=e.getBoundingClientRect();return S(W),{x:Math.floor(Number(n.left)+Number(s.x)),y:Math.floor(Number(n.top)+Number(s.y))}}function c(e){var n=e?r(P.iframe):{x:0,y:0},t={x:Number(P.width)+n.x,y:Number(P.height)+n.y};p(W,"Reposition requested from iFrame (offset x:"+n.x+" y:"+n.y+")"),window.top===window.self?(s=t,d(),p(W,"--")):window.parentIFrame?window.parentIFrame["scrollTo"+(e?"Offset":"")](t.x,t.y):k(W,"Unable to scroll to requested position, window.parentIFrame not found")}function d(){!1===l("onScroll",s)?T():j(W)}function f(e){var n={};if(0===Number(P.width)&&0===Number(P.height)){var t=i(9).split(":");n={x:t[1],y:t[0]}}else n={x:P.width,y:P.height};l(e,{iframe:P.iframe,screenX:Number(n.x),screenY:Number(n.y),type:P.type})}function l(e,n){return z(W,e,n)}var m,g,y,x,I,F,A=e.data,P={},W=null;"[iFrameResizerChild]Ready"===A?function(){for(var e in u)E("iFrame requested init",N(e),u[e].iframe,e)}():a===(""+A).slice(0,13)&&A.slice(13).split(":")[0]in u?(x=(y=A.slice(13).split(":"))[1]?parseInt(y[1],10):0,I=u[y[0]]&&u[y[0]].iframe,F=getComputedStyle(I),P={iframe:I,id:y[0],height:x+function(e){return"border-box"!==e.boxSizing?0:(e.paddingTop?parseInt(e.paddingTop,10):0)+(e.paddingBottom?parseInt(e.paddingBottom,10):0)}(F)+function(e){return"border-box"!==e.boxSizing?0:(e.borderTopWidth?parseInt(e.borderTopWidth,10):0)+(e.borderBottomWidth?parseInt(e.borderBottomWidth,10):0)}(F),width:y[2],type:y[3]},u[W=P.id]&&(u[W].loaded=!0),(g=P.type in{true:1,false:1,undefined:1})&&p(W,"Ignoring init message from meta parent page"),!g&&function(e){var n=!0;return u[e]||(n=!1,k(P.type+" No settings for "+e+". Message was: "+A)),n}(W)&&(p(W,"Received: "+A),m=!0,null===P.iframe&&(k(W,"IFrame ("+P.id+") not found"),m=!1),m&&function(){var n,t=e.origin,i=u[W]&&u[W].checkOrigin;if(i&&""+t!="null"&&!(i.constructor===Array?function(){var e=0,n=!1;for(p(W,"Checking connection is from allowed list of origins: "+i);e<i.length;e++)if(i[e]===t){n=!0;break}return n}():(p(W,"Checking connection is from: "+(n=u[W]&&u[W].remoteHost)),t===n)))throw new Error("Unexpected message received from: "+t+" for "+P.iframe.id+". Message was: "+e.data+". This error can be disabled by setting the checkOrigin: false option or by providing of array of trusted domains.");return!0}()&&function(){switch(u[W]&&u[W].firstRun&&u[W]&&(u[W].firstRun=!1),P.type){case"close":M(P.iframe);break;case"message":m=i(6),p(W,"onMessage passed: {iframe: "+P.iframe.id+", message: "+m+"}"),l("onMessage",{iframe:P.iframe,message:JSON.parse(m)}),p(W,"--");break;case"mouseenter":f("onMouseEnter");break;case"mouseleave":f("onMouseLeave");break;case"autoResize":u[W].autoResize=JSON.parse(i(9));break;case"scrollTo":c(!1);break;case"scrollToOffset":c(!0);break;case"pageInfo":o(u[W]&&u[W].iframe,W),function(){function e(e,i){function r(){u[t]?o(u[t].iframe,t):n()}["scroll","resize"].forEach((function(n){p(t,e+n+" listener for sendPageInfo"),i(window,n,r)}))}function n(){e("Remove ",b)}var t=W;e("Add ",w),u[t]&&(u[t].stopPageInfo=n)}();break;case"pageInfoStop":u[W]&&u[W].stopPageInfo&&(u[W].stopPageInfo(),delete u[W].stopPageInfo);break;case"inPageLink":t=i(9).split("#")[1]||"",a=decodeURIComponent(t),(h=document.getElementById(a)||document.getElementsByName(a)[0])?(e=r(h),p(W,"Moving to in page link (#"+t+") at x: "+e.x+" y: "+e.y),s={x:e.x,y:e.y},d(),p(W,"--")):window.top===window.self?p(W,"In page link #"+t+" not found"):window.parentIFrame?window.parentIFrame.moveToAnchor(t):p(W,"In page link #"+t+" not found and window.parentIFrame not found");break;case"reset":O(P);break;case"init":n(),l("onInit",P.iframe);break;default:0===Number(P.width)&&0===Number(P.height)?k("Unsupported message received ("+P.type+"), this is likely due to the iframe containing a later version of iframe-resizer than the parent page"):n()}var e,t,a,h,m}())):v(W,"Ignored: "+A)}function z(e,n,t){var i=null,o=null;if(u[e]){if("function"!=typeof(i=u[e][n]))throw new TypeError(n+" on iFrame["+e+"] is not a function");o=i(t)}return o}function F(e){delete u[e.id]}function M(e){var t=e.id;if(!1!==z(t,"onClose",t)){p(t,"Removing iFrame: "+t);try{e.parentNode&&e.parentNode.removeChild(e)}catch(e){k(e)}z(t,"onClosed",t),p(t,"--"),F(e),n&&(n.disconnect(),n=null)}else p(t,"Close iframe cancelled by onClose event")}function S(n){null===s&&p(n,"Get page position: "+(s={x:window.pageXOffset===e?document.documentElement.scrollLeft:window.pageXOffset,y:window.pageYOffset===e?document.documentElement.scrollTop:window.pageYOffset}).x+","+s.y)}function j(e){null!==s&&(window.scrollTo(s.x,s.y),p(e,"Set page position: "+s.x+","+s.y),T())}function T(){s=null}function O(e){p(e.id,"Size reset requested by "+("init"===e.type?"host page":"iFrame")),S(e.id),C((function(){R(e),E("reset","reset",e.iframe,e.id)}),e,"reset")}function R(e){function n(n){r||"0"!==e[n]||(r=!0,p(i,"Hidden iFrame detected, creating visibility listener"),function(){function e(){Object.keys(u).forEach((function(e){!function(e){function n(n){return"0px"===(u[e]&&u[e].iframe.style[n])}u[e]&&null!==u[e].iframe.offsetParent&&(n("height")||n("width"))&&E("Visibility change","resize",u[e].iframe,e)}(e)}))}function n(n){p("window","Mutation observed: "+n[0].target+" "+n[0].type),P(e,16)}var t,i=m();i&&(t=document.querySelector("body"),new i(n).observe(t,{attributes:!0,attributeOldValue:!1,characterData:!0,characterDataOldValue:!1,childList:!0,subtree:!0}))}())}function t(t){!function(n){e.id?(e.iframe.style[n]=e[n]+"px",p(e.id,"IFrame ("+i+") "+n+" set to "+e[n]+"px")):p("undefined","messageData id not set")}(t),n(t)}var i=e.iframe.id;u[i]&&(u[i].sizeHeight&&t("height"),u[i].sizeWidth&&t("width"))}function C(e,n,t){t!==n.type&&c&&!window.jasmine?(p(n.id,"Requesting animation frame"),c(e)):e()}function E(e,n,t,i,o){var r,s=!1;u[i=i||t.id]&&(t&&"contentWindow"in t&&null!==t.contentWindow?(p(i,"["+e+"] Sending msg to iframe["+i+"] ("+n+") targetOrigin: "+(r=u[i]&&u[i].targetOrigin)),t.contentWindow.postMessage(a+n,r)):k(i,"["+e+"] IFrame("+i+") not found"),o&&u[i]&&u[i].warningTimeout&&(u[i].msgTimeout=setTimeout((function(){!u[i]||u[i].loaded||s||(s=!0,k(i,"IFrame has not responded within "+u[i].warningTimeout/1e3+" seconds. Check iFrameResizer.contentWindow.js has been loaded in iFrame. This message can be ignored if everything is working, or you can set the warningTimeout option to a higher value or zero to suppress this warning."))}),u[i].warningTimeout)))}function N(e){return e+":"+u[e].bodyMarginV1+":"+u[e].sizeWidth+":"+u[e].log+":"+u[e].interval+":"+u[e].enablePublicMethods+":"+u[e].autoResize+":"+u[e].bodyMargin+":"+u[e].heightCalculationMethod+":"+u[e].bodyBackground+":"+u[e].bodyPadding+":"+u[e].tolerance+":"+u[e].inPageLinks+":"+u[e].resizeFrom+":"+u[e].widthCalculationMethod+":"+u[e].mouseEvents}function A(t,r){function a(e){var n=e.split("Callback");if(2===n.length){var t="on"+n[0].charAt(0).toUpperCase()+n[0].slice(1);this[t]=this[e],delete this[e],k(f,"Deprecated: '"+e+"' has been renamed '"+t+"'. The old method will be removed in the next major version.")}}var s,c,f=function(e){if("string"!=typeof e)throw new TypeError("Invaild id for iFrame. Expected String");var n;return""===e&&(t.id=(n=r&&r.id||l.id+i++,null!==document.getElementById(n)&&(n+=i++),e=n),o=(r||{}).log,p(e,"Added missing iframe ID: "+e+" ("+t.src+")")),e}(t.id);f in u&&"iFrameResizer"in t?k(f,"Ignored iFrame, already setup."):(function(e){var n;e=e||{},u[f]=Object.create(null),u[f].iframe=t,u[f].firstRun=!0,u[f].remoteHost=t.src&&t.src.split("/").slice(0,3).join("/"),function(e){if("object"!=typeof e)throw new TypeError("Options is not an object")}(e),Object.keys(e).forEach(a,e),function(e){for(var n in l)Object.prototype.hasOwnProperty.call(l,n)&&(u[f][n]=Object.prototype.hasOwnProperty.call(e,n)?e[n]:l[n])}(e),u[f]&&(u[f].targetOrigin=!0===u[f].checkOrigin?""===(n=u[f].remoteHost)||null!==n.match(/^(about:blank|javascript:|file:\/\/)/)?"*":n:"*")}(r),function(){switch(p(f,"IFrame scrolling "+(u[f]&&u[f].scrolling?"enabled":"disabled")+" for "+f),t.style.overflow=!1===(u[f]&&u[f].scrolling)?"hidden":"auto",u[f]&&u[f].scrolling){case"omit":break;case!0:t.scrolling="yes";break;case!1:t.scrolling="no";break;default:t.scrolling=u[f]?u[f].scrolling:"no"}}(),function(){function e(e){var n=u[f][e];1/0!==n&&0!==n&&(t.style[e]="number"==typeof n?n+"px":n,p(f,"Set "+e+" = "+t.style[e]))}function n(e){if(u[f]["min"+e]>u[f]["max"+e])throw new Error("Value for min"+e+" can not be greater than max"+e)}n("Height"),n("Width"),e("maxHeight"),e("minHeight"),e("maxWidth"),e("minWidth")}(),"number"!=typeof(u[f]&&u[f].bodyMargin)&&"0"!==(u[f]&&u[f].bodyMargin)||(u[f].bodyMarginV1=u[f].bodyMargin,u[f].bodyMargin=u[f].bodyMargin+"px"),s=N(f),(c=m())&&(n=function(e){if(!t.parentNode)return null;var n=new e((function(e){e.forEach((function(e){Array.prototype.slice.call(e.removedNodes).forEach((function(e){e===t&&M(t)}))}))}));return n.observe(t.parentNode,{childList:!0}),n}(c)),w(t,"load",(function(){E("iFrame.onload",s,t,e,!0),(!u[f]||!u[f].firstRun)&&u[f]&&u[f].heightCalculationMethod in d&&O({iframe:t,height:0,width:0,type:"init"})})),E("init",s,t,e,!0),u[f]&&(u[f].iframe.iFrameResizer={close:M.bind(null,u[f].iframe),removeListeners:F.bind(null,u[f].iframe),resize:E.bind(null,"Window resize","resize",u[f].iframe),moveToAnchor:function(e){E("Move to anchor","moveToAnchor:"+e,u[f].iframe,f)},sendMessage:function(e){E("Send Message","message:"+(e=JSON.stringify(e)),u[f].iframe,f)}}))}function P(e,n){null===f&&(f=setTimeout((function(){f=null,e()}),n))}function W(){"hidden"!==document.visibilityState&&(p("document","Trigger event: Visibility change"),P((function(){H("Tab Visible","resize")}),16))}function H(e,n){Object.keys(u).forEach((function(t){(function(e){return u[e]&&"parent"===u[e].resizeFrom&&u[e].autoResize&&!u[e].firstRun})(t)&&E(e,n,u[t].iframe,t)}))}function L(){function n(e,n){n&&(function(){if(!n.tagName)throw new TypeError("Object is not a valid DOM element");if("IFRAME"!==n.tagName.toUpperCase())throw new TypeError("Expected <IFRAME> tag, found <"+n.tagName+">")}(),A(n,e),t.push(n))}var t;return function(){var e,n=["moz","webkit","o","ms"];for(e=0;e<n.length&&!c;e+=1)c=window[n[e]+"RequestAnimationFrame"];c?c=c.bind(window):p("setup","RequestAnimationFrame not supported")}(),w(window,"message",I),w(window,"resize",(function(){p("window","Trigger event: resize"),P((function(){H("Window resize","resize")}),16)})),w(document,"visibilitychange",W),w(document,"-webkit-visibilitychange",W),function(i,o){switch(t=[],function(e){e&&e.enablePublicMethods&&k("enablePublicMethods option has been removed, public methods are now always available in the iFrame")}(i),typeof o){case"undefined":case"string":Array.prototype.forEach.call(document.querySelectorAll(o||"iframe"),n.bind(e,i));break;case"object":n(i,o);break;default:throw new TypeError("Unexpected data type ("+typeof o+")")}return t}}}()),v.exports));class x{constructor(e,n){this.iframe=e,this.iframeOrigin=n}postMessage(e,n){const t=Object.assign({eventType:e},n);this.iframe.contentWindow.postMessage(t,this.iframeOrigin)}addMessageListener(e){window.addEventListener("message",e)}removeMessageListener(e){window.removeEventListener("message",e)}postMessageWithResponseListener(e,n){return new Promise((t=>{const i=n=>{n.data.eventType===e&&(window.removeEventListener("message",i),t(n.data.data))};window.addEventListener("message",i),this.postMessage(e,n)}))}}const I=class{constructor(n){e(this,n),this.iframeLoaded=i(this,"iframeLoaded"),this.isFocused=!1,this.isValid=!0,this.dispatchMessageEvent=e=>{const{eventType:n,data:t}=e.data;(null==t?void 0:t.id)===this.inputId&&("focused"===n&&(this.isFocused=!0),"blurred"===n&&(this.isFocused=!1))}}disconnectedCallback(){this.frameService.removeMessageListener(this.dispatchMessageEvent)}async validate(){const e=await this.frameService.postMessageWithResponseListener("validate");return this.isValid=e.isValid,this.errorText=e.error.message,e}async tokenize(e,n,t){return this.frameService.postMessageWithResponseListener("tokenize",{clientId:e,paymentMethodMetadata:n,account:t,componentVersion:h.version})}initializeFrameCommunicationService(){var e;this.frameService=new x(this.iframeElement,this.iframeOrigin),null===(e=this.frameService)||void 0===e||e.addMessageListener(this.dispatchMessageEvent)}get part(){return this.isFocused&&!this.isValid?a:this.isValid?this.isFocused?c:d:s}get style(){return this.isFocused?this.isValid?w.focused:w.focusedAndInvalid:null}get urlParams(){const e=Object.fromEntries(Object.entries(w.fontStyles).map((([e,n])=>[e,btoa(String(n))])));return new URLSearchParams(e).toString()}render(){return n(t,{key:"c8a36a456afdfd883ae2ad8e05de98d307615b4c",class:"form-group d-flex flex-column"},n("div",{key:"580cdd90dd76289f78b688fcdb1486ecb7fe6c5a",style:{visibility:this.iframeLoaded?"visible":"hidden",height:this.iframeLoaded?"auto":"0"}},n("label",{key:"7df8c29c720b5edf85553e5667c14eeb0ad6e2b6",class:"form-label",htmlFor:"",part:u},this.label||""),n("div",{key:"3caeb47ddf3940e1b1a7fe08d8bd50b8123eb2c5",class:"p-0 d-flex form-control "+(this.isValid?"":"is-invalid"),part:this.part,style:Object.assign(Object.assign({},this.style),{overflow:"hidden"})},n("iframe",{key:"2fdff0682753d32292431a8d62d30a1647fa62ef",id:this.inputId,name:this.inputId,src:`${this.iframeOrigin}?${this.urlParams}`,ref:e=>{this.iframeElement=e,this.initializeFrameCommunicationService()},width:"100%",onLoad:()=>{k({log:!1,onResized:()=>{this.iframeLoaded.emit()}},this.iframeElement)}})),n(l,{key:"075ca2ca25623703280fda84ff119e4820f9a5cb",errorText:this.errorText,name:this.inputId})))}get el(){return o(this)}};export{g as hidden_input,I as iframe_input}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as t,c as s,h as i}from"./p-
|
|
1
|
+
import{r as t,c as s,h as i}from"./p-qipqIMyC.js";import{P as p}from"./p-CpKvg1ok.js";import{m as r}from"./p-CU4XQ3fO.js";import{E as e}from"./p-BIPdn2VU.js";import{C as o,a}from"./p-Cjcsf8ku.js";import{c as m,J as h}from"./p-BB5-CJF-.js";import"./p-BUa0YOaw.js";import"./p-Bp_QFeog.js";import"./p-DsAwPf2y.js";import"./p-BHf9IqGw.js";import"./p-HXpYMWUU.js";import"./p-c4Mh3ZZ_.js";import"./p-BH0Xfn-F.js";import"./p-CLHwhyvu.js";import"./p-BlJnA265.js";import"./p-Dt-vy9Le.js";import"./p-BX8GieXu.js";import"./p-D2muobcE.js";import"./p-RvUQ__Pq.js";import"./p-pXjOPQhG.js";const n=class{constructor(i){t(this,i),this.errorEvent=s(this,"error-event"),this.errorMessage=null,this.paymentService=new p,this.handleErrorEvent=t=>{this.errorMessage=t.detail.message,this.errorEvent.emit(t.detail)}}componentWillLoad(){m(),this.analytics=new h(this),this.initializeGetPaymentDetails()}disconnectedCallback(){var t;null===(t=this.analytics)||void 0===t||t.cleanup()}propChanged(){this.initializeGetPaymentDetails()}initializeGetPaymentDetails(){this.paymentId&&this.authToken?this.getPaymentDetails=r({id:this.paymentId,authToken:this.authToken,service:new p}):(this.errorMessage="Payment ID and Auth Token are required",this.errorEvent.emit({message:this.errorMessage,errorCode:a.MISSING_PROPS,severity:o.ERROR}))}render(){return this.errorMessage?e(this.errorMessage):i("payment-details-core",{getPaymentDetails:this.getPaymentDetails,"onError-event":this.handleErrorEvent})}static get watchers(){return{paymentId:["propChanged"],authToken:["propChanged"]}}};export{n as justifi_payment_details}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as t,c as s,h as e}from"./p-qipqIMyC.js";import"./p-Bp_QFeog.js";import"./p-HXpYMWUU.js";import"./p-Cjcsf8ku.js";import"./p-c4Mh3ZZ_.js";import{p as i}from"./p-CLHwhyvu.js";import"./p-BlJnA265.js";import"./p-BH0Xfn-F.js";import{T as a,a as r,b as h,c as o,d as c,e as n,f as p,g as f,h as d,i as u,j as b,k as m,l as g}from"./p-BZ7C9duj.js";import{T as y}from"./p-CZfYo5-1.js";import{c as j,a as k}from"./p-CzPUMw00.js";import{o as l,g as C}from"./p-DyDHaG6n.js";import"./p-DsAwPf2y.js";import"./p-BHf9IqGw.js";import"./p-Dt-vy9Le.js";import"./p-BX8GieXu.js";import"./p-RvUQ__Pq.js";import"./p-xY5RkFuA.js";import"./p-D--yCspA.js";const w=class{constructor(e){t(this,e),this.clickEvent=s(this,"click-event"),this.errorEvent=s(this,"error-event"),this.checkouts=[],this.subAccounts=[],this.loading=!0,this.paging=i,this.pagingParams={},this.handleClickPrevious=t=>{this.pagingParams={before_cursor:t},this.clickEvent.emit({name:y.previous})},this.handleClickNext=t=>{this.pagingParams={after_cursor:t},this.clickEvent.emit({name:y.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:y.row,data:e})}}updateOnPropChange(){this.fetchData()}componentWillLoad(){this.checkoutsTable=new a(this.checkouts,this.columns,j,k),this.getCheckouts&&this.getSubAccounts&&this.fetchData(),l("set",(()=>{this.pagingParams={}})),l("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=C();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(g,{key:"04dae06915792f92df18740353f63781fbc15558"},e(r,{key:"87f0d5658e76198d6332c272eabc09236569a6c3"},e(h,{key:"7b9d1d9e5875b7c83c126c06a80b1e4f8e9ec86c"},e(o,{key:"8e8963b02099f6ae81a1ab9b9e00212a87be742f"},this.checkoutsTable.columnData.map((t=>t)))),e(c,{key:"2e1b461150fc01112c08f030402c8433611da6f3"},e(n,{key:"aefba717db73fb1052eb49906354492548eda57d",columnSpan:this.checkoutsTable.columnKeys.length,isLoading:this.loading}),e(p,{key:"b353ddae94305c6f58c4026ab6a48ef16a05005c",isEmpty:this.showEmptyState,columnSpan:this.checkoutsTable.columnKeys.length}),e(f,{key:"852bb7c4f1968f56a692e595dbe9a6223b5b3b1d",columnSpan:this.checkoutsTable.columnKeys.length,errorMessage:this.errorMessage}),this.showRowData&&this.checkoutsTable.rowData.map(((t,s)=>e(d,{"data-test-id":"table-row","data-row-entity-id":this.entityId[s],onClick:this.rowClickHandler},t)))),this.paging&&e(u,{key:"5077d7f5843d62b73d85adafff03022db168de0f"},e(b,{key:"b338655c2ef2fb256795f781113a0fc312d76a1b"},e(m,{key:"c6f4f321400d0f6a73f2ef85a77ea9dab38270b6",colSpan:this.checkoutsTable.columnData.length},e("pagination-menu",{key:"de00aeea2bbf8cf88c2e31105967d6355ebb18f0",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{w as checkouts_list_core}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e,c as t,h as a,H as s}from"./p-qipqIMyC.js";import{I as i}from"./p-Ce_F4E0f.js";import{b as l,T as d,a as o,c as r,l as c}from"./p-RvUQ__Pq.js";import{F as n}from"./p-DCMrHeJI.js";import"./p-CZfYo5-1.js";import{S as h}from"./p-BX8GieXu.js";import{n as f}from"./p-BnjCmwMr.js";const u=class{constructor(a){e(this,a),this.formControlInput=t(this,"formControlInput"),this.formControlBlur=t(this,"formControlBlur"),this.imask=null,this.isFocused=!1,this.initializeIMask=()=>{this.textInput&&(this.imask=i(this.textInput,{mask:this.mask}),this.imask.on("accept",(()=>{var e;const t=null===(e=this.imask)||void 0===e?void 0:e.unmaskedValue;void 0!==t&&this.inputHandler(this.name,t)})),this.textInput.addEventListener("blur",(()=>this.formControlBlur.emit())))},this.handleFormControlInput=e=>{var t;const a=e.target,s=a.getAttribute("name"),i=(null===(t=this.imask)||void 0===t?void 0:t.unmaskedValue)||a.value;this.formControlInput.emit({name:s,value:i})},this.updateInput=e=>{this.imask&&e&&(this.imask.value=String(e))}}handleDefaultValueChange(e){this.initializeIMask(),this.updateInput(e)}disconnectedCallback(){var e;null===(e=this.imask)||void 0===e||e.destroy()}componentDidLoad(){this.textInput&&(this.initializeIMask(),this.updateInput(this.defaultValue))}get part(){return this.errorText?l:this.disabled?d:this.isFocused?o:r}render(){return a(s,{key:"cd0a23e4a4b1d7b39448e0770c5681aa319fe376"},a("div",{key:"fdaeea5b68035edc6885d7e3e5106d6c4962325f",class:"form-group d-flex flex-column"},a("div",{key:"46379bb141130c88d0b09c1382a9f34758808b8c",class:"d-flex align-items-start gap-2"},a("label",{key:"5a191a9c22d82d58354fa297d78f51c4cd0ec36b",part:c,class:"form-label",htmlFor:this.name},this.label),a("form-control-tooltip",{key:"9a8c580ee3b69902a30bca5aa79309be15d0c51d",helpText:this.helpText})),a("input",{key:"03bec84295380c4c86cc4c1b9ff6609ddf15c7b8",ref:e=>this.textInput=e,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:"text",disabled:this.disabled}),a(n,{key:"55e523b3be538bccd3a438edf109acbb7de3fce9",errorText:this.errorText,name:this.name})))}static get watchers(){return{defaultValue:["handleDefaultValueChange"]}}},b=class{constructor(t){e(this,t),this.address={},this.inputHandler=(e,t)=>{this.address[e]=t,this.address=Object.assign({},this.address)}}handleAddressChange(e){this.handleFormUpdate(e)}render(){var e,t,i,l,d,o,r,c,n,u,b,m;return a(s,{key:"63db91625abddc3e615b031e04366a5823d516cf"},a("div",{key:"e07f0e511b178471343594fe0c88ae286325a5e5",class:"row gy-3"},a("div",{key:"a22674f05f19378994eceb7386c29f579c285a26",class:"col-12 col-md-8"},a("form-control-text",{key:"c6cfe95a8ce577a162e4eae61ff7d61902b36e73",name:"line1",label:"Street Address",defaultValue:null===(e=this.defaultValues)||void 0===e?void 0:e.line1,errorText:null===(t=this.errors)||void 0===t?void 0:t.line1,inputHandler:this.inputHandler,helpText:"Enter your address exactly as stated on your driver's license. No PO Boxes."})),a("div",{key:"de08102a8f4948a929f4fd9194ba7eb2f075d507",class:"col-12 col-md-4"},a("form-control-text",{key:"8dd269cbd72719ff4ad7b85693ed67e1fdd88225",name:"line2",label:"Apartment, Suite, etc. (optional)",defaultValue:null===(i=this.defaultValues)||void 0===i?void 0:i.line2,errorText:null===(l=this.errors)||void 0===l?void 0:l.line2,inputHandler:this.inputHandler})),a("div",{key:"a1081a9a0016dc5fe06106ffdb0063374389f5de",class:"col-12"},a("form-control-text",{key:"94b340156ae354a87a93a8cb44bbc0a2f6507489",name:"city",label:"City",defaultValue:null===(d=this.defaultValues)||void 0===d?void 0:d.city,errorText:null===(o=this.errors)||void 0===o?void 0:o.city,inputHandler:this.inputHandler})),a("div",{key:"66732609b564a08b4b907e9a50aab38a782b0cbc",class:"col-12 col-md-6"},a("form-control-select",{key:"8f91fd2a2ae886044b105f21177c0ccd893c3993",name:"state",label:"State",defaultValue:null===(r=this.defaultValues)||void 0===r?void 0:r.state,options:h,errorText:null===(c=this.errors)||void 0===c?void 0:c.state,inputHandler:this.inputHandler})),a("div",{key:"ebec4b6351ccb7741e195806f1897436e10404cc",class:"col-12 col-md-6"},a("form-control-text",{key:"2d0884fb5acd8e2557fb5ece1b735e6d5945f2a1",name:"postal_code",label:"Postal Code",defaultValue:null===(n=this.defaultValues)||void 0===n?void 0:n.postal_code,errorText:null===(u=this.errors)||void 0===u?void 0:u.postal_code,maxLength:5,keyDownHandler:f,inputHandler:this.inputHandler})),a("div",{key:"8051b9545fd8a93fec6f1c00623c2e2876912db7",class:"col-12"},a("form-control-select",{key:"c68c63ce249f139f4d1df8820f0e1dd56763a67f",name:"country",label:"Country",options:[{label:"United States",value:"USA"}],inputHandler:this.inputHandler,defaultValue:null===(b=this.defaultValues)||void 0===b?void 0:b.country,errorText:null===(m=this.errors)||void 0===m?void 0:m.country,disabled:!0}))))}static get watchers(){return{address:["handleAddressChange"]}}};export{u as form_control_number_masked,b as justifi_identity_address_form}
|