Channel: "+u.alias.padEnd(20)+"			Amount (Sats): "+a.decimalPipe.transform(s.amt_to_forward)+""):a.dataService.getAliasesFromPubkeys(s.pub_key,!1).pipe((0,d.R)(a.unSubs[6])).subscribe(g=>{o.push("
Channel: "+(g.node&&g.node.alias?g.node.alias.padEnd(20):s.pub_key.substring(0,17)+"...")+"			Amount (Sats): "+a.decimalPipe.transform(s.amt_to_forward)+"")}),o},[])}onHTLCClick(t,a){a.payment_request&&""!==a.payment_request.trim()?this.dataService.decodePayment(a.payment_request,!1).pipe((0,G.q)(1)).subscribe({next:o=>{setTimeout(()=>{this.showHTLCView(t,a,o)},0)},error:o=>{this.showHTLCView(t,a,null)}}):this.showHTLCView(t,a,null)}showHTLCView(t,a,o){const s=[[{key:"payment_hash",value:a.payment_hash,title:"Payment Hash",width:100,type:l.Gi.STRING}],[{key:"preimage",value:t.preimage,title:"Preimage",width:100,type:l.Gi.STRING}],[{key:"payment_request",value:a.payment_request,title:"Payment Request",width:100,type:l.Gi.STRING}],[{key:"status",value:t.status,title:"Status",width:33,type:l.Gi.STRING},{key:"attempt_time_ns",value:+t.attempt_time_ns/1e9,title:"Attempt Time",width:33,type:l.Gi.DATE_TIME},{key:"resolve_time_ns",value:+t.resolve_time_ns/1e9,title:"Resolve Time",width:34,type:l.Gi.DATE_TIME}],[{key:"total_amt",value:t.route.total_amt,title:"Amount (Sats)",width:33,type:l.Gi.NUMBER},{key:"total_fees",value:t.route.total_fees,title:"Fee (Sats)",width:33,type:l.Gi.NUMBER},{key:"total_time_lock",value:t.route.total_time_lock,title:"Total Time Lock",width:34,type:l.Gi.NUMBER}],[{key:"hops",value:this.getHopDetails(t.route.hops),title:"Hops",width:100,type:l.Gi.ARRAY}]];o&&o.description&&""!==o.description&&s.splice(3,0,[{key:"description",value:o.description,title:"Description",width:100,type:l.Gi.STRING}]),this.store.dispatch((0,v.qR)({payload:{data:{type:l.n_.INFORMATION,alertTitle:"HTLC Information",message:s,scrollable:t.route&&t.route.hops&&t.route.hops.length>1}}}))}onPaymentClick(t){if(t.htlcs&&t.htlcs[0]&&t.htlcs[0].route&&t.htlcs[0].route.hops&&t.htlcs[0].route.hops.length>0){const a=t.htlcs[0].route.hops.reduce((o,s)=>""===o?s.pub_key:o+","+s.pub_key,"");this.dataService.getAliasesFromPubkeys(a,!0).pipe((0,d.R)(this.unSubs[7])).subscribe(o=>{this.showPaymentView(t,o.reduce((s,u)=>""===s?u:s+"\n"+u,""))})}else this.showPaymentView(t,"")}showPaymentView(t,a){const o=[[{key:"payment_hash",value:t.payment_hash,title:"Payment Hash",width:100,type:l.Gi.STRING}],[{key:"payment_preimage",value:t.payment_preimage,title:"Payment Preimage",width:100,type:l.Gi.STRING}],[{key:"payment_request",value:t.payment_request,title:"Payment Request",width:100,type:l.Gi.STRING}],[{key:"status",value:t.status,title:"Status",width:50,type:l.Gi.STRING},{key:"creation_date",value:t.creation_date,title:"Creation Date",width:50,type:l.Gi.DATE_TIME}],[{key:"value_msat",value:t.value_msat,title:"Value (mSats)",width:50,type:l.Gi.NUMBER},{key:"fee_msat",value:t.fee_msat,title:"Fee (mSats)",width:50,type:l.Gi.NUMBER}],[{key:"path",value:a,title:"Path",width:100,type:l.Gi.STRING}]];t.payment_request&&""!==t.payment_request.trim()?this.dataService.decodePayment(t.payment_request,!1).pipe((0,G.q)(1)).subscribe(s=>{s&&s.description&&""!==s.description&&o.splice(3,0,[{key:"description",value:s.description,title:"Description",width:100,type:l.Gi.STRING}]),setTimeout(()=>{this.openPaymentAlert(o,t.htlcs&&t.htlcs[0]&&t.htlcs[0].route&&t.htlcs[0].route.hops&&t.htlcs[0].route.hops.length>1)},0)}):this.openPaymentAlert(o,!1)}openPaymentAlert(t,a){this.store.dispatch((0,v.qR)({payload:{data:{type:l.n_.INFORMATION,alertTitle:"Payment Information",message:t,scrollable:a}}}))}applyFilter(){this.payments.filter=this.selFilter.trim().toLowerCase()}loadPaymentsTable(t){this.payments=new r.by(t?[...t]:[]),this.payments.sortingDataAccessor=(a,o)=>"hops"===o?a.htlcs.length&&a.htlcs[0]&&a.htlcs[0].route&&a.htlcs[0].route.hops&&a.htlcs[0].route.hops.length?a.htlcs[0].route.hops.length:0:a[o]&&isNaN(a[o])?a[o].toLocaleLowerCase():a[o]?+a[o]:null,this.payments.sort=this.sort,this.payments.filterPredicate=(a,o)=>((a.creation_date?this.datePipe.transform(new Date(1e3*a.creation_date),"dd/MMM/YYYY HH:mm").toLowerCase():"")+JSON.stringify(a).toLowerCase()).includes(o),this.applyFilter()}onDownloadCSV(){if(this.payments.data&&this.payments.data.length>0){const t=JSON.parse(JSON.stringify(this.payments.data)),a=t.reduce((o,s)=>(s.payment_request&&""!==s.payment_request.trim()&&(o=""===o?s.payment_request:o+","+s.payment_request),o),"");this.dataService.decodePayments(a).pipe((0,d.R)(this.unSubs[8])).subscribe(o=>{let s=0;o.forEach((g,U)=>{if(g){for(;t[U+s].payment_hash!==g.payment_hash;)s+=1;t[U+s].description=g.description}});const u=t.reduce((g,U)=>g.concat(U),[]);this.commonService.downloadFile(u,"Payments")})}}ngOnDestroy(){this.unSubs.forEach(t=>{t.next(null),t.complete()})}}return n.\u0275fac=function(t){return new(t||n)(e.Y36(F.mQ),e.Y36(P.v),e.Y36(K.D),e.Y36(w.yh),e.Y36(ie.V),e.Y36(ee.l),e.Y36(m.JJ),e.Y36(m.uU))},n.\u0275cmp=e.Xpm({type:n,selectors:[["rtl-lightning-payments"]],viewQuery:function(t,a){if(1&t&&(e.Gf(kn,5),e.Gf(Z.YE,5),e.Gf(q.NW,5)),2&t){let o;e.iGM(o=e.CRH())&&(a.form=o.first),e.iGM(o=e.CRH())&&(a.sort=o.first),e.iGM(o=e.CRH())&&(a.paginator=o.first)}},inputs:{calledFrom:"calledFrom"},features:[e._Bn([{provide:q.ye,useValue:(0,l.pt)("Payments")}])],decls:4,vars:3,consts:[["fxLayout","column","fxFlex","100","fxLayoutAlign","space-between stretch",1,"padding-gap-x"],["fxLayoutAlign","space-between stretch","fxLayout","row wrap",4,"ngIf"],["fxLayout","row",4,"ngIf"],["fxLayout","column","fxLayoutAlign","start stretch",4,"ngIf"],["fxLayoutAlign","space-between stretch","fxLayout","row wrap"],["sendPaymentForm","ngForm"],["fxFlex","100"],["matInput","","placeholder","Payment Request","name","paymentRequest","tabindex","1","required","",3,"perfectScrollbar","ngModel","ngModelChange","matTextareaAutosize"],["paymentReq","ngModel"],[4,"ngIf"],["fxLayout","row",1,"mt-1"],["mat-stroked-button","","color","primary","tabindex","2","type","reset",1,"mr-1",3,"click"],["mat-flat-button","","color","primary","tabindex","3",3,"click"],["fxLayout","row"],["mat-flat-button","","color","primary","tabindex","4",3,"click"],["fxLayout","column","fxLayoutAlign","start stretch"],["fxLayout","column","fxLayoutAlign","start stretch","fxLayout.gt-sm","row wrap",1,"page-sub-title-container","mt-1"],["fxFlex","70","fxLayoutAlign","start start","fxLayoutAlign.gt-sm","start center"],[1,"page-title-img","mr-1",3,"icon"],[1,"page-title"],["fxFlex","30","fxLayoutAlign","start end"],["matInput","","placeholder","Filter",3,"ngModel","keyup","ngModelChange"],["fxLayout","row","fxLayoutAlign","start start"],["fxLayout","column","fxLayoutAlign","start end","fxFlex","100",1,"table-container",3,"perfectScrollbar"],["mode","indeterminate",4,"ngIf"],["mat-table","","fxFlex","100","matSort","",3,"dataSource","ngClass"],["table",""],["matColumnDef","creation_date"],["mat-header-cell","","mat-sort-header","",4,"matHeaderCellDef"],["mat-cell","",4,"matCellDef"],["matColumnDef","payment_hash"],["matColumnDef","fee"],["mat-header-cell","","mat-sort-header","","arrowPosition","before",4,"matHeaderCellDef"],["matColumnDef","value"],["matColumnDef","hops"],["matColumnDef","actions"],["mat-header-cell","","class","px-2",4,"matHeaderCellDef"],["mat-cell","","class","px-2","fxLayoutAlign","end center",4,"matCellDef"],["matColumnDef","no_payment"],["mat-footer-cell","","colspan","4",4,"matFooterCellDef"],["matColumnDef","groupTotal"],["matColumnDef","groupHash"],["matColumnDef","groupFee"],["matColumnDef","groupValue"],["matColumnDef","groupHops"],["matColumnDef","groupAction"],["mat-cell","","class","px-2",4,"matCellDef"],["mat-row","",4,"matRowDef","matRowDefColumns","matRowDefWhen"],["mat-footer-row","",3,"ngClass",4,"matFooterRowDef"],["mat-header-row","",4,"matHeaderRowDef","matHeaderRowDefSticky"],["mat-row","",4,"matRowDef","matRowDefColumns"],[1,"mb-1",3,"length","pageSize","pageSizeOptions","showFirstLastButtons","page"],["mode","indeterminate"],["mat-header-cell","","mat-sort-header",""],["mat-cell",""],["class","dot green","matTooltip","Succeeded","matTooltipPosition","right",3,"ngClass",4,"ngIf"],["class","dot red","matTooltip","Failed","matTooltipPosition","right",3,"ngClass",4,"ngIf"],["matTooltip","Succeeded","matTooltipPosition","right",1,"dot","green",3,"ngClass"],["matTooltip","Failed","matTooltipPosition","right",1,"dot","red",3,"ngClass"],["fxLayout","row",1,"ellipsis-parent",3,"ngStyle"],[1,"ellipsis-child"],["mat-header-cell","","mat-sort-header","","arrowPosition","before"],["fxLayoutAlign","end center"],["mat-header-cell","",1,"px-2"],[1,"bordered-box","table-actions-select"],["placeholder","Actions","tabindex","1",1,"mr-0"],[3,"click"],["mat-cell","","fxLayoutAlign","end center",1,"px-2"],["mat-stroked-button","","color","primary","type","button","tabindex","4",3,"click"],["mat-footer-cell","","colspan","4"],["fxLayoutAlign","start center",1,"htlc-row-span"],["fxLayoutAlign","start center","class","htlc-row-span pl-3",4,"ngFor","ngForOf"],["fxLayoutAlign","start center",1,"htlc-row-span","pl-3"],["fxLayoutAlign","start center","class","htlc-row-span",4,"ngFor","ngForOf"],["fxLayoutAlign","end center",1,"htlc-row-span"],["fxLayoutAlign","end center","class","htlc-row-span",4,"ngFor","ngForOf"],["mat-cell","",1,"px-2"],["mat-flat-button","","color","primary","type","button","tabindex","5",1,"btn-htlc-expand",3,"click"],["fxLayoutAlign","end center",4,"ngFor","ngForOf"],["mat-stroked-button","","color","primary","type","button","tabindex","6",1,"btn-htlc-info",3,"click"],["mat-row",""],["mat-footer-row","",3,"ngClass"],["mat-header-row",""]],template:function(t,a){1&t&&(e.TgZ(0,"div",0),e.YNc(1,On,12,3,"form",1),e.YNc(2,Un,3,0,"div",2),e.YNc(3,La,50,18,"div",3),e.qZA()),2&t&&(e.xp6(1),e.Q6J("ngIf","home"===a.calledFrom),e.xp6(1),e.Q6J("ngIf","transactions"===a.calledFrom),e.xp6(1),e.Q6J("ngIf","transactions"===a.calledFrom))},directives:[_.xw,_.yH,_.Wh,m.O5,c._Y,c.JL,c.F,f.KE,R.Nt,c.Fj,c.Q7,Y.$V,c.JJ,c.On,L.lW,f.bx,f.TO,I.BN,r.BZ,Z.YE,m.mk,S.oO,r.w1,r.fO,r.Dz,r.mD,r.nj,r.Ke,r.as,q.NW,M.pW,r.ge,Z.nU,r.ev,W.gM,m.PC,S.Zl,O.gD,O.$L,E.ey,r.yh,m.sg,r.Gk,r.Q2,r.XQ],pipes:[m.uU,m.JJ],styles:[".mat-column-actions[_ngcontent-%COMP%]{min-height:4.8rem}.mat-column-payment_hash[_ngcontent-%COMP%]{flex:0 0 20%;width:20%}.mat-column-payment_hash[_ngcontent-%COMP%] .ellipsis-parent[_ngcontent-%COMP%]{display:flex}.mat-column-groupAction[_ngcontent-%COMP%]{min-height:4.8rem}.mat-column-groupAction[_ngcontent-%COMP%] .btn-htlc-expand[_ngcontent-%COMP%]{width:9rem}.mat-column-groupAction[_ngcontent-%COMP%] .btn-htlc-info[_ngcontent-%COMP%]{margin-top:.5rem;width:9rem}.htlc-row-span[_ngcontent-%COMP%]{min-height:4.2rem;place-content:center flex-start;align-items:center}.mat-column-groupTotal[_ngcontent-%COMP%]{min-width:17rem}"]}),n})();function ka(n,i){if(1&n&&(e.TgZ(0,"button",26),e.TgZ(1,"mat-icon"),e._uU(2,"more_vert"),e.qZA(),e.qZA()),2&n){e.oxw();const t=e.MAs(11);e.Q6J("matMenuTriggerFor",t)}}function Fa(n,i){if(1&n){const t=e.EpF();e.TgZ(0,"button",27),e.NdJ("click",function(){const s=e.CHM(t).index,u=e.oxw().$implicit;return e.oxw(2).onNavigateTo(u.links[s])}),e._uU(1),e.qZA()}if(2&n){const t=i.$implicit;e.xp6(1),e.Oqu(t)}}function Na(n,i){if(1&n){const t=e.EpF();e.TgZ(0,"button",27),e.NdJ("click",function(){return e.CHM(t),e.oxw(3).onsortChannelsBy()}),e._uU(1),e.qZA()}if(2&n){const t=e.oxw(3);e.xp6(1),e.hij("Sort By ","Balance Score"===t.sortField?"Capacity":"Balance Score","")}}function Oa(n,i){1&n&&e._UZ(0,"mat-progress-bar",28)}function Ua(n,i){if(1&n&&e._UZ(0,"rtl-node-info",29),2&n){const t=e.oxw(3);e.Q6J("information",t.information)("showColorFieldSeparately",!1)}}function Ra(n,i){if(1&n&&e._UZ(0,"rtl-balances-info",30),2&n){const t=e.oxw(3);e.Q6J("balances",t.balances)("errorMessage",t.errorMessages[3]+" "+t.errorMessages[2])}}function Ia(n,i){if(1&n&&e._UZ(0,"rtl-channel-capacity-info",31),2&n){const t=e.oxw(3);e.Q6J("sortBy",t.sortField)("channelBalances",t.channelBalances)("allChannels",t.allChannelsCapacity)("errorMessage",t.errorMessages[3])}}function Da(n,i){if(1&n&&e._UZ(0,"rtl-fee-info",32),2&n){const t=e.oxw(3);e.Q6J("fees",t.fees)("errorMessage",t.errorMessages[1])}}function Pa(n,i){if(1&n&&e._UZ(0,"rtl-channel-status-info",33),2&n){const t=e.oxw(3);e.Q6J("channelsStatus",t.channelsStatus)("errorMessage",t.errorMessages[3]+" "+t.errorMessages[4])}}function Ma(n,i){1&n&&(e.TgZ(0,"h3"),e._uU(1,"Error! Unable to find information!"),e.qZA())}const Re=function(n){return{"dashboard-card-content":!0,"error-border":n}};function Ja(n,i){if(1&n&&(e.TgZ(0,"mat-grid-tile",8),e.TgZ(1,"mat-card",9),e.TgZ(2,"mat-card-header"),e.TgZ(3,"mat-card-title",10),e.TgZ(4,"div"),e._UZ(5,"fa-icon",11),e.TgZ(6,"span"),e._uU(7),e.qZA(),e.qZA(),e.TgZ(8,"div"),e.YNc(9,ka,3,1,"button",12),e.TgZ(10,"mat-menu",13,14),e.YNc(12,Fa,2,1,"button",15),e.YNc(13,Na,2,1,"button",16),e.qZA(),e.qZA(),e.qZA(),e.qZA(),e.TgZ(14,"mat-card-content",17),e.YNc(15,Oa,1,0,"mat-progress-bar",18),e.TgZ(16,"div",19),e.YNc(17,Ua,1,2,"rtl-node-info",20),e.YNc(18,Ra,1,2,"rtl-balances-info",21),e.YNc(19,Ia,1,4,"rtl-channel-capacity-info",22),e.YNc(20,Da,1,2,"rtl-fee-info",23),e.YNc(21,Pa,1,2,"rtl-channel-status-info",24),e.YNc(22,Ma,2,0,"h3",25),e.qZA(),e.qZA(),e.qZA(),e.qZA()),2&n){const t=i.$implicit,a=e.oxw(2);e.Q6J("colspan",t.cols)("rowspan",t.rows),e.xp6(5),e.Q6J("icon",t.icon),e.xp6(2),e.Oqu(t.title),e.xp6(2),e.Q6J("ngIf",t.links[0]),e.xp6(3),e.Q6J("ngForOf",t.goToOptions),e.xp6(1),e.Q6J("ngIf","capacity"===t.id),e.xp6(1),e.s9C("fxFlex","node"===t.id||"balance"===t.id?70:"fee"===t.id||"status"===t.id?78:90),e.Q6J("ngClass",e.VKq(16,Re,"node"===t.id&&a.apiCallStatusNodeInfo.status===a.apiCallStatusEnum.ERROR||"balance"===t.id&&(a.apiCallStatusChannels.status===a.apiCallStatusEnum.ERROR||a.apiCallStatusBlockchainBalance.status===a.apiCallStatusEnum.ERROR)||"capacity"===t.id&&a.apiCallStatusChannels.status===a.apiCallStatusEnum.ERROR||"fee"===t.id&&a.apiCallStatusFees.status===a.apiCallStatusEnum.ERROR||"status"===t.id&&(a.apiCallStatusChannels.status===a.apiCallStatusEnum.ERROR||a.apiCallStatusPendingChannels.status===a.apiCallStatusEnum.ERROR))),e.xp6(1),e.Q6J("ngIf","node"===t.id&&a.apiCallStatusNodeInfo.status===a.apiCallStatusEnum.INITIATED||"balance"===t.id&&(a.apiCallStatusChannels.status===a.apiCallStatusEnum.INITIATED||a.apiCallStatusBlockchainBalance.status===a.apiCallStatusEnum.INITIATED)||"capacity"===t.id&&a.apiCallStatusChannels.status===a.apiCallStatusEnum.INITIATED||"fee"===t.id&&a.apiCallStatusFees.status===a.apiCallStatusEnum.INITIATED||"status"===t.id&&(a.apiCallStatusChannels.status===a.apiCallStatusEnum.INITIATED||a.apiCallStatusPendingChannels.status===a.apiCallStatusEnum.INITIATED)),e.xp6(1),e.Q6J("ngSwitch",t.id),e.xp6(1),e.Q6J("ngSwitchCase","node"),e.xp6(1),e.Q6J("ngSwitchCase","balance"),e.xp6(1),e.Q6J("ngSwitchCase","capacity"),e.xp6(1),e.Q6J("ngSwitchCase","fee"),e.xp6(1),e.Q6J("ngSwitchCase","status")}}function Qa(n,i){if(1&n&&(e.TgZ(0,"div",2),e.TgZ(1,"div",3),e._UZ(2,"fa-icon",4),e.TgZ(3,"span",5),e._uU(4),e.qZA(),e.qZA(),e.TgZ(5,"mat-grid-list",6),e.YNc(6,Ja,23,18,"mat-grid-tile",7),e.qZA(),e.qZA()),2&n){const t=e.oxw();e.xp6(2),e.Q6J("icon",t.apiCallStatusNodeInfo.status===t.apiCallStatusEnum.ERROR?t.faFrown:t.faSmile),e.xp6(2),e.Oqu(t.apiCallStatusNodeInfo.status===t.apiCallStatusEnum.COMPLETED?"Welcome "+t.information.alias+"! Your node is up and running.":t.apiCallStatusNodeInfo.status===t.apiCallStatusEnum.INITIATED?"Wait! Getting your node information...":"Error! Please check the server connection."),e.xp6(1),e.Q6J("rowHeight",t.operatorCardHeight),e.xp6(1),e.Q6J("ngForOf",t.operatorCards)}}function Ea(n,i){if(1&n&&(e.TgZ(0,"button",26),e.TgZ(1,"mat-icon"),e._uU(2,"more_vert"),e.qZA(),e.qZA()),2&n){e.oxw();const t=e.MAs(9);e.Q6J("matMenuTriggerFor",t)}}function Ya(n,i){if(1&n){const t=e.EpF();e.TgZ(0,"button",27),e.NdJ("click",function(){const s=e.CHM(t).index,u=e.oxw(2).$implicit;return e.oxw(2).onNavigateTo(u.links[s])}),e._uU(1),e.qZA()}if(2&n){const t=i.$implicit;e.xp6(1),e.Oqu(t)}}function Ba(n,i){if(1&n&&(e.TgZ(0,"mat-card-header"),e.TgZ(1,"mat-card-title",10),e.TgZ(2,"div"),e._UZ(3,"fa-icon",11),e.TgZ(4,"span"),e._uU(5),e.qZA(),e.qZA(),e.TgZ(6,"div"),e.YNc(7,Ea,3,1,"button",12),e.TgZ(8,"mat-menu",13,43),e.YNc(10,Ya,2,1,"button",15),e.qZA(),e.qZA(),e.qZA(),e.qZA()),2&n){const t=e.oxw().$implicit;e.xp6(3),e.Q6J("icon",t.icon),e.xp6(2),e.Oqu(t.title),e.xp6(2),e.Q6J("ngIf",t.links[0]),e.xp6(3),e.Q6J("ngForOf",t.goToOptions)}}function Ha(n,i){1&n&&e._UZ(0,"mat-progress-bar",28)}function Ga(n,i){if(1&n&&e._UZ(0,"rtl-node-info",44),2&n){const t=e.oxw(3);e.Q6J("information",t.information)}}function za(n,i){if(1&n&&e._UZ(0,"rtl-balances-info",30),2&n){const t=e.oxw(3);e.Q6J("balances",t.balances)("errorMessage",t.errorMessages[3]+" "+t.errorMessages[2])}}function Va(n,i){if(1&n&&e._UZ(0,"rtl-channel-liquidity-info",45),2&n){const t=e.oxw(3);e.Q6J("direction","In")("totalLiquidity",t.totalInboundLiquidity)("allChannels",t.allInboundChannels)("errorMessage",t.errorMessages[3])}}function Wa(n,i){if(1&n&&e._UZ(0,"rtl-channel-liquidity-info",45),2&n){const t=e.oxw(3);e.Q6J("direction","Out")("totalLiquidity",t.totalOutboundLiquidity)("allChannels",t.allOutboundChannels)("errorMessage",t.errorMessages[3])}}function Xa(n,i){if(1&n){const t=e.EpF();e.TgZ(0,"button",27),e.NdJ("click",function(){const s=e.CHM(t).index,u=e.oxw(3).$implicit;return e.oxw(2).onNavigateTo(u.links[s])}),e._uU(1),e.qZA()}if(2&n){const t=i.$implicit;e.xp6(1),e.Oqu(t)}}function $a(n,i){if(1&n&&(e.TgZ(0,"button",26),e.TgZ(1,"mat-icon"),e._uU(2,"more_vert"),e.qZA(),e.qZA(),e.TgZ(3,"mat-menu",13,53),e.YNc(5,Xa,2,1,"button",15),e.qZA()),2&n){const t=e.MAs(4),a=e.oxw(2).$implicit;e.Q6J("matMenuTriggerFor",t),e.xp6(5),e.Q6J("ngForOf",a.goToOptions)}}function ja(n,i){1&n&&(e.TgZ(0,"span",46),e.TgZ(1,"mat-tab-group",47),e.TgZ(2,"mat-tab",48),e._UZ(3,"rtl-lightning-invoices",49),e.qZA(),e.TgZ(4,"mat-tab",50),e._UZ(5,"rtl-lightning-payments",49),e.qZA(),e.TgZ(6,"mat-tab",51),e.YNc(7,$a,6,2,"ng-template",52),e.qZA(),e.qZA(),e.qZA()),2&n&&(e.xp6(3),e.Q6J("calledFrom","home"),e.xp6(2),e.Q6J("calledFrom","home"),e.xp6(1),e.Q6J("disabled",!0))}function Ka(n,i){1&n&&(e.TgZ(0,"h3"),e._uU(1,"Error! Unable to find information!"),e.qZA())}const ei=function(n){return{"p-0":n}};function ti(n,i){if(1&n&&(e.TgZ(0,"mat-grid-tile",8),e.TgZ(1,"mat-card",36),e.YNc(2,Ba,11,4,"mat-card-header",37),e.TgZ(3,"mat-card-content",38),e.YNc(4,Ha,1,0,"mat-progress-bar",18),e.TgZ(5,"div",39),e.YNc(6,Ga,1,1,"rtl-node-info",40),e.YNc(7,za,1,2,"rtl-balances-info",21),e.YNc(8,Va,1,4,"rtl-channel-liquidity-info",41),e.YNc(9,Wa,1,4,"rtl-channel-liquidity-info",41),e.YNc(10,ja,8,3,"span",42),e.YNc(11,Ka,2,0,"h3",25),e.qZA(),e.qZA(),e.qZA(),e.qZA()),2&n){const t=i.$implicit,a=e.oxw(2);e.Q6J("colspan",t.cols)("rowspan",t.rows),e.xp6(1),e.Q6J("ngClass",e.VKq(13,ei,"transactions"===t.id)),e.xp6(1),e.Q6J("ngIf","transactions"!==t.id),e.xp6(1),e.s9C("fxFlex","transactions"===t.id?100:"balance"===t.id?70:90),e.Q6J("ngClass",e.VKq(15,Re,"node"===t.id&&a.apiCallStatusNodeInfo.status===a.apiCallStatusEnum.ERROR||"balance"===t.id&&(a.apiCallStatusChannels.status===a.apiCallStatusEnum.ERROR||a.apiCallStatusBlockchainBalance.status===a.apiCallStatusEnum.ERROR)||("inboundLiq"===t.id||"outboundLiq"===t.id)&&a.apiCallStatusChannels.status===a.apiCallStatusEnum.ERROR)),e.xp6(1),e.Q6J("ngIf","node"===t.id&&a.apiCallStatusNodeInfo.status===a.apiCallStatusEnum.INITIATED||"balance"===t.id&&(a.apiCallStatusChannels.status===a.apiCallStatusEnum.INITIATED||a.apiCallStatusBlockchainBalance.status===a.apiCallStatusEnum.INITIATED)||("inboundLiq"===t.id||"outboundLiq"===t.id)&&a.apiCallStatusChannels.status===a.apiCallStatusEnum.INITIATED),e.xp6(1),e.Q6J("ngSwitch",t.id),e.xp6(1),e.Q6J("ngSwitchCase","node"),e.xp6(1),e.Q6J("ngSwitchCase","balance"),e.xp6(1),e.Q6J("ngSwitchCase","inboundLiq"),e.xp6(1),e.Q6J("ngSwitchCase","outboundLiq"),e.xp6(1),e.Q6J("ngSwitchCase","transactions")}}function ni(n,i){if(1&n&&(e.TgZ(0,"div",34),e._UZ(1,"fa-icon",4),e.TgZ(2,"span",5),e._uU(3),e.qZA(),e.qZA(),e.TgZ(4,"mat-grid-list",35),e.YNc(5,ti,12,17,"mat-grid-tile",7),e.qZA()),2&n){const t=e.oxw();e.xp6(1),e.Q6J("icon",t.faSmile),e.xp6(2),e.hij("Welcome ",t.information.alias,"! Your node is up and running."),e.xp6(1),e.Q6J("rowHeight",t.merchantCardHeight),e.xp6(1),e.Q6J("ngForOf",t.merchantCards)}}let ai=(()=>{class n{constructor(t,a,o,s,u){switch(this.logger=t,this.store=a,this.actions=o,this.commonService=s,this.router=u,this.faSmile=ve.I3,this.faFrown=ve.Kf,this.faAngleDoubleDown=y.Sbq,this.faAngleDoubleUp=y.Vfw,this.faChartPie=y.OS1,this.faBolt=y.BDt,this.faServer=y.xf3,this.faNetworkWired=y.kXW,this.flgChildInfoUpdated=!1,this.userPersonaEnum=l.ol,this.activeChannels=0,this.inactiveChannels=0,this.channelBalances={localBalance:0,remoteBalance:0,balancedness:0},this.selNode={},this.information={},this.balances={onchain:-1,lightning:-1,total:0},this.allChannels=[],this.channelsStatus={},this.allChannelsCapacity=[],this.allInboundChannels=[],this.allOutboundChannels=[],this.totalInboundLiquidity=0,this.totalOutboundLiquidity=0,this.operatorCards=[],this.merchantCards=[],this.screenSize="",this.operatorCardHeight="330px",this.merchantCardHeight="65px",this.sortField="Balance Score",this.screenSizeEnum=l.cu,this.errorMessages=["","","","",""],this.apiCallStatusNodeInfo=null,this.apiCallStatusFees=null,this.apiCallStatusBlockchainBalance=null,this.apiCallStatusChannels=null,this.apiCallStatusPendingChannels=null,this.apiCallStatusEnum=l.Bn,this.unSubs=[new p.x,new p.x,new p.x,new p.x,new p.x,new p.x,new p.x,new p.x,new p.x],this.screenSize=this.commonService.getScreenSize(),this.screenSize){case l.cu.XS:this.operatorCards=[{id:"node",goToOptions:[],links:[],icon:this.faServer,title:"Node Information",cols:10,rows:1},{id:"balance",goToOptions:["On-Chain"],links:["onchain"],icon:this.faChartPie,title:"Balances",cols:10,rows:1},{id:"fee",goToOptions:["Routing","Fees Summary"],links:["routing","reports"],icon:this.faBolt,title:"Routing Fee",cols:10,rows:1},{id:"status",goToOptions:["Channels","Inactive Channels"],links:["connections","inactive"],icon:this.faNetworkWired,title:"Channels",cols:10,rows:1},{id:"capacity",goToOptions:["Channels"],links:["connections"],icon:this.faNetworkWired,title:"Channels Capacity",cols:10,rows:2}],this.merchantCards=[{id:"balance",goToOptions:["On-Chain"],links:["onchain"],icon:this.faChartPie,title:"Balances",cols:6,rows:4},{id:"transactions",goToOptions:["Transactions","Transactions Summary"],links:["transactions","reports/transactions"],title:"",cols:6,rows:6},{id:"inboundLiq",goToOptions:["Channels"],links:["connections"],icon:this.faAngleDoubleDown,title:"In-Bound Liquidity",cols:6,rows:8},{id:"outboundLiq",goToOptions:["Channels"],links:["connections"],icon:this.faAngleDoubleUp,title:"Out-Bound Liquidity",cols:6,rows:8}];break;case l.cu.SM:case l.cu.MD:this.operatorCards=[{id:"node",goToOptions:[],links:[],icon:this.faServer,title:"Node Information",cols:5,rows:1},{id:"balance",goToOptions:["On-Chain"],links:["onchain"],icon:this.faChartPie,title:"Balances",cols:5,rows:1},{id:"fee",goToOptions:["Routing","Fees Summary"],links:["routing","reports"],icon:this.faBolt,title:"Routing Fee",cols:5,rows:1},{id:"status",goToOptions:["Channels","Inactive Channels"],links:["connections","inactive"],icon:this.faNetworkWired,title:"Channels",cols:5,rows:1},{id:"capacity",goToOptions:["Channels"],links:["connections"],icon:this.faNetworkWired,title:"Channels Capacity",cols:10,rows:2}],this.merchantCards=[{id:"balance",goToOptions:["On-Chain"],links:["onchain"],icon:this.faChartPie,title:"Balances",cols:3,rows:4},{id:"transactions",goToOptions:["Transactions","Transactions Summary"],links:["transactions","reports/transactions"],title:"",cols:3,rows:4},{id:"inboundLiq",goToOptions:["Channels"],links:["connections"],icon:this.faAngleDoubleDown,title:"In-Bound Liquidity",cols:3,rows:8},{id:"outboundLiq",goToOptions:["Channels"],links:["connections"],icon:this.faAngleDoubleUp,title:"Out-Bound Liquidity",cols:3,rows:8}];break;default:this.operatorCards=[{id:"node",goToOptions:[],links:[],icon:this.faServer,title:"Node Information",cols:3,rows:1},{id:"balance",goToOptions:["On-Chain"],links:["onchain"],icon:this.faChartPie,title:"Balances",cols:3,rows:1},{id:"capacity",goToOptions:["Channels"],links:["connections"],icon:this.faNetworkWired,title:"Channels Capacity",cols:4,rows:2},{id:"fee",goToOptions:["Routing","Fees Summary"],links:["routing","reports"],icon:this.faBolt,title:"Routing Fee",cols:3,rows:1},{id:"status",goToOptions:["Channels","Inactive Channels"],links:["connections","inactive"],icon:this.faNetworkWired,title:"Channels",cols:3,rows:1}],this.merchantCards=[{id:"balance",goToOptions:["On-Chain"],links:["onchain"],icon:this.faChartPie,title:"Balances",cols:2,rows:5},{id:"inboundLiq",goToOptions:["Channels"],links:["connections"],icon:this.faAngleDoubleDown,title:"In-Bound Liquidity",cols:2,rows:10},{id:"outboundLiq",goToOptions:["Channels"],links:["connections"],icon:this.faAngleDoubleUp,title:"Out-Bound Liquidity",cols:2,rows:10},{id:"transactions",goToOptions:["Transactions","Transactions Summary"],links:["transactions","reports/transactions"],title:"",cols:2,rows:5}]}}ngOnInit(){this.store.select(C.bx).pipe((0,d.R)(this.unSubs[0])).subscribe(t=>{this.errorMessages[0]="",this.apiCallStatusNodeInfo=t.apiCallStatus,this.apiCallStatusNodeInfo.status===l.Bn.ERROR&&(this.errorMessages[0]="object"==typeof this.apiCallStatusNodeInfo.message?JSON.stringify(this.apiCallStatusNodeInfo.message):this.apiCallStatusNodeInfo.message),this.selNode=t.nodeSettings,this.information=t.information}),this.store.select(C.JG).pipe((0,d.R)(this.unSubs[1])).subscribe(t=>{this.errorMessages[1]="",this.apiCallStatusFees=t.apiCallStatus,this.apiCallStatusFees.status===l.Bn.ERROR&&(this.errorMessages[1]="object"==typeof this.apiCallStatusFees.message?JSON.stringify(this.apiCallStatusFees.message):this.apiCallStatusFees.message),this.fees=t.fees}),this.store.select(C.qU).pipe((0,d.R)(this.unSubs[2])).subscribe(t=>{this.errorMessages[2]="",this.apiCallStatusBlockchainBalance=t.apiCallStatus,this.apiCallStatusBlockchainBalance.status===l.Bn.ERROR&&(this.errorMessages[2]="object"==typeof this.apiCallStatusBlockchainBalance.message?JSON.stringify(this.apiCallStatusBlockchainBalance.message):this.apiCallStatusBlockchainBalance.message),this.balances.onchain=+t.blockchainBalance.total_balance>=0?+t.blockchainBalance.total_balance:0,this.balances.total=this.balances.lightning+this.balances.onchain,this.balances=Object.assign({},this.balances)}),this.store.select(C.ni).pipe((0,d.R)(this.unSubs[3])).subscribe(t=>{this.errorMessages[4]="",this.apiCallStatusPendingChannels=t.apiCallStatus,this.apiCallStatusPendingChannels.status===l.Bn.ERROR&&(this.errorMessages[4]="object"==typeof this.apiCallStatusPendingChannels.message?JSON.stringify(this.apiCallStatusPendingChannels.message):this.apiCallStatusPendingChannels.message),this.channelsStatus.pending={num_channels:t.pendingChannelsSummary.open.num_channels,capacity:t.pendingChannelsSummary.open.limbo_balance},this.channelsStatus.closing={num_channels:t.pendingChannelsSummary.closing.num_channels+t.pendingChannelsSummary.force_closing.num_channels+t.pendingChannelsSummary.waiting_close.num_channels,capacity:t.pendingChannelsSummary.total_limbo_balance}}),this.store.select(C.ZW).pipe((0,d.R)(this.unSubs[4])).subscribe(t=>{this.errorMessages[3]="",this.apiCallStatusChannels=t.apiCallStatus,this.apiCallStatusChannels.status===l.Bn.ERROR&&(this.errorMessages[3]="object"==typeof this.apiCallStatusChannels.message?JSON.stringify(this.apiCallStatusChannels.message):this.apiCallStatusChannels.message);const a=t.lightningBalance&&t.lightningBalance.local?+t.lightningBalance.local:0,o=t.lightningBalance&&t.lightningBalance.remote?+t.lightningBalance.remote:0;this.channelBalances={localBalance:a,remoteBalance:o,balancedness:+(1-Math.abs((a-o)/(a+o))).toFixed(3)},this.balances.lightning=t.lightningBalance.local,this.balances.total=this.balances.lightning+this.balances.onchain,this.balances=Object.assign({},this.balances),this.activeChannels=t.channelsSummary.active.num_channels,this.inactiveChannels=t.channelsSummary.inactive.num_channels,this.channelsStatus.active=t.channelsSummary.active,this.channelsStatus.inactive=t.channelsSummary.inactive,this.totalInboundLiquidity=0,this.totalOutboundLiquidity=0,this.allChannels=t.channels.filter(u=>!0===u.active),this.allChannelsCapacity=JSON.parse(JSON.stringify(this.commonService.sortDescByKey(this.allChannels,"balancedness"))),this.allInboundChannels=JSON.parse(JSON.stringify(this.commonService.sortDescByKey(this.allChannels.filter(u=>u.remote_balance>0),"remote_balance"))),this.allOutboundChannels=JSON.parse(JSON.stringify(this.commonService.sortDescByKey(this.allChannels.filter(u=>u.local_balance>0),"local_balance"))),this.allChannels.forEach(u=>{this.totalInboundLiquidity=this.totalInboundLiquidity+ +u.remote_balance,this.totalOutboundLiquidity=this.totalOutboundLiquidity+ +u.local_balance}),this.flgChildInfoUpdated=this.balances.lightning>=0&&this.balances.onchain>=0&&this.fees.month_fee_sum>=0,this.logger.info(t)}),this.actions.pipe((0,d.R)(this.unSubs[5]),(0,Q.h)(t=>t.type===l.uR.FETCH_FEES_LND||t.type===l.uR.SET_FEES_LND)).subscribe(t=>{t.type===l.uR.FETCH_FEES_LND&&(this.flgChildInfoUpdated=!1),t.type===l.uR.SET_FEES_LND&&(this.flgChildInfoUpdated=!0)})}onNavigateTo(t){"inactive"===t?this.router.navigateByUrl("/lnd/connections",{state:{filter:t}}):this.router.navigateByUrl("/lnd/"+t)}onsortChannelsBy(){"Balance Score"===this.sortField?(this.sortField="Capacity",this.allChannelsCapacity=this.allChannels.sort((t,a)=>{const o=+t.local_balance+ +t.remote_balance,s=+a.local_balance+ +a.remote_balance;return o>s?-1:o
Channel: "+u.alias.padEnd(20)+"			Amount (Sats): "+a.decimalPipe.transform(s.amt_to_forward)+""):a.dataService.getAliasesFromPubkeys(s.pub_key,!1).pipe((0,d.R)(a.unSubs[6])).subscribe(g=>{o.push("
Channel: "+(g.node&&g.node.alias?g.node.alias.padEnd(20):s.pub_key.substring(0,17)+"...")+"			Amount (Sats): "+a.decimalPipe.transform(s.amt_to_forward)+"")}),o},[])}onHTLCClick(t,a){a.payment_request&&""!==a.payment_request.trim()?this.dataService.decodePayment(a.payment_request,!1).pipe((0,V.q)(1)).subscribe({next:o=>{setTimeout(()=>{this.showHTLCView(t,a,o)},0)},error:o=>{this.showHTLCView(t,a,null)}}):this.showHTLCView(t,a,null)}showHTLCView(t,a,o){const s=[[{key:"payment_hash",value:a.payment_hash,title:"Payment Hash",width:100,type:l.Gi.STRING}],[{key:"preimage",value:t.preimage,title:"Preimage",width:100,type:l.Gi.STRING}],[{key:"payment_request",value:a.payment_request,title:"Payment Request",width:100,type:l.Gi.STRING}],[{key:"status",value:t.status,title:"Status",width:33,type:l.Gi.STRING},{key:"attempt_time_ns",value:+t.attempt_time_ns/1e9,title:"Attempt Time",width:33,type:l.Gi.DATE_TIME},{key:"resolve_time_ns",value:+t.resolve_time_ns/1e9,title:"Resolve Time",width:34,type:l.Gi.DATE_TIME}],[{key:"total_amt",value:t.route.total_amt,title:"Amount (Sats)",width:33,type:l.Gi.NUMBER},{key:"total_fees",value:t.route.total_fees,title:"Fee (Sats)",width:33,type:l.Gi.NUMBER},{key:"total_time_lock",value:t.route.total_time_lock,title:"Total Time Lock",width:34,type:l.Gi.NUMBER}],[{key:"hops",value:this.getHopDetails(t.route.hops),title:"Hops",width:100,type:l.Gi.ARRAY}]];o&&o.description&&""!==o.description&&s.splice(3,0,[{key:"description",value:o.description,title:"Description",width:100,type:l.Gi.STRING}]),this.store.dispatch((0,v.qR)({payload:{data:{type:l.n_.INFORMATION,alertTitle:"HTLC Information",message:s,scrollable:t.route&&t.route.hops&&t.route.hops.length>1}}}))}onPaymentClick(t){if(t.htlcs&&t.htlcs[0]&&t.htlcs[0].route&&t.htlcs[0].route.hops&&t.htlcs[0].route.hops.length>0){const a=t.htlcs[0].route.hops.reduce((o,s)=>""===o?s.pub_key:o+","+s.pub_key,"");this.dataService.getAliasesFromPubkeys(a,!0).pipe((0,d.R)(this.unSubs[7])).subscribe(o=>{this.showPaymentView(t,o.reduce((s,u)=>""===s?u:s+"\n"+u,""))})}else this.showPaymentView(t,"")}showPaymentView(t,a){const o=[[{key:"payment_hash",value:t.payment_hash,title:"Payment Hash",width:100,type:l.Gi.STRING}],[{key:"payment_preimage",value:t.payment_preimage,title:"Payment Preimage",width:100,type:l.Gi.STRING}],[{key:"payment_request",value:t.payment_request,title:"Payment Request",width:100,type:l.Gi.STRING}],[{key:"status",value:t.status,title:"Status",width:50,type:l.Gi.STRING},{key:"creation_date",value:t.creation_date,title:"Creation Date",width:50,type:l.Gi.DATE_TIME}],[{key:"value_msat",value:t.value_msat,title:"Value (mSats)",width:50,type:l.Gi.NUMBER},{key:"fee_msat",value:t.fee_msat,title:"Fee (mSats)",width:50,type:l.Gi.NUMBER}],[{key:"path",value:a,title:"Path",width:100,type:l.Gi.STRING}]];t.payment_request&&""!==t.payment_request.trim()?this.dataService.decodePayment(t.payment_request,!1).pipe((0,V.q)(1)).subscribe(s=>{s&&s.description&&""!==s.description&&o.splice(3,0,[{key:"description",value:s.description,title:"Description",width:100,type:l.Gi.STRING}]),setTimeout(()=>{this.openPaymentAlert(o,t.htlcs&&t.htlcs[0]&&t.htlcs[0].route&&t.htlcs[0].route.hops&&t.htlcs[0].route.hops.length>1)},0)}):this.openPaymentAlert(o,!1)}openPaymentAlert(t,a){this.store.dispatch((0,v.qR)({payload:{data:{type:l.n_.INFORMATION,alertTitle:"Payment Information",message:t,scrollable:a}}}))}applyFilter(){this.payments.filter=this.selFilter.trim().toLowerCase()}loadPaymentsTable(t){this.payments=new r.by(t?[...t]:[]),this.payments.sortingDataAccessor=(a,o)=>"hops"===o?a.htlcs.length&&a.htlcs[0]&&a.htlcs[0].route&&a.htlcs[0].route.hops&&a.htlcs[0].route.hops.length?a.htlcs[0].route.hops.length:0:a[o]&&isNaN(a[o])?a[o].toLocaleLowerCase():a[o]?+a[o]:null,this.payments.sort=this.sort,this.payments.filterPredicate=(a,o)=>((a.creation_date?this.datePipe.transform(new Date(1e3*a.creation_date),"dd/MMM/YYYY HH:mm").toLowerCase():"")+JSON.stringify(a).toLowerCase()).includes(o),this.applyFilter()}onDownloadCSV(){if(this.payments.data&&this.payments.data.length>0){const t=JSON.parse(JSON.stringify(this.payments.data)),a=t.reduce((o,s)=>(s.payment_request&&""!==s.payment_request.trim()&&(o=""===o?s.payment_request:o+","+s.payment_request),o),"");this.dataService.decodePayments(a).pipe((0,d.R)(this.unSubs[8])).subscribe(o=>{let s=0;o.forEach((g,N)=>{if(g){for(;t[N+s].payment_hash!==g.payment_hash;)s+=1;t[N+s].description=g.description}});const u=t.reduce((g,N)=>g.concat(N),[]);this.commonService.downloadFile(u,"Payments")})}}ngOnDestroy(){this.unSubs.forEach(t=>{t.next(null),t.complete()})}}return n.\u0275fac=function(t){return new(t||n)(e.Y36(F.mQ),e.Y36(O.v),e.Y36(j.D),e.Y36(w.yh),e.Y36(ie.V),e.Y36(ee.l),e.Y36(p.JJ),e.Y36(p.uU))},n.\u0275cmp=e.Xpm({type:n,selectors:[["rtl-lightning-payments"]],viewQuery:function(t,a){if(1&t&&(e.Gf(Nn,5),e.Gf(A.YE,5),e.Gf(S.NW,5)),2&t){let o;e.iGM(o=e.CRH())&&(a.form=o.first),e.iGM(o=e.CRH())&&(a.sort=o.first),e.iGM(o=e.CRH())&&(a.paginator=o.first)}},inputs:{calledFrom:"calledFrom"},features:[e._Bn([{provide:S.ye,useValue:(0,l.pt)("Payments")}])],decls:4,vars:3,consts:[["fxLayout","column","fxFlex","100","fxLayoutAlign","space-between stretch",1,"padding-gap-x"],["fxLayoutAlign","space-between stretch","fxLayout","row wrap",4,"ngIf"],["fxLayout","row",4,"ngIf"],["fxLayout","column","fxLayoutAlign","start stretch",4,"ngIf"],["fxLayoutAlign","space-between stretch","fxLayout","row wrap"],["sendPaymentForm","ngForm"],["fxFlex","100"],["matInput","","placeholder","Payment Request","name","paymentRequest","tabindex","1","required","",3,"perfectScrollbar","ngModel","ngModelChange","matTextareaAutosize"],["paymentReq","ngModel"],[4,"ngIf"],["fxLayout","row",1,"mt-1"],["mat-stroked-button","","color","primary","tabindex","2","type","reset",1,"mr-1",3,"click"],["mat-flat-button","","color","primary","tabindex","3",3,"click"],["fxLayout","row"],["mat-flat-button","","color","primary","tabindex","4",3,"click"],["fxLayout","column","fxLayoutAlign","start stretch"],["fxLayout","column","fxLayoutAlign","start stretch","fxLayout.gt-sm","row wrap",1,"page-sub-title-container","mt-1"],["fxFlex","70","fxLayoutAlign","start start","fxLayoutAlign.gt-sm","start center"],[1,"page-title-img","mr-1",3,"icon"],[1,"page-title"],["fxFlex","30","fxLayoutAlign","start end"],["matInput","","placeholder","Filter",3,"ngModel","keyup","ngModelChange"],["fxLayout","row","fxLayoutAlign","start start"],["fxLayout","column","fxLayoutAlign","start end","fxFlex","100",1,"table-container",3,"perfectScrollbar"],["mode","indeterminate",4,"ngIf"],["mat-table","","fxFlex","100","matSort","",3,"dataSource","ngClass"],["table",""],["matColumnDef","creation_date"],["mat-header-cell","","mat-sort-header","",4,"matHeaderCellDef"],["mat-cell","",4,"matCellDef"],["matColumnDef","payment_hash"],["matColumnDef","fee"],["mat-header-cell","","mat-sort-header","","arrowPosition","before",4,"matHeaderCellDef"],["matColumnDef","value"],["matColumnDef","hops"],["matColumnDef","actions"],["mat-header-cell","","class","px-2",4,"matHeaderCellDef"],["mat-cell","","class","px-2","fxLayoutAlign","end center",4,"matCellDef"],["matColumnDef","no_payment"],["mat-footer-cell","","colspan","4",4,"matFooterCellDef"],["matColumnDef","groupTotal"],["matColumnDef","groupHash"],["matColumnDef","groupFee"],["matColumnDef","groupValue"],["matColumnDef","groupHops"],["matColumnDef","groupAction"],["mat-cell","","class","px-2",4,"matCellDef"],["mat-row","",4,"matRowDef","matRowDefColumns","matRowDefWhen"],["mat-footer-row","",3,"ngClass",4,"matFooterRowDef"],["mat-header-row","",4,"matHeaderRowDef","matHeaderRowDefSticky"],["mat-row","",4,"matRowDef","matRowDefColumns"],[1,"mb-1",3,"length","pageSize","pageSizeOptions","showFirstLastButtons","page"],["mode","indeterminate"],["mat-header-cell","","mat-sort-header",""],["mat-cell",""],["class","dot green","matTooltip","Succeeded","matTooltipPosition","right",3,"ngClass",4,"ngIf"],["class","dot red","matTooltip","Failed","matTooltipPosition","right",3,"ngClass",4,"ngIf"],["matTooltip","Succeeded","matTooltipPosition","right",1,"dot","green",3,"ngClass"],["matTooltip","Failed","matTooltipPosition","right",1,"dot","red",3,"ngClass"],["fxLayout","row",1,"ellipsis-parent",3,"ngStyle"],[1,"ellipsis-child"],["mat-header-cell","","mat-sort-header","","arrowPosition","before"],["fxLayoutAlign","end center"],["mat-header-cell","",1,"px-2"],[1,"bordered-box","table-actions-select"],["placeholder","Actions","tabindex","1",1,"mr-0"],[3,"click"],["mat-cell","","fxLayoutAlign","end center",1,"px-2"],["mat-stroked-button","","color","primary","type","button","tabindex","4",3,"click"],["mat-footer-cell","","colspan","4"],["fxLayoutAlign","start center",1,"htlc-row-span"],["fxLayoutAlign","start center","class","htlc-row-span pl-3",4,"ngFor","ngForOf"],["fxLayoutAlign","start center",1,"htlc-row-span","pl-3"],["fxLayoutAlign","start center","class","htlc-row-span",4,"ngFor","ngForOf"],["fxLayoutAlign","end center",1,"htlc-row-span"],["fxLayoutAlign","end center","class","htlc-row-span",4,"ngFor","ngForOf"],["mat-cell","",1,"px-2"],["mat-flat-button","","color","primary","type","button","tabindex","5",1,"btn-htlc-expand",3,"click"],["fxLayoutAlign","end center",4,"ngFor","ngForOf"],["mat-stroked-button","","color","primary","type","button","tabindex","6",1,"btn-htlc-info",3,"click"],["mat-row",""],["mat-footer-row","",3,"ngClass"],["mat-header-row",""]],template:function(t,a){1&t&&(e.TgZ(0,"div",0),e.YNc(1,In,12,3,"form",1),e.YNc(2,Mn,3,0,"div",2),e.YNc(3,Ua,50,18,"div",3),e.qZA()),2&t&&(e.xp6(1),e.Q6J("ngIf","home"===a.calledFrom),e.xp6(1),e.Q6J("ngIf","transactions"===a.calledFrom),e.xp6(1),e.Q6J("ngIf","transactions"===a.calledFrom))},directives:[_.xw,_.yH,_.Wh,p.O5,c._Y,c.JL,c.F,f.KE,I.Nt,c.Fj,c.Q7,Q.$V,c.JJ,c.On,L.lW,f.bx,f.TO,M.BN,r.BZ,A.YE,p.mk,q.oO,r.w1,r.fO,r.Dz,r.mD,r.nj,r.Ke,r.as,S.NW,P.pW,r.ge,A.nU,r.ev,X.gM,p.PC,q.Zl,R.gD,R.$L,Y.ey,r.yh,p.sg,r.Gk,r.Q2,r.XQ],pipes:[p.uU,p.JJ],styles:[".mat-column-actions[_ngcontent-%COMP%]{min-height:4.8rem}.mat-column-payment_hash[_ngcontent-%COMP%]{flex:0 0 20%;width:20%}.mat-column-payment_hash[_ngcontent-%COMP%] .ellipsis-parent[_ngcontent-%COMP%]{display:flex}.mat-column-groupAction[_ngcontent-%COMP%]{min-height:4.8rem}.mat-column-groupAction[_ngcontent-%COMP%] .btn-htlc-expand[_ngcontent-%COMP%]{width:9rem}.mat-column-groupAction[_ngcontent-%COMP%] .btn-htlc-info[_ngcontent-%COMP%]{margin-top:.5rem;width:9rem}.htlc-row-span[_ngcontent-%COMP%]{min-height:4.2rem;place-content:center flex-start;align-items:center}.mat-column-groupTotal[_ngcontent-%COMP%]{min-width:17rem}"]}),n})();function Na(n,i){if(1&n&&(e.TgZ(0,"button",26),e.TgZ(1,"mat-icon"),e._uU(2,"more_vert"),e.qZA(),e.qZA()),2&n){e.oxw();const t=e.MAs(11);e.Q6J("matMenuTriggerFor",t)}}function Oa(n,i){if(1&n){const t=e.EpF();e.TgZ(0,"button",27),e.NdJ("click",function(){const s=e.CHM(t).index,u=e.oxw().$implicit;return e.oxw(2).onNavigateTo(u.links[s])}),e._uU(1),e.qZA()}if(2&n){const t=i.$implicit;e.xp6(1),e.Oqu(t)}}function Ra(n,i){if(1&n){const t=e.EpF();e.TgZ(0,"button",27),e.NdJ("click",function(){return e.CHM(t),e.oxw(3).onsortChannelsBy()}),e._uU(1),e.qZA()}if(2&n){const t=e.oxw(3);e.xp6(1),e.hij("Sort By ","Balance Score"===t.sortField?"Capacity":"Balance Score","")}}function Ia(n,i){1&n&&e._UZ(0,"mat-progress-bar",28)}function Ma(n,i){if(1&n&&e._UZ(0,"rtl-node-info",29),2&n){const t=e.oxw(3);e.Q6J("information",t.information)("showColorFieldSeparately",!1)}}function Da(n,i){if(1&n&&e._UZ(0,"rtl-balances-info",30),2&n){const t=e.oxw(3);e.Q6J("balances",t.balances)("errorMessage",t.errorMessages[3]+" "+t.errorMessages[2])}}function Pa(n,i){if(1&n&&e._UZ(0,"rtl-channel-capacity-info",31),2&n){const t=e.oxw(3);e.Q6J("sortBy",t.sortField)("channelBalances",t.channelBalances)("allChannels",t.allChannelsCapacity)("errorMessage",t.errorMessages[3])}}function Ja(n,i){if(1&n&&e._UZ(0,"rtl-fee-info",32),2&n){const t=e.oxw(3);e.Q6J("fees",t.fees)("errorMessage",t.errorMessages[1])}}function Ea(n,i){if(1&n&&e._UZ(0,"rtl-channel-status-info",33),2&n){const t=e.oxw(3);e.Q6J("channelsStatus",t.channelsStatus)("errorMessage",t.errorMessages[3]+" "+t.errorMessages[4])}}function Qa(n,i){1&n&&(e.TgZ(0,"h3"),e._uU(1,"Error! Unable to find information!"),e.qZA())}const Pe=function(n){return{"dashboard-card-content":!0,"error-border":n}};function Ya(n,i){if(1&n&&(e.TgZ(0,"mat-grid-tile",8),e.TgZ(1,"mat-card",9),e.TgZ(2,"mat-card-header"),e.TgZ(3,"mat-card-title",10),e.TgZ(4,"div"),e._UZ(5,"fa-icon",11),e.TgZ(6,"span"),e._uU(7),e.qZA(),e.qZA(),e.TgZ(8,"div"),e.YNc(9,Na,3,1,"button",12),e.TgZ(10,"mat-menu",13,14),e.YNc(12,Oa,2,1,"button",15),e.YNc(13,Ra,2,1,"button",16),e.qZA(),e.qZA(),e.qZA(),e.qZA(),e.TgZ(14,"mat-card-content",17),e.YNc(15,Ia,1,0,"mat-progress-bar",18),e.TgZ(16,"div",19),e.YNc(17,Ma,1,2,"rtl-node-info",20),e.YNc(18,Da,1,2,"rtl-balances-info",21),e.YNc(19,Pa,1,4,"rtl-channel-capacity-info",22),e.YNc(20,Ja,1,2,"rtl-fee-info",23),e.YNc(21,Ea,1,2,"rtl-channel-status-info",24),e.YNc(22,Qa,2,0,"h3",25),e.qZA(),e.qZA(),e.qZA(),e.qZA()),2&n){const t=i.$implicit,a=e.oxw(2);e.Q6J("colspan",t.cols)("rowspan",t.rows),e.xp6(5),e.Q6J("icon",t.icon),e.xp6(2),e.Oqu(t.title),e.xp6(2),e.Q6J("ngIf",t.links[0]),e.xp6(3),e.Q6J("ngForOf",t.goToOptions),e.xp6(1),e.Q6J("ngIf","capacity"===t.id),e.xp6(1),e.s9C("fxFlex","node"===t.id||"balance"===t.id?70:"fee"===t.id||"status"===t.id?78:90),e.Q6J("ngClass",e.VKq(16,Pe,"node"===t.id&&a.apiCallStatusNodeInfo.status===a.apiCallStatusEnum.ERROR||"balance"===t.id&&(a.apiCallStatusChannels.status===a.apiCallStatusEnum.ERROR||a.apiCallStatusBlockchainBalance.status===a.apiCallStatusEnum.ERROR)||"capacity"===t.id&&a.apiCallStatusChannels.status===a.apiCallStatusEnum.ERROR||"fee"===t.id&&a.apiCallStatusFees.status===a.apiCallStatusEnum.ERROR||"status"===t.id&&(a.apiCallStatusChannels.status===a.apiCallStatusEnum.ERROR||a.apiCallStatusPendingChannels.status===a.apiCallStatusEnum.ERROR))),e.xp6(1),e.Q6J("ngIf","node"===t.id&&a.apiCallStatusNodeInfo.status===a.apiCallStatusEnum.INITIATED||"balance"===t.id&&(a.apiCallStatusChannels.status===a.apiCallStatusEnum.INITIATED||a.apiCallStatusBlockchainBalance.status===a.apiCallStatusEnum.INITIATED)||"capacity"===t.id&&a.apiCallStatusChannels.status===a.apiCallStatusEnum.INITIATED||"fee"===t.id&&a.apiCallStatusFees.status===a.apiCallStatusEnum.INITIATED||"status"===t.id&&(a.apiCallStatusChannels.status===a.apiCallStatusEnum.INITIATED||a.apiCallStatusPendingChannels.status===a.apiCallStatusEnum.INITIATED)),e.xp6(1),e.Q6J("ngSwitch",t.id),e.xp6(1),e.Q6J("ngSwitchCase","node"),e.xp6(1),e.Q6J("ngSwitchCase","balance"),e.xp6(1),e.Q6J("ngSwitchCase","capacity"),e.xp6(1),e.Q6J("ngSwitchCase","fee"),e.xp6(1),e.Q6J("ngSwitchCase","status")}}function Ha(n,i){if(1&n&&(e.TgZ(0,"div",2),e.TgZ(1,"div",3),e._UZ(2,"fa-icon",4),e.TgZ(3,"span",5),e._uU(4),e.qZA(),e.qZA(),e.TgZ(5,"mat-grid-list",6),e.YNc(6,Ya,23,18,"mat-grid-tile",7),e.qZA(),e.qZA()),2&n){const t=e.oxw();e.xp6(2),e.Q6J("icon",t.apiCallStatusNodeInfo.status===t.apiCallStatusEnum.ERROR?t.faFrown:t.faSmile),e.xp6(2),e.Oqu(t.apiCallStatusNodeInfo.status===t.apiCallStatusEnum.COMPLETED?"Welcome "+t.information.alias+"! Your node is up and running.":t.apiCallStatusNodeInfo.status===t.apiCallStatusEnum.INITIATED?"Wait! Getting your node information...":"Error! Please check the server connection."),e.xp6(1),e.Q6J("rowHeight",t.operatorCardHeight),e.xp6(1),e.Q6J("ngForOf",t.operatorCards)}}function Ba(n,i){if(1&n&&(e.TgZ(0,"button",26),e.TgZ(1,"mat-icon"),e._uU(2,"more_vert"),e.qZA(),e.qZA()),2&n){e.oxw();const t=e.MAs(9);e.Q6J("matMenuTriggerFor",t)}}function Va(n,i){if(1&n){const t=e.EpF();e.TgZ(0,"button",27),e.NdJ("click",function(){const s=e.CHM(t).index,u=e.oxw(2).$implicit;return e.oxw(2).onNavigateTo(u.links[s])}),e._uU(1),e.qZA()}if(2&n){const t=i.$implicit;e.xp6(1),e.Oqu(t)}}function Ga(n,i){if(1&n&&(e.TgZ(0,"mat-card-header"),e.TgZ(1,"mat-card-title",10),e.TgZ(2,"div"),e._UZ(3,"fa-icon",11),e.TgZ(4,"span"),e._uU(5),e.qZA(),e.qZA(),e.TgZ(6,"div"),e.YNc(7,Ba,3,1,"button",12),e.TgZ(8,"mat-menu",13,43),e.YNc(10,Va,2,1,"button",15),e.qZA(),e.qZA(),e.qZA(),e.qZA()),2&n){const t=e.oxw().$implicit;e.xp6(3),e.Q6J("icon",t.icon),e.xp6(2),e.Oqu(t.title),e.xp6(2),e.Q6J("ngIf",t.links[0]),e.xp6(3),e.Q6J("ngForOf",t.goToOptions)}}function za(n,i){1&n&&e._UZ(0,"mat-progress-bar",28)}function Wa(n,i){if(1&n&&e._UZ(0,"rtl-node-info",44),2&n){const t=e.oxw(3);e.Q6J("information",t.information)}}function Xa(n,i){if(1&n&&e._UZ(0,"rtl-balances-info",30),2&n){const t=e.oxw(3);e.Q6J("balances",t.balances)("errorMessage",t.errorMessages[3]+" "+t.errorMessages[2])}}function $a(n,i){if(1&n&&e._UZ(0,"rtl-channel-liquidity-info",45),2&n){const t=e.oxw(3);e.Q6J("direction","In")("totalLiquidity",t.totalInboundLiquidity)("allChannels",t.allInboundChannels)("errorMessage",t.errorMessages[3])}}function ja(n,i){if(1&n&&e._UZ(0,"rtl-channel-liquidity-info",45),2&n){const t=e.oxw(3);e.Q6J("direction","Out")("totalLiquidity",t.totalOutboundLiquidity)("allChannels",t.allOutboundChannels)("errorMessage",t.errorMessages[3])}}function Ka(n,i){if(1&n){const t=e.EpF();e.TgZ(0,"button",27),e.NdJ("click",function(){const s=e.CHM(t).index,u=e.oxw(3).$implicit;return e.oxw(2).onNavigateTo(u.links[s])}),e._uU(1),e.qZA()}if(2&n){const t=i.$implicit;e.xp6(1),e.Oqu(t)}}function ei(n,i){if(1&n&&(e.TgZ(0,"button",26),e.TgZ(1,"mat-icon"),e._uU(2,"more_vert"),e.qZA(),e.qZA(),e.TgZ(3,"mat-menu",13,53),e.YNc(5,Ka,2,1,"button",15),e.qZA()),2&n){const t=e.MAs(4),a=e.oxw(2).$implicit;e.Q6J("matMenuTriggerFor",t),e.xp6(5),e.Q6J("ngForOf",a.goToOptions)}}function ti(n,i){1&n&&(e.TgZ(0,"span",46),e.TgZ(1,"mat-tab-group",47),e.TgZ(2,"mat-tab",48),e._UZ(3,"rtl-lightning-invoices",49),e.qZA(),e.TgZ(4,"mat-tab",50),e._UZ(5,"rtl-lightning-payments",49),e.qZA(),e.TgZ(6,"mat-tab",51),e.YNc(7,ei,6,2,"ng-template",52),e.qZA(),e.qZA(),e.qZA()),2&n&&(e.xp6(3),e.Q6J("calledFrom","home"),e.xp6(2),e.Q6J("calledFrom","home"),e.xp6(1),e.Q6J("disabled",!0))}function ni(n,i){1&n&&(e.TgZ(0,"h3"),e._uU(1,"Error! Unable to find information!"),e.qZA())}const ai=function(n){return{"p-0":n}};function ii(n,i){if(1&n&&(e.TgZ(0,"mat-grid-tile",8),e.TgZ(1,"mat-card",36),e.YNc(2,Ga,11,4,"mat-card-header",37),e.TgZ(3,"mat-card-content",38),e.YNc(4,za,1,0,"mat-progress-bar",18),e.TgZ(5,"div",39),e.YNc(6,Wa,1,1,"rtl-node-info",40),e.YNc(7,Xa,1,2,"rtl-balances-info",21),e.YNc(8,$a,1,4,"rtl-channel-liquidity-info",41),e.YNc(9,ja,1,4,"rtl-channel-liquidity-info",41),e.YNc(10,ti,8,3,"span",42),e.YNc(11,ni,2,0,"h3",25),e.qZA(),e.qZA(),e.qZA(),e.qZA()),2&n){const t=i.$implicit,a=e.oxw(2);e.Q6J("colspan",t.cols)("rowspan",t.rows),e.xp6(1),e.Q6J("ngClass",e.VKq(13,ai,"transactions"===t.id)),e.xp6(1),e.Q6J("ngIf","transactions"!==t.id),e.xp6(1),e.s9C("fxFlex","transactions"===t.id?100:"balance"===t.id?70:90),e.Q6J("ngClass",e.VKq(15,Pe,"node"===t.id&&a.apiCallStatusNodeInfo.status===a.apiCallStatusEnum.ERROR||"balance"===t.id&&(a.apiCallStatusChannels.status===a.apiCallStatusEnum.ERROR||a.apiCallStatusBlockchainBalance.status===a.apiCallStatusEnum.ERROR)||("inboundLiq"===t.id||"outboundLiq"===t.id)&&a.apiCallStatusChannels.status===a.apiCallStatusEnum.ERROR)),e.xp6(1),e.Q6J("ngIf","node"===t.id&&a.apiCallStatusNodeInfo.status===a.apiCallStatusEnum.INITIATED||"balance"===t.id&&(a.apiCallStatusChannels.status===a.apiCallStatusEnum.INITIATED||a.apiCallStatusBlockchainBalance.status===a.apiCallStatusEnum.INITIATED)||("inboundLiq"===t.id||"outboundLiq"===t.id)&&a.apiCallStatusChannels.status===a.apiCallStatusEnum.INITIATED),e.xp6(1),e.Q6J("ngSwitch",t.id),e.xp6(1),e.Q6J("ngSwitchCase","node"),e.xp6(1),e.Q6J("ngSwitchCase","balance"),e.xp6(1),e.Q6J("ngSwitchCase","inboundLiq"),e.xp6(1),e.Q6J("ngSwitchCase","outboundLiq"),e.xp6(1),e.Q6J("ngSwitchCase","transactions")}}function oi(n,i){if(1&n&&(e.TgZ(0,"div",34),e._UZ(1,"fa-icon",4),e.TgZ(2,"span",5),e._uU(3),e.qZA(),e.qZA(),e.TgZ(4,"mat-grid-list",35),e.YNc(5,ii,12,17,"mat-grid-tile",7),e.qZA()),2&n){const t=e.oxw();e.xp6(1),e.Q6J("icon",t.faSmile),e.xp6(2),e.hij("Welcome ",t.information.alias,"! Your node is up and running."),e.xp6(1),e.Q6J("rowHeight",t.merchantCardHeight),e.xp6(1),e.Q6J("ngForOf",t.merchantCards)}}let si=(()=>{class n{constructor(t,a,o,s,u){switch(this.logger=t,this.store=a,this.actions=o,this.commonService=s,this.router=u,this.faSmile=Le.I3,this.faFrown=Le.Kf,this.faAngleDoubleDown=Z.Sbq,this.faAngleDoubleUp=Z.Vfw,this.faChartPie=Z.OS1,this.faBolt=Z.BDt,this.faServer=Z.xf3,this.faNetworkWired=Z.kXW,this.flgChildInfoUpdated=!1,this.userPersonaEnum=l.ol,this.activeChannels=0,this.inactiveChannels=0,this.channelBalances={localBalance:0,remoteBalance:0,balancedness:0},this.selNode={},this.information={},this.balances={onchain:-1,lightning:-1,total:0},this.allChannels=[],this.channelsStatus={},this.allChannelsCapacity=[],this.allInboundChannels=[],this.allOutboundChannels=[],this.totalInboundLiquidity=0,this.totalOutboundLiquidity=0,this.operatorCards=[],this.merchantCards=[],this.screenSize="",this.operatorCardHeight="330px",this.merchantCardHeight="65px",this.sortField="Balance Score",this.screenSizeEnum=l.cu,this.errorMessages=["","","","",""],this.apiCallStatusNodeInfo=null,this.apiCallStatusFees=null,this.apiCallStatusBlockchainBalance=null,this.apiCallStatusChannels=null,this.apiCallStatusPendingChannels=null,this.apiCallStatusEnum=l.Bn,this.unSubs=[new m.x,new m.x,new m.x,new m.x,new m.x,new m.x,new m.x,new m.x,new m.x],this.screenSize=this.commonService.getScreenSize(),this.screenSize){case l.cu.XS:this.operatorCards=[{id:"node",goToOptions:[],links:[],icon:this.faServer,title:"Node Information",cols:10,rows:1},{id:"balance",goToOptions:["On-Chain"],links:["onchain"],icon:this.faChartPie,title:"Balances",cols:10,rows:1},{id:"fee",goToOptions:["Routing","Fees Summary"],links:["routing","reports"],icon:this.faBolt,title:"Routing Fee",cols:10,rows:1},{id:"status",goToOptions:["Channels","Inactive Channels"],links:["connections","inactive"],icon:this.faNetworkWired,title:"Channels",cols:10,rows:1},{id:"capacity",goToOptions:["Channels"],links:["connections"],icon:this.faNetworkWired,title:"Channels Capacity",cols:10,rows:2}],this.merchantCards=[{id:"balance",goToOptions:["On-Chain"],links:["onchain"],icon:this.faChartPie,title:"Balances",cols:6,rows:4},{id:"transactions",goToOptions:["Transactions","Transactions Summary"],links:["transactions","reports/transactions"],title:"",cols:6,rows:6},{id:"inboundLiq",goToOptions:["Channels"],links:["connections"],icon:this.faAngleDoubleDown,title:"In-Bound Liquidity",cols:6,rows:8},{id:"outboundLiq",goToOptions:["Channels"],links:["connections"],icon:this.faAngleDoubleUp,title:"Out-Bound Liquidity",cols:6,rows:8}];break;case l.cu.SM:case l.cu.MD:this.operatorCards=[{id:"node",goToOptions:[],links:[],icon:this.faServer,title:"Node Information",cols:5,rows:1},{id:"balance",goToOptions:["On-Chain"],links:["onchain"],icon:this.faChartPie,title:"Balances",cols:5,rows:1},{id:"fee",goToOptions:["Routing","Fees Summary"],links:["routing","reports"],icon:this.faBolt,title:"Routing Fee",cols:5,rows:1},{id:"status",goToOptions:["Channels","Inactive Channels"],links:["connections","inactive"],icon:this.faNetworkWired,title:"Channels",cols:5,rows:1},{id:"capacity",goToOptions:["Channels"],links:["connections"],icon:this.faNetworkWired,title:"Channels Capacity",cols:10,rows:2}],this.merchantCards=[{id:"balance",goToOptions:["On-Chain"],links:["onchain"],icon:this.faChartPie,title:"Balances",cols:3,rows:4},{id:"transactions",goToOptions:["Transactions","Transactions Summary"],links:["transactions","reports/transactions"],title:"",cols:3,rows:4},{id:"inboundLiq",goToOptions:["Channels"],links:["connections"],icon:this.faAngleDoubleDown,title:"In-Bound Liquidity",cols:3,rows:8},{id:"outboundLiq",goToOptions:["Channels"],links:["connections"],icon:this.faAngleDoubleUp,title:"Out-Bound Liquidity",cols:3,rows:8}];break;default:this.operatorCards=[{id:"node",goToOptions:[],links:[],icon:this.faServer,title:"Node Information",cols:3,rows:1},{id:"balance",goToOptions:["On-Chain"],links:["onchain"],icon:this.faChartPie,title:"Balances",cols:3,rows:1},{id:"capacity",goToOptions:["Channels"],links:["connections"],icon:this.faNetworkWired,title:"Channels Capacity",cols:4,rows:2},{id:"fee",goToOptions:["Routing","Fees Summary"],links:["routing","reports"],icon:this.faBolt,title:"Routing Fee",cols:3,rows:1},{id:"status",goToOptions:["Channels","Inactive Channels"],links:["connections","inactive"],icon:this.faNetworkWired,title:"Channels",cols:3,rows:1}],this.merchantCards=[{id:"balance",goToOptions:["On-Chain"],links:["onchain"],icon:this.faChartPie,title:"Balances",cols:2,rows:5},{id:"inboundLiq",goToOptions:["Channels"],links:["connections"],icon:this.faAngleDoubleDown,title:"In-Bound Liquidity",cols:2,rows:10},{id:"outboundLiq",goToOptions:["Channels"],links:["connections"],icon:this.faAngleDoubleUp,title:"Out-Bound Liquidity",cols:2,rows:10},{id:"transactions",goToOptions:["Transactions","Transactions Summary"],links:["transactions","reports/transactions"],title:"",cols:2,rows:5}]}}ngOnInit(){this.store.select(C.bx).pipe((0,d.R)(this.unSubs[0])).subscribe(t=>{this.errorMessages[0]="",this.apiCallStatusNodeInfo=t.apiCallStatus,this.apiCallStatusNodeInfo.status===l.Bn.ERROR&&(this.errorMessages[0]="object"==typeof this.apiCallStatusNodeInfo.message?JSON.stringify(this.apiCallStatusNodeInfo.message):this.apiCallStatusNodeInfo.message),this.selNode=t.nodeSettings,this.information=t.information}),this.store.select(C.JG).pipe((0,d.R)(this.unSubs[1])).subscribe(t=>{this.errorMessages[1]="",this.apiCallStatusFees=t.apiCallStatus,this.apiCallStatusFees.status===l.Bn.ERROR&&(this.errorMessages[1]="object"==typeof this.apiCallStatusFees.message?JSON.stringify(this.apiCallStatusFees.message):this.apiCallStatusFees.message),this.fees=t.fees}),this.store.select(C.qU).pipe((0,d.R)(this.unSubs[2])).subscribe(t=>{this.errorMessages[2]="",this.apiCallStatusBlockchainBalance=t.apiCallStatus,this.apiCallStatusBlockchainBalance.status===l.Bn.ERROR&&(this.errorMessages[2]="object"==typeof this.apiCallStatusBlockchainBalance.message?JSON.stringify(this.apiCallStatusBlockchainBalance.message):this.apiCallStatusBlockchainBalance.message),this.balances.onchain=+t.blockchainBalance.total_balance>=0?+t.blockchainBalance.total_balance:0,this.balances.total=this.balances.lightning+this.balances.onchain,this.balances=Object.assign({},this.balances)}),this.store.select(C.ni).pipe((0,d.R)(this.unSubs[3])).subscribe(t=>{this.errorMessages[4]="",this.apiCallStatusPendingChannels=t.apiCallStatus,this.apiCallStatusPendingChannels.status===l.Bn.ERROR&&(this.errorMessages[4]="object"==typeof this.apiCallStatusPendingChannels.message?JSON.stringify(this.apiCallStatusPendingChannels.message):this.apiCallStatusPendingChannels.message),this.channelsStatus.pending={num_channels:t.pendingChannelsSummary.open.num_channels,capacity:t.pendingChannelsSummary.open.limbo_balance},this.channelsStatus.closing={num_channels:t.pendingChannelsSummary.closing.num_channels+t.pendingChannelsSummary.force_closing.num_channels+t.pendingChannelsSummary.waiting_close.num_channels,capacity:t.pendingChannelsSummary.total_limbo_balance}}),this.store.select(C.ZW).pipe((0,d.R)(this.unSubs[4])).subscribe(t=>{this.errorMessages[3]="",this.apiCallStatusChannels=t.apiCallStatus,this.apiCallStatusChannels.status===l.Bn.ERROR&&(this.errorMessages[3]="object"==typeof this.apiCallStatusChannels.message?JSON.stringify(this.apiCallStatusChannels.message):this.apiCallStatusChannels.message);const a=t.lightningBalance&&t.lightningBalance.local?+t.lightningBalance.local:0,o=t.lightningBalance&&t.lightningBalance.remote?+t.lightningBalance.remote:0;this.channelBalances={localBalance:a,remoteBalance:o,balancedness:+(1-Math.abs((a-o)/(a+o))).toFixed(3)},this.balances.lightning=t.lightningBalance.local,this.balances.total=this.balances.lightning+this.balances.onchain,this.balances=Object.assign({},this.balances),this.activeChannels=t.channelsSummary.active.num_channels,this.inactiveChannels=t.channelsSummary.inactive.num_channels,this.channelsStatus.active=t.channelsSummary.active,this.channelsStatus.inactive=t.channelsSummary.inactive,this.totalInboundLiquidity=0,this.totalOutboundLiquidity=0,this.allChannels=t.channels.filter(u=>!0===u.active),this.allChannelsCapacity=JSON.parse(JSON.stringify(this.commonService.sortDescByKey(this.allChannels,"balancedness"))),this.allInboundChannels=JSON.parse(JSON.stringify(this.commonService.sortDescByKey(this.allChannels.filter(u=>u.remote_balance>0),"remote_balance"))),this.allOutboundChannels=JSON.parse(JSON.stringify(this.commonService.sortDescByKey(this.allChannels.filter(u=>u.local_balance>0),"local_balance"))),this.allChannels.forEach(u=>{this.totalInboundLiquidity=this.totalInboundLiquidity+ +u.remote_balance,this.totalOutboundLiquidity=this.totalOutboundLiquidity+ +u.local_balance}),this.flgChildInfoUpdated=this.balances.lightning>=0&&this.balances.onchain>=0&&this.fees.month_fee_sum>=0,this.logger.info(t)}),this.actions.pipe((0,d.R)(this.unSubs[5]),(0,E.h)(t=>t.type===l.uR.FETCH_FEES_LND||t.type===l.uR.SET_FEES_LND)).subscribe(t=>{t.type===l.uR.FETCH_FEES_LND&&(this.flgChildInfoUpdated=!1),t.type===l.uR.SET_FEES_LND&&(this.flgChildInfoUpdated=!0)})}onNavigateTo(t){"inactive"===t?this.router.navigateByUrl("/lnd/connections",{state:{filter:t}}):this.router.navigateByUrl("/lnd/"+t)}onsortChannelsBy(){"Balance Score"===this.sortField?(this.sortField="Capacity",this.allChannelsCapacity=this.allChannels.sort((t,a)=>{const o=+t.local_balance+ +t.remote_balance,s=+a.local_balance+ +a.remote_balance;return o>s?-1:o
1&&q>2&&(TA>4?(_+="\n".concat(S,"...").concat(L),CA=!0):TA>3&&(_+="\n ".concat(bA[q-2]),GA++),_+="\n ".concat(bA[q-1]),GA++),dA=q,_+="\n".concat(x,"+").concat(L," ").concat(bA[q]),GA++;else{var rt=XA[q],Dt=bA[q],pt=Dt!==rt&&(!v(Dt,",")||Dt.slice(0,-1)!==rt);pt&&v(rt,",")&&rt.slice(0,-1)===Dt&&(pt=!1,Dt+=","),pt?(TA>1&&q>2&&(TA>4?(_+="\n".concat(S,"...").concat(L),CA=!0):TA>3&&(_+="\n ".concat(bA[q-2]),GA++),_+="\n ".concat(bA[q-1]),GA++),dA=q,_+="\n".concat(x,"+").concat(L," ").concat(Dt),FA+="\n".concat(N,"-").concat(L," ").concat(rt),GA+=2):(_+=FA,FA="",(1===TA||0===q)&&(_+="\n ".concat(Dt),GA++))}if(GA>20&&q30)for(q[26]="".concat(S,"...").concat(L);q.length>27;)q.pop();FA=B(this,1===q.length?Q(BA).call(this,"".concat(XA," ").concat(q[0])):Q(BA).call(this,"".concat(XA,"\n\n").concat(q.join("\n"),"\n")))}else{var H=cA(CA),$="",W=V[dA];"notDeepEqual"===dA||"notEqual"===dA?(H="".concat(V[dA],"\n\n").concat(H)).length>1024&&(H="".concat(H.slice(0,1021),"...")):($="".concat(cA(SA)),H.length>512&&(H="".concat(H.slice(0,509),"...")),$.length>512&&($="".concat($.slice(0,509),"...")),"deepEqual"===dA||"equal"===dA?H="".concat(W,"\n\n").concat(H,"\n\nshould equal\n\n"):$=" ".concat(dA," ").concat($)),FA=B(this,Q(BA).call(this,"".concat(H).concat($)))}return Error.stackTraceLimit=bA,FA.generatedMessage=!_,Object.defineProperty(h(FA),"name",{value:"AssertionError [ERR_ASSERTION]",enumerable:!1,writable:!0,configurable:!0}),FA.code="ERR_ASSERTION",FA.actual=CA,FA.expected=SA,FA.operator=dA,Error.captureStackTrace&&Error.captureStackTrace(h(FA),uA),FA.name="AssertionError",B(FA)}return function(lA,BA){if("function"!=typeof BA&&null!==BA)throw new TypeError("Super expression must either be null or a function");lA.prototype=Object.create(BA&&BA.prototype,{constructor:{value:lA,writable:!0,configurable:!0}}),BA&&w(lA,BA)}(BA,lA),function(lA,BA,vA){BA&&E(lA.prototype,BA),vA&&E(lA,vA)}(BA,[{key:"toString",value:function(){return"".concat(this.name," [").concat(this.code,"]: ").concat(this.message)}},{key:m.custom,value:function(FA,_){return m(this,function(lA){for(var BA=1;BA 2?"one of ".concat(Y," ").concat(M.slice(0,m-1).join(", "),", or ")+M[m-1]:2===m?"one of ".concat(Y," ").concat(M[0]," or ").concat(M[1]):"of ".concat(Y," ").concat(M[0])}return"of ".concat(Y," ").concat(String(M))}e("ERR_AMBIGUOUS_ARGUMENT",'The "%s" argument is ambiguous. %s',TypeError),e("ERR_INVALID_ARG_TYPE",function(M,Y,m){var p,D;if(void 0===u&&(u=n(9282)),u("string"==typeof M,"'name' must be a string"),"string"==typeof Y&&function(M,Y,m){return M.substr(!m||m<0?0:+m,Y.length)===Y}(Y,"not ")?(p="must not be",Y=Y.replace(/^not /,"")):p="must be",function(M,Y,m){return(void 0===m||m>M.length)&&(m=M.length),M.substring(m-Y.length,m)===Y}(M," argument"))D="The ".concat(M," ").concat(p," ").concat(f(Y,"type"));else{var v=function(M,Y,m){return"number"!=typeof m&&(m=0),!(m+Y.length>M.length)&&-1!==M.indexOf(Y,m)}(M,".")?"property":"argument";D='The "'.concat(M,'" ').concat(v," ").concat(p," ").concat(f(Y,"type"))}return D+". Received type ".concat(c(m))},TypeError),e("ERR_INVALID_ARG_VALUE",function(M,Y){var m=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"is invalid";void 0===C&&(C=n(9539));var p=C.inspect(Y);return p.length>128&&(p="".concat(p.slice(0,128),"...")),"The argument '".concat(M,"' ").concat(m,". Received ").concat(p)},TypeError,RangeError),e("ERR_INVALID_RETURN_VALUE",function(M,Y,m){var p;return p=m&&m.constructor&&m.constructor.name?"instance of ".concat(m.constructor.name):"type ".concat(c(m)),"Expected ".concat(M,' to be returned from the "').concat(Y,'"')+" function but got ".concat(p,".")},TypeError),e("ERR_MISSING_ARGS",function(){for(var M=arguments.length,Y=new Array(M),m=0;m 0,"At least one arg needs to be specified");var p="The ",D=Y.length;switch(Y=Y.map(function(v){return'"'.concat(v,'"')}),D){case 1:p+="".concat(Y[0]," argument");break;case 2:p+="".concat(Y[0]," and ").concat(Y[1]," arguments");break;default:p+=Y.slice(0,D-1).join(", "),p+=", and ".concat(Y[D-1]," arguments")}return"".concat(p," must be specified")},TypeError),T.exports.codes=h},9158:function(T,I,n){"use strict";function c(JA,WA){return function(JA){if(Array.isArray(JA))return JA}(JA)||function(JA,WA){var it=[],yA=!0,dt=!1,ft=void 0;try{for(var Yt,KA=JA[Symbol.iterator]();!(yA=(Yt=KA.next()).done)&&(it.push(Yt.value),!WA||it.length!==WA);yA=!0);}catch(J){dt=!0,ft=J}finally{try{!yA&&null!=KA.return&&KA.return()}finally{if(dt)throw ft}}return it}(JA,WA)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}()}function E(JA){return(E="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(it){return typeof it}:function(it){return it&&"function"==typeof Symbol&&it.constructor===Symbol&&it!==Symbol.prototype?"symbol":typeof it})(JA)}var a=void 0!==/a/g.flags,B=function(WA){var it=[];return WA.forEach(function(yA){return it.push(yA)}),it},h=function(WA){var it=[];return WA.forEach(function(yA,dt){return it.push([dt,yA])}),it},u=Object.is?Object.is:n(609),C=Object.getOwnPropertySymbols?Object.getOwnPropertySymbols:function(){return[]},e=Number.isNaN?Number.isNaN:n(360);function f(JA){return JA.call.bind(JA)}var l=f(Object.prototype.hasOwnProperty),w=f(Object.prototype.propertyIsEnumerable),Q=f(Object.prototype.toString),M=n(9539).types,Y=M.isAnyArrayBuffer,m=M.isArrayBufferView,p=M.isDate,D=M.isMap,v=M.isRegExp,P=M.isSet,S=M.isNativeError,x=M.isBoxedPrimitive,N=M.isNumberObject,L=M.isStringObject,V=M.isBooleanObject,aA=M.isBigIntObject,AA=M.isSymbolObject,cA=M.isFloat32Array,MA=M.isFloat64Array;function gA(JA){if(0===JA.length||JA.length>10)return!0;for(var WA=0;WA 57)return!0}return 10===JA.length&&JA>=Math.pow(2,32)}function lA(JA){return Object.keys(JA).filter(gA).concat(C(JA).filter(Object.prototype.propertyIsEnumerable.bind(JA)))}function BA(JA,WA){if(JA===WA)return 0;for(var it=JA.length,yA=WA.length,dt=0,ft=Math.min(it,yA);dt =h.length?{done:!0}:{done:!1,value:h[e++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function o(h,u){(null==u||u>h.length)&&(u=h.length);for(var C=0,e=new Array(u);Cthis.buffer.length)return this.flush()},f.flush=function(){if(this.bufferOffset>0)return this.push(c.from(this.buffer.slice(0,this.bufferOffset))),this.bufferOffset=0},f.writeBuffer=function(w){return this.flush(),this.push(w),this.pos+=w.length},f.writeString=function(w,Q){switch(void 0===Q&&(Q="ascii"),Q){case"utf16le":case"ucs2":case"utf8":case"ascii":return this.writeBuffer(c.from(w,Q));case"utf16be":for(var M=c.from(w,"utf16le"),Y=0,m=M.length-1;Y >>16&255,this.buffer[this.bufferOffset++]=w>>>8&255,this.buffer[this.bufferOffset++]=255&w,this.pos+=3},f.writeUInt24LE=function(w){return this.ensure(3),this.buffer[this.bufferOffset++]=255&w,this.buffer[this.bufferOffset++]=w>>>8&255,this.buffer[this.bufferOffset++]=w>>>16&255,this.pos+=3},f.writeInt24BE=function(w){return this.writeUInt24BE(w>=0?w:w+16777215+1)},f.writeInt24LE=function(w){return this.writeUInt24LE(w>=0?w:w+16777215+1)},f.fill=function(w,Q){if(Q =this.length)){if(null==this.items[w]){var Q=this.stream.pos;this.stream.pos=this.base+this.type.size(null,this.ctx)*w,this.items[w]=this.type.decode(this.stream,this.ctx),this.stream.pos=Q}return this.items[w]}},f.toArray=function(){for(var w=[],Q=0,M=this.length;Q >1),(f=a.call(this,"Int"+u,C)||this)._point=1< u)throw new RangeError('The value "'+J+'" is invalid for option "size"');var O=new Uint8Array(J);return Object.setPrototypeOf(O,f.prototype),O}function f(J,O,z){if("number"==typeof J){if("string"==typeof O)throw new TypeError('The "string" argument must be of type string. Received type number');return M(J)}return l(J,O,z)}function l(J,O,z){if("string"==typeof J)return function(J,O){if(("string"!=typeof O||""===O)&&(O="utf8"),!f.isEncoding(O))throw new TypeError("Unknown encoding: "+O);var z=0|x(J,O),QA=e(z),wA=QA.write(J,O);return wA!==z&&(QA=QA.slice(0,wA)),QA}(J,O);if(ArrayBuffer.isView(J))return function(J){if(yA(J,Uint8Array)){var O=new Uint8Array(J);return D(O.buffer,O.byteOffset,O.byteLength)}return m(J)}(J);if(null==J)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof J);if(yA(J,ArrayBuffer)||J&&yA(J.buffer,ArrayBuffer)||"undefined"!=typeof SharedArrayBuffer&&(yA(J,SharedArrayBuffer)||J&&yA(J.buffer,SharedArrayBuffer)))return D(J,O,z);if("number"==typeof J)throw new TypeError('The "value" argument must not be of type number. Received type number');var QA=J.valueOf&&J.valueOf();if(null!=QA&&QA!==J)return f.from(QA,O,z);var wA=function(J){if(f.isBuffer(J)){var O=0|P(J.length),z=e(O);return 0===z.length||J.copy(z,0,0,O),z}return void 0!==J.length?"number"!=typeof J.length||dt(J.length)?e(0):m(J):"Buffer"===J.type&&Array.isArray(J.data)?m(J.data):void 0}(J);if(wA)return wA;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof J[Symbol.toPrimitive])return f.from(J[Symbol.toPrimitive]("string"),O,z);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof J)}function w(J){if("number"!=typeof J)throw new TypeError('"size" argument must be of type number');if(J<0)throw new RangeError('The value "'+J+'" is invalid for option "size"')}function M(J){return w(J),e(J<0?0:0|P(J))}function m(J){for(var O=J.length<0?0:0|P(J.length),z=e(O),QA=0;QA =u)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+u.toString(16)+" bytes");return 0|J}function x(J,O){if(f.isBuffer(J))return J.length;if(ArrayBuffer.isView(J)||yA(J,ArrayBuffer))return J.byteLength;if("string"!=typeof J)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof J);var z=J.length,QA=arguments.length>2&&!0===arguments[2];if(!QA&&0===z)return 0;for(var wA=!1;;)switch(O){case"ascii":case"latin1":case"binary":return z;case"utf8":case"utf-8":return pt(J).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*z;case"hex":return z>>>1;case"base64":return WA(J).length;default:if(wA)return QA?-1:pt(J).length;O=(""+O).toLowerCase(),wA=!0}}function N(J,O,z){var QA=!1;if((void 0===O||O<0)&&(O=0),O>this.length||((void 0===z||z>this.length)&&(z=this.length),z<=0)||(z>>>=0)<=(O>>>=0))return"";for(J||(J="utf8");;)switch(J){case"hex":return CA(this,O,z);case"utf8":case"utf-8":return vA(this,O,z);case"ascii":return dA(this,O,z);case"latin1":case"binary":return uA(this,O,z);case"base64":return BA(this,O,z);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return SA(this,O,z);default:if(QA)throw new TypeError("Unknown encoding: "+J);J=(J+"").toLowerCase(),QA=!0}}function L(J,O,z){var QA=J[O];J[O]=J[z],J[z]=QA}function V(J,O,z,QA,wA){if(0===J.length)return-1;if("string"==typeof z?(QA=z,z=0):z>2147483647?z=2147483647:z<-2147483648&&(z=-2147483648),dt(z=+z)&&(z=wA?0:J.length-1),z<0&&(z=J.length+z),z>=J.length){if(wA)return-1;z=J.length-1}else if(z<0){if(!wA)return-1;z=0}if("string"==typeof O&&(O=f.from(O,QA)),f.isBuffer(O))return 0===O.length?-1:aA(J,O,z,QA,wA);if("number"==typeof O)return O&=255,"function"==typeof Uint8Array.prototype.indexOf?wA?Uint8Array.prototype.indexOf.call(J,O,z):Uint8Array.prototype.lastIndexOf.call(J,O,z):aA(J,[O],z,QA,wA);throw new TypeError("val must be string, number or Buffer")}function aA(J,O,z,QA,wA){var j,RA=1,rA=J.length,gt=O.length;if(void 0!==QA&&("ucs2"===(QA=String(QA).toLowerCase())||"ucs-2"===QA||"utf16le"===QA||"utf-16le"===QA)){if(J.length<2||O.length<2)return-1;RA=2,rA/=2,gt/=2,z/=2}function Ft(jA,st){return 1===RA?jA[st]:jA.readUInt16BE(st*RA)}if(wA){var OA=-1;for(j=z;j rA&&(z=rA-gt),j=z;j>=0;j--){for(var At=!0,mA=0;mA wA&&(QA=wA):QA=wA;var rA,RA=O.length;for(QA>RA/2&&(QA=RA/2),rA=0;rA >8,RA.push(z%256),RA.push(QA);return RA}(O,J.length-z),J,z,QA)}function BA(J,O,z){return a.fromByteArray(0===O&&z===J.length?J:J.slice(O,z))}function vA(J,O,z){z=Math.min(J.length,z);for(var QA=[],wA=O;wA 239?4:RA>223?3:RA>191?2:1;if(wA+gt<=z){var Ft=void 0,j=void 0,OA=void 0,At=void 0;switch(gt){case 1:RA<128&&(rA=RA);break;case 2:128==(192&(Ft=J[wA+1]))&&(At=(31&RA)<<6|63&Ft)>127&&(rA=At);break;case 3:j=J[wA+2],128==(192&(Ft=J[wA+1]))&&128==(192&j)&&(At=(15&RA)<<12|(63&Ft)<<6|63&j)>2047&&(At<55296||At>57343)&&(rA=At);break;case 4:j=J[wA+2],OA=J[wA+3],128==(192&(Ft=J[wA+1]))&&128==(192&j)&&128==(192&OA)&&(At=(15&RA)<<18|(63&Ft)<<12|(63&j)<<6|63&OA)>65535&&At<1114112&&(rA=At)}}null===rA?(rA=65533,gt=1):rA>65535&&(QA.push((rA-=65536)>>>10&1023|55296),rA=56320|1023&rA),QA.push(rA),wA+=gt}return function(J){var O=J.length;if(O<=4096)return String.fromCharCode.apply(String,J);for(var z="",QA=0;QA wA.length?(f.isBuffer(rA)||(rA=f.from(rA)),rA.copy(wA,RA)):Uint8Array.prototype.set.call(wA,rA,RA);else{if(!f.isBuffer(rA))throw new TypeError('"list" argument must be an Array of Buffers');rA.copy(wA,RA)}RA+=rA.length}return wA},f.byteLength=x,f.prototype._isBuffer=!0,f.prototype.swap16=function(){var O=this.length;if(O%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var z=0;z z&&(O+=" ... ")," "},h&&(f.prototype[h]=f.prototype.inspect),f.prototype.compare=function(O,z,QA,wA,RA){if(yA(O,Uint8Array)&&(O=f.from(O,O.offset,O.byteLength)),!f.isBuffer(O))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof O);if(void 0===z&&(z=0),void 0===QA&&(QA=O?O.length:0),void 0===wA&&(wA=0),void 0===RA&&(RA=this.length),z<0||QA>O.length||wA<0||RA>this.length)throw new RangeError("out of range index");if(wA>=RA&&z>=QA)return 0;if(wA>=RA)return-1;if(z>=QA)return 1;if(this===O)return 0;for(var rA=(RA>>>=0)-(wA>>>=0),gt=(QA>>>=0)-(z>>>=0),Ft=Math.min(rA,gt),j=this.slice(wA,RA),OA=O.slice(z,QA),At=0;At >>=0,isFinite(QA)?(QA>>>=0,void 0===wA&&(wA="utf8")):(wA=QA,QA=void 0)}var RA=this.length-z;if((void 0===QA||QA>RA)&&(QA=RA),O.length>0&&(QA<0||z<0)||z>this.length)throw new RangeError("Attempt to write outside buffer bounds");wA||(wA="utf8");for(var rA=!1;;)switch(wA){case"hex":return AA(this,O,z,QA);case"utf8":case"utf-8":return cA(this,O,z,QA);case"ascii":case"latin1":case"binary":return MA(this,O,z,QA);case"base64":return gA(this,O,z,QA);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return lA(this,O,z,QA);default:if(rA)throw new TypeError("Unknown encoding: "+wA);wA=(""+wA).toLowerCase(),rA=!0}},f.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function dA(J,O,z){var QA="";z=Math.min(J.length,z);for(var wA=O;wA QA)&&(z=QA);for(var wA="",RA=O;RA z)throw new RangeError("Trying to access beyond buffer length")}function XA(J,O,z,QA,wA,RA){if(!f.isBuffer(J))throw new TypeError('"buffer" argument must be a Buffer instance');if(O>wA||O J.length)throw new RangeError("Index out of range")}function q(J,O,z,QA,wA){et(O,QA,wA,J,z,7);var RA=Number(O&BigInt(4294967295));J[z++]=RA,J[z++]=RA>>=8,J[z++]=RA>>=8,J[z++]=RA>>=8;var rA=Number(O>>BigInt(32)&BigInt(4294967295));return J[z++]=rA,J[z++]=rA>>=8,J[z++]=rA>>=8,J[z++]=rA>>=8,z}function H(J,O,z,QA,wA){et(O,QA,wA,J,z,7);var RA=Number(O&BigInt(4294967295));J[z+7]=RA,J[z+6]=RA>>=8,J[z+5]=RA>>=8,J[z+4]=RA>>=8;var rA=Number(O>>BigInt(32)&BigInt(4294967295));return J[z+3]=rA,J[z+2]=rA>>=8,J[z+1]=rA>>=8,J[z]=rA>>=8,z+8}function $(J,O,z,QA,wA,RA){if(z+QA>J.length)throw new RangeError("Index out of range");if(z<0)throw new RangeError("Index out of range")}function W(J,O,z,QA,wA){return O=+O,z>>>=0,wA||$(J,0,z,4),B.write(J,O,z,QA,23,4),z+4}function EA(J,O,z,QA,wA){return O=+O,z>>>=0,wA||$(J,0,z,8),B.write(J,O,z,QA,52,8),z+8}f.prototype.slice=function(O,z){var QA=this.length;(O=~~O)<0?(O+=QA)<0&&(O=0):O>QA&&(O=QA),(z=void 0===z?QA:~~z)<0?(z+=QA)<0&&(z=0):z>QA&&(z=QA),z >>=0,z>>>=0,QA||bA(O,z,this.length);for(var wA=this[O],RA=1,rA=0;++rA >>=0,z>>>=0,QA||bA(O,z,this.length);for(var wA=this[O+--z],RA=1;z>0&&(RA*=256);)wA+=this[O+--z]*RA;return wA},f.prototype.readUint8=f.prototype.readUInt8=function(O,z){return O>>>=0,z||bA(O,1,this.length),this[O]},f.prototype.readUint16LE=f.prototype.readUInt16LE=function(O,z){return O>>>=0,z||bA(O,2,this.length),this[O]|this[O+1]<<8},f.prototype.readUint16BE=f.prototype.readUInt16BE=function(O,z){return O>>>=0,z||bA(O,2,this.length),this[O]<<8|this[O+1]},f.prototype.readUint32LE=f.prototype.readUInt32LE=function(O,z){return O>>>=0,z||bA(O,4,this.length),(this[O]|this[O+1]<<8|this[O+2]<<16)+16777216*this[O+3]},f.prototype.readUint32BE=f.prototype.readUInt32BE=function(O,z){return O>>>=0,z||bA(O,4,this.length),16777216*this[O]+(this[O+1]<<16|this[O+2]<<8|this[O+3])},f.prototype.readBigUInt64LE=KA(function(O){ot(O>>>=0,"offset");var z=this[O],QA=this[O+7];(void 0===z||void 0===QA)&&TA(O,this.length-8);var wA=z+this[++O]*Math.pow(2,8)+this[++O]*Math.pow(2,16)+this[++O]*Math.pow(2,24),RA=this[++O]+this[++O]*Math.pow(2,8)+this[++O]*Math.pow(2,16)+QA*Math.pow(2,24);return BigInt(wA)+(BigInt(RA)< >>=0,"offset");var z=this[O],QA=this[O+7];(void 0===z||void 0===QA)&&TA(O,this.length-8);var wA=z*Math.pow(2,24)+this[++O]*Math.pow(2,16)+this[++O]*Math.pow(2,8)+this[++O],RA=this[++O]*Math.pow(2,24)+this[++O]*Math.pow(2,16)+this[++O]*Math.pow(2,8)+QA;return(BigInt(wA)< >>=0,z>>>=0,QA||bA(O,z,this.length);for(var wA=this[O],RA=1,rA=0;++rA =(RA*=128)&&(wA-=Math.pow(2,8*z)),wA},f.prototype.readIntBE=function(O,z,QA){O>>>=0,z>>>=0,QA||bA(O,z,this.length);for(var wA=z,RA=1,rA=this[O+--wA];wA>0&&(RA*=256);)rA+=this[O+--wA]*RA;return rA>=(RA*=128)&&(rA-=Math.pow(2,8*z)),rA},f.prototype.readInt8=function(O,z){return O>>>=0,z||bA(O,1,this.length),128&this[O]?-1*(255-this[O]+1):this[O]},f.prototype.readInt16LE=function(O,z){O>>>=0,z||bA(O,2,this.length);var QA=this[O]|this[O+1]<<8;return 32768&QA?4294901760|QA:QA},f.prototype.readInt16BE=function(O,z){O>>>=0,z||bA(O,2,this.length);var QA=this[O+1]|this[O]<<8;return 32768&QA?4294901760|QA:QA},f.prototype.readInt32LE=function(O,z){return O>>>=0,z||bA(O,4,this.length),this[O]|this[O+1]<<8|this[O+2]<<16|this[O+3]<<24},f.prototype.readInt32BE=function(O,z){return O>>>=0,z||bA(O,4,this.length),this[O]<<24|this[O+1]<<16|this[O+2]<<8|this[O+3]},f.prototype.readBigInt64LE=KA(function(O){ot(O>>>=0,"offset");var z=this[O],QA=this[O+7];(void 0===z||void 0===QA)&&TA(O,this.length-8);var wA=this[O+4]+this[O+5]*Math.pow(2,8)+this[O+6]*Math.pow(2,16)+(QA<<24);return(BigInt(wA)< >>=0,"offset");var z=this[O],QA=this[O+7];(void 0===z||void 0===QA)&&TA(O,this.length-8);var wA=(z<<24)+this[++O]*Math.pow(2,16)+this[++O]*Math.pow(2,8)+this[++O];return(BigInt(wA)< >>=0,z||bA(O,4,this.length),B.read(this,O,!0,23,4)},f.prototype.readFloatBE=function(O,z){return O>>>=0,z||bA(O,4,this.length),B.read(this,O,!1,23,4)},f.prototype.readDoubleLE=function(O,z){return O>>>=0,z||bA(O,8,this.length),B.read(this,O,!0,52,8)},f.prototype.readDoubleBE=function(O,z){return O>>>=0,z||bA(O,8,this.length),B.read(this,O,!1,52,8)},f.prototype.writeUintLE=f.prototype.writeUIntLE=function(O,z,QA,wA){O=+O,z>>>=0,QA>>>=0,wA||XA(this,O,z,QA,Math.pow(2,8*QA)-1,0);var rA=1,gt=0;for(this[z]=255&O;++gt >>=0,QA>>>=0,wA||XA(this,O,z,QA,Math.pow(2,8*QA)-1,0);var rA=QA-1,gt=1;for(this[z+rA]=255&O;--rA>=0&&(gt*=256);)this[z+rA]=O/gt&255;return z+QA},f.prototype.writeUint8=f.prototype.writeUInt8=function(O,z,QA){return O=+O,z>>>=0,QA||XA(this,O,z,1,255,0),this[z]=255&O,z+1},f.prototype.writeUint16LE=f.prototype.writeUInt16LE=function(O,z,QA){return O=+O,z>>>=0,QA||XA(this,O,z,2,65535,0),this[z]=255&O,this[z+1]=O>>>8,z+2},f.prototype.writeUint16BE=f.prototype.writeUInt16BE=function(O,z,QA){return O=+O,z>>>=0,QA||XA(this,O,z,2,65535,0),this[z]=O>>>8,this[z+1]=255&O,z+2},f.prototype.writeUint32LE=f.prototype.writeUInt32LE=function(O,z,QA){return O=+O,z>>>=0,QA||XA(this,O,z,4,4294967295,0),this[z+3]=O>>>24,this[z+2]=O>>>16,this[z+1]=O>>>8,this[z]=255&O,z+4},f.prototype.writeUint32BE=f.prototype.writeUInt32BE=function(O,z,QA){return O=+O,z>>>=0,QA||XA(this,O,z,4,4294967295,0),this[z]=O>>>24,this[z+1]=O>>>16,this[z+2]=O>>>8,this[z+3]=255&O,z+4},f.prototype.writeBigUInt64LE=KA(function(O,z){return void 0===z&&(z=0),q(this,O,z,BigInt(0),BigInt("0xffffffffffffffff"))}),f.prototype.writeBigUInt64BE=KA(function(O,z){return void 0===z&&(z=0),H(this,O,z,BigInt(0),BigInt("0xffffffffffffffff"))}),f.prototype.writeIntLE=function(O,z,QA,wA){if(O=+O,z>>>=0,!wA){var RA=Math.pow(2,8*QA-1);XA(this,O,z,QA,RA-1,-RA)}var rA=0,gt=1,Ft=0;for(this[z]=255&O;++rA >0)-Ft&255;return z+QA},f.prototype.writeIntBE=function(O,z,QA,wA){if(O=+O,z>>>=0,!wA){var RA=Math.pow(2,8*QA-1);XA(this,O,z,QA,RA-1,-RA)}var rA=QA-1,gt=1,Ft=0;for(this[z+rA]=255&O;--rA>=0&&(gt*=256);)O<0&&0===Ft&&0!==this[z+rA+1]&&(Ft=1),this[z+rA]=(O/gt>>0)-Ft&255;return z+QA},f.prototype.writeInt8=function(O,z,QA){return O=+O,z>>>=0,QA||XA(this,O,z,1,127,-128),O<0&&(O=255+O+1),this[z]=255&O,z+1},f.prototype.writeInt16LE=function(O,z,QA){return O=+O,z>>>=0,QA||XA(this,O,z,2,32767,-32768),this[z]=255&O,this[z+1]=O>>>8,z+2},f.prototype.writeInt16BE=function(O,z,QA){return O=+O,z>>>=0,QA||XA(this,O,z,2,32767,-32768),this[z]=O>>>8,this[z+1]=255&O,z+2},f.prototype.writeInt32LE=function(O,z,QA){return O=+O,z>>>=0,QA||XA(this,O,z,4,2147483647,-2147483648),this[z]=255&O,this[z+1]=O>>>8,this[z+2]=O>>>16,this[z+3]=O>>>24,z+4},f.prototype.writeInt32BE=function(O,z,QA){return O=+O,z>>>=0,QA||XA(this,O,z,4,2147483647,-2147483648),O<0&&(O=4294967295+O+1),this[z]=O>>>24,this[z+1]=O>>>16,this[z+2]=O>>>8,this[z+3]=255&O,z+4},f.prototype.writeBigInt64LE=KA(function(O,z){return void 0===z&&(z=0),q(this,O,z,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),f.prototype.writeBigInt64BE=KA(function(O,z){return void 0===z&&(z=0),H(this,O,z,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),f.prototype.writeFloatLE=function(O,z,QA){return W(this,O,z,!0,QA)},f.prototype.writeFloatBE=function(O,z,QA){return W(this,O,z,!1,QA)},f.prototype.writeDoubleLE=function(O,z,QA){return EA(this,O,z,!0,QA)},f.prototype.writeDoubleBE=function(O,z,QA){return EA(this,O,z,!1,QA)},f.prototype.copy=function(O,z,QA,wA){if(!f.isBuffer(O))throw new TypeError("argument should be a Buffer");if(QA||(QA=0),!wA&&0!==wA&&(wA=this.length),z>=O.length&&(z=O.length),z||(z=0),wA>0&&wA =this.length)throw new RangeError("Index out of range");if(wA<0)throw new RangeError("sourceEnd out of bounds");wA>this.length&&(wA=this.length),O.length-z >>=0,QA=void 0===QA?this.length:QA>>>0,O||(O=0),"number"==typeof O)for(rA=z;rA =QA+4;z-=3)O="_"+J.slice(z-3,z)+O;return""+J.slice(0,z)+O}function et(J,O,z,QA,wA,RA){if(J>z||J 3?0===O||O===BigInt(0)?">= 0"+rA+" and < 2"+rA+" ** "+8*(RA+1)+rA:">= -(2"+rA+" ** "+(8*(RA+1)-1)+rA+") and < 2 ** "+(8*(RA+1)-1)+rA:">= "+O+rA+" and <= "+z+rA,new DA.ERR_OUT_OF_RANGE("value",gt,J)}!function(J,O,z){ot(O,"offset"),(void 0===J[O]||void 0===J[O+z])&&TA(O,J.length-(z+1))}(QA,wA,RA)}function ot(J,O){if("number"!=typeof J)throw new DA.ERR_INVALID_ARG_TYPE(O,"number",J)}function TA(J,O,z){throw Math.floor(J)!==J?(ot(J,z),new DA.ERR_OUT_OF_RANGE(z||"offset","an integer",J)):O<0?new DA.ERR_BUFFER_OUT_OF_BOUNDS:new DA.ERR_OUT_OF_RANGE(z||"offset",">= "+(z?1:0)+" and <= "+O,J)}nA("ERR_BUFFER_OUT_OF_BOUNDS",function(J){return J?J+" is outside of buffer bounds":"Attempt to access memory outside buffer bounds"},RangeError),nA("ERR_INVALID_ARG_TYPE",function(J,O){return'The "'+J+'" argument must be of type number. Received type '+typeof O},TypeError),nA("ERR_OUT_OF_RANGE",function(J,O,z){var QA='The value of "'+J+'" is out of range.',wA=z;return Number.isInteger(z)&&Math.abs(z)>Math.pow(2,32)?wA=hA(String(z)):"bigint"==typeof z&&(wA=String(z),(z>Math.pow(BigInt(2),BigInt(32))||z<-Math.pow(BigInt(2),BigInt(32)))&&(wA=hA(wA)),wA+="n"),QA+" It must be "+O+". Received "+wA},RangeError);var rt=/[^+/0-9A-Za-z-_]/g;function pt(J,O){O=O||1/0;for(var z,QA=J.length,wA=null,RA=[],rA=0;rA 55295&&z<57344){if(!wA){if(z>56319){(O-=3)>-1&&RA.push(239,191,189);continue}if(rA+1===QA){(O-=3)>-1&&RA.push(239,191,189);continue}wA=z;continue}if(z<56320){(O-=3)>-1&&RA.push(239,191,189),wA=z;continue}z=65536+(wA-55296<<10|z-56320)}else wA&&(O-=3)>-1&&RA.push(239,191,189);if(wA=null,z<128){if((O-=1)<0)break;RA.push(z)}else if(z<2048){if((O-=2)<0)break;RA.push(z>>6|192,63&z|128)}else if(z<65536){if((O-=3)<0)break;RA.push(z>>12|224,z>>6&63|128,63&z|128)}else{if(!(z<1114112))throw new Error("Invalid code point");if((O-=4)<0)break;RA.push(z>>18|240,z>>12&63|128,z>>6&63|128,63&z|128)}}return RA}function WA(J){return a.toByteArray(function(J){if((J=(J=J.split("=")[0]).trim().replace(rt,"")).length<2)return"";for(;J.length%4!=0;)J+="=";return J}(J))}function it(J,O,z,QA){var wA;for(wA=0;wA =O.length||wA>=J.length);++wA)O[wA+z]=J[wA];return wA}function yA(J,O){return J instanceof O||null!=J&&null!=J.constructor&&null!=J.constructor.name&&J.constructor.name===O.name}function dt(J){return J!=J}var ft=function(){for(var J="0123456789abcdef",O=new Array(256),z=0;z<16;++z)for(var QA=16*z,wA=0;wA<16;++wA)O[QA+wA]=J[z]+J[wA];return O}();function KA(J){return"undefined"==typeof BigInt?Yt:J}function Yt(){throw new Error("BigInt not supported")}},477:function(T,I,n){"use strict";n(7803),n(1539),T.exports="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView},2094:function(T,I,n){"use strict";var cA,MA,gA,c=n(477),r=n(9781),o=n(7854),s=n(614),E=n(111),a=n(2597),B=n(648),h=n(6330),u=n(8880),C=n(1320),e=n(3070).f,f=n(7976),l=n(9518),w=n(7674),Q=n(5112),M=n(9711),Y=o.Int8Array,m=Y&&Y.prototype,p=o.Uint8ClampedArray,D=p&&p.prototype,v=Y&&l(Y),P=m&&l(m),S=Object.prototype,x=o.TypeError,N=Q("toStringTag"),L=M("TYPED_ARRAY_TAG"),V=M("TYPED_ARRAY_CONSTRUCTOR"),aA=c&&!!w&&"Opera"!==B(o.opera),AA=!1,lA={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},BA={BigInt64Array:8,BigUint64Array:8},FA=function(bA){if(!E(bA))return!1;var XA=B(bA);return a(lA,XA)||a(BA,XA)};for(cA in lA)(gA=(MA=o[cA])&&MA.prototype)?u(gA,V,MA):aA=!1;for(cA in BA)(gA=(MA=o[cA])&&MA.prototype)&&u(gA,V,MA);if((!aA||!s(v)||v===Function.prototype)&&(v=function(){throw x("Incorrect invocation")},aA))for(cA in lA)o[cA]&&w(o[cA],v);if((!aA||!P||P===S)&&(P=v.prototype,aA))for(cA in lA)o[cA]&&w(o[cA].prototype,P);if(aA&&l(D)!==P&&w(D,P),r&&!a(P,N))for(cA in AA=!0,e(P,N,{get:function(){return E(this)?this[L]:void 0}}),lA)o[cA]&&u(o[cA],L,cA);T.exports={NATIVE_ARRAY_BUFFER_VIEWS:aA,TYPED_ARRAY_CONSTRUCTOR:V,TYPED_ARRAY_TAG:AA&&L,aTypedArray:function(bA){if(FA(bA))return bA;throw x("Target is not a typed array")},aTypedArrayConstructor:function(bA){if(s(bA)&&(!w||f(v,bA)))return bA;throw x(h(bA)+" is not a typed array constructor")},exportTypedArrayMethod:function(bA,XA,q){if(r){if(q)for(var H in lA){var $=o[H];if($&&a($.prototype,bA))try{delete $.prototype[bA]}catch(W){}}(!P[bA]||q)&&C(P,bA,q?XA:aA&&m[bA]||XA)}},exportTypedArrayStaticMethod:function(bA,XA,q){var H,$;if(r){if(w){if(q)for(H in lA)if(($=o[H])&&a($,bA))try{delete $[bA]}catch(W){}if(v[bA]&&!q)return;try{return C(v,bA,q?XA:aA&&v[bA]||XA)}catch(W){}}for(H in lA)($=o[H])&&(!$[bA]||q)&&C($,bA,XA)}},isView:function(bA){if(!E(bA))return!1;var XA=B(bA);return"DataView"===XA||a(lA,XA)||a(BA,XA)},isTypedArray:FA,TypedArray:v,TypedArrayPrototype:P}},2091:function(T,I,n){"use strict";n(8309);var c=n(7854),r=n(1702),o=n(9781),s=n(477),E=n(6530),a=n(8880),B=n(2248),h=n(7293),u=n(5787),C=n(9303),e=n(7466),f=n(7067),l=n(1179),w=n(9518),Q=n(7674),M=n(8006).f,Y=n(3070).f,m=n(1285),p=n(206),D=n(8003),v=n(9909),P=E.PROPER,S=E.CONFIGURABLE,x=v.get,N=v.set,L="ArrayBuffer",V="DataView",aA="prototype",cA="Wrong index",MA=c[L],gA=MA,lA=gA&&gA[aA],BA=c[V],vA=BA&&BA[aA],FA=Object.prototype,_=c.Array,dA=c.RangeError,uA=r(m),CA=r([].reverse),SA=l.pack,bA=l.unpack,XA=function(ut){return[255&ut]},q=function(ut){return[255&ut,ut>>8&255]},H=function(ut){return[255&ut,ut>>8&255,ut>>16&255,ut>>24&255]},$=function(ut){return ut[3]<<24|ut[2]<<16|ut[1]<<8|ut[0]},W=function(ut){return SA(ut,23,4)},EA=function(ut){return SA(ut,52,8)},DA=function(ut,JA){Y(ut[aA],JA,{get:function(){return x(this)[JA]}})},nA=function(ut,JA,WA,it){var yA=f(WA),dt=x(ut);if(yA+JA>dt.byteLength)throw dA(cA);var ft=x(dt.buffer).bytes,KA=yA+dt.byteOffset,Yt=p(ft,KA,KA+JA);return it?Yt:CA(Yt)},hA=function(ut,JA,WA,it,yA,dt){var ft=f(WA),KA=x(ut);if(ft+JA>KA.byteLength)throw dA(cA);for(var Yt=x(KA.buffer).bytes,J=ft+KA.byteOffset,O=it(+yA),z=0;z ot;)(TA=et[ot++])in gA||a(gA,TA,MA[TA]);lA.constructor=gA}Q&&w(vA)!==FA&&Q(vA,FA);var rt=new BA(new gA(2)),Dt=r(vA.setInt8);rt.setInt8(0,2147483648),rt.setInt8(1,2147483649),(rt.getInt8(0)||!rt.getInt8(1))&&B(vA,{setInt8:function(ut,JA){Dt(this,ut,JA<<24>>24)},setUint8:function(ut,JA){Dt(this,ut,JA<<24>>24)}},{unsafe:!0})}else lA=(gA=function(ut){u(this,lA);var JA=f(ut);N(this,{bytes:uA(_(JA),0),byteLength:JA}),o||(this.byteLength=JA)})[aA],vA=(BA=function(ut,JA,WA){u(this,vA),u(ut,lA);var it=x(ut).byteLength,yA=C(JA);if(yA<0||yA>it)throw dA("Wrong offset");if(yA+(WA=void 0===WA?it-yA:e(WA))>it)throw dA("Wrong length");N(this,{buffer:ut,byteLength:WA,byteOffset:yA}),o||(this.buffer=ut,this.byteLength=WA,this.byteOffset=yA)})[aA],o&&(DA(gA,"byteLength"),DA(BA,"buffer"),DA(BA,"byteLength"),DA(BA,"byteOffset")),B(vA,{getInt8:function(ut){return nA(this,1,ut)[0]<<24>>24},getUint8:function(ut){return nA(this,1,ut)[0]},getInt16:function(ut){var JA=nA(this,2,ut,arguments.length>1?arguments[1]:void 0);return(JA[1]<<8|JA[0])<<16>>16},getUint16:function(ut){var JA=nA(this,2,ut,arguments.length>1?arguments[1]:void 0);return JA[1]<<8|JA[0]},getInt32:function(ut){return $(nA(this,4,ut,arguments.length>1?arguments[1]:void 0))},getUint32:function(ut){return $(nA(this,4,ut,arguments.length>1?arguments[1]:void 0))>>>0},getFloat32:function(ut){return bA(nA(this,4,ut,arguments.length>1?arguments[1]:void 0),23)},getFloat64:function(ut){return bA(nA(this,8,ut,arguments.length>1?arguments[1]:void 0),52)},setInt8:function(ut,JA){hA(this,1,ut,XA,JA)},setUint8:function(ut,JA){hA(this,1,ut,XA,JA)},setInt16:function(ut,JA){hA(this,2,ut,q,JA,arguments.length>2?arguments[2]:void 0)},setUint16:function(ut,JA){hA(this,2,ut,q,JA,arguments.length>2?arguments[2]:void 0)},setInt32:function(ut,JA){hA(this,4,ut,H,JA,arguments.length>2?arguments[2]:void 0)},setUint32:function(ut,JA){hA(this,4,ut,H,JA,arguments.length>2?arguments[2]:void 0)},setFloat32:function(ut,JA){hA(this,4,ut,W,JA,arguments.length>2?arguments[2]:void 0)},setFloat64:function(ut,JA){hA(this,8,ut,EA,JA,arguments.length>2?arguments[2]:void 0)}});D(gA,L),D(BA,V),T.exports={ArrayBuffer:gA,DataView:BA}},7803:function(T,I,n){"use strict";var c=n(2109),r=n(7854),o=n(2091),s=n(6340),E="ArrayBuffer",a=o[E];c({global:!0,forced:r[E]!==a},{ArrayBuffer:a}),s(E)},194:function(T,I,n){"use strict";T.exports=function(c){return function(){var r=c,s=r.lib.BlockCipher,E=r.algo,a=[],B=[],h=[],u=[],C=[],e=[],f=[],l=[],w=[],Q=[];!function(){for(var m=[],p=0;p<256;p++)m[p]=p<128?p<<1:p<<1^283;var D=0,v=0;for(p=0;p<256;p++){var P=v^v<<1^v<<2^v<<3^v<<4;a[D]=P=P>>>8^255&P^99,B[P]=D;var L,S=m[D],x=m[S],N=m[x];h[D]=(L=257*m[P]^16843008*P)<<24|L>>>8,u[D]=L<<16|L>>>16,C[D]=L<<8|L>>>24,e[D]=L,f[P]=(L=16843009*N^65537*x^257*S^16843008*D)<<24|L>>>8,l[P]=L<<16|L>>>16,w[P]=L<<8|L>>>24,Q[P]=L,D?(D=S^m[m[m[N^S]]],v^=m[m[v]]):D=v=1}}();var M=[0,1,2,4,8,16,32,64,128,27,54],Y=E.AES=s.extend({_doReset:function(){if(!this._nRounds||this._keyPriorReset!==this._key){for(var D=this._keyPriorReset=this._key,v=D.words,P=D.sigBytes/4,x=4*((this._nRounds=P+6)+1),N=this._keySchedule=[],L=0;L 6&&L%P==4&&(p=a[p>>>24]<<24|a[p>>>16&255]<<16|a[p>>>8&255]<<8|a[255&p]):(p=a[(p=p<<8|p>>>24)>>>24]<<24|a[p>>>16&255]<<16|a[p>>>8&255]<<8|a[255&p],p^=M[L/P|0]<<24),N[L]=N[L-P]^p);for(var V=this._invKeySchedule=[],aA=0;aA >>24]]^l[a[p>>>16&255]]^w[a[p>>>8&255]]^Q[a[255&p]]}}},encryptBlock:function(p,D){this._doCryptBlock(p,D,this._keySchedule,h,u,C,e,a)},decryptBlock:function(p,D){var v=p[D+1];p[D+1]=p[D+3],p[D+3]=v,this._doCryptBlock(p,D,this._invKeySchedule,f,l,w,Q,B),v=p[D+1],p[D+1]=p[D+3],p[D+3]=v},_doCryptBlock:function(p,D,v,P,S,x,N,L){for(var V=this._nRounds,aA=p[D]^v[0],AA=p[D+1]^v[1],cA=p[D+2]^v[2],MA=p[D+3]^v[3],gA=4,lA=1;lA >>24]^S[AA>>>16&255]^x[cA>>>8&255]^N[255&MA]^v[gA++],vA=P[AA>>>24]^S[cA>>>16&255]^x[MA>>>8&255]^N[255&aA]^v[gA++],FA=P[cA>>>24]^S[MA>>>16&255]^x[aA>>>8&255]^N[255&AA]^v[gA++],_=P[MA>>>24]^S[aA>>>16&255]^x[AA>>>8&255]^N[255&cA]^v[gA++];aA=BA,AA=vA,cA=FA,MA=_}BA=(L[aA>>>24]<<24|L[AA>>>16&255]<<16|L[cA>>>8&255]<<8|L[255&MA])^v[gA++],vA=(L[AA>>>24]<<24|L[cA>>>16&255]<<16|L[MA>>>8&255]<<8|L[255&aA])^v[gA++],FA=(L[cA>>>24]<<24|L[MA>>>16&255]<<16|L[aA>>>8&255]<<8|L[255&AA])^v[gA++],_=(L[MA>>>24]<<24|L[aA>>>16&255]<<16|L[AA>>>8&255]<<8|L[255&cA])^v[gA++],p[D]=BA,p[D+1]=vA,p[D+2]=FA,p[D+3]=_},keySize:8});r.AES=s._createHelper(Y)}(),c.AES}(n(757),n(7508),n(3440),n(3839),n(1582))},1582:function(T,I,n){"use strict";n(7042),n(2222),n(1539),n(9714),n(561),T.exports=function(c){var o,s,E,a,B,C,f,l,Q,M,Y,p,v,S,x,L,V;c.lib.Cipher||(a=(s=(o=c).lib).WordArray,C=o.enc.Base64,f=o.algo.EvpKDF,l=s.Cipher=(B=s.BufferedBlockAlgorithm).extend({cfg:(E=s.Base).extend(),createEncryptor:function(AA,cA){return this.create(this._ENC_XFORM_MODE,AA,cA)},createDecryptor:function(AA,cA){return this.create(this._DEC_XFORM_MODE,AA,cA)},init:function(AA,cA,MA){this.cfg=this.cfg.extend(MA),this._xformMode=AA,this._key=cA,this.reset()},reset:function(){B.reset.call(this),this._doReset()},process:function(AA){return this._append(AA),this._process()},finalize:function(AA){return AA&&this._append(AA),this._doFinalize()},keySize:4,ivSize:4,_ENC_XFORM_MODE:1,_DEC_XFORM_MODE:2,_createHelper:function(){function aA(AA){return"string"==typeof AA?V:x}return function(AA){return{encrypt:function(MA,gA,lA){return aA(gA).encrypt(AA,MA,gA,lA)},decrypt:function(MA,gA,lA){return aA(gA).decrypt(AA,MA,gA,lA)}}}}()}),s.StreamCipher=l.extend({_doFinalize:function(){return this._process(!0)},blockSize:1}),Q=o.mode={},M=s.BlockCipherMode=E.extend({createEncryptor:function(AA,cA){return this.Encryptor.create(AA,cA)},createDecryptor:function(AA,cA){return this.Decryptor.create(AA,cA)},init:function(AA,cA){this._cipher=AA,this._iv=cA}}),Y=Q.CBC=function(){var aA=M.extend();function AA(cA,MA,gA){var lA,BA=this._iv;BA?(lA=BA,this._iv=undefined):lA=this._prevBlock;for(var vA=0;vA >>2]}},s.BlockCipher=l.extend({cfg:l.cfg.extend({mode:Y,padding:p}),reset:function(){var AA;l.reset.call(this);var cA=this.cfg,MA=cA.iv,gA=cA.mode;this._xformMode==this._ENC_XFORM_MODE?AA=gA.createEncryptor:(AA=gA.createDecryptor,this._minBufferSize=1),this._mode&&this._mode.__creator==AA?this._mode.init(this,MA&&MA.words):(this._mode=AA.call(gA,this,MA&&MA.words),this._mode.__creator=AA)},_doProcessBlock:function(AA,cA){this._mode.processBlock(AA,cA)},_doFinalize:function(){var AA,cA=this.cfg.padding;return this._xformMode==this._ENC_XFORM_MODE?(cA.pad(this._data,this.blockSize),AA=this._process(!0)):(AA=this._process(!0),cA.unpad(AA)),AA},blockSize:4}),v=s.CipherParams=E.extend({init:function(AA){this.mixIn(AA)},toString:function(AA){return(AA||this.formatter).stringify(this)}}),S=(o.format={}).OpenSSL={stringify:function(AA){var MA=AA.ciphertext,gA=AA.salt;return(gA?a.create([1398893684,1701076831]).concat(gA).concat(MA):MA).toString(C)},parse:function(AA){var cA,MA=C.parse(AA),gA=MA.words;return 1398893684==gA[0]&&1701076831==gA[1]&&(cA=a.create(gA.slice(2,4)),gA.splice(0,4),MA.sigBytes-=16),v.create({ciphertext:MA,salt:cA})}},x=s.SerializableCipher=E.extend({cfg:E.extend({format:S}),encrypt:function(AA,cA,MA,gA){gA=this.cfg.extend(gA);var lA=AA.createEncryptor(MA,gA),BA=lA.finalize(cA),vA=lA.cfg;return v.create({ciphertext:BA,key:MA,iv:vA.iv,algorithm:AA,mode:vA.mode,padding:vA.padding,blockSize:AA.blockSize,formatter:gA.format})},decrypt:function(AA,cA,MA,gA){return gA=this.cfg.extend(gA),cA=this._parse(cA,gA.format),AA.createDecryptor(MA,gA).finalize(cA.ciphertext)},_parse:function(AA,cA){return"string"==typeof AA?cA.parse(AA,this):AA}}),L=(o.kdf={}).OpenSSL={execute:function(AA,cA,MA,gA){gA||(gA=a.random(8));var lA=f.create({keySize:cA+MA}).compute(AA,gA),BA=a.create(lA.words.slice(cA),4*MA);return lA.sigBytes=4*cA,v.create({key:lA,iv:BA,salt:gA})}},V=s.PasswordBasedCipher=x.extend({cfg:x.cfg.extend({kdf:L}),encrypt:function(AA,cA,MA,gA){var lA=(gA=this.cfg.extend(gA)).kdf.execute(MA,AA.keySize,AA.ivSize);gA.iv=lA.iv;var BA=x.encrypt.call(this,AA,cA,lA.key,gA);return BA.mixIn(lA),BA},decrypt:function(AA,cA,MA,gA){gA=this.cfg.extend(gA),cA=this._parse(cA,gA.format);var lA=gA.kdf.execute(MA,AA.keySize,AA.ivSize,cA.salt);return gA.iv=lA.iv,x.decrypt.call(this,AA,cA,lA.key,gA)}}))}(n(757),n(3839))},757:function(T,I,n){"use strict";var r;n(5743),n(6992),n(1539),n(9135),n(2990),n(8927),n(3105),n(5035),n(4345),n(7174),n(2846),n(4731),n(7209),n(6319),n(8867),n(7789),n(3739),n(9368),n(4483),n(2056),n(3462),n(678),n(7462),n(3824),n(5021),n(2974),n(5016),n(9714),n(7042),n(9600),n(2222),n(561),r=function(){var c=c||function(r,o){var s;if("undefined"!=typeof window&&window.crypto&&(s=window.crypto),"undefined"!=typeof self&&self.crypto&&(s=self.crypto),"undefined"!=typeof globalThis&&globalThis.crypto&&(s=globalThis.crypto),!s&&"undefined"!=typeof window&&window.msCrypto&&(s=window.msCrypto),!s&&void 0!==n.g&&n.g.crypto&&(s=n.g.crypto),!s)try{s=n(2480)}catch(m){}var E=function(){if(s){if("function"==typeof s.getRandomValues)try{return s.getRandomValues(new Uint32Array(1))[0]}catch(p){}if("function"==typeof s.randomBytes)try{return s.randomBytes(4).readInt32LE()}catch(p){}}throw new Error("Native crypto module could not be used to get secure random number.")},a=Object.create||function(){function m(){}return function(p){var D;return m.prototype=p,D=new m,m.prototype=null,D}}(),B={},h=B.lib={},u=h.Base={extend:function(p){var D=a(this);return p&&D.mixIn(p),(!D.hasOwnProperty("init")||this.init===D.init)&&(D.init=function(){D.$super.init.apply(this,arguments)}),D.init.prototype=D,D.$super=this,D},create:function(){var p=this.extend();return p.init.apply(p,arguments),p},init:function(){},mixIn:function(p){for(var D in p)p.hasOwnProperty(D)&&(this[D]=p[D]);p.hasOwnProperty("toString")&&(this.toString=p.toString)},clone:function(){return this.init.prototype.extend(this)}},C=h.WordArray=u.extend({init:function(p,D){p=this.words=p||[],this.sigBytes=null!=D?D:4*p.length},toString:function(p){return(p||f).stringify(this)},concat:function(p){var D=this.words,v=p.words,P=this.sigBytes,S=p.sigBytes;if(this.clamp(),P%4)for(var x=0;x >>2]|=(v[x>>>2]>>>24-x%4*8&255)<<24-(P+x)%4*8;else for(var L=0;L>>2]=v[L>>>2];return this.sigBytes+=S,this},clamp:function(){var p=this.words,D=this.sigBytes;p[D>>>2]&=4294967295<<32-D%4*8,p.length=r.ceil(D/4)},clone:function(){var p=u.clone.call(this);return p.words=this.words.slice(0),p},random:function(p){for(var D=[],v=0;v>>2]>>>24-S%4*8&255;P.push((x>>>4).toString(16)),P.push((15&x).toString(16))}return P.join("")},parse:function(p){for(var D=p.length,v=[],P=0;P
>>3]|=parseInt(p.substr(P,2),16)<<24-P%8*4;return new C.init(v,D/2)}},l=e.Latin1={stringify:function(p){for(var D=p.words,v=p.sigBytes,P=[],S=0;S >>2]>>>24-S%4*8&255));return P.join("")},parse:function(p){for(var D=p.length,v=[],P=0;P >>2]|=(255&p.charCodeAt(P))<<24-P%4*8;return new C.init(v,D)}},w=e.Utf8={stringify:function(p){try{return decodeURIComponent(escape(l.stringify(p)))}catch(D){throw new Error("Malformed UTF-8 data")}},parse:function(p){return l.parse(unescape(encodeURIComponent(p)))}},Q=h.BufferedBlockAlgorithm=u.extend({reset:function(){this._data=new C.init,this._nDataBytes=0},_append:function(p){"string"==typeof p&&(p=w.parse(p)),this._data.concat(p),this._nDataBytes+=p.sigBytes},_process:function(p){var D,v=this._data,P=v.words,S=v.sigBytes,x=this.blockSize,L=S/(4*x),V=(L=p?r.ceil(L):r.max((0|L)-this._minBufferSize,0))*x,aA=r.min(4*V,S);if(V){for(var AA=0;AA >>2]>>>24-w%4*8&255)<<16|(C[w+1>>>2]>>>24-(w+1)%4*8&255)<<8|C[w+2>>>2]>>>24-(w+2)%4*8&255,p=0;p<4&&w+.75*p >>6*(3-p)&63));var D=f.charAt(64);if(D)for(;l.length%4;)l.push(D);return l.join("")},parse:function(u){var C=u.length,e=this._map,f=this._reverseMap;if(!f){f=this._reverseMap=[];for(var l=0;l >>6-l%4*2;e[f>>>2]|=(w|Q)<<24-f%4*8,f++}return s.create(e,f)}(u,C,f)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="},c.enc.Base64;var s}(n(757))},7590:function(T,I,n){"use strict";n(9600),T.exports=function(c){return s=c.lib.WordArray,c.enc.Base64url={stringify:function(u,C){void 0===C&&(C=!0);var e=u.words,f=u.sigBytes,l=C?this._safe_map:this._map;u.clamp();for(var w=[],Q=0;Q >>2]>>>24-Q%4*8&255)<<16|(e[Q+1>>>2]>>>24-(Q+1)%4*8&255)<<8|e[Q+2>>>2]>>>24-(Q+2)%4*8&255,D=0;D<4&&Q+.75*D >>6*(3-D)&63));var v=l.charAt(64);if(v)for(;w.length%4;)w.push(v);return w.join("")},parse:function(u,C){void 0===C&&(C=!0);var e=u.length,f=C?this._safe_map:this._map,l=this._reverseMap;if(!l){l=this._reverseMap=[];for(var w=0;w >>6-l%4*2;e[f>>>2]|=(w|Q)<<24-f%4*8,f++}return s.create(e,f)}(u,e,l)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",_safe_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"},c.enc.Base64url;var s}(n(757))},4978:function(T,I,n){"use strict";n(9600),T.exports=function(c){return function(){var s=c.lib.WordArray,E=c.enc;function B(h){return h<<8&4278255360|h>>>8&16711935}E.Utf16=E.Utf16BE={stringify:function(u){for(var C=u.words,e=u.sigBytes,f=[],l=0;l >>2]>>>16-l%4*8&65535));return f.join("")},parse:function(u){for(var C=u.length,e=[],f=0;f >>1]|=u.charCodeAt(f)<<16-f%2*16;return s.create(e,2*C)}},E.Utf16LE={stringify:function(u){for(var C=u.words,e=u.sigBytes,f=[],l=0;l >>2]>>>16-l%4*8&65535);f.push(String.fromCharCode(w))}return f.join("")},parse:function(u){for(var C=u.length,e=[],f=0;f >>1]|=B(u.charCodeAt(f)<<16-f%2*16);return s.create(e,2*C)}}}(),c.enc.Utf16}(n(757))},3839:function(T,I,n){"use strict";n(2222),T.exports=function(c){return E=(o=(r=c).lib).WordArray,h=(a=r.algo).EvpKDF=(s=o.Base).extend({cfg:s.extend({keySize:4,hasher:a.MD5,iterations:1}),init:function(C){this.cfg=this.cfg.extend(C)},compute:function(C,e){for(var f,l=this.cfg,w=l.hasher.create(),Q=E.create(),M=Q.words,Y=l.keySize,m=l.iterations;M.length l&&(e=C.finalize(e)),e.clamp();for(var w=this._oKey=e.clone(),Q=this._iKey=e.clone(),M=w.words,Y=Q.words,m=0;m >>2]|=B[C]<<24-C%4*8;E.call(this,u,h)}else E.apply(this,arguments)};a.prototype=s}}(),c.lib.WordArray},T.exports=r(n(757))},3440:function(T,I,n){"use strict";T.exports=function(c){return function(r){var o=c,s=o.lib,E=s.WordArray,a=s.Hasher,B=o.algo,h=[];!function(){for(var w=0;w<64;w++)h[w]=4294967296*r.abs(r.sin(w+1))|0}();var u=B.MD5=a.extend({_doReset:function(){this._hash=new E.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(Q,M){for(var Y=0;Y<16;Y++){var m=M+Y,p=Q[m];Q[m]=16711935&(p<<8|p>>>24)|4278255360&(p<<24|p>>>8)}var D=this._hash.words,v=Q[M+0],P=Q[M+1],S=Q[M+2],x=Q[M+3],N=Q[M+4],L=Q[M+5],V=Q[M+6],aA=Q[M+7],AA=Q[M+8],cA=Q[M+9],MA=Q[M+10],gA=Q[M+11],lA=Q[M+12],BA=Q[M+13],vA=Q[M+14],FA=Q[M+15],_=D[0],dA=D[1],uA=D[2],CA=D[3];_=C(_,dA,uA,CA,v,7,h[0]),CA=C(CA,_,dA,uA,P,12,h[1]),uA=C(uA,CA,_,dA,S,17,h[2]),dA=C(dA,uA,CA,_,x,22,h[3]),_=C(_,dA,uA,CA,N,7,h[4]),CA=C(CA,_,dA,uA,L,12,h[5]),uA=C(uA,CA,_,dA,V,17,h[6]),dA=C(dA,uA,CA,_,aA,22,h[7]),_=C(_,dA,uA,CA,AA,7,h[8]),CA=C(CA,_,dA,uA,cA,12,h[9]),uA=C(uA,CA,_,dA,MA,17,h[10]),dA=C(dA,uA,CA,_,gA,22,h[11]),_=C(_,dA,uA,CA,lA,7,h[12]),CA=C(CA,_,dA,uA,BA,12,h[13]),uA=C(uA,CA,_,dA,vA,17,h[14]),_=e(_,dA=C(dA,uA,CA,_,FA,22,h[15]),uA,CA,P,5,h[16]),CA=e(CA,_,dA,uA,V,9,h[17]),uA=e(uA,CA,_,dA,gA,14,h[18]),dA=e(dA,uA,CA,_,v,20,h[19]),_=e(_,dA,uA,CA,L,5,h[20]),CA=e(CA,_,dA,uA,MA,9,h[21]),uA=e(uA,CA,_,dA,FA,14,h[22]),dA=e(dA,uA,CA,_,N,20,h[23]),_=e(_,dA,uA,CA,cA,5,h[24]),CA=e(CA,_,dA,uA,vA,9,h[25]),uA=e(uA,CA,_,dA,x,14,h[26]),dA=e(dA,uA,CA,_,AA,20,h[27]),_=e(_,dA,uA,CA,BA,5,h[28]),CA=e(CA,_,dA,uA,S,9,h[29]),uA=e(uA,CA,_,dA,aA,14,h[30]),_=f(_,dA=e(dA,uA,CA,_,lA,20,h[31]),uA,CA,L,4,h[32]),CA=f(CA,_,dA,uA,AA,11,h[33]),uA=f(uA,CA,_,dA,gA,16,h[34]),dA=f(dA,uA,CA,_,vA,23,h[35]),_=f(_,dA,uA,CA,P,4,h[36]),CA=f(CA,_,dA,uA,N,11,h[37]),uA=f(uA,CA,_,dA,aA,16,h[38]),dA=f(dA,uA,CA,_,MA,23,h[39]),_=f(_,dA,uA,CA,BA,4,h[40]),CA=f(CA,_,dA,uA,v,11,h[41]),uA=f(uA,CA,_,dA,x,16,h[42]),dA=f(dA,uA,CA,_,V,23,h[43]),_=f(_,dA,uA,CA,cA,4,h[44]),CA=f(CA,_,dA,uA,lA,11,h[45]),uA=f(uA,CA,_,dA,FA,16,h[46]),_=l(_,dA=f(dA,uA,CA,_,S,23,h[47]),uA,CA,v,6,h[48]),CA=l(CA,_,dA,uA,aA,10,h[49]),uA=l(uA,CA,_,dA,vA,15,h[50]),dA=l(dA,uA,CA,_,L,21,h[51]),_=l(_,dA,uA,CA,lA,6,h[52]),CA=l(CA,_,dA,uA,x,10,h[53]),uA=l(uA,CA,_,dA,MA,15,h[54]),dA=l(dA,uA,CA,_,P,21,h[55]),_=l(_,dA,uA,CA,AA,6,h[56]),CA=l(CA,_,dA,uA,FA,10,h[57]),uA=l(uA,CA,_,dA,V,15,h[58]),dA=l(dA,uA,CA,_,BA,21,h[59]),_=l(_,dA,uA,CA,N,6,h[60]),CA=l(CA,_,dA,uA,gA,10,h[61]),uA=l(uA,CA,_,dA,S,15,h[62]),dA=l(dA,uA,CA,_,cA,21,h[63]),D[0]=D[0]+_|0,D[1]=D[1]+dA|0,D[2]=D[2]+uA|0,D[3]=D[3]+CA|0},_doFinalize:function(){var Q=this._data,M=Q.words,Y=8*this._nDataBytes,m=8*Q.sigBytes;M[m>>>5]|=128<<24-m%32;var p=r.floor(Y/4294967296),D=Y;M[15+(m+64>>>9<<4)]=16711935&(p<<8|p>>>24)|4278255360&(p<<24|p>>>8),M[14+(m+64>>>9<<4)]=16711935&(D<<8|D>>>24)|4278255360&(D<<24|D>>>8),Q.sigBytes=4*(M.length+1),this._process();for(var v=this._hash,P=v.words,S=0;S<4;S++){var x=P[S];P[S]=16711935&(x<<8|x>>>24)|4278255360&(x<<24|x>>>8)}return v},clone:function(){var Q=a.clone.call(this);return Q._hash=this._hash.clone(),Q}});function C(w,Q,M,Y,m,p,D){var v=w+(Q&M|~Q&Y)+m+D;return(v< >>32-p)+Q}function e(w,Q,M,Y,m,p,D){var v=w+(Q&Y|M&~Y)+m+D;return(v<
>>32-p)+Q}function f(w,Q,M,Y,m,p,D){var v=w+(Q^M^Y)+m+D;return(v<
>>32-p)+Q}function l(w,Q,M,Y,m,p,D){var v=w+(M^(Q|~Y))+m+D;return(v<