PageSourceSearch

https://files-pro.coinswitch.co/cspro/1790158118883/build/_shared/chunk-A27RYC4P.js

js coinswitch.co collected 2026-09-24 09:09:04 UTC 3,425 bytes, 1 lines download raw bytes

1import{d as O}from"https://files-pro.coinswitch.co/cspro/1790158118883/build/_shared/chunk-NG3AHSKA.js";import{Fh as f,Ih as M,Jm as C,Qa as E,Ra as S,mn as v}from"https://files-pro.coinswitch.co/cspro/1790158118883/build/_shared/chunk-FLDDPSDZ.js";import{h as _,wa as h}from"https://files-pro.coinswitch.co/cspro/1790158118883/build/_shared/chunk-MBCP2MIM.js";h();M();S();v();function H(e){return typeof e=="string"?(e=e.toLowerCase(),e.charAt(0).toUpperCase()+e.slice(1)):e}function X(e){let s=e.match(/([0-9A-Za-z]+)(USDT)/);return s?s.map(r=>r.toLowerCase()):"--"}function B(e){return e?(e=e==null?void 0:e.replace(/1000/g,""),`https://files.coinswitch.co/public/coins/${e}.png`):""}function k(e,s){let r=e[s];r=r.sort((N,m)=>{let p=new Date(N.time).getTime(),a=new Date(m.time).getTime();return isNaN(p)||isNaN(a)?0:a-p});let I={RAISED:"NEW",EXCHANGE_FAILED:"FAILED",PARTIALLY_FILLED:"PARTIAIL",EXCHANGE_EXECUTED:"FILLED",EXCHANGE_CANCELLED:"CANCELLED",EXCHANGE_EXPIRED:"EXPIRED IN MATCH"},d={TRANSFER:"TRANSFER",COMMISSION:"COMMISION",COMMISSION_REBATE:"COMMISION REBATE",REALIZED_PNL:"REALIZED P&L",INSURANCE_CLEAR:"INSURANCE CLEAR",FUNDING_FEE:"FUNDING FEE"};switch(s){case"orders":return r.map(a=>{var w,y;let{pair:g,contract_type:A,side:t,order_price:o,order_type:n,qty:i,filled:R,status:c,order_id:l,exchange:T,stop_price:L,avg_price:u,time:D}=a;return t=t==="BUY"?"Long":"Short",c=(w=I[c])!=null?w:"--",o=Number(o)?o:"--",u=Number(u)?u:"--",i.value=Number(i.value)?i.value:"--",T=(y=_)==null?void 0:y.binance,n=n==="STOP_MARKET"?"Stop Market":n==="TAKE_PROFIT_MARKET"?"Take Profit":n,{pair:g,contract_type:A,side:t,price:o,order_type:n,qty:i,filled:R,status:c,order_id:l,exchange:T,stop_price:L,avg_price:u,time:D}});case"transactions":return r.map(a=>{var c,l;let{pair:g,contract_type:A,stage:t,fees:o,exchange:n,time:i,net_pl:R}=a;return t=(c=d[t])!=null?c:"--",n=(l=_)==null?void 0:l.binance,{pair:g,contract_type:A,stage:t,fees:o,exchange:n,time:i,net_pl:R}}).filter(a=>a.stage!=="TRANSFER");case"trades":return r.map(a=>{var u;let{pair:g,contract_type:A,side:t,price:o,exchange:n,qty:i,fee_type:R,fee:c,order_id:l,time:T,ReleasedPNL:L}=a;return t=t==="BUY"?"Long":"Short",n=(u=_)==null?void 0:u.binance,{pair:g,ReleasedPNL:L,contract_type:A,side:t,price:o,exchange:n,time:T,qty:i,fee_type:R,fees:c,order_id:l}});default:return e}}var x=async e=>{var s;try{let{success:r,data:I}=await O(e);if(r){let d=I==null?void 0:I.link;if(d&&d!=="invoice_creation_pending"){let N=/iPad|iPhone|iPod/.test(navigator.userAgent);if(C()&&N)(s=window.ReactNativeWebView)==null||s.postMessage(JSON.stringify({type:"OPEN_EXTERNAL_URL",url:d})),f(E({type:"success",header:"Invoice downloaded successfully!",content:"Your Invoice has been successfully downloaded"}));else if(N)window.open(d,"_blank"),f(E({type:"success",header:"Invoice downloaded successfully!",content:"Your Invoice has been successfully downloaded"}));else{let p=document.createElement("a");p.href=d,p.download="invoice.pdf",p.dispatchEvent(new MouseEvent("click")),f(E({type:"success",header:"Invoice downloaded successfully!",content:"Your Invoice has been successfully downloaded"}))}}else f(E({type:"failure",header:"Invoice creation pending",content:"Please try again later"}))}else throw new Error("Api Failure")}catch{f(E({type:"failure",header:"Invoice download failed.",content:"Please try again later"}))}};export{H as a,X as b,B as c,k as d,x as e};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.