@justifi/webcomponents 4.6.4 → 4.7.0-rc.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{Api-f76b337f.js → Api-548eaa62.js} +3 -17
- package/dist/cjs/Api-548eaa62.js.map +1 -0
- package/dist/cjs/Pagination-cae1dcbd.js +15 -0
- package/dist/cjs/Pagination-cae1dcbd.js.map +1 -0
- package/dist/cjs/{Payout-4906a445.js → Payout-68a99ee3.js} +22 -1
- package/dist/cjs/Payout-68a99ee3.js.map +1 -0
- package/dist/cjs/SubAccount-f47c8522.js +109 -0
- package/dist/cjs/SubAccount-f47c8522.js.map +1 -0
- package/dist/cjs/additional-questions-details_5.cjs.entry.js +84 -0
- package/dist/cjs/additional-questions-details_5.cjs.entry.js.map +1 -0
- package/dist/cjs/{business-form-schema-725ec6f5.js → business-form-schema-fe831c30.js} +2 -2
- package/dist/cjs/business-form-schema-fe831c30.js.map +1 -0
- package/dist/cjs/config-70f62990.js +19 -0
- package/dist/cjs/config-70f62990.js.map +1 -0
- package/dist/cjs/form-1e732a9d.js +731 -0
- package/dist/cjs/form-1e732a9d.js.map +1 -0
- package/dist/cjs/form-control-datepart_2.cjs.entry.js +44 -20
- package/dist/cjs/form-control-datepart_2.cjs.entry.js.map +1 -1
- package/dist/cjs/form-control-monetary.cjs.entry.js +1 -1
- package/dist/cjs/form-control-number_3.cjs.entry.js +17 -32
- package/dist/cjs/form-control-number_3.cjs.entry.js.map +1 -1
- package/dist/cjs/helpers-c505d861.js +28 -0
- package/dist/cjs/helpers-c505d861.js.map +1 -0
- package/dist/cjs/{index-3533152c.js → index-c5ace247.js} +8 -1
- package/dist/cjs/index-c5ace247.js.map +1 -0
- package/dist/cjs/{index.esm-84a0a7a8.js → index.esm-91ec051e.js} +123 -1
- package/dist/cjs/index.esm-91ec051e.js.map +1 -0
- package/dist/cjs/{justifi-additional-questions_5.cjs.entry.js → justifi-additional-questions_6.cjs.entry.js} +41 -16
- package/dist/cjs/justifi-additional-questions_6.cjs.entry.js.map +1 -0
- package/dist/cjs/justifi-bank-account-form.cjs.entry.js +1 -1
- package/dist/cjs/justifi-billing-form_2.cjs.entry.js +2 -2
- package/dist/cjs/justifi-business-details.cjs.entry.js +77 -0
- package/dist/cjs/justifi-business-details.cjs.entry.js.map +1 -0
- package/dist/cjs/justifi-business-form-stepped.cjs.entry.js +131 -0
- package/dist/cjs/justifi-business-form-stepped.cjs.entry.js.map +1 -0
- package/dist/cjs/justifi-business-form.cjs.entry.js +13 -756
- package/dist/cjs/justifi-business-form.cjs.entry.js.map +1 -1
- package/dist/cjs/justifi-business-list.cjs.entry.js +38 -67
- package/dist/cjs/justifi-business-list.cjs.entry.js.map +1 -1
- package/dist/cjs/justifi-card-form.cjs.entry.js +1 -1
- package/dist/cjs/justifi-details.cjs.entry.js +4 -8
- package/dist/cjs/justifi-details.cjs.entry.js.map +1 -1
- package/dist/cjs/justifi-gross-payment-chart.cjs.entry.js +11029 -0
- package/dist/cjs/justifi-gross-payment-chart.cjs.entry.js.map +1 -0
- package/dist/cjs/justifi-payment-balance-transactions.cjs.entry.js +88 -0
- package/dist/cjs/justifi-payment-balance-transactions.cjs.entry.js.map +1 -0
- package/dist/cjs/justifi-payment-details.cjs.entry.js +9 -9
- package/dist/cjs/justifi-payment-details.cjs.entry.js.map +1 -1
- package/dist/cjs/justifi-payment-form.cjs.entry.js +4 -3
- package/dist/cjs/justifi-payment-form.cjs.entry.js.map +1 -1
- package/dist/cjs/justifi-payment-method-form.cjs.entry.js +12 -10
- package/dist/cjs/justifi-payment-method-form.cjs.entry.js.map +1 -1
- package/dist/cjs/justifi-payments-list.cjs.entry.js +23 -17
- package/dist/cjs/justifi-payments-list.cjs.entry.js.map +1 -1
- package/dist/cjs/justifi-payout-details.cjs.entry.js +9 -7
- package/dist/cjs/justifi-payout-details.cjs.entry.js.map +1 -1
- package/dist/cjs/justifi-payouts-list.cjs.entry.js +24 -18
- package/dist/cjs/justifi-payouts-list.cjs.entry.js.map +1 -1
- package/dist/cjs/justifi-proceeds-list.cjs.entry.js +24 -18
- package/dist/cjs/justifi-proceeds-list.cjs.entry.js.map +1 -1
- package/dist/cjs/justifi-refund-form.cjs.entry.js +105 -0
- package/dist/cjs/justifi-refund-form.cjs.entry.js.map +1 -0
- package/dist/cjs/justifi-subaccount-details.cjs.entry.js +82 -0
- package/dist/cjs/justifi-subaccount-details.cjs.entry.js.map +1 -0
- package/dist/cjs/justifi-subaccounts-list.cjs.entry.js +105 -0
- package/dist/cjs/justifi-subaccounts-list.cjs.entry.js.map +1 -0
- package/dist/cjs/justifi-table_2.cjs.entry.js +80 -0
- package/dist/cjs/justifi-table_2.cjs.entry.js.map +1 -0
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/select-input_2.cjs.entry.js +1 -1
- package/dist/cjs/subaccount-account-details_4.cjs.entry.js +72 -0
- package/dist/cjs/subaccount-account-details_4.cjs.entry.js.map +1 -0
- package/dist/cjs/subaccount-bank-details.cjs.entry.js +24 -0
- package/dist/cjs/subaccount-bank-details.cjs.entry.js.map +1 -0
- package/dist/cjs/subaccount-terms-details.cjs.entry.js +24 -0
- package/dist/cjs/subaccount-terms-details.cjs.entry.js.map +1 -0
- package/dist/cjs/{utils-0fd61dbd.js → utils-13d069be.js} +96 -18
- package/dist/cjs/utils-13d069be.js.map +1 -0
- package/dist/cjs/utils-4622829d.js +37 -0
- package/dist/cjs/utils-4622829d.js.map +1 -0
- package/dist/cjs/webcomponents.cjs.js +2 -2
- package/dist/collection/api/Api.js +2 -16
- package/dist/collection/api/Api.js.map +1 -1
- package/dist/collection/api/Business.js +0 -2
- package/dist/collection/api/Business.js.map +1 -1
- package/dist/collection/api/GrossVolume.js +2 -0
- package/dist/collection/api/GrossVolume.js.map +1 -0
- package/dist/collection/api/Pagination.js +8 -8
- package/dist/collection/api/Pagination.js.map +1 -1
- package/dist/collection/api/Payment.js +20 -0
- package/dist/collection/api/Payment.js.map +1 -1
- package/dist/collection/api/SubAccount.js +104 -0
- package/dist/collection/api/SubAccount.js.map +1 -0
- package/dist/collection/api/mockData/MockOnboardingData.js +118 -0
- package/dist/collection/api/mockData/MockOnboardingData.js.map +1 -0
- package/dist/collection/api/mockData/MockSubAccount.js +103 -0
- package/dist/collection/api/mockData/MockSubAccount.js.map +1 -0
- package/dist/collection/api/mockData/mockGrossVolumeReport.js +126 -0
- package/dist/collection/api/mockData/mockGrossVolumeReport.js.map +1 -0
- package/dist/collection/assets/info-icon.svg +5 -0
- package/dist/collection/collection-manifest.json +20 -1
- package/dist/collection/components/bank-account-form/bank-account-form.stories.js +2 -9
- package/dist/collection/components/bank-account-form/bank-account-form.stories.js.map +1 -1
- package/dist/collection/components/billing-form/billing-form.stories.js +1 -1
- package/dist/collection/components/billing-form/billing-form.stories.js.map +1 -1
- package/dist/collection/components/business-details/additional-questions-details/additional-questions-details.css +7341 -0
- package/dist/collection/components/business-details/additional-questions-details/additional-questions-details.js +57 -0
- package/dist/collection/components/business-details/additional-questions-details/additional-questions-details.js.map +1 -0
- package/dist/collection/components/business-details/business-details.css +6439 -0
- package/dist/collection/components/business-details/business-details.js +128 -0
- package/dist/collection/components/business-details/business-details.js.map +1 -0
- package/dist/collection/components/business-details/business-details.stories.js +24 -0
- package/dist/collection/components/business-details/business-details.stories.js.map +1 -0
- package/dist/collection/components/business-details/generic-info-details/generic-info-details.css +7341 -0
- package/dist/collection/components/business-details/generic-info-details/generic-info-details.js +50 -0
- package/dist/collection/components/business-details/generic-info-details/generic-info-details.js.map +1 -0
- package/dist/collection/components/business-details/legal-address-details/legal-address-details.css +7341 -0
- package/dist/collection/components/business-details/legal-address-details/legal-address-details.js +49 -0
- package/dist/collection/components/business-details/legal-address-details/legal-address-details.js.map +1 -0
- package/dist/collection/components/business-details/owner-details/owner-details.css +7341 -0
- package/dist/collection/components/business-details/owner-details/owner-details.js +57 -0
- package/dist/collection/components/business-details/owner-details/owner-details.js.map +1 -0
- package/dist/collection/components/business-details/representative-details/representative-details.css +7341 -0
- package/dist/collection/components/business-details/representative-details/representative-details.js +58 -0
- package/dist/collection/components/business-details/representative-details/representative-details.js.map +1 -0
- package/dist/collection/components/business-form/additional-questions/additional-questions.js +1 -1
- package/dist/collection/components/business-form/additional-questions/additional-questions.js.map +1 -1
- package/dist/collection/components/business-form/business-form-schema.js +1 -1
- package/dist/collection/components/business-form/business-form-schema.js.map +1 -1
- package/dist/collection/components/business-form/business-form-stepped.css +7929 -0
- package/dist/collection/components/business-form/business-form-stepped.js +195 -0
- package/dist/collection/components/business-form/business-form-stepped.js.map +1 -0
- package/dist/collection/components/business-form/business-form-stepped.stories.js +132 -0
- package/dist/collection/components/business-form/business-form-stepped.stories.js.map +1 -0
- package/dist/collection/components/business-form/business-form.js +5 -24
- package/dist/collection/components/business-form/business-form.js.map +1 -1
- package/dist/collection/components/business-form/business-form.stories.js +21 -8
- package/dist/collection/components/business-form/business-form.stories.js.map +1 -1
- package/dist/collection/components/business-form/business-generic-info/business-generic-info.js +7 -5
- package/dist/collection/components/business-form/business-generic-info/business-generic-info.js.map +1 -1
- package/dist/collection/components/business-form/business-owners/business-owners.js +4 -5
- package/dist/collection/components/business-form/business-owners/business-owners.js.map +1 -1
- package/dist/collection/components/business-form/business-representative/business-representative-schema.js.map +1 -1
- package/dist/collection/components/business-form/business-representative/business-representative.js +1 -1
- package/dist/collection/components/business-form/business-representative/business-representative.js.map +1 -1
- package/dist/collection/components/business-form/helpers.js +23 -0
- package/dist/collection/components/business-form/helpers.js.map +1 -0
- package/dist/collection/components/business-form/legal-address-form/legal-address-form-schema.js.map +1 -0
- package/dist/collection/components/{legal-address-form → business-form/legal-address-form}/legal-address-form.js +3 -21
- package/dist/collection/components/business-form/legal-address-form/legal-address-form.js.map +1 -0
- package/dist/collection/components/business-list/business-list.js +72 -84
- package/dist/collection/components/business-list/business-list.js.map +1 -1
- package/dist/collection/components/business-list/business-list.stories.js +3 -2
- package/dist/collection/components/business-list/business-list.stories.js.map +1 -1
- package/dist/collection/components/card-form/card-form.stories.js +2 -9
- package/dist/collection/components/card-form/card-form.stories.js.map +1 -1
- package/dist/collection/components/details/details.js +2 -21
- package/dist/collection/components/details/details.js.map +1 -1
- package/dist/collection/components/details/utils.js +7 -8
- package/dist/collection/components/details/utils.js.map +1 -1
- package/dist/collection/components/form/form-control-number-masked.js +1 -1
- package/dist/collection/components/form/form-control-number-masked.js.map +1 -1
- package/dist/collection/components/form/form.js +4 -4
- package/dist/collection/components/form/form.js.map +1 -1
- package/dist/collection/components/gross-payment-chart/chart-utils.js +59 -0
- package/dist/collection/components/gross-payment-chart/chart-utils.js.map +1 -0
- package/dist/collection/components/gross-payment-chart/gross-payment-chart.css +572 -0
- package/dist/collection/components/gross-payment-chart/gross-payment-chart.js +127 -0
- package/dist/collection/components/gross-payment-chart/gross-payment-chart.js.map +1 -0
- package/dist/collection/components/gross-payment-chart/gross-payment-chart.stories.js +22 -0
- package/dist/collection/components/gross-payment-chart/gross-payment-chart.stories.js.map +1 -0
- package/dist/collection/components/gross-payment-chart/test/gross-payment-chart.spec.js +15 -0
- package/dist/collection/components/gross-payment-chart/test/gross-payment-chart.spec.js.map +1 -0
- package/dist/collection/components/pagination-menu/pagination-menu.js +78 -0
- package/dist/collection/components/pagination-menu/pagination-menu.js.map +1 -0
- package/dist/collection/components/payment-balance-transactions/payment-balance-transactions.css +0 -0
- package/dist/collection/components/payment-balance-transactions/payment-balance-transactions.js +153 -0
- package/dist/collection/components/payment-balance-transactions/payment-balance-transactions.js.map +1 -0
- package/dist/collection/components/payment-balance-transactions/payment-balance-transactions.stories.js +32 -0
- package/dist/collection/components/payment-balance-transactions/payment-balance-transactions.stories.js.map +1 -0
- package/dist/collection/components/payment-details/payment-details.js +12 -6
- package/dist/collection/components/payment-details/payment-details.js.map +1 -1
- package/dist/collection/components/payment-details/payment-details.stories.js +4 -4
- package/dist/collection/components/payment-details/payment-details.stories.js.map +1 -1
- package/dist/collection/components/payment-form/payment-form.stories.js +3 -11
- package/dist/collection/components/payment-form/payment-form.stories.js.map +1 -1
- package/dist/collection/components/payment-method-form/payment-method-form.js +7 -6
- package/dist/collection/components/payment-method-form/payment-method-form.js.map +1 -1
- package/dist/collection/components/payment-method-form/test/payment-method-form.spec.js +15 -14
- package/dist/collection/components/payment-method-form/test/payment-method-form.spec.js.map +1 -1
- package/dist/collection/components/payments-list/payments-list.js +21 -13
- package/dist/collection/components/payments-list/payments-list.js.map +1 -1
- package/dist/collection/components/payments-list/payments-list.stories.js +4 -4
- package/dist/collection/components/payments-list/payments-list.stories.js.map +1 -1
- package/dist/collection/components/payout-details/payout-details.js +12 -3
- package/dist/collection/components/payout-details/payout-details.js.map +1 -1
- package/dist/collection/components/payout-details/payout-details.stories.js +4 -4
- package/dist/collection/components/payout-details/payout-details.stories.js.map +1 -1
- package/dist/collection/components/payouts-list/payouts-list.js +22 -14
- package/dist/collection/components/payouts-list/payouts-list.js.map +1 -1
- package/dist/collection/components/payouts-list/payouts-list.stories.js +4 -4
- package/dist/collection/components/payouts-list/payouts-list.stories.js.map +1 -1
- package/dist/collection/components/proceeds-list/proceeds-list.js +22 -14
- package/dist/collection/components/proceeds-list/proceeds-list.js.map +1 -1
- package/dist/collection/components/proceeds-list/proceeds-list.stories.js +3 -2
- package/dist/collection/components/proceeds-list/proceeds-list.stories.js.map +1 -1
- package/dist/collection/components/refund-form/refund-form-schema.js +14 -0
- package/dist/collection/components/refund-form/refund-form-schema.js.map +1 -0
- package/dist/collection/components/refund-form/refund-form.css +7785 -0
- package/dist/collection/components/refund-form/refund-form.js +229 -0
- package/dist/collection/components/refund-form/refund-form.js.map +1 -0
- package/dist/collection/components/refund-form/refund-form.stories.js +169 -0
- package/dist/collection/components/refund-form/refund-form.stories.js.map +1 -0
- package/dist/collection/components/subaccount-details/subaccount-account-details/subaccount-account-details.css +7345 -0
- package/dist/collection/components/subaccount-details/subaccount-account-details/subaccount-account-details.js +71 -0
- package/dist/collection/components/subaccount-details/subaccount-account-details/subaccount-account-details.js.map +1 -0
- package/dist/collection/components/subaccount-details/subaccount-bank-details/subaccount-bank-details.css +7345 -0
- package/dist/collection/components/subaccount-details/subaccount-bank-details/subaccount-bank-details.js +49 -0
- package/dist/collection/components/subaccount-details/subaccount-bank-details/subaccount-bank-details.js.map +1 -0
- package/dist/collection/components/subaccount-details/subaccount-details.css +7983 -0
- package/dist/collection/components/subaccount-details/subaccount-details.js +148 -0
- package/dist/collection/components/subaccount-details/subaccount-details.js.map +1 -0
- package/dist/collection/components/subaccount-details/subaccount-details.stories.js +26 -0
- package/dist/collection/components/subaccount-details/subaccount-details.stories.js.map +1 -0
- package/dist/collection/components/subaccount-details/subaccount-merchant-details/subaccount-merchant-details.css +7345 -0
- package/dist/collection/components/subaccount-details/subaccount-merchant-details/subaccount-merchant-details.js +51 -0
- package/dist/collection/components/subaccount-details/subaccount-merchant-details/subaccount-merchant-details.js.map +1 -0
- package/dist/collection/components/subaccount-details/subaccount-owners-details/subaccount-owners-details.css +7345 -0
- package/dist/collection/components/subaccount-details/subaccount-owners-details/subaccount-owners-details.js +49 -0
- package/dist/collection/components/subaccount-details/subaccount-owners-details/subaccount-owners-details.js.map +1 -0
- package/dist/collection/components/subaccount-details/subaccount-representative-details/subaccount-representative-details.css +7345 -0
- package/dist/collection/components/subaccount-details/subaccount-representative-details/subaccount-representative-details.js +50 -0
- package/dist/collection/components/subaccount-details/subaccount-representative-details/subaccount-representative-details.js.map +1 -0
- package/dist/collection/components/subaccount-details/subaccount-terms-details/subaccount-terms-details.css +7345 -0
- package/dist/collection/components/subaccount-details/subaccount-terms-details/subaccount-terms-details.js +49 -0
- package/dist/collection/components/subaccount-details/subaccount-terms-details/subaccount-terms-details.js.map +1 -0
- package/dist/collection/components/subaccount-details/test/subaccount-details.spec.js +22 -0
- package/dist/collection/components/subaccount-details/test/subaccount-details.spec.js.map +1 -0
- package/dist/collection/components/subaccounts-list/subaccounts-list.css +3 -0
- package/dist/collection/components/subaccounts-list/subaccounts-list.js +180 -0
- package/dist/collection/components/subaccounts-list/subaccounts-list.js.map +1 -0
- package/dist/collection/components/subaccounts-list/subaccounts-list.stories.js +70 -0
- package/dist/collection/components/subaccounts-list/subaccounts-list.stories.js.map +1 -0
- package/dist/collection/components/subaccounts-list/test/subaccounts-list.e2e.js +10 -0
- package/dist/collection/components/subaccounts-list/test/subaccounts-list.e2e.js.map +1 -0
- package/dist/collection/components/subaccounts-list/test/subaccounts-list.spec.js +34 -0
- package/dist/collection/components/subaccounts-list/test/subaccounts-list.spec.js.map +1 -0
- package/dist/collection/components/table/table.js +27 -12
- package/dist/collection/components/table/table.js.map +1 -1
- package/dist/collection/components/table/test/table.spec.js +2 -2
- package/dist/collection/components/table/test/table.spec.js.map +1 -1
- package/dist/collection/utils/utils.js +95 -17
- package/dist/collection/utils/utils.js.map +1 -1
- package/dist/components/Api.js +2 -16
- package/dist/components/Api.js.map +1 -1
- package/dist/components/Pagination.js +12 -0
- package/dist/components/Pagination.js.map +1 -0
- package/dist/components/Payout.js +21 -1
- package/dist/components/Payout.js.map +1 -1
- package/dist/components/SubAccount.js +107 -0
- package/dist/components/SubAccount.js.map +1 -0
- package/dist/components/additional-questions-details.d.ts +11 -0
- package/dist/components/additional-questions-details.js +8 -0
- package/dist/components/additional-questions-details.js.map +1 -0
- package/dist/{cjs/justifi-table.cjs.entry.js → components/additional-questions-details2.js} +30 -61
- package/dist/components/additional-questions-details2.js.map +1 -0
- package/dist/components/additional-questions.js +1 -1
- package/dist/components/additional-questions.js.map +1 -1
- package/dist/components/business-generic-info.js +2 -5
- package/dist/components/business-generic-info.js.map +1 -1
- package/dist/components/business-owners.js +4 -5
- package/dist/components/business-owners.js.map +1 -1
- package/dist/components/business-representative.js +1 -1
- package/dist/components/business-representative.js.map +1 -1
- package/dist/components/config.js +17 -0
- package/dist/components/config.js.map +1 -0
- package/dist/components/details.js +6 -33
- package/dist/components/details.js.map +1 -1
- package/dist/components/form-control-number-masked2.js +1 -1
- package/dist/components/form-control-number-masked2.js.map +1 -1
- package/dist/components/form.js +729 -0
- package/dist/components/form.js.map +1 -0
- package/dist/components/generic-info-details.d.ts +11 -0
- package/dist/components/generic-info-details.js +8 -0
- package/dist/components/generic-info-details.js.map +1 -0
- package/dist/components/generic-info-details2.js +38 -0
- package/dist/components/generic-info-details2.js.map +1 -0
- package/dist/components/helpers.js +26 -0
- package/dist/components/helpers.js.map +1 -0
- package/dist/components/index.esm.js +122 -1
- package/dist/components/index.esm.js.map +1 -1
- package/dist/components/justifi-business-details.d.ts +11 -0
- package/dist/components/justifi-business-details.js +127 -0
- package/dist/components/justifi-business-details.js.map +1 -0
- package/dist/components/justifi-business-form-stepped.d.ts +11 -0
- package/dist/components/justifi-business-form-stepped.js +222 -0
- package/dist/components/justifi-business-form-stepped.js.map +1 -0
- package/dist/components/justifi-business-form.js +7 -750
- package/dist/components/justifi-business-form.js.map +1 -1
- package/dist/components/justifi-business-list.js +44 -65
- package/dist/components/justifi-business-list.js.map +1 -1
- package/dist/components/justifi-gross-payment-chart.d.ts +11 -0
- package/dist/components/justifi-gross-payment-chart.js +11052 -0
- package/dist/components/justifi-gross-payment-chart.js.map +1 -0
- package/dist/components/justifi-payment-balance-transactions.d.ts +11 -0
- package/dist/components/justifi-payment-balance-transactions.js +123 -0
- package/dist/components/justifi-payment-balance-transactions.js.map +1 -0
- package/dist/components/justifi-payment-details.js +7 -6
- package/dist/components/justifi-payment-details.js.map +1 -1
- package/dist/components/justifi-payment-form.js +3 -2
- package/dist/components/justifi-payment-form.js.map +1 -1
- package/dist/components/justifi-payments-list.js +30 -16
- package/dist/components/justifi-payments-list.js.map +1 -1
- package/dist/components/justifi-payout-details.js +7 -4
- package/dist/components/justifi-payout-details.js.map +1 -1
- package/dist/components/justifi-payouts-list.js +31 -17
- package/dist/components/justifi-payouts-list.js.map +1 -1
- package/dist/components/justifi-proceeds-list.js +30 -16
- package/dist/components/justifi-proceeds-list.js.map +1 -1
- package/dist/components/justifi-refund-form.d.ts +11 -0
- package/dist/components/justifi-refund-form.js +140 -0
- package/dist/components/justifi-refund-form.js.map +1 -0
- package/dist/components/justifi-subaccount-details.d.ts +11 -0
- package/dist/components/justifi-subaccount-details.js +134 -0
- package/dist/components/justifi-subaccount-details.js.map +1 -0
- package/dist/components/justifi-subaccounts-list.d.ts +11 -0
- package/dist/components/justifi-subaccounts-list.js +139 -0
- package/dist/components/justifi-subaccounts-list.js.map +1 -0
- package/dist/components/legal-address-details.d.ts +11 -0
- package/dist/components/legal-address-details.js +8 -0
- package/dist/components/legal-address-details.js.map +1 -0
- package/dist/components/legal-address-details2.js +37 -0
- package/dist/components/legal-address-details2.js.map +1 -0
- package/dist/components/legal-address-form.js +1 -3
- package/dist/components/legal-address-form.js.map +1 -1
- package/dist/components/owner-details.d.ts +11 -0
- package/dist/components/owner-details.js +8 -0
- package/dist/components/owner-details.js.map +1 -0
- package/dist/components/owner-details2.js +37 -0
- package/dist/components/owner-details2.js.map +1 -0
- package/dist/components/pagination-menu.d.ts +11 -0
- package/dist/components/pagination-menu.js +8 -0
- package/dist/components/pagination-menu.js.map +1 -0
- package/dist/{esm/justifi-table.entry.js → components/pagination-menu2.js} +35 -55
- package/dist/components/pagination-menu2.js.map +1 -0
- package/dist/components/payment-method-form.js +11 -9
- package/dist/components/payment-method-form.js.map +1 -1
- package/dist/components/representative-details.d.ts +11 -0
- package/dist/components/representative-details.js +8 -0
- package/dist/components/representative-details.js.map +1 -0
- package/dist/components/representative-details2.js +38 -0
- package/dist/components/representative-details2.js.map +1 -0
- package/dist/components/subaccount-account-details.d.ts +11 -0
- package/dist/components/subaccount-account-details.js +8 -0
- package/dist/components/subaccount-account-details.js.map +1 -0
- package/dist/components/subaccount-account-details2.js +39 -0
- package/dist/components/subaccount-account-details2.js.map +1 -0
- package/dist/components/subaccount-bank-details.d.ts +11 -0
- package/dist/components/subaccount-bank-details.js +40 -0
- package/dist/components/subaccount-bank-details.js.map +1 -0
- package/dist/components/subaccount-merchant-details.d.ts +11 -0
- package/dist/components/subaccount-merchant-details.js +8 -0
- package/dist/components/subaccount-merchant-details.js.map +1 -0
- package/dist/components/subaccount-merchant-details2.js +38 -0
- package/dist/components/subaccount-merchant-details2.js.map +1 -0
- package/dist/components/subaccount-owners-details.d.ts +11 -0
- package/dist/components/subaccount-owners-details.js +8 -0
- package/dist/components/subaccount-owners-details.js.map +1 -0
- package/dist/components/subaccount-owners-details2.js +38 -0
- package/dist/components/subaccount-owners-details2.js.map +1 -0
- package/dist/components/subaccount-representative-details.d.ts +11 -0
- package/dist/components/subaccount-representative-details.js +8 -0
- package/dist/components/subaccount-representative-details.js.map +1 -0
- package/dist/components/subaccount-representative-details2.js +38 -0
- package/dist/components/subaccount-representative-details2.js.map +1 -0
- package/dist/components/subaccount-terms-details.d.ts +11 -0
- package/dist/components/subaccount-terms-details.js +40 -0
- package/dist/components/subaccount-terms-details.js.map +1 -0
- package/dist/components/table.js +12 -21
- package/dist/components/table.js.map +1 -1
- package/dist/components/utils.js +27 -3909
- package/dist/components/utils.js.map +1 -1
- package/dist/components/utils2.js +3983 -0
- package/dist/components/utils2.js.map +1 -0
- package/dist/config.js +12 -4
- package/dist/config.js.map +1 -1
- package/dist/esm/{Api-cca120a8.js → Api-c65d3ed8.js} +3 -17
- package/dist/esm/Api-c65d3ed8.js.map +1 -0
- package/dist/esm/Pagination-31f770d6.js +12 -0
- package/dist/esm/Pagination-31f770d6.js.map +1 -0
- package/dist/esm/{Payout-9a1f2859.js → Payout-fcf16887.js} +22 -2
- package/dist/esm/Payout-fcf16887.js.map +1 -0
- package/dist/esm/SubAccount-128190e9.js +107 -0
- package/dist/esm/SubAccount-128190e9.js.map +1 -0
- package/dist/esm/additional-questions-details_5.entry.js +76 -0
- package/dist/esm/additional-questions-details_5.entry.js.map +1 -0
- package/dist/esm/{business-form-schema-5885d3d6.js → business-form-schema-30a3eadd.js} +2 -2
- package/dist/esm/business-form-schema-30a3eadd.js.map +1 -0
- package/dist/esm/config-b1976dbd.js +17 -0
- package/dist/esm/config-b1976dbd.js.map +1 -0
- package/dist/esm/form-32cf3d1e.js +729 -0
- package/dist/esm/form-32cf3d1e.js.map +1 -0
- package/dist/esm/form-control-datepart_2.entry.js +44 -20
- package/dist/esm/form-control-datepart_2.entry.js.map +1 -1
- package/dist/esm/form-control-monetary.entry.js +1 -1
- package/dist/esm/form-control-number_3.entry.js +17 -32
- package/dist/esm/form-control-number_3.entry.js.map +1 -1
- package/dist/esm/helpers-1d5ecdc8.js +26 -0
- package/dist/esm/helpers-1d5ecdc8.js.map +1 -0
- package/dist/esm/{index-fe877d03.js → index-7471ed60.js} +8 -1
- package/dist/esm/index-7471ed60.js.map +1 -0
- package/dist/esm/{index.esm-89fe6af9.js → index.esm-9397ffa0.js} +123 -2
- package/dist/esm/index.esm-9397ffa0.js.map +1 -0
- package/dist/esm/{justifi-additional-questions_5.entry.js → justifi-additional-questions_6.entry.js} +41 -17
- package/dist/esm/justifi-additional-questions_6.entry.js.map +1 -0
- package/dist/esm/justifi-bank-account-form.entry.js +1 -1
- package/dist/esm/justifi-billing-form_2.entry.js +2 -2
- package/dist/esm/justifi-business-details.entry.js +73 -0
- package/dist/esm/justifi-business-details.entry.js.map +1 -0
- package/dist/esm/justifi-business-form-stepped.entry.js +127 -0
- package/dist/esm/justifi-business-form-stepped.entry.js.map +1 -0
- package/dist/esm/justifi-business-form.entry.js +12 -755
- package/dist/esm/justifi-business-form.entry.js.map +1 -1
- package/dist/esm/justifi-business-list.entry.js +37 -66
- package/dist/esm/justifi-business-list.entry.js.map +1 -1
- package/dist/esm/justifi-card-form.entry.js +1 -1
- package/dist/esm/justifi-details.entry.js +4 -8
- package/dist/esm/justifi-details.entry.js.map +1 -1
- package/dist/esm/justifi-gross-payment-chart.entry.js +11025 -0
- package/dist/esm/justifi-gross-payment-chart.entry.js.map +1 -0
- package/dist/esm/justifi-payment-balance-transactions.entry.js +84 -0
- package/dist/esm/justifi-payment-balance-transactions.entry.js.map +1 -0
- package/dist/esm/justifi-payment-details.entry.js +9 -9
- package/dist/esm/justifi-payment-details.entry.js.map +1 -1
- package/dist/esm/justifi-payment-form.entry.js +4 -3
- package/dist/esm/justifi-payment-form.entry.js.map +1 -1
- package/dist/esm/justifi-payment-method-form.entry.js +12 -10
- package/dist/esm/justifi-payment-method-form.entry.js.map +1 -1
- package/dist/esm/justifi-payments-list.entry.js +22 -16
- package/dist/esm/justifi-payments-list.entry.js.map +1 -1
- package/dist/esm/justifi-payout-details.entry.js +9 -7
- package/dist/esm/justifi-payout-details.entry.js.map +1 -1
- package/dist/esm/justifi-payouts-list.entry.js +23 -17
- package/dist/esm/justifi-payouts-list.entry.js.map +1 -1
- package/dist/esm/justifi-proceeds-list.entry.js +23 -17
- package/dist/esm/justifi-proceeds-list.entry.js.map +1 -1
- package/dist/esm/justifi-refund-form.entry.js +101 -0
- package/dist/esm/justifi-refund-form.entry.js.map +1 -0
- package/dist/esm/justifi-subaccount-details.entry.js +78 -0
- package/dist/esm/justifi-subaccount-details.entry.js.map +1 -0
- package/dist/esm/justifi-subaccounts-list.entry.js +101 -0
- package/dist/esm/justifi-subaccounts-list.entry.js.map +1 -0
- package/dist/esm/justifi-table_2.entry.js +75 -0
- package/dist/esm/justifi-table_2.entry.js.map +1 -0
- package/dist/esm/loader.js +3 -3
- package/dist/esm/select-input_2.entry.js +1 -1
- package/dist/esm/subaccount-account-details_4.entry.js +65 -0
- package/dist/esm/subaccount-account-details_4.entry.js.map +1 -0
- package/dist/esm/subaccount-bank-details.entry.js +20 -0
- package/dist/esm/subaccount-bank-details.entry.js.map +1 -0
- package/dist/esm/subaccount-terms-details.entry.js +20 -0
- package/dist/esm/subaccount-terms-details.entry.js.map +1 -0
- package/dist/esm/{utils-ad0bbe03.js → utils-40b7002c.js} +91 -19
- package/dist/esm/utils-40b7002c.js.map +1 -0
- package/dist/esm/utils-6352c002.js +29 -0
- package/dist/esm/utils-6352c002.js.map +1 -0
- package/dist/esm/webcomponents.js +3 -3
- package/dist/types/api/Api.d.ts +4 -4
- package/dist/types/api/Business.d.ts +12 -4
- package/dist/types/api/GrossVolume.d.ts +8 -0
- package/dist/types/api/Pagination.d.ts +12 -6
- package/dist/types/api/Payment.d.ts +28 -0
- package/dist/types/api/SubAccount.d.ts +165 -0
- package/dist/types/api/mockData/MockOnboardingData.d.ts +8 -0
- package/dist/types/api/mockData/MockSubAccount.d.ts +3 -0
- package/dist/types/api/mockData/mockGrossVolumeReport.d.ts +7 -0
- package/dist/types/components/bank-account-form/bank-account-form.stories.d.ts +0 -7
- package/dist/types/components/business-details/additional-questions-details/additional-questions-details.d.ts +13 -0
- package/dist/types/components/business-details/business-details.d.ts +28 -0
- package/dist/types/components/business-details/business-details.stories.d.ts +7 -0
- package/dist/types/components/business-details/generic-info-details/generic-info-details.d.ts +5 -0
- package/dist/types/components/business-details/legal-address-details/legal-address-details.d.ts +5 -0
- package/dist/types/components/business-details/owner-details/owner-details.d.ts +13 -0
- package/dist/types/components/business-details/representative-details/representative-details.d.ts +13 -0
- package/dist/types/components/business-form/business-form-stepped.d.ts +29 -0
- package/dist/types/components/business-form/business-form-stepped.stories.d.ts +27 -0
- package/dist/types/components/business-form/business-form.d.ts +0 -1
- package/dist/types/components/business-form/business-form.stories.d.ts +6 -0
- package/dist/types/components/business-form/business-generic-info/business-generic-info.d.ts +5 -1
- package/dist/types/components/business-form/business-representative/business-representative-schema.d.ts +2 -0
- package/dist/types/components/business-form/helpers.d.ts +1 -0
- package/dist/types/components/{legal-address-form → business-form/legal-address-form}/legal-address-form.d.ts +1 -2
- package/dist/types/components/business-list/business-list.d.ts +34 -21
- package/dist/types/components/card-form/card-form.stories.d.ts +0 -7
- package/dist/types/components/details/details.d.ts +0 -3
- package/dist/types/components/details/utils.d.ts +5 -2
- package/dist/types/components/form/form.d.ts +1 -1
- package/dist/types/components/gross-payment-chart/chart-utils.d.ts +45 -0
- package/dist/types/components/gross-payment-chart/gross-payment-chart.d.ts +20 -0
- package/dist/types/components/gross-payment-chart/gross-payment-chart.stories.d.ts +7 -0
- package/dist/types/components/pagination-menu/pagination-menu.d.ts +10 -0
- package/dist/types/components/payment-balance-transactions/payment-balance-transactions.d.ts +17 -0
- package/dist/types/components/payment-balance-transactions/payment-balance-transactions.stories.d.ts +8 -0
- package/dist/types/components/payment-details/payment-details.d.ts +8 -0
- package/dist/types/components/payment-form/payment-form.stories.d.ts +1 -9
- package/dist/types/components/payments-list/payments-list.d.ts +5 -4
- package/dist/types/components/payout-details/payout-details.d.ts +8 -0
- package/dist/types/components/payouts-list/payouts-list.d.ts +5 -4
- package/dist/types/components/proceeds-list/proceeds-list.d.ts +5 -3
- package/dist/types/components/refund-form/refund-form-schema.d.ts +11 -0
- package/dist/types/components/refund-form/refund-form.d.ts +58 -0
- package/dist/types/components/refund-form/refund-form.stories.d.ts +27 -0
- package/dist/types/components/subaccount-details/subaccount-account-details/subaccount-account-details.d.ts +6 -0
- package/dist/types/components/subaccount-details/subaccount-bank-details/subaccount-bank-details.d.ts +5 -0
- package/dist/types/components/subaccount-details/subaccount-details.d.ts +16 -0
- package/dist/types/components/subaccount-details/subaccount-details.stories.d.ts +7 -0
- package/dist/types/components/subaccount-details/subaccount-merchant-details/subaccount-merchant-details.d.ts +5 -0
- package/dist/types/components/subaccount-details/subaccount-owners-details/subaccount-owners-details.d.ts +5 -0
- package/dist/types/components/subaccount-details/subaccount-representative-details/subaccount-representative-details.d.ts +5 -0
- package/dist/types/components/subaccount-details/subaccount-terms-details/subaccount-terms-details.d.ts +5 -0
- package/dist/types/components/subaccounts-list/subaccounts-list.d.ts +19 -0
- package/dist/types/components/subaccounts-list/subaccounts-list.stories.d.ts +9 -0
- package/dist/types/components/table/table.d.ts +3 -7
- package/dist/types/components.d.ts +619 -7
- package/dist/types/home/runner/work/web-component-library/web-component-library/stencil-library/.stencil/config.d.ts +12 -4
- package/dist/types/utils/utils.d.ts +19 -0
- package/dist/webcomponents/p-0d5d02d7.js +2 -0
- package/dist/webcomponents/p-0d5d02d7.js.map +1 -0
- package/dist/webcomponents/p-0e9a7fa7.entry.js +2 -0
- package/dist/webcomponents/p-0e9a7fa7.entry.js.map +1 -0
- package/dist/webcomponents/p-1920e118.entry.js +2 -0
- package/dist/webcomponents/p-1920e118.entry.js.map +1 -0
- package/dist/webcomponents/p-215b4c87.entry.js +2 -0
- package/dist/webcomponents/{p-f6cc37a6.entry.js.map → p-215b4c87.entry.js.map} +1 -1
- package/dist/webcomponents/p-222d357c.entry.js +20 -0
- package/dist/webcomponents/p-222d357c.entry.js.map +1 -0
- package/dist/webcomponents/{p-d92116e6.entry.js → p-2cd29187.entry.js} +2 -2
- package/dist/webcomponents/p-301a23aa.js +2 -0
- package/dist/webcomponents/p-301a23aa.js.map +1 -0
- package/dist/webcomponents/p-355eabff.entry.js +2 -0
- package/dist/webcomponents/p-355eabff.entry.js.map +1 -0
- package/dist/webcomponents/{p-640bfa9f.entry.js → p-356cf20d.entry.js} +2 -2
- package/dist/webcomponents/p-397e0d5a.entry.js +2 -0
- package/dist/webcomponents/p-397e0d5a.entry.js.map +1 -0
- package/dist/webcomponents/p-491d5c69.entry.js +2 -0
- package/dist/webcomponents/p-491d5c69.entry.js.map +1 -0
- package/dist/webcomponents/p-526cb161.js +2 -0
- package/dist/webcomponents/p-526cb161.js.map +1 -0
- package/dist/webcomponents/{p-f9e127a5.js → p-59860ac8.js} +2 -2
- package/dist/webcomponents/p-59860ac8.js.map +1 -0
- package/dist/webcomponents/p-62872b87.entry.js +2 -0
- package/dist/webcomponents/p-62872b87.entry.js.map +1 -0
- package/dist/webcomponents/p-635a3b3e.entry.js +2 -0
- package/dist/webcomponents/p-635a3b3e.entry.js.map +1 -0
- package/dist/webcomponents/p-64184a0c.entry.js +2 -0
- package/dist/webcomponents/p-64184a0c.entry.js.map +1 -0
- package/dist/webcomponents/p-6c3236e8.entry.js +2 -0
- package/dist/webcomponents/p-6c3236e8.entry.js.map +1 -0
- package/dist/webcomponents/p-76983a7e.js +2 -0
- package/dist/webcomponents/p-76983a7e.js.map +1 -0
- package/dist/webcomponents/p-76dffeec.js +2 -0
- package/dist/webcomponents/p-76dffeec.js.map +1 -0
- package/dist/webcomponents/{p-2b6f5e35.entry.js → p-77e732b2.entry.js} +2 -2
- package/dist/webcomponents/p-77e732b2.entry.js.map +1 -0
- package/dist/webcomponents/p-798483dd.entry.js +2 -0
- package/dist/webcomponents/p-798483dd.entry.js.map +1 -0
- package/dist/webcomponents/p-7a24ab66.entry.js +2 -0
- package/dist/webcomponents/p-7a24ab66.entry.js.map +1 -0
- package/dist/webcomponents/p-7cde64a2.entry.js +2 -0
- package/dist/webcomponents/{p-9d1c7e6a.entry.js.map → p-7cde64a2.entry.js.map} +1 -1
- package/dist/webcomponents/p-7d58db66.js +2 -0
- package/dist/webcomponents/p-7d58db66.js.map +1 -0
- package/dist/webcomponents/p-8367b46c.entry.js +2 -0
- package/dist/webcomponents/p-8367b46c.entry.js.map +1 -0
- package/dist/webcomponents/{p-1beaaba3.entry.js → p-88fa33c1.entry.js} +2 -2
- package/dist/webcomponents/{p-c46241ba.js → p-8f37e3ee.js} +2 -2
- package/dist/webcomponents/p-8f37e3ee.js.map +1 -0
- package/dist/webcomponents/p-931989e6.entry.js +2 -0
- package/dist/webcomponents/p-931989e6.entry.js.map +1 -0
- package/dist/webcomponents/{p-cd0eca25.entry.js → p-96eecdff.entry.js} +2 -2
- package/dist/webcomponents/p-988191bf.js +2 -0
- package/dist/webcomponents/p-988191bf.js.map +1 -0
- package/dist/webcomponents/p-a4c78757.entry.js +2 -0
- package/dist/webcomponents/p-a4c78757.entry.js.map +1 -0
- package/dist/webcomponents/p-b08a9520.entry.js +2 -0
- package/dist/webcomponents/p-b08a9520.entry.js.map +1 -0
- package/dist/webcomponents/p-b157f6ae.js +2 -0
- package/dist/webcomponents/p-b157f6ae.js.map +1 -0
- package/dist/webcomponents/p-b45453ea.entry.js +2 -0
- package/dist/webcomponents/p-b45453ea.entry.js.map +1 -0
- package/dist/webcomponents/p-c2845c5d.entry.js +2 -0
- package/dist/webcomponents/p-c2845c5d.entry.js.map +1 -0
- package/dist/webcomponents/p-c4289027.entry.js +2 -0
- package/dist/webcomponents/p-c4289027.entry.js.map +1 -0
- package/dist/webcomponents/p-c43e9572.entry.js +2 -0
- package/dist/webcomponents/p-c43e9572.entry.js.map +1 -0
- package/dist/webcomponents/p-cbb60191.js +3 -0
- package/dist/webcomponents/p-cbb60191.js.map +1 -0
- package/dist/webcomponents/{p-26392ae3.entry.js → p-d40718da.entry.js} +2 -2
- package/dist/webcomponents/p-d40718da.entry.js.map +1 -0
- package/dist/webcomponents/{p-9346ae33.js → p-d6b5793d.js} +2 -2
- package/dist/webcomponents/p-d6b5793d.js.map +1 -0
- package/dist/webcomponents/{p-a922b908.entry.js → p-ec1890fc.entry.js} +2 -2
- package/dist/webcomponents/p-ffcbf779.entry.js +2 -0
- package/dist/webcomponents/p-ffcbf779.entry.js.map +1 -0
- package/dist/webcomponents/webcomponents.esm.js +1 -1
- package/dist/webcomponents/webcomponents.esm.js.map +1 -1
- package/package.json +8 -7
- package/dist/cjs/Api-f76b337f.js.map +0 -1
- package/dist/cjs/Payout-4906a445.js.map +0 -1
- package/dist/cjs/business-form-schema-725ec6f5.js.map +0 -1
- package/dist/cjs/form-control-select.cjs.entry.js +0 -47
- package/dist/cjs/form-control-select.cjs.entry.js.map +0 -1
- package/dist/cjs/index-3533152c.js.map +0 -1
- package/dist/cjs/index.esm-84a0a7a8.js.map +0 -1
- package/dist/cjs/justifi-additional-questions_5.cjs.entry.js.map +0 -1
- package/dist/cjs/justifi-table.cjs.entry.js.map +0 -1
- package/dist/cjs/table-utils-617126e5.js +0 -13
- package/dist/cjs/table-utils-617126e5.js.map +0 -1
- package/dist/cjs/utils-0fd61dbd.js.map +0 -1
- package/dist/cjs/utils-d95b09c2.js +0 -35
- package/dist/cjs/utils-d95b09c2.js.map +0 -1
- package/dist/collection/components/legal-address-form/legal-address-form-schema.js.map +0 -1
- package/dist/collection/components/legal-address-form/legal-address-form.js.map +0 -1
- package/dist/collection/components/table/table-utils.js +0 -8
- package/dist/collection/components/table/table-utils.js.map +0 -1
- package/dist/esm/Api-cca120a8.js.map +0 -1
- package/dist/esm/Payout-9a1f2859.js.map +0 -1
- package/dist/esm/business-form-schema-5885d3d6.js.map +0 -1
- package/dist/esm/form-control-select.entry.js +0 -43
- package/dist/esm/form-control-select.entry.js.map +0 -1
- package/dist/esm/index-fe877d03.js.map +0 -1
- package/dist/esm/index.esm-89fe6af9.js.map +0 -1
- package/dist/esm/justifi-additional-questions_5.entry.js.map +0 -1
- package/dist/esm/justifi-table.entry.js.map +0 -1
- package/dist/esm/table-utils-6cdcaa8c.js +0 -11
- package/dist/esm/table-utils-6cdcaa8c.js.map +0 -1
- package/dist/esm/utils-1e7d6279.js +0 -28
- package/dist/esm/utils-1e7d6279.js.map +0 -1
- package/dist/esm/utils-ad0bbe03.js.map +0 -1
- package/dist/types/components/table/table-utils.d.ts +0 -14
- package/dist/webcomponents/p-26392ae3.entry.js.map +0 -1
- package/dist/webcomponents/p-2b6f5e35.entry.js.map +0 -1
- package/dist/webcomponents/p-2e66512d.entry.js +0 -2
- package/dist/webcomponents/p-2e66512d.entry.js.map +0 -1
- package/dist/webcomponents/p-523cbe04.js +0 -2
- package/dist/webcomponents/p-523cbe04.js.map +0 -1
- package/dist/webcomponents/p-641883b2.entry.js +0 -2
- package/dist/webcomponents/p-641883b2.entry.js.map +0 -1
- package/dist/webcomponents/p-69a1bec2.entry.js +0 -2
- package/dist/webcomponents/p-69a1bec2.entry.js.map +0 -1
- package/dist/webcomponents/p-6a0c8dec.entry.js +0 -2
- package/dist/webcomponents/p-6a0c8dec.entry.js.map +0 -1
- package/dist/webcomponents/p-87410719.entry.js +0 -2
- package/dist/webcomponents/p-87410719.entry.js.map +0 -1
- package/dist/webcomponents/p-881edb4d.entry.js +0 -2
- package/dist/webcomponents/p-881edb4d.entry.js.map +0 -1
- package/dist/webcomponents/p-9346ae33.js.map +0 -1
- package/dist/webcomponents/p-9d1c7e6a.entry.js +0 -2
- package/dist/webcomponents/p-ab0756ff.js +0 -2
- package/dist/webcomponents/p-ab0756ff.js.map +0 -1
- package/dist/webcomponents/p-c46241ba.js.map +0 -1
- package/dist/webcomponents/p-ccb0e1c5.js +0 -2
- package/dist/webcomponents/p-ccb0e1c5.js.map +0 -1
- package/dist/webcomponents/p-dabeb3df.entry.js +0 -2
- package/dist/webcomponents/p-dabeb3df.entry.js.map +0 -1
- package/dist/webcomponents/p-db9945b1.entry.js +0 -2
- package/dist/webcomponents/p-db9945b1.entry.js.map +0 -1
- package/dist/webcomponents/p-e1f6c8ec.entry.js +0 -2
- package/dist/webcomponents/p-e1f6c8ec.entry.js.map +0 -1
- package/dist/webcomponents/p-e41fb562.entry.js +0 -2
- package/dist/webcomponents/p-e41fb562.entry.js.map +0 -1
- package/dist/webcomponents/p-e6695628.js +0 -2
- package/dist/webcomponents/p-e6695628.js.map +0 -1
- package/dist/webcomponents/p-e70b2a21.js +0 -3
- package/dist/webcomponents/p-e70b2a21.js.map +0 -1
- package/dist/webcomponents/p-f6cc37a6.entry.js +0 -2
- package/dist/webcomponents/p-f8067330.entry.js +0 -2
- package/dist/webcomponents/p-f8067330.entry.js.map +0 -1
- package/dist/webcomponents/p-f9e127a5.js.map +0 -1
- /package/dist/collection/components/{legal-address-form → business-form/legal-address-form}/legal-address-form-schema.js +0 -0
- /package/dist/collection/components/{legal-address-form → business-form/legal-address-form}/legal-address-form.css +0 -0
- /package/dist/types/components/{legal-address-form → business-form/legal-address-form}/legal-address-form-schema.d.ts +0 -0
- /package/dist/webcomponents/{p-d92116e6.entry.js.map → p-2cd29187.entry.js.map} +0 -0
- /package/dist/webcomponents/{p-640bfa9f.entry.js.map → p-356cf20d.entry.js.map} +0 -0
- /package/dist/webcomponents/{p-1beaaba3.entry.js.map → p-88fa33c1.entry.js.map} +0 -0
- /package/dist/webcomponents/{p-cd0eca25.entry.js.map → p-96eecdff.entry.js.map} +0 -0
- /package/dist/webcomponents/{p-a922b908.entry.js.map → p-ec1890fc.entry.js.map} +0 -0
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
import { Host, h } from "@stencil/core";
|
|
2
|
+
import { Api } from "../../api";
|
|
3
|
+
import { Chart, BarController, Colors, BarElement, CategoryScale, LinearScale, Legend, Tooltip, Title } from "chart.js";
|
|
4
|
+
import { generateChartOptions } from "./chart-utils";
|
|
5
|
+
import { ErrorState } from "../details/utils";
|
|
6
|
+
export class GrossPaymentChart {
|
|
7
|
+
constructor() {
|
|
8
|
+
this.accountId = undefined;
|
|
9
|
+
this.authToken = undefined;
|
|
10
|
+
this.data = undefined;
|
|
11
|
+
this.total = undefined;
|
|
12
|
+
this.dates = undefined;
|
|
13
|
+
this.endDate = undefined;
|
|
14
|
+
this.loading = true;
|
|
15
|
+
this.errorMessage = '';
|
|
16
|
+
}
|
|
17
|
+
updateOnPropChange() {
|
|
18
|
+
this.fetchData();
|
|
19
|
+
}
|
|
20
|
+
connectedCallback() {
|
|
21
|
+
this.fetchData();
|
|
22
|
+
}
|
|
23
|
+
componentDidRender() {
|
|
24
|
+
this.renderChart();
|
|
25
|
+
}
|
|
26
|
+
async fetchData() {
|
|
27
|
+
if (!this.accountId || !this.authToken) {
|
|
28
|
+
this.errorMessage = "Can not fetch any data without an AccountID and an AuthToken";
|
|
29
|
+
this.loading = false;
|
|
30
|
+
return;
|
|
31
|
+
}
|
|
32
|
+
this.loading = true;
|
|
33
|
+
const api = Api(this.authToken, process.env.PRIVATE_API_ORIGIN);
|
|
34
|
+
const endpoint = `account/${this.accountId}/reports/gross_volume`;
|
|
35
|
+
const response = await api.get(endpoint);
|
|
36
|
+
if (!response.error) {
|
|
37
|
+
this.total = response === null || response === void 0 ? void 0 : response.data.total;
|
|
38
|
+
this.dates = response === null || response === void 0 ? void 0 : response.data.dates.reverse();
|
|
39
|
+
this.endDate = this.dates[this.dates.length - 1].date;
|
|
40
|
+
}
|
|
41
|
+
this.loading = false;
|
|
42
|
+
}
|
|
43
|
+
renderChart() {
|
|
44
|
+
if (this.chart) {
|
|
45
|
+
this.chart.update();
|
|
46
|
+
}
|
|
47
|
+
else if (this.chartRef && this.endDate) {
|
|
48
|
+
Chart.register(Colors, BarController, BarElement, CategoryScale, LinearScale, Legend, Tooltip, Title);
|
|
49
|
+
this.chart = new Chart(this.chartRef.getContext("2d"), generateChartOptions(this.total, this.dates, this.endDate));
|
|
50
|
+
this.chart.render();
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
render() {
|
|
54
|
+
return (h(Host, null, this.errorMessage ? ErrorState(this.errorMessage)
|
|
55
|
+
: h("canvas", { id: "chart", ref: (elem) => this.chartRef = elem })));
|
|
56
|
+
}
|
|
57
|
+
static get is() { return "justifi-gross-payment-chart"; }
|
|
58
|
+
static get encapsulation() { return "shadow"; }
|
|
59
|
+
static get originalStyleUrls() {
|
|
60
|
+
return {
|
|
61
|
+
"$": ["gross-payment-chart.scss"]
|
|
62
|
+
};
|
|
63
|
+
}
|
|
64
|
+
static get styleUrls() {
|
|
65
|
+
return {
|
|
66
|
+
"$": ["gross-payment-chart.css"]
|
|
67
|
+
};
|
|
68
|
+
}
|
|
69
|
+
static get properties() {
|
|
70
|
+
return {
|
|
71
|
+
"accountId": {
|
|
72
|
+
"type": "string",
|
|
73
|
+
"mutable": false,
|
|
74
|
+
"complexType": {
|
|
75
|
+
"original": "string",
|
|
76
|
+
"resolved": "string",
|
|
77
|
+
"references": {}
|
|
78
|
+
},
|
|
79
|
+
"required": false,
|
|
80
|
+
"optional": false,
|
|
81
|
+
"docs": {
|
|
82
|
+
"tags": [],
|
|
83
|
+
"text": ""
|
|
84
|
+
},
|
|
85
|
+
"attribute": "account-id",
|
|
86
|
+
"reflect": false
|
|
87
|
+
},
|
|
88
|
+
"authToken": {
|
|
89
|
+
"type": "string",
|
|
90
|
+
"mutable": false,
|
|
91
|
+
"complexType": {
|
|
92
|
+
"original": "string",
|
|
93
|
+
"resolved": "string",
|
|
94
|
+
"references": {}
|
|
95
|
+
},
|
|
96
|
+
"required": false,
|
|
97
|
+
"optional": false,
|
|
98
|
+
"docs": {
|
|
99
|
+
"tags": [],
|
|
100
|
+
"text": ""
|
|
101
|
+
},
|
|
102
|
+
"attribute": "auth-token",
|
|
103
|
+
"reflect": false
|
|
104
|
+
}
|
|
105
|
+
};
|
|
106
|
+
}
|
|
107
|
+
static get states() {
|
|
108
|
+
return {
|
|
109
|
+
"data": {},
|
|
110
|
+
"total": {},
|
|
111
|
+
"dates": {},
|
|
112
|
+
"endDate": {},
|
|
113
|
+
"loading": {},
|
|
114
|
+
"errorMessage": {}
|
|
115
|
+
};
|
|
116
|
+
}
|
|
117
|
+
static get watchers() {
|
|
118
|
+
return [{
|
|
119
|
+
"propName": "accountId",
|
|
120
|
+
"methodName": "updateOnPropChange"
|
|
121
|
+
}, {
|
|
122
|
+
"propName": "authToken",
|
|
123
|
+
"methodName": "updateOnPropChange"
|
|
124
|
+
}];
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
//# sourceMappingURL=gross-payment-chart.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"gross-payment-chart.js","sourceRoot":"","sources":["../../../../src/components/gross-payment-chart/gross-payment-chart.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,CAAC,EAAE,MAAM,eAAe,CAAC;AACvE,OAAO,EAAE,GAAG,EAA0B,MAAM,WAAW,CAAC;AACxD,OAAO,EAAE,KAAK,EAAE,aAAa,EAAE,MAAM,EAAE,UAAU,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,EAAE,OAAO,EAAE,KAAK,EAAqB,MAAM,UAAU,CAAA;AAE1I,OAAO,EAAE,oBAAoB,EAAE,MAAM,eAAe,CAAC;AACrD,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAO9C,MAAM,OAAO,iBAAiB;;;;;;;;mBAUA,IAAI;wBACA,EAAE;;EAIlC,kBAAkB;IAChB,IAAI,CAAC,SAAS,EAAE,CAAC;EACnB,CAAC;EAED,iBAAiB;IACf,IAAI,CAAC,SAAS,EAAE,CAAC;EACnB,CAAC;EAED,kBAAkB;IAChB,IAAI,CAAC,WAAW,EAAE,CAAC;EACrB,CAAC;EAED,KAAK,CAAC,SAAS;IACb,IAAI,CAAC,IAAI,CAAC,SAAS,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE;MACtC,IAAI,CAAC,YAAY,GAAG,8DAA8D,CAAC;MACnF,IAAI,CAAC,OAAO,GAAG,KAAK,CAAC;MACrB,OAAO;KACR;IACD,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC;IAEpB,MAAM,GAAG,GAAG,GAAG,CAAC,IAAI,CAAC,SAAS,EAAE,OAAO,CAAC,GAAG,CAAC,kBAAkB,CAAC,CAAC;IAChE,MAAM,QAAQ,GAAG,WAAW,IAAI,CAAC,SAAS,uBAAuB,CAAC;IAClE,MAAM,QAAQ,GAA8C,MAAM,GAAG,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;IAEpF,IAAI,CAAC,QAAQ,CAAC,KAAK,EAAE;MACnB,IAAI,CAAC,KAAK,GAAG,QAAQ,aAAR,QAAQ,uBAAR,QAAQ,CAAE,IAAI,CAAC,KAAK,CAAC;MAClC,IAAI,CAAC,KAAK,GAAG,QAAQ,aAAR,QAAQ,uBAAR,QAAQ,CAAE,IAAI,CAAC,KAAK,CAAC,OAAO,EAAE,CAAC;MAC5C,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC;KACvD;IAED,IAAI,CAAC,OAAO,GAAG,KAAK,CAAC;EACvB,CAAC;EAED,WAAW;IACT,IAAI,IAAI,CAAC,KAAK,EAAE;MACd,IAAI,CAAC,KAAK,CAAC,MAAM,EAAE,CAAA;KACpB;SAAM,IAAI,IAAI,CAAC,QAAQ,IAAI,IAAI,CAAC,OAAO,EAAE;MACxC,KAAK,CAAC,QAAQ,CACZ,MAAM,EACN,aAAa,EACb,UAAU,EACV,aAAa,EACb,WAAW,EACX,MAAM,EACN,OAAO,EACP,KAAK,CACN,CAAA;MACD,IAAI,CAAC,KAAK,GAAG,IAAI,KAAK,CACpB,IAAI,CAAC,QAAQ,CAAC,UAAU,CAAC,IAAI,CAAC,EAC9B,oBAAoB,CAAC,IAAI,CAAC,KAAK,EAAE,IAAI,CAAC,KAAK,EAAE,IAAI,CAAC,OAAO,CAAuB,CACjF,CAAC;MACF,IAAI,CAAC,KAAK,CAAC,MAAM,EAAE,CAAA;KACpB;EACH,CAAC;EAED,MAAM;IACJ,OAAO,CACL,EAAC,IAAI,QAED,IAAI,CAAC,YAAY,CAAC,CAAC,CAAC,UAAU,CAAC,IAAI,CAAC,YAAY,CAAC;MAC/C,CAAC,CAAC,cAAQ,EAAE,EAAC,OAAO,EAAC,GAAG,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,QAAQ,GAAG,IAAI,GAAI,CAE3D,CACR,CAAC;EACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Host, Prop, State, Watch, h } from '@stencil/core';\nimport { Api, IApiResponseCollection } from '../../api';\nimport { Chart, BarController, Colors, BarElement, CategoryScale, LinearScale, Legend, Tooltip, Title, ChartConfiguration} from 'chart.js'\nimport { GrossVolumeReport, GrossVolumeReportDate } from '../../api/GrossVolume';\nimport { generateChartOptions } from './chart-utils';\nimport { ErrorState } from '../details/utils';\n\n@Component({\n tag: 'justifi-gross-payment-chart',\n styleUrl: 'gross-payment-chart.scss',\n shadow: true,\n})\nexport class GrossPaymentChart {\n chart: Chart\n chartRef: HTMLCanvasElement\n\n @Prop() accountId: string;\n @Prop() authToken: string;\n @State() data: GrossVolumeReport;\n @State() total: number;\n @State() dates: GrossVolumeReportDate[];\n @State() endDate: string;\n @State() loading: boolean = true;\n @State() errorMessage: string = '';\n\n @Watch('accountId')\n @Watch('authToken')\n updateOnPropChange() {\n this.fetchData();\n }\n\n connectedCallback() {\n this.fetchData();\n }\n \n componentDidRender() {\n this.renderChart();\n }\n\n async fetchData(): Promise<void> {\n if (!this.accountId || !this.authToken) {\n this.errorMessage = \"Can not fetch any data without an AccountID and an AuthToken\";\n this.loading = false;\n return;\n }\n this.loading = true;\n\n const api = Api(this.authToken, process.env.PRIVATE_API_ORIGIN);\n const endpoint = `account/${this.accountId}/reports/gross_volume`;\n const response: IApiResponseCollection<GrossVolumeReport> = await api.get(endpoint);\n\n if (!response.error) {\n this.total = response?.data.total;\n this.dates = response?.data.dates.reverse();\n this.endDate = this.dates[this.dates.length - 1].date;\n }\n\n this.loading = false;\n }\n\n renderChart() {\n if (this.chart) {\n this.chart.update()\n } else if (this.chartRef && this.endDate) {\n Chart.register(\n Colors,\n BarController,\n BarElement,\n CategoryScale,\n LinearScale,\n Legend,\n Tooltip,\n Title\n )\n this.chart = new Chart(\n this.chartRef.getContext(\"2d\"),\n generateChartOptions(this.total, this.dates, this.endDate) as ChartConfiguration\n );\n this.chart.render()\n }\n }\n\n render() {\n return (\n <Host>\n {\n this.errorMessage ? ErrorState(this.errorMessage) \n : <canvas id=\"chart\" ref={(elem) => this.chartRef = elem} />\n }\n </Host>\n );\n }\n}\n"]}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export default {
|
|
2
|
+
title: 'dev/Components/GrossPaymentChart',
|
|
3
|
+
component: 'justifi-gross-payment-chart',
|
|
4
|
+
parameters: {}
|
|
5
|
+
};
|
|
6
|
+
class GrossChartArgs {
|
|
7
|
+
constructor(args) {
|
|
8
|
+
this['auth-token'] = args['auth-token'] || '';
|
|
9
|
+
this['account-id'] = args['account-id'] || '';
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
const Template = (args) => {
|
|
13
|
+
return (`
|
|
14
|
+
<justifi-gross-payment-chart
|
|
15
|
+
auth-token="${args['auth-token']}"
|
|
16
|
+
account-id="${args['account-id']}"
|
|
17
|
+
/>
|
|
18
|
+
`);
|
|
19
|
+
};
|
|
20
|
+
export const Basic = Template.bind({});
|
|
21
|
+
Basic.args = new GrossChartArgs({});
|
|
22
|
+
//# sourceMappingURL=gross-payment-chart.stories.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"gross-payment-chart.stories.js","sourceRoot":"","sources":["../../../../src/components/gross-payment-chart/gross-payment-chart.stories.ts"],"names":[],"mappings":"AAAA,eAAe;EACb,KAAK,EAAE,kCAAkC;EACzC,SAAS,EAAE,6BAA6B;EACxC,UAAU,EAAE,EAAE;CACf,CAAC;AAEF,MAAM,cAAc;EAIlB,YAAY,IAAI;IACd,IAAI,CAAC,YAAY,CAAC,GAAG,IAAI,CAAC,YAAY,CAAC,IAAI,EAAE,CAAC;IAC9C,IAAI,CAAC,YAAY,CAAC,GAAG,IAAI,CAAC,YAAY,CAAC,IAAI,EAAE,CAAC;EAChD,CAAC;CACF;AAED,MAAM,QAAQ,GAAG,CAAC,IAAoB,EAAE,EAAE;EACxC,OAAO,CAAC;;oBAEU,IAAI,CAAC,YAAY,CAAC;oBAClB,IAAI,CAAC,YAAY,CAAC;;GAEnC,CAAC,CAAA;AACJ,CAAC,CAAA;AAED,MAAM,CAAC,MAAM,KAAK,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;AACvC,KAAK,CAAC,IAAI,GAAG,IAAI,cAAc,CAAC,EAAE,CAAC,CAAC","sourcesContent":["export default {\n title: 'dev/Components/GrossPaymentChart',\n component: 'justifi-gross-payment-chart',\n parameters: {}\n};\n\nclass GrossChartArgs {\n 'auth-token': string;\n 'account-id': string;\n\n constructor(args) {\n this['auth-token'] = args['auth-token'] || '';\n this['account-id'] = args['account-id'] || '';\n }\n}\n\nconst Template = (args: GrossChartArgs) => {\n return (`\n <justifi-gross-payment-chart \n auth-token=\"${args['auth-token']}\"\n account-id=\"${args['account-id']}\"\n />\n `)\n}\n\nexport const Basic = Template.bind({});\nBasic.args = new GrossChartArgs({});\n"]}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { newSpecPage } from "@stencil/core/testing";
|
|
2
|
+
import { GrossPaymentChart } from "../gross-payment-chart";
|
|
3
|
+
describe('gross-payment-chart', () => {
|
|
4
|
+
it('renders', async () => {
|
|
5
|
+
const page = await newSpecPage({
|
|
6
|
+
components: [GrossPaymentChart],
|
|
7
|
+
html: `<gross-payment-chart></gross-payment-chart>`,
|
|
8
|
+
});
|
|
9
|
+
expect(page.root).toEqualHtml(`
|
|
10
|
+
<gross-payment-chart>
|
|
11
|
+
</gross-payment-chart>
|
|
12
|
+
`);
|
|
13
|
+
});
|
|
14
|
+
});
|
|
15
|
+
//# sourceMappingURL=gross-payment-chart.spec.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"gross-payment-chart.spec.js","sourceRoot":"","sources":["../../../../../src/components/gross-payment-chart/test/gross-payment-chart.spec.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACpD,OAAO,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAE3D,QAAQ,CAAC,qBAAqB,EAAE,GAAG,EAAE;EACnC,EAAE,CAAC,SAAS,EAAE,KAAK,IAAI,EAAE;IACvB,MAAM,IAAI,GAAG,MAAM,WAAW,CAAC;MAC7B,UAAU,EAAE,CAAC,iBAAiB,CAAC;MAC/B,IAAI,EAAE,6CAA6C;KACpD,CAAC,CAAC;IACH,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,WAAW,CAAC;;;KAG7B,CAAC,CAAC;EACL,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC","sourcesContent":["import { newSpecPage } from '@stencil/core/testing';\nimport { GrossPaymentChart } from '../gross-payment-chart';\n\ndescribe('gross-payment-chart', () => {\n it('renders', async () => {\n const page = await newSpecPage({\n components: [GrossPaymentChart],\n html: `<gross-payment-chart></gross-payment-chart>`,\n });\n expect(page.root).toEqualHtml(`\n <gross-payment-chart>\n </gross-payment-chart>\n `);\n });\n});\n"]}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import { Host, h } from "@stencil/core";
|
|
2
|
+
import { ExtendedPagingDefaults } from "../../api/Pagination";
|
|
3
|
+
export class PaginationMenu {
|
|
4
|
+
constructor() {
|
|
5
|
+
this.paging = ExtendedPagingDefaults;
|
|
6
|
+
this.params = {};
|
|
7
|
+
}
|
|
8
|
+
render() {
|
|
9
|
+
return (h(Host, null, h("nav", { "aria-label": "Table pagination", class: "d-flex justify-content-end gap-3" }, h("ul", { class: "pagination m-0" }, h("li", { onClick: (e) => {
|
|
10
|
+
e.preventDefault();
|
|
11
|
+
this.paging.handleClickPrevious(this.paging.start_cursor);
|
|
12
|
+
}, part: `previous-button${this.paging.has_previous ? '' : ' button-disabled'}`, class: `page-item ${this.paging.has_previous ? '' : ' disabled'}` }, h("a", { href: "#", class: "page-link" }, h("span", { class: "me-1", part: "arrow arrow-left" }, "\u00AB"), h("span", { part: "previous-button-text" }, "Previous"))), h("li", { onClick: (e) => {
|
|
13
|
+
e.preventDefault();
|
|
14
|
+
this.paging.handleClickNext(this.paging.end_cursor);
|
|
15
|
+
}, part: `${this.paging.has_next ? '' : ' button-disabled'}`, class: `page-item ${this.paging.has_next ? '' : ' disabled'}` }, h("a", { href: "#", class: "page-link" }, h("span", { part: "next-button-text" }, "Next"), h("span", { class: "ms-1", part: "arrow arrow-right" }, "\u00BB")))))));
|
|
16
|
+
}
|
|
17
|
+
static get is() { return "pagination-menu"; }
|
|
18
|
+
static get encapsulation() { return "shadow"; }
|
|
19
|
+
static get originalStyleUrls() {
|
|
20
|
+
return {
|
|
21
|
+
"$": ["../table/table.scss"]
|
|
22
|
+
};
|
|
23
|
+
}
|
|
24
|
+
static get styleUrls() {
|
|
25
|
+
return {
|
|
26
|
+
"$": ["../table/table.css"]
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
static get properties() {
|
|
30
|
+
return {
|
|
31
|
+
"paging": {
|
|
32
|
+
"type": "unknown",
|
|
33
|
+
"mutable": false,
|
|
34
|
+
"complexType": {
|
|
35
|
+
"original": "PaginationProps['paging']",
|
|
36
|
+
"resolved": "ExtendedPagingInfo",
|
|
37
|
+
"references": {
|
|
38
|
+
"PaginationProps": {
|
|
39
|
+
"location": "local",
|
|
40
|
+
"path": "/home/runner/work/web-component-library/web-component-library/stencil-library/src/components/pagination-menu/pagination-menu.tsx",
|
|
41
|
+
"id": "src/components/pagination-menu/pagination-menu.tsx::PaginationProps"
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
},
|
|
45
|
+
"required": false,
|
|
46
|
+
"optional": false,
|
|
47
|
+
"docs": {
|
|
48
|
+
"tags": [],
|
|
49
|
+
"text": ""
|
|
50
|
+
},
|
|
51
|
+
"defaultValue": "ExtendedPagingDefaults"
|
|
52
|
+
},
|
|
53
|
+
"params": {
|
|
54
|
+
"type": "unknown",
|
|
55
|
+
"mutable": false,
|
|
56
|
+
"complexType": {
|
|
57
|
+
"original": "PaginationProps['params']",
|
|
58
|
+
"resolved": "{}",
|
|
59
|
+
"references": {
|
|
60
|
+
"PaginationProps": {
|
|
61
|
+
"location": "local",
|
|
62
|
+
"path": "/home/runner/work/web-component-library/web-component-library/stencil-library/src/components/pagination-menu/pagination-menu.tsx",
|
|
63
|
+
"id": "src/components/pagination-menu/pagination-menu.tsx::PaginationProps"
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
},
|
|
67
|
+
"required": false,
|
|
68
|
+
"optional": false,
|
|
69
|
+
"docs": {
|
|
70
|
+
"tags": [],
|
|
71
|
+
"text": ""
|
|
72
|
+
},
|
|
73
|
+
"defaultValue": "{}"
|
|
74
|
+
}
|
|
75
|
+
};
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
//# sourceMappingURL=pagination-menu.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pagination-menu.js","sourceRoot":"","sources":["../../../../src/components/pagination-menu/pagination-menu.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,eAAe,CAAC;AACzD,OAAO,EAAE,sBAAsB,EAAsB,MAAM,sBAAsB,CAAC;AAalF,MAAM,OAAO,cAAc;;kBACmB,sBAAsB;kBACtB,EAAE;;EAE9C,MAAM;IACJ,OAAO,CACL,EAAC,IAAI;MACH,yBAAgB,kBAAkB,EAAC,KAAK,EAAC,kCAAkC;QACzE,UAAI,KAAK,EAAC,gBAAgB;UACxB,UACE,OAAO,EAAE,CAAC,CAAC,EAAE,EAAE;cACb,CAAC,CAAC,cAAc,EAAE,CAAC;cACnB,IAAI,CAAC,MAAM,CAAC,mBAAmB,CAAC,IAAI,CAAC,MAAM,CAAC,YAAY,CAAC,CAAC;YAC5D,CAAC,EACD,IAAI,EAAE,kBAAkB,IAAI,CAAC,MAAM,CAAC,YAAY,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,kBAAkB,EAAE,EAC5E,KAAK,EAAE,aAAa,IAAI,CAAC,MAAM,CAAC,YAAY,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,WAAW,EAAE;YAEjE,SAAG,IAAI,EAAC,GAAG,EAAC,KAAK,EAAC,WAAW;cAC3B,YAAM,KAAK,EAAC,MAAM,EAAC,IAAI,EAAC,kBAAkB,aAAe;cACzD,YAAM,IAAI,EAAC,sBAAsB,eAAgB,CAC/C,CACD;UACL,UACE,OAAO,EAAE,CAAC,CAAC,EAAE,EAAE;cACb,CAAC,CAAC,cAAc,EAAE,CAAC;cACnB,IAAI,CAAC,MAAM,CAAC,eAAe,CAAC,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC;YACtD,CAAC,EACD,IAAI,EAAE,GAAG,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,kBAAkB,EAAE,EACzD,KAAK,EAAE,aAAa,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,WAAW,EAAE;YAE7D,SAAG,IAAI,EAAC,GAAG,EAAC,KAAK,EAAC,WAAW;cAC3B,YAAM,IAAI,EAAC,kBAAkB,WAAY;cACzC,YAAM,KAAK,EAAC,MAAM,EAAC,IAAI,EAAC,mBAAmB,aAAe,CACxD,CACD,CACF,CACD,CACD,CACR,CAAC;EACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Host, h, Prop } from '@stencil/core';\nimport { ExtendedPagingDefaults, ExtendedPagingInfo } from '../../api/Pagination';\n\nexport interface PaginationProps {\n paging: ExtendedPagingInfo;\n params?: {};\n}\n\n@Component({\n tag: 'pagination-menu',\n styleUrl: '../table/table.scss',\n shadow: true,\n})\n\nexport class PaginationMenu {\n @Prop() paging: PaginationProps['paging'] = ExtendedPagingDefaults;\n @Prop() params: PaginationProps['params'] = {};\n\n render() {\n return (\n <Host>\n <nav aria-label=\"Table pagination\" class=\"d-flex justify-content-end gap-3\">\n <ul class=\"pagination m-0\">\n <li\n onClick={(e) => {\n e.preventDefault();\n this.paging.handleClickPrevious(this.paging.start_cursor);\n }}\n part={`previous-button${this.paging.has_previous ? '' : ' button-disabled'}`}\n class={`page-item ${this.paging.has_previous ? '' : ' disabled'}`}\n >\n <a href=\"#\" class=\"page-link\">\n <span class=\"me-1\" part=\"arrow arrow-left\">«</span>\n <span part=\"previous-button-text\">Previous</span>\n </a>\n </li>\n <li\n onClick={(e) => {\n e.preventDefault();\n this.paging.handleClickNext(this.paging.end_cursor);\n }}\n part={`${this.paging.has_next ? '' : ' button-disabled'}`}\n class={`page-item ${this.paging.has_next ? '' : ' disabled'}`}\n >\n <a href=\"#\" class=\"page-link\">\n <span part=\"next-button-text\">Next</span>\n <span class=\"ms-1\" part=\"arrow arrow-right\">»</span>\n </a>\n </li>\n </ul>\n </nav>\n </Host>\n );\n }\n}\n"]}
|
package/dist/collection/components/payment-balance-transactions/payment-balance-transactions.css
ADDED
|
File without changes
|
package/dist/collection/components/payment-balance-transactions/payment-balance-transactions.js
ADDED
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
import { Host, h } from "@stencil/core";
|
|
2
|
+
import { Api, PaymentBalanceTransaction, pagingDefaults, } from "../../api";
|
|
3
|
+
import { formatCurrency, formatDate, formatTime, snakeCaseToHumanReadable, } from "../../utils/utils";
|
|
4
|
+
export class PaymentBalanceTransactions {
|
|
5
|
+
constructor() {
|
|
6
|
+
this.handleClickPrevious = (beforeCursor) => {
|
|
7
|
+
const newParams = Object.assign({}, this.params);
|
|
8
|
+
delete newParams.after_cursor;
|
|
9
|
+
this.params = (Object.assign(Object.assign({}, newParams), { before_cursor: beforeCursor }));
|
|
10
|
+
};
|
|
11
|
+
this.handleClickNext = (afterCursor) => {
|
|
12
|
+
const newParams = Object.assign({}, this.params);
|
|
13
|
+
delete newParams.before_cursor;
|
|
14
|
+
this.params = (Object.assign(Object.assign({}, newParams), { after_cursor: afterCursor }));
|
|
15
|
+
};
|
|
16
|
+
this.accountId = undefined;
|
|
17
|
+
this.authToken = undefined;
|
|
18
|
+
this.paymentId = undefined;
|
|
19
|
+
this.balanceTransactions = [];
|
|
20
|
+
this.loading = true;
|
|
21
|
+
this.errorMessage = undefined;
|
|
22
|
+
this.paging = pagingDefaults;
|
|
23
|
+
this.params = undefined;
|
|
24
|
+
}
|
|
25
|
+
updateOnPropChange() {
|
|
26
|
+
this.fetchData();
|
|
27
|
+
}
|
|
28
|
+
connectedCallback() {
|
|
29
|
+
this.fetchData();
|
|
30
|
+
}
|
|
31
|
+
async fetchData() {
|
|
32
|
+
this.loading = true;
|
|
33
|
+
if (!this.accountId || !this.paymentId) {
|
|
34
|
+
this.errorMessage = 'Missing required props: accountId or paymentId';
|
|
35
|
+
this.loading = false;
|
|
36
|
+
return;
|
|
37
|
+
}
|
|
38
|
+
const endpoint = `account/${this.accountId}/payments/${this.paymentId}/payment_balance_transactions`;
|
|
39
|
+
const response = await Api(this.authToken).get(endpoint, this.params);
|
|
40
|
+
if (!response.error) {
|
|
41
|
+
this.paging = Object.assign(Object.assign({}, this.paging), response.page_info);
|
|
42
|
+
this.balanceTransactions = response.data.map(dataItem => new PaymentBalanceTransaction(dataItem));
|
|
43
|
+
}
|
|
44
|
+
else {
|
|
45
|
+
this.errorMessage =
|
|
46
|
+
typeof response.error === 'string'
|
|
47
|
+
? response.error
|
|
48
|
+
: response.error.message;
|
|
49
|
+
}
|
|
50
|
+
this.loading = false;
|
|
51
|
+
}
|
|
52
|
+
render() {
|
|
53
|
+
return (h(Host, null, h("justifi-table", { columnData: [
|
|
54
|
+
['Processed On', 'The date each transaction occurred'],
|
|
55
|
+
['Type', 'The type of each transaction'],
|
|
56
|
+
['ID', 'The unique identifier of each transaction'],
|
|
57
|
+
['Amout', 'The dollar amount of each transaction'],
|
|
58
|
+
[
|
|
59
|
+
'Balance',
|
|
60
|
+
'The running total amount of this payment that belongs to you',
|
|
61
|
+
],
|
|
62
|
+
], entityId: this.balanceTransactions.map(transaction => transaction.id), rowData: this.balanceTransactions.map(balanceTransaction => [
|
|
63
|
+
h("div", null, h("div", null, formatDate(balanceTransaction.created_at)), h("div", null, formatTime(balanceTransaction.created_at))),
|
|
64
|
+
snakeCaseToHumanReadable(balanceTransaction.payment_balance_txn_type),
|
|
65
|
+
balanceTransaction.payment_id,
|
|
66
|
+
formatCurrency(balanceTransaction.amount),
|
|
67
|
+
formatCurrency(balanceTransaction.balance),
|
|
68
|
+
]), loading: this.loading, "error-message": this.errorMessage, params: this.params, paging: Object.assign(Object.assign({}, this.paging), { handleClickNext: this.handleClickNext, handleClickPrevious: this.handleClickPrevious }) })));
|
|
69
|
+
}
|
|
70
|
+
static get is() { return "justifi-payment-balance-transactions"; }
|
|
71
|
+
static get encapsulation() { return "shadow"; }
|
|
72
|
+
static get originalStyleUrls() {
|
|
73
|
+
return {
|
|
74
|
+
"$": ["payment-balance-transactions.scss"]
|
|
75
|
+
};
|
|
76
|
+
}
|
|
77
|
+
static get styleUrls() {
|
|
78
|
+
return {
|
|
79
|
+
"$": ["payment-balance-transactions.css"]
|
|
80
|
+
};
|
|
81
|
+
}
|
|
82
|
+
static get properties() {
|
|
83
|
+
return {
|
|
84
|
+
"accountId": {
|
|
85
|
+
"type": "string",
|
|
86
|
+
"mutable": false,
|
|
87
|
+
"complexType": {
|
|
88
|
+
"original": "string",
|
|
89
|
+
"resolved": "string",
|
|
90
|
+
"references": {}
|
|
91
|
+
},
|
|
92
|
+
"required": false,
|
|
93
|
+
"optional": false,
|
|
94
|
+
"docs": {
|
|
95
|
+
"tags": [],
|
|
96
|
+
"text": ""
|
|
97
|
+
},
|
|
98
|
+
"attribute": "account-id",
|
|
99
|
+
"reflect": false
|
|
100
|
+
},
|
|
101
|
+
"authToken": {
|
|
102
|
+
"type": "string",
|
|
103
|
+
"mutable": false,
|
|
104
|
+
"complexType": {
|
|
105
|
+
"original": "string",
|
|
106
|
+
"resolved": "string",
|
|
107
|
+
"references": {}
|
|
108
|
+
},
|
|
109
|
+
"required": false,
|
|
110
|
+
"optional": false,
|
|
111
|
+
"docs": {
|
|
112
|
+
"tags": [],
|
|
113
|
+
"text": ""
|
|
114
|
+
},
|
|
115
|
+
"attribute": "auth-token",
|
|
116
|
+
"reflect": false
|
|
117
|
+
},
|
|
118
|
+
"paymentId": {
|
|
119
|
+
"type": "string",
|
|
120
|
+
"mutable": false,
|
|
121
|
+
"complexType": {
|
|
122
|
+
"original": "string",
|
|
123
|
+
"resolved": "string",
|
|
124
|
+
"references": {}
|
|
125
|
+
},
|
|
126
|
+
"required": false,
|
|
127
|
+
"optional": false,
|
|
128
|
+
"docs": {
|
|
129
|
+
"tags": [],
|
|
130
|
+
"text": ""
|
|
131
|
+
},
|
|
132
|
+
"attribute": "payment-id",
|
|
133
|
+
"reflect": false
|
|
134
|
+
}
|
|
135
|
+
};
|
|
136
|
+
}
|
|
137
|
+
static get states() {
|
|
138
|
+
return {
|
|
139
|
+
"balanceTransactions": {},
|
|
140
|
+
"loading": {},
|
|
141
|
+
"errorMessage": {},
|
|
142
|
+
"paging": {},
|
|
143
|
+
"params": {}
|
|
144
|
+
};
|
|
145
|
+
}
|
|
146
|
+
static get watchers() {
|
|
147
|
+
return [{
|
|
148
|
+
"propName": "params",
|
|
149
|
+
"methodName": "updateOnPropChange"
|
|
150
|
+
}];
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
//# sourceMappingURL=payment-balance-transactions.js.map
|
package/dist/collection/components/payment-balance-transactions/payment-balance-transactions.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"payment-balance-transactions.js","sourceRoot":"","sources":["../../../../src/components/payment-balance-transactions/payment-balance-transactions.tsx"],"names":[],"mappings":"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","sourcesContent":["import { Component, Host, h, Prop, State, Watch } from '@stencil/core';\nimport {\n Api,\n IApiResponseCollection,\n IPaymentBalanceTransaction,\n PagingInfo,\n PaymentBalanceTransaction,\n pagingDefaults,\n} from '../../api';\n\nimport {\n formatCurrency,\n formatDate,\n formatTime,\n snakeCaseToHumanReadable,\n} from '../../utils/utils';\n\n@Component({\n tag: 'justifi-payment-balance-transactions',\n styleUrl: 'payment-balance-transactions.scss',\n shadow: true,\n})\nexport class PaymentBalanceTransactions {\n @Prop() accountId: string;\n @Prop() authToken: string;\n @Prop() paymentId: string;\n @State() balanceTransactions: IPaymentBalanceTransaction[] = [];\n @State() loading: boolean = true;\n @State() errorMessage: string;\n @State() paging: PagingInfo = pagingDefaults;\n @State() params: any\n\n @Watch('params')\n updateOnPropChange() {\n this.fetchData();\n }\n\n connectedCallback() {\n this.fetchData();\n }\n\n handleClickPrevious = (beforeCursor: string) => {\n const newParams: any = { ...this.params };\n delete newParams.after_cursor;\n this.params = ({ ...newParams, before_cursor: beforeCursor });\n };\n\n handleClickNext = (afterCursor: string) => {\n const newParams: any = { ...this.params };\n delete newParams.before_cursor;\n this.params = ({ ...newParams, after_cursor: afterCursor });\n }; \n\n async fetchData(): Promise<void> {\n this.loading = true;\n\n if (!this.accountId || !this.paymentId) {\n this.errorMessage = 'Missing required props: accountId or paymentId';\n this.loading = false;\n return;\n }\n const endpoint = `account/${this.accountId}/payments/${this.paymentId}/payment_balance_transactions`;\n\n const response: IApiResponseCollection<IPaymentBalanceTransaction[]> =\n await Api(this.authToken).get(endpoint, this.params);\n\n if (!response.error) {\n this.paging = {\n ...this.paging,\n ...response.page_info,\n };\n this.balanceTransactions = response.data.map(\n dataItem => new PaymentBalanceTransaction(dataItem),\n );\n } else {\n this.errorMessage =\n typeof response.error === 'string'\n ? response.error\n : response.error.message;\n }\n this.loading = false;\n }\n\n render() {\n return (\n <Host>\n <justifi-table\n columnData={[\n ['Processed On', 'The date each transaction occurred'],\n ['Type', 'The type of each transaction'],\n ['ID', 'The unique identifier of each transaction'],\n ['Amout', 'The dollar amount of each transaction'],\n [\n 'Balance',\n 'The running total amount of this payment that belongs to you',\n ],\n ]}\n entityId={this.balanceTransactions.map(transaction => transaction.id)}\n rowData={this.balanceTransactions.map(balanceTransaction => [\n <div>\n <div>{formatDate(balanceTransaction.created_at)}</div>\n <div>{formatTime(balanceTransaction.created_at)}</div>\n </div>,\n snakeCaseToHumanReadable(\n balanceTransaction.payment_balance_txn_type,\n ),\n balanceTransaction.payment_id,\n formatCurrency(balanceTransaction.amount),\n formatCurrency(balanceTransaction.balance),\n ])}\n loading={this.loading}\n error-message={this.errorMessage}\n params={this.params}\n paging={{\n ...this.paging,\n handleClickNext: this.handleClickNext,\n handleClickPrevious: this.handleClickPrevious\n }}\n />\n </Host>\n );\n }\n}\n"]}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
export default {
|
|
2
|
+
title: 'Components/PaymentBalanceTransactions',
|
|
3
|
+
component: 'justifi-payment-balance-transactions',
|
|
4
|
+
parameters: {},
|
|
5
|
+
};
|
|
6
|
+
class PaymentBalanceTransactionsArgs {
|
|
7
|
+
constructor(args) {
|
|
8
|
+
this['auth-token'] = args['auth-token'] || '';
|
|
9
|
+
this['payment-id'] = args['payment-id'] || '';
|
|
10
|
+
this['account-id'] = args['account-id'] || '';
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
const Template = (args) => {
|
|
14
|
+
return `
|
|
15
|
+
<justifi-payment-balance-transactions
|
|
16
|
+
data-testid="justifi-payment-balance-transactions"
|
|
17
|
+
auth-token="${args['auth-token']}"
|
|
18
|
+
payment-id="${args['payment-id']}"
|
|
19
|
+
account-id="${args['account-id']}"
|
|
20
|
+
/>
|
|
21
|
+
`;
|
|
22
|
+
};
|
|
23
|
+
export const Basic = Template.bind({});
|
|
24
|
+
Basic.args = new PaymentBalanceTransactionsArgs({});
|
|
25
|
+
export const Styled = Template.bind({});
|
|
26
|
+
Styled.args = new PaymentBalanceTransactionsArgs({});
|
|
27
|
+
Styled.decorators = [
|
|
28
|
+
Story => `
|
|
29
|
+
${Story()}
|
|
30
|
+
`,
|
|
31
|
+
];
|
|
32
|
+
//# sourceMappingURL=payment-balance-transactions.stories.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"payment-balance-transactions.stories.js","sourceRoot":"","sources":["../../../../src/components/payment-balance-transactions/payment-balance-transactions.stories.ts"],"names":[],"mappings":"AAAA,eAAe;EACb,KAAK,EAAE,uCAAuC;EAC9C,SAAS,EAAE,sCAAsC;EACjD,UAAU,EAAE,EAAE;CACf,CAAC;AAEF,MAAM,8BAA8B;EAKlC,YAAc,IAAI;IAChB,IAAI,CAAC,YAAY,CAAC,GAAG,IAAI,CAAC,YAAY,CAAC,IAAI,EAAE,CAAC;IAC9C,IAAI,CAAC,YAAY,CAAC,GAAG,IAAI,CAAC,YAAY,CAAC,IAAI,EAAE,CAAC;IAC9C,IAAI,CAAC,YAAY,CAAC,GAAG,IAAI,CAAC,YAAY,CAAC,IAAI,EAAE,CAAC;EAChD,CAAC;CACF;AAED,MAAM,QAAQ,GAAG,CAAC,IAAoC,EAAE,EAAE;EACxD,OAAO;;;oBAGW,IAAI,CAAC,YAAY,CAAC;oBAClB,IAAI,CAAC,YAAY,CAAC;oBAClB,IAAI,CAAC,YAAY,CAAC;;GAEnC,CAAC;AACJ,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,KAAK,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;AACvC,KAAK,CAAC,IAAI,GAAG,IAAI,8BAA8B,CAAC,EAAE,CAAC,CAAC;AAEpD,MAAM,CAAC,MAAM,MAAM,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;AACxC,MAAM,CAAC,IAAI,GAAG,IAAI,8BAA8B,CAAC,EAAE,CAAC,CAAC;AACrD,MAAM,CAAC,UAAU,GAAG;EAClB,KAAK,CAAC,EAAE,CAAC;MACL,KAAK,EAAE;GACV;CACF,CAAC","sourcesContent":["export default {\n title: 'Components/PaymentBalanceTransactions',\n component: 'justifi-payment-balance-transactions',\n parameters: {},\n};\n\nclass PaymentBalanceTransactionsArgs {\n 'auth-token': string;\n 'payment-id': string;\n 'account-id': string;\n\n 'constructor'(args) {\n this['auth-token'] = args['auth-token'] || '';\n this['payment-id'] = args['payment-id'] || '';\n this['account-id'] = args['account-id'] || '';\n }\n}\n\nconst Template = (args: PaymentBalanceTransactionsArgs) => {\n return `\n <justifi-payment-balance-transactions\n data-testid=\"justifi-payment-balance-transactions\"\n auth-token=\"${args['auth-token']}\"\n payment-id=\"${args['payment-id']}\"\n account-id=\"${args['account-id']}\"\n />\n `;\n};\n\nexport const Basic = Template.bind({});\nBasic.args = new PaymentBalanceTransactionsArgs({});\n\nexport const Styled = Template.bind({});\nStyled.args = new PaymentBalanceTransactionsArgs({});\nStyled.decorators = [\n Story => `\n ${Story()}\n `,\n];\n"]}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Host, h } from "@stencil/core";
|
|
2
2
|
import { Api } from "../../api";
|
|
3
3
|
import { MapPaymentStatusToBadge, formatCurrency, formatDate, formatTime } from "../../utils/utils";
|
|
4
|
-
import { DetailItem, EntityHeadInfo, EntityHeadInfoItem, ErrorState, LoadingState } from "../details/utils";
|
|
5
|
-
import {
|
|
4
|
+
import { CodeBlock, DetailItem, DetailSection, EntityHeadInfo, EntityHeadInfoItem, ErrorState, LoadingState } from "../details/utils";
|
|
5
|
+
import { config } from "../../../config";
|
|
6
6
|
/**
|
|
7
7
|
* @exportedPart detail-loading-spinner
|
|
8
8
|
* @exportedPart detail-loading-state
|
|
@@ -18,6 +18,14 @@ import { DetailSection } from "../details/utils";
|
|
|
18
18
|
* @exportedPart detail-metadata-title
|
|
19
19
|
* @exportedPart detail-method-title
|
|
20
20
|
* @exportedPart detail-method-data
|
|
21
|
+
* @exportedPart detail-section
|
|
22
|
+
* @exportedPart detail-section-title
|
|
23
|
+
* @exportedPart detail-section-item-title
|
|
24
|
+
* @exportedPart detail-section-item-data
|
|
25
|
+
* @exportedPart detail-head-info
|
|
26
|
+
* @exportedPart detail-head-info-item
|
|
27
|
+
* @exportedPart detail-head-info-item-title
|
|
28
|
+
* @exportedPart detail-head-info-item-data
|
|
21
29
|
*/
|
|
22
30
|
export class PaymentDetails {
|
|
23
31
|
constructor() {
|
|
@@ -42,7 +50,7 @@ export class PaymentDetails {
|
|
|
42
50
|
}
|
|
43
51
|
this.loading = true;
|
|
44
52
|
const endpoint = `payments/${this.paymentId}`;
|
|
45
|
-
const response = await Api(this.authToken).get(endpoint);
|
|
53
|
+
const response = await Api(this.authToken, config.proxyApiOrigin).get(endpoint);
|
|
46
54
|
if (!response.error) {
|
|
47
55
|
this.payment = response.data;
|
|
48
56
|
}
|
|
@@ -55,9 +63,7 @@ export class PaymentDetails {
|
|
|
55
63
|
var _a;
|
|
56
64
|
return (h(Host, null, this.loading ? LoadingState :
|
|
57
65
|
!this.payment ? ErrorState(this.errorMessage) :
|
|
58
|
-
h("justifi-details", { "error-message": this.errorMessage,
|
|
59
|
-
metadata: this.payment.metadata
|
|
60
|
-
} }, h(EntityHeadInfo, { slot: "head-info", badge: h("span", { slot: 'badge', innerHTML: MapPaymentStatusToBadge((_a = this.payment) === null || _a === void 0 ? void 0 : _a.status) }), title: `${formatCurrency(this.payment.amount)} ${this.payment.currency.toUpperCase()}` }, h(EntityHeadInfoItem, { classes: "border-1 border-end", title: "Updated At", value: `${formatDate(this.payment.updated_at)} ${formatTime(this.payment.updated_at)}` }), h(EntityHeadInfoItem, { classes: "border-1 border-end", title: "Created At", value: `${formatDate(this.payment.created_at)} ${formatTime(this.payment.created_at)}` }), h(EntityHeadInfoItem, { title: "ID", value: this.payment.id })), h("div", { slot: 'detail-sections' }, h(DetailSection, { sectionTitle: "Details" }, h(DetailItem, { title: "Amount", value: formatCurrency(this.payment.amount) }), h(DetailItem, { title: "Fees", value: formatCurrency(this.payment.fee_amount) }), h(DetailItem, { title: "Refunded", value: formatCurrency(this.payment.amount_refunded) }), h(DetailItem, { title: "Net", value: formatCurrency(this.payment.balance) }), h(DetailItem, { title: "Status", value: MapPaymentStatusToBadge(this.payment.status) }), h(DetailItem, { title: "Payment ID", value: this.payment.id }), h(DetailItem, { title: "Processing Fees", value: formatCurrency(this.payment.fee_amount) }), h(DetailItem, { title: "Statement Descriptor", value: this.payment.statement_descriptor }), h(DetailItem, { title: "Description", value: this.payment.description })), h(DetailSection, { sectionTitle: "Payment Method" }, h(DetailItem, { title: "ID", value: this.payment.payment_method.card.id }), h(DetailItem, { title: "Payment Type", value: "Card" }), h(DetailItem, { title: "Last 4 Numbers", value: this.payment.payment_method.card.acct_last_four }), h(DetailItem, { title: "Brand", value: this.payment.payment_method.card.brand }), h(DetailItem, { title: "Cardholder", value: this.payment.payment_method.card.name }))))));
|
|
66
|
+
h("justifi-details", { "error-message": this.errorMessage }, h(EntityHeadInfo, { slot: "head-info", badge: h("span", { slot: 'badge', innerHTML: MapPaymentStatusToBadge((_a = this.payment) === null || _a === void 0 ? void 0 : _a.status) }), title: `${formatCurrency(this.payment.amount)} ${this.payment.currency.toUpperCase()}` }, h(EntityHeadInfoItem, { classes: "border-1 border-end", title: "Updated At", value: `${formatDate(this.payment.updated_at)} ${formatTime(this.payment.updated_at)}` }), h(EntityHeadInfoItem, { classes: "border-1 border-end", title: "Created At", value: `${formatDate(this.payment.created_at)} ${formatTime(this.payment.created_at)}` }), h(EntityHeadInfoItem, { title: "ID", value: this.payment.id })), h("div", { slot: 'detail-sections' }, h(DetailSection, { sectionTitle: "Details" }, h(DetailItem, { title: "Amount", value: formatCurrency(this.payment.amount) }), h(DetailItem, { title: "Fees", value: formatCurrency(this.payment.fee_amount) }), h(DetailItem, { title: "Refunded", value: formatCurrency(this.payment.amount_refunded) }), h(DetailItem, { title: "Net", value: formatCurrency(this.payment.balance) }), h(DetailItem, { title: "Status", value: MapPaymentStatusToBadge(this.payment.status) }), h(DetailItem, { title: "Payment ID", value: this.payment.id }), h(DetailItem, { title: "Processing Fees", value: formatCurrency(this.payment.fee_amount) }), h(DetailItem, { title: "Statement Descriptor", value: this.payment.statement_descriptor }), h(DetailItem, { title: "Description", value: this.payment.description })), h(DetailSection, { sectionTitle: "Payment Method" }, h(DetailItem, { title: "ID", value: this.payment.payment_method.card.id }), h(DetailItem, { title: "Payment Type", value: "Card" }), h(DetailItem, { title: "Last 4 Numbers", value: this.payment.payment_method.card.acct_last_four }), h(DetailItem, { title: "Brand", value: this.payment.payment_method.card.brand }), h(DetailItem, { title: "Cardholder", value: this.payment.payment_method.card.name })), h(DetailSection, { sectionTitle: 'Metadata' }, h(CodeBlock, { metadata: this.payment.metadata }))))));
|
|
61
67
|
}
|
|
62
68
|
static get is() { return "justifi-payment-details"; }
|
|
63
69
|
static get encapsulation() { return "shadow"; }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"payment-details.js","sourceRoot":"","sources":["../../../../src/components/payment-details/payment-details.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACvE,OAAO,EAAE,GAAG,EAAmC,MAAM,WAAW,CAAC;AACjE,OAAO,EAAE,uBAAuB,EAAE,cAAc,EAAE,UAAU,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AACpG,OAAO,EAAE,UAAU,EAAE,cAAc,EAAE,kBAAkB,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;
|
|
1
|
+
{"version":3,"file":"payment-details.js","sourceRoot":"","sources":["../../../../src/components/payment-details/payment-details.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACvE,OAAO,EAAE,GAAG,EAAmC,MAAM,WAAW,CAAC;AACjE,OAAO,EAAE,uBAAuB,EAAE,cAAc,EAAE,UAAU,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AACpG,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,aAAa,EAAE,cAAc,EAAE,kBAAkB,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AACtI,OAAO,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AAEzC;;;;;;;;;;;;;;;;;;;;;;;EAuBE;AAOF,MAAM,OAAO,cAAc;;;;;mBAIG,IAAI;;;EAKhC,kBAAkB;IAChB,IAAI,CAAC,SAAS,EAAE,CAAC;EACnB,CAAC;EAED,iBAAiB;IACf,IAAI,CAAC,SAAS,EAAE,CAAC;EACnB,CAAC;EAED,KAAK,CAAC,SAAS;IACb,IAAI,CAAC,YAAY,GAAG,EAAE,CAAC;IACvB,IAAI,CAAC,IAAI,CAAC,SAAS,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE;MACtC,IAAI,CAAC,YAAY,GAAG,6DAA6D,CAAC;MAClF,IAAI,CAAC,OAAO,GAAG,KAAK,CAAC;MACrB,OAAO;KACR;IACD,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC;IACpB,MAAM,QAAQ,GAAG,YAAY,IAAI,CAAC,SAAS,EAAE,CAAC;IAE9C,MAAM,QAAQ,GAAoC,MAAM,GAAG,CAAC,IAAI,CAAC,SAAS,EAAE,MAAM,CAAC,cAAc,CAAC,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;IACjH,IAAI,CAAC,QAAQ,CAAC,KAAK,EAAE;MACnB,IAAI,CAAC,OAAO,GAAG,QAAQ,CAAC,IAAI,CAAC;KAC9B;SAAM;MACL,IAAI,CAAC,YAAY,GAAG,OAAO,QAAQ,CAAC,KAAK,KAAK,QAAQ,CAAC,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,OAAO,CAAC;KAClG;IAED,IAAI,CAAC,OAAO,GAAG,KAAK,CAAC;EACvB,CAAC;EAED,MAAM;;IACJ,OAAO,CACL,EAAC,IAAI,QAED,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC;MAC3B,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,UAAU,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC,CAAC;QAC7C,wCAAgC,IAAI,CAAC,YAAY;UAC/C,EAAC,cAAc,IAAC,IAAI,EAAC,WAAW,EAAC,KAAK,EAAE,YAAM,IAAI,EAAC,OAAO,EAAC,SAAS,EAAE,uBAAuB,CAAC,MAAA,IAAI,CAAC,OAAO,0CAAE,MAAM,CAAC,GAAI,EAAE,KAAK,EAAE,GAAG,cAAc,CAAC,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,IAAI,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC,WAAW,EAAE,EAAE;YAC7M,EAAC,kBAAkB,IACjB,OAAO,EAAC,qBAAqB,EAC7B,KAAK,EAAC,YAAY,EAClB,KAAK,EAAE,GAAG,UAAU,CAAC,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,UAAU,CAAC,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,EAAE,GACtF;YACF,EAAC,kBAAkB,IACjB,OAAO,EAAC,qBAAqB,EAC7B,KAAK,EAAC,YAAY,EAClB,KAAK,EAAE,GAAG,UAAU,CAAC,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,UAAU,CAAC,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,EAAE,GACtF;YACF,EAAC,kBAAkB,IAAC,KAAK,EAAC,IAAI,EAAC,KAAK,EAAE,IAAI,CAAC,OAAO,CAAC,EAAE,GAAI,CAC1C;UACjB,WAAK,IAAI,EAAC,iBAAiB;YACzB,EAAC,aAAa,IAAC,YAAY,EAAC,SAAS;cACnC,EAAC,UAAU,IAAC,KAAK,EAAC,QAAQ,EAAC,KAAK,EAAE,cAAc,CAAC,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,GAAI;cACzE,EAAC,UAAU,IAAC,KAAK,EAAC,MAAM,EAAC,KAAK,EAAE,cAAc,CAAC,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,GAAI;cAC3E,EAAC,UAAU,IAAC,KAAK,EAAC,UAAU,EAAC,KAAK,EAAE,cAAc,CAAC,IAAI,CAAC,OAAO,CAAC,eAAe,CAAC,GAAI;cACpF,EAAC,UAAU,IAAC,KAAK,EAAC,KAAK,EAAC,KAAK,EAAE,cAAc,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,GAAI;cACvE,EAAC,UAAU,IAAC,KAAK,EAAC,QAAQ,EAAC,KAAK,EAAE,uBAAuB,CAAC,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,GAAI;cAClF,EAAC,UAAU,IAAC,KAAK,EAAC,YAAY,EAAC,KAAK,EAAE,IAAI,CAAC,OAAO,CAAC,EAAE,GAAI;cACzD,EAAC,UAAU,IAAC,KAAK,EAAC,iBAAiB,EAAC,KAAK,EAAE,cAAc,CAAC,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,GAAI;cACtF,EAAC,UAAU,IAAC,KAAK,EAAC,sBAAsB,EAAC,KAAK,EAAE,IAAI,CAAC,OAAO,CAAC,oBAAoB,GAAI;cACrF,EAAC,UAAU,IAAC,KAAK,EAAC,aAAa,EAAC,KAAK,EAAE,IAAI,CAAC,OAAO,CAAC,WAAW,GAAI,CACrD;YAChB,EAAC,aAAa,IAAC,YAAY,EAAC,gBAAgB;cAC1C,EAAC,UAAU,IAAC,KAAK,EAAC,IAAI,EAAC,KAAK,EAAE,IAAI,CAAC,OAAO,CAAC,cAAc,CAAC,IAAI,CAAC,EAAE,GAAI;cACrE,EAAC,UAAU,IAAC,KAAK,EAAC,cAAc,EAAC,KAAK,EAAC,MAAM,GAAG;cAChD,EAAC,UAAU,IAAC,KAAK,EAAC,gBAAgB,EAAC,KAAK,EAAE,IAAI,CAAC,OAAO,CAAC,cAAc,CAAC,IAAI,CAAC,cAAc,GAAI;cAC7F,EAAC,UAAU,IAAC,KAAK,EAAC,OAAO,EAAC,KAAK,EAAE,IAAI,CAAC,OAAO,CAAC,cAAc,CAAC,IAAI,CAAC,KAAK,GAAI;cAC3E,EAAC,UAAU,IAAC,KAAK,EAAC,YAAY,EAAC,KAAK,EAAE,IAAI,CAAC,OAAO,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,GAAI,CACjE;YAChB,EAAC,aAAa,IAAC,YAAY,EAAC,UAAU;cACpC,EAAC,SAAS,IAAC,QAAQ,EAAE,IAAI,CAAC,OAAO,CAAC,QAAQ,GAAI,CAChC,CACZ,CACU,CAEnB,CACR,CAAC;EACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Host, h, Prop, State, Watch } from '@stencil/core';\nimport { Api, IApiResponseCollection, Payment } from '../../api';\nimport { MapPaymentStatusToBadge, formatCurrency, formatDate, formatTime } from '../../utils/utils';\nimport { CodeBlock, DetailItem, DetailSection, EntityHeadInfo, EntityHeadInfoItem, ErrorState, LoadingState } from '../details/utils';\nimport { config } from '../../../config';\n\n/**\n * @exportedPart detail-loading-spinner\n * @exportedPart detail-loading-state\n * @exportedPart detail-empty-state\n * @exportedPart detail-head\n * @exportedPart detail-title\n * @exportedPart detail-method\n * @exportedPart detail-info\n * @exportedPart detail-info-item\n * @exportedPart detail-info-item-title\n * @exportedPart detail-info-item-data\n * @exportedPart detail-metadata\n * @exportedPart detail-metadata-title\n * @exportedPart detail-method-title\n * @exportedPart detail-method-data\n * @exportedPart detail-section\n * @exportedPart detail-section-title\n * @exportedPart detail-section-item-title\n * @exportedPart detail-section-item-data\n * @exportedPart detail-head-info\n * @exportedPart detail-head-info-item\n * @exportedPart detail-head-info-item-title\n * @exportedPart detail-head-info-item-data\n*/\n@Component({\n tag: 'justifi-payment-details',\n styleUrl: 'payment-details.scss',\n shadow: true,\n})\n\nexport class PaymentDetails {\n @Prop() paymentId: string;\n @Prop() authToken: string;\n @State() payment: Payment;\n @State() loading: boolean = true;\n @State() errorMessage: string;\n\n @Watch('paymentId')\n @Watch('authToken')\n updateOnPropChange() {\n this.fetchData();\n }\n\n connectedCallback() {\n this.fetchData();\n }\n\n async fetchData(): Promise<void> {\n this.errorMessage = '';\n if (!this.paymentId || !this.authToken) {\n this.errorMessage = \"Can not fetch any data without a PaymentID and an AuthToken\";\n this.loading = false;\n return;\n }\n this.loading = true;\n const endpoint = `payments/${this.paymentId}`;\n\n const response: IApiResponseCollection<Payment> = await Api(this.authToken, config.proxyApiOrigin).get(endpoint);\n if (!response.error) {\n this.payment = response.data;\n } else {\n this.errorMessage = typeof response.error === 'string' ? response.error : response.error.message;\n }\n\n this.loading = false;\n }\n\n render() {\n return (\n <Host>\n {\n this.loading ? LoadingState :\n !this.payment ? ErrorState(this.errorMessage) :\n <justifi-details error-message={this.errorMessage}>\n <EntityHeadInfo slot=\"head-info\" badge={<span slot='badge' innerHTML={MapPaymentStatusToBadge(this.payment?.status)} />} title={`${formatCurrency(this.payment.amount)} ${this.payment.currency.toUpperCase()}`}>\n <EntityHeadInfoItem\n classes=\"border-1 border-end\"\n title=\"Updated At\"\n value={`${formatDate(this.payment.updated_at)} ${formatTime(this.payment.updated_at)}`}\n />\n <EntityHeadInfoItem\n classes=\"border-1 border-end\"\n title=\"Created At\"\n value={`${formatDate(this.payment.created_at)} ${formatTime(this.payment.created_at)}`}\n />\n <EntityHeadInfoItem title=\"ID\" value={this.payment.id} />\n </EntityHeadInfo>\n <div slot='detail-sections'>\n <DetailSection sectionTitle=\"Details\">\n <DetailItem title=\"Amount\" value={formatCurrency(this.payment.amount)} />\n <DetailItem title=\"Fees\" value={formatCurrency(this.payment.fee_amount)} />\n <DetailItem title=\"Refunded\" value={formatCurrency(this.payment.amount_refunded)} />\n <DetailItem title=\"Net\" value={formatCurrency(this.payment.balance)} />\n <DetailItem title=\"Status\" value={MapPaymentStatusToBadge(this.payment.status)} />\n <DetailItem title=\"Payment ID\" value={this.payment.id} />\n <DetailItem title=\"Processing Fees\" value={formatCurrency(this.payment.fee_amount)} />\n <DetailItem title=\"Statement Descriptor\" value={this.payment.statement_descriptor} />\n <DetailItem title=\"Description\" value={this.payment.description} />\n </DetailSection>\n <DetailSection sectionTitle=\"Payment Method\">\n <DetailItem title=\"ID\" value={this.payment.payment_method.card.id} />\n <DetailItem title=\"Payment Type\" value=\"Card\" />\n <DetailItem title=\"Last 4 Numbers\" value={this.payment.payment_method.card.acct_last_four} />\n <DetailItem title=\"Brand\" value={this.payment.payment_method.card.brand} />\n <DetailItem title=\"Cardholder\" value={this.payment.payment_method.card.name} />\n </DetailSection>\n <DetailSection sectionTitle='Metadata'>\n <CodeBlock metadata={this.payment.metadata} />\n </DetailSection>\n </div>\n </justifi-details>\n }\n </Host>\n );\n }\n}"]}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import config from "../../../config";
|
|
1
|
+
import { config } from "../../../config";
|
|
2
2
|
export default {
|
|
3
|
-
title: '
|
|
3
|
+
title: 'Components/PaymentDetails',
|
|
4
4
|
component: 'justifi-payment-details',
|
|
5
5
|
parameters: {},
|
|
6
6
|
};
|
|
7
7
|
class PaymentDetailsArgs {
|
|
8
8
|
constructor(args) {
|
|
9
|
-
this['auth-token'] = args['auth-token'] || config.
|
|
10
|
-
this['payment-id'] = args['payment-id'] ||
|
|
9
|
+
this['auth-token'] = args['auth-token'] || config.proxyAuthToken;
|
|
10
|
+
this['payment-id'] = args['payment-id'] || config.examplePaymentId;
|
|
11
11
|
}
|
|
12
12
|
}
|
|
13
13
|
const Template = (args) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"payment-details.stories.js","sourceRoot":"","sources":["../../../../src/components/payment-details/payment-details.stories.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"payment-details.stories.js","sourceRoot":"","sources":["../../../../src/components/payment-details/payment-details.stories.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AAEzC,eAAe;EACb,KAAK,EAAE,2BAA2B;EAClC,SAAS,EAAE,yBAAyB;EACpC,UAAU,EAAE,EAAE;CACf,CAAC;AAEF,MAAM,kBAAkB;EAItB,YAAY,IAAI;IACd,IAAI,CAAC,YAAY,CAAC,GAAG,IAAI,CAAC,YAAY,CAAC,IAAI,MAAM,CAAC,cAAc,CAAC;IACjE,IAAI,CAAC,YAAY,CAAC,GAAG,IAAI,CAAC,YAAY,CAAC,IAAI,MAAM,CAAC,gBAAgB,CAAC;EACrE,CAAC;CACF;AAED,MAAM,QAAQ,GAAG,CAAC,IAAwB,EAAE,EAAE;EAC5C,OAAO,CAAC;;;oBAGU,IAAI,CAAC,YAAY,CAAC;oBAClB,IAAI,CAAC,YAAY,CAAC;;GAEnC,CAAC,CAAC;AACL,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,KAAK,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;AACvC,KAAK,CAAC,IAAI,GAAG,IAAI,kBAAkB,CAAC,EAAE,CAAC,CAAC;AAExC,MAAM,CAAC,MAAM,MAAM,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;AACxC,MAAM,CAAC,IAAI,GAAG,IAAI,kBAAkB,CAAC,EAAE,CAAC,CAAC;AACzC,MAAM,CAAC,UAAU,GAAG;EAClB,CAAC,KAAK,EAAE,EAAE,CAAC;MACP,KAAK,EAAE;;;;;;;;;;;;;;;;;;GAkBV;CACF,CAAA","sourcesContent":["import { config } from '../../../config';\n\nexport default {\n title: 'Components/PaymentDetails',\n component: 'justifi-payment-details',\n parameters: {},\n};\n\nclass PaymentDetailsArgs {\n 'auth-token': string;\n 'payment-id': string;\n\n constructor(args) {\n this['auth-token'] = args['auth-token'] || config.proxyAuthToken;\n this['payment-id'] = args['payment-id'] || config.examplePaymentId;\n }\n}\n\nconst Template = (args: PaymentDetailsArgs) => {\n return (`\n <justifi-payment-details\n data-testid=\"justifi-payment-details\"\n auth-token=\"${args['auth-token']}\"\n payment-id=\"${args['payment-id']}\"\n />\n `);\n};\n\nexport const Basic = Template.bind({});\nBasic.args = new PaymentDetailsArgs({});\n\nexport const Styled = Template.bind({});\nStyled.args = new PaymentDetailsArgs({});\nStyled.decorators = [\n (Story) => `\n ${Story()}\n <style>\n justifi-payment-details::part(detail-head) {\n background-color: rgba(100, 200, 250, 0.2);\n border-left: 4px solid rgba(100, 200, 250, 1);\n }\n justifi-payment-details::part(detail-info-item-title),\n justifi-payment-details::part(detail-method-item-title) {\n border-radius: 3px;\n background-color: rgba(0, 0, 0, 0.8);\n text-align: center;\n padding: 0 10px;\n color: white !important;\n }\n justifi-payment-details::part(detail-metadata) {\n background-color: rgba(100,100,100,0.2)\n }\n </style>\n `\n]\n"]}
|