PageSourceSearch

https://swapter.io/_next/static/chunks/6660-273ceb01f2e38086.js

js swapter.io collected 2026-10-07 01:40:47 UTC 23,278 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6660],{2188:(e,l,t)=>{t.d(l,{P:()=>r});var s=t(37876),i=t(63320),n=t(297),a=t(89368);let r=e=>{let{isTimeCode:l,isEmailCode:t,timeCode:r,emailCode:o,title:d,onClose:c}=e,u=(0,a.useTranslations)("Login");return(0,s.jsxs)("div",{children:[(0,s.jsxs)("div",{className:"px-4 p-4 md:px-10 md:py-8 md:border-b border-white/[.2] flex items-center justify-between md:bg-[#D9203655]",children:[(0,s.jsx)("p",{className:" text-[#D92036] md:text-white text-[25px] font-bold md:text-xl",children:d}),(0,s.jsx)("button",{className:"flex items-center justify-center rounded-lg w-8 h-8 opacity-50",onClick:c,children:(0,s.jsx)(i.US,{width:30,height:30,color:"white"})})]}),(0,s.jsxs)("div",{className:"px-4 md:px-10 md:py-8",children:[(0,s.jsx)("p",{className:"text-white opacity-80 mb-8 text-base font-medium",children:u("complete-all-verifications")}),t?(0,s.jsx)(n.Cl,{...o}):null,l?(0,s.jsx)(n.lE,{...r}):null]})]})}},17632:(e,l,t)=>{t.d(l,{d:()=>s});let s={container:e=>({...e,":active":{borderColor:"#3CC8C8",transition:"all"},":focus":{borderColor:"#3CC8C8",outline:"#3CC8C8",transition:"all"},":hover":{borderColor:"#3CC8C8",outline:"#3CC8C8",transition:"all"},backgroundColor:"#FFFFFF14",border:1,borderColor:"rgb(103,107,110)",borderRadius:14,borderStyle:"solid",color:"#ffffff"}),control:(e,l)=>{let{isFocused:t}=l;return{...e,backgroundColor:"rgba(255,255,255,0)",border:0,borderRadius:"14px",boxShadow:t?"none":void 0,color:"#ffffff",cursor:"pointer",fontSize:18,fontWeight:500,height:56}},indicatorSeparator:e=>({...e,display:"none"}),menu:e=>({...e,backdropFilter:"blur(8px)",backgroundColor:"#FFFFFF14",border:"1px solid #FFFFFF66",borderRadius:"14px",color:"#FFF",overflow:"hidden",padding:0,zIndex:"10"}),menuList:e=>({...e,maxHeight:"200px",overflowX:"hidden",overflowY:"auto",padding:0}),option:(e,l)=>{let{isDisabled:t,isFocused:s,isSelected:i}=l;return{...e,":active":{...e[":active"],backgroundColor:i?"rgba(38, 67, 122, 0.16)":void 0},backgroundColor:i?"#3CC8C81F":s?"rgba(38, 67, 122, 0.04)":"rgba(255,255,255,0)",color:"#FFF",cursor:t?"not-allowed":"pointer",fontSize:16,fontWeight:500,padding:"8px 16px"}},singleValue:e=>({...e,color:"#ffffff",padding:"2px 2px 2px 16px"})}},37258:(e,l,t)=>{t.d(l,{D:()=>p});var s=t(37876),i=t(14232),n=t(63320),a=t(13527),r=t(50959),o=t(88376),d=t(40110),c=t(6327),u=t(94825),m=t(69241),x=t(89368);let p=e=>{let{onPrevStep:l,onSubmit:t,sendCodeToMail:p,code:h,setCode:v,loaders:w}=e,b=window.location.pathname.split("/").includes("personal"),f=(0,x.useTranslations)("Login"),[g,j]=(0,i.useState)(!1),{data:y}=(0,d.v)(),{info:C}=null!=y?y:{};return(0,i.useEffect)(()=>{p(),j(!0)},[]),(0,s.jsxs)("div",{className:"px-4 sm:px-10 py-8",children:[(0,s.jsx)(a.o,{onClick:l}),(0,s.jsxs)("div",{className:"flex justify-start flex-col items-start md:items-center  md:flex-row  mb-3",children:[(0,s.jsx)("span",{className:(0,m.A)(b?"hidden":"w-10 min-w-10 h-10 md:min-w-12 md:w-12 md:h-12 bg-white/[.16] rounded-lg flex items-center justify-center mr-6  mb-6 md:mb-0"),children:(0,s.jsx)(n.Xq,{})}),(0,s.jsx)("p",{className:"text-white font-bold text-3xl",children:f("email-verification")})]}),(0,s.jsxs)("p",{className:"text-white text-base pb-6",children:[(0,s.jsx)("span",{className:"opacity-50",children:f("enter-digit-verification-code")})," ",null==C?void 0:C.email]}),(0,s.jsxs)("div",{className:"py-8",children:[(0,s.jsxs)("div",{className:"flex items-center justify-between mb-1",children:[(0,s.jsxs)("p",{className:"text-white text-base font-medium",children:[f("email-verification")," ",f("code")]}),(null==w?void 0:w.link)?(0,s.jsx)(n.Z_,{fill:"rgba(255, 255, 255, 0.5)"}):(0,s.jsx)("p",{className:"text-white text-sm font-medium",children:f("code-sent")})]}),(0,s.jsx)(r.M,{codes:h,setCodes:v}),(0,s.jsx)(o.z,{isSendCode:g,setIsSendCode:j,onResendCode:p})]}),(0,s.jsxs)("div",{className:"flex space-x-4",children:[!b&&(0,s.jsx)(c.$,{disabled:(null==h?void 0:h.join("").length)!==6,title:f("submit"),size:"md",color:"primary",onClick:()=>{t(null==h?void 0:h.join(""))},additionalStyles:"w-full"}),(null==h?void 0:h.join("").length)!==6?(0,s.jsx)(u.z,{disabled:(null==h?void 0:h.join("").length)!==6,title:f("submit"),size:"md",color:"personal-inactive",onClick:()=>{t(null==h?void 0:h.join(""))},additionalStyles:"w-full"}):(0,s.jsx)(u.z,{title:f("submit"),size:"md",color:"personal-active",onClick:()=>{t(null==h?void 0:h.join(""))},additionalStyles:"w-full"})]})]})}},41819:(e,l,t)=>{t.d(l,{P:()=>a});var s=t(2188),i=t(76021),n=t(37258),a=function(e){return e.Initial="initial-view",e.TwoFAStep="2-fa-step-view",e.TimeCode="time-code-view",e.EmailCode="email-code-view",e}(a||{});s.P,i.C,n.D},46660:(e,l,t)=>{t.d(l,{I:()=>q});var s=t(37876),i=t(14232),n=t(63320),a=t(23171),r=t(89368),o=t(73557);let d=e=>{let{min:l,max:t,value:i,setValue:n}=e,a=(0,r.useTranslations)("General");return(0,s.jsxs)("div",{className:"px-5 sm:px-6 py-10 md:p-10 md:grid grid-cols-12 gap-10 items-start border-b border-solid border-white-20",children:[(0,s.jsx)("div",{className:"col-span-4",children:(0,s.jsx)("p",{className:"text-white text-[20px] md:text-lg mb-6 md:mb-2 font-bold",children:a("configure-your-widget")})}),(0,s.jsx)("div",{className:"col-span-8",children:(0,s.jsxs)("div",{className:"lg:flex items-end justify-start",children:[(0,s.jsxs)("div",{className:"md:mr-6",children:[(0,s.jsx)("p",{className:"text-white mb-2",children:a("width")}),(0,s.jsxs)("div",{className:"w-full md:max-w-[200px] border border-white/[.3] flex items-stretch justify-start h-14 roun
1ded-[16px] overflow-hidden",children:[(0,s.jsx)("input",{defaultValue:null!=l?l:0,value:+i,onChange:e=>{let{target:l}=e;return n(+l.value)},className:"px-2.5 w-3/4 bg-white/[.04] text-white"}),(0,s.jsx)("div",{className:" w-1/4 text-white flex items-center border-l border-turquiose/[.3] justify-center bg-turquiose/[.24]",children:(0,s.jsx)("p",{children:"px"})})]})]}),(0,s.jsxs)("div",{className:"w-full 2xl:max-w-[50%] mt-6 3xl:mt-3 3xl:pl-6",children:[(0,s.jsx)(o.A,{step:10,min:l,max:t,value:i,onChange:e=>n(e),trackStyle:{background:"linear-gradient(to right, #9544E4, #3CC8C8)",borderRadius:"8px",height:"5px"},draggableTrack:!0}),(0,s.jsxs)("div",{className:"w-full flex items-center justify-between pt-1",children:[(0,s.jsxs)("p",{className:"text-white text-sm opacity-50 uppercase",children:[l," px"]}),(0,s.jsxs)("p",{className:"text-white text-sm opacity-50 uppercase",children:[t," px"]})]})]})]})})]})};var c=t(23610),u=t(40998),m=t(17632),x=t(59819),p=t(14260);let h=e=>{var l,t,i,n,a,o;let{createWidgetHook:d}=e,h=(0,r.useTranslations)("General"),{flattenOptions:v,depositNetworks:w,depositCurrency:b,withdrawCurrency:f,withdrawalNetworks:g,isLoading:j,depositAmountController:y}=d;return(0,s.jsxs)("div",{className:"mx-5 md:mx-0 sm:px-6 py-10 md:p-10 md:grid md:grid-cols-12 gap-10 items-start border-b border-solid border-white-20",children:[(0,s.jsx)("div",{className:"col-span-4",children:(0,s.jsx)("p",{className:"text-white text-lg mb-2 font-bold",children:h("default-exchange-settings")})}),(0,s.jsxs)("div",{className:"flex flex-col gap-6 md:grid md:col-span-8",children:[(0,s.jsxs)("div",{className:"flex gap-2 items-stretch justify-start md:mb-[24px]",children:[(0,s.jsxs)("div",{className:"mr-2 max-w-[200px] w-full relative flex flex-col flex-grow",children:[(0,s.jsx)("p",{className:"text-white mb-2",children:h("coin-send")}),(0,s.jsx)("div",{className:"bg-white/[.08] border border-solid border-white/[.3] rounded-[14px] h-[58px] relative",children:(0,s.jsxs)(c.A,{options:v,selectedOption:null==b||null==(l=b.currency)?void 0:l.currency,disabledOption:null==f||null==(t=f.currency)?void 0:t.currency,loading:j,onChange:e=>b.changeController.currency(e,"deposit"),children:[(0,s.jsx)(u.K,{fullWidth:!0}),(0,s.jsx)(x.FH,{options:{disableFullName:!0,personal:!0},placeholder:h("coin-send")})]})})]})," ",(0,s.jsxs)("div",{className:"mr-2 max-w-[120px] w-full",children:[(0,s.jsx)("p",{className:"text-white mb-2",children:h("network")}),(0,s.jsx)(p.Ay,{classNamePrefix:"custom-select",isLoading:j,options:w,isClearable:!1,isSearchable:!1,name:"network-send",styles:m.d,value:null==b||null==(i=b.currency)?void 0:i.network,onChange:e=>null==b?void 0:b.changeController.network(e)})]})]}),(0,s.jsxs)("div",{className:"max-w-[200px] w-full flex flex-col",children:[(0,s.jsx)("p",{className:"text-white mb-2",children:h("default-amount")}),(0,s.jsx)("input",{...y,className:"text-white border border-white/[.3] rounded-[16px] bg-white/[.04] px-4 py-3 w-full text-[18px] flex-grow focus:outline-none",placeholder:"0.1"})]}),(0,s.jsxs)("div",{className:"flex items-stretch justify-start gap-2",children:[(0,s.jsxs)("div",{className:"mr-2 max-w-[200px] w-full relative flex flex-col flex-grow",children:[(0,s.jsx)("p",{className:"text-white mb-2",children:h("coin-receive")}),(0,s.jsx)("div",{className:"bg-white/[.08] border border-solid border-white/[.3] rounded-[14px] h-[58px] relative bg-swapterBlack",children:(0,s.jsxs)(c.A,{options:v,selectedOption:null==f||null==(n=f.currency)?void 0:n.currency,disabledOption:null==b||null==(a=b.currency)?void 0:a.currency,loading:j,onChange:e=>f.changeController.currency(e,"deposit"),children:[(0,s.jsx)(u.K,{fullWidth:!0}),(0,s.jsx)(x.FH,{options:{disableFullName:!0,personal:!0},placeholder:h("coin-receive")})]})})]}),(0,s.jsxs)("div",{className:"mr-2 max-w-[120px] w-full",children:[(0,s.jsx)("p",{className:"text-white mb-2",children:h("network")}),(0,s.jsx)(p.Ay,{classNamePrefix:"custom-select",isLoading:j,options:g,isClearable:!1,isSearchable:!1,name:"network-send",styles:m.d,value:null==f||null==(o=f.currency)?void 0:o.network,onChange:e=>null==f?void 0:f.changeController.network(e)})]})]}),(0,s.jsx)("div",{})]})]})};
1var v=t(82870);let w=e=>{var l,t,i;let{control:n}=e,a=(0,r.useTranslations)("General"),{register:o}=n;return(0,s.jsxs)("div",{className:"mx-5 md:mx-0 sm:px-6 py-10 md:p-10 md:grid grid-cols-12 gap-10 items-start border-b border-solid border-white-20",children:[(0,s.jsx)("div",{className:"col-span-4",children:(0,s.jsx)("p",{className:"text-white text-[20px] md:text-lg mb-2 font-bold",children:a("setup-widget")})}),(0,s.jsxs)("div",{className:"col-span-8",children:[(0,s.jsxs)("div",{className:"mb-6",children:[(0,s.jsx)("p",{className:"text-white mb-2",children:a("name")}),(0,s.jsxs)("div",{className:"flex flex-col",children:[(0,s.jsx)("input",{className:"bg-white/[.04] border text-white border-white/[.3] focus:outline-none px-4 py-3 max-w-[550px] w-full text-[18px] rounded-[16px]",placeholder:"John Doe",...o("name",{required:"This field is required"})}),(null==(l=n.formState.errors.name)?void 0:l.message)&&(0,s.jsx)("span",{className:"text-[#FF4F4F] text-[14px] mt-2 ml-2",children:null==(i=n.formState.errors)||null==(t=i.name)?void 0:t.message})]})]}),(0,s.jsxs)("div",{className:"mb-4",children:[(0,s.jsxs)("p",{className:"text-white text-base mb-3",children:[a("select-swap-options"),":"]}),(0,s.jsxs)("label",{className:"flex items-center justify-start relative",children:[(0,s.jsx)("input",{type:"checkbox",id:"exchange",checked:!0,readOnly:!0,className:"appearance-none w-4 h-4 bg-white rounded-[4px] checked:bg-turquiose",...o("exchange",{required:"This field is required"})}),(0,s.jsx)("span",{className:"absolute",children:(0,s.jsx)(v.mmP,{className:"text-white"})}),(0,s.jsx)("p",{className:"text-white text-base ml-2",children:a("exchange")})]})]}),(0,s.jsx)("div",{})]})]})};var b=t(41819),f=t(54761),g=t(20408),j=t(67598),y=t(57259),C=t(38669),N=t(35527),k=t(80075),S=t(72610),F=t(6327),P=t(94825),A=t(38758),T=t(54587),z=t.n(T),E=t(89099),L=t(88992);let q=()=>{var e,l;let t=(0,r.useTranslations)("General"),o=(0,E.useRouter)(),c=(0,A.q)(),[u,m]=(0,i.useState)(700),x=(()=>{var e,l;let{isLoading:t,assetOptions:s}=(0,j.v)(),[n,a]=(0,i.useState)(""),r=(0,i.useMemo)(()=>s?Array.from(null==s?void 0:s.values()):[],[s]),{initialDepositOptions:o,initialWithdrawalOptions:d,depositAmount:c,isLoading:u}=(0,y.R)({assetOptions:s}),m=(0,C.W)({assetsOptionMap:s,initials:{currency:null==o?void 0:o.asset,network:null==o?void 0:o.network,value:null==c?void 0:c.toString()}}),x=(0,C.W)({assetsOptionMap:s,initials:{currency:null==d?void 0:d.asset,network:null==d?void 0:d.network,value:void 0}});(0,i.useEffect)(()=>{var e;null==m||m.changeController.internal({currency:null==o?void 0:o.asset,network:null==o?void 0:o.network,value:null==c?void 0:c.toString()}),null==x||null==(e=x.changeController)||e.internal({currency:null==d?void 0:d.asset,network:null==d?void 0:d.network,value:void 0}),c&&a(null==c?void 0:c.toString())},[d,d]);let p=(0,g.YQ)({currency:null==m||null==(e=m.currency)?void 0:e.currency,source:"deposit"}),h=(0,g.YQ)({currency:null==x||null==(l=x.currency)?void 0:l.currency,source:"withdraw"});return{defaultDepositAmount:c,depositAmountController:(0,i.useMemo)(()=>({onChange:e=>{var l;return a(null==e||null==(l=e.target)?void 0:l.value)},value:n}),[n,a]),depositCurrency:m,depositNetworks:p,flattenOptions:r,isLoading:u&&t,withdrawCurrency:x,withdrawalNetworks:h}})(),{depositCurrency:p,withdrawCurrency:v,depositAmountController:T}=x,q=(0,L.mN)({defaultValues:{donate:!1,exchange:!0}}),{watch:I}=null!=q?q:{},O=I("name"),M=()=>{var e,l,t,s,i,n,a,r,o,d,c,m;return{...q.getValues(),depositAmount:+(null==T?void 0:T.value)||0,depositCoin:null!=(o=null==p||null==(l=p.currency)||null==(e=l.currency)?void 0:e.value)?o:"",depositNetwork:null!=(d=null==p||null==(s=p.currency)||null==(t=s.network)?void 0:t.value)?d:"",dex:!1,sellBuy:!1,theme:"light",width:u,withdrawCoin:null!=(c=null==v||null==(n=v.currency)||null==(i=n.currency)?void 0:i.value)?c:"",withdrawNetwork:null!=(m=null==v||null==(r=v.currency)||null==(a=r.network)?void 0:a.value)?m:""}},W=()=>{_();let e=M();H.mutate({payload:e})},R=(0,i.useRef)(),[D,U]=(0,i.useState)(!1);(0,i.useEffect)(()=>{var e,l,t,s,i,n,a,r,o,d,c;if(!D||!R.current)return;let u={globals:{depositAmount:null==T||null==(e=T.value)?void 0:e.toString(),depositCurrency:null==p||null==(t=p.currency)||null==(l=t.currency)?void 0:l.value,depositNetwork:null==p||null==(i=p.currency)||null==(s=i.network)?void 0:s.value,withdrawalCurrency:null==v||null==(a=v.currency)||null==(n=a.currency)?void 0:n.value,withdrawalNetwork:null==v||null==(o=v.currency)||null==(r=o.network)?void 0:r.value},tabs:{exchange:!0}};null==(c=R.current)||null==(d=c.contentWindow)||d.postMessage({payload:u,source:"swapter-exchange-widget"},"*")},[null==p?void 0:p.currency,null==v?void 0:v.currency,null==p||null==(e=p.currency)?void 0:e.network,null==v||null==(l=v.currency)?void 0:l.network,null==T?void 0:T.value,R,D]),(0,i.useEffect)(()=>{let e=e=>{var l;(null==(l=e.data)?void 0:l.source)==="swapter-exchange-widget"&&U(e.data.loaded)};return window.addEventListener("message",e),()=>{window.removeEventListener("message",e)}},[U]);let{onToggle:G,isOpen:V,onOpen:_}=(0,N.j)(),H=(0,k.M)({method:"post",onSuccess:()=>{G(!1),(0,a.P)("success","Widget created successfully"),S.q.refetchQueries("widget-all"),o.push("/pers
1onal/affiliate-tools/widget")},operation:"create",toolPath:"widget"});return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(f.h,{isOpen:V,onToggle:G,mutation:H,mutationPayload:M(),title:t("create-widget-title"),initialStep:b.P.TwoFAStep,inputLabel:t("create-widget-title"),bTitle:t("create-widget-title")}),(0,s.jsxs)("form",{className:"w-full bg-white/[.04] xl:rounded-[40px] md:border-y xl:border-x border-white/[.3]",onSubmit:q.handleSubmit(W),children:[(0,s.jsxs)("div",{className:"flex justify-between items-center p-5 md:px-10 md:pt-10 md:pb-6 border-b border-solid border-white-20",children:[(0,s.jsx)("p",{className:"text-white md:mb-4 text-[24px] md:text-3xl font-bold",children:t("create-widget-title")}),(0,s.jsx)("button",{className:"md:hidden",onClick:()=>o.back(),type:"button",children:(0,s.jsx)(n.US,{width:24,height:24})})]}),(0,s.jsx)(w,{control:q}),(0,s.jsx)(h,{createWidgetHook:x}),(0,s.jsx)(d,{value:u,setValue:m,max:1200,min:300}),(0,s.jsxs)("div",{className:"flex items-center justify-center md:p-9 relative",children:[(0,s.jsx)(z(),{src:"https://storage.googleapis.com/swapter-web-images/bg-widget-transparent.png",alt:"",width:1240,height:576,className:"w-full h-full object-cover top-0 left-0 absolute z-10 aspect-video"}),c&&(0,s.jsx)("div",{className:"z-40 overflow-x-visible scrollable-x",children:(0,s.jsx)("iframe",{scrolling:"no",ref:R,width:u,height:576,src:"/".concat(c,"/exchange-widget/preview")})})]}),(0,s.jsxs)("div",{className:"flex items-center justify-start px-4 py-8 md:p-10",children:[(null==O?void 0:O.length)?(0,s.jsx)(P.z,{title:t("save-widget-template"),size:"ml",color:"personal-active",onClick:W,type:"submit",additionalStyles:"mr-4 w-full md:w-auto"}):(0,s.jsx)(P.z,{title:t("save-widget-template"),size:"ml",color:"personal-inactive",onClick:W,type:"submit",disabled:!(null==O?void 0:O.length),additionalStyles:"mr-4 w-full md:w-auto"}),(0,s.jsx)(F.$,{title:t("cancel"),size:"ml",color:"cancel",type:"button",onPress:()=>o.back(),additionalStyles:"hidden md:flex"})]})]})]})}},54761:(e,l,t)=>{t.d(l,{h:()=>g});var s=t(37876),i=t(14232),n=t(2188),a=t(76021),r=t(37258),o=t(16896),d=t(45397),c=t(99448),u=t(41819);let m=e=>{let{isOpen:l,onToggle:t,children:m,title:x,mutation:p,requestPayload:h,resetChildForm:v,eventChannel:w,initialStep:b=u.P.Initial}=e,[f,g]=(0,i.useState)(b),[j,y]=(0,i.useState)(Array(6).fill("")),[C,N]=(0,i.useState)(Array(6).fill("")),{sendVerification:k,validateEmail:S,validateTimeCode:F,resetMutations:P}=(0,o.A)(),{data:A}=(0,c.v4)(),{security:T,info:z}=null!=A?A:{};(0,i.useEffect)(()=>{l||q()},[l]);let E=e=>l=>{switch(e){case"timeCode":return p.mutateAsync({params:{discount:null==h?void 0:h.discount,maxUsages:null==h?void 0:h.maxUsages,name:null==h?void 0:h.name,uid:null==h?void 0:h.uid},payload:{...h},security:{time:l}}).then(()=>g(u.P.TwoFAStep)).catch(e=>{var l;(null==e||null==(l=e.response)?void 0:l.headers["x-time"])==="false"&&g(u.P.TwoFAStep),console.log(e)});case"emailCode":return p.mutateAsync({params:{discount:null==h?void 0:h.discount,maxUsages:null==h?void 0:h.maxUsages,name:null==h?void 0:h.name,uid:null==h?void 0:h.uid},payload:{...h},security:{email:l}}).then(()=>g(u.P.TwoFAStep)).catch(e=>{var l;(null==e||null==(l=e.response)?void 0:l.headers["x-email"])==="false"&&g(u.P.TwoFAStep),console.log(e)})}},L=e=>()=>g(e),q=()=>{g(b||u.P.Initial),N(Array(6).fill("")),y(Array(6).fill("")),P(),"function"==typeof v&&v(),p.reset()},I=e=>{t(e),q()};return(0,i.useEffect)(()=>{let e=null==w?void 0:w.subscribe(e=>{"step-change"===e.type&&g(e.payload.step)});return()=>{e&&(null==w||w.unsubscribe(e))}},[g]),(0,s.jsx)(d.IG,{isOpen:l,setIsOpen:I,children:(()=>{switch(f){case u.P.Initial:return m;case u.P.TwoFAStep:var e,l,t,i;return(0,s.jsx)(n.P,{title:x,onClose:()=>I(!1),onChangeStep:L(u.P.Initial),isSubmitDisabled:(()=>{var e,l,t,s;return null!=p&&null!=(l=p.data)&&null!=(e=l.securityTypes)&&!!e.emailCode&&!S.isSuccess||!!((null==p||null==(s=p.data)||null==(t=s.securityTypes)?void 0:t.timeCode)&&!F.isSuccess)})(),isEmailCode:!!(null==T?void 0:T.email),isTimeCode:!!(null==T?void 0:T.time),timeCode:{isPassed:p.isSuccess||(null==(l=p.error)||null==(e=l.response)?void 0:e.headers["x-time"])==="false",onStepChange:L(u.P.TimeCode)},emailCode:{isPassed:p.isSuccess||(null==(i=p.error)||null==(t=i.response)?void 0:t.headers["x-email"])==="false",onStepChange:L(u.P.EmailCode)}});case u.P.TimeCode:return(0,s.jsx)(a.C,{onPrevStep:L(u.P.TwoFAStep),onSubmit:E("timeCode"),code:C,setCode:N});case u.P.EmailCode:return(0,s.jsx)(r.D,{onPrevStep:L(u.P.TwoFAStep),sendCodeToMail:()=>k.mutate(),onSubmit:E("emailCode"),email:(null==z?void 0:z.email)||"",loaders:{link:k.isLoading,validation:S.isLoading},code:j,setCode:y})}})()})};var x=t(63320);let p=e=>{let{onClose:l,children:t}=e;return(0,s.jsxs)("div",{className:"px-5 sm:px-5 md:px-10 md:py-6 flex items-center justify-between md:border-b border-solid border-white-20",children:[(0,s.jsx)("p",{className:"text-white text-xl font-bold",children:t}),(0,s.jsx)("button",{className:"flex items-center justify-center rounded-lg  w-8 h-8 opacity-50",onClick:l,children:(0,s.jsx)(x.US,{width:30,height:30,color:"white"})})]})};var h=t(17925),v=t(94825),w=t(69241),b=t(88992),f=t(82107);let g=e=>{var l,t,i,n,a;let{mutation:r}=e,{mutate:o,isLoading:d}=r||{},c=(0,h.n)(),x=(0,f.useTranslations)("General"),g=null==e?void 0:e.title,{register:j,watch:y,reset:C}=(0,b.mN)(),N=y(),k=async()=>{o({params:{...e.mutationPayload,name:N.name}}),c.emit({payload:{step:u.P.TwoFAStep},type:"step-change"})};return(0,s.jsx)(m,{requestPayload:null!=(n=null==e?void 0:e.mutationPayload)?n:N,eventChannel:c,resetChildForm:()=>C(),...e,children:(0,s.jsxs)("div",{children:[(0,s.jsx)(p,{onClose:()=>e.onToggle(!1),children:g}),(0,s.jsxs)("div",{className:"pt-8 pb-10 px-5 sm:px-5 md:px-10",children:[(0,s.jsxs)("div",{children:[(0,s.jsx)("p",{className:"text-white mb-2 text-base font-medium",children:null!=(a=null==e?void 0:e.inputLabel)?a:x("API-key-name")}),(0,s.jsx)("input",{type:"text",placeholder:x(e.placeholder),className:(0,w.A)("bg-white px-4 py-3 w-full text-[18px] rounded-[14px] text-black border border-white/[.3] focus:outline-none"),...j("name")}
1)]}),(null==(l=N.name)?void 0:l.length)?(0,s.jsx)(v.z,{title:g,size:"lg",type:"submit",color:"personal-active",additionalStyles:"w-full mt-10",loading:d,disabled:!(null==(i=N.name)?void 0:i.length),onClick:k}):(0,s.jsx)(v.z,{title:g,size:"lg",type:"submit",color:"primary",additionalStyles:"w-full mt-10",loading:d,disabled:!(null==(t=N.name)?void 0:t.length),onClick:k})]})]})})}},76021:(e,l,t)=>{t.d(l,{C:()=>u});var s=t(37876);t(14232);var i=t(63320),n=t(13527),a=t(50959),r=t(6327),o=t(94825),d=t(69241),c=t(89368);let u=e=>{let{onPrevStep:l,onSubmit:t,code:u,setCode:m}=e,x=(0,c.useTranslations)("Login"),p=window.location.pathname.split("/").includes("personal");return(0,s.jsxs)("div",{className:"px-4 sm:px-10 py-8",children:[(0,s.jsx)(n.o,{onClick:l}),(0,s.jsxs)("div",{className:"flex justify-start flex-col items-start md:items-center  md:flex-row  mb-3",children:[(0,s.jsx)("span",{className:(0,d.A)(p?"hidden":"w-10 min-w-10 h-10 md:min-w-12 md:w-12 md:h-12 bg-white/[.16] rounded-lg flex items-center justify-center mr-6  mb-6 md:mb-0"),children:(0,s.jsx)(i.Xq,{})}),(0,s.jsx)("p",{className:"text-white font-bold text-3xl",children:x("authentication-app")})]}),(0,s.jsx)("p",{className:"text-white text-base pb-6",children:(0,s.jsx)("span",{className:"opacity-50",children:x("enter-verification-code-auth-app")})}),(0,s.jsxs)("div",{className:"py-8",children:[(0,s.jsx)("p",{className:"text-white text-base font-medium",children:x("2FA-password")}),(0,s.jsx)(a.M,{codes:u,setCodes:m})]}),!p&&(0,s.jsx)(r.$,{disabled:(null==u?void 0:u.join("").length)!==6,title:x("submit"),size:"md",color:"primary",onPress:()=>{t(null==u?void 0:u.join(""))},additionalStyles:"w-full"}),(null==u?void 0:u.join("").length)!==6?(0,s.jsx)(o.z,{disabled:(null==u?void 0:u.join("").length)!==6,title:x("submit"),size:"md",color:"primary",onPress:()=>{t(null==u?void 0:u.join(""))},additionalStyles:"w-full"}):(0,s.jsx)(o.z,{title:x("submit"),size:"md",color:"personal-active",onClick:()=>{t(null==u?void 0:u.join(""))},additionalStyles:"w-full"})]})}}}]);

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.