@everymatrix/cashier-page 1.56.2 → 1.57.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("./CashierConfirmModal-BVT51ZOp.cjs"),P=require("./CashierModal-BhCdxWcE.cjs"),L=require("./CashierError-YmV_PQP8.cjs"),q=require("./CashierMethodDetails-Ba0LNaer.cjs");L.init({fallbackLocale:"en"});function G(r,e){L.addMessages(r,e)}function B(r){L.$locale.set(r)}const E={en:{transactionHistoryTitle:"Transaction History",transactionIdTitle:"ID",transactionDateTitle:"Date",transactionTypeTitle:"Type",transactionStatusTitle:"Status",copyTransactionId:"Transaction Id copied to clipboard",transactionStatus:{Authorized:"Authorized",Success:"Success",Failed:"Failed",Rejected:"Rejected",Pending:"Pending"},transactionType:{Deposit:"Deposit",Withdraw:"Withdraw"}},tr:{transactionHistoryTitle:"Transaction History",transactionIdTitle:"ID",transactionDateTitle:"Date",transactionTypeTitle:"Type",transactionStatusTitle:"Status",copyTransactionId:"Transaction Id copied to clipboard",transactionStatus:{Authorized:"Authorized",Success:"Success",Failed:"Failed",Rejected:"Rejected",Pending:"Pending"},transactionType:{Deposit:"Yatırma",Withdraw:"Çekim"}}};function Y(r,e){if(r){const a=document.createElement("style");a.innerHTML=e,r.appendChild(a)}}function X(r,e){const a=new URL(e);fetch(a.href).then(n=>n.text()).then(n=>{const i=document.createElement("style");i.innerHTML=n,r&&r.appendChild(i)}).catch(n=>{console.error("There was an error while trying to load client styling from URL",n)})}function J(r){t.append_styles(r,"svelte-1g1fw8z",".svelte-1g1fw8z.svelte-1g1fw8z,.svelte-1g1fw8z.svelte-1g1fw8z::before,.svelte-1g1fw8z.svelte-1g1fw8z::after{margin:0;padding:0;list-style:none;text-decoration:none;outline:none;box-sizing:border-box;font-style:inherit}.CopyTooltip.svelte-1g1fw8z.svelte-1g1fw8z{width:50%;display:flex;align-items:center;justify-content:center;background-color:var(--emw--color-primary, #7EC51E);position:absolute;top:-6px;left:50%;transform:translateX(-50%);color:var(--emw--color-white, #FFF);border-radius:var(--mmw--border-radius-medium-plus, 6px);z-index:1;opacity:1;container-name:copy-tooltip;font-size:var(--emw--font-size-medium, 16px);line-height:calc(var(--emw--font-size-medium, 16px) + 2px);padding:4px}.CashierTransactionHistory.svelte-1g1fw8z.svelte-1g1fw8z{display:flex;flex-direction:column;position:relative;width:100%;row-gap:var(--emw--spacing-small, 12px);container-name:transaction-history;container-type:inline-size;margin-bottom:var(--emw--spacing-small, 12px)}.CashierTransactionHistory.svelte-1g1fw8z table.svelte-1g1fw8z{font-size:var(--emw--font-size-medium, 16px);word-break:break-all;width:100%;border-collapse:collapse;box-sizing:border-box;overflow:hidden;text-overflow:ellipsis;margin-bottom:var(--emw--spacing-small-minus, 10px)}.CashierTransactionHistory.svelte-1g1fw8z table.svelte-1g1fw8z:not(:last-child){margin-bottom:var(--emw--spacing-large, 20px)}.CashierTransactionHistory.svelte-1g1fw8z thead tr.svelte-1g1fw8z{border-bottom:1px solid var(--mmw--color-grey-105, #E8E9EB);color:var(--mmw--color-grey-10, #111);height:50px}.CashierTransactionHistory.svelte-1g1fw8z tbody tr.svelte-1g1fw8z{color:var(--mmw--color-grey-290, #666)}.CashierTransactionHistory.svelte-1g1fw8z td.svelte-1g1fw8z{max-width:250px;vertical-align:middle;height:40px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding:0 var(--emw--spacing-large, 20px) 0 var(--emw--spacing-small, 12px)}.CashierTransactionHistory.svelte-1g1fw8z tr.svelte-1g1fw8z{position:relative}@container transaction-history (width < 750px){.CashierTransactionHistory.svelte-1g1fw8z .CopyTooltip.svelte-1g1fw8z{width:100%}.CashierTransactionHistory.svelte-1g1fw8z .CashierTransactionId.svelte-1g1fw8z{max-width:150px}.CashierTransactionHistory.svelte-1g1fw8z td.svelte-1g1fw8z{padding:0 var(--emw--spacing-small, 12px) 0 var(--emw--spacing-small, 12px)}}@container transaction-history (width < 475px){.CashierTransactionHistory.svelte-1g1fw8z .CashierTransactionHistoryWrapper.svelte-1g1fw8z{padding:0 var(--emw--spacing-2x-small-plus, 6px)}.CashierTransactionHistory.svelte-1g1fw8z td.svelte-1g1fw8z{padding:0 var(--emw--spacing-2x-small-plus, 6px)}.CashierTransactionHistory.svelte-1g1fw8z td.svelte-1g1fw8z:first-child{max-width:75px}}@container transaction-history (width < 350px){.CashierTransactionHistory.svelte-1g1fw8z table.svelte-1g1fw8z{table-layout:fixed}.CashierTransactionHistory.svelte-1g1fw8z table td.svelte-1g1fw8z{padding:0 0 0 var(--emw--spacing-small, 5px)}}.CashierTransactionHistoryWrapper.svelte-1g1fw8z.svelte-1g1fw8z{background:var(--emw--color-background, #fff);box-shadow:0 0 4px var(--mmw--color-black-transparency-10, rgba(0, 0, 0, 0.1));border-radius:var(--mmw--border-radius-medium-plus, 6px);width:100%;box-sizing:border-box;padding:0 var(--emw--spacing-small, 12px)}.CashierTransactionHistoryTitle.svelte-1g1fw8z.svelte-1g1fw8z{color:var(--mmw--color-grey-10, #111);font-size:var(--emw--font-size-medium, 16px);font-weight:var(--emw--font-weight-normal, 400);line-height:calc(var(--emw--font-size-medium, 16px) + 2px);text-align:left}.CashierTransactionId.svelte-1g1fw8z.svelte-1g1fw8z{cursor:pointer;-webkit-user-select:none;-ms-user-select:none;user-select:none}.CashierTransactionId.svelte-1g1fw8z.svelte-1g1fw8z:hover{background-color:var(--emw--color-gray-50, #F7F8FA)}.CashierTransactionHistoryStatus.svelte-1g1fw8z.svelte-1g1fw8z{line-height:calc(var(--emw--font-size-medium, 16px) + 2px)}.CashierTransactionHistoryContent.svelte-1g1fw8z.svelte-1g1fw8z{width:100%}.CashierTransactionHistoryIcon.svelte-1g1fw8z.svelte-1g1fw8z{vertical-align:middle;height:var(--emw--font-size-medium, 16px);width:var(--emw--font-size-medium, 16px)}")}function U(r,e,a){const n=r.slice();return n[24]=e[a],n[26]=a,n}function Z(r){let e,a,n,i=r[5]("transactionHistoryTitle")+"",o,l,c,g,m,T,v,b,R=r[5]("transactionIdTitle")+"",C,y,V,_=r[5]("transactionDateTitle")+"",S,k,j,D=r[5]("transactionTypeTitle")+"",I,M,x,w=r[5]("transactionStatusTitle")+"",d,s,p,f=r[3]&&O(r),F=t.ensure_array_like(r[2]),h=[];for(let u=0;u<F.length;u+=1)h[u]=W(U(r,F,u));return{c(){e=t.element("div"),f&&f.c(),a=t.space(),n=t.element("h3"),o=t.text(i),l=t.space(),c=t.element("div"),g=t.element("div"),m=t.element("table"),T=t.element("thead"),v=t.element("tr"),b=t.element("td"),C=t.text(R),y=t.space(),V=t.element("td"),S=t.text(_),k=t.space(),j=t.element("td"),I=t.text(D),M=t.space(),x=t.element("td"),d=t.text(w),s=t.space(),p=t.element("tbody");for(let u=0;u<h.length;u+=1)h[u].c();t.attr(n,"class","CashierTransactionHistoryTitle svelte-1g1fw8z"),t.attr(b,"class","svelte-1g1fw8z"),t.attr(V,"class","svelte-1g1fw8z"),t.attr(j,"class","svelte-1g1fw8z"),t.attr(x,"class","svelte-1g1fw8z"),t.attr(v,"class","svelte-1g1fw8z"),t.attr(T,"class","svelte-1g1fw8z"),t.attr(p,"class","svelte-1g1fw8z"),t.attr(m,"class","svelte-1g1fw8z"),t.attr(g,"class","CashierTransactionHistoryContent svelte-1g1fw8z"),t.attr(c,"class","CashierTransactionHistoryWrapper svelte-1g1fw8z"),t.attr(e,"class","CashierTransactionHistory svelte-1g1fw8z")},m(u,H){t.insert(u,e,H),f&&f.m(e,null),t.append(e,a),t.append(e,n),t.append(n,o),t.append(e,l),t.append(e,c),t.append(c,g),t.append(g,m),t.append(m,T),t.append(T,v),t.append(v,b),t.append(b,C),t.append(v,y),t.append(v,V),t.append(V,S),t.append(v,k),t.append(v,j),t.append(j,I),t.append(v,M),t.append(v,x),t.append(x,d),t.append(m,s),t.append(m,p);for(let z=0;z<h.length;z+=1)h[z]&&h[z].m(p,null);r[16](e)},p(u,H){if(u[3]?f?(f.p(u,H),H&8&&t.transition_in(f,1)):(f=O(u),f.c(),t.transition_in(f,1),f.m(e,a)):f&&(t.group_outros(),t.transition_out(f,1,1,()=>{f=null}),t.check_outros()),H&32&&i!==(i=u[5]("transactionHistoryTitle")+"")&&t.set_data(o,i),H&32&&R!==(R=u[5]("transactionIdTitle")+"")&&t.set_data(C,R),H&32&&_!==(_=u[5]("transactionDateTitle")+"")&&t.set_data(S,_),H&32&&D!==(D=u[5]("transactionTypeTitle")+"")&&t.set_data(I,D),H&32&&w!==(w=u[5]("transactionStatusTitle")+"")&&t.set_data(d,w),H&124){F=t.ensure_array_like(u[2]);let z;for(z=0;z<F.length;z+=1){const A=U(u,F,z);h[z]?h[z].p(A,H):(h[z]=W(A),h[z].c(),h[z].m(p,null))}for(;z<h.length;z+=1)h[z].d(1);h.length=F.length}},d(u){u&&t.detach(e),f&&f.d(),t.destroy_each(h,u),r[16](null)}}}function O(r){let e,a=r[5]("copyTransactionId")+"",n,i,o,l;return{c(){e=t.element("div"),n=t.text(a),t.attr(e,"class","CopyTooltip svelte-1g1fw8z")},m(c,g){t.insert(c,e,g),t.append(e,n),l=!0},p(c,g){r=c,(!l||g&32)&&a!==(a=r[5]("copyTransactionId")+"")&&t.set_data(n,a)},i(c){l||(c&&t.add_render_callback(()=>{l&&(o&&o.end(1),i=t.create_in_transition(e,P.fade,{duration:100}),i.start())}),l=!0)},o(c){i&&i.invalidate(),c&&(o=t.create_out_transition(e,P.fade,{duration:r[0]})),l=!1},d(c){c&&t.detach(e),c&&o&&o.end()}}}function K(r){let e,a,n,i,o;return{c(){e=t.svg_element("svg"),a=t.svg_element("g"),n=t.svg_element("g"),i=t.svg_element("g"),o=t.svg_element("path"),t.attr(a,"id","SVGRepo_bgCarrier"),t.attr(a,"stroke-width","0"),t.attr(a,"class","svelte-1g1fw8z"),t.attr(n,"id","SVGRepo_tracerCarrier"),t.attr(n,"stroke-linecap","round"),t.attr(n,"stroke-linejoin","round"),t.attr(n,"class","svelte-1g1fw8z"),t.attr(o,"fill-rule","evenodd"),t.attr(o,"clip-rule","evenodd"),t.attr(o,"d","M22 12C22 17.5228 17.5228 22 12 22C6.47715 22 2 17.5228 2 12C2 6.47715 6.47715 2 12 2C17.5228 2 22 6.47715 22 12ZM16.0303 8.96967C16.3232 9.26256 16.3232 9.73744 16.0303 10.0303L11.0303 15.0303C10.7374 15.3232 10.2626 15.3232 9.96967 15.0303L7.96967 13.0303C7.67678 12.7374 7.67678 12.2626 7.96967 11.9697C8.26256 11.6768 8.73744 11.6768 9.03033 11.9697L10.5 13.4393L12.7348 11.2045L14.9697 8.96967C15.2626 8.67678 15.7374 8.67678 16.0303 8.96967Z"),t.attr(o,"fill","#7EC51E"),t.attr(o,"class","svelte-1g1fw8z"),t.attr(i,"id","SVGRepo_iconCarrier"),t.attr(i,"class","svelte-1g1fw8z"),t.attr(e,"width","18px"),t.attr(e,"height","18px"),t.attr(e,"viewBox","0 0 24 24"),t.attr(e,"fill","none"),t.attr(e,"xmlns","http://www.w3.org/2000/svg"),t.attr(e,"class","svelte-1g1fw8z")},m(l,c){t.insert(l,e,c),t.append(e,a),t.append(e,n),t.append(e,i),t.append(i,o)},d(l){l&&t.detach(e)}}}function Q(r){let e,a,n,i,o,l,c;return{c(){e=t.svg_element("svg"),a=t.svg_element("g"),n=t.svg_element("rect"),i=t.svg_element("g"),o=t.svg_element("g"),l=t.svg_element("text"),c=t.text("R j"),t.attr(n,"x","-2.4"),t.attr(n,"y","-2.4"),t.attr(n,"width","28.80"),t.attr(n,"height","28.80"),t.attr(n,"rx","14.4"),t.attr(n,"fill","#dd6617d4"),t.attr(n,"class","svelte-1g1fw8z"),t.attr(a,"id","SVGRepo_bgCarrier"),t.attr(a,"stroke-width","0"),t.attr(a,"class","svelte-1g1fw8z"),t.attr(i,"id","SVGRepo_tracerCarrier"),t.attr(i,"stroke-linecap","round"),t.attr(i,"stroke-linejoin","round"),t.attr(i,"class","svelte-1g1fw8z"),t.attr(l,"x","42%"),t.attr(l,"y","50%"),t.attr(l,"dominant-baseline","middle"),t.attr(l,"text-anchor","middle"),t.attr(l,"font-family","Arial"),t.attr(l,"font-size","16"),t.attr(l,"fill","#ffffff"),t.attr(l,"class","svelte-1g1fw8z"),t.attr(o,"id","SVGRepo_iconCarrier"),t.attr(o,"class","svelte-1g1fw8z"),t.attr(e,"width","16px"),t.attr(e,"height","18px"),t.attr(e,"viewBox","-2.4 -2.4 28.80 28.80"),t.attr(e,"fill","none"),t.attr(e,"xmlns","http://www.w3.org/2000/svg"),t.attr(e,"class","svelte-1g1fw8z")},m(g,m){t.insert(g,e,m),t.append(e,a),t.append(a,n),t.append(e,i),t.append(e,o),t.append(o,l),t.append(l,c)},d(g){g&&t.detach(e)}}}function $(r){let e,a,n,i,o,l,c;return{c(){e=t.svg_element("svg"),a=t.svg_element("g"),n=t.svg_element("rect"),i=t.svg_element("g"),o=t.svg_element("g"),l=t.svg_element("path"),c=t.svg_element("path"),t.attr(n,"x","-2.4"),t.attr(n,"y","-2.4"),t.attr(n,"width","28.80"),t.attr(n,"height","28.80"),t.attr(n,"rx","14.4"),t.attr(n,"fill","#dd6617d4"),t.attr(n,"class","svelte-1g1fw8z"),t.attr(a,"id","SVGRepo_bgCarrier"),t.attr(a,"stroke-width","0"),t.attr(a,"class","svelte-1g1fw8z"),t.attr(i,"id","SVGRepo_tracerCarrier"),t.attr(i,"stroke-linecap","round"),t.attr(i,"stroke-linejoin","round"),t.attr(i,"class","svelte-1g1fw8z"),t.attr(l,"d","M13 6H11V7C11 7.55228 11.4477 8 12 8C12.5523 8 13 7.55228 13 7V6Z"),t.attr(l,"fill","#ffffff"),t.attr(l,"class","svelte-1g1fw8z"),t.attr(c,"fill-rule","evenodd"),t.attr(c,"clip-rule","evenodd"),t.attr(c,"d","M6 2V4H7V7C7 9.76142 9.23858 12 12 12C9.23858 12 7 14.2386 7 17V20H6V22H18V20H17V17C17 14.2386 14.7614 12 12 12C14.7614 12 17 9.76142 17 7V4H18V2H6ZM9 4H15V7C15 8.65685 13.6569 10 12 10C10.3431 10 9 8.65685 9 7V4ZM9 17V20H15V17C15 15.3431 13.6569 14 12 14C10.3431 14 9 15.3431 9 17Z"),t.attr(c,"fill","#ffffff"),t.attr(c,"class","svelte-1g1fw8z"),t.attr(o,"id","SVGRepo_iconCarrier"),t.attr(o,"class","svelte-1g1fw8z"),t.attr(e,"width","16px"),t.attr(e,"height","18px"),t.attr(e,"viewBox","-2.4 -2.4 28.80 28.80"),t.attr(e,"fill","none"),t.attr(e,"xmlns","http://www.w3.org/2000/svg"),t.attr(e,"class","svelte-1g1fw8z")},m(g,m){t.insert(g,e,m),t.append(e,a),t.append(a,n),t.append(e,i),t.append(e,o),t.append(o,l),t.append(o,c)},d(g){g&&t.detach(e)}}}function tt(r){let e,a,n,i,o;return{c(){e=t.svg_element("svg"),a=t.svg_element("g"),n=t.svg_element("g"),i=t.svg_element("g"),o=t.svg_element("path"),t.attr(a,"id","SVGRepo_bgCarrier"),t.attr(a,"stroke-width","0"),t.attr(a,"class","svelte-1g1fw8z"),t.attr(n,"id","SVGRepo_tracerCarrier"),t.attr(n,"stroke-linecap","round"),t.attr(n,"stroke-linejoin","round"),t.attr(n,"class","svelte-1g1fw8z"),t.attr(o,"d","M960 0c530.193 0 960 429.807 960 960s-429.807 960-960 960S0 1490.193 0 960 429.807 0 960 0Zm-9.838 1342.685c-84.47 0-153.19 68.721-153.19 153.19 0 84.47 68.72 153.192 153.19 153.192s153.19-68.721 153.19-153.191-68.72-153.19-153.19-153.19ZM1153.658 320H746.667l99.118 898.623h208.755L1153.658 320Z"),t.attr(o,"fill-rule","evenodd"),t.attr(o,"class","svelte-1g1fw8z"),t.attr(i,"id","SVGRepo_iconCarrier"),t.attr(i,"class","svelte-1g1fw8z"),t.attr(e,"fill","#ed0909"),t.attr(e,"width","16px"),t.attr(e,"height","18px"),t.attr(e,"viewBox","0 0 1920 1920"),t.attr(e,"xmlns","http://www.w3.org/2000/svg"),t.attr(e,"class","svelte-1g1fw8z")},m(l,c){t.insert(l,e,c),t.append(e,a),t.append(e,n),t.append(e,i),t.append(i,o)},d(l){l&&t.detach(e)}}}function et(r){let e,a,n,i,o,l;return{c(){e=t.svg_element("svg"),a=t.svg_element("g"),n=t.svg_element("g"),i=t.svg_element("g"),o=t.svg_element("circle"),l=t.svg_element("path"),t.attr(a,"id","SVGRepo_bgCarrier"),t.attr(a,"stroke-width","0"),t.attr(a,"class","svelte-1g1fw8z"),t.attr(n,"id","SVGRepo_tracerCarrier"),t.attr(n,"stroke-linecap","round"),t.attr(n,"stroke-linejoin","round"),t.attr(n,"class","svelte-1g1fw8z"),t.attr(o,"cx","32"),t.attr(o,"cy","32"),t.attr(o,"r","30"),t.attr(o,"fill","#4fd1d9"),t.attr(o,"class","svelte-1g1fw8z"),t.attr(l,"d","M28.6 17.5h6.9l10.3 29h-6.6l-1.9-6H26.6l-2 6h-6.3l10.3-29m-.4 18h7.4L32 24.1l-3.8 11.4"),t.attr(l,"fill","#ffffff"),t.attr(l,"class","svelte-1g1fw8z"),t.attr(i,"id","SVGRepo_iconCarrier"),t.attr(i,"class","svelte-1g1fw8z"),t.attr(e,"width","17px"),t.attr(e,"height","18px"),t.attr(e,"viewBox","0 0 64 64"),t.attr(e,"xmlns","http://www.w3.org/2000/svg"),t.attr(e,"xmlns:xlink","http://www.w3.org/1999/xlink"),t.attr(e,"aria-hidden","true"),t.attr(e,"role","img"),t.attr(e,"class","iconify iconify--emojione svelte-1g1fw8z"),t.attr(e,"preserveAspectRatio","xMidYMid meet"),t.attr(e,"fill","#000000")},m(c,g){t.insert(c,e,g),t.append(e,a),t.append(e,n),t.append(e,i),t.append(i,o),t.append(i,l)},d(c){c&&t.detach(e)}}}function W(r){let e,a,n=r[24].Code+"",i,o,l,c=r[24].Date+"",g,m,T,v=r[5](`transactionType.${r[24].Type}`)+"",b,R,C,y,V,_,S=r[5](`transactionStatus.${r[24].Status}`)+"",k,j,D,I;function M(d,s){if(d[24].Status===d[4].Authorized)return et;if(d[24].Status===d[4].Failed)return tt;if(d[24].Status===d[4].Pending)return $;if(d[24].Status===d[4].Rejected)return Q;if(d[24].Status===d[4].Success)return K}let x=M(r),w=x&&x(r);return{c(){e=t.element("tr"),a=t.element("td"),i=t.text(n),o=t.space(),l=t.element("td"),g=t.text(c),m=t.space(),T=t.element("td"),b=t.text(v),R=t.space(),C=t.element("td"),y=t.element("span"),w&&w.c(),V=t.space(),_=t.element("span"),k=t.text(S),j=t.space(),t.attr(a,"class","CashierTransactionId svelte-1g1fw8z"),t.toggle_class(a,"copied",r[3]),t.attr(l,"class","svelte-1g1fw8z"),t.attr(T,"class","svelte-1g1fw8z"),t.attr(y,"class","CashierTransactionHistoryIcon svelte-1g1fw8z"),t.attr(_,"class","CashierTransactionHistoryStatus svelte-1g1fw8z"),t.attr(C,"class","svelte-1g1fw8z"),t.attr(e,"class","svelte-1g1fw8z")},m(d,s){t.insert(d,e,s),t.append(e,a),t.append(a,i),t.append(e,o),t.append(e,l),t.append(l,g),t.append(e,m),t.append(e,T),t.append(T,b),t.append(e,R),t.append(e,C),t.append(C,y),w&&w.m(y,null),t.append(C,V),t.append(C,_),t.append(_,k),t.append(e,j),D||(I=t.listen(a,"mousedown",r[15]),D=!0)},p(d,s){s&4&&n!==(n=d[24].Code+"")&&t.set_data(i,n),s&8&&t.toggle_class(a,"copied",d[3]),s&4&&c!==(c=d[24].Date+"")&&t.set_data(g,c),s&36&&v!==(v=d[5](`transactionType.${d[24].Type}`)+"")&&t.set_data(b,v),x!==(x=M(d))&&(w&&w.d(1),w=x&&x(d),w&&(w.c(),w.m(y,null))),s&36&&S!==(S=d[5](`transactionStatus.${d[24].Status}`)+"")&&t.set_data(k,S)},d(d){d&&t.detach(e),w&&w.d(),D=!1,I()}}}function at(r){let e,a=r[2].length&&Z(r);return{c(){a&&a.c(),e=t.empty()},m(n,i){a&&a.m(n,i),t.insert(n,e,i)},p(n,[i]){n[2].length?a?a.p(n,i):(a=Z(n),a.c(),a.m(e.parentNode,e)):a&&(a.d(1),a=null)},i:t.noop,o:t.noop,d(n){n&&t.detach(e),a&&a.d(n)}}}const nt="DD.MM.YYYY";function st(r,e,a){let n;t.component_subscribe(r,L.$format,s=>a(5,n=s));let{endpoint:i}=e,{session:o}=e,{lang:l="en"}=e,{customerid:c}=e,{clientstyling:g=""}=e,{clientstylingurl:m=""}=e,{translationurl:T}=e,{tooltipduration:v=1e3}=e,{txncount:b=3}=e,R=[],C=!1,y,V;var _;(function(s){s.Deposit="deposit",s.Withdraw="withdraw",s.Refund="refund",s.Unknown="unknown",s.TaxDeduction="taxDeduction"})(_||(_={}));const S=["Authorized","Success","Failed","Rejected","PendingApprovalStage1","PendingApprovalStage2","PendingApprovalStage3","PendingNotification","PendingOfflineNotification","PendingConfirmation"];var k;(function(s){s.Authorized="Authorized",s.Success="Success",s.Failed="Failed",s.Rejected="Rejected",s.Pending="Pending"})(k||(k={}));const j=()=>{let s=T;if(s)return fetch(s).then(p=>p.json()).then(p=>{Object.keys(p).forEach(f=>{G(f,p[f])})}).catch(p=>{console.log(p)})};Object.keys(E).forEach(s=>{G(s,E[s])});const D=()=>{B(l)},I=()=>{const s=new URL(`${i}/api/v1/mm/payment/gettransactionshistory`),p=new Headers;p.append("accept","application/json"),p.append("Content-Type","application/json"),p.append("X-SessionId",`${o}`);const f=new Date(new Date().setMonth(new Date().getMonth()-3)).toISOString(),F={method:"POST",mode:"cors",headers:p,body:JSON.stringify({language:l,customerId:c,count:b,page:0,fromDate:f,toDate:null,statuses:{[_.Deposit]:S,[_.Withdraw]:S,[_.Refund]:["Unknown"],[_.TaxDeduction]:["Unknown"],[_.Unknown]:["Unknown"]},calculateProfit:!1})};fetch(s,F).then(h=>h.json()).then(h=>{a(2,R=M((h==null?void 0:h.items)||[]))}).catch(h=>console.log(h))},M=s=>s.map(p=>{let f=p.generalFields.status;return p.generalFields.status.toLowerCase().includes("pending")&&(f=k.Pending),{Code:p.generalFields.code,Date:q.dayjs(p.generalFields.created).format(nt),Status:f,Type:p.generalFields.type}})||[],x=s=>{const p=s.currentTarget;s.target===p&&navigator.clipboard.writeText(p.innerText).then(()=>{a(3,C=!0),clearTimeout(V),V=setTimeout(()=>{a(3,C=!1)},2e3)}).catch(f=>{console.error("Could not copy text: ",f)})},w=s=>x(s);function d(s){t.binding_callbacks[s?"unshift":"push"](()=>{y=s,a(1,y)})}return r.$$set=s=>{"endpoint"in s&&a(7,i=s.endpoint),"session"in s&&a(8,o=s.session),"lang"in s&&a(9,l=s.lang),"customerid"in s&&a(10,c=s.customerid),"clientstyling"in s&&a(11,g=s.clientstyling),"clientstylingurl"in s&&a(12,m=s.clientstylingurl),"translationurl"in s&&a(13,T=s.translationurl),"tooltipduration"in s&&a(0,v=s.tooltipduration),"txncount"in s&&a(14,b=s.txncount)},r.$$.update=()=>{r.$$.dirty&512&&l&&D(),r.$$.dirty&2050&&g&&y&&Y(y,g),r.$$.dirty&4098&&m&&y&&X(y,m),r.$$.dirty&1920&&i&&o&&c&&l&&I(),r.$$.dirty&8192&&T&&j()},[v,y,R,C,k,n,x,i,o,l,c,g,m,T,b,w,d]}class N extends t.SvelteComponent{constructor(e){super(),t.init(this,e,st,at,t.safe_not_equal,{endpoint:7,session:8,lang:9,customerid:10,clientstyling:11,clientstylingurl:12,translationurl:13,tooltipduration:0,txncount:14},J)}get endpoint(){return this.$$.ctx[7]}set endpoint(e){this.$$set({endpoint:e}),t.flush()}get session(){return this.$$.ctx[8]}set session(e){this.$$set({session:e}),t.flush()}get lang(){return this.$$.ctx[9]}set lang(e){this.$$set({lang:e}),t.flush()}get customerid(){return this.$$.ctx[10]}set customerid(e){this.$$set({customerid:e}),t.flush()}get clientstyling(){return this.$$.ctx[11]}set clientstyling(e){this.$$set({clientstyling:e}),t.flush()}get clientstylingurl(){return this.$$.ctx[12]}set clientstylingurl(e){this.$$set({clientstylingurl:e}),t.flush()}get translationurl(){return this.$$.ctx[13]}set translationurl(e){this.$$set({translationurl:e}),t.flush()}get tooltipduration(){return this.$$.ctx[0]}set tooltipduration(e){this.$$set({tooltipduration:e}),t.flush()}get txncount(){return this.$$.ctx[14]}set txncount(e){this.$$set({txncount:e}),t.flush()}}t.create_custom_element(N,{endpoint:{},session:{},lang:{},customerid:{},clientstyling:{},clientstylingurl:{},translationurl:{},tooltipduration:{},txncount:{}},[],[],!0);exports.default=N;
@@ -0,0 +1,569 @@
1
+ import { S as se, b as ne, f as G, c as le, a as ae, d as re, x as oe, k as E, n as N, v as U, w as ce, K as Y, g as m, h as j, y as I, j as t, l as n, t as q, B as de, p as fe, q as ge, z as M, M as ue, F as we, W as he, X as pe, I as X, A as ve, C as me, O as g } from "./CashierConfirmModal-B0WZGuf5.js";
2
+ import { f as J } from "./CashierModal-DB1wg0l3.js";
3
+ import { i as ze, a as ye, $ as _e, b as Te } from "./CashierError-Dyf5BWS1.js";
4
+ import { d as Ce } from "./CashierMethodDetails-C6upoqd2.js";
5
+ ze({
6
+ fallbackLocale: "en"
7
+ });
8
+ function K(a, e) {
9
+ ye(a, e);
10
+ }
11
+ function be(a) {
12
+ _e.set(a);
13
+ }
14
+ const Q = {
15
+ en: {
16
+ transactionHistoryTitle: "Transaction History",
17
+ transactionIdTitle: "ID",
18
+ transactionDateTitle: "Date",
19
+ transactionTypeTitle: "Type",
20
+ transactionStatusTitle: "Status",
21
+ copyTransactionId: "Transaction Id copied to clipboard",
22
+ transactionStatus: {
23
+ Authorized: "Authorized",
24
+ Success: "Success",
25
+ Failed: "Failed",
26
+ Rejected: "Rejected",
27
+ Pending: "Pending"
28
+ },
29
+ transactionType: {
30
+ Deposit: "Deposit",
31
+ Withdraw: "Withdraw"
32
+ }
33
+ },
34
+ tr: {
35
+ transactionHistoryTitle: "Transaction History",
36
+ transactionIdTitle: "ID",
37
+ transactionDateTitle: "Date",
38
+ transactionTypeTitle: "Type",
39
+ transactionStatusTitle: "Status",
40
+ copyTransactionId: "Transaction Id copied to clipboard",
41
+ transactionStatus: {
42
+ Authorized: "Authorized",
43
+ Success: "Success",
44
+ Failed: "Failed",
45
+ Rejected: "Rejected",
46
+ Pending: "Pending"
47
+ },
48
+ transactionType: {
49
+ Deposit: "Yatırma",
50
+ Withdraw: "Çekim"
51
+ }
52
+ }
53
+ };
54
+ function xe(a, e) {
55
+ if (a) {
56
+ const i = document.createElement("style");
57
+ i.innerHTML = e, a.appendChild(i);
58
+ }
59
+ }
60
+ function Se(a, e) {
61
+ const i = new URL(e);
62
+ fetch(i.href).then((s) => s.text()).then((s) => {
63
+ const r = document.createElement("style");
64
+ r.innerHTML = s, a && a.appendChild(r);
65
+ }).catch((s) => {
66
+ console.error("There was an error while trying to load client styling from URL", s);
67
+ });
68
+ }
69
+ function ke(a) {
70
+ re(a, "svelte-1g1fw8z", ".svelte-1g1fw8z.svelte-1g1fw8z,.svelte-1g1fw8z.svelte-1g1fw8z::before,.svelte-1g1fw8z.svelte-1g1fw8z::after{margin:0;padding:0;list-style:none;text-decoration:none;outline:none;box-sizing:border-box;font-style:inherit}.CopyTooltip.svelte-1g1fw8z.svelte-1g1fw8z{width:50%;display:flex;align-items:center;justify-content:center;background-color:var(--emw--color-primary, #7EC51E);position:absolute;top:-6px;left:50%;transform:translateX(-50%);color:var(--emw--color-white, #FFF);border-radius:var(--mmw--border-radius-medium-plus, 6px);z-index:1;opacity:1;container-name:copy-tooltip;font-size:var(--emw--font-size-medium, 16px);line-height:calc(var(--emw--font-size-medium, 16px) + 2px);padding:4px}.CashierTransactionHistory.svelte-1g1fw8z.svelte-1g1fw8z{display:flex;flex-direction:column;position:relative;width:100%;row-gap:var(--emw--spacing-small, 12px);container-name:transaction-history;container-type:inline-size;margin-bottom:var(--emw--spacing-small, 12px)}.CashierTransactionHistory.svelte-1g1fw8z table.svelte-1g1fw8z{font-size:var(--emw--font-size-medium, 16px);word-break:break-all;width:100%;border-collapse:collapse;box-sizing:border-box;overflow:hidden;text-overflow:ellipsis;margin-bottom:var(--emw--spacing-small-minus, 10px)}.CashierTransactionHistory.svelte-1g1fw8z table.svelte-1g1fw8z:not(:last-child){margin-bottom:var(--emw--spacing-large, 20px)}.CashierTransactionHistory.svelte-1g1fw8z thead tr.svelte-1g1fw8z{border-bottom:1px solid var(--mmw--color-grey-105, #E8E9EB);color:var(--mmw--color-grey-10, #111);height:50px}.CashierTransactionHistory.svelte-1g1fw8z tbody tr.svelte-1g1fw8z{color:var(--mmw--color-grey-290, #666)}.CashierTransactionHistory.svelte-1g1fw8z td.svelte-1g1fw8z{max-width:250px;vertical-align:middle;height:40px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding:0 var(--emw--spacing-large, 20px) 0 var(--emw--spacing-small, 12px)}.CashierTransactionHistory.svelte-1g1fw8z tr.svelte-1g1fw8z{position:relative}@container transaction-history (width < 750px){.CashierTransactionHistory.svelte-1g1fw8z .CopyTooltip.svelte-1g1fw8z{width:100%}.CashierTransactionHistory.svelte-1g1fw8z .CashierTransactionId.svelte-1g1fw8z{max-width:150px}.CashierTransactionHistory.svelte-1g1fw8z td.svelte-1g1fw8z{padding:0 var(--emw--spacing-small, 12px) 0 var(--emw--spacing-small, 12px)}}@container transaction-history (width < 475px){.CashierTransactionHistory.svelte-1g1fw8z .CashierTransactionHistoryWrapper.svelte-1g1fw8z{padding:0 var(--emw--spacing-2x-small-plus, 6px)}.CashierTransactionHistory.svelte-1g1fw8z td.svelte-1g1fw8z{padding:0 var(--emw--spacing-2x-small-plus, 6px)}.CashierTransactionHistory.svelte-1g1fw8z td.svelte-1g1fw8z:first-child{max-width:75px}}@container transaction-history (width < 350px){.CashierTransactionHistory.svelte-1g1fw8z table.svelte-1g1fw8z{table-layout:fixed}.CashierTransactionHistory.svelte-1g1fw8z table td.svelte-1g1fw8z{padding:0 0 0 var(--emw--spacing-small, 5px)}}.CashierTransactionHistoryWrapper.svelte-1g1fw8z.svelte-1g1fw8z{background:var(--emw--color-background, #fff);box-shadow:0 0 4px var(--mmw--color-black-transparency-10, rgba(0, 0, 0, 0.1));border-radius:var(--mmw--border-radius-medium-plus, 6px);width:100%;box-sizing:border-box;padding:0 var(--emw--spacing-small, 12px)}.CashierTransactionHistoryTitle.svelte-1g1fw8z.svelte-1g1fw8z{color:var(--mmw--color-grey-10, #111);font-size:var(--emw--font-size-medium, 16px);font-weight:var(--emw--font-weight-normal, 400);line-height:calc(var(--emw--font-size-medium, 16px) + 2px);text-align:left}.CashierTransactionId.svelte-1g1fw8z.svelte-1g1fw8z{cursor:pointer;-webkit-user-select:none;-ms-user-select:none;user-select:none}.CashierTransactionId.svelte-1g1fw8z.svelte-1g1fw8z:hover{background-color:var(--emw--color-gray-50, #F7F8FA)}.CashierTransactionHistoryStatus.svelte-1g1fw8z.svelte-1g1fw8z{line-height:calc(var(--emw--font-size-medium, 16px) + 2px)}.CashierTransactionHistoryContent.svelte-1g1fw8z.svelte-1g1fw8z{width:100%}.CashierTransactionHistoryIcon.svelte-1g1fw8z.svelte-1g1fw8z{vertical-align:middle;height:var(--emw--font-size-medium, 16px);width:var(--emw--font-size-medium, 16px)}");
71
+ }
72
+ function $(a, e, i) {
73
+ const s = a.slice();
74
+ return s[24] = e[i], s[26] = i, s;
75
+ }
76
+ function ee(a) {
77
+ let e, i, s, r = (
78
+ /*$_*/
79
+ a[5]("transactionHistoryTitle") + ""
80
+ ), c, o, d, u, y, x, _, H, F = (
81
+ /*$_*/
82
+ a[5]("transactionIdTitle") + ""
83
+ ), S, b, A, T = (
84
+ /*$_*/
85
+ a[5]("transactionDateTitle") + ""
86
+ ), R, V, P, L = (
87
+ /*$_*/
88
+ a[5]("transactionTypeTitle") + ""
89
+ ), W, O, k, z = (
90
+ /*$_*/
91
+ a[5]("transactionStatusTitle") + ""
92
+ ), f, l, w, h = (
93
+ /*copied*/
94
+ a[3] && te(a)
95
+ ), Z = Y(
96
+ /*txnHistory*/
97
+ a[2]
98
+ ), v = [];
99
+ for (let p = 0; p < Z.length; p += 1)
100
+ v[p] = ie($(a, Z, p));
101
+ return {
102
+ c() {
103
+ e = m("div"), h && h.c(), i = j(), s = m("h3"), c = I(r), o = j(), d = m("div"), u = m("div"), y = m("table"), x = m("thead"), _ = m("tr"), H = m("td"), S = I(F), b = j(), A = m("td"), R = I(T), V = j(), P = m("td"), W = I(L), O = j(), k = m("td"), f = I(z), l = j(), w = m("tbody");
104
+ for (let p = 0; p < v.length; p += 1)
105
+ v[p].c();
106
+ t(s, "class", "CashierTransactionHistoryTitle svelte-1g1fw8z"), t(H, "class", "svelte-1g1fw8z"), t(A, "class", "svelte-1g1fw8z"), t(P, "class", "svelte-1g1fw8z"), t(k, "class", "svelte-1g1fw8z"), t(_, "class", "svelte-1g1fw8z"), t(x, "class", "svelte-1g1fw8z"), t(w, "class", "svelte-1g1fw8z"), t(y, "class", "svelte-1g1fw8z"), t(u, "class", "CashierTransactionHistoryContent svelte-1g1fw8z"), t(d, "class", "CashierTransactionHistoryWrapper svelte-1g1fw8z"), t(e, "class", "CashierTransactionHistory svelte-1g1fw8z");
107
+ },
108
+ m(p, D) {
109
+ E(p, e, D), h && h.m(e, null), n(e, i), n(e, s), n(s, c), n(e, o), n(e, d), n(d, u), n(u, y), n(y, x), n(x, _), n(_, H), n(H, S), n(_, b), n(_, A), n(A, R), n(_, V), n(_, P), n(P, W), n(_, O), n(_, k), n(k, f), n(y, l), n(y, w);
110
+ for (let C = 0; C < v.length; C += 1)
111
+ v[C] && v[C].m(w, null);
112
+ a[16](e);
113
+ },
114
+ p(p, D) {
115
+ if (/*copied*/
116
+ p[3] ? h ? (h.p(p, D), D & /*copied*/
117
+ 8 && q(h, 1)) : (h = te(p), h.c(), q(h, 1), h.m(e, i)) : h && (de(), fe(h, 1, 1, () => {
118
+ h = null;
119
+ }), ge()), D & /*$_*/
120
+ 32 && r !== (r = /*$_*/
121
+ p[5]("transactionHistoryTitle") + "") && M(c, r), D & /*$_*/
122
+ 32 && F !== (F = /*$_*/
123
+ p[5]("transactionIdTitle") + "") && M(S, F), D & /*$_*/
124
+ 32 && T !== (T = /*$_*/
125
+ p[5]("transactionDateTitle") + "") && M(R, T), D & /*$_*/
126
+ 32 && L !== (L = /*$_*/
127
+ p[5]("transactionTypeTitle") + "") && M(W, L), D & /*$_*/
128
+ 32 && z !== (z = /*$_*/
129
+ p[5]("transactionStatusTitle") + "") && M(f, z), D & /*$_, txnHistory, TransactionMainStatus, copied, copyToClipboard*/
130
+ 124) {
131
+ Z = Y(
132
+ /*txnHistory*/
133
+ p[2]
134
+ );
135
+ let C;
136
+ for (C = 0; C < Z.length; C += 1) {
137
+ const B = $(p, Z, C);
138
+ v[C] ? v[C].p(B, D) : (v[C] = ie(B), v[C].c(), v[C].m(w, null));
139
+ }
140
+ for (; C < v.length; C += 1)
141
+ v[C].d(1);
142
+ v.length = Z.length;
143
+ }
144
+ },
145
+ d(p) {
146
+ p && U(e), h && h.d(), ue(v, p), a[16](null);
147
+ }
148
+ };
149
+ }
150
+ function te(a) {
151
+ let e, i = (
152
+ /*$_*/
153
+ a[5]("copyTransactionId") + ""
154
+ ), s, r, c, o;
155
+ return {
156
+ c() {
157
+ e = m("div"), s = I(i), t(e, "class", "CopyTooltip svelte-1g1fw8z");
158
+ },
159
+ m(d, u) {
160
+ E(d, e, u), n(e, s), o = !0;
161
+ },
162
+ p(d, u) {
163
+ a = d, (!o || u & /*$_*/
164
+ 32) && i !== (i = /*$_*/
165
+ a[5]("copyTransactionId") + "") && M(s, i);
166
+ },
167
+ i(d) {
168
+ o || (d && we(() => {
169
+ o && (c && c.end(1), r = he(e, J, { duration: 100 }), r.start());
170
+ }), o = !0);
171
+ },
172
+ o(d) {
173
+ r && r.invalidate(), d && (c = pe(e, J, { duration: (
174
+ /*tooltipduration*/
175
+ a[0]
176
+ ) })), o = !1;
177
+ },
178
+ d(d) {
179
+ d && U(e), d && c && c.end();
180
+ }
181
+ };
182
+ }
183
+ function He(a) {
184
+ let e, i, s, r, c;
185
+ return {
186
+ c() {
187
+ e = g("svg"), i = g("g"), s = g("g"), r = g("g"), c = g("path"), t(i, "id", "SVGRepo_bgCarrier"), t(i, "stroke-width", "0"), t(i, "class", "svelte-1g1fw8z"), t(s, "id", "SVGRepo_tracerCarrier"), t(s, "stroke-linecap", "round"), t(s, "stroke-linejoin", "round"), t(s, "class", "svelte-1g1fw8z"), t(c, "fill-rule", "evenodd"), t(c, "clip-rule", "evenodd"), t(c, "d", "M22 12C22 17.5228 17.5228 22 12 22C6.47715 22 2 17.5228 2 12C2 6.47715 6.47715 2 12 2C17.5228 2 22 6.47715 22 12ZM16.0303 8.96967C16.3232 9.26256 16.3232 9.73744 16.0303 10.0303L11.0303 15.0303C10.7374 15.3232 10.2626 15.3232 9.96967 15.0303L7.96967 13.0303C7.67678 12.7374 7.67678 12.2626 7.96967 11.9697C8.26256 11.6768 8.73744 11.6768 9.03033 11.9697L10.5 13.4393L12.7348 11.2045L14.9697 8.96967C15.2626 8.67678 15.7374 8.67678 16.0303 8.96967Z"), t(c, "fill", "#7EC51E"), t(c, "class", "svelte-1g1fw8z"), t(r, "id", "SVGRepo_iconCarrier"), t(r, "class", "svelte-1g1fw8z"), t(e, "width", "18px"), t(e, "height", "18px"), t(e, "viewBox", "0 0 24 24"), t(e, "fill", "none"), t(e, "xmlns", "http://www.w3.org/2000/svg"), t(e, "class", "svelte-1g1fw8z");
188
+ },
189
+ m(o, d) {
190
+ E(o, e, d), n(e, i), n(e, s), n(e, r), n(r, c);
191
+ },
192
+ d(o) {
193
+ o && U(e);
194
+ }
195
+ };
196
+ }
197
+ function Re(a) {
198
+ let e, i, s, r, c, o, d;
199
+ return {
200
+ c() {
201
+ e = g("svg"), i = g("g"), s = g("rect"), r = g("g"), c = g("g"), o = g("text"), d = I("R j"), t(s, "x", "-2.4"), t(s, "y", "-2.4"), t(s, "width", "28.80"), t(s, "height", "28.80"), t(s, "rx", "14.4"), t(s, "fill", "#dd6617d4"), t(s, "class", "svelte-1g1fw8z"), t(i, "id", "SVGRepo_bgCarrier"), t(i, "stroke-width", "0"), t(i, "class", "svelte-1g1fw8z"), t(r, "id", "SVGRepo_tracerCarrier"), t(r, "stroke-linecap", "round"), t(r, "stroke-linejoin", "round"), t(r, "class", "svelte-1g1fw8z"), t(o, "x", "42%"), t(o, "y", "50%"), t(o, "dominant-baseline", "middle"), t(o, "text-anchor", "middle"), t(o, "font-family", "Arial"), t(o, "font-size", "16"), t(o, "fill", "#ffffff"), t(o, "class", "svelte-1g1fw8z"), t(c, "id", "SVGRepo_iconCarrier"), t(c, "class", "svelte-1g1fw8z"), t(e, "width", "16px"), t(e, "height", "18px"), t(e, "viewBox", "-2.4 -2.4 28.80 28.80"), t(e, "fill", "none"), t(e, "xmlns", "http://www.w3.org/2000/svg"), t(e, "class", "svelte-1g1fw8z");
202
+ },
203
+ m(u, y) {
204
+ E(u, e, y), n(e, i), n(i, s), n(e, r), n(e, c), n(c, o), n(o, d);
205
+ },
206
+ d(u) {
207
+ u && U(e);
208
+ }
209
+ };
210
+ }
211
+ function Ve(a) {
212
+ let e, i, s, r, c, o, d;
213
+ return {
214
+ c() {
215
+ e = g("svg"), i = g("g"), s = g("rect"), r = g("g"), c = g("g"), o = g("path"), d = g("path"), t(s, "x", "-2.4"), t(s, "y", "-2.4"), t(s, "width", "28.80"), t(s, "height", "28.80"), t(s, "rx", "14.4"), t(s, "fill", "#dd6617d4"), t(s, "class", "svelte-1g1fw8z"), t(i, "id", "SVGRepo_bgCarrier"), t(i, "stroke-width", "0"), t(i, "class", "svelte-1g1fw8z"), t(r, "id", "SVGRepo_tracerCarrier"), t(r, "stroke-linecap", "round"), t(r, "stroke-linejoin", "round"), t(r, "class", "svelte-1g1fw8z"), t(o, "d", "M13 6H11V7C11 7.55228 11.4477 8 12 8C12.5523 8 13 7.55228 13 7V6Z"), t(o, "fill", "#ffffff"), t(o, "class", "svelte-1g1fw8z"), t(d, "fill-rule", "evenodd"), t(d, "clip-rule", "evenodd"), t(d, "d", "M6 2V4H7V7C7 9.76142 9.23858 12 12 12C9.23858 12 7 14.2386 7 17V20H6V22H18V20H17V17C17 14.2386 14.7614 12 12 12C14.7614 12 17 9.76142 17 7V4H18V2H6ZM9 4H15V7C15 8.65685 13.6569 10 12 10C10.3431 10 9 8.65685 9 7V4ZM9 17V20H15V17C15 15.3431 13.6569 14 12 14C10.3431 14 9 15.3431 9 17Z"), t(d, "fill", "#ffffff"), t(d, "class", "svelte-1g1fw8z"), t(c, "id", "SVGRepo_iconCarrier"), t(c, "class", "svelte-1g1fw8z"), t(e, "width", "16px"), t(e, "height", "18px"), t(e, "viewBox", "-2.4 -2.4 28.80 28.80"), t(e, "fill", "none"), t(e, "xmlns", "http://www.w3.org/2000/svg"), t(e, "class", "svelte-1g1fw8z");
216
+ },
217
+ m(u, y) {
218
+ E(u, e, y), n(e, i), n(i, s), n(e, r), n(e, c), n(c, o), n(c, d);
219
+ },
220
+ d(u) {
221
+ u && U(e);
222
+ }
223
+ };
224
+ }
225
+ function De(a) {
226
+ let e, i, s, r, c;
227
+ return {
228
+ c() {
229
+ e = g("svg"), i = g("g"), s = g("g"), r = g("g"), c = g("path"), t(i, "id", "SVGRepo_bgCarrier"), t(i, "stroke-width", "0"), t(i, "class", "svelte-1g1fw8z"), t(s, "id", "SVGRepo_tracerCarrier"), t(s, "stroke-linecap", "round"), t(s, "stroke-linejoin", "round"), t(s, "class", "svelte-1g1fw8z"), t(c, "d", "M960 0c530.193 0 960 429.807 960 960s-429.807 960-960 960S0 1490.193 0 960 429.807 0 960 0Zm-9.838 1342.685c-84.47 0-153.19 68.721-153.19 153.19 0 84.47 68.72 153.192 153.19 153.192s153.19-68.721 153.19-153.191-68.72-153.19-153.19-153.19ZM1153.658 320H746.667l99.118 898.623h208.755L1153.658 320Z"), t(c, "fill-rule", "evenodd"), t(c, "class", "svelte-1g1fw8z"), t(r, "id", "SVGRepo_iconCarrier"), t(r, "class", "svelte-1g1fw8z"), t(e, "fill", "#ed0909"), t(e, "width", "16px"), t(e, "height", "18px"), t(e, "viewBox", "0 0 1920 1920"), t(e, "xmlns", "http://www.w3.org/2000/svg"), t(e, "class", "svelte-1g1fw8z");
230
+ },
231
+ m(o, d) {
232
+ E(o, e, d), n(e, i), n(e, s), n(e, r), n(r, c);
233
+ },
234
+ d(o) {
235
+ o && U(e);
236
+ }
237
+ };
238
+ }
239
+ function je(a) {
240
+ let e, i, s, r, c, o;
241
+ return {
242
+ c() {
243
+ e = g("svg"), i = g("g"), s = g("g"), r = g("g"), c = g("circle"), o = g("path"), t(i, "id", "SVGRepo_bgCarrier"), t(i, "stroke-width", "0"), t(i, "class", "svelte-1g1fw8z"), t(s, "id", "SVGRepo_tracerCarrier"), t(s, "stroke-linecap", "round"), t(s, "stroke-linejoin", "round"), t(s, "class", "svelte-1g1fw8z"), t(c, "cx", "32"), t(c, "cy", "32"), t(c, "r", "30"), t(c, "fill", "#4fd1d9"), t(c, "class", "svelte-1g1fw8z"), t(o, "d", "M28.6 17.5h6.9l10.3 29h-6.6l-1.9-6H26.6l-2 6h-6.3l10.3-29m-.4 18h7.4L32 24.1l-3.8 11.4"), t(o, "fill", "#ffffff"), t(o, "class", "svelte-1g1fw8z"), t(r, "id", "SVGRepo_iconCarrier"), t(r, "class", "svelte-1g1fw8z"), t(e, "width", "17px"), t(e, "height", "18px"), t(e, "viewBox", "0 0 64 64"), t(e, "xmlns", "http://www.w3.org/2000/svg"), t(e, "xmlns:xlink", "http://www.w3.org/1999/xlink"), t(e, "aria-hidden", "true"), t(e, "role", "img"), t(e, "class", "iconify iconify--emojione svelte-1g1fw8z"), t(e, "preserveAspectRatio", "xMidYMid meet"), t(e, "fill", "#000000");
244
+ },
245
+ m(d, u) {
246
+ E(d, e, u), n(e, i), n(e, s), n(e, r), n(r, c), n(r, o);
247
+ },
248
+ d(d) {
249
+ d && U(e);
250
+ }
251
+ };
252
+ }
253
+ function ie(a) {
254
+ let e, i, s = (
255
+ /*transaction*/
256
+ a[24].Code + ""
257
+ ), r, c, o, d = (
258
+ /*transaction*/
259
+ a[24].Date + ""
260
+ ), u, y, x, _ = (
261
+ /*$_*/
262
+ a[5](`transactionType.${/*transaction*/
263
+ a[24].Type}`) + ""
264
+ ), H, F, S, b, A, T, R = (
265
+ /*$_*/
266
+ a[5](`transactionStatus.${/*transaction*/
267
+ a[24].Status}`) + ""
268
+ ), V, P, L, W;
269
+ function O(f, l) {
270
+ if (
271
+ /*transaction*/
272
+ f[24].Status === /*TransactionMainStatus*/
273
+ f[4].Authorized
274
+ )
275
+ return je;
276
+ if (
277
+ /*transaction*/
278
+ f[24].Status === /*TransactionMainStatus*/
279
+ f[4].Failed
280
+ )
281
+ return De;
282
+ if (
283
+ /*transaction*/
284
+ f[24].Status === /*TransactionMainStatus*/
285
+ f[4].Pending
286
+ )
287
+ return Ve;
288
+ if (
289
+ /*transaction*/
290
+ f[24].Status === /*TransactionMainStatus*/
291
+ f[4].Rejected
292
+ )
293
+ return Re;
294
+ if (
295
+ /*transaction*/
296
+ f[24].Status === /*TransactionMainStatus*/
297
+ f[4].Success
298
+ )
299
+ return He;
300
+ }
301
+ let k = O(a), z = k && k(a);
302
+ return {
303
+ c() {
304
+ e = m("tr"), i = m("td"), r = I(s), c = j(), o = m("td"), u = I(d), y = j(), x = m("td"), H = I(_), F = j(), S = m("td"), b = m("span"), z && z.c(), A = j(), T = m("span"), V = I(R), P = j(), t(i, "class", "CashierTransactionId svelte-1g1fw8z"), X(
305
+ i,
306
+ "copied",
307
+ /*copied*/
308
+ a[3]
309
+ ), t(o, "class", "svelte-1g1fw8z"), t(x, "class", "svelte-1g1fw8z"), t(b, "class", "CashierTransactionHistoryIcon svelte-1g1fw8z"), t(T, "class", "CashierTransactionHistoryStatus svelte-1g1fw8z"), t(S, "class", "svelte-1g1fw8z"), t(e, "class", "svelte-1g1fw8z");
310
+ },
311
+ m(f, l) {
312
+ E(f, e, l), n(e, i), n(i, r), n(e, c), n(e, o), n(o, u), n(e, y), n(e, x), n(x, H), n(e, F), n(e, S), n(S, b), z && z.m(b, null), n(S, A), n(S, T), n(T, V), n(e, P), L || (W = ve(
313
+ i,
314
+ "mousedown",
315
+ /*mousedown_handler*/
316
+ a[15]
317
+ ), L = !0);
318
+ },
319
+ p(f, l) {
320
+ l & /*txnHistory*/
321
+ 4 && s !== (s = /*transaction*/
322
+ f[24].Code + "") && M(r, s), l & /*copied*/
323
+ 8 && X(
324
+ i,
325
+ "copied",
326
+ /*copied*/
327
+ f[3]
328
+ ), l & /*txnHistory*/
329
+ 4 && d !== (d = /*transaction*/
330
+ f[24].Date + "") && M(u, d), l & /*$_, txnHistory*/
331
+ 36 && _ !== (_ = /*$_*/
332
+ f[5](`transactionType.${/*transaction*/
333
+ f[24].Type}`) + "") && M(H, _), k !== (k = O(f)) && (z && z.d(1), z = k && k(f), z && (z.c(), z.m(b, null))), l & /*$_, txnHistory*/
334
+ 36 && R !== (R = /*$_*/
335
+ f[5](`transactionStatus.${/*transaction*/
336
+ f[24].Status}`) + "") && M(V, R);
337
+ },
338
+ d(f) {
339
+ f && U(e), z && z.d(), L = !1, W();
340
+ }
341
+ };
342
+ }
343
+ function Ie(a) {
344
+ let e, i = (
345
+ /*txnHistory*/
346
+ a[2].length && ee(a)
347
+ );
348
+ return {
349
+ c() {
350
+ i && i.c(), e = oe();
351
+ },
352
+ m(s, r) {
353
+ i && i.m(s, r), E(s, e, r);
354
+ },
355
+ p(s, [r]) {
356
+ /*txnHistory*/
357
+ s[2].length ? i ? i.p(s, r) : (i = ee(s), i.c(), i.m(e.parentNode, e)) : i && (i.d(1), i = null);
358
+ },
359
+ i: N,
360
+ o: N,
361
+ d(s) {
362
+ s && U(e), i && i.d(s);
363
+ }
364
+ };
365
+ }
366
+ const Fe = "DD.MM.YYYY";
367
+ function Ae(a, e, i) {
368
+ let s;
369
+ ce(a, Te, (l) => i(5, s = l));
370
+ let { endpoint: r } = e, { session: c } = e, { lang: o = "en" } = e, { customerid: d } = e, { clientstyling: u = "" } = e, { clientstylingurl: y = "" } = e, { translationurl: x } = e, { tooltipduration: _ = 1e3 } = e, { txncount: H = 3 } = e, F = [], S = !1, b, A;
371
+ var T;
372
+ (function(l) {
373
+ l.Deposit = "deposit", l.Withdraw = "withdraw", l.Refund = "refund", l.Unknown = "unknown", l.TaxDeduction = "taxDeduction";
374
+ })(T || (T = {}));
375
+ const R = [
376
+ "Authorized",
377
+ "Success",
378
+ "Failed",
379
+ "Rejected",
380
+ "PendingApprovalStage1",
381
+ "PendingApprovalStage2",
382
+ "PendingApprovalStage3",
383
+ "PendingNotification",
384
+ "PendingOfflineNotification",
385
+ "PendingConfirmation"
386
+ ];
387
+ var V;
388
+ (function(l) {
389
+ l.Authorized = "Authorized", l.Success = "Success", l.Failed = "Failed", l.Rejected = "Rejected", l.Pending = "Pending";
390
+ })(V || (V = {}));
391
+ const P = () => {
392
+ let l = x;
393
+ if (l)
394
+ return fetch(l).then((w) => w.json()).then((w) => {
395
+ Object.keys(w).forEach((h) => {
396
+ K(h, w[h]);
397
+ });
398
+ }).catch((w) => {
399
+ console.log(w);
400
+ });
401
+ };
402
+ Object.keys(Q).forEach((l) => {
403
+ K(l, Q[l]);
404
+ });
405
+ const L = () => {
406
+ be(o);
407
+ }, W = () => {
408
+ const l = new URL(`${r}/api/v1/mm/payment/gettransactionshistory`), w = new Headers();
409
+ w.append("accept", "application/json"), w.append("Content-Type", "application/json"), w.append("X-SessionId", `${c}`);
410
+ const h = new Date((/* @__PURE__ */ new Date()).setMonth((/* @__PURE__ */ new Date()).getMonth() - 3)).toISOString(), Z = {
411
+ method: "POST",
412
+ mode: "cors",
413
+ headers: w,
414
+ body: JSON.stringify({
415
+ language: o,
416
+ customerId: d,
417
+ count: H,
418
+ page: 0,
419
+ fromDate: h,
420
+ toDate: null,
421
+ statuses: {
422
+ [T.Deposit]: R,
423
+ [T.Withdraw]: R,
424
+ [T.Refund]: ["Unknown"],
425
+ [T.TaxDeduction]: ["Unknown"],
426
+ [T.Unknown]: ["Unknown"]
427
+ },
428
+ calculateProfit: !1
429
+ })
430
+ };
431
+ fetch(l, Z).then((v) => v.json()).then((v) => {
432
+ i(2, F = O(v?.items || []));
433
+ }).catch((v) => console.log(v));
434
+ }, O = (l) => l.map((w) => {
435
+ let h = w.generalFields.status;
436
+ return w.generalFields.status.toLowerCase().includes("pending") && (h = V.Pending), {
437
+ Code: w.generalFields.code,
438
+ Date: Ce(w.generalFields.created).format(Fe),
439
+ Status: h,
440
+ Type: w.generalFields.type
441
+ };
442
+ }) || [], k = (l) => {
443
+ const w = l.currentTarget;
444
+ l.target === w && navigator.clipboard.writeText(w.innerText).then(() => {
445
+ i(3, S = !0), clearTimeout(A), A = setTimeout(
446
+ () => {
447
+ i(3, S = !1);
448
+ },
449
+ 2e3
450
+ );
451
+ }).catch((h) => {
452
+ console.error("Could not copy text: ", h);
453
+ });
454
+ }, z = (l) => k(l);
455
+ function f(l) {
456
+ me[l ? "unshift" : "push"](() => {
457
+ b = l, i(1, b);
458
+ });
459
+ }
460
+ return a.$$set = (l) => {
461
+ "endpoint" in l && i(7, r = l.endpoint), "session" in l && i(8, c = l.session), "lang" in l && i(9, o = l.lang), "customerid" in l && i(10, d = l.customerid), "clientstyling" in l && i(11, u = l.clientstyling), "clientstylingurl" in l && i(12, y = l.clientstylingurl), "translationurl" in l && i(13, x = l.translationurl), "tooltipduration" in l && i(0, _ = l.tooltipduration), "txncount" in l && i(14, H = l.txncount);
462
+ }, a.$$.update = () => {
463
+ a.$$.dirty & /*lang*/
464
+ 512 && o && L(), a.$$.dirty & /*clientstyling, customStylingContainer*/
465
+ 2050 && u && b && xe(b, u), a.$$.dirty & /*clientstylingurl, customStylingContainer*/
466
+ 4098 && y && b && Se(b, y), a.$$.dirty & /*endpoint, session, customerid, lang*/
467
+ 1920 && r && c && d && o && W(), a.$$.dirty & /*translationurl*/
468
+ 8192 && x && P();
469
+ }, [
470
+ _,
471
+ b,
472
+ F,
473
+ S,
474
+ V,
475
+ s,
476
+ k,
477
+ r,
478
+ c,
479
+ o,
480
+ d,
481
+ u,
482
+ y,
483
+ x,
484
+ H,
485
+ z,
486
+ f
487
+ ];
488
+ }
489
+ class Le extends se {
490
+ constructor(e) {
491
+ super(), ne(
492
+ this,
493
+ e,
494
+ Ae,
495
+ Ie,
496
+ ae,
497
+ {
498
+ endpoint: 7,
499
+ session: 8,
500
+ lang: 9,
501
+ customerid: 10,
502
+ clientstyling: 11,
503
+ clientstylingurl: 12,
504
+ translationurl: 13,
505
+ tooltipduration: 0,
506
+ txncount: 14
507
+ },
508
+ ke
509
+ );
510
+ }
511
+ get endpoint() {
512
+ return this.$$.ctx[7];
513
+ }
514
+ set endpoint(e) {
515
+ this.$$set({ endpoint: e }), G();
516
+ }
517
+ get session() {
518
+ return this.$$.ctx[8];
519
+ }
520
+ set session(e) {
521
+ this.$$set({ session: e }), G();
522
+ }
523
+ get lang() {
524
+ return this.$$.ctx[9];
525
+ }
526
+ set lang(e) {
527
+ this.$$set({ lang: e }), G();
528
+ }
529
+ get customerid() {
530
+ return this.$$.ctx[10];
531
+ }
532
+ set customerid(e) {
533
+ this.$$set({ customerid: e }), G();
534
+ }
535
+ get clientstyling() {
536
+ return this.$$.ctx[11];
537
+ }
538
+ set clientstyling(e) {
539
+ this.$$set({ clientstyling: e }), G();
540
+ }
541
+ get clientstylingurl() {
542
+ return this.$$.ctx[12];
543
+ }
544
+ set clientstylingurl(e) {
545
+ this.$$set({ clientstylingurl: e }), G();
546
+ }
547
+ get translationurl() {
548
+ return this.$$.ctx[13];
549
+ }
550
+ set translationurl(e) {
551
+ this.$$set({ translationurl: e }), G();
552
+ }
553
+ get tooltipduration() {
554
+ return this.$$.ctx[0];
555
+ }
556
+ set tooltipduration(e) {
557
+ this.$$set({ tooltipduration: e }), G();
558
+ }
559
+ get txncount() {
560
+ return this.$$.ctx[14];
561
+ }
562
+ set txncount(e) {
563
+ this.$$set({ txncount: e }), G();
564
+ }
565
+ }
566
+ le(Le, { endpoint: {}, session: {}, lang: {}, customerid: {}, clientstyling: {}, clientstylingurl: {}, translationurl: {}, tooltipduration: {}, txncount: {} }, [], [], !0);
567
+ export {
568
+ Le as default
569
+ };