@justifi/webcomponents 6.14.4-rc.1 → 6.14.4-rc.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (139) hide show
  1. package/dist/cjs/{Analytics-CLtNL7cp.js → Analytics-DahOCpJB.js} +2 -2
  2. package/dist/cjs/{Api-j0tZ-Tix.js → Api-B4fSXAdi.js} +1 -1
  3. package/dist/cjs/additional-questions-form-step_15.cjs.entry.js +4 -4
  4. package/dist/cjs/bank-account-form.cjs.entry.js +2 -2
  5. package/dist/cjs/{business.service-BGTzzUHv.js → business.service-BAjtyKsg.js} +1 -1
  6. package/dist/cjs/card-form.cjs.entry.js +2 -2
  7. package/dist/cjs/{check-pkg-version-IIkBL56i.js → check-pkg-version-DR4Ghb6-.js} +1 -1
  8. package/dist/cjs/{checkout.service-C6banXoZ.js → checkout.service-DyL8PSeF.js} +1 -1
  9. package/dist/cjs/dispute-notification_2.cjs.entry.js +5 -5
  10. package/dist/cjs/{event-types-CuvC_5oJ.js → event-types-DyRIxSSS.js} +1 -1
  11. package/dist/cjs/{get-subaccounts-BPqMUWqF.js → get-subaccounts-Csq0SIVV.js} +1 -1
  12. package/dist/cjs/hidden-input_2.cjs.entry.js +1 -1
  13. package/dist/cjs/justifi-apple-pay_11.cjs.entry.js +7 -6
  14. package/dist/cjs/justifi-bank-account-billing-form-simple.cjs.entry.js +4 -4
  15. package/dist/cjs/justifi-bank-account-form.cjs.entry.js +4 -4
  16. package/dist/cjs/justifi-business-details.cjs.entry.js +5 -5
  17. package/dist/cjs/justifi-business-form.cjs.entry.js +5 -5
  18. package/dist/cjs/justifi-card-form.cjs.entry.js +4 -4
  19. package/dist/cjs/justifi-checkout-qr-code.cjs.entry.js +4 -4
  20. package/dist/cjs/justifi-checkout.cjs.entry.js +4 -4
  21. package/dist/cjs/justifi-checkouts-list.cjs.entry.js +6 -6
  22. package/dist/cjs/justifi-dispute-management.cjs.entry.js +5 -5
  23. package/dist/cjs/justifi-gross-payment-chart.cjs.entry.js +4 -4
  24. package/dist/cjs/justifi-order-terminals.cjs.entry.js +6 -6
  25. package/dist/cjs/justifi-payment-details.cjs.entry.js +5 -5
  26. package/dist/cjs/justifi-payment-provisioning.cjs.entry.js +5 -5
  27. package/dist/cjs/justifi-payment-transactions-list.cjs.entry.js +5 -5
  28. package/dist/cjs/justifi-payments-list.cjs.entry.js +5 -5
  29. package/dist/cjs/justifi-payout-details.cjs.entry.js +5 -5
  30. package/dist/cjs/justifi-payout-transactions-list.cjs.entry.js +5 -5
  31. package/dist/cjs/justifi-payouts-list.cjs.entry.js +6 -6
  32. package/dist/cjs/justifi-qr-terminal.cjs.entry.js +5 -5
  33. package/dist/cjs/justifi-refund-payment.cjs.entry.js +5 -5
  34. package/dist/cjs/justifi-season-interruption-insurance.cjs.entry.js +4 -4
  35. package/dist/cjs/justifi-terminal-orders-list.cjs.entry.js +4 -4
  36. package/dist/cjs/justifi-terminals-list.cjs.entry.js +6 -6
  37. package/dist/cjs/{package-D_k65Ek-.js → package-DkLJAjev.js} +1 -1
  38. package/dist/cjs/{payment.service-CsRgUBpg.js → payment.service-CBMsLP9b.js} +1 -1
  39. package/dist/cjs/{payout.service-B9Uy-vnZ.js → payout.service-BAturpCC.js} +1 -1
  40. package/dist/cjs/{plaid.service-BO5TCVg-.js → plaid.service-DJ42fz7B.js} +1 -1
  41. package/dist/cjs/{terminal.service-IQgeT2S0.js → terminal.service-C4ksBqBo.js} +1 -1
  42. package/dist/collection/components/modular-checkout/sub-components/justifi-apple-pay.js +1 -0
  43. package/dist/docs.json +1 -1
  44. package/dist/esm/{Analytics-CkVFbWbI.js → Analytics-WT1A3bAb.js} +2 -2
  45. package/dist/esm/{Api-C_lKBDA2.js → Api-DoxYyzWs.js} +1 -1
  46. package/dist/esm/additional-questions-form-step_15.entry.js +4 -4
  47. package/dist/esm/bank-account-form.entry.js +2 -2
  48. package/dist/esm/{business.service-CFAfsTjM.js → business.service-DhBcj7ui.js} +1 -1
  49. package/dist/esm/card-form.entry.js +2 -2
  50. package/dist/esm/{check-pkg-version-D8eS1EP8.js → check-pkg-version-BL_f_mbi.js} +1 -1
  51. package/dist/esm/{checkout.service-B3kWd3Cb.js → checkout.service-NUZlIPnJ.js} +1 -1
  52. package/dist/esm/dispute-notification_2.entry.js +5 -5
  53. package/dist/esm/{event-types-CWcuMhpX.js → event-types-CXLixpiw.js} +1 -1
  54. package/dist/esm/{get-subaccounts-DX2J9fAE.js → get-subaccounts-Dnf1EKn1.js} +1 -1
  55. package/dist/esm/hidden-input_2.entry.js +1 -1
  56. package/dist/esm/justifi-apple-pay_11.entry.js +7 -6
  57. package/dist/esm/justifi-bank-account-billing-form-simple.entry.js +4 -4
  58. package/dist/esm/justifi-bank-account-form.entry.js +4 -4
  59. package/dist/esm/justifi-business-details.entry.js +5 -5
  60. package/dist/esm/justifi-business-form.entry.js +5 -5
  61. package/dist/esm/justifi-card-form.entry.js +4 -4
  62. package/dist/esm/justifi-checkout-qr-code.entry.js +4 -4
  63. package/dist/esm/justifi-checkout.entry.js +4 -4
  64. package/dist/esm/justifi-checkouts-list.entry.js +6 -6
  65. package/dist/esm/justifi-dispute-management.entry.js +5 -5
  66. package/dist/esm/justifi-gross-payment-chart.entry.js +4 -4
  67. package/dist/esm/justifi-order-terminals.entry.js +6 -6
  68. package/dist/esm/justifi-payment-details.entry.js +5 -5
  69. package/dist/esm/justifi-payment-provisioning.entry.js +5 -5
  70. package/dist/esm/justifi-payment-transactions-list.entry.js +5 -5
  71. package/dist/esm/justifi-payments-list.entry.js +5 -5
  72. package/dist/esm/justifi-payout-details.entry.js +5 -5
  73. package/dist/esm/justifi-payout-transactions-list.entry.js +5 -5
  74. package/dist/esm/justifi-payouts-list.entry.js +6 -6
  75. package/dist/esm/justifi-qr-terminal.entry.js +5 -5
  76. package/dist/esm/justifi-refund-payment.entry.js +5 -5
  77. package/dist/esm/justifi-season-interruption-insurance.entry.js +4 -4
  78. package/dist/esm/justifi-terminal-orders-list.entry.js +4 -4
  79. package/dist/esm/justifi-terminals-list.entry.js +6 -6
  80. package/dist/esm/{package-XQGYXcNa.js → package-CrTWHVKE.js} +1 -1
  81. package/dist/esm/{payment.service-DICpfY3q.js → payment.service-UBuViC7e.js} +1 -1
  82. package/dist/esm/{payout.service-C0dmZtzu.js → payout.service-CV2uYm-0.js} +1 -1
  83. package/dist/esm/{plaid.service-CDwe-YbI.js → plaid.service-B0mFmUgQ.js} +1 -1
  84. package/dist/esm/{terminal.service-DIDTZ_fB.js → terminal.service-ClKFvbFw.js} +1 -1
  85. package/dist/module/justifi-apple-pay2.js +1 -0
  86. package/dist/module/package.js +1 -1
  87. package/dist/webcomponents/{p-5071aaa4.entry.js → p-06d3d9b6.entry.js} +1 -1
  88. package/dist/webcomponents/p-1e3f096f.entry.js +1 -0
  89. package/dist/webcomponents/p-2599e169.entry.js +1 -0
  90. package/dist/webcomponents/{p-a7d0cc9f.entry.js → p-26fe714a.entry.js} +1 -1
  91. package/dist/webcomponents/{p-c0698710.entry.js → p-2ba48cf1.entry.js} +1 -1
  92. package/dist/webcomponents/{p-4baac05b.entry.js → p-33070a71.entry.js} +1 -1
  93. package/dist/webcomponents/{p-0d0167f8.entry.js → p-396ed502.entry.js} +4 -4
  94. package/dist/webcomponents/{p-43a53ae2.entry.js → p-52b25165.entry.js} +1 -1
  95. package/dist/webcomponents/{p-a686ebeb.entry.js → p-67a444f7.entry.js} +1 -1
  96. package/dist/webcomponents/{p-222a5422.entry.js → p-6f5d9579.entry.js} +1 -1
  97. package/dist/webcomponents/{p-64377ff6.entry.js → p-7d61e758.entry.js} +1 -1
  98. package/dist/webcomponents/{p-8cb504d4.entry.js → p-7dfe47bf.entry.js} +1 -1
  99. package/dist/webcomponents/{p-b0deb260.entry.js → p-8476b45a.entry.js} +1 -1
  100. package/dist/webcomponents/{p-02097c85.entry.js → p-86e0ac37.entry.js} +1 -1
  101. package/dist/webcomponents/p-925ca097.entry.js +1 -0
  102. package/dist/webcomponents/{p-ba8eae66.entry.js → p-9735a37b.entry.js} +1 -1
  103. package/dist/webcomponents/{p-Tf63eN3X.js → p-BGD3uog3.js} +1 -1
  104. package/dist/webcomponents/p-BS8j0DWf.js +1 -0
  105. package/dist/webcomponents/{p-CZTtbCDg.js → p-B_i1R4O_.js} +1 -1
  106. package/dist/webcomponents/{p-CYH0JCan.js → p-BmrZbyuT.js} +1 -1
  107. package/dist/webcomponents/{p-CV9bTMsT.js → p-C7lKXwUt.js} +1 -1
  108. package/dist/webcomponents/{p-Da3ZlxHS.js → p-CB69z5Eh.js} +1 -1
  109. package/dist/webcomponents/p-CrTWHVKE.js +1 -0
  110. package/dist/webcomponents/{p-M5r3mgPH.js → p-CvFpXdzD.js} +1 -1
  111. package/dist/webcomponents/{p-ynzkwSZi.js → p-DfL-8Yvt.js} +1 -1
  112. package/dist/webcomponents/{p-IcPtYL88.js → p-ECg6MX8R.js} +1 -1
  113. package/dist/webcomponents/{p-bpbC1knu.js → p-Sr5nnVDM.js} +1 -1
  114. package/dist/webcomponents/p-Xf0jRfzp.js +1 -0
  115. package/dist/webcomponents/{p-20f07ac9.entry.js → p-a55fe1c2.entry.js} +1 -1
  116. package/dist/webcomponents/p-a7c7898d.entry.js +1 -0
  117. package/dist/webcomponents/p-aa3f1d88.entry.js +1 -0
  118. package/dist/webcomponents/{p-f3977cfe.entry.js → p-b2c4f61b.entry.js} +1 -1
  119. package/dist/webcomponents/{p-4a5d5dbb.entry.js → p-b46f303d.entry.js} +1 -1
  120. package/dist/webcomponents/p-b8fcb871.entry.js +1 -0
  121. package/dist/webcomponents/{p-ebbb72db.entry.js → p-c1209de0.entry.js} +1 -1
  122. package/dist/webcomponents/{p-932f6c6f.entry.js → p-c1ada405.entry.js} +1 -1
  123. package/dist/webcomponents/{p-b6c45aa2.entry.js → p-ca9886fd.entry.js} +1 -1
  124. package/dist/webcomponents/{p-6624dcf8.entry.js → p-d2c8cc7d.entry.js} +1 -1
  125. package/dist/webcomponents/{p-b36bdd5e.entry.js → p-e704d652.entry.js} +1 -1
  126. package/dist/webcomponents/{p-f8c2ee31.entry.js → p-f8734760.entry.js} +1 -1
  127. package/dist/webcomponents/p-fd9b4f83.entry.js +1 -0
  128. package/dist/webcomponents/webcomponents.esm.js +1 -1
  129. package/package.json +1 -1
  130. package/dist/webcomponents/p-0da78470.entry.js +0 -1
  131. package/dist/webcomponents/p-35a01bf7.entry.js +0 -1
  132. package/dist/webcomponents/p-3d89543a.entry.js +0 -1
  133. package/dist/webcomponents/p-8ef24398.entry.js +0 -1
  134. package/dist/webcomponents/p-9525003b.entry.js +0 -1
  135. package/dist/webcomponents/p-CmmWlVnF.js +0 -1
  136. package/dist/webcomponents/p-DnaE803u.js +0 -1
  137. package/dist/webcomponents/p-XQGYXcNa.js +0 -1
  138. package/dist/webcomponents/p-a504a830.entry.js +0 -1
  139. package/dist/webcomponents/p-c902503d.entry.js +0 -1
@@ -1 +0,0 @@
1
- import{A as e}from"./p-ynzkwSZi.js";import"./p-AyLerOda.js";import"./p-CLHwhyvu.js";import"./p-BcNb9bVO.js";const n=e();class r{async fetchTerminals(e,r,s){return n.get({endpoint:"terminals",params:s,headers:{Account:e},authToken:r})}async fetchTerminal(e,r){return n.get({endpoint:`terminals/${e}`,authToken:r})}async fetchTerminalModels(e,r){return n.get({endpoint:"terminals/order_models",headers:{"sub-account":e},authToken:r})}async orderTerminals(e,r){return n.post({endpoint:"terminals/orders",body:r,headers:{"sub-account":r.sub_account_id},authToken:e})}}export{r as T}
@@ -1 +0,0 @@
1
- import{A as n}from"./p-ynzkwSZi.js";import"./p-AyLerOda.js";import"./p-CLHwhyvu.js";import"./p-BcNb9bVO.js";const t=n();class a{async fetchPayments(n,a,e){return t.get({endpoint:`account/${n}/payments`,params:e,authToken:a})}async fetchPayment(n,a){return t.get({endpoint:`payments/${n}`,authToken:a})}async fetchPaymentTransactions(n,a,e){return t.get({endpoint:`payments/${n}/payment_balance_transactions`,params:e,authToken:a})}}export{a as P}
@@ -1 +0,0 @@
1
- var e={name:"@justifi/webcomponents",version:"6.14.4-rc.1"};export{e as p}
@@ -1 +0,0 @@
1
- import{h as s,r as t,c as i}from"./p-CV0Pyo1O.js";import{A as e}from"./p-ynzkwSZi.js";import{C as r,b as o}from"./p-AyLerOda.js";import"./p-CLHwhyvu.js";import"./p-BcNb9bVO.js";import{g as a,a as n}from"./p-CXZRiaUw.js";import{J as c}from"./p-CV9bTMsT.js";import{c as l}from"./p-Tf63eN3X.js";import{c as h}from"./p-DyPk4BJt.js";import{p as d,f as p,r as u,i as v}from"./p-Ds_P-dB8.js";import{v as m,i as y,a as f,H as j}from"./p-C-Jgmek8.js";import{t as _,z as g}from"./p-CPKMvyV_.js";import{S as b}from"./p-05AWudQe.js";import"./p-CZfYo5-1.js";import{S as k}from"./p-uZ5KAseb.js";import"./p-DVJaoI_m.js";import"./p-D8GTwl9v.js";import"./p-XQGYXcNa.js";import"./p-DkoufM1t.js";import"./p-HXpYMWUU.js";const w=e();class C{async fetchQuote(s,t){return w.post({endpoint:"insurance/quotes",body:t,authToken:s})}async toggleCoverage(s,t,i){return w.post({endpoint:`insurance/quotes/${t}/toggle`,body:i,authToken:s})}}const T=()=>s("div",{class:"row gap-3"},s("div",{class:"col-12"},s(k,{width:"35%",height:"30px"})),s("div",{class:"col-12"},s(k,{width:"70%"})),s("div",{class:"col-12"},s(k,{width:"40%"})),s("div",{class:"col-12"},s(k,{width:"40%"})),s("div",{class:"col-12"},s(k,{width:"100%"})),s("div",{class:"col-12"},s(k,{width:"80%"}))),H=class{constructor(s){t(this,s),this.insuranceUpdated=i(this,"insurance-updated",7),this.errorEvent=i(this,"error-event",7),this.isLoading=!0}async validate(){return m()}processHTMLContent(s){return d(s,[s=>u(s,"style"),s=>v(s,"a","part",_),s=>v(s,"p","part",_)])}componentWillLoad(){l(),this.analytics=new c(this),this.initializeServiceMethods(),this.getQuote&&this.fetchData()}disconnectedCallback(){var s;null===(s=this.analytics)||void 0===s||s.cleanup()}initializeServiceMethods(){const s=this.authToken||h.authToken;if(!s)return void this.errorEvent.emit({errorCode:o.MISSING_PROPS,message:"Missing authToken",severity:r.ERROR});const t={authToken:s,service:new C};this.getQuote=(({authToken:s,service:t})=>async({payload:i,onSuccess:e,onError:o})=>{var c;try{const l=await t.fetchQuote(s,i);if(l.error)return o({error:n(l.error),code:a(null===(c=l.error)||void 0===c?void 0:c.code),severity:r.ERROR});e({quote:l.data})}catch(s){const t=a(null==s?void 0:s.code);return o({error:s.message||s,code:t,severity:r.ERROR})}})(t),this.toggleCoverage=(({authToken:s,service:t})=>async({quoteId:i,payload:e,onSuccess:o,onError:c})=>{var l;try{const h=await t.toggleCoverage(s,i,e);if(h.error)return c({error:n(h.error),code:a(null===(l=h.error)||void 0===l?void 0:l.code),severity:r.ERROR});o({quote:h.data})}catch(s){const t=a(null==s?void 0:s.code);return c({error:s.message||s,code:t,severity:r.ERROR})}})(t)}fetchData(){this.isLoading=!0,this.getQuote({payload:{checkout_id:this.checkoutId||h.checkoutId,policy_type:"season_interruption",primary_identity:{state:this.primaryIdentityState,email:this.primaryIdentityEmailAddress,first_name:this.primaryIdentityFirstName,last_name:this.primaryIdentityLastName,postal_code:this.primaryIdentityPostalCode,country:this.primaryIdentityCountry},policy_attributes:{insurable_amount:this.policyAttributesInsurableAmount,start_date:this.policyAttributesStartDate,end_date:this.policyAttributesEndDate,covered_identity:{first_name:this.coveredIdentityFirstName,last_name:this.coveredIdentityLastName}}},onSuccess:({quote:s})=>{this.quote=s,this.quote.product.description=this.processHTMLContent(this.quote.product.description),this.quote.product.legal_disclaimer=this.processHTMLContent(this.quote.product.legal_disclaimer),y[s.policy_type]=s.accepted,this.isLoading=!1},onError:({error:s,code:t,severity:i})=>{this.isLoading=!1,this.errorEvent.emit({errorCode:t,message:s,severity:i})}})}onChangeHandler(s,t){this.accepted=t,f[this.quote.policy_type]=!1,this.toggleCoverage({quoteId:this.quote.id,payload:{accepted:this.accepted},onSuccess:()=>{this.insuranceUpdated.emit(),y[this.quote.policy_type]=this.accepted},onError:({error:s,code:t,severity:i})=>{this.errorEvent.emit({errorCode:t,message:s,severity:i})}})}get error(){var s;return f[null===(s=this.quote)||void 0===s?void 0:s.policy_type]}render(){var t,i,e,r;return h&&!1===h.insuranceEnabled?(console.warn("[justifi-season-interruption-insurance] Insurance is disabled for this checkout (payment_settings.insurance_payments=false)."),null):s(b,null,this.isLoading?s(T,null):s("div",null,s(j,{text:null===(t=this.quote)||void 0===t?void 0:t.product.title,class:"fs-5 fw-bold pb-3"}),s("small",{part:_,innerHTML:null===(i=this.quote)||void 0===i?void 0:i.product.description}),s("form-control-radio",{label:`Accept coverage for ${p(null===(e=this.quote)||void 0===e?void 0:e.total_cents)}`,name:"opt-in",value:"true",checked:"true"===this.accepted,inputHandler:this.onChangeHandler.bind(this),errorText:this.error?" ":void 0}),s("form-control-radio",{label:"Decline coverage",name:"opt-in",value:"false",checked:"false"===this.accepted,inputHandler:this.onChangeHandler.bind(this),errorText:this.error?" ":void 0}),s("div",{class:"invalid-feedback",style:{display:this.error?"block":"none"},part:g},"Please select an option"),s("small",{part:_,innerHTML:null===(r=this.quote)||void 0===r?void 0:r.product.legal_disclaimer})))}};export{H as justifi_season_interruption_insurance}
@@ -1 +0,0 @@
1
- import{h as t,r as e,c as a}from"./p-CV0Pyo1O.js";import{c as s}from"./p-DVJaoI_m.js";import"./p-HXpYMWUU.js";import{l as i,C as o,b as r}from"./p-AyLerOda.js";import{p as n}from"./p-CLHwhyvu.js";import"./p-BcNb9bVO.js";import{J as c}from"./p-CV9bTMsT.js";import{c as d}from"./p-Tf63eN3X.js";import{g as p,a as h}from"./p-CXZRiaUw.js";import{P as l}from"./p-bpbC1knu.js";import{T as f,a as u,b as m,c as b,d as y,e as _,f as w,g,h as T,i as j,j as v,k,l as C}from"./p-BICxxa69.js";import{S as P}from"./p-05AWudQe.js";import{T as D}from"./p-CZfYo5-1.js";import{a as I}from"./p-Ds_P-dB8.js";import{a6 as S,a7 as F}from"./p-CPKMvyV_.js";import"./p-D8GTwl9v.js";import"./p-XQGYXcNa.js";import"./p-ynzkwSZi.js";import"./p-CqiVXthx.js";const O={id:()=>t("th",{part:S,scope:"col",title:"The unique identifier of each transaction"},"ID"),account_id:()=>t("th",{part:S,scope:"col",title:"The unique identifier of the account associated with each transaction"},"Account ID"),payout_id:()=>t("th",{part:S,scope:"col",title:"The unique identifier of the payout associated with each transaction"},"Payout ID"),financial_transaction_id:()=>t("th",{part:S,scope:"col",title:"The unique identifier of the financial transaction associated with the payment balance transaction"},"Financial Transaction ID"),amount:()=>t("th",{part:S,scope:"col",title:"The dollar amount of each transaction"},"Amount"),fee:()=>t("th",{part:S,scope:"col",title:"The fee associated with each transaction"},"Fee"),net:()=>t("th",{part:S,scope:"col",title:"The net amount of each transaction"},"Net"),currency:()=>t("th",{part:S,scope:"col",title:"The currency of each transaction"},"Currency"),description:()=>t("th",{part:S,scope:"col",title:"The description of each transaction"},"Description"),source_id:()=>t("th",{part:S,scope:"col",title:"The unique identifier of the source object associated with the payment balance transaction"},"Source ID"),txn_type:()=>t("th",{part:S,scope:"col",title:"The type of each transaction"},"Type"),created_at:()=>t("th",{part:S,scope:"col",title:"The date and time each transaction was made"},"Processed On"),available_on:()=>t("th",{part:S,scope:"col",title:"The date and time each transaction will be available"},"Available On"),updated_at:()=>t("th",{part:S,scope:"col",title:"The date and time each transaction was last updated"},"Updated On")},q={fee:"Fee",payment:"Payment",payout:"Payout",seller_payment_refund:"Seller Payment Refund",dispute_amount_collected:"Dispute Amount Collected",dispute_fee_collected:"Dispute Fee Collected",seller_payment:"Seller Payment",transfer:"Transfer",partner_platform_proceeds_credit:"Partner Platform Proceeds Credit",processing_fee:"Processing Fee",refund_processing_fee:"Refund Processing Fee",fee_rounding_adjustment:"Fee Rounding Adjustment",platform_fee:"Platform Fee",processing_fee_return:"Processing Fee Return",platform_fee_return:"Platform Fee Return"},x={id:e=>t("td",{part:F(e.id)},e.id),account_id:e=>t("td",{part:F(e.account_id)},e.account_id),payout_id:e=>t("td",{part:F(e.payout_id)},e.payout_id),financial_transaction_id:e=>t("td",{part:F(e.financial_transaction_id)},e.financial_transaction_id),amount:e=>t("td",{part:F(e.amount)},e.formattedPaymentAmount(e.amount)),fee:e=>t("td",{part:F(e.fee)},e.formattedPaymentAmount(e.fee)),net:e=>t("td",{part:F(e.net)},e.formattedPaymentAmount(e.net)),currency:e=>t("td",{part:F(e.currency)},e.currency),description:e=>t("td",{part:F(e.description)},e.description),source_id:e=>t("td",{part:F(e.source_id)},e.source_id),txn_type:e=>t("td",{part:F(e.txn_type)},q[e.txn_type]),created_at:e=>t("td",{part:F(e.created_at)},t("div",{class:"fw-bold"},I(e.created_at,{showDisplayDate:!0})),t("div",{class:"fw-bold"},I(e.created_at,{showTime:!0}))),available_on:e=>t("td",{part:F(e.available_on)},t("div",{class:"fw-bold"},I(e.available_on,{showDisplayDate:!0})),t("div",{class:"fw-bold"},I(e.available_on,{showTime:!0}))),updated_at:e=>t("td",{part:F(e.updated_at)},t("div",{class:"fw-bold"},I(e.updated_at,{showDisplayDate:!0})),t("div",{class:"fw-bold"},I(e.updated_at,{showTime:!0})))},A=class{constructor(t){e(this,t),this.clickEvent=a(this,"click-event",7),this.errorEvent=a(this,"error-event",7),this.balanceTransactions=[],this.isLoading=!0,this.errorMessage=null,this.paging=n,this.pagingParams={},this.columns="created_at,txn_type,description,amount,fee,net",this.handleClickPrevious=t=>{this.pagingParams={before_cursor:t},this.clickEvent.emit({name:D.previous})},this.handleClickNext=t=>{this.pagingParams={after_cursor:t},this.clickEvent.emit({name:D.next})},this.rowClickHandler=t=>{const e=t.target.closest("tr").dataset.rowEntityId;if(!e)return;const a=this.balanceTransactions.find((t=>t.id===e));this.clickEvent.emit({name:D.row,data:a})}}componentWillLoad(){this.transactionsTable=new f(this.balanceTransactions,this.columns,O,x),d(),this.analytics=new c(this),this.initializeApi()}disconnectedCallback(){var t;null===(t=this.analytics)||void 0===t||t.cleanup()}propChanged(){this.initializeApi()}handleError(t,e,a){this.isLoading=!1,this.errorEvent.emit({errorCode:t,message:e,severity:a})}initializeApi(){this.payoutId&&this.authToken?(({accountId:t,authToken:e,service:a})=>async({params:s,onSuccess:r,onError:n,final:c})=>{var d;try{const c=await a.fetchPayoutTransactions(t,e,s);c.error?n({error:h(c.error),code:p(null===(d=c.error)||void 0===d?void 0:d.code),severity:o.ERROR}):r({balanceTransactions:c.data.map((t=>new i(t))),pagingInfo:Object.assign({},c.page_info)})}catch(t){const e=p(null==t?void 0:t.code);n({error:h(t),code:e,severity:o.ERROR})}finally{c()}})({accountId:s.accountId,authToken:this.authToken,service:new l})({params:this.requestParams,onSuccess:({balanceTransactions:t,pagingInfo:e})=>{this.balanceTransactions=t,this.paging=e,this.transactionsTable.collectionData=this.balanceTransactions},onError:({error:t,code:e,severity:a})=>{this.errorMessage=t.message,this.handleError(t,e,a)},final:()=>{this.isLoading=!1}}):(this.errorMessage="payout-id and auth-token props are required",this.handleError(r.MISSING_PROPS,this.errorMessage,o.ERROR))}get entityId(){return this.balanceTransactions.map((t=>t.id))}get showEmptyState(){return!this.isLoading&&!this.errorMessage&&this.transactionsTable.rowData.length<1}get showErrorState(){return!this.isLoading&&!!this.errorMessage}get showRowData(){return!this.showEmptyState&&!this.showErrorState&&!this.isLoading}get requestParams(){return Object.assign({payout_id:this.payoutId,limit:"15"},this.pagingParams)}render(){return t(P,{key:"e7b5b219c34d1c8610fb4113fedd503f0512db2d"},t(u,{key:"97bbe678c90ba115a091db4fac42560c17f557f2"},t(m,{key:"ef90c77cd8f19a80e2b3e2b514aa1bc735a1b783"},t(b,{key:"f5f0a00594f099931f1ac1cd4e359bb8fab11ec8"},t(y,{key:"559648add19e0426d756f71ecb7bbd5cbcf1349e"},this.transactionsTable.columnData.map((t=>t)))),t(_,{key:"49f8da0be5dba34ffbb92805d7b5b0fb3eeb6bf7"},t(w,{key:"1d61dc2157608f38eb34e64452d7089857e6c67d",columnSpan:this.transactionsTable.columnKeys.length,isLoading:this.isLoading}),t(g,{key:"d1f735fdb009740a186a16ea7e15d0320965a286",isEmpty:this.showEmptyState,columnSpan:this.transactionsTable.columnKeys.length}),t(T,{key:"f50ecc151be5c9143fb69d575a1ef14b3aa17b61",columnSpan:this.transactionsTable.columnKeys.length,errorMessage:this.errorMessage}),this.showRowData&&this.transactionsTable.rowData.map(((e,a)=>t(j,{"data-test-id":"table-row","data-row-entity-id":this.entityId[a],onClick:this.rowClickHandler},e)))),this.paging&&t(v,{key:"560536e623b2437d613169af2980aec13ebb4531"},t(k,{key:"42b82920fdd6056bb654db92acf3741aafb13d99"},t(C,{key:"e2545104fdac51e0ada942138a08714f213bce63",colSpan:this.transactionsTable.columnData.length},t("pagination-menu",{key:"6a74b19f3fa02f0e86e00783a06b0dfba2bc0ed8",paging:Object.assign(Object.assign({},this.paging),{handleClickPrevious:this.handleClickPrevious,handleClickNext:this.handleClickNext})})))))))}static get watchers(){return{pagingParams:["propChanged"],payoutId:["propChanged"],authToken:["propChanged"]}}};export{A as justifi_payout_transactions_list}