@dcl/governance-site 2.4.0 → 2.4.1-26053490649.commit-7819886
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/{BlockOverrides-20fed6f4.js → BlockOverrides-f0043737.js} +1 -1
- package/assets/{ConstantsUtil-5b007dc6.js → ConstantsUtil-e2cd00bd.js} +1 -1
- package/assets/{ExchangeController-7e00faa3.js → ExchangeController-609a1f8c.js} +1 -1
- package/assets/{HelpersUtil-619fe34c.js → HelpersUtil-8166e848.js} +1 -1
- package/assets/{NetworkUtil-02b4425a.js → NetworkUtil-a423d25a.js} +1 -1
- package/assets/{ReownAuthentication-1b062588.js → ReownAuthentication-e97b67e8.js} +1 -1
- package/assets/{SwapController-967c3bb7.js → SwapController-e982292a.js} +1 -1
- package/assets/{UserAvatar-9f3237d1.js → UserAvatar-416242a8.js} +1 -1
- package/assets/{browser-38882dd1.js → browser-7f89d6f5.js} +1 -1
- package/assets/{ccip-f1cad225.js → ccip-34280675.js} +1 -1
- package/assets/{ccip-764d5507.js → ccip-a83d37fd.js} +1 -1
- package/assets/{data-capture-b76da51a.js → data-capture-12750c05.js} +1 -1
- package/assets/{email-65fe5ba2.js → email-f705d359.js} +1 -1
- package/assets/{embedded-wallet-d76a09b7.js → embedded-wallet-7b37b0f3.js} +1 -1
- package/assets/features-d6cbb4d3.js +1 -0
- package/assets/{fortmatic-16e19888.js → fortmatic-233cf816.js} +1 -1
- package/assets/{if-defined-92244c26.js → if-defined-b80e1e5f.js} +1 -1
- package/assets/{index-27925a2f.js → index-016592b7.js} +1 -1
- package/assets/{index-33d1eb17.js → index-0790ea56.js} +1 -1
- package/assets/{index-7fd459dc.js → index-0c360c0f.js} +1 -1
- package/assets/{index-52e013c4.js → index-1def7b3c.js} +1 -1
- package/assets/{index-57e0dc54.js → index-2e026425.js} +1 -1
- package/assets/{index-34752e67.js → index-309c17e3.js} +1 -1
- package/assets/{index-b60004aa.js → index-445fe463.js} +1 -1
- package/assets/{index-5a81d007.js → index-44db0baa.js} +1 -1
- package/assets/{index-67ef8b4a.js → index-450d0678.js} +1 -1
- package/assets/{index-c4d19ff7.js → index-4e635b3b.js} +1 -1
- package/assets/{index-b7ff7f7f.js → index-51ad1ac0.js} +1 -1
- package/assets/{index-60a03db2.js → index-5cb9cf07.js} +1 -1
- package/assets/{index-97685b09.js → index-5d5e656b.js} +1 -1
- package/assets/{index-03870cad.js → index-6304375e.js} +1 -1
- package/assets/{index-dd806019.js → index-67d2807b.js} +1 -1
- package/assets/{index-d149e016.js → index-6dc60c34.js} +1 -1
- package/assets/{index-9622e3f7.js → index-7748ac85.js} +1 -1
- package/assets/{index-81e632eb.js → index-7ed20462.js} +1 -1
- package/assets/{index-dea98de6.js → index-8017fe71.js} +1 -1
- package/assets/{index-29a16f18.js → index-8485cfe1.js} +1 -1
- package/assets/{index-ff62bbe7.js → index-870741d2.js} +1 -1
- package/assets/{index-026a802e.js → index-8e9b20ff.js} +1 -1
- package/assets/{index-7bb70dc0.js → index-9fad67dc.js} +1 -1
- package/assets/{index-3157a25f.js → index-a1808fcb.js} +1 -1
- package/assets/{index-ab9ba68c.css → index-a2717004.css} +4 -4
- package/assets/{index-ff100d2b.js → index-a3f378d1.js} +1 -1
- package/assets/{index-714a675d.js → index-ac8937b9.js} +1 -1
- package/assets/{index-c698c1f5.js → index-ae732654.js} +1 -1
- package/assets/{index-ee0b5500.js → index-b318296e.js} +1 -1
- package/assets/{index-a0eaa57b.js → index-becc5f18.js} +2 -2
- package/assets/{index-3cc40d48.js → index-bfff18be.js} +1 -1
- package/assets/{index-33c90fff.js → index-ca30e4fd.js} +1 -1
- package/assets/{index-7b68384a.js → index-d1b7c41c.js} +20 -20
- package/assets/{index-c7587657.js → index-ea4ab9a5.js} +1 -1
- package/assets/{index-9d7b64c5.js → index-eb68ccad.js} +1 -1
- package/assets/{index-cfb33cb3.js → index-f36edea8.js} +1 -1
- package/assets/{index-28c16ace.js → index-f8b8fc20.js} +1 -1
- package/assets/{index-94114b1d.js → index-ffe0d000.js} +1 -1
- package/assets/{index.web-0b5f4697.js → index.web-ef9fca62.js} +1 -1
- package/assets/{networks-9f3446a4.js → networks-0983c1e2.js} +1 -1
- package/assets/{onramp-7dc355d5.js → onramp-62fd00ae.js} +1 -1
- package/assets/{pay-with-exchange-4b9eb30a.js → pay-with-exchange-e7534688.js} +1 -1
- package/assets/{receive-b6c8e808.js → receive-376da46f.js} +1 -1
- package/assets/{ref-3aacfb42.js → ref-93e8bc0a.js} +1 -1
- package/assets/{secp256k1-eed662a5.js → secp256k1-4d02a4f4.js} +1 -1
- package/assets/{send-46dbb49f.js → send-3e79035e.js} +1 -1
- package/assets/{socials-85d095dc.js → socials-32dc8734.js} +1 -1
- package/assets/{swaps-d413a89f.js → swaps-fc3ef2da.js} +1 -1
- package/assets/{transactions-342a8d38.js → transactions-4147a1b0.js} +1 -1
- package/assets/{w3m-modal-98fb6186.js → w3m-modal-e7f26548.js} +1 -1
- package/assets/{zoraTestnet-a66d1115.js → zoraTestnet-04c4a199.js} +2 -2
- package/index.html +4 -4
- package/package.json +3 -3
- package/assets/features-a44be130.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{Z as Mr,c as w,a5 as La,U as N,t as Be,a as Na,a6 as Fa,$ as Ha,h as qa,a7 as kr,T as Za,a8 as Dr,b as ue,_ as g,a9 as za,aa as Tr,ab as R,ac as Ya,ad as Xa,ae as T,af as ke}from"./index-7b68384a.js";import{h as xr,d as Wr,c as F,s as ne,w as Ga}from"./index-27925a2f.js";import{i as Cr,r as Ka,a as Va}from"./index-d149e016.js";import{i as Rr}from"./index-980812a4.js";var De=Object.prototype.toString,Ur=function(e){var a=De.call(e),t=a==="[object Arguments]";return t||(t=a!=="[object Array]"&&e!==null&&typeof e=="object"&&typeof e.length=="number"&&e.length>=0&&De.call(e.callee)==="[object Function]"),t},le,Te;function Qa(){if(Te)return le;Te=1;var r;if(!Object.keys){var e=Object.prototype.hasOwnProperty,a=Object.prototype.toString,t=Ur,n=Object.prototype.propertyIsEnumerable,o=!n.call({toString:null},"toString"),i=n.call(function(){},"prototype"),u=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],s=function(p){var c=p.constructor;return c&&c.prototype===p},l={$applicationCache:!0,$console:!0,$external:!0,$frame:!0,$frameElement:!0,$frames:!0,$innerHeight:!0,$innerWidth:!0,$onmozfullscreenchange:!0,$onmozfullscreenerror:!0,$outerHeight:!0,$outerWidth:!0,$pageXOffset:!0,$pageYOffset:!0,$parent:!0,$scrollLeft:!0,$scrollTop:!0,$scrollX:!0,$scrollY:!0,$self:!0,$webkitIndexedDB:!0,$webkitStorageInfo:!0,$window:!0},y=function(){if(typeof window>"u")return!1;for(var p in window)try{if(!l["$"+p]&&e.call(window,p)&&window[p]!==null&&typeof window[p]=="object")try{s(window[p])}catch{return!0}}catch{return!0}return!1}(),v=function(p){if(typeof window>"u"||!y)return s(p);try{return s(p)}catch{return!1}};r=function(c){var B=c!==null&&typeof c=="object",_=a.call(c)==="[object Function]",E=t(c),M=B&&a.call(c)==="[object String]",S=[];if(!B&&!_&&!E)throw new TypeError("Object.keys called on a non-object");var k=i&&_;if(M&&c.length>0&&!e.call(c,0))for(var O=0;O<c.length;++O)S.push(String(O));if(E&&c.length>0)for(var j=0;j<c.length;++j)S.push(String(j));else for(var m in c)!(k&&m==="prototype")&&e.call(c,m)&&S.push(String(m));if(o)for(var A=v(c),d=0;d<u.length;++d)!(A&&u[d]==="constructor")&&e.call(c,u[d])&&S.push(u[d]);return S}}return le=r,le}var Ja=Array.prototype.slice,en=Ur,xe=Object.keys,q=xe?function(e){return xe(e)}:Qa(),We=Object.keys;q.shim=function(){if(Object.keys){var e=function(){var a=Object.keys(arguments);return a&&a.length===arguments.length}(1,2);e||(Object.keys=function(t){return en(t)?We(Ja.call(t)):We(t)})}else Object.keys=q;return Object.keys||q};var _e=q,rn=_e,tn=typeof Symbol=="function"&&typeof Symbol("foo")=="symbol",an=Object.prototype.toString,nn=Array.prototype.concat,Ce=Wr,on=function(r){return typeof r=="function"&&an.call(r)==="[object Function]"},Lr=xr(),sn=function(r,e,a,t){if(e in r){if(t===!0){if(r[e]===a)return}else if(!on(t)||!t())return}Lr?Ce(r,e,a,!0):Ce(r,e,a)},Nr=function(r,e){var a=arguments.length>2?arguments[2]:{},t=rn(e);tn&&(t=nn.call(t,Object.getOwnPropertySymbols(e)));for(var n=0;n<t.length;n+=1)sn(r,t[n],e[t[n]],a[t[n]])};Nr.supportsDescriptors=!!Lr;var I=Nr,fn=_e,Fr=Mr(),Hr=w,Z=La,un=Hr("Array.prototype.push"),Re=Hr("Object.prototype.propertyIsEnumerable"),ln=Fr?Z.getOwnPropertySymbols:null,qr=function(e,a){if(e==null)throw new TypeError("target must be an object");var t=Z(e);if(arguments.length===1)return t;for(var n=1;n<arguments.length;++n){var o=Z(arguments[n]),i=fn(o),u=Fr&&(Z.getOwnPropertySymbols||ln);if(u)for(var s=u(o),l=0;l<s.length;++l){var y=s[l];Re(o,y)&&un(i,y)}for(var v=0;v<i.length;++v){var p=i[v];if(Re(o,p)){var c=o[p];t[p]=c}}}return t},ce=qr,cn=function(){if(!Object.assign)return!1;for(var r="abcdefghijklmnopqrst",e=r.split(""),a={},t=0;t<e.length;++t)a[e[t]]=e[t];var n=Object.assign({},a),o="";for(var i in n)o+=i;return r!==o},pn=function(){if(!Object.assign||!Object.preventExtensions)return!1;var r=Object.preventExtensions({1:2});try{Object.assign(r,"xy")}catch{return r[1]==="y"}return!1},Zr=function(){return!Object.assign||cn()||pn()?ce:Object.assign},vn=I,yn=Zr,gn=function(){var e=yn();return vn(Object,{assign:e},{assign:function(){return Object.assign!==e}}),e},mn=I,dn=F,hn=qr,zr=Zr,bn=gn,Sn=dn.apply(zr()),Yr=function(e,a){return Sn(Object,arguments)};mn(Yr,{getPolyfill:zr,implementation:hn,shim:bn});var wn=Yr,Xr=N,Gr=F,$n=Gr(Xr("String.prototype.indexOf")),Kr=function(e,a){var t=Xr(e,!!a);return typeof t=="function"&&$n(e,".prototype.")>-1?Gr(t):t},L=function(){return typeof(function(){}).name=="string"},U=Object.getOwnPropertyDescriptor;if(U)try{U([],"length")}catch{U=null}L.functionsHaveConfigurableNames=function(){if(!L()||!U)return!1;var e=U(function(){},"name");return!!e&&!!e.configurable};var Pn=Function.prototype.bind;L.boundFunctionsHaveNames=function(){return L()&&typeof Pn=="function"&&(function(){}).bind().name!==""};var On=L,Ue=Wr,jn=xr(),Bn=On.functionsHaveConfigurableNames(),_n=Be,En=function(e,a){if(typeof e!="function")throw new _n("`fn` is not a function");var t=arguments.length>2&&!!arguments[2];return(!t||Bn)&&(jn?Ue(e,"name",a,!0,!0):Ue(e,"name",a)),e},An=En,In=Be,Mn=Object,Vr=An(function(){if(this==null||this!==Mn(this))throw new In("RegExp.prototype.flags getter called on non-object");var e="";return this.hasIndices&&(e+="d"),this.global&&(e+="g"),this.ignoreCase&&(e+="i"),this.multiline&&(e+="m"),this.dotAll&&(e+="s"),this.unicode&&(e+="u"),this.unicodeSets&&(e+="v"),this.sticky&&(e+="y"),e},"get flags",!0),kn=Vr,Dn=I.supportsDescriptors,Tn=Object.getOwnPropertyDescriptor,Qr=function(){if(Dn&&/a/mig.flags==="gim"){var e=Tn(RegExp.prototype,"flags");if(e&&typeof e.get=="function"&&"dotAll"in RegExp.prototype&&"hasIndices"in RegExp.prototype){var a="",t={};if(Object.defineProperty(t,"hasIndices",{get:function(){a+="d"}}),Object.defineProperty(t,"sticky",{get:function(){a+="y"}}),e.get.call(t),a==="dy")return e.get}}return kn},xn=I.supportsDescriptors,Wn=Qr,Cn=Na,Rn=Object.defineProperty,Un=Fa,Le=Ha,Ln=/a/,Nn=function(){if(!xn||!Le)throw new Un("RegExp.prototype.flags requires a true ES5 environment that supports property descriptors");var e=Wn(),a=Le(Ln),t=Cn(a,"flags");return(!t||t.get!==e)&&Rn(a,"flags",{configurable:!0,enumerable:!1,get:e}),e},Fn=I,Hn=F,qn=Vr,Jr=Qr,Zn=Nn,et=Hn(Jr());Fn(et,{getPolyfill:Jr,implementation:qn,shim:Zn});var zn=et,z={exports:{}},Yn=qa,x=kr(),P=Be,Ee={assert:function(r,e){if(!r||typeof r!="object"&&typeof r!="function")throw new P("`O` is not an object");if(typeof e!="string")throw new P("`slot` must be a string");if(x.assert(r),!Ee.has(r,e))throw new P("`"+e+"` is not present on `O`")},get:function(r,e){if(!r||typeof r!="object"&&typeof r!="function")throw new P("`O` is not an object");if(typeof e!="string")throw new P("`slot` must be a string");var a=x.get(r);return a&&a["$"+e]},has:function(r,e){if(!r||typeof r!="object"&&typeof r!="function")throw new P("`O` is not an object");if(typeof e!="string")throw new P("`slot` must be a string");var a=x.get(r);return!!a&&Yn(a,"$"+e)},set:function(r,e,a){if(!r||typeof r!="object"&&typeof r!="function")throw new P("`O` is not an object");if(typeof e!="string")throw new P("`slot` must be a string");var t=x.get(r);t||(t={},x.set(r,t)),t["$"+e]=a}};Object.freeze&&Object.freeze(Ee);var Xn=Ee,W=Xn,Gn=Za,Ne=typeof StopIteration=="object"?StopIteration:null,Kn=function(e){if(!Ne)throw new Gn("this environment lacks StopIteration");W.set(e,"[[Done]]",!1);var a={next:function(){var n=W.get(this,"[[Iterator]]"),o=!!W.get(n,"[[Done]]");try{return{done:o,value:o?void 0:n.next()}}catch(i){if(W.set(n,"[[Done]]",!0),i!==Ne)throw i;return{done:!0,value:void 0}}}};return W.set(a,"[[Iterator]]",e),a},rt=w,Vn=rt("String.prototype.valueOf"),Qn=function(e){try{return Vn(e),!0}catch{return!1}},Jn=rt("Object.prototype.toString"),eo="[object String]",ro=ne(),tt=function(e){return typeof e=="string"?!0:!e||typeof e!="object"?!1:ro?Qn(e):Jn(e)===eo},Ae=typeof Map=="function"&&Map.prototype?Map:null,to=typeof Set=="function"&&Set.prototype?Set:null,G;Ae||(G=function(e){return!1});var at=Ae?Map.prototype.has:null,Fe=to?Set.prototype.has:null;!G&&!at&&(G=function(e){return!1});var nt=G||function(e){if(!e||typeof e!="object")return!1;try{if(at.call(e),Fe)try{Fe.call(e)}catch{return!0}return e instanceof Ae}catch{}return!1},ao=typeof Map=="function"&&Map.prototype?Map:null,Ie=typeof Set=="function"&&Set.prototype?Set:null,K;Ie||(K=function(e){return!1});var He=ao?Map.prototype.has:null,ot=Ie?Set.prototype.has:null;!K&&!ot&&(K=function(e){return!1});var it=K||function(e){if(!e||typeof e!="object")return!1;try{if(ot.call(e),He)try{He.call(e)}catch{return!0}return e instanceof Ie}catch{}return!1},qe=Cr,Ze=Kn;if(Dr()||Mr()){var pe=Symbol.iterator;z.exports=function(e){if(e!=null&&typeof e[pe]<"u")return e[pe]();if(qe(e))return Array.prototype[pe].call(e)}}else{var no=Rr,oo=tt,ze=N,io=ze("%Map%",!0),so=ze("%Set%",!0),h=Kr,Ye=h("Array.prototype.push"),Xe=h("String.prototype.charCodeAt"),fo=h("String.prototype.slice"),uo=function(e,a){var t=e.length;if(a+1>=t)return a+1;var n=Xe(e,a);if(n<55296||n>56319)return a+1;var o=Xe(e,a+1);return o<56320||o>57343?a+1:a+2},ve=function(e){var a=0;return{next:function(){var n=a>=e.length,o;return n||(o=e[a],a+=1),{done:n,value:o}}}},Ge=function(e,a){if(no(e)||qe(e))return ve(e);if(oo(e)){var t=0;return{next:function(){var o=uo(e,t),i=fo(e,t,o);return t=o,{done:o>e.length,value:i}}}}if(a&&typeof e["_es6-shim iterator_"]<"u")return e["_es6-shim iterator_"]()};if(!io&&!so)z.exports=function(e){if(e!=null)return Ge(e,!0)};else{var lo=nt,co=it,Ke=h("Map.prototype.forEach",!0),Ve=h("Set.prototype.forEach",!0);if(typeof ue>"u"||!ue.versions||!ue.versions.node)var Qe=h("Map.prototype.iterator",!0),Je=h("Set.prototype.iterator",!0);var er=h("Map.prototype.@@iterator",!0)||h("Map.prototype._es6-shim iterator_",!0),rr=h("Set.prototype.@@iterator",!0)||h("Set.prototype._es6-shim iterator_",!0),po=function(e){if(lo(e)){if(Qe)return Ze(Qe(e));if(er)return er(e);if(Ke){var a=[];return Ke(e,function(n,o){Ye(a,[o,n])}),ve(a)}}if(co(e)){if(Je)return Ze(Je(e));if(rr)return rr(e);if(Ve){var t=[];return Ve(e,function(n){Ye(t,n)}),ve(t)}}};z.exports=function(e){return po(e)||Ge(e)}}}var vo=z.exports,tr=function(r){return r!==r},st=function(e,a){return e===0&&a===0?1/e===1/a:!!(e===a||tr(e)&&tr(a))},yo=st,ft=function(){return typeof Object.is=="function"?Object.is:yo},go=ft,mo=I,ho=function(){var e=go();return mo(Object,{is:e},{is:function(){return Object.is!==e}}),e},bo=I,So=F,wo=st,ut=ft,$o=ho,lt=So(ut(),Object);bo(lt,{getPolyfill:ut,implementation:wo,shim:$o});var Po=lt,Oo=F,ct=w,jo=N,he=jo("%ArrayBuffer%",!0),Y=ct("ArrayBuffer.prototype.byteLength",!0),Bo=ct("Object.prototype.toString"),ar=!!he&&!Y&&new he(0).slice,nr=!!ar&&Oo(ar),pt=Y||nr?function(e){if(!e||typeof e!="object")return!1;try{return Y?Y(e):nr(e,0),!0}catch{return!1}}:he?function(e){return Bo(e)==="[object ArrayBuffer]"}:function(e){return!1},vt=w,_o=vt("Date.prototype.getDay"),Eo=function(e){try{return _o(e),!0}catch{return!1}},Ao=vt("Object.prototype.toString"),Io="[object Date]",Mo=ne(),ko=function(e){return typeof e!="object"||e===null?!1:Mo?Eo(e):Ao(e)===Io},Do=w,or=Do("SharedArrayBuffer.prototype.byteLength",!0),To=or?function(e){if(!e||typeof e!="object")return!1;try{return or(e),!0}catch{return!1}}:function(e){return!1},yt=w,xo=yt("Number.prototype.toString"),Wo=function(e){try{return xo(e),!0}catch{return!1}},Co=yt("Object.prototype.toString"),Ro="[object Number]",Uo=ne(),Lo=function(e){return typeof e=="number"?!0:!e||typeof e!="object"?!1:Uo?Wo(e):Co(e)===Ro},gt=w,No=gt("Boolean.prototype.toString"),Fo=gt("Object.prototype.toString"),Ho=function(e){try{return No(e),!0}catch{return!1}},qo="[object Boolean]",Zo=ne(),zo=function(e){return typeof e=="boolean"?!0:e===null||typeof e!="object"?!1:Zo?Ho(e):Fo(e)===qo},be={exports:{}},mt=w,Yo=mt("Object.prototype.toString"),Xo=Dr(),Go=Ka();if(Xo){var Ko=mt("Symbol.prototype.toString"),Vo=Go(/^Symbol\(.*\)$/),Qo=function(e){return typeof e.valueOf()!="symbol"?!1:Vo(Ko(e))};be.exports=function(e){if(typeof e=="symbol")return!0;if(!e||typeof e!="object"||Yo(e)!=="[object Symbol]")return!1;try{return Qo(e)}catch{return!1}}}else be.exports=function(e){return!1};var Jo=be.exports,Se={exports:{}},ir=typeof BigInt<"u"&&BigInt,ei=function(){return typeof ir=="function"&&typeof BigInt=="function"&&typeof ir(42)=="bigint"&&typeof BigInt(42)=="bigint"},ri=ei();if(ri){var ti=BigInt.prototype.valueOf,ai=function(e){try{return ti.call(e),!0}catch{}return!1};Se.exports=function(e){return e===null||typeof e>"u"||typeof e=="boolean"||typeof e=="string"||typeof e=="number"||typeof e=="symbol"||typeof e=="function"?!1:typeof e=="bigint"?!0:ai(e)}}else Se.exports=function(e){return!1};var ni=Se.exports,oi=tt,ii=Lo,si=zo,fi=Jo,ui=ni,li=function(e){if(e==null||typeof e!="object"&&typeof e!="function")return null;if(oi(e))return"String";if(ii(e))return"Number";if(si(e))return"Boolean";if(fi(e))return"Symbol";if(ui(e))return"BigInt"},V=typeof WeakMap=="function"&&WeakMap.prototype?WeakMap:null,sr=typeof WeakSet=="function"&&WeakSet.prototype?WeakSet:null,Q;V||(Q=function(e){return!1});var we=V?V.prototype.has:null,ye=sr?sr.prototype.has:null;!Q&&!we&&(Q=function(e){return!1});var ci=Q||function(e){if(!e||typeof e!="object")return!1;try{if(we.call(e,we),ye)try{ye.call(e,ye)}catch{return!0}return e instanceof V}catch{}return!1},$e={exports:{}},pi=N,dt=w,vi=pi("%WeakSet%",!0),ge=dt("WeakSet.prototype.has",!0);if(ge){var me=dt("WeakMap.prototype.has",!0);$e.exports=function(e){if(!e||typeof e!="object")return!1;try{if(ge(e,ge),me)try{me(e,me)}catch{return!0}return e instanceof vi}catch{}return!1}}else $e.exports=function(e){return!1};var yi=$e.exports,gi=nt,mi=it,di=ci,hi=yi,bi=function(e){if(e&&typeof e=="object"){if(gi(e))return"Map";if(mi(e))return"Set";if(di(e))return"WeakMap";if(hi(e))return"WeakSet"}return!1},Si=w,fr=Si("ArrayBuffer.prototype.byteLength",!0),wi=pt,$i=function(e){return wi(e)?fr?fr(e):e.byteLength:NaN},ht=wn,$=Kr,ur=zn,Pi=N,D=vo,Oi=kr,lr=Po,cr=Cr,pr=Rr,vr=pt,yr=ko,gr=Va,mr=To,dr=_e,hr=li,br=bi,Sr=Ga,wr=$i,$r=$("SharedArrayBuffer.prototype.byteLength",!0),Pr=$("Date.prototype.getTime"),de=Object.getPrototypeOf,Or=$("Object.prototype.toString"),J=Pi("%Set%",!0),Pe=$("Map.prototype.has",!0),ee=$("Map.prototype.get",!0),jr=$("Map.prototype.size",!0),re=$("Set.prototype.add",!0),bt=$("Set.prototype.delete",!0),te=$("Set.prototype.has",!0),X=$("Set.prototype.size",!0);function Br(r,e,a,t){for(var n=D(r),o;(o=n.next())&&!o.done;)if(b(e,o.value,a,t))return bt(r,o.value),!0;return!1}function St(r){if(typeof r>"u")return null;if(typeof r!="object")return typeof r=="symbol"?!1:typeof r=="string"||typeof r=="number"?+r==+r:!0}function ji(r,e,a,t,n,o){var i=St(a);if(i!=null)return i;var u=ee(e,i),s=ht({},n,{strict:!1});return typeof u>"u"&&!Pe(e,i)||!b(t,u,s,o)?!1:!Pe(r,i)&&b(t,u,s,o)}function Bi(r,e,a){var t=St(a);return t??(te(e,t)&&!te(r,t))}function _r(r,e,a,t,n,o){for(var i=D(r),u,s;(u=i.next())&&!u.done;)if(s=u.value,b(a,s,n,o)&&b(t,ee(e,s),n,o))return bt(r,s),!0;return!1}function b(r,e,a,t){var n=a||{};if(n.strict?lr(r,e):r===e)return!0;var o=hr(r),i=hr(e);if(o!==i)return!1;if(!r||!e||typeof r!="object"&&typeof e!="object")return n.strict?lr(r,e):r==e;var u=t.has(r),s=t.has(e),l;if(u&&s){if(t.get(r)===t.get(e))return!0}else l={};return u||t.set(r,l),s||t.set(e,l),Ai(r,e,n,t)}function Er(r){return!r||typeof r!="object"||typeof r.length!="number"||typeof r.copy!="function"||typeof r.slice!="function"||r.length>0&&typeof r[0]!="number"?!1:!!(r.constructor&&r.constructor.isBuffer&&r.constructor.isBuffer(r))}function _i(r,e,a,t){if(X(r)!==X(e))return!1;for(var n=D(r),o=D(e),i,u,s;(i=n.next())&&!i.done;)if(i.value&&typeof i.value=="object")s||(s=new J),re(s,i.value);else if(!te(e,i.value)){if(a.strict||!Bi(r,e,i.value))return!1;s||(s=new J),re(s,i.value)}if(s){for(;(u=o.next())&&!u.done;)if(u.value&&typeof u.value=="object"){if(!Br(s,u.value,a.strict,t))return!1}else if(!a.strict&&!te(r,u.value)&&!Br(s,u.value,a.strict,t))return!1;return X(s)===0}return!0}function Ei(r,e,a,t){if(jr(r)!==jr(e))return!1;for(var n=D(r),o=D(e),i,u,s,l,y,v;(i=n.next())&&!i.done;)if(l=i.value[0],y=i.value[1],l&&typeof l=="object")s||(s=new J),re(s,l);else if(v=ee(e,l),typeof v>"u"&&!Pe(e,l)||!b(y,v,a,t)){if(a.strict||!ji(r,e,l,y,a,t))return!1;s||(s=new J),re(s,l)}if(s){for(;(u=o.next())&&!u.done;)if(l=u.value[0],v=u.value[1],l&&typeof l=="object"){if(!_r(s,r,l,v,a,t))return!1}else if(!a.strict&&(!r.has(l)||!b(ee(r,l),v,a,t))&&!_r(s,r,l,v,ht({},a,{strict:!1}),t))return!1;return X(s)===0}return!0}function Ai(r,e,a,t){var n,o;if(typeof r!=typeof e||r==null||e==null||Or(r)!==Or(e)||cr(r)!==cr(e))return!1;var i=pr(r),u=pr(e);if(i!==u)return!1;var s=r instanceof Error,l=e instanceof Error;if(s!==l||(s||l)&&(r.name!==e.name||r.message!==e.message))return!1;var y=gr(r),v=gr(e);if(y!==v||(y||v)&&(r.source!==e.source||ur(r)!==ur(e)))return!1;var p=yr(r),c=yr(e);if(p!==c||(p||c)&&Pr(r)!==Pr(e)||a.strict&&de&&de(r)!==de(e))return!1;var B=Sr(r),_=Sr(e);if(B!==_)return!1;if(B||_){if(r.length!==e.length)return!1;for(n=0;n<r.length;n++)if(r[n]!==e[n])return!1;return!0}var E=Er(r),M=Er(e);if(E!==M)return!1;if(E||M){if(r.length!==e.length)return!1;for(n=0;n<r.length;n++)if(r[n]!==e[n])return!1;return!0}var S=vr(r),k=vr(e);if(S!==k)return!1;if(S||k)return wr(r)!==wr(e)?!1:typeof Uint8Array=="function"&&b(new Uint8Array(r),new Uint8Array(e),a,t);var O=mr(r),j=mr(e);if(O!==j)return!1;if(O||j)return $r(r)!==$r(e)?!1:typeof Uint8Array=="function"&&b(new Uint8Array(r),new Uint8Array(e),a,t);if(typeof r!=typeof e)return!1;var m=dr(r),A=dr(e);if(m.length!==A.length)return!1;for(m.sort(),A.sort(),n=m.length-1;n>=0;n--)if(m[n]!=A[n])return!1;for(n=m.length-1;n>=0;n--)if(o=m[n],!b(r[o],e[o],a,t))return!1;var d=br(r),H=br(e);return d!==H?!1:d==="Set"||H==="Set"?_i(r,e,a,t):d==="Map"?Ei(r,e,a,t):!0}var Ii=function(e,a,t){return b(e,a,t,Oi())},oe={};Object.defineProperty(oe,"__esModule",{value:!0});function wt(){let r,e;const a=new Promise((t,n)=>{r=o=>{t(o),a.isPending=!1},e=o=>{n(o),a.isPending=!1}}).catch(t=>Promise.reject(t));return a.resolve=r,a.reject=e,"finally"in a||(a.finally=t=>{a.then(t),a.catch(t)}),a.isPending=!0,a}oe.future=wt;oe.default=wt;function Mi(r){return{all:r=r||new Map,on:function(e,a){var t=r.get(e);t?t.push(a):r.set(e,[a])},off:function(e,a){var t=r.get(e);t&&(a?t.splice(t.indexOf(a)>>>0,1):r.set(e,[]))},emit:function(e,a){var t=r.get(e);t&&t.slice().map(function(n){n(a)}),(t=r.get("*"))&&t.slice().map(function(n){n(e,a)})}}}const ki=Object.freeze(Object.defineProperty({__proto__:null,default:Mi},Symbol.toStringTag,{value:"Module"}));var Me={},ie={},Di=g&&g.__spreadArray||function(r,e,a){if(a||arguments.length===2)for(var t=0,n=e.length,o;t<n;t++)(o||!(t in e))&&(o||(o=Array.prototype.slice.call(e,0,t)),o[t]=e[t]);return r.concat(o||Array.prototype.slice.call(e))};Object.defineProperty(ie,"__esModule",{value:!0});ie.createDebounce=void 0;function Ti(){var r=null;return function(e,a){for(var t=[],n=2;n<arguments.length;n++)t[n-2]=arguments[n];r&&clearTimeout(r),r=setTimeout.apply(void 0,Di([e,a],t,!1))}}ie.createDebounce=Ti;var se={};const xi=za(ki);var $t=g&&g.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(se,"__esModule",{value:!0});se.createController=void 0;var Wi=$t(xi),Ci=$t(oe),ae=Tr,Pt=new Map,Oe=new Map;window.onmessage=function(e){if(e.data&&e.data.type)switch(e.data.type){case ae.PreviewMessageType.CONTROLLER_RESPONSE:{var a=e.data.payload,t=a.id,n=Pt.get(t);n&&(a.ok?n.resolve(a.result):a.ok===!1&&n.reject(new Error(a.error)));break}case ae.PreviewMessageType.EMOTE_EVENT:{var a=e.data.payload,o=a.type,i=a.payload,u=Oe.get(e.source);u&&o&&u.emit(o,i);break}}};var Ar=0;function Ri(r){return function(a,t,n){var o=document.getElementById(r),i=r+"-"+Ar,u=(0,Ci.default)();Pt.set(i,u);var s=ae.PreviewMessageType.CONTROLLER_REQUEST,l={id:i,namespace:a,method:t,params:n};return(0,ae.sendMessage)(o.contentWindow,s,l),Ar++,u}}function Ui(r){var e,a=document.getElementById(r);if(!a)throw new Error('Could not find an iframe with id="'.concat(r,'"'));var t=(e=Oe.get(a.contentWindow))!==null&&e!==void 0?e:(0,Wi.default)();Oe.set(a.contentWindow,t);var n=Ri(r);return{scene:{getScreenshot:function(o,i){return n("scene","getScreenshot",[o,i])},getMetrics:function(){return n("scene","getMetrics",[])},changeZoom:function(o){return n("scene","changeZoom",[o])},panCamera:function(o){return n("scene","panCamera",[o])},changeCameraPosition:function(o){return n("scene","changeCameraPosition",[o])},setUsername:function(o){return n("scene","setUsername",[o])},cleanup:function(){return n("scene","cleanup",[])}},emote:{getLength:function(){return n("emote","getLength",[])},isPlaying:function(){return n("emote","isPlaying",[])},goTo:function(o){return n("emote","goTo",[o])},play:function(){return n("emote","play",[])},pause:function(){return n("emote","pause",[])},stop:function(){return n("emote","stop",[])},enableSound:function(){return n("emote","enableSound",[])},disableSound:function(){return n("emote","disableSound",[])},hasSound:function(){return n("emote","hasSound",[])},isSocialEmote:function(){return n("emote","isSocialEmote",[])},getSocialEmoteAnimations:function(){return n("emote","getSocialEmoteAnimations",[])},getPlayingSocialEmoteAnimation:function(){return n("emote","getPlayingSocialEmoteAnimation",[])},emote:null,events:t}}}se.createController=Ui;var Li=g&&g.__extends||function(){var r=function(e,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])},r(e,a)};return function(e,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(e,a);function t(){this.constructor=e}e.prototype=a===null?Object.create(a):(t.prototype=a.prototype,new t)}}(),Ni=g&&g.__createBinding||(Object.create?function(r,e,a,t){t===void 0&&(t=a);var n=Object.getOwnPropertyDescriptor(e,a);(!n||("get"in n?!e.__esModule:n.writable||n.configurable))&&(n={enumerable:!0,get:function(){return e[a]}}),Object.defineProperty(r,t,n)}:function(r,e,a,t){t===void 0&&(t=a),r[t]=e[a]}),Fi=g&&g.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),Hi=g&&g.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var a in r)a!=="default"&&Object.prototype.hasOwnProperty.call(r,a)&&Ni(e,r,a);return Fi(e,r),e},qi=g&&g.__rest||function(r,e){var a={};for(var t in r)Object.prototype.hasOwnProperty.call(r,t)&&e.indexOf(t)<0&&(a[t]=r[t]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,t=Object.getOwnPropertySymbols(r);n<t.length;n++)e.indexOf(t[n])<0&&Object.prototype.propertyIsEnumerable.call(r,t[n])&&(a[t[n]]=r[t[n]]);return a},Zi=g&&g.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Me,"__esModule",{value:!0});var je=Me.WearablePreview=void 0,Ir=Hi(R),zi=Zi(Ii),C=Tr,Yi=ie,Xi=se,Gi=Ya,Ki=(0,Yi.createDebounce)(),f=function(r,e){return e==null||e===""?"":Array.isArray(e)?e.length>0?e.map(function(a){return"".concat(r,"=").concat(encodeURIComponent(String(a)))}).join("&"):"":"".concat(r,"=").concat(encodeURIComponent(String(e)))},Vi=function(r){Li(e,r);function e(){var a=r!==null&&r.apply(this,arguments)||this;return a.state={isReady:!1,pendingOptions:null,lastOptions:null},a.iframe=null,a.getUrl=function(){var t=a.props,n=t.contractAddress,o=t.tokenId,i=t.itemId,u=t.profile,s=t.urns,l=t.urls,y=t.base64s,v=t.skin,p=t.hair,c=t.eyes,B=t.bodyShape,_=t.emote,E=t.camera,M=t.projection,S=t.zoom,k=t.background,O=t.offsetX,j=t.offsetY,m=t.offsetZ,A=t.cameraX,d=t.cameraY,H=t.cameraZ,Ot=t.wheelZoom,jt=t.wheelPrecision,Bt=t.wheelStart,_t=t.disableBackground,Et=t.disableAutoRotate,At=t.disableAutoCenter,It=t.disableFace,Mt=t.disableDefaultWearables,kt=t.disableDefaultEmotes,Dt=t.disableFadeEffect,Tt=t.showSceneBoundaries,xt=t.showThumbnailBoundaries,Wt=t.panning,Ct=t.lockAlpha,Rt=t.lockBeta,Ut=t.lockRadius,Lt=t.dev,Nt=t.baseUrl,Ft=t.peerUrl,Ht=t.nftServerUrl,fe=t.marketplaceServerUrl,qt=t.type,Zt=t.unity,zt=t.unityMode,Yt=f("contract",n),Xt=f("token",o),Gt=f("item",i),Kt=f("profile",u),Vt=f("urn",s),Qt=f("url",l),Jt=f("base64",y),ea=f("skin",v),ra=f("hair",p),ta=f("eyes",c),aa=f("bodyShape",B),na=f("emote",_),oa=f("camera",E),ia=f("projection",M),sa=f("zoom",S),fa=f("background",k),ua=f("offsetX",O),la=f("offsetY",j),ca=f("offsetZ",m),pa=f("cameraX",A),va=f("cameraY",d),ya=f("cameraZ",H),ga=f("wheelZoom",Ot),ma=f("wheelPrecision",jt),da=f("wheelStart",Bt),ha=f("disableBackground",_t),ba=f("disableAutoRotate",Et),Sa=f("disableAutoCenter",At),wa=f("disableFace",It),$a=f("disableDefaultWearables",Mt),Pa=f("disableDefaultEmotes",kt),Oa=f("disableFadeEffect",Dt),ja=f("showSceneBoundaries",Tt),Ba=f("showThumbnailBoundaries",xt),_a=f("peerUrl",Ft),Ea=fe??Ht,Aa=f("marketplaceServerUrl",Ea),Ia=f("type",qt),Ma=f("panning",Wt),ka=f("lockAlpha",Ct),Da=f("lockBeta",Rt),Ta=f("lockRadius",Ut),xa=f("env",Lt?"dev":void 0),Wa=f("unity",Zt),Ca=f("mode",zt),Ra=Nt+"?"+[Yt,Xt,Gt,Kt,Vt,Qt,Jt,ea,ra,ta,aa,na,oa,ia,sa,fa,ua,la,ca,pa,va,ya,ga,ma,da,ha,ba,Sa,wa,$a,Pa,Oa,ja,Ba,_a,Aa,Ia,Ma,ka,Da,Ta,xa,Wa,Ca].filter(function(Ua){return!!Ua}).join("&");return Ra},a.getOptions=function(){var t=a.props;t.dev;var n=qi(t,["dev"]),o={};for(var i in n)typeof n[i]!="function"&&(o[i]=n[i]);return o},a.handleMessage=function(t){var n=a.props,o=n.baseUrl,i=n.onLoad,u=n.onError,s=t.origin;if(s===o&&t.data&&t.data.type){var l=t.data.type;switch(l){case C.PreviewMessageType.LOAD:{var y=t.data.payload;i(y==null?void 0:y.renderer);break}case C.PreviewMessageType.ERROR:{var y=t.data.payload;u(new Error(y.message));break}case C.PreviewMessageType.READY:{var v=a.state,p=v.isReady,c=v.pendingOptions;if(p)return;c!==null?(a.sendUpdate(c),a.setState({isReady:!0,pendingOptions:null})):a.setState({isReady:!0});break}}}},a.handleUpdate=function(){if(a.iframe){if(window){var t=a.getOptions();a.state.isReady?a.sendUpdate(t):a.setState({pendingPreviewOptions:t})}}else console.warn("Could not send update, iframe is not referenced")},a.sendUpdate=function(t){var n=a.state.lastOptions;if(!n||!(0,zi.default)(t,n)){(0,C.sendMessage)(a.iframe.contentWindow,C.PreviewMessageType.UPDATE,{options:t});var o=a.props.onUpdate;o(t),a.setState({lastOptions:t})}},a.refIframe=function(t){a.iframe=t},a}return e.createController=function(a){return(0,Xi.createController)(a)},e.prototype.componentDidMount=function(){window.addEventListener("message",this.handleMessage,!1),this.setState({url:this.getUrl()}),this.props.blob&&this.handleUpdate()},e.prototype.componentWillUnmount=function(){window.removeEventListener("message",this.handleMessage,!1)},e.prototype.componentDidUpdate=function(){Ki(this.handleUpdate,500)},e.prototype.render=function(){return this.props.tokenId&&this.props.itemId&&console.warn("You should NOT use `tokenId` and `itemId` props simultaneously"),Ir.createElement("iframe",{id:this.props.id,className:"WearablePreview",src:this.state.url,width:"100%",height:"100%",frameBorder:"0",ref:this.refIframe,allow:"autoplay"})},e.defaultProps={dev:!1,baseUrl:Gi.config.get("WEARABLE_PREVIEW_URL"),unity:!1,onLoad:function(){},onError:function(){},onUpdate:function(){}},e}(Ir.PureComponent);je=Me.WearablePreview=Vi;function ts({address:r}){const[e,a]=R.useState(),{profile:t}=Xa(r),n=R.useCallback(()=>{a(je.createController("wearable-preview"))},[]),o=R.useMemo(()=>{const i=[T.PreviewEmote.DAB,T.PreviewEmote.FIST_PUMP,T.PreviewEmote.DANCE,T.PreviewEmote.HEAD_EXPLODE];return i[Math.random()*i.length|0]},[]);return R.useEffect(()=>{const i=setInterval(()=>{e&&e.emote.play()},2e4);return()=>clearInterval(i)},[e]),!r||!t.hasCustomAvatar?null:ke.jsx("div",{className:"UserAvatar__Container",children:ke.jsx(je,{id:"wearable-preview",profile:r,onLoad:n,background:"FFFFFF",emote:o,disableAutoRotate:!0,camera:T.PreviewCamera.STATIC})})}export{ts as default};
|
|
1
|
+
import{Z as Mr,c as w,a5 as La,U as N,t as Be,a as Na,a6 as Fa,$ as Ha,h as qa,a7 as kr,T as Za,a8 as Dr,b as ue,_ as g,a9 as za,aa as Tr,ab as R,ac as Ya,ad as Xa,ae as T,af as ke}from"./index-d1b7c41c.js";import{h as xr,d as Wr,c as F,s as ne,w as Ga}from"./index-016592b7.js";import{i as Cr,r as Ka,a as Va}from"./index-6dc60c34.js";import{i as Rr}from"./index-980812a4.js";var De=Object.prototype.toString,Ur=function(e){var a=De.call(e),t=a==="[object Arguments]";return t||(t=a!=="[object Array]"&&e!==null&&typeof e=="object"&&typeof e.length=="number"&&e.length>=0&&De.call(e.callee)==="[object Function]"),t},le,Te;function Qa(){if(Te)return le;Te=1;var r;if(!Object.keys){var e=Object.prototype.hasOwnProperty,a=Object.prototype.toString,t=Ur,n=Object.prototype.propertyIsEnumerable,o=!n.call({toString:null},"toString"),i=n.call(function(){},"prototype"),u=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],s=function(p){var c=p.constructor;return c&&c.prototype===p},l={$applicationCache:!0,$console:!0,$external:!0,$frame:!0,$frameElement:!0,$frames:!0,$innerHeight:!0,$innerWidth:!0,$onmozfullscreenchange:!0,$onmozfullscreenerror:!0,$outerHeight:!0,$outerWidth:!0,$pageXOffset:!0,$pageYOffset:!0,$parent:!0,$scrollLeft:!0,$scrollTop:!0,$scrollX:!0,$scrollY:!0,$self:!0,$webkitIndexedDB:!0,$webkitStorageInfo:!0,$window:!0},y=function(){if(typeof window>"u")return!1;for(var p in window)try{if(!l["$"+p]&&e.call(window,p)&&window[p]!==null&&typeof window[p]=="object")try{s(window[p])}catch{return!0}}catch{return!0}return!1}(),v=function(p){if(typeof window>"u"||!y)return s(p);try{return s(p)}catch{return!1}};r=function(c){var B=c!==null&&typeof c=="object",_=a.call(c)==="[object Function]",E=t(c),M=B&&a.call(c)==="[object String]",S=[];if(!B&&!_&&!E)throw new TypeError("Object.keys called on a non-object");var k=i&&_;if(M&&c.length>0&&!e.call(c,0))for(var O=0;O<c.length;++O)S.push(String(O));if(E&&c.length>0)for(var j=0;j<c.length;++j)S.push(String(j));else for(var m in c)!(k&&m==="prototype")&&e.call(c,m)&&S.push(String(m));if(o)for(var A=v(c),d=0;d<u.length;++d)!(A&&u[d]==="constructor")&&e.call(c,u[d])&&S.push(u[d]);return S}}return le=r,le}var Ja=Array.prototype.slice,en=Ur,xe=Object.keys,q=xe?function(e){return xe(e)}:Qa(),We=Object.keys;q.shim=function(){if(Object.keys){var e=function(){var a=Object.keys(arguments);return a&&a.length===arguments.length}(1,2);e||(Object.keys=function(t){return en(t)?We(Ja.call(t)):We(t)})}else Object.keys=q;return Object.keys||q};var _e=q,rn=_e,tn=typeof Symbol=="function"&&typeof Symbol("foo")=="symbol",an=Object.prototype.toString,nn=Array.prototype.concat,Ce=Wr,on=function(r){return typeof r=="function"&&an.call(r)==="[object Function]"},Lr=xr(),sn=function(r,e,a,t){if(e in r){if(t===!0){if(r[e]===a)return}else if(!on(t)||!t())return}Lr?Ce(r,e,a,!0):Ce(r,e,a)},Nr=function(r,e){var a=arguments.length>2?arguments[2]:{},t=rn(e);tn&&(t=nn.call(t,Object.getOwnPropertySymbols(e)));for(var n=0;n<t.length;n+=1)sn(r,t[n],e[t[n]],a[t[n]])};Nr.supportsDescriptors=!!Lr;var I=Nr,fn=_e,Fr=Mr(),Hr=w,Z=La,un=Hr("Array.prototype.push"),Re=Hr("Object.prototype.propertyIsEnumerable"),ln=Fr?Z.getOwnPropertySymbols:null,qr=function(e,a){if(e==null)throw new TypeError("target must be an object");var t=Z(e);if(arguments.length===1)return t;for(var n=1;n<arguments.length;++n){var o=Z(arguments[n]),i=fn(o),u=Fr&&(Z.getOwnPropertySymbols||ln);if(u)for(var s=u(o),l=0;l<s.length;++l){var y=s[l];Re(o,y)&&un(i,y)}for(var v=0;v<i.length;++v){var p=i[v];if(Re(o,p)){var c=o[p];t[p]=c}}}return t},ce=qr,cn=function(){if(!Object.assign)return!1;for(var r="abcdefghijklmnopqrst",e=r.split(""),a={},t=0;t<e.length;++t)a[e[t]]=e[t];var n=Object.assign({},a),o="";for(var i in n)o+=i;return r!==o},pn=function(){if(!Object.assign||!Object.preventExtensions)return!1;var r=Object.preventExtensions({1:2});try{Object.assign(r,"xy")}catch{return r[1]==="y"}return!1},Zr=function(){return!Object.assign||cn()||pn()?ce:Object.assign},vn=I,yn=Zr,gn=function(){var e=yn();return vn(Object,{assign:e},{assign:function(){return Object.assign!==e}}),e},mn=I,dn=F,hn=qr,zr=Zr,bn=gn,Sn=dn.apply(zr()),Yr=function(e,a){return Sn(Object,arguments)};mn(Yr,{getPolyfill:zr,implementation:hn,shim:bn});var wn=Yr,Xr=N,Gr=F,$n=Gr(Xr("String.prototype.indexOf")),Kr=function(e,a){var t=Xr(e,!!a);return typeof t=="function"&&$n(e,".prototype.")>-1?Gr(t):t},L=function(){return typeof(function(){}).name=="string"},U=Object.getOwnPropertyDescriptor;if(U)try{U([],"length")}catch{U=null}L.functionsHaveConfigurableNames=function(){if(!L()||!U)return!1;var e=U(function(){},"name");return!!e&&!!e.configurable};var Pn=Function.prototype.bind;L.boundFunctionsHaveNames=function(){return L()&&typeof Pn=="function"&&(function(){}).bind().name!==""};var On=L,Ue=Wr,jn=xr(),Bn=On.functionsHaveConfigurableNames(),_n=Be,En=function(e,a){if(typeof e!="function")throw new _n("`fn` is not a function");var t=arguments.length>2&&!!arguments[2];return(!t||Bn)&&(jn?Ue(e,"name",a,!0,!0):Ue(e,"name",a)),e},An=En,In=Be,Mn=Object,Vr=An(function(){if(this==null||this!==Mn(this))throw new In("RegExp.prototype.flags getter called on non-object");var e="";return this.hasIndices&&(e+="d"),this.global&&(e+="g"),this.ignoreCase&&(e+="i"),this.multiline&&(e+="m"),this.dotAll&&(e+="s"),this.unicode&&(e+="u"),this.unicodeSets&&(e+="v"),this.sticky&&(e+="y"),e},"get flags",!0),kn=Vr,Dn=I.supportsDescriptors,Tn=Object.getOwnPropertyDescriptor,Qr=function(){if(Dn&&/a/mig.flags==="gim"){var e=Tn(RegExp.prototype,"flags");if(e&&typeof e.get=="function"&&"dotAll"in RegExp.prototype&&"hasIndices"in RegExp.prototype){var a="",t={};if(Object.defineProperty(t,"hasIndices",{get:function(){a+="d"}}),Object.defineProperty(t,"sticky",{get:function(){a+="y"}}),e.get.call(t),a==="dy")return e.get}}return kn},xn=I.supportsDescriptors,Wn=Qr,Cn=Na,Rn=Object.defineProperty,Un=Fa,Le=Ha,Ln=/a/,Nn=function(){if(!xn||!Le)throw new Un("RegExp.prototype.flags requires a true ES5 environment that supports property descriptors");var e=Wn(),a=Le(Ln),t=Cn(a,"flags");return(!t||t.get!==e)&&Rn(a,"flags",{configurable:!0,enumerable:!1,get:e}),e},Fn=I,Hn=F,qn=Vr,Jr=Qr,Zn=Nn,et=Hn(Jr());Fn(et,{getPolyfill:Jr,implementation:qn,shim:Zn});var zn=et,z={exports:{}},Yn=qa,x=kr(),P=Be,Ee={assert:function(r,e){if(!r||typeof r!="object"&&typeof r!="function")throw new P("`O` is not an object");if(typeof e!="string")throw new P("`slot` must be a string");if(x.assert(r),!Ee.has(r,e))throw new P("`"+e+"` is not present on `O`")},get:function(r,e){if(!r||typeof r!="object"&&typeof r!="function")throw new P("`O` is not an object");if(typeof e!="string")throw new P("`slot` must be a string");var a=x.get(r);return a&&a["$"+e]},has:function(r,e){if(!r||typeof r!="object"&&typeof r!="function")throw new P("`O` is not an object");if(typeof e!="string")throw new P("`slot` must be a string");var a=x.get(r);return!!a&&Yn(a,"$"+e)},set:function(r,e,a){if(!r||typeof r!="object"&&typeof r!="function")throw new P("`O` is not an object");if(typeof e!="string")throw new P("`slot` must be a string");var t=x.get(r);t||(t={},x.set(r,t)),t["$"+e]=a}};Object.freeze&&Object.freeze(Ee);var Xn=Ee,W=Xn,Gn=Za,Ne=typeof StopIteration=="object"?StopIteration:null,Kn=function(e){if(!Ne)throw new Gn("this environment lacks StopIteration");W.set(e,"[[Done]]",!1);var a={next:function(){var n=W.get(this,"[[Iterator]]"),o=!!W.get(n,"[[Done]]");try{return{done:o,value:o?void 0:n.next()}}catch(i){if(W.set(n,"[[Done]]",!0),i!==Ne)throw i;return{done:!0,value:void 0}}}};return W.set(a,"[[Iterator]]",e),a},rt=w,Vn=rt("String.prototype.valueOf"),Qn=function(e){try{return Vn(e),!0}catch{return!1}},Jn=rt("Object.prototype.toString"),eo="[object String]",ro=ne(),tt=function(e){return typeof e=="string"?!0:!e||typeof e!="object"?!1:ro?Qn(e):Jn(e)===eo},Ae=typeof Map=="function"&&Map.prototype?Map:null,to=typeof Set=="function"&&Set.prototype?Set:null,G;Ae||(G=function(e){return!1});var at=Ae?Map.prototype.has:null,Fe=to?Set.prototype.has:null;!G&&!at&&(G=function(e){return!1});var nt=G||function(e){if(!e||typeof e!="object")return!1;try{if(at.call(e),Fe)try{Fe.call(e)}catch{return!0}return e instanceof Ae}catch{}return!1},ao=typeof Map=="function"&&Map.prototype?Map:null,Ie=typeof Set=="function"&&Set.prototype?Set:null,K;Ie||(K=function(e){return!1});var He=ao?Map.prototype.has:null,ot=Ie?Set.prototype.has:null;!K&&!ot&&(K=function(e){return!1});var it=K||function(e){if(!e||typeof e!="object")return!1;try{if(ot.call(e),He)try{He.call(e)}catch{return!0}return e instanceof Ie}catch{}return!1},qe=Cr,Ze=Kn;if(Dr()||Mr()){var pe=Symbol.iterator;z.exports=function(e){if(e!=null&&typeof e[pe]<"u")return e[pe]();if(qe(e))return Array.prototype[pe].call(e)}}else{var no=Rr,oo=tt,ze=N,io=ze("%Map%",!0),so=ze("%Set%",!0),h=Kr,Ye=h("Array.prototype.push"),Xe=h("String.prototype.charCodeAt"),fo=h("String.prototype.slice"),uo=function(e,a){var t=e.length;if(a+1>=t)return a+1;var n=Xe(e,a);if(n<55296||n>56319)return a+1;var o=Xe(e,a+1);return o<56320||o>57343?a+1:a+2},ve=function(e){var a=0;return{next:function(){var n=a>=e.length,o;return n||(o=e[a],a+=1),{done:n,value:o}}}},Ge=function(e,a){if(no(e)||qe(e))return ve(e);if(oo(e)){var t=0;return{next:function(){var o=uo(e,t),i=fo(e,t,o);return t=o,{done:o>e.length,value:i}}}}if(a&&typeof e["_es6-shim iterator_"]<"u")return e["_es6-shim iterator_"]()};if(!io&&!so)z.exports=function(e){if(e!=null)return Ge(e,!0)};else{var lo=nt,co=it,Ke=h("Map.prototype.forEach",!0),Ve=h("Set.prototype.forEach",!0);if(typeof ue>"u"||!ue.versions||!ue.versions.node)var Qe=h("Map.prototype.iterator",!0),Je=h("Set.prototype.iterator",!0);var er=h("Map.prototype.@@iterator",!0)||h("Map.prototype._es6-shim iterator_",!0),rr=h("Set.prototype.@@iterator",!0)||h("Set.prototype._es6-shim iterator_",!0),po=function(e){if(lo(e)){if(Qe)return Ze(Qe(e));if(er)return er(e);if(Ke){var a=[];return Ke(e,function(n,o){Ye(a,[o,n])}),ve(a)}}if(co(e)){if(Je)return Ze(Je(e));if(rr)return rr(e);if(Ve){var t=[];return Ve(e,function(n){Ye(t,n)}),ve(t)}}};z.exports=function(e){return po(e)||Ge(e)}}}var vo=z.exports,tr=function(r){return r!==r},st=function(e,a){return e===0&&a===0?1/e===1/a:!!(e===a||tr(e)&&tr(a))},yo=st,ft=function(){return typeof Object.is=="function"?Object.is:yo},go=ft,mo=I,ho=function(){var e=go();return mo(Object,{is:e},{is:function(){return Object.is!==e}}),e},bo=I,So=F,wo=st,ut=ft,$o=ho,lt=So(ut(),Object);bo(lt,{getPolyfill:ut,implementation:wo,shim:$o});var Po=lt,Oo=F,ct=w,jo=N,he=jo("%ArrayBuffer%",!0),Y=ct("ArrayBuffer.prototype.byteLength",!0),Bo=ct("Object.prototype.toString"),ar=!!he&&!Y&&new he(0).slice,nr=!!ar&&Oo(ar),pt=Y||nr?function(e){if(!e||typeof e!="object")return!1;try{return Y?Y(e):nr(e,0),!0}catch{return!1}}:he?function(e){return Bo(e)==="[object ArrayBuffer]"}:function(e){return!1},vt=w,_o=vt("Date.prototype.getDay"),Eo=function(e){try{return _o(e),!0}catch{return!1}},Ao=vt("Object.prototype.toString"),Io="[object Date]",Mo=ne(),ko=function(e){return typeof e!="object"||e===null?!1:Mo?Eo(e):Ao(e)===Io},Do=w,or=Do("SharedArrayBuffer.prototype.byteLength",!0),To=or?function(e){if(!e||typeof e!="object")return!1;try{return or(e),!0}catch{return!1}}:function(e){return!1},yt=w,xo=yt("Number.prototype.toString"),Wo=function(e){try{return xo(e),!0}catch{return!1}},Co=yt("Object.prototype.toString"),Ro="[object Number]",Uo=ne(),Lo=function(e){return typeof e=="number"?!0:!e||typeof e!="object"?!1:Uo?Wo(e):Co(e)===Ro},gt=w,No=gt("Boolean.prototype.toString"),Fo=gt("Object.prototype.toString"),Ho=function(e){try{return No(e),!0}catch{return!1}},qo="[object Boolean]",Zo=ne(),zo=function(e){return typeof e=="boolean"?!0:e===null||typeof e!="object"?!1:Zo?Ho(e):Fo(e)===qo},be={exports:{}},mt=w,Yo=mt("Object.prototype.toString"),Xo=Dr(),Go=Ka();if(Xo){var Ko=mt("Symbol.prototype.toString"),Vo=Go(/^Symbol\(.*\)$/),Qo=function(e){return typeof e.valueOf()!="symbol"?!1:Vo(Ko(e))};be.exports=function(e){if(typeof e=="symbol")return!0;if(!e||typeof e!="object"||Yo(e)!=="[object Symbol]")return!1;try{return Qo(e)}catch{return!1}}}else be.exports=function(e){return!1};var Jo=be.exports,Se={exports:{}},ir=typeof BigInt<"u"&&BigInt,ei=function(){return typeof ir=="function"&&typeof BigInt=="function"&&typeof ir(42)=="bigint"&&typeof BigInt(42)=="bigint"},ri=ei();if(ri){var ti=BigInt.prototype.valueOf,ai=function(e){try{return ti.call(e),!0}catch{}return!1};Se.exports=function(e){return e===null||typeof e>"u"||typeof e=="boolean"||typeof e=="string"||typeof e=="number"||typeof e=="symbol"||typeof e=="function"?!1:typeof e=="bigint"?!0:ai(e)}}else Se.exports=function(e){return!1};var ni=Se.exports,oi=tt,ii=Lo,si=zo,fi=Jo,ui=ni,li=function(e){if(e==null||typeof e!="object"&&typeof e!="function")return null;if(oi(e))return"String";if(ii(e))return"Number";if(si(e))return"Boolean";if(fi(e))return"Symbol";if(ui(e))return"BigInt"},V=typeof WeakMap=="function"&&WeakMap.prototype?WeakMap:null,sr=typeof WeakSet=="function"&&WeakSet.prototype?WeakSet:null,Q;V||(Q=function(e){return!1});var we=V?V.prototype.has:null,ye=sr?sr.prototype.has:null;!Q&&!we&&(Q=function(e){return!1});var ci=Q||function(e){if(!e||typeof e!="object")return!1;try{if(we.call(e,we),ye)try{ye.call(e,ye)}catch{return!0}return e instanceof V}catch{}return!1},$e={exports:{}},pi=N,dt=w,vi=pi("%WeakSet%",!0),ge=dt("WeakSet.prototype.has",!0);if(ge){var me=dt("WeakMap.prototype.has",!0);$e.exports=function(e){if(!e||typeof e!="object")return!1;try{if(ge(e,ge),me)try{me(e,me)}catch{return!0}return e instanceof vi}catch{}return!1}}else $e.exports=function(e){return!1};var yi=$e.exports,gi=nt,mi=it,di=ci,hi=yi,bi=function(e){if(e&&typeof e=="object"){if(gi(e))return"Map";if(mi(e))return"Set";if(di(e))return"WeakMap";if(hi(e))return"WeakSet"}return!1},Si=w,fr=Si("ArrayBuffer.prototype.byteLength",!0),wi=pt,$i=function(e){return wi(e)?fr?fr(e):e.byteLength:NaN},ht=wn,$=Kr,ur=zn,Pi=N,D=vo,Oi=kr,lr=Po,cr=Cr,pr=Rr,vr=pt,yr=ko,gr=Va,mr=To,dr=_e,hr=li,br=bi,Sr=Ga,wr=$i,$r=$("SharedArrayBuffer.prototype.byteLength",!0),Pr=$("Date.prototype.getTime"),de=Object.getPrototypeOf,Or=$("Object.prototype.toString"),J=Pi("%Set%",!0),Pe=$("Map.prototype.has",!0),ee=$("Map.prototype.get",!0),jr=$("Map.prototype.size",!0),re=$("Set.prototype.add",!0),bt=$("Set.prototype.delete",!0),te=$("Set.prototype.has",!0),X=$("Set.prototype.size",!0);function Br(r,e,a,t){for(var n=D(r),o;(o=n.next())&&!o.done;)if(b(e,o.value,a,t))return bt(r,o.value),!0;return!1}function St(r){if(typeof r>"u")return null;if(typeof r!="object")return typeof r=="symbol"?!1:typeof r=="string"||typeof r=="number"?+r==+r:!0}function ji(r,e,a,t,n,o){var i=St(a);if(i!=null)return i;var u=ee(e,i),s=ht({},n,{strict:!1});return typeof u>"u"&&!Pe(e,i)||!b(t,u,s,o)?!1:!Pe(r,i)&&b(t,u,s,o)}function Bi(r,e,a){var t=St(a);return t??(te(e,t)&&!te(r,t))}function _r(r,e,a,t,n,o){for(var i=D(r),u,s;(u=i.next())&&!u.done;)if(s=u.value,b(a,s,n,o)&&b(t,ee(e,s),n,o))return bt(r,s),!0;return!1}function b(r,e,a,t){var n=a||{};if(n.strict?lr(r,e):r===e)return!0;var o=hr(r),i=hr(e);if(o!==i)return!1;if(!r||!e||typeof r!="object"&&typeof e!="object")return n.strict?lr(r,e):r==e;var u=t.has(r),s=t.has(e),l;if(u&&s){if(t.get(r)===t.get(e))return!0}else l={};return u||t.set(r,l),s||t.set(e,l),Ai(r,e,n,t)}function Er(r){return!r||typeof r!="object"||typeof r.length!="number"||typeof r.copy!="function"||typeof r.slice!="function"||r.length>0&&typeof r[0]!="number"?!1:!!(r.constructor&&r.constructor.isBuffer&&r.constructor.isBuffer(r))}function _i(r,e,a,t){if(X(r)!==X(e))return!1;for(var n=D(r),o=D(e),i,u,s;(i=n.next())&&!i.done;)if(i.value&&typeof i.value=="object")s||(s=new J),re(s,i.value);else if(!te(e,i.value)){if(a.strict||!Bi(r,e,i.value))return!1;s||(s=new J),re(s,i.value)}if(s){for(;(u=o.next())&&!u.done;)if(u.value&&typeof u.value=="object"){if(!Br(s,u.value,a.strict,t))return!1}else if(!a.strict&&!te(r,u.value)&&!Br(s,u.value,a.strict,t))return!1;return X(s)===0}return!0}function Ei(r,e,a,t){if(jr(r)!==jr(e))return!1;for(var n=D(r),o=D(e),i,u,s,l,y,v;(i=n.next())&&!i.done;)if(l=i.value[0],y=i.value[1],l&&typeof l=="object")s||(s=new J),re(s,l);else if(v=ee(e,l),typeof v>"u"&&!Pe(e,l)||!b(y,v,a,t)){if(a.strict||!ji(r,e,l,y,a,t))return!1;s||(s=new J),re(s,l)}if(s){for(;(u=o.next())&&!u.done;)if(l=u.value[0],v=u.value[1],l&&typeof l=="object"){if(!_r(s,r,l,v,a,t))return!1}else if(!a.strict&&(!r.has(l)||!b(ee(r,l),v,a,t))&&!_r(s,r,l,v,ht({},a,{strict:!1}),t))return!1;return X(s)===0}return!0}function Ai(r,e,a,t){var n,o;if(typeof r!=typeof e||r==null||e==null||Or(r)!==Or(e)||cr(r)!==cr(e))return!1;var i=pr(r),u=pr(e);if(i!==u)return!1;var s=r instanceof Error,l=e instanceof Error;if(s!==l||(s||l)&&(r.name!==e.name||r.message!==e.message))return!1;var y=gr(r),v=gr(e);if(y!==v||(y||v)&&(r.source!==e.source||ur(r)!==ur(e)))return!1;var p=yr(r),c=yr(e);if(p!==c||(p||c)&&Pr(r)!==Pr(e)||a.strict&&de&&de(r)!==de(e))return!1;var B=Sr(r),_=Sr(e);if(B!==_)return!1;if(B||_){if(r.length!==e.length)return!1;for(n=0;n<r.length;n++)if(r[n]!==e[n])return!1;return!0}var E=Er(r),M=Er(e);if(E!==M)return!1;if(E||M){if(r.length!==e.length)return!1;for(n=0;n<r.length;n++)if(r[n]!==e[n])return!1;return!0}var S=vr(r),k=vr(e);if(S!==k)return!1;if(S||k)return wr(r)!==wr(e)?!1:typeof Uint8Array=="function"&&b(new Uint8Array(r),new Uint8Array(e),a,t);var O=mr(r),j=mr(e);if(O!==j)return!1;if(O||j)return $r(r)!==$r(e)?!1:typeof Uint8Array=="function"&&b(new Uint8Array(r),new Uint8Array(e),a,t);if(typeof r!=typeof e)return!1;var m=dr(r),A=dr(e);if(m.length!==A.length)return!1;for(m.sort(),A.sort(),n=m.length-1;n>=0;n--)if(m[n]!=A[n])return!1;for(n=m.length-1;n>=0;n--)if(o=m[n],!b(r[o],e[o],a,t))return!1;var d=br(r),H=br(e);return d!==H?!1:d==="Set"||H==="Set"?_i(r,e,a,t):d==="Map"?Ei(r,e,a,t):!0}var Ii=function(e,a,t){return b(e,a,t,Oi())},oe={};Object.defineProperty(oe,"__esModule",{value:!0});function wt(){let r,e;const a=new Promise((t,n)=>{r=o=>{t(o),a.isPending=!1},e=o=>{n(o),a.isPending=!1}}).catch(t=>Promise.reject(t));return a.resolve=r,a.reject=e,"finally"in a||(a.finally=t=>{a.then(t),a.catch(t)}),a.isPending=!0,a}oe.future=wt;oe.default=wt;function Mi(r){return{all:r=r||new Map,on:function(e,a){var t=r.get(e);t?t.push(a):r.set(e,[a])},off:function(e,a){var t=r.get(e);t&&(a?t.splice(t.indexOf(a)>>>0,1):r.set(e,[]))},emit:function(e,a){var t=r.get(e);t&&t.slice().map(function(n){n(a)}),(t=r.get("*"))&&t.slice().map(function(n){n(e,a)})}}}const ki=Object.freeze(Object.defineProperty({__proto__:null,default:Mi},Symbol.toStringTag,{value:"Module"}));var Me={},ie={},Di=g&&g.__spreadArray||function(r,e,a){if(a||arguments.length===2)for(var t=0,n=e.length,o;t<n;t++)(o||!(t in e))&&(o||(o=Array.prototype.slice.call(e,0,t)),o[t]=e[t]);return r.concat(o||Array.prototype.slice.call(e))};Object.defineProperty(ie,"__esModule",{value:!0});ie.createDebounce=void 0;function Ti(){var r=null;return function(e,a){for(var t=[],n=2;n<arguments.length;n++)t[n-2]=arguments[n];r&&clearTimeout(r),r=setTimeout.apply(void 0,Di([e,a],t,!1))}}ie.createDebounce=Ti;var se={};const xi=za(ki);var $t=g&&g.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(se,"__esModule",{value:!0});se.createController=void 0;var Wi=$t(xi),Ci=$t(oe),ae=Tr,Pt=new Map,Oe=new Map;window.onmessage=function(e){if(e.data&&e.data.type)switch(e.data.type){case ae.PreviewMessageType.CONTROLLER_RESPONSE:{var a=e.data.payload,t=a.id,n=Pt.get(t);n&&(a.ok?n.resolve(a.result):a.ok===!1&&n.reject(new Error(a.error)));break}case ae.PreviewMessageType.EMOTE_EVENT:{var a=e.data.payload,o=a.type,i=a.payload,u=Oe.get(e.source);u&&o&&u.emit(o,i);break}}};var Ar=0;function Ri(r){return function(a,t,n){var o=document.getElementById(r),i=r+"-"+Ar,u=(0,Ci.default)();Pt.set(i,u);var s=ae.PreviewMessageType.CONTROLLER_REQUEST,l={id:i,namespace:a,method:t,params:n};return(0,ae.sendMessage)(o.contentWindow,s,l),Ar++,u}}function Ui(r){var e,a=document.getElementById(r);if(!a)throw new Error('Could not find an iframe with id="'.concat(r,'"'));var t=(e=Oe.get(a.contentWindow))!==null&&e!==void 0?e:(0,Wi.default)();Oe.set(a.contentWindow,t);var n=Ri(r);return{scene:{getScreenshot:function(o,i){return n("scene","getScreenshot",[o,i])},getMetrics:function(){return n("scene","getMetrics",[])},changeZoom:function(o){return n("scene","changeZoom",[o])},panCamera:function(o){return n("scene","panCamera",[o])},changeCameraPosition:function(o){return n("scene","changeCameraPosition",[o])},setUsername:function(o){return n("scene","setUsername",[o])},cleanup:function(){return n("scene","cleanup",[])}},emote:{getLength:function(){return n("emote","getLength",[])},isPlaying:function(){return n("emote","isPlaying",[])},goTo:function(o){return n("emote","goTo",[o])},play:function(){return n("emote","play",[])},pause:function(){return n("emote","pause",[])},stop:function(){return n("emote","stop",[])},enableSound:function(){return n("emote","enableSound",[])},disableSound:function(){return n("emote","disableSound",[])},hasSound:function(){return n("emote","hasSound",[])},isSocialEmote:function(){return n("emote","isSocialEmote",[])},getSocialEmoteAnimations:function(){return n("emote","getSocialEmoteAnimations",[])},getPlayingSocialEmoteAnimation:function(){return n("emote","getPlayingSocialEmoteAnimation",[])},emote:null,events:t}}}se.createController=Ui;var Li=g&&g.__extends||function(){var r=function(e,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])},r(e,a)};return function(e,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(e,a);function t(){this.constructor=e}e.prototype=a===null?Object.create(a):(t.prototype=a.prototype,new t)}}(),Ni=g&&g.__createBinding||(Object.create?function(r,e,a,t){t===void 0&&(t=a);var n=Object.getOwnPropertyDescriptor(e,a);(!n||("get"in n?!e.__esModule:n.writable||n.configurable))&&(n={enumerable:!0,get:function(){return e[a]}}),Object.defineProperty(r,t,n)}:function(r,e,a,t){t===void 0&&(t=a),r[t]=e[a]}),Fi=g&&g.__setModuleDefault||(Object.create?function(r,e){Object.defineProperty(r,"default",{enumerable:!0,value:e})}:function(r,e){r.default=e}),Hi=g&&g.__importStar||function(r){if(r&&r.__esModule)return r;var e={};if(r!=null)for(var a in r)a!=="default"&&Object.prototype.hasOwnProperty.call(r,a)&&Ni(e,r,a);return Fi(e,r),e},qi=g&&g.__rest||function(r,e){var a={};for(var t in r)Object.prototype.hasOwnProperty.call(r,t)&&e.indexOf(t)<0&&(a[t]=r[t]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,t=Object.getOwnPropertySymbols(r);n<t.length;n++)e.indexOf(t[n])<0&&Object.prototype.propertyIsEnumerable.call(r,t[n])&&(a[t[n]]=r[t[n]]);return a},Zi=g&&g.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Me,"__esModule",{value:!0});var je=Me.WearablePreview=void 0,Ir=Hi(R),zi=Zi(Ii),C=Tr,Yi=ie,Xi=se,Gi=Ya,Ki=(0,Yi.createDebounce)(),f=function(r,e){return e==null||e===""?"":Array.isArray(e)?e.length>0?e.map(function(a){return"".concat(r,"=").concat(encodeURIComponent(String(a)))}).join("&"):"":"".concat(r,"=").concat(encodeURIComponent(String(e)))},Vi=function(r){Li(e,r);function e(){var a=r!==null&&r.apply(this,arguments)||this;return a.state={isReady:!1,pendingOptions:null,lastOptions:null},a.iframe=null,a.getUrl=function(){var t=a.props,n=t.contractAddress,o=t.tokenId,i=t.itemId,u=t.profile,s=t.urns,l=t.urls,y=t.base64s,v=t.skin,p=t.hair,c=t.eyes,B=t.bodyShape,_=t.emote,E=t.camera,M=t.projection,S=t.zoom,k=t.background,O=t.offsetX,j=t.offsetY,m=t.offsetZ,A=t.cameraX,d=t.cameraY,H=t.cameraZ,Ot=t.wheelZoom,jt=t.wheelPrecision,Bt=t.wheelStart,_t=t.disableBackground,Et=t.disableAutoRotate,At=t.disableAutoCenter,It=t.disableFace,Mt=t.disableDefaultWearables,kt=t.disableDefaultEmotes,Dt=t.disableFadeEffect,Tt=t.showSceneBoundaries,xt=t.showThumbnailBoundaries,Wt=t.panning,Ct=t.lockAlpha,Rt=t.lockBeta,Ut=t.lockRadius,Lt=t.dev,Nt=t.baseUrl,Ft=t.peerUrl,Ht=t.nftServerUrl,fe=t.marketplaceServerUrl,qt=t.type,Zt=t.unity,zt=t.unityMode,Yt=f("contract",n),Xt=f("token",o),Gt=f("item",i),Kt=f("profile",u),Vt=f("urn",s),Qt=f("url",l),Jt=f("base64",y),ea=f("skin",v),ra=f("hair",p),ta=f("eyes",c),aa=f("bodyShape",B),na=f("emote",_),oa=f("camera",E),ia=f("projection",M),sa=f("zoom",S),fa=f("background",k),ua=f("offsetX",O),la=f("offsetY",j),ca=f("offsetZ",m),pa=f("cameraX",A),va=f("cameraY",d),ya=f("cameraZ",H),ga=f("wheelZoom",Ot),ma=f("wheelPrecision",jt),da=f("wheelStart",Bt),ha=f("disableBackground",_t),ba=f("disableAutoRotate",Et),Sa=f("disableAutoCenter",At),wa=f("disableFace",It),$a=f("disableDefaultWearables",Mt),Pa=f("disableDefaultEmotes",kt),Oa=f("disableFadeEffect",Dt),ja=f("showSceneBoundaries",Tt),Ba=f("showThumbnailBoundaries",xt),_a=f("peerUrl",Ft),Ea=fe??Ht,Aa=f("marketplaceServerUrl",Ea),Ia=f("type",qt),Ma=f("panning",Wt),ka=f("lockAlpha",Ct),Da=f("lockBeta",Rt),Ta=f("lockRadius",Ut),xa=f("env",Lt?"dev":void 0),Wa=f("unity",Zt),Ca=f("mode",zt),Ra=Nt+"?"+[Yt,Xt,Gt,Kt,Vt,Qt,Jt,ea,ra,ta,aa,na,oa,ia,sa,fa,ua,la,ca,pa,va,ya,ga,ma,da,ha,ba,Sa,wa,$a,Pa,Oa,ja,Ba,_a,Aa,Ia,Ma,ka,Da,Ta,xa,Wa,Ca].filter(function(Ua){return!!Ua}).join("&");return Ra},a.getOptions=function(){var t=a.props;t.dev;var n=qi(t,["dev"]),o={};for(var i in n)typeof n[i]!="function"&&(o[i]=n[i]);return o},a.handleMessage=function(t){var n=a.props,o=n.baseUrl,i=n.onLoad,u=n.onError,s=t.origin;if(s===o&&t.data&&t.data.type){var l=t.data.type;switch(l){case C.PreviewMessageType.LOAD:{var y=t.data.payload;i(y==null?void 0:y.renderer);break}case C.PreviewMessageType.ERROR:{var y=t.data.payload;u(new Error(y.message));break}case C.PreviewMessageType.READY:{var v=a.state,p=v.isReady,c=v.pendingOptions;if(p)return;c!==null?(a.sendUpdate(c),a.setState({isReady:!0,pendingOptions:null})):a.setState({isReady:!0});break}}}},a.handleUpdate=function(){if(a.iframe){if(window){var t=a.getOptions();a.state.isReady?a.sendUpdate(t):a.setState({pendingPreviewOptions:t})}}else console.warn("Could not send update, iframe is not referenced")},a.sendUpdate=function(t){var n=a.state.lastOptions;if(!n||!(0,zi.default)(t,n)){(0,C.sendMessage)(a.iframe.contentWindow,C.PreviewMessageType.UPDATE,{options:t});var o=a.props.onUpdate;o(t),a.setState({lastOptions:t})}},a.refIframe=function(t){a.iframe=t},a}return e.createController=function(a){return(0,Xi.createController)(a)},e.prototype.componentDidMount=function(){window.addEventListener("message",this.handleMessage,!1),this.setState({url:this.getUrl()}),this.props.blob&&this.handleUpdate()},e.prototype.componentWillUnmount=function(){window.removeEventListener("message",this.handleMessage,!1)},e.prototype.componentDidUpdate=function(){Ki(this.handleUpdate,500)},e.prototype.render=function(){return this.props.tokenId&&this.props.itemId&&console.warn("You should NOT use `tokenId` and `itemId` props simultaneously"),Ir.createElement("iframe",{id:this.props.id,className:"WearablePreview",src:this.state.url,width:"100%",height:"100%",frameBorder:"0",ref:this.refIframe,allow:"autoplay"})},e.defaultProps={dev:!1,baseUrl:Gi.config.get("WEARABLE_PREVIEW_URL"),unity:!1,onLoad:function(){},onError:function(){},onUpdate:function(){}},e}(Ir.PureComponent);je=Me.WearablePreview=Vi;function ts({address:r}){const[e,a]=R.useState(),{profile:t}=Xa(r),n=R.useCallback(()=>{a(je.createController("wearable-preview"))},[]),o=R.useMemo(()=>{const i=[T.PreviewEmote.DAB,T.PreviewEmote.FIST_PUMP,T.PreviewEmote.DANCE,T.PreviewEmote.HEAD_EXPLODE];return i[Math.random()*i.length|0]},[]);return R.useEffect(()=>{const i=setInterval(()=>{e&&e.emote.play()},2e4);return()=>clearInterval(i)},[e]),!r||!t.hasCustomAvatar?null:ke.jsx("div",{className:"UserAvatar__Container",children:ke.jsx(je,{id:"wearable-preview",profile:r,onLoad:n,background:"FFFFFF",emote:o,disableAutoRotate:!0,camera:T.PreviewCamera.STATIC})})}export{ts as default};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{w as Lr}from"./index-
|
|
1
|
+
import{w as Lr}from"./index-016592b7.js";import{a1 as xr,a2 as Cr,b as H,_ as be,a3 as Ce}from"./index-d1b7c41c.js";var Be={exports:{}},Me={},xe={},Qe;function Nr(){if(Qe)return xe;Qe=1,xe.byteLength=i,xe.toByteArray=S,xe.fromByteArray=g;for(var T=[],w=[],M=typeof Uint8Array<"u"?Uint8Array:Array,_="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",N=0,E=_.length;N<E;++N)T[N]=_[N],w[_.charCodeAt(N)]=N;w["-".charCodeAt(0)]=62,w["_".charCodeAt(0)]=63;function p(m){var b=m.length;if(b%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var F=m.indexOf("=");F===-1&&(F=b);var x=F===b?0:4-F%4;return[F,x]}function i(m){var b=p(m),F=b[0],x=b[1];return(F+x)*3/4-x}function l(m,b,F){return(b+F)*3/4-F}function S(m){var b,F=p(m),x=F[0],u=F[1],y=new M(l(m,x,u)),C=0,L=u>0?x-4:x,I;for(I=0;I<L;I+=4)b=w[m.charCodeAt(I)]<<18|w[m.charCodeAt(I+1)]<<12|w[m.charCodeAt(I+2)]<<6|w[m.charCodeAt(I+3)],y[C++]=b>>16&255,y[C++]=b>>8&255,y[C++]=b&255;return u===2&&(b=w[m.charCodeAt(I)]<<2|w[m.charCodeAt(I+1)]>>4,y[C++]=b&255),u===1&&(b=w[m.charCodeAt(I)]<<10|w[m.charCodeAt(I+1)]<<4|w[m.charCodeAt(I+2)]>>2,y[C++]=b>>8&255,y[C++]=b&255),y}function R(m){return T[m>>18&63]+T[m>>12&63]+T[m>>6&63]+T[m&63]}function h(m,b,F){for(var x,u=[],y=b;y<F;y+=3)x=(m[y]<<16&16711680)+(m[y+1]<<8&65280)+(m[y+2]&255),u.push(R(x));return u.join("")}function g(m){for(var b,F=m.length,x=F%3,u=[],y=16383,C=0,L=F-x;C<L;C+=y)u.push(h(m,C,C+y>L?L:C+y));return x===1?(b=m[F-1],u.push(T[b>>2]+T[b<<4&63]+"==")):x===2&&(b=(m[F-2]<<8)+m[F-1],u.push(T[b>>10]+T[b>>4&63]+T[b<<2&63]+"=")),u.join("")}return xe}var Fe={};/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */var er;function Ur(){return er||(er=1,Fe.read=function(T,w,M,_,N){var E,p,i=N*8-_-1,l=(1<<i)-1,S=l>>1,R=-7,h=M?N-1:0,g=M?-1:1,m=T[w+h];for(h+=g,E=m&(1<<-R)-1,m>>=-R,R+=i;R>0;E=E*256+T[w+h],h+=g,R-=8);for(p=E&(1<<-R)-1,E>>=-R,R+=_;R>0;p=p*256+T[w+h],h+=g,R-=8);if(E===0)E=1-S;else{if(E===l)return p?NaN:(m?-1:1)*(1/0);p=p+Math.pow(2,_),E=E-S}return(m?-1:1)*p*Math.pow(2,E-_)},Fe.write=function(T,w,M,_,N,E){var p,i,l,S=E*8-N-1,R=(1<<S)-1,h=R>>1,g=N===23?Math.pow(2,-24)-Math.pow(2,-77):0,m=_?0:E-1,b=_?1:-1,F=w<0||w===0&&1/w<0?1:0;for(w=Math.abs(w),isNaN(w)||w===1/0?(i=isNaN(w)?1:0,p=R):(p=Math.floor(Math.log(w)/Math.LN2),w*(l=Math.pow(2,-p))<1&&(p--,l*=2),p+h>=1?w+=g/l:w+=g*Math.pow(2,1-h),w*l>=2&&(p++,l/=2),p+h>=R?(i=0,p=R):p+h>=1?(i=(w*l-1)*Math.pow(2,N),p=p+h):(i=w*Math.pow(2,h-1)*Math.pow(2,N),p=0));N>=8;T[M+m]=i&255,m+=b,i/=256,N-=8);for(p=p<<N|i,S+=N;S>0;T[M+m]=p&255,m+=b,p/=256,S-=8);T[M+m-b]|=F*128}),Fe}/*!
|
|
2
2
|
* The buffer module from node.js, for the browser.
|
|
3
3
|
*
|
|
4
4
|
* @author Feross Aboukhadijeh <https://feross.org>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{B as w,g as O,s as x,a as b,t as F,f as L,A as S,d as $,b as M,c as E,e as I,h as y,i as D,j as A,k as G,I as T,l as m,m as C,n as H,o as j,p as v,q as B,H as R,r as U}from"./zoraTestnet-
|
|
1
|
+
import{B as w,g as O,s as x,a as b,t as F,f as L,A as S,d as $,b as M,c as E,e as I,h as y,i as D,j as A,k as G,I as T,l as m,m as C,n as H,o as j,p as v,q as B,H as R,r as U}from"./zoraTestnet-04c4a199.js";import"./BlockOverrides-f0043737.js";import"./index-d1b7c41c.js";class _ extends w{constructor({callbackSelector:n,cause:e,data:s,extraData:t,sender:o,urls:r}){var c;super(e.shortMessage||"An error occurred while fetching for an offchain result.",{cause:e,metaMessages:[...e.metaMessages||[],(c=e.metaMessages)!=null&&c.length?"":[],"Offchain Gateway Call:",r&&[" Gateway URL(s):",...r.map(u=>` ${O(u)}`)],` Sender: ${o}`,` Data: ${s}`,` Callback selector: ${n}`,` Extra data: ${t}`].flat(),name:"OffchainLookupError"})}}class J extends w{constructor({result:n,url:e}){super("Offchain gateway response is malformed. Response data must be a hex value.",{metaMessages:[`Gateway URL: ${O(e)}`,`Response: ${x(n)}`],name:"OffchainLookupResponseMalformedError"})}}class W extends w{constructor({sender:n,to:e}){super("Reverted sender address does not match target contract address (`to`).",{metaMessages:[`Contract address: ${e}`,`OffchainLookup sender address: ${n}`],name:"OffchainLookupSenderMismatchError"})}}function z(a){const{abi:n,data:e}=a,s=b(e,0,4),t=n.find(o=>o.type==="function"&&s===F(L(o)));if(!t)throw new S(s,{docsPath:"/docs/contract/decodeFunctionData"});return{functionName:t.name,args:"inputs"in t&&t.inputs&&t.inputs.length>0?$(t.inputs,b(e,4)):void 0}}const p="/docs/contract/encodeErrorResult";function k(a){const{abi:n,errorName:e,args:s}=a;let t=n[0];if(e){const u=M({abi:n,args:s,name:e});if(!u)throw new E(e,{docsPath:p});t=u}if(t.type!=="error")throw new E(void 0,{docsPath:p});const o=L(t),r=F(o);let c="0x";if(s&&s.length>0){if(!t.inputs)throw new I(t.name,{docsPath:p});c=y(t.inputs,s)}return D([r,c])}const h="/docs/contract/encodeFunctionResult";function K(a){const{abi:n,functionName:e,result:s}=a;let t=n[0];if(e){const r=M({abi:n,name:e});if(!r)throw new A(e,{docsPath:h});t=r}if(t.type!=="function")throw new A(void 0,{docsPath:h});if(!t.outputs)throw new G(t.name,{docsPath:h});const o=(()=>{if(t.outputs.length===0)return[];if(t.outputs.length===1)return[s];if(Array.isArray(s))return s;throw new T(s)})();return y(t.outputs,o)}const N="x-batch-gateway:true";async function P(a){const{data:n,ccipRequest:e}=a,{args:[s]}=z({abi:m,data:n}),t=[],o=[];return await Promise.all(s.map(async(r,c)=>{try{o[c]=r.urls.includes(N)?await P({data:r.data,ccipRequest:e}):await e(r),t[c]=!1}catch(u){t[c]=!0,o[c]=Q(u)}})),K({abi:m,functionName:"query",result:[t,o]})}function Q(a){return a.name==="HttpRequestError"&&a.status?k({abi:m,errorName:"HttpError",args:[a.status,a.shortMessage]}):k({abi:[C],errorName:"Error",args:["shortMessage"in a?a.shortMessage:a.message]})}const et="0x556f1830",V={name:"OffchainLookup",type:"error",inputs:[{name:"sender",type:"address"},{name:"urls",type:"string[]"},{name:"callData",type:"bytes"},{name:"callbackFunction",type:"bytes4"},{name:"extraData",type:"bytes"}]};async function at(a,{blockNumber:n,blockTag:e,data:s,to:t}){const{args:o}=H({data:s,abi:[V]}),[r,c,u,f,d]=o,{ccipRead:i}=a,g=i&&typeof(i==null?void 0:i.request)=="function"?i.request:X;try{if(!j(t,r))throw new W({sender:r,to:t});const l=c.includes(N)?await P({data:u,ccipRequest:g}):await g({data:u,sender:r,urls:c}),{data:q}=await v(a,{blockNumber:n,blockTag:e,data:B([f,y([{type:"bytes"},{type:"bytes"}],[l,d])]),to:t});return q}catch(l){throw new _({callbackSelector:f,cause:l,data:s,extraData:d,sender:r,urls:c})}}async function X({data:a,sender:n,urls:e}){var t;let s=new Error("An unknown error occurred.");for(let o=0;o<e.length;o++){const r=e[o],c=r.includes("{data}")?"GET":"POST",u=c==="POST"?{data:a,sender:n}:void 0,f=c==="POST"?{"Content-Type":"application/json"}:{};try{const d=await fetch(r.replace("{sender}",n.toLowerCase()).replace("{data}",a),{body:JSON.stringify(u),headers:f,method:c});let i;if((t=d.headers.get("Content-Type"))!=null&&t.startsWith("application/json")?i=(await d.json()).data:i=await d.text(),!d.ok){s=new R({body:u,details:i!=null&&i.error?x(i.error):d.statusText,headers:d.headers,status:d.status,url:r});continue}if(!U(i)){s=new J({result:i,url:r});continue}return i}catch(d){s=new R({body:u,details:d.message,url:r})}}throw s}export{X as ccipRequest,at as offchainLookup,V as offchainLookupAbiItem,et as offchainLookupSignature};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{s as b,d as x,f as O,A as S,e as $,i as F,j as E,k as I,l as w,m as C,n as A,o as D,I as G,B as y,p as L,q as M,u as m,v as T,w as H,x as v,y as j,z as B,H as R,C as U}from"./index-
|
|
1
|
+
import{s as b,d as x,f as O,A as S,e as $,i as F,j as E,k as I,l as w,m as C,n as A,o as D,I as G,B as y,p as L,q as M,u as m,v as T,w as H,x as v,y as j,z as B,H as R,C as U}from"./index-d1b7c41c.js";function _(a){const{abi:r,data:e}=a,s=b(e,0,4),t=r.find(o=>o.type==="function"&&s===x(O(o)));if(!t)throw new S(s,{docsPath:"/docs/contract/decodeFunctionData"});return{functionName:t.name,args:"inputs"in t&&t.inputs&&t.inputs.length>0?$(t.inputs,b(e,4)):void 0}}const p="/docs/contract/encodeErrorResult";function k(a){const{abi:r,errorName:e,args:s}=a;let t=r[0];if(e){const u=F({abi:r,args:s,name:e});if(!u)throw new E(e,{docsPath:p});t=u}if(t.type!=="error")throw new E(void 0,{docsPath:p});const o=O(t),n=x(o);let c="0x";if(s&&s.length>0){if(!t.inputs)throw new I(t.name,{docsPath:p});c=w(t.inputs,s)}return C([n,c])}const h="/docs/contract/encodeFunctionResult";function z(a){const{abi:r,functionName:e,result:s}=a;let t=r[0];if(e){const n=F({abi:r,name:e});if(!n)throw new A(e,{docsPath:h});t=n}if(t.type!=="function")throw new A(void 0,{docsPath:h});if(!t.outputs)throw new D(t.name,{docsPath:h});const o=(()=>{if(t.outputs.length===0)return[];if(t.outputs.length===1)return[s];if(Array.isArray(s))return s;throw new G(s)})();return w(t.outputs,o)}class J extends y{constructor({callbackSelector:r,cause:e,data:s,extraData:t,sender:o,urls:n}){var c;super(e.shortMessage||"An error occurred while fetching for an offchain result.",{cause:e,metaMessages:[...e.metaMessages||[],(c=e.metaMessages)!=null&&c.length?"":[],"Offchain Gateway Call:",n&&[" Gateway URL(s):",...n.map(u=>` ${L(u)}`)],` Sender: ${o}`,` Data: ${s}`,` Callback selector: ${r}`,` Extra data: ${t}`].flat(),name:"OffchainLookupError"})}}class W extends y{constructor({result:r,url:e}){super("Offchain gateway response is malformed. Response data must be a hex value.",{metaMessages:[`Gateway URL: ${L(e)}`,`Response: ${M(r)}`],name:"OffchainLookupResponseMalformedError"})}}class K extends y{constructor({sender:r,to:e}){super("Reverted sender address does not match target contract address (`to`).",{metaMessages:[`Contract address: ${e}`,`OffchainLookup sender address: ${r}`],name:"OffchainLookupSenderMismatchError"})}}const N="x-batch-gateway:true";async function P(a){const{data:r,ccipRequest:e}=a,{args:[s]}=_({abi:m,data:r}),t=[],o=[];return await Promise.all(s.map(async(n,c)=>{try{o[c]=n.urls.includes(N)?await P({data:n.data,ccipRequest:e}):await e(n),t[c]=!1}catch(u){t[c]=!0,o[c]=Q(u)}})),z({abi:m,functionName:"query",result:[t,o]})}function Q(a){return a.name==="HttpRequestError"&&a.status?k({abi:m,errorName:"HttpError",args:[a.status,a.shortMessage]}):k({abi:[T],errorName:"Error",args:["shortMessage"in a?a.shortMessage:a.message]})}const Z="0x556f1830",V={name:"OffchainLookup",type:"error",inputs:[{name:"sender",type:"address"},{name:"urls",type:"string[]"},{name:"callData",type:"bytes"},{name:"callbackFunction",type:"bytes4"},{name:"extraData",type:"bytes"}]};async function tt(a,{blockNumber:r,blockTag:e,data:s,to:t}){const{args:o}=H({data:s,abi:[V]}),[n,c,u,f,d]=o,{ccipRead:i}=a,g=i&&typeof(i==null?void 0:i.request)=="function"?i.request:X;try{if(!v(t,n))throw new K({sender:n,to:t});const l=c.includes(N)?await P({data:u,ccipRequest:g}):await g({data:u,sender:n,urls:c}),{data:q}=await j(a,{blockNumber:r,blockTag:e,data:B([f,w([{type:"bytes"},{type:"bytes"}],[l,d])]),to:t});return q}catch(l){throw new J({callbackSelector:f,cause:l,data:s,extraData:d,sender:n,urls:c})}}async function X({data:a,sender:r,urls:e}){var t;let s=new Error("An unknown error occurred.");for(let o=0;o<e.length;o++){const n=e[o],c=n.includes("{data}")?"GET":"POST",u=c==="POST"?{data:a,sender:r}:void 0,f=c==="POST"?{"Content-Type":"application/json"}:{};try{const d=await fetch(n.replace("{sender}",r.toLowerCase()).replace("{data}",a),{body:JSON.stringify(u),headers:f,method:c});let i;if((t=d.headers.get("Content-Type"))!=null&&t.startsWith("application/json")?i=(await d.json()).data:i=await d.text(),!d.ok){s=new R({body:u,details:i!=null&&i.error?M(i.error):d.statusText,headers:d.headers,status:d.status,url:n});continue}if(!U(i)){s=new W({result:i,url:n});continue}return i}catch(d){s=new R({body:u,details:d.message,url:n})}}throw s}export{X as ccipRequest,tt as offchainLookup,V as offchainLookupAbiItem,Z as offchainLookupSignature};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{n as y,l as $,m as l,O as m,R as p,C as g,S as h,F as E,z as R}from"./index-
|
|
1
|
+
import{n as y,l as $,m as l,O as m,R as p,C as g,S as h,F as E,z as R}from"./index-becc5f18.js";import{n as S,c as x,r as u,U as _}from"./index-ca30e4fd.js";import{W as C}from"./index-8e9b20ff.js";import{R as v}from"./ReownAuthentication-e97b67e8.js";import"./index-d1b7c41c.js";import"./NetworkUtil-a423d25a.js";import"./index-2e026425.js";import"./BlockOverrides-f0043737.js";import"./index-5cb9cf07.js";import"./index-44db0baa.js";const D=y`
|
|
2
2
|
.email-sufixes {
|
|
3
3
|
display: flex;
|
|
4
4
|
flex-direction: row;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{C as S,x as O,O as d,E as c,M as _,R as s,S as f,h as b,j as T,l as C,o as m,m as u,n as D,P as $}from"./index-
|
|
1
|
+
import{C as S,x as O,O as d,E as c,M as _,R as s,S as f,h as b,j as T,l as C,o as m,m as u,n as D,P as $}from"./index-becc5f18.js";import{c as h,r as E}from"./index-ca30e4fd.js";import{W as g}from"./index-8e9b20ff.js";import"./index-870741d2.js";import"./index-5cb9cf07.js";import{e as W,n as P}from"./ref-93e8bc0a.js";import"./index-ae732654.js";import"./index-f8b8fc20.js";import{C as N}from"./NetworkUtil-a423d25a.js";import"./index-d1b7c41c.js";import"./index-2e026425.js";import"./BlockOverrides-f0043737.js";import"./index-44db0baa.js";import"./if-defined-b80e1e5f.js";import"./index-7ed20462.js";var j=globalThis&&globalThis.__decorate||function(a,e,t,r){var n=arguments.length,i=n<3?e:r===null?r=Object.getOwnPropertyDescriptor(e,t):r,o;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(a,e,t,r);else for(var l=a.length-1;l>=0;l--)(o=a[l])&&(i=(n<3?o(i):n>3?o(e,t,i):o(e,t))||i);return n>3&&i&&Object.defineProperty(e,t,i),i};let I=class extends g{constructor(){super(...arguments),this.onOtpSubmit=async e=>{var t,r;try{if(this.authConnector){const n=S.state.activeChain,i=O.getConnections(n),o=(t=d.state.remoteFeatures)==null?void 0:t.multiWallet,l=i.length>0;if(await this.authConnector.provider.connectOtp({otp:e}),c.sendEvent({type:"track",event:"EMAIL_VERIFICATION_CODE_PASS"}),n)await O.connectExternal(this.authConnector,n);else throw new Error("Active chain is not set on ChainController");if((r=d.state.remoteFeatures)!=null&&r.emailCapture)return;if(d.state.siwx){_.close();return}if(l&&o){s.replace("ProfileWallets"),f.showSuccess("New Wallet Added");return}_.close()}}catch(n){throw c.sendEvent({type:"track",event:"EMAIL_VERIFICATION_CODE_FAIL",properties:{message:b.parseError(n)}}),n}},this.onOtpResend=async e=>{this.authConnector&&(await this.authConnector.provider.connectEmail({email:e}),c.sendEvent({type:"track",event:"EMAIL_VERIFICATION_CODE_SENT"}))}}};I=j([h("w3m-email-verify-otp-view")],I);const F=T`
|
|
2
2
|
wui-icon-box {
|
|
3
3
|
height: ${({spacing:a})=>a[16]};
|
|
4
4
|
width: ${({spacing:a})=>a[16]};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{n as H,l as f,M as W,O as K,m as c,o as _,T as j,V as G,j as E,r as z,k as B,c as N,C as m,X as V,y as T,W as h,x as L,Y as X,Z as v,h as k,E as O,S as q,R as Z}from"./index-
|
|
1
|
+
import{n as H,l as f,M as W,O as K,m as c,o as _,T as j,V as G,j as E,r as z,k as B,c as N,C as m,X as V,y as T,W as h,x as L,Y as X,Z as v,h as k,E as O,S as q,R as Z}from"./index-becc5f18.js";import{r as u,c as w,n as l}from"./index-ca30e4fd.js";import"./index-a3f378d1.js";import{C as D}from"./NetworkUtil-a423d25a.js";import{e as Q,n as J}from"./ref-93e8bc0a.js";import"./index-44db0baa.js";import{H as I}from"./HelpersUtil-8166e848.js";import{o as ee}from"./if-defined-b80e1e5f.js";import"./index-7ed20462.js";import"./index-1def7b3c.js";import"./index-ae732654.js";import"./index-870741d2.js";import"./index-5cb9cf07.js";import{N as te}from"./NavigationUtil-a0d0ce87.js";import"./index-d1b7c41c.js";import"./index-2e026425.js";import"./BlockOverrides-f0043737.js";import"./ConstantsUtil-e2cd00bd.js";const ie=H`
|
|
2
2
|
div {
|
|
3
3
|
width: 100%;
|
|
4
4
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{R as p,a}from"./ReownAuthentication-e97b67e8.js";import"./index-becc5f18.js";import"./index-d1b7c41c.js";import"./NetworkUtil-a423d25a.js";import"./index-2e026425.js";import"./BlockOverrides-f0043737.js";export{p as ReownAuthentication,a as ReownAuthenticationMessenger};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{g as Z}from"./index-7b68384a.js";function $(h,y){for(var a=0;a<y.length;a++){const r=y[a];if(typeof r!="string"&&!Array.isArray(r)){for(const o in r)if(o!=="default"&&!(o in h)){const u=Object.getOwnPropertyDescriptor(r,o);u&&Object.defineProperty(h,o,u.get?u:{enumerable:!0,get:()=>r[o]})}}}return Object.freeze(Object.defineProperty(h,Symbol.toStringTag,{value:"Module"}))}var z=function(h){var y={};function a(r){if(y[r])return y[r].exports;var o=y[r]={i:r,l:!1,exports:{}};return h[r].call(o.exports,o,o.exports,a),o.l=!0,o.exports}return a.m=h,a.c=y,a.d=function(r,o,u){a.o(r,o)||Object.defineProperty(r,o,{enumerable:!0,get:u})},a.r=function(r){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(r,"__esModule",{value:!0})},a.t=function(r,o){if(1&o&&(r=a(r)),8&o||4&o&&typeof r=="object"&&r&&r.__esModule)return r;var u=Object.create(null);if(a.r(u),Object.defineProperty(u,"default",{enumerable:!0,value:r}),2&o&&typeof r!="string")for(var l in r)a.d(u,l,(function(R){return r[R]}).bind(null,l));return u},a.n=function(r){var o=r&&r.__esModule?function(){return r.default}:function(){return r};return a.d(o,"a",o),o},a.o=function(r,o){return Object.prototype.hasOwnProperty.call(r,o)},a.p="",a(a.s=3)}([function(h,y){h.exports=function(a){return a&&a.__esModule?a:{default:a}}},function(h,y){h.exports=function(a,r){if(!(a instanceof r))throw new TypeError("Cannot call a class as a function")}},function(h,y,a){function r(){return Math.floor(9e4*Math.random())+1e4}Object.defineProperty(y,"__esModule",{value:!0}),y.sendAsyncWrapper=function(o,u){var l=this;return new Promise(function(R,x){l.sendAsync({jsonrpc:"2.0",id:r(),method:o,params:u||[]},function(O,T){O?x(O):R(T.result)})})},y.sendFortmaticAsyncWrapper=function(o){var u=this;return new Promise(function(l,R){u.getProvider().sendFortmaticAsync(o,function(x,O){x?R(x):l(O?O.result:{})})})},y.randomId=r,y.findExistingResponse=function(o,u){for(var l=0;l<o.length;l++)if(o[l].id===u)return o[l];return null}},function(h,y,a){h.exports=a(4)},function(h,y,a){var r=a(0),o=r(a(1)),u=r(a(5)),l=a(2),R="fm_composeSend",x="fm_logout",O="fm_get_balances",T="fm_get_transactions",w="fm_is_logged_in",P="fm_accountSettings",n="fm_deposit",s="fm_get_user",c="fm_configure",f={};h.exports=function b(_,A,I){var v=this;if((0,o.default)(this,b),this.fortmaticClient="https://x2.fortmatic.com",!_)throw new Error("Please provide a Fortmatic API key that you acquired from the developer dashboard.");this.apiKey=_,this.options=I,this.ethNetwork=A,this.queryParams=btoa(JSON.stringify({API_KEY:_,ETH_NETWORK:A})),this.transactions={send:function(m,M){var C=new g(R,{to:m.to,value:m.amount});v.getProvider().sendFortmaticAsync(C,M)}},this.getProvider=function(){return f["fortmatic-".concat(v.queryParams)]||(f["fortmatic-".concat(v.queryParams)]=new u.default(v.fortmaticClient,{API_KEY:_,ETH_NETWORK:A})),f["fortmatic-".concat(v.queryParams)]},this.user={login:function(){return v.getProvider().enable()},logout:function(){v.getProvider().account=null,v.getProvider().network=null;var m=new g(x);return l.sendFortmaticAsyncWrapper.call(v,m)},getUser:function(){var m=new g(s);return l.sendFortmaticAsyncWrapper.call(v,m)},getBalances:function(){var m=new g(O);return l.sendFortmaticAsyncWrapper.call(v,m)},getTransactions:function(){var m=new g(T);return l.sendFortmaticAsyncWrapper.call(v,m)},isLoggedIn:function(){var m=new g(w);return l.sendFortmaticAsyncWrapper.call(v,m)},settings:function(){var m=new g(P);return l.sendFortmaticAsyncWrapper.call(v,m)},deposit:function(m){var M=new g(n,m);return l.sendFortmaticAsyncWrapper.call(v,M)}},this.configure=function(){var m=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},M=new g(c);return M.params=[m],l.sendFortmaticAsyncWrapper.call(v,M)}};var g=function b(_,A){(0,o.default)(this,b),this.id=(0,l.randomId)(),this.method=_,this.params=A?[A]:[{}]}},function(h,y,a){var r=a(0);Object.defineProperty(y,"__esModule",{value:!0}),y.default=void 0;var o=r(a(6)),u=r(a(9)),l=r(a(1)),R=r(a(10)),x=a(11),O=r(a(12)),T=a(2),w=function(){function P(n,s){if((0,l.default)(this,P),this.fortmaticClient=n,this.requests={},this.queue=[],this.account=null,this.network=null,this.isFortmatic=!0,this.overlayReady=!1,this.isLoggedIn=!1,this.postMessages={FORTMATIC_HANDLE_BATCH_REQUEST:"FORTMATIC_HANDLE_BATCH_REQUEST",FORTMATIC_HANDLE_REQUEST:"FORTMATIC_HANDLE_REQUEST",FORTMATIC_HANDLE_FORTMATIC_REQUEST:"FORTMATIC_HANDLE_FORTMATIC_REQUEST",FORTMATIC_HANDLE_RESPONSE:"FORTMATIC_HANDLE_RESPONSE",FORTMATIC_OVERLAY_READY:"FORTMATIC_OVERLAY_READY",FORTMATIC_SHOW_OVERLAY:"FORTMATIC_SHOW_OVERLAY",FORTMATIC_HIDE_OVERLAY:"FORTMATIC_HIDE_OVERLAY",FORTMATIC_USER_DENIED:"FORTMATIC_USER_DENIED",FORTMATIC_USER_LOGOUT:"FORTMATIC_USER_LOGOUT",FORTMATIC_UNAUTHORIZED_API_KEY:"FORTMATIC_UNAUTHORIZED_API_KEY"},!s.API_KEY)throw new Error("Please provide a Fortmatic API key that you acquired from the developer dashboard.");this.options={API_KEY:s.API_KEY,ETH_NETWORK:s.ETH_NETWORK,DOMAIN_ORIGIN:window.location?window.location.origin:"",version:x.version},this.queryParams=btoa(JSON.stringify(this.options)),this.constructPostMessage(),this.overlay=this.createOverlay(),this.listenMessage()}return(0,R.default)(P,[{key:"constructPostMessage",value:function(){var n=this;Object.keys(this.postMessages).map(function(s){n.postMessages[s]+="-".concat(n.queryParams)})}},{key:"createOverlay",value:function(){var n=this;return new Promise(function(s,c){var f=function(){if(function(){var A=!0,I=!1,v=void 0;try{for(var m,M=document.getElementsByClassName("fortmatic-iframe")[Symbol.iterator]();!(A=(m=M.next()).done);A=!0)if(m.value.src.includes(n.queryParams))return!1}catch(C){I=!0,v=C}finally{try{A||M.return==null||M.return()}finally{if(I)throw v}}return!0}()){var g=document.createElement("style");g.innerHTML=O.default.css,g.type="text/css",document.head.appendChild(g);var b=document.createElement("iframe");b.className="fortmatic-iframe",b.src="".concat(n.fortmaticClient,"/send?params=").concat(n.queryParams),document.body.appendChild(b);var _=document.createElement("img");_.src="https://static.fortmatic.com/assets/trans.gif",document.body.appendChild(_),s({iframe:b})}else console.error("Fortmatic: Duplicate instances found.")};["loaded","interactive","complete"].indexOf(document.readyState)>-1?f():window.addEventListener("load",f.bind(n),!1)})}},{key:"showOverlay",value:function(){var n=(0,u.default)(o.default.mark(function s(){return o.default.wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.next=2,this.overlay;case 2:c.sent.iframe.style.display="block";case 4:case"end":return c.stop()}},s,this)}));return function(){return n.apply(this,arguments)}}()},{key:"hideOverlay",value:function(){var n=(0,u.default)(o.default.mark(function s(){return o.default.wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.next=2,this.overlay;case 2:c.sent.iframe.style.display="none";case 4:case"end":return c.stop()}},s,this)}));return function(){return n.apply(this,arguments)}}()},{key:"sendAsync",value:function(n,s){n.length>0?this.enqueue({payload:{id:(0,T.randomId)(),batch:n.map(function(c){return c.id=(0,T.randomId)(),c}),method:"eth_batchRequest"},cb:s}):this.enqueue({payload:n,cb:s})}},{key:"sendFortmaticAsync",value:function(n,s){this.enqueue({payload:n,cb:s,isNative:!0})}},{key:"send",value:function(n,s){if(typeof n=="string")return T.sendAsyncWrapper.call(this,n,s);if(!s){console.warn("Non-async web3 methods will be deprecated in web3 > 1.0, and are not supported by the Fortmatic provider. An async method to be used instead."),this.sendAsync(n,function(){});var c={};switch(n.method){case"eth_accounts":c=this.account?[this.account]:[];break;case"eth_coinbase":c=this.account;break;case"net_version":c=this.network||(this.options.API_KEY.startsWith("pk_live")?1:4);break;case"eth_uninstallFilter":c=!0;break;default:c={}}return{id:n.id,jsonrpc:n.jsonrpc,result:c}}this.sendAsync(n,s)}},{key:"enqueue",value:function(n){this.queue.push(n),this.overlayReady&&this.dequeue()}},{key:"dequeue",value:function(){var n=(0,u.default)(o.default.mark(function s(){var c,f,g,b=this;return o.default.wrap(function(_){for(;;)switch(_.prev=_.next){case 0:if(this.queue.length!==0){_.next=2;break}return _.abrupt("return");case 2:if(!(c=this.queue.shift())){_.next=11;break}return f=c.payload,g=c.cb,f.id=(0,T.randomId)(),_.next=9,this.postMessage(c.isNative?this.postMessages.FORTMATIC_HANDLE_FORTMATIC_REQUEST:this.postMessages.FORTMATIC_HANDLE_REQUEST,c.payload);case 9:f.batch&&f.batch.length>0?(f.batch.forEach(function(A){b.requests[A.id]={parentId:f.id,payload:A,cb:function(I,v){var m=b.requests[f.id].batchResponse;if(I&&I.response&&!(0,T.findExistingResponse)(m,I.response.id))throw m.push({jsonrpc:"2.0",id:I.response.id,error:{code:I.response.code,message:I.response.message}}),b.requests[f.id].cb(null,m),I.response;if(v&&v.result&&!(0,T.findExistingResponse)(m,v.id))return m.push(v);throw new Error("Fortmatic: unexpected callback behavior")}}}),this.requests[f.id]={payload:f,cb:g,batchResponse:[]}):this.requests[f.id]={payload:f,cb:g},this.dequeue();case 11:case"end":return _.stop()}},s,this)}));return function(){return n.apply(this,arguments)}}()},{key:"postMessage",value:function(){var n=(0,u.default)(o.default.mark(function s(c,f){var g;return o.default.wrap(function(b){for(;;)switch(b.prev=b.next){case 0:return b.next=2,this.overlay;case 2:if(!(g=b.sent).iframe.contentWindow){b.next=7;break}g.iframe.contentWindow.postMessage({msgType:c,payload:f},"*"),b.next=8;break;case 7:throw new Error("Fortmatic: Modal is not ready.");case 8:case"end":return b.stop()}},s,this)}));return function(s,c){return n.apply(this,arguments)}}()},{key:"enable",value:function(){return T.sendAsyncWrapper.call(this,"eth_accounts")}},{key:"listenMessage",value:function(){var n=this;window.addEventListener("message",function(s){if(s.origin===n.fortmaticClient){var c=s.data.response?s.data.response.id:null;switch(s.data.msgType){case n.postMessages.FORTMATIC_OVERLAY_READY:n.overlayReady=!0,n.dequeue();break;case n.postMessages.FORTMATIC_HANDLE_RESPONSE:try{n.requests[c].cb(null,s.data.response);var f=n.requests[c].parentId;f&&n.requests[f].payload.batch.length===n.requests[f].batchResponse.length&&n.requests[f].cb(null,n.requests[f].batchResponse),n.requests[c].payload.method==="eth_accounts"?n.account=s.data.response.result[0]:n.requests[c].payload.method==="eth_coinbase"?n.account=s.data.response.result:n.requests[c].payload.method==="net_version"&&(n.network=s.data.response.result)}catch{}n.isLoggedIn=!0,n.dequeue();break;case n.postMessages.FORTMATIC_HIDE_OVERLAY:n.hideOverlay();break;case n.postMessages.FORTMATIC_SHOW_OVERLAY:n.showOverlay();break;case n.postMessages.FORTMATIC_USER_LOGOUT:n.account=null,n.network=null,n.isLoggedIn=!1;break;case n.postMessages.FORTMATIC_UNAUTHORIZED_API_KEY:throw n.overlayReady=!1,new Error("Given API key is not authorized to access the resource.");case n.postMessages.FORTMATIC_USER_DENIED:if(c){var g=s.data.response&&s.data.response.message?s.data.response.message:"Fortmatic: Modal was closed without executing action!",b=s.data.response&&s.data.response.code?s.data.response.code:1;n.requests[c].cb({message:g,code:b,response:s.data.response})}else n.queue.forEach(function(_){return _.cb({message:"Fortmatic: Modal was closed without executing action!",code:1})});n.dequeue()}}})}}]),P}();y.default=w},function(h,y,a){h.exports=a(7)},function(h,y,a){var r=function(){return this||typeof self=="object"&&self}()||Function("return this")(),o=r.regeneratorRuntime&&Object.getOwnPropertyNames(r).indexOf("regeneratorRuntime")>=0,u=o&&r.regeneratorRuntime;if(r.regeneratorRuntime=void 0,h.exports=a(8),o)r.regeneratorRuntime=u;else try{delete r.regeneratorRuntime}catch{r.regeneratorRuntime=void 0}},function(h,y){(function(a){var r,o=Object.prototype,u=o.hasOwnProperty,l=typeof Symbol=="function"?Symbol:{},R=l.iterator||"@@iterator",x=l.asyncIterator||"@@asyncIterator",O=l.toStringTag||"@@toStringTag",T=typeof h=="object",w=a.regeneratorRuntime;if(w)T&&(h.exports=w);else{(w=a.regeneratorRuntime=T?h.exports:{}).wrap=I;var P="suspendedStart",n="suspendedYield",s="executing",c="completed",f={},g={};g[R]=function(){return this};var b=Object.getPrototypeOf,_=b&&b(b(G([])));_&&_!==o&&u.call(_,R)&&(g=_);var A=C.prototype=m.prototype=Object.create(g);M.prototype=A.constructor=C,C.constructor=M,C[O]=M.displayName="GeneratorFunction",w.isGeneratorFunction=function(t){var e=typeof t=="function"&&t.constructor;return!!e&&(e===M||(e.displayName||e.name)==="GeneratorFunction")},w.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,C):(t.__proto__=C,O in t||(t[O]="GeneratorFunction")),t.prototype=Object.create(A),t},w.awrap=function(t){return{__await:t}},V(U.prototype),U.prototype[x]=function(){return this},w.AsyncIterator=U,w.async=function(t,e,d,p){var i=new U(I(t,e,d,p));return w.isGeneratorFunction(e)?i:i.next().then(function(F){return F.done?F.value:i.next()})},V(A),A[O]="Generator",A[R]=function(){return this},A.toString=function(){return"[object Generator]"},w.keys=function(t){var e=[];for(var d in t)e.push(d);return e.reverse(),function p(){for(;e.length;){var i=e.pop();if(i in t)return p.value=i,p.done=!1,p}return p.done=!0,p}},w.values=G,K.prototype={constructor:K,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=r,this.done=!1,this.delegate=null,this.method="next",this.arg=r,this.tryEntries.forEach(Y),!t)for(var e in this)e.charAt(0)==="t"&&u.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=r)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if(t.type==="throw")throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function d(W,E){return F.type="throw",F.arg=t,e.next=W,E&&(e.method="next",e.arg=r),!!E}for(var p=this.tryEntries.length-1;p>=0;--p){var i=this.tryEntries[p],F=i.completion;if(i.tryLoc==="root")return d("end");if(i.tryLoc<=this.prev){var j=u.call(i,"catchLoc"),q=u.call(i,"finallyLoc");if(j&&q){if(this.prev<i.catchLoc)return d(i.catchLoc,!0);if(this.prev<i.finallyLoc)return d(i.finallyLoc)}else if(j){if(this.prev<i.catchLoc)return d(i.catchLoc,!0)}else{if(!q)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return d(i.finallyLoc)}}}},abrupt:function(t,e){for(var d=this.tryEntries.length-1;d>=0;--d){var p=this.tryEntries[d];if(p.tryLoc<=this.prev&&u.call(p,"finallyLoc")&&this.prev<p.finallyLoc){var i=p;break}}i&&(t==="break"||t==="continue")&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var F=i?i.completion:{};return F.type=t,F.arg=e,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(F)},complete:function(t,e){if(t.type==="throw")throw t.arg;return t.type==="break"||t.type==="continue"?this.next=t.arg:t.type==="return"?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):t.type==="normal"&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var d=this.tryEntries[e];if(d.finallyLoc===t)return this.complete(d.completion,d.afterLoc),Y(d),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var d=this.tryEntries[e];if(d.tryLoc===t){var p=d.completion;if(p.type==="throw"){var i=p.arg;Y(d)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,d){return this.delegate={iterator:G(t),resultName:e,nextLoc:d},this.method==="next"&&(this.arg=r),f}}}function I(t,e,d,p){var i=e&&e.prototype instanceof m?e:m,F=Object.create(i.prototype),j=new K(p||[]);return F._invoke=function(q,W,E){var L=P;return function(S,D){if(L===s)throw new Error("Generator is already running");if(L===c){if(S==="throw")throw D;return Q()}for(E.method=S,E.arg=D;;){var H=E.delegate;if(H){var N=B(H,E);if(N){if(N===f)continue;return N}}if(E.method==="next")E.sent=E._sent=E.arg;else if(E.method==="throw"){if(L===P)throw L=c,E.arg;E.dispatchException(E.arg)}else E.method==="return"&&E.abrupt("return",E.arg);L=s;var k=v(q,W,E);if(k.type==="normal"){if(L=E.done?c:n,k.arg===f)continue;return{value:k.arg,done:E.done}}k.type==="throw"&&(L=c,E.method="throw",E.arg=k.arg)}}}(t,d,j),F}function v(t,e,d){try{return{type:"normal",arg:t.call(e,d)}}catch(p){return{type:"throw",arg:p}}}function m(){}function M(){}function C(){}function V(t){["next","throw","return"].forEach(function(e){t[e]=function(d){return this._invoke(e,d)}})}function U(t){var e;this._invoke=function(d,p){function i(){return new Promise(function(F,j){(function q(W,E,L,S){var D=v(t[W],t,E);if(D.type!=="throw"){var H=D.arg,N=H.value;return N&&typeof N=="object"&&u.call(N,"__await")?Promise.resolve(N.__await).then(function(k){q("next",k,L,S)},function(k){q("throw",k,L,S)}):Promise.resolve(N).then(function(k){H.value=k,L(H)},function(k){return q("throw",k,L,S)})}S(D.arg)})(d,p,F,j)})}return e=e?e.then(i,i):i()}}function B(t,e){var d=t.iterator[e.method];if(d===r){if(e.delegate=null,e.method==="throw"){if(t.iterator.return&&(e.method="return",e.arg=r,B(t,e),e.method==="throw"))return f;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return f}var p=v(d,t.iterator,e.arg);if(p.type==="throw")return e.method="throw",e.arg=p.arg,e.delegate=null,f;var i=p.arg;return i?i.done?(e[t.resultName]=i.value,e.next=t.nextLoc,e.method!=="return"&&(e.method="next",e.arg=r),e.delegate=null,f):i:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function J(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function Y(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function K(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(J,this),this.reset(!0)}function G(t){if(t){var e=t[R];if(e)return e.call(t);if(typeof t.next=="function")return t;if(!isNaN(t.length)){var d=-1,p=function i(){for(;++d<t.length;)if(u.call(t,d))return i.value=t[d],i.done=!1,i;return i.value=r,i.done=!0,i};return p.next=p}}return{next:Q}}function Q(){return{value:r,done:!0}}})(function(){return this||typeof self=="object"&&self}()||Function("return this")())},function(h,y){function a(r,o,u,l,R,x,O){try{var T=r[x](O),w=T.value}catch(P){return void u(P)}T.done?o(w):Promise.resolve(w).then(l,R)}h.exports=function(r){return function(){var o=this,u=arguments;return new Promise(function(l,R){var x=r.apply(o,u);function O(w){a(x,l,R,O,T,"next",w)}function T(w){a(x,l,R,O,T,"throw",w)}O(void 0)})}}},function(h,y){function a(r,o){for(var u=0;u<o.length;u++){var l=o[u];l.enumerable=l.enumerable||!1,l.configurable=!0,"value"in l&&(l.writable=!0),Object.defineProperty(r,l.key,l)}}h.exports=function(r,o,u){return o&&a(r.prototype,o),u&&a(r,u),r}},function(h){h.exports={name:"fortmatic",version:"1.1.3",description:"Fortmatic Javascript SDK",main:"lib/fortmatic.js",scripts:{build:"WEBPACK_ENV=production webpack","build:dev":"WEBPACK_ENV=development BABEL_ENV=development webpack --progress --colors --watch",test:"nyc --reporter=lcov --reporter=text-summary ava"},author:"Fortmatic <team@fortmatic.com> (https://fortmatic.com/)",license:"MIT",repository:{type:"git",url:"https://github.com/fortmatic/fortmatic-js"},keywords:["Auth","Login","Web3","Crypto","Ethereum","MetaMask","Wallet","Blockchain","Dapp"],homepage:"https://www.fortmatic.com",ava:{require:["@babel/register"],files:["test/**/*.spec.js"],babel:{testOptions:{presets:["@babel/env"],plugins:["@babel/plugin-proposal-function-bind","@babel/plugin-transform-runtime"]}},verbose:!0},nyc:{all:!1,"check-coverage":!0,"per-file":!0,lines:80,statements:80,functions:80,branches:80,include:["src/**/*.js"],exclude:["*/style.js"],require:[],reporter:["html","lcov"]},dependencies:{"@babel/runtime":"7.3.4"},devDependencies:{"@babel/core":"7.3.4","@babel/plugin-proposal-function-bind":"7.2.0","@babel/plugin-transform-modules-commonjs":"7.2.0","@babel/plugin-transform-runtime":"7.3.4","@babel/preset-env":"7.3.4","@babel/register":"7.0.0",ava:"2.2.0","babel-eslint":"10.0.1","babel-loader":"8.0.5",eslint:"5.9.0",lodash:"4.17.11",nyc:"13.1.0",sinon:"7.1.1",webpack:"4.26.1","webpack-cli":"3.1.2"}}},function(h,y,a){y.css=`
|
|
1
|
+
import{g as Z}from"./index-d1b7c41c.js";function $(h,y){for(var a=0;a<y.length;a++){const r=y[a];if(typeof r!="string"&&!Array.isArray(r)){for(const o in r)if(o!=="default"&&!(o in h)){const u=Object.getOwnPropertyDescriptor(r,o);u&&Object.defineProperty(h,o,u.get?u:{enumerable:!0,get:()=>r[o]})}}}return Object.freeze(Object.defineProperty(h,Symbol.toStringTag,{value:"Module"}))}var z=function(h){var y={};function a(r){if(y[r])return y[r].exports;var o=y[r]={i:r,l:!1,exports:{}};return h[r].call(o.exports,o,o.exports,a),o.l=!0,o.exports}return a.m=h,a.c=y,a.d=function(r,o,u){a.o(r,o)||Object.defineProperty(r,o,{enumerable:!0,get:u})},a.r=function(r){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(r,"__esModule",{value:!0})},a.t=function(r,o){if(1&o&&(r=a(r)),8&o||4&o&&typeof r=="object"&&r&&r.__esModule)return r;var u=Object.create(null);if(a.r(u),Object.defineProperty(u,"default",{enumerable:!0,value:r}),2&o&&typeof r!="string")for(var l in r)a.d(u,l,(function(R){return r[R]}).bind(null,l));return u},a.n=function(r){var o=r&&r.__esModule?function(){return r.default}:function(){return r};return a.d(o,"a",o),o},a.o=function(r,o){return Object.prototype.hasOwnProperty.call(r,o)},a.p="",a(a.s=3)}([function(h,y){h.exports=function(a){return a&&a.__esModule?a:{default:a}}},function(h,y){h.exports=function(a,r){if(!(a instanceof r))throw new TypeError("Cannot call a class as a function")}},function(h,y,a){function r(){return Math.floor(9e4*Math.random())+1e4}Object.defineProperty(y,"__esModule",{value:!0}),y.sendAsyncWrapper=function(o,u){var l=this;return new Promise(function(R,x){l.sendAsync({jsonrpc:"2.0",id:r(),method:o,params:u||[]},function(O,T){O?x(O):R(T.result)})})},y.sendFortmaticAsyncWrapper=function(o){var u=this;return new Promise(function(l,R){u.getProvider().sendFortmaticAsync(o,function(x,O){x?R(x):l(O?O.result:{})})})},y.randomId=r,y.findExistingResponse=function(o,u){for(var l=0;l<o.length;l++)if(o[l].id===u)return o[l];return null}},function(h,y,a){h.exports=a(4)},function(h,y,a){var r=a(0),o=r(a(1)),u=r(a(5)),l=a(2),R="fm_composeSend",x="fm_logout",O="fm_get_balances",T="fm_get_transactions",w="fm_is_logged_in",P="fm_accountSettings",n="fm_deposit",s="fm_get_user",c="fm_configure",f={};h.exports=function b(_,A,I){var v=this;if((0,o.default)(this,b),this.fortmaticClient="https://x2.fortmatic.com",!_)throw new Error("Please provide a Fortmatic API key that you acquired from the developer dashboard.");this.apiKey=_,this.options=I,this.ethNetwork=A,this.queryParams=btoa(JSON.stringify({API_KEY:_,ETH_NETWORK:A})),this.transactions={send:function(m,M){var C=new g(R,{to:m.to,value:m.amount});v.getProvider().sendFortmaticAsync(C,M)}},this.getProvider=function(){return f["fortmatic-".concat(v.queryParams)]||(f["fortmatic-".concat(v.queryParams)]=new u.default(v.fortmaticClient,{API_KEY:_,ETH_NETWORK:A})),f["fortmatic-".concat(v.queryParams)]},this.user={login:function(){return v.getProvider().enable()},logout:function(){v.getProvider().account=null,v.getProvider().network=null;var m=new g(x);return l.sendFortmaticAsyncWrapper.call(v,m)},getUser:function(){var m=new g(s);return l.sendFortmaticAsyncWrapper.call(v,m)},getBalances:function(){var m=new g(O);return l.sendFortmaticAsyncWrapper.call(v,m)},getTransactions:function(){var m=new g(T);return l.sendFortmaticAsyncWrapper.call(v,m)},isLoggedIn:function(){var m=new g(w);return l.sendFortmaticAsyncWrapper.call(v,m)},settings:function(){var m=new g(P);return l.sendFortmaticAsyncWrapper.call(v,m)},deposit:function(m){var M=new g(n,m);return l.sendFortmaticAsyncWrapper.call(v,M)}},this.configure=function(){var m=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},M=new g(c);return M.params=[m],l.sendFortmaticAsyncWrapper.call(v,M)}};var g=function b(_,A){(0,o.default)(this,b),this.id=(0,l.randomId)(),this.method=_,this.params=A?[A]:[{}]}},function(h,y,a){var r=a(0);Object.defineProperty(y,"__esModule",{value:!0}),y.default=void 0;var o=r(a(6)),u=r(a(9)),l=r(a(1)),R=r(a(10)),x=a(11),O=r(a(12)),T=a(2),w=function(){function P(n,s){if((0,l.default)(this,P),this.fortmaticClient=n,this.requests={},this.queue=[],this.account=null,this.network=null,this.isFortmatic=!0,this.overlayReady=!1,this.isLoggedIn=!1,this.postMessages={FORTMATIC_HANDLE_BATCH_REQUEST:"FORTMATIC_HANDLE_BATCH_REQUEST",FORTMATIC_HANDLE_REQUEST:"FORTMATIC_HANDLE_REQUEST",FORTMATIC_HANDLE_FORTMATIC_REQUEST:"FORTMATIC_HANDLE_FORTMATIC_REQUEST",FORTMATIC_HANDLE_RESPONSE:"FORTMATIC_HANDLE_RESPONSE",FORTMATIC_OVERLAY_READY:"FORTMATIC_OVERLAY_READY",FORTMATIC_SHOW_OVERLAY:"FORTMATIC_SHOW_OVERLAY",FORTMATIC_HIDE_OVERLAY:"FORTMATIC_HIDE_OVERLAY",FORTMATIC_USER_DENIED:"FORTMATIC_USER_DENIED",FORTMATIC_USER_LOGOUT:"FORTMATIC_USER_LOGOUT",FORTMATIC_UNAUTHORIZED_API_KEY:"FORTMATIC_UNAUTHORIZED_API_KEY"},!s.API_KEY)throw new Error("Please provide a Fortmatic API key that you acquired from the developer dashboard.");this.options={API_KEY:s.API_KEY,ETH_NETWORK:s.ETH_NETWORK,DOMAIN_ORIGIN:window.location?window.location.origin:"",version:x.version},this.queryParams=btoa(JSON.stringify(this.options)),this.constructPostMessage(),this.overlay=this.createOverlay(),this.listenMessage()}return(0,R.default)(P,[{key:"constructPostMessage",value:function(){var n=this;Object.keys(this.postMessages).map(function(s){n.postMessages[s]+="-".concat(n.queryParams)})}},{key:"createOverlay",value:function(){var n=this;return new Promise(function(s,c){var f=function(){if(function(){var A=!0,I=!1,v=void 0;try{for(var m,M=document.getElementsByClassName("fortmatic-iframe")[Symbol.iterator]();!(A=(m=M.next()).done);A=!0)if(m.value.src.includes(n.queryParams))return!1}catch(C){I=!0,v=C}finally{try{A||M.return==null||M.return()}finally{if(I)throw v}}return!0}()){var g=document.createElement("style");g.innerHTML=O.default.css,g.type="text/css",document.head.appendChild(g);var b=document.createElement("iframe");b.className="fortmatic-iframe",b.src="".concat(n.fortmaticClient,"/send?params=").concat(n.queryParams),document.body.appendChild(b);var _=document.createElement("img");_.src="https://static.fortmatic.com/assets/trans.gif",document.body.appendChild(_),s({iframe:b})}else console.error("Fortmatic: Duplicate instances found.")};["loaded","interactive","complete"].indexOf(document.readyState)>-1?f():window.addEventListener("load",f.bind(n),!1)})}},{key:"showOverlay",value:function(){var n=(0,u.default)(o.default.mark(function s(){return o.default.wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.next=2,this.overlay;case 2:c.sent.iframe.style.display="block";case 4:case"end":return c.stop()}},s,this)}));return function(){return n.apply(this,arguments)}}()},{key:"hideOverlay",value:function(){var n=(0,u.default)(o.default.mark(function s(){return o.default.wrap(function(c){for(;;)switch(c.prev=c.next){case 0:return c.next=2,this.overlay;case 2:c.sent.iframe.style.display="none";case 4:case"end":return c.stop()}},s,this)}));return function(){return n.apply(this,arguments)}}()},{key:"sendAsync",value:function(n,s){n.length>0?this.enqueue({payload:{id:(0,T.randomId)(),batch:n.map(function(c){return c.id=(0,T.randomId)(),c}),method:"eth_batchRequest"},cb:s}):this.enqueue({payload:n,cb:s})}},{key:"sendFortmaticAsync",value:function(n,s){this.enqueue({payload:n,cb:s,isNative:!0})}},{key:"send",value:function(n,s){if(typeof n=="string")return T.sendAsyncWrapper.call(this,n,s);if(!s){console.warn("Non-async web3 methods will be deprecated in web3 > 1.0, and are not supported by the Fortmatic provider. An async method to be used instead."),this.sendAsync(n,function(){});var c={};switch(n.method){case"eth_accounts":c=this.account?[this.account]:[];break;case"eth_coinbase":c=this.account;break;case"net_version":c=this.network||(this.options.API_KEY.startsWith("pk_live")?1:4);break;case"eth_uninstallFilter":c=!0;break;default:c={}}return{id:n.id,jsonrpc:n.jsonrpc,result:c}}this.sendAsync(n,s)}},{key:"enqueue",value:function(n){this.queue.push(n),this.overlayReady&&this.dequeue()}},{key:"dequeue",value:function(){var n=(0,u.default)(o.default.mark(function s(){var c,f,g,b=this;return o.default.wrap(function(_){for(;;)switch(_.prev=_.next){case 0:if(this.queue.length!==0){_.next=2;break}return _.abrupt("return");case 2:if(!(c=this.queue.shift())){_.next=11;break}return f=c.payload,g=c.cb,f.id=(0,T.randomId)(),_.next=9,this.postMessage(c.isNative?this.postMessages.FORTMATIC_HANDLE_FORTMATIC_REQUEST:this.postMessages.FORTMATIC_HANDLE_REQUEST,c.payload);case 9:f.batch&&f.batch.length>0?(f.batch.forEach(function(A){b.requests[A.id]={parentId:f.id,payload:A,cb:function(I,v){var m=b.requests[f.id].batchResponse;if(I&&I.response&&!(0,T.findExistingResponse)(m,I.response.id))throw m.push({jsonrpc:"2.0",id:I.response.id,error:{code:I.response.code,message:I.response.message}}),b.requests[f.id].cb(null,m),I.response;if(v&&v.result&&!(0,T.findExistingResponse)(m,v.id))return m.push(v);throw new Error("Fortmatic: unexpected callback behavior")}}}),this.requests[f.id]={payload:f,cb:g,batchResponse:[]}):this.requests[f.id]={payload:f,cb:g},this.dequeue();case 11:case"end":return _.stop()}},s,this)}));return function(){return n.apply(this,arguments)}}()},{key:"postMessage",value:function(){var n=(0,u.default)(o.default.mark(function s(c,f){var g;return o.default.wrap(function(b){for(;;)switch(b.prev=b.next){case 0:return b.next=2,this.overlay;case 2:if(!(g=b.sent).iframe.contentWindow){b.next=7;break}g.iframe.contentWindow.postMessage({msgType:c,payload:f},"*"),b.next=8;break;case 7:throw new Error("Fortmatic: Modal is not ready.");case 8:case"end":return b.stop()}},s,this)}));return function(s,c){return n.apply(this,arguments)}}()},{key:"enable",value:function(){return T.sendAsyncWrapper.call(this,"eth_accounts")}},{key:"listenMessage",value:function(){var n=this;window.addEventListener("message",function(s){if(s.origin===n.fortmaticClient){var c=s.data.response?s.data.response.id:null;switch(s.data.msgType){case n.postMessages.FORTMATIC_OVERLAY_READY:n.overlayReady=!0,n.dequeue();break;case n.postMessages.FORTMATIC_HANDLE_RESPONSE:try{n.requests[c].cb(null,s.data.response);var f=n.requests[c].parentId;f&&n.requests[f].payload.batch.length===n.requests[f].batchResponse.length&&n.requests[f].cb(null,n.requests[f].batchResponse),n.requests[c].payload.method==="eth_accounts"?n.account=s.data.response.result[0]:n.requests[c].payload.method==="eth_coinbase"?n.account=s.data.response.result:n.requests[c].payload.method==="net_version"&&(n.network=s.data.response.result)}catch{}n.isLoggedIn=!0,n.dequeue();break;case n.postMessages.FORTMATIC_HIDE_OVERLAY:n.hideOverlay();break;case n.postMessages.FORTMATIC_SHOW_OVERLAY:n.showOverlay();break;case n.postMessages.FORTMATIC_USER_LOGOUT:n.account=null,n.network=null,n.isLoggedIn=!1;break;case n.postMessages.FORTMATIC_UNAUTHORIZED_API_KEY:throw n.overlayReady=!1,new Error("Given API key is not authorized to access the resource.");case n.postMessages.FORTMATIC_USER_DENIED:if(c){var g=s.data.response&&s.data.response.message?s.data.response.message:"Fortmatic: Modal was closed without executing action!",b=s.data.response&&s.data.response.code?s.data.response.code:1;n.requests[c].cb({message:g,code:b,response:s.data.response})}else n.queue.forEach(function(_){return _.cb({message:"Fortmatic: Modal was closed without executing action!",code:1})});n.dequeue()}}})}}]),P}();y.default=w},function(h,y,a){h.exports=a(7)},function(h,y,a){var r=function(){return this||typeof self=="object"&&self}()||Function("return this")(),o=r.regeneratorRuntime&&Object.getOwnPropertyNames(r).indexOf("regeneratorRuntime")>=0,u=o&&r.regeneratorRuntime;if(r.regeneratorRuntime=void 0,h.exports=a(8),o)r.regeneratorRuntime=u;else try{delete r.regeneratorRuntime}catch{r.regeneratorRuntime=void 0}},function(h,y){(function(a){var r,o=Object.prototype,u=o.hasOwnProperty,l=typeof Symbol=="function"?Symbol:{},R=l.iterator||"@@iterator",x=l.asyncIterator||"@@asyncIterator",O=l.toStringTag||"@@toStringTag",T=typeof h=="object",w=a.regeneratorRuntime;if(w)T&&(h.exports=w);else{(w=a.regeneratorRuntime=T?h.exports:{}).wrap=I;var P="suspendedStart",n="suspendedYield",s="executing",c="completed",f={},g={};g[R]=function(){return this};var b=Object.getPrototypeOf,_=b&&b(b(G([])));_&&_!==o&&u.call(_,R)&&(g=_);var A=C.prototype=m.prototype=Object.create(g);M.prototype=A.constructor=C,C.constructor=M,C[O]=M.displayName="GeneratorFunction",w.isGeneratorFunction=function(t){var e=typeof t=="function"&&t.constructor;return!!e&&(e===M||(e.displayName||e.name)==="GeneratorFunction")},w.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,C):(t.__proto__=C,O in t||(t[O]="GeneratorFunction")),t.prototype=Object.create(A),t},w.awrap=function(t){return{__await:t}},V(U.prototype),U.prototype[x]=function(){return this},w.AsyncIterator=U,w.async=function(t,e,d,p){var i=new U(I(t,e,d,p));return w.isGeneratorFunction(e)?i:i.next().then(function(F){return F.done?F.value:i.next()})},V(A),A[O]="Generator",A[R]=function(){return this},A.toString=function(){return"[object Generator]"},w.keys=function(t){var e=[];for(var d in t)e.push(d);return e.reverse(),function p(){for(;e.length;){var i=e.pop();if(i in t)return p.value=i,p.done=!1,p}return p.done=!0,p}},w.values=G,K.prototype={constructor:K,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=r,this.done=!1,this.delegate=null,this.method="next",this.arg=r,this.tryEntries.forEach(Y),!t)for(var e in this)e.charAt(0)==="t"&&u.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=r)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if(t.type==="throw")throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function d(W,E){return F.type="throw",F.arg=t,e.next=W,E&&(e.method="next",e.arg=r),!!E}for(var p=this.tryEntries.length-1;p>=0;--p){var i=this.tryEntries[p],F=i.completion;if(i.tryLoc==="root")return d("end");if(i.tryLoc<=this.prev){var j=u.call(i,"catchLoc"),q=u.call(i,"finallyLoc");if(j&&q){if(this.prev<i.catchLoc)return d(i.catchLoc,!0);if(this.prev<i.finallyLoc)return d(i.finallyLoc)}else if(j){if(this.prev<i.catchLoc)return d(i.catchLoc,!0)}else{if(!q)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return d(i.finallyLoc)}}}},abrupt:function(t,e){for(var d=this.tryEntries.length-1;d>=0;--d){var p=this.tryEntries[d];if(p.tryLoc<=this.prev&&u.call(p,"finallyLoc")&&this.prev<p.finallyLoc){var i=p;break}}i&&(t==="break"||t==="continue")&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var F=i?i.completion:{};return F.type=t,F.arg=e,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(F)},complete:function(t,e){if(t.type==="throw")throw t.arg;return t.type==="break"||t.type==="continue"?this.next=t.arg:t.type==="return"?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):t.type==="normal"&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var d=this.tryEntries[e];if(d.finallyLoc===t)return this.complete(d.completion,d.afterLoc),Y(d),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var d=this.tryEntries[e];if(d.tryLoc===t){var p=d.completion;if(p.type==="throw"){var i=p.arg;Y(d)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,d){return this.delegate={iterator:G(t),resultName:e,nextLoc:d},this.method==="next"&&(this.arg=r),f}}}function I(t,e,d,p){var i=e&&e.prototype instanceof m?e:m,F=Object.create(i.prototype),j=new K(p||[]);return F._invoke=function(q,W,E){var L=P;return function(S,D){if(L===s)throw new Error("Generator is already running");if(L===c){if(S==="throw")throw D;return Q()}for(E.method=S,E.arg=D;;){var H=E.delegate;if(H){var N=B(H,E);if(N){if(N===f)continue;return N}}if(E.method==="next")E.sent=E._sent=E.arg;else if(E.method==="throw"){if(L===P)throw L=c,E.arg;E.dispatchException(E.arg)}else E.method==="return"&&E.abrupt("return",E.arg);L=s;var k=v(q,W,E);if(k.type==="normal"){if(L=E.done?c:n,k.arg===f)continue;return{value:k.arg,done:E.done}}k.type==="throw"&&(L=c,E.method="throw",E.arg=k.arg)}}}(t,d,j),F}function v(t,e,d){try{return{type:"normal",arg:t.call(e,d)}}catch(p){return{type:"throw",arg:p}}}function m(){}function M(){}function C(){}function V(t){["next","throw","return"].forEach(function(e){t[e]=function(d){return this._invoke(e,d)}})}function U(t){var e;this._invoke=function(d,p){function i(){return new Promise(function(F,j){(function q(W,E,L,S){var D=v(t[W],t,E);if(D.type!=="throw"){var H=D.arg,N=H.value;return N&&typeof N=="object"&&u.call(N,"__await")?Promise.resolve(N.__await).then(function(k){q("next",k,L,S)},function(k){q("throw",k,L,S)}):Promise.resolve(N).then(function(k){H.value=k,L(H)},function(k){return q("throw",k,L,S)})}S(D.arg)})(d,p,F,j)})}return e=e?e.then(i,i):i()}}function B(t,e){var d=t.iterator[e.method];if(d===r){if(e.delegate=null,e.method==="throw"){if(t.iterator.return&&(e.method="return",e.arg=r,B(t,e),e.method==="throw"))return f;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return f}var p=v(d,t.iterator,e.arg);if(p.type==="throw")return e.method="throw",e.arg=p.arg,e.delegate=null,f;var i=p.arg;return i?i.done?(e[t.resultName]=i.value,e.next=t.nextLoc,e.method!=="return"&&(e.method="next",e.arg=r),e.delegate=null,f):i:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function J(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function Y(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function K(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(J,this),this.reset(!0)}function G(t){if(t){var e=t[R];if(e)return e.call(t);if(typeof t.next=="function")return t;if(!isNaN(t.length)){var d=-1,p=function i(){for(;++d<t.length;)if(u.call(t,d))return i.value=t[d],i.done=!1,i;return i.value=r,i.done=!0,i};return p.next=p}}return{next:Q}}function Q(){return{value:r,done:!0}}})(function(){return this||typeof self=="object"&&self}()||Function("return this")())},function(h,y){function a(r,o,u,l,R,x,O){try{var T=r[x](O),w=T.value}catch(P){return void u(P)}T.done?o(w):Promise.resolve(w).then(l,R)}h.exports=function(r){return function(){var o=this,u=arguments;return new Promise(function(l,R){var x=r.apply(o,u);function O(w){a(x,l,R,O,T,"next",w)}function T(w){a(x,l,R,O,T,"throw",w)}O(void 0)})}}},function(h,y){function a(r,o){for(var u=0;u<o.length;u++){var l=o[u];l.enumerable=l.enumerable||!1,l.configurable=!0,"value"in l&&(l.writable=!0),Object.defineProperty(r,l.key,l)}}h.exports=function(r,o,u){return o&&a(r.prototype,o),u&&a(r,u),r}},function(h){h.exports={name:"fortmatic",version:"1.1.3",description:"Fortmatic Javascript SDK",main:"lib/fortmatic.js",scripts:{build:"WEBPACK_ENV=production webpack","build:dev":"WEBPACK_ENV=development BABEL_ENV=development webpack --progress --colors --watch",test:"nyc --reporter=lcov --reporter=text-summary ava"},author:"Fortmatic <team@fortmatic.com> (https://fortmatic.com/)",license:"MIT",repository:{type:"git",url:"https://github.com/fortmatic/fortmatic-js"},keywords:["Auth","Login","Web3","Crypto","Ethereum","MetaMask","Wallet","Blockchain","Dapp"],homepage:"https://www.fortmatic.com",ava:{require:["@babel/register"],files:["test/**/*.spec.js"],babel:{testOptions:{presets:["@babel/env"],plugins:["@babel/plugin-proposal-function-bind","@babel/plugin-transform-runtime"]}},verbose:!0},nyc:{all:!1,"check-coverage":!0,"per-file":!0,lines:80,statements:80,functions:80,branches:80,include:["src/**/*.js"],exclude:["*/style.js"],require:[],reporter:["html","lcov"]},dependencies:{"@babel/runtime":"7.3.4"},devDependencies:{"@babel/core":"7.3.4","@babel/plugin-proposal-function-bind":"7.2.0","@babel/plugin-transform-modules-commonjs":"7.2.0","@babel/plugin-transform-runtime":"7.3.4","@babel/preset-env":"7.3.4","@babel/register":"7.0.0",ava:"2.2.0","babel-eslint":"10.0.1","babel-loader":"8.0.5",eslint:"5.9.0",lodash:"4.17.11",nyc:"13.1.0",sinon:"7.1.1",webpack:"4.26.1","webpack-cli":"3.1.2"}}},function(h,y,a){y.css=`
|
|
2
2
|
.fortmatic-iframe {
|
|
3
3
|
display: none;
|
|
4
4
|
position: fixed;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{S as $,T as G,t as I,a as F,U as q,V as N,W as V,X,Y,Z,_,c as z,$ as J}from"./index-
|
|
1
|
+
import{S as $,T as G,t as I,a as F,U as q,V as N,W as V,X,Y,Z,_,c as z,$ as J}from"./index-d1b7c41c.js";var E=$,K=G,f=I,O=F,Q=function(r,n,e){if(!r||typeof r!="object"&&typeof r!="function")throw new f("`obj` must be an object or a function`");if(typeof n!="string"&&typeof n!="symbol")throw new f("`property` must be a string or a symbol`");if(arguments.length>3&&typeof arguments[3]!="boolean"&&arguments[3]!==null)throw new f("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!="boolean"&&arguments[4]!==null)throw new f("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!="boolean"&&arguments[5]!==null)throw new f("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!="boolean")throw new f("`loose`, if provided, must be a boolean");var t=arguments.length>3?arguments[3]:null,o=arguments.length>4?arguments[4]:null,l=arguments.length>5?arguments[5]:null,h=arguments.length>6?arguments[6]:!1,i=!!O&&O(r,n);if(E)E(r,n,{configurable:l===null&&i?i.configurable:!l,enumerable:t===null&&i?i.enumerable:!t,value:e,writable:o===null&&i?i.writable:!o});else if(h||!t&&!o&&!l)r[n]=e;else throw new K("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")},d=$,M=function(){return!!d};M.hasArrayLengthDefineBug=function(){if(!d)return null;try{return d([],"length",{value:1}).length!==1}catch{return!0}};var k=M,U={exports:{}},rr=q,B=Q,nr=k(),D=F,P=I,tr=rr("%Math.floor%"),er=function(r,n){if(typeof r!="function")throw new P("`fn` is not a function");if(typeof n!="number"||n<0||n>4294967295||tr(n)!==n)throw new P("`length` must be a positive 32-bit integer");var e=arguments.length>2&&!!arguments[2],t=!0,o=!0;if("length"in r&&D){var l=D(r,"length");l&&!l.configurable&&(t=!1),l&&!l.writable&&(o=!1)}return(t||o||!e)&&(nr?B(r,"length",n,!0,!0):B(r,"length",n)),r},ar=N(),or=V(),lr=X,ir=function(){return lr(ar,or,arguments)};(function(a){var r=er,n=$,e=Y,t=ir;a.exports=function(l){var h=e(arguments),i=l.length-(arguments.length-1);return r(h,1+(i>0?i:0),!0)},n?n(a.exports,"apply",{value:t}):a.exports.apply=t})(U);var fr=U.exports,sr=Z,ur=function(){return sr()&&!!Symbol.toStringTag},H=Function.prototype.toString,s=typeof Reflect=="object"&&Reflect!==null&&Reflect.apply,A,c;if(typeof s=="function"&&typeof Object.defineProperty=="function")try{A=Object.defineProperty({},"length",{get:function(){throw c}}),c={},s(function(){throw 42},null,A)}catch(a){a!==c&&(s=null)}else s=null;var cr=/^\s*class\b/,S=function(r){try{var n=H.call(r);return cr.test(n)}catch{return!1}},b=function(r){try{return S(r)?!1:(H.call(r),!0)}catch{return!1}},y=Object.prototype.toString,yr="[object Object]",gr="[object Function]",pr="[object GeneratorFunction]",vr="[object HTMLAllCollection]",hr="[object HTML document.all class]",br="[object HTMLCollection]",mr=typeof Symbol=="function"&&!!Symbol.toStringTag,dr=!(0 in[,]),T=function(){return!1};if(typeof document=="object"){var Ar=document.all;y.call(Ar)===y.call(document.all)&&(T=function(r){if((dr||!r)&&(typeof r>"u"||typeof r=="object"))try{var n=y.call(r);return(n===vr||n===hr||n===br||n===yr)&&r("")==null}catch{}return!1})}var Sr=s?function(r){if(T(r))return!0;if(!r||typeof r!="function"&&typeof r!="object")return!1;try{s(r,null,A)}catch(n){if(n!==c)return!1}return!S(r)&&b(r)}:function(r){if(T(r))return!0;if(!r||typeof r!="function"&&typeof r!="object")return!1;if(mr)return b(r);if(S(r))return!1;var n=y.call(r);return n!==gr&&n!==pr&&!/^\[object HTML/.test(n)?!1:b(r)},Tr=Sr,wr=Object.prototype.toString,R=Object.prototype.hasOwnProperty,$r=function(r,n,e){for(var t=0,o=r.length;t<o;t++)R.call(r,t)&&(e==null?n(r[t],t,r):n.call(e,r[t],t,r))},Fr=function(r,n,e){for(var t=0,o=r.length;t<o;t++)e==null?n(r.charAt(t),t,r):n.call(e,r.charAt(t),t,r)},jr=function(r,n,e){for(var t in r)R.call(r,t)&&(e==null?n(r[t],t,r):n.call(e,r[t],t,r))};function Cr(a){return wr.call(a)==="[object Array]"}var Er=function(r,n,e){if(!Tr(n))throw new TypeError("iterator must be a function");var t;arguments.length>=3&&(t=e),Cr(r)?$r(r,n,t):typeof r=="string"?Fr(r,n,t):jr(r,n,t)},Or=["Float16Array","Float32Array","Float64Array","Int8Array","Int16Array","Int32Array","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array"],m=Or,Br=typeof globalThis>"u"?_:globalThis,Dr=function(){for(var r=[],n=0;n<m.length;n++)typeof Br[m[n]]=="function"&&(r[r.length]=m[n]);return r},p=Er,Pr=Dr,x=fr,j=z,g=F,u=J,xr=j("Object.prototype.toString"),W=ur(),L=typeof globalThis>"u"?_:globalThis,w=Pr(),C=j("String.prototype.slice"),Lr=j("Array.prototype.indexOf",!0)||function(r,n){for(var e=0;e<r.length;e+=1)if(r[e]===n)return e;return-1},v={__proto__:null};W&&g&&u?p(w,function(a){var r=new L[a];if(Symbol.toStringTag in r&&u){var n=u(r),e=g(n,Symbol.toStringTag);if(!e&&n){var t=u(n);e=g(t,Symbol.toStringTag)}if(e&&e.get){var o=x(e.get);v["$"+a]=o}}}):p(w,function(a){var r=new L[a],n=r.slice||r.set;if(n){var e=x(n);v["$"+a]=e}});var Ir=function(r){var n=!1;return p(v,function(e,t){if(!n)try{"$"+e(r)===t&&(n=C(t,1))}catch{}}),n},_r=function(r){var n=!1;return p(v,function(e,t){if(!n)try{e(r),n=C(t,1)}catch{}}),n},Ur=function(r){if(!r||typeof r!="object")return!1;if(!W){var n=C(xr(r),8,-1);return Lr(w,n)>-1?n:n!=="Object"?!1:_r(r)}return g?Ir(r):null};export{fr as c,Q as d,k as h,ur as s,Ur as w};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as g,r as m,k as u,l as p,m as n}from"./index-
|
|
1
|
+
import{j as g,r as m,k as u,l as p,m as n}from"./index-becc5f18.js";import{n as r,c as x}from"./index-ca30e4fd.js";import"./index-a3f378d1.js";import"./index-450d0678.js";const b=g`
|
|
2
2
|
button {
|
|
3
3
|
display: block;
|
|
4
4
|
display: flex;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as v,r as I,k as W,l as m,m as l,O as f,C as u,$ as Te,H as T,h as y,M as P,n as ee,E as C,K as fe,o as b,R as h,c as D,S as k,x,y as ze,W as Fe,af as Xt,ag as he,aa as J,a6 as Hi,G as A,ah as tt,u as Ai,U as Ki,Q as qi,P as Gi,T as mt,a0 as Yt,a1 as Qt,ai as Xi,a3 as Bt,aj as Yi}from"./index-
|
|
1
|
+
import{j as v,r as I,k as W,l as m,m as l,O as f,C as u,$ as Te,H as T,h as y,M as P,n as ee,E as C,K as fe,o as b,R as h,c as D,S as k,x,y as ze,W as Fe,af as Xt,ag as he,aa as J,a6 as Hi,G as A,ah as tt,u as Ai,U as Ki,Q as qi,P as Gi,T as mt,a0 as Yt,a1 as Qt,ai as Xi,a3 as Bt,aj as Yi}from"./index-becc5f18.js";import{n as c,c as p,U as F,r as d,b as Ii}from"./index-ca30e4fd.js";import{o as w}from"./if-defined-b80e1e5f.js";import"./index-a3f378d1.js";import"./index-44db0baa.js";import"./index-eb68ccad.js";import"./index-870741d2.js";import{a as Ta,W as Sa}from"./index-ac8937b9.js";import"./index-1def7b3c.js";import"./index-67d2807b.js";import"./index-ae732654.js";import{C as S}from"./NetworkUtil-a423d25a.js";import{H as Jt}from"./HelpersUtil-8166e848.js";import{n as Qi}from"./index-9fad67dc.js";import{E as Q}from"./ExchangeController-609a1f8c.js";import"./index-309c17e3.js";import"./index-445fe463.js";import"./index-b318296e.js";import{M as ft}from"./MathUtil-b514a570.js";import"./index-bfff18be.js";import{e as Zt,n as ei}from"./ref-93e8bc0a.js";import"./index-7ed20462.js";import"./index-450d0678.js";import"./index-f36edea8.js";import"./index-f8b8fc20.js";import{O as bt}from"./index-51ad1ac0.js";import{e as Ji}from"./index-ea4ab9a5.js";import"./index-5cb9cf07.js";import"./index-4e635b3b.js";import{N as Zi}from"./NavigationUtil-a0d0ce87.js";import"./index-a1808fcb.js";import"./index-d1b7c41c.js";import"./index-2e026425.js";import"./BlockOverrides-f0043737.js";import"./ConstantsUtil-e2cd00bd.js";const en=v`
|
|
2
2
|
:host {
|
|
3
3
|
display: block;
|
|
4
4
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as u,r as b,k as p,l as h,m as v}from"./index-
|
|
1
|
+
import{j as u,r as b,k as p,l as h,m as v}from"./index-becc5f18.js";import{n as r,c as f}from"./index-ca30e4fd.js";const g=u`
|
|
2
2
|
button {
|
|
3
3
|
background-color: transparent;
|
|
4
4
|
padding: ${({spacing:t})=>t[1]};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{r as np,a as zt,b as an,c as ap,d as rm,e as op,f as Ds,g as ip,h as nm,i as sp,j as Kc,k as am,l as cp}from"./BlockOverrides-
|
|
1
|
+
import{r as np,a as zt,b as an,c as ap,d as rm,e as op,f as Ds,g as ip,h as nm,i as sp,j as Kc,k as am,l as cp}from"./BlockOverrides-f0043737.js";import{b3 as up}from"./index-d1b7c41c.js";var Cc={},Xt={},xn={},td;function te(){if(td)return xn;td=1,Object.defineProperty(xn,"__esModule",{value:!0}),xn.getAction=e;function e(r,n,t){const i=r[n.name];if(typeof i=="function")return i;const s=r[t];return typeof s=="function"?s:o=>n(r,o)}return xn}var $n={},zn={},Z={},wr={},rd;function it(){if(rd)return wr;rd=1,Object.defineProperty(wr,"__esModule",{value:!0}),wr.formatAbiItem=r,wr.formatAbiParams=n;const e=ue();function r(i,{includeName:s=!1}={}){if(i.type!=="function"&&i.type!=="event"&&i.type!=="error")throw new e.InvalidDefinitionTypeError(i.type);return`${i.name}(${n(i.inputs,{includeName:s})})`}function n(i,{includeName:s=!1}={}){return i?i.map(o=>t(o,{includeName:s})).join(s?", ":","):""}function t(i,{includeName:s}){return i.type.startsWith("tuple")?`(${n(i.components,{includeName:s})})${i.type.slice(5)}`:i.type+(s&&i.name?` ${i.name}`:"")}return wr}var Dn={},Un={},nd;function he(){if(nd)return Un;nd=1,Object.defineProperty(Un,"__esModule",{value:!0}),Un.isHex=e;function e(r,{strict:n=!0}={}){return!r||typeof r!="string"?!1:n?/^0x[0-9a-fA-F]*$/.test(r):r.startsWith("0x")}return Un}var ad;function _e(){if(ad)return Dn;ad=1,Object.defineProperty(Dn,"__esModule",{value:!0}),Dn.size=r;const e=he();function r(n){return(0,e.isHex)(n,{strict:!1})?Math.ceil((n.length-2)/2):n.length}return Dn}var Qt={},Ar={},od;function dp(){return od||(od=1,Object.defineProperty(Ar,"__esModule",{value:!0}),Ar.version=void 0,Ar.version="2.45.0"),Ar}var id;function X(){if(id)return Qt;id=1,Object.defineProperty(Qt,"__esModule",{value:!0}),Qt.BaseError=void 0,Qt.setErrorConfig=n;const e=dp();let r={getDocsUrl:({docsBaseUrl:s,docsPath:o="",docsSlug:a})=>o?`${s??"https://viem.sh"}${o}${a?`#${a}`:""}`:void 0,version:`viem@${e.version}`};function n(s){r=s}class t extends Error{constructor(o,a={}){var l;const c=(()=>{var y;return a.cause instanceof t?a.cause.details:(y=a.cause)!=null&&y.message?a.cause.message:a.details})(),d=(()=>a.cause instanceof t&&a.cause.docsPath||a.docsPath)(),f=(l=r.getDocsUrl)==null?void 0:l.call(r,{...a,docsPath:d}),u=[o||"An error occurred.","",...a.metaMessages?[...a.metaMessages,""]:[],...f?[`Docs: ${f}`]:[],...c?[`Details: ${c}`]:[],...r.version?[`Version: ${r.version}`]:[]].join(`
|
|
2
2
|
`);super(u,a.cause?{cause:a.cause}:void 0),Object.defineProperty(this,"details",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"docsPath",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"metaMessages",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"shortMessage",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"version",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),Object.defineProperty(this,"name",{enumerable:!0,configurable:!0,writable:!0,value:"BaseError"}),this.details=c,this.docsPath=d,this.metaMessages=a.metaMessages,this.name=a.name??this.name,this.shortMessage=o,this.version=e.version}walk(o){return i(this,o)}}Qt.BaseError=t;function i(s,o){return o!=null&&o(s)?s:s&&typeof s=="object"&&"cause"in s&&s.cause!==void 0?i(s.cause,o):o?null:s}return Qt}var sd;function ue(){if(sd)return Z;sd=1,Object.defineProperty(Z,"__esModule",{value:!0}),Z.UnsupportedPackedAbiType=Z.InvalidDefinitionTypeError=Z.InvalidArrayError=Z.InvalidAbiDecodingTypeError=Z.InvalidAbiEncodingTypeError=Z.DecodeLogTopicsMismatch=Z.DecodeLogDataMismatch=Z.BytesSizeMismatchError=Z.AbiItemAmbiguityError=Z.AbiFunctionSignatureNotFoundError=Z.AbiFunctionOutputsNotFoundError=Z.AbiFunctionNotFoundError=Z.AbiEventNotFoundError=Z.AbiEventSignatureNotFoundError=Z.AbiEventSignatureEmptyTopicsError=Z.AbiErrorSignatureNotFoundError=Z.AbiErrorNotFoundError=Z.AbiErrorInputsNotFoundError=Z.AbiEncodingLengthMismatchError=Z.AbiEncodingBytesSizeMismatchError=Z.AbiEncodingArrayLengthMismatchError=Z.AbiDecodingZeroDataError=Z.AbiDecodingDataSizeTooSmallError=Z.AbiDecodingDataSizeInvalidError=Z.AbiConstructorParamsNotFoundError=Z.AbiConstructorNotFoundError=void 0;const e=it(),r=_e(),n=X();class t extends n.BaseError{constructor({docsPath:R}){super(["A constructor was not found on the ABI.","Make sure you are using the correct ABI and that the constructor exists on it."].join(`
|
|
3
3
|
`),{docsPath:R,name:"AbiConstructorNotFoundError"})}}Z.AbiConstructorNotFoundError=t;class i extends n.BaseError{constructor({docsPath:R}){super(["Constructor arguments were provided (`args`), but a constructor parameters (`inputs`) were not found on the ABI.","Make sure you are using the correct ABI, and that the `inputs` attribute on the constructor exists."].join(`
|
|
4
4
|
`),{docsPath:R,name:"AbiConstructorParamsNotFoundError"})}}Z.AbiConstructorParamsNotFoundError=i;class s extends n.BaseError{constructor({data:R,size:B}){super([`Data size of ${B} bytes is invalid.`,"Size must be in increments of 32 bytes (size % 32 === 0)."].join(`
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as ot,l as st,m as w,r as Tt,C as ht,a2 as F,h as gt,R as Ot,E as At,y as Ct,W as Ft,O as Nt}from"./index-a0eaa57b.js";import{U as vt,n as I,r as Q,c as at}from"./index-33c90fff.js";import{_ as mt,g as ft}from"./index-7b68384a.js";import"./index-ff62bbe7.js";import"./index-60a03db2.js";import{o as Rt}from"./if-defined-92244c26.js";import"./index-ff100d2b.js";import"./index-67ef8b4a.js";var _t={exports:{}};(function(t,e){(function(i,r){t.exports=r()})(mt,function(){var i=1e3,r=6e4,o=36e5,n="millisecond",s="second",u="minute",g="hour",h="day",y="week",$="month",L="quarter",D="year",N="date",Y="Invalid Date",X=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,tt=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,et={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(p){var l=["th","st","nd","rd"],a=p%100;return"["+p+(l[(a-20)%10]||l[a]||l[0])+"]"}},it=function(p,l,a){var d=String(p);return!d||d.length>=l?p:""+Array(l+1-d.length).join(a)+p},B={s:it,z:function(p){var l=-p.utcOffset(),a=Math.abs(l),d=Math.floor(a/60),c=a%60;return(l<=0?"+":"-")+it(d,2,"0")+":"+it(c,2,"0")},m:function p(l,a){if(l.date()<a.date())return-p(a,l);var d=12*(a.year()-l.year())+(a.month()-l.month()),c=l.clone().add(d,$),m=a-c<0,f=l.clone().add(d+(m?-1:1),$);return+(-(d+(a-c)/(m?c-f:f-c))||0)},a:function(p){return p<0?Math.ceil(p)||0:Math.floor(p)},p:function(p){return{M:$,y:D,w:y,d:h,D:N,h:g,m:u,s,ms:n,Q:L}[p]||String(p||"").toLowerCase().replace(/s$/,"")},u:function(p){return p===void 0}},S="en",O={};O[S]=et;var V="$isDayjsObject",W=function(p){return p instanceof lt||!(!p||!p[V])},ct=function p(l,a,d){var c;if(!l)return S;if(typeof l=="string"){var m=l.toLowerCase();O[m]&&(c=m),a&&(O[m]=a,c=m);var f=l.split("-");if(!c&&f.length>1)return p(f[0])}else{var b=l.name;O[b]=l,c=b}return!d&&c&&(S=c),c||!d&&S},T=function(p,l){if(W(p))return p.clone();var a=typeof l=="object"?l:{};return a.date=p,a.args=arguments,new lt(a)},x=B;x.l=ct,x.i=W,x.w=function(p,l){return T(p,{locale:l.$L,utc:l.$u,x:l.$x,$offset:l.$offset})};var lt=function(){function p(a){this.$L=ct(a.locale,null,!0),this.parse(a),this.$x=this.$x||a.x||{},this[V]=!0}var l=p.prototype;return l.parse=function(a){this.$d=function(d){var c=d.date,m=d.utc;if(c===null)return new Date(NaN);if(x.u(c))return new Date;if(c instanceof Date)return new Date(c);if(typeof c=="string"&&!/Z$/i.test(c)){var f=c.match(X);if(f){var b=f[2]-1||0,v=(f[7]||"0").substring(0,3);return m?new Date(Date.UTC(f[1],b,f[3]||1,f[4]||0,f[5]||0,f[6]||0,v)):new Date(f[1],b,f[3]||1,f[4]||0,f[5]||0,f[6]||0,v)}}return new Date(c)}(a),this.init()},l.init=function(){var a=this.$d;this.$y=a.getFullYear(),this.$M=a.getMonth(),this.$D=a.getDate(),this.$W=a.getDay(),this.$H=a.getHours(),this.$m=a.getMinutes(),this.$s=a.getSeconds(),this.$ms=a.getMilliseconds()},l.$utils=function(){return x},l.isValid=function(){return this.$d.toString()!==Y},l.isSame=function(a,d){var c=T(a);return this.startOf(d)<=c&&c<=this.endOf(d)},l.isAfter=function(a,d){return T(a)<this.startOf(d)},l.isBefore=function(a,d){return this.endOf(d)<T(a)},l.$g=function(a,d,c){return x.u(a)?this[d]:this.set(c,a)},l.unix=function(){return Math.floor(this.valueOf()/1e3)},l.valueOf=function(){return this.$d.getTime()},l.startOf=function(a,d){var c=this,m=!!x.u(d)||d,f=x.p(a),b=function(H,A){var z=x.w(c.$u?Date.UTC(c.$y,A,H):new Date(c.$y,A,H),c);return m?z:z.endOf(h)},v=function(H,A){return x.w(c.toDate()[H].apply(c.toDate("s"),(m?[0,0,0,0]:[23,59,59,999]).slice(A)),c)},_=this.$W,M=this.$M,C=this.$D,J="set"+(this.$u?"UTC":"");switch(f){case D:return m?b(1,0):b(31,11);case $:return m?b(1,M):b(0,M+1);case y:var P=this.$locale().weekStart||0,rt=(_<P?_+7:_)-P;return b(m?C-rt:C+(6-rt),M);case h:case N:return v(J+"Hours",0);case g:return v(J+"Minutes",1);case u:return v(J+"Seconds",2);case s:return v(J+"Milliseconds",3);default:return this.clone()}},l.endOf=function(a){return this.startOf(a,!1)},l.$set=function(a,d){var c,m=x.p(a),f="set"+(this.$u?"UTC":""),b=(c={},c[h]=f+"Date",c[N]=f+"Date",c[$]=f+"Month",c[D]=f+"FullYear",c[g]=f+"Hours",c[u]=f+"Minutes",c[s]=f+"Seconds",c[n]=f+"Milliseconds",c)[m],v=m===h?this.$D+(d-this.$W):d;if(m===$||m===D){var _=this.clone().set(N,1);_.$d[b](v),_.init(),this.$d=_.set(N,Math.min(this.$D,_.daysInMonth())).$d}else b&&this.$d[b](v);return this.init(),this},l.set=function(a,d){return this.clone().$set(a,d)},l.get=function(a){return this[x.p(a)]()},l.add=function(a,d){var c,m=this;a=Number(a);var f=x.p(d),b=function(M){var C=T(m);return x.w(C.date(C.date()+Math.round(M*a)),m)};if(f===$)return this.set($,this.$M+a);if(f===D)return this.set(D,this.$y+a);if(f===h)return b(1);if(f===y)return b(7);var v=(c={},c[u]=r,c[g]=o,c[s]=i,c)[f]||1,_=this.$d.getTime()+a*v;return x.w(_,this)},l.subtract=function(a,d){return this.add(-1*a,d)},l.format=function(a){var d=this,c=this.$locale();if(!this.isValid())return c.invalidDate||Y;var m=a||"YYYY-MM-DDTHH:mm:ssZ",f=x.z(this),b=this.$H,v=this.$m,_=this.$M,M=c.weekdays,C=c.months,J=c.meridiem,P=function(A,z,nt,dt){return A&&(A[z]||A(d,m))||nt[z].slice(0,dt)},rt=function(A){return x.s(b%12||12,A,"0")},H=J||function(A,z,nt){var dt=A<12?"AM":"PM";return nt?dt.toLowerCase():dt};return m.replace(tt,function(A,z){return z||function(nt){switch(nt){case"YY":return String(d.$y).slice(-2);case"YYYY":return x.s(d.$y,4,"0");case"M":return _+1;case"MM":return x.s(_+1,2,"0");case"MMM":return P(c.monthsShort,_,C,3);case"MMMM":return P(C,_);case"D":return d.$D;case"DD":return x.s(d.$D,2,"0");case"d":return String(d.$W);case"dd":return P(c.weekdaysMin,d.$W,M,2);case"ddd":return P(c.weekdaysShort,d.$W,M,3);case"dddd":return M[d.$W];case"H":return String(b);case"HH":return x.s(b,2,"0");case"h":return rt(1);case"hh":return rt(2);case"a":return H(b,v,!0);case"A":return H(b,v,!1);case"m":return String(v);case"mm":return x.s(v,2,"0");case"s":return String(d.$s);case"ss":return x.s(d.$s,2,"0");case"SSS":return x.s(d.$ms,3,"0");case"Z":return f}return null}(A)||f.replace(":","")})},l.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},l.diff=function(a,d,c){var m,f=this,b=x.p(d),v=T(a),_=(v.utcOffset()-this.utcOffset())*r,M=this-v,C=function(){return x.m(f,v)};switch(b){case D:m=C()/12;break;case $:m=C();break;case L:m=C()/3;break;case y:m=(M-_)/6048e5;break;case h:m=(M-_)/864e5;break;case g:m=M/o;break;case u:m=M/r;break;case s:m=M/i;break;default:m=M}return c?m:x.a(m)},l.daysInMonth=function(){return this.endOf($).$D},l.$locale=function(){return O[this.$L]},l.locale=function(a,d){if(!a)return this.$L;var c=this.clone(),m=ct(a,d,!0);return m&&(c.$L=m),c},l.clone=function(){return x.w(this.$d,this)},l.toDate=function(){return new Date(this.valueOf())},l.toJSON=function(){return this.isValid()?this.toISOString():null},l.toISOString=function(){return this.$d.toISOString()},l.toString=function(){return this.$d.toUTCString()},p}(),$t=lt.prototype;return T.prototype=$t,[["$ms",n],["$s",s],["$m",u],["$H",g],["$W",h],["$M",$],["$y",D],["$D",N]].forEach(function(p){$t[p[1]]=function(l){return this.$g(l,p[0],p[1])}}),T.extend=function(p,l){return p.$i||(p(l,lt,T),p.$i=!0),T},T.locale=ct,T.isDayjs=W,T.unix=function(p){return T(1e3*p)},T.en=O[S],T.Ls=O,T.p={},T})})(_t);var jt=_t.exports;const K=ft(jt);var It={exports:{}};(function(t,e){(function(i,r){t.exports=r()})(mt,function(){return{name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(i){var r=["th","st","nd","rd"],o=i%100;return"["+i+(r[(o-20)%10]||r[o]||r[0])+"]"}}})})(It);var Lt=It.exports;const kt=ft(Lt);var Mt={exports:{}};(function(t,e){(function(i,r){t.exports=r()})(mt,function(){return function(i,r,o){i=i||{};var n=r.prototype,s={future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function u(h,y,$,L){return n.fromToBase(h,y,$,L)}o.en.relativeTime=s,n.fromToBase=function(h,y,$,L,D){for(var N,Y,X,tt=$.$locale().relativeTime||s,et=i.thresholds||[{l:"s",r:44,d:"second"},{l:"m",r:89},{l:"mm",r:44,d:"minute"},{l:"h",r:89},{l:"hh",r:21,d:"hour"},{l:"d",r:35},{l:"dd",r:25,d:"day"},{l:"M",r:45},{l:"MM",r:10,d:"month"},{l:"y",r:17},{l:"yy",d:"year"}],it=et.length,B=0;B<it;B+=1){var S=et[B];S.d&&(N=L?o(h).diff($,S.d,!0):$.diff(h,S.d,!0));var O=(i.rounding||Math.round)(Math.abs(N));if(X=N>0,O<=S.r||!S.r){O<=1&&B>0&&(S=et[B-1]);var V=tt[S.l];D&&(O=D(""+O)),Y=typeof V=="string"?V.replace("%d",O):V(O,y,S.l,X);break}}if(y)return Y;var W=X?tt.future:tt.past;return typeof W=="function"?W(Y):W.replace("%s",Y)},n.to=function(h,y){return u(h,y,this,!0)},n.from=function(h,y){return u(h,y,this)};var g=function(h){return h.$u?o.utc():o()};n.toNow=function(h){return this.to(g(this),h)},n.fromNow=function(h){return this.from(g(this),h)}}})})(Mt);var zt=Mt.exports;const Ut=ft(zt);var St={exports:{}};(function(t,e){(function(i,r){t.exports=r()})(mt,function(){return function(i,r,o){o.updateLocale=function(n,s){var u=o.Ls[n];if(u)return(s?Object.keys(s):[]).forEach(function(g){u[g]=s[g]}),u}}})})(St);var Et=St.exports;const Yt=ft(Et);K.extend(Ut);K.extend(Yt);const Bt={...kt,name:"en-web3-modal",relativeTime:{future:"in %s",past:"%s ago",s:"%d sec",m:"1 min",mm:"%d min",h:"1 hr",hh:"%d hrs",d:"1 d",dd:"%d d",M:"1 mo",MM:"%d mo",y:"1 yr",yy:"%d yr"}},Wt=["January","February","March","April","May","June","July","August","September","October","November","December"];K.locale("en-web3-modal",Bt);const yt={getMonthNameByIndex(t){return Wt[t]},getYear(t=new Date().toISOString()){return K(t).year()},getRelativeDateFromNow(t){return K(t).locale("en-web3-modal").fromNow(!0)},formatDate(t,e="DD MMM"){return K(t).format(e)}},Pt=3,pt=.1,Ht=["receive","deposit","borrow","claim"],Gt=["withdraw","repay","burn"],Z={getTransactionGroupTitle(t,e){const i=yt.getYear(),r=yt.getMonthNameByIndex(e);return t===i?r:`${r} ${t}`},getTransactionImages(t){const[e]=t;return(t==null?void 0:t.length)>1?t.map(r=>this.getTransactionImage(r)):[this.getTransactionImage(e)]},getTransactionImage(t){return{type:Z.getTransactionTransferTokenType(t),url:Z.getTransactionImageURL(t)}},getTransactionImageURL(t){var o,n,s,u,g;let e;const i=!!(t!=null&&t.nft_info),r=!!(t!=null&&t.fungible_info);return t&&i?e=(s=(n=(o=t==null?void 0:t.nft_info)==null?void 0:o.content)==null?void 0:n.preview)==null?void 0:s.url:t&&r&&(e=(g=(u=t==null?void 0:t.fungible_info)==null?void 0:u.icon)==null?void 0:g.url),e},getTransactionTransferTokenType(t){if(t!=null&&t.fungible_info)return"FUNGIBLE";if(t!=null&&t.nft_info)return"NFT"},getTransactionDescriptions(t,e){var L;const i=(L=t==null?void 0:t.metadata)==null?void 0:L.operationType,r=e||(t==null?void 0:t.transfers),o=r&&r.length>0,n=r&&r.length>1,s=o&&r.every(D=>!!(D!=null&&D.fungible_info)),[u,g]=r||[];let h=this.getTransferDescription(u),y=this.getTransferDescription(g);if(!o)return(i==="send"||i==="receive")&&s?(h=vt.getTruncateString({string:t==null?void 0:t.metadata.sentFrom,charsStart:4,charsEnd:6,truncate:"middle"}),y=vt.getTruncateString({string:t==null?void 0:t.metadata.sentTo,charsStart:4,charsEnd:6,truncate:"middle"}),[h,y]):[t.metadata.status];if(n)return r==null?void 0:r.map(D=>this.getTransferDescription(D));let $="";return Ht.includes(i)?$="+":Gt.includes(i)&&($="-"),h=$.concat(h),[h]},getTransferDescription(t){var i;let e="";return t&&(t!=null&&t.nft_info?e=((i=t==null?void 0:t.nft_info)==null?void 0:i.name)||"-":t!=null&&t.fungible_info&&(e=this.getFungibleTransferDescription(t)||"-")),e},getFungibleTransferDescription(t){var r;return t?[this.getQuantityFixedValue(t==null?void 0:t.quantity.numeric),(r=t==null?void 0:t.fungible_info)==null?void 0:r.symbol].join(" ").trim():null},mergeTransfers(t){if((t==null?void 0:t.length)<=1)return t;const i=this.filterGasFeeTransfers(t).reduce((o,n)=>{var g;const s=(g=n==null?void 0:n.fungible_info)==null?void 0:g.name,u=o.find(({fungible_info:h,direction:y})=>s&&s===(h==null?void 0:h.name)&&y===n.direction);if(u){const h=Number(u.quantity.numeric)+Number(n.quantity.numeric);u.quantity.numeric=h.toString(),u.value=(u.value||0)+(n.value||0)}else o.push(n);return o},[]);let r=i;return i.length>2&&(r=i.sort((o,n)=>(n.value||0)-(o.value||0)).slice(0,2)),r=r.sort((o,n)=>o.direction==="out"&&n.direction==="in"?-1:o.direction==="in"&&n.direction==="out"?1:0),r},filterGasFeeTransfers(t){const e=t==null?void 0:t.reduce((r,o)=>{var s;const n=(s=o==null?void 0:o.fungible_info)==null?void 0:s.name;return n&&(r[n]||(r[n]=[]),r[n].push(o)),r},{}),i=[];return Object.values(e??{}).forEach(r=>{if(r.length===1){const o=r[0];o&&i.push(o)}else{const o=r.filter(s=>s.direction==="in"),n=r.filter(s=>s.direction==="out");if(o.length===1&&n.length===1){const s=o[0],u=n[0];let g=!1;if(s&&u){const h=Number(s.quantity.numeric),y=Number(u.quantity.numeric);y<h*pt?(i.push(s),g=!0):h<y*pt&&(i.push(u),g=!0)}g||i.push(...r)}else{const s=this.filterGasFeesFromTokenGroup(r);i.push(...s)}}}),t==null||t.forEach(r=>{var o;(o=r==null?void 0:r.fungible_info)!=null&&o.name||i.push(r)}),i},filterGasFeesFromTokenGroup(t){if(t.length<=1)return t;const e=t==null?void 0:t.map(u=>Number(u.quantity.numeric)),i=Math.max(...e),r=Math.min(...e),o=.01;if(r<i*o)return t==null?void 0:t.filter(g=>Number(g.quantity.numeric)>=i*o);const n=t==null?void 0:t.filter(u=>u.direction==="in"),s=t==null?void 0:t.filter(u=>u.direction==="out");if(n.length===1&&s.length===1){const u=n[0],g=s[0];if(u&&g){const h=Number(u.quantity.numeric),y=Number(g.quantity.numeric);if(y<h*pt)return[u];if(h<y*pt)return[g]}}return t},getQuantityFixedValue(t){return t?parseFloat(t).toFixed(Pt):null}};var xt;(function(t){t.approve="approved",t.bought="bought",t.borrow="borrowed",t.burn="burnt",t.cancel="canceled",t.claim="claimed",t.deploy="deployed",t.deposit="deposited",t.execute="executed",t.mint="minted",t.receive="received",t.repay="repaid",t.send="sent",t.sell="sold",t.stake="staked",t.trade="swapped",t.unstake="unstaked",t.withdraw="withdrawn"})(xt||(xt={}));const qt=ot`
|
|
1
|
+
import{j as ot,l as st,m as w,r as Tt,C as ht,a2 as F,h as gt,R as Ot,E as At,y as Ct,W as Ft,O as Nt}from"./index-becc5f18.js";import{U as vt,n as I,r as Q,c as at}from"./index-ca30e4fd.js";import{_ as mt,g as ft}from"./index-d1b7c41c.js";import"./index-870741d2.js";import"./index-5cb9cf07.js";import{o as Rt}from"./if-defined-b80e1e5f.js";import"./index-a3f378d1.js";import"./index-450d0678.js";var _t={exports:{}};(function(t,e){(function(i,r){t.exports=r()})(mt,function(){var i=1e3,r=6e4,o=36e5,n="millisecond",s="second",u="minute",g="hour",h="day",y="week",$="month",L="quarter",D="year",N="date",Y="Invalid Date",X=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,tt=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,et={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(p){var l=["th","st","nd","rd"],a=p%100;return"["+p+(l[(a-20)%10]||l[a]||l[0])+"]"}},it=function(p,l,a){var d=String(p);return!d||d.length>=l?p:""+Array(l+1-d.length).join(a)+p},B={s:it,z:function(p){var l=-p.utcOffset(),a=Math.abs(l),d=Math.floor(a/60),c=a%60;return(l<=0?"+":"-")+it(d,2,"0")+":"+it(c,2,"0")},m:function p(l,a){if(l.date()<a.date())return-p(a,l);var d=12*(a.year()-l.year())+(a.month()-l.month()),c=l.clone().add(d,$),m=a-c<0,f=l.clone().add(d+(m?-1:1),$);return+(-(d+(a-c)/(m?c-f:f-c))||0)},a:function(p){return p<0?Math.ceil(p)||0:Math.floor(p)},p:function(p){return{M:$,y:D,w:y,d:h,D:N,h:g,m:u,s,ms:n,Q:L}[p]||String(p||"").toLowerCase().replace(/s$/,"")},u:function(p){return p===void 0}},S="en",O={};O[S]=et;var V="$isDayjsObject",W=function(p){return p instanceof lt||!(!p||!p[V])},ct=function p(l,a,d){var c;if(!l)return S;if(typeof l=="string"){var m=l.toLowerCase();O[m]&&(c=m),a&&(O[m]=a,c=m);var f=l.split("-");if(!c&&f.length>1)return p(f[0])}else{var b=l.name;O[b]=l,c=b}return!d&&c&&(S=c),c||!d&&S},T=function(p,l){if(W(p))return p.clone();var a=typeof l=="object"?l:{};return a.date=p,a.args=arguments,new lt(a)},x=B;x.l=ct,x.i=W,x.w=function(p,l){return T(p,{locale:l.$L,utc:l.$u,x:l.$x,$offset:l.$offset})};var lt=function(){function p(a){this.$L=ct(a.locale,null,!0),this.parse(a),this.$x=this.$x||a.x||{},this[V]=!0}var l=p.prototype;return l.parse=function(a){this.$d=function(d){var c=d.date,m=d.utc;if(c===null)return new Date(NaN);if(x.u(c))return new Date;if(c instanceof Date)return new Date(c);if(typeof c=="string"&&!/Z$/i.test(c)){var f=c.match(X);if(f){var b=f[2]-1||0,v=(f[7]||"0").substring(0,3);return m?new Date(Date.UTC(f[1],b,f[3]||1,f[4]||0,f[5]||0,f[6]||0,v)):new Date(f[1],b,f[3]||1,f[4]||0,f[5]||0,f[6]||0,v)}}return new Date(c)}(a),this.init()},l.init=function(){var a=this.$d;this.$y=a.getFullYear(),this.$M=a.getMonth(),this.$D=a.getDate(),this.$W=a.getDay(),this.$H=a.getHours(),this.$m=a.getMinutes(),this.$s=a.getSeconds(),this.$ms=a.getMilliseconds()},l.$utils=function(){return x},l.isValid=function(){return this.$d.toString()!==Y},l.isSame=function(a,d){var c=T(a);return this.startOf(d)<=c&&c<=this.endOf(d)},l.isAfter=function(a,d){return T(a)<this.startOf(d)},l.isBefore=function(a,d){return this.endOf(d)<T(a)},l.$g=function(a,d,c){return x.u(a)?this[d]:this.set(c,a)},l.unix=function(){return Math.floor(this.valueOf()/1e3)},l.valueOf=function(){return this.$d.getTime()},l.startOf=function(a,d){var c=this,m=!!x.u(d)||d,f=x.p(a),b=function(H,A){var z=x.w(c.$u?Date.UTC(c.$y,A,H):new Date(c.$y,A,H),c);return m?z:z.endOf(h)},v=function(H,A){return x.w(c.toDate()[H].apply(c.toDate("s"),(m?[0,0,0,0]:[23,59,59,999]).slice(A)),c)},_=this.$W,M=this.$M,C=this.$D,J="set"+(this.$u?"UTC":"");switch(f){case D:return m?b(1,0):b(31,11);case $:return m?b(1,M):b(0,M+1);case y:var P=this.$locale().weekStart||0,rt=(_<P?_+7:_)-P;return b(m?C-rt:C+(6-rt),M);case h:case N:return v(J+"Hours",0);case g:return v(J+"Minutes",1);case u:return v(J+"Seconds",2);case s:return v(J+"Milliseconds",3);default:return this.clone()}},l.endOf=function(a){return this.startOf(a,!1)},l.$set=function(a,d){var c,m=x.p(a),f="set"+(this.$u?"UTC":""),b=(c={},c[h]=f+"Date",c[N]=f+"Date",c[$]=f+"Month",c[D]=f+"FullYear",c[g]=f+"Hours",c[u]=f+"Minutes",c[s]=f+"Seconds",c[n]=f+"Milliseconds",c)[m],v=m===h?this.$D+(d-this.$W):d;if(m===$||m===D){var _=this.clone().set(N,1);_.$d[b](v),_.init(),this.$d=_.set(N,Math.min(this.$D,_.daysInMonth())).$d}else b&&this.$d[b](v);return this.init(),this},l.set=function(a,d){return this.clone().$set(a,d)},l.get=function(a){return this[x.p(a)]()},l.add=function(a,d){var c,m=this;a=Number(a);var f=x.p(d),b=function(M){var C=T(m);return x.w(C.date(C.date()+Math.round(M*a)),m)};if(f===$)return this.set($,this.$M+a);if(f===D)return this.set(D,this.$y+a);if(f===h)return b(1);if(f===y)return b(7);var v=(c={},c[u]=r,c[g]=o,c[s]=i,c)[f]||1,_=this.$d.getTime()+a*v;return x.w(_,this)},l.subtract=function(a,d){return this.add(-1*a,d)},l.format=function(a){var d=this,c=this.$locale();if(!this.isValid())return c.invalidDate||Y;var m=a||"YYYY-MM-DDTHH:mm:ssZ",f=x.z(this),b=this.$H,v=this.$m,_=this.$M,M=c.weekdays,C=c.months,J=c.meridiem,P=function(A,z,nt,dt){return A&&(A[z]||A(d,m))||nt[z].slice(0,dt)},rt=function(A){return x.s(b%12||12,A,"0")},H=J||function(A,z,nt){var dt=A<12?"AM":"PM";return nt?dt.toLowerCase():dt};return m.replace(tt,function(A,z){return z||function(nt){switch(nt){case"YY":return String(d.$y).slice(-2);case"YYYY":return x.s(d.$y,4,"0");case"M":return _+1;case"MM":return x.s(_+1,2,"0");case"MMM":return P(c.monthsShort,_,C,3);case"MMMM":return P(C,_);case"D":return d.$D;case"DD":return x.s(d.$D,2,"0");case"d":return String(d.$W);case"dd":return P(c.weekdaysMin,d.$W,M,2);case"ddd":return P(c.weekdaysShort,d.$W,M,3);case"dddd":return M[d.$W];case"H":return String(b);case"HH":return x.s(b,2,"0");case"h":return rt(1);case"hh":return rt(2);case"a":return H(b,v,!0);case"A":return H(b,v,!1);case"m":return String(v);case"mm":return x.s(v,2,"0");case"s":return String(d.$s);case"ss":return x.s(d.$s,2,"0");case"SSS":return x.s(d.$ms,3,"0");case"Z":return f}return null}(A)||f.replace(":","")})},l.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},l.diff=function(a,d,c){var m,f=this,b=x.p(d),v=T(a),_=(v.utcOffset()-this.utcOffset())*r,M=this-v,C=function(){return x.m(f,v)};switch(b){case D:m=C()/12;break;case $:m=C();break;case L:m=C()/3;break;case y:m=(M-_)/6048e5;break;case h:m=(M-_)/864e5;break;case g:m=M/o;break;case u:m=M/r;break;case s:m=M/i;break;default:m=M}return c?m:x.a(m)},l.daysInMonth=function(){return this.endOf($).$D},l.$locale=function(){return O[this.$L]},l.locale=function(a,d){if(!a)return this.$L;var c=this.clone(),m=ct(a,d,!0);return m&&(c.$L=m),c},l.clone=function(){return x.w(this.$d,this)},l.toDate=function(){return new Date(this.valueOf())},l.toJSON=function(){return this.isValid()?this.toISOString():null},l.toISOString=function(){return this.$d.toISOString()},l.toString=function(){return this.$d.toUTCString()},p}(),$t=lt.prototype;return T.prototype=$t,[["$ms",n],["$s",s],["$m",u],["$H",g],["$W",h],["$M",$],["$y",D],["$D",N]].forEach(function(p){$t[p[1]]=function(l){return this.$g(l,p[0],p[1])}}),T.extend=function(p,l){return p.$i||(p(l,lt,T),p.$i=!0),T},T.locale=ct,T.isDayjs=W,T.unix=function(p){return T(1e3*p)},T.en=O[S],T.Ls=O,T.p={},T})})(_t);var jt=_t.exports;const K=ft(jt);var It={exports:{}};(function(t,e){(function(i,r){t.exports=r()})(mt,function(){return{name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(i){var r=["th","st","nd","rd"],o=i%100;return"["+i+(r[(o-20)%10]||r[o]||r[0])+"]"}}})})(It);var Lt=It.exports;const kt=ft(Lt);var Mt={exports:{}};(function(t,e){(function(i,r){t.exports=r()})(mt,function(){return function(i,r,o){i=i||{};var n=r.prototype,s={future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function u(h,y,$,L){return n.fromToBase(h,y,$,L)}o.en.relativeTime=s,n.fromToBase=function(h,y,$,L,D){for(var N,Y,X,tt=$.$locale().relativeTime||s,et=i.thresholds||[{l:"s",r:44,d:"second"},{l:"m",r:89},{l:"mm",r:44,d:"minute"},{l:"h",r:89},{l:"hh",r:21,d:"hour"},{l:"d",r:35},{l:"dd",r:25,d:"day"},{l:"M",r:45},{l:"MM",r:10,d:"month"},{l:"y",r:17},{l:"yy",d:"year"}],it=et.length,B=0;B<it;B+=1){var S=et[B];S.d&&(N=L?o(h).diff($,S.d,!0):$.diff(h,S.d,!0));var O=(i.rounding||Math.round)(Math.abs(N));if(X=N>0,O<=S.r||!S.r){O<=1&&B>0&&(S=et[B-1]);var V=tt[S.l];D&&(O=D(""+O)),Y=typeof V=="string"?V.replace("%d",O):V(O,y,S.l,X);break}}if(y)return Y;var W=X?tt.future:tt.past;return typeof W=="function"?W(Y):W.replace("%s",Y)},n.to=function(h,y){return u(h,y,this,!0)},n.from=function(h,y){return u(h,y,this)};var g=function(h){return h.$u?o.utc():o()};n.toNow=function(h){return this.to(g(this),h)},n.fromNow=function(h){return this.from(g(this),h)}}})})(Mt);var zt=Mt.exports;const Ut=ft(zt);var St={exports:{}};(function(t,e){(function(i,r){t.exports=r()})(mt,function(){return function(i,r,o){o.updateLocale=function(n,s){var u=o.Ls[n];if(u)return(s?Object.keys(s):[]).forEach(function(g){u[g]=s[g]}),u}}})})(St);var Et=St.exports;const Yt=ft(Et);K.extend(Ut);K.extend(Yt);const Bt={...kt,name:"en-web3-modal",relativeTime:{future:"in %s",past:"%s ago",s:"%d sec",m:"1 min",mm:"%d min",h:"1 hr",hh:"%d hrs",d:"1 d",dd:"%d d",M:"1 mo",MM:"%d mo",y:"1 yr",yy:"%d yr"}},Wt=["January","February","March","April","May","June","July","August","September","October","November","December"];K.locale("en-web3-modal",Bt);const yt={getMonthNameByIndex(t){return Wt[t]},getYear(t=new Date().toISOString()){return K(t).year()},getRelativeDateFromNow(t){return K(t).locale("en-web3-modal").fromNow(!0)},formatDate(t,e="DD MMM"){return K(t).format(e)}},Pt=3,pt=.1,Ht=["receive","deposit","borrow","claim"],Gt=["withdraw","repay","burn"],Z={getTransactionGroupTitle(t,e){const i=yt.getYear(),r=yt.getMonthNameByIndex(e);return t===i?r:`${r} ${t}`},getTransactionImages(t){const[e]=t;return(t==null?void 0:t.length)>1?t.map(r=>this.getTransactionImage(r)):[this.getTransactionImage(e)]},getTransactionImage(t){return{type:Z.getTransactionTransferTokenType(t),url:Z.getTransactionImageURL(t)}},getTransactionImageURL(t){var o,n,s,u,g;let e;const i=!!(t!=null&&t.nft_info),r=!!(t!=null&&t.fungible_info);return t&&i?e=(s=(n=(o=t==null?void 0:t.nft_info)==null?void 0:o.content)==null?void 0:n.preview)==null?void 0:s.url:t&&r&&(e=(g=(u=t==null?void 0:t.fungible_info)==null?void 0:u.icon)==null?void 0:g.url),e},getTransactionTransferTokenType(t){if(t!=null&&t.fungible_info)return"FUNGIBLE";if(t!=null&&t.nft_info)return"NFT"},getTransactionDescriptions(t,e){var L;const i=(L=t==null?void 0:t.metadata)==null?void 0:L.operationType,r=e||(t==null?void 0:t.transfers),o=r&&r.length>0,n=r&&r.length>1,s=o&&r.every(D=>!!(D!=null&&D.fungible_info)),[u,g]=r||[];let h=this.getTransferDescription(u),y=this.getTransferDescription(g);if(!o)return(i==="send"||i==="receive")&&s?(h=vt.getTruncateString({string:t==null?void 0:t.metadata.sentFrom,charsStart:4,charsEnd:6,truncate:"middle"}),y=vt.getTruncateString({string:t==null?void 0:t.metadata.sentTo,charsStart:4,charsEnd:6,truncate:"middle"}),[h,y]):[t.metadata.status];if(n)return r==null?void 0:r.map(D=>this.getTransferDescription(D));let $="";return Ht.includes(i)?$="+":Gt.includes(i)&&($="-"),h=$.concat(h),[h]},getTransferDescription(t){var i;let e="";return t&&(t!=null&&t.nft_info?e=((i=t==null?void 0:t.nft_info)==null?void 0:i.name)||"-":t!=null&&t.fungible_info&&(e=this.getFungibleTransferDescription(t)||"-")),e},getFungibleTransferDescription(t){var r;return t?[this.getQuantityFixedValue(t==null?void 0:t.quantity.numeric),(r=t==null?void 0:t.fungible_info)==null?void 0:r.symbol].join(" ").trim():null},mergeTransfers(t){if((t==null?void 0:t.length)<=1)return t;const i=this.filterGasFeeTransfers(t).reduce((o,n)=>{var g;const s=(g=n==null?void 0:n.fungible_info)==null?void 0:g.name,u=o.find(({fungible_info:h,direction:y})=>s&&s===(h==null?void 0:h.name)&&y===n.direction);if(u){const h=Number(u.quantity.numeric)+Number(n.quantity.numeric);u.quantity.numeric=h.toString(),u.value=(u.value||0)+(n.value||0)}else o.push(n);return o},[]);let r=i;return i.length>2&&(r=i.sort((o,n)=>(n.value||0)-(o.value||0)).slice(0,2)),r=r.sort((o,n)=>o.direction==="out"&&n.direction==="in"?-1:o.direction==="in"&&n.direction==="out"?1:0),r},filterGasFeeTransfers(t){const e=t==null?void 0:t.reduce((r,o)=>{var s;const n=(s=o==null?void 0:o.fungible_info)==null?void 0:s.name;return n&&(r[n]||(r[n]=[]),r[n].push(o)),r},{}),i=[];return Object.values(e??{}).forEach(r=>{if(r.length===1){const o=r[0];o&&i.push(o)}else{const o=r.filter(s=>s.direction==="in"),n=r.filter(s=>s.direction==="out");if(o.length===1&&n.length===1){const s=o[0],u=n[0];let g=!1;if(s&&u){const h=Number(s.quantity.numeric),y=Number(u.quantity.numeric);y<h*pt?(i.push(s),g=!0):h<y*pt&&(i.push(u),g=!0)}g||i.push(...r)}else{const s=this.filterGasFeesFromTokenGroup(r);i.push(...s)}}}),t==null||t.forEach(r=>{var o;(o=r==null?void 0:r.fungible_info)!=null&&o.name||i.push(r)}),i},filterGasFeesFromTokenGroup(t){if(t.length<=1)return t;const e=t==null?void 0:t.map(u=>Number(u.quantity.numeric)),i=Math.max(...e),r=Math.min(...e),o=.01;if(r<i*o)return t==null?void 0:t.filter(g=>Number(g.quantity.numeric)>=i*o);const n=t==null?void 0:t.filter(u=>u.direction==="in"),s=t==null?void 0:t.filter(u=>u.direction==="out");if(n.length===1&&s.length===1){const u=n[0],g=s[0];if(u&&g){const h=Number(u.quantity.numeric),y=Number(g.quantity.numeric);if(y<h*pt)return[u];if(h<y*pt)return[g]}}return t},getQuantityFixedValue(t){return t?parseFloat(t).toFixed(Pt):null}};var xt;(function(t){t.approve="approved",t.bought="bought",t.borrow="borrowed",t.burn="burnt",t.cancel="canceled",t.claim="claimed",t.deploy="deployed",t.deposit="deposited",t.execute="executed",t.mint="minted",t.receive="received",t.repay="repaid",t.send="sent",t.sell="sold",t.stake="staked",t.trade="swapped",t.unstake="unstaked",t.withdraw="withdrawn"})(xt||(xt={}));const qt=ot`
|
|
2
2
|
:host > wui-flex {
|
|
3
3
|
display: flex;
|
|
4
4
|
justify-content: center;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as p,r as f,k as h,l as b,m,N as d}from"./index-
|
|
1
|
+
import{j as p,r as f,k as h,l as b,m,N as d}from"./index-becc5f18.js";import{n as i,c as g}from"./index-ca30e4fd.js";import"./index-a3f378d1.js";const w=p`
|
|
2
2
|
:host {
|
|
3
3
|
width: 100%;
|
|
4
4
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{n as p,r as d,l as m,v as r,m as g}from"./index-
|
|
1
|
+
import{n as p,r as d,l as m,v as r,m as g}from"./index-becc5f18.js";import{n as h,c as x}from"./index-ca30e4fd.js";const v=p`
|
|
2
2
|
:host {
|
|
3
3
|
display: flex;
|
|
4
4
|
}
|