/**
 * Minified by jsDelivr using Terser v5.39.0.
 * Original file: /npm/@particle-network/auth@1.3.1/lib/index.js
 *
 * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files
 */
"use strict";var name,version,files,type,main,module2,types,license,publishConfig,dependencies,devDependencies,scripts,gitHead,package_default,__create=Object.create,__defProp=Object.defineProperty,__getOwnPropDesc=Object.getOwnPropertyDescriptor,__getOwnPropNames=Object.getOwnPropertyNames,__getOwnPropSymbols=Object.getOwnPropertySymbols,__getProtoOf=Object.getPrototypeOf,__hasOwnProp=Object.prototype.hasOwnProperty,__propIsEnum=Object.prototype.propertyIsEnumerable,__defNormalProp=(e,t,n)=>t in e?__defProp(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,__spreadValues=(e,t)=>{for(var n in t||(t={}))__hasOwnProp.call(t,n)&&__defNormalProp(e,n,t[n]);if(__getOwnPropSymbols)for(var n of __getOwnPropSymbols(t))__propIsEnum.call(t,n)&&__defNormalProp(e,n,t[n]);return e},__objRest=(e,t)=>{var n={};for(var i in e)__hasOwnProp.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(null!=e&&__getOwnPropSymbols)for(var i of __getOwnPropSymbols(e))t.indexOf(i)<0&&__propIsEnum.call(e,i)&&(n[i]=e[i]);return n},__esm=(e,t)=>function(){return e&&(t=(0,e[__getOwnPropNames(e)[0]])(e=0)),t},__export=(e,t)=>{for(var n in t)__defProp(e,n,{get:t[n],enumerable:!0})},__copyProps=(e,t,n,i)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let r of __getOwnPropNames(t))__hasOwnProp.call(e,r)||r===n||__defProp(e,r,{get:()=>t[r],enumerable:!(i=__getOwnPropDesc(t,r))||i.enumerable});return e},__toESM=(e,t,n)=>(n=null!=e?__create(__getProtoOf(e)):{},__copyProps(!t&&e&&e.__esModule?n:__defProp(n,"default",{value:e,enumerable:!0}),e)),__toCommonJS=e=>__copyProps(__defProp({},"__esModule",{value:!0}),e),__accessCheck=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)},__privateGet=(e,t,n)=>(__accessCheck(e,t,"read from private field"),n?n.call(e):t.get(e)),__privateAdd=(e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)},__privateSet=(e,t,n,i)=>(__accessCheck(e,t,"write to private field"),i?i.call(e,n):t.set(e,n),n),__async=(e,t,n)=>new Promise(((i,r)=>{var o=e=>{try{s(n.next(e))}catch(e){r(e)}},a=e=>{try{s(n.throw(e))}catch(e){r(e)}},s=e=>e.done?i(e.value):Promise.resolve(e.value).then(o,a);s((n=n.apply(e,t)).next())})),package_exports={};__export(package_exports,{default:()=>package_default,dependencies:()=>dependencies,devDependencies:()=>devDependencies,files:()=>files,gitHead:()=>gitHead,license:()=>license,main:()=>main,module:()=>module2,name:()=>name,publishConfig:()=>publishConfig,scripts:()=>scripts,type:()=>type,types:()=>types,version:()=>version});var init_package=__esm({"package.json"(){package_default={name:name="@particle-network/auth",version:version="1.3.1",files:files=["lib","es","LICENSE"],type:type="module",main:main="lib/index.js",module:module2="es/index.js",types:types="lib/types/index.d.ts",license:license="Apache-2.0",publishConfig:publishConfig={access:"public"},dependencies:dependencies={"@particle-network/analytics":"^1.0.1","@particle-network/chains":"*","@particle-network/crypto":"^1.0.1",buffer:"^6.0.3",draggabilly:"^3.0.0"},devDependencies:devDependencies={"@metamask/eth-sig-util":"^5.0.2","@types/draggabilly":"^2.1.3","ts-loader":"^9.3.1","webpack-cli":"^4.10.0"},scripts:scripts={clean:"shx rm -rf lib/* && shx rm -rf es/*",package:'shx echo \'{ "type": "commonjs" }\' > lib/package.json',build:"yarn clean && node ./esBuild.js && tsc --emitDeclarationOnly -p tsconfig.json && yarn package","dev:lib":'cross-env NODE_ENV=development concurrently "tsc -w" "node ./esBuild.js"',"build:min.js":"webpack",version:"yarn build"},gitHead:gitHead="cc999e430ebfb1dd821783f7cf099ddd51f3495a"}}}),src_exports={};__export(src_exports,{Auth:()=>Auth,AuthError:()=>AuthError,AuthTypes:()=>AuthTypes,ParticleNetwork:()=>ParticleNetwork,SettingOption:()=>SettingOption,WalletEntryPosition:()=>WalletEntryPosition,addHexPrefix:()=>addHexPrefix,apiUrl:()=>apiUrl,authUrl:()=>authUrl,bufferToHex:()=>bufferToHex,buyUrl:()=>buyUrl,getParticleEnv:()=>getParticleEnv,intToHex:()=>intToHex,isHexPrefixed:()=>isHexPrefixed,isHexString:()=>isHexString,isHttpUrl:()=>isHttpUrl,isNullish:()=>isNullish,rpcUrl:()=>rpcUrl,stripHexPrefix:()=>stripHexPrefix,toBase58Address:()=>toBase58Address,toHexAddress:()=>toHexAddress,walletUrl:()=>walletUrl}),module.exports=__toCommonJS(src_exports);var import_analytics3=require("@particle-network/analytics"),import_chains2=require("@particle-network/chains"),import_analytics2=require("@particle-network/analytics"),import_chains=require("@particle-network/chains"),import_crypto3=require("@particle-network/crypto"),import_buffer3=require("buffer"),import_events=require("events"),erc4337Option=!1,controller={languageCode:"en",fiatCoin:"USD",get erc4337(){return erc4337Option},set erc4337(e){erc4337Option=e}},en={title:"Approve Pop-up",content_sign:"Click Continue to complete the signature or transaction",content_login:"Click Continue to complete creating or connecting wallet"},ja={title:"承認ポップアップ",content_sign:"[続行] をクリックして、署名またはトランザクションを完了します",content_login:"[続行] をクリックして、ウォレットの作成または接続を完了します"},ko={title:"팝업 승인",content_sign:"서명 또는 트랜잭션을 완료하려면 계속을 클릭하십시오.",content_login:"계속을 클릭하여 지갑 생성 또는 연결을 완료합니다."},zh_CN={title:"批准弹出窗口",content_sign:"点击继续完成签名或交易",content_login:"点击继续完成创建或连接钱包"},zh_HK={title:"批准彈出窗口",content_sign:"點擊繼續完成簽名或交易",content_login:"點擊繼續完成創建或連接錢包"};function locale(){const e=controller.languageCode;return e.startsWith("en")?en:e.startsWith("ja")?ja:e.startsWith("ko")?ko:"zh_CN"===e||"zh-CN"===e||"zh"===e?zh_CN:"zh_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guaWTY1W1kj4vkVDkBOa4KbPk+dLnCETQDxG0f09Z+MgF1AkxVD7hH0B1xtNafkYIuTPd7JIPqVWtGrPQoYhbNUKYXMCUXYa80EoxVB/LLkBSBYs+Oquh5m6tTGg8UI8IUPmkf1rQuiYO+hsQYsxm5rKjH8vsMnZbjMmqial5BpBZcnN2/6JIIyDC1fc3VLOv8zyi11EByq741oKWxXHgj5SQyqQwqGI/bbHiDzpGPVMdOai/qSFXAcoGppaaixTdlOouXbd30hdHhGTiQ0cNKDvPn+YeqozoI+9QkLmtqPi7AAABj0lEQVTHR4A0WJmDACWjhsQPqUVSZ0AUdKcYIResa6rpPhowJad1jF5/mEWNoq3tWkrpPSAC74GMZ+Zj1Vtz8ZnqwHyMVm+2dFKkPSIlP6O0er3cEzpaOI4ZoEnBWtRpESOR60XgLkpI4ksIFa3pHMw8FzCPRoAoMAgRD9s85JlbDx/bf3HhmAOaBHZWvz1s9t9ICW4HSfzTFTmAmQRqjNAoG5jjCVAclO0PfzweMz+1bn+p/2jZqPX54waofLHfzmkv0OlE1km9VgQpzql7mgYmO9d4Ex1jCZAIMkgpeT6msz+ybldhxvfVHUtgjzug8s2uAxVq53WcRikuFAVcCODEdB8r+d0jFyBlqY0C+yjFnwHd25GGSdvW/X/553+yrf7zc9tqRQjfo6AXgmApBXQTSifTVF4EjYKSzyjw51jU8Na/N1ayb5f8m7/+Zgwd68menU8N8cihaqITa+JUqKaE1lBCqwFSQ0VUg/0usfcQJehkf4qUdhJCDtG40ElBO/NN1Yeu20Gkr9P5O77+FxTFLrSBkpzzAAAAAElFTkSuQmCC",approvePopupContentHtml=e=>`\n    <div class="particle-pam-left">\n      <div class="particle-pam-wrap">\n        <div class="particle-pam-img">\n          <img src='${logoBase64_default}' alt="" />\n        </div>\n        <div class="particle-pam-content">\n          <div class="particle-pam-title">${locale().title}</div>\n          <div class="particle-pam-text">${e}</div>\n        </div>\n      </div>\n    </div>\n    <div class="particle-pam-right parm-continue-btn">Continue</div>\n`,style="\n.particle-approve-popup {\n  position: fixed;\n  z-index: 999999;\n  display: -webkit-box;\n  display: -ms-flexbox;\n  display: flex;\n  border-radius: 6px;\n  padding: 0px 18px;\n  -webkit-box-sizing: border-box;\n          box-sizing: border-box;\n  -webkit-box-align: center;\n      -ms-flex-align: center;\n          align-items: center;\n  background: #fff;\n  -webkit-box-shadow: 4px 4px 20px 1px rgba(180, 180, 180, 0.6);\n          box-shadow: 4px 4px 20px 1px rgba(180, 180, 180, 0.6);\n  top: 30px;\n  -webkit-transition: all 0.3s;\n  transition: all 0.3s;\n  right: -600px;\n  width: 379px;\n  height: 78px;\n  padding-right: 0;\n}\n@media screen and (max-width: 600px) {\n  .particle-approve-popup {\n    max-width: 90%;\n    left: 50%;\n    -webkit-transform: translateX(-50%);\n            transform: translateX(-50%);\n    padding: 0px 12px;\n    right: 0;\n    top: -100px;\n  }\n}\n.particle-approve-popup.particle-approve-popup-show {\n  right: 30px;\n}\n@media screen and (max-width: 600px) {\n  .particle-approve-popup.particle-approve-popup-show {\n    right: 0;\n    top: 30px;\n  }\n}\n.particle-approve-popup .particle-pam-left {\n  position: relative;\n  padding-right: 20px;\n  height: 100%;\n  display: -webkit-box;\n  display: -ms-flexbox;\n  display: flex;\n  flex:1;\n}\n@media screen and (max-width: 600px) {\n  .particle-approve-popup .particle-pam-left {\n    padding-right: 10px;\n  }\n}\n.particle-approve-popup .particle-pam-left:after {\n  content: '';\n  position: absolute;\n  width: 1px;\n  border-left: 1px solid rgba(0, 0, 0, 0.1);\n  right: 0px;\n  top: 0;\n  height: 100%;\n}\n.particle-approve-popup .particle-pam-left .particle-pam-wrap {\n  display: -webkit-box;\n  display: -ms-flexbox;\n  display: flex;\n  -webkit-box-align: center;\n      -ms-flex-align: center;\n          align-items: center;\n}\n.particle-approve-popup .particle-pam-left .particle-pam-wrap .particle-pam-img {\n  display: -webkit-box;\n  display: -ms-flexbox;\n  display: flex;\n  -webkit-box-align: center;\n      -ms-flex-align: center;\n          align-items: center;\n  width: 42px;\n  height: 42px;\n  min-width: 42px;\n  margin-right: 10px;\n  border-radius: 42px;\n  position: relative;\n  overflow: hidden;\n}\n.particle-approve-popup .particle-pam-left .particle-pam-wrap .particle-pam-img img {\n  width: 100%;\n  height: 100%;\n}\n.particle-approve-popup .particle-pam-left .particle-pam-wrap .particle-pam-content {\n  display: -webkit-box;\n  display: -ms-flexbox;\n  display: flex;\n  -webkit-box-orient: vertical;\n  -webkit-box-direction: normal;\n      -ms-flex-direction: column;\n          flex-direction: column;\n  -webkit-box-pack: center;\n      -ms-flex-pack: center;\n          justify-content: center;\n}\n.particle-approve-popup .particle-pam-left .particle-pam-wrap .particle-pam-content .particle-pam-title {\n  font-weight: bold;\n  font-size: 17px;\n  color: #000;\n}\n.particle-approve-popup .particle-pam-left .particle-pam-wrap .particle-pam-content .particle-pam-text {\n  font-size: 12px;\n  color: #666;\n  opacity: 0.8;\n  line-height: 12px;\n}\n.particle-approve-popup .particle-pam-right {\n  position: relative;\n  cursor: pointer;\n  font-size: 14px;\n  color: #2d6af6;\n  font-weight: bold;\n  margin-left: 20px;\n  height: 100%;\n  white-space: nowrap;\n  overflow: hidden;\n  text-overflow: ellipsis;\n  display: -webkit-box;\n  min-width: 88px;\n  padding: 0 10px;\n  margin: 0;\n  display: -ms-flexbox;\n  display: flex;\n  justify-content: center;\n  -webkit-box-align: center;\n      -ms-flex-align: center;\n          align-items: center;\n}\n.particle-approve-popup .particle-pam-right:hover {\n  color: #2d6af6;\n  font-weight: bold;\n}\n",approvePopupRenderStyle=()=>{const e="particle-approve-popup-style",t=document.querySelector("."+e);t&&t.remove();const n=document.createElement("style");n.classList.add(e),n.innerHTML=style,document.head.appendChild(n)},approvePopupRender=(e,t)=>{approvePopupRenderStyle();const n="particle-approve-popup",i=document.querySelector("."+n);i&&i.remove();const r=document.createElement("div");r.classList.add(n),r.innerHTML=approvePopupContentHtml(locale()[`content_${t}`]),document.body.appendChild(r),setTimeout((()=>{r.classList.add("particle-approve-popup-show")}));const o=document.querySelector(".parm-continue-btn");o&&o.addEventListener("click",(t=>{t.stopPropagation(),r.classList.remove("particle-approve-popup-show"),e&&e()}))},import_uuid=require("uuid"),HTTP_REGEX="^https?:";function getUrlProtocol(e){const t=e.match(new RegExp(/^\w+:/,"gi"));if(t&&t.length)return t[0]}function matchRegexProtocol(e,t){const n=getUrlProtocol(e);return void 0!==n&&new RegExp(t).test(n)}function isHttpUrl(e){return matchRegexProtocol(e,HTTP_REGEX)}function isNullish(e){return null==e}function getParticleEnv(){return"undefined"==typeof window||"staging"!==window.__PARTICLE_ENVIRONMENT__&&"development"!==window.__PARTICLE_ENVIRONMENT__?"production":window.__PARTICLE_ENVIRONMENT__}function isSafariOrIOS(){const e=navigator.userAgent;return/Version\/([0-9\\._]+).*Mobile.*Safari.*/.test(e)||/Version\/([0-9\\._]+).*Safari/.test(e)||/iP(hone|od|ad)/.test(e)}var isBraveBrowser=()=>"undefined"!=typeof window&&navigator.brave,isFireFox=()=>"undefined"!=typeof window&&/Firefox\/([0-9.]+)(?:\s|$)/.test(navigator.userAgent),isChrome=()=>"undefined"!=typeof window&&/(?!Chrom.*OPR)Chrom(?:e|ium)\/([0-9\\.]+)(:?\s|$)/.test(navigator.userAgent),isBlockingThirdpartyCookiesBrowser=e=>isSafariOrIOS()||isBraveBrowser()||isFireFox()||isChrome()&&!isBraveBrowser()&&!e;function getDeviceId(){if("undefined"==typeof window)return(0,import_uuid.v4)();{const e="pn_device_id";let t=localStorage.getItem(e);return t||(t=(0,import_uuid.v4)(),localStorage.setItem(e,t)),t}}function getVersion(){return`web_${(init_package(),__toCommonJS(package_exports)).version}`}function popupWindow(e,t,n,i){const r=screen.width/2-n/2,o=screen.height/2-i/2;return open(e,t,"toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, copyhistory=no, width="+n+", height="+i+", top="+o+", left="+r)}var import_buffer=require("buffer"),import_crypto_js=__toESM(require("crypto-js"),1),ALPHABET="123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz",ALPHABET_MAP=ALPHABET.split("").reduce(((e,t,n)=>(e[t]=n,e)),{}),BASE=58,encode58=e=>{if(0===e.length)return"";const t=[0];for(let n=0;n<e.length;n++){for(let e=0;e<t.length;e++)t[e]<<=8;t[0]+=e[n];let i=0;for(let e=0;e<t.length;++e)t[e]+=i,i=t[e]/BASE|0,t[e]%=BASE;for(;i;)t.push(i%BASE),i=i/BASE|0}for(let n=0;0===e[n]&&n<e.length-1;n++)t.push(0);return[...t].reverse().map((e=>ALPHABET[e])).join("")},decode58=e=>{if(0===e.length)return[];const t=[0];for(let n=0;n<e.length;n++){const i=e[n];if(!(i in ALPHABET_MAP))throw new Error("Non-base58 character");for(let e=0;e<t.length;e++)t[e]*=BASE;t[0]+=ALPHABET_MAP[i];let r=0;for(let e=0;e<t.length;++e)t[e]+=r,r=t[e]>>8,t[e]&=255;for(;r;)t.push(255&r),r>>=8}for(let n=0;"1"===e[n]&&n<e.length-1;n++)t.push(0);return t.reverse()},sha256Hex=e=>import_crypto_js.default.enc.Hex.stringify(import_crypto_js.default.SHA256(import_crypto_js.default.enc.Hex.parse(e))),toBase58Address=e=>{const t=`41${e.substring(2)}`,n=sha256Hex(sha256Hex(t)).substring(0,8),i=import_buffer.Buffer.from(t+n,"hex");return encode58(i)},toHexAddress=e=>{if(e.length<=4)throw new Error("Invalid address provided");let t=import_buffer.Buffer.from(decode58(e)).toString("hex");const n=t.substring(t.length-8,t.length);t=t.substring(0,t.length-8);if(`${n}`==`${sha256Hex(sha256Hex(t)).substring(0,8)}`)return`0x${t.substring(2)}`;throw new Error("Invalid address provided")},authUrl=()=>{const e=getParticleEnv();if("undefined"!=typeof window&&window.__PARTICLE_AUTH_LOCALHOST__&&"string"==typeof window.__PARTICLE_AUTH_LOCALHOST__&&window.__PARTICLE_AUTH_LOCALHOST__.includes("localhost"))return window.__PARTICLE_AUTH_LOCALHOST__;switch(e){case"production":return"https://auth.particle.network";case"staging":return"https://auth-staging.particle.network";case"development":return"https://auth-debug.particle.network"}},apiUrl=()=>"development"===getParticleEnv()?"https://api-debug.particle.network":"https://api.particle.network",rpcUrl=()=>"development"===getParticleEnv()?"https://rpc-debug.particle.network":"https://rpc.particle.network",walletUrl=()=>{switch(getParticleEnv()){case"production":return"https://wallet.particle.network";case"staging":return"https://wallet-staging.particle.network";case"development":return"https://wallet-debug.particle.network"}},buyUrl=()=>{switch(getParticleEnv()){case"production":return"https://ramp.particle.network";case"staging":return"https://ramp-staging.particle.network";case"development":return"https://ramp-debug.particle.network"}},import_crypto2=require("@particle-network/crypto"),import_buffer2=require("buffer"),AuthError=class{constructor(e,t){this.code=e,this.message=t,this.code=e,this.message=t}static userCancelOperation(){return new AuthError(4011,"The user cancel the operation")}static unauthorized(){return new AuthError(4100,"The requested method and/or account has not been authorized by the user")}static unsupportedMethod(){return new AuthError(4200,"The Provider does not support the requested method")}static unsupportedChain(){return new AuthError(4201,"The Provider does not support the chain")}static paramsError(){return new AuthError(8002,"Param error, see doc for more info")}static notLogin(){return new AuthError(8005,"User not login")}static walletNotCreated(){return new AuthError(8006,"Wallet not created")}static decrypt(e){return new AuthError(8007,"decrypt error: "+e)}},AuthTypes=["email","phone","facebook","google","apple","discord","github","twitch","twitter","microsoft","linkedin","jwt"],SettingOption=(e=>(e[e.None=0]="None",e[e.Once=1]="Once",e[e.Always=2]="Always",e[e.Force=3]="Force",e))(SettingOption||{});function getWalletUrl(e,t){var n,i,r,o,a;if(!e.isLogin())throw AuthError.notLogin();if(!e.walletExist())throw AuthError.walletNotCreated();const{projectId:s,clientKey:l,appId:c,chainName:p,chainId:d,securityAccount:u}=e.config;let h=(null==(i=null==(n=e.config.wallet)?void 0:n.customStyle)?void 0:i.supportChains)||(null==(r=e.config.wallet)?void 0:r.supportChains);h&&e.config.chainId&&e.config.chainName&&(h.find((t=>{var n;return t.id===e.config.chainId&&t.name.toLowerCase()===(null==(n=e.config.chainName)?void 0:n.toLowerCase())}))||h.unshift({id:e.config.chainId,name:e.config.chainName})),h=null==h?void 0:h.map((e=>{const{id:t,name:n}=e;return{id:t,name:n}}));const f=null==(o=e.config.wallet)?void 0:o.customStyle;f&&(f.supportChains=h,f.fiatCoin||(f.fiatCoin=controller.fiatCoin));const g={projectId:s,clientKey:l,appId:c,chainName:p,chainId:d,securityAccount:u,authUserInfo:e.getUserInfo(),authType:e.getAuthType(),authSDKVersion:null==(a=window.particle)?void 0:a.version,supportChains:h},m=import_crypto2.urlCrypto.encryptUrlParam(g);let w=`${walletUrl()}/?params=${m}&theme=${getWalletUIMode(e)}&language=${controller.languageCode}`;f&&(w+=`&customStyle=${encodeURIComponent(import_buffer2.Buffer.from(JSON.stringify(f)).toString("base64"))}`);const{uiMode:y,modalBorderRadius:v}=e.getAuthTheme();return w+=`&authTheme=${encodeURIComponent(import_buffer2.Buffer.from(JSON.stringify({uiMode:y,modalBorderRadius:v})).toString("base64"))}`,t&&t.topMenuType&&(w+=`&topMenuType=${t.topMenuType}`),controller.erc4337&&(w+=`&erc4337=${encodeURIComponent(JSON.stringify(controller.erc4337))}`),w}function getBuyUrl(e,t){var n,i,r;let o=`${buyUrl()}/?language=${controller.languageCode}&theme=${getWalletUIMode(e)}`;const a=null==(n=e.config.wallet)?void 0:n.customStyle;if(a){const{light:e,dark:t}=a;o+=`&customStyle=${encodeURIComponent(import_buffer2.Buffer.from(JSON.stringify({light:e,dark:t})).toString("base64"))}`,a.fiatCoin||(a.fiatCoin=controller.fiatCoin)}if(e.isLogin()&&e.walletExist())t?(t.walletAddress||(t.walletAddress=null==(i=e.getWallet())?void 0:i.public_address),t.network||(t.network=e.config.chainName)):t={walletAddress:null==(r=e.getWallet())?void 0:r.public_address,network:e.config.chainName};else if(!t||!t.network||!t.walletAddress)throw new Error("network or walletAddress not found");return t&&Object.keys(t).forEach((e=>{const n=t[e];n&&(o+=`&${e}=${encodeURIComponent(n)}`)})),o}function getWalletUIMode(e){var t,n,i;let r=e.getThemeType();return(null==(t=e.config.wallet)?void 0:t.uiMode)&&(r="auto"===(null==(n=e.config.wallet)?void 0:n.uiMode)?window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light":null==(i=e.config.wallet)?void 0:i.uiMode),r}var draggie,html='\n  <button class="particle-pwe-btn">\n    <img class="particle-pwe-img particle-pwe-wallet-icon" src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNkYAAAAAYAAjCB0C8AAAAASUVORK5CYII=" alt="" />\n    <img class="particle-pwe-img particle-pwe-down-arrow particle-pwe-down-arrow-hide" src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNkYAAAAAYAAjCB0C8AAAAASUVORK5CYII=" alt="" />\n  </button>\n  <div class="particle-pwe-iframe-content">\n  </div>\n',walletEntryRender=()=>{const e="particle-wallet-entry-container",t=document.querySelector("."+e);t&&t.remove();const n=document.createElement("div");n.classList.add(e),n.innerHTML=html,document.body.appendChild(n)},html_default=walletEntryRender,walletIconDarkBase64="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHgAAAB4CAYAAAA5ZDbSAAAAAXNSR0IArs4c6QAAIABJREFUeF7dfQlwXdWZ5neenvanXbKNWWRWIxkIiwgTQmwSSIPorsmiOEhqZEjiHjuTiUUcsqjLnqbHrjipqXhipqobd1HdiQWWXY4gSXfaIsGAFDLNopiwWLLxIj0veJFkWct72t67Z+o/9913t3OX9yQZ05dyCVt3Oef+5/+/71/Ofxn+kxxvPHz2E/EgX8bjWAaGag4s5GD5Cud5jLE8hSMfDEWKmC8bUcAjjLFoXFF/KmBnAXZAAT8AKAdq2xa++5/h1bCP4yTerj+9JM6U+znY5xSghoNdT/Pg4g9L/NT+rv4EGFThIvFTfp52feK8w5yx1xWOfZkBtu+h58pOftze18dCwPtXnq5AULkfjN2nKPgcY+xqRYiNhKb9VIXIxX+q8My/N5+nXWc8X71Ofl7i/MOcYR8Utm86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ow4SHlj9eshAngcXFzbsqf12a89j0XuS6/ndaPWwOJL2LZkb9PRT499AwjmEuJcIjhd5qiqPujgU6qoJb8LiBtLLm6cNO74U/PWzvSPKhrNP2PCwMkX+FrH7lkE7lxAnOtl4QR4ZpR1S54mGDlJicw8FgHfLRFsBgefRcRnrnmsbddoNqZqbGPSwKqJbM7vuQCBZgPAbAKY7QLMIILJ4MAU708XcAoANZex9pB3LJhLMOzVXwnA88Q9LuHbCLi1RO7Wq3pmvD7WjKka7/8BbY+V/aWsSwsAAAAASUVORK5CYII=",style2="\n.particle-wallet-entry-container .particle-pwe-btn {\n  background: none;\n  border: none;\n  cursor: pointer;\n  height: 60px;\n  margin: 0;\n  outline: none;\n  padding: 0;\n  position: fixed;\n  width: 60px;\n  -webkit-box-shadow: 2px 2px 10px 3px rgba(0, 0, 0, 0.1);\n  box-shadow: 2px 2px 10px 3px rgba(0, 0, 0, 0.1);\n  border-radius: 60px;\n}\n.particle-wallet-entry-container .particle-pwe-btn:not(.is-dragging) {\n  -webkit-transition: all 0.2s;\n  transition: all 0.2s;\n}\n.particle-wallet-entry-container .particle-pwe-btn > img {\n  height: 100%;\n  width: 100%;\n}\n.particle-wallet-entry-container .particle-pwe-btn .particle-pwe-wallet-icon {\n  display: block;\n}\n.particle-wallet-entry-container .particle-pwe-btn .particle-pwe-wallet-icon:not(.particle-pwe-wallet-icon-hide) {\n  -webkit-animation: particle-pwe-wallet-icon-show 0.3s ease-in-out;\n          animation: particle-pwe-wallet-icon-show 0.3s ease-in-out;\n}\n@-webkit-keyframes particle-pwe-wallet-icon-show {\n  0% {\n    -webkit-transform: scale(0.6);\n            transform: scale(0.6);\n  }\n  100% {\n    -webkit-transform: scale(1);\n            transform: scale(1);\n  }\n}\n@keyframes particle-pwe-wallet-icon-show {\n  0% {\n    -webkit-transform: scale(0.6);\n            transform: scale(0.6);\n  }\n  100% {\n    -webkit-transform: scale(1);\n            transform: scale(1);\n  }\n}\n.particle-wallet-entry-container .particle-pwe-btn .particle-pwe-wallet-icon.particle-pwe-wallet-icon-hide {\n  display: none;\n}\n.particle-wallet-entry-container .particle-pwe-btn .particle-pwe-down-arrow {\n  display: block;\n}\n.particle-wallet-entry-container .particle-pwe-btn .particle-pwe-down-arrow:not(.particle-pwe-down-arrow-hide) {\n  -webkit-animation: particle-pwe-down-arrow-show 0.3s ease-in-out;\n          animation: particle-pwe-down-arrow-show 0.3s ease-in-out;\n}\n@-webkit-keyframes particle-pwe-down-arrow-show {\n  0% {\n    -webkit-transform: scale(0.6);\n            transform: scale(0.6);\n  }\n  100% {\n    -webkit-transform: scale(1);\n            transform: scale(1);\n  }\n}\n@keyframes particle-pwe-down-arrow-show {\n  0% {\n    -webkit-transform: scale(0.6);\n            transform: scale(0.6);\n  }\n  100% {\n    -webkit-transform: scale(1);\n            transform: scale(1);\n  }\n}\n.particle-wallet-entry-container .particle-pwe-btn .particle-pwe-down-arrow.particle-pwe-down-arrow-hide {\n  display: none;\n}\n.particle-wallet-entry-container .particle-pwe-iframe-content {\n  background-color: #fff;\n  border: none;\n  border-radius: 10px;\n  -webkit-box-shadow: -1px 3px 11px 2px #00000073;\n          box-shadow: -1px 3px 11px 2px #00000073;\n  display: none;\n  height: 650px;\n  overflow: hidden;\n  position: fixed;\n  width: 400px;\n  z-index: 1000;\n}\n.particle-wallet-entry-container .particle-pwe-iframe-content.particle-pwe-full-screen-iframe-content {\n  top: 0 !important;\n  left: 0 !important;\n  width: 100% !important;\n  height: 100% !important;\n  border-radius: 0 !important;\n}\n@media screen and (max-height: 660px) {\n  .particle-wallet-entry-container .particle-pwe-iframe-content {\n    height: 600px;\n    width: 360px;\n  }\n}\n.particle-wallet-entry-container .particle-pwe-iframe-content.particle-pwe-iframe-content-show {\n  display: block;\n}\n.particle-pwe-iframe-content-dark{\n  background-color: #000 !important;\n}\n.particle-pwe-iframe-content-light{\n  background-color: #fff !important;\n}\n.particle-wallet-entry-container .particle-pwe-iframe-content .particle-pwe-iframe {\n  border: none;\n  height: 100%;\n  width: 100%;\n}\n\n",renderStyle=()=>{const e="particle-wallet-entry-style",t=document.querySelector("."+e);t&&t.remove();const n=document.createElement("style");n.classList.add(e),n.innerHTML=style2,document.head.appendChild(n)},style_default=renderStyle,fullScreenClass="particle-pwe-full-screen-iframe-content",isListen=!1,WalletEntryPosition=(e=>(e.BR="bottom-right",e.BL="bottom-left",e.TR="top-right",e.TL="top-left",e))(WalletEntryPosition||{}),timer=null,_WalletEntryPlugin=class{constructor(e,t,n){this.config=e,this.auth=t,this.walletEntryOptions=n,"undefined"!=typeof window&&(this.destroy(),this.auth.isLogin()&&this.walletEntryRander(),this.auth.on("connect",(()=>{this.walletEntryRander()})),this.auth.on("disconnect",(()=>{this.destroy()})))}isMobile(){return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)}openWallet(e){var t,n,i,r,o,a;if(!(null==(n=null==(t=this.auth)?void 0:t.isLogin)?void 0:n.call(t)))return;const s=getWalletUrl(this.auth);if(this.isMobile()||isBraveBrowser())return window.open(s),!1;const l=document.querySelector(".particle-pwe-wallet-icon"),c=document.querySelector(".particle-pwe-down-arrow"),p=document.querySelector(".particle-pwe-iframe-content");"large"===(null==e?void 0:e.windowSize)&&(null==p||p.classList.add(fullScreenClass)),isNullish(null==(r=null==(i=this.auth)?void 0:i.getAuthTheme())?void 0:r.modalBorderRadius)||(p.style.borderRadius=`${null==(a=null==(o=this.auth)?void 0:o.getAuthTheme())?void 0:a.modalBorderRadius}px`),null==p||p.classList.add("particle-pwe-iframe-content-show");const d=getWalletUIMode(this.auth);"dark"==d?(null==p||p.classList.add("particle-pwe-iframe-content-dark"),null==p||p.classList.remove("particle-pwe-iframe-content-light")):(null==p||p.classList.add("particle-pwe-iframe-content-light"),null==p||p.classList.remove("particle-pwe-iframe-content-dark"));let u=document.querySelector(".particle-pwe-iframe");(null==u?void 0:u.src)&&new URLSearchParams(null==u?void 0:u.src).get("theme")!==d&&(u.remove(),u=null),u||(u=document.createElement("iframe"),u.className="particle-pwe-iframe",u.allow="camera",null==p||p.appendChild(u),u.src=s),null==l||l.classList.add("particle-pwe-wallet-icon-hide"),null==c||c.classList.remove("particle-pwe-down-arrow-hide"),this.updateIframeContentPosition()}setWalletIcon(){const e=document.querySelector(".particle-pwe-wallet-icon"),t=document.querySelector(".particle-pwe-down-arrow");e&&e.setAttribute("src",walletIconDarkBase64),t&&t.setAttribute("src",downArrowDarkBase64)}updateIframeContentPosition(){var e,t;const n=document.querySelector(".particle-pwe-iframe-content");if(!n||"none"===(null==(e=null==n?void 0:n.style)?void 0:e.display))return;const i=document.querySelector(".particle-pwe-btn");(null==(t=this.config.wallet)?void 0:t.displayWalletEntry)||(i.style.display="none");const r=i.getBoundingClientRect(),o=n.getBoundingClientRect(),a=window.innerHeight,s=window.innerWidth,l=o.height,c=o.width,p=r.height,d=r.top,u=r.left,h=r.bottom,f=r.right;if(h+l+10<a&&f+c+10<s)n.style.top=h+10+"px",n.style.left=u+"px";else if(h+l+10<a&&u-c-10>0)n.style.top=h+10+"px",n.style.left=f-c+"px";else if(d-l-10>0&&f+c+10<s)n.style.top=d-l-10+"px",n.style.left=u+"px";else if(d-l-10>0&&u-c-10>0)n.style.top=d-l-10+"px",n.style.left=f-c+"px";else if(f+c+10<s){const e=d+p/2-l/2;n.style.top=e<30?"30px":e>a-l-30?a-l-30+"px":e+"px",n.style.left=f+10+"px"}else if(u-c-10>0){const e=d+p/2-l/2;n.style.top=e<30?"30px":e>a-l-30?a-l-30+"px":e+"px",n.style.left=u-c-10+"px"}}setButtonStorageData(e){const{innerWidth:t,innerHeight:n}=window,i=this.walletEntryOptions.position||"bottom-right";localStorage.setItem(_WalletEntryPlugin.WALLET_BTN_POSITION,`${e.x},${e.y},${e.direction},${i}`),localStorage.setItem(_WalletEntryPlugin.WALLET_BTN_POSITION+"_window",`${t},${n}`)}getButtonStorageData(){var e,t,n,i;const{innerWidth:r,innerHeight:o}=window,[a,s,l="right",c]=(null==(t=null==(e=null==localStorage?void 0:localStorage.getItem(_WalletEntryPlugin.WALLET_BTN_POSITION))?void 0:e.split)?void 0:t.call(e,","))||[];let[p,d]=(null==(i=null==(n=localStorage.getItem(_WalletEntryPlugin.WALLET_BTN_POSITION+"_window"))?void 0:n.split)?void 0:i.call(n,","))||[];return p=Number(p||0),d=Number(d||0),p&&d&&(p!=r||d!=o)?(localStorage.removeItem(_WalletEntryPlugin.WALLET_BTN_POSITION),localStorage.removeItem(_WalletEntryPlugin.WALLET_BTN_POSITION+"_window"),{x:r,y:o,position:c||this.walletEntryOptions.position||"bottom-right",direction:"right"}):{x:Number(a)||0,y:Number(s)||0,position:c||this.walletEntryOptions.position||"bottom-right",direction:l}}updateWalletBtnPosition(e,t,n=""){const{width:i}=document.body.getBoundingClientRect(),{direction:r}=this.getButtonStorageData();let o=e>i/2||"windowResize"==n&&"right"===r?i-60:0,a=t,s="left";return o<30?(o=30,s="left"):o>i-90&&(o=i-90,s="right"),a<30?a=30:a>window.innerHeight-90&&(a=window.innerHeight-90),{left:o,top:a,direction:s}}closeWallet(){const e=document.querySelector(".particle-pwe-iframe-content");null==e||e.classList.remove("particle-pwe-iframe-content-show");const t=document.querySelector(".particle-pwe-wallet-icon"),n=document.querySelector(".particle-pwe-down-arrow");null==t||t.classList.remove("particle-pwe-wallet-icon-hide"),null==n||n.classList.add("particle-pwe-down-arrow-hide")}resize(){const e=this;return()=>{clearTimeout(timer),timer=setTimeout((()=>{localStorage.removeItem(_WalletEntryPlugin.WALLET_BTN_POSITION);const t=document.querySelector(".particle-pwe-btn"),{x:n,y:i}=this.getButtonStorageData(),r=n||window.innerWidth,o=i||window.innerHeight,{left:a,top:s,direction:l}=e.updateWalletBtnPosition(r,o,"windowResize");t&&(t.style.left=a+"px",t.style.top=s+"px"),this.setButtonStorageData({x:r,y:o,direction:l}),e.updateIframeContentPosition(),(()=>{__async(this,null,(function*(){let e=0;do{e++,yield this.sleep(100),this.updateIframeContentPosition()}while(e<15)}))})()}),10)}}sleep(e){return __async(this,null,(function*(){return new Promise((t=>setTimeout(t,e)))}))}preload(){const e=walletUrl(),t=document.createElement("script");t.src=`${e}/preload.js?_=${6e4*Math.floor(Date.now()/6e4)}`,t.setAttribute("data-target","web-wallet"),document.body.appendChild(t)}walletEntryRander(){return __async(this,null,(function*(){var e;style_default(),html_default(),this.setWalletIcon(),!1!==(null==(e=this.walletEntryOptions)?void 0:e.preload)&&this.preload();const t=document.querySelector(".particle-pwe-btn"),{x:n,y:i}=this.getButtonStorageData();if(n&&i)if((Number(n)||0)<window.innerWidth&&(Number(i)||0)<window.innerHeight){const{left:e,top:r}=this.updateWalletBtnPosition(Number(n)||0,Number(i)||0);t.style.left=e+"px",t.style.top=r+"px",this.updateIframeContentPosition()}else{const{left:e,top:n}=this.updateWalletBtnPosition(window.innerWidth,window.innerHeight);t.style.left=e+"px",t.style.top=n+"px",this.updateIframeContentPosition()}else{const e=this.walletEntryOptions.position||"bottom-left";let n,i;"bottom-right"===e?(n=window.innerHeight,i=window.innerWidth):"top-right"===e?(n=0,i=window.innerWidth):"top-left"===e?(n=0,i=0):(n=window.innerHeight,i=0);const r=this.updateWalletBtnPosition(i,n);t.style.left=r.left+"px",t.style.top=r.top+"px",this.updateIframeContentPosition()}const r=document.querySelector(".particle-pwe-wallet-icon"),o=document.querySelector(".particle-pwe-down-arrow");let a=!1;const s=(yield import("draggabilly")).default;(draggie=new s(t)).on("dragStart",(()=>{a=!0,t.style.cursor="move"})),draggie.on("dragMove",(()=>{this.updateIframeContentPosition()})),draggie.on("dragEnd",((e,n)=>{e.stopPropagation(),t.style.cursor="pointer";const{clientX:i,clientY:r}=n,{left:o,top:s,direction:l}=this.updateWalletBtnPosition(i,r-35);t.style.left=o+"px",t.style.top=s+"px",this.updateIframeContentPosition(),(()=>{__async(this,null,(function*(){let e=0;do{e++,yield this.sleep(20),this.updateIframeContentPosition()}while(e<70)}))})(),this.setButtonStorageData({x:o,y:s,direction:l}),setTimeout((()=>{a=!1}))})),t.addEventListener("touchend",(()=>{a||this.openWallet()})),null==r||r.addEventListener("click",(e=>{var t;null==(t=null==e?void 0:e.stopPropagation)||t.call(e),a||this.isMobile()||this.openWallet()})),null==o||o.addEventListener("click",(e=>{e.stopPropagation(),a||this.closeWallet()})),window.walletEntryPlugin=this,isListen||(isListen=!0,window.addEventListener("resize",window.walletEntryPlugin.resize(),!1),window.addEventListener("message",(e=>{var t,n,i,r,o;if("PARTICLE_WALLET_RESIZE_IFRAME"===(null==(t=null==e?void 0:e.data)?void 0:t.type)){const e=document.querySelector(".particle-pwe-iframe-content"),t=null==e?void 0:e.classList;(null==(n=null==t?void 0:t.contains)?void 0:n.call(t,fullScreenClass))?(null==(i=window.walletEntryPlugin.config.wallet)?void 0:i.displayWalletEntry)?(null==(r=null==t?void 0:t.remove)||r.call(t,fullScreenClass),window.walletEntryPlugin.resize(),window.walletEntryPlugin.updateIframeContentPosition()):window.walletEntryPlugin.closeWallet():null==(o=null==t?void 0:t.add)||o.call(t,fullScreenClass)}}),!1))}))}destroy(){var e,t,n;null==(e=null==draggie?void 0:draggie.destroy)||e.call(draggie),window.removeEventListener("resize",this.resize(),!1),null==(n=null==(t=document.querySelector(".particle-wallet-entry-container"))?void 0:t.remove)||n.call(t)}},WalletEntryPlugin=_WalletEntryPlugin;WalletEntryPlugin.WALLET_BTN_POSITION="walletBtnPosition";var import_analytics=require("@particle-network/analytics");function particleActive(e,t,n,i,r){const o=i,{token:a,thirdparty_user_info:s,security_account:l}=o,c=__objRest(o,["token","thirdparty_user_info","security_account"]);e.active({chain_id:t,identity:c.uuid,login_type:import_analytics.AcitveLoginType.PARTICLE,action:r,wallet_address:n,user_info:JSON.stringify(c,((e,t)=>{if(!isNullish(t))return t}))})}var createSession=e=>__async(void 0,null,(function*(){return new Promise(((t,n)=>{const i=new XMLHttpRequest;i.open("POST",`${apiUrl()}/auth-sessions`,!0),i.timeout=3e4,i.setRequestHeader("Content-type","application/x-www-form-urlencoded"),i.onload=function(){const e=JSON.parse(this.responseText);e.error_code?n(e.message):t(e.key)},i.onerror=function(){n(this.statusText)},i.send(`data=${e}`)}))})),create_session_default=createSession,silenceLogout=e=>__async(void 0,[e],(function*({token:e,projectUuid:t,projectKey:n}){return new Promise(((i,r)=>{const o=new XMLHttpRequest;let a=`${apiUrl()}/fast_logout`;a+=`?projectUuid=${t}&projectKey=${n}`,o.open("POST",a,!0),o.timeout=3e4,o.setRequestHeader("Content-type","application/x-www-form-urlencoded"),o.onload=function(){const e=JSON.parse(this.responseText);e.error_code?r(e):i(e.success)},o.onerror=function(){r(this.statusText)},o.send(`token=${e}`)}))})),silence_logout_default=silenceLogout,userSimpleInfo=e=>__async(void 0,[e],(function*({token:e,projectUuid:t,projectKey:n,projectAppUuid:i}){return new Promise(((r,o)=>{const a=new XMLHttpRequest;let s=`${apiUrl()}/apps/${i}/user-simple-info`;s+=`?projectUuid=${t}&projectKey=${n}&token=${e}`,a.open("GET",s,!0),a.timeout=3e4,a.onload=function(){const e=JSON.parse(this.responseText);e.error_code?o(e):r(e)},a.onerror=function(){o(this.statusText)},a.send()}))})),user_simple_info_default=userSimpleInfo,Auth=class{constructor(e,t){this.config=e,this.bi=t,this.PN_AUTH_USER_INFO="pn_auth_user_info",this.PN_AUTH_TYPE="pn_auth_type",this.PN_TEMP_SECRET_KEY="pn_temp_secret_key",this.events=new import_events.EventEmitter,this.uiMode="auto",this.displayCloseButton=!0,this.displayWallet=!1,this.modalBorderRadius=24,this.authResultMap=new Map,"undefined"!=typeof window&&addEventListener("message",(e=>{var t,n,i;"particle-network-provider"===(null==(t=null==e?void 0:e.data)?void 0:t.name)?this.handleAuthEvent(e):"particle-network-wallet"===(null==(n=null==e?void 0:e.data)?void 0:n.name)?this.handleWalletEvent(e):"particle-network-auth-load-completed"===(null==(i=null==e?void 0:e.data)?void 0:i.name)&&this.hideIframeBackground(e)}))}handleAuthEvent(e){var t,n;const i=this.getAuthResult(null==(t=e.data)?void 0:t.state,!0);if(!i)return;let r;try{r=this.decrypt(e.data)}catch(e){r={error:AuthError.decrypt(e)}}if(r.wallets){const e=this.getUserInfo();e&&(e.wallets=r.wallets,this.setUserInfo(e))}if(r.security_account){const e=this.getUserInfo();e&&(e.security_account=r.security_account,this.setUserInfo(e))}if(r.token&&r.uuid){const t=r,{redirect_type:i}=t,o=__objRest(t,["redirect_type"]);this.setUserInfo(o),this.setAuthType((null==(n=e.data)?void 0:n.authType)||""),this.bi.records({record_type:import_analytics2.RecordType.PAGE_LOGIN_SUCCESS_BACK})}const{resolve:o,reject:a,container:s}=i;if(r.error?(8005!==r.error.code&&10005!==r.error.code||(this.setUserInfo(null),this.events.emit("disconnect")),a(r.error)):o(r),s)try{"remove"in s&&s.remove()}catch(e){}const l=document.getElementById("particle-network-container");l&&(l.style.display="none")}handleWalletEvent(e){var t,n;"logout"===(null==(n=null==(t=null==e?void 0:e.data)?void 0:t.data)?void 0:n.type)&&(this.setUserInfo(null),this.events.emit("disconnect"))}hideIframeBackground(e){var t;const n=null==(t=null==e?void 0:e.data)?void 0:t.state,i=this.authResultMap.get(n);i&&i.container&&"remove"in i.container&&(i.container.style.backgroundColor="#00000000")}setAuthResult(e){if((null==e?void 0:e.container)&&"close"in e.container&&!e.container.closed)try{e.intervalTimer=setInterval((()=>{if((null==e?void 0:e.container)&&"close"in e.container&&e.container.closed){const t=this.getAuthResult(e.state,!0);t&&t.reject(AuthError.userCancelOperation())}}),500)}catch(e){}this.authResultMap.set(e.state,e)}getAuthResult(e,t=!1){if(!e)return;const n=this.authResultMap.get(e);return t&&n&&(n.intervalTimer&&(clearInterval(n.intervalTimer),n.intervalTimer=void 0),this.authResultMap.delete(e)),n}login(e){return __async(this,null,(function*(){var t;this.bi.records({record_type:import_analytics2.RecordType.PAGE_LOGIN_BUTTON_CLICK});const n=yield this.buildUrl("/login",{login_type:null==e?void 0:e.preferredAuthType,support_auth_types:null!=(t=null==e?void 0:e.supportAuthTypes)?t:"all",account:null==e?void 0:e.account,prompt:null==e?void 0:e.socialLoginPrompt,authorization:null==e?void 0:e.authorization}),i=new URL(n).searchParams.get("state")||"";let r;if(e&&e.preferredAuthType&&(this.isSocialLogin(e.preferredAuthType)||e.account&&isBlockingThirdpartyCookiesBrowser("email"===e.preferredAuthType||"phone"===e.preferredAuthType||"jwt"===e.preferredAuthType))){const t="facebook"==e.preferredAuthType?800:475,i=770;r=yield this.openUrl(n,t,i,!0,"login")}else r=this.getIframe(),r.src=n,"jwt"===(null==e?void 0:e.preferredAuthType)&&(null==e?void 0:e.hideLoading)&&this.hideLoading(r);return new Promise(((e,t)=>{this.setAuthResult({resolve:t=>{var n;this.events.emit("connect",t),particleActive(this.bi,this.getChainId(),(null==(n=this.getWallet())?void 0:n.public_address)||"",this.getUserInfo(),import_analytics2.ActiveAction.LOGIN),e(t)},reject:t,state:i,container:r})}))}))}isSocialLogin(e){return"email"!==e&&"phone"!==e&&"jwt"!==e}logout(e=!0){return __async(this,null,(function*(){var t;if(this.isLogin()){if(!e){const t=yield this.buildUrl("/logout"),n=yield this.openUrl(t),i=new URL(t).searchParams.get("state")||"";return e&&this.hideLoading(n),new Promise((e=>{this.setAuthResult({resolve:()=>{this.setUserInfo(null),this.events.emit("disconnect"),e()},reject:t=>{this.setUserInfo(null),this.events.emit("disconnect"),e()},state:i,container:n})}))}try{yield silence_logout_default({token:(null==(t=this.getUserInfo())?void 0:t.token)||"",projectUuid:this.config.projectId,projectKey:this.config.clientKey})}catch(e){if(10005!==(null==e?void 0:e.error_code))throw e}this.setUserInfo(null),this.events.emit("disconnect")}}))}accountSecurity(){return __async(this,null,(function*(){yield this.openAccountAndSecurity()}))}openAccountAndSecurity(){return __async(this,null,(function*(){var e;if(!this.isLogin())return Promise.reject(AuthError.notLogin());const t=yield this.buildUrl("/account/security",{token:null==(e=this.getUserInfo())?void 0:e.token}),n=yield this.openUrl(t),i=new URL(t).searchParams.get("state")||"";return new Promise(((e,t)=>{this.setAuthResult({resolve:e,reject:t,state:i,container:n})}))}))}getSecurityAccount(){return __async(this,null,(function*(){var e;if(!this.isLogin())return Promise.reject(AuthError.notLogin());const{projectId:t,clientKey:n,appId:i}=this.config,r=yield user_simple_info_default({projectUuid:t,projectKey:n,projectAppUuid:i,token:(null==(e=this.getUserInfo())?void 0:e.token)||""}),o=this.getUserInfo();return o&&this.setUserInfo(__spreadValues(__spreadValues({},o),r)),r}))}hasMasterPassword(){var e,t;if(!this.isLogin())throw AuthError.notLogin();return(null==(t=null==(e=this.getUserInfo())?void 0:e.security_account)?void 0:t.has_set_master_password)||!1}hasPaymentPassword(){var e,t;if(!this.isLogin())throw AuthError.notLogin();return(null==(t=null==(e=this.getUserInfo())?void 0:e.security_account)?void 0:t.has_set_payment_password)||!1}hasSecurityAccount(){var e,t,n,i;if(!this.isLogin())throw AuthError.notLogin();return!isNullish(null==(t=null==(e=this.getUserInfo())?void 0:e.security_account)?void 0:t.phone)||!isNullish(null==(i=null==(n=this.getUserInfo())?void 0:n.security_account)?void 0:i.email)}sign(e,t){return __async(this,null,(function*(){var n,i,r;if(!this.walletExist())return Promise.reject(AuthError.walletNotCreated());let o;o="solana"===(null==(n=this.config.chainName)?void 0:n.toLowerCase())?yield this.buildUrl("/solana/sign",{token:null==(i=this.getUserInfo())?void 0:i.token,method:e,message:t}):yield this.buildUrl("/evm-chain/sign",{token:null==(r=this.getUserInfo())?void 0:r.token,method:e,message:t});const a=yield this.openUrl(o),s=new URL(o).searchParams.get("state")||"";return new Promise(((e,t)=>{this.setAuthResult({resolve:t=>{var n,i;particleActive(this.bi,this.getChainId(),(null==(n=this.getWallet())?void 0:n.public_address)||"",this.getUserInfo(),import_analytics2.ActiveAction.SIGN),e(null!=(i=t.signature)?i:"")},reject:t,state:s,container:a})}))}))}signAllTransactions(e){return __async(this,null,(function*(){var t;if(!this.walletExist())return Promise.reject(AuthError.walletNotCreated());if("solana"!==(null==(t=this.config.chainName)?void 0:t.toLowerCase()))return Promise.reject(AuthError.unsupportedMethod());const n=yield this.sign("signAllTransactions",JSON.stringify(e));return JSON.parse(n)}))}sendTransaction(e){return __async(this,null,(function*(){var t;return this.walletExist()?"solana"===(null==(t=this.config.chainName)?void 0:t.toLowerCase())?this.sign("signAndSendTransaction",e):this.sign("eth_sendTransaction",e):Promise.reject(AuthError.walletNotCreated())}))}switchChain(e,t=!1){return __async(this,null,(function*(){var n;const i=this.getUserInfo();if(!i)return Promise.reject(AuthError.notLogin());if("string"!=typeof e.name||"number"!=typeof e.id)throw AuthError.paramsError();if(!import_chains.chains.getChainInfo(e))throw AuthError.unsupportedChain();const r=i.wallets;if((null==(n=this.config.chainName)?void 0:n.toLowerCase())===e.name.toLowerCase()&&this.config.chainId===e.id)return r;if(this.getWallet("solana"===e.name.toLowerCase()?"solana":"evm_chain"))return this.config.chainName=e.name,this.config.chainId=e.id,this.events.emit("chainChanged",e),r;const o=yield this.createWallet(e.name,t);return this.config.chainName=e.name,this.config.chainId=e.id,this.events.emit("connect",this.getUserInfo()),this.events.emit("chainChanged",e),o}))}setChainInfo(e){if("string"!=typeof e.name||"number"!=typeof e.id)throw AuthError.paramsError();if(!import_chains.chains.getChainInfo(e))throw AuthError.unsupportedChain();this.config.chainName=e.name,this.config.chainId=e.id}createWallet(e,t=!1){return __async(this,null,(function*(){const n=this.getUserInfo();if(!n)return Promise.reject(AuthError.notLogin());if(this.getWallet("solana"===e.toLowerCase()?"solana":"evm_chain"))return n.wallets;const i=yield this.buildUrl("/wallet",{token:n.token,chain_name:e}),r=new URL(i).searchParams.get("state")||"",o=yield this.openUrl(i);return t&&this.hideLoading(o),new Promise(((e,t)=>{this.setAuthResult({resolve:t=>{e(t)},reject:t,state:r,container:o})}))}))}hideLoading(e){const t=document.getElementById("particle-network-container");t&&(t.style.display="none");try{e&&"remove"in e&&(e.style.display="none")}catch(e){}}chainId(){return this.getChainId()}getChainId(){return this.config.chainId}chain(){return this.getChain()}getChain(){return{id:this.config.chainId,name:this.config.chainName}}basicCredentials(){return`Basic ${import_buffer3.Buffer.from(`${this.config.projectId}:${this.config.clientKey}`,"utf8").toString("base64")}`}isLogin(){return null!==this.getUserInfo()}isLoginAsync(){return __async(this,null,(function*(){return yield this.getSecurityAccount(),this.getUserInfo()}))}userInfo(){return this.getUserInfo()}getUserInfo(){const e=localStorage.getItem(this.concatStorageKey(this.PN_AUTH_USER_INFO));return e?JSON.parse(e):null}getAuthType(){return localStorage.getItem(this.concatStorageKey(this.PN_AUTH_TYPE))}setAuthType(e){localStorage.setItem(this.concatStorageKey(this.PN_AUTH_TYPE),e)}walletExist(){return null!=this.getWallet()}wallet(e){return this.getWallet(e)}getWallet(e){const t=this.getUserInfo();if(!t)return null;const n=t.wallets.find((t=>t.chain_name===(e||this.walletChainName())));return void 0!==n&&n.public_address.length>0?n:null}getEVMAddress(){const e=this.getWallet("evm_chain");return Promise.resolve(null==e?void 0:e.public_address)}getSolanaAddress(){const e=this.getWallet("solana");return Promise.resolve(null==e?void 0:e.public_address)}setAuthTheme(e){e.uiMode&&(this.uiMode=e.uiMode),null!==e.displayCloseButton&&void 0!==e.displayCloseButton&&(this.displayCloseButton=e.displayCloseButton),null!==e.displayWallet&&void 0!==e.displayWallet&&(this.displayWallet=e.displayWallet),isNullish(e.modalBorderRadius)||(this.modalBorderRadius=e.modalBorderRadius)}getAuthTheme(){return{uiMode:this.uiMode,displayCloseButton:this.displayCloseButton,displayWallet:this.displayWallet,modalBorderRadius:this.modalBorderRadius}}on(e,t){return this.events.on(e,t),this}once(e,t){return this.events.once(e,t),this}off(e,t){return this.events.off(e,t),this}removeListener(e,t){return this.events.removeListener(e,t),this}walletChainName(){var e;return"solana"===(null==(e=this.config.chainName)?void 0:e.toLowerCase())?"solana":"evm_chain"}setUserInfo(e){e?localStorage.setItem(this.concatStorageKey(this.PN_AUTH_USER_INFO),JSON.stringify(e)):(localStorage.removeItem(this.concatStorageKey(this.PN_AUTH_USER_INFO)),localStorage.removeItem(WalletEntryPlugin.WALLET_BTN_POSITION),localStorage.removeItem(this.concatStorageKey(this.PN_AUTH_TYPE)))}concatStorageKey(e){return`${e}_${this.config.appId}`}getIframe(){let e,t=document.getElementById("particle-network-container");t?t.style.display="block":(t=document.createElement("div"),t.setAttribute("style","display: block;position: fixed;top: 0px;right: 0px;width: 100%;height: 100%;border-radius: 0px;border: none;z-index: 2147483647;background-color: rgba(0, 0, 0, 0.5);align-items: center;"),t.id="particle-network-container",document.body.appendChild(t));const n=document.getElementsByName("particle-network-iframe");if(n.length>0)e=n[0],e.style.display="";else{e=document.createElement("iframe"),e.name="particle-network-iframe",e.className="particle-auth-iframe",e.allow="publickey-credentials-get";let n="#FFFFFF";"dark"===this.getThemeType()&&(n="#1C1D22");const{width:i}=window.screen;let r="400px",o="650px",a="50%",s="50%",l=this.modalBorderRadius,c="translate(-50%, -50%)";i<500&&(r="100%",o="100%",l=0,c="none",a="0px",s="0px");const p={position:"absolute",left:s,top:a,transform:c,width:r,height:o,border:"none","border-radius":`${l}px`,"z-index":"2147483647","background-color":n,"max-width":"100%","max-height":"100%"};e.setAttribute("style",Object.entries(p).map((([e,t])=>`${e}:${t}`)).join(";")),t.appendChild(e)}return e}openUrl(e,t=475,n=770,i=!1,r="sign"){return __async(this,null,(function*(){const o=this.getAuthType();if(i||isBlockingThirdpartyCookiesBrowser("email"===o||"phone"===o||"jwt"===o)){let i=popupWindow(e,"particle-auth",t,n);return i||(i=yield this.continuePopup(e,t,n,r)),i.name="particle-auth-popup",i}const a=this.getIframe();return a.src=e,a}))}continuePopup(e,t=500,n=750,i="sign"){return __async(this,null,(function*(){return new Promise(((r,o)=>{approvePopupRender((()=>{const i=popupWindow(e,"particle-auth",t,n);i?r(i):o(new Error("popup window blocked"))}),i)}))}))}buildUrl(e){return __async(this,arguments,(function*(e,t={}){const n={project_uuid:this.config.projectId,project_client_key:this.config.clientKey,project_app_uuid:this.config.appId,chain_name:this.config.chainName,chain_id:Number(this.config.chainId),sdk_version:getVersion(),device_id:getDeviceId()};Object.assign(n,__spreadValues({},t));const i=(0,import_crypto3.uuidv4)();let r=import_crypto3.urlCrypto.encryptUrlParam(n);const o=r.slice(-32);if(sessionStorage.setItem(`${this.PN_TEMP_SECRET_KEY}-${i}`,o),r.length>1e4){r=`session_key_${yield create_session_default(r)}`}let a=`${authUrl()}?params=${r}&encoding=base64&theme_type=${this.getThemeType()}&display_close_button=${this.displayCloseButton}&display_wallet=${this.displayWallet}&language=${controller.languageCode}&state=${i}&fiat_coin=${controller.fiatCoin}`;return this.config.securityAccount&&(a+=`&security_account=${encodeURIComponent(JSON.stringify(this.config.securityAccount))}`),controller.erc4337&&(a+=`&erc4337=${encodeURIComponent(JSON.stringify(controller.erc4337))}`),`${a}#${e}`}))}getThemeType(){return"auto"===this.uiMode?window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light":this.uiMode}decrypt({data:e,state:t}){const n=sessionStorage.getItem(`${this.PN_TEMP_SECRET_KEY}-${t}`)||"",i=import_crypto3.urlCrypto.decryptData(e,n,"hex");return JSON.parse(i)}},import_buffer4=require("buffer");function bufferToHex(e){return`0x${e.toString("hex")}`}function intToHex(e){return`0x${Number(e).toString(16)}`}function isHexPrefixed(e){if("string"!=typeof e)throw new Error("[isHexPrefixed] input must be type 'string', received type "+typeof e);return"0"===e[0]&&"x"===e[1]}function addHexPrefix(e){return"string"!=typeof e||isHexPrefixed(e)?e:"0x"+e}function stripHexPrefix(e){if("string"!=typeof e)throw new Error("[stripHexPrefix] input must be type 'string', received "+typeof e);return isHexPrefixed(e)?e.slice(2):e}function isHexString(e,t){return!("string"!=typeof e||!e.match(/^0x[0-9A-Fa-f]*$/))&&!(void 0!==t&&t>0&&e.length!==2+2*t)}var _bi,EvmService=class{constructor(e){this.auth=e}assertEVM(){var e,t;if("solana"===(null==(t=null==(e=this.auth.getChain())?void 0:e.name)?void 0:t.toLowerCase()))throw AuthError.unsupportedMethod()}sendTransaction(e){return __async(this,null,(function*(){return this.assertEVM(),this.auth.sendTransaction(addHexPrefix(import_buffer4.Buffer.from(JSON.stringify(e)).toString("hex")))}))}personalSign(e){return __async(this,null,(function*(){return this.assertEVM(),this.auth.sign("personal_sign",e)}))}personalSignUniq(e){return __async(this,null,(function*(){return this.assertEVM(),this.auth.sign("personal_sign_uniq",e)}))}signTypedData(e){return __async(this,arguments,(function*({data:e,version:t}){return this.assertEVM(),this.auth.sign(`eth_signTypedData_${t.toLowerCase()}`,addHexPrefix(import_buffer4.Buffer.from(JSON.stringify(e)).toString("hex")))}))}signTypedDataUniq(e){return __async(this,null,(function*(){return this.assertEVM(),this.auth.sign("eth_signTypedData_v4_uniq",addHexPrefix(import_buffer4.Buffer.from(JSON.stringify(e)).toString("hex")))}))}getAddress(){return __async(this,null,(function*(){return this.auth.getEVMAddress()}))}getRpcUrl(){this.assertEVM();return`${`${rpcUrl()}/evm-chain`}?chainId=${this.auth.getChain().id}&projectUuid=${this.auth.config.projectId}&projectKey=${this.auth.config.clientKey}`}},evmService_default=EvmService,import_buffer5=require("buffer"),SolanaService=class{constructor(e){this.auth=e}assertSolana(){var e,t;if("solana"!==(null==(t=null==(e=this.auth.getChain())?void 0:e.name)?void 0:t.toLowerCase()))throw AuthError.unsupportedMethod()}signAndSendTransaction(e){return this.assertSolana(),this.auth.sendTransaction(e)}signTransaction(e){return __async(this,null,(function*(){this.assertSolana();const t=yield this.auth.sign("signTransaction",e);return import_buffer5.Buffer.from(t,"base64")}))}signAllTransactions(e){return __async(this,null,(function*(){this.assertSolana();return(yield this.auth.signAllTransactions(e)).map((e=>import_buffer5.Buffer.from(e,"base64")))}))}signMessage(e){return __async(this,null,(function*(){this.assertSolana();const t=yield this.auth.sign("signMessage",e);return import_buffer5.Buffer.from(t,"base64")}))}getAddress(){return __async(this,null,(function*(){return this.auth.getSolanaAddress()}))}getRpcUrl(){this.assertSolana();return`${`${rpcUrl()}/solana`}?chainId=${this.auth.getChain().id}&projectUuid=${this.auth.config.projectId}&projectKey=${this.auth.config.clientKey}`}},solanaService_default=SolanaService,ParticleNetwork=class{constructor(e){if(this.isParticleNetwork=!0,__privateAdd(this,_bi,void 0),e||(e={projectId:"34c6b829-5b89-44e8-90a9-6d982787b9c9",clientKey:"c6Z44Ml4TQeNhctvwYgdSv6DBzfjf6t6CB0JDscR",appId:"c1ad1496-5707-4db6-8a2b-3e9f7273d846",chainName:"Solana",chainId:101,preload:!0,wallet:{displayWalletEntry:!0,defaultWalletEntryPosition:"bottom-right"}}),e.chainName&&"string"!=typeof e.chainName||e.chainId&&"number"!=typeof e.chainId||"string"!=typeof e.projectId||"string"!=typeof e.clientKey||"string"!=typeof e.appId)throw AuthError.paramsError();if(e.chainName&&e.chainId){if(!import_chains2.chains.getChainInfo({id:e.chainId,name:e.chainName}))throw AuthError.unsupportedChain()}else e.chainName="Ethereum",e.chainId=1;this.config=e,__privateSet(this,_bi,new import_analytics3.BI({sdk_api_domain:apiUrl(),device_id:getDeviceId(),sdk_version:getVersion(),project_config:{project_uuid:e.projectId,project_key:e.clientKey,project_app_uuid:e.appId}})),this.auth=new Auth(this.config,__privateGet(this,_bi)),this.walletEntryCreate(),this.evm=new evmService_default(this.auth),this.solana=new solanaService_default(this.auth),"undefined"!=typeof window&&(this.openActive(),window.particle=this),!1!==(null==e?void 0:e.preload)&&"undefined"!=typeof window&&setTimeout((()=>{this.preload()}),2e3)}preload(){const e=authUrl(),t=document.createElement("script");t.src=`${e}/preload.js?_=${6e4*Math.floor(Date.now()/6e4)}`,t.setAttribute("data-target","web-auth"),document.body.appendChild(t)}openActive(){var e;this.auth.isLogin()&&(null==(e=this.auth.getWallet())?void 0:e.public_address)&&particleActive(__privateGet(this,_bi),this.auth.getChainId(),this.auth.getWallet().public_address,this.auth.getUserInfo(),import_analytics3.ActiveAction.OPEN)}setAuthTheme(e){this.auth.setAuthTheme(e)}getAuthTheme(){return this.auth.getAuthTheme()}switchChain(e,t=!1){return __async(this,null,(function*(){return this.auth.switchChain(e,t)}))}setChainInfo(e){this.auth.setChainInfo(e)}walletEntryDestroy(){var e;null==(e=this.walletEntry)||e.destroy(),this.walletEntry=void 0}walletEntryCreate(){var e,t;this.walletEntry=new WalletEntryPlugin(this.config,this.auth,{position:(null==(e=this.config.wallet)?void 0:e.defaultWalletEntryPosition)||"bottom-right",preload:null==(t=this.config.wallet)?void 0:t.preload})}openWallet(){var e,t;"undefined"!=typeof window&&(this.auth.isLogin()&&(null==(e=this.auth.getWallet())?void 0:e.public_address)&&particleActive(__privateGet(this,_bi),this.auth.getChainId(),this.auth.getWallet().public_address,this.auth.getUserInfo(),import_analytics3.ActiveAction.OPEN_WALLET),null==(t=this.walletEntry)||t.openWallet({windowSize:"large"}))}buildWalletUrl(e){return getWalletUrl(this.auth,e)}openBuy(e,t,n){const i=getBuyUrl(this.auth,e);"undefined"!=typeof window&&window.open(i,t,n)}setLanguage(e){controller.languageCode=e}getLanguage(){return controller.languageCode}get version(){return getVersion()}setFiatCoin(e){controller.fiatCoin=e}getChain(){return this.auth.getChain()}setERC4337(e){controller.erc4337="boolean"==typeof e&&e?{name:"BICONOMY",version:"1.0.0"}:e}};_bi=new WeakMap;
//# sourceMappingURL=/sm/39783d61cbc4973df1bb89bf6353ff77887b9122a54b40e383470e34e6ad702b.map