1import{J as be,K as we}from"./entry-9f6422c3.mjs";var re={exports:{}};/*! For license information please see index.js.LICENSE.txt */(function(r,t){(function(o,i){r.exports=i()})(typeof self!="undefined"?self:be,function(){return(()=>{var o={434:(f,y,p)=>{var d;(function(){var g="input is invalid type",w=typeof window=="object",R=w?window:{};R.JS_SHA512_NO_WINDOW&&(w=!1);var C=!w&&typeof self=="object";!R.JS_SHA512_NO_NODE_JS&&typeof process=="object"&&process.versions&&process.versions.node?R=p.g:C&&(R=self);var F=!R.JS_SHA512_NO_COMMON_JS&&f.exports,I=p.amdO,j=!R.JS_SHA512_NO_ARRAY_BUFFER&&typeof ArrayBuffer!="undefined",a="0123456789abcdef".split(""),S=[-2147483648,8388608,32768,128],P=[24,16,8,0],q=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,
11126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],L=["hex","array","digest","arrayBuffer"],T=[];!R.JS_SHA512_NO_NODE_JS&&Array.isArray||(Array.isArray=function(h){return Object.prototype.toString.call(h)==="[object Array]"}),!j||!R.JS_SHA512_NO_ARRAY_BUFFER_IS_VIEW&&ArrayBuffer.isView||(ArrayBuffer.isView=function(h){return typeof h=="object"&&h.buffer&&h.buffer.constructor===ArrayBuffer});var D=function(h,b){return function(_){return new z(b,!0).update(_)[h]()}},Y=function(h){var b=D("hex",h);b.create=function(){return new z(h)},b.update=function(v){return b.create().update(v)};for(var _=0;_<L.length;++_){var E=L[_];b[E]=D(E,h)}return b},K=function(h,b){return function(_,E){return new gt(_,b,!0).update(E)[h]()}},X=function(h){var b=K("hex",h);b.create=function(v){return new gt(v,h)},b.update=function(v,n){return b.create(v).update(n)};for(var _=0;_<L.length;++_){var E=L[_];b[E]=K(E,h)}return b};function z(h,b){b?(T[0]=T[1]=T[2]=T[3]=T[4]=T[5]=T[6]=T[7]=T[8]=T[9]=T[10]=T[11]=T[12]=T[13]=T[14]=T[15]=T[16]=T[17]=T[18]=T[19]=T[20]=T[21]=T[22]=T[23]=T[24]=T[25]=T[26]=T[27]=T[28]=T[29]=T[30]=T[31]=T[32]=0,this.blocks=T):this.blocks=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],h==384?(this.h0h=3418070365,this.h0l=3238371032,this.h1h=1654270250,this.h1l=914150663,this.h2h=2438529370,this.h2l=812702999,this.h3h=355462360,this.h3l=4144912697,this.h4h=1731405415,this.h4l=4290775857,this.h5h=2394180231,this.h5l=1750603025,this.h6h=3675008525,this.h6l=1694076839,this.h7h=1203062813,this.h7l=3204075428):h==256?(this.h0h=573645204,this.h0l=4230739756,this.h1h=2673172387,this.h1l=3360449730,this.h2h=596883563,this.h2l=1867755857,this.h3h=2520282905,this.h3l=1497426621,this.h4h=2519219938,this.h4l=2827943907,this.h5h=3193839141,this.h5l=1401305490,this.h6h=721525244,this.h6l=746961066,this.h7h=246885852,this.h7l=2177182882):h==224?(this.h0h=2352822216,this.h0l=424955298,this.h1h=1944164710,this.h1l=2312950998,this.h2h=502970286,this.h2l=855612546,this.h3h=1738396948,this.h3l=1479516111,this.h4h=258812777,this.h4l=2077511080,this.h5h=2011393907,this.h5l=79989058,this.h6h=1067287976,this.h6l=1780299464,this.h7h=286451373,this.h7l=2446758561):(this.h0h=1779033703,this.h0l=4089235720,this.h1h=3144134277,this.h1l=2227873595,this.h2h=1013904242,this.h2l=4271175723,this.h3h=2773480762,this.h3l=1595750129,this.h4h=1359893119,this.h4l=2917565137,this.h5h=2600822924,this.h5l=725511199,this.h6h=528734635,this.h6l=4215389547,this.h7h=1541459225,this.h7l=327033209),this.bits=h,this.block=this.start=this.bytes=this.hBytes=0,this.finalized=this.hashed=!1}function gt(h,b,_){var E,v=typeof h;if(v!=="string"){if(v!=="object")throw new Error(g);if(h===null)throw new Error(g);if(j&&h.constructor===ArrayBuffer)h=new Uint8Array(h);else if(!(Array.isArray(h)||j&&ArrayBuffer.isView(h)))throw new Error(g);E=!0}var n=h.length;if(!E){for(var s,e=[],u=(n=h.length,0),l=0;l<n;++l)(s=h.charCodeAt(l))<128?e[u++]=s:s<2048?(e[u++]=192|s>>6,e[u++]=128|63&s):s<55296||s>=57344?(e[u++]=224|s>>12,e[u++]=128|s>>6&63,e[u++]=128|63&s):(s=65536+((1023&s)<<10|1023&h.charCodeAt(++l)),e[u++]=240|s>>18,e[u++]=128|s>>12&63,e[u++]=128|s>>6&63,e[u++]=128|63&s);h=e}h.length>128&&(h=new z(b,!0).update(h).array());var U=[],O=[];for(l=0;l<128;++l){var B=h[l]||0;U[l]=92^B,O[l]=54^B}z.call(this,b,_),this.update(O),this.oKeyPad=U,this.inner=!0,this.sharedMemory=_}z.prototype.update=function(h){if(this.finalized)throw new Error("finalize already called");var b,_=typeof h;if(_!=="string"){if(_!=="object")throw new Error(g);if(h===null)throw new Error(g);if(j&&h.constructor===ArrayBuffer)h=new Uint8Array(h);else if(!(Array.isArray(h)||j&&ArrayBuffer.isView(h)))throw new Error(g);b=!0}for(var E,v,n=0,s=h.length,e=this.blocks;n<s;){if(this.hashed&&(this.hashed=!1,e[0]=this.block,e[1]=e[2]=e[3]=e[4]=e[5]=e[6]=e[7]=e[8]=e[9]=e[10]=e[11]=e[12]=e[13]=e[14]=e[15]=e[16]=e[17]=e[18]=e[19]=e[20]=e[21]=e[22]=e[23]=e[24]=e[25]=e[26]=e[27]=e[28]=e[29]=e[30]=e[31]=e[32]=0),b)for(v=this.start;n<s&&v<128;++n)e[v>>2]|=h[n]<<P[3&v++];else for(v=this.start;n<s&&v<128;
1++n)(E=h.charCodeAt(n))<128?e[v>>2]|=E<<P[3&v++]:E<2048?(e[v>>2]|=(192|E>>6)<<P[3&v++],e[v>>2]|=(128|63&E)<<P[3&v++]):E<55296||E>=57344?(e[v>>2]|=(224|E>>12)<<P[3&v++],e[v>>2]|=(128|E>>6&63)<<P[3&v++],e[v>>2]|=(128|63&E)<<P[3&v++]):(E=65536+((1023&E)<<10|1023&h.charCodeAt(++n)),e[v>>2]|=(240|E>>18)<<P[3&v++],e[v>>2]|=(128|E>>12&63)<<P[3&v++],e[v>>2]|=(128|E>>6&63)<<P[3&v++],e[v>>2]|=(128|63&E)<<P[3&v++]);this.lastByteIndex=v,this.bytes+=v-this.start,v>=128?(this.block=e[32],this.start=v-128,this.hash(),this.hashed=!0):this.start=v}return this.bytes>4294967295&&(this.hBytes+=this.bytes/4294967296<<0,this.bytes=this.bytes%4294967296),this},z.prototype.finalize=function(){if(!this.finalized){this.finalized=!0;var h=this.blocks,b=this.lastByteIndex;h[32]=this.block,h[b>>2]|=S[3&b],this.block=h[32],b>=112&&(this.hashed||this.hash(),h[0]=this.block,h[1]=h[2]=h[3]=h[4]=h[5]=h[6]=h[7]=h[8]=h[9]=h[10]=h[11]=h[12]=h[13]=h[14]=h[15]=h[16]=h[17]=h[18]=h[19]=h[20]=h[21]=h[22]=h[23]=h[24]=h[25]=h[26]=h[27]=h[28]=h[29]=h[30]=h[31]=h[32]=0),h[30]=this.hBytes<<3|this.bytes>>>29,h[31]=this.bytes<<3,this.hash()}},z.prototype.hash=function(){var h,b,_,E,v,n,s,e,u,l,U,O,B,H,J,A,$,N,Q,k,x,G,W,wt,vt,Pt=this.h0h,kt=this.h0l,Rt=this.h1h,xt=this.h1l,Ft=this.h2h,Bt=this.h2l,It=this.h3h,Dt=this.h3l,zt=this.h4h,Lt=this.h4l,Nt=this.h5h,Jt=this.h5l,$t=this.h6h,Mt=this.h6l,Ht=this.h7h,qt=this.h7l,Z=this.blocks;for(h=32;h<160;h+=2)b=((k=Z[h-30])>>>1|(x=Z[h-29])<<31)^(k>>>8|x<<24)^k>>>7,_=(x>>>1|k<<31)^(x>>>8|k<<24)^(x>>>7|k<<25),E=((k=Z[h-4])>>>19|(x=Z[h-3])<<13)^(x>>>29|k<<3)^k>>>6,v=(x>>>19|k<<13)^(k>>>29|x<<3)^(x>>>6|k<<26),k=Z[h-32],x=Z[h-31],u=((G=Z[h-14])>>>16)+(k>>>16)+(b>>>16)+(E>>>16)+((e=(65535&G)+(65535&k)+(65535&b)+(65535&E)+((s=((W=Z[h-13])>>>16)+(x>>>16)+(_>>>16)+(v>>>16)+((n=(65535&W)+(65535&x)+(65535&_)+(65535&v))>>>16))>>>16))>>>16),Z[h]=u<<16|65535&e,Z[h+1]=s<<16|65535&n;var tt=Pt,et=kt,rt=Rt,nt=xt,st=Ft,ot=Bt,mt=It,yt=Dt,it=zt,at=Lt,ht=Nt,ut=Jt,ct=$t,lt=Mt,ft=Ht,pt=qt;for(A=rt&st,$=nt&ot,h=0;h<160;h+=8)b=(tt>>>28|et<<4)^(et>>>2|tt<<30)^(et>>>7|tt<<25),_=(et>>>28|tt<<4)^(tt>>>2|et<<30)^(tt>>>7|et<<25),E=(it>>>14|at<<18)^(it>>>18|at<<14)^(at>>>9|it<<23),v=(at>>>14|it<<18)^(at>>>18|it<<14)^(it>>>9|at<<23),N=(l=tt&rt)^tt&st^A,Q=(U=et&nt)^et&ot^$,wt=it&ht^~it&ct,vt=at&ut^~at<,k=Z[h],x=Z[h+1],k=(u=((G=q[h])>>>16)+(k>>>16)+(wt>>>16)+(E>>>16)+(ft>>>16)+((e=(65535&G)+(65535&k)+(65535&wt)+(65535&E)+(65535&ft)+((s=((W=q[h+1])>>>16)+(x>>>16)+(vt>>>16)+(v>>>16)+(pt>>>16)+((n=(65535&W)+(65535&x)+(65535&vt)+(65535&v)+(65535&pt))>>>16))>>>16))>>>16))<<16|65535&e,x=s<<16|65535&n,G=(u=(N>>>16)+(b>>>16)+((e=(65535&N)+(65535&b)+((s=(Q>>>16)+(_>>>16)+((n=(65535&Q)+(65535&_))>>>16))>>>16))>>>16))<<16|65535&e,W=s<<16|65535&n,ft=(u=(mt>>>16)+(k>>>16)+((e=(65535&mt)+(65535&k)+((s=(yt>>>16)+(x>>>16)+((n=(65535&yt)+(65535&x))>>>16))>>>16))>>>16))<<16|65535&e,pt=s<<16|65535&n,b=((mt=(u=(G>>>16)+(k>>>16)+((e=(65535&G)+(65535&k)+((s=(W>>>16)+(x>>>16)+((n=(65535&W)+(65535&x))>>>16))>>>16))>>>16))<<16|65535&e)>>>28|(yt=s<<16|65535&n)<<4)^(yt>>>2|mt<<30)^(yt>>>7|mt<<25),_=(yt>>>28|mt<<4)^(mt>>>2|yt<<30)^(mt>>>7|yt<<25),E=(ft>>>14|pt<<18)^(ft>>>18|pt<<14)^(pt>>>9|ft<<23),v=(pt>>>14|ft<<18)^(pt>>>18|ft<<14)^(ft>>>9|pt<<23),N=(O=mt&tt)^mt&rt^l,Q=(B=yt&et)^yt&nt^U,wt=ft&it^~ft&ht,vt=pt&at^~pt&ut,k=Z[h+2],x=Z[h+3],k=(u=((G=q[h+2])>>>16)+(k>>>16)+(wt>>>16)+(E>>>16)+(ct>>>16)+((e=(65535&G)+(65535&k)+(65535&wt)+(65535&E)+(65535&ct)+((s=((W=q[h+3])>>>16)+(x>>>16)+(vt>>>16)+(v>>>16)+(lt>>>16)+((n=(65535&W)+(65535&x)+(65535&vt)+(65535&v)+(65535<))>>>16))>>>16))>>>16))<<16|65535&e,x=s<<16|65535&n,G=(u=(N>>>16)+(b>>>16)+((e=(65535&N)+(65535&b)+((s=(Q>>>16)+(_>>>16)+((n=(65535&Q)+(65535&_))>>>16))>>>16))>>>16))<<16|65535&e,W=s<<16|65535&n,ct=(u=(st>>>16)+(k>>>16)+((e=(65535&st)+(65535&k)+((s=(ot>>>16)+(x>>>16)+((n=(65535&ot)+(65535&x))>>>16))>>>16))>>>16))<<16|65535&e,lt=s<<16|65535&n,b=((st=(u=(G>>>16)+(k>>>16)+((e=(65535&G)+(65535&k)+((s=(W>>>16)+(x>>>16)+((n=(65535&W)+(65535&x))>>>16))>>>16))>>>16))<<16|65535&e)>>>28|(ot=s<<16|65535&n)<<4)^(ot>>>2|st<<30)^(ot>>>7|st<<25),_=(ot>>>28|st<<4)^(st>>>2|ot<<30)^(st>>>7|ot<<25),E=(ct>>>14|lt<<18)^(ct>>>18|lt<<14)^(lt>>>9|ct<<23),v=(lt>>>14|ct<<18)^(lt>>>18|ct<<14)^(ct>>>9|lt<<23),N=(H=st&mt)^st&tt^O,Q=(J=ot&yt)^ot&et^B,wt=ct&ft^~ct&it,vt=lt&pt^~lt&at,k=Z[h+4],x=Z[h+5],k=(u=((G=q[h+4])>>>16)+(k>>>16)+(wt>>>16)+(E>>>16)+(ht>>>16)+((e=(65535&G)+(65535&k)+(65535&wt)+(65535&E)+(65535&ht)+((s=((W=q[h+5])>>>16)+(x>>>16)+(vt>>>16)+(v>>>16)+(ut>>>16)+((n=(65535&W)+(65535&x)+(65535&vt)+(65535&v)+(65535&ut))>>>16))>>>16))>>>16))<<16|65535&e,x=s<<16|65535&n,G=(u=(N>>>16)+(b>>>16)+((e=(65535&N)+(65535&b)+((s=(Q>>>16)+(_>>>16)+((n=(65535&Q)+(65535&_))>>>16))>>>16))>>>16))<<16|65535&e,W=s<<16|65535&n,ht=(u=(rt>>>16)+(k>>>16)+((e=(65535&rt)+(65535&k)+((s=(nt>>>16)+(x>>>16)+((n=(65535&nt)+(65535&x))>>>16))>>>16))>>>16))<<16|65535&e,ut=s<<16|65535&n,b=((rt=(u=(G>>>16)+(k>>>16)+((e=(65535&G)+(65535&k)+((s=(W>>>16)+(x>>>16)+((n=(65535&W)+(65535&x))>>>16))>>>16))>>>16))<<16|65535&e)>>>28|(nt=s<<16|65535&n)<<4)^(nt>>>2|rt<<30)^(nt>>>7|rt<<25),_=(nt>>>28|rt<<4)^(rt>>>2|nt<<30)^(rt>>>7|nt<<25),E=(ht>>>14|ut<<18)^(ht>>>18|ut<<14)^(ut>>>9|ht<<23),v=(ut>>>14|ht<<18)^(ut>>>18|ht<<14)^(ht>>>9|ut<<23),N=(A=rt&st)^rt&mt^H,Q=($=nt&ot)^nt&yt^J,wt=ht&ct^~ht&ft,vt=ut<^~ut&pt,k=Z[h+6],x=Z[h+7],k=(u=((G=q[h+6])>>>16)+(k>>>16)+(wt>>>16)+(E>>>16)+(it>>>16)+((e=(65535&G)+(65535&k)+(65535&wt)+(65535&E)+(65535&it)+((s=((W=q[h+7])>>>16)+(x>>>16)+(vt>>>16)+(v>>>16)+(at>>>16)+((n=(65535&W)+(65535&x)+(65535&vt)+(65535&v)+(65535&at))>>>16))>>>16))>>>16))<<16|65535&e,x=s<<16|65535&n,G=(u=(N>>>16)+(b>>>16)+((e=(65535&N)+(65535&b)+((s=(Q>>>16)+(_>>>16)+((n=(65535&Q)+(65535&_))>>>16))>>>16))>>>16))<<16|65535&e,W=s<<16|65535&n,it=(u=(tt>>>16)+(k>>>16)+((e=(65535&tt)+(65535&k)+((s=(et>>>16)+(x>>>16)+((n=(65535&et)+(65535&x))>>>16))>>>16))>>>16))<<16|65535&e,at=s<<16|65535&n,tt=(u=(G>>>16)+(k>>>16)+((e=(65535&G)+(65535&k)+((s=(W>>>16)+(x>>>16)+((n=(65535&W)+(65535&x))>>>16))>>>16))>>>16))<<16|65535&e,et=s<<16|65535&n;u=(Pt>>>16)+(tt>>>16)+((e=(65535&Pt)+(65535&tt)+((s=(kt>>>16)+(et>>>16)+((n=(65535&kt)+(65535&et))>>>16))>>>16))>>>16),this.h0h=u<<16|65535&e,this.h0l=s<<16|65535&n,u=(Rt>>>16)+(rt>>>16)+((e=(65535&Rt)+(65535&rt)+((s=(xt>>>16)+(nt>>>16)+((n=(65535&xt)+(65535&nt))>>>16))>>>16))>>>16),this.h1h=u<<16|65535&e,this.h1l=s<<16|65535&n,u=(Ft>>>16)+(st>>>16)+((e=(65535&Ft)+(65535&st)+((s=(Bt>>>16)+(ot>>>16)+((n=(65535&Bt)+(65535&ot))>>>16))>>>16))>>>16),this.h2h=u<<16|65535&e,this.h2l=s<<16|65535&n,u=(It>>>16)+(mt>>>16)+((e=(65535&It)+(65535&mt)+((s=(Dt>>>16)+(yt>>>16)+((n=(65535&Dt)+(65535&yt))>>>16))>>>16))>>>16),this.h3h=u<<16|65535&e,this.h3l=s<<16|65535&n,u=(zt>>>16)+(it>>>16)+((e=(65535&zt)+(65535&it)+((s=(Lt>>>16)+(at>>>16)+((n=(65535&Lt)+(65535&at))>>>16))>>>16))>>>16),this.h4h=u<<16|65535&e,this.h4l=s<<16|65535&n,u=(Nt>>>16)+(ht>>>16)+((e=(65535&Nt)+(65535&ht)+((s=(Jt>>>16)+(ut>>>16)+((n=(65535&Jt)+(65535&ut))>>>16))>>>16))>>>16),this.h5h=u<<16|65535&e,this.h5l=s<<16|65535&n,u=($t>>>16)+(ct>>>16)+((e=(65535&$t)+(65535&ct)+((s=(Mt>>>16)+(lt>>>16)+((n=(65535&Mt)+(65535<))>>>16))>>>16))>>>16),this.h6h=u<<16|65535&e,this.h6l=s<<16|65535&n,u=(Ht>>>16)+(ft>>>16)+((e=(65535&Ht)+(65535&ft)+((s=(qt>>>16)+(pt>>>16)+((n=(65535&qt)+(65535&pt))>>>16))>>>16))>>>16),this.h7h=u<<16|65535&e,this.h7l=s<<16|65535&n},z.prototype.hex=function(){this.finalize();var h=this.h0h,b=this.h0l,_=this.h1h,E=this.h1l,v=this.h2h,n=this.h2l,s=this.h3h,e=this.h3l,u=this.h4h,l=this.h4l,U=this.h5h,O=this.h5l,B=this.h6h,H=this.h6l,J=this.h7h,A=this.h7l,$=this.bits,N=a[h>>28&15]+a[h>>24&15]+a[h>>20&15]+a[h>>16&15]+a[h>>12&15]+a[h>>8&15]+a[h>>4&15]+a[15&h]+a[b>>28&15]+a[b>>24&15]+a[b>>20&15]+a[b>>16&15]+a[b>>12&15]+a[b>>8&15]+a[b>>4&15]+a[15&b]+a[_>>28&15]+a[_>>24&15]+a[_>>20&15]+a[_>>16&15]+a[_>>12&15]+a[_>>8&15]+a[_>>4&15]+a[15&_]+a[E>>28&15]+a[E>>24&15]+a[E>>20&15]+a[E>>16&15]+a[E>>12&15]+a[E>>8&15]+a[E>>4&15]+a[15&E]+a[v>>28&15]+a[v>>24&15]+a[v>>20&15]+a[v>>16&15]+a[v>>12&15]+a[v>>8&15]+a[v>>4&15]+a[15&v]+a[n>>28&15]+a[n>>24&15]+a[n>>20&15]+a[n>>16&15]+a[n>>12&15]+a[n>>8&15]+a[n>>4&15]+a[15&n]+a[s>>28&15]+a[s>>24&15]+a[s>>20&15]+a[s>>16&15]+a[s>>12&15]+a[s>>8&15]+a[s>>4&15]+a[15&s];return $>=256&&(N+=a[e>>28&15]+a[e>>24&15]+a[e>>20&15]+a[e>>16&15]+a[e>>12&15]+a[e>>8&15]+a[e>>4&15]+a[15&e]),$>=384&&(N+=a[u>>28&15]+a[u>>24&15]+a[u>>20&15]+a[u>>16&15]+a[u>>12&15]+a[u>>8&15]+a[u>>4&15]+a[15&u]+a[l>>28&15]+a[l>>24&15]+a[l>>20&15]+a[l>>16&15]+a[l>>12&15]+a[l>>8&15]+a[l>>4&15]+a[15&l]+a[U>>28&15]+a[U>>24&15]+a[U>>20&15]+a[U>>16&15]+a[U>>12&15]+a[U>>8&15]+a[U>>4&15]+a[15&U]+a[O>>28&15]+a[O>>24&15]+a[O>>20&15]+a[O>>16&15]+a[O>>12&15]+a[O>>8&15]+a[O>>4&15]+a[15&O]),$==512&&(N+=a[B>>28&15]+a[B>>24&15]+a[B>>20&15]+a[B>>16&15]+a[B>>12&15]+a[B>>8&15]+a[B>>4&15]+a[15&B]+a[H>>28&15]+a[H>>24&15]+a[H>>20&15]+a[H>>16&15]+a[H>>12&15]+a[H>>8&15]+a[H>>4&15]+a[15&H]+a[J>>28&15]+a[J>>24&15]+a[J>>20&15]+a[J>>16&15]+a[J>>12&15]+a[J>>8&15]+a[J>>4&15]+a[15&J]+a[A>>28&15]+a[A>>24&15]+a[A>>20&15]+a[A>>16&15]+a[A>>12&15]+a[A>>8&15]+a[A>>4&15]+a[15&A]),N},z.prototype.toString=z.prototype.hex,z.prototype.digest=function(){this.finalize();var h=this.h0h,b=this.h0l,_=this.h1h,E=this.h1l,v=this.h2h,n=this.h2l,s=this.h3h,e=this.h3l,u=this.h4h,l=this.h4l,U=this.h5h,O=this.h5l,B=this.h6h,H=this.h6l,J=this.h7h,A=this.h7l,$=this.bits,N=[h>>24&255,h>>16&255,h>>8&255,255&h,b>>24&255,b>>16&255,b>>8&255,255&b,_>>24&255,_>>16&255,_>>
18&255,255&_,E>>24&255,E>>16&255,E>>8&255,255&E,v>>24&255,v>>16&255,v>>8&255,255&v,n>>24&255,n>>16&255,n>>8&255,255&n,s>>24&255,s>>16&255,s>>8&255,255&s];return $>=256&&N.push(e>>24&255,e>>16&255,e>>8&255,255&e),$>=384&&N.push(u>>24&255,u>>16&255,u>>8&255,255&u,l>>24&255,l>>16&255,l>>8&255,255&l,U>>24&255,U>>16&255,U>>8&255,255&U,O>>24&255,O>>16&255,O>>8&255,255&O),$==512&&N.push(B>>24&255,B>>16&255,B>>8&255,255&B,H>>24&255,H>>16&255,H>>8&255,255&H,J>>24&255,J>>16&255,J>>8&255,255&J,A>>24&255,A>>16&255,A>>8&255,255&A),N},z.prototype.array=z.prototype.digest,z.prototype.arrayBuffer=function(){this.finalize();var h=this.bits,b=new ArrayBuffer(h/8),_=new DataView(b);return _.setUint32(0,this.h0h),_.setUint32(4,this.h0l),_.setUint32(8,this.h1h),_.setUint32(12,this.h1l),_.setUint32(16,this.h2h),_.setUint32(20,this.h2l),_.setUint32(24,this.h3h),h>=256&&_.setUint32(28,this.h3l),h>=384&&(_.setUint32(32,this.h4h),_.setUint32(36,this.h4l),_.setUint32(40,this.h5h),_.setUint32(44,this.h5l)),h==512&&(_.setUint32(48,this.h6h),_.setUint32(52,this.h6l),_.setUint32(56,this.h7h),_.setUint32(60,this.h7l)),b},z.prototype.clone=function(){var h=new z(this.bits,!1);return this.copyTo(h),h},z.prototype.copyTo=function(h){var b=0,_=["h0h","h0l","h1h","h1l","h2h","h2l","h3h","h3l","h4h","h4l","h5h","h5l","h6h","h6l","h7h","h7l","start","bytes","hBytes","finalized","hashed","lastByteIndex"];for(b=0;b<_.length;++b)h[_[b]]=this[_[b]];for(b=0;b<this.blocks.length;++b)h.blocks[b]=this.blocks[b]},gt.prototype=new z,gt.prototype.finalize=function(){if(z.prototype.finalize.call(this),this.inner){this.inner=!1;var h=this.array();z.call(this,this.bits,this.sharedMemory),this.update(this.oKeyPad),this.update(h),z.prototype.finalize.call(this)}},gt.prototype.clone=function(){var h=new gt([],this.bits,!1);this.copyTo(h),h.inner=this.inner;for(var b=0;b<this.oKeyPad.length;++b)h.oKeyPad[b]=this.oKeyPad[b];return h};var V=Y(512);V.sha512=V,V.sha384=Y(384),V.sha512_256=Y(256),V.sha512_224=Y(224),V.sha512.hmac=X(512),V.sha384.hmac=X(384),V.sha512_256.hmac=X(256),V.sha512_224.hmac=X(224),F?f.exports=V:(R.sha512=V.sha512,R.sha384=V.sha384,R.sha512_256=V.sha512_256,R.sha512_224=V.sha512_224,I&&((d=function(){return V}.call(V,p,V,f))===void 0||(f.exports=d)))})()},900:(f,y,p)=>{Object.defineProperty(y,"__esModule",{value:!0});var d=p(655),g=p(434),w=function(C){var F=C.input,I=C.expected;return(0,d.__awaiter)(void 0,void 0,void 0,function(){var j,a;return(0,d.__generator)(this,function(S){switch(S.label){case 0:j=0,S.label=1;case 1:return a=(0,g.sha512)(F+":"+j),j%4e4!=0?[3,3]:[4,R(0)];case 2:S.sent(),S.label=3;case 3:return a.substring(0,I.length)===I?[2,j.toString()]:(j++,[3,1]);case 4:return[2]}})})},R=function(C){return new Promise(function(F){return setTimeout(F,C)})};y.default=function(C){var F=C.challenge,I=C.onProgress;return(0,d.__awaiter)(void 0,void 0,void 0,function(){var j,a,S,P,q,L,T;return(0,d.__generator)(this,function(D){switch(D.label){case 0:j=F.payload,a=j.nonce,S=j.difficulty,P=j.hardness,q=[],I==null||I(0),L=0,D.label=1;case 1:return L<P?[4,w({input:a+":"+L,expected:"0".repeat(S)})]:[3,5];case 2:return T=D.sent(),q.push(T),I==null||I(q.length/P),[4,R(0)];case 3:D.sent(),D.label=4;case 4:return L++,[3,1];case 5:return[2,q]}})})}},655:(f,y,p)=>{p.r(y),p.d(y,{__extends:()=>g,__assign:()=>w,__rest:()=>R,__decorate:()=>C,__param:()=>F,__metadata:()=>I,__awaiter:()=>j,__generator:()=>a,__createBinding:()=>S,__exportStar:()=>P,__values:()=>q,__read:()=>L,__spread:()=>T,__spreadArrays:()=>D,__spreadArray:()=>Y,__await:()=>K,__asyncGenerator:()=>X,__asyncDelegator:()=>z,__asyncValues:()=>
1gt,__makeTemplateObject:()=>V,__importStar:()=>b,__importDefault:()=>_,__classPrivateFieldGet:()=>E,__classPrivateFieldSet:()=>v});var d=function(n,s){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,u){e.__proto__=u}||function(e,u){for(var l in u)Object.prototype.hasOwnProperty.call(u,l)&&(e[l]=u[l])},d(n,s)};function g(n,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");function e(){this.constructor=n}d(n,s),n.prototype=s===null?Object.create(s):(e.prototype=s.prototype,new e)}var w=function(){return w=Object.assign||function(n){for(var s,e=1,u=arguments.length;e<u;e++)for(var l in s=arguments[e])Object.prototype.hasOwnProperty.call(s,l)&&(n[l]=s[l]);return n},w.apply(this,arguments)};function R(n,s){var e={};for(var u in n)Object.prototype.hasOwnProperty.call(n,u)&&s.indexOf(u)<0&&(e[u]=n[u]);if(n!=null&&typeof Object.getOwnPropertySymbols=="function"){var l=0;for(u=Object.getOwnPropertySymbols(n);l<u.length;l++)s.indexOf(u[l])<0&&Object.prototype.propertyIsEnumerable.call(n,u[l])&&(e[u[l]]=n[u[l]])}return e}function C(n,s,e,u){var l,U=arguments.length,O=U<3?s:u===null?u=Object.getOwnPropertyDescriptor(s,e):u;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")O=Reflect.decorate(n,s,e,u);else for(var B=n.length-1;B>=0;B--)(l=n[B])&&(O=(U<3?l(O):U>3?l(s,e,O):l(s,e))||O);return U>3&&O&&Object.defineProperty(s,e,O),O}function F(n,s){return function(e,u){s(e,u,n)}}function I(n,s){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(n,s)}function j(n,s,e,u){return new(e||(e=Promise))(function(l,U){function O(J){try{H(u.next(J))}catch(A){U(A)}}function B(J){try{H(u.throw(J))}catch(A){U(A)}}function H(J){var A;J.done?l(J.value):(A=J.value,A instanceof e?A:new e(function($){$(A)})).then(O,B)}H((u=u.apply(n,s||[])).next())})}function a(n,s){var e,u,l,U,O={label:0,sent:function(){if(1&l[0])throw l[1];return l[1]},trys:[],ops:[]};return U={next:B(0),throw:B(1),return:B(2)},typeof Symbol=="function"&&(U[Symbol.iterator]=function(){return this}),U;function B(H){return function(J){return function(A){if(e)throw new TypeError("Generator is already executing.");for(;O;)try{if(e=1,u&&(l=2&A[0]?u.return:A[0]?u.throw||((l=u.return)&&l.call(u),0):u.next)&&!(l=l.call(u,A[1])).done)return l;switch(u=0,l&&(A=[2&A[0],l.value]),A[0]){case 0:case 1:l=A;break;case 4:return O.label++,{value:A[1],done:!1};case 5:O.label++,u=A[1],A=[0];continue;case 7:A=O.ops.pop(),O.trys.pop();continue;default:if(!((l=(l=O.trys).length>0&&l[l.length-1])||A[0]!==6&&A[0]!==2)){O=0;continue}if(A[0]===3&&(!l||A[1]>l[0]&&A[1]<l[3])){O.label=A[1];break}if(A[0]===6&&O.label<l[1]){O.label=l[1],l=A;break}if(l&&O.label<l[2]){O.label=l[2],O.ops.push(A);break}l[2]&&O.ops.pop(),O.trys.pop();continue}A=s.call(n,O)}catch($){A=[6,$],u=0}finally{e=l=0}if(5&A[0])throw A[1];return{value:A[0]?A[1]:void 0,done:!0}}([H,J])}}}var S=Object.create?function(n,s,e,u){u===void 0&&(u=e),Object.defineProperty(n,u,{enumerable:!0,get:function(){return s[e]}})}:function(n,s,e,u){u===void 0&&(u=e),n[u]=s[e]};function P(n,s){for(var e in n)e==="default"||Object.prototype.hasOwnProperty.call(s,e)||S(s,n,e)}function q(n){var s=typeof Symbol=="function"&&Symbol.iterator,e=s&&n[s],u=0;if(e)return e.call(n);if(n&&typeof n.length=="number")return{next:function(){return n&&u>=n.length&&(n=void 0),{value:n&&n[u++],done:!n}}};throw new TypeError(s?"Object is not iterable.":"Symbol.iterator is not defined.")}function L(n,s){var e=typeof Symbol=="function"&&n[Symbol.iterator];if(!e)return n;var u,l,U=e.call(n),O=[];try{for(;(s===void 0||s-- >0)&&!(u=U.next()).done;)O.push(u.value)}catch(B){l={error:B}}finally{try{u&&!u.done&&(e=U.return)&&e.call(U)}finally{if(l)throw l.error}}return O}function T(){for(var n=[],s=0;s<arguments.length;s++)n=n.concat(L(arguments[s]));return n}function D(){for(var n=0,s=0,e=arguments.length;s<e;s++)n+=arguments[s].length;var u=Array(n),l=0;for(s=0;s<e;s++)for(var U=arguments[s],O=0,B=U.length;O<B;O++,l++)u[l]=U[O];return u}function Y(n,s,e){if(e||arguments.length===2)for(var u,l=0,U=s.length;l<U;l++)!u&&l in s||(u||(u=Array.prototype.slice.call(s,0,l)),u[l]=s[l]);return n.concat(u||Array.prototype.slice.call(s))}function K(n){return this instanceof K?(this.v=n,this):new K(n)}function X(n,s,e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var u,l=e.apply(n,s||[]),U=[];return u={},O("next"),O("throw"),O("return"),u[Symbol.asyncIterator]=function(){return this},u;function O($){l[$]&&(u[$]=function(N){return new Promise(function(Q,k){U.push([$,N,Q,k])>1||B($,N)})})}function B($,N){try{(Q=l[$](N)).value instanceof K?Promise.resolve(Q.value.v).then(H,J):A(U[0][2],Q)}catch(k){A(U[0][3],k)}var Q}function H($){B("next",$)}function J($){B("throw",$)}function A($,N){$(N),U.shift(),U.length&&B(U[0][0],U[0][1])}}function z(n){var s,e;return s={},u("next"),u("throw",function(l){throw l}),u("return"),s[Symbol.iterator]=function(){return this},s;function u(l,U){s[l]=n[l]?function(O){return(e=!e)?{value:K(n[l](O)),done:l==="return"}:U?U(O):O}:U}}function gt(n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var s,e=n[Symbol.asyncIterator];return e?e.call(n):(n=q(n),s={},u("next"),u("throw"),u("return"),s[Symbol.asyncIterator]=function(){return this},s);function u(l){s[l]=n[l]&&function(U){return new Promise(function(O,B){(function(H,J,A,$){Promise.resolve($).then(function(N){H({value:N,done:A})},J)})(O,B,(U=n[l](U)).done,U.value)})}}}function V(n,s){return Object.defineProperty?Object.defineProperty(n,"raw",{value:s}):n.raw=s,n}var h=Object.create?function(n,s){Object.defineProperty(n,"default",{enumerable:!0,value:s})}:function(n,s){n.default=s};function b(n){if(n&&n.__esModule)return n;var s={};if(n!=null)for(var e in n)e!=="default"&&Object.prototype.hasOwnProperty.call(n,e)&&S(s,n,e);return h(s,n),s}function _(n){return n&&n.__esModule?n:{default:n}}function E(n,s,e,u){if(e==="a"&&!u)throw new TypeError("Private accessor was defined without a getter");if(typeof s=="function"?n!==s||!u:!s.has(n))throw new TypeError("Cannot read private member from an object whose class did not declare it");return e==="m"?u:e==="a"?u.call(n):u?u.value:s.get(n)}function v(n,s,e,u,l){if(u==="m")throw new TypeError("Private method is not writable");if(u==="a"&&!l)throw new TypeError("Private accessor was defined without a setter");if(typeof s=="function"?n!==s||!l:!s.has(n))throw new TypeError("Cannot write private member to an object whose class did not declare it");return u==="a"?l.call(n,e):l?l.value=e:s.set(n,e),e}},147:f=>{f.exports={i8:"0.1.30"}}},i={};function c(f){var y=i[f];if(y!==void 0)return y.exports;var p=i[f]={exports:{}};return o[f](p,p.exports,c),p.exports}c.amdO={},c.d=(f,y)=>{for(var p in y)c.o(y,p)&&!c.o(f,p)&&Object.defineProperty(f,p,{enumerable:!0,get:y[p]})},c.g=function(){if(typeof globalThis=="object")return globalThis;try{return this||new Function("return this")()}catch{if(typeof window=="object")return window}
1}(),c.o=(f,y)=>Object.prototype.hasOwnProperty.call(f,y),c.r=f=>{typeof Symbol!="undefined"&&Symbol.toStringTag&&Object.defineProperty(f,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(f,"__esModule",{value:!0})};var m={};return(()=>{var f=m,y=c(655),p=(0,y.__importDefault)(c(900)),d=function(){w(),R(),C()},g=function(){function F(I){var j=I.publicKey;this.publicKey=j}return F.init=function(){d()},F.prototype.challenge=function(I){return(0,y.__awaiter)(this,void 0,void 0,function(){var j,a,S;return(0,y.__generator)(this,function(P){switch(P.label){case 0:return j=(I||{}).onProgress,[4,fetch("https://api.botpoison.com/challenge",{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({publicKey:this.publicKey,hostname:location.hostname})})];case 1:return[4,P.sent().json()];case 2:return a=P.sent(),[4,(0,p.default)({challenge:a,onProgress:j})];case 3:return S=P.sent(),[2,{solution:btoa(JSON.stringify({challenge:a,solutions:S}))}]}})})},F}();f.default=g;var w=function(){typeof document!="undefined"&&(window.__BOTPOISON_VERSION__=c(147).i8)},R=function(){typeof document!="undefined"&&(window.__BOTPOISON_SUBMIT_LISTENER__||(window.__BOTPOISON_SUBMIT_LISTENER__=!0,document.addEventListener("submit",function(F){try{var I=F.target;if(I){var j=I,a=j.dataset.botpoisonPublicKey;if(a){F.preventDefault(),j.dispatchEvent(new CustomEvent("botpoison-challenge-start"));var S=new g({publicKey:a});S.challenge().then(function(P){var q=P.solution;j.dispatchEvent(new CustomEvent("botpoison-challenge-success")),function(L){var T=L.formElement,D=L.id,Y=L.name,K=L.value,X=document.getElementById(D);if(!X){var z=document.createElement("input");z.setAttribute("type","hidden"),z.setAttribute("id",D),z.setAttribute("name",Y),T.appendChild(z),X=z}X.setAttribute("value",K)}({formElement:j,id:"_botpoison",name:"_botpoison",value:q}),HTMLFormElement.prototype.submit.call(j)}).catch(function(P){console.error(P),j.dispatchEvent(new CustomEvent("botpoison-challenge-error"))})}}}catch(P){console.error(P)}return!0})))},C=function(){typeof document=="undefined"||window.__BOTPOISON_HEARTBEAT_DISPATCHER__||(window.__BOTPOISON_HEARTBEAT_DISPATCHER__=!0)};d()})(),m.default})()})})(re);var ve=we(re.exports);class dt extends Error{constructor(t,o,i,c,m){super(),this.name="UploadClientError",this.message=t,this.code=o,this.request=i,this.response=c,this.headers=m,Object.setPrototypeOf(this,dt.prototype)}}const Xt=(r="Request canceled")=>{const t=new dt(r);return t.isCancel=!0,t},Tt=(r,t)=>{r&&(r.aborted?Promise.resolve().then(t):r.addEventListener("abort",()=>t(),{once:!0}))},Ot=({method:r,url:t,data:o,headers:i={},signal:c,onProgress:m})=>new Promise((f,y)=>{const p=new XMLHttpRequest,d=(r==null?void 0:r.toUpperCase())||"GET";let g=!1;p.open(d,t,!0),i&&Object.entries(i).forEach(w=>{const[R,C]=w;typeof C!="undefined"&&!Array.isArray(C)&&p.setRequestHeader(R,C)}),p.responseType="text",Tt(c,()=>{g=!0,p.abort(),y(Xt())}),p.onload=()=>{if(p.status!=200)y(new Error(`Error ${p.status}: ${p.statusText}`));else{const w={method:d,url:t,data:o,headers:i||void 0,signal:c,onProgress:m},R=p.getAllResponseHeaders().trim().split(/[\r\n]+/),C={};R.forEach(function(j){const a=j.split(": "),S=a.shift(),P=a.join(": ");S&&typeof S!="undefined"&&(C[S]=P)});const F=p.response,I=p.status;f({request:w,data:F,headers:C,status:I})}},p.onerror=()=>{g||y(new Error("Network error"))},m&&typeof m=="function"&&(p.upload.onprogress=w=>{w.lengthComputable?m({isComputable:!0,value:w.loaded/w.total}):m({isComputable:!1})}),o?p.send(o):p.send()});function _e(r){return r}const ge=({name:r})=>r?[r]:[],Se=_e;var Oe=()=>new FormData;const Ut=r=>r!==void 0&&(typeof Blob!="undefined"&&r instanceof Blob||typeof File!="undefined"&&r instanceof File||typeof Buffer!="undefined"&&r instanceof Buffer),ne=r=>{const t="[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}",o=new RegExp(t);return!Ut(r)&&o.test(r)},se=r=>{const t="^(?:\\w+:)?\\/\\/([^\\s\\.]+\\.\\S{2}
1|localhost[\\:?\\d]*)\\S*$",o=new RegExp(t);return!Ut(r)&&o.test(r)},Ee=r=>typeof r=="string"||typeof r=="number"||typeof r=="undefined",Ae=r=>!!r&&typeof r=="object"&&!Array.isArray(r),Ce=r=>!!r&&typeof r=="object"&&"data"in r&&Ut(r.data);function Ue(r,t,o){if(Ce(o)){const{name:i,contentType:c}=o,m=Se(o.data),f=ge({name:i,contentType:c});r.push([t,m,...f])}else if(Ae(o))for(const[i,c]of Object.entries(o))typeof c!="undefined"&&r.push([`${t}[${i}]`,String(c)]);else Ee(o)&&o&&r.push([t,o.toString()])}function Te(r){const t=[];for(const[o,i]of Object.entries(r))Ue(t,o,i);return t}function Vt(r){const t=Oe(),o=Te(r);for(const i of o){const[c,m,...f]=i;t.append(c,m,...f)}return t}const je=r=>{const t=new URLSearchParams;for(const[o,i]of Object.entries(r))i&&typeof i=="object"&&!Array.isArray(i)?Object.entries(i).filter(c=>{var m;return(m=c[1])!=null?m:!1}).forEach(c=>t.set(`${o}[${c[0]}]`,String(c[1]))):Array.isArray(i)?i.forEach(c=>{t.append(`${o}[]`,c)}):typeof i=="string"&&i?t.set(o,i):typeof i=="number"&&t.set(o,i.toString());return t.toString()},Et=(r,t,o)=>{const i=new URL(r);return i.pathname=(i.pathname+t).replace("//","/"),o&&(i.search=je(o)),i.toString()},M={baseCDN:"https://ucarecdn.com",baseURL:"https://upload.uploadcare.com",maxContentLength:50*1024*1024,retryThrottledRequestMaxTimes:1,multipartMinFileSize:25*1024*1024,multipartChunkSize:5*1024*1024,multipartMinLastPartSize:1024*1024,maxConcurrentRequests:4,multipartMaxAttempts:3,pollingTimeoutMilliseconds:1e4,pusherKey:"79ae88bd931ea68464d9"},Pe="application/octet-stream",oe="original";var ke="4.3.1";function te(r){return Object.prototype.toString.call(r)==="[object Object]"}const Re=/\W|_/g;function xe(r){return r.split(Re).map((t,o)=>t.charAt(0)[o>0?"toUpperCase":"toLowerCase"]()+t.slice(1)).join("")}function ee(r,{ignoreKeys:t}={ignoreKeys:[]}){return Array.isArray(r)?r.map(o=>St(o,{ignoreKeys:t})):r}function St(r,{ignoreKeys:t}={ignoreKeys:[]}){if(Array.isArray(r))return ee(r,{ignoreKeys:t});if(!te(r))return r;const o={};for(const i of Object.keys(r)){let c=r[i];if(t.includes(i)){o[i]=c;continue}te(c)?c=St(c,{ignoreKeys:t}):Array.isArray(c)&&(c=ee(c,{ignoreKeys:t})),o[xe(i)]=c}return o}const Fe=r=>new Promise(t=>setTimeout(t,r));function Be({libraryName:r,libraryVersion:t,userAgent:o,publicKey:i="",integration:c=""}){const m="JavaScript";if(typeof o=="string")return o;if(typeof o=="function")return o({publicKey:i,libraryName:r,libraryVersion:t,languageName:m,integration:c});const f=[r,t,i].filter(Boolean).join("/"),y=[m,c].filter(Boolean).join("; ");return`${f} (${y})`}const Ie={factor:2,time:100};function ie(r,t=Ie){let o=0;function i(c){const m=Math.round(t.time*t.factor**o);return c({attempt:o,retry:y=>Fe(y!=null?y:m).then(()=>(o+=1,i(c)))})}return i(r)}const De="UploadcareUploadClient",ze=ke;function At(r){return Be({libraryName:De,libraryVersion:ze,...r})}const Le="RequestThrottledError",Ne=15e3;function Je(r){const{headers:t}=r||{};return t&&Number.parseInt(t["x-throttle-wait-seconds"])*1e3||Ne}function Ct(r,t){return ie(({attempt:o,retry:i})=>r().catch(c=>{if("response"in c&&(c==null?void 0:c.code)===Le&&o<t)return i(Je(c));throw c}))}function Yt(r){return typeof r=="undefined"?"auto":r?"1":"0"}function ae(r,{publicKey:t,fileName:o,contentType:i,baseURL:c=M.baseURL,secureSignature:m,secureExpire:f,store:y,signal:p,onProgress:d,source:g="local",integration:w,userAgent:R,retryThrottledRequestMaxTimes:C=M.retryThrottledRequestMaxTimes,metadata:F}){return Ct(()=>{var I;return Ot({method:"POST",url:Et(c,"/base/",{jsonerrors:1}),headers:{"X-UC-User-Agent":At({publicKey:t,integration:w,userAgent:R})},data:Vt({file:{data:r,name:(I=o!=null?o:r.name)!=null?I:oe,contentType:i},UPLOADCARE_PUB_KEY:t,UPLOADCARE_STORE:Yt(y),signature:m,expire:f,source:g,metadata:F}),signal:p,onProgress:d}).then(({data:j,headers:a,request:S})=>{const P=St(JSON.parse(j));if("error"in P)throw new dt(P.error.content,P.error.errorCode,S,P,a);return P})},C)}var Wt;(function(r){r.Token="token",r.FileInfo="file_info"})(Wt||(Wt={}));function he(r,{publicKey:t,baseURL:o=M.baseURL,store:i,fileName:c,checkForUrlDuplicates:m,s
1aveUrlForRecurrentUploads:f,secureSignature:y,secureExpire:p,source:d="url",signal:g,integration:w,userAgent:R,retryThrottledRequestMaxTimes:C=M.retryThrottledRequestMaxTimes,metadata:F}){return Ct(()=>Ot({method:"POST",headers:{"X-UC-User-Agent":At({publicKey:t,integration:w,userAgent:R})},url:Et(o,"/from_url/",{jsonerrors:1,pub_key:t,source_url:r,store:Yt(i),filename:c,check_URL_duplicates:m?1:void 0,save_URL_duplicates:f?1:void 0,signature:y,expire:p,source:d,metadata:F}),signal:g}).then(({data:I,headers:j,request:a})=>{const S=St(JSON.parse(I));if("error"in S)throw new dt(S.error.content,S.error.errorCode,a,S,j);return S}),C)}var bt;(function(r){r.Unknown="unknown",r.Waiting="waiting",r.Progress="progress",r.Error="error",r.Success="success"})(bt||(bt={}));const $e=r=>"status"in r&&r.status===bt.Error;function ue(r,{publicKey:t,baseURL:o=M.baseURL,signal:i,integration:c,userAgent:m,retryThrottledRequestMaxTimes:f=M.retryThrottledRequestMaxTimes}={}){return Ct(()=>Ot({method:"GET",headers:t?{"X-UC-User-Agent":At({publicKey:t,integration:c,userAgent:m})}:void 0,url:Et(o,"/from_url/status/",{jsonerrors:1,token:r}),signal:i}).then(({data:y,headers:p,request:d})=>{const g=St(JSON.parse(y));if("error"in g&&!$e(g))throw new dt(g.error.content,void 0,d,g,p);return g}),f)}function ce(r,{publicKey:t,baseURL:o=M.baseURL,jsonpCallback:i,secureSignature:c,secureExpire:m,signal:f,source:y,integration:p,userAgent:d,retryThrottledRequestMaxTimes:g=M.retryThrottledRequestMaxTimes}){return Ct(()=>Ot({method:"POST",headers:{"X-UC-User-Agent":At({publicKey:t,integration:p,userAgent:d})},url:Et(o,"/group/",{jsonerrors:1,pub_key:t,files:r,callback:i,signature:c,expire:m,source:y}),signal:f}).then(({data:w,headers:R,request:C})=>{const F=St(JSON.parse(w));if("error"in F)throw new dt(F.error.content,F.error.errorCode,C,F,R);return F}),g)}function Me(r,{publicKey:t,baseURL:o=M.baseURL,signal:i,source:c,integration:m,userAgent:f,retryThrottledRequestMaxTimes:y=M.retryThrottledRequestMaxTimes}){return Ct(()=>Ot({method:"GET",headers:{"X-UC-User-Agent":At({publicKey:t,integration:m,userAgent:f})},url:Et(o,"/group/info/",{jsonerrors:1,pub_key:t,group_id:r,source:c}),signal:i}).then(({data:p,headers:d,request:g})=>{const w=St(JSON.parse(p));if("error"in w)throw new dt(w.error.content,w.error.errorCode,g,w,d);return w}),y)}function Qt(r,{publicKey:t,baseURL:o=M.baseURL,signal:i,source:c,integration:m,userAgent:f,retryThrottledRequestMaxTimes:y=M.retryThrottledRequestMaxTimes}){return Ct(()=>Ot({method:"GET",headers:{"X-UC-User-Agent":At({publicKey:t,integration:m,userAgent:f})},url:Et(o,"/info/",{jsonerrors:1,pub_key:t,file_id:r,source:c}),signal:i}).then(({data:p,headers:d,request:g})=>{const w=St(JSON.parse(p));if("error"in w)throw new dt(w.error.content,w.error.errorCode,g,w,d);return w}),y)}function le(r,{publicKey:t,contentType:o,fileName:i,multipartChunkSize:c=M.multipartChunkSize,baseURL:m="",secureSignature:f,secureExpire:y,store:p,signal:d,source:g="local",integration:w,userAgent:R,retryThrottledRequestMaxTimes:C=M.retryThrottledRequestMaxTimes,metadata:F}){return Ct(()=>Ot({method:"POST",url:Et(m,"/multipart/start/",{jsonerrors:1}),headers:{"X-UC-User-Agent":At({publicKey:t,integration:w,userAgent:R})},data:Vt({filename:i!=null?i:oe,size:r,content_type:o!=null?o:Pe,part_size:c,UPLOADCARE_STORE:Yt(p),UPLOADCARE_PUB_KEY:t,signature:f,expire:y,source:g,metadata:F}),signal:d}).then(({data:I,headers:j,request:a})=>{const S=St(JSON.parse(I));if("error"in S)throw new dt(S.error.content,S.error.errorCode,a,S,j);return S.parts=Object.keys(S.parts).map(P=>S.parts[P]),S}),C)}function fe(r,t,{signal:o,onProgress:i}){return Ot({method:"PUT",url:t,data:r,onProgress:i,signal:o}).then(c=>(i&&i({isComputable:!0,value:1}),c)).then(({status:c})=>({code:c}))}function pe(r,{publicKey:t,baseURL:o=M.baseURL,source:i="local",signal:c,integration:m,userAgent:f,retryThrottledRequestMaxTimes:y=M.retryThrottledRequestMaxTimes}){return Ct(()=>Ot({method:"POST",url:Et(o,"/multipart/complete/",{jsonerrors:1}),headers:{"X-UC-User-Agent":At({publicKey:t,integration:m,userAgent:f})},data:Vt({uuid:r,UPLOADCARE_PUB_KEY:t,source:i}),signal:c}).then(({data:p,headers:d,request:g})=>{const w=St(JSON.parse(p));if("error"in w)throw new dt(w.error.content,w.error.errorCode,g,w,d);return w}),y)}class jt{constructor(t,{baseCDN:o,fileName:i}){this.name=null,this.size=null,this.isStored=null,this.isImage=null,this.mimeType=null,this.cdnUrl=null,this.s3Url=null,this.originalFilename=null,this.imageInfo=null,this.videoInfo=null,this.contentInfo=null,this.metadata=null,this.s3Bucket=null;const{uuid:c,s3Bucket:m}=t,f=`${o}/${c}/`,y=m?`https://${m}.s3.amazonaws.com/${c}/${t.filename}`:null;this.uuid=c,this.name=i||t.filename,this.size=t.size,this.isStored=t.isStored,this.isImage=t.isImage,this.mimeType=t.mimeType,this.cdnUrl=f,this.originalFilename=t.originalFilename,this.imageInfo=t.imageInfo,this.videoInfo=t.videoInfo,this.contentInfo=t.contentInfo,this.metadata=t.metadata||null,this.s3Bucket=m||null,this.s3Url=y}}const He=500,de=({check:r,interval:t=He,signal:o})=>new Promise((i,c)=>{let m;Tt(o,()=>{m&&clearTimeout(m),c(Xt("Poll cancelled"))});const f=()=>{try{Promise.resolve(r(o)).then(y=>{y?i(y):m=setTimeout(f,t)}).catch(y=>c(y))}catch(y){c(y)}};m=setTimeout(f,0)});function Zt({file:r,publicKey:t,baseURL:o,source:i,integration:c,userAgent:m,retryThrottledRequestMaxTimes:f,signal:y,onProgress:p}){return de({check:d=>Qt(r,{publicKey:t,baseURL:o,signal:d,source:i,integration:c,userAgent:m,retryThrottledRequestMaxTimes:f}).then(g=>g.isReady?g:(p&&p({isComputable:!0,value:1}),!1)),signal:y})}const qe=(r,{publicKey:t,fileName:o,baseURL:i,secureSignature:c,secureExpire:m,store:f,contentType:y,signal:p,onProgress:d,source:g,integration:w,userAgent:R,retryThrottledRequestMaxTimes:C,baseCDN:F,metadata:I})=>ae(r,{publicKey:t,fileName:o,contentType:y,baseURL:i,secureSignature:c,secureExpire:m,store:f,signal:p,onProgress:d,source:g,integration:w,userAgent:R,retryThrottledRequestMaxTimes:C,metadata:I}).then(({file:j})=>Zt({file:j,publicKey:t,baseURL:i,source:g,integration:w,userAgent:R,retryThrottledRequestMaxTimes:C,onProgress:d,signal:p})).then(j=>new jt(j,{baseCDN:F})),Ge=(r,{signal:t}={})=>{let o=null,i=null;const c=r.map(()=>new AbortController),m=f=>()=>
1{i=f,c.forEach((y,p)=>p!==f&&y.abort())};return Tt(t,()=>{c.forEach(f=>f.abort())}),Promise.all(r.map((f,y)=>{const p=m(y);return Promise.resolve().then(()=>f({stopRace:p,signal:c[y].signal})).then(d=>(p(),d)).catch(d=>(o=d,null))})).then(f=>{if(i===null)throw o;return f[i]})};var We=window.WebSocket;class Xe{constructor(){this.events=Object.create({})}emit(t,o){var i;(i=this.events[t])==null||i.forEach(c=>c(o))}on(t,o){this.events[t]=this.events[t]||[],this.events[t].push(o)}off(t,o){o?this.events[t]=this.events[t].filter(i=>i!==o):this.events[t]=[]}}const Ve=(r,t)=>r==="success"?{status:bt.Success,...t}:r==="progress"?{status:bt.Progress,...t}:{status:bt.Error,...t};class Ye{constructor(t,o=3e4){this.ws=void 0,this.queue=[],this.isConnected=!1,this.subscribers=0,this.emmitter=new Xe,this.disconnectTimeoutId=null,this.key=t,this.disconnectTime=o}connect(){if(this.disconnectTimeoutId&&clearTimeout(this.disconnectTimeoutId),!this.isConnected&&!this.ws){const t=`wss://ws.pusherapp.com/app/${this.key}?protocol=5&client=js&version=1.12.2`;this.ws=new We(t),this.ws.addEventListener("error",o=>{this.emmitter.emit("error",new Error(o.message))}),this.emmitter.on("connected",()=>{this.isConnected=!0,this.queue.forEach(o=>this.send(o.event,o.data)),this.queue=[]}),this.ws.addEventListener("message",o=>{const i=JSON.parse(o.data.toString());switch(i.event){case"pusher:connection_established":{this.emmitter.emit("connected",void 0);break}case"pusher:ping":{this.send("pusher:pong",{});break}case"progress":case"success":case"fail":this.emmitter.emit(i.channel,Ve(i.event,JSON.parse(i.data)))}})}}disconnect(){const t=()=>{var o;(o=this.ws)==null||o.close(),this.ws=void 0,this.isConnected=!1};this.disconnectTime?this.disconnectTimeoutId=setTimeout(()=>{t()},this.disconnectTime):t()}send(t,o){var c;const i=JSON.stringify({event:t,data:o});(c=this.ws)==null||c.send(i)}subscribe(t,o){this.subscribers+=1,this.connect();const i=`task-status-${t}`,c={event:"pusher:subscribe",data:{channel:i}};this.emmitter.on(i,o),this.isConnected?this.send(c.event,c.data):this.queue.push(c)}unsubscribe(t){this.subscribers-=1;const o=`task-status-${t}`,i={event:"pusher:unsubscribe",data:{channel:o}};this.emmitter.off(o),this.isConnected?this.send(i.event,i.data):this.queue=this.queue.filter(c=>c.data.channel!==o),this.subscribers===0&&this.disconnect()}onError(t){return this.emmitter.on("error",t),()=>this.emmitter.off("error",t)}}let Gt=null;const Kt=r=>{if(!Gt){const t=typeof window=="undefined"?0:3e4;Gt=new Ye(r,t)}return Gt},Qe=r=>{Kt(r).connect()};function Ze({token:r,publicKey:t,baseURL:o,integration:i,userAgent:c,retryThrottledRequestMaxTimes:m,onProgress:f,signal:y}){return de({check:p=>ue(r,{publicKey:t,baseURL:o,integration:i,userAgent:c,retryThrottledRequestMaxTimes:m,signal:p}).then(d=>{switch(d.status){case bt.Error:return new dt(d.error,d.errorCode);case bt.Waiting:return!1;case bt.Unknown:return new dt(`Token "${r}" was not found.`);case bt.Progress:return f&&(d.total==="unknown"?f({isComputable:!1}):f({isComputable:!0,value:d.done/d.total})),!1;case bt.Success:return f&&f({isComputable:!0,value:d.done/d.total}),d;default:throw new Error("Unknown status")}}),signal:y})}const Ke=({token:r,pusherKey:t,signal:o,onProgress:i})=>new Promise((c,m)=>{const f=Kt(t),y=f.onError(m),p=()=>{y(),f.unsubscribe(r)};Tt(o,()=>{p(),m(Xt("pusher cancelled"))}),f.subscribe(r,d=>{switch(d.status){case bt.Progress:{i&&(d.total==="unknown"?i({isComputable:!1}):i({isComputable:!0,value:d.done/d.total}));break}case bt.Success:{p(),i&&i({isComputable:!0,value:d.done/d.total}),c(d);break}case bt.Error:p(),m(new dt(d.msg,d.error_code))}})}),tr=(r,{publicKey:t,fileName:o,baseURL:i,baseCDN:c,checkForUrlDuplicates:m,saveUrlForRecurrentUploads:f,secureSignature:y,secureExpire:p,store:d,signal:g,onProgress:w,source:R,integration:C,userAgent:F,retryThrottledRequestMaxTimes:I,pusherKey:j=M.pusherKey,metadata:a})=>Promise.resolve(Qe(j)).then(()=>he(r,{publicKey:t,fileName:o,baseURL:i,checkForUrlDuplicates:m,saveUrlForRecurrentUploads:f,secureSignature:y,secureExpire:p,store:d,signal:g,source:R,integration:C,userAgent:F,retryThrottledRequestMaxTimes:I,metadata:a})).catch(S=>{const P=Kt(j);return P==null||P.disconnect(),Promise.reject(S)}).then(S=>S.type===Wt.FileInfo?S:Ge([({signal:P})=>Ze({token:S.token,publicKey:t,baseURL:i,integration:C,userAgent:F,retryThrottledRequestMaxTimes:I,onProgress:w,signal:P}),({signal:P})=>Ke({token:S.token,pusherKey:j,signal:P,onProgress:w})],{signal:g})).then(S=>{if(S instanceof dt)throw S;return S}).then(S=>Zt({file:S.uuid,publicKey:t,baseURL:i,integration:C,userAgent:F,retryThrottledRequestMaxTimes:I,onProgress:w,signal:g})).then(S=>new jt(S,{baseCDN:c})),er=(r,{publicKey:t,fileName:o,baseURL:i,signal:c,onProgress:m,source:f,integration:y,userAgent:p,retryThrottledRequestMaxTimes:d,baseCDN:g})=>Qt(r,{publicKey:t,baseURL:i,signal:c,source:f,integration:y,userAgent:p,retryThrottledRequestMaxTimes:d}).then(w=>
1new jt(w,{baseCDN:g,fileName:o})).then(w=>(m&&m({isComputable:!0,value:1}),w)),me=r=>r.length||r.size,rr=(r,t=M.multipartMinFileSize)=>r>=t,nr=(r,t,o,i)=>{const c=i*t,m=Math.min(c+i,o);return r.slice(c,m)};function sr(r,t,o){return i=>nr(r,i,t,o)}const or=(r,t)=>new Promise((o,i)=>{const c=[];let m=!1,f=t.length;const y=[...t],p=()=>{const d=t.length-y.length,g=y.shift();g&&g().then(w=>{m||(c[d]=w,f-=1,f?p():o(c))}).catch(w=>{m=!0,i(w)})};for(let d=0;d<r;d++)p()}),ir=(r,t,{publicKey:o,onProgress:i,signal:c,integration:m,multipartMaxAttempts:f})=>ie(({attempt:y,retry:p})=>fe(r,t,{publicKey:o,onProgress:i,signal:c,integration:m}).catch(d=>{if(y<f)return p();throw d})),ar=(r,{publicKey:t,fileName:o,fileSize:i,baseURL:c,secureSignature:m,secureExpire:f,store:y,signal:p,onProgress:d,source:g,integration:w,userAgent:R,retryThrottledRequestMaxTimes:C,contentType:F,multipartChunkSize:I=M.multipartChunkSize,maxConcurrentRequests:j=M.maxConcurrentRequests,multipartMaxAttempts:a=M.multipartMaxAttempts,baseCDN:S,metadata:P})=>{const q=i||me(r);let L;const T=(D,Y)=>{if(!d)return;L||(L=Array(D).fill(0));const K=X=>X.reduce((z,gt)=>z+gt,0);return X=>{!X.isComputable||(L[Y]=X.value,d({isComputable:!0,value:K(L)/D}))}};return le(q,{publicKey:t,contentType:F,fileName:o!=null?o:r.name,baseURL:c,secureSignature:m,secureExpire:f,store:y,signal:p,source:g,integration:w,userAgent:R,retryThrottledRequestMaxTimes:C,metadata:P}).then(({uuid:D,parts:Y})=>{const K=sr(r,q,I);return Promise.all([D,or(j,Y.map((X,z)=>()=>ir(K(z),X,{publicKey:t,onProgress:T(Y.length,z),signal:p,integration:w,multipartMaxAttempts:a})))])}).then(([D])=>pe(D,{publicKey:t,baseURL:c,source:g,integration:w,userAgent:R,retryThrottledRequestMaxTimes:C})).then(D=>D.isReady?D:Zt({file:D.uuid,publicKey:t,baseURL:c,source:g,integration:w,userAgent:R,retryThrottledRequestMaxTimes:C,onProgress:d,signal:p})).then(D=>new jt(D,{baseCDN:S}))};function ye(r,{publicKey:t,fileName:o,baseURL:i=M.baseURL,secureSignature:c,secureExpire:m,store:f,signal:y,onProgress:p,source:d,integration:g,userAgent:w,retryThrottledRequestMaxTimes:R,contentType:C,multipartMinFileSize:F,multipartChunkSize:I,multipartMaxAttempts:j,maxConcurrentRequests:a,baseCDN:S=M.baseCDN,checkForUrlDuplicates:P,saveUrlForRecurrentUploads:q,pusherKey:L,metadata:T}){if(Ut(r)){const D=me(r);return rr(D,F)?ar(r,{publicKey:t,contentType:C,multipartChunkSize:I,multipartMaxAttempts:j,fileName:o,baseURL:i,secureSignature:c,secureExpire:m,store:f,signal:y,onProgress:p,source:d,integration:g,userAgent:w,maxConcurrentRequests:a,retryThrottledRequestMaxTimes:R,baseCDN:S,metadata:T}):qe(r,{publicKey:t,fileName:o,contentType:C,baseURL:i,secureSignature:c,secureExpire:m,store:f,signal:y,onProgress:p,source:d,integration:g,userAgent:w,retryThrottledRequestMaxTimes:R,baseCDN:S,metadata:T})}if(se(r))return tr(r,{publicKey:t,fileName:o,baseURL:i,baseCDN:S,checkForUrlDuplicates:P,saveUrlForRecurrentUploads:q,secureSignature:c,secureExpire:m,store:f,signal:y,onProgress:p,source:d,integration:g,userAgent:w,retryThrottledRequestMaxTimes:R,pusherKey:L,metadata:T});if(ne(r))return er(r,{publicKey:t,fileName:o,baseURL:i,signal:y,onProgress:p,source:d,integration:g,userAgent:w,retryThrottledRequestMaxTimes:R,baseCDN:S});throw new TypeError(`File uploading from "${r}" is not supported`)}class hr{constructor(t,o){this.storedAt=null,this.uuid=t.id,this.filesCount=t.filesCount,this.totalSize=Object.values(t.files).reduce((i,c)=>i+c.size,0),this.isStored=!!t.datetimeStored,this.isImage=!!Object.values(t.files).filter(i=>i.isImage).length,this.cdnUrl=t.cdnUrl,this.files=o,this.createdAt=t.datetimeCreated,this.storedAt=t.datetimeStored}}const ur=r=>{for(const t of r)if(!Ut(t))return!1;return!0},cr=r=>{for(const t of r)if(!ne(t))return!1;return!0},lr=r=>{for(const t of r)if(!se(t))return!1;return!0};function fr(r,{publicKey:t,fileName:o,baseURL:i=M.baseURL,secureSignature:c,secureExpire:m,store:f,signal:y,onProgress:p,source:d,integration:g,userAgent:w,retryThrottledRequestMaxTimes:R,contentType:C,multipartChunkSize:F=M.multipartChunkSize,baseCDN:I=M.baseCDN,jsonpCallback:j}){if(!ur(r)&&!lr(r)&&!cr(r))throw new TypeError(`Group uploading from "${r}" is not supported`);let a,S=!0;const P=r.length,q=(L,T)=>{if(!p)return;a||(a=Array(L).fill(0));const D=Y=>Y.reduce((K,X)=>K+X)/L;return Y=>{if(!Y.isComputable||!S){S=!1,p({isComputable:!1});return}a[T]=Y.value,p({isComputable:!0,value:D(a)})}};return Promise.all(r.map((L,T)=>ye(L,{publicKey:t,fileName:o,baseURL:i,secureSignature:c,secureExpire:m,store:f,signal:y,onProgress:q(P,T),source:d,integration:g,userAgent:w,retryThrottledRequestMaxTimes:R,contentType:C,multipartChunkSize:F,baseCDN:I}))).then(L=>{const T=L.map(D=>D.uuid);return ce(T,{publicKey:t,baseURL:i,jsonpCallback:j,secureSignature:c,secureExpire:m,signal:y,source:d,integration:g,userAgent:w,retryThrottledRequestMaxTimes:R}).then(D=>new hr(D,L)).then(D=>(p&&p({isComputable:!0,value:1}),D))})}const _t=(r,t)=>({...t,...r});class pr{constructor(t){this.settings=Object.assign({},M,t)}updateSettings(t){this.settings=Object.assign(this.settings,t)}getSettings(){return this.settings}base(t,o={}){const i=this.getSettings();return ae(t,_t(o,i))}info(t,o={}){const i=this.getSettings();return Qt(t,_t(o,i))}fromUrl(t,o={}){const i=this.getSettings();return he(t,_t(o,i))}fromUrlStatus(t,o={}){const i=this.getSettings();return ue(t,_t(o,i))}group(t,o={}){const i=this.getSettings();return ce(t,_t(o,i))}groupInfo(t,o={}){const i=this.getSettings();return Me(t,_t(o,i))}multipartStart(t,o={}){const i=this.getSettings();return le(t,_t(o,i))}multipartUpload(t,o,i={}){const c=this.getSettings();return fe(t,o,_t(i,c))}multipartComplete(t,o={}){const i=this.getSettings();return pe(t,_t(o,i))}uploadFile(t,o={}){const i=this.getSettings();return ye(t,_t(o,i))}uploadFileGroup(t,o={}){const i=this.getSettings();return fr(t,_t(o,i))}}function mr(){new pr({publicKey:"c84e346d54b17919469a"});const r=new ve({publicKey:"pk_2c599ac8-4678-4cb8-8242-f5e18a3823c0"});return{submitFormsparkForm:async(o,i,c,m,f)=>{console.log(o,i,c,m,f),o.target.setAttribute("disabled","disabled");const{solution:y}
1=await r.challenge(),p=new FormData(o.target);let d="",g={};g._botpoison=y;for(const[C,F]of p)g[C]=F;const w=`https://submit-form.com/${i}`;return await fetch(w,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify(g)}).then(C=>(console.log(C),C.status==404?d="error":d="success",C.status==200?(console.log(C.status),o.target.removeAttribute("disabled"),c.textContent="Submitted",m&&(m.textContent=C.statusText?C.statusText:f||"Success!",m.classList.add(d))):m&&(m.textContent=C.statusText?C.statusText:C.status+": Failed",m.classList.add(d)),C)).catch(()=>(alert("Something went wrong, please submit the form again"),o.target.removeAttribute("disabled"),!1))}}}export{mr as u};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.