PageSourceSearch

https://www.btse.com/static/js/BBCZVWsC.js

js btse.com collected 2026-09-25 18:38:59 UTC 64,871 bytes, 2 lines download raw bytes

1!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{};e.SENTRY_RELEASE={id:"btse@5f19a485"};var t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="902fc541-46c0-42db-9e4a-85f1a1caee10",e._sentryDebugIdIdentifier="sentry-dbid-902fc541-46c0-42db-9e4a-85f1a1caee10")}catch(a){}}();import{aL as e,a8 as t,a9 as a,aa as r,af as i,ar as s,aK as n,ak as o,am as l,ae as c,ag as u,al as d,bJ as m,B as p,ab as h,aW as y,ai as v,ap as f,aY as g,a5 as C,r as b,a6 as S,bQ as _,as as T,a$ as I,an as w,aE as N,aF as k,ah as F,ad as x,aU as L,ac as M,aI as E,aP as D,aS as P,bD as $,aq as B,b5 as z,aO as O,bI as U,aG as R,bi as A}from"./PmfENnFs.js";import{v as q,t as W,x as Q,y as V,fo as j,E as Y,f as G,c as H,p as K,w as J,iX as X,aj as Z,jp as ee,jq as te,cV as ae,fI as re,u as ie,D as se,X as ne,dZ as oe,a9 as le,jr as ce,js as ue,jt as de,ju as me,jv as pe,jw as he,j as ye,d0 as ve,af as fe,N as ge,U as Ce,F as be,eD as Se,eE as _e,R as Te,aI as Ie,a5 as we,dz as Ne,B as ke,cJ as Fe,hs as xe,A as Le,ag as Me,ik as Ee,jx as De,ah as Pe,dn as $e,ia as Be,dR as ze,Y as Oe,cl as Ue,bz as Re,b1 as Ae,jy as qe,iK as We,iW as Qe,aL as Ve,bP as je,jz as Ye}from"./BhKTELSe.js";import{_ as Ge}from"./CRPzHAml.js";import{I as He,a as Ke,h as Je,S as Xe,_ as Ze}from"./DTvt6p8J.js";import{u as et,O as tt,a as at,b as rt,c as it,d as st,e as nt,f as ot,g as lt,h as ct,i as ut,j as dt}from"./B7TQbCQK.js";import{a3 as mt}from"../../app.DuROpXuw.js";import{d as pt}from"./Bam2FmDF.js";const ht={name:"CurrencyExchangeRate",props:{ruleForm:{type:Object,default:()=>({})}},computed:{...e({currencyMap:"currencyMap"}),fromSelectedCurrencyInfo(){return this.currencyMap[this.ruleForm.fromSelectedCurrency]||{}},toSelectedCurrencyInfo(){return this.currencyMap[this.ruleForm.toSelectedCurrency]||{}}}},yt={class:"convert__rate"};const vt=Ge(ht,[["render",function(e,s,n,o,l,c){return a(),t("p",yt,[s[0]||(s[0]=r("strong",null,"1",-1)),r("span",null,i(c.fromSelectedCurrencyInfo.displayName)+" =",1),r("strong",null,i(e.$filters.formatNumber(n.ruleForm.rate,"max")),1),r("span",null,i(c.toSelectedCurrencyInfo.displayName),1)])}],["__scopeId","data-v-5b40ee98"]]),ft={class:"flex-box flex-column justify-center items-center convert__loading"};const gt=Ge({name:"LoadingExchangeRate",components:{IconSecondLoading:q}},[["render",function(e,o,l,c,u,d){const m=s("IconSecondLoading");return a(),t("div",ft,[r("p",null,i(e.$t("wallets.convert.loading")),1),n(m,{class:"convert__loading-icon"})])}],["__scopeId","data-v-b7ac60d6"]]),Ct="wallets.convert.title",bt="home.convert.title";const St=Ge({name:"ConvertTitle",props:{isConvertPage:{type:Boolean,default:!1}},computed:{classes(){return{"convert-landing-title":!this.isConvertPage,"convert-page-title":this.isConvertPage}},headLevel(){return this.isConvertPage?"h1":"h2"},i18nTitle(){return this.isConvertPage?Ct:bt}}},[["render",function(e,t,r,s,n,m){return a(),o(d(m.headLevel),{class:u(m.classes)},{default:l((()=>[c(i(e.$t(m.i18nTitle)),1)])),_:1},8,["class"])}],["__scopeId","data-v-9ddb2293"]]);const _t=Ge({name:"SwitchFromTo",components:{IconSwitch:He},emits:["switch"],methods:{handleClick(){this.$emit("switch")}}},[["render",function(e,r,i,o,l,c){const u=s("IconSwitch");return a(),t("button",{class:"convert__transfer-button",onClick:r[0]||(r[0]=(...e)=>c.handleClick&&c.handleClick(...e))},[n(u,{class:"convert__transfer-icon"})])}],["__scopeId","data-v-c7789360"]]);const Tt={name:"Exchange",components:{ToLabel:Ge({name:"ToLabel",props:{isConvertPage:{type:Boolean,default:!1}},computed:{...e({isLogin:"loginState"})}},[["render",function(e,r,s,n,o,l){return a(),t("p",{class:u(["convert__input-heading",{hidden:!(s.isConvertPage&&e.isLogin)}])},i(e.$t("home.convert.to")),3)}],["__scopeId","data-v-f6d182f0"]]),SwitchFromTo:_t,InputWithCurrencyDropDown:Ke},props:{isGetRateError:{type:Boolean,default:!1},isFullFormCharError:{type:Boolean,default:!1},ruleForm:{type:Object,required:!0},isConvertPage:{type:Boolean,default:!1}},emits:["switch"],data:()=>({BarTextSize:G,CURRENCY_SORTING_STRATEGY:Y,appliedCurrencyList:[]}),computed:{...e({isLogin:"loginState",currencyMap:"currencyMap"}),balanceLabel(){return this.isMobile?this.$t("convert.available.mobile"):this.$t("wallets.convert.availableAmou
1nt")},toExcludedCurrencyList(){return this.ruleForm.fromSelectedCurrency?[this.ruleForm.fromSelectedCurrency]:[]},getToAmount(){if(!this.ruleForm.amount||this.isGetRateError)return"";let e=j(this.ruleForm.amount);isNaN(e)&&(e=0);const t=Number(this.ruleForm.rate)||0;return`≈ ${this.$filters.formatNumber(p(e).times(t).toString(),"max")}`},fromSelectedCurrencyInfo(){return this.currencyMap[this.ruleForm.fromSelectedCurrency]||{}},formDecimalLimit(){return this.getAssetScaleByCurrency(this.ruleForm.fromSelectedCurrency)},availableBalance(){var e;const t=(null==(e=this.fromSelectedCurrencyInfo)?void 0:e.available)??"0";return p(t).dp(this.formDecimalLimit,p.ROUND_DOWN).toFixed()},formatedAvailableBalance(){return this.$filters.commaNumber(this.availableBalance)},isMaxDisable(){return p(this.availableBalance).lte(0)},isInsufficientBalance(){return p(this.ruleForm.amount).gt(this.availableBalance)},errorMsgI18n(){return this.isFullFormCharError?"msg.halfWidth":this.isInsufficientBalance?"futuresMain.insufficientBalance.title":""}},mounted(){this.fetchAppliedCurrencyList()},methods:{...m(V,["getAssetScaleByCurrency"]),e2eID:W,async fetchAppliedCurrencyList(){try{const e=await Q.initWalletInfo(!1),{cryptoList:t=[],fiatList:a=[]}=e,r=[...t,...a];this.appliedCurrencyList=r.filter((e=>e.allowConvert)).map((e=>e.shortName))}catch(e){this.appliedCurrencyList=[]}},handleSwitch(){this.$emit("switch")},onMaxClick(){this.ruleForm.amount=this.availableBalance}}},It={class:"flex-box items-center justify-center convert__input-wrapper"},wt={class:"convert__input-container"},Nt={class:"flex-box items-center justify-between"},kt={key:0,class:"convert__available"},Ft={key:0,class:"convert__error"},xt={class:"convert__input-container"};const Lt=Ge(Tt,[["render",function(e,o,l,c,d,m){const p=s("InputWithCurrencyDropDown"),y=s("SwitchFromTo"),v=s("ToLabel");return a(),t("div",It,[r("div",wt,[r("div",Nt,[r("p",{class:u(["convert__input-heading",{hidden:!(l.isConvertPage&&e.isLogin)}])},i(e.$t("home.convert.from")),3),e.isLogin&&l.isConvertPage?(a(),t("p",kt,i(m.balanceLabel)+" "+i(m.formatedAvailableBalance)+" "+i(m.fromSelectedCurrencyInfo.displayName),1)):h("",!0)]),n(p,{id:m.e2eID("input_search_coin","from"),value:l.ruleForm.amount,"onUpdate:value":o[0]||(o[0]=e=>l.ruleForm.amount=e),selectedCurrency:l.ruleForm.fromSelectedCurrency,"onUpdate:selectedCurrency":o[1]||(o[1]=e=>l.ruleForm.fromSelectedCurrency=e),class:"convert__input",isError:l.isFullFormCharError,decimalLimit:m.formDecimalLimit,isShowMaxBtn:l.isConvertPage,maxBtnI
1d:m.e2eID("btn_max"),appliedCurrencyList:d.appliedCurrencyList,barTextSize:e.isMobile?d.BarTextSize.BIG:d.BarTextSize.BIGGER,sortingStrategy:d.CURRENCY_SORTING_STRATEGY.BALANCE_DESC,placeholder:"0.00",currencyDropdownIdPrefix:"convert_exchange",currencyDropdownIdSuffix:"from",showBalance:"",isFilterShown:"",onMaxClick:m.onMaxClick},null,8,["id","value","selectedCurrency","isError","decimalLimit","isShowMaxBtn","maxBtnId","appliedCurrencyList","barTextSize","sortingStrategy","onMaxClick"]),m.errorMsgI18n?(a(),t("p",Ft,i(e.$t(m.errorMsgI18n)),1)):h("",!0)]),n(y,{onSwitch:m.handleSwitch},null,8,["onSwitch"]),r("div",xt,[n(v,{isConvertPage:l.isConvertPage},null,8,["isConvertPage"]),n(p,{id:m.e2eID("input_search_coin","to"),value:m.getToAmount,"onUpdate:value":o[2]||(o[2]=e=>m.getToAmount=e),selectedCurrency:l.ruleForm.toSelectedCurrency,"onUpdate:selectedCurrency":o[3]||(o[3]=e=>l.ruleForm.toSelectedCurrency=e),class:"convert__input readonly",excludedCurrencyList:m.toExcludedCurrencyList,appliedCurrencyList:d.appliedCurrencyList,barTextSize:e.isMobile?d.BarTextSize.BIG:d.BarTextSize.BIGGER,sortingStrategy:d.CURRENCY_SORTING_STRATEGY.TOKEN_NAME_ASC,placeholder:"0.00",currencyDropdownIdPrefix:"convert_exchange",currencyDropdownIdSuffix:"to",isFilterShown:"",readonly:"",disabled:"",onMaxClick:m.onMaxClick},null,8,["id","value","selectedCurrency","excludedCurrencyList","appliedCurrencyList","barTextSize","sortingStrategy","onMaxClick"])])])}],["__scopeId","data-v-1057c4d8"]]),{convertDefaultSelected:Mt}=K,Et={convertNow:ae("earn.transferDialog.convertNow"),converting:ae("wallets.convert.buttonConverting"),loginToConvert:ae("convert.button.logout")},Dt={name:"ConvertBlock",components:{Exchange:Lt,ConvertTitle:St,LoadingExchangeRate:gt,CurrencyExchangeRate:vt,SuccessDialog:Xe,FailDialog:Je},props:{toCurrency:{type:String,default:Mt.toCurrency},fromCurrency:{type:String,default:Mt.fromCurrency},amount:{type:String,default:""}},setup(){const{getIsUserFeatureAllow:e}=re(),{showIdVerificationRequiredDialog:t}=et();return{getIsUserFeatureAllow:e,showIdVerificationRequiredDialog:t}},data(){return{ruleForm:{fromSelectedCurrency:this.fromCurrency,toSelectedCurrency:this.toCurrency,fromText:"",amount:this.amount,amountError:!1,rate:""},rateLoading:!0,isGetRateError:!1,getConvertRate:!1,isFullFormCharError:!1,isShowSuccess:!1,isShowFail:!1,isSubmitLoading:!1,successData:{}}},computed:{...e({isLogin:"loginState",currencyMap:"currencyMap",lang:"lang"}),isConvertNowBtn(){return!this.isConvertPage||!this.isSubmitLoading&&this.isLogin},currencyMapNotReady(){return!(this.ruleForm.fromSelectedCurrency&&this.ruleForm.toSelectedCurrency)},buttonText(){return this.isConvertPage?this.isSubmitLoading?Et.converting:this.isLogin?Et.convertNow:Et.loginToConvert:Et.convertNow},isConvertPage(){return"convert"===this.$route.name},fromCurrencyInfo(){return this.currencyMap[this.ruleForm.fromSelectedCurrency]||{}},toCurrencyInfo(){return this.currencyMap[this.ruleForm.toSelectedCurrency]||{}},isNotCurrenciesBothAllow(){return!this.fromCurrencyInfo.allowConvert||!this.toCurrencyInfo.allowConvert},isSubmitDisabled(){return this.isNotCurrenciesBothAllow||this.ruleForm.amountError||""===this.ruleForm.amount||Number(this.ruleForm.amount)<=0||Number(this.ruleForm.amount)>this.fromCurrencyInfo.available}},watch:{"ruleForm.amount"(e,t){if(this.ruleForm.fromText="",this.ruleForm.amountError=!1,""===e)return;this.isFullFormCharError=ee(e)||ee(t);const a=te(e);isNaN(a)?this.$nextTick((()=>{this.ruleForm.amount=t})):this.debounceGetRate()},"ruleForm.fromSelectedCurrency"(e,t){this.ruleForm.amount="",this.handleIsSame("to",t)},"ruleForm.toSelectedCurrency"(e,t){this.handleIsSame("from",t)},getConvertRate(){this.getConvertRate&&(this.getRate(),this.getConvertRate=!1)},fromCurrency(e){this.ruleForm.fromSelectedCurrency=e},toCurrency(e){this.ruleForm.toSelectedCurrency=e}},created(){this.setDefaultCurrencyPair(),this.getRate()},methods:{...y(["messageSuccess","messageError"]),e2eID:W,setDefaultCurrencyPair(){this.currencyMap[this.fromCurrency]||(this.ruleForm.fromSelectedCurrency=Mt.fromCurrency),this.currencyMap[this.toCurrency
1]||(this.ruleForm.toSelectedCurrency=Mt.toCurrency)},async submit(){var e,t;if(!this.ruleForm.amountError){this.isSubmitLoading=!0;try{const e=await J.convert({scrCurrency:this.ruleForm.fromSelectedCurrency,targetCurrency:this.ruleForm.toSelectedCurrency,amount:this.ruleForm.amount});Object.keys(e).length?(e.amountCurrency=e.amountCurrency||e.currency,this.successData=e,this.isShowSuccess=!0):this.messageSuccess(this.$t("response-code.3021")),this.ruleForm.amount=""}catch(a){return(null==(t=null==(e=null==a?void 0:a.response)?void 0:e.data)?void 0:t.code)===Z.CONVERT_FAIL&&(this.getRate(),this.isShowFail=!0),Promise.reject(a)}finally{this.isSubmitLoading=!1}}},onConvertClick(){if(this.isConvertPage)if(this.isLogin)this.showIdVerificationRequiredDialog(X.CONVERT.CONVERT_NOW)||this.submit();else{const e=this.$router.resolve({name:"convert",params:{lang:this.lang,fromCurrency:this.ruleForm.fromSelectedCurrency,toCurrency:this.ruleForm.toSelectedCurrency},query:{amount:this.ruleForm.amount}});this.$router.push({name:"login",query:{redirect:e.href},params:{lang:this.lang}})}else this.$router.push({name:"convert",params:{fromCurrency:this.ruleForm.fromSelectedCurrency,toCurrency:this.ruleForm.toSelectedCurrency},state:{amount:this.ruleForm.amount}})},handleIsSame(e,t){this.ruleForm.fromSelectedCurrency===this.ruleForm.toSelectedCurrency&&("to"===e?this.ruleForm.toSelectedCurrency=t:this.ruleForm.fromSelectedCurrency=t),this.rateLoading=!0,this.getConvertRate=!0},transferOnClicked(){[this.ruleForm.toSelectedCurrency,this.ruleForm.fromSelectedCurrency]=[this.ruleForm.fromSelectedCurrency,this.ruleForm.toSelectedCurrency],this.cancelRequest(),this.debounceGetRate()},cancelRequest(){this.requestController&&this.requestController.abort()},getRate(){if(this.currencyMapNotReady)return;this.cancelRequest(),this.requestController=new AbortController;const e=Date.now(),t=p(this.ruleForm.amount).gt(0)?this.ruleForm.amount:"1";J.getConvertRate({scrCurrency:this.ruleForm.fromSelectedCurrency,targetCurrency:this.ruleForm.toSelectedCurrency,amount:t},this.requestController.signal).then((({rate:t,time:a})=>{const r=Date.now();this.ruleForm.rate=t,this.rateLoading=!1,this.isGetRateError=!1;const i=r-e;if(i>1e3){(0,console.log)(`🐢⏱️ ${i}ms | ⬆️ ts: ${e} | 📡 ts: ${a} | ⬇️ ts: ${r}`)}})).catch((e=>{this.isGetRateError="CanceledError"!==e.name}))},debounceGetRate:H((function(){this.getRate()}),500)}},Pt={class:"flex-box flex-column convert"};const $t=Ge(Dt,[["render",function(e,r,u,d,m,p){const y=s("ConvertTitle"),v=s("Exchange"),f=s("LoadingExchangeRate"),g=s("CurrencyExchangeRate"),C=s("BaseButton"),b=s("SuccessDialog"),S=s("FailDialog");return a(),t("div",Pt,[n(y,{isConvertPage:p.isConvertPage},null,8,["isConvertPage"]),n(v,{fromSelectedCurrency:m.ruleForm.fromSelectedCurrency,"onUpdate:fromSelectedCurrency":r[0]||(r[0]=e=>m.ruleForm.fromSelectedCurrency=e),toSelectedCurrency:m.ruleForm.toSelectedCurrency,"onUpdate:toSelectedCurrency":r[1]||(r[1]=e=>m.ruleForm.toSelectedCurrency=e),ruleForm:m.ruleForm,isConvertPage:p.isConvertPage,isGetRateError:m.isGetRateError,isFullFormCharError:m.isFullFormCharError,onSwitch:p.transferOnClicked},null,8,["fromSelectedCurrency","toSelectedCurrency","ruleForm","isConvertPage","isGetRateError","isFullFormCharError","onSwitch"]),m.rateLoading?(a(),o(f,{key:0})):h("",!0),m.isGetRateError||m.rateLoading?h("",!0):(a(),o(g,{key:1,ruleForm:m.ruleForm},null,8,["ruleForm"])),n(C,{id:p.isConvertNowBtn?p.e2eID("btn_convert_now"):null,class:"green convert-button",size:"large",disabled:e.isLogin&&p.isConvertPage&&p.isSubmitDisabled,isLoading:m.isSubmitLoading,onClick:p.onConvertClick},{default:l((()=>[c(i(e.$t(p.buttonText)),1)])),_:1},8,["id","disabled","isLoading","onClick"]),m.isShowSuccess?(a(),o(b,{key:2,isShow:m.isShowSuccess,"onUpdate:isShow":r[2]||(r[2]=e=>m.isShowSuccess=e),data:m.successData},null,8,["isShow","data"])):h("",!0),m.isShowFail?(a(),o(S,{key:3,isShow:m.isShowFail,"onUpdate:isShow":r[3]||(r[3]=e=>m.isShowFail=e)},null,8,["isShow"])):h("",!0)])}],["__scopeId","data-v-5acd76d3"]]),Bt={class:"convert-container"},zt={class:"convert-page"},Ot={key:0,class:"convert-page__background"},Ut={key:1,class:"convert-page__container"},Rt={key:0,class:"convert-page__info-wrapper"},At={class:"convert-page__info-text"},qt=Ge(v({__name:"index",props:{toCurrency:{default:K.convertDefaultSelected.toCurrency},fromCurrency:{default:K.convertDefaultSelected.fromCurrency}},setup(e){const{bgCoinIconVisible:s,enableConvertMetaBySymbol:l}=K,{visible:c}=se,d=e,m=f(),p=g(),y=ie(),{currencyMap:v}=C(y),I=c.convertFeeFree,w=b(history.state.amount||m.query.amount||""),N=S((()=>Object.keys(v.value).length>0)),k=S((()=>
1{if(!l)return;const e=`router.convert.${d.fromCurrency}.${d.toCurrency}`;return ne(e)?p.t(e):p.t("router.convert")})),F=S((()=>{if(!l)return;const e=`router.convert.description.${d.fromCurrency}.${d.toCurrency}`;return ne(e)?p.t(e):p.t("router.convert.description")})),x=S((()=>l?oe({title:k.value,description:F.value}):[]));return _({title:k,meta:x}),(e,l)=>(a(),t("div",Bt,[n(le,{class:"kyc-notification"}),r("div",zt,[T(s)?(a(),t("div",Ot,[n(T(ce),{class:u(["coin-icon btc-icon",{"is-mobile":e.isMobile}])},null,8,["class"]),n(T(ue),{class:u(["coin-icon eth-icon",{"is-mobile":e.isMobile}])},null,8,["class"]),n(T(de),{class:u(["coin-icon usd-icon",{"is-mobile":e.isMobile}])},null,8,["class"]),e.isMobile?h("",!0):(a(),o(T(me),{key:0,class:"coin-icon xmr-icon"})),e.isMobile?h("",!0):(a(),o(T(pe),{key:1,class:"coin-icon yen-icon"})),e.isMobile?h("",!0):(a(),o(T(he),{key:2,class:"img-bg"})),e.isMobile?h("",!0):(a(),o(T(he),{key:3,class:"img-bg2"}))])):h("",!0),N.value?(a(),t("div",Ut,[n($t,{toCurrency:e.toCurrency,fromCurrency:e.fromCurrency,amount:w.value},null,8,["toCurrency","fromCurrency","amount"]),T(I)?(a(),t("div",Rt,[n(Ze,{class:"convert-page__icon-check"}),r("p",At,i(e.$t("wallets.convert.fee-free-instant-conversion")),1)])):h("",!0)])):h("",!0)])]))}}),[["__scopeId","data-v-4d5475c5"]]),Wt=Object.freeze(Object.defineProperty({__proto__:null,default:qt},Symbol.toStringTag,{value:"Module"})),Qt={class:"marquee-track"},Vt=Ge(v({__name:"Marquee",props:{list:{default:()=>[]},isPause:{type:Boolean,default:!1},isHoverPause:{type:Boolean,default:!1},speedRate:{default:40},maxLength:{default:64}},setup(e){const s=e,n=I("marqueeContainerRef"),o=I("groupListRef"),l=b(!1),d=b(0),m=S((()=>{const e=Number(s.maxLength);return s.list.length>e?1:p(e).div(s.list.length||1).div(2).dp(0,p.ROUND_UP).toNumber()})),h=S((()=>Array.from({length:m.value}).reduce((e=>e.concat(s.list.slice())),[]))),y=S((()=>p(d.value).div(s.speedRate).toNumber())),v=S((()=>({"--marquee-animation-duration-seconds":`${y.value}s`})));const f=H((async function(e){for(const t of e)t.contentBoxSize&&_()}),100),g=new ResizeObserver(f);const C=H((function(){document.hidden||_()}),50);const _=H((async function(){l.value=!1,await async function(){var e,t,a;await E(),d.value=(null==(a=null==(t=null==(e=o.value)?void 0:e[0])?void 0:t.getBoundingClientRect())?void 0:a.width)||0}(),await E(),l.value=!0}),200);return w((()=>s.list),(e=>{(null==e?void 0:e.length)&&_()}),{deep:!0,immediate:!0}),N((()=>{document.addEventListener("visibilitychange",C),n.value&&g.observe(n.value)})),k((()=>{document.removeEventListener("visibilitychange",C),n.value&&g.unobserve(n.value)})),(e,s)=>(a(),t("div",{ref_key:"marqueeContainerRef",ref:n,class:u(["common-marquee",{"starting-animation":l.value,"is-pause":e.isPause,"hover-pause":e.isHoverPause}]),style:F(v.value)},[r("div",Qt,[(a(),t(x,null,L(2,(s=>r("div",{key:s,ref_for:!0,ref_key:"groupListRef",ref:o,class:"marquee-group"},[(a(!0),t(x,null,L(h.value,((r,s)=>(a(),t("div",{key:s,class:"marquee-item"},[M(e.$slots,"default",{info:r},(()=>[c(i(r),1)]),!0)])))),128))]))),64))])],6))}}),[["__scopeId","data-v-6ddf83a4"]]),jt={class:"otc-timeline"},Yt={key:0,class:"time-text"},Gt=Ge(v({__name:"OtcTimeline",props:{time:{default:tt.TIMELINE_TIME},styleType:{default:""},disabled:{type:Boolean}},emits:["timeout"],setup(e,{expose:s,emit:n}){const o=e,l=n,{t:c}=g(),d=b(o.time),m=b(0),p=b(null),y=S((()=>Math.max(0,Math.ceil(d.value/1e3)))),v=S((()=>{if(!o.time)return 0;const e=o.time-d.value;return Math.min(100,Math.max(0,e/o.time*100))})),f=S((()=>({"background-position":`${v.value}%`}))),C=S((()=>c("otc.timeline.expired",{time:y.value}))),_=S((()=>({buy:o.styleType===at.BUY,sell:o.styleType===at.SELL})));function T(){p.value&&(clearInterval(p.value),p.value=null)}function I(){d.value=Math.max(0,m.value-Date.now()),d.value<=0&&(T(),l("timeout",x))}function N(){T(),m.value=Date.now()+o.time,d.value=o.time,p.value=setInterval(I,300)}function k(){T(),d.value=o.time}function x(){N()}return s({resetTimeline:x,stop:k}),w((()=>o.disabled),(e=>e?k():N()),{immediate:!0}),D((()=>{T()})),(e,s)=>(a(),t("div",jt,[r("div",{class:u(["otc-timeline-text",_.value])},[r("div",{class:u(["otc-timeline-light",_.value]),style:F(f.value)},null,6),M(e.$slots,"default",{},void 0,!0)],2),e.disabled?h("",!0):(a(),t("span",Yt,i(C.value),1))]))}}),[["__scopeId","data-v-8ab39e20"]]),Ht=Ge(v({__name:"IconNoData2",setup:e=>(e,t)=>
1(a(),o(ye,{class:"icon-no-data-2",width:"76",height:"76","aria-label":"NoData Icon 2",viewBox:"0 0 76 76","fill-rule":"evenodd"},{default:l((()=>t[0]||(t[0]=[r("path",{d:"M37.817 3.958L53.3 19.441v16.366c-.861-.12-1.74-.182-2.633-.182-.552 0-1.098.024-1.637.07V22.46H34.798V8.228H10.603v54.794h23.022c.77 1.555 1.745 2.99 2.892 4.27H6.333V3.958h31.484zM31.96 51.281c-.193 1.086-.294 2.203-.294 3.344 0 .31.007.618.022.925H15.584v-4.27zm5.157-9.963c-1.242 1.264-2.31 2.7-3.161 4.27H15.584v-4.27zm6.971-9.963v4.27H15.625v-4.27h28.464zm-5.022-20.108v6.944h6.944l-6.944-6.944z",transform:"translate(-777 -307) translate(777 307)"},null,-1),r("path",{fill:"var(--custom-nodata2-magnifier, var(--compbg-neutral-500))",d:"M49.875 40.117c7.576 0 13.717 6.14 13.717 13.716 0 2.64-.746 5.106-2.038 7.198l7.015 5.538-1.962 2.485-7.017-5.538c-2.483 2.492-5.92 4.034-9.715 4.034-7.576 0-13.717-6.141-13.717-13.717 0-7.575 6.141-13.716 13.717-13.716zm0 3.026c-5.904 0-10.69 4.786-10.69 10.69 0 5.905 4.786 10.69 10.69 10.69s10.69-4.785 10.69-10.69c0-5.904-4.786-10.69-10.69-10.69zM44.252 53.78c1.371 3.802 3.05 5.307 7.455 5.375l.421.003.009 1.9c-5.444.024-7.866-1.898-9.528-6.244l-.144-.39 1.787-.644z",transform:"translate(-777 -307) translate(777 307)"},null,-1)]))),_:1,__:[0]}))}),[["__scopeId","data-v-89935148"]]),Kt={key:1,class:"otc-panel-quote-container"},Jt={class:"otc-quote__wrapper"},Xt={class:"item"},Zt={class:"des"},ea={class:"value"},ta={class:"otc-text otc-text--center otc-text--primary otc-quote__input otc-quote__input-crypto"},aa={class:"otc-text-prefix"},ra={class:"otc-panel-quote-coin-container"},ia={class:"item quote"},sa={class:"des"},na={class:"value"},oa={class:"content"},la={class:"fiat-currency"},ca={key:0,class:"note"},ua={class:"item total"},da={class:"des"},ma={class:"total-right"},pa={class:"value"},ha={class:"fiat-currency"},ya={key:2,class:"otc-panel-footer"},va={class:"footer-btn"},fa=Ge(v({__name:"OtcPanelQuote",props:{data:{default:()=>({})},orderType:{},inputUpdate:{type:Boolean,default:!1}},emits:["update:inputUpdate","update:isQuoteWaiting"],setup(e,{emit:s}){const c=e,d=s,m=g(),p=Ie(),y=P(),{$openDialog:v}=ve(),{$sendEvent:f}=Se(),_=ie(),{lang:T,loginState:I,currencyMap:N,accountInfo:k}=C(_),F=rt(),x=b(null),L=b(null),M=b(!1),D=S((()=>c.data)),$=S({get:()=>F.quoteState,set(e){F.setQuoteState(e)}}),B=S((()=>0!==Object.keys(D.value).length)),z=S((()=>c.orderType===at.BUY)),O=S((()=>z.value?m.t("otc.tab.buy"):m.t("otc.tab.sell"))),U=S((()=>"USD"!==D.value.payCurrency)),R=S((()=>$.value===it.TIMEOUT||M.value)),A=S((()=>{const{buyCurrency:e}=D.value;return m.t("otc.description.price.2",{cryptoType:e})})),q=S((()=>z.value?m.t("otc.total.buy"):m.t("otc.total.sell"))),W=S((()=>{const{cryptoAmount:e}=D.value;return se(e)})),Q=S((()=>D.value.buyCurrency)),V=S((()=>{var e;return(null==(e=N.value[D.value.buyCurrency??""])?void 0:e.isFiat)?"fiat":"coin"})),j=S((()=>{const{priceEachCrypto:e}=D.value;return se(e)})),Y=S((()=>{const{totalPrice:e}=D.value;return se(e)})),G=S((()=>D.value.payCurrency)),H=S((()=>{const{usdPrice:e}=D.value;return`≈ ${se(e)} USD`})),K=S((()=>z.value?m.t("otc.button.accept.buy"):m.t("otc.button.accept.sell"))),X=S((()=>m.t("otc.button.reject"))),Z=S((()=>({buy:D.value.orderType===at.BUY,sell:D.value.orderType===at.SELL})));function ee(){k.value.kycNotice!==be.limited?(d("update:isQuoteWaiting",!1),I.value?async function(){try{await J.acceptOtcQuote(D.value.quoteId),f(_e.EVENT_WEB_OTC_BUY_SELL_ORDER_SUBMITTED,{submitSuccess:!0,quoteData:D.value}),re(),$.value=it.CONFIRMED,M.value=!0}catch{f(_e.EVENT_WEB_OTC_BUY_SELL_ORDER_SUBMITTED,{submitSuccess:!1,quoteData:D.value}),te()}}():y.push({name:Te.LOGIN,params:{lang:T.value}})):v(mt,{visible:!0})}function te(){F.clearQuote(),re(),d("update:isQuoteWaiting",!1),window.scroll({top:0,behavior:"smooth"})}function ae(){$.value=it.TIMEOUT}function re(){L.value&&L.value.stop()}function se(e=""){const t=String(e);let a=t.replace(/^\d*\./g,"").length;return a>4&&(a="48"),fe(t,a)}return w((()=>c.inputUpdate),(e=>{e&&te(),d("update:inputUpdate",!1)})),w($,(e=>{e===it.INIT&&(M.value=!1)})),w((()=>F.quoteState),(e=>{e===it.REFRESH&&L.value&&L.value.resetTimeline()})),w(B,(async e=>{var t;if(!p.isMobile||!e)return;await E();const a=null==(t=x.value)?void 0:t.$el;a&&window.scroll({top:a.offsetTop,behavior:"smooth"})})),(e,s)=>e.isMobile&&B.value||!e.isMobile?(a(),o(nt,{key:0,ref_key:"otcBlockRef",ref:x,class:u(["otc-panel-quote",{active:B.value}])},{default:l((()=>[B.value?h("",!0):(a(),o(ge,{key:0,class:"no-data-wrap"},{"no-data-icon":l((()=>[n(Ht,{class:"no-data-icon"})])),"empty-text":l((()=>[r("span",null,i(e.$t("otc.no_quote")),1)])),_:1})),B.value?(a(),t("div",Kt,[r("div",Jt,[r("div",Xt,[r("div",Zt,i(O.value),1),r("div",ea,[r("div",ta,[r("div",aa,i(W.value),1),r("div",ra,[n(Ce,{class:"otc-panel-quote-coin-icon",name:Q.value,shortName:"",type:V.value,size:"24"},null,8,["name","type"])])])])]),r("div",ia,[r("div",sa,i(A.value),1),r("div",na,[r("span",oa,i(j.value),1),r("span",la,i(G.value),1),s[0]||(s[0]=r("br",null,null,-1)),U.value?(a(),t("span",ca,i(H.value),1)):h("",!0)])]),r("div",ua,[r("span",da,i(q.value),1),r("div",ma,[r("span",pa,i(Y.value),1),r("span",ha,i(G.value),1)])])])])):h("",!0),B.value?(a(),t("div",ya,[r("div",va,[n(st,{class:u(["reject-btn block",Z.value]),isNewStyle:"",text:X.value,onClick:te},null,8,["class","text"])]),n(Gt,{ref_key:"timelineRef",ref:L,class:"footer-btn time-line",styleType:D.value.orderType,time:D.value.expiredTime,disabled:!B.value,onTimeout:ae},{default:l((()=>[n(st,{class:"accept-button block",isNewStyle:"",text:K.value,disabled:R.value,styleType:D.value.orderType,isFill:!0,noBackgroun
1d:!0,onClick:ee},null,8,["text","disabled","styleType"])])),_:1},8,["styleType","time","disabled"])])):h("",!0)])),_:1},8,["class"])):h("",!0)}}),[["__scopeId","data-v-ed163cdb"]]),ga={class:"otc-tabs"},Ca={class:"text"},ba={class:"text"},Sa=Ge(v({__name:"OtcTabs",props:{model:{default:at.BUY}},emits:["update:model"],setup(e,{emit:s}){const n=s;function o(e){n("update:model",e)}return(e,s)=>(a(),t("div",ga,[r("div",{class:u(["tab item-buy",{"is-active":e.model===T(at).BUY}]),onClick:s[0]||(s[0]=e=>o(T(at).BUY))},[r("span",Ca,i(e.$t("otc.tab.buy")),1)],2),r("div",{class:u(["tab item-sell",{"is-active":e.model===T(at).SELL}]),onClick:s[1]||(s[1]=e=>o(T(at).SELL))},[r("span",ba,i(e.$t("otc.tab.sell")),1)],2)]))}}),[["__scopeId","data-v-16238c45"]]),_a={class:"otc-panel"},Ta=Ge(v({__name:"OtcPanel",props:{orderType:{default:tt.ORDER_TYPE},orderTypeModifiers:{}},emits:["update:orderType"],setup(e){const i=$(e,"orderType"),s=S((()=>{switch(i.value){case at.BUY:return"buy";case at.SELL:return"sell";default:return""}}));return(e,o)=>(a(),t("div",_a,[n(Sa,{model:i.value,"onUpdate:model":o[0]||(o[0]=e=>i.value=e)},null,8,["model"]),r("div",{class:u(["content",s.value])},[M(e.$slots,"default",{orderType:i.value},void 0,!0)],2)]))}}),[["__scopeId","data-v-da7b0214"]]),Ia={class:"contact-us-text"},wa=["href"];const Na=Ge({name:"ContactUsText",computed:{contactLink:()=>`mailto:${we.bdEmail}`}},[["render",function(e,s,n,o,l,u){return a(),t("div",Ia,[c(i(e.$t("streamingQuote.commercialNote"))+" ",1),r("a",{href:u.contactLink,class:"contact-us-email"},i(e.$t("t.contactUs")),9,wa)])}],["__scopeId","data-v-d35db868"]]),ka={name:"SimplePageShell",components:{IconWatermarkBtc:ce,IconWatermarkEth:ue,IconWatermarkUsd:de,IconWatermarkXmr:me,IconWatermarkYen:pe,IconWatermarkDrop:he},props:{fullWidth:{type:Boolean,default:!1}},computed:{isCoinIconVisible:()=>K.bgCoinIconVisible}},Fa={key:0,class:"background"};const xa=Ge(ka,[["render",function(e,i,o,l,c,d){const m=s("IconWatermarkBtc"),p=s("IconWatermarkEth"),y=s("IconWatermarkUsd"),v=s("IconWatermarkXmr"),f=s("IconWatermarkYen"),g=s("IconWatermarkDrop");return a(),t("div",{class:u(["simple-page",{full:o.fullWidth}])},[d.isCoinIconVisible?(a(),t("div",Fa,[n(m,{class:u(["coin-icon btc-icon",{"is-mobile":e.isMobile}])},null,8,["class"]),n(p,{class:u(["coin-icon eth-icon",{"is-mobile":e.isMobile}])},null,8,["class"]),n(y,{class:u(["coin-icon usd-icon",{"is-mobile":e.isMobile}])},null,8,["class"]),e.isMobile?h("",!0):(a(),t(x,{key:0},[n(v,{class:"coin-icon xmr-icon"}),n(f,{class:"coin-icon yen-icon"}),n(g,{class:"img-bg"}),n(g,{class:"img-bg2"})],64))])):h("",!0),r("div",{class:u(["container",{full:o.fullWidth}])},[M(e.$slots,"default",{},void 0,!0)],2)],2)}],["__scopeId","data-v-a7fd8af8"]]),La={class:"apply-content"},Ma={class:"apply-title"},Ea={class:"apply-description"},Da=Ge(v({__name:"ApplySuccessDialog",props:{visible:{type:Boolean,default:!1},visibleModifiers:{}},emits:["update:visible"],setup(e){const t=$(e,"visible");return(e,s)=>(a(),o(xe,{visible:t.value,"onUpdate:visible":s[1]||(s[1]=e=>t.value=e),isBrandNewStyle:""},{header:l((()=>[c(i(e.$t("otc.masthead.title")),1)])),successIcon:l((()=>[n(Fe)])),buttons:l((()=>[n(Ne,{class:"primary block",size:T(ke).L,onClick:s[0]||(s[0]=e=>t.value=!1)},{default:l((()=>[c(i(e.$t("t.ok")),1)])),_:1},8,["size"])])),default:l((()=>[r("div",La,[r("div",Ma,i(e.$t("t.applicationSubmitted")),1),r("div",Ea,i(e.$t("otc.applySuccessDialog.description")),1)])])),_:1},8,["visible"]))}}),[["__scopeId","data-v-13866dfb"]]),Pa={applyForm:e=>Le.post("/otc/apply-form",e)},$a=1,Ba=2,za=3,Oa=1,Ua=2,Ra=3,Aa={class:"contact-form"},qa={class:"contact-fields"},Wa={class:"contact-buttons"},Qa=Ge(v({__name:"ContactForm",setup(e){const d="name",m="email",p="tradingDemand",h="monthlyTradingVolume",y="telegram",v="whatsapp",f="captcha",C=g(),{defineField:_,values:I,errors:w,meta:N,validate:k,handleReset:F}=Me({initialValues:{[d]:"",[m]:"",[p]:"",[h]:"",[y]:"",[v]:"",[f]:new Ee},validationSchema:{[d]:{required:!0},[m]:{required:!0,email:!0},[p]:{required:!0},[h]:{required:!0},[y]:{required:!0},[v]:{required:!0},[f](e){if(e.resetError(),e._type===De.LEGACY){if(!0==!e.value.captchaNumber)e.errorMessage=C.t("rules.required");if(e.isJumpingError)return!1}return!0}}}),[x,L]=_(d),[M,E]=_(m),[D,P]=_(p),[$,O]=_(h),[U,R]=_(y),[A,q]=_(v),[W,Q]=_(f),V=b(null),j=b(Symbol()),Y=b(!1),G=b(!1),H=S((()=>[{name:C.t("otc.contactForm.tradingDemand.onRampOrFiatToCrypto.name"),value:$a},{name:C.t("otc.contactForm.tradingDemand.offRampOrCryptoToFiat.name"),value:Ba},{name:C.t("otc.contactForm.tradingDemand.cryptoToCrypto.name"),value:za}])),K=S((()=>[{name:C.t("otc.contactForm.monthlyTradingVolume.lessThan2m.name"),value:Oa},{name:C.t("otc.contactForm.monthlyTradingVolume.between2mAnd10m.name"),value:Ua},{name:C.t("otc.contactForm.monthlyTradingVolume.moreThan10m.name"),value:Ra}]));async function J(){var e;try{const{valid:t}=await k();if(t){if(Y.value=!0,!I[f].isCompleted)return void(null==(e=V.value)||e.startCaptchaValidation());await Pa.applyForm({name:x.value,email:M.value,tradingDemand:D.value.value,monthlyTradingVolume:$.value.value,telegram:U.value,whatsapp:A.value,...W.value._value}),G.value=!0,F(),j.value=Symbol()}}catch(t){}finally{Y.value=!1}}return(e,f)=>{const g=s("BrandInput"),C=s("BaseButton");return a(),t("div",Aa,[r("div",qa,[n(Pe,{requireMark:"",errorMessage:T(w)[d]},{label:l((()=>[c(i(e.$t("otc.contactForm.name.label")),1)])),default:l((({hasError:t})=>[n(g,B({value:T(x),"onUpdate:value":f[0]||(f[0]=e=>z(x)?x.value=e:null),isBrandNewStyle:"",clearable:"",placeholder:e.$t("otc.contactForm.name.placeholder"),isError:t},T(L)),null,16,["value","placeholder","isError"])])),_:1},8,["errorMessage"]),n(Pe,{requireMark:"",errorMessage:T(w)[m]},{label:l((()=>[c(i(e.$t("otc.contactForm.email.label")),1)])),default:l((({hasError:t})=>[n(g,B({value:T(M),"onUpdate:value":f[1]||(f[1]=e=>z(M)?M.value=e:null),isBrandNewStyle:"",clearable:"",placeholder:e.$t("otc.contactForm.email.placeholder"),isError:t},T(E)),null,16,["value","placeholder","isError"])])),_:1},8,["errorMessage"]),n(Pe,{requireMark:"",errorMessage:T(w)[p]},{label:l((()=>[c(i(e.$t("otc.contactForm.tradingDemand.label")),1)])),default:l((({hasError:t})=>[n($e,B({modelValue:T(D),"onUpdate:modelValue":f[2]||(f[2]=e=>z(D)?D.value=e:null),class:"contact-dropdown",list:H.value,placeholder:e.$t("otc.contactForm.tradingDemand.placeholder"),isError:t},T(P)),null,16,["modelValue","list","placeholder","isError"])])),_:1},8,["errorMessage"]),n(Pe,{requireMark:"",errorMessage:T(w)[h]},{label:l((()=>[c(i(e.$t("otc.contactForm.monthlyTradingVolume.label")),1)])),default:l((({hasError:t})=>[n($e,B({modelValue:T($),"onUpdate:modelValue":f[3]||(f[3]=e=>z($)?$.value=e:null),class:"contact-dropdown",list:K.value,placeholder:e.$t("otc.contactForm.monthlyTradingVolume.placeholder"),isError:t},T(O)),null,16,["modelValue","list","placeholder","isError"])])),_:1},8,["errorMessage"]),n(Pe,{requireMark:"",errorMessage:T(w)[y]},{label:l((()=>[c(i(e.$t("otc.contactForm.telegram.label")),1)])),default:l((({hasError:t})=>[n(g,B({value:T(U),"onUpdate:value":f[4]||(f[4]=e=>z(U)?U.value=e:null),isBrandNewStyle:"",clearable:"",placeholder:e.$t("otc.contactForm.telegram.placeholder"),isError:t},T(R)),null,16,["value","placeholder","isError"])])),_:1},8,["errorMessage"]),n(Pe,{requireMark:"",errorMessage:T(w)[v]},{label:l((()=>[c(i(e.$t("t.whatsApp")),1)])),default:l((({hasError:t})=>
1[n(g,B({value:T(A),"onUpdate:value":f[5]||(f[5]=e=>z(A)?A.value=e:null),isBrandNewStyle:"",clearable:"",placeholder:e.$t("otc.contactForm.whatsapp.placeholder"),isError:t},T(q)),null,16,["value","placeholder","isError"])])),_:1},8,["errorMessage"])]),r("div",Wa,[n(C,{size:T(ke).L,class:u(["primary",{disabled:!T(N).valid}]),isLoading:Y.value,onClick:J},{default:l((()=>[c(i(e.$t("t.contactUs")),1)])),_:1},8,["size","class","isLoading"]),(a(),o(Be,B({ref_key:"captchaRef",ref:V,key:j.value,modelValue:T(W),"onUpdate:modelValue":f[6]||(f[6]=e=>z(W)?W.value=e:null),isShowImmediately:""},T(Q),{onHandleSuccess:J}),null,16,["modelValue"]))]),n(Da,{visible:G.value,"onUpdate:visible":f[7]||(f[7]=e=>G.value=e)},null,8,["visible"])])}}}),[["__scopeId","data-v-e6e9ce73"]]),Va={class:"contact-us"},ja={class:"contact-inner"},Ya={class:"contact-title"},Ga=Ge(v({__name:"ContactUs",setup:e=>(e,s)=>(a(),t("div",Va,[r("div",ja,[r("div",Ya,i(e.$t("t.contactUs")),1),n(Qa,{class:"contact-form"})])]))}),[["__scopeId","data-v-dc08d52c"]]),Ha={class:"otc-section"},Ka=Ge(v({__name:"OtcSection",setup(e){const r=g(),{orderType:i,quoteState:s,quoteData:c,clearQuote:u}=ot(),d=S((()=>s.value===it.CONFIRMED)),m=S((()=>{const e=c.value.orderType===at.BUY,t=e?r.t("otc.tab.buy"):r.t("otc.tab.sell"),a=e?r.t("otc.wallet.pay"):r.t("otc.wallet.sell");return{isOTCOrder:!0,amount:c.value.totalPrice,amountCurrency:c.value.payCurrency,rate:c.value.priceEachCrypto,settlementAmount:c.value.cryptoAmount,settlementCurrency:c.value.buyCurrency,title:t,actionText:t,totalPayText:a}})),p=b(!1),y=b(!1);function v(e){i.value=e,u()}return(e,r)=>(a(),t("div",Ha,[n(Ta,{orderType:T(i),"onUpdate:orderType":r[5]||(r[5]=e=>z(i)?i.value=e:null)},{default:l((()=>[n(lt,{data:T(c),"onUpdate:data":r[0]||(r[0]=e=>z(c)?c.value=e:null),isQuoteWaiting:p.value,"onUpdate:isQuoteWaiting":r[1]||(r[1]=e=>p.value=e),inputUpdate:y.value,"onUpdate:inputUpdate":r[2]||(r[2]=e=>y.value=e),isNewStyle:"",isShowSeparator:"",orderType:T(i),onOnOrderTypeChange:v},null,8,["data","isQuoteWaiting","inputUpdate","orderType"]),n(fa,{isQuoteWaiting:p.value,"onUpdate:isQuoteWaiting":r[3]||(r[3]=e=>p.value=e),inputUpdate:y.value,"onUpdate:inputUpdate":r[4]||(r[4]=e=>y.value=e),class:"otc-panel-quote",data:T(c),orderType:T(i)},null,8,["isQuoteWaiting","inputUpdate","data","orderType"]),d.value?(a(),o(Xe,{key:0,data:m.value,closeAction:T(u)},null,8,["data","closeAction"])):h("",!0)])),_:1},8,["orderType"])]))}}),[["__scopeId","data-v-ae25967f"]]),Ja={class:"otc-masthead"},Xa={class:"masthead-inner"},Za={class:"masthead-left"},er={class:"masthead-left-content"},tr={class:"masthead-title"},ar={class:"masthead-subtitle"},rr={class:"masthead-description"},ir={class:"masthead-buttons"},sr=["src"],nr={class:"masthead-right"},or={class:"masthead-disclaimer"},lr=Ge(v({__name:"Masthead",emits:["clickContact"],setup(e,{emit:o}){const u=o,d=ie(),m=S((()=>d.isSupportWebp?"/static/img/BDr67LU1.webp":"/static/img/BuVFJTnn.png"));return(e,o)=>{const d=s("BaseButton");return a(),t("div",Ja,[r("div",Xa,[r("div",Za,[r("div",er,[r("div",tr,i(e.$t("otc.masthead.title")),1),r("div",ar,i(e.$t("otc.masthead.subtitle")),1),r("div",rr,i(e.$t("otc.masthead.description")),1),r("div",ir,[n(d,{class:"primary",type:T(ke).L,onClick:o[0]||(o[0]=e=>u("clickContact",e))},{default:l((()=>[c(i(e.$t("t.contactUs")),1)])),_:1},8,["type"])])]),e.isDesktop?(a(),t("img",{key:0,class:"masthead-image",src:m.value},null,8,sr)):h("",!0)]),r("div",nr,[n(Ka),r("div",or,i(e.$t("otc.masthead.disclaimer")),1)])])])}}}),[["__scopeId","data-v-26789e02"]]),cr={class:"currency-chips"},ur={class:"multiple-chips"},dr={class:"currency-chip"},mr=Ge(v({__name:"CurrencyChips",setup(e){const i=b(!1),s=ie(),{currencyMap:c}=C(s),u=ct(),{otcCurrencies:d,otcFromCurrencies:m,currencyAliasMap:p}=C(u),h=S((()=>{const e=m.value.reduce(((e,t)=>{const a=c.value[t];return e.has(t)||e.set(t,a),e}),new Map),t=d.value.reduce(((e,t)=>(t.supportQuoteCurrencies.forEach((t=>{const a=p.value[t]||t,r=c.value[a];r&&r.available&&!e.has(a)&&e.set(a,r)})),e)),e);return Array.from(t.values()).sort((()=>Math.random()-Math.random()))})),y=S((()=>h.value.reduce(((e,t,a)=>{const r=a%3;return e[r]?e[r].push(t):e.length===a&&e.push([t]),e}),[])));return O((()=>{u.debounceFetchMarkets()})),(e,s)=>(a(),o(T(pt),{offset:0,onViewed:s[0]||(s[0]=e=>i.value=!!e)},{default:l((()=>[r("div",cr,[r("div",ur,[(a(!0),t(x,null,L(y.value,((e,t)=>
1(a(),o(Vt,{key:`line_${t}`,class:"marquee-line",list:e,isPause:!i.value},{default:l((({info:e})=>[r("div",dr,[n(Ce,{class:"currency",shortName:"",displayName:null==e?void 0:e.displayName,type:e.isFiat?T(ze).FIAT:T(ze).COIN,name:e.shortName,size:"32",imgLoadingAttr:"lazy"},null,8,["displayName","type","name"])])])),_:2},1032,["list","isPause"])))),128))])])])),_:1}))}}),[["__scopeId","data-v-7fa631fd"]]),pr={class:"support-currency"},hr={class:"support-title"},yr=Ge(v({__name:"SupportCurrency",setup:e=>(e,s)=>(a(),t("div",pr,[r("div",hr,i(e.$t("otc.supportCurrency.title")),1),n(mr,{class:"support-content"})]))}),[["__scopeId","data-v-e344bce5"]]),vr={class:"feature-card"},fr={class:"feature-title"},gr={class:"feature-description"};const Cr=Ge({},[["render",function(e,i){return a(),t("div",vr,[r("div",fr,[M(e.$slots,"title",{},void 0,!0)]),r("div",gr,[M(e.$slots,"description",{},void 0,!0)])])}],["__scopeId","data-v-15494f92"]]),br={class:"what-we-offer"},Sr={class:"what-we-offer-inner"},_r={class:"section-title"},Tr={class:"offer-detail"},Ir={class:"detail-left offer-banner"},wr={class:"offer-description"},Nr={class:"offer-image-container"},kr=["src"],Fr={class:"detail-right card-container"},xr=Ge(v({__name:"WhatWeOffer",setup(e){const s=g(),n=ie(),u=S((()=>n.isSupportWebp?"/static/img/DHlwDxVx.webp":"/static/img/LJVoMMbZ.jpg")),d=S((()=>[{title:s.t("otc.whatWeOffer.features.fiatToCrypto.title"),description:s.t("otc.whatWeOffer.features.fiatToCrypto.description")},{title:s.t("otc.whatWeOffer.features.cryptoToFiat.title"),description:s.t("otc.whatWeOffer.features.cryptoToFiat.description")},{title:s.t("otc.whatWeOffer.features.cryptoToCrypto.title"),description:s.t("otc.whatWeOffer.features.cryptoToCrypto.description")}]));return(e,s)=>(a(),t("div",br,[r("div",Sr,[r("div",_r,i(e.$t("otc.whatWeOffer.title")),1),r("div",Tr,[r("div",Ir,[r("div",wr,i(e.$t("otc.whatWeOffer.description")),1),r("div",Nr,[r("img",{class:"offer-image",src:u.value},null,8,kr)])]),r("div",Fr,[(a(!0),t(x,null,L(d.value,((e,t)=>(a(),o(Cr,{key:t},{title:l((()=>[c(i(e.title),1)])),description:l((()=>[c(i(e.description),1)])),_:2},1024)))),128))])])])]))}}),[["__scopeId","data-v-02f06ecb"]]),Lr={class:"global-presence"},Mr={class:"global-left global-presence-content"},Er={class:"global-presence-title"},Dr={class:"global-presence-description"},Pr={class:"global-right global-image-container"},$r=["src"],Br=Ge(v({__name:"GlobalPresence",setup(e){const s=ie(),n=S((()=>s.isSupportWebp?"/static/img/BOZOs5GM.webp":"/static/img/KwwDCjH8.png"));return(e,s)=>(a(),t("div",Lr,[r("div",Mr,[r("div",Er,i(e.$t("otc.globalPresence.title")),1),r("div",Dr,i(e.$t("otc.globalPresence.description")),1)]),r("div",Pr,[r("img",{class:"global-image",src:n.value},null,8,$r)])]))}}),[["__scopeId","data-v-e60093ed"]]),zr={class:"diverse-banking"},Or={class:"banking-title"},Ur={class:"banking-description"},Rr={class:"banking-image-container"},Ar=["src"],qr=Ge(v({__name:"DiverseBanking",setup(e){const s=ie(),n=S((()=>s.isSupportWebp?"/static/img/Czfx8YHX.webp":"/static/img/GFgQVWKJ.png"));return(e,s)=>(a(),t("div",zr,[r("div",Or,i(e.$t("otc.diverseBanking.title")),1),r("div",Ur,i(e.$t("otc.diverseBanking.description")),1),r("div",Rr,[r("img",{class:"banking-image",src:n.value},null,8,Ar)])]))}}),[["__scopeId","data-v-bcff6577"]]),Wr={class:"competitive-pricing"},Qr={class:"pricing-title"},Vr={class:"pricing-description"},jr={class:"pricing-image-container"},Yr=["src"],Gr=Ge(v({__name:"CompetitivePricing",setup(e){const s=ie(),n=S((()=>s.isSupportWebp?"/static/img/CTZwU4Hz.webp":"/static/img/CHmRV_AV.png"));return(e,s)=>(a(),t("div",Wr,[r("div",Qr,i(e.$t("otc.competitivePricing.title")),1),r("div",Vr,i(e.$t("otc.competitivePricing.description")),1),r("div",jr,[r("img",{class:"pricing-image",src:n.value},null,8,Yr)])]))}}),[["__scopeId","data-v-e84b8ef0"]]),Hr={class:"strategic-trading-partnership"},Kr={class:"strategic-left"},Jr=["src"],Xr={class:"strategic-right"},Zr={class:"strategic-title"},ei={class:"strategic-description"},ti=Ge(v({__name:"StrategicTradingPartnerships",setup(e){const s=ie(),n=S((()=>
1s.isSupportWebp?"/static/img/BAho6VEN.webp":"/static/img/FJOShOuz.png"));return(e,s)=>(a(),t("div",Hr,[r("div",Kr,[r("img",{class:"strategic-image",src:n.value},null,8,Jr)]),r("div",Xr,[r("div",Zr,i(e.$t("otc.strategicTradingPartnership.title")),1),r("div",ei,i(e.$t("otc.strategicTradingPartnership.description")),1)])]))}}),[["__scopeId","data-v-fb4f05f4"]]),ai={class:"why-trade-with-us"},ri={class:"why-trade-inner"},ii={class:"why-trade-title"},si={class:"why-trade-middle-section"},ni={class:"middle-section-left"},oi={class:"middle-section-right"},li=Ge(v({__name:"WhyTradeWithUs",setup:e=>(e,s)=>(a(),t("div",ai,[r("div",ri,[r("div",ii,i(e.$t("otc.whyTradeWithUs.title")),1),n(Br),r("div",si,[r("div",ni,[n(qr,{class:"diverse-banking"})]),r("div",oi,[n(Gr,{class:"competitive-pricing"})])]),n(ti)])]))}),[["__scopeId","data-v-f42b3579"]]),ci={class:"otc-page"},ui=["id"],di=Ge(v({__name:"OtcV2",setup(e){const i=ct(),s=b(null);function o(){s.value&&s.value.scrollIntoView({behavior:"smooth",block:"center"})}return k((()=>{i.clearRetryFetchMarketTimer()})),(e,i)=>(a(),t("div",ci,[n(le,{class:"kyc-notification"}),n(lr,{onClickContact:o}),n(xr),n(li),n(yr),r("div",{id:T(ut),ref_key:"contactUsRef",ref:s},[n(Ga)],8,ui)]))}}),[["__scopeId","data-v-1990b467"]]),mi=Object.freeze(Object.defineProperty({__proto__:null,default:di},Symbol.toStringTag,{value:"Module"})),pi={name:"StreamingButton",props:{text:{type:String,default:""},styleType:{type:String,default:""},disabled:{type:Boolean,default:!1},quote:{type:Object,default:()=>({})}},emits:["click"],computed:{isBuy(){return this.styleType===at.BUY},buttonClasses(){return{"button--buy":this.styleType===at.BUY,"button--sell":this.styleType===at.SELL,"button--disabled":this.disabled||!this.hasQuote}},hasQuote(){return Object.keys(this.quote).length>0&&this.quote.priceInOrderCurrency},quoteValue(){var e;const t=this.$filters,a=(null==(e=this.quote)?void 0:e.priceInOrderCurrency)||0,r=this.getEffectiveDigitsLength(a),i=this.isBuy?p.ROUND_UP:p.ROUND_DOWN;let s="8";return r>=12&&(s="2"),r>=8&&r<12&&(s="4"),t.formatNumber(a,{formatKey:s,roundMode:i})}},methods:{getBaseLog:(e,t)=>Math.log(t)/Math.log(e),getEffectiveDigitsLength(e){const t=p(e).times(Math.pow(10,8)).toNumber(),a=this.getBaseLog(10,t);return Math.ceil(a)}}},hi={class:"type"},yi={class:"quote"};const vi=Ge(pi,[["render",function(e,s,n,o,l,c){return a(),t("div",{class:u(["streaming-button",{...c.buttonClasses,"no-quote":!c.hasQuote}]),onClick:s[0]||(s[0]=t=>e.$emit("click",t))},[r("span",hi,i(n.text),1),r("span",yi,i(c.quoteValue),1)],2)}],["__scopeId","data-v-c9acd802"]]),fi="BTC",gi="ETH",Ci=(at.BUY,"size"),bi="ACCEPTED",Si="REJECTED",_i="CODE",Ti=["BTC","ETH","LTC","TUSD","USDC","USDT","DAI","PAX","USDP","WAED","WAUD","WCAD","WCHF","WEUR","WGBP","WHKD","WINR","WJPY","WMYR","WSGD","WUSD","AED","AUD","CAD","EUR","HKD","INR","JPY","SGD","USD","CHF","GBP","MYR"],Ii=["JT_BTC","JT_ETH","JT_LTC","BTC","ETH","LTC","TUSD","USDC","USDT","PAX","USDP","DAI"];class wi{constructor(e,t){this.text=e||"",this.sizeCurrency=t||""}}const Ni={data:()=>({nextNotify:new wi,currentNotify:new wi,isShowNotify:!1,isNotifySuccess:!1}),methods:{mixinNotify(e){const{status:t,memo:a,message:r,errorCode:i}=e;if(r)return this._sendNotification(r);switch(t){case bi:return this._sendAcceptedNotification(e);case Si:return this._sendMemoNotification("otc.notify.rejected",a);case _i:return this._sendMemoNotification(`response-code.${i}`);default:return}},_sendNotification(e,t,a){this.swapTimeout||this.showNotify(e,t,a)},hideNotify(){this.isShowNotify=!1,this.currentNotify=new wi,this.nextNotify=new wi},swapNotify(){this.currentNotify=this.nextNotify,this.nextNotify=new wi},showNotify(e,t=!1,a){const r=t?5e3:1e3;clearTimeout(this.showNotifyTimeout),this.isNotifySuccess=t,this.nextNotify=new wi(e,a),this.isShowNotify=!0,this.handleTargetNotify(this.targetId),this.swapTimeout=setTimeout((()=>{clearTimeout(this.swapTimeout),this.swapTimeout=null,this.swapNotify()}),300),this.showNotifyTimeout=setTimeout((()=>{this.hideNotify()}),r)},_sendMemoNotification(e,t){const a=this._i18nMemoText(t),r=this.$t(e,[a]);this._sendNotification(r)},_sendAcceptedNotification(e){const{side:t="",deductAmount:a,receiveAmount:r,deductCurrency:i,receiveCurrency:s,priceInOrderCurrency:n}=e,o=Oe(t);let l="",c="";const u=n;let d="",m="";t===at.SELL&&(l=a,c=i,d=this.formatNumber(p(u).times(l).toNumber()),m=s),t===at.BUY&&(l=r,c=s,d=this.formatNumber(p(u).times(l).toNumber()),m=i);const h=t===at.SELL?i:s,y=`Success. ${o}: ${this.formatNumber(l)} ${c} @${this.formatNumber(u)} (Total ${d} ${m})`;this._sendNotification(y,!0,h)},_i18nMemoText(e){try{const{msgKey:t,params:a,default_msg:r}=JSON.parse(e);return this.$te(t)?this.$t(t,a):r}catch(t){return e}},formatNumber(e){return this.$filters.formatNumber(e,"max8")}}};const ki={name:"StreamingNotifier",components:{IconSelected2:Ge({name:"IconSelected",components:{Icon:ye}},[["render",function(e,t,i,n,c,u){const d=s("Icon");return a(),o(d,{"aria-label":"selected",width:"18",height:"18",fill:"none",viewBox:"0 0 18 18"},{default:l((()=>
1t[0]||(t[0]=[r("circle",{cx:"9",cy:"9",r:"9",fill:"currentColor"},null,-1),r("path",{fill:"#222222",d:"M2.829 10.037H4.751V15.803H2.829z",transform:"rotate(-49.573 2.829 10.037)"},null,-1),r("path",{fill:"#222222",d:"M5.755 12.529H16.326V14.451H5.755z",transform:"rotate(-49.573 5.755 12.53)"},null,-1)]))),_:1,__:[0]})}]]),IconError:Ue},props:{nextNotify:{type:Object,required:!0},currentNotify:{type:Object,required:!0},sizeCurrency:{type:String,default:"BTC"},isNotifySuccess:{type:Boolean,required:!0},isShowNotify:{type:Boolean,required:!0}},computed:{...e(["lang"])},methods:{handleClickMore(e){if(!e||!e.sizeCurrency)return;const t=this.$router.resolve({name:"spotTradeHistory",params:{lang:this.lang}});window.open(t.href,"_blank")}}},Fi={class:"streaming-notifier next"},xi={class:"icon-wrap"},Li=["innerHTML"],Mi={class:"icon-wrap"},Ei=["innerHTML"];const Di=Ge(ki,[["render",function(e,n,l,c,d,m){const p=s("IconSelected2"),y=s("IconError");return a(),t("div",{class:u(["streaming-notifier-wrap",{toNext:l.nextNotify.text}])},[r("div",Fi,[r("div",xi,[l.isNotifySuccess?(a(),o(p,{key:0,class:"icon-success"})):(a(),o(y,{key:1,class:"icon-error"}))]),r("span",{innerHTML:l.nextNotify.text},null,8,Li),l.isNotifySuccess?(a(),t("span",{key:0,class:"more",onClick:n[0]||(n[0]=e=>m.handleClickMore(l.nextNotify))},i(e.$t("t.moreDetails")),1)):h("",!0)]),r("div",{class:u(["streaming-notifier current",{hidden:!l.isShowNotify}])},[r("div",Mi,[l.isNotifySuccess?(a(),o(p,{key:0,class:"icon-success"})):(a(),o(y,{key:1,class:"icon-error"}))]),r("span",{innerHTML:l.currentNotify.text},null,8,Ei),l.isNotifySuccess?(a(),t("span",{key:0,class:"more",onClick:n[1]||(n[1]=e=>m.handleClickMore(l.currentNotify))},i(e.$t("t.moreDetails")),1)):h("",!0)],2)],2)}],["__scopeId","data-v-95d23bb3"]]),Pi={name:"StreamingPanel",components:{StreamingButton:vi,InputWithCurrencyDropDown:Ke,IconAdd:Ae,IconDelete2:Re,StreamingNotifier:Di},props:{marketOriginalList:{type:Array,default:()=>[]},currencyAliasMap:{type:Object,default:()=>({})},handleAddPanel:{type:Function,default:()=>{}},handleClosePanel:{type:Function,default:()=>{}},isMultiplePanel:{type:Boolean,required:!0},defaultTradePair:{type:Object,required:!0},targetId:{type:String,required:!0},updateTradePairs:{type:Function,required:!0},targetIndex:{type:Number,required:!0},handleTargetNotify:{type:Function,required:!0},targetNotify:{type:String,default:""},totalPairs:{type:Number,required:!0}},emits:["closeWebSocket","mixinNotify","setupWebSocket"],data(){return{...Ni.data(),OrderSide:at,BarTextSize:G,webSocketKey:Ve(),baseType:Ci,size:"",valueOf:"",sizeCurrency:this.defaultTradePair.size,valueCurrency:this.defaultTradePair.value,currentRef:"streamingInputSize",tryTimes:0,keepQuoteData:{[at.SELL]:{},[at.BUY]:{}},keepAcceptQuoteData:{},DEFAULT_AMOUNT_DECIMAL_LIMIT:Qe,inputComponent:U(dt)}},computed:{...e(["isTradingCountry","currencyMap","loginState","lang"]),isLogin(){return this.loginState},showNotifier(){return!this.$deviceSmallerThan.lg(this.$mq)},baseCurrencyInfo(){return this.marketOriginalList.find((e=>e.assetName===this.sizeCurrency))||{}},quoteCurrencyInfoList(){let e=[],t=[];const{supportQuoteCurrencies:a=[],minQuoteSizes:r=[],maxQuoteSizes:i=[]}=this.baseCurrencyInfo;return a.forEach(((a,s)=>{const n=this.currencyMap[this.getCurrencyKey(a)];if(!Ti.includes(a)||!n)return;const o={currency:a,minQuoteSize:r[s],maxQuoteSize:i[s]};n.available?e.push(o):t.push(o)})),e=e.sort(We((e=>e.currency))),t=t.sort(We((e=>e.currency))),e.concat(t)},valueCurrencyList(){return this.quoteCurrencyInfoList.map((e=>e.currency))},quoteCurrencyInfo(){return this.quoteCurrencyInfoList.find((e=>e.currency===this.valueCurrency))||{}},sizeCurrencyList(){return this.marketOriginalList.map((e=>e.assetName))},webSocketPayload(){const e={clOrderId:this.webSocketKey,symbol:`${this.sizeCurrency}-${this.valueCurrency}`};switch(!0){case"size"===this.baseType&&!this.isBaseInputInvalid:case""===this.size&&""===this.valueOf:{const t=Number(this.size)||1;Object.assign(e,{quantity:{quantity:t.toString(),currency:this.sizeCurrency}});break}case"valueOf"===this.baseType&&!this.isQuoteInputInvalid:{const t=Number(this.valueOf)||1;Object.assign(e,{quantity:{quantity:t.toString(),currency:this.valueCurrency}});break}default:return null}return e},isValidInput(){const e=Number(this.size),t=Number(this.valueOf);return!!e||!!t},isSubmitDisabled(){return!this.isTradingCountry||!this.isValidInput||this.isBaseInputInvalid||this.isQuoteInputInvalid},sizeBalanceText(){const{available:e=0,isFiat:t}=this.getCurrencyInfo(this.sizeCurrency),a=t?"fc":"vc",r=this.$filters.formatNumber(e,a);return`${this.$t("convert.available.mobile")} ${r} ${this.sizeCurrency}`},valueBalanceText(){const{available:e=0,isFiat:t}=this.getCurrencyInfo(this.valueCurrency),a=t?"fc":"vc",r=this.$filters.formatNumber(e,a);return`${this.$t("convert.available.mobile")} ${r} ${this.valueCurrency}`},shouldShowNotify(){return this.isMobile?this.isShowNotify&&this.targetId===this.targetNotify:this.isShowNotify},baseInputPlaceholder(){const{minBaseSize:e,maxBaseSize:t}=this.baseCurrencyInfo||{};return`${this.getFormattedAmount(e)}-${this.getFormattedAmount(t)}`},quoteInputPlaceholder(){const{minQuoteSize:e,maxQuoteSize:t}=this.quoteCurrencyInfo||{};return`${this.getFormattedAmount(e)}-${this.getFormattedAmount(t)}`},baseInputInvalidMessage(){const{minBaseSize:e,maxBaseSize:t}=this.baseCurrencyInfo||{},a=p(this.size);return a.lt(e)?this.$t("otc.limit.min.v2",{min:this.getFormattedAmount(e)}):a.gt(t)?this.$t("otc.limit.max.v2",{max:this.getFormattedAmount(t)}):""},quoteInputInvalidMessage(){const{minQuoteSize:e,maxQuoteSize:t}=this.quoteCurrencyInfo||{},a=p(this.valueOf);return a.lt(e)?this.$t("otc.limit.min.v2",{min:this.getFormattedAmount(e)}):a.gt(t)?this.$t("otc.limit.max.v2",{max:this.getFormattedAmount(t)}):""},isBaseInputInvalid(){return Boolean(this.baseInputInvalidMessage)},isQuoteInputInvalid(){return Boolean(this.quoteInputInvalidMessage)}},watch:{defaultTradePair(){this.sizeCurrency=this.defaultTradePair.size,this.valueCurrency=this.defaultTradePair.value},baseType(){this.size="",this.valueOf=""},webSocketPayload(e,t){this.getQuotes(t)},sizeCurrencyList:{handler(){this.sizeCurrencyList.length>0&&!this.sizeCurrencyList.includes(this.sizeCurrency)&&(this.sizeCurrency=this.sizeCurrencyList[0],this.onSizeCurrencyChange())},immediate:!0},sizeCurrency(e,t){this.getCurrencyKey(e)===this.valueCurrency&&(this.valueCurrency=this.valueCurrencyList.includes(t)?t:this.valueCurrencyList[0],this.onValueCurrencyChange())}},mounted(){this.getQuotes()},beforeUnmount(){clearTimeout(this.showNotifyTimeout),this.$emit("closeWebSocket",{key:this.webSocketKey,payload:this.webSocketPayload})},methods:{...Ni.methods,sendNotification(e){this.$emit("mixinNotify",e),this.mixinNotify(e)},getCurrencyKey(e){return this.currencyAliasMap[e]||e},getCurrencyInfo(e){const t=this.getCurrencyKey(e);return this.currencyMap[t]||{}},notifyStatus(e,t){this.sendNotification({status:e,memo:t})},onTab(e,t){e.preventDefault(),this.$refs[t].focus()},onSizeCurrencyChange(){this.updateTradePairs({id:this.targetId,size:this.sizeCurrency,value:this.valueCurrency})},onValueCurrencyChange(){this.updateTradePairs({id:this.targetId,size:this.sizeCurrency,value:this.valueCurrency})},checkIsEnableCurrency(){return!!(Ii.includes(this.sizeCurrency)&&Ti.includes(this.valueCurrency)&&this.sizeCurrencyList.includes(this.sizeCurrency))},webSocketCallback(e){"REJECT"===e.status&&e.reason&&this.notifyStatus(Si,e.reason),this.keepQuoteData={[at.SELL]:{priceInOrderCurrency:e.sellUnitPrice,quoteId:e.sellQuoteId},[at.BUY]:{priceInOrderCurrency:e.buyUnitPrice,quoteId:e.buyQuoteId}},0===this.targetIndex&&this.changeWindowTitle()},getQuotes(e=null){this.$emit("setupWebSocket",{key:this.webSocketKey,oldPayload:e,payload:this.webSocketPayload,callback:e=>this.webSocketCallback(e)})},sendAcceptRequest(e){if(!this.isLogin)return void this.gotoLoginView();if(""===this.size&&""===this.valueOf)return void this.sendNotification({message:this.$t("otc.enter.sizeAndValue")});const t=this.keepQuoteData[e].quoteId;this.keepAcceptQuoteData[t]||(this.keepAcceptQuoteData={...this.keepAcceptQuoteData,[t]:{orderType:e,actionType:this.baseType,currencyPairs:`${this.sizeCurrency}-${this.valueCurrency}`,sizeCurrency:this.sizeCurrency,valueCurrency:this.valueCurrency,orderNumber:this.size||this.valueOf}},J.acceptOtcQuote(t).then((e=>{this.sendNotification({status:bi,...e})})).catch((e=>{[Z.INSUFFICIENT_BALANCE,qe.OTC_QUERY_FAIL,qe.OTC_ACCEPT_FAIL,qe.OTC_NO_SUPPORT].includes(e)&&this.sendNotification({status:_i,errorCode:e})})))},goToOTC(){const e=this.$router.resolve({name:"spotTradeHistory",params:{lang:this.lang}});window.open(e.href,"_blank")},changeWindowTitle(){const e=this.keepQuoteData[at.SELL],t=this.keepQuoteData[at.BUY],a=String(e.priceInOrderCurrency).slice(0,8),r=String(t.priceInOrderCurrency).slice(0,8);document.title=`${a} | ${r} ${this.sizeCurrency}-${this.valueCurrency}`},gotoLoginView(){this.$router.push({name:"login",query:{redirect:this.$route.fullPath},params:{lang:this.lang}})},getFormattedAmount(e){return this.$filters.formatNumber(e,{minDigits:0})}}},$i={class:"streaming-panel-wrap"},Bi={class:"streaming-panel"},zi={class:"top-info"},Oi={class:"coin-pair"},Ui={class:"action-wrapper size-action"},Ri={class:"info-wrap"},Ai={class:"text"},qi={key:0,class:"balance"},Wi={key:0,class:"invalid-message"},Qi={class:"action-wrapper"},Vi={class:"info-wrap"},ji={class:"text"},Yi={key:0,class:"balance"},Gi={class:"relative"},Hi={key:0,class:"invalid-message"},Ki={class:"streaming-panel-footer"};const Ji={name:"StreamingQuotes",components:{SimplePageShell:xa,StreamingNotifier:Di,StreamingPanel:Ge(Pi,[["render",function(e,l,c,d,m,p){const y=s("IconAdd"),v=s("IconDelete2"),f=s("InputWithCurrencyDropDown"),g=s("StreamingButton"),C=s("StreamingNotifier");return a(),t("div",$i,[r("div",Bi,[r("div",zi,[r("div",Oi,i(`${c.defaultTradePair.size} / ${c.defaultTradePair.value}`),1),c.isMultiplePanel?(a(),t("div",{key:1,class:"close-icon-wrap",onClick:l[1]||(l[1]=()=>c.handleClosePanel(c.targetId))},[n(v,{class:"icon-close"}
1)])):(a(),t("div",{key:0,class:"add-icon-wrap",onClick:l[0]||(l[0]=(...e)=>c.handleAddPanel&&c.handleAddPanel(...e))},[n(y,{class:"icon-add"})]))]),r("div",Ui,[r("div",Ri,[r("span",Ai,i(e.$t("t.size")),1),p.isLogin?(a(),t("span",qi,i(p.sizeBalanceText),1)):h("",!0)]),r("div",{ref:"inputSizeWrapRef",class:u(["input-wrap",{"input-invalid":p.isBaseInputInvalid}])},[n(f,{model:m.size,"onUpdate:model":l[2]||(l[2]=e=>m.size=e),radio:m.baseType,"onUpdate:radio":l[3]||(l[3]=e=>m.baseType=e),currentRef:m.currentRef,"onUpdate:currentRef":l[4]||(l[4]=e=>m.currentRef=e),selectedCurrency:m.sizeCurrency,"onUpdate:selectedCurrency":l[5]||(l[5]=e=>m.sizeCurrency=e),inputComponent:m.inputComponent,placeholder:p.baseInputPlaceholder,appliedCurrencyList:p.sizeCurrencyList,currencyAliasMap:c.currencyAliasMap,barTextSize:m.BarTextSize.BIG,decimalLimit:m.DEFAULT_AMOUNT_DECIMAL_LIMIT,isSearchShown:!1,radioValue:"size",refName:"streamingInputSize",currencyDropdownIdPrefix:"streaming_panel",currencyDropdownIdSuffix:"size",onKeydown:l[6]||(l[6]=R((e=>p.onTab(e,"inputValue")),["tab"])),onOnCurrencyChange:p.onSizeCurrencyChange},null,8,["model","radio","currentRef","selectedCurrency","inputComponent","placeholder","appliedCurrencyList","currencyAliasMap","barTextSize","decimalLimit","onOnCurrencyChange"])],2),p.baseInputInvalidMessage?(a(),t("div",Wi,i(p.baseInputInvalidMessage),1)):h("",!0)]),r("div",Qi,[r("div",Vi,[r("span",ji,i(e.$t("streamingQuote.valueOf")),1),p.isLogin?(a(),t("span",Yi,i(p.valueBalanceText),
11)):h("",!0)]),r("div",Gi,[r("div",{ref:"inputValueWrapRef",class:u(["input-wrap",{"input-invalid":p.isQuoteInputInvalid}])},[n(f,{radio:m.baseType,"onUpdate:radio":l[7]||(l[7]=e=>m.baseType=e),model:m.valueOf,"onUpdate:model":l[8]||(l[8]=e=>m.valueOf=e),currentRef:m.currentRef,"onUpdate:currentRef":l[9]||(l[9]=e=>m.currentRef=e),selectedCurrency:m.valueCurrency,"onUpdate:selectedCurrency":l[10]||(l[10]=e=>m.valueCurrency=e),inputComponent:m.inputComponent,placeholder:p.quoteInputPlaceholder,appliedCurrencyList:p.valueCurrencyList,barTextSize:m.BarTextSize.BIG,decimalLimit:m.DEFAULT_AMOUNT_DECIMAL_LIMIT,radioValue:"valueOf",refName:"streamingInputValue",currencyDropdownIdPrefix:"streaming_panel",currencyDropdownIdSuffix:"value",isFilterShown:"",onKeydown:l[11]||(l[11]=R((e=>p.onTab(e,"inputSize")),["tab"])),onOnCurrencyChange:p.onValueCurrencyChange},null,8,["radio","model","currentRef","selectedCurrency","inputComponent","placeholder","appliedCurrencyList","barTextSize","decimalLimit","onOnCurrencyChange"])],2),p.quoteInputInvalidMessage?(a(),t("div",Hi,i(p.quoteInputInvalidMessage),1)):h("",!0)]),r("div",Ki,[n(g,{text:e.$t("t.sell"),disabled:p.isSubmitDisabled,styleType:m.OrderSide.SELL,isFill:!0,quote:m.keepQuoteData[m.OrderSide.SELL],onClick:l[12]||(l[12]=e=>p.sendAcceptRequest(m.OrderSide.SELL))},null,8,["text","disabled","styleType","quote"]),n(g,{text:e.$t("t.buy"),disabled:p.isSubmitDisabled,styleType:m.OrderSide.BUY,isFill:!0,quote:m.keepQuoteData[m.OrderSide.BUY],onClick:l[13]||(l[13]=e=>p.sendAcceptRequest(m.OrderSide.BUY))},null,8,["text","disabled","styleType","quote"])])])]),p.showNotifier?(a(),o(C,{key:0,nextNotify:e.nextNotify,currentNotify:e.currentNotify,isNotifySuccess:e.isNotifySuccess,isShowNotify:e.isShowNotify},null,8,["nextNotify","currentNotify","isNotifySuccess","isShowNotify"])):h("",!0)])}],["__scopeId","data-v-a74dc1ac"]]),ContactUsText:Na,FullKycNotification:le},data:()=>({...Ni.data(),marketOriginalList:[],currencyAliasMap:{},currentSelectedTradePairs:[],targetNotify:null,webSocket:new Ye("otc")}),computed:{...A(ie,["isDefaultBrand","userConfig","lang","loginState","token"]),showNotifier(){return this.$deviceSmallerThan.lg(this.$mq)},isMultiplePanel(){return this.currentSelectedTradePairs.length>1}},async created(){await this.fetchMarkets(),this.webSocket.open(!!this.loginState&&{op:"token",args:[this.token]},{reconnecting:()=>{},connected:()=>{}}),this.handleDefaultCurrencyPair()},beforeUnmount(){clearTimeout(this.showNotifyTimeout)},unmounted(){this.webSocket.close()},methods:{...Ni.methods,...y(["updateUserConfigByKey"]),async fetchMarkets(){const e=await J.getOtcMarkets();this.marketOriginalList=e.filter((e=>Ii.includes(e.assetName))).map(this.mapMarketDictionary)},mapMarketDictionary(e){return e.alias&&e.assetName!==e.alias&&(this.currencyAliasMap[e.assetName]=e.alias),{...e,assetName:e.assetName,supportQuoteCurrencies:e.supportQuoteCurrencies,minBaseSize:e.minBaseSize,maxBaseSize:e.maxBaseSize,minQuoteSizes:e.minQuoteSizes,maxQuoteSizes:e.maxQuoteSizes}},handleAddPanel(){this.currentSelectedTradePairs=[...this.currentSelectedTradePairs,{id:Ve(),size:gi,value:"USD"}],this.saveTradePairs(this.currentSelectedTradePairs)},handleClosePanel(e){this.currentSelectedTradePairs=this.currentSelectedTradePairs.filter((t=>t.id!==e)),this.saveTradePairs(this.currentSelectedTradePairs)},handleDefaultCurrencyPair(){const e=this.userConfig[je.STREAMING_TRADE_CURRENCY_PAIRS]||[];if(this.$route.params.id1){const[e,t]=this.$route.params.id1.split("-");this.currentSelectedTradePairs=[{id:Ve(),size:e,value:t}]}else e&&e.length>0?this.currentSelectedTradePairs=e:this.currentSelectedTradePairs=[{id:Ve(),size:fi,value:"USD"}]},updateTradePairs(e){const{id:t,size:a,value:r}=e,i=this.currentSelectedTradePairs.map((e=>(e.id===t&&a&&r&&(e={...e,size:a,value:r}),e)));this.currentSelectedTradePairs=i,this.saveTradePairs(i)},saveTradePairs(e){this.updateUserConfigByKey({key:je.STREAMING_TRADE_CURRENCY_PAIRS,value:e})},handleTargetNotify(e){this.targetNotify=e},handleNotification(e){this.mixinNotify(e)},unsubscribeWebSocket({key:e,payload:t}){this.webSocket.unsubscribe(e,{op:"unsubscribe-quote",...t})},setupSubscription({key:e,oldPayload:t,payload:a,callback:r}){t&&this.unsubscribeWebSocket({key:e,payload:t}),a&&this.webSocket.subscribe(e,{op:"quote",...a},r)}}},Xi={class:"streaming-quote-wrapper"},Zi={class:"title-wrap"},es={class:"title"},ts={class:"panel-wrapper"};const as=Ge(Ji,[["render",function(e,c,u,d,m,p){const y=s("FullKycNotification"),v=s("StreamingNotifier"),f=s("StreamingPanel"),g=s("ContactUsText"),C=s("SimplePageShell");return a(),o(C,{fullWidth:!0},{default:l((()=>[n(y,{class:"kyc-notification"}),p.showNotifier?(a(),o(v,{key:0,nextNotify:e.nextNotify,currentNotify:e.currentNotify,isNotifySuccess:e.isNotifySuccess,isShowNotify:e.isShowNotify},null,8,["nextNotify","currentNotify","isNotifySuccess","isShowNotify"])):h("",!0),r("div",Xi,[r("div",Zi,[r("div",es,i(e.$t("streamingQuote.title")),1)]),r("div",ts,[(a(!0),t(x,null,L(m.currentSelectedTradePairs,((e,r)=>(a(),t("div",{key:e.id},[n(f,{marketOriginalList:m.marketOriginalList,currencyAliasMap:m.currencyAliasMap,isMultiplePanel:p.isMultiplePanel,handleAddPanel:p.handleAddPanel,handleClosePanel:p.handleClosePanel,defaultTradePair:e,targetId:e.id,targetIndex:r,updateTradePairs:p.updateTradePairs,handleTargetNotify:p.handleTargetNotify,targetNotify:m.targetNotify,totalPairs:m.currentSelectedTradePairs.length,onMixinNotify:p.handleNotification,onSetupWebSocket:p.setupSubscription,onCloseWebSocket:p.unsubscribeWebSocket},null,8,["marketOriginalList","currencyAliasMap","isMultiplePanel","handleAddPanel","handleClosePanel","defaultTradePair","targetId","targetIndex","updateTradePairs","handleTargetNotify","targetNotify","totalPairs","onMixinNotify","onSetupWebSocket","onCloseWebSocket"])])))),128)),e.isDefaultBrand?(a(),o(g,{key:0})):h("",!0)])])])),_:1})}],["__scopeId","data-v-dce4d87c"]]),rs=Object.freeze(Object.defineProperty({__proto__:null,default:as},Symbol.toStringTag,{value:"Module"}));
1export{Vt as M,mi as O,rs as S,Wt as i};
2//# sourceMappingURL=BBCZVWsC.js.map

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.