@chillicream/nitro-embedded 32.0.0-insider.10 → 32.0.0-insider.13

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.
Files changed (28) hide show
  1. package/assets/{context-providers.b1acbb1e.wL2x-v5H.js → context-providers.3c65901d.BbDsagYj.js} +548 -547
  2. package/assets/{editor.worker.b1acbb1e.Bw-_xkYh.js → editor.worker.3c65901d.VyOkROub.js} +1 -1
  3. package/assets/{graphql-engine-scheduler.b1acbb1e.WARAOefW.js → graphql-engine-scheduler.3c65901d.CLpxHFDS.js} +54 -49
  4. package/assets/graphql-indexer-scheduler.3c65901d.BKGOllcA.js +350 -0
  5. package/assets/{graphql.worker.b1acbb1e.CRdQx-to.js → graphql.worker.3c65901d.3hSDTQ-Q.js} +68 -43
  6. package/assets/{index.b1acbb1e.tniRSGKe.js → index.3c65901d.Dbw3nb3I.js} +3 -3
  7. package/assets/{json.worker.b1acbb1e.CFX7bLI0.js → json.worker.3c65901d.BPuueYht.js} +1 -1
  8. package/assets/{jsonMode.b1acbb1e.BfB1ehZb.js → jsonMode.3c65901d.0PSvtCkH.js} +1 -1
  9. package/assets/{main.b1acbb1e.CkzasL7C.js → main.3c65901d.4PfoGKqs.js} +246 -241
  10. package/assets/{monaco.b1acbb1e.ChChfCHO.css → monaco.3c65901d.BjmtXf0G.css} +1 -1
  11. package/assets/{monaco.b1acbb1e.C9Koc2BW.js → monaco.3c65901d.CRsh97E0.js} +2 -2
  12. package/assets/{monaco.b1acbb1e.Be1FF1yz.css → monaco.3c65901d.CbCq4TOi.css} +1 -1
  13. package/assets/{session-scheduler.b1acbb1e.CSTbT1bk.js → session-scheduler.3c65901d.CsyRaG5z.js} +50 -45
  14. package/assets/{yaml.b1acbb1e.B9kfcSe1.js → yaml.3c65901d.DPAy9tvH.js} +1 -1
  15. package/assets/{yaml.worker.b1acbb1e.tHNr3N_3.js → yaml.worker.3c65901d.B0AJOH-B.js} +1 -1
  16. package/index.html +4 -4
  17. package/package.json +1 -1
  18. package/service-worker.js +1 -1
  19. package/assets/graphql-indexer-scheduler.b1acbb1e.D2ytie4P.js +0 -345
  20. /package/assets/{FiraCode-Medium.b1acbb1e.-YTCSZkP.woff2 → FiraCode-Medium.3c65901d.-YTCSZkP.woff2} +0 -0
  21. /package/assets/{codicon.b1acbb1e.Hscy-R9e.ttf → codicon.3c65901d.Hscy-R9e.ttf} +0 -0
  22. /package/assets/{context-providers.b1acbb1e.3HkX5s82.css → context-providers.3c65901d.3HkX5s82.css} +0 -0
  23. /package/assets/{main.b1acbb1e.BdMtxJz7.css → main.3c65901d.BdMtxJz7.css} +0 -0
  24. /package/assets/{monaco.b1acbb1e.Bg6EtW1-.js → monaco.3c65901d.CV02ik9y.js} +0 -0
  25. /package/assets/{monaco.b1acbb1e.HPGMvCp7.js → monaco.3c65901d.DB7C9Jv5.js} +0 -0
  26. /package/assets/{monaco.b1acbb1e.BAGyKpSQ.js → monaco.3c65901d.DlGi09Mw.js} +0 -0
  27. /package/assets/{monaco.b1acbb1e.CjWNeUFB.js → monaco.3c65901d.Dwj9Wrec.js} +0 -0
  28. /package/assets/{monaco.b1acbb1e.CwVbDieG.js → monaco.3c65901d.dLDhee6y.js} +0 -0
@@ -0,0 +1,350 @@
1
+ import{p as process$1,B as Buffer}from"./monaco.3c65901d.DB7C9Jv5.js";const APP_NAME="Nitro",APP_VERSION="32.0.0-insider.13",APP_GRAPHQL_CLIENT_ID="Q2xpZW50Cmc5ZjAwOTFmNTY5NmQ0NTZkOWUwZDQ0ZDMzYjJhZDJlOA==",cloudUriPattern=new RegExp("^https?:\\/\\/.*?\\.(bananacakepop\\.com|chillicream\\.com|chillicream\\.cloud)","i"),IS_RUNNING_IN_CLOUD=cloudUriPattern?.test(self.origin)??!1,IS_RUNNING_IN_ELECTRON=navigator.userAgent.indexOf("Electron")>=0,APP_TYPE=IS_RUNNING_IN_CLOUD?"cloud":IS_RUNNING_IN_ELECTRON?"app":"middleware",APP_AGENT=`${APP_NAME}/${APP_VERSION} (${APP_TYPE})`;getOsName();isMacLike();function getOsName(){return navigator.userAgent.indexOf("Win")>=0?"Windows":navigator.userAgent.indexOf("Mac")>=0?"macOS":navigator.userAgent.indexOf("X11")>=0||navigator.userAgent.indexOf("Linux")>=0?"Linux":"Unknown"}function isMacLike(){const r=navigator.userAgent.toLowerCase();return r.includes("mac os")||r.includes("ipad")}const HEADER_CONTENT_TYPE="Content-Type",HTTP_SCHEME_PATTERN=/^https?:\/\//i,INTROSPECTION_PREFIX=/^_{2}(?!_)/i,FIFTY_MILLISECONDS=50,ONE_SECOND=1e3,FIVE_SECONDS=5e3,ONE_MINUTE=6e4,ABORT_ERROR_NAME="AbortError",ABORT_ERROR=new DOMException("Action cancelled",ABORT_ERROR_NAME),TIMEOUT_ABORT_ERROR_MESSAGE="Action timed out",TIMEOUT_ABORT_ERROR=new DOMException(TIMEOUT_ABORT_ERROR_MESSAGE,ABORT_ERROR_NAME);class TimeoutAbortSignal{#e;#t;#r;constructor(t,i){this.#e=t,this.#t=i}get aborted(){return this.#e.aborted}get cancelled(){return this.#t()}get onabort(){return this.#e.onabort}get reason(){return this.#e.reason}dispatchEvent(t){return this.#e.dispatchEvent(t)}throwIfAborted(){this.#e.throwIfAborted()}toAbortSignal(){return this.#e}toPromise(){if(this.#r)return this.#r;const t=this;let i=!1;return this.#r=new Promise((n,s)=>{if(t.aborted){i=!0,s(TIMEOUT_ABORT_ERROR);return}if(t.cancelled){i=!0,n();return}function a(){t.removeEventListener("abort",a),t.removeEventListener("cancelled",h),i||(i=!0,s(TIMEOUT_ABORT_ERROR))}function h(){t.removeEventListener("abort",a),t.removeEventListener("cancelled",h),i||(i=!0,n())}t.addEventListener("abort",a),t.addEventListener("cancelled",h)}),this.#r}addEventListener(t,i,n){this.#e.addEventListener(t,i,n)}removeEventListener(t,i,n){this.#e.removeEventListener(t,i,n)}}class TimeoutAbortController{_controller=new AbortController;_signal=new TimeoutAbortSignal(this._controller.signal,()=>this._cancelled);_cancelled=!1;_timeoutHandle;constructor(t){this._timeoutHandle=self.setTimeout(()=>{this.abort(TIMEOUT_ABORT_ERROR_MESSAGE)},t)}get signal(){return this._signal}abort(t){this._controller.abort(t)}cancel(){this._cancelled=!0,self.clearTimeout(this._timeoutHandle),this._signal.dispatchEvent(new Event("cancelled"))}}function isAbortError(r){return r instanceof DOMException&&r.name===ABORT_ERROR_NAME}function isTimeoutAbortError(r){return isAbortError(r)&&r.message===TIMEOUT_ABORT_ERROR_MESSAGE}function createAbortScope(r,t,i){return i?i.aborted?Promise.reject(ABORT_ERROR):(i.addEventListener("abort",r),t().finally(()=>{i.removeEventListener("abort",r)})):t()}var commonjsGlobal=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function getAugmentedNamespace(r){if(Object.prototype.hasOwnProperty.call(r,"__esModule"))return r;var t=r.default;if(typeof t=="function"){var i=function n(){var s=!1;try{s=this instanceof n}catch{}return s?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};i.prototype=t.prototype}else i={};return Object.defineProperty(i,"__esModule",{value:!0}),Object.keys(r).forEach(function(n){var s=Object.getOwnPropertyDescriptor(r,n);Object.defineProperty(i,n,s.get?s:{enumerable:!0,get:function(){return r[n]}})}),i}var inherits_browser={exports:{}},hasRequiredInherits_browser;function requireInherits_browser(){return hasRequiredInherits_browser||(hasRequiredInherits_browser=1,typeof Object.create=="function"?inherits_browser.exports=function(t,i){i&&(t.super_=i,t.prototype=Object.create(i.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}))}:inherits_browser.exports=function(t,i){if(i){t.super_=i;var n=function(){};n.prototype=i.prototype,t.prototype=new n,t.prototype.constructor=t}}),inherits_browser.exports}var safeBuffer$1={exports:{}},dist={},hasRequiredDist;function requireDist(){return hasRequiredDist||(hasRequiredDist=1,function(r){Object.defineProperties(r,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});var t={},i={};i.byteLength=l,i.toByteArray=D,i.fromByteArray=bi;for(var n=[],s=[],a=typeof Uint8Array<"u"?Uint8Array:Array,h="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",v=0,hi=h.length;v<hi;++v)n[v]=h[v],s[h.charCodeAt(v)]=v;s[45]=62,s[95]=63;function u(Ii){var qi=Ii.length;if(qi%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var Oi=Ii.indexOf("=");Oi===-1&&(Oi=qi);var ki=Oi===qi?0:4-Oi%4;return[Oi,ki]}function l(Ii){var qi=u(Ii),Oi=qi[0],ki=qi[1];return(Oi+ki)*3/4-ki}function vi(Ii,qi,Oi){return(qi+Oi)*3/4-Oi}function D(Ii){var qi,Oi=u(Ii),ki=Oi[0],Li=Oi[1],ji=new a(vi(Ii,ki,Li)),Hi=0,Ui=Li>0?ki-4:ki,Qi;for(Qi=0;Qi<Ui;Qi+=4)qi=s[Ii.charCodeAt(Qi)]<<18|s[Ii.charCodeAt(Qi+1)]<<12|s[Ii.charCodeAt(Qi+2)]<<6|s[Ii.charCodeAt(Qi+3)],ji[Hi++]=qi>>16&255,ji[Hi++]=qi>>8&255,ji[Hi++]=qi&255;return Li===2&&(qi=s[Ii.charCodeAt(Qi)]<<2|s[Ii.charCodeAt(Qi+1)]>>4,ji[Hi++]=qi&255),Li===1&&(qi=s[Ii.charCodeAt(Qi)]<<10|s[Ii.charCodeAt(Qi+1)]<<4|s[Ii.charCodeAt(Qi+2)]>>2,ji[Hi++]=qi>>8&255,ji[Hi++]=qi&255),ji}function mi(Ii){return n[Ii>>18&63]+n[Ii>>12&63]+n[Ii>>6&63]+n[Ii&63]}function gi(Ii,qi,Oi){for(var ki,Li=[],ji=qi;ji<Oi;ji+=3)ki=(Ii[ji]<<16&16711680)+(Ii[ji+1]<<8&65280)+(Ii[ji+2]&255),Li.push(mi(ki));return Li.join("")}function bi(Ii){for(var qi,Oi=Ii.length,ki=Oi%3,Li=[],ji=16383,Hi=0,Ui=Oi-ki;Hi<Ui;Hi+=ji)Li.push(gi(Ii,Hi,Hi+ji>Ui?Ui:Hi+ji));return ki===1?(qi=Ii[Oi-1],Li.push(n[qi>>2]+n[qi<<4&63]+"==")):ki===2&&(qi=(Ii[Oi-2]<<8)+Ii[Oi-1],Li.push(n[qi>>10]+n[qi>>4&63]+n[qi<<2&63]+"=")),Li.join("")}var Ri={};/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */Ri.read=function(Ii,qi,Oi,ki,Li){var ji,Hi,Ui=Li*8-ki-1,Qi=(1<<Ui)-1,$i=Qi>>1,wi=-7,xi=Oi?Li-1:0,yi=Oi?-1:1,Ei=Ii[qi+xi];for(xi+=yi,ji=Ei&(1<<-wi)-1,Ei>>=-wi,wi+=Ui;wi>0;ji=ji*256+Ii[qi+xi],xi+=yi,wi-=8);for(Hi=ji&(1<<-wi)-1,ji>>=-wi,wi+=ki;wi>0;Hi=Hi*256+Ii[qi+xi],xi+=yi,wi-=8);if(ji===0)ji=1-$i;else{if(ji===Qi)return Hi?NaN:(Ei?-1:1)*(1/0);Hi=Hi+Math.pow(2,ki),ji=ji-$i}return(Ei?-1:1)*Hi*Math.pow(2,ji-ki)},Ri.write=function(Ii,qi,Oi,ki,Li,ji){var Hi,Ui,Qi,$i=ji*8-Li-1,wi=(1<<$i)-1,xi=wi>>1,yi=Li===23?Math.pow(2,-24)-Math.pow(2,-77):0,Ei=ki?0:ji-1,Ci=ki?1:-1,Ni=qi<0||qi===0&&1/qi<0?1:0;for(qi=Math.abs(qi),isNaN(qi)||qi===1/0?(Ui=isNaN(qi)?1:0,Hi=wi):(Hi=Math.floor(Math.log(qi)/Math.LN2),qi*(Qi=Math.pow(2,-Hi))<1&&(Hi--,Qi*=2),Hi+xi>=1?qi+=yi/Qi:qi+=yi*Math.pow(2,1-xi),qi*Qi>=2&&(Hi++,Qi/=2),Hi+xi>=wi?(Ui=0,Hi=wi):Hi+xi>=1?(Ui=(qi*Qi-1)*Math.pow(2,Li),Hi=Hi+xi):(Ui=qi*Math.pow(2,xi-1)*Math.pow(2,Li),Hi=0));Li>=8;Ii[Oi+Ei]=Ui&255,Ei+=Ci,Ui/=256,Li-=8);for(Hi=Hi<<Li|Ui,$i+=Li;$i>0;Ii[Oi+Ei]=Hi&255,Ei+=Ci,Hi/=256,$i-=8);Ii[Oi+Ei-Ci]|=Ni*128};/*!
2
+ * The buffer module from node.js, for the browser.
3
+ *
4
+ * @author Feross Aboukhadijeh <https://feross.org>
5
+ * @license MIT
6
+ */(function(Ii){const qi=i,Oi=Ri,ki=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;Ii.Buffer=wi,Ii.SlowBuffer=Bi,Ii.INSPECT_MAX_BYTES=50;const Li=2147483647;Ii.kMaxLength=Li;const{Uint8Array:ji,ArrayBuffer:Hi,SharedArrayBuffer:Ui}=globalThis;wi.TYPED_ARRAY_SUPPORT=Qi(),!wi.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function Qi(){try{const Rn=new ji(1),Wi={foo:function(){return 42}};return Object.setPrototypeOf(Wi,ji.prototype),Object.setPrototypeOf(Rn,Wi),Rn.foo()===42}catch{return!1}}Object.defineProperty(wi.prototype,"parent",{enumerable:!0,get:function(){if(wi.isBuffer(this))return this.buffer}}),Object.defineProperty(wi.prototype,"offset",{enumerable:!0,get:function(){if(wi.isBuffer(this))return this.byteOffset}});function $i(Rn){if(Rn>Li)throw new RangeError('The value "'+Rn+'" is invalid for option "size"');const Wi=new ji(Rn);return Object.setPrototypeOf(Wi,wi.prototype),Wi}function wi(Rn,Wi,Yi){if(typeof Rn=="number"){if(typeof Wi=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return Ci(Rn)}return xi(Rn,Wi,Yi)}wi.poolSize=8192;function xi(Rn,Wi,Yi){if(typeof Rn=="string")return Ni(Rn,Wi);if(Hi.isView(Rn))return Mi(Rn);if(Rn==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof Rn);if(Ba(Rn,Hi)||Rn&&Ba(Rn.buffer,Hi)||typeof Ui<"u"&&(Ba(Rn,Ui)||Rn&&Ba(Rn.buffer,Ui)))return Si(Rn,Wi,Yi);if(typeof Rn=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');const Mn=Rn.valueOf&&Rn.valueOf();if(Mn!=null&&Mn!==Rn)return wi.from(Mn,Wi,Yi);const Yn=Ai(Rn);if(Yn)return Yn;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof Rn[Symbol.toPrimitive]=="function")return wi.from(Rn[Symbol.toPrimitive]("string"),Wi,Yi);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof Rn)}wi.from=function(Rn,Wi,Yi){return xi(Rn,Wi,Yi)},Object.setPrototypeOf(wi.prototype,ji.prototype),Object.setPrototypeOf(wi,ji);function yi(Rn){if(typeof Rn!="number")throw new TypeError('"size" argument must be of type number');if(Rn<0)throw new RangeError('The value "'+Rn+'" is invalid for option "size"')}function Ei(Rn,Wi,Yi){return yi(Rn),Rn<=0?$i(Rn):Wi!==void 0?typeof Yi=="string"?$i(Rn).fill(Wi,Yi):$i(Rn).fill(Wi):$i(Rn)}wi.alloc=function(Rn,Wi,Yi){return Ei(Rn,Wi,Yi)};function Ci(Rn){return yi(Rn),$i(Rn<0?0:_i(Rn)|0)}wi.allocUnsafe=function(Rn){return Ci(Rn)},wi.allocUnsafeSlow=function(Rn){return Ci(Rn)};function Ni(Rn,Wi){if((typeof Wi!="string"||Wi==="")&&(Wi="utf8"),!wi.isEncoding(Wi))throw new TypeError("Unknown encoding: "+Wi);const Yi=Pi(Rn,Wi)|0;let Mn=$i(Yi);const Yn=Mn.write(Rn,Wi);return Yn!==Yi&&(Mn=Mn.slice(0,Yn)),Mn}function Fi(Rn){const Wi=Rn.length<0?0:_i(Rn.length)|0,Yi=$i(Wi);for(let Mn=0;Mn<Wi;Mn+=1)Yi[Mn]=Rn[Mn]&255;return Yi}function Mi(Rn){if(Ba(Rn,ji)){const Wi=new ji(Rn);return Si(Wi.buffer,Wi.byteOffset,Wi.byteLength)}return Fi(Rn)}function Si(Rn,Wi,Yi){if(Wi<0||Rn.byteLength<Wi)throw new RangeError('"offset" is outside of buffer bounds');if(Rn.byteLength<Wi+(Yi||0))throw new RangeError('"length" is outside of buffer bounds');let Mn;return Wi===void 0&&Yi===void 0?Mn=new ji(Rn):Yi===void 0?Mn=new ji(Rn,Wi):Mn=new ji(Rn,Wi,Yi),Object.setPrototypeOf(Mn,wi.prototype),Mn}function Ai(Rn){if(wi.isBuffer(Rn)){const Wi=_i(Rn.length)|0,Yi=$i(Wi);return Yi.length===0||Rn.copy(Yi,0,0,Wi),Yi}if(Rn.length!==void 0)return typeof Rn.length!="number"||Aa(Rn.length)?$i(0):Fi(Rn);if(Rn.type==="Buffer"&&Array.isArray(Rn.data))return Fi(Rn.data)}function _i(Rn){if(Rn>=Li)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+Li.toString(16)+" bytes");return Rn|0}function Bi(Rn){return+Rn!=Rn&&(Rn=0),wi.alloc(+Rn)}wi.isBuffer=function(Wi){return Wi!=null&&Wi._isBuffer===!0&&Wi!==wi.prototype},wi.compare=function(Wi,Yi){if(Ba(Wi,ji)&&(Wi=wi.from(Wi,Wi.offset,Wi.byteLength)),Ba(Yi,ji)&&(Yi=wi.from(Yi,Yi.offset,Yi.byteLength)),!wi.isBuffer(Wi)||!wi.isBuffer(Yi))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(Wi===Yi)return 0;let Mn=Wi.length,Yn=Yi.length;for(let ra=0,na=Math.min(Mn,Yn);ra<na;++ra)if(Wi[ra]!==Yi[ra]){Mn=Wi[ra],Yn=Yi[ra];break}return Mn<Yn?-1:Yn<Mn?1:0},wi.isEncoding=function(Wi){switch(String(Wi).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},wi.concat=function(Wi,Yi){if(!Array.isArray(Wi))throw new TypeError('"list" argument must be an Array of Buffers');if(Wi.length===0)return wi.alloc(0);let Mn;if(Yi===void 0)for(Yi=0,Mn=0;Mn<Wi.length;++Mn)Yi+=Wi[Mn].length;const Yn=wi.allocUnsafe(Yi);let ra=0;for(Mn=0;Mn<Wi.length;++Mn){let na=Wi[Mn];if(Ba(na,ji))ra+na.length>Yn.length?(wi.isBuffer(na)||(na=wi.from(na)),na.copy(Yn,ra)):ji.prototype.set.call(Yn,na,ra);else if(wi.isBuffer(na))na.copy(Yn,ra);else throw new TypeError('"list" argument must be an Array of Buffers');ra+=na.length}return Yn};function Pi(Rn,Wi){if(wi.isBuffer(Rn))return Rn.length;if(Hi.isView(Rn)||Ba(Rn,Hi))return Rn.byteLength;if(typeof Rn!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof Rn);const Yi=Rn.length,Mn=arguments.length>2&&arguments[2]===!0;if(!Mn&&Yi===0)return 0;let Yn=!1;for(;;)switch(Wi){case"ascii":case"latin1":case"binary":return Yi;case"utf8":case"utf-8":return Sa(Rn).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Yi*2;case"hex":return Yi>>>1;case"base64":return Ta(Rn).length;default:if(Yn)return Mn?-1:Sa(Rn).length;Wi=(""+Wi).toLowerCase(),Yn=!0}}wi.byteLength=Pi;function zi(Rn,Wi,Yi){let Mn=!1;if((Wi===void 0||Wi<0)&&(Wi=0),Wi>this.length||((Yi===void 0||Yi>this.length)&&(Yi=this.length),Yi<=0)||(Yi>>>=0,Wi>>>=0,Yi<=Wi))return"";for(Rn||(Rn="utf8");;)switch(Rn){case"hex":return oa(this,Wi,Yi);case"utf8":case"utf-8":return Ln(this,Wi,Yi);case"ascii":return ia(this,Wi,Yi);case"latin1":case"binary":return Wn(this,Wi,Yi);case"base64":return jn(this,Wi,Yi);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ta(this,Wi,Yi);default:if(Mn)throw new TypeError("Unknown encoding: "+Rn);Rn=(Rn+"").toLowerCase(),Mn=!0}}wi.prototype._isBuffer=!0;function Gi(Rn,Wi,Yi){const Mn=Rn[Wi];Rn[Wi]=Rn[Yi],Rn[Yi]=Mn}wi.prototype.swap16=function(){const Wi=this.length;if(Wi%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let Yi=0;Yi<Wi;Yi+=2)Gi(this,Yi,Yi+1);return this},wi.prototype.swap32=function(){const Wi=this.length;if(Wi%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let Yi=0;Yi<Wi;Yi+=4)Gi(this,Yi,Yi+3),Gi(this,Yi+1,Yi+2);return this},wi.prototype.swap64=function(){const Wi=this.length;if(Wi%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let Yi=0;Yi<Wi;Yi+=8)Gi(this,Yi,Yi+7),Gi(this,Yi+1,Yi+6),Gi(this,Yi+2,Yi+5),Gi(this,Yi+3,Yi+4);return this},wi.prototype.toString=function(){const Wi=this.length;return Wi===0?"":arguments.length===0?Ln(this,0,Wi):zi.apply(this,arguments)},wi.prototype.toLocaleString=wi.prototype.toString,wi.prototype.equals=function(Wi){if(!wi.isBuffer(Wi))throw new TypeError("Argument must be a Buffer");return this===Wi?!0:wi.compare(this,Wi)===0},wi.prototype.inspect=function(){let Wi="";const Yi=Ii.INSPECT_MAX_BYTES;return Wi=this.toString("hex",0,Yi).replace(/(.{2})/g,"$1 ").trim(),this.length>Yi&&(Wi+=" ... "),"<Buffer "+Wi+">"},ki&&(wi.prototype[ki]=wi.prototype.inspect),wi.prototype.compare=function(Wi,Yi,Mn,Yn,ra){if(Ba(Wi,ji)&&(Wi=wi.from(Wi,Wi.offset,Wi.byteLength)),!wi.isBuffer(Wi))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof Wi);if(Yi===void 0&&(Yi=0),Mn===void 0&&(Mn=Wi?Wi.length:0),Yn===void 0&&(Yn=0),ra===void 0&&(ra=this.length),Yi<0||Mn>Wi.length||Yn<0||ra>this.length)throw new RangeError("out of range index");if(Yn>=ra&&Yi>=Mn)return 0;if(Yn>=ra)return-1;if(Yi>=Mn)return 1;if(Yi>>>=0,Mn>>>=0,Yn>>>=0,ra>>>=0,this===Wi)return 0;let na=ra-Yn,Ea=Mn-Yi;const ba=Math.min(na,Ea),fa=this.slice(Yn,ra),Ia=Wi.slice(Yi,Mn);for(let ma=0;ma<ba;++ma)if(fa[ma]!==Ia[ma]){na=fa[ma],Ea=Ia[ma];break}return na<Ea?-1:Ea<na?1:0};function Vi(Rn,Wi,Yi,Mn,Yn){if(Rn.length===0)return-1;if(typeof Yi=="string"?(Mn=Yi,Yi=0):Yi>2147483647?Yi=2147483647:Yi<-2147483648&&(Yi=-2147483648),Yi=+Yi,Aa(Yi)&&(Yi=Yn?0:Rn.length-1),Yi<0&&(Yi=Rn.length+Yi),Yi>=Rn.length){if(Yn)return-1;Yi=Rn.length-1}else if(Yi<0)if(Yn)Yi=0;else return-1;if(typeof Wi=="string"&&(Wi=wi.from(Wi,Mn)),wi.isBuffer(Wi))return Wi.length===0?-1:Ki(Rn,Wi,Yi,Mn,Yn);if(typeof Wi=="number")return Wi=Wi&255,typeof ji.prototype.indexOf=="function"?Yn?ji.prototype.indexOf.call(Rn,Wi,Yi):ji.prototype.lastIndexOf.call(Rn,Wi,Yi):Ki(Rn,[Wi],Yi,Mn,Yn);throw new TypeError("val must be string, number or Buffer")}function Ki(Rn,Wi,Yi,Mn,Yn){let ra=1,na=Rn.length,Ea=Wi.length;if(Mn!==void 0&&(Mn=String(Mn).toLowerCase(),Mn==="ucs2"||Mn==="ucs-2"||Mn==="utf16le"||Mn==="utf-16le")){if(Rn.length<2||Wi.length<2)return-1;ra=2,na/=2,Ea/=2,Yi/=2}function ba(Ia,ma){return ra===1?Ia[ma]:Ia.readUInt16BE(ma*ra)}let fa;if(Yn){let Ia=-1;for(fa=Yi;fa<na;fa++)if(ba(Rn,fa)===ba(Wi,Ia===-1?0:fa-Ia)){if(Ia===-1&&(Ia=fa),fa-Ia+1===Ea)return Ia*ra}else Ia!==-1&&(fa-=fa-Ia),Ia=-1}else for(Yi+Ea>na&&(Yi=na-Ea),fa=Yi;fa>=0;fa--){let Ia=!0;for(let ma=0;ma<Ea;ma++)if(ba(Rn,fa+ma)!==ba(Wi,ma)){Ia=!1;break}if(Ia)return fa}return-1}wi.prototype.includes=function(Wi,Yi,Mn){return this.indexOf(Wi,Yi,Mn)!==-1},wi.prototype.indexOf=function(Wi,Yi,Mn){return Vi(this,Wi,Yi,Mn,!0)},wi.prototype.lastIndexOf=function(Wi,Yi,Mn){return Vi(this,Wi,Yi,Mn,!1)};function Zi(Rn,Wi,Yi,Mn){Yi=Number(Yi)||0;const Yn=Rn.length-Yi;Mn?(Mn=Number(Mn),Mn>Yn&&(Mn=Yn)):Mn=Yn;const ra=Wi.length;Mn>ra/2&&(Mn=ra/2);let na;for(na=0;na<Mn;++na){const Ea=parseInt(Wi.substr(na*2,2),16);if(Aa(Ea))return na;Rn[Yi+na]=Ea}return na}function In(Rn,Wi,Yi,Mn){return va(Sa(Wi,Rn.length-Yi),Rn,Yi,Mn)}function Ji(Rn,Wi,Yi,Mn){return va(ga(Wi),Rn,Yi,Mn)}function Xi(Rn,Wi,Yi,Mn){return va(Ta(Wi),Rn,Yi,Mn)}function on(Rn,Wi,Yi,Mn){return va(Pa(Wi,Rn.length-Yi),Rn,Yi,Mn)}wi.prototype.write=function(Wi,Yi,Mn,Yn){if(Yi===void 0)Yn="utf8",Mn=this.length,Yi=0;else if(Mn===void 0&&typeof Yi=="string")Yn=Yi,Mn=this.length,Yi=0;else if(isFinite(Yi))Yi=Yi>>>0,isFinite(Mn)?(Mn=Mn>>>0,Yn===void 0&&(Yn="utf8")):(Yn=Mn,Mn=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");const ra=this.length-Yi;if((Mn===void 0||Mn>ra)&&(Mn=ra),Wi.length>0&&(Mn<0||Yi<0)||Yi>this.length)throw new RangeError("Attempt to write outside buffer bounds");Yn||(Yn="utf8");let na=!1;for(;;)switch(Yn){case"hex":return Zi(this,Wi,Yi,Mn);case"utf8":case"utf-8":return In(this,Wi,Yi,Mn);case"ascii":case"latin1":case"binary":return Ji(this,Wi,Yi,Mn);case"base64":return Xi(this,Wi,Yi,Mn);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return on(this,Wi,Yi,Mn);default:if(na)throw new TypeError("Unknown encoding: "+Yn);Yn=(""+Yn).toLowerCase(),na=!0}},wi.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function jn(Rn,Wi,Yi){return Wi===0&&Yi===Rn.length?qi.fromByteArray(Rn):qi.fromByteArray(Rn.slice(Wi,Yi))}function Ln(Rn,Wi,Yi){Yi=Math.min(Rn.length,Yi);const Mn=[];let Yn=Wi;for(;Yn<Yi;){const ra=Rn[Yn];let na=null,Ea=ra>239?4:ra>223?3:ra>191?2:1;if(Yn+Ea<=Yi){let ba,fa,Ia,ma;switch(Ea){case 1:ra<128&&(na=ra);break;case 2:ba=Rn[Yn+1],(ba&192)===128&&(ma=(ra&31)<<6|ba&63,ma>127&&(na=ma));break;case 3:ba=Rn[Yn+1],fa=Rn[Yn+2],(ba&192)===128&&(fa&192)===128&&(ma=(ra&15)<<12|(ba&63)<<6|fa&63,ma>2047&&(ma<55296||ma>57343)&&(na=ma));break;case 4:ba=Rn[Yn+1],fa=Rn[Yn+2],Ia=Rn[Yn+3],(ba&192)===128&&(fa&192)===128&&(Ia&192)===128&&(ma=(ra&15)<<18|(ba&63)<<12|(fa&63)<<6|Ia&63,ma>65535&&ma<1114112&&(na=ma))}}na===null?(na=65533,Ea=1):na>65535&&(na-=65536,Mn.push(na>>>10&1023|55296),na=56320|na&1023),Mn.push(na),Yn+=Ea}return ea(Mn)}const Hn=4096;function ea(Rn){const Wi=Rn.length;if(Wi<=Hn)return String.fromCharCode.apply(String,Rn);let Yi="",Mn=0;for(;Mn<Wi;)Yi+=String.fromCharCode.apply(String,Rn.slice(Mn,Mn+=Hn));return Yi}function ia(Rn,Wi,Yi){let Mn="";Yi=Math.min(Rn.length,Yi);for(let Yn=Wi;Yn<Yi;++Yn)Mn+=String.fromCharCode(Rn[Yn]&127);return Mn}function Wn(Rn,Wi,Yi){let Mn="";Yi=Math.min(Rn.length,Yi);for(let Yn=Wi;Yn<Yi;++Yn)Mn+=String.fromCharCode(Rn[Yn]);return Mn}function oa(Rn,Wi,Yi){const Mn=Rn.length;(!Wi||Wi<0)&&(Wi=0),(!Yi||Yi<0||Yi>Mn)&&(Yi=Mn);let Yn="";for(let ra=Wi;ra<Yi;++ra)Yn+=_a[Rn[ra]];return Yn}function ta(Rn,Wi,Yi){const Mn=Rn.slice(Wi,Yi);let Yn="";for(let ra=0;ra<Mn.length-1;ra+=2)Yn+=String.fromCharCode(Mn[ra]+Mn[ra+1]*256);return Yn}wi.prototype.slice=function(Wi,Yi){const Mn=this.length;Wi=~~Wi,Yi=Yi===void 0?Mn:~~Yi,Wi<0?(Wi+=Mn,Wi<0&&(Wi=0)):Wi>Mn&&(Wi=Mn),Yi<0?(Yi+=Mn,Yi<0&&(Yi=0)):Yi>Mn&&(Yi=Mn),Yi<Wi&&(Yi=Wi);const Yn=this.subarray(Wi,Yi);return Object.setPrototypeOf(Yn,wi.prototype),Yn};function aa(Rn,Wi,Yi){if(Rn%1!==0||Rn<0)throw new RangeError("offset is not uint");if(Rn+Wi>Yi)throw new RangeError("Trying to access beyond buffer length")}wi.prototype.readUintLE=wi.prototype.readUIntLE=function(Wi,Yi,Mn){Wi=Wi>>>0,Yi=Yi>>>0,Mn||aa(Wi,Yi,this.length);let Yn=this[Wi],ra=1,na=0;for(;++na<Yi&&(ra*=256);)Yn+=this[Wi+na]*ra;return Yn},wi.prototype.readUintBE=wi.prototype.readUIntBE=function(Wi,Yi,Mn){Wi=Wi>>>0,Yi=Yi>>>0,Mn||aa(Wi,Yi,this.length);let Yn=this[Wi+--Yi],ra=1;for(;Yi>0&&(ra*=256);)Yn+=this[Wi+--Yi]*ra;return Yn},wi.prototype.readUint8=wi.prototype.readUInt8=function(Wi,Yi){return Wi=Wi>>>0,Yi||aa(Wi,1,this.length),this[Wi]},wi.prototype.readUint16LE=wi.prototype.readUInt16LE=function(Wi,Yi){return Wi=Wi>>>0,Yi||aa(Wi,2,this.length),this[Wi]|this[Wi+1]<<8},wi.prototype.readUint16BE=wi.prototype.readUInt16BE=function(Wi,Yi){return Wi=Wi>>>0,Yi||aa(Wi,2,this.length),this[Wi]<<8|this[Wi+1]},wi.prototype.readUint32LE=wi.prototype.readUInt32LE=function(Wi,Yi){return Wi=Wi>>>0,Yi||aa(Wi,4,this.length),(this[Wi]|this[Wi+1]<<8|this[Wi+2]<<16)+this[Wi+3]*16777216},wi.prototype.readUint32BE=wi.prototype.readUInt32BE=function(Wi,Yi){return Wi=Wi>>>0,Yi||aa(Wi,4,this.length),this[Wi]*16777216+(this[Wi+1]<<16|this[Wi+2]<<8|this[Wi+3])},wi.prototype.readBigUInt64LE=ka(function(Wi){Wi=Wi>>>0,Ma(Wi,"offset");const Yi=this[Wi],Mn=this[Wi+7];(Yi===void 0||Mn===void 0)&&wa(Wi,this.length-8);const Yn=Yi+this[++Wi]*2**8+this[++Wi]*2**16+this[++Wi]*2**24,ra=this[++Wi]+this[++Wi]*2**8+this[++Wi]*2**16+Mn*2**24;return BigInt(Yn)+(BigInt(ra)<<BigInt(32))}),wi.prototype.readBigUInt64BE=ka(function(Wi){Wi=Wi>>>0,Ma(Wi,"offset");const Yi=this[Wi],Mn=this[Wi+7];(Yi===void 0||Mn===void 0)&&wa(Wi,this.length-8);const Yn=Yi*2**24+this[++Wi]*2**16+this[++Wi]*2**8+this[++Wi],ra=this[++Wi]*2**24+this[++Wi]*2**16+this[++Wi]*2**8+Mn;return(BigInt(Yn)<<BigInt(32))+BigInt(ra)}),wi.prototype.readIntLE=function(Wi,Yi,Mn){Wi=Wi>>>0,Yi=Yi>>>0,Mn||aa(Wi,Yi,this.length);let Yn=this[Wi],ra=1,na=0;for(;++na<Yi&&(ra*=256);)Yn+=this[Wi+na]*ra;return ra*=128,Yn>=ra&&(Yn-=Math.pow(2,8*Yi)),Yn},wi.prototype.readIntBE=function(Wi,Yi,Mn){Wi=Wi>>>0,Yi=Yi>>>0,Mn||aa(Wi,Yi,this.length);let Yn=Yi,ra=1,na=this[Wi+--Yn];for(;Yn>0&&(ra*=256);)na+=this[Wi+--Yn]*ra;return ra*=128,na>=ra&&(na-=Math.pow(2,8*Yi)),na},wi.prototype.readInt8=function(Wi,Yi){return Wi=Wi>>>0,Yi||aa(Wi,1,this.length),this[Wi]&128?(255-this[Wi]+1)*-1:this[Wi]},wi.prototype.readInt16LE=function(Wi,Yi){Wi=Wi>>>0,Yi||aa(Wi,2,this.length);const Mn=this[Wi]|this[Wi+1]<<8;return Mn&32768?Mn|4294901760:Mn},wi.prototype.readInt16BE=function(Wi,Yi){Wi=Wi>>>0,Yi||aa(Wi,2,this.length);const Mn=this[Wi+1]|this[Wi]<<8;return Mn&32768?Mn|4294901760:Mn},wi.prototype.readInt32LE=function(Wi,Yi){return Wi=Wi>>>0,Yi||aa(Wi,4,this.length),this[Wi]|this[Wi+1]<<8|this[Wi+2]<<16|this[Wi+3]<<24},wi.prototype.readInt32BE=function(Wi,Yi){return Wi=Wi>>>0,Yi||aa(Wi,4,this.length),this[Wi]<<24|this[Wi+1]<<16|this[Wi+2]<<8|this[Wi+3]},wi.prototype.readBigInt64LE=ka(function(Wi){Wi=Wi>>>0,Ma(Wi,"offset");const Yi=this[Wi],Mn=this[Wi+7];(Yi===void 0||Mn===void 0)&&wa(Wi,this.length-8);const Yn=this[Wi+4]+this[Wi+5]*2**8+this[Wi+6]*2**16+(Mn<<24);return(BigInt(Yn)<<BigInt(32))+BigInt(Yi+this[++Wi]*2**8+this[++Wi]*2**16+this[++Wi]*2**24)}),wi.prototype.readBigInt64BE=ka(function(Wi){Wi=Wi>>>0,Ma(Wi,"offset");const Yi=this[Wi],Mn=this[Wi+7];(Yi===void 0||Mn===void 0)&&wa(Wi,this.length-8);const Yn=(Yi<<24)+this[++Wi]*2**16+this[++Wi]*2**8+this[++Wi];return(BigInt(Yn)<<BigInt(32))+BigInt(this[++Wi]*2**24+this[++Wi]*2**16+this[++Wi]*2**8+Mn)}),wi.prototype.readFloatLE=function(Wi,Yi){return Wi=Wi>>>0,Yi||aa(Wi,4,this.length),Oi.read(this,Wi,!0,23,4)},wi.prototype.readFloatBE=function(Wi,Yi){return Wi=Wi>>>0,Yi||aa(Wi,4,this.length),Oi.read(this,Wi,!1,23,4)},wi.prototype.readDoubleLE=function(Wi,Yi){return Wi=Wi>>>0,Yi||aa(Wi,8,this.length),Oi.read(this,Wi,!0,52,8)},wi.prototype.readDoubleBE=function(Wi,Yi){return Wi=Wi>>>0,Yi||aa(Wi,8,this.length),Oi.read(this,Wi,!1,52,8)};function sa(Rn,Wi,Yi,Mn,Yn,ra){if(!wi.isBuffer(Rn))throw new TypeError('"buffer" argument must be a Buffer instance');if(Wi>Yn||Wi<ra)throw new RangeError('"value" argument is out of bounds');if(Yi+Mn>Rn.length)throw new RangeError("Index out of range")}wi.prototype.writeUintLE=wi.prototype.writeUIntLE=function(Wi,Yi,Mn,Yn){if(Wi=+Wi,Yi=Yi>>>0,Mn=Mn>>>0,!Yn){const Ea=Math.pow(2,8*Mn)-1;sa(this,Wi,Yi,Mn,Ea,0)}let ra=1,na=0;for(this[Yi]=Wi&255;++na<Mn&&(ra*=256);)this[Yi+na]=Wi/ra&255;return Yi+Mn},wi.prototype.writeUintBE=wi.prototype.writeUIntBE=function(Wi,Yi,Mn,Yn){if(Wi=+Wi,Yi=Yi>>>0,Mn=Mn>>>0,!Yn){const Ea=Math.pow(2,8*Mn)-1;sa(this,Wi,Yi,Mn,Ea,0)}let ra=Mn-1,na=1;for(this[Yi+ra]=Wi&255;--ra>=0&&(na*=256);)this[Yi+ra]=Wi/na&255;return Yi+Mn},wi.prototype.writeUint8=wi.prototype.writeUInt8=function(Wi,Yi,Mn){return Wi=+Wi,Yi=Yi>>>0,Mn||sa(this,Wi,Yi,1,255,0),this[Yi]=Wi&255,Yi+1},wi.prototype.writeUint16LE=wi.prototype.writeUInt16LE=function(Wi,Yi,Mn){return Wi=+Wi,Yi=Yi>>>0,Mn||sa(this,Wi,Yi,2,65535,0),this[Yi]=Wi&255,this[Yi+1]=Wi>>>8,Yi+2},wi.prototype.writeUint16BE=wi.prototype.writeUInt16BE=function(Wi,Yi,Mn){return Wi=+Wi,Yi=Yi>>>0,Mn||sa(this,Wi,Yi,2,65535,0),this[Yi]=Wi>>>8,this[Yi+1]=Wi&255,Yi+2},wi.prototype.writeUint32LE=wi.prototype.writeUInt32LE=function(Wi,Yi,Mn){return Wi=+Wi,Yi=Yi>>>0,Mn||sa(this,Wi,Yi,4,4294967295,0),this[Yi+3]=Wi>>>24,this[Yi+2]=Wi>>>16,this[Yi+1]=Wi>>>8,this[Yi]=Wi&255,Yi+4},wi.prototype.writeUint32BE=wi.prototype.writeUInt32BE=function(Wi,Yi,Mn){return Wi=+Wi,Yi=Yi>>>0,Mn||sa(this,Wi,Yi,4,4294967295,0),this[Yi]=Wi>>>24,this[Yi+1]=Wi>>>16,this[Yi+2]=Wi>>>8,this[Yi+3]=Wi&255,Yi+4};function ua(Rn,Wi,Yi,Mn,Yn){pa(Wi,Mn,Yn,Rn,Yi,7);let ra=Number(Wi&BigInt(4294967295));Rn[Yi++]=ra,ra=ra>>8,Rn[Yi++]=ra,ra=ra>>8,Rn[Yi++]=ra,ra=ra>>8,Rn[Yi++]=ra;let na=Number(Wi>>BigInt(32)&BigInt(4294967295));return Rn[Yi++]=na,na=na>>8,Rn[Yi++]=na,na=na>>8,Rn[Yi++]=na,na=na>>8,Rn[Yi++]=na,Yi}function da(Rn,Wi,Yi,Mn,Yn){pa(Wi,Mn,Yn,Rn,Yi,7);let ra=Number(Wi&BigInt(4294967295));Rn[Yi+7]=ra,ra=ra>>8,Rn[Yi+6]=ra,ra=ra>>8,Rn[Yi+5]=ra,ra=ra>>8,Rn[Yi+4]=ra;let na=Number(Wi>>BigInt(32)&BigInt(4294967295));return Rn[Yi+3]=na,na=na>>8,Rn[Yi+2]=na,na=na>>8,Rn[Yi+1]=na,na=na>>8,Rn[Yi]=na,Yi+8}wi.prototype.writeBigUInt64LE=ka(function(Wi,Yi=0){return ua(this,Wi,Yi,BigInt(0),BigInt("0xffffffffffffffff"))}),wi.prototype.writeBigUInt64BE=ka(function(Wi,Yi=0){return da(this,Wi,Yi,BigInt(0),BigInt("0xffffffffffffffff"))}),wi.prototype.writeIntLE=function(Wi,Yi,Mn,Yn){if(Wi=+Wi,Yi=Yi>>>0,!Yn){const ba=Math.pow(2,8*Mn-1);sa(this,Wi,Yi,Mn,ba-1,-ba)}let ra=0,na=1,Ea=0;for(this[Yi]=Wi&255;++ra<Mn&&(na*=256);)Wi<0&&Ea===0&&this[Yi+ra-1]!==0&&(Ea=1),this[Yi+ra]=(Wi/na>>0)-Ea&255;return Yi+Mn},wi.prototype.writeIntBE=function(Wi,Yi,Mn,Yn){if(Wi=+Wi,Yi=Yi>>>0,!Yn){const ba=Math.pow(2,8*Mn-1);sa(this,Wi,Yi,Mn,ba-1,-ba)}let ra=Mn-1,na=1,Ea=0;for(this[Yi+ra]=Wi&255;--ra>=0&&(na*=256);)Wi<0&&Ea===0&&this[Yi+ra+1]!==0&&(Ea=1),this[Yi+ra]=(Wi/na>>0)-Ea&255;return Yi+Mn},wi.prototype.writeInt8=function(Wi,Yi,Mn){return Wi=+Wi,Yi=Yi>>>0,Mn||sa(this,Wi,Yi,1,127,-128),Wi<0&&(Wi=255+Wi+1),this[Yi]=Wi&255,Yi+1},wi.prototype.writeInt16LE=function(Wi,Yi,Mn){return Wi=+Wi,Yi=Yi>>>0,Mn||sa(this,Wi,Yi,2,32767,-32768),this[Yi]=Wi&255,this[Yi+1]=Wi>>>8,Yi+2},wi.prototype.writeInt16BE=function(Wi,Yi,Mn){return Wi=+Wi,Yi=Yi>>>0,Mn||sa(this,Wi,Yi,2,32767,-32768),this[Yi]=Wi>>>8,this[Yi+1]=Wi&255,Yi+2},wi.prototype.writeInt32LE=function(Wi,Yi,Mn){return Wi=+Wi,Yi=Yi>>>0,Mn||sa(this,Wi,Yi,4,2147483647,-2147483648),this[Yi]=Wi&255,this[Yi+1]=Wi>>>8,this[Yi+2]=Wi>>>16,this[Yi+3]=Wi>>>24,Yi+4},wi.prototype.writeInt32BE=function(Wi,Yi,Mn){return Wi=+Wi,Yi=Yi>>>0,Mn||sa(this,Wi,Yi,4,2147483647,-2147483648),Wi<0&&(Wi=4294967295+Wi+1),this[Yi]=Wi>>>24,this[Yi+1]=Wi>>>16,this[Yi+2]=Wi>>>8,this[Yi+3]=Wi&255,Yi+4},wi.prototype.writeBigInt64LE=ka(function(Wi,Yi=0){return ua(this,Wi,Yi,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),wi.prototype.writeBigInt64BE=ka(function(Wi,Yi=0){return da(this,Wi,Yi,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function ca(Rn,Wi,Yi,Mn,Yn,ra){if(Yi+Mn>Rn.length)throw new RangeError("Index out of range");if(Yi<0)throw new RangeError("Index out of range")}function la(Rn,Wi,Yi,Mn,Yn){return Wi=+Wi,Yi=Yi>>>0,Yn||ca(Rn,Wi,Yi,4),Oi.write(Rn,Wi,Yi,Mn,23,4),Yi+4}wi.prototype.writeFloatLE=function(Wi,Yi,Mn){return la(this,Wi,Yi,!0,Mn)},wi.prototype.writeFloatBE=function(Wi,Yi,Mn){return la(this,Wi,Yi,!1,Mn)};function Fa(Rn,Wi,Yi,Mn,Yn){return Wi=+Wi,Yi=Yi>>>0,Yn||ca(Rn,Wi,Yi,8),Oi.write(Rn,Wi,Yi,Mn,52,8),Yi+8}wi.prototype.writeDoubleLE=function(Wi,Yi,Mn){return Fa(this,Wi,Yi,!0,Mn)},wi.prototype.writeDoubleBE=function(Wi,Yi,Mn){return Fa(this,Wi,Yi,!1,Mn)},wi.prototype.copy=function(Wi,Yi,Mn,Yn){if(!wi.isBuffer(Wi))throw new TypeError("argument should be a Buffer");if(Mn||(Mn=0),!Yn&&Yn!==0&&(Yn=this.length),Yi>=Wi.length&&(Yi=Wi.length),Yi||(Yi=0),Yn>0&&Yn<Mn&&(Yn=Mn),Yn===Mn||Wi.length===0||this.length===0)return 0;if(Yi<0)throw new RangeError("targetStart out of bounds");if(Mn<0||Mn>=this.length)throw new RangeError("Index out of range");if(Yn<0)throw new RangeError("sourceEnd out of bounds");Yn>this.length&&(Yn=this.length),Wi.length-Yi<Yn-Mn&&(Yn=Wi.length-Yi+Mn);const ra=Yn-Mn;return this===Wi&&typeof ji.prototype.copyWithin=="function"?this.copyWithin(Yi,Mn,Yn):ji.prototype.set.call(Wi,this.subarray(Mn,Yn),Yi),ra},wi.prototype.fill=function(Wi,Yi,Mn,Yn){if(typeof Wi=="string"){if(typeof Yi=="string"?(Yn=Yi,Yi=0,Mn=this.length):typeof Mn=="string"&&(Yn=Mn,Mn=this.length),Yn!==void 0&&typeof Yn!="string")throw new TypeError("encoding must be a string");if(typeof Yn=="string"&&!wi.isEncoding(Yn))throw new TypeError("Unknown encoding: "+Yn);if(Wi.length===1){const na=Wi.charCodeAt(0);(Yn==="utf8"&&na<128||Yn==="latin1")&&(Wi=na)}}else typeof Wi=="number"?Wi=Wi&255:typeof Wi=="boolean"&&(Wi=Number(Wi));if(Yi<0||this.length<Yi||this.length<Mn)throw new RangeError("Out of range index");if(Mn<=Yi)return this;Yi=Yi>>>0,Mn=Mn===void 0?this.length:Mn>>>0,Wi||(Wi=0);let ra;if(typeof Wi=="number")for(ra=Yi;ra<Mn;++ra)this[ra]=Wi;else{const na=wi.isBuffer(Wi)?Wi:wi.from(Wi,Yn),Ea=na.length;if(Ea===0)throw new TypeError('The value "'+Wi+'" is invalid for argument "value"');for(ra=0;ra<Mn-Yi;++ra)this[ra+Yi]=na[ra%Ea]}return this};const xa={};function ha(Rn,Wi,Yi){xa[Rn]=class extends Yi{constructor(){super(),Object.defineProperty(this,"message",{value:Wi.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${Rn}]`,this.stack,delete this.name}get code(){return Rn}set code(Yn){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:Yn,writable:!0})}toString(){return`${this.name} [${Rn}]: ${this.message}`}}}ha("ERR_BUFFER_OUT_OF_BOUNDS",function(Rn){return Rn?`${Rn} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError),ha("ERR_INVALID_ARG_TYPE",function(Rn,Wi){return`The "${Rn}" argument must be of type number. Received type ${typeof Wi}`},TypeError),ha("ERR_OUT_OF_RANGE",function(Rn,Wi,Yi){let Mn=`The value of "${Rn}" is out of range.`,Yn=Yi;return Number.isInteger(Yi)&&Math.abs(Yi)>2**32?Yn=Ca(String(Yi)):typeof Yi=="bigint"&&(Yn=String(Yi),(Yi>BigInt(2)**BigInt(32)||Yi<-(BigInt(2)**BigInt(32)))&&(Yn=Ca(Yn)),Yn+="n"),Mn+=` It must be ${Wi}. Received ${Yn}`,Mn},RangeError);function Ca(Rn){let Wi="",Yi=Rn.length;const Mn=Rn[0]==="-"?1:0;for(;Yi>=Mn+4;Yi-=3)Wi=`_${Rn.slice(Yi-3,Yi)}${Wi}`;return`${Rn.slice(0,Yi)}${Wi}`}function Ra(Rn,Wi,Yi){Ma(Wi,"offset"),(Rn[Wi]===void 0||Rn[Wi+Yi]===void 0)&&wa(Wi,Rn.length-(Yi+1))}function pa(Rn,Wi,Yi,Mn,Yn,ra){if(Rn>Yi||Rn<Wi){const na=typeof Wi=="bigint"?"n":"";let Ea;throw Wi===0||Wi===BigInt(0)?Ea=`>= 0${na} and < 2${na} ** ${(ra+1)*8}${na}`:Ea=`>= -(2${na} ** ${(ra+1)*8-1}${na}) and < 2 ** ${(ra+1)*8-1}${na}`,new xa.ERR_OUT_OF_RANGE("value",Ea,Rn)}Ra(Mn,Yn,ra)}function Ma(Rn,Wi){if(typeof Rn!="number")throw new xa.ERR_INVALID_ARG_TYPE(Wi,"number",Rn)}function wa(Rn,Wi,Yi){throw Math.floor(Rn)!==Rn?(Ma(Rn,Yi),new xa.ERR_OUT_OF_RANGE("offset","an integer",Rn)):Wi<0?new xa.ERR_BUFFER_OUT_OF_BOUNDS:new xa.ERR_OUT_OF_RANGE("offset",`>= 0 and <= ${Wi}`,Rn)}const ya=/[^+/0-9A-Za-z-_]/g;function La(Rn){if(Rn=Rn.split("=")[0],Rn=Rn.trim().replace(ya,""),Rn.length<2)return"";for(;Rn.length%4!==0;)Rn=Rn+"=";return Rn}function Sa(Rn,Wi){Wi=Wi||1/0;let Yi;const Mn=Rn.length;let Yn=null;const ra=[];for(let na=0;na<Mn;++na){if(Yi=Rn.charCodeAt(na),Yi>55295&&Yi<57344){if(!Yn){if(Yi>56319){(Wi-=3)>-1&&ra.push(239,191,189);continue}else if(na+1===Mn){(Wi-=3)>-1&&ra.push(239,191,189);continue}Yn=Yi;continue}if(Yi<56320){(Wi-=3)>-1&&ra.push(239,191,189),Yn=Yi;continue}Yi=(Yn-55296<<10|Yi-56320)+65536}else Yn&&(Wi-=3)>-1&&ra.push(239,191,189);if(Yn=null,Yi<128){if((Wi-=1)<0)break;ra.push(Yi)}else if(Yi<2048){if((Wi-=2)<0)break;ra.push(Yi>>6|192,Yi&63|128)}else if(Yi<65536){if((Wi-=3)<0)break;ra.push(Yi>>12|224,Yi>>6&63|128,Yi&63|128)}else if(Yi<1114112){if((Wi-=4)<0)break;ra.push(Yi>>18|240,Yi>>12&63|128,Yi>>6&63|128,Yi&63|128)}else throw new Error("Invalid code point")}return ra}function ga(Rn){const Wi=[];for(let Yi=0;Yi<Rn.length;++Yi)Wi.push(Rn.charCodeAt(Yi)&255);return Wi}function Pa(Rn,Wi){let Yi,Mn,Yn;const ra=[];for(let na=0;na<Rn.length&&!((Wi-=2)<0);++na)Yi=Rn.charCodeAt(na),Mn=Yi>>8,Yn=Yi%256,ra.push(Yn),ra.push(Mn);return ra}function Ta(Rn){return qi.toByteArray(La(Rn))}function va(Rn,Wi,Yi,Mn){let Yn;for(Yn=0;Yn<Mn&&!(Yn+Yi>=Wi.length||Yn>=Rn.length);++Yn)Wi[Yn+Yi]=Rn[Yn];return Yn}function Ba(Rn,Wi){return Rn instanceof Wi||Rn!=null&&Rn.constructor!=null&&Rn.constructor.name!=null&&Rn.constructor.name===Wi.name}function Aa(Rn){return Rn!==Rn}const _a=function(){const Rn="0123456789abcdef",Wi=new Array(256);for(let Yi=0;Yi<16;++Yi){const Mn=Yi*16;for(let Yn=0;Yn<16;++Yn)Wi[Mn+Yn]=Rn[Yi]+Rn[Yn]}return Wi}();function ka(Rn){return typeof BigInt>"u"?Na:Rn}function Na(){throw new Error("BigInt not supported")}})(t);const Ti=t.Buffer;r.Blob=t.Blob,r.BlobOptions=t.BlobOptions,r.Buffer=t.Buffer,r.File=t.File,r.FileOptions=t.FileOptions,r.INSPECT_MAX_BYTES=t.INSPECT_MAX_BYTES,r.SlowBuffer=t.SlowBuffer,r.TranscodeEncoding=t.TranscodeEncoding,r.atob=t.atob,r.btoa=t.btoa,r.constants=t.constants,r.default=Ti,r.isAscii=t.isAscii,r.isUtf8=t.isUtf8,r.kMaxLength=t.kMaxLength,r.kStringMaxLength=t.kStringMaxLength,r.resolveObjectURL=t.resolveObjectURL,r.transcode=t.transcode}(dist)),dist}/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */var hasRequiredSafeBuffer$1;function requireSafeBuffer$1(){return hasRequiredSafeBuffer$1||(hasRequiredSafeBuffer$1=1,function(r,t){var i=requireDist(),n=i.Buffer;function s(h,v){for(var hi in h)v[hi]=h[hi]}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?r.exports=i:(s(i,t),t.Buffer=a);function a(h,v,hi){return n(h,v,hi)}a.prototype=Object.create(n.prototype),s(n,a),a.from=function(h,v,hi){if(typeof h=="number")throw new TypeError("Argument must not be a number");return n(h,v,hi)},a.alloc=function(h,v,hi){if(typeof h!="number")throw new TypeError("Argument must be a number");var u=n(h);return v!==void 0?typeof hi=="string"?u.fill(v,hi):u.fill(v):u.fill(0),u},a.allocUnsafe=function(h){if(typeof h!="number")throw new TypeError("Argument must be a number");return n(h)},a.allocUnsafeSlow=function(h){if(typeof h!="number")throw new TypeError("Argument must be a number");return i.SlowBuffer(h)}}(safeBuffer$1,safeBuffer$1.exports)),safeBuffer$1.exports}var readableBrowser$1={exports:{}},events={exports:{}},hasRequiredEvents;function requireEvents(){if(hasRequiredEvents)return events.exports;hasRequiredEvents=1;var r=typeof Reflect=="object"?Reflect:null,t=r&&typeof r.apply=="function"?r.apply:function(ki,Li,ji){return Function.prototype.apply.call(ki,Li,ji)},i;r&&typeof r.ownKeys=="function"?i=r.ownKeys:Object.getOwnPropertySymbols?i=function(ki){return Object.getOwnPropertyNames(ki).concat(Object.getOwnPropertySymbols(ki))}:i=function(ki){return Object.getOwnPropertyNames(ki)};function n(Oi){console&&console.warn&&console.warn(Oi)}var s=Number.isNaN||function(ki){return ki!==ki};function a(){a.init.call(this)}events.exports=a,events.exports.once=Ti,a.EventEmitter=a,a.prototype._events=void 0,a.prototype._eventsCount=0,a.prototype._maxListeners=void 0;var h=10;function v(Oi){if(typeof Oi!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof Oi)}Object.defineProperty(a,"defaultMaxListeners",{enumerable:!0,get:function(){return h},set:function(Oi){if(typeof Oi!="number"||Oi<0||s(Oi))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+Oi+".");h=Oi}}),a.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},a.prototype.setMaxListeners=function(ki){if(typeof ki!="number"||ki<0||s(ki))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+ki+".");return this._maxListeners=ki,this};function hi(Oi){return Oi._maxListeners===void 0?a.defaultMaxListeners:Oi._maxListeners}a.prototype.getMaxListeners=function(){return hi(this)},a.prototype.emit=function(ki){for(var Li=[],ji=1;ji<arguments.length;ji++)Li.push(arguments[ji]);var Hi=ki==="error",Ui=this._events;if(Ui!==void 0)Hi=Hi&&Ui.error===void 0;else if(!Hi)return!1;if(Hi){var Qi;if(Li.length>0&&(Qi=Li[0]),Qi instanceof Error)throw Qi;var $i=new Error("Unhandled error."+(Qi?" ("+Qi.message+")":""));throw $i.context=Qi,$i}var wi=Ui[ki];if(wi===void 0)return!1;if(typeof wi=="function")t(wi,this,Li);else for(var xi=wi.length,yi=gi(wi,xi),ji=0;ji<xi;++ji)t(yi[ji],this,Li);return!0};function u(Oi,ki,Li,ji){var Hi,Ui,Qi;if(v(Li),Ui=Oi._events,Ui===void 0?(Ui=Oi._events=Object.create(null),Oi._eventsCount=0):(Ui.newListener!==void 0&&(Oi.emit("newListener",ki,Li.listener?Li.listener:Li),Ui=Oi._events),Qi=Ui[ki]),Qi===void 0)Qi=Ui[ki]=Li,++Oi._eventsCount;else if(typeof Qi=="function"?Qi=Ui[ki]=ji?[Li,Qi]:[Qi,Li]:ji?Qi.unshift(Li):Qi.push(Li),Hi=hi(Oi),Hi>0&&Qi.length>Hi&&!Qi.warned){Qi.warned=!0;var $i=new Error("Possible EventEmitter memory leak detected. "+Qi.length+" "+String(ki)+" listeners added. Use emitter.setMaxListeners() to increase limit");$i.name="MaxListenersExceededWarning",$i.emitter=Oi,$i.type=ki,$i.count=Qi.length,n($i)}return Oi}a.prototype.addListener=function(ki,Li){return u(this,ki,Li,!1)},a.prototype.on=a.prototype.addListener,a.prototype.prependListener=function(ki,Li){return u(this,ki,Li,!0)};function l(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function vi(Oi,ki,Li){var ji={fired:!1,wrapFn:void 0,target:Oi,type:ki,listener:Li},Hi=l.bind(ji);return Hi.listener=Li,ji.wrapFn=Hi,Hi}a.prototype.once=function(ki,Li){return v(Li),this.on(ki,vi(this,ki,Li)),this},a.prototype.prependOnceListener=function(ki,Li){return v(Li),this.prependListener(ki,vi(this,ki,Li)),this},a.prototype.removeListener=function(ki,Li){var ji,Hi,Ui,Qi,$i;if(v(Li),Hi=this._events,Hi===void 0)return this;if(ji=Hi[ki],ji===void 0)return this;if(ji===Li||ji.listener===Li)--this._eventsCount===0?this._events=Object.create(null):(delete Hi[ki],Hi.removeListener&&this.emit("removeListener",ki,ji.listener||Li));else if(typeof ji!="function"){for(Ui=-1,Qi=ji.length-1;Qi>=0;Qi--)if(ji[Qi]===Li||ji[Qi].listener===Li){$i=ji[Qi].listener,Ui=Qi;break}if(Ui<0)return this;Ui===0?ji.shift():bi(ji,Ui),ji.length===1&&(Hi[ki]=ji[0]),Hi.removeListener!==void 0&&this.emit("removeListener",ki,$i||Li)}return this},a.prototype.off=a.prototype.removeListener,a.prototype.removeAllListeners=function(ki){var Li,ji,Hi;if(ji=this._events,ji===void 0)return this;if(ji.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):ji[ki]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete ji[ki]),this;if(arguments.length===0){var Ui=Object.keys(ji),Qi;for(Hi=0;Hi<Ui.length;++Hi)Qi=Ui[Hi],Qi!=="removeListener"&&this.removeAllListeners(Qi);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(Li=ji[ki],typeof Li=="function")this.removeListener(ki,Li);else if(Li!==void 0)for(Hi=Li.length-1;Hi>=0;Hi--)this.removeListener(ki,Li[Hi]);return this};function D(Oi,ki,Li){var ji=Oi._events;if(ji===void 0)return[];var Hi=ji[ki];return Hi===void 0?[]:typeof Hi=="function"?Li?[Hi.listener||Hi]:[Hi]:Li?Ri(Hi):gi(Hi,Hi.length)}a.prototype.listeners=function(ki){return D(this,ki,!0)},a.prototype.rawListeners=function(ki){return D(this,ki,!1)},a.listenerCount=function(Oi,ki){return typeof Oi.listenerCount=="function"?Oi.listenerCount(ki):mi.call(Oi,ki)},a.prototype.listenerCount=mi;function mi(Oi){var ki=this._events;if(ki!==void 0){var Li=ki[Oi];if(typeof Li=="function")return 1;if(Li!==void 0)return Li.length}return 0}a.prototype.eventNames=function(){return this._eventsCount>0?i(this._events):[]};function gi(Oi,ki){for(var Li=new Array(ki),ji=0;ji<ki;++ji)Li[ji]=Oi[ji];return Li}function bi(Oi,ki){for(;ki+1<Oi.length;ki++)Oi[ki]=Oi[ki+1];Oi.pop()}function Ri(Oi){for(var ki=new Array(Oi.length),Li=0;Li<ki.length;++Li)ki[Li]=Oi[Li].listener||Oi[Li];return ki}function Ti(Oi,ki){return new Promise(function(Li,ji){function Hi(Qi){Oi.removeListener(ki,Ui),ji(Qi)}function Ui(){typeof Oi.removeListener=="function"&&Oi.removeListener("error",Hi),Li([].slice.call(arguments))}qi(Oi,ki,Ui,{once:!0}),ki!=="error"&&Ii(Oi,Hi,{once:!0})})}function Ii(Oi,ki,Li){typeof Oi.on=="function"&&qi(Oi,"error",ki,Li)}function qi(Oi,ki,Li,ji){if(typeof Oi.on=="function")ji.once?Oi.once(ki,Li):Oi.on(ki,Li);else if(typeof Oi.addEventListener=="function")Oi.addEventListener(ki,function Hi(Ui){ji.once&&Oi.removeEventListener(ki,Hi),Li(Ui)});else throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof Oi)}return events.exports}var streamBrowser$1,hasRequiredStreamBrowser$1;function requireStreamBrowser$1(){return hasRequiredStreamBrowser$1||(hasRequiredStreamBrowser$1=1,streamBrowser$1=requireEvents().EventEmitter),streamBrowser$1}var util$1={},types$1={},shams$3,hasRequiredShams$3;function requireShams$3(){return hasRequiredShams$3||(hasRequiredShams$3=1,shams$3=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var t={},i=Symbol("test"),n=Object(i);if(typeof i=="string"||Object.prototype.toString.call(i)!=="[object Symbol]"||Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var s=42;t[i]=s;for(i in t)return!1;if(typeof Object.keys=="function"&&Object.keys(t).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(t).length!==0)return!1;var a=Object.getOwnPropertySymbols(t);if(a.length!==1||a[0]!==i||!Object.prototype.propertyIsEnumerable.call(t,i))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var h=Object.getOwnPropertyDescriptor(t,i);if(h.value!==s||h.enumerable!==!0)return!1}return!0}),shams$3}var shams$2,hasRequiredShams$2;function requireShams$2(){if(hasRequiredShams$2)return shams$2;hasRequiredShams$2=1;var r=requireShams$3();return shams$2=function(){return r()&&!!Symbol.toStringTag},shams$2}var esObjectAtoms$1,hasRequiredEsObjectAtoms$1;function requireEsObjectAtoms$1(){return hasRequiredEsObjectAtoms$1||(hasRequiredEsObjectAtoms$1=1,esObjectAtoms$1=Object),esObjectAtoms$1}var esErrors,hasRequiredEsErrors;function requireEsErrors(){return hasRequiredEsErrors||(hasRequiredEsErrors=1,esErrors=Error),esErrors}var _eval,hasRequired_eval;function require_eval(){return hasRequired_eval||(hasRequired_eval=1,_eval=EvalError),_eval}var range,hasRequiredRange;function requireRange(){return hasRequiredRange||(hasRequiredRange=1,range=RangeError),range}var ref,hasRequiredRef;function requireRef(){return hasRequiredRef||(hasRequiredRef=1,ref=ReferenceError),ref}var syntax,hasRequiredSyntax;function requireSyntax(){return hasRequiredSyntax||(hasRequiredSyntax=1,syntax=SyntaxError),syntax}var type,hasRequiredType;function requireType(){return hasRequiredType||(hasRequiredType=1,type=TypeError),type}var uri,hasRequiredUri;function requireUri(){return hasRequiredUri||(hasRequiredUri=1,uri=URIError),uri}var abs,hasRequiredAbs;function requireAbs(){return hasRequiredAbs||(hasRequiredAbs=1,abs=Math.abs),abs}var floor,hasRequiredFloor;function requireFloor(){return hasRequiredFloor||(hasRequiredFloor=1,floor=Math.floor),floor}var max,hasRequiredMax;function requireMax(){return hasRequiredMax||(hasRequiredMax=1,max=Math.max),max}var min,hasRequiredMin;function requireMin(){return hasRequiredMin||(hasRequiredMin=1,min=Math.min),min}var pow,hasRequiredPow;function requirePow(){return hasRequiredPow||(hasRequiredPow=1,pow=Math.pow),pow}var round,hasRequiredRound;function requireRound(){return hasRequiredRound||(hasRequiredRound=1,round=Math.round),round}var _isNaN,hasRequired_isNaN;function require_isNaN(){return hasRequired_isNaN||(hasRequired_isNaN=1,_isNaN=Number.isNaN||function(t){return t!==t}),_isNaN}var sign$1,hasRequiredSign$1;function requireSign$1(){if(hasRequiredSign$1)return sign$1;hasRequiredSign$1=1;var r=require_isNaN();return sign$1=function(i){return r(i)||i===0?i:i<0?-1:1},sign$1}var gOPD,hasRequiredGOPD;function requireGOPD(){return hasRequiredGOPD||(hasRequiredGOPD=1,gOPD=Object.getOwnPropertyDescriptor),gOPD}var gopd$2,hasRequiredGopd$2;function requireGopd$2(){if(hasRequiredGopd$2)return gopd$2;hasRequiredGopd$2=1;var r=requireGOPD();if(r)try{r([],"length")}catch{r=null}return gopd$2=r,gopd$2}var esDefineProperty$1,hasRequiredEsDefineProperty$1;function requireEsDefineProperty$1(){if(hasRequiredEsDefineProperty$1)return esDefineProperty$1;hasRequiredEsDefineProperty$1=1;var r=Object.defineProperty||!1;if(r)try{r({},"a",{value:1})}catch{r=!1}return esDefineProperty$1=r,esDefineProperty$1}var shams$1,hasRequiredShams$1;function requireShams$1(){return hasRequiredShams$1||(hasRequiredShams$1=1,shams$1=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var t={},i=Symbol("test"),n=Object(i);if(typeof i=="string"||Object.prototype.toString.call(i)!=="[object Symbol]"||Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var s=42;t[i]=s;for(var a in t)return!1;if(typeof Object.keys=="function"&&Object.keys(t).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(t).length!==0)return!1;var h=Object.getOwnPropertySymbols(t);if(h.length!==1||h[0]!==i||!Object.prototype.propertyIsEnumerable.call(t,i))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var v=Object.getOwnPropertyDescriptor(t,i);if(v.value!==s||v.enumerable!==!0)return!1}return!0}),shams$1}var hasSymbols$1,hasRequiredHasSymbols$1;function requireHasSymbols$1(){if(hasRequiredHasSymbols$1)return hasSymbols$1;hasRequiredHasSymbols$1=1;var r=typeof Symbol<"u"&&Symbol,t=requireShams$1();return hasSymbols$1=function(){return typeof r!="function"||typeof Symbol!="function"||typeof r("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:t()},hasSymbols$1}var Reflect_getPrototypeOf,hasRequiredReflect_getPrototypeOf;function requireReflect_getPrototypeOf(){return hasRequiredReflect_getPrototypeOf||(hasRequiredReflect_getPrototypeOf=1,Reflect_getPrototypeOf=typeof Reflect<"u"&&Reflect.getPrototypeOf||null),Reflect_getPrototypeOf}var esObjectAtoms,hasRequiredEsObjectAtoms;function requireEsObjectAtoms(){return hasRequiredEsObjectAtoms||(hasRequiredEsObjectAtoms=1,esObjectAtoms=Object),esObjectAtoms}var Object_getPrototypeOf,hasRequiredObject_getPrototypeOf;function requireObject_getPrototypeOf(){if(hasRequiredObject_getPrototypeOf)return Object_getPrototypeOf;hasRequiredObject_getPrototypeOf=1;var r=requireEsObjectAtoms();return Object_getPrototypeOf=r.getPrototypeOf||null,Object_getPrototypeOf}var implementation,hasRequiredImplementation;function requireImplementation(){if(hasRequiredImplementation)return implementation;hasRequiredImplementation=1;var r="Function.prototype.bind called on incompatible ",t=Object.prototype.toString,i=Math.max,n="[object Function]",s=function(hi,u){for(var l=[],vi=0;vi<hi.length;vi+=1)l[vi]=hi[vi];for(var D=0;D<u.length;D+=1)l[D+hi.length]=u[D];return l},a=function(hi,u){for(var l=[],vi=u,D=0;vi<hi.length;vi+=1,D+=1)l[D]=hi[vi];return l},h=function(v,hi){for(var u="",l=0;l<v.length;l+=1)u+=v[l],l+1<v.length&&(u+=hi);return u};return implementation=function(hi){var u=this;if(typeof u!="function"||t.apply(u)!==n)throw new TypeError(r+u);for(var l=a(arguments,1),vi,D=function(){if(this instanceof vi){var Ti=u.apply(this,s(l,arguments));return Object(Ti)===Ti?Ti:this}return u.apply(hi,s(l,arguments))},mi=i(0,u.length-l.length),gi=[],bi=0;bi<mi;bi++)gi[bi]="$"+bi;if(vi=Function("binder","return function ("+h(gi,",")+"){ return binder.apply(this,arguments); }")(D),u.prototype){var Ri=function(){};Ri.prototype=u.prototype,vi.prototype=new Ri,Ri.prototype=null}return vi},implementation}var functionBind,hasRequiredFunctionBind;function requireFunctionBind(){if(hasRequiredFunctionBind)return functionBind;hasRequiredFunctionBind=1;var r=requireImplementation();return functionBind=Function.prototype.bind||r,functionBind}var functionCall,hasRequiredFunctionCall;function requireFunctionCall(){return hasRequiredFunctionCall||(hasRequiredFunctionCall=1,functionCall=Function.prototype.call),functionCall}var functionApply,hasRequiredFunctionApply;function requireFunctionApply(){return hasRequiredFunctionApply||(hasRequiredFunctionApply=1,functionApply=Function.prototype.apply),functionApply}var reflectApply,hasRequiredReflectApply;function requireReflectApply(){return hasRequiredReflectApply||(hasRequiredReflectApply=1,reflectApply=typeof Reflect<"u"&&Reflect&&Reflect.apply),reflectApply}var actualApply,hasRequiredActualApply;function requireActualApply(){if(hasRequiredActualApply)return actualApply;hasRequiredActualApply=1;var r=requireFunctionBind(),t=requireFunctionApply(),i=requireFunctionCall(),n=requireReflectApply();return actualApply=n||r.call(i,t),actualApply}var callBindApplyHelpers,hasRequiredCallBindApplyHelpers;function requireCallBindApplyHelpers(){if(hasRequiredCallBindApplyHelpers)return callBindApplyHelpers;hasRequiredCallBindApplyHelpers=1;var r=requireFunctionBind(),t=requireType(),i=requireFunctionCall(),n=requireActualApply();return callBindApplyHelpers=function(a){if(a.length<1||typeof a[0]!="function")throw new t("a function is required");return n(r,i,a)},callBindApplyHelpers}var get,hasRequiredGet;function requireGet(){if(hasRequiredGet)return get;hasRequiredGet=1;var r=requireCallBindApplyHelpers(),t=requireGopd$2(),i;try{i=[].__proto__===Array.prototype}catch(h){if(!h||typeof h!="object"||!("code"in h)||h.code!=="ERR_PROTO_ACCESS")throw h}var n=!!i&&t&&t(Object.prototype,"__proto__"),s=Object,a=s.getPrototypeOf;return get=n&&typeof n.get=="function"?r([n.get]):typeof a=="function"?function(v){return a(v==null?v:s(v))}:!1,get}var getProto,hasRequiredGetProto;function requireGetProto(){if(hasRequiredGetProto)return getProto;hasRequiredGetProto=1;var r=requireReflect_getPrototypeOf(),t=requireObject_getPrototypeOf(),i=requireGet();return getProto=r?function(s){return r(s)}:t?function(s){if(!s||typeof s!="object"&&typeof s!="function")throw new TypeError("getProto: not an object");return t(s)}:i?function(s){return i(s)}:null,getProto}var hasown,hasRequiredHasown;function requireHasown(){if(hasRequiredHasown)return hasown;hasRequiredHasown=1;var r=Function.prototype.call,t=Object.prototype.hasOwnProperty,i=requireFunctionBind();return hasown=i.call(r,t),hasown}var getIntrinsic$1,hasRequiredGetIntrinsic$1;function requireGetIntrinsic$1(){if(hasRequiredGetIntrinsic$1)return getIntrinsic$1;hasRequiredGetIntrinsic$1=1;var r,t=requireEsObjectAtoms$1(),i=requireEsErrors(),n=require_eval(),s=requireRange(),a=requireRef(),h=requireSyntax(),v=requireType(),hi=requireUri(),u=requireAbs(),l=requireFloor(),vi=requireMax(),D=requireMin(),mi=requirePow(),gi=requireRound(),bi=requireSign$1(),Ri=Function,Ti=function(Zi){try{return Ri('"use strict"; return ('+Zi+").constructor;")()}catch{}},Ii=requireGopd$2(),qi=requireEsDefineProperty$1(),Oi=function(){throw new v},ki=Ii?function(){try{return arguments.callee,Oi}catch{try{return Ii(arguments,"callee").get}catch{return Oi}}}():Oi,Li=requireHasSymbols$1()(),ji=requireGetProto(),Hi=requireObject_getPrototypeOf(),Ui=requireReflect_getPrototypeOf(),Qi=requireFunctionApply(),$i=requireFunctionCall(),wi={},xi=typeof Uint8Array>"u"||!ji?r:ji(Uint8Array),yi={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?r:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?r:ArrayBuffer,"%ArrayIteratorPrototype%":Li&&ji?ji([][Symbol.iterator]()):r,"%AsyncFromSyncIteratorPrototype%":r,"%AsyncFunction%":wi,"%AsyncGenerator%":wi,"%AsyncGeneratorFunction%":wi,"%AsyncIteratorPrototype%":wi,"%Atomics%":typeof Atomics>"u"?r:Atomics,"%BigInt%":typeof BigInt>"u"?r:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?r:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?r:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?r:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":i,"%eval%":eval,"%EvalError%":n,"%Float16Array%":typeof Float16Array>"u"?r:Float16Array,"%Float32Array%":typeof Float32Array>"u"?r:Float32Array,"%Float64Array%":typeof Float64Array>"u"?r:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?r:FinalizationRegistry,"%Function%":Ri,"%GeneratorFunction%":wi,"%Int8Array%":typeof Int8Array>"u"?r:Int8Array,"%Int16Array%":typeof Int16Array>"u"?r:Int16Array,"%Int32Array%":typeof Int32Array>"u"?r:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":Li&&ji?ji(ji([][Symbol.iterator]())):r,"%JSON%":typeof JSON=="object"?JSON:r,"%Map%":typeof Map>"u"?r:Map,"%MapIteratorPrototype%":typeof Map>"u"||!Li||!ji?r:ji(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":t,"%Object.getOwnPropertyDescriptor%":Ii,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?r:Promise,"%Proxy%":typeof Proxy>"u"?r:Proxy,"%RangeError%":s,"%ReferenceError%":a,"%Reflect%":typeof Reflect>"u"?r:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?r:Set,"%SetIteratorPrototype%":typeof Set>"u"||!Li||!ji?r:ji(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?r:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":Li&&ji?ji(""[Symbol.iterator]()):r,"%Symbol%":Li?Symbol:r,"%SyntaxError%":h,"%ThrowTypeError%":ki,"%TypedArray%":xi,"%TypeError%":v,"%Uint8Array%":typeof Uint8Array>"u"?r:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?r:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?r:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?r:Uint32Array,"%URIError%":hi,"%WeakMap%":typeof WeakMap>"u"?r:WeakMap,"%WeakRef%":typeof WeakRef>"u"?r:WeakRef,"%WeakSet%":typeof WeakSet>"u"?r:WeakSet,"%Function.prototype.call%":$i,"%Function.prototype.apply%":Qi,"%Object.defineProperty%":qi,"%Object.getPrototypeOf%":Hi,"%Math.abs%":u,"%Math.floor%":l,"%Math.max%":vi,"%Math.min%":D,"%Math.pow%":mi,"%Math.round%":gi,"%Math.sign%":bi,"%Reflect.getPrototypeOf%":Ui};if(ji)try{null.error}catch(Zi){var Ei=ji(ji(Zi));yi["%Error.prototype%"]=Ei}var Ci=function Zi(In){var Ji;if(In==="%AsyncFunction%")Ji=Ti("async function () {}");else if(In==="%GeneratorFunction%")Ji=Ti("function* () {}");else if(In==="%AsyncGeneratorFunction%")Ji=Ti("async function* () {}");else if(In==="%AsyncGenerator%"){var Xi=Zi("%AsyncGeneratorFunction%");Xi&&(Ji=Xi.prototype)}else if(In==="%AsyncIteratorPrototype%"){var on=Zi("%AsyncGenerator%");on&&ji&&(Ji=ji(on.prototype))}return yi[In]=Ji,Ji},Ni={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},Fi=requireFunctionBind(),Mi=requireHasown(),Si=Fi.call($i,Array.prototype.concat),Ai=Fi.call(Qi,Array.prototype.splice),_i=Fi.call($i,String.prototype.replace),Bi=Fi.call($i,String.prototype.slice),Pi=Fi.call($i,RegExp.prototype.exec),zi=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,Gi=/\\(\\)?/g,Vi=function(In){var Ji=Bi(In,0,1),Xi=Bi(In,-1);if(Ji==="%"&&Xi!=="%")throw new h("invalid intrinsic syntax, expected closing `%`");if(Xi==="%"&&Ji!=="%")throw new h("invalid intrinsic syntax, expected opening `%`");var on=[];return _i(In,zi,function(jn,Ln,Hn,ea){on[on.length]=Hn?_i(ea,Gi,"$1"):Ln||jn}),on},Ki=function(In,Ji){var Xi=In,on;if(Mi(Ni,Xi)&&(on=Ni[Xi],Xi="%"+on[0]+"%"),Mi(yi,Xi)){var jn=yi[Xi];if(jn===wi&&(jn=Ci(Xi)),typeof jn>"u"&&!Ji)throw new v("intrinsic "+In+" exists, but is not available. Please file an issue!");return{alias:on,name:Xi,value:jn}}throw new h("intrinsic "+In+" does not exist!")};return getIntrinsic$1=function(In,Ji){if(typeof In!="string"||In.length===0)throw new v("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof Ji!="boolean")throw new v('"allowMissing" argument must be a boolean');if(Pi(/^%?[^%]*%?$/,In)===null)throw new h("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var Xi=Vi(In),on=Xi.length>0?Xi[0]:"",jn=Ki("%"+on+"%",Ji),Ln=jn.name,Hn=jn.value,ea=!1,ia=jn.alias;ia&&(on=ia[0],Ai(Xi,Si([0,1],ia)));for(var Wn=1,oa=!0;Wn<Xi.length;Wn+=1){var ta=Xi[Wn],aa=Bi(ta,0,1),sa=Bi(ta,-1);if((aa==='"'||aa==="'"||aa==="`"||sa==='"'||sa==="'"||sa==="`")&&aa!==sa)throw new h("property names with quotes must have matching quotes");if((ta==="constructor"||!oa)&&(ea=!0),on+="."+ta,Ln="%"+on+"%",Mi(yi,Ln))Hn=yi[Ln];else if(Hn!=null){if(!(ta in Hn)){if(!Ji)throw new v("base intrinsic for "+In+" exists, but the property is not available.");return}if(Ii&&Wn+1>=Xi.length){var ua=Ii(Hn,ta);oa=!!ua,oa&&"get"in ua&&!("originalValue"in ua.get)?Hn=ua.get:Hn=Hn[ta]}else oa=Mi(Hn,ta),Hn=Hn[ta];oa&&!ea&&(yi[Ln]=Hn)}}return Hn},getIntrinsic$1}var callBound,hasRequiredCallBound;function requireCallBound(){if(hasRequiredCallBound)return callBound;hasRequiredCallBound=1;var r=requireGetIntrinsic$1(),t=requireCallBindApplyHelpers(),i=t([r("%String.prototype.indexOf%")]);return callBound=function(s,a){var h=r(s,!!a);return typeof h=="function"&&i(s,".prototype.")>-1?t([h]):h},callBound}var isArguments,hasRequiredIsArguments;function requireIsArguments(){if(hasRequiredIsArguments)return isArguments;hasRequiredIsArguments=1;var r=requireShams$2()(),t=requireCallBound(),i=t("Object.prototype.toString"),n=function(v){return r&&v&&typeof v=="object"&&Symbol.toStringTag in v?!1:i(v)==="[object Arguments]"},s=function(v){return n(v)?!0:v!==null&&typeof v=="object"&&"length"in v&&typeof v.length=="number"&&v.length>=0&&i(v)!=="[object Array]"&&"callee"in v&&i(v.callee)==="[object Function]"},a=function(){return n(arguments)}();return n.isLegacyArguments=s,isArguments=a?n:s,isArguments}var isRegex,hasRequiredIsRegex;function requireIsRegex(){if(hasRequiredIsRegex)return isRegex;hasRequiredIsRegex=1;var r=requireCallBound(),t=requireShams$2()(),i=requireHasown(),n=requireGopd$2(),s;if(t){var a=r("RegExp.prototype.exec"),h={},v=function(){throw h},hi={toString:v,valueOf:v};typeof Symbol.toPrimitive=="symbol"&&(hi[Symbol.toPrimitive]=v),s=function(D){if(!D||typeof D!="object")return!1;var mi=n(D,"lastIndex"),gi=mi&&i(mi,"value");if(!gi)return!1;try{a(D,hi)}catch(bi){return bi===h}}}else{var u=r("Object.prototype.toString"),l="[object RegExp]";s=function(D){return!D||typeof D!="object"&&typeof D!="function"?!1:u(D)===l}}return isRegex=s,isRegex}var safeRegexTest,hasRequiredSafeRegexTest;function requireSafeRegexTest(){if(hasRequiredSafeRegexTest)return safeRegexTest;hasRequiredSafeRegexTest=1;var r=requireCallBound(),t=requireIsRegex(),i=r("RegExp.prototype.exec"),n=requireType();return safeRegexTest=function(a){if(!t(a))throw new n("`regex` must be a RegExp");return function(v){return i(a,v)!==null}},safeRegexTest}var isGeneratorFunction,hasRequiredIsGeneratorFunction;function requireIsGeneratorFunction(){if(hasRequiredIsGeneratorFunction)return isGeneratorFunction;hasRequiredIsGeneratorFunction=1;var r=requireCallBound(),t=requireSafeRegexTest(),i=t(/^\s*(?:function)?\*/),n=requireShams$2()(),s=requireGetProto(),a=r("Object.prototype.toString"),h=r("Function.prototype.toString"),v=function(){if(!n)return!1;try{return Function("return function*() {}")()}catch{}},hi;return isGeneratorFunction=function(l){if(typeof l!="function")return!1;if(i(h(l)))return!0;if(!n){var vi=a(l);return vi==="[object GeneratorFunction]"}if(!s)return!1;if(typeof hi>"u"){var D=v();hi=D?s(D):!1}return s(l)===hi},isGeneratorFunction}var isCallable,hasRequiredIsCallable;function requireIsCallable(){if(hasRequiredIsCallable)return isCallable;hasRequiredIsCallable=1;var r=Function.prototype.toString,t=typeof Reflect=="object"&&Reflect!==null&&Reflect.apply,i,n;if(typeof t=="function"&&typeof Object.defineProperty=="function")try{i=Object.defineProperty({},"length",{get:function(){throw n}}),n={},t(function(){throw 42},null,i)}catch(Ii){Ii!==n&&(t=null)}else t=null;var s=/^\s*class\b/,a=function(qi){try{var Oi=r.call(qi);return s.test(Oi)}catch{return!1}},h=function(qi){try{return a(qi)?!1:(r.call(qi),!0)}catch{return!1}},v=Object.prototype.toString,hi="[object Object]",u="[object Function]",l="[object GeneratorFunction]",vi="[object HTMLAllCollection]",D="[object HTML document.all class]",mi="[object HTMLCollection]",gi=typeof Symbol=="function"&&!!Symbol.toStringTag,bi=!(0 in[,]),Ri=function(){return!1};if(typeof document=="object"){var Ti=document.all;v.call(Ti)===v.call(document.all)&&(Ri=function(qi){if((bi||!qi)&&(typeof qi>"u"||typeof qi=="object"))try{var Oi=v.call(qi);return(Oi===vi||Oi===D||Oi===mi||Oi===hi)&&qi("")==null}catch{}return!1})}return isCallable=t?function(qi){if(Ri(qi))return!0;if(!qi||typeof qi!="function"&&typeof qi!="object")return!1;try{t(qi,null,i)}catch(Oi){if(Oi!==n)return!1}return!a(qi)&&h(qi)}:function(qi){if(Ri(qi))return!0;if(!qi||typeof qi!="function"&&typeof qi!="object")return!1;if(gi)return h(qi);if(a(qi))return!1;var Oi=v.call(qi);return Oi!==u&&Oi!==l&&!/^\[object HTML/.test(Oi)?!1:h(qi)},isCallable}var forEach,hasRequiredForEach;function requireForEach(){if(hasRequiredForEach)return forEach;hasRequiredForEach=1;var r=requireIsCallable(),t=Object.prototype.toString,i=Object.prototype.hasOwnProperty,n=function(hi,u,l){for(var vi=0,D=hi.length;vi<D;vi++)i.call(hi,vi)&&(l==null?u(hi[vi],vi,hi):u.call(l,hi[vi],vi,hi))},s=function(hi,u,l){for(var vi=0,D=hi.length;vi<D;vi++)l==null?u(hi.charAt(vi),vi,hi):u.call(l,hi.charAt(vi),vi,hi)},a=function(hi,u,l){for(var vi in hi)i.call(hi,vi)&&(l==null?u(hi[vi],vi,hi):u.call(l,hi[vi],vi,hi))};function h(v){return t.call(v)==="[object Array]"}return forEach=function(hi,u,l){if(!r(u))throw new TypeError("iterator must be a function");var vi;arguments.length>=3&&(vi=l),h(hi)?n(hi,u,vi):typeof hi=="string"?s(hi,u,vi):a(hi,u,vi)},forEach}var possibleTypedArrayNames,hasRequiredPossibleTypedArrayNames;function requirePossibleTypedArrayNames(){return hasRequiredPossibleTypedArrayNames||(hasRequiredPossibleTypedArrayNames=1,possibleTypedArrayNames=["Float32Array","Float64Array","Int8Array","Int16Array","Int32Array","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array"]),possibleTypedArrayNames}var availableTypedArrays,hasRequiredAvailableTypedArrays;function requireAvailableTypedArrays(){if(hasRequiredAvailableTypedArrays)return availableTypedArrays;hasRequiredAvailableTypedArrays=1;var r=requirePossibleTypedArrayNames(),t=typeof globalThis>"u"?commonjsGlobal:globalThis;return availableTypedArrays=function(){for(var n=[],s=0;s<r.length;s++)typeof t[r[s]]=="function"&&(n[n.length]=r[s]);return n},availableTypedArrays}var callBind={exports:{}},shams,hasRequiredShams;function requireShams(){return hasRequiredShams||(hasRequiredShams=1,shams=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var t={},i=Symbol("test"),n=Object(i);if(typeof i=="string"||Object.prototype.toString.call(i)!=="[object Symbol]"||Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var s=42;t[i]=s;for(i in t)return!1;if(typeof Object.keys=="function"&&Object.keys(t).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(t).length!==0)return!1;var a=Object.getOwnPropertySymbols(t);if(a.length!==1||a[0]!==i||!Object.prototype.propertyIsEnumerable.call(t,i))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var h=Object.getOwnPropertyDescriptor(t,i);if(h.value!==s||h.enumerable!==!0)return!1}return!0}),shams}var hasSymbols,hasRequiredHasSymbols;function requireHasSymbols(){if(hasRequiredHasSymbols)return hasSymbols;hasRequiredHasSymbols=1;var r=typeof Symbol<"u"&&Symbol,t=requireShams();return hasSymbols=function(){return typeof r!="function"||typeof Symbol!="function"||typeof r("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:t()},hasSymbols}var hasProto,hasRequiredHasProto;function requireHasProto(){if(hasRequiredHasProto)return hasProto;hasRequiredHasProto=1;var r={__proto__:null,foo:{}},t=Object;return hasProto=function(){return{__proto__:r}.foo===r.foo&&!(r instanceof t)},hasProto}var getIntrinsic,hasRequiredGetIntrinsic;function requireGetIntrinsic(){if(hasRequiredGetIntrinsic)return getIntrinsic;hasRequiredGetIntrinsic=1;var r,t=requireEsErrors(),i=require_eval(),n=requireRange(),s=requireRef(),a=requireSyntax(),h=requireType(),v=requireUri(),hi=Function,u=function(Ni){try{return hi('"use strict"; return ('+Ni+").constructor;")()}catch{}},l=Object.getOwnPropertyDescriptor;if(l)try{l({},"")}catch{l=null}var vi=function(){throw new h},D=l?function(){try{return arguments.callee,vi}catch{try{return l(arguments,"callee").get}catch{return vi}}}():vi,mi=requireHasSymbols()(),gi=requireHasProto()(),bi=Object.getPrototypeOf||(gi?function(Ni){return Ni.__proto__}:null),Ri={},Ti=typeof Uint8Array>"u"||!bi?r:bi(Uint8Array),Ii={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?r:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?r:ArrayBuffer,"%ArrayIteratorPrototype%":mi&&bi?bi([][Symbol.iterator]()):r,"%AsyncFromSyncIteratorPrototype%":r,"%AsyncFunction%":Ri,"%AsyncGenerator%":Ri,"%AsyncGeneratorFunction%":Ri,"%AsyncIteratorPrototype%":Ri,"%Atomics%":typeof Atomics>"u"?r:Atomics,"%BigInt%":typeof BigInt>"u"?r:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?r:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?r:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?r:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":t,"%eval%":eval,"%EvalError%":i,"%Float32Array%":typeof Float32Array>"u"?r:Float32Array,"%Float64Array%":typeof Float64Array>"u"?r:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?r:FinalizationRegistry,"%Function%":hi,"%GeneratorFunction%":Ri,"%Int8Array%":typeof Int8Array>"u"?r:Int8Array,"%Int16Array%":typeof Int16Array>"u"?r:Int16Array,"%Int32Array%":typeof Int32Array>"u"?r:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":mi&&bi?bi(bi([][Symbol.iterator]())):r,"%JSON%":typeof JSON=="object"?JSON:r,"%Map%":typeof Map>"u"?r:Map,"%MapIteratorPrototype%":typeof Map>"u"||!mi||!bi?r:bi(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?r:Promise,"%Proxy%":typeof Proxy>"u"?r:Proxy,"%RangeError%":n,"%ReferenceError%":s,"%Reflect%":typeof Reflect>"u"?r:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?r:Set,"%SetIteratorPrototype%":typeof Set>"u"||!mi||!bi?r:bi(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?r:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":mi&&bi?bi(""[Symbol.iterator]()):r,"%Symbol%":mi?Symbol:r,"%SyntaxError%":a,"%ThrowTypeError%":D,"%TypedArray%":Ti,"%TypeError%":h,"%Uint8Array%":typeof Uint8Array>"u"?r:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?r:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?r:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?r:Uint32Array,"%URIError%":v,"%WeakMap%":typeof WeakMap>"u"?r:WeakMap,"%WeakRef%":typeof WeakRef>"u"?r:WeakRef,"%WeakSet%":typeof WeakSet>"u"?r:WeakSet};if(bi)try{null.error}catch(Ni){var qi=bi(bi(Ni));Ii["%Error.prototype%"]=qi}var Oi=function Ni(Fi){var Mi;if(Fi==="%AsyncFunction%")Mi=u("async function () {}");else if(Fi==="%GeneratorFunction%")Mi=u("function* () {}");else if(Fi==="%AsyncGeneratorFunction%")Mi=u("async function* () {}");else if(Fi==="%AsyncGenerator%"){var Si=Ni("%AsyncGeneratorFunction%");Si&&(Mi=Si.prototype)}else if(Fi==="%AsyncIteratorPrototype%"){var Ai=Ni("%AsyncGenerator%");Ai&&bi&&(Mi=bi(Ai.prototype))}return Ii[Fi]=Mi,Mi},ki={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},Li=requireFunctionBind(),ji=requireHasown(),Hi=Li.call(Function.call,Array.prototype.concat),Ui=Li.call(Function.apply,Array.prototype.splice),Qi=Li.call(Function.call,String.prototype.replace),$i=Li.call(Function.call,String.prototype.slice),wi=Li.call(Function.call,RegExp.prototype.exec),xi=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,yi=/\\(\\)?/g,Ei=function(Fi){var Mi=$i(Fi,0,1),Si=$i(Fi,-1);if(Mi==="%"&&Si!=="%")throw new a("invalid intrinsic syntax, expected closing `%`");if(Si==="%"&&Mi!=="%")throw new a("invalid intrinsic syntax, expected opening `%`");var Ai=[];return Qi(Fi,xi,function(_i,Bi,Pi,zi){Ai[Ai.length]=Pi?Qi(zi,yi,"$1"):Bi||_i}),Ai},Ci=function(Fi,Mi){var Si=Fi,Ai;if(ji(ki,Si)&&(Ai=ki[Si],Si="%"+Ai[0]+"%"),ji(Ii,Si)){var _i=Ii[Si];if(_i===Ri&&(_i=Oi(Si)),typeof _i>"u"&&!Mi)throw new h("intrinsic "+Fi+" exists, but is not available. Please file an issue!");return{alias:Ai,name:Si,value:_i}}throw new a("intrinsic "+Fi+" does not exist!")};return getIntrinsic=function(Fi,Mi){if(typeof Fi!="string"||Fi.length===0)throw new h("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof Mi!="boolean")throw new h('"allowMissing" argument must be a boolean');if(wi(/^%?[^%]*%?$/,Fi)===null)throw new a("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var Si=Ei(Fi),Ai=Si.length>0?Si[0]:"",_i=Ci("%"+Ai+"%",Mi),Bi=_i.name,Pi=_i.value,zi=!1,Gi=_i.alias;Gi&&(Ai=Gi[0],Ui(Si,Hi([0,1],Gi)));for(var Vi=1,Ki=!0;Vi<Si.length;Vi+=1){var Zi=Si[Vi],In=$i(Zi,0,1),Ji=$i(Zi,-1);if((In==='"'||In==="'"||In==="`"||Ji==='"'||Ji==="'"||Ji==="`")&&In!==Ji)throw new a("property names with quotes must have matching quotes");if((Zi==="constructor"||!Ki)&&(zi=!0),Ai+="."+Zi,Bi="%"+Ai+"%",ji(Ii,Bi))Pi=Ii[Bi];else if(Pi!=null){if(!(Zi in Pi)){if(!Mi)throw new h("base intrinsic for "+Fi+" exists, but the property is not available.");return}if(l&&Vi+1>=Si.length){var Xi=l(Pi,Zi);Ki=!!Xi,Ki&&"get"in Xi&&!("originalValue"in Xi.get)?Pi=Xi.get:Pi=Pi[Zi]}else Ki=ji(Pi,Zi),Pi=Pi[Zi];Ki&&!zi&&(Ii[Bi]=Pi)}}return Pi},getIntrinsic}var esDefineProperty,hasRequiredEsDefineProperty;function requireEsDefineProperty(){if(hasRequiredEsDefineProperty)return esDefineProperty;hasRequiredEsDefineProperty=1;var r=requireGetIntrinsic(),t=r("%Object.defineProperty%",!0)||!1;if(t)try{t({},"a",{value:1})}catch{t=!1}return esDefineProperty=t,esDefineProperty}var gopd$1,hasRequiredGopd$1;function requireGopd$1(){if(hasRequiredGopd$1)return gopd$1;hasRequiredGopd$1=1;var r=requireGetIntrinsic(),t=r("%Object.getOwnPropertyDescriptor%",!0);if(t)try{t([],"length")}catch{t=null}return gopd$1=t,gopd$1}var defineDataProperty,hasRequiredDefineDataProperty;function requireDefineDataProperty(){if(hasRequiredDefineDataProperty)return defineDataProperty;hasRequiredDefineDataProperty=1;var r=requireEsDefineProperty(),t=requireSyntax(),i=requireType(),n=requireGopd$1();return defineDataProperty=function(a,h,v){if(!a||typeof a!="object"&&typeof a!="function")throw new i("`obj` must be an object or a function`");if(typeof h!="string"&&typeof h!="symbol")throw new i("`property` must be a string or a symbol`");if(arguments.length>3&&typeof arguments[3]!="boolean"&&arguments[3]!==null)throw new i("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!="boolean"&&arguments[4]!==null)throw new i("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!="boolean"&&arguments[5]!==null)throw new i("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!="boolean")throw new i("`loose`, if provided, must be a boolean");var hi=arguments.length>3?arguments[3]:null,u=arguments.length>4?arguments[4]:null,l=arguments.length>5?arguments[5]:null,vi=arguments.length>6?arguments[6]:!1,D=!!n&&n(a,h);if(r)r(a,h,{configurable:l===null&&D?D.configurable:!l,enumerable:hi===null&&D?D.enumerable:!hi,value:v,writable:u===null&&D?D.writable:!u});else if(vi||!hi&&!u&&!l)a[h]=v;else throw new t("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")},defineDataProperty}var hasPropertyDescriptors_1,hasRequiredHasPropertyDescriptors;function requireHasPropertyDescriptors(){if(hasRequiredHasPropertyDescriptors)return hasPropertyDescriptors_1;hasRequiredHasPropertyDescriptors=1;var r=requireEsDefineProperty(),t=function(){return!!r};return t.hasArrayLengthDefineBug=function(){if(!r)return null;try{return r([],"length",{value:1}).length!==1}catch{return!0}},hasPropertyDescriptors_1=t,hasPropertyDescriptors_1}var gopd,hasRequiredGopd;function requireGopd(){if(hasRequiredGopd)return gopd;hasRequiredGopd=1;var r=requireGetIntrinsic(),t=r("%Object.getOwnPropertyDescriptor%",!0);if(t)try{t([],"length")}catch{t=null}return gopd=t,gopd}var setFunctionLength,hasRequiredSetFunctionLength;function requireSetFunctionLength(){if(hasRequiredSetFunctionLength)return setFunctionLength;hasRequiredSetFunctionLength=1;var r=requireGetIntrinsic(),t=requireDefineDataProperty(),i=requireHasPropertyDescriptors()(),n=requireGopd(),s=requireType(),a=r("%Math.floor%");return setFunctionLength=function(v,hi){if(typeof v!="function")throw new s("`fn` is not a function");if(typeof hi!="number"||hi<0||hi>4294967295||a(hi)!==hi)throw new s("`length` must be a positive 32-bit integer");var u=arguments.length>2&&!!arguments[2],l=!0,vi=!0;if("length"in v&&n){var D=n(v,"length");D&&!D.configurable&&(l=!1),D&&!D.writable&&(vi=!1)}return(l||vi||!u)&&(i?t(v,"length",hi,!0,!0):t(v,"length",hi)),v},setFunctionLength}var applyBind,hasRequiredApplyBind;function requireApplyBind(){if(hasRequiredApplyBind)return applyBind;hasRequiredApplyBind=1;var r=requireFunctionBind(),t=requireFunctionApply(),i=requireActualApply();return applyBind=function(){return i(r,t,arguments)},applyBind}var hasRequiredCallBind;function requireCallBind(){return hasRequiredCallBind||(hasRequiredCallBind=1,function(r){var t=requireSetFunctionLength(),i=requireEsDefineProperty(),n=requireCallBindApplyHelpers(),s=requireApplyBind();r.exports=function(h){var v=n(arguments),hi=h.length-(arguments.length-1);return t(v,1+(hi>0?hi:0),!0)},i?i(r.exports,"apply",{value:s}):r.exports.apply=s}(callBind)),callBind.exports}var whichTypedArray,hasRequiredWhichTypedArray;function requireWhichTypedArray(){if(hasRequiredWhichTypedArray)return whichTypedArray;hasRequiredWhichTypedArray=1;var r=requireForEach(),t=requireAvailableTypedArrays(),i=requireCallBind(),n=requireCallBound(),s=requireGopd$2(),a=requireGetProto(),h=n("Object.prototype.toString"),v=requireShams$2()(),hi=typeof globalThis>"u"?commonjsGlobal:globalThis,u=t(),l=n("String.prototype.slice"),vi=n("Array.prototype.indexOf",!0)||function(Ri,Ti){for(var Ii=0;Ii<Ri.length;Ii+=1)if(Ri[Ii]===Ti)return Ii;return-1},D={__proto__:null};v&&s&&a?r(u,function(bi){var Ri=new hi[bi];if(Symbol.toStringTag in Ri&&a){var Ti=a(Ri),Ii=s(Ti,Symbol.toStringTag);if(!Ii&&Ti){var qi=a(Ti);Ii=s(qi,Symbol.toStringTag)}D["$"+bi]=i(Ii.get)}}):r(u,function(bi){var Ri=new hi[bi],Ti=Ri.slice||Ri.set;Ti&&(D["$"+bi]=i(Ti))});var mi=function(Ri){var Ti=!1;return r(D,function(Ii,qi){if(!Ti)try{"$"+Ii(Ri)===qi&&(Ti=l(qi,1))}catch{}}),Ti},gi=function(Ri){var Ti=!1;return r(D,function(Ii,qi){if(!Ti)try{Ii(Ri),Ti=l(qi,1)}catch{}}),Ti};return whichTypedArray=function(Ri){if(!Ri||typeof Ri!="object")return!1;if(!v){var Ti=l(h(Ri),8,-1);return vi(u,Ti)>-1?Ti:Ti!=="Object"?!1:gi(Ri)}return s?mi(Ri):null},whichTypedArray}var isTypedArray$1,hasRequiredIsTypedArray$1;function requireIsTypedArray$1(){if(hasRequiredIsTypedArray$1)return isTypedArray$1;hasRequiredIsTypedArray$1=1;var r=requireWhichTypedArray();return isTypedArray$1=function(i){return!!r(i)},isTypedArray$1}var hasRequiredTypes$1;function requireTypes$1(){return hasRequiredTypes$1||(hasRequiredTypes$1=1,function(r){var t=requireIsArguments(),i=requireIsGeneratorFunction(),n=requireWhichTypedArray(),s=requireIsTypedArray$1();function a(Wn){return Wn.call.bind(Wn)}var h=typeof BigInt<"u",v=typeof Symbol<"u",hi=a(Object.prototype.toString),u=a(Number.prototype.valueOf),l=a(String.prototype.valueOf),vi=a(Boolean.prototype.valueOf);if(h)var D=a(BigInt.prototype.valueOf);if(v)var mi=a(Symbol.prototype.valueOf);function gi(Wn,oa){if(typeof Wn!="object")return!1;try{return oa(Wn),!0}catch{return!1}}r.isArgumentsObject=t,r.isGeneratorFunction=i,r.isTypedArray=s;function bi(Wn){return typeof Promise<"u"&&Wn instanceof Promise||Wn!==null&&typeof Wn=="object"&&typeof Wn.then=="function"&&typeof Wn.catch=="function"}r.isPromise=bi;function Ri(Wn){return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?ArrayBuffer.isView(Wn):s(Wn)||Bi(Wn)}r.isArrayBufferView=Ri;function Ti(Wn){return n(Wn)==="Uint8Array"}r.isUint8Array=Ti;function Ii(Wn){return n(Wn)==="Uint8ClampedArray"}r.isUint8ClampedArray=Ii;function qi(Wn){return n(Wn)==="Uint16Array"}r.isUint16Array=qi;function Oi(Wn){return n(Wn)==="Uint32Array"}r.isUint32Array=Oi;function ki(Wn){return n(Wn)==="Int8Array"}r.isInt8Array=ki;function Li(Wn){return n(Wn)==="Int16Array"}r.isInt16Array=Li;function ji(Wn){return n(Wn)==="Int32Array"}r.isInt32Array=ji;function Hi(Wn){return n(Wn)==="Float32Array"}r.isFloat32Array=Hi;function Ui(Wn){return n(Wn)==="Float64Array"}r.isFloat64Array=Ui;function Qi(Wn){return n(Wn)==="BigInt64Array"}r.isBigInt64Array=Qi;function $i(Wn){return n(Wn)==="BigUint64Array"}r.isBigUint64Array=$i;function wi(Wn){return hi(Wn)==="[object Map]"}wi.working=typeof Map<"u"&&wi(new Map);function xi(Wn){return typeof Map>"u"?!1:wi.working?wi(Wn):Wn instanceof Map}r.isMap=xi;function yi(Wn){return hi(Wn)==="[object Set]"}yi.working=typeof Set<"u"&&yi(new Set);function Ei(Wn){return typeof Set>"u"?!1:yi.working?yi(Wn):Wn instanceof Set}r.isSet=Ei;function Ci(Wn){return hi(Wn)==="[object WeakMap]"}Ci.working=typeof WeakMap<"u"&&Ci(new WeakMap);function Ni(Wn){return typeof WeakMap>"u"?!1:Ci.working?Ci(Wn):Wn instanceof WeakMap}r.isWeakMap=Ni;function Fi(Wn){return hi(Wn)==="[object WeakSet]"}Fi.working=typeof WeakSet<"u"&&Fi(new WeakSet);function Mi(Wn){return Fi(Wn)}r.isWeakSet=Mi;function Si(Wn){return hi(Wn)==="[object ArrayBuffer]"}Si.working=typeof ArrayBuffer<"u"&&Si(new ArrayBuffer);function Ai(Wn){return typeof ArrayBuffer>"u"?!1:Si.working?Si(Wn):Wn instanceof ArrayBuffer}r.isArrayBuffer=Ai;function _i(Wn){return hi(Wn)==="[object DataView]"}_i.working=typeof ArrayBuffer<"u"&&typeof DataView<"u"&&_i(new DataView(new ArrayBuffer(1),0,1));function Bi(Wn){return typeof DataView>"u"?!1:_i.working?_i(Wn):Wn instanceof DataView}r.isDataView=Bi;var Pi=typeof SharedArrayBuffer<"u"?SharedArrayBuffer:void 0;function zi(Wn){return hi(Wn)==="[object SharedArrayBuffer]"}function Gi(Wn){return typeof Pi>"u"?!1:(typeof zi.working>"u"&&(zi.working=zi(new Pi)),zi.working?zi(Wn):Wn instanceof Pi)}r.isSharedArrayBuffer=Gi;function Vi(Wn){return hi(Wn)==="[object AsyncFunction]"}r.isAsyncFunction=Vi;function Ki(Wn){return hi(Wn)==="[object Map Iterator]"}r.isMapIterator=Ki;function Zi(Wn){return hi(Wn)==="[object Set Iterator]"}r.isSetIterator=Zi;function In(Wn){return hi(Wn)==="[object Generator]"}r.isGeneratorObject=In;function Ji(Wn){return hi(Wn)==="[object WebAssembly.Module]"}r.isWebAssemblyCompiledModule=Ji;function Xi(Wn){return gi(Wn,u)}r.isNumberObject=Xi;function on(Wn){return gi(Wn,l)}r.isStringObject=on;function jn(Wn){return gi(Wn,vi)}r.isBooleanObject=jn;function Ln(Wn){return h&&gi(Wn,D)}r.isBigIntObject=Ln;function Hn(Wn){return v&&gi(Wn,mi)}r.isSymbolObject=Hn;function ea(Wn){return Xi(Wn)||on(Wn)||jn(Wn)||Ln(Wn)||Hn(Wn)}r.isBoxedPrimitive=ea;function ia(Wn){return typeof Uint8Array<"u"&&(Ai(Wn)||Gi(Wn))}r.isAnyArrayBuffer=ia,["isProxy","isExternal","isModuleNamespaceObject"].forEach(function(Wn){Object.defineProperty(r,Wn,{enumerable:!1,value:function(){throw new Error(Wn+" is not supported in userland")}})})}(types$1)),types$1}var isBufferBrowser,hasRequiredIsBufferBrowser;function requireIsBufferBrowser(){return hasRequiredIsBufferBrowser||(hasRequiredIsBufferBrowser=1,isBufferBrowser=function(t){return t&&typeof t=="object"&&typeof t.copy=="function"&&typeof t.fill=="function"&&typeof t.readUInt8=="function"}),isBufferBrowser}var hasRequiredUtil$1;function requireUtil$1(){return hasRequiredUtil$1||(hasRequiredUtil$1=1,function(r){var t={},i=Object.getOwnPropertyDescriptors||function(Pi){for(var zi=Object.keys(Pi),Gi={},Vi=0;Vi<zi.length;Vi++)Gi[zi[Vi]]=Object.getOwnPropertyDescriptor(Pi,zi[Vi]);return Gi},n=/%[sdj%]/g;r.format=function(Bi){if(!Li(Bi)){for(var Pi=[],zi=0;zi<arguments.length;zi++)Pi.push(v(arguments[zi]));return Pi.join(" ")}for(var zi=1,Gi=arguments,Vi=Gi.length,Ki=String(Bi).replace(n,function(In){if(In==="%%")return"%";if(zi>=Vi)return In;switch(In){case"%s":return String(Gi[zi++]);case"%d":return Number(Gi[zi++]);case"%j":try{return JSON.stringify(Gi[zi++])}catch{return"[Circular]"}default:return In}}),Zi=Gi[zi];zi<Vi;Zi=Gi[++zi])qi(Zi)||!Qi(Zi)?Ki+=" "+Zi:Ki+=" "+v(Zi);return Ki},r.deprecate=function(Bi,Pi){if(typeof process$1<"u"&&process$1.noDeprecation===!0)return Bi;if(typeof process$1>"u")return function(){return r.deprecate(Bi,Pi).apply(this,arguments)};var zi=!1;function Gi(){if(!zi){if(process$1.throwDeprecation)throw new Error(Pi);process$1.traceDeprecation?console.trace(Pi):console.error(Pi),zi=!0}return Bi.apply(this,arguments)}return Gi};var s={},a=/^$/;if(t.NODE_DEBUG){var h=t.NODE_DEBUG;h=h.replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase(),a=new RegExp("^"+h+"$","i")}r.debuglog=function(Bi){if(Bi=Bi.toUpperCase(),!s[Bi])if(a.test(Bi)){var Pi=process$1.pid;s[Bi]=function(){var zi=r.format.apply(r,arguments);console.error("%s %d: %s",Bi,Pi,zi)}}else s[Bi]=function(){};return s[Bi]};function v(Bi,Pi){var zi={seen:[],stylize:u};return arguments.length>=3&&(zi.depth=arguments[2]),arguments.length>=4&&(zi.colors=arguments[3]),Ii(Pi)?zi.showHidden=Pi:Pi&&r._extend(zi,Pi),Hi(zi.showHidden)&&(zi.showHidden=!1),Hi(zi.depth)&&(zi.depth=2),Hi(zi.colors)&&(zi.colors=!1),Hi(zi.customInspect)&&(zi.customInspect=!0),zi.colors&&(zi.stylize=hi),vi(zi,Bi,zi.depth)}r.inspect=v,v.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},v.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"};function hi(Bi,Pi){var zi=v.styles[Pi];return zi?"\x1B["+v.colors[zi][0]+"m"+Bi+"\x1B["+v.colors[zi][1]+"m":Bi}function u(Bi,Pi){return Bi}function l(Bi){var Pi={};return Bi.forEach(function(zi,Gi){Pi[zi]=!0}),Pi}function vi(Bi,Pi,zi){if(Bi.customInspect&&Pi&&xi(Pi.inspect)&&Pi.inspect!==r.inspect&&!(Pi.constructor&&Pi.constructor.prototype===Pi)){var Gi=Pi.inspect(zi,Bi);return Li(Gi)||(Gi=vi(Bi,Gi,zi)),Gi}var Vi=D(Bi,Pi);if(Vi)return Vi;var Ki=Object.keys(Pi),Zi=l(Ki);if(Bi.showHidden&&(Ki=Object.getOwnPropertyNames(Pi)),wi(Pi)&&(Ki.indexOf("message")>=0||Ki.indexOf("description")>=0))return mi(Pi);if(Ki.length===0){if(xi(Pi)){var In=Pi.name?": "+Pi.name:"";return Bi.stylize("[Function"+In+"]","special")}if(Ui(Pi))return Bi.stylize(RegExp.prototype.toString.call(Pi),"regexp");if($i(Pi))return Bi.stylize(Date.prototype.toString.call(Pi),"date");if(wi(Pi))return mi(Pi)}var Ji="",Xi=!1,on=["{","}"];if(Ti(Pi)&&(Xi=!0,on=["[","]"]),xi(Pi)){var jn=Pi.name?": "+Pi.name:"";Ji=" [Function"+jn+"]"}if(Ui(Pi)&&(Ji=" "+RegExp.prototype.toString.call(Pi)),$i(Pi)&&(Ji=" "+Date.prototype.toUTCString.call(Pi)),wi(Pi)&&(Ji=" "+mi(Pi)),Ki.length===0&&(!Xi||Pi.length==0))return on[0]+Ji+on[1];if(zi<0)return Ui(Pi)?Bi.stylize(RegExp.prototype.toString.call(Pi),"regexp"):Bi.stylize("[Object]","special");Bi.seen.push(Pi);var Ln;return Xi?Ln=gi(Bi,Pi,zi,Zi,Ki):Ln=Ki.map(function(Hn){return bi(Bi,Pi,zi,Zi,Hn,Xi)}),Bi.seen.pop(),Ri(Ln,Ji,on)}function D(Bi,Pi){if(Hi(Pi))return Bi.stylize("undefined","undefined");if(Li(Pi)){var zi="'"+JSON.stringify(Pi).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return Bi.stylize(zi,"string")}if(ki(Pi))return Bi.stylize(""+Pi,"number");if(Ii(Pi))return Bi.stylize(""+Pi,"boolean");if(qi(Pi))return Bi.stylize("null","null")}function mi(Bi){return"["+Error.prototype.toString.call(Bi)+"]"}function gi(Bi,Pi,zi,Gi,Vi){for(var Ki=[],Zi=0,In=Pi.length;Zi<In;++Zi)Mi(Pi,String(Zi))?Ki.push(bi(Bi,Pi,zi,Gi,String(Zi),!0)):Ki.push("");return Vi.forEach(function(Ji){Ji.match(/^\d+$/)||Ki.push(bi(Bi,Pi,zi,Gi,Ji,!0))}),Ki}function bi(Bi,Pi,zi,Gi,Vi,Ki){var Zi,In,Ji;if(Ji=Object.getOwnPropertyDescriptor(Pi,Vi)||{value:Pi[Vi]},Ji.get?Ji.set?In=Bi.stylize("[Getter/Setter]","special"):In=Bi.stylize("[Getter]","special"):Ji.set&&(In=Bi.stylize("[Setter]","special")),Mi(Gi,Vi)||(Zi="["+Vi+"]"),In||(Bi.seen.indexOf(Ji.value)<0?(qi(zi)?In=vi(Bi,Ji.value,null):In=vi(Bi,Ji.value,zi-1),In.indexOf(`
7
+ `)>-1&&(Ki?In=In.split(`
8
+ `).map(function(Xi){return" "+Xi}).join(`
9
+ `).slice(2):In=`
10
+ `+In.split(`
11
+ `).map(function(Xi){return" "+Xi}).join(`
12
+ `))):In=Bi.stylize("[Circular]","special")),Hi(Zi)){if(Ki&&Vi.match(/^\d+$/))return In;Zi=JSON.stringify(""+Vi),Zi.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(Zi=Zi.slice(1,-1),Zi=Bi.stylize(Zi,"name")):(Zi=Zi.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),Zi=Bi.stylize(Zi,"string"))}return Zi+": "+In}function Ri(Bi,Pi,zi){var Gi=Bi.reduce(function(Vi,Ki){return Ki.indexOf(`
13
+ `)>=0,Vi+Ki.replace(/\u001b\[\d\d?m/g,"").length+1},0);return Gi>60?zi[0]+(Pi===""?"":Pi+`
14
+ `)+" "+Bi.join(`,
15
+ `)+" "+zi[1]:zi[0]+Pi+" "+Bi.join(", ")+" "+zi[1]}r.types=requireTypes$1();function Ti(Bi){return Array.isArray(Bi)}r.isArray=Ti;function Ii(Bi){return typeof Bi=="boolean"}r.isBoolean=Ii;function qi(Bi){return Bi===null}r.isNull=qi;function Oi(Bi){return Bi==null}r.isNullOrUndefined=Oi;function ki(Bi){return typeof Bi=="number"}r.isNumber=ki;function Li(Bi){return typeof Bi=="string"}r.isString=Li;function ji(Bi){return typeof Bi=="symbol"}r.isSymbol=ji;function Hi(Bi){return Bi===void 0}r.isUndefined=Hi;function Ui(Bi){return Qi(Bi)&&Ei(Bi)==="[object RegExp]"}r.isRegExp=Ui,r.types.isRegExp=Ui;function Qi(Bi){return typeof Bi=="object"&&Bi!==null}r.isObject=Qi;function $i(Bi){return Qi(Bi)&&Ei(Bi)==="[object Date]"}r.isDate=$i,r.types.isDate=$i;function wi(Bi){return Qi(Bi)&&(Ei(Bi)==="[object Error]"||Bi instanceof Error)}r.isError=wi,r.types.isNativeError=wi;function xi(Bi){return typeof Bi=="function"}r.isFunction=xi;function yi(Bi){return Bi===null||typeof Bi=="boolean"||typeof Bi=="number"||typeof Bi=="string"||typeof Bi=="symbol"||typeof Bi>"u"}r.isPrimitive=yi,r.isBuffer=requireIsBufferBrowser();function Ei(Bi){return Object.prototype.toString.call(Bi)}function Ci(Bi){return Bi<10?"0"+Bi.toString(10):Bi.toString(10)}var Ni=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function Fi(){var Bi=new Date,Pi=[Ci(Bi.getHours()),Ci(Bi.getMinutes()),Ci(Bi.getSeconds())].join(":");return[Bi.getDate(),Ni[Bi.getMonth()],Pi].join(" ")}r.log=function(){console.log("%s - %s",Fi(),r.format.apply(r,arguments))},r.inherits=requireInherits_browser(),r._extend=function(Bi,Pi){if(!Pi||!Qi(Pi))return Bi;for(var zi=Object.keys(Pi),Gi=zi.length;Gi--;)Bi[zi[Gi]]=Pi[zi[Gi]];return Bi};function Mi(Bi,Pi){return Object.prototype.hasOwnProperty.call(Bi,Pi)}var Si=typeof Symbol<"u"?Symbol("util.promisify.custom"):void 0;r.promisify=function(Pi){if(typeof Pi!="function")throw new TypeError('The "original" argument must be of type Function');if(Si&&Pi[Si]){var zi=Pi[Si];if(typeof zi!="function")throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(zi,Si,{value:zi,enumerable:!1,writable:!1,configurable:!0}),zi}function zi(){for(var Gi,Vi,Ki=new Promise(function(Ji,Xi){Gi=Ji,Vi=Xi}),Zi=[],In=0;In<arguments.length;In++)Zi.push(arguments[In]);Zi.push(function(Ji,Xi){Ji?Vi(Ji):Gi(Xi)});try{Pi.apply(this,Zi)}catch(Ji){Vi(Ji)}return Ki}return Object.setPrototypeOf(zi,Object.getPrototypeOf(Pi)),Si&&Object.defineProperty(zi,Si,{value:zi,enumerable:!1,writable:!1,configurable:!0}),Object.defineProperties(zi,i(Pi))},r.promisify.custom=Si;function Ai(Bi,Pi){if(!Bi){var zi=new Error("Promise was rejected with a falsy value");zi.reason=Bi,Bi=zi}return Pi(Bi)}function _i(Bi){if(typeof Bi!="function")throw new TypeError('The "original" argument must be of type Function');function Pi(){for(var zi=[],Gi=0;Gi<arguments.length;Gi++)zi.push(arguments[Gi]);var Vi=zi.pop();if(typeof Vi!="function")throw new TypeError("The last argument must be of type Function");var Ki=this,Zi=function(){return Vi.apply(Ki,arguments)};Bi.apply(this,zi).then(function(In){process$1.nextTick(Zi.bind(null,null,In))},function(In){process$1.nextTick(Ai.bind(null,In,Zi))})}return Object.setPrototypeOf(Pi,Object.getPrototypeOf(Bi)),Object.defineProperties(Pi,i(Bi)),Pi}r.callbackify=_i}(util$1)),util$1}var buffer_list,hasRequiredBuffer_list;function requireBuffer_list(){if(hasRequiredBuffer_list)return buffer_list;hasRequiredBuffer_list=1;function r(gi,bi){var Ri=Object.keys(gi);if(Object.getOwnPropertySymbols){var Ti=Object.getOwnPropertySymbols(gi);bi&&(Ti=Ti.filter(function(Ii){return Object.getOwnPropertyDescriptor(gi,Ii).enumerable})),Ri.push.apply(Ri,Ti)}return Ri}function t(gi){for(var bi=1;bi<arguments.length;bi++){var Ri=arguments[bi]!=null?arguments[bi]:{};bi%2?r(Object(Ri),!0).forEach(function(Ti){i(gi,Ti,Ri[Ti])}):Object.getOwnPropertyDescriptors?Object.defineProperties(gi,Object.getOwnPropertyDescriptors(Ri)):r(Object(Ri)).forEach(function(Ti){Object.defineProperty(gi,Ti,Object.getOwnPropertyDescriptor(Ri,Ti))})}return gi}function i(gi,bi,Ri){return bi=h(bi),bi in gi?Object.defineProperty(gi,bi,{value:Ri,enumerable:!0,configurable:!0,writable:!0}):gi[bi]=Ri,gi}function n(gi,bi){if(!(gi instanceof bi))throw new TypeError("Cannot call a class as a function")}function s(gi,bi){for(var Ri=0;Ri<bi.length;Ri++){var Ti=bi[Ri];Ti.enumerable=Ti.enumerable||!1,Ti.configurable=!0,"value"in Ti&&(Ti.writable=!0),Object.defineProperty(gi,h(Ti.key),Ti)}}function a(gi,bi,Ri){return bi&&s(gi.prototype,bi),Object.defineProperty(gi,"prototype",{writable:!1}),gi}function h(gi){var bi=v(gi,"string");return typeof bi=="symbol"?bi:String(bi)}function v(gi,bi){if(typeof gi!="object"||gi===null)return gi;var Ri=gi[Symbol.toPrimitive];if(Ri!==void 0){var Ti=Ri.call(gi,bi);if(typeof Ti!="object")return Ti;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(gi)}var hi=requireDist(),u=hi.Buffer,l=requireUtil$1(),vi=l.inspect,D=vi&&vi.custom||"inspect";function mi(gi,bi,Ri){u.prototype.copy.call(gi,bi,Ri)}return buffer_list=function(){function gi(){n(this,gi),this.head=null,this.tail=null,this.length=0}return a(gi,[{key:"push",value:function(Ri){var Ti={data:Ri,next:null};this.length>0?this.tail.next=Ti:this.head=Ti,this.tail=Ti,++this.length}},{key:"unshift",value:function(Ri){var Ti={data:Ri,next:this.head};this.length===0&&(this.tail=Ti),this.head=Ti,++this.length}},{key:"shift",value:function(){if(this.length!==0){var Ri=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,Ri}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(Ri){if(this.length===0)return"";for(var Ti=this.head,Ii=""+Ti.data;Ti=Ti.next;)Ii+=Ri+Ti.data;return Ii}},{key:"concat",value:function(Ri){if(this.length===0)return u.alloc(0);for(var Ti=u.allocUnsafe(Ri>>>0),Ii=this.head,qi=0;Ii;)mi(Ii.data,Ti,qi),qi+=Ii.data.length,Ii=Ii.next;return Ti}},{key:"consume",value:function(Ri,Ti){var Ii;return Ri<this.head.data.length?(Ii=this.head.data.slice(0,Ri),this.head.data=this.head.data.slice(Ri)):Ri===this.head.data.length?Ii=this.shift():Ii=Ti?this._getString(Ri):this._getBuffer(Ri),Ii}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(Ri){var Ti=this.head,Ii=1,qi=Ti.data;for(Ri-=qi.length;Ti=Ti.next;){var Oi=Ti.data,ki=Ri>Oi.length?Oi.length:Ri;if(ki===Oi.length?qi+=Oi:qi+=Oi.slice(0,Ri),Ri-=ki,Ri===0){ki===Oi.length?(++Ii,Ti.next?this.head=Ti.next:this.head=this.tail=null):(this.head=Ti,Ti.data=Oi.slice(ki));break}++Ii}return this.length-=Ii,qi}},{key:"_getBuffer",value:function(Ri){var Ti=u.allocUnsafe(Ri),Ii=this.head,qi=1;for(Ii.data.copy(Ti),Ri-=Ii.data.length;Ii=Ii.next;){var Oi=Ii.data,ki=Ri>Oi.length?Oi.length:Ri;if(Oi.copy(Ti,Ti.length-Ri,0,ki),Ri-=ki,Ri===0){ki===Oi.length?(++qi,Ii.next?this.head=Ii.next:this.head=this.tail=null):(this.head=Ii,Ii.data=Oi.slice(ki));break}++qi}return this.length-=qi,Ti}},{key:D,value:function(Ri,Ti){return vi(this,t(t({},Ti),{},{depth:0,customInspect:!1}))}}]),gi}(),buffer_list}var destroy_1$1,hasRequiredDestroy$1;function requireDestroy$1(){if(hasRequiredDestroy$1)return destroy_1$1;hasRequiredDestroy$1=1;function r(h,v){var hi=this,u=this._readableState&&this._readableState.destroyed,l=this._writableState&&this._writableState.destroyed;return u||l?(v?v(h):h&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,process$1.nextTick(s,this,h)):process$1.nextTick(s,this,h)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(h||null,function(vi){!v&&vi?hi._writableState?hi._writableState.errorEmitted?process$1.nextTick(i,hi):(hi._writableState.errorEmitted=!0,process$1.nextTick(t,hi,vi)):process$1.nextTick(t,hi,vi):v?(process$1.nextTick(i,hi),v(vi)):process$1.nextTick(i,hi)}),this)}function t(h,v){s(h,v),i(h)}function i(h){h._writableState&&!h._writableState.emitClose||h._readableState&&!h._readableState.emitClose||h.emit("close")}function n(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function s(h,v){h.emit("error",v)}function a(h,v){var hi=h._readableState,u=h._writableState;hi&&hi.autoDestroy||u&&u.autoDestroy?h.destroy(v):h.emit("error",v)}return destroy_1$1={destroy:r,undestroy:n,errorOrDestroy:a},destroy_1$1}var errorsBrowser={},hasRequiredErrorsBrowser;function requireErrorsBrowser(){if(hasRequiredErrorsBrowser)return errorsBrowser;hasRequiredErrorsBrowser=1;function r(v,hi){v.prototype=Object.create(hi.prototype),v.prototype.constructor=v,v.__proto__=hi}var t={};function i(v,hi,u){u||(u=Error);function l(D,mi,gi){return typeof hi=="string"?hi:hi(D,mi,gi)}var vi=function(D){r(mi,D);function mi(gi,bi,Ri){return D.call(this,l(gi,bi,Ri))||this}return mi}(u);vi.prototype.name=u.name,vi.prototype.code=v,t[v]=vi}function n(v,hi){if(Array.isArray(v)){var u=v.length;return v=v.map(function(l){return String(l)}),u>2?"one of ".concat(hi," ").concat(v.slice(0,u-1).join(", "),", or ")+v[u-1]:u===2?"one of ".concat(hi," ").concat(v[0]," or ").concat(v[1]):"of ".concat(hi," ").concat(v[0])}else return"of ".concat(hi," ").concat(String(v))}function s(v,hi,u){return v.substr(0,hi.length)===hi}function a(v,hi,u){return(u===void 0||u>v.length)&&(u=v.length),v.substring(u-hi.length,u)===hi}function h(v,hi,u){return typeof u!="number"&&(u=0),u+hi.length>v.length?!1:v.indexOf(hi,u)!==-1}return i("ERR_INVALID_OPT_VALUE",function(v,hi){return'The value "'+hi+'" is invalid for option "'+v+'"'},TypeError),i("ERR_INVALID_ARG_TYPE",function(v,hi,u){var l;typeof hi=="string"&&s(hi,"not ")?(l="must not be",hi=hi.replace(/^not /,"")):l="must be";var vi;if(a(v," argument"))vi="The ".concat(v," ").concat(l," ").concat(n(hi,"type"));else{var D=h(v,".")?"property":"argument";vi='The "'.concat(v,'" ').concat(D," ").concat(l," ").concat(n(hi,"type"))}return vi+=". Received type ".concat(typeof u),vi},TypeError),i("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),i("ERR_METHOD_NOT_IMPLEMENTED",function(v){return"The "+v+" method is not implemented"}),i("ERR_STREAM_PREMATURE_CLOSE","Premature close"),i("ERR_STREAM_DESTROYED",function(v){return"Cannot call "+v+" after a stream was destroyed"}),i("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),i("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),i("ERR_STREAM_WRITE_AFTER_END","write after end"),i("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),i("ERR_UNKNOWN_ENCODING",function(v){return"Unknown encoding: "+v},TypeError),i("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),errorsBrowser.codes=t,errorsBrowser}var state,hasRequiredState;function requireState(){if(hasRequiredState)return state;hasRequiredState=1;var r=requireErrorsBrowser().codes.ERR_INVALID_OPT_VALUE;function t(n,s,a){return n.highWaterMark!=null?n.highWaterMark:s?n[a]:null}function i(n,s,a,h){var v=t(s,h,a);if(v!=null){if(!(isFinite(v)&&Math.floor(v)===v)||v<0){var hi=h?a:"highWaterMark";throw new r(hi,v)}return Math.floor(v)}return n.objectMode?16:16*1024}return state={getHighWaterMark:i},state}var browser$c,hasRequiredBrowser$c;function requireBrowser$c(){if(hasRequiredBrowser$c)return browser$c;hasRequiredBrowser$c=1,browser$c=r;function r(i,n){if(t("noDeprecation"))return i;var s=!1;function a(){if(!s){if(t("throwDeprecation"))throw new Error(n);t("traceDeprecation")?console.trace(n):console.warn(n),s=!0}return i.apply(this,arguments)}return a}function t(i){try{if(!commonjsGlobal.localStorage)return!1}catch{return!1}var n=commonjsGlobal.localStorage[i];return n==null?!1:String(n).toLowerCase()==="true"}return browser$c}var _stream_writable$1,hasRequired_stream_writable$1;function require_stream_writable$1(){if(hasRequired_stream_writable$1)return _stream_writable$1;hasRequired_stream_writable$1=1,_stream_writable$1=Hi;function r(Gi){var Vi=this;this.next=null,this.entry=null,this.finish=function(){zi(Vi,Gi)}}var t;Hi.WritableState=Li;var i={deprecate:requireBrowser$c()},n=requireStreamBrowser$1(),s=requireDist().Buffer,a=(typeof commonjsGlobal<"u"?commonjsGlobal:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function h(Gi){return s.from(Gi)}function v(Gi){return s.isBuffer(Gi)||Gi instanceof a}var hi=requireDestroy$1(),u=requireState(),l=u.getHighWaterMark,vi=requireErrorsBrowser().codes,D=vi.ERR_INVALID_ARG_TYPE,mi=vi.ERR_METHOD_NOT_IMPLEMENTED,gi=vi.ERR_MULTIPLE_CALLBACK,bi=vi.ERR_STREAM_CANNOT_PIPE,Ri=vi.ERR_STREAM_DESTROYED,Ti=vi.ERR_STREAM_NULL_VALUES,Ii=vi.ERR_STREAM_WRITE_AFTER_END,qi=vi.ERR_UNKNOWN_ENCODING,Oi=hi.errorOrDestroy;requireInherits_browser()(Hi,n);function ki(){}function Li(Gi,Vi,Ki){t=t||require_stream_duplex$1(),Gi=Gi||{},typeof Ki!="boolean"&&(Ki=Vi instanceof t),this.objectMode=!!Gi.objectMode,Ki&&(this.objectMode=this.objectMode||!!Gi.writableObjectMode),this.highWaterMark=l(this,Gi,"writableHighWaterMark",Ki),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var Zi=Gi.decodeStrings===!1;this.decodeStrings=!Zi,this.defaultEncoding=Gi.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(In){Ci(Vi,In)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=Gi.emitClose!==!1,this.autoDestroy=!!Gi.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new r(this)}Li.prototype.getBuffer=function(){for(var Vi=this.bufferedRequest,Ki=[];Vi;)Ki.push(Vi),Vi=Vi.next;return Ki},function(){try{Object.defineProperty(Li.prototype,"buffer",{get:i.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}}();var ji;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(ji=Function.prototype[Symbol.hasInstance],Object.defineProperty(Hi,Symbol.hasInstance,{value:function(Vi){return ji.call(this,Vi)?!0:this!==Hi?!1:Vi&&Vi._writableState instanceof Li}})):ji=function(Vi){return Vi instanceof this};function Hi(Gi){t=t||require_stream_duplex$1();var Vi=this instanceof t;if(!Vi&&!ji.call(Hi,this))return new Hi(Gi);this._writableState=new Li(Gi,this,Vi),this.writable=!0,Gi&&(typeof Gi.write=="function"&&(this._write=Gi.write),typeof Gi.writev=="function"&&(this._writev=Gi.writev),typeof Gi.destroy=="function"&&(this._destroy=Gi.destroy),typeof Gi.final=="function"&&(this._final=Gi.final)),n.call(this)}Hi.prototype.pipe=function(){Oi(this,new bi)};function Ui(Gi,Vi){var Ki=new Ii;Oi(Gi,Ki),process$1.nextTick(Vi,Ki)}function Qi(Gi,Vi,Ki,Zi){var In;return Ki===null?In=new Ti:typeof Ki!="string"&&!Vi.objectMode&&(In=new D("chunk",["string","Buffer"],Ki)),In?(Oi(Gi,In),process$1.nextTick(Zi,In),!1):!0}Hi.prototype.write=function(Gi,Vi,Ki){var Zi=this._writableState,In=!1,Ji=!Zi.objectMode&&v(Gi);return Ji&&!s.isBuffer(Gi)&&(Gi=h(Gi)),typeof Vi=="function"&&(Ki=Vi,Vi=null),Ji?Vi="buffer":Vi||(Vi=Zi.defaultEncoding),typeof Ki!="function"&&(Ki=ki),Zi.ending?Ui(this,Ki):(Ji||Qi(this,Zi,Gi,Ki))&&(Zi.pendingcb++,In=wi(this,Zi,Ji,Gi,Vi,Ki)),In},Hi.prototype.cork=function(){this._writableState.corked++},Hi.prototype.uncork=function(){var Gi=this._writableState;Gi.corked&&(Gi.corked--,!Gi.writing&&!Gi.corked&&!Gi.bufferProcessing&&Gi.bufferedRequest&&Mi(this,Gi))},Hi.prototype.setDefaultEncoding=function(Vi){if(typeof Vi=="string"&&(Vi=Vi.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((Vi+"").toLowerCase())>-1))throw new qi(Vi);return this._writableState.defaultEncoding=Vi,this},Object.defineProperty(Hi.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function $i(Gi,Vi,Ki){return!Gi.objectMode&&Gi.decodeStrings!==!1&&typeof Vi=="string"&&(Vi=s.from(Vi,Ki)),Vi}Object.defineProperty(Hi.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function wi(Gi,Vi,Ki,Zi,In,Ji){if(!Ki){var Xi=$i(Vi,Zi,In);Zi!==Xi&&(Ki=!0,In="buffer",Zi=Xi)}var on=Vi.objectMode?1:Zi.length;Vi.length+=on;var jn=Vi.length<Vi.highWaterMark;if(jn||(Vi.needDrain=!0),Vi.writing||Vi.corked){var Ln=Vi.lastBufferedRequest;Vi.lastBufferedRequest={chunk:Zi,encoding:In,isBuf:Ki,callback:Ji,next:null},Ln?Ln.next=Vi.lastBufferedRequest:Vi.bufferedRequest=Vi.lastBufferedRequest,Vi.bufferedRequestCount+=1}else xi(Gi,Vi,!1,on,Zi,In,Ji);return jn}function xi(Gi,Vi,Ki,Zi,In,Ji,Xi){Vi.writelen=Zi,Vi.writecb=Xi,Vi.writing=!0,Vi.sync=!0,Vi.destroyed?Vi.onwrite(new Ri("write")):Ki?Gi._writev(In,Vi.onwrite):Gi._write(In,Ji,Vi.onwrite),Vi.sync=!1}function yi(Gi,Vi,Ki,Zi,In){--Vi.pendingcb,Ki?(process$1.nextTick(In,Zi),process$1.nextTick(Bi,Gi,Vi),Gi._writableState.errorEmitted=!0,Oi(Gi,Zi)):(In(Zi),Gi._writableState.errorEmitted=!0,Oi(Gi,Zi),Bi(Gi,Vi))}function Ei(Gi){Gi.writing=!1,Gi.writecb=null,Gi.length-=Gi.writelen,Gi.writelen=0}function Ci(Gi,Vi){var Ki=Gi._writableState,Zi=Ki.sync,In=Ki.writecb;if(typeof In!="function")throw new gi;if(Ei(Ki),Vi)yi(Gi,Ki,Zi,Vi,In);else{var Ji=Si(Ki)||Gi.destroyed;!Ji&&!Ki.corked&&!Ki.bufferProcessing&&Ki.bufferedRequest&&Mi(Gi,Ki),Zi?process$1.nextTick(Ni,Gi,Ki,Ji,In):Ni(Gi,Ki,Ji,In)}}function Ni(Gi,Vi,Ki,Zi){Ki||Fi(Gi,Vi),Vi.pendingcb--,Zi(),Bi(Gi,Vi)}function Fi(Gi,Vi){Vi.length===0&&Vi.needDrain&&(Vi.needDrain=!1,Gi.emit("drain"))}function Mi(Gi,Vi){Vi.bufferProcessing=!0;var Ki=Vi.bufferedRequest;if(Gi._writev&&Ki&&Ki.next){var Zi=Vi.bufferedRequestCount,In=new Array(Zi),Ji=Vi.corkedRequestsFree;Ji.entry=Ki;for(var Xi=0,on=!0;Ki;)In[Xi]=Ki,Ki.isBuf||(on=!1),Ki=Ki.next,Xi+=1;In.allBuffers=on,xi(Gi,Vi,!0,Vi.length,In,"",Ji.finish),Vi.pendingcb++,Vi.lastBufferedRequest=null,Ji.next?(Vi.corkedRequestsFree=Ji.next,Ji.next=null):Vi.corkedRequestsFree=new r(Vi),Vi.bufferedRequestCount=0}else{for(;Ki;){var jn=Ki.chunk,Ln=Ki.encoding,Hn=Ki.callback,ea=Vi.objectMode?1:jn.length;if(xi(Gi,Vi,!1,ea,jn,Ln,Hn),Ki=Ki.next,Vi.bufferedRequestCount--,Vi.writing)break}Ki===null&&(Vi.lastBufferedRequest=null)}Vi.bufferedRequest=Ki,Vi.bufferProcessing=!1}Hi.prototype._write=function(Gi,Vi,Ki){Ki(new mi("_write()"))},Hi.prototype._writev=null,Hi.prototype.end=function(Gi,Vi,Ki){var Zi=this._writableState;return typeof Gi=="function"?(Ki=Gi,Gi=null,Vi=null):typeof Vi=="function"&&(Ki=Vi,Vi=null),Gi!=null&&this.write(Gi,Vi),Zi.corked&&(Zi.corked=1,this.uncork()),Zi.ending||Pi(this,Zi,Ki),this},Object.defineProperty(Hi.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function Si(Gi){return Gi.ending&&Gi.length===0&&Gi.bufferedRequest===null&&!Gi.finished&&!Gi.writing}function Ai(Gi,Vi){Gi._final(function(Ki){Vi.pendingcb--,Ki&&Oi(Gi,Ki),Vi.prefinished=!0,Gi.emit("prefinish"),Bi(Gi,Vi)})}function _i(Gi,Vi){!Vi.prefinished&&!Vi.finalCalled&&(typeof Gi._final=="function"&&!Vi.destroyed?(Vi.pendingcb++,Vi.finalCalled=!0,process$1.nextTick(Ai,Gi,Vi)):(Vi.prefinished=!0,Gi.emit("prefinish")))}function Bi(Gi,Vi){var Ki=Si(Vi);if(Ki&&(_i(Gi,Vi),Vi.pendingcb===0&&(Vi.finished=!0,Gi.emit("finish"),Vi.autoDestroy))){var Zi=Gi._readableState;(!Zi||Zi.autoDestroy&&Zi.endEmitted)&&Gi.destroy()}return Ki}function Pi(Gi,Vi,Ki){Vi.ending=!0,Bi(Gi,Vi),Ki&&(Vi.finished?process$1.nextTick(Ki):Gi.once("finish",Ki)),Vi.ended=!0,Gi.writable=!1}function zi(Gi,Vi,Ki){var Zi=Gi.entry;for(Gi.entry=null;Zi;){var In=Zi.callback;Vi.pendingcb--,In(Ki),Zi=Zi.next}Vi.corkedRequestsFree.next=Gi}return Object.defineProperty(Hi.prototype,"destroyed",{enumerable:!1,get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(Vi){this._writableState&&(this._writableState.destroyed=Vi)}}),Hi.prototype.destroy=hi.destroy,Hi.prototype._undestroy=hi.undestroy,Hi.prototype._destroy=function(Gi,Vi){Vi(Gi)},_stream_writable$1}var _stream_duplex$1,hasRequired_stream_duplex$1;function require_stream_duplex$1(){if(hasRequired_stream_duplex$1)return _stream_duplex$1;hasRequired_stream_duplex$1=1;var r=Object.keys||function(u){var l=[];for(var vi in u)l.push(vi);return l};_stream_duplex$1=h;var t=require_stream_readable$1(),i=require_stream_writable$1();requireInherits_browser()(h,t);for(var n=r(i.prototype),s=0;s<n.length;s++){var a=n[s];h.prototype[a]||(h.prototype[a]=i.prototype[a])}function h(u){if(!(this instanceof h))return new h(u);t.call(this,u),i.call(this,u),this.allowHalfOpen=!0,u&&(u.readable===!1&&(this.readable=!1),u.writable===!1&&(this.writable=!1),u.allowHalfOpen===!1&&(this.allowHalfOpen=!1,this.once("end",v)))}Object.defineProperty(h.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(h.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(h.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function v(){this._writableState.ended||process$1.nextTick(hi,this)}function hi(u){u.end()}return Object.defineProperty(h.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(l){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=l,this._writableState.destroyed=l)}}),_stream_duplex$1}var string_decoder={},hasRequiredString_decoder;function requireString_decoder(){if(hasRequiredString_decoder)return string_decoder;hasRequiredString_decoder=1;var r=requireSafeBuffer$1().Buffer,t=r.isEncoding||function(Ti){switch(Ti=""+Ti,Ti&&Ti.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function i(Ti){if(!Ti)return"utf8";for(var Ii;;)switch(Ti){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return Ti;default:if(Ii)return;Ti=(""+Ti).toLowerCase(),Ii=!0}}function n(Ti){var Ii=i(Ti);if(typeof Ii!="string"&&(r.isEncoding===t||!t(Ti)))throw new Error("Unknown encoding: "+Ti);return Ii||Ti}string_decoder.StringDecoder=s;function s(Ti){this.encoding=n(Ti);var Ii;switch(this.encoding){case"utf16le":this.text=vi,this.end=D,Ii=4;break;case"utf8":this.fillLast=hi,Ii=4;break;case"base64":this.text=mi,this.end=gi,Ii=3;break;default:this.write=bi,this.end=Ri;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=r.allocUnsafe(Ii)}s.prototype.write=function(Ti){if(Ti.length===0)return"";var Ii,qi;if(this.lastNeed){if(Ii=this.fillLast(Ti),Ii===void 0)return"";qi=this.lastNeed,this.lastNeed=0}else qi=0;return qi<Ti.length?Ii?Ii+this.text(Ti,qi):this.text(Ti,qi):Ii||""},s.prototype.end=l,s.prototype.text=u,s.prototype.fillLast=function(Ti){if(this.lastNeed<=Ti.length)return Ti.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);Ti.copy(this.lastChar,this.lastTotal-this.lastNeed,0,Ti.length),this.lastNeed-=Ti.length};function a(Ti){return Ti<=127?0:Ti>>5===6?2:Ti>>4===14?3:Ti>>3===30?4:Ti>>6===2?-1:-2}function h(Ti,Ii,qi){var Oi=Ii.length-1;if(Oi<qi)return 0;var ki=a(Ii[Oi]);return ki>=0?(ki>0&&(Ti.lastNeed=ki-1),ki):--Oi<qi||ki===-2?0:(ki=a(Ii[Oi]),ki>=0?(ki>0&&(Ti.lastNeed=ki-2),ki):--Oi<qi||ki===-2?0:(ki=a(Ii[Oi]),ki>=0?(ki>0&&(ki===2?ki=0:Ti.lastNeed=ki-3),ki):0))}function v(Ti,Ii,qi){if((Ii[0]&192)!==128)return Ti.lastNeed=0,"�";if(Ti.lastNeed>1&&Ii.length>1){if((Ii[1]&192)!==128)return Ti.lastNeed=1,"�";if(Ti.lastNeed>2&&Ii.length>2&&(Ii[2]&192)!==128)return Ti.lastNeed=2,"�"}}function hi(Ti){var Ii=this.lastTotal-this.lastNeed,qi=v(this,Ti);if(qi!==void 0)return qi;if(this.lastNeed<=Ti.length)return Ti.copy(this.lastChar,Ii,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);Ti.copy(this.lastChar,Ii,0,Ti.length),this.lastNeed-=Ti.length}function u(Ti,Ii){var qi=h(this,Ti,Ii);if(!this.lastNeed)return Ti.toString("utf8",Ii);this.lastTotal=qi;var Oi=Ti.length-(qi-this.lastNeed);return Ti.copy(this.lastChar,0,Oi),Ti.toString("utf8",Ii,Oi)}function l(Ti){var Ii=Ti&&Ti.length?this.write(Ti):"";return this.lastNeed?Ii+"�":Ii}function vi(Ti,Ii){if((Ti.length-Ii)%2===0){var qi=Ti.toString("utf16le",Ii);if(qi){var Oi=qi.charCodeAt(qi.length-1);if(Oi>=55296&&Oi<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=Ti[Ti.length-2],this.lastChar[1]=Ti[Ti.length-1],qi.slice(0,-1)}return qi}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=Ti[Ti.length-1],Ti.toString("utf16le",Ii,Ti.length-1)}function D(Ti){var Ii=Ti&&Ti.length?this.write(Ti):"";if(this.lastNeed){var qi=this.lastTotal-this.lastNeed;return Ii+this.lastChar.toString("utf16le",0,qi)}return Ii}function mi(Ti,Ii){var qi=(Ti.length-Ii)%3;return qi===0?Ti.toString("base64",Ii):(this.lastNeed=3-qi,this.lastTotal=3,qi===1?this.lastChar[0]=Ti[Ti.length-1]:(this.lastChar[0]=Ti[Ti.length-2],this.lastChar[1]=Ti[Ti.length-1]),Ti.toString("base64",Ii,Ti.length-qi))}function gi(Ti){var Ii=Ti&&Ti.length?this.write(Ti):"";return this.lastNeed?Ii+this.lastChar.toString("base64",0,3-this.lastNeed):Ii}function bi(Ti){return Ti.toString(this.encoding)}function Ri(Ti){return Ti&&Ti.length?this.write(Ti):""}return string_decoder}var endOfStream,hasRequiredEndOfStream;function requireEndOfStream(){if(hasRequiredEndOfStream)return endOfStream;hasRequiredEndOfStream=1;var r=requireErrorsBrowser().codes.ERR_STREAM_PREMATURE_CLOSE;function t(a){var h=!1;return function(){if(!h){h=!0;for(var v=arguments.length,hi=new Array(v),u=0;u<v;u++)hi[u]=arguments[u];a.apply(this,hi)}}}function i(){}function n(a){return a.setHeader&&typeof a.abort=="function"}function s(a,h,v){if(typeof h=="function")return s(a,null,h);h||(h={}),v=t(v||i);var hi=h.readable||h.readable!==!1&&a.readable,u=h.writable||h.writable!==!1&&a.writable,l=function(){a.writable||D()},vi=a._writableState&&a._writableState.finished,D=function(){u=!1,vi=!0,hi||v.call(a)},mi=a._readableState&&a._readableState.endEmitted,gi=function(){hi=!1,mi=!0,u||v.call(a)},bi=function(qi){v.call(a,qi)},Ri=function(){var qi;if(hi&&!mi)return(!a._readableState||!a._readableState.ended)&&(qi=new r),v.call(a,qi);if(u&&!vi)return(!a._writableState||!a._writableState.ended)&&(qi=new r),v.call(a,qi)},Ti=function(){a.req.on("finish",D)};return n(a)?(a.on("complete",D),a.on("abort",Ri),a.req?Ti():a.on("request",Ti)):u&&!a._writableState&&(a.on("end",l),a.on("close",l)),a.on("end",gi),a.on("finish",D),h.error!==!1&&a.on("error",bi),a.on("close",Ri),function(){a.removeListener("complete",D),a.removeListener("abort",Ri),a.removeListener("request",Ti),a.req&&a.req.removeListener("finish",D),a.removeListener("end",l),a.removeListener("close",l),a.removeListener("finish",D),a.removeListener("end",gi),a.removeListener("error",bi),a.removeListener("close",Ri)}}return endOfStream=s,endOfStream}var async_iterator,hasRequiredAsync_iterator;function requireAsync_iterator(){if(hasRequiredAsync_iterator)return async_iterator;hasRequiredAsync_iterator=1;var r;function t(qi,Oi,ki){return Oi=i(Oi),Oi in qi?Object.defineProperty(qi,Oi,{value:ki,enumerable:!0,configurable:!0,writable:!0}):qi[Oi]=ki,qi}function i(qi){var Oi=n(qi,"string");return typeof Oi=="symbol"?Oi:String(Oi)}function n(qi,Oi){if(typeof qi!="object"||qi===null)return qi;var ki=qi[Symbol.toPrimitive];if(ki!==void 0){var Li=ki.call(qi,Oi);if(typeof Li!="object")return Li;throw new TypeError("@@toPrimitive must return a primitive value.")}return(Oi==="string"?String:Number)(qi)}var s=requireEndOfStream(),a=Symbol("lastResolve"),h=Symbol("lastReject"),v=Symbol("error"),hi=Symbol("ended"),u=Symbol("lastPromise"),l=Symbol("handlePromise"),vi=Symbol("stream");function D(qi,Oi){return{value:qi,done:Oi}}function mi(qi){var Oi=qi[a];if(Oi!==null){var ki=qi[vi].read();ki!==null&&(qi[u]=null,qi[a]=null,qi[h]=null,Oi(D(ki,!1)))}}function gi(qi){process$1.nextTick(mi,qi)}function bi(qi,Oi){return function(ki,Li){qi.then(function(){if(Oi[hi]){ki(D(void 0,!0));return}Oi[l](ki,Li)},Li)}}var Ri=Object.getPrototypeOf(function(){}),Ti=Object.setPrototypeOf((r={get stream(){return this[vi]},next:function(){var Oi=this,ki=this[v];if(ki!==null)return Promise.reject(ki);if(this[hi])return Promise.resolve(D(void 0,!0));if(this[vi].destroyed)return new Promise(function(Ui,Qi){process$1.nextTick(function(){Oi[v]?Qi(Oi[v]):Ui(D(void 0,!0))})});var Li=this[u],ji;if(Li)ji=new Promise(bi(Li,this));else{var Hi=this[vi].read();if(Hi!==null)return Promise.resolve(D(Hi,!1));ji=new Promise(this[l])}return this[u]=ji,ji}},t(r,Symbol.asyncIterator,function(){return this}),t(r,"return",function(){var Oi=this;return new Promise(function(ki,Li){Oi[vi].destroy(null,function(ji){if(ji){Li(ji);return}ki(D(void 0,!0))})})}),r),Ri),Ii=function(Oi){var ki,Li=Object.create(Ti,(ki={},t(ki,vi,{value:Oi,writable:!0}),t(ki,a,{value:null,writable:!0}),t(ki,h,{value:null,writable:!0}),t(ki,v,{value:null,writable:!0}),t(ki,hi,{value:Oi._readableState.endEmitted,writable:!0}),t(ki,l,{value:function(Hi,Ui){var Qi=Li[vi].read();Qi?(Li[u]=null,Li[a]=null,Li[h]=null,Hi(D(Qi,!1))):(Li[a]=Hi,Li[h]=Ui)},writable:!0}),ki));return Li[u]=null,s(Oi,function(ji){if(ji&&ji.code!=="ERR_STREAM_PREMATURE_CLOSE"){var Hi=Li[h];Hi!==null&&(Li[u]=null,Li[a]=null,Li[h]=null,Hi(ji)),Li[v]=ji;return}var Ui=Li[a];Ui!==null&&(Li[u]=null,Li[a]=null,Li[h]=null,Ui(D(void 0,!0))),Li[hi]=!0}),Oi.on("readable",gi.bind(null,Li)),Li};return async_iterator=Ii,async_iterator}var fromBrowser,hasRequiredFromBrowser;function requireFromBrowser(){return hasRequiredFromBrowser||(hasRequiredFromBrowser=1,fromBrowser=function(){throw new Error("Readable.from is not available in the browser")}),fromBrowser}var _stream_readable$1,hasRequired_stream_readable$1;function require_stream_readable$1(){if(hasRequired_stream_readable$1)return _stream_readable$1;hasRequired_stream_readable$1=1,_stream_readable$1=Ui;var r;Ui.ReadableState=Hi,requireEvents().EventEmitter;var t=function(Xi,on){return Xi.listeners(on).length},i=requireStreamBrowser$1(),n=requireDist().Buffer,s=(typeof commonjsGlobal<"u"?commonjsGlobal:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function a(Ji){return n.from(Ji)}function h(Ji){return n.isBuffer(Ji)||Ji instanceof s}var v=requireUtil$1(),hi;v&&v.debuglog?hi=v.debuglog("stream"):hi=function(){};var u=requireBuffer_list(),l=requireDestroy$1(),vi=requireState(),D=vi.getHighWaterMark,mi=requireErrorsBrowser().codes,gi=mi.ERR_INVALID_ARG_TYPE,bi=mi.ERR_STREAM_PUSH_AFTER_EOF,Ri=mi.ERR_METHOD_NOT_IMPLEMENTED,Ti=mi.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,Ii,qi,Oi;requireInherits_browser()(Ui,i);var ki=l.errorOrDestroy,Li=["error","close","destroy","pause","resume"];function ji(Ji,Xi,on){if(typeof Ji.prependListener=="function")return Ji.prependListener(Xi,on);!Ji._events||!Ji._events[Xi]?Ji.on(Xi,on):Array.isArray(Ji._events[Xi])?Ji._events[Xi].unshift(on):Ji._events[Xi]=[on,Ji._events[Xi]]}function Hi(Ji,Xi,on){r=r||require_stream_duplex$1(),Ji=Ji||{},typeof on!="boolean"&&(on=Xi instanceof r),this.objectMode=!!Ji.objectMode,on&&(this.objectMode=this.objectMode||!!Ji.readableObjectMode),this.highWaterMark=D(this,Ji,"readableHighWaterMark",on),this.buffer=new u,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=Ji.emitClose!==!1,this.autoDestroy=!!Ji.autoDestroy,this.destroyed=!1,this.defaultEncoding=Ji.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,Ji.encoding&&(Ii||(Ii=requireString_decoder().StringDecoder),this.decoder=new Ii(Ji.encoding),this.encoding=Ji.encoding)}function Ui(Ji){if(r=r||require_stream_duplex$1(),!(this instanceof Ui))return new Ui(Ji);var Xi=this instanceof r;this._readableState=new Hi(Ji,this,Xi),this.readable=!0,Ji&&(typeof Ji.read=="function"&&(this._read=Ji.read),typeof Ji.destroy=="function"&&(this._destroy=Ji.destroy)),i.call(this)}Object.defineProperty(Ui.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(Xi){this._readableState&&(this._readableState.destroyed=Xi)}}),Ui.prototype.destroy=l.destroy,Ui.prototype._undestroy=l.undestroy,Ui.prototype._destroy=function(Ji,Xi){Xi(Ji)},Ui.prototype.push=function(Ji,Xi){var on=this._readableState,jn;return on.objectMode?jn=!0:typeof Ji=="string"&&(Xi=Xi||on.defaultEncoding,Xi!==on.encoding&&(Ji=n.from(Ji,Xi),Xi=""),jn=!0),Qi(this,Ji,Xi,!1,jn)},Ui.prototype.unshift=function(Ji){return Qi(this,Ji,null,!0,!1)};function Qi(Ji,Xi,on,jn,Ln){hi("readableAddChunk",Xi);var Hn=Ji._readableState;if(Xi===null)Hn.reading=!1,Ci(Ji,Hn);else{var ea;if(Ln||(ea=wi(Hn,Xi)),ea)ki(Ji,ea);else if(Hn.objectMode||Xi&&Xi.length>0)if(typeof Xi!="string"&&!Hn.objectMode&&Object.getPrototypeOf(Xi)!==n.prototype&&(Xi=a(Xi)),jn)Hn.endEmitted?ki(Ji,new Ti):$i(Ji,Hn,Xi,!0);else if(Hn.ended)ki(Ji,new bi);else{if(Hn.destroyed)return!1;Hn.reading=!1,Hn.decoder&&!on?(Xi=Hn.decoder.write(Xi),Hn.objectMode||Xi.length!==0?$i(Ji,Hn,Xi,!1):Mi(Ji,Hn)):$i(Ji,Hn,Xi,!1)}else jn||(Hn.reading=!1,Mi(Ji,Hn))}return!Hn.ended&&(Hn.length<Hn.highWaterMark||Hn.length===0)}function $i(Ji,Xi,on,jn){Xi.flowing&&Xi.length===0&&!Xi.sync?(Xi.awaitDrain=0,Ji.emit("data",on)):(Xi.length+=Xi.objectMode?1:on.length,jn?Xi.buffer.unshift(on):Xi.buffer.push(on),Xi.needReadable&&Ni(Ji)),Mi(Ji,Xi)}function wi(Ji,Xi){var on;return!h(Xi)&&typeof Xi!="string"&&Xi!==void 0&&!Ji.objectMode&&(on=new gi("chunk",["string","Buffer","Uint8Array"],Xi)),on}Ui.prototype.isPaused=function(){return this._readableState.flowing===!1},Ui.prototype.setEncoding=function(Ji){Ii||(Ii=requireString_decoder().StringDecoder);var Xi=new Ii(Ji);this._readableState.decoder=Xi,this._readableState.encoding=this._readableState.decoder.encoding;for(var on=this._readableState.buffer.head,jn="";on!==null;)jn+=Xi.write(on.data),on=on.next;return this._readableState.buffer.clear(),jn!==""&&this._readableState.buffer.push(jn),this._readableState.length=jn.length,this};var xi=1073741824;function yi(Ji){return Ji>=xi?Ji=xi:(Ji--,Ji|=Ji>>>1,Ji|=Ji>>>2,Ji|=Ji>>>4,Ji|=Ji>>>8,Ji|=Ji>>>16,Ji++),Ji}function Ei(Ji,Xi){return Ji<=0||Xi.length===0&&Xi.ended?0:Xi.objectMode?1:Ji!==Ji?Xi.flowing&&Xi.length?Xi.buffer.head.data.length:Xi.length:(Ji>Xi.highWaterMark&&(Xi.highWaterMark=yi(Ji)),Ji<=Xi.length?Ji:Xi.ended?Xi.length:(Xi.needReadable=!0,0))}Ui.prototype.read=function(Ji){hi("read",Ji),Ji=parseInt(Ji,10);var Xi=this._readableState,on=Ji;if(Ji!==0&&(Xi.emittedReadable=!1),Ji===0&&Xi.needReadable&&((Xi.highWaterMark!==0?Xi.length>=Xi.highWaterMark:Xi.length>0)||Xi.ended))return hi("read: emitReadable",Xi.length,Xi.ended),Xi.length===0&&Xi.ended?Ki(this):Ni(this),null;if(Ji=Ei(Ji,Xi),Ji===0&&Xi.ended)return Xi.length===0&&Ki(this),null;var jn=Xi.needReadable;hi("need readable",jn),(Xi.length===0||Xi.length-Ji<Xi.highWaterMark)&&(jn=!0,hi("length less than watermark",jn)),Xi.ended||Xi.reading?(jn=!1,hi("reading or ended",jn)):jn&&(hi("do read"),Xi.reading=!0,Xi.sync=!0,Xi.length===0&&(Xi.needReadable=!0),this._read(Xi.highWaterMark),Xi.sync=!1,Xi.reading||(Ji=Ei(on,Xi)));var Ln;return Ji>0?Ln=Vi(Ji,Xi):Ln=null,Ln===null?(Xi.needReadable=Xi.length<=Xi.highWaterMark,Ji=0):(Xi.length-=Ji,Xi.awaitDrain=0),Xi.length===0&&(Xi.ended||(Xi.needReadable=!0),on!==Ji&&Xi.ended&&Ki(this)),Ln!==null&&this.emit("data",Ln),Ln};function Ci(Ji,Xi){if(hi("onEofChunk"),!Xi.ended){if(Xi.decoder){var on=Xi.decoder.end();on&&on.length&&(Xi.buffer.push(on),Xi.length+=Xi.objectMode?1:on.length)}Xi.ended=!0,Xi.sync?Ni(Ji):(Xi.needReadable=!1,Xi.emittedReadable||(Xi.emittedReadable=!0,Fi(Ji)))}}function Ni(Ji){var Xi=Ji._readableState;hi("emitReadable",Xi.needReadable,Xi.emittedReadable),Xi.needReadable=!1,Xi.emittedReadable||(hi("emitReadable",Xi.flowing),Xi.emittedReadable=!0,process$1.nextTick(Fi,Ji))}function Fi(Ji){var Xi=Ji._readableState;hi("emitReadable_",Xi.destroyed,Xi.length,Xi.ended),!Xi.destroyed&&(Xi.length||Xi.ended)&&(Ji.emit("readable"),Xi.emittedReadable=!1),Xi.needReadable=!Xi.flowing&&!Xi.ended&&Xi.length<=Xi.highWaterMark,Gi(Ji)}function Mi(Ji,Xi){Xi.readingMore||(Xi.readingMore=!0,process$1.nextTick(Si,Ji,Xi))}function Si(Ji,Xi){for(;!Xi.reading&&!Xi.ended&&(Xi.length<Xi.highWaterMark||Xi.flowing&&Xi.length===0);){var on=Xi.length;if(hi("maybeReadMore read 0"),Ji.read(0),on===Xi.length)break}Xi.readingMore=!1}Ui.prototype._read=function(Ji){ki(this,new Ri("_read()"))},Ui.prototype.pipe=function(Ji,Xi){var on=this,jn=this._readableState;switch(jn.pipesCount){case 0:jn.pipes=Ji;break;case 1:jn.pipes=[jn.pipes,Ji];break;default:jn.pipes.push(Ji);break}jn.pipesCount+=1,hi("pipe count=%d opts=%j",jn.pipesCount,Xi);var Ln=(!Xi||Xi.end!==!1)&&Ji!==process$1.stdout&&Ji!==process$1.stderr,Hn=Ln?ia:ca;jn.endEmitted?process$1.nextTick(Hn):on.once("end",Hn),Ji.on("unpipe",ea);function ea(la,Fa){hi("onunpipe"),la===on&&Fa&&Fa.hasUnpiped===!1&&(Fa.hasUnpiped=!0,ta())}function ia(){hi("onend"),Ji.end()}var Wn=Ai(on);Ji.on("drain",Wn);var oa=!1;function ta(){hi("cleanup"),Ji.removeListener("close",ua),Ji.removeListener("finish",da),Ji.removeListener("drain",Wn),Ji.removeListener("error",sa),Ji.removeListener("unpipe",ea),on.removeListener("end",ia),on.removeListener("end",ca),on.removeListener("data",aa),oa=!0,jn.awaitDrain&&(!Ji._writableState||Ji._writableState.needDrain)&&Wn()}on.on("data",aa);function aa(la){hi("ondata");var Fa=Ji.write(la);hi("dest.write",Fa),Fa===!1&&((jn.pipesCount===1&&jn.pipes===Ji||jn.pipesCount>1&&In(jn.pipes,Ji)!==-1)&&!oa&&(hi("false write response, pause",jn.awaitDrain),jn.awaitDrain++),on.pause())}function sa(la){hi("onerror",la),ca(),Ji.removeListener("error",sa),t(Ji,"error")===0&&ki(Ji,la)}ji(Ji,"error",sa);function ua(){Ji.removeListener("finish",da),ca()}Ji.once("close",ua);function da(){hi("onfinish"),Ji.removeListener("close",ua),ca()}Ji.once("finish",da);function ca(){hi("unpipe"),on.unpipe(Ji)}return Ji.emit("pipe",on),jn.flowing||(hi("pipe resume"),on.resume()),Ji};function Ai(Ji){return function(){var on=Ji._readableState;hi("pipeOnDrain",on.awaitDrain),on.awaitDrain&&on.awaitDrain--,on.awaitDrain===0&&t(Ji,"data")&&(on.flowing=!0,Gi(Ji))}}Ui.prototype.unpipe=function(Ji){var Xi=this._readableState,on={hasUnpiped:!1};if(Xi.pipesCount===0)return this;if(Xi.pipesCount===1)return Ji&&Ji!==Xi.pipes?this:(Ji||(Ji=Xi.pipes),Xi.pipes=null,Xi.pipesCount=0,Xi.flowing=!1,Ji&&Ji.emit("unpipe",this,on),this);if(!Ji){var jn=Xi.pipes,Ln=Xi.pipesCount;Xi.pipes=null,Xi.pipesCount=0,Xi.flowing=!1;for(var Hn=0;Hn<Ln;Hn++)jn[Hn].emit("unpipe",this,{hasUnpiped:!1});return this}var ea=In(Xi.pipes,Ji);return ea===-1?this:(Xi.pipes.splice(ea,1),Xi.pipesCount-=1,Xi.pipesCount===1&&(Xi.pipes=Xi.pipes[0]),Ji.emit("unpipe",this,on),this)},Ui.prototype.on=function(Ji,Xi){var on=i.prototype.on.call(this,Ji,Xi),jn=this._readableState;return Ji==="data"?(jn.readableListening=this.listenerCount("readable")>0,jn.flowing!==!1&&this.resume()):Ji==="readable"&&!jn.endEmitted&&!jn.readableListening&&(jn.readableListening=jn.needReadable=!0,jn.flowing=!1,jn.emittedReadable=!1,hi("on readable",jn.length,jn.reading),jn.length?Ni(this):jn.reading||process$1.nextTick(Bi,this)),on},Ui.prototype.addListener=Ui.prototype.on,Ui.prototype.removeListener=function(Ji,Xi){var on=i.prototype.removeListener.call(this,Ji,Xi);return Ji==="readable"&&process$1.nextTick(_i,this),on},Ui.prototype.removeAllListeners=function(Ji){var Xi=i.prototype.removeAllListeners.apply(this,arguments);return(Ji==="readable"||Ji===void 0)&&process$1.nextTick(_i,this),Xi};function _i(Ji){var Xi=Ji._readableState;Xi.readableListening=Ji.listenerCount("readable")>0,Xi.resumeScheduled&&!Xi.paused?Xi.flowing=!0:Ji.listenerCount("data")>0&&Ji.resume()}function Bi(Ji){hi("readable nexttick read 0"),Ji.read(0)}Ui.prototype.resume=function(){var Ji=this._readableState;return Ji.flowing||(hi("resume"),Ji.flowing=!Ji.readableListening,Pi(this,Ji)),Ji.paused=!1,this};function Pi(Ji,Xi){Xi.resumeScheduled||(Xi.resumeScheduled=!0,process$1.nextTick(zi,Ji,Xi))}function zi(Ji,Xi){hi("resume",Xi.reading),Xi.reading||Ji.read(0),Xi.resumeScheduled=!1,Ji.emit("resume"),Gi(Ji),Xi.flowing&&!Xi.reading&&Ji.read(0)}Ui.prototype.pause=function(){return hi("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(hi("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function Gi(Ji){var Xi=Ji._readableState;for(hi("flow",Xi.flowing);Xi.flowing&&Ji.read()!==null;);}Ui.prototype.wrap=function(Ji){var Xi=this,on=this._readableState,jn=!1;Ji.on("end",function(){if(hi("wrapped end"),on.decoder&&!on.ended){var ea=on.decoder.end();ea&&ea.length&&Xi.push(ea)}Xi.push(null)}),Ji.on("data",function(ea){if(hi("wrapped data"),on.decoder&&(ea=on.decoder.write(ea)),!(on.objectMode&&ea==null)&&!(!on.objectMode&&(!ea||!ea.length))){var ia=Xi.push(ea);ia||(jn=!0,Ji.pause())}});for(var Ln in Ji)this[Ln]===void 0&&typeof Ji[Ln]=="function"&&(this[Ln]=function(ia){return function(){return Ji[ia].apply(Ji,arguments)}}(Ln));for(var Hn=0;Hn<Li.length;Hn++)Ji.on(Li[Hn],this.emit.bind(this,Li[Hn]));return this._read=function(ea){hi("wrapped _read",ea),jn&&(jn=!1,Ji.resume())},this},typeof Symbol=="function"&&(Ui.prototype[Symbol.asyncIterator]=function(){return qi===void 0&&(qi=requireAsync_iterator()),qi(this)}),Object.defineProperty(Ui.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(Ui.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(Ui.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(Xi){this._readableState&&(this._readableState.flowing=Xi)}}),Ui._fromList=Vi,Object.defineProperty(Ui.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}});function Vi(Ji,Xi){if(Xi.length===0)return null;var on;return Xi.objectMode?on=Xi.buffer.shift():!Ji||Ji>=Xi.length?(Xi.decoder?on=Xi.buffer.join(""):Xi.buffer.length===1?on=Xi.buffer.first():on=Xi.buffer.concat(Xi.length),Xi.buffer.clear()):on=Xi.buffer.consume(Ji,Xi.decoder),on}function Ki(Ji){var Xi=Ji._readableState;hi("endReadable",Xi.endEmitted),Xi.endEmitted||(Xi.ended=!0,process$1.nextTick(Zi,Xi,Ji))}function Zi(Ji,Xi){if(hi("endReadableNT",Ji.endEmitted,Ji.length),!Ji.endEmitted&&Ji.length===0&&(Ji.endEmitted=!0,Xi.readable=!1,Xi.emit("end"),Ji.autoDestroy)){var on=Xi._writableState;(!on||on.autoDestroy&&on.finished)&&Xi.destroy()}}typeof Symbol=="function"&&(Ui.from=function(Ji,Xi){return Oi===void 0&&(Oi=requireFromBrowser()),Oi(Ui,Ji,Xi)});function In(Ji,Xi){for(var on=0,jn=Ji.length;on<jn;on++)if(Ji[on]===Xi)return on;return-1}return _stream_readable$1}var _stream_transform$1,hasRequired_stream_transform$1;function require_stream_transform$1(){if(hasRequired_stream_transform$1)return _stream_transform$1;hasRequired_stream_transform$1=1,_stream_transform$1=v;var r=requireErrorsBrowser().codes,t=r.ERR_METHOD_NOT_IMPLEMENTED,i=r.ERR_MULTIPLE_CALLBACK,n=r.ERR_TRANSFORM_ALREADY_TRANSFORMING,s=r.ERR_TRANSFORM_WITH_LENGTH_0,a=require_stream_duplex$1();requireInherits_browser()(v,a);function h(l,vi){var D=this._transformState;D.transforming=!1;var mi=D.writecb;if(mi===null)return this.emit("error",new i);D.writechunk=null,D.writecb=null,vi!=null&&this.push(vi),mi(l);var gi=this._readableState;gi.reading=!1,(gi.needReadable||gi.length<gi.highWaterMark)&&this._read(gi.highWaterMark)}function v(l){if(!(this instanceof v))return new v(l);a.call(this,l),this._transformState={afterTransform:h.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,l&&(typeof l.transform=="function"&&(this._transform=l.transform),typeof l.flush=="function"&&(this._flush=l.flush)),this.on("prefinish",hi)}function hi(){var l=this;typeof this._flush=="function"&&!this._readableState.destroyed?this._flush(function(vi,D){u(l,vi,D)}):u(this,null,null)}v.prototype.push=function(l,vi){return this._transformState.needTransform=!1,a.prototype.push.call(this,l,vi)},v.prototype._transform=function(l,vi,D){D(new t("_transform()"))},v.prototype._write=function(l,vi,D){var mi=this._transformState;if(mi.writecb=D,mi.writechunk=l,mi.writeencoding=vi,!mi.transforming){var gi=this._readableState;(mi.needTransform||gi.needReadable||gi.length<gi.highWaterMark)&&this._read(gi.highWaterMark)}},v.prototype._read=function(l){var vi=this._transformState;vi.writechunk!==null&&!vi.transforming?(vi.transforming=!0,this._transform(vi.writechunk,vi.writeencoding,vi.afterTransform)):vi.needTransform=!0},v.prototype._destroy=function(l,vi){a.prototype._destroy.call(this,l,function(D){vi(D)})};function u(l,vi,D){if(vi)return l.emit("error",vi);if(D!=null&&l.push(D),l._writableState.length)throw new s;if(l._transformState.transforming)throw new n;return l.push(null)}return _stream_transform$1}var _stream_passthrough$1,hasRequired_stream_passthrough$1;function require_stream_passthrough$1(){if(hasRequired_stream_passthrough$1)return _stream_passthrough$1;hasRequired_stream_passthrough$1=1,_stream_passthrough$1=t;var r=require_stream_transform$1();requireInherits_browser()(t,r);function t(i){if(!(this instanceof t))return new t(i);r.call(this,i)}return t.prototype._transform=function(i,n,s){s(null,i)},_stream_passthrough$1}var pipeline_1,hasRequiredPipeline;function requirePipeline(){if(hasRequiredPipeline)return pipeline_1;hasRequiredPipeline=1;var r;function t(D){var mi=!1;return function(){mi||(mi=!0,D.apply(void 0,arguments))}}var i=requireErrorsBrowser().codes,n=i.ERR_MISSING_ARGS,s=i.ERR_STREAM_DESTROYED;function a(D){if(D)throw D}function h(D){return D.setHeader&&typeof D.abort=="function"}function v(D,mi,gi,bi){bi=t(bi);var Ri=!1;D.on("close",function(){Ri=!0}),r===void 0&&(r=requireEndOfStream()),r(D,{readable:mi,writable:gi},function(Ii){if(Ii)return bi(Ii);Ri=!0,bi()});var Ti=!1;return function(Ii){if(!Ri&&!Ti){if(Ti=!0,h(D))return D.abort();if(typeof D.destroy=="function")return D.destroy();bi(Ii||new s("pipe"))}}}function hi(D){D()}function u(D,mi){return D.pipe(mi)}function l(D){return!D.length||typeof D[D.length-1]!="function"?a:D.pop()}function vi(){for(var D=arguments.length,mi=new Array(D),gi=0;gi<D;gi++)mi[gi]=arguments[gi];var bi=l(mi);if(Array.isArray(mi[0])&&(mi=mi[0]),mi.length<2)throw new n("streams");var Ri,Ti=mi.map(function(Ii,qi){var Oi=qi<mi.length-1,ki=qi>0;return v(Ii,Oi,ki,function(Li){Ri||(Ri=Li),Li&&Ti.forEach(hi),!Oi&&(Ti.forEach(hi),bi(Ri))})});return mi.reduce(u)}return pipeline_1=vi,pipeline_1}var hasRequiredReadableBrowser$1;function requireReadableBrowser$1(){return hasRequiredReadableBrowser$1||(hasRequiredReadableBrowser$1=1,function(r,t){t=r.exports=require_stream_readable$1(),t.Stream=t,t.Readable=t,t.Writable=require_stream_writable$1(),t.Duplex=require_stream_duplex$1(),t.Transform=require_stream_transform$1(),t.PassThrough=require_stream_passthrough$1(),t.finished=requireEndOfStream(),t.pipeline=requirePipeline()}(readableBrowser$1,readableBrowser$1.exports)),readableBrowser$1.exports}var hashBase$2,hasRequiredHashBase$2;function requireHashBase$2(){if(hasRequiredHashBase$2)return hashBase$2;hasRequiredHashBase$2=1;var r=requireSafeBuffer$1().Buffer,t=requireReadableBrowser$1().Transform,i=requireInherits_browser();function n(a,h){if(!r.isBuffer(a)&&typeof a!="string")throw new TypeError(h+" must be a string or a buffer")}function s(a){t.call(this),this._block=r.allocUnsafe(a),this._blockSize=a,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}return i(s,t),s.prototype._transform=function(a,h,v){var hi=null;try{this.update(a,h)}catch(u){hi=u}v(hi)},s.prototype._flush=function(a){var h=null;try{this.push(this.digest())}catch(v){h=v}a(h)},s.prototype.update=function(a,h){if(n(a,"Data"),this._finalized)throw new Error("Digest already called");r.isBuffer(a)||(a=r.from(a,h));for(var v=this._block,hi=0;this._blockOffset+a.length-hi>=this._blockSize;){for(var u=this._blockOffset;u<this._blockSize;)v[u++]=a[hi++];this._update(),this._blockOffset=0}for(;hi<a.length;)v[this._blockOffset++]=a[hi++];for(var l=0,vi=a.length*8;vi>0;++l)this._length[l]+=vi,vi=this._length[l]/4294967296|0,vi>0&&(this._length[l]-=4294967296*vi);return this},s.prototype._update=function(){throw new Error("_update is not implemented")},s.prototype.digest=function(a){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var h=this._digest();a!==void 0&&(h=h.toString(a)),this._block.fill(0),this._blockOffset=0;for(var v=0;v<4;++v)this._length[v]=0;return h},s.prototype._digest=function(){throw new Error("_digest is not implemented")},hashBase$2=s,hashBase$2}var md5_js,hasRequiredMd5_js;function requireMd5_js(){if(hasRequiredMd5_js)return md5_js;hasRequiredMd5_js=1;var r=requireInherits_browser(),t=requireHashBase$2(),i=requireSafeBuffer$1().Buffer,n=new Array(16);function s(){t.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}r(s,t),s.prototype._update=function(){for(var l=n,vi=0;vi<16;++vi)l[vi]=this._block.readInt32LE(vi*4);var D=this._a,mi=this._b,gi=this._c,bi=this._d;D=h(D,mi,gi,bi,l[0],3614090360,7),bi=h(bi,D,mi,gi,l[1],3905402710,12),gi=h(gi,bi,D,mi,l[2],606105819,17),mi=h(mi,gi,bi,D,l[3],3250441966,22),D=h(D,mi,gi,bi,l[4],4118548399,7),bi=h(bi,D,mi,gi,l[5],1200080426,12),gi=h(gi,bi,D,mi,l[6],2821735955,17),mi=h(mi,gi,bi,D,l[7],4249261313,22),D=h(D,mi,gi,bi,l[8],1770035416,7),bi=h(bi,D,mi,gi,l[9],2336552879,12),gi=h(gi,bi,D,mi,l[10],4294925233,17),mi=h(mi,gi,bi,D,l[11],2304563134,22),D=h(D,mi,gi,bi,l[12],1804603682,7),bi=h(bi,D,mi,gi,l[13],4254626195,12),gi=h(gi,bi,D,mi,l[14],2792965006,17),mi=h(mi,gi,bi,D,l[15],1236535329,22),D=v(D,mi,gi,bi,l[1],4129170786,5),bi=v(bi,D,mi,gi,l[6],3225465664,9),gi=v(gi,bi,D,mi,l[11],643717713,14),mi=v(mi,gi,bi,D,l[0],3921069994,20),D=v(D,mi,gi,bi,l[5],3593408605,5),bi=v(bi,D,mi,gi,l[10],38016083,9),gi=v(gi,bi,D,mi,l[15],3634488961,14),mi=v(mi,gi,bi,D,l[4],3889429448,20),D=v(D,mi,gi,bi,l[9],568446438,5),bi=v(bi,D,mi,gi,l[14],3275163606,9),gi=v(gi,bi,D,mi,l[3],4107603335,14),mi=v(mi,gi,bi,D,l[8],1163531501,20),D=v(D,mi,gi,bi,l[13],2850285829,5),bi=v(bi,D,mi,gi,l[2],4243563512,9),gi=v(gi,bi,D,mi,l[7],1735328473,14),mi=v(mi,gi,bi,D,l[12],2368359562,20),D=hi(D,mi,gi,bi,l[5],4294588738,4),bi=hi(bi,D,mi,gi,l[8],2272392833,11),gi=hi(gi,bi,D,mi,l[11],1839030562,16),mi=hi(mi,gi,bi,D,l[14],4259657740,23),D=hi(D,mi,gi,bi,l[1],2763975236,4),bi=hi(bi,D,mi,gi,l[4],1272893353,11),gi=hi(gi,bi,D,mi,l[7],4139469664,16),mi=hi(mi,gi,bi,D,l[10],3200236656,23),D=hi(D,mi,gi,bi,l[13],681279174,4),bi=hi(bi,D,mi,gi,l[0],3936430074,11),gi=hi(gi,bi,D,mi,l[3],3572445317,16),mi=hi(mi,gi,bi,D,l[6],76029189,23),D=hi(D,mi,gi,bi,l[9],3654602809,4),bi=hi(bi,D,mi,gi,l[12],3873151461,11),gi=hi(gi,bi,D,mi,l[15],530742520,16),mi=hi(mi,gi,bi,D,l[2],3299628645,23),D=u(D,mi,gi,bi,l[0],4096336452,6),bi=u(bi,D,mi,gi,l[7],1126891415,10),gi=u(gi,bi,D,mi,l[14],2878612391,15),mi=u(mi,gi,bi,D,l[5],4237533241,21),D=u(D,mi,gi,bi,l[12],1700485571,6),bi=u(bi,D,mi,gi,l[3],2399980690,10),gi=u(gi,bi,D,mi,l[10],4293915773,15),mi=u(mi,gi,bi,D,l[1],2240044497,21),D=u(D,mi,gi,bi,l[8],1873313359,6),bi=u(bi,D,mi,gi,l[15],4264355552,10),gi=u(gi,bi,D,mi,l[6],2734768916,15),mi=u(mi,gi,bi,D,l[13],1309151649,21),D=u(D,mi,gi,bi,l[4],4149444226,6),bi=u(bi,D,mi,gi,l[11],3174756917,10),gi=u(gi,bi,D,mi,l[2],718787259,15),mi=u(mi,gi,bi,D,l[9],3951481745,21),this._a=this._a+D|0,this._b=this._b+mi|0,this._c=this._c+gi|0,this._d=this._d+bi|0},s.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var l=i.allocUnsafe(16);return l.writeInt32LE(this._a,0),l.writeInt32LE(this._b,4),l.writeInt32LE(this._c,8),l.writeInt32LE(this._d,12),l};function a(l,vi){return l<<vi|l>>>32-vi}function h(l,vi,D,mi,gi,bi,Ri){return a(l+(vi&D|~vi&mi)+gi+bi|0,Ri)+vi|0}function v(l,vi,D,mi,gi,bi,Ri){return a(l+(vi&mi|D&~mi)+gi+bi|0,Ri)+vi|0}function hi(l,vi,D,mi,gi,bi,Ri){return a(l+(vi^D^mi)+gi+bi|0,Ri)+vi|0}function u(l,vi,D,mi,gi,bi,Ri){return a(l+(D^(vi|~mi))+gi+bi|0,Ri)+vi|0}return md5_js=s,md5_js}requireMd5_js();function objectNameComparer(r,t){return r.name.localeCompare(t.name,"en",{sensitivity:"base"})}let nanoid=(r=21)=>crypto.getRandomValues(new Uint8Array(r)).reduce((t,i)=>(i&=63,i<36?t+=i.toString(36):i<62?t+=(i-26).toString(36).toUpperCase():i>62?t+="-":t+="_",t),"");const ID_PREFIX_SEPARATOR="|";function createId(r){return r&&r.length>0?`${r}${ID_PREFIX_SEPARATOR}${nanoid()}`:nanoid()}function now(){return Date.now()}var dayjs_min$1={exports:{}},dayjs_min=dayjs_min$1.exports,hasRequiredDayjs_min;function requireDayjs_min(){return hasRequiredDayjs_min||(hasRequiredDayjs_min=1,function(r,t){(function(i,n){r.exports=n()})(dayjs_min,function(){var i=1e3,n=6e4,s=36e5,a="millisecond",h="second",v="minute",hi="hour",u="day",l="week",vi="month",D="quarter",mi="year",gi="date",bi="Invalid Date",Ri=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,Ti=/\[([^\]]+)]|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,Ii={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(yi){var Ei=["th","st","nd","rd"],Ci=yi%100;return"["+yi+(Ei[(Ci-20)%10]||Ei[Ci]||Ei[0])+"]"}},qi=function(yi,Ei,Ci){var Ni=String(yi);return!Ni||Ni.length>=Ei?yi:""+Array(Ei+1-Ni.length).join(Ci)+yi},Oi={s:qi,z:function(yi){var Ei=-yi.utcOffset(),Ci=Math.abs(Ei),Ni=Math.floor(Ci/60),Fi=Ci%60;return(Ei<=0?"+":"-")+qi(Ni,2,"0")+":"+qi(Fi,2,"0")},m:function yi(Ei,Ci){if(Ei.date()<Ci.date())return-yi(Ci,Ei);var Ni=12*(Ci.year()-Ei.year())+(Ci.month()-Ei.month()),Fi=Ei.clone().add(Ni,vi),Mi=Ci-Fi<0,Si=Ei.clone().add(Ni+(Mi?-1:1),vi);return+(-(Ni+(Ci-Fi)/(Mi?Fi-Si:Si-Fi))||0)},a:function(yi){return yi<0?Math.ceil(yi)||0:Math.floor(yi)},p:function(yi){return{M:vi,y:mi,w:l,d:u,D:gi,h:hi,m:v,s:h,ms:a,Q:D}[yi]||String(yi||"").toLowerCase().replace(/s$/,"")},u:function(yi){return yi===void 0}},ki="en",Li={};Li[ki]=Ii;var ji="$isDayjsObject",Hi=function(yi){return yi instanceof wi||!(!yi||!yi[ji])},Ui=function yi(Ei,Ci,Ni){var Fi;if(!Ei)return ki;if(typeof Ei=="string"){var Mi=Ei.toLowerCase();Li[Mi]&&(Fi=Mi),Ci&&(Li[Mi]=Ci,Fi=Mi);var Si=Ei.split("-");if(!Fi&&Si.length>1)return yi(Si[0])}else{var Ai=Ei.name;Li[Ai]=Ei,Fi=Ai}return!Ni&&Fi&&(ki=Fi),Fi||!Ni&&ki},Qi=function(yi,Ei){if(Hi(yi))return yi.clone();var Ci=typeof Ei=="object"?Ei:{};return Ci.date=yi,Ci.args=arguments,new wi(Ci)},$i=Oi;$i.l=Ui,$i.i=Hi,$i.w=function(yi,Ei){return Qi(yi,{locale:Ei.$L,utc:Ei.$u,x:Ei.$x,$offset:Ei.$offset})};var wi=function(){function yi(Ci){this.$L=Ui(Ci.locale,null,!0),this.parse(Ci),this.$x=this.$x||Ci.x||{},this[ji]=!0}var Ei=yi.prototype;return Ei.parse=function(Ci){this.$d=function(Ni){var Fi=Ni.date,Mi=Ni.utc;if(Fi===null)return new Date(NaN);if($i.u(Fi))return new Date;if(Fi instanceof Date)return new Date(Fi);if(typeof Fi=="string"&&!/Z$/i.test(Fi)){var Si=Fi.match(Ri);if(Si){var Ai=Si[2]-1||0,_i=(Si[7]||"0").substring(0,3);return Mi?new Date(Date.UTC(Si[1],Ai,Si[3]||1,Si[4]||0,Si[5]||0,Si[6]||0,_i)):new Date(Si[1],Ai,Si[3]||1,Si[4]||0,Si[5]||0,Si[6]||0,_i)}}return new Date(Fi)}(Ci),this.init()},Ei.init=function(){var Ci=this.$d;this.$y=Ci.getFullYear(),this.$M=Ci.getMonth(),this.$D=Ci.getDate(),this.$W=Ci.getDay(),this.$H=Ci.getHours(),this.$m=Ci.getMinutes(),this.$s=Ci.getSeconds(),this.$ms=Ci.getMilliseconds()},Ei.$utils=function(){return $i},Ei.isValid=function(){return this.$d.toString()!==bi},Ei.isSame=function(Ci,Ni){var Fi=Qi(Ci);return this.startOf(Ni)<=Fi&&Fi<=this.endOf(Ni)},Ei.isAfter=function(Ci,Ni){return Qi(Ci)<this.startOf(Ni)},Ei.isBefore=function(Ci,Ni){return this.endOf(Ni)<Qi(Ci)},Ei.$g=function(Ci,Ni,Fi){return $i.u(Ci)?this[Ni]:this.set(Fi,Ci)},Ei.unix=function(){return Math.floor(this.valueOf()/1e3)},Ei.valueOf=function(){return this.$d.getTime()},Ei.startOf=function(Ci,Ni){var Fi=this,Mi=!!$i.u(Ni)||Ni,Si=$i.p(Ci),Ai=function(Zi,In){var Ji=$i.w(Fi.$u?Date.UTC(Fi.$y,In,Zi):new Date(Fi.$y,In,Zi),Fi);return Mi?Ji:Ji.endOf(u)},_i=function(Zi,In){return $i.w(Fi.toDate()[Zi].apply(Fi.toDate("s"),(Mi?[0,0,0,0]:[23,59,59,999]).slice(In)),Fi)},Bi=this.$W,Pi=this.$M,zi=this.$D,Gi="set"+(this.$u?"UTC":"");switch(Si){case mi:return Mi?Ai(1,0):Ai(31,11);case vi:return Mi?Ai(1,Pi):Ai(0,Pi+1);case l:var Vi=this.$locale().weekStart||0,Ki=(Bi<Vi?Bi+7:Bi)-Vi;return Ai(Mi?zi-Ki:zi+(6-Ki),Pi);case u:case gi:return _i(Gi+"Hours",0);case hi:return _i(Gi+"Minutes",1);case v:return _i(Gi+"Seconds",2);case h:return _i(Gi+"Milliseconds",3);default:return this.clone()}},Ei.endOf=function(Ci){return this.startOf(Ci,!1)},Ei.$set=function(Ci,Ni){var Fi,Mi=$i.p(Ci),Si="set"+(this.$u?"UTC":""),Ai=(Fi={},Fi[u]=Si+"Date",Fi[gi]=Si+"Date",Fi[vi]=Si+"Month",Fi[mi]=Si+"FullYear",Fi[hi]=Si+"Hours",Fi[v]=Si+"Minutes",Fi[h]=Si+"Seconds",Fi[a]=Si+"Milliseconds",Fi)[Mi],_i=Mi===u?this.$D+(Ni-this.$W):Ni;if(Mi===vi||Mi===mi){var Bi=this.clone().set(gi,1);Bi.$d[Ai](_i),Bi.init(),this.$d=Bi.set(gi,Math.min(this.$D,Bi.daysInMonth())).$d}else Ai&&this.$d[Ai](_i);return this.init(),this},Ei.set=function(Ci,Ni){return this.clone().$set(Ci,Ni)},Ei.get=function(Ci){return this[$i.p(Ci)]()},Ei.add=function(Ci,Ni){var Fi,Mi=this;Ci=Number(Ci);var Si=$i.p(Ni),Ai=function(Pi){var zi=Qi(Mi);return $i.w(zi.date(zi.date()+Math.round(Pi*Ci)),Mi)};if(Si===vi)return this.set(vi,this.$M+Ci);if(Si===mi)return this.set(mi,this.$y+Ci);if(Si===u)return Ai(1);if(Si===l)return Ai(7);var _i=(Fi={},Fi[v]=n,Fi[hi]=s,Fi[h]=i,Fi)[Si]||1,Bi=this.$d.getTime()+Ci*_i;return $i.w(Bi,this)},Ei.subtract=function(Ci,Ni){return this.add(-1*Ci,Ni)},Ei.format=function(Ci){var Ni=this,Fi=this.$locale();if(!this.isValid())return Fi.invalidDate||bi;var Mi=Ci||"YYYY-MM-DDTHH:mm:ssZ",Si=$i.z(this),Ai=this.$H,_i=this.$m,Bi=this.$M,Pi=Fi.weekdays,zi=Fi.months,Gi=Fi.meridiem,Vi=function(In,Ji,Xi,on){return In&&(In[Ji]||In(Ni,Mi))||Xi[Ji].slice(0,on)},Ki=function(In){return $i.s(Ai%12||12,In,"0")},Zi=Gi||function(In,Ji,Xi){var on=In<12?"AM":"PM";return Xi?on.toLowerCase():on};return Mi.replace(Ti,function(In,Ji){return Ji||function(Xi){switch(Xi){case"YY":return String(Ni.$y).slice(-2);case"YYYY":return $i.s(Ni.$y,4,"0");case"M":return Bi+1;case"MM":return $i.s(Bi+1,2,"0");case"MMM":return Vi(Fi.monthsShort,Bi,zi,3);case"MMMM":return Vi(zi,Bi);case"D":return Ni.$D;case"DD":return $i.s(Ni.$D,2,"0");case"d":return String(Ni.$W);case"dd":return Vi(Fi.weekdaysMin,Ni.$W,Pi,2);case"ddd":return Vi(Fi.weekdaysShort,Ni.$W,Pi,3);case"dddd":return Pi[Ni.$W];case"H":return String(Ai);case"HH":return $i.s(Ai,2,"0");case"h":return Ki(1);case"hh":return Ki(2);case"a":return Zi(Ai,_i,!0);case"A":return Zi(Ai,_i,!1);case"m":return String(_i);case"mm":return $i.s(_i,2,"0");case"s":return String(Ni.$s);case"ss":return $i.s(Ni.$s,2,"0");case"SSS":return $i.s(Ni.$ms,3,"0");case"Z":return Si}return null}(In)||Si.replace(":","")})},Ei.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},Ei.diff=function(Ci,Ni,Fi){var Mi,Si=this,Ai=$i.p(Ni),_i=Qi(Ci),Bi=(_i.utcOffset()-this.utcOffset())*n,Pi=this-_i,zi=function(){return $i.m(Si,_i)};switch(Ai){case mi:Mi=zi()/12;break;case vi:Mi=zi();break;case D:Mi=zi()/3;break;case l:Mi=(Pi-Bi)/6048e5;break;case u:Mi=(Pi-Bi)/864e5;break;case hi:Mi=Pi/s;break;case v:Mi=Pi/n;break;case h:Mi=Pi/i;break;default:Mi=Pi}return Fi?Mi:$i.a(Mi)},Ei.daysInMonth=function(){return this.endOf(vi).$D},Ei.$locale=function(){return Li[this.$L]},Ei.locale=function(Ci,Ni){if(!Ci)return this.$L;var Fi=this.clone(),Mi=Ui(Ci,Ni,!0);return Mi&&(Fi.$L=Mi),Fi},Ei.clone=function(){return $i.w(this.$d,this)},Ei.toDate=function(){return new Date(this.valueOf())},Ei.toJSON=function(){return this.isValid()?this.toISOString():null},Ei.toISOString=function(){return this.$d.toISOString()},Ei.toString=function(){return this.$d.toUTCString()},yi}(),xi=wi.prototype;return Qi.prototype=xi,[["$ms",a],["$s",h],["$m",v],["$H",hi],["$W",u],["$M",vi],["$y",mi],["$D",gi]].forEach(function(yi){xi[yi[1]]=function(Ei){return this.$g(Ei,yi[0],yi[1])}}),Qi.extend=function(yi,Ei){return yi.$i||(yi(Ei,wi,Qi),yi.$i=!0),Qi},Qi.locale=Ui,Qi.isDayjs=Hi,Qi.unix=function(yi){return Qi(1e3*yi)},Qi.en=Li[ki],Qi.Ls=Li,Qi.p={},Qi})}(dayjs_min$1)),dayjs_min$1.exports}requireDayjs_min();var RelativeDateTimeRange=(r=>(r[r.today=0]="today",r[r.last15Minutes=900]="last15Minutes",r[r.last30Minutes=1800]="last30Minutes",r[r.lastHour=3600]="lastHour",r[r.last2Hours=7200]="last2Hours",r[r.last6Hours=21600]="last6Hours",r[r.last12Hours=43200]="last12Hours",r[r.last24Hours=86400]="last24Hours",r[r.last2Days=172800]="last2Days",r[r.last7Days=604800]="last7Days",r[r.last60Days=5184e3]="last60Days",r))(RelativeDateTimeRange||{});const isAsyncIterable$1=r=>isFunction(Object(r)[Symbol.asyncIterator]);function isDictionary(r){return r!==null&&typeof r=="object"&&!Array.isArray(r)}function isFunction(r){return typeof r=="function"}function harmonizeSchemaUrl(r){return r.replace(/\/(?=\?)|\/(?=#)|\/$/,"")}class LRUMap extends Map{#e=10;#t;constructor(t){super(),t?.maxSize&&t.maxSize>0&&(this.#e=t.maxSize),this.#t=t?.cleanupItem}get(t){if(!super.has(t))return;const i=super.get(t);return i!==void 0&&(super.delete(t),super.set(t,i)),i}set(t,i){if(this.size>=this.#e){const n=this.entries().next().value;this.delete(n[0]),this.#t?.(n[1])}return super.set(t,i)}}/*!
16
+ * is-primitive <https://github.com/jonschlinkert/is-primitive>
17
+ *
18
+ * Copyright (c) 2014-present, Jon Schlinkert.
19
+ * Released under the MIT License.
20
+ */var isPrimitive,hasRequiredIsPrimitive;function requireIsPrimitive(){return hasRequiredIsPrimitive||(hasRequiredIsPrimitive=1,isPrimitive=function(t){return typeof t=="object"?t===null:typeof t!="function"}),isPrimitive}/*!
21
+ * isobject <https://github.com/jonschlinkert/isobject>
22
+ *
23
+ * Copyright (c) 2014-2017, Jon Schlinkert.
24
+ * Released under the MIT License.
25
+ */var isobject,hasRequiredIsobject;function requireIsobject(){return hasRequiredIsobject||(hasRequiredIsobject=1,isobject=function(t){return t!=null&&typeof t=="object"&&Array.isArray(t)===!1}),isobject}/*!
26
+ * is-plain-object <https://github.com/jonschlinkert/is-plain-object>
27
+ *
28
+ * Copyright (c) 2014-2017, Jon Schlinkert.
29
+ * Released under the MIT License.
30
+ */var isPlainObject,hasRequiredIsPlainObject;function requireIsPlainObject(){if(hasRequiredIsPlainObject)return isPlainObject;hasRequiredIsPlainObject=1;var r=requireIsobject();function t(i){return r(i)===!0&&Object.prototype.toString.call(i)==="[object Object]"}return isPlainObject=function(n){var s,a;return!(t(n)===!1||(s=n.constructor,typeof s!="function")||(a=s.prototype,t(a)===!1)||a.hasOwnProperty("isPrototypeOf")===!1)},isPlainObject}/*!
31
+ * set-value <https://github.com/jonschlinkert/set-value>
32
+ *
33
+ * Copyright (c) Jon Schlinkert (https://github.com/jonschlinkert).
34
+ * Released under the MIT License.
35
+ */var setValue_1,hasRequiredSetValue;function requireSetValue(){if(hasRequiredSetValue)return setValue_1;hasRequiredSetValue=1;const{deleteProperty:r}=Reflect,t=requireIsPrimitive(),i=requireIsPlainObject(),n=mi=>typeof mi=="object"&&mi!==null||typeof mi=="function",s=mi=>mi==="__proto__"||mi==="constructor"||mi==="prototype",a=mi=>{if(!t(mi))throw new TypeError("Object keys must be strings or symbols");if(s(mi))throw new Error(`Cannot set unsafe key: "${mi}"`)},h=mi=>Array.isArray(mi)?mi.flat().map(String).join(","):mi,v=(mi,gi)=>{if(typeof mi!="string"||!gi)return mi;let bi=mi+";";return gi.arrays!==void 0&&(bi+=`arrays=${gi.arrays};`),gi.separator!==void 0&&(bi+=`separator=${gi.separator};`),gi.split!==void 0&&(bi+=`split=${gi.split};`),gi.merge!==void 0&&(bi+=`merge=${gi.merge};`),gi.preservePaths!==void 0&&(bi+=`preservePaths=${gi.preservePaths};`),bi},hi=(mi,gi,bi)=>{const Ri=h(gi?v(mi,gi):mi);a(Ri);const Ti=D.cache.get(Ri)||bi();return D.cache.set(Ri,Ti),Ti},u=(mi,gi={})=>{const bi=gi.separator||".",Ri=bi==="/"?!1:gi.preservePaths;if(typeof mi=="string"&&Ri!==!1&&/\//.test(mi))return[mi];const Ti=[];let Ii="";const qi=Oi=>{let ki;Oi.trim()!==""&&Number.isInteger(ki=Number(Oi))?Ti.push(ki):Ti.push(Oi)};for(let Oi=0;Oi<mi.length;Oi++){const ki=mi[Oi];if(ki==="\\"){Ii+=mi[++Oi];continue}if(ki===bi){qi(Ii),Ii="";continue}Ii+=ki}return Ii&&qi(Ii),Ti},l=(mi,gi)=>gi&&typeof gi.split=="function"?gi.split(mi):typeof mi=="symbol"?[mi]:Array.isArray(mi)?mi:hi(mi,gi,()=>u(mi,gi)),vi=(mi,gi,bi,Ri)=>{if(a(gi),bi===void 0)r(mi,gi);else if(Ri&&Ri.merge){const Ti=Ri.merge==="function"?Ri.merge:Object.assign;Ti&&i(mi[gi])&&i(bi)?mi[gi]=Ti(mi[gi],bi):mi[gi]=bi}else mi[gi]=bi;return mi},D=(mi,gi,bi,Ri)=>{if(!gi||!n(mi))return mi;const Ti=l(gi,Ri);let Ii=mi;for(let qi=0;qi<Ti.length;qi++){const Oi=Ti[qi],ki=Ti[qi+1];if(a(Oi),ki===void 0){vi(Ii,Oi,bi,Ri);break}if(typeof ki=="number"&&!Array.isArray(Ii[Oi])){Ii=Ii[Oi]=[];continue}n(Ii[Oi])||(Ii[Oi]={}),Ii=Ii[Oi]}return mi};return D.split=l,D.cache=new Map,D.clear=()=>{D.cache=new Map},setValue_1=D,setValue_1}requireSetValue();function isURL(r){return HTTP_SCHEME_PATTERN.test(r)}var tt$1=Object.defineProperty,Ne$1=(r,t)=>{for(var i in t)tt$1(r,i,{get:t[i],enumerable:!0})},Te$1={};Ne$1(Te$1,{languages:()=>Pe$1,options:()=>we$1,parsers:()=>Ee$1,printers:()=>sn});var nt$1=(r,t,i,n)=>{if(!(r&&t==null))return t.replaceAll?t.replaceAll(i,n):i.global?t.replace(i,n):t.split(i).join(n)},Y$1=nt$1,re$1="indent",se$1="group",oe$1="if-break",P$1="line",ae$1="break-parent",xe$1=()=>{},ce$1=xe$1;function x$1(r){return{type:re$1,contents:r}}function y$1(r,t={}){return ce$1(t.expandedStates),{type:se$1,id:t.id,contents:r,break:!!t.shouldBreak,expandedStates:t.expandedStates}}function O$1(r,t="",i={}){return{type:oe$1,breakContents:r,flatContents:t,groupId:i.groupId}}var mt$1={type:ae$1},Et$1={type:P$1,hard:!0},k={type:P$1},p={type:P$1,soft:!0},f=[Et$1,mt$1];function E(r,t){let i=[];for(let n=0;n<t.length;n++)n!==0&&i.push(r),i.push(t[n]);return i}function j$1(r){return(t,i,n)=>{let s=!!(n!=null&&n.backwards);if(i===!1)return!1;let{length:a}=t,h=i;for(;h>=0&&h<a;){let v=t.charAt(h);if(r instanceof RegExp){if(!r.test(v))return h}else if(!r.includes(v))return h;s?h--:h++}return h===-1||h===a?h:!1}}var G$1=j$1(" "),_e$1=j$1(",; "),ye=j$1(/[^\n\r]/u);function Tt$1(r,t,i){let n=!!(i!=null&&i.backwards);if(t===!1)return!1;let s=r.charAt(t);if(n){if(r.charAt(t-1)==="\r"&&s===`
36
+ `)return t-2;if(s===`
37
+ `||s==="\r"||s==="\u2028"||s==="\u2029")return t-1}else{if(s==="\r"&&r.charAt(t+1)===`
38
+ `)return t+2;if(s===`
39
+ `||s==="\r"||s==="\u2028"||s==="\u2029")return t+1}return t}var $=Tt$1;function Nt$1(r,t,i={}){let n=G$1(r,i.backwards?t-1:t,i),s=$(r,n,i);return n!==s}var Ie$1=Nt$1;function xt$1(r,t){if(t===!1)return!1;if(r.charAt(t)==="/"&&r.charAt(t+1)==="*"){for(let i=t+2;i<r.length;++i)if(r.charAt(i)==="*"&&r.charAt(i+1)==="/")return i+2}return t}var Oe$1=xt$1;function _t$1(r,t){return t===!1?!1:r.charAt(t)==="/"&&r.charAt(t+1)==="/"?ye(r,t):t}var De$1=_t$1;function yt(r,t){let i=null,n=t;for(;n!==i;)i=n,n=_e$1(r,n),n=Oe$1(r,n),n=G$1(r,n);return n=De$1(r,n),n=$(r,n),n!==!1&&Ie$1(r,n)}var Ae$1=yt;function It$1(r){return Array.isArray(r)&&r.length>0}var ue$1=It$1,le$1=class extends Error{name="UnexpectedNodeError";constructor(t,i,n="type"){super(`Unexpected ${i} node ${n}: ${JSON.stringify(t[n])}.`),this.node=t}},ge$1=le$1,F=null;function w(r){if(F!==null&&typeof F.property){let t=F;return F=w.prototype=null,t}return F=w.prototype=r??Object.create(null),new w}var Ot$1=10;for(let r=0;r<=Ot$1;r++)w();function pe$1(r){return w(r)}function Dt$1(r,t="type"){pe$1(r);function i(n){let s=n[t],a=r[s];if(!Array.isArray(a))throw Object.assign(new Error(`Missing visitor keys for '${s}'.`),{node:n});return a}return i}var ke$1=Dt$1,J$1=class{constructor(t,i,n){this.start=t.start,this.end=i.end,this.startToken=t,this.endToken=i,this.source=n}get[Symbol.toStringTag](){return"Location"}toJSON(){return{start:this.start,end:this.end}}},V$1=class{constructor(t,i,n,s,a,h){this.kind=t,this.start=i,this.end=n,this.line=s,this.column=a,this.value=h,this.prev=null,this.next=null}get[Symbol.toStringTag](){return"Token"}toJSON(){return{kind:this.kind,value:this.value,line:this.line,column:this.column}}},X$1={Name:[],Document:["definitions"],OperationDefinition:["name","variableDefinitions","directives","selectionSet"],VariableDefinition:["variable","type","defaultValue","directives"],Variable:["name"],SelectionSet:["selections"],Field:["alias","name","arguments","directives","selectionSet"],Argument:["name","value"],FragmentSpread:["name","directives"],InlineFragment:["typeCondition","directives","selectionSet"],FragmentDefinition:["name","variableDefinitions","typeCondition","directives","selectionSet"],IntValue:[],FloatValue:[],StringValue:[],BooleanValue:[],NullValue:[],EnumValue:[],ListValue:["values"],ObjectValue:["fields"],ObjectField:["name","value"],Directive:["name","arguments"],NamedType:["name"],ListType:["type"],NonNullType:["type"],SchemaDefinition:["description","directives","operationTypes"],OperationTypeDefinition:["type"],ScalarTypeDefinition:["description","name","directives"],ObjectTypeDefinition:["description","name","interfaces","directives","fields"],FieldDefinition:["description","name","arguments","type","directives"],InputValueDefinition:["description","name","type","defaultValue","directives"],InterfaceTypeDefinition:["description","name","interfaces","directives","fields"],UnionTypeDefinition:["description","name","directives","types"],EnumTypeDefinition:["description","name","directives","values"],EnumValueDefinition:["description","name","directives"],InputObjectTypeDefinition:["description","name","directives","fields"],DirectiveDefinition:["description","name","arguments","locations"],SchemaExtension:["directives","operationTypes"],ScalarTypeExtension:["name","directives"],ObjectTypeExtension:["name","interfaces","directives","fields"],InterfaceTypeExtension:["name","interfaces","directives","fields"],UnionTypeExtension:["name","directives","types"],EnumTypeExtension:["name","directives","values"],InputObjectTypeExtension:["name","directives","fields"]};new Set(Object.keys(X$1));var S$1;(function(r){r.QUERY="query",r.MUTATION="mutation",r.SUBSCRIPTION="subscription"})(S$1||(S$1={}));var At$1=ke$1(X$1,"kind"),Se$1=At$1;function q$1(r){return r.loc.start}function Q$1(r){return r.loc.end}function Ce$1(r){return/^\s*#[^\S\n]*@(?:format|prettier)\s*(?:\n|$)/u.test(r)}function ve$1(r){return`# @format
40
+
41
+ `+r}function gt$1(r,t,i){let{node:n}=r;if(!n.description)return"";let s=[i("description")];return n.kind==="InputValueDefinition"&&!n.description.block?s.push(k):s.push(f),s}var A=gt$1;function kt$1(r,t,i){let{node:n}=r;switch(n.kind){case"Document":return[...E(f,g(r,t,i,"definitions")),f];case"OperationDefinition":{let s=t.originalText[q$1(n)]!=="{",a=!!n.name;return[s?n.operation:"",s&&a?[" ",i("name")]:"",s&&!a&&ue$1(n.variableDefinitions)?" ":"",be$1(r,i),_$1(r,i,n),!s&&!a?"":" ",i("selectionSet")]}case"FragmentDefinition":return["fragment ",i("name"),be$1(r,i)," on ",i("typeCondition"),_$1(r,i,n)," ",i("selectionSet")];case"SelectionSet":return["{",x$1([f,E(f,g(r,t,i,"selections"))]),f,"}"];case"Field":return y$1([n.alias?[i("alias"),": "]:"",i("name"),n.arguments.length>0?y$1(["(",x$1([p,E([O$1("",", "),p],g(r,t,i,"arguments"))]),p,")"]):"",_$1(r,i,n),n.selectionSet?" ":"",i("selectionSet")]);case"Name":return n.value;case"StringValue":if(n.block){let s=Y$1(!1,n.value,'"""',String.raw`\"""`).split(`
42
+ `);return s.length===1&&(s[0]=s[0].trim()),s.every(a=>a==="")&&(s.length=0),E(f,['"""',...s,'"""'])}return['"',Y$1(!1,Y$1(!1,n.value,/["\\]/gu,String.raw`\$&`),`
43
+ `,String.raw`\n`),'"'];case"IntValue":case"FloatValue":case"EnumValue":return n.value;case"BooleanValue":return n.value?"true":"false";case"NullValue":return"null";case"Variable":return["$",i("name")];case"ListValue":return y$1(["[",x$1([p,E([O$1("",", "),p],r.map(i,"values"))]),p,"]"]);case"ObjectValue":{let s=t.bracketSpacing&&n.fields.length>0?" ":"";return y$1(["{",s,x$1([p,E([O$1("",", "),p],r.map(i,"fields"))]),p,O$1("",s),"}"])}case"ObjectField":case"Argument":return[i("name"),": ",i("value")];case"Directive":return["@",i("name"),n.arguments.length>0?y$1(["(",x$1([p,E([O$1("",", "),p],g(r,t,i,"arguments"))]),p,")"]):""];case"NamedType":return i("name");case"VariableDefinition":return[i("variable"),": ",i("type"),n.defaultValue?[" = ",i("defaultValue")]:"",_$1(r,i,n)];case"ObjectTypeExtension":case"ObjectTypeDefinition":case"InputObjectTypeExtension":case"InputObjectTypeDefinition":case"InterfaceTypeExtension":case"InterfaceTypeDefinition":{let{kind:s}=n,a=[];return s.endsWith("TypeDefinition")?a.push(A(r,t,i)):a.push("extend "),s.startsWith("ObjectType")?a.push("type"):s.startsWith("InputObjectType")?a.push("input"):a.push("interface"),a.push(" ",i("name")),!s.startsWith("InputObjectType")&&n.interfaces.length>0&&a.push(" implements ",...vt$1(r,t,i)),a.push(_$1(r,i,n)),n.fields.length>0&&a.push([" {",x$1([f,E(f,g(r,t,i,"fields"))]),f,"}"]),a}case"FieldDefinition":return[A(r,t,i),i("name"),n.arguments.length>0?y$1(["(",x$1([p,E([O$1("",", "),p],g(r,t,i,"arguments"))]),p,")"]):"",": ",i("type"),_$1(r,i,n)];case"DirectiveDefinition":return[A(r,t,i),"directive ","@",i("name"),n.arguments.length>0?y$1(["(",x$1([p,E([O$1("",", "),p],g(r,t,i,"arguments"))]),p,")"]):"",n.repeatable?" repeatable":""," on ",...E(" | ",r.map(i,"locations"))];case"EnumTypeExtension":case"EnumTypeDefinition":return[A(r,t,i),n.kind==="EnumTypeExtension"?"extend ":"","enum ",i("name"),_$1(r,i,n),n.values.length>0?[" {",x$1([f,E(f,g(r,t,i,"values"))]),f,"}"]:""];case"EnumValueDefinition":return[A(r,t,i),i("name"),_$1(r,i,n)];case"InputValueDefinition":return[A(r,t,i),i("name"),": ",i("type"),n.defaultValue?[" = ",i("defaultValue")]:"",_$1(r,i,n)];case"SchemaExtension":return["extend schema",_$1(r,i,n),...n.operationTypes.length>0?[" {",x$1([f,E(f,g(r,t,i,"operationTypes"))]),f,"}"]:[]];case"SchemaDefinition":return[A(r,t,i),"schema",_$1(r,i,n)," {",n.operationTypes.length>0?x$1([f,E(f,g(r,t,i,"operationTypes"))]):"",f,"}"];case"OperationTypeDefinition":return[n.operation,": ",i("type")];case"FragmentSpread":return["...",i("name"),_$1(r,i,n)];case"InlineFragment":return["...",n.typeCondition?[" on ",i("typeCondition")]:"",_$1(r,i,n)," ",i("selectionSet")];case"UnionTypeExtension":case"UnionTypeDefinition":return y$1([A(r,t,i),y$1([n.kind==="UnionTypeExtension"?"extend ":"","union ",i("name"),_$1(r,i,n),n.types.length>0?[" =",O$1(""," "),x$1([O$1([k,"| "]),E([k,"| "],r.map(i,"types"))])]:""])]);case"ScalarTypeExtension":case"ScalarTypeDefinition":return[A(r,t,i),n.kind==="ScalarTypeExtension"?"extend ":"","scalar ",i("name"),_$1(r,i,n)];case"NonNullType":return[i("type"),"!"];case"ListType":return["[",i("type"),"]"];default:throw new ge$1(n,"Graphql","kind")}}function _$1(r,t,i){if(i.directives.length===0)return"";let n=E(k,r.map(t,"directives"));return i.kind==="FragmentDefinition"||i.kind==="OperationDefinition"?y$1([k,n]):[" ",y$1(x$1([p,n]))]}function g(r,t,i,n){return r.map(({isLast:s,node:a})=>{let h=i();return!s&&Ae$1(t.originalText,Q$1(a))?[h,f]:h},n)}function St$1(r){return r.kind!=="Comment"}function Ct(r){let t=r.node;if(t.kind==="Comment")return"#"+t.value.trimEnd();throw new Error("Not a comment: "+JSON.stringify(t))}function vt$1(r,t,i){let{node:n}=r,s=[],{interfaces:a}=n,h=r.map(i,"interfaces");for(let v=0;v<a.length;v++){let hi=a[v];s.push(h[v]);let u=a[v+1];if(u){let l=t.originalText.slice(hi.loc.end,u.loc.start).includes("#");s.push(" &",l?k:" ")}}return s}function be$1(r,t){let{node:i}=r;return ue$1(i.variableDefinitions)?y$1(["(",x$1([p,E([O$1("",", "),p],r.map(t,"variableDefinitions"))]),p,")"]):""}function Le$1(r,t){r.kind==="StringValue"&&r.block&&!r.value.includes(`
44
+ `)&&(t.value=r.value.trim())}Le$1.ignoredProperties=new Set(["loc","comments"]);function bt$1(r){var t;let{node:i}=r;return(t=i?.comments)==null?void 0:t.some(n=>n.value.trim()==="prettier-ignore")}var Lt$1={print:kt$1,massageAstNode:Le$1,hasPrettierIgnore:bt$1,insertPragma:ve$1,printComment:Ct,canAttachComment:St$1,getVisitorKeys:Se$1},Re$1=Lt$1,Pe$1=[{linguistLanguageId:139,name:"GraphQL",type:"data",color:"#e10098",extensions:[".graphql",".gql",".graphqls"],tmScope:"source.graphql",aceMode:"text",parsers:["graphql"],vscodeLanguageIds:["graphql"]}],Fe$1={bracketSpacing:{category:"Common",type:"boolean",default:!0,description:"Print spaces between brackets.",oppositeDescription:"Do not print spaces between brackets."}},Rt$1={bracketSpacing:Fe$1.bracketSpacing},we$1=Rt$1,Ee$1={};Ne$1(Ee$1,{graphql:()=>rn$1});function Ve$1(r){return typeof r=="object"&&r!==null}function Be$1(r,t){throw new Error("Unexpected invariant triggered.")}var Pt$1=/\r\n|[\n\r]/g;function B$1(r,t){let i=0,n=1;for(let s of r.body.matchAll(Pt$1)){if(typeof s.index=="number"||Be$1(),s.index>=t)break;i=s.index+s[0].length,n+=1}return{line:n,column:t+1-i}}function Me$1(r){return fe$1(r.source,B$1(r.source,r.start))}function fe$1(r,t){let i=r.locationOffset.column-1,n="".padStart(i)+r.body,s=t.line-1,a=r.locationOffset.line-1,h=t.line+a,v=t.line===1?i:0,hi=t.column+v,u=`${r.name}:${h}:${hi}
45
+ `,l=n.split(/\r\n|[\n\r]/g),vi=l[s];if(vi.length>120){let D=Math.floor(hi/80),mi=hi%80,gi=[];for(let bi=0;bi<vi.length;bi+=80)gi.push(vi.slice(bi,bi+80));return u+Ue$1([[`${h} |`,gi[0]],...gi.slice(1,D+1).map(bi=>["|",bi]),["|","^".padStart(mi)],["|",gi[D+1]]])}return u+Ue$1([[`${h-1} |`,l[s-1]],[`${h} |`,vi],["|","^".padStart(hi)],[`${h+1} |`,l[s+1]]])}function Ue$1(r){let t=r.filter(([n,s])=>s!==void 0),i=Math.max(...t.map(([n])=>n.length));return t.map(([n,s])=>n.padStart(i)+(s?" "+s:"")).join(`
46
+ `)}function Ft$1(r){let t=r[0];return t==null||"kind"in t||"length"in t?{nodes:t,source:r[1],positions:r[2],path:r[3],originalError:r[4],extensions:r[5]}:t}var W$1=class No extends Error{constructor(t,...i){var n,s,a;let{nodes:h,source:v,positions:hi,path:u,originalError:l,extensions:vi}=Ft$1(i);super(t),this.name="GraphQLError",this.path=u??void 0,this.originalError=l??void 0,this.nodes=Ye$1(Array.isArray(h)?h:h?[h]:void 0);let D=Ye$1((n=this.nodes)===null||n===void 0?void 0:n.map(gi=>gi.loc).filter(gi=>gi!=null));this.source=v??(D==null||(s=D[0])===null||s===void 0?void 0:s.source),this.positions=hi??D?.map(gi=>gi.start),this.locations=hi&&v?hi.map(gi=>B$1(v,gi)):D?.map(gi=>B$1(gi.source,gi.start));let mi=Ve$1(l?.extensions)?l?.extensions:void 0;this.extensions=(a=vi??mi)!==null&&a!==void 0?a:Object.create(null),Object.defineProperties(this,{message:{writable:!0,enumerable:!0},name:{enumerable:!1},nodes:{enumerable:!1},source:{enumerable:!1},positions:{enumerable:!1},originalError:{enumerable:!1}}),l!=null&&l.stack?Object.defineProperty(this,"stack",{value:l.stack,writable:!0,configurable:!0}):Error.captureStackTrace?Error.captureStackTrace(this,No):Object.defineProperty(this,"stack",{value:Error().stack,writable:!0,configurable:!0})}get[Symbol.toStringTag](){return"GraphQLError"}toString(){let t=this.message;if(this.nodes)for(let i of this.nodes)i.loc&&(t+=`
47
+
48
+ `+Me$1(i.loc));else if(this.source&&this.locations)for(let i of this.locations)t+=`
49
+
50
+ `+fe$1(this.source,i);return t}toJSON(){let t={message:this.message};return this.locations!=null&&(t.locations=this.locations),this.path!=null&&(t.path=this.path),this.extensions!=null&&Object.keys(this.extensions).length>0&&(t.extensions=this.extensions),t}};function Ye$1(r){return r===void 0||r.length===0?void 0:r}function d(r,t,i){return new W$1(`Syntax Error: ${i}`,{source:r,positions:[t]})}var H$1;(function(r){r.QUERY="QUERY",r.MUTATION="MUTATION",r.SUBSCRIPTION="SUBSCRIPTION",r.FIELD="FIELD",r.FRAGMENT_DEFINITION="FRAGMENT_DEFINITION",r.FRAGMENT_SPREAD="FRAGMENT_SPREAD",r.INLINE_FRAGMENT="INLINE_FRAGMENT",r.VARIABLE_DEFINITION="VARIABLE_DEFINITION",r.SCHEMA="SCHEMA",r.SCALAR="SCALAR",r.OBJECT="OBJECT",r.FIELD_DEFINITION="FIELD_DEFINITION",r.ARGUMENT_DEFINITION="ARGUMENT_DEFINITION",r.INTERFACE="INTERFACE",r.UNION="UNION",r.ENUM="ENUM",r.ENUM_VALUE="ENUM_VALUE",r.INPUT_OBJECT="INPUT_OBJECT",r.INPUT_FIELD_DEFINITION="INPUT_FIELD_DEFINITION"})(H$1||(H$1={}));var c;(function(r){r.NAME="Name",r.DOCUMENT="Document",r.OPERATION_DEFINITION="OperationDefinition",r.VARIABLE_DEFINITION="VariableDefinition",r.SELECTION_SET="SelectionSet",r.FIELD="Field",r.ARGUMENT="Argument",r.FRAGMENT_SPREAD="FragmentSpread",r.INLINE_FRAGMENT="InlineFragment",r.FRAGMENT_DEFINITION="FragmentDefinition",r.VARIABLE="Variable",r.INT="IntValue",r.FLOAT="FloatValue",r.STRING="StringValue",r.BOOLEAN="BooleanValue",r.NULL="NullValue",r.ENUM="EnumValue",r.LIST="ListValue",r.OBJECT="ObjectValue",r.OBJECT_FIELD="ObjectField",r.DIRECTIVE="Directive",r.NAMED_TYPE="NamedType",r.LIST_TYPE="ListType",r.NON_NULL_TYPE="NonNullType",r.SCHEMA_DEFINITION="SchemaDefinition",r.OPERATION_TYPE_DEFINITION="OperationTypeDefinition",r.SCALAR_TYPE_DEFINITION="ScalarTypeDefinition",r.OBJECT_TYPE_DEFINITION="ObjectTypeDefinition",r.FIELD_DEFINITION="FieldDefinition",r.INPUT_VALUE_DEFINITION="InputValueDefinition",r.INTERFACE_TYPE_DEFINITION="InterfaceTypeDefinition",r.UNION_TYPE_DEFINITION="UnionTypeDefinition",r.ENUM_TYPE_DEFINITION="EnumTypeDefinition",r.ENUM_VALUE_DEFINITION="EnumValueDefinition",r.INPUT_OBJECT_TYPE_DEFINITION="InputObjectTypeDefinition",r.DIRECTIVE_DEFINITION="DirectiveDefinition",r.SCHEMA_EXTENSION="SchemaExtension",r.SCALAR_TYPE_EXTENSION="ScalarTypeExtension",r.OBJECT_TYPE_EXTENSION="ObjectTypeExtension",r.INTERFACE_TYPE_EXTENSION="InterfaceTypeExtension",r.UNION_TYPE_EXTENSION="UnionTypeExtension",r.ENUM_TYPE_EXTENSION="EnumTypeExtension",r.INPUT_OBJECT_TYPE_EXTENSION="InputObjectTypeExtension"})(c||(c={}));function je$1(r){return r===9||r===32}function L$1(r){return r>=48&&r<=57}function Ge$1(r){return r>=97&&r<=122||r>=65&&r<=90}function he$1(r){return Ge$1(r)||r===95}function $e$1(r){return Ge$1(r)||L$1(r)||r===95}function Je$1(r){var t;let i=Number.MAX_SAFE_INTEGER,n=null,s=-1;for(let h=0;h<r.length;++h){var a;let v=r[h],hi=wt$1(v);hi!==v.length&&(n=(a=n)!==null&&a!==void 0?a:h,s=h,h!==0&&hi<i&&(i=hi))}return r.map((h,v)=>v===0?h:h.slice(i)).slice((t=n)!==null&&t!==void 0?t:0,s+1)}function wt$1(r){let t=0;for(;t<r.length&&je$1(r.charCodeAt(t));)++t;return t}var o;(function(r){r.SOF="<SOF>",r.EOF="<EOF>",r.BANG="!",r.DOLLAR="$",r.AMP="&",r.PAREN_L="(",r.PAREN_R=")",r.SPREAD="...",r.COLON=":",r.EQUALS="=",r.AT="@",r.BRACKET_L="[",r.BRACKET_R="]",r.BRACE_L="{",r.PIPE="|",r.BRACE_R="}",r.NAME="Name",r.INT="Int",r.FLOAT="Float",r.STRING="String",r.BLOCK_STRING="BlockString",r.COMMENT="Comment"})(o||(o={}));var z$1=class{constructor(t){let i=new V$1(o.SOF,0,0,0,0);this.source=t,this.lastToken=i,this.token=i,this.line=1,this.lineStart=0}get[Symbol.toStringTag](){return"Lexer"}advance(){return this.lastToken=this.token,this.token=this.lookahead()}lookahead(){let t=this.token;if(t.kind!==o.EOF)do if(t.next)t=t.next;else{let i=Vt$1(this,t.end);t.next=i,i.prev=t,t=i}while(t.kind===o.COMMENT);return t}};function qe$1(r){return r===o.BANG||r===o.DOLLAR||r===o.AMP||r===o.PAREN_L||r===o.PAREN_R||r===o.SPREAD||r===o.COLON||r===o.EQUALS||r===o.AT||r===o.BRACKET_L||r===o.BRACKET_R||r===o.BRACE_L||r===o.PIPE||r===o.BRACE_R}function R$1(r){return r>=0&&r<=55295||r>=57344&&r<=1114111}function K(r,t){return Qe$1(r.charCodeAt(t))&&We$1(r.charCodeAt(t+1))}function Qe$1(r){return r>=55296&&r<=56319}function We$1(r){return r>=56320&&r<=57343}function C(r,t){let i=r.source.body.codePointAt(t);if(i===void 0)return o.EOF;if(i>=32&&i<=126){let n=String.fromCodePoint(i);return n==='"'?`'"'`:`"${n}"`}return"U+"+i.toString(16).toUpperCase().padStart(4,"0")}function m(r,t,i,n,s){let a=r.line,h=1+i-r.lineStart;return new V$1(t,i,n,a,h,s)}function Vt$1(r,t){let i=r.source.body,n=i.length,s=t;for(;s<n;){let a=i.charCodeAt(s);switch(a){case 65279:case 9:case 32:case 44:++s;continue;case 10:++s,++r.line,r.lineStart=s;continue;case 13:i.charCodeAt(s+1)===10?s+=2:++s,++r.line,r.lineStart=s;continue;case 35:return Bt$1(r,s);case 33:return m(r,o.BANG,s,s+1);case 36:return m(r,o.DOLLAR,s,s+1);case 38:return m(r,o.AMP,s,s+1);case 40:return m(r,o.PAREN_L,s,s+1);case 41:return m(r,o.PAREN_R,s,s+1);case 46:if(i.charCodeAt(s+1)===46&&i.charCodeAt(s+2)===46)return m(r,o.SPREAD,s,s+3);break;case 58:return m(r,o.COLON,s,s+1);case 61:return m(r,o.EQUALS,s,s+1);case 64:return m(r,o.AT,s,s+1);case 91:return m(r,o.BRACKET_L,s,s+1);case 93:return m(r,o.BRACKET_R,s,s+1);case 123:return m(r,o.BRACE_L,s,s+1);case 124:return m(r,o.PIPE,s,s+1);case 125:return m(r,o.BRACE_R,s,s+1);case 34:return i.charCodeAt(s+1)===34&&i.charCodeAt(s+2)===34?$t$1(r,s):Mt$1(r,s)}if(L$1(a)||a===45)return Ut$1(r,s,a);if(he$1(a))return Jt$1(r,s);throw d(r.source,s,a===39?`Unexpected single quote character ('), did you mean to use a double quote (")?`:R$1(a)||K(i,s)?`Unexpected character: ${C(r,s)}.`:`Invalid character: ${C(r,s)}.`)}return m(r,o.EOF,n,n)}function Bt$1(r,t){let i=r.source.body,n=i.length,s=t+1;for(;s<n;){let a=i.charCodeAt(s);if(a===10||a===13)break;if(R$1(a))++s;else if(K(i,s))s+=2;else break}return m(r,o.COMMENT,t,s,i.slice(t+1,s))}function Ut$1(r,t,i){let n=r.source.body,s=t,a=i,h=!1;if(a===45&&(a=n.charCodeAt(++s)),a===48){if(a=n.charCodeAt(++s),L$1(a))throw d(r.source,s,`Invalid number, unexpected digit after 0: ${C(r,s)}.`)}else s=de$1(r,s,a),a=n.charCodeAt(s);if(a===46&&(h=!0,a=n.charCodeAt(++s),s=de$1(r,s,a),a=n.charCodeAt(s)),(a===69||a===101)&&(h=!0,a=n.charCodeAt(++s),(a===43||a===45)&&(a=n.charCodeAt(++s)),s=de$1(r,s,a),a=n.charCodeAt(s)),a===46||he$1(a))throw d(r.source,s,`Invalid number, expected digit but got: ${C(r,s)}.`);return m(r,h?o.FLOAT:o.INT,t,s,n.slice(t,s))}function de$1(r,t,i){if(!L$1(i))throw d(r.source,t,`Invalid number, expected digit but got: ${C(r,t)}.`);let n=r.source.body,s=t+1;for(;L$1(n.charCodeAt(s));)++s;return s}function Mt$1(r,t){let i=r.source.body,n=i.length,s=t+1,a=s,h="";for(;s<n;){let v=i.charCodeAt(s);if(v===34)return h+=i.slice(a,s),m(r,o.STRING,t,s+1,h);if(v===92){h+=i.slice(a,s);let hi=i.charCodeAt(s+1)===117?i.charCodeAt(s+2)===123?Yt$1(r,s):jt$1(r,s):Gt$1(r,s);h+=hi.value,s+=hi.size,a=s;continue}if(v===10||v===13)break;if(R$1(v))++s;else if(K(i,s))s+=2;else throw d(r.source,s,`Invalid character within String: ${C(r,s)}.`)}throw d(r.source,s,"Unterminated string.")}function Yt$1(r,t){let i=r.source.body,n=0,s=3;for(;s<12;){let a=i.charCodeAt(t+s++);if(a===125){if(s<5||!R$1(n))break;return{value:String.fromCodePoint(n),size:s}}if(n=n<<4|U$1(a),n<0)break}throw d(r.source,t,`Invalid Unicode escape sequence: "${i.slice(t,t+s)}".`)}function jt$1(r,t){let i=r.source.body,n=Xe$1(i,t+2);if(R$1(n))return{value:String.fromCodePoint(n),size:6};if(Qe$1(n)&&i.charCodeAt(t+6)===92&&i.charCodeAt(t+7)===117){let s=Xe$1(i,t+8);if(We$1(s))return{value:String.fromCodePoint(n,s),size:12}}throw d(r.source,t,`Invalid Unicode escape sequence: "${i.slice(t,t+6)}".`)}function Xe$1(r,t){return U$1(r.charCodeAt(t))<<12|U$1(r.charCodeAt(t+1))<<8|U$1(r.charCodeAt(t+2))<<4|U$1(r.charCodeAt(t+3))}function U$1(r){return r>=48&&r<=57?r-48:r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:-1}function Gt$1(r,t){let i=r.source.body;switch(i.charCodeAt(t+1)){case 34:return{value:'"',size:2};case 92:return{value:"\\",size:2};case 47:return{value:"/",size:2};case 98:return{value:"\b",size:2};case 102:return{value:"\f",size:2};case 110:return{value:`
51
+ `,size:2};case 114:return{value:"\r",size:2};case 116:return{value:" ",size:2}}throw d(r.source,t,`Invalid character escape sequence: "${i.slice(t,t+2)}".`)}function $t$1(r,t){let i=r.source.body,n=i.length,s=r.lineStart,a=t+3,h=a,v="",hi=[];for(;a<n;){let u=i.charCodeAt(a);if(u===34&&i.charCodeAt(a+1)===34&&i.charCodeAt(a+2)===34){v+=i.slice(h,a),hi.push(v);let l=m(r,o.BLOCK_STRING,t,a+3,Je$1(hi).join(`
52
+ `));return r.line+=hi.length-1,r.lineStart=s,l}if(u===92&&i.charCodeAt(a+1)===34&&i.charCodeAt(a+2)===34&&i.charCodeAt(a+3)===34){v+=i.slice(h,a),h=a+1,a+=4;continue}if(u===10||u===13){v+=i.slice(h,a),hi.push(v),u===13&&i.charCodeAt(a+1)===10?a+=2:++a,v="",h=a,s=a;continue}if(R$1(u))++a;else if(K(i,a))a+=2;else throw d(r.source,a,`Invalid character within String: ${C(r,a)}.`)}throw d(r.source,a,"Unterminated string.")}function Jt$1(r,t){let i=r.source.body,n=i.length,s=t+1;for(;s<n;){let a=i.charCodeAt(s);if($e$1(a))++s;else break}return m(r,o.NAME,t,s,i.slice(t,s))}function Z$1(r,t){throw new Error(t)}function ee$1(r){return te$1(r,[])}function te$1(r,t){switch(typeof r){case"string":return JSON.stringify(r);case"function":return r.name?`[function ${r.name}]`:"[function]";case"object":return Xt(r,t);default:return String(r)}}function Xt(r,t){if(r===null)return"null";if(t.includes(r))return"[Circular]";let i=[...t,r];if(qt$1(r)){let n=r.toJSON();if(n!==r)return typeof n=="string"?n:te$1(n,i)}else if(Array.isArray(r))return Wt$1(r,i);return Qt$1(r,i)}function qt$1(r){return typeof r.toJSON=="function"}function Qt$1(r,t){let i=Object.entries(r);return i.length===0?"{}":t.length>2?"["+Ht$1(r)+"]":"{ "+i.map(([n,s])=>n+": "+te$1(s,t)).join(", ")+" }"}function Wt$1(r,t){if(r.length===0)return"[]";if(t.length>2)return"[Array]";let i=Math.min(10,r.length),n=r.length-i,s=[];for(let a=0;a<i;++a)s.push(te$1(r[a],t));return n===1?s.push("... 1 more item"):n>1&&s.push(`... ${n} more items`),"["+s.join(", ")+"]"}function Ht$1(r){let t=Object.prototype.toString.call(r).replace(/^\[object /,"").replace(/]$/,"");if(t==="Object"&&typeof r.constructor=="function"){let i=r.constructor.name;if(typeof i=="string"&&i!=="")return i}return t}var zt$1=globalThis.process&&!0,He$1=zt$1?function(r,t){return r instanceof t}:function(r,t){if(r instanceof t)return!0;if(typeof r=="object"&&r!==null){var i;let n=t.prototype[Symbol.toStringTag],s=Symbol.toStringTag in r?r[Symbol.toStringTag]:(i=r.constructor)===null||i===void 0?void 0:i.name;if(n===s){let a=ee$1(r);throw new Error(`Cannot use ${n} "${a}" from another module or realm.
53
+
54
+ Ensure that there is only one instance of "graphql" in the node_modules
55
+ directory. If different versions of "graphql" are the dependencies of other
56
+ relied on modules, use "resolutions" to ensure only one version is installed.
57
+
58
+ https://yarnpkg.com/en/docs/selective-version-resolutions
59
+
60
+ Duplicate "graphql" modules cannot be used at the same time since different
61
+ versions may have different capabilities and behavior. The data from one
62
+ version used in the function from another could produce confusing and
63
+ spurious results.`)}}return!1},M$1=class{constructor(t,i="GraphQL request",n={line:1,column:1}){typeof t=="string"||Z$1(!1,`Body must be a string. Received: ${ee$1(t)}.`),this.body=t,this.name=i,this.locationOffset=n,this.locationOffset.line>0||Z$1(!1,"line in locationOffset is 1-indexed and must be positive."),this.locationOffset.column>0||Z$1(!1,"column in locationOffset is 1-indexed and must be positive.")}get[Symbol.toStringTag](){return"Source"}};function ze$1(r){return He$1(r,M$1)}function Ke$1(r,t){return new me$1(r,t).parseDocument()}var me$1=class{constructor(t,i={}){let n=ze$1(t)?t:new M$1(t);this._lexer=new z$1(n),this._options=i,this._tokenCounter=0}parseName(){let t=this.expectToken(o.NAME);return this.node(t,{kind:c.NAME,value:t.value})}parseDocument(){return this.node(this._lexer.token,{kind:c.DOCUMENT,definitions:this.many(o.SOF,this.parseDefinition,o.EOF)})}parseDefinition(){if(this.peek(o.BRACE_L))return this.parseOperationDefinition();let t=this.peekDescription(),i=t?this._lexer.lookahead():this._lexer.token;if(i.kind===o.NAME){switch(i.value){case"schema":return this.parseSchemaDefinition();case"scalar":return this.parseScalarTypeDefinition();case"type":return this.parseObjectTypeDefinition();case"interface":return this.parseInterfaceTypeDefinition();case"union":return this.parseUnionTypeDefinition();case"enum":return this.parseEnumTypeDefinition();case"input":return this.parseInputObjectTypeDefinition();case"directive":return this.parseDirectiveDefinition()}if(t)throw d(this._lexer.source,this._lexer.token.start,"Unexpected description, descriptions are supported only on type definitions.");switch(i.value){case"query":case"mutation":case"subscription":return this.parseOperationDefinition();case"fragment":return this.parseFragmentDefinition();case"extend":return this.parseTypeSystemExtension()}}throw this.unexpected(i)}parseOperationDefinition(){let t=this._lexer.token;if(this.peek(o.BRACE_L))return this.node(t,{kind:c.OPERATION_DEFINITION,operation:S$1.QUERY,name:void 0,variableDefinitions:[],directives:[],selectionSet:this.parseSelectionSet()});let i=this.parseOperationType(),n;return this.peek(o.NAME)&&(n=this.parseName()),this.node(t,{kind:c.OPERATION_DEFINITION,operation:i,name:n,variableDefinitions:this.parseVariableDefinitions(),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseOperationType(){let t=this.expectToken(o.NAME);switch(t.value){case"query":return S$1.QUERY;case"mutation":return S$1.MUTATION;case"subscription":return S$1.SUBSCRIPTION}throw this.unexpected(t)}parseVariableDefinitions(){return this.optionalMany(o.PAREN_L,this.parseVariableDefinition,o.PAREN_R)}parseVariableDefinition(){return this.node(this._lexer.token,{kind:c.VARIABLE_DEFINITION,variable:this.parseVariable(),type:(this.expectToken(o.COLON),this.parseTypeReference()),defaultValue:this.expectOptionalToken(o.EQUALS)?this.parseConstValueLiteral():void 0,directives:this.parseConstDirectives()})}parseVariable(){let t=this._lexer.token;return this.expectToken(o.DOLLAR),this.node(t,{kind:c.VARIABLE,name:this.parseName()})}parseSelectionSet(){return this.node(this._lexer.token,{kind:c.SELECTION_SET,selections:this.many(o.BRACE_L,this.parseSelection,o.BRACE_R)})}parseSelection(){return this.peek(o.SPREAD)?this.parseFragment():this.parseField()}parseField(){let t=this._lexer.token,i=this.parseName(),n,s;return this.expectOptionalToken(o.COLON)?(n=i,s=this.parseName()):s=i,this.node(t,{kind:c.FIELD,alias:n,name:s,arguments:this.parseArguments(!1),directives:this.parseDirectives(!1),selectionSet:this.peek(o.BRACE_L)?this.parseSelectionSet():void 0})}parseArguments(t){let i=t?this.parseConstArgument:this.parseArgument;return this.optionalMany(o.PAREN_L,i,o.PAREN_R)}parseArgument(t=!1){let i=this._lexer.token,n=this.parseName();return this.expectToken(o.COLON),this.node(i,{kind:c.ARGUMENT,name:n,value:this.parseValueLiteral(t)})}parseConstArgument(){return this.parseArgument(!0)}parseFragment(){let t=this._lexer.token;this.expectToken(o.SPREAD);let i=this.expectOptionalKeyword("on");return!i&&this.peek(o.NAME)?this.node(t,{kind:c.FRAGMENT_SPREAD,name:this.parseFragmentName(),directives:this.parseDirectives(!1)}):this.node(t,{kind:c.INLINE_FRAGMENT,typeCondition:i?this.parseNamedType():void 0,directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentDefinition(){let t=this._lexer.token;return this.expectKeyword("fragment"),this._options.allowLegacyFragmentVariables===!0?this.node(t,{kind:c.FRAGMENT_DEFINITION,name:this.parseFragmentName(),variableDefinitions:this.parseVariableDefinitions(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()}):this.node(t,{kind:c.FRAGMENT_DEFINITION,name:this.parseFragmentName(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentName(){if(this._lexer.token.value==="on")throw this.unexpected();return this.parseName()}parseValueLiteral(t){let i=this._lexer.token;switch(i.kind){case o.BRACKET_L:return this.parseList(t);case o.BRACE_L:return this.parseObject(t);case o.INT:return this.advanceLexer(),this.node(i,{kind:c.INT,value:i.value});case o.FLOAT:return this.advanceLexer(),this.node(i,{kind:c.FLOAT,value:i.value});case o.STRING:case o.BLOCK_STRING:return this.parseStringLiteral();case o.NAME:switch(this.advanceLexer(),i.value){case"true":return this.node(i,{kind:c.BOOLEAN,value:!0});case"false":return this.node(i,{kind:c.BOOLEAN,value:!1});case"null":return this.node(i,{kind:c.NULL});default:return this.node(i,{kind:c.ENUM,value:i.value})}case o.DOLLAR:if(t)if(this.expectToken(o.DOLLAR),this._lexer.token.kind===o.NAME){let n=this._lexer.token.value;throw d(this._lexer.source,i.start,`Unexpected variable "$${n}" in constant value.`)}else throw this.unexpected(i);return this.parseVariable();default:throw this.unexpected()}}parseConstValueLiteral(){return this.parseValueLiteral(!0)}parseStringLiteral(){let t=this._lexer.token;return this.advanceLexer(),this.node(t,{kind:c.STRING,value:t.value,block:t.kind===o.BLOCK_STRING})}parseList(t){let i=()=>this.parseValueLiteral(t);return this.node(this._lexer.token,{kind:c.LIST,values:this.any(o.BRACKET_L,i,o.BRACKET_R)})}parseObject(t){let i=()=>this.parseObjectField(t);return this.node(this._lexer.token,{kind:c.OBJECT,fields:this.any(o.BRACE_L,i,o.BRACE_R)})}parseObjectField(t){let i=this._lexer.token,n=this.parseName();return this.expectToken(o.COLON),this.node(i,{kind:c.OBJECT_FIELD,name:n,value:this.parseValueLiteral(t)})}parseDirectives(t){let i=[];for(;this.peek(o.AT);)i.push(this.parseDirective(t));return i}parseConstDirectives(){return this.parseDirectives(!0)}parseDirective(t){let i=this._lexer.token;return this.expectToken(o.AT),this.node(i,{kind:c.DIRECTIVE,name:this.parseName(),arguments:this.parseArguments(t)})}parseTypeReference(){let t=this._lexer.token,i;if(this.expectOptionalToken(o.BRACKET_L)){let n=this.parseTypeReference();this.expectToken(o.BRACKET_R),i=this.node(t,{kind:c.LIST_TYPE,type:n})}else i=this.parseNamedType();return this.expectOptionalToken(o.BANG)?this.node(t,{kind:c.NON_NULL_TYPE,type:i}):i}parseNamedType(){return this.node(this._lexer.token,{kind:c.NAMED_TYPE,name:this.parseName()})}peekDescription(){return this.peek(o.STRING)||this.peek(o.BLOCK_STRING)}parseDescription(){if(this.peekDescription())return this.parseStringLiteral()}parseSchemaDefinition(){let t=this._lexer.token,i=this.parseDescription();this.expectKeyword("schema");let n=this.parseConstDirectives(),s=this.many(o.BRACE_L,this.parseOperationTypeDefinition,o.BRACE_R);return this.node(t,{kind:c.SCHEMA_DEFINITION,description:i,directives:n,operationTypes:s})}parseOperationTypeDefinition(){let t=this._lexer.token,i=this.parseOperationType();this.expectToken(o.COLON);let n=this.parseNamedType();return this.node(t,{kind:c.OPERATION_TYPE_DEFINITION,operation:i,type:n})}parseScalarTypeDefinition(){let t=this._lexer.token,i=this.parseDescription();this.expectKeyword("scalar");let n=this.parseName(),s=this.parseConstDirectives();return this.node(t,{kind:c.SCALAR_TYPE_DEFINITION,description:i,name:n,directives:s})}parseObjectTypeDefinition(){let t=this._lexer.token,i=this.parseDescription();this.expectKeyword("type");let n=this.parseName(),s=this.parseImplementsInterfaces(),a=this.parseConstDirectives(),h=this.parseFieldsDefinition();return this.node(t,{kind:c.OBJECT_TYPE_DEFINITION,description:i,name:n,interfaces:s,directives:a,fields:h})}parseImplementsInterfaces(){return this.expectOptionalKeyword("implements")?this.delimitedMany(o.AMP,this.parseNamedType):[]}parseFieldsDefinition(){return this.optionalMany(o.BRACE_L,this.parseFieldDefinition,o.BRACE_R)}parseFieldDefinition(){let t=this._lexer.token,i=this.parseDescription(),n=this.parseName(),s=this.parseArgumentDefs();this.expectToken(o.COLON);let a=this.parseTypeReference(),h=this.parseConstDirectives();return this.node(t,{kind:c.FIELD_DEFINITION,description:i,name:n,arguments:s,type:a,directives:h})}parseArgumentDefs(){return this.optionalMany(o.PAREN_L,this.parseInputValueDef,o.PAREN_R)}parseInputValueDef(){let t=this._lexer.token,i=this.parseDescription(),n=this.parseName();this.expectToken(o.COLON);let s=this.parseTypeReference(),a;this.expectOptionalToken(o.EQUALS)&&(a=this.parseConstValueLiteral());let h=this.parseConstDirectives();return this.node(t,{kind:c.INPUT_VALUE_DEFINITION,description:i,name:n,type:s,defaultValue:a,directives:h})}parseInterfaceTypeDefinition(){let t=this._lexer.token,i=this.parseDescription();this.expectKeyword("interface");let n=this.parseName(),s=this.parseImplementsInterfaces(),a=this.parseConstDirectives(),h=this.parseFieldsDefinition();return this.node(t,{kind:c.INTERFACE_TYPE_DEFINITION,description:i,name:n,interfaces:s,directives:a,fields:h})}parseUnionTypeDefinition(){let t=this._lexer.token,i=this.parseDescription();this.expectKeyword("union");let n=this.parseName(),s=this.parseConstDirectives(),a=this.parseUnionMemberTypes();return this.node(t,{kind:c.UNION_TYPE_DEFINITION,description:i,name:n,directives:s,types:a})}parseUnionMemberTypes(){return this.expectOptionalToken(o.EQUALS)?this.delimitedMany(o.PIPE,this.parseNamedType):[]}parseEnumTypeDefinition(){let t=this._lexer.token,i=this.parseDescription();this.expectKeyword("enum");let n=this.parseName(),s=this.parseConstDirectives(),a=this.parseEnumValuesDefinition();return this.node(t,{kind:c.ENUM_TYPE_DEFINITION,description:i,name:n,directives:s,values:a})}parseEnumValuesDefinition(){return this.optionalMany(o.BRACE_L,this.parseEnumValueDefinition,o.BRACE_R)}parseEnumValueDefinition(){let t=this._lexer.token,i=this.parseDescription(),n=this.parseEnumValueName(),s=this.parseConstDirectives();return this.node(t,{kind:c.ENUM_VALUE_DEFINITION,description:i,name:n,directives:s})}parseEnumValueName(){if(this._lexer.token.value==="true"||this._lexer.token.value==="false"||this._lexer.token.value==="null")throw d(this._lexer.source,this._lexer.token.start,`${ne$1(this._lexer.token)} is reserved and cannot be used for an enum value.`);return this.parseName()}parseInputObjectTypeDefinition(){let t=this._lexer.token,i=this.parseDescription();this.expectKeyword("input");let n=this.parseName(),s=this.parseConstDirectives(),a=this.parseInputFieldsDefinition();return this.node(t,{kind:c.INPUT_OBJECT_TYPE_DEFINITION,description:i,name:n,directives:s,fields:a})}parseInputFieldsDefinition(){return this.optionalMany(o.BRACE_L,this.parseInputValueDef,o.BRACE_R)}parseTypeSystemExtension(){let t=this._lexer.lookahead();if(t.kind===o.NAME)switch(t.value){case"schema":return this.parseSchemaExtension();case"scalar":return this.parseScalarTypeExtension();case"type":return this.parseObjectTypeExtension();case"interface":return this.parseInterfaceTypeExtension();case"union":return this.parseUnionTypeExtension();case"enum":return this.parseEnumTypeExtension();case"input":return this.parseInputObjectTypeExtension()}throw this.unexpected(t)}parseSchemaExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("schema");let i=this.parseConstDirectives(),n=this.optionalMany(o.BRACE_L,this.parseOperationTypeDefinition,o.BRACE_R);if(i.length===0&&n.length===0)throw this.unexpected();return this.node(t,{kind:c.SCHEMA_EXTENSION,directives:i,operationTypes:n})}parseScalarTypeExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("scalar");let i=this.parseName(),n=this.parseConstDirectives();if(n.length===0)throw this.unexpected();return this.node(t,{kind:c.SCALAR_TYPE_EXTENSION,name:i,directives:n})}parseObjectTypeExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("type");let i=this.parseName(),n=this.parseImplementsInterfaces(),s=this.parseConstDirectives(),a=this.parseFieldsDefinition();if(n.length===0&&s.length===0&&a.length===0)throw this.unexpected();return this.node(t,{kind:c.OBJECT_TYPE_EXTENSION,name:i,interfaces:n,directives:s,fields:a})}parseInterfaceTypeExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("interface");let i=this.parseName(),n=this.parseImplementsInterfaces(),s=this.parseConstDirectives(),a=this.parseFieldsDefinition();if(n.length===0&&s.length===0&&a.length===0)throw this.unexpected();return this.node(t,{kind:c.INTERFACE_TYPE_EXTENSION,name:i,interfaces:n,directives:s,fields:a})}parseUnionTypeExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("union");let i=this.parseName(),n=this.parseConstDirectives(),s=this.parseUnionMemberTypes();if(n.length===0&&s.length===0)throw this.unexpected();return this.node(t,{kind:c.UNION_TYPE_EXTENSION,name:i,directives:n,types:s})}parseEnumTypeExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("enum");let i=this.parseName(),n=this.parseConstDirectives(),s=this.parseEnumValuesDefinition();if(n.length===0&&s.length===0)throw this.unexpected();return this.node(t,{kind:c.ENUM_TYPE_EXTENSION,name:i,directives:n,values:s})}parseInputObjectTypeExtension(){let t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("input");let i=this.parseName(),n=this.parseConstDirectives(),s=this.parseInputFieldsDefinition();if(n.length===0&&s.length===0)throw this.unexpected();return this.node(t,{kind:c.INPUT_OBJECT_TYPE_EXTENSION,name:i,directives:n,fields:s})}parseDirectiveDefinition(){let t=this._lexer.token,i=this.parseDescription();this.expectKeyword("directive"),this.expectToken(o.AT);let n=this.parseName(),s=this.parseArgumentDefs(),a=this.expectOptionalKeyword("repeatable");this.expectKeyword("on");let h=this.parseDirectiveLocations();return this.node(t,{kind:c.DIRECTIVE_DEFINITION,description:i,name:n,arguments:s,repeatable:a,locations:h})}parseDirectiveLocations(){return this.delimitedMany(o.PIPE,this.parseDirectiveLocation)}parseDirectiveLocation(){let t=this._lexer.token,i=this.parseName();if(Object.prototype.hasOwnProperty.call(H$1,i.value))return i;throw this.unexpected(t)}node(t,i){return this._options.noLocation!==!0&&(i.loc=new J$1(t,this._lexer.lastToken,this._lexer.source)),i}peek(t){return this._lexer.token.kind===t}expectToken(t){let i=this._lexer.token;if(i.kind===t)return this.advanceLexer(),i;throw d(this._lexer.source,i.start,`Expected ${Ze$1(t)}, found ${ne$1(i)}.`)}expectOptionalToken(t){return this._lexer.token.kind===t?(this.advanceLexer(),!0):!1}expectKeyword(t){let i=this._lexer.token;if(i.kind===o.NAME&&i.value===t)this.advanceLexer();else throw d(this._lexer.source,i.start,`Expected "${t}", found ${ne$1(i)}.`)}expectOptionalKeyword(t){let i=this._lexer.token;return i.kind===o.NAME&&i.value===t?(this.advanceLexer(),!0):!1}unexpected(t){let i=t??this._lexer.token;return d(this._lexer.source,i.start,`Unexpected ${ne$1(i)}.`)}any(t,i,n){this.expectToken(t);let s=[];for(;!this.expectOptionalToken(n);)s.push(i.call(this));return s}optionalMany(t,i,n){if(this.expectOptionalToken(t)){let s=[];do s.push(i.call(this));while(!this.expectOptionalToken(n));return s}return[]}many(t,i,n){this.expectToken(t);let s=[];do s.push(i.call(this));while(!this.expectOptionalToken(n));return s}delimitedMany(t,i){this.expectOptionalToken(t);let n=[];do n.push(i.call(this));while(this.expectOptionalToken(t));return n}advanceLexer(){let{maxTokens:t}=this._options,i=this._lexer.advance();if(t!==void 0&&i.kind!==o.EOF&&(++this._tokenCounter,this._tokenCounter>t))throw d(this._lexer.source,i.start,`Document contains more that ${t} tokens. Parsing aborted.`)}};function ne$1(r){let t=r.value;return Ze$1(r.kind)+(t!=null?` "${t}"`:"")}function Ze$1(r){return qe$1(r)?`"${r}"`:r}function Kt$1(r,t){let i=new SyntaxError(r+" ("+t.loc.start.line+":"+t.loc.start.column+")");return Object.assign(i,t)}var et$1=Kt$1;function Zt(r){let t=[],{startToken:i,endToken:n}=r.loc;for(let s=i;s!==n;s=s.next)s.kind==="Comment"&&t.push({...s,loc:{start:s.start,end:s.end}});return t}var en$1={allowLegacyFragmentVariables:!0};function tn(r){if(r?.name==="GraphQLError"){let{message:t,locations:[i]}=r;return et$1(t,{loc:{start:i},cause:r})}return r}function nn$1(r){let t;try{t=Ke$1(r,en$1)}catch(i){throw tn(i)}return t.comments=Zt(t),t}var rn$1={parse:nn$1,astFormat:"graphql",hasPragma:Ce$1,locStart:q$1,locEnd:Q$1},sn={graphql:Re$1},yu=Object.create,He=Object.defineProperty,Au=Object.getOwnPropertyDescriptor,Bu=Object.getOwnPropertyNames,wu=Object.getPrototypeOf,xu=Object.prototype.hasOwnProperty,sr=r=>{throw TypeError(r)},_u=(r,t)=>()=>(r&&(t=r(r=0)),t),At=(r,t)=>()=>(t||r((t={exports:{}}).exports,t),t.exports),We=(r,t)=>{for(var i in t)He(r,i,{get:t[i],enumerable:!0})},ar=(r,t,i,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let s of Bu(t))!xu.call(r,s)&&s!==i&&He(r,s,{get:()=>t[s],enumerable:!(n=Au(t,s))||n.enumerable});return r},Me=(r,t,i)=>(i=r!=null?yu(wu(r)):{},ar(He(i,"default",{value:r,enumerable:!0}),r)),vu=r=>ar(He({},"__esModule",{value:!0}),r),bu=(r,t,i)=>t.has(r)||sr("Cannot "+i),Dr=(r,t,i)=>t.has(r)?sr("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(r):t.set(r,i),pe=(r,t,i)=>(bu(r,t,"access private method"),i),it=At((r,t)=>{var i=new Proxy(String,{get:()=>i});t.exports=i}),Tn={};We(Tn,{default:()=>_o,shouldHighlight:()=>xo});var xo,_o,kn=_u(()=>{xo=()=>!1,_o=String}),Pn=At((r,t)=>{var i=String,n=function(){return{isColorSupported:!1,reset:i,bold:i,dim:i,italic:i,underline:i,inverse:i,hidden:i,strikethrough:i,black:i,red:i,green:i,yellow:i,blue:i,magenta:i,cyan:i,white:i,gray:i,bgBlack:i,bgRed:i,bgGreen:i,bgYellow:i,bgBlue:i,bgMagenta:i,bgCyan:i,bgWhite:i}};t.exports=n(),t.exports.createColors=n}),$n=At(r=>{Object.defineProperty(r,"__esModule",{value:!0}),r.codeFrameColumns=mi,r.default=gi;var t=(kn(),vu(Tn)),i=s(Pn(),!0);function n(bi){if(typeof WeakMap!="function")return null;var Ri=new WeakMap,Ti=new WeakMap;return(n=function(Ii){return Ii?Ti:Ri})(bi)}function s(bi,Ri){if(bi===null||typeof bi!="object"&&typeof bi!="function")return{default:bi};var Ti=n(Ri);if(Ti&&Ti.has(bi))return Ti.get(bi);var Ii={__proto__:null},qi=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var Oi in bi)if(Oi!=="default"&&{}.hasOwnProperty.call(bi,Oi)){var ki=qi?Object.getOwnPropertyDescriptor(bi,Oi):null;ki&&(ki.get||ki.set)?Object.defineProperty(Ii,Oi,ki):Ii[Oi]=bi[Oi]}return Ii.default=bi,Ti&&Ti.set(bi,Ii),Ii}var a=i.default,h=(bi,Ri)=>Ti=>bi(Ri(Ti)),v;function hi(bi){return bi?(v!=null||(v=(0,i.createColors)(!0)),v):a}var u=!1;function l(bi){return{gutter:bi.gray,marker:h(bi.red,bi.bold),message:h(bi.red,bi.bold)}}var vi=/\r\n|[\n\r\u2028\u2029]/;function D(bi,Ri,Ti){let Ii=Object.assign({column:0,line:-1},bi.start),qi=Object.assign({},Ii,bi.end),{linesAbove:Oi=2,linesBelow:ki=3}=Ti||{},Li=Ii.line,ji=Ii.column,Hi=qi.line,Ui=qi.column,Qi=Math.max(Li-(Oi+1),0),$i=Math.min(Ri.length,Hi+ki);Li===-1&&(Qi=0),Hi===-1&&($i=Ri.length);let wi=Hi-Li,xi={};if(wi)for(let yi=0;yi<=wi;yi++){let Ei=yi+Li;if(!ji)xi[Ei]=!0;else if(yi===0){let Ci=Ri[Ei-1].length;xi[Ei]=[ji,Ci-ji+1]}else if(yi===wi)xi[Ei]=[0,Ui];else{let Ci=Ri[Ei-yi].length;xi[Ei]=[0,Ci]}}else ji===Ui?ji?xi[Li]=[ji,0]:xi[Li]=!0:xi[Li]=[ji,Ui-ji];return{start:Qi,end:$i,markerLines:xi}}function mi(bi,Ri,Ti={}){let Ii=(Ti.highlightCode||Ti.forceColor)&&(0,t.shouldHighlight)(Ti),qi=hi(Ti.forceColor),Oi=l(qi),ki=(xi,yi)=>Ii?xi(yi):yi,Li=bi.split(vi),{start:ji,end:Hi,markerLines:Ui}=D(Ri,Li,Ti),Qi=Ri.start&&typeof Ri.start.column=="number",$i=String(Hi).length,wi=(Ii?(0,t.default)(bi,Ti):bi).split(vi,Hi).slice(ji,Hi).map((xi,yi)=>{let Ei=ji+1+yi,Ci=` ${` ${Ei}`.slice(-$i)} |`,Ni=Ui[Ei],Fi=!Ui[Ei+1];if(Ni){let Mi="";if(Array.isArray(Ni)){let Si=xi.slice(0,Math.max(Ni[0]-1,0)).replace(/[^\t]/g," "),Ai=Ni[1]||1;Mi=[`
64
+ `,ki(Oi.gutter,Ci.replace(/\d/g," "))," ",Si,ki(Oi.marker,"^").repeat(Ai)].join(""),Fi&&Ti.message&&(Mi+=" "+ki(Oi.message,Ti.message))}return[ki(Oi.marker,">"),ki(Oi.gutter,Ci),xi.length>0?` ${xi}`:"",Mi].join("")}else return` ${ki(Oi.gutter,Ci)}${xi.length>0?` ${xi}`:""}`}).join(`
65
+ `);return Ti.message&&!Qi&&(wi=`${" ".repeat($i+1)}${Ti.message}
66
+ ${wi}`),Ii?qi.reset(wi):wi}function gi(bi,Ri,Ti,Ii={}){if(!u){u=!0;let qi="Passing lineNumber and colNumber is deprecated to @babel/code-frame. Please use `codeFrameColumns`.";{let Oi=new Error(qi);Oi.name="DeprecationWarning",console.warn(new Error(qi))}}return Ti=Math.max(Ti,0),mi(bi,{start:{column:Ti,line:Ri}},Ii)}}),ir={};We(ir,{__debug:()=>di,check:()=>fi,doc:()=>nr,format:()=>gu,formatWithCursor:()=>Cu,getSupportInfo:()=>pi,util:()=>or,version:()=>fu});var Ou=(r,t,i,n)=>{if(!(r&&t==null))return t.replaceAll?t.replaceAll(i,n):i.global?t.replace(i,n):t.split(i).join(n)},ne=Ou;function Z(){}Z.prototype={diff:function(r,t){var i,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},s=n.callback;typeof n=="function"&&(s=n,n={}),this.options=n;var a=this;function h(qi){return s?(setTimeout(function(){s(void 0,qi)},0),!0):qi}r=this.castInput(r),t=this.castInput(t),r=this.removeEmpty(this.tokenize(r)),t=this.removeEmpty(this.tokenize(t));var v=t.length,hi=r.length,u=1,l=v+hi;n.maxEditLength&&(l=Math.min(l,n.maxEditLength));var vi=(i=n.timeout)!==null&&i!==void 0?i:1/0,D=Date.now()+vi,mi=[{oldPos:-1,lastComponent:void 0}],gi=this.extractCommon(mi[0],t,r,0);if(mi[0].oldPos+1>=hi&&gi+1>=v)return h([{value:this.join(t),count:t.length}]);var bi=-1/0,Ri=1/0;function Ti(){for(var qi=Math.max(bi,-u);qi<=Math.min(Ri,u);qi+=2){var Oi=void 0,ki=mi[qi-1],Li=mi[qi+1];ki&&(mi[qi-1]=void 0);var ji=!1;if(Li){var Hi=Li.oldPos-qi;ji=Li&&0<=Hi&&Hi<v}var Ui=ki&&ki.oldPos+1<hi;if(!ji&&!Ui){mi[qi]=void 0;continue}if(!Ui||ji&&ki.oldPos+1<Li.oldPos?Oi=a.addToPath(Li,!0,void 0,0):Oi=a.addToPath(ki,void 0,!0,1),gi=a.extractCommon(Oi,t,r,qi),Oi.oldPos+1>=hi&&gi+1>=v)return h(Su(a,Oi.lastComponent,t,r,a.useLongestToken));mi[qi]=Oi,Oi.oldPos+1>=hi&&(Ri=Math.min(Ri,qi-1)),gi+1>=v&&(bi=Math.max(bi,qi+1))}u++}if(s)(function qi(){setTimeout(function(){if(u>l||Date.now()>D)return s();Ti()||qi()},0)})();else for(;u<=l&&Date.now()<=D;){var Ii=Ti();if(Ii)return Ii}},addToPath:function(r,t,i,n){var s=r.lastComponent;return s&&s.added===t&&s.removed===i?{oldPos:r.oldPos+n,lastComponent:{count:s.count+1,added:t,removed:i,previousComponent:s.previousComponent}}:{oldPos:r.oldPos+n,lastComponent:{count:1,added:t,removed:i,previousComponent:s}}},extractCommon:function(r,t,i,n){for(var s=t.length,a=i.length,h=r.oldPos,v=h-n,hi=0;v+1<s&&h+1<a&&this.equals(t[v+1],i[h+1]);)v++,h++,hi++;return hi&&(r.lastComponent={count:hi,previousComponent:r.lastComponent}),r.oldPos=h,v},equals:function(r,t){return this.options.comparator?this.options.comparator(r,t):r===t||this.options.ignoreCase&&r.toLowerCase()===t.toLowerCase()},removeEmpty:function(r){for(var t=[],i=0;i<r.length;i++)r[i]&&t.push(r[i]);return t},castInput:function(r){return r},tokenize:function(r){return r.split("")},join:function(r){return r.join("")}};function Su(r,t,i,n,s){for(var a=[],h;t;)a.push(t),h=t.previousComponent,delete t.previousComponent,t=h;a.reverse();for(var v=0,hi=a.length,u=0,l=0;v<hi;v++){var vi=a[v];if(vi.removed){if(vi.value=r.join(n.slice(l,l+vi.count)),l+=vi.count,v&&a[v-1].added){var D=a[v-1];a[v-1]=a[v],a[v]=D}}else{if(!vi.added&&s){var mi=i.slice(u,u+vi.count);mi=mi.map(function(bi,Ri){var Ti=n[l+Ri];return Ti.length>bi.length?Ti:bi}),vi.value=r.join(mi)}else vi.value=r.join(i.slice(u,u+vi.count));u+=vi.count,vi.added||(l+=vi.count)}}var gi=a[hi-1];return hi>1&&typeof gi.value=="string"&&(gi.added||gi.removed)&&r.equals("",gi.value)&&(a[hi-2].value+=gi.value,a.pop()),a}var lr=/^[A-Za-z\xC0-\u02C6\u02C8-\u02D7\u02DE-\u02FF\u1E00-\u1EFF]+$/,cr=/\S/,fr=new Z;fr.equals=function(r,t){return this.options.ignoreCase&&(r=r.toLowerCase(),t=t.toLowerCase()),r===t||this.options.ignoreWhitespace&&!cr.test(r)&&!cr.test(t)};fr.tokenize=function(r){for(var t=r.split(/([^\S\r\n]+|[()[\]{}'"\r\n]|\b)/),i=0;i<t.length-1;i++)!t[i+1]&&t[i+2]&&lr.test(t[i])&&lr.test(t[i+2])&&(t[i]+=t[i+2],t.splice(i+1,2),i--);return t};var pr=new Z;pr.tokenize=function(r){this.options.stripTrailingCr&&(r=r.replace(/\r\n/g,`
67
+ `));var t=[],i=r.split(/(\n|\r\n)/);i[i.length-1]||i.pop();for(var n=0;n<i.length;n++){var s=i[n];n%2&&!this.options.newlineIsToken?t[t.length-1]+=s:(this.options.ignoreWhitespace&&(s=s.trim()),t.push(s))}return t};var Nu=new Z;Nu.tokenize=function(r){return r.split(/(\S.+?[.!?])(?=\s+|$)/)};var Tu=new Z;Tu.tokenize=function(r){return r.split(/([{}:;,]|\s+)/)};function $e(r){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?$e=function(t){return typeof t}:$e=function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},$e(r)}var ku=Object.prototype.toString,Ae=new Z;Ae.useLongestToken=!0;Ae.tokenize=pr.tokenize;Ae.castInput=function(r){var t=this.options,i=t.undefinedReplacement,n=t.stringifyReplacer,s=n===void 0?function(a,h){return typeof h>"u"?i:h}:n;return typeof r=="string"?r:JSON.stringify(Bt(r,null,null,s),s," ")};Ae.equals=function(r,t){return Z.prototype.equals.call(Ae,r.replace(/,([\r\n])/g,"$1"),t.replace(/,([\r\n])/g,"$1"))};function Bt(r,t,i,n,s){t=t||[],i=i||[],n&&(r=n(s,r));var a;for(a=0;a<t.length;a+=1)if(t[a]===r)return i[a];var h;if(ku.call(r)==="[object Array]"){for(t.push(r),h=new Array(r.length),i.push(h),a=0;a<r.length;a+=1)h[a]=Bt(r[a],t,i,n,s);return t.pop(),i.pop(),h}if(r&&r.toJSON&&(r=r.toJSON()),$e(r)==="object"&&r!==null){t.push(r),h={},i.push(h);var v=[],hi;for(hi in r)r.hasOwnProperty(hi)&&v.push(hi);for(v.sort(),a=0;a<v.length;a+=1)hi=v[a],h[hi]=Bt(r[hi],t,i,n,hi);t.pop(),i.pop()}else h=r;return h}var Ve=new Z;Ve.tokenize=function(r){return r.slice()};Ve.join=Ve.removeEmpty=function(r){return r};function dr(r,t,i){return Ve.diff(r,t,i)}function Fr(r){let t=r.indexOf("\r");return t>=0?r.charAt(t+1)===`
68
+ `?"crlf":"cr":"lf"}function Be(r){switch(r){case"cr":return"\r";case"crlf":return`\r
69
+ `;default:return`
70
+ `}}function wt(r,t){let i;switch(t){case`
71
+ `:i=/\n/gu;break;case"\r":i=/\r/gu;break;case`\r
72
+ `:i=/\r\n/gu;break;default:throw new Error(`Unexpected "eol" ${JSON.stringify(t)}.`)}let n=r.match(i);return n?n.length:0}function mr$1(r){return ne(!1,r,/\r\n?/gu,`
73
+ `)}var U="string",W="array",z="cursor",L="indent",P="align",I="trim",x="group",S="fill",_="if-break",R="indent-if-break",Y="line-suffix",j="line-suffix-boundary",B="line",N="label",b="break-parent",Ue=new Set([z,L,P,I,x,S,_,R,Y,j,B,N,b]);function Lu(r){if(typeof r=="string")return U;if(Array.isArray(r))return W;if(!r)return;let{type:t}=r;if(Ue.has(t))return t}var G=Lu,Pu=r=>new Intl.ListFormat("en-US",{type:"disjunction"}).format(r);function Iu(r){let t=r===null?"null":typeof r;if(t!=="string"&&t!=="object")return`Unexpected doc '${t}',
74
+ Expected it to be 'string' or 'object'.`;if(G(r))throw new Error("doc is valid.");let i=Object.prototype.toString.call(r);if(i!=="[object Object]")return`Unexpected doc '${i}'.`;let n=Pu([...Ue].map(s=>`'${s}'`));return`Unexpected doc.type '${r.type}'.
75
+ Expected it to be ${n}.`}var xt=class extends Error{name="InvalidDocError";constructor(r){super(Iu(r)),this.doc=r}},Q=xt,Er={};function Ru(r,t,i,n){let s=[r];for(;s.length>0;){let a=s.pop();if(a===Er){i(s.pop());continue}i&&s.push(a,Er);let h=G(a);if(!h)throw new Q(a);if(t?.(a)!==!1)switch(h){case W:case S:{let v=h===W?a:a.parts;for(let hi=v.length,u=hi-1;u>=0;--u)s.push(v[u]);break}case _:s.push(a.flatContents,a.breakContents);break;case x:if(n&&a.expandedStates)for(let v=a.expandedStates.length,hi=v-1;hi>=0;--hi)s.push(a.expandedStates[hi]);else s.push(a.contents);break;case P:case L:case R:case N:case Y:s.push(a.contents);break;case U:case z:case I:case j:case B:case b:break;default:throw new Q(a)}}}var we=Ru,hr=()=>{},ze=hr;function De(r){return{type:L,contents:r}}function ae(r,t){return{type:P,contents:t,n:r}}function _t(r,t={}){return ze(t.expandedStates),{type:x,id:t.id,contents:r,break:!!t.shouldBreak,expandedStates:t.expandedStates}}function Cr(r){return ae(Number.NEGATIVE_INFINITY,r)}function gr(r){return ae({type:"root"},r)}function yr(r){return ae(-1,r)}function Ar(r,t){return _t(r[0],{...t,expandedStates:r})}function Ge(r){return{type:S,parts:r}}function Br(r,t="",i={}){return{type:_,breakContents:r,flatContents:t,groupId:i.groupId}}function wr(r,t){return{type:R,contents:r,groupId:t.groupId,negate:t.negate}}function xe(r){return{type:Y,contents:r}}var xr={type:j},de={type:b},_r={type:I},_e={type:B,hard:!0},vt={type:B,hard:!0,literal:!0},Ke={type:B},vr={type:B,soft:!0},q=[_e,de],qe=[vt,de],ve={type:z};function be(r,t){let i=[];for(let n=0;n<t.length;n++)n!==0&&i.push(r),i.push(t[n]);return i}function Je(r,t,i){let n=r;if(t>0){for(let s=0;s<Math.floor(t/i);++s)n=De(n);n=ae(t%i,n),n=ae(Number.NEGATIVE_INFINITY,n)}return n}function br(r,t){return r?{type:N,label:r,contents:t}:t}function ee(r){var t;if(!r)return"";if(Array.isArray(r)){let i=[];for(let n of r)if(Array.isArray(n))i.push(...ee(n));else{let s=ee(n);s!==""&&i.push(s)}return i}return r.type===_?{...r,breakContents:ee(r.breakContents),flatContents:ee(r.flatContents)}:r.type===x?{...r,contents:ee(r.contents),expandedStates:(t=r.expandedStates)==null?void 0:t.map(ee)}:r.type===S?{type:"fill",parts:r.parts.map(ee)}:r.contents?{...r,contents:ee(r.contents)}:r}function Or(r){let t=Object.create(null),i=new Set;return n(ee(r));function n(a,h,v){var hi,u;if(typeof a=="string")return JSON.stringify(a);if(Array.isArray(a)){let l=a.map(n).filter(Boolean);return l.length===1?l[0]:`[${l.join(", ")}]`}if(a.type===B){let l=((hi=v?.[h+1])==null?void 0:hi.type)===b;return a.literal?l?"literalline":"literallineWithoutBreakParent":a.hard?l?"hardline":"hardlineWithoutBreakParent":a.soft?"softline":"line"}if(a.type===b)return((u=v?.[h-1])==null?void 0:u.type)===B&&v[h-1].hard?void 0:"breakParent";if(a.type===I)return"trim";if(a.type===L)return"indent("+n(a.contents)+")";if(a.type===P)return a.n===Number.NEGATIVE_INFINITY?"dedentToRoot("+n(a.contents)+")":a.n<0?"dedent("+n(a.contents)+")":a.n.type==="root"?"markAsRoot("+n(a.contents)+")":"align("+JSON.stringify(a.n)+", "+n(a.contents)+")";if(a.type===_)return"ifBreak("+n(a.breakContents)+(a.flatContents?", "+n(a.flatContents):"")+(a.groupId?(a.flatContents?"":', ""')+`, { groupId: ${s(a.groupId)} }`:"")+")";if(a.type===R){let l=[];a.negate&&l.push("negate: true"),a.groupId&&l.push(`groupId: ${s(a.groupId)}`);let vi=l.length>0?`, { ${l.join(", ")} }`:"";return`indentIfBreak(${n(a.contents)}${vi})`}if(a.type===x){let l=[];a.break&&a.break!=="propagated"&&l.push("shouldBreak: true"),a.id&&l.push(`id: ${s(a.id)}`);let vi=l.length>0?`, { ${l.join(", ")} }`:"";return a.expandedStates?`conditionalGroup([${a.expandedStates.map(D=>n(D)).join(",")}]${vi})`:`group(${n(a.contents)}${vi})`}if(a.type===S)return`fill([${a.parts.map(l=>n(l)).join(", ")}])`;if(a.type===Y)return"lineSuffix("+n(a.contents)+")";if(a.type===j)return"lineSuffixBoundary";if(a.type===N)return`label(${JSON.stringify(a.label)}, ${n(a.contents)})`;throw new Error("Unknown doc type "+a.type)}function s(a){if(typeof a!="symbol")return JSON.stringify(String(a));if(a in t)return t[a];let h=a.description||"symbol";for(let v=0;;v++){let hi=h+(v>0?` #${v}`:"");if(!i.has(hi))return i.add(hi),t[a]=`Symbol.for(${JSON.stringify(hi)})`}}}var Yu=(r,t,i)=>{if(!(r&&t==null))return Array.isArray(t)||typeof t=="string"?t[i<0?t.length+i:i]:t.at(i)},y=Yu,Sr=()=>/[#*0-9]\uFE0F?\u20E3|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26AA\u26B0\u26B1\u26BD\u26BE\u26C4\u26C8\u26CF\u26D1\u26E9\u26F0-\u26F5\u26F7\u26F8\u26FA\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2757\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B55\u3030\u303D\u3297\u3299]\uFE0F?|[\u261D\u270C\u270D](?:\uFE0F|\uD83C[\uDFFB-\uDFFF])?|[\u270A\u270B](?:\uD83C[\uDFFB-\uDFFF])?|[\u23E9-\u23EC\u23F0\u23F3\u25FD\u2693\u26A1\u26AB\u26C5\u26CE\u26D4\u26EA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2795-\u2797\u27B0\u27BF\u2B50]|\u26D3\uFE0F?(?:\u200D\uD83D\uDCA5)?|\u26F9(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|\u2764\uFE0F?(?:\u200D(?:\uD83D\uDD25|\uD83E\uDE79))?|\uD83C(?:[\uDC04\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]\uFE0F?|[\uDF85\uDFC2\uDFC7](?:\uD83C[\uDFFB-\uDFFF])?|[\uDFC4\uDFCA](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDFCB\uDFCC](?:\uFE0F|\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF43\uDF45-\uDF4A\uDF4C-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uDDE6\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF]|\uDDE7\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF]|\uDDE8\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF5\uDDF7\uDDFA-\uDDFF]|\uDDE9\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF]|\uDDEA\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA]|\uDDEB\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7]|\uDDEC\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE]|\uDDED\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA]|\uDDEE\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9]|\uDDEF\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5]|\uDDF0\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF]|\uDDF1\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE]|\uDDF2\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF]|\uDDF3\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF]|\uDDF4\uD83C\uDDF2|\uDDF5\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE]|\uDDF6\uD83C\uDDE6|\uDDF7\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC]|\uDDF8\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF]|\uDDF9\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF]|\uDDFA\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF]|\uDDFB\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA]|\uDDFC\uD83C[\uDDEB\uDDF8]|\uDDFD\uD83C\uDDF0|\uDDFE\uD83C[\uDDEA\uDDF9]|\uDDFF\uD83C[\uDDE6\uDDF2\uDDFC]|\uDF44(?:\u200D\uD83D\uDFEB)?|\uDF4B(?:\u200D\uD83D\uDFE9)?|\uDFC3(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDFF3\uFE0F?(?:\u200D(?:\u26A7\uFE0F?|\uD83C\uDF08))?|\uDFF4(?:\u200D\u2620\uFE0F?|\uDB40\uDC67\uDB40\uDC62\uDB40(?:\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDC73\uDB40\uDC63\uDB40\uDC74|\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F)?)|\uD83D(?:[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3]\uFE0F?|[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC](?:\uD83C[\uDFFB-\uDFFF])?|[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4\uDEB5](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD74\uDD90](?:\uFE0F|\uD83C[\uDFFB-\uDFFF])?|[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC25\uDC27-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE41\uDE43\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED7\uDEDC-\uDEDF\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB\uDFF0]|\uDC08(?:\u200D\u2B1B)?|\uDC15(?:\u200D\uD83E\uDDBA)?|\uDC26(?:\u200D(?:\u2B1B|\uD83D\uDD25))?|\uDC3B(?:\u200D\u2744\uFE0F?)?|\uDC41\uFE0F?(?:\u200D\uD83D\uDDE8\uFE0F?)?|\uDC68(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDC68\uDC69]\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE])))?))?|\uDC69(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?[\uDC68\uDC69]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?|\uDC69\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?))|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFE])))?))?|\uDC6F(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDD75(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDE2E(?:\u200D\uD83D\uDCA8)?|\uDE35(?:\u200D\uD83D\uDCAB)?|\uDE36(?:\u200D\uD83C\uDF2B\uFE0F?)?|\uDE42(?:\u200D[\u2194\u2195]\uFE0F?)?|\uDEB6(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?)|\uD83E(?:[\uDD0C\uDD0F\uDD18-\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5\uDEC3-\uDEC5\uDEF0\uDEF2-\uDEF8](?:\uD83C[\uDFFB-\uDFFF])?|[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD\uDDCF\uDDD4\uDDD6-\uDDDD](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDDDE\uDDDF](?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD0D\uDD0E\uDD10-\uDD17\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCC\uDDD0\uDDE0-\uDDFF\uDE70-\uDE7C\uDE80-\uDE88\uDE90-\uDEBD\uDEBF-\uDEC2\uDECE-\uDEDB\uDEE0-\uDEE8]|\uDD3C(?:\u200D[\u2640\u2642]\uFE0F?|\uD83C[\uDFFB-\uDFFF])?|\uDDCE(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDDD1(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1|\uDDD1\u200D\uD83E\uDDD2(?:\u200D\uD83E\uDDD2)?|\uDDD2(?:\u200D\uD83E\uDDD2)?))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF])))?))?|\uDEF1(?:\uD83C(?:\uDFFB(?:\u200D\uD83E\uDEF2\uD83C[\uDFFC-\uDFFF])?|\uDFFC(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFD-\uDFFF])?|\uDFFD(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])?|\uDFFE(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFD\uDFFF])?|\uDFFF(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFE])?))?)/g;function Nr(r){return r===12288||r>=65281&&r<=65376||r>=65504&&r<=65510}function Tr(r){return r>=4352&&r<=4447||r===8986||r===8987||r===9001||r===9002||r>=9193&&r<=9196||r===9200||r===9203||r===9725||r===9726||r===9748||r===9749||r>=9800&&r<=9811||r===9855||r===9875||r===9889||r===9898||r===9899||r===9917||r===9918||r===9924||r===9925||r===9934||r===9940||r===9962||r===9970||r===9971||r===9973||r===9978||r===9981||r===9989||r===9994||r===9995||r===10024||r===10060||r===10062||r>=10067&&r<=10069||r===10071||r>=10133&&r<=10135||r===10160||r===10175||r===11035||r===11036||r===11088||r===11093||r>=11904&&r<=11929||r>=11931&&r<=12019||r>=12032&&r<=12245||r>=12272&&r<=12287||r>=12289&&r<=12350||r>=12353&&r<=12438||r>=12441&&r<=12543||r>=12549&&r<=12591||r>=12593&&r<=12686||r>=12688&&r<=12771||r>=12783&&r<=12830||r>=12832&&r<=12871||r>=12880&&r<=19903||r>=19968&&r<=42124||r>=42128&&r<=42182||r>=43360&&r<=43388||r>=44032&&r<=55203||r>=63744&&r<=64255||r>=65040&&r<=65049||r>=65072&&r<=65106||r>=65108&&r<=65126||r>=65128&&r<=65131||r>=94176&&r<=94180||r===94192||r===94193||r>=94208&&r<=100343||r>=100352&&r<=101589||r>=101632&&r<=101640||r>=110576&&r<=110579||r>=110581&&r<=110587||r===110589||r===110590||r>=110592&&r<=110882||r===110898||r>=110928&&r<=110930||r===110933||r>=110948&&r<=110951||r>=110960&&r<=111355||r===126980||r===127183||r===127374||r>=127377&&r<=127386||r>=127488&&r<=127490||r>=127504&&r<=127547||r>=127552&&r<=127560||r===127568||r===127569||r>=127584&&r<=127589||r>=127744&&r<=127776||r>=127789&&r<=127797||r>=127799&&r<=127868||r>=127870&&r<=127891||r>=127904&&r<=127946||r>=127951&&r<=127955||r>=127968&&r<=127984||r===127988||r>=127992&&r<=128062||r===128064||r>=128066&&r<=128252||r>=128255&&r<=128317||r>=128331&&r<=128334||r>=128336&&r<=128359||r===128378||r===128405||r===128406||r===128420||r>=128507&&r<=128591||r>=128640&&r<=128709||r===128716||r>=128720&&r<=128722||r>=128725&&r<=128727||r>=128732&&r<=128735||r===128747||r===128748||r>=128756&&r<=128764||r>=128992&&r<=129003||r===129008||r>=129292&&r<=129338||r>=129340&&r<=129349||r>=129351&&r<=129535||r>=129648&&r<=129660||r>=129664&&r<=129672||r>=129680&&r<=129725||r>=129727&&r<=129733||r>=129742&&r<=129755||r>=129760&&r<=129768||r>=129776&&r<=129784||r>=131072&&r<=196605||r>=196608&&r<=262141}var kr=r=>!(Nr(r)||Tr(r)),ju=/[^\x20-\x7F]/u;function Hu(r){if(!r)return 0;if(!ju.test(r))return r.length;r=r.replace(Sr()," ");let t=0;for(let i of r){let n=i.codePointAt(0);n<=31||n>=127&&n<=159||n>=768&&n<=879||(t+=kr(n)?1:2)}return t}var Oe=Hu;function Ne(r,t){if(typeof r=="string")return t(r);let i=new Map;return n(r);function n(a){if(i.has(a))return i.get(a);let h=s(a);return i.set(a,h),h}function s(a){switch(G(a)){case W:return t(a.map(n));case S:return t({...a,parts:a.parts.map(n)});case _:return t({...a,breakContents:n(a.breakContents),flatContents:n(a.flatContents)});case x:{let{expandedStates:h,contents:v}=a;return h?(h=h.map(n),v=h[0]):v=n(v),t({...a,contents:v,expandedStates:h})}case P:case L:case R:case N:case Y:return t({...a,contents:n(a.contents)});case U:case z:case I:case j:case B:case b:return t(a);default:throw new Q(a)}}}function Xe(r,t,i){let n=i,s=!1;function a(h){if(s)return!1;let v=t(h);v!==void 0&&(s=!0,n=v)}return we(r,a),n}function Wu(r){if(r.type===x&&r.break||r.type===B&&r.hard||r.type===b)return!0}function Ir(r){return Xe(r,Wu,!1)}function Lr(r){if(r.length>0){let t=y(!1,r,-1);!t.expandedStates&&!t.break&&(t.break="propagated")}return null}function Rr(r){let t=new Set,i=[];function n(a){if(a.type===b&&Lr(i),a.type===x){if(i.push(a),t.has(a))return!1;t.add(a)}}function s(a){a.type===x&&i.pop().break&&Lr(i)}we(r,n,s,!0)}function Mu(r){return r.type===B&&!r.hard?r.soft?"":" ":r.type===_?r.flatContents:r}function Yr(r){return Ne(r,Mu)}function Pr(r){for(r=[...r];r.length>=2&&y(!1,r,-2).type===B&&y(!1,r,-1).type===b;)r.length-=2;if(r.length>0){let t=Se(y(!1,r,-1));r[r.length-1]=t}return r}function Se(r){switch(G(r)){case L:case R:case x:case Y:case N:{let t=Se(r.contents);return{...r,contents:t}}case _:return{...r,breakContents:Se(r.breakContents),flatContents:Se(r.flatContents)};case S:return{...r,parts:Pr(r.parts)};case W:return Pr(r);case U:return r.replace(/[\n\r]*$/u,"");case P:case z:case I:case j:case B:case b:break;default:throw new Q(r)}return r}function Ze(r){return Se(Vu(r))}function $u(r){switch(G(r)){case S:if(r.parts.every(t=>t===""))return"";break;case x:if(!r.contents&&!r.id&&!r.break&&!r.expandedStates)return"";if(r.contents.type===x&&r.contents.id===r.id&&r.contents.break===r.break&&r.contents.expandedStates===r.expandedStates)return r.contents;break;case P:case L:case R:case Y:if(!r.contents)return"";break;case _:if(!r.flatContents&&!r.breakContents)return"";break;case W:{let t=[];for(let i of r){if(!i)continue;let[n,...s]=Array.isArray(i)?i:[i];typeof n=="string"&&typeof y(!1,t,-1)=="string"?t[t.length-1]+=n:t.push(n),t.push(...s)}return t.length===0?"":t.length===1?t[0]:t}case U:case z:case I:case j:case B:case N:case b:break;default:throw new Q(r)}return r}function Vu(r){return Ne(r,t=>$u(t))}function jr(r,t=qe){return Ne(r,i=>typeof i=="string"?be(t,i.split(`
76
+ `)):i)}function Uu(r){if(r.type===B)return!0}function Hr(r){return Xe(r,Uu,!1)}function Qe(r,t){return r.type===N?{...r,contents:t(r.contents)}:t(r)}var H=Symbol("MODE_BREAK"),J=Symbol("MODE_FLAT"),Te=Symbol("cursor");function Wr(){return{value:"",length:0,queue:[]}}function zu(r,t){return bt(r,{type:"indent"},t)}function Gu(r,t,i){return t===Number.NEGATIVE_INFINITY?r.root||Wr():t<0?bt(r,{type:"dedent"},i):t?t.type==="root"?{...r,root:r}:bt(r,{type:typeof t=="string"?"stringAlign":"numberAlign",n:t},i):r}function bt(r,t,i){let n=t.type==="dedent"?r.queue.slice(0,-1):[...r.queue,t],s="",a=0,h=0,v=0;for(let gi of n)switch(gi.type){case"indent":l(),i.useTabs?hi(1):u(i.tabWidth);break;case"stringAlign":l(),s+=gi.n,a+=gi.n.length;break;case"numberAlign":h+=1,v+=gi.n;break;default:throw new Error(`Unexpected type '${gi.type}'`)}return D(),{...r,value:s,length:a,queue:n};function hi(gi){s+=" ".repeat(gi),a+=i.tabWidth*gi}function u(gi){s+=" ".repeat(gi),a+=gi}function l(){i.useTabs?vi():D()}function vi(){h>0&&hi(h),mi()}function D(){v>0&&u(v),mi()}function mi(){h=0,v=0}}function Ot(r){let t=0,i=0,n=r.length;e:for(;n--;){let s=r[n];if(s===Te){i++;continue}for(let a=s.length-1;a>=0;a--){let h=s[a];if(h===" "||h===" ")t++;else{r[n]=s.slice(0,a+1);break e}}}if(t>0||i>0)for(r.length=n+1;i-- >0;)r.push(Te);return t}function et(r,t,i,n,s,a){if(i===Number.POSITIVE_INFINITY)return!0;let h=t.length,v=[r],hi=[];for(;i>=0;){if(v.length===0){if(h===0)return!0;v.push(t[--h]);continue}let{mode:u,doc:l}=v.pop(),vi=G(l);switch(vi){case U:hi.push(l),i-=Oe(l);break;case W:case S:{let D=vi===W?l:l.parts;for(let mi=D.length-1;mi>=0;mi--)v.push({mode:u,doc:D[mi]});break}case L:case P:case R:case N:v.push({mode:u,doc:l.contents});break;case I:i+=Ot(hi);break;case x:{if(a&&l.break)return!1;let D=l.break?H:u,mi=l.expandedStates&&D===H?y(!1,l.expandedStates,-1):l.contents;v.push({mode:D,doc:mi});break}case _:{let D=(l.groupId?s[l.groupId]||J:u)===H?l.breakContents:l.flatContents;D&&v.push({mode:u,doc:D});break}case B:if(u===H||l.hard)return!0;l.soft||(hi.push(" "),i--);break;case Y:n=!0;break;case j:if(n)return!1;break}}return!1}function Fe(r,t){let i={},n=t.printWidth,s=Be(t.endOfLine),a=0,h=[{ind:Wr(),mode:H,doc:r}],v=[],hi=!1,u=[],l=0;for(Rr(r);h.length>0;){let{ind:D,mode:mi,doc:gi}=h.pop();switch(G(gi)){case U:{let bi=s!==`
77
+ `?ne(!1,gi,`
78
+ `,s):gi;v.push(bi),h.length>0&&(a+=Oe(bi));break}case W:for(let bi=gi.length-1;bi>=0;bi--)h.push({ind:D,mode:mi,doc:gi[bi]});break;case z:if(l>=2)throw new Error("There are too many 'cursor' in doc.");v.push(Te),l++;break;case L:h.push({ind:zu(D,t),mode:mi,doc:gi.contents});break;case P:h.push({ind:Gu(D,gi.n,t),mode:mi,doc:gi.contents});break;case I:a-=Ot(v);break;case x:switch(mi){case J:if(!hi){h.push({ind:D,mode:gi.break?H:J,doc:gi.contents});break}case H:{hi=!1;let bi={ind:D,mode:J,doc:gi.contents},Ri=n-a,Ti=u.length>0;if(!gi.break&&et(bi,h,Ri,Ti,i))h.push(bi);else if(gi.expandedStates){let Ii=y(!1,gi.expandedStates,-1);if(gi.break){h.push({ind:D,mode:H,doc:Ii});break}else for(let qi=1;qi<gi.expandedStates.length+1;qi++)if(qi>=gi.expandedStates.length){h.push({ind:D,mode:H,doc:Ii});break}else{let Oi=gi.expandedStates[qi],ki={ind:D,mode:J,doc:Oi};if(et(ki,h,Ri,Ti,i)){h.push(ki);break}}}else h.push({ind:D,mode:H,doc:gi.contents});break}}gi.id&&(i[gi.id]=y(!1,h,-1).mode);break;case S:{let bi=n-a,{parts:Ri}=gi;if(Ri.length===0)break;let[Ti,Ii]=Ri,qi={ind:D,mode:J,doc:Ti},Oi={ind:D,mode:H,doc:Ti},ki=et(qi,[],bi,u.length>0,i,!0);if(Ri.length===1){ki?h.push(qi):h.push(Oi);break}let Li={ind:D,mode:J,doc:Ii},ji={ind:D,mode:H,doc:Ii};if(Ri.length===2){ki?h.push(Li,qi):h.push(ji,Oi);break}Ri.splice(0,2);let Hi={ind:D,mode:mi,doc:Ge(Ri)},Ui=Ri[0];et({ind:D,mode:J,doc:[Ti,Ii,Ui]},[],bi,u.length>0,i,!0)?h.push(Hi,Li,qi):ki?h.push(Hi,ji,qi):h.push(Hi,ji,Oi);break}case _:case R:{let bi=gi.groupId?i[gi.groupId]:mi;if(bi===H){let Ri=gi.type===_?gi.breakContents:gi.negate?gi.contents:De(gi.contents);Ri&&h.push({ind:D,mode:mi,doc:Ri})}if(bi===J){let Ri=gi.type===_?gi.flatContents:gi.negate?De(gi.contents):gi.contents;Ri&&h.push({ind:D,mode:mi,doc:Ri})}break}case Y:u.push({ind:D,mode:mi,doc:gi.contents});break;case j:u.length>0&&h.push({ind:D,mode:mi,doc:_e});break;case B:switch(mi){case J:if(gi.hard)hi=!0;else{gi.soft||(v.push(" "),a+=1);break}case H:if(u.length>0){h.push({ind:D,mode:mi,doc:gi},...u.reverse()),u.length=0;break}gi.literal?D.root?(v.push(s,D.root.value),a=D.root.length):(v.push(s),a=0):(a-=Ot(v),v.push(s+D.value),a=D.length);break}break;case N:h.push({ind:D,mode:mi,doc:gi.contents});break;case b:break;default:throw new Q(gi)}h.length===0&&u.length>0&&(h.push(...u.reverse()),u.length=0)}let vi=v.indexOf(Te);if(vi!==-1){let D=v.indexOf(Te,vi+1),mi=v.slice(0,vi).join(""),gi=v.slice(vi+1,D).join(""),bi=v.slice(D+1).join("");return{formatted:mi+gi+bi,cursorNodeStart:mi.length,cursorNodeText:gi}}return{formatted:v.join("")}}function Ku(r,t,i=0){let n=0;for(let s=i;s<r.length;++s)r[s]===" "?n=n+t-n%t:n++;return n}var me=Ku,te,Nt,tt,St=class{constructor(r){Dr(this,te),this.stack=[r]}get key(){let{stack:r,siblings:t}=this;return y(!1,r,t===null?-2:-4)??null}get index(){return this.siblings===null?null:y(!1,this.stack,-2)}get node(){return y(!1,this.stack,-1)}get parent(){return this.getNode(1)}get grandparent(){return this.getNode(2)}get isInArray(){return this.siblings!==null}get siblings(){let{stack:r}=this,t=y(!1,r,-3);return Array.isArray(t)?t:null}get next(){let{siblings:r}=this;return r===null?null:r[this.index+1]}get previous(){let{siblings:r}=this;return r===null?null:r[this.index-1]}get isFirst(){return this.index===0}get isLast(){let{siblings:r,index:t}=this;return r!==null&&t===r.length-1}get isRoot(){return this.stack.length===1}get root(){return this.stack[0]}get ancestors(){return[...pe(this,te,tt).call(this)]}getName(){let{stack:r}=this,{length:t}=r;return t>1?y(!1,r,-2):null}getValue(){return y(!1,this.stack,-1)}getNode(r=0){let t=pe(this,te,Nt).call(this,r);return t===-1?null:this.stack[t]}getParentNode(r=0){return this.getNode(r+1)}call(r,...t){let{stack:i}=this,{length:n}=i,s=y(!1,i,-1);for(let a of t)s=s[a],i.push(a,s);try{return r(this)}finally{i.length=n}}callParent(r,t=0){let i=pe(this,te,Nt).call(this,t+1),n=this.stack.splice(i+1);try{return r(this)}finally{this.stack.push(...n)}}each(r,...t){let{stack:i}=this,{length:n}=i,s=y(!1,i,-1);for(let a of t)s=s[a],i.push(a,s);try{for(let a=0;a<s.length;++a)i.push(a,s[a]),r(this,a,s),i.length-=2}finally{i.length=n}}map(r,...t){let i=[];return this.each((n,s,a)=>{i[s]=r(n,s,a)},...t),i}match(...r){let t=this.stack.length-1,i=null,n=this.stack[t--];for(let s of r){if(n===void 0)return!1;let a=null;if(typeof i=="number"&&(a=i,i=this.stack[t--],n=this.stack[t--]),s&&!s(n,i,a))return!1;i=this.stack[t--],n=this.stack[t--]}return!0}findAncestor(r){for(let t of pe(this,te,tt).call(this))if(r(t))return t}hasAncestor(r){for(let t of pe(this,te,tt).call(this))if(r(t))return!0;return!1}};te=new WeakSet,Nt=function(r){let{stack:t}=this;for(let i=t.length-1;i>=0;i-=2)if(!Array.isArray(t[i])&&--r<0)return i;return-1},tt=function*(){let{stack:r}=this;for(let t=r.length-3;t>=0;t-=2){let i=r[t];Array.isArray(i)||(yield i)}};var Mr=St,$r=new Proxy(()=>{},{get:()=>$r}),ke=$r;function qu(r){return r!==null&&typeof r=="object"}var Vr=qu;function*Tt(r,t){let{getVisitorKeys:i,filter:n=()=>!0}=t,s=a=>Vr(a)&&n(a);for(let a of i(r)){let h=r[a];if(Array.isArray(h))for(let v of h)s(v)&&(yield v);else s(h)&&(yield h)}}function*Ur(r,t){let i=[r];for(let n=0;n<i.length;n++){let s=i[n];for(let a of Tt(s,t))yield a,i.push(a)}}function Ee(r){return(t,i,n)=>{let s=!!(n!=null&&n.backwards);if(i===!1)return!1;let{length:a}=t,h=i;for(;h>=0&&h<a;){let v=t.charAt(h);if(r instanceof RegExp){if(!r.test(v))return h}else if(!r.includes(v))return h;s?h--:h++}return h===-1||h===a?h:!1}}var zr=Ee(/\s/u),T=Ee(" "),rt=Ee(",; "),nt=Ee(/[^\n\r]/u);function Ju(r,t,i){let n=!!(i!=null&&i.backwards);if(t===!1)return!1;let s=r.charAt(t);if(n){if(r.charAt(t-1)==="\r"&&s===`
79
+ `)return t-2;if(s===`
80
+ `||s==="\r"||s==="\u2028"||s==="\u2029")return t-1}else{if(s==="\r"&&r.charAt(t+1)===`
81
+ `)return t+2;if(s===`
82
+ `||s==="\r"||s==="\u2028"||s==="\u2029")return t+1}return t}var M=Ju;function Xu(r,t,i={}){let n=T(r,i.backwards?t-1:t,i),s=M(r,n,i);return n!==s}var V=Xu;function Zu(r){return Array.isArray(r)&&r.length>0}var kt=Zu,Gr=new Set(["tokens","comments","parent","enclosingNode","precedingNode","followingNode"]),Qu=r=>Object.keys(r).filter(t=>!Gr.has(t));function eo(r){return r?t=>r(t,Gr):Qu}var X=eo;function to(r){let t=r.type||r.kind||"(unknown type)",i=String(r.name||r.id&&(typeof r.id=="object"?r.id.name:r.id)||r.key&&(typeof r.key=="object"?r.key.name:r.key)||r.value&&(typeof r.value=="object"?"":String(r.value))||r.operator||"");return i.length>20&&(i=i.slice(0,19)+"…"),t+(i?" "+i:"")}function Lt(r,t){(r.comments??(r.comments=[])).push(t),t.printed=!1,t.nodeDescription=to(r)}function ue(r,t){t.leading=!0,t.trailing=!1,Lt(r,t)}function re(r,t,i){t.leading=!1,t.trailing=!1,i&&(t.marker=i),Lt(r,t)}function oe(r,t){t.leading=!1,t.trailing=!0,Lt(r,t)}var Pt=new WeakMap;function ut(r,t){if(Pt.has(r))return Pt.get(r);let{printer:{getCommentChildNodes:i,canAttachComment:n,getVisitorKeys:s},locStart:a,locEnd:h}=t;if(!n)return[];let v=(i?.(r,t)??[...Tt(r,{getVisitorKeys:X(s)})]).flatMap(hi=>n(hi)?[hi]:ut(hi,t));return v.sort((hi,u)=>a(hi)-a(u)||h(hi)-h(u)),Pt.set(r,v),v}function qr(r,t,i,n){let{locStart:s,locEnd:a}=i,h=s(t),v=a(t),hi=ut(r,i),u,l,vi=0,D=hi.length;for(;vi<D;){let mi=vi+D>>1,gi=hi[mi],bi=s(gi),Ri=a(gi);if(bi<=h&&v<=Ri)return qr(gi,t,i,gi);if(Ri<=h){u=gi,vi=mi+1;continue}if(v<=bi){l=gi,D=mi;continue}throw new Error("Comment location overlaps with node location")}if(n?.type==="TemplateLiteral"){let{quasis:mi}=n,gi=Rt(mi,t,i);u&&Rt(mi,u,i)!==gi&&(u=null),l&&Rt(mi,l,i)!==gi&&(l=null)}return{enclosingNode:n,precedingNode:u,followingNode:l}}var It=()=>!1;function Jr(r,t){let{comments:i}=r;if(delete r.comments,!kt(i)||!t.printer.canAttachComment)return;let n=[],{locStart:s,locEnd:a,printer:{experimentalFeatures:{avoidAstMutation:h=!1}={},handleComments:v={}},originalText:hi}=t,{ownLine:u=It,endOfLine:l=It,remaining:vi=It}=v,D=i.map((mi,gi)=>({...qr(r,mi,t),comment:mi,text:hi,options:t,ast:r,isLastComment:i.length-1===gi}));for(let[mi,gi]of D.entries()){let{comment:bi,precedingNode:Ri,enclosingNode:Ti,followingNode:Ii,text:qi,options:Oi,ast:ki,isLastComment:Li}=gi;if(Oi.parser==="json"||Oi.parser==="json5"||Oi.parser==="jsonc"||Oi.parser==="__js_expression"||Oi.parser==="__ts_expression"||Oi.parser==="__vue_expression"||Oi.parser==="__vue_ts_expression"){if(s(bi)-s(ki)<=0){ue(ki,bi);continue}if(a(bi)-a(ki)>=0){oe(ki,bi);continue}}let ji;if(h?ji=[gi]:(bi.enclosingNode=Ti,bi.precedingNode=Ri,bi.followingNode=Ii,ji=[bi,qi,Oi,ki,Li]),ro(qi,Oi,D,mi))bi.placement="ownLine",u(...ji)||(Ii?ue(Ii,bi):Ri?oe(Ri,bi):re(Ti||ki,bi));else if(no(qi,Oi,D,mi))bi.placement="endOfLine",l(...ji)||(Ri?oe(Ri,bi):Ii?ue(Ii,bi):re(Ti||ki,bi));else if(bi.placement="remaining",!vi(...ji))if(Ri&&Ii){let Hi=n.length;Hi>0&&n[Hi-1].followingNode!==Ii&&Kr(n,Oi),n.push(gi)}else Ri?oe(Ri,bi):Ii?ue(Ii,bi):re(Ti||ki,bi)}if(Kr(n,t),!h)for(let mi of i)delete mi.precedingNode,delete mi.enclosingNode,delete mi.followingNode}var Xr=r=>!/[\S\n\u2028\u2029]/u.test(r);function ro(r,t,i,n){let{comment:s,precedingNode:a}=i[n],{locStart:h,locEnd:v}=t,hi=h(s);if(a)for(let u=n-1;u>=0;u--){let{comment:l,precedingNode:vi}=i[u];if(vi!==a||!Xr(r.slice(v(l),hi)))break;hi=h(l)}return V(r,hi,{backwards:!0})}function no(r,t,i,n){let{comment:s,followingNode:a}=i[n],{locStart:h,locEnd:v}=t,hi=v(s);if(a)for(let u=n+1;u<i.length;u++){let{comment:l,followingNode:vi}=i[u];if(vi!==a||!Xr(r.slice(hi,h(l))))break;hi=v(l)}return V(r,hi)}function Kr(r,t){var i,n;let s=r.length;if(s===0)return;let{precedingNode:a,followingNode:h}=r[0],v=t.locStart(h),hi;for(hi=s;hi>0;--hi){let{comment:u,precedingNode:l,followingNode:vi}=r[hi-1];ke.strictEqual(l,a),ke.strictEqual(vi,h);let D=t.originalText.slice(t.locEnd(u),v);if(((n=(i=t.printer).isGap)==null?void 0:n.call(i,D,t))??/^[\s(]*$/u.test(D))v=t.locStart(u);else break}for(let[u,{comment:l}]of r.entries())u<hi?oe(a,l):ue(h,l);for(let u of[a,h])u.comments&&u.comments.length>1&&u.comments.sort((l,vi)=>t.locStart(l)-t.locStart(vi));r.length=0}function Rt(r,t,i){let n=i.locStart(t)-1;for(let s=1;s<r.length;++s)if(n<i.locStart(r[s]))return s-1;return 0}function uo(r,t){let i=t-1;i=T(r,i,{backwards:!0}),i=M(r,i,{backwards:!0}),i=T(r,i,{backwards:!0});let n=M(r,i,{backwards:!0});return i!==n}var Le=uo;function Zr(r,t){let i=r.node;return i.printed=!0,t.printer.printComment(r,t)}function oo(r,t){var i;let n=r.node,s=[Zr(r,t)],{printer:a,originalText:h,locStart:v,locEnd:hi}=t;if((i=a.isBlockComment)!=null&&i.call(a,n)){let l=V(h,hi(n))?V(h,v(n),{backwards:!0})?q:Ke:" ";s.push(l)}else s.push(q);let u=M(h,T(h,hi(n)));return u!==!1&&V(h,u)&&s.push(q),s}function io(r,t,i){var n;let s=r.node,a=Zr(r,t),{printer:h,originalText:v,locStart:hi}=t,u=(n=h.isBlockComment)==null?void 0:n.call(h,s);if(i!=null&&i.hasLineSuffix&&!(i!=null&&i.isBlock)||V(v,hi(s),{backwards:!0})){let l=Le(v,hi(s));return{doc:xe([q,l?q:"",a]),isBlock:u,hasLineSuffix:!0}}return!u||i!=null&&i.hasLineSuffix?{doc:[xe([" ",a]),de],isBlock:u,hasLineSuffix:!0}:{doc:[" ",a],isBlock:u,hasLineSuffix:!1}}function so(r,t){let i=r.node;if(!i)return{};let n=t[Symbol.for("printedComments")];if((i.comments||[]).filter(v=>!n.has(v)).length===0)return{leading:"",trailing:""};let s=[],a=[],h;return r.each(()=>{let v=r.node;if(n!=null&&n.has(v))return;let{leading:hi,trailing:u}=v;hi?s.push(oo(r,t)):u&&(h=io(r,t,h),a.push(h.doc))},"comments"),{leading:s,trailing:a}}function Qr(r,t,i){let{leading:n,trailing:s}=so(r,i);return!n&&!s?t:Qe(t,a=>[n,a,s])}function en(r){let{[Symbol.for("comments")]:t,[Symbol.for("printedComments")]:i}=r;for(let n of t){if(!n.printed&&!i.has(n))throw new Error('Comment "'+n.value.trim()+'" was not printed. Please report this error!');delete n.printed}}var Pe=class extends Error{name="ConfigError"},Ie=class extends Error{name="UndefinedParserError"},rn={cursorOffset:{category:"Special",type:"int",default:-1,range:{start:-1,end:1/0,step:1},description:"Print (to stderr) where a cursor at the given position would move to after formatting.",cliCategory:"Editor"},endOfLine:{category:"Global",type:"choice",default:"lf",description:"Which end of line characters to apply.",choices:[{value:"lf",description:"Line Feed only (\\n), common on Linux and macOS as well as inside git repos"},{value:"crlf",description:"Carriage Return + Line Feed characters (\\r\\n), common on Windows"},{value:"cr",description:"Carriage Return character only (\\r), used very rarely"},{value:"auto",description:`Maintain existing
83
+ (mixed values within one file are normalised by looking at what's used after the first line)`}]},filepath:{category:"Special",type:"path",description:"Specify the input filepath. This will be used to do parser inference.",cliName:"stdin-filepath",cliCategory:"Other",cliDescription:"Path to the file to pretend that stdin comes from."},insertPragma:{category:"Special",type:"boolean",default:!1,description:"Insert @format pragma into file's first docblock comment.",cliCategory:"Other"},parser:{category:"Global",type:"choice",default:void 0,description:"Which parser to use.",exception:r=>typeof r=="string"||typeof r=="function",choices:[{value:"flow",description:"Flow"},{value:"babel",description:"JavaScript"},{value:"babel-flow",description:"Flow"},{value:"babel-ts",description:"TypeScript"},{value:"typescript",description:"TypeScript"},{value:"acorn",description:"JavaScript"},{value:"espree",description:"JavaScript"},{value:"meriyah",description:"JavaScript"},{value:"css",description:"CSS"},{value:"less",description:"Less"},{value:"scss",description:"SCSS"},{value:"json",description:"JSON"},{value:"json5",description:"JSON5"},{value:"jsonc",description:"JSON with Comments"},{value:"json-stringify",description:"JSON.stringify"},{value:"graphql",description:"GraphQL"},{value:"markdown",description:"Markdown"},{value:"mdx",description:"MDX"},{value:"vue",description:"Vue"},{value:"yaml",description:"YAML"},{value:"glimmer",description:"Ember / Handlebars"},{value:"html",description:"HTML"},{value:"angular",description:"Angular"},{value:"lwc",description:"Lightning Web Components"}]},plugins:{type:"path",array:!0,default:[{value:[]}],category:"Global",description:"Add a plugin. Multiple plugins can be passed as separate `--plugin`s.",exception:r=>typeof r=="string"||typeof r=="object",cliName:"plugin",cliCategory:"Config"},printWidth:{category:"Global",type:"int",default:80,description:"The line length where Prettier will try wrap.",range:{start:0,end:1/0,step:1}},rangeEnd:{category:"Special",type:"int",default:1/0,range:{start:0,end:1/0,step:1},description:`Format code ending at a given character offset (exclusive).
84
+ The range will extend forwards to the end of the selected statement.`,cliCategory:"Editor"},rangeStart:{category:"Special",type:"int",default:0,range:{start:0,end:1/0,step:1},description:`Format code starting at a given character offset.
85
+ The range will extend backwards to the start of the first line containing the selected statement.`,cliCategory:"Editor"},requirePragma:{category:"Special",type:"boolean",default:!1,description:`Require either '@prettier' or '@format' to be present in the file's first docblock comment
86
+ in order for it to be formatted.`,cliCategory:"Other"},tabWidth:{type:"int",category:"Global",default:2,description:"Number of spaces per indentation level.",range:{start:0,end:1/0,step:1}},useTabs:{category:"Global",type:"boolean",default:!1,description:"Indent with tabs instead of spaces."},embeddedLanguageFormatting:{category:"Global",type:"choice",default:"auto",description:"Control how Prettier formats quoted code embedded in the file.",choices:[{value:"auto",description:"Format embedded code if Prettier can automatically identify it."},{value:"off",description:"Never automatically format embedded code."}]}};function ot({plugins:r=[],showDeprecated:t=!1}={}){let i=r.flatMap(s=>s.languages??[]),n=[];for(let s of lo(Object.assign({},...r.map(({options:a})=>a),rn)))!t&&s.deprecated||(Array.isArray(s.choices)&&(t||(s.choices=s.choices.filter(a=>!a.deprecated)),s.name==="parser"&&(s.choices=[...s.choices,...Do(s.choices,i,r)])),s.pluginDefaults=Object.fromEntries(r.filter(a=>{var h;return((h=a.defaultOptions)==null?void 0:h[s.name])!==void 0}).map(a=>[a.name,a.defaultOptions[s.name]])),n.push(s));return{languages:i,options:n}}function*Do(r,t,i){let n=new Set(r.map(s=>s.value));for(let s of t)if(s.parsers){for(let a of s.parsers)if(!n.has(a)){n.add(a);let h=i.find(hi=>hi.parsers&&Object.prototype.hasOwnProperty.call(hi.parsers,a)),v=s.name;h!=null&&h.name&&(v+=` (plugin: ${h.name})`),yield{value:a,description:v}}}}function lo(r){let t=[];for(let[i,n]of Object.entries(r)){let s={name:i,...n};Array.isArray(s.default)&&(s.default=y(!1,s.default,-1).value),t.push(s)}return t}var co=r=>String(r).split(/[/\\]/u).pop();function nn(r,t){if(!t)return;let i=co(t).toLowerCase();return r.find(({filenames:n})=>n?.some(s=>s.toLowerCase()===i))??r.find(({extensions:n})=>n?.some(s=>i.endsWith(s)))}function fo(r,t){if(t)return r.find(({name:i})=>i.toLowerCase()===t)??r.find(({aliases:i})=>i?.includes(t))??r.find(({extensions:i})=>i?.includes(`.${t}`))}function po(r,t){let i=r.plugins.flatMap(s=>s.languages??[]),n=fo(i,t.language)??nn(i,t.physicalFile)??nn(i,t.file)??(t.physicalFile,void 0);return n?.parsers[0]}var un=po,ie={key:r=>/^[$_a-zA-Z][$_a-zA-Z0-9]*$/.test(r)?r:JSON.stringify(r),value(r){if(r===null||typeof r!="object")return JSON.stringify(r);if(Array.isArray(r))return`[${r.map(i=>ie.value(i)).join(", ")}]`;let t=Object.keys(r);return t.length===0?"{}":`{ ${t.map(i=>`${ie.key(i)}: ${ie.value(r[i])}`).join(", ")} }`},pair:({key:r,value:t})=>ie.value({[r]:t})},Yt=Me(it()),an=(r,t,{descriptor:i})=>{let n=[`${Yt.default.yellow(typeof r=="string"?i.key(r):i.pair(r))} is deprecated`];return t&&n.push(`we now treat it as ${Yt.default.blue(typeof t=="string"?i.key(t):i.pair(t))}`),n.join("; ")+"."},le=Me(it()),st=Symbol.for("vnopts.VALUE_NOT_EXIST"),he=Symbol.for("vnopts.VALUE_UNCHANGED"),Dn=" ".repeat(2),cn=(r,t,i)=>{let{text:n,list:s}=i.normalizeExpectedResult(i.schemas[r].expected(i)),a=[];return n&&a.push(ln(r,t,n,i.descriptor)),s&&a.push([ln(r,t,s.title,i.descriptor)].concat(s.values.map(h=>fn(h,i.loggerPrintWidth))).join(`
87
+ `)),pn(a,i.loggerPrintWidth)};function ln(r,t,i,n){return[`Invalid ${le.default.red(n.key(r))} value.`,`Expected ${le.default.blue(i)},`,`but received ${t===st?le.default.gray("nothing"):le.default.red(n.value(t))}.`].join(" ")}function fn({text:r,list:t},i){let n=[];return r&&n.push(`- ${le.default.blue(r)}`),t&&n.push([`- ${le.default.blue(t.title)}:`].concat(t.values.map(s=>fn(s,i-Dn.length).replace(/^|\n/g,`$&${Dn}`))).join(`
88
+ `)),pn(n,i)}function pn(r,t){if(r.length===1)return r[0];let[i,n]=r,[s,a]=r.map(h=>h.split(`
89
+ `,1)[0].length);return s>t&&s>a?n:i}var Wt=Me(it()),jt=[],dn=[];function Ht(r,t){if(r===t)return 0;let i=r;r.length>t.length&&(r=t,t=i);let n=r.length,s=t.length;for(;n>0&&r.charCodeAt(~-n)===t.charCodeAt(~-s);)n--,s--;let a=0;for(;a<n&&r.charCodeAt(a)===t.charCodeAt(a);)a++;if(n-=a,s-=a,n===0)return s;let h,v,hi,u,l=0,vi=0;for(;l<n;)dn[l]=r.charCodeAt(a+l),jt[l]=++l;for(;vi<s;)for(h=t.charCodeAt(a+vi),hi=vi++,v=vi,l=0;l<n;l++)u=h===dn[l]?hi:hi+1,hi=jt[l],v=jt[l]=hi>v?u>v?v+1:u:u>hi?hi+1:u;return v}var at=(r,t,{descriptor:i,logger:n,schemas:s})=>{let a=[`Ignored unknown option ${Wt.default.yellow(i.pair({key:r,value:t}))}.`],h=Object.keys(s).sort().find(v=>Ht(r,v)<3);h&&a.push(`Did you mean ${Wt.default.blue(i.key(h))}?`),n.warn(a.join(" "))},Fo=["default","expected","validate","deprecated","forward","redirect","overlap","preprocess","postprocess"];function mo(r,t){let i=new r(t),n=Object.create(i);for(let s of Fo)s in t&&(n[s]=Eo(t[s],i,O.prototype[s].length));return n}var O=class{static create(r){return mo(this,r)}constructor(r){this.name=r.name}default(r){}expected(r){return"nothing"}validate(r,t){return!1}deprecated(r,t){return!1}forward(r,t){}redirect(r,t){}overlap(r,t,i){return r}preprocess(r,t){return r}postprocess(r,t){return he}};function Eo(r,t,i){return typeof r=="function"?(...n)=>r(...n.slice(0,i-1),t,...n.slice(i-1)):()=>r}var Dt=class extends O{constructor(r){super(r),this._sourceName=r.sourceName}expected(r){return r.schemas[this._sourceName].expected(r)}validate(r,t){return t.schemas[this._sourceName].validate(r,t)}redirect(r,t){return this._sourceName}},lt=class extends O{expected(){return"anything"}validate(){return!0}},ct=class extends O{constructor({valueSchema:r,name:t=r.name,...i}){super({...i,name:t}),this._valueSchema=r}expected(r){let{text:t,list:i}=r.normalizeExpectedResult(this._valueSchema.expected(r));return{text:t&&`an array of ${t}`,list:i&&{title:"an array of the following values",values:[{list:i}]}}}validate(r,t){if(!Array.isArray(r))return!1;let i=[];for(let n of r){let s=t.normalizeValidateResult(this._valueSchema.validate(n,t),n);s!==!0&&i.push(s.value)}return i.length===0?!0:{value:i}}deprecated(r,t){let i=[];for(let n of r){let s=t.normalizeDeprecatedResult(this._valueSchema.deprecated(n,t),n);s!==!1&&i.push(...s.map(({value:a})=>({value:[a]})))}return i}forward(r,t){let i=[];for(let n of r){let s=t.normalizeForwardResult(this._valueSchema.forward(n,t),n);i.push(...s.map(Fn))}return i}redirect(r,t){let i=[],n=[];for(let s of r){let a=t.normalizeRedirectResult(this._valueSchema.redirect(s,t),s);"remain"in a&&i.push(a.remain),n.push(...a.redirect.map(Fn))}return i.length===0?{redirect:n}:{redirect:n,remain:i}}overlap(r,t){return r.concat(t)}};function Fn({from:r,to:t}){return{from:[r],to:t}}var ft=class extends O{expected(){return"true or false"}validate(r){return typeof r=="boolean"}};function En(r,t){let i=Object.create(null);for(let n of r){let s=n[t];if(i[s])throw new Error(`Duplicate ${t} ${JSON.stringify(s)}`);i[s]=n}return i}function hn(r,t){let i=new Map;for(let n of r){let s=n[t];if(i.has(s))throw new Error(`Duplicate ${t} ${JSON.stringify(s)}`);i.set(s,n)}return i}function Cn(){let r=Object.create(null);return t=>{let i=JSON.stringify(t);return r[i]?!0:(r[i]=!0,!1)}}function gn(r,t){let i=[],n=[];for(let s of r)t(s)?i.push(s):n.push(s);return[i,n]}function yn(r){return r===Math.floor(r)}function An(r,t){if(r===t)return 0;let i=typeof r,n=typeof t,s=["undefined","object","boolean","number","string"];return i!==n?s.indexOf(i)-s.indexOf(n):i!=="string"?Number(r)-Number(t):r.localeCompare(t)}function Bn(r){return(...t)=>{let i=r(...t);return typeof i=="string"?new Error(i):i}}function Mt(r){return r===void 0?{}:r}function $t(r){if(typeof r=="string")return{text:r};let{text:t,list:i}=r;return ho((t||i)!==void 0,"Unexpected `expected` result, there should be at least one field."),i?{text:t,list:{title:i.title,values:i.values.map($t)}}:{text:t}}function Vt(r,t){return r===!0?!0:r===!1?{value:t}:r}function Ut(r,t,i=!1){return r===!1?!1:r===!0?i?!0:[{value:t}]:"value"in r?[r]:r.length===0?!1:r}function mn(r,t){return typeof r=="string"||"key"in r?{from:t,to:r}:"from"in r?{from:r.from,to:r.to}:{from:t,to:r.to}}function pt(r,t){return r===void 0?[]:Array.isArray(r)?r.map(i=>mn(i,t)):[mn(r,t)]}function zt(r,t){let i=pt(typeof r=="object"&&"redirect"in r?r.redirect:r,t);return i.length===0?{remain:t,redirect:i}:typeof r=="object"&&"remain"in r?{remain:r.remain,redirect:i}:{redirect:i}}function ho(r,t){if(!r)throw new Error(t)}var dt=class extends O{constructor(r){super(r),this._choices=hn(r.choices.map(t=>t&&typeof t=="object"?t:{value:t}),"value")}expected({descriptor:r}){let t=Array.from(this._choices.keys()).map(s=>this._choices.get(s)).filter(({hidden:s})=>!s).map(s=>s.value).sort(An).map(r.value),i=t.slice(0,-2),n=t.slice(-2);return{text:i.concat(n.join(" or ")).join(", "),list:{title:"one of the following values",values:t}}}validate(r){return this._choices.has(r)}deprecated(r){let t=this._choices.get(r);return t&&t.deprecated?{value:r}:!1}forward(r){let t=this._choices.get(r);return t?t.forward:void 0}redirect(r){let t=this._choices.get(r);return t?t.redirect:void 0}},Ft=class extends O{expected(){return"a number"}validate(r,t){return typeof r=="number"}},mt=class extends Ft{expected(){return"an integer"}validate(r,t){return t.normalizeValidateResult(super.validate(r,t),r)===!0&&yn(r)}},Re=class extends O{expected(){return"a string"}validate(r){return typeof r=="string"}},wn=ie,xn=at,_n=cn,vn=an,Et=class{constructor(r,t){let{logger:i=console,loggerPrintWidth:n=80,descriptor:s=wn,unknown:a=xn,invalid:h=_n,deprecated:v=vn,missing:hi=()=>!1,required:u=()=>!1,preprocess:l=D=>D,postprocess:vi=()=>he}=t||{};this._utils={descriptor:s,logger:i||{warn:()=>{}},loggerPrintWidth:n,schemas:En(r,"name"),normalizeDefaultResult:Mt,normalizeExpectedResult:$t,normalizeDeprecatedResult:Ut,normalizeForwardResult:pt,normalizeRedirectResult:zt,normalizeValidateResult:Vt},this._unknownHandler=a,this._invalidHandler=Bn(h),this._deprecatedHandler=v,this._identifyMissing=(D,mi)=>!(D in mi)||hi(D,mi),this._identifyRequired=u,this._preprocess=l,this._postprocess=vi,this.cleanHistory()}cleanHistory(){this._hasDeprecationWarned=Cn()}normalize(r){let t={},i=[this._preprocess(r,this._utils)],n=()=>{for(;i.length!==0;){let s=i.shift(),a=this._applyNormalization(s,t);i.push(...a)}};n();for(let s of Object.keys(this._utils.schemas)){let a=this._utils.schemas[s];if(!(s in t)){let h=Mt(a.default(this._utils));"value"in h&&i.push({[s]:h.value})}}n();for(let s of Object.keys(this._utils.schemas)){if(!(s in t))continue;let a=this._utils.schemas[s],h=t[s],v=a.postprocess(h,this._utils);v!==he&&(this._applyValidation(v,s,a),t[s]=v)}return this._applyPostprocess(t),this._applyRequiredCheck(t),t}_applyNormalization(r,t){let i=[],{knownKeys:n,unknownKeys:s}=this._partitionOptionKeys(r);for(let a of n){let h=this._utils.schemas[a],v=h.preprocess(r[a],this._utils);this._applyValidation(v,a,h);let hi=({from:vi,to:D})=>{i.push(typeof D=="string"?{[D]:vi}:{[D.key]:D.value})},u=({value:vi,redirectTo:D})=>{let mi=Ut(h.deprecated(vi,this._utils),v,!0);if(mi!==!1)if(mi===!0)this._hasDeprecationWarned(a)||this._utils.logger.warn(this._deprecatedHandler(a,D,this._utils));else for(let{value:gi}of mi){let bi={key:a,value:gi};if(!this._hasDeprecationWarned(bi)){let Ri=typeof D=="string"?{key:D,value:gi}:D;this._utils.logger.warn(this._deprecatedHandler(bi,Ri,this._utils))}}};pt(h.forward(v,this._utils),v).forEach(hi);let l=zt(h.redirect(v,this._utils),v);if(l.redirect.forEach(hi),"remain"in l){let vi=l.remain;t[a]=a in t?h.overlap(t[a],vi,this._utils):vi,u({value:vi})}for(let{from:vi,to:D}of l.redirect)u({value:vi,redirectTo:D})}for(let a of s){let h=r[a];this._applyUnknownHandler(a,h,t,(v,hi)=>{i.push({[v]:hi})})}return i}_applyRequiredCheck(r){for(let t of Object.keys(this._utils.schemas))if(this._identifyMissing(t,r)&&this._identifyRequired(t))throw this._invalidHandler(t,st,this._utils)}_partitionOptionKeys(r){let[t,i]=gn(Object.keys(r).filter(n=>!this._identifyMissing(n,r)),n=>n in this._utils.schemas);return{knownKeys:t,unknownKeys:i}}_applyValidation(r,t,i){let n=Vt(i.validate(r,this._utils),r);if(n!==!0)throw this._invalidHandler(t,n.value,this._utils)}_applyUnknownHandler(r,t,i,n){let s=this._unknownHandler(r,t,this._utils);if(s)for(let a of Object.keys(s)){if(this._identifyMissing(a,s))continue;let h=s[a];a in this._utils.schemas?n(a,h):i[a]=h}}_applyPostprocess(r){let t=this._postprocess(r,this._utils);if(t!==he){if(t.delete)for(let i of t.delete)delete r[i];if(t.override){let{knownKeys:i,unknownKeys:n}=this._partitionOptionKeys(t.override);for(let s of i){let a=t.override[s];this._applyValidation(a,s,this._utils.schemas[s]),r[s]=a}for(let s of n){let a=t.override[s];this._applyUnknownHandler(s,a,r,(h,v)=>{let hi=this._utils.schemas[h];this._applyValidation(v,h,hi),r[h]=v})}}}}},Gt;function go(r,t,{logger:i=!1,isCLI:n=!1,passThrough:s=!1,FlagSchema:a,descriptor:h}={}){if(n){if(!a)throw new Error("'FlagSchema' option is required.");if(!h)throw new Error("'descriptor' option is required.")}else h=ie;let v=s?Array.isArray(s)?(D,mi)=>s.includes(D)?{[D]:mi}:void 0:(D,mi)=>({[D]:mi}):(D,mi,gi)=>{let{_:bi,...Ri}=gi.schemas;return at(D,mi,{...gi,schemas:Ri})},hi=yo(t,{isCLI:n,FlagSchema:a}),u=new Et(hi,{logger:i,unknown:v,descriptor:h}),l=i!==!1;l&&Gt&&(u._hasDeprecationWarned=Gt);let vi=u.normalize(r);return l&&(Gt=u._hasDeprecationWarned),vi}function yo(r,{isCLI:t,FlagSchema:i}){let n=[];t&&n.push(lt.create({name:"_"}));for(let s of r)n.push(Ao(s,{isCLI:t,optionInfos:r,FlagSchema:i})),s.alias&&t&&n.push(Dt.create({name:s.alias,sourceName:s.name}));return n}function Ao(r,{isCLI:t,optionInfos:i,FlagSchema:n}){let{name:s}=r,a={name:s},h,v={};switch(r.type){case"int":h=mt,t&&(a.preprocess=Number);break;case"string":h=Re;break;case"choice":h=dt,a.choices=r.choices.map(hi=>hi!=null&&hi.redirect?{...hi,redirect:{to:{key:r.name,value:hi.redirect}}}:hi);break;case"boolean":h=ft;break;case"flag":h=n,a.flags=i.flatMap(hi=>[hi.alias,hi.description&&hi.name,hi.oppositeDescription&&`no-${hi.name}`].filter(Boolean));break;case"path":h=Re;break;default:throw new Error(`Unexpected type ${r.type}`)}if(r.exception?a.validate=(hi,u,l)=>r.exception(hi)||u.validate(hi,l):a.validate=(hi,u,l)=>hi===void 0||u.validate(hi,l),r.redirect&&(v.redirect=hi=>hi?{to:typeof r.redirect=="string"?r.redirect:{key:r.redirect.option,value:r.redirect.value}}:void 0),r.deprecated&&(v.deprecated=!0),t&&!r.array){let hi=a.preprocess||(u=>u);a.preprocess=(u,l,vi)=>l.preprocess(hi(Array.isArray(u)?y(!1,u,-1):u),vi)}return r.array?ct.create({...t?{preprocess:hi=>Array.isArray(hi)?hi:[hi]}:{},...v,valueSchema:h.create(a)}):h.create({...a,...v})}var bn$6=go,Bo=(r,t,i)=>{if(!(r&&t==null)){if(t.findLast)return t.findLast(i);for(let n=t.length-1;n>=0;n--){let s=t[n];if(i(s,n,t))return s}}},Kt=Bo;function qt(r,t){if(!t)throw new Error("parserName is required.");let i=Kt(!1,r,s=>s.parsers&&Object.prototype.hasOwnProperty.call(s.parsers,t));if(i)return i;let n=`Couldn't resolve parser "${t}".`;throw n+=" Plugins must be explicitly added to the standalone bundle.",new Pe(n)}function On(r,t){if(!t)throw new Error("astFormat is required.");let i=Kt(!1,r,s=>s.printers&&Object.prototype.hasOwnProperty.call(s.printers,t));if(i)return i;let n=`Couldn't find plugin for AST format "${t}".`;throw n+=" Plugins must be explicitly added to the standalone bundle.",new Pe(n)}function ht({plugins:r,parser:t}){let i=qt(r,t);return Jt(i,t)}function Jt(r,t){let i=r.parsers[t];return typeof i=="function"?i():i}function Sn(r,t){let i=r.printers[t];return typeof i=="function"?i():i}var Nn={astFormat:"estree",printer:{},originalText:void 0,locStart:null,locEnd:null};async function wo(r,t={}){var i;let n={...r};if(!n.parser)if(n.filepath){if(n.parser=un(n,{physicalFile:n.filepath}),!n.parser)throw new Ie(`No parser could be inferred for file "${n.filepath}".`)}else throw new Ie("No parser and no file path given, couldn't infer a parser.");let s=ot({plugins:r.plugins,showDeprecated:!0}).options,a={...Nn,...Object.fromEntries(s.filter(D=>D.default!==void 0).map(D=>[D.name,D.default]))},h=qt(n.plugins,n.parser),v=await Jt(h,n.parser);n.astFormat=v.astFormat,n.locEnd=v.locEnd,n.locStart=v.locStart;let hi=(i=h.printers)!=null&&i[v.astFormat]?h:On(n.plugins,v.astFormat),u=await Sn(hi,v.astFormat);n.printer=u;let l=hi.defaultOptions?Object.fromEntries(Object.entries(hi.defaultOptions).filter(([,D])=>D!==void 0)):{},vi={...a,...l};for(let[D,mi]of Object.entries(vi))(n[D]===null||n[D]===void 0)&&(n[D]=mi);return n.parser==="json"&&(n.trailingComma="none"),bn$6(n,s,{passThrough:Object.keys(Nn),...t})}var se=wo,Vn=Me($n());async function ko(r,t){let i=await ht(t),n=i.preprocess?i.preprocess(r,t):r;t.originalText=n;let s;try{s=await i.parse(n,t,t)}catch(a){Lo(a,r)}return{text:n,ast:s}}function Lo(r,t){let{loc:i}=r;if(i){let n=(0,Vn.codeFrameColumns)(t,i,{highlightCode:!0});throw r.message+=`
90
+ `+n,r.codeFrame=n,r}throw r}var ce=ko;async function Un(r,t,i,n,s){let{embeddedLanguageFormatting:a,printer:{embed:h,hasPrettierIgnore:v=()=>!1,getVisitorKeys:hi}}=i;if(!h||a!=="auto")return;if(h.length>2)throw new Error("printer.embed has too many parameters. The API changed in Prettier v3. Please update your plugin. See https://prettier.io/docs/en/plugins.html#optional-embed");let u=X(h.getVisitorKeys??hi),l=[];mi();let vi=r.stack;for(let{print:gi,node:bi,pathStack:Ri}of l)try{r.stack=Ri;let Ti=await gi(D,t,r,i);Ti&&s.set(bi,Ti)}catch(Ti){if(globalThis.PRETTIER_DEBUG)throw Ti}r.stack=vi;function D(gi,bi){return Po(gi,bi,i,n)}function mi(){let{node:gi}=r;if(gi===null||typeof gi!="object"||v(r))return;for(let Ri of u(gi))Array.isArray(gi[Ri])?r.each(mi,Ri):r.call(mi,Ri);let bi=h(r,i);if(bi){if(typeof bi=="function"){l.push({print:bi,node:gi,pathStack:[...r.stack]});return}s.set(gi,bi)}}}async function Po(r,t,i,n){let s=await se({...i,...t,parentParser:i.parser,originalText:r},{passThrough:!0}),{ast:a}=await ce(r,s),h=await n(a,s);return Ze(h)}function Io(r,t){let{originalText:i,[Symbol.for("comments")]:n,locStart:s,locEnd:a,[Symbol.for("printedComments")]:h}=t,{node:v}=r,hi=s(v),u=a(v);for(let l of n)s(l)>=hi&&a(l)<=u&&h.add(l);return i.slice(hi,u)}var zn=Io;async function Ye(r,t){({ast:r}=await Qt(r,t));let i=new Map,n=new Mr(r),s=new Map;await Un(n,h,t,Ye,s);let a=await Gn(n,t,h,void 0,s);return en(t),a;function h(hi,u){return hi===void 0||hi===n?v(u):Array.isArray(hi)?n.call(()=>v(u),...hi):n.call(()=>v(u),hi)}function v(hi){let u=n.node;if(u==null)return"";let l=u&&typeof u=="object"&&hi===void 0;if(l&&i.has(u))return i.get(u);let vi=Gn(n,t,h,hi,s);return l&&i.set(u,vi),vi}}function Gn(r,t,i,n,s){var a;let{node:h}=r,{printer:v}=t,hi;return(a=v.hasPrettierIgnore)!=null&&a.call(v,r)?hi=zn(r,t):s.has(h)?hi=s.get(h):hi=v.print(r,t,i,n),h===t.cursorNode&&(hi=Qe(hi,u=>[ve,u,ve])),v.printComment&&(!v.willPrintOwnComments||!v.willPrintOwnComments(r,t))&&(hi=Qr(r,hi,t)),hi}async function Qt(r,t){let i=r.comments??[];t[Symbol.for("comments")]=i,t[Symbol.for("tokens")]=r.tokens??[],t[Symbol.for("printedComments")]=new Set,Jr(r,t);let{printer:{preprocess:n}}=t;return r=n?await n(r,t):r,{ast:r,comments:i}}function Ro(r,t){let{cursorOffset:i,locStart:n,locEnd:s}=t,a=X(t.printer.getVisitorKeys),h=hi=>n(hi)<=i&&s(hi)>=i,v=r;for(let hi of Ur(r,{getVisitorKeys:a,filter:h}))v=hi;return v}var Kn=Ro;function Yo(r,t){let{printer:{massageAstNode:i,getVisitorKeys:n}}=t;if(!i)return r;let s=X(n),a=i.ignoredProperties??new Set;return h(r);function h(v,hi){if(!(v!==null&&typeof v=="object"))return v;if(Array.isArray(v))return v.map(D=>h(D,hi)).filter(Boolean);let u={},l=new Set(s(v));for(let D in v)!Object.prototype.hasOwnProperty.call(v,D)||a.has(D)||(l.has(D)?u[D]=h(v[D],v):u[D]=v[D]);let vi=i(v,u,hi);if(vi!==null)return vi??u}}var qn=Yo,jo=(r,t,i)=>{if(!(r&&t==null)){if(t.findLastIndex)return t.findLastIndex(i);for(let n=t.length-1;n>=0;n--){let s=t[n];if(i(s,n,t))return n}return-1}},Jn=jo,Ho=({parser:r})=>r==="json"||r==="json5"||r==="jsonc"||r==="json-stringify";function Wo(r,t){let i=[r.node,...r.parentNodes],n=new Set([t.node,...t.parentNodes]);return i.find(s=>Qn.has(s.type)&&n.has(s))}function Xn(r){let t=Jn(!1,r,i=>i.type!=="Program"&&i.type!=="File");return t===-1?r:r.slice(0,t+1)}function Mo(r,t,{locStart:i,locEnd:n}){let s=r.node,a=t.node;if(s===a)return{startNode:s,endNode:a};let h=i(r.node);for(let hi of Xn(t.parentNodes))if(i(hi)>=h)a=hi;else break;let v=n(t.node);for(let hi of Xn(r.parentNodes)){if(n(hi)<=v)s=hi;else break;if(s===a)break}return{startNode:s,endNode:a}}function er(r,t,i,n,s=[],a){let{locStart:h,locEnd:v}=i,hi=h(r),u=v(r);if(!(t>u||t<hi||a==="rangeEnd"&&t===hi||a==="rangeStart"&&t===u)){for(let l of ut(r,i)){let vi=er(l,t,i,n,[r,...s],a);if(vi)return vi}if(!n||n(r,s[0]))return{node:r,parentNodes:s}}}function $o(r,t){return t!=="DeclareExportDeclaration"&&r!=="TypeParameterDeclaration"&&(r==="Directive"||r==="TypeAlias"||r==="TSExportAssignment"||r.startsWith("Declare")||r.startsWith("TSDeclare")||r.endsWith("Statement")||r.endsWith("Declaration"))}var Qn=new Set(["JsonRoot","ObjectExpression","ArrayExpression","StringLiteral","NumericLiteral","BooleanLiteral","NullLiteral","UnaryExpression","TemplateLiteral"]),Vo=new Set(["OperationDefinition","FragmentDefinition","VariableDefinition","TypeExtensionDefinition","ObjectTypeDefinition","FieldDefinition","DirectiveDefinition","EnumTypeDefinition","EnumValueDefinition","InputValueDefinition","InputObjectTypeDefinition","SchemaDefinition","OperationTypeDefinition","InterfaceTypeDefinition","UnionTypeDefinition","ScalarTypeDefinition"]);function Zn(r,t,i){if(!t)return!1;switch(r.parser){case"flow":case"babel":case"babel-flow":case"babel-ts":case"typescript":case"acorn":case"espree":case"meriyah":case"__babel_estree":return $o(t.type,i?.type);case"json":case"json5":case"jsonc":case"json-stringify":return Qn.has(t.type);case"graphql":return Vo.has(t.kind);case"vue":return t.tag!=="root"}return!1}function eu(r,t,i){let{rangeStart:n,rangeEnd:s,locStart:a,locEnd:h}=t;ke.ok(s>n);let v=r.slice(n,s).search(/\S/u),hi=v===-1;if(!hi)for(n+=v;s>n&&!/\S/u.test(r[s-1]);--s);let u=er(i,n,t,(mi,gi)=>Zn(t,mi,gi),[],"rangeStart"),l=hi?u:er(i,s,t,mi=>Zn(t,mi),[],"rangeEnd");if(!u||!l)return{rangeStart:0,rangeEnd:0};let vi,D;if(Ho(t)){let mi=Wo(u,l);vi=mi,D=mi}else({startNode:vi,endNode:D}=Mo(u,l,t));return{rangeStart:Math.min(a(vi),a(D)),rangeEnd:Math.max(h(vi),h(D))}}var uu="\uFEFF",tu=Symbol("cursor");async function ou(r,t,i=0){if(!r||r.trim().length===0)return{formatted:"",cursorOffset:-1,comments:[]};let{ast:n,text:s}=await ce(r,t);t.cursorOffset>=0&&(t.cursorNode=Kn(n,t));let a=await Ye(n,t);i>0&&(a=Je([q,a],i,t.tabWidth));let h=Fe(a,t);if(i>0){let hi=h.formatted.trim();h.cursorNodeStart!==void 0&&(h.cursorNodeStart-=h.formatted.indexOf(hi)),h.formatted=hi+Be(t.endOfLine)}let v=t[Symbol.for("comments")];if(t.cursorOffset>=0){let hi,u,l,vi,D;if(t.cursorNode&&h.cursorNodeText?(hi=t.locStart(t.cursorNode),u=s.slice(hi,t.locEnd(t.cursorNode)),l=t.cursorOffset-hi,vi=h.cursorNodeStart,D=h.cursorNodeText):(hi=0,u=s,l=t.cursorOffset,vi=0,D=h.formatted),u===D)return{formatted:h.formatted,cursorOffset:vi+l,comments:v};let mi=u.split("");mi.splice(l,0,tu);let gi=D.split(""),bi=dr(mi,gi),Ri=vi;for(let Ti of bi)if(Ti.removed){if(Ti.value.includes(tu))break}else Ri+=Ti.count;return{formatted:h.formatted,cursorOffset:Ri,comments:v}}return{formatted:h.formatted,cursorOffset:-1,comments:v}}async function Uo(r,t){let{ast:i,text:n}=await ce(r,t),{rangeStart:s,rangeEnd:a}=eu(n,t,i),h=n.slice(s,a),v=Math.min(s,n.lastIndexOf(`
91
+ `,s)+1),hi=n.slice(v,s).match(/^\s*/u)[0],u=me(hi,t.tabWidth),l=await ou(h,{...t,rangeStart:0,rangeEnd:Number.POSITIVE_INFINITY,cursorOffset:t.cursorOffset>s&&t.cursorOffset<=a?t.cursorOffset-s:-1,endOfLine:"lf"},u),vi=l.formatted.trimEnd(),{cursorOffset:D}=t;D>a?D+=vi.length-h.length:l.cursorOffset>=0&&(D=l.cursorOffset+s);let mi=n.slice(0,s)+vi+n.slice(a);if(t.endOfLine!=="lf"){let gi=Be(t.endOfLine);D>=0&&gi===`\r
92
+ `&&(D+=wt(mi.slice(0,D),`
93
+ `)),mi=ne(!1,mi,`
94
+ `,gi)}return{formatted:mi,cursorOffset:D,comments:l.comments}}function tr(r,t,i){return typeof t!="number"||Number.isNaN(t)||t<0||t>r.length?i:t}function ru(r,t){let{cursorOffset:i,rangeStart:n,rangeEnd:s}=t;return i=tr(r,i,-1),n=tr(r,n,0),s=tr(r,s,r.length),{...t,cursorOffset:i,rangeStart:n,rangeEnd:s}}function iu(r,t){let{cursorOffset:i,rangeStart:n,rangeEnd:s,endOfLine:a}=ru(r,t),h=r.charAt(0)===uu;if(h&&(r=r.slice(1),i--,n--,s--),a==="auto"&&(a=Fr(r)),r.includes("\r")){let v=hi=>wt(r.slice(0,Math.max(hi,0)),`\r
95
+ `);i-=v(i),n-=v(n),s-=v(s),r=mr$1(r)}return{hasBOM:h,text:r,options:ru(r,{...t,cursorOffset:i,rangeStart:n,rangeEnd:s,endOfLine:a})}}async function nu(r,t){let i=await ht(t);return!i.hasPragma||i.hasPragma(r)}async function rr(r,t){let{hasBOM:i,text:n,options:s}=iu(r,await se(t));if(s.rangeStart>=s.rangeEnd&&n!==""||s.requirePragma&&!await nu(n,s))return{formatted:r,cursorOffset:t.cursorOffset,comments:[]};let a;return s.rangeStart>0||s.rangeEnd<n.length?a=await Uo(n,s):(!s.requirePragma&&s.insertPragma&&s.printer.insertPragma&&!await nu(n,s)&&(n=s.printer.insertPragma(n)),a=await ou(n,s)),i&&(a.formatted=uu+a.formatted,a.cursorOffset>=0&&a.cursorOffset++),a}async function su(r,t,i){let{text:n,options:s}=iu(r,await se(t)),a=await ce(n,s);return i&&(i.preprocessForPrint&&(a.ast=await Qt(a.ast,s)),i.massage&&(a.ast=qn(a.ast,s))),a}async function au(r,t){t=await se(t);let i=await Ye(r,t);return Fe(i,t)}async function Du(r,t){let i=Or(r),{formatted:n}=await rr(i,{...t,parser:"__js_expression"});return n}async function lu(r,t){t=await se(t);let{ast:i}=await ce(r,t);return Ye(i,t)}async function cu(r,t){return Fe(r,await se(t))}var nr={};We(nr,{builders:()=>Go,printer:()=>Ko,utils:()=>qo});var Go={join:be,line:Ke,softline:vr,hardline:q,literalline:qe,group:_t,conditionalGroup:Ar,fill:Ge,lineSuffix:xe,lineSuffixBoundary:xr,cursor:ve,breakParent:de,ifBreak:Br,trim:_r,indent:De,indentIfBreak:wr,align:ae,addAlignmentToDoc:Je,markAsRoot:gr,dedentToRoot:Cr,dedent:yr,hardlineWithoutBreakParent:_e,literallineWithoutBreakParent:vt,label:br,concat:r=>r},Ko={printDocToString:Fe},qo={willBreak:Ir,traverseDoc:we,findInDoc:Xe,mapDoc:Ne,removeLines:Yr,stripTrailingHardline:Ze,replaceEndOfLine:jr,canBreak:Hr},fu="3.3.3",or={};We(or,{addDanglingComment:()=>re,addLeadingComment:()=>ue,addTrailingComment:()=>oe,getAlignmentSize:()=>me,getIndentSize:()=>pu,getMaxContinuousCount:()=>du,getNextNonSpaceNonCommentCharacter:()=>Fu,getNextNonSpaceNonCommentCharacterIndex:()=>si,getStringWidth:()=>Oe,hasNewline:()=>V,hasNewlineInRange:()=>mu,hasSpaces:()=>Eu,isNextLineEmpty:()=>ci,isNextLineEmptyAfterIndex:()=>gt,isPreviousLineEmpty:()=>Di,makeString:()=>hu,skip:()=>Ee,skipEverythingButNewLine:()=>nt,skipInlineComment:()=>Ce,skipNewline:()=>M,skipSpaces:()=>T,skipToLineEnd:()=>rt,skipTrailingComment:()=>ge,skipWhitespace:()=>zr});function Jo(r,t){if(t===!1)return!1;if(r.charAt(t)==="/"&&r.charAt(t+1)==="*"){for(let i=t+2;i<r.length;++i)if(r.charAt(i)==="*"&&r.charAt(i+1)==="/")return i+2}return t}var Ce=Jo;function Xo(r,t){return t===!1?!1:r.charAt(t)==="/"&&r.charAt(t+1)==="/"?nt(r,t):t}var ge=Xo;function Zo(r,t){let i=null,n=t;for(;n!==i;)i=n,n=T(r,n),n=Ce(r,n),n=ge(r,n),n=M(r,n);return n}var je=Zo;function Qo(r,t){let i=null,n=t;for(;n!==i;)i=n,n=rt(r,n),n=Ce(r,n),n=T(r,n);return n=ge(r,n),n=M(r,n),n!==!1&&V(r,n)}var gt=Qo;function ei(r,t){let i=r.lastIndexOf(`
96
+ `);return i===-1?0:me(r.slice(i+1).match(/^[\t ]*/u)[0],t)}var pu=ei;function ur(r){if(typeof r!="string")throw new TypeError("Expected a string");return r.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function ti(r,t){let i=r.match(new RegExp(`(${ur(t)})+`,"gu"));return i===null?0:i.reduce((n,s)=>Math.max(n,s.length/t.length),0)}var du=ti;function ri(r,t){let i=je(r,t);return i===!1?"":r.charAt(i)}var Fu=ri;function ni(r,t,i){for(let n=t;n<i;++n)if(r.charAt(n)===`
97
+ `)return!0;return!1}var mu=ni;function ui(r,t,i={}){return T(r,i.backwards?t-1:t,i)!==t}var Eu=ui;function oi(r,t,i){let n=t==='"'?"'":'"',s=ne(!1,r,/\\(.)|(["'])/gsu,(a,h,v)=>h===n?h:v===t?"\\"+v:v||(i&&/^[^\n\r"'0-7\\bfnrt-vx\u2028\u2029]$/u.test(h)?h:"\\"+h));return t+s+t}var hu=oi;function ii(r,t,i){return je(r,i(t))}function si(r,t){return arguments.length===2||typeof t=="number"?je(r,t):ii(...arguments)}function ai(r,t,i){return Le(r,i(t))}function Di(r,t){return arguments.length===2||typeof t=="number"?Le(r,t):ai(...arguments)}function li(r,t,i){return gt(r,i(t))}function ci(r,t){return arguments.length===2||typeof t=="number"?gt(r,t):li(...arguments)}function fe(r,t=1){return async(...i)=>{let n=i[t]??{},s=n.plugins??[];return i[t]={...n,plugins:Array.isArray(s)?s:Object.values(s)},r(...i)}}var Cu=fe(rr);async function gu(r,t){let{formatted:i}=await Cu(r,{...t,cursorOffset:-1});return i}async function fi(r,t){return await gu(r,t)===r}var pi=fe(ot,0),di={parse:fe(su),formatAST:fe(au),formatDoc:fe(Du),printToDoc:fe(lu),printDocToString:fe(cu)};function delay(r){return new Promise(t=>void self.setTimeout(t,r))}function isSessionExpired(r,t=ONE_MINUTE){return msUntilSessionExpired(r,t)<1}function msUntilSessionExpired(r,t=ONE_MINUTE){return r.expiresAt-now()-t}const instanceOfAny=(r,t)=>t.some(i=>r instanceof i);let idbProxyableTypes,cursorAdvanceMethods;function getIdbProxyableTypes(){return idbProxyableTypes||(idbProxyableTypes=[IDBDatabase,IDBObjectStore,IDBIndex,IDBCursor,IDBTransaction])}function getCursorAdvanceMethods(){return cursorAdvanceMethods||(cursorAdvanceMethods=[IDBCursor.prototype.advance,IDBCursor.prototype.continue,IDBCursor.prototype.continuePrimaryKey])}const cursorRequestMap=new WeakMap,transactionDoneMap=new WeakMap,transactionStoreNamesMap=new WeakMap,transformCache=new WeakMap,reverseTransformCache=new WeakMap;function promisifyRequest(r){const t=new Promise((i,n)=>{const s=()=>{r.removeEventListener("success",a),r.removeEventListener("error",h)},a=()=>{i(wrap$2(r.result)),s()},h=()=>{n(r.error),s()};r.addEventListener("success",a),r.addEventListener("error",h)});return t.then(i=>{i instanceof IDBCursor&&cursorRequestMap.set(i,r)}).catch(()=>{}),reverseTransformCache.set(t,r),t}function cacheDonePromiseForTransaction(r){if(transactionDoneMap.has(r))return;const t=new Promise((i,n)=>{const s=()=>{r.removeEventListener("complete",a),r.removeEventListener("error",h),r.removeEventListener("abort",h)},a=()=>{i(),s()},h=()=>{n(r.error||new DOMException("AbortError","AbortError")),s()};r.addEventListener("complete",a),r.addEventListener("error",h),r.addEventListener("abort",h)});transactionDoneMap.set(r,t)}let idbProxyTraps={get(r,t,i){if(r instanceof IDBTransaction){if(t==="done")return transactionDoneMap.get(r);if(t==="objectStoreNames")return r.objectStoreNames||transactionStoreNamesMap.get(r);if(t==="store")return i.objectStoreNames[1]?void 0:i.objectStore(i.objectStoreNames[0])}return wrap$2(r[t])},set(r,t,i){return r[t]=i,!0},has(r,t){return r instanceof IDBTransaction&&(t==="done"||t==="store")?!0:t in r}};function replaceTraps(r){idbProxyTraps=r(idbProxyTraps)}function wrapFunction(r){return r===IDBDatabase.prototype.transaction&&!("objectStoreNames"in IDBTransaction.prototype)?function(t,...i){const n=r.call(unwrap(this),t,...i);return transactionStoreNamesMap.set(n,t.sort?t.sort():[t]),wrap$2(n)}:getCursorAdvanceMethods().includes(r)?function(...t){return r.apply(unwrap(this),t),wrap$2(cursorRequestMap.get(this))}:function(...t){return wrap$2(r.apply(unwrap(this),t))}}function transformCachableValue(r){return typeof r=="function"?wrapFunction(r):(r instanceof IDBTransaction&&cacheDonePromiseForTransaction(r),instanceOfAny(r,getIdbProxyableTypes())?new Proxy(r,idbProxyTraps):r)}function wrap$2(r){if(r instanceof IDBRequest)return promisifyRequest(r);if(transformCache.has(r))return transformCache.get(r);const t=transformCachableValue(r);return t!==r&&(transformCache.set(r,t),reverseTransformCache.set(t,r)),t}const unwrap=r=>reverseTransformCache.get(r);function openDB(r,t,{blocked:i,upgrade:n,blocking:s,terminated:a}={}){const h=indexedDB.open(r,t),v=wrap$2(h);return n&&h.addEventListener("upgradeneeded",hi=>{n(wrap$2(h.result),hi.oldVersion,hi.newVersion,wrap$2(h.transaction),hi)}),i&&h.addEventListener("blocked",hi=>i(hi.oldVersion,hi.newVersion,hi)),v.then(hi=>{a&&hi.addEventListener("close",()=>a()),s&&hi.addEventListener("versionchange",u=>s(u.oldVersion,u.newVersion,u))}).catch(()=>{}),v}const readMethods=["get","getKey","getAll","getAllKeys","count"],writeMethods=["put","add","delete","clear"],cachedMethods=new Map;function getMethod(r,t){if(!(r instanceof IDBDatabase&&!(t in r)&&typeof t=="string"))return;if(cachedMethods.get(t))return cachedMethods.get(t);const i=t.replace(/FromIndex$/,""),n=t!==i,s=writeMethods.includes(i);if(!(i in(n?IDBIndex:IDBObjectStore).prototype)||!(s||readMethods.includes(i)))return;const a=async function(h,...v){const hi=this.transaction(h,s?"readwrite":"readonly");let u=hi.store;return n&&(u=u.index(v.shift())),(await Promise.all([u[i](...v),s&&hi.done]))[0]};return cachedMethods.set(t,a),a}replaceTraps(r=>({...r,get:(t,i,n)=>getMethod(t,i)||r.get(t,i,n),has:(t,i)=>!!getMethod(t,i)||r.has(t,i)}));const advanceMethodProps=["continue","continuePrimaryKey","advance"],methodMap={},advanceResults=new WeakMap,ittrProxiedCursorToOriginalProxy=new WeakMap,cursorIteratorTraps={get(r,t){if(!advanceMethodProps.includes(t))return r[t];let i=methodMap[t];return i||(i=methodMap[t]=function(...n){advanceResults.set(this,ittrProxiedCursorToOriginalProxy.get(this)[t](...n))}),i}};async function*iterate(...r){let t=this;if(t instanceof IDBCursor||(t=await t.openCursor(...r)),!t)return;t=t;const i=new Proxy(t,cursorIteratorTraps);for(ittrProxiedCursorToOriginalProxy.set(i,t),reverseTransformCache.set(i,unwrap(t));t;)yield i,t=await(advanceResults.get(i)||t.continue()),advanceResults.delete(i)}function isIteratorProp(r,t){return t===Symbol.asyncIterator&&instanceOfAny(r,[IDBIndex,IDBObjectStore,IDBCursor])||t==="iterate"&&instanceOfAny(r,[IDBIndex,IDBObjectStore])}replaceTraps(r=>({...r,get(t,i,n){return isIteratorProp(t,i)?iterate:r.get(t,i,n)},has(t,i){return isIteratorProp(t,i)||r.has(t,i)}}));const DB_NAME="chillicream-nitro-insider";function getDatabaseName(){return self.appNamespace?`${DB_NAME}-${self.appNamespace}`:DB_NAME}function getEntityByKey(r,t){return openDatabaseScope(i=>i.get(r,t))}function putEntity(r,t){return openDatabaseScope(async i=>{await i.put(r,t)})}function openDatabase(){return openDB(getDatabaseName())}async function openDatabaseScope(r){const t=await openDatabase();try{return await r(t)}finally{t.close()}}async function openTransactionScope(r,t,i,n,s){const a=await createTransaction(r,t,i);try{return await n(a,r.version)}finally{await a.done}}function openDatabaseWithTransactionScope(r,t,i,n){return openDatabaseScope(s=>openTransactionScope(s,r,t,i,n))}const camelizationCache=new Map;function camelizeString(r){let t=camelizationCache.get(r);return t||(t=r.split("-").reduce((i,n)=>(n&&(i!==""?(i+=n[0].toUpperCase(),i+=n.substring(1)):i=n),i),""),camelizationCache.set(r,t)),t}async function createTransaction(r,t,i){const n=r.transaction(t,i),s={},a={};for(const h of t){const v=n.objectStore(h),hi=camelizeString(h);s[hi]=v,a[hi]={};for(const u of v.indexNames)a[hi][u]=v.index(u)}return{abort:h=>abortWithError(n,h),done:n.done.catch(h=>{if(!isAbortError(h))throw h}),store:s,index:a}}function abortWithError(r,t){throw r.abort(),new Error(t)}globalThis.idbGet=function(r,t){return openDatabaseScope(async i=>{console.log("IDB_GET",{store:r,key:t,data:await i.get(r,t)})})};globalThis.idbSet=function(r,t,i){return openDatabaseScope(async n=>{console.log("IDB_SET",{store:r,key:i,value:t,result:await n.put(r,t,i)})})};async function getUserSession({sub:r,tenant:t,issuer:i}){return openDatabaseWithTransactionScope(["session"],"readonly",n=>n.index.session.key.get([r,t,i]))}async function replaceUserSession(r){return await putEntity("session",r),r}const APP_CURRENT_TENANT="current-tenant";function getCurrentTenant(){return getEntityByKey("app",APP_CURRENT_TENANT)}var cryptoJs$1={exports:{}};function commonjsRequire(r){throw new Error('Could not dynamically require "'+r+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var core$1={exports:{}},cryptoBrowserify={},browser$b={exports:{}},hasRequiredBrowser$b;function requireBrowser$b(){if(hasRequiredBrowser$b)return browser$b.exports;hasRequiredBrowser$b=1;var r=65536,t=4294967295;function i(){throw new Error(`Secure random number generation is not supported by this browser.
98
+ Use Chrome, Firefox or Internet Explorer 11`)}var n=requireSafeBuffer$1().Buffer,s=commonjsGlobal.crypto||commonjsGlobal.msCrypto;s&&s.getRandomValues?browser$b.exports=a:browser$b.exports=i;function a(h,v){if(h>t)throw new RangeError("requested too many random bytes");var hi=n.allocUnsafe(h);if(h>0)if(h>r)for(var u=0;u<h;u+=r)s.getRandomValues(hi.slice(u,u+r));else s.getRandomValues(hi);return typeof v=="function"?process$1.nextTick(function(){v(null,hi)}):hi}return browser$b.exports}var hashBase$1,hasRequiredHashBase$1;function requireHashBase$1(){if(hasRequiredHashBase$1)return hashBase$1;hasRequiredHashBase$1=1;var r=requireSafeBuffer$1().Buffer,t=requireReadableBrowser$1().Transform,i=requireInherits_browser();function n(a,h){if(!r.isBuffer(a)&&typeof a!="string")throw new TypeError(h+" must be a string or a buffer")}function s(a){t.call(this),this._block=r.allocUnsafe(a),this._blockSize=a,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}return i(s,t),s.prototype._transform=function(a,h,v){var hi=null;try{this.update(a,h)}catch(u){hi=u}v(hi)},s.prototype._flush=function(a){var h=null;try{this.push(this.digest())}catch(v){h=v}a(h)},s.prototype.update=function(a,h){if(n(a,"Data"),this._finalized)throw new Error("Digest already called");r.isBuffer(a)||(a=r.from(a,h));for(var v=this._block,hi=0;this._blockOffset+a.length-hi>=this._blockSize;){for(var u=this._blockOffset;u<this._blockSize;)v[u++]=a[hi++];this._update(),this._blockOffset=0}for(;hi<a.length;)v[this._blockOffset++]=a[hi++];for(var l=0,vi=a.length*8;vi>0;++l)this._length[l]+=vi,vi=this._length[l]/4294967296|0,vi>0&&(this._length[l]-=4294967296*vi);return this},s.prototype._update=function(){throw new Error("_update is not implemented")},s.prototype.digest=function(a){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var h=this._digest();a!==void 0&&(h=h.toString(a)),this._block.fill(0),this._blockOffset=0;for(var v=0;v<4;++v)this._length[v]=0;return h},s.prototype._digest=function(){throw new Error("_digest is not implemented")},hashBase$1=s,hashBase$1}var ripemd160$3,hasRequiredRipemd160$2;function requireRipemd160$2(){if(hasRequiredRipemd160$2)return ripemd160$3;hasRequiredRipemd160$2=1;var r=requireDist().Buffer,t=requireInherits_browser(),i=requireHashBase$1(),n=new Array(16),s=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],a=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],h=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],v=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11],hi=[0,1518500249,1859775393,2400959708,2840853838],u=[1352829926,1548603684,1836072691,2053994217,0];function l(){i.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}t(l,i),l.prototype._update=function(){for(var Ti=n,Ii=0;Ii<16;++Ii)Ti[Ii]=this._block.readInt32LE(Ii*4);for(var qi=this._a|0,Oi=this._b|0,ki=this._c|0,Li=this._d|0,ji=this._e|0,Hi=this._a|0,Ui=this._b|0,Qi=this._c|0,$i=this._d|0,wi=this._e|0,xi=0;xi<80;xi+=1){var yi,Ei;xi<16?(yi=D(qi,Oi,ki,Li,ji,Ti[s[xi]],hi[0],h[xi]),Ei=Ri(Hi,Ui,Qi,$i,wi,Ti[a[xi]],u[0],v[xi])):xi<32?(yi=mi(qi,Oi,ki,Li,ji,Ti[s[xi]],hi[1],h[xi]),Ei=bi(Hi,Ui,Qi,$i,wi,Ti[a[xi]],u[1],v[xi])):xi<48?(yi=gi(qi,Oi,ki,Li,ji,Ti[s[xi]],hi[2],h[xi]),Ei=gi(Hi,Ui,Qi,$i,wi,Ti[a[xi]],u[2],v[xi])):xi<64?(yi=bi(qi,Oi,ki,Li,ji,Ti[s[xi]],hi[3],h[xi]),Ei=mi(Hi,Ui,Qi,$i,wi,Ti[a[xi]],u[3],v[xi])):(yi=Ri(qi,Oi,ki,Li,ji,Ti[s[xi]],hi[4],h[xi]),Ei=D(Hi,Ui,Qi,$i,wi,Ti[a[xi]],u[4],v[xi])),qi=ji,ji=Li,Li=vi(ki,10),ki=Oi,Oi=yi,Hi=wi,wi=$i,$i=vi(Qi,10),Qi=Ui,Ui=Ei}var Ci=this._b+ki+$i|0;this._b=this._c+Li+wi|0,this._c=this._d+ji+Hi|0,this._d=this._e+qi+Ui|0,this._e=this._a+Oi+Qi|0,this._a=Ci},l.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var Ti=r.alloc?r.alloc(20):new r(20);return Ti.writeInt32LE(this._a,0),Ti.writeInt32LE(this._b,4),Ti.writeInt32LE(this._c,8),Ti.writeInt32LE(this._d,12),Ti.writeInt32LE(this._e,16),Ti};function vi(Ti,Ii){return Ti<<Ii|Ti>>>32-Ii}function D(Ti,Ii,qi,Oi,ki,Li,ji,Hi){return vi(Ti+(Ii^qi^Oi)+Li+ji|0,Hi)+ki|0}function mi(Ti,Ii,qi,Oi,ki,Li,ji,Hi){return vi(Ti+(Ii&qi|~Ii&Oi)+Li+ji|0,Hi)+ki|0}function gi(Ti,Ii,qi,Oi,ki,Li,ji,Hi){return vi(Ti+((Ii|~qi)^Oi)+Li+ji|0,Hi)+ki|0}function bi(Ti,Ii,qi,Oi,ki,Li,ji,Hi){return vi(Ti+(Ii&Oi|qi&~Oi)+Li+ji|0,Hi)+ki|0}function Ri(Ti,Ii,qi,Oi,ki,Li,ji,Hi){return vi(Ti+(Ii^(qi|~Oi))+Li+ji|0,Hi)+ki|0}return ripemd160$3=l,ripemd160$3}var sha_js={exports:{}},isarray$1,hasRequiredIsarray$1;function requireIsarray$1(){if(hasRequiredIsarray$1)return isarray$1;hasRequiredIsarray$1=1;var r={}.toString;return isarray$1=Array.isArray||function(t){return r.call(t)=="[object Array]"},isarray$1}var isTypedArray,hasRequiredIsTypedArray;function requireIsTypedArray(){if(hasRequiredIsTypedArray)return isTypedArray;hasRequiredIsTypedArray=1;var r=requireWhichTypedArray();return isTypedArray=function(i){return!!r(i)},isTypedArray}var typedArrayBuffer,hasRequiredTypedArrayBuffer;function requireTypedArrayBuffer(){if(hasRequiredTypedArrayBuffer)return typedArrayBuffer;hasRequiredTypedArrayBuffer=1;var r=requireType(),t=requireCallBound(),i=t("TypedArray.prototype.buffer",!0),n=requireIsTypedArray();return typedArrayBuffer=i||function(a){if(!n(a))throw new r("Not a Typed Array");return a.buffer},typedArrayBuffer}var toBuffer,hasRequiredToBuffer$1;function requireToBuffer$1(){if(hasRequiredToBuffer$1)return toBuffer;hasRequiredToBuffer$1=1;var r=requireSafeBuffer$1().Buffer,t=requireIsarray$1(),i=requireTypedArrayBuffer(),n=ArrayBuffer.isView||function(hi){try{return i(hi),!0}catch{return!1}},s=typeof Uint8Array<"u",a=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u",h=a&&(r.prototype instanceof Uint8Array||r.TYPED_ARRAY_SUPPORT);return toBuffer=function(hi,u){if(hi instanceof r)return hi;if(typeof hi=="string")return r.from(hi,u);if(a&&n(hi)){if(hi.byteLength===0)return r.alloc(0);if(h){var l=r.from(hi.buffer,hi.byteOffset,hi.byteLength);if(l.byteLength===hi.byteLength)return l}var vi=hi instanceof Uint8Array?hi:new Uint8Array(hi.buffer,hi.byteOffset,hi.byteLength),D=r.from(vi);if(D.length===hi.byteLength)return D}if(s&&hi instanceof Uint8Array)return r.from(hi);var mi=t(hi);if(mi)for(var gi=0;gi<hi.length;gi+=1){var bi=hi[gi];if(typeof bi!="number"||bi<0||bi>255||~~bi!==bi)throw new RangeError("Array items must be numbers in the range 0-255.")}if(mi||r.isBuffer(hi)&&hi.constructor&&typeof hi.constructor.isBuffer=="function"&&hi.constructor.isBuffer(hi))return r.from(hi);throw new TypeError('The "data" argument must be a string, an Array, a Buffer, a Uint8Array, or a DataView.')},toBuffer}var hash$1,hasRequiredHash$1;function requireHash$1(){if(hasRequiredHash$1)return hash$1;hasRequiredHash$1=1;var r=requireSafeBuffer$1().Buffer,t=requireToBuffer$1();function i(n,s){this._block=r.alloc(n),this._finalSize=s,this._blockSize=n,this._len=0}return i.prototype.update=function(n,s){n=t(n,s||"utf8");for(var a=this._block,h=this._blockSize,v=n.length,hi=this._len,u=0;u<v;){for(var l=hi%h,vi=Math.min(v-u,h-l),D=0;D<vi;D++)a[l+D]=n[u+D];hi+=vi,u+=vi,hi%h===0&&this._update(a)}return this._len+=v,this},i.prototype.digest=function(n){var s=this._len%this._blockSize;this._block[s]=128,this._block.fill(0,s+1),s>=this._finalSize&&(this._update(this._block),this._block.fill(0));var a=this._len*8;if(a<=4294967295)this._block.writeUInt32BE(a,this._blockSize-4);else{var h=(a&4294967295)>>>0,v=(a-h)/4294967296;this._block.writeUInt32BE(v,this._blockSize-8),this._block.writeUInt32BE(h,this._blockSize-4)}this._update(this._block);var hi=this._hash();return n?hi.toString(n):hi},i.prototype._update=function(){throw new Error("_update must be implemented by subclass")},hash$1=i,hash$1}var sha$1,hasRequiredSha$1;function requireSha$1(){if(hasRequiredSha$1)return sha$1;hasRequiredSha$1=1;var r=requireInherits_browser(),t=requireHash$1(),i=requireSafeBuffer$1().Buffer,n=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function a(){this.init(),this._w=s,t.call(this,64,56)}r(a,t),a.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this};function h(u){return u<<5|u>>>27}function v(u){return u<<30|u>>>2}function hi(u,l,vi,D){return u===0?l&vi|~l&D:u===2?l&vi|l&D|vi&D:l^vi^D}return a.prototype._update=function(u){for(var l=this._w,vi=this._a|0,D=this._b|0,mi=this._c|0,gi=this._d|0,bi=this._e|0,Ri=0;Ri<16;++Ri)l[Ri]=u.readInt32BE(Ri*4);for(;Ri<80;++Ri)l[Ri]=l[Ri-3]^l[Ri-8]^l[Ri-14]^l[Ri-16];for(var Ti=0;Ti<80;++Ti){var Ii=~~(Ti/20),qi=h(vi)+hi(Ii,D,mi,gi)+bi+l[Ti]+n[Ii]|0;bi=gi,gi=mi,mi=v(D),D=vi,vi=qi}this._a=vi+this._a|0,this._b=D+this._b|0,this._c=mi+this._c|0,this._d=gi+this._d|0,this._e=bi+this._e|0},a.prototype._hash=function(){var u=i.allocUnsafe(20);return u.writeInt32BE(this._a|0,0),u.writeInt32BE(this._b|0,4),u.writeInt32BE(this._c|0,8),u.writeInt32BE(this._d|0,12),u.writeInt32BE(this._e|0,16),u},sha$1=a,sha$1}var sha1$2,hasRequiredSha1$1;function requireSha1$1(){if(hasRequiredSha1$1)return sha1$2;hasRequiredSha1$1=1;var r=requireInherits_browser(),t=requireHash$1(),i=requireSafeBuffer$1().Buffer,n=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function a(){this.init(),this._w=s,t.call(this,64,56)}r(a,t),a.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this};function h(l){return l<<1|l>>>31}function v(l){return l<<5|l>>>27}function hi(l){return l<<30|l>>>2}function u(l,vi,D,mi){return l===0?vi&D|~vi&mi:l===2?vi&D|vi&mi|D&mi:vi^D^mi}return a.prototype._update=function(l){for(var vi=this._w,D=this._a|0,mi=this._b|0,gi=this._c|0,bi=this._d|0,Ri=this._e|0,Ti=0;Ti<16;++Ti)vi[Ti]=l.readInt32BE(Ti*4);for(;Ti<80;++Ti)vi[Ti]=h(vi[Ti-3]^vi[Ti-8]^vi[Ti-14]^vi[Ti-16]);for(var Ii=0;Ii<80;++Ii){var qi=~~(Ii/20),Oi=v(D)+u(qi,mi,gi,bi)+Ri+vi[Ii]+n[qi]|0;Ri=bi,bi=gi,gi=hi(mi),mi=D,D=Oi}this._a=D+this._a|0,this._b=mi+this._b|0,this._c=gi+this._c|0,this._d=bi+this._d|0,this._e=Ri+this._e|0},a.prototype._hash=function(){var l=i.allocUnsafe(20);return l.writeInt32BE(this._a|0,0),l.writeInt32BE(this._b|0,4),l.writeInt32BE(this._c|0,8),l.writeInt32BE(this._d|0,12),l.writeInt32BE(this._e|0,16),l},sha1$2=a,sha1$2}var sha256$3,hasRequiredSha256$1;function requireSha256$1(){if(hasRequiredSha256$1)return sha256$3;hasRequiredSha256$1=1;var r=requireInherits_browser(),t=requireHash$1(),i=requireSafeBuffer$1().Buffer,n=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],s=new Array(64);function a(){this.init(),this._w=s,t.call(this,64,56)}r(a,t),a.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this};function h(D,mi,gi){return gi^D&(mi^gi)}function v(D,mi,gi){return D&mi|gi&(D|mi)}function hi(D){return(D>>>2|D<<30)^(D>>>13|D<<19)^(D>>>22|D<<10)}function u(D){return(D>>>6|D<<26)^(D>>>11|D<<21)^(D>>>25|D<<7)}function l(D){return(D>>>7|D<<25)^(D>>>18|D<<14)^D>>>3}function vi(D){return(D>>>17|D<<15)^(D>>>19|D<<13)^D>>>10}return a.prototype._update=function(D){for(var mi=this._w,gi=this._a|0,bi=this._b|0,Ri=this._c|0,Ti=this._d|0,Ii=this._e|0,qi=this._f|0,Oi=this._g|0,ki=this._h|0,Li=0;Li<16;++Li)mi[Li]=D.readInt32BE(Li*4);for(;Li<64;++Li)mi[Li]=vi(mi[Li-2])+mi[Li-7]+l(mi[Li-15])+mi[Li-16]|0;for(var ji=0;ji<64;++ji){var Hi=ki+u(Ii)+h(Ii,qi,Oi)+n[ji]+mi[ji]|0,Ui=hi(gi)+v(gi,bi,Ri)|0;ki=Oi,Oi=qi,qi=Ii,Ii=Ti+Hi|0,Ti=Ri,Ri=bi,bi=gi,gi=Hi+Ui|0}this._a=gi+this._a|0,this._b=bi+this._b|0,this._c=Ri+this._c|0,this._d=Ti+this._d|0,this._e=Ii+this._e|0,this._f=qi+this._f|0,this._g=Oi+this._g|0,this._h=ki+this._h|0},a.prototype._hash=function(){var D=i.allocUnsafe(32);return D.writeInt32BE(this._a,0),D.writeInt32BE(this._b,4),D.writeInt32BE(this._c,8),D.writeInt32BE(this._d,12),D.writeInt32BE(this._e,16),D.writeInt32BE(this._f,20),D.writeInt32BE(this._g,24),D.writeInt32BE(this._h,28),D},sha256$3=a,sha256$3}var sha224$3,hasRequiredSha224$1;function requireSha224$1(){if(hasRequiredSha224$1)return sha224$3;hasRequiredSha224$1=1;var r=requireInherits_browser(),t=requireSha256$1(),i=requireHash$1(),n=requireSafeBuffer$1().Buffer,s=new Array(64);function a(){this.init(),this._w=s,i.call(this,64,56)}return r(a,t),a.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this},a.prototype._hash=function(){var h=n.allocUnsafe(28);return h.writeInt32BE(this._a,0),h.writeInt32BE(this._b,4),h.writeInt32BE(this._c,8),h.writeInt32BE(this._d,12),h.writeInt32BE(this._e,16),h.writeInt32BE(this._f,20),h.writeInt32BE(this._g,24),h},sha224$3=a,sha224$3}var sha512$3,hasRequiredSha512$1;function requireSha512$1(){if(hasRequiredSha512$1)return sha512$3;hasRequiredSha512$1=1;var r=requireInherits_browser(),t=requireHash$1(),i=requireSafeBuffer$1().Buffer,n=[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,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],s=new Array(160);function a(){this.init(),this._w=s,t.call(this,128,112)}r(a,t),a.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this};function h(bi,Ri,Ti){return Ti^bi&(Ri^Ti)}function v(bi,Ri,Ti){return bi&Ri|Ti&(bi|Ri)}function hi(bi,Ri){return(bi>>>28|Ri<<4)^(Ri>>>2|bi<<30)^(Ri>>>7|bi<<25)}function u(bi,Ri){return(bi>>>14|Ri<<18)^(bi>>>18|Ri<<14)^(Ri>>>9|bi<<23)}function l(bi,Ri){return(bi>>>1|Ri<<31)^(bi>>>8|Ri<<24)^bi>>>7}function vi(bi,Ri){return(bi>>>1|Ri<<31)^(bi>>>8|Ri<<24)^(bi>>>7|Ri<<25)}function D(bi,Ri){return(bi>>>19|Ri<<13)^(Ri>>>29|bi<<3)^bi>>>6}function mi(bi,Ri){return(bi>>>19|Ri<<13)^(Ri>>>29|bi<<3)^(bi>>>6|Ri<<26)}function gi(bi,Ri){return bi>>>0<Ri>>>0?1:0}return a.prototype._update=function(bi){for(var Ri=this._w,Ti=this._ah|0,Ii=this._bh|0,qi=this._ch|0,Oi=this._dh|0,ki=this._eh|0,Li=this._fh|0,ji=this._gh|0,Hi=this._hh|0,Ui=this._al|0,Qi=this._bl|0,$i=this._cl|0,wi=this._dl|0,xi=this._el|0,yi=this._fl|0,Ei=this._gl|0,Ci=this._hl|0,Ni=0;Ni<32;Ni+=2)Ri[Ni]=bi.readInt32BE(Ni*4),Ri[Ni+1]=bi.readInt32BE(Ni*4+4);for(;Ni<160;Ni+=2){var Fi=Ri[Ni-30],Mi=Ri[Ni-30+1],Si=l(Fi,Mi),Ai=vi(Mi,Fi);Fi=Ri[Ni-4],Mi=Ri[Ni-4+1];var _i=D(Fi,Mi),Bi=mi(Mi,Fi),Pi=Ri[Ni-14],zi=Ri[Ni-14+1],Gi=Ri[Ni-32],Vi=Ri[Ni-32+1],Ki=Ai+zi|0,Zi=Si+Pi+gi(Ki,Ai)|0;Ki=Ki+Bi|0,Zi=Zi+_i+gi(Ki,Bi)|0,Ki=Ki+Vi|0,Zi=Zi+Gi+gi(Ki,Vi)|0,Ri[Ni]=Zi,Ri[Ni+1]=Ki}for(var In=0;In<160;In+=2){Zi=Ri[In],Ki=Ri[In+1];var Ji=v(Ti,Ii,qi),Xi=v(Ui,Qi,$i),on=hi(Ti,Ui),jn=hi(Ui,Ti),Ln=u(ki,xi),Hn=u(xi,ki),ea=n[In],ia=n[In+1],Wn=h(ki,Li,ji),oa=h(xi,yi,Ei),ta=Ci+Hn|0,aa=Hi+Ln+gi(ta,Ci)|0;ta=ta+oa|0,aa=aa+Wn+gi(ta,oa)|0,ta=ta+ia|0,aa=aa+ea+gi(ta,ia)|0,ta=ta+Ki|0,aa=aa+Zi+gi(ta,Ki)|0;var sa=jn+Xi|0,ua=on+Ji+gi(sa,jn)|0;Hi=ji,Ci=Ei,ji=Li,Ei=yi,Li=ki,yi=xi,xi=wi+ta|0,ki=Oi+aa+gi(xi,wi)|0,Oi=qi,wi=$i,qi=Ii,$i=Qi,Ii=Ti,Qi=Ui,Ui=ta+sa|0,Ti=aa+ua+gi(Ui,ta)|0}this._al=this._al+Ui|0,this._bl=this._bl+Qi|0,this._cl=this._cl+$i|0,this._dl=this._dl+wi|0,this._el=this._el+xi|0,this._fl=this._fl+yi|0,this._gl=this._gl+Ei|0,this._hl=this._hl+Ci|0,this._ah=this._ah+Ti+gi(this._al,Ui)|0,this._bh=this._bh+Ii+gi(this._bl,Qi)|0,this._ch=this._ch+qi+gi(this._cl,$i)|0,this._dh=this._dh+Oi+gi(this._dl,wi)|0,this._eh=this._eh+ki+gi(this._el,xi)|0,this._fh=this._fh+Li+gi(this._fl,yi)|0,this._gh=this._gh+ji+gi(this._gl,Ei)|0,this._hh=this._hh+Hi+gi(this._hl,Ci)|0},a.prototype._hash=function(){var bi=i.allocUnsafe(64);function Ri(Ti,Ii,qi){bi.writeInt32BE(Ti,qi),bi.writeInt32BE(Ii,qi+4)}return Ri(this._ah,this._al,0),Ri(this._bh,this._bl,8),Ri(this._ch,this._cl,16),Ri(this._dh,this._dl,24),Ri(this._eh,this._el,32),Ri(this._fh,this._fl,40),Ri(this._gh,this._gl,48),Ri(this._hh,this._hl,56),bi},sha512$3=a,sha512$3}var sha384$3,hasRequiredSha384$1;function requireSha384$1(){if(hasRequiredSha384$1)return sha384$3;hasRequiredSha384$1=1;var r=requireInherits_browser(),t=requireSha512$1(),i=requireHash$1(),n=requireSafeBuffer$1().Buffer,s=new Array(160);function a(){this.init(),this._w=s,i.call(this,128,112)}return r(a,t),a.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this},a.prototype._hash=function(){var h=n.allocUnsafe(48);function v(hi,u,l){h.writeInt32BE(hi,l),h.writeInt32BE(u,l+4)}return v(this._ah,this._al,0),v(this._bh,this._bl,8),v(this._ch,this._cl,16),v(this._dh,this._dl,24),v(this._eh,this._el,32),v(this._fh,this._fl,40),h},sha384$3=a,sha384$3}var hasRequiredSha_js;function requireSha_js(){return hasRequiredSha_js||(hasRequiredSha_js=1,function(r){r.exports=function(i){var n=i.toLowerCase(),s=r.exports[n];if(!s)throw new Error(n+" is not supported (we accept pull requests)");return new s},r.exports.sha=requireSha$1(),r.exports.sha1=requireSha1$1(),r.exports.sha224=requireSha224$1(),r.exports.sha256=requireSha256$1(),r.exports.sha384=requireSha384$1(),r.exports.sha512=requireSha512$1()}(sha_js)),sha_js.exports}var streamBrowserify,hasRequiredStreamBrowserify;function requireStreamBrowserify(){if(hasRequiredStreamBrowserify)return streamBrowserify;hasRequiredStreamBrowserify=1,streamBrowserify=i;var r=requireEvents().EventEmitter,t=requireInherits_browser();t(i,r),i.Readable=require_stream_readable$1(),i.Writable=require_stream_writable$1(),i.Duplex=require_stream_duplex$1(),i.Transform=require_stream_transform$1(),i.PassThrough=require_stream_passthrough$1(),i.finished=requireEndOfStream(),i.pipeline=requirePipeline(),i.Stream=i;function i(){r.call(this)}return i.prototype.pipe=function(n,s){var a=this;function h(mi){n.writable&&n.write(mi)===!1&&a.pause&&a.pause()}a.on("data",h);function v(){a.readable&&a.resume&&a.resume()}n.on("drain",v),!n._isStdio&&(!s||s.end!==!1)&&(a.on("end",u),a.on("close",l));var hi=!1;function u(){hi||(hi=!0,n.end())}function l(){hi||(hi=!0,typeof n.destroy=="function"&&n.destroy())}function vi(mi){if(D(),r.listenerCount(this,"error")===0)throw mi}a.on("error",vi),n.on("error",vi);function D(){a.removeListener("data",h),n.removeListener("drain",v),a.removeListener("end",u),a.removeListener("close",l),a.removeListener("error",vi),n.removeListener("error",vi),a.removeListener("end",D),a.removeListener("close",D),n.removeListener("close",D)}return a.on("end",D),a.on("close",D),n.on("close",D),n.emit("pipe",a),n},streamBrowserify}var cipherBase,hasRequiredCipherBase;function requireCipherBase(){if(hasRequiredCipherBase)return cipherBase;hasRequiredCipherBase=1;var r=requireSafeBuffer$1().Buffer,t=requireStreamBrowserify().Transform,i=requireString_decoder().StringDecoder,n=requireInherits_browser();function s(hi){t.call(this),this.hashMode=typeof hi=="string",this.hashMode?this[hi]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}n(s,t);var a=typeof Uint8Array<"u",h=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u"&&ArrayBuffer.isView&&(r.prototype instanceof Uint8Array||r.TYPED_ARRAY_SUPPORT);function v(hi,u){if(hi instanceof r)return hi;if(typeof hi=="string")return r.from(hi,u);if(h&&ArrayBuffer.isView(hi)){if(hi.byteLength===0)return r.alloc(0);var l=r.from(hi.buffer,hi.byteOffset,hi.byteLength);if(l.byteLength===hi.byteLength)return l}if(a&&hi instanceof Uint8Array||r.isBuffer(hi)&&hi.constructor&&typeof hi.constructor.isBuffer=="function"&&hi.constructor.isBuffer(hi))return r.from(hi);throw new TypeError('The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView.')}return s.prototype.update=function(hi,u,l){var vi=v(hi,u),D=this._update(vi);return this.hashMode?this:(l&&(D=this._toString(D,l)),D)},s.prototype.setAutoPadding=function(){},s.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")},s.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")},s.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")},s.prototype._transform=function(hi,u,l){var vi;try{this.hashMode?this._update(hi):this.push(this._update(hi))}catch(D){vi=D}finally{l(vi)}},s.prototype._flush=function(hi){var u;try{this.push(this.__final())}catch(l){u=l}hi(u)},s.prototype._finalOrDigest=function(hi){var u=this.__final()||r.alloc(0);return hi&&(u=this._toString(u,hi,!0)),u},s.prototype._toString=function(hi,u,l){if(this._decoder||(this._decoder=new i(u),this._encoding=u),this._encoding!==u)throw new Error("can’t switch encodings");var vi=this._decoder.write(hi);return l&&(vi+=this._decoder.end()),vi},cipherBase=s,cipherBase}var browser$a,hasRequiredBrowser$a;function requireBrowser$a(){if(hasRequiredBrowser$a)return browser$a;hasRequiredBrowser$a=1;var r=requireInherits_browser(),t=requireMd5_js(),i=requireRipemd160$2(),n=requireSha_js(),s=requireCipherBase();function a(h){s.call(this,"digest"),this._hash=h}return r(a,s),a.prototype._update=function(h){this._hash.update(h)},a.prototype._final=function(){return this._hash.digest()},browser$a=function(v){return v=v.toLowerCase(),v==="md5"?new t:v==="rmd160"||v==="ripemd160"?new i:new a(n(v))},browser$a}var legacy,hasRequiredLegacy;function requireLegacy(){if(hasRequiredLegacy)return legacy;hasRequiredLegacy=1;var r=requireInherits_browser(),t=requireSafeBuffer$1().Buffer,i=requireCipherBase(),n=t.alloc(128),s=64;function a(h,v){i.call(this,"digest"),typeof v=="string"&&(v=t.from(v)),this._alg=h,this._key=v,v.length>s?v=h(v):v.length<s&&(v=t.concat([v,n],s));for(var hi=this._ipad=t.allocUnsafe(s),u=this._opad=t.allocUnsafe(s),l=0;l<s;l++)hi[l]=v[l]^54,u[l]=v[l]^92;this._hash=[hi]}return r(a,i),a.prototype._update=function(h){this._hash.push(h)},a.prototype._final=function(){var h=this._alg(t.concat(this._hash));return this._alg(t.concat([this._opad,h]))},legacy=a,legacy}var md5$3,hasRequiredMd5$2;function requireMd5$2(){if(hasRequiredMd5$2)return md5$3;hasRequiredMd5$2=1;var r=requireMd5_js();return md5$3=function(t){return new r().update(t).digest()},md5$3}var browser$9,hasRequiredBrowser$9;function requireBrowser$9(){if(hasRequiredBrowser$9)return browser$9;hasRequiredBrowser$9=1;var r=requireInherits_browser(),t=requireLegacy(),i=requireCipherBase(),n=requireSafeBuffer$1().Buffer,s=requireMd5$2(),a=requireRipemd160$2(),h=requireSha_js(),v=n.alloc(128);function hi(u,l){i.call(this,"digest"),typeof l=="string"&&(l=n.from(l));var vi=u==="sha512"||u==="sha384"?128:64;if(this._alg=u,this._key=l,l.length>vi){var D=u==="rmd160"?new a:h(u);l=D.update(l).digest()}else l.length<vi&&(l=n.concat([l,v],vi));for(var mi=this._ipad=n.allocUnsafe(vi),gi=this._opad=n.allocUnsafe(vi),bi=0;bi<vi;bi++)mi[bi]=l[bi]^54,gi[bi]=l[bi]^92;this._hash=u==="rmd160"?new a:h(u),this._hash.update(mi)}return r(hi,i),hi.prototype._update=function(u){this._hash.update(u)},hi.prototype._final=function(){var u=this._hash.digest(),l=this._alg==="rmd160"?new a:h(this._alg);return l.update(this._opad).update(u).digest()},browser$9=function(l,vi){return l=l.toLowerCase(),l==="rmd160"||l==="ripemd160"?new hi("rmd160",vi):l==="md5"?new t(s,vi):new hi(l,vi)},browser$9}const sha224WithRSAEncryption={sign:"rsa",hash:"sha224",id:"302d300d06096086480165030402040500041c"},sha256WithRSAEncryption={sign:"rsa",hash:"sha256",id:"3031300d060960864801650304020105000420"},sha384WithRSAEncryption={sign:"rsa",hash:"sha384",id:"3041300d060960864801650304020205000430"},sha512WithRSAEncryption={sign:"rsa",hash:"sha512",id:"3051300d060960864801650304020305000440"},sha256$2={sign:"ecdsa",hash:"sha256",id:""},sha224$2={sign:"ecdsa",hash:"sha224",id:""},sha384$2={sign:"ecdsa",hash:"sha384",id:""},sha512$2={sign:"ecdsa",hash:"sha512",id:""},DSA={sign:"dsa",hash:"sha1",id:""},ripemd160WithRSA={sign:"rsa",hash:"rmd160",id:"3021300906052b2403020105000414"},md5WithRSAEncryption={sign:"rsa",hash:"md5",id:"3020300c06082a864886f70d020505000410"};var require$$6={sha224WithRSAEncryption,"RSA-SHA224":{sign:"ecdsa/rsa",hash:"sha224",id:"302d300d06096086480165030402040500041c"},sha256WithRSAEncryption,"RSA-SHA256":{sign:"ecdsa/rsa",hash:"sha256",id:"3031300d060960864801650304020105000420"},sha384WithRSAEncryption,"RSA-SHA384":{sign:"ecdsa/rsa",hash:"sha384",id:"3041300d060960864801650304020205000430"},sha512WithRSAEncryption,"RSA-SHA512":{sign:"ecdsa/rsa",hash:"sha512",id:"3051300d060960864801650304020305000440"},"RSA-SHA1":{sign:"rsa",hash:"sha1",id:"3021300906052b0e03021a05000414"},"ecdsa-with-SHA1":{sign:"ecdsa",hash:"sha1",id:""},sha256:sha256$2,sha224:sha224$2,sha384:sha384$2,sha512:sha512$2,"DSA-SHA":{sign:"dsa",hash:"sha1",id:""},"DSA-SHA1":{sign:"dsa",hash:"sha1",id:""},DSA,"DSA-WITH-SHA224":{sign:"dsa",hash:"sha224",id:""},"DSA-SHA224":{sign:"dsa",hash:"sha224",id:""},"DSA-WITH-SHA256":{sign:"dsa",hash:"sha256",id:""},"DSA-SHA256":{sign:"dsa",hash:"sha256",id:""},"DSA-WITH-SHA384":{sign:"dsa",hash:"sha384",id:""},"DSA-SHA384":{sign:"dsa",hash:"sha384",id:""},"DSA-WITH-SHA512":{sign:"dsa",hash:"sha512",id:""},"DSA-SHA512":{sign:"dsa",hash:"sha512",id:""},"DSA-RIPEMD160":{sign:"dsa",hash:"rmd160",id:""},ripemd160WithRSA,"RSA-RIPEMD160":{sign:"rsa",hash:"rmd160",id:"3021300906052b2403020105000414"},md5WithRSAEncryption,"RSA-MD5":{sign:"rsa",hash:"md5",id:"3020300c06082a864886f70d020505000410"}},algos,hasRequiredAlgos;function requireAlgos(){return hasRequiredAlgos||(hasRequiredAlgos=1,algos=require$$6),algos}var browser$8={},precondition,hasRequiredPrecondition;function requirePrecondition(){if(hasRequiredPrecondition)return precondition;hasRequiredPrecondition=1;var r=Math.pow(2,30)-1;return precondition=function(t,i){if(typeof t!="number")throw new TypeError("Iterations not a number");if(t<0)throw new TypeError("Bad iterations");if(typeof i!="number")throw new TypeError("Key length not a number");if(i<0||i>r||i!==i)throw new TypeError("Bad key length")},precondition}var defaultEncoding_1,hasRequiredDefaultEncoding;function requireDefaultEncoding(){if(hasRequiredDefaultEncoding)return defaultEncoding_1;hasRequiredDefaultEncoding=1;var r;if(commonjsGlobal.process&&commonjsGlobal.process.browser)r="utf-8";else if(commonjsGlobal.process&&commonjsGlobal.process.version){var t=parseInt(process$1.version.split(".")[0].slice(1),10);r=t>=6?"utf-8":"binary"}else r="utf-8";return defaultEncoding_1=r,defaultEncoding_1}var makeHash,hasRequiredMakeHash;function requireMakeHash(){if(hasRequiredMakeHash)return makeHash;hasRequiredMakeHash=1;var r=4,t=new Buffer(r);t.fill(0);var i=8,n=16;function s(a){if(a.length%r!==0){var h=a.length+(r-a.length%r);a=Buffer.concat([a,t],h)}for(var v=new Array(a.length>>>2),hi=0,u=0;hi<a.length;hi+=r,u++)v[u]=a.readInt32LE(hi);return v}return makeHash=function(h,v){var hi=v(s(h),h.length*i);h=new Buffer(n);for(var u=0;u<hi.length;u++)h.writeInt32LE(hi[u],u<<2,!0);return h},makeHash}var md5$2,hasRequiredMd5$1;function requireMd5$1(){if(hasRequiredMd5$1)return md5$2;hasRequiredMd5$1=1;var r=requireMakeHash();function t(u,l){u[l>>5]|=128<<l%32,u[(l+64>>>9<<4)+14]=l;for(var vi=1732584193,D=-271733879,mi=-1732584194,gi=271733878,bi=0;bi<u.length;bi+=16){var Ri=vi,Ti=D,Ii=mi,qi=gi;vi=n(vi,D,mi,gi,u[bi+0],7,-680876936),gi=n(gi,vi,D,mi,u[bi+1],12,-389564586),mi=n(mi,gi,vi,D,u[bi+2],17,606105819),D=n(D,mi,gi,vi,u[bi+3],22,-1044525330),vi=n(vi,D,mi,gi,u[bi+4],7,-176418897),gi=n(gi,vi,D,mi,u[bi+5],12,1200080426),mi=n(mi,gi,vi,D,u[bi+6],17,-1473231341),D=n(D,mi,gi,vi,u[bi+7],22,-45705983),vi=n(vi,D,mi,gi,u[bi+8],7,1770035416),gi=n(gi,vi,D,mi,u[bi+9],12,-1958414417),mi=n(mi,gi,vi,D,u[bi+10],17,-42063),D=n(D,mi,gi,vi,u[bi+11],22,-1990404162),vi=n(vi,D,mi,gi,u[bi+12],7,1804603682),gi=n(gi,vi,D,mi,u[bi+13],12,-40341101),mi=n(mi,gi,vi,D,u[bi+14],17,-1502002290),D=n(D,mi,gi,vi,u[bi+15],22,1236535329),vi=s(vi,D,mi,gi,u[bi+1],5,-165796510),gi=s(gi,vi,D,mi,u[bi+6],9,-1069501632),mi=s(mi,gi,vi,D,u[bi+11],14,643717713),D=s(D,mi,gi,vi,u[bi+0],20,-373897302),vi=s(vi,D,mi,gi,u[bi+5],5,-701558691),gi=s(gi,vi,D,mi,u[bi+10],9,38016083),mi=s(mi,gi,vi,D,u[bi+15],14,-660478335),D=s(D,mi,gi,vi,u[bi+4],20,-405537848),vi=s(vi,D,mi,gi,u[bi+9],5,568446438),gi=s(gi,vi,D,mi,u[bi+14],9,-1019803690),mi=s(mi,gi,vi,D,u[bi+3],14,-187363961),D=s(D,mi,gi,vi,u[bi+8],20,1163531501),vi=s(vi,D,mi,gi,u[bi+13],5,-1444681467),gi=s(gi,vi,D,mi,u[bi+2],9,-51403784),mi=s(mi,gi,vi,D,u[bi+7],14,1735328473),D=s(D,mi,gi,vi,u[bi+12],20,-1926607734),vi=a(vi,D,mi,gi,u[bi+5],4,-378558),gi=a(gi,vi,D,mi,u[bi+8],11,-2022574463),mi=a(mi,gi,vi,D,u[bi+11],16,1839030562),D=a(D,mi,gi,vi,u[bi+14],23,-35309556),vi=a(vi,D,mi,gi,u[bi+1],4,-1530992060),gi=a(gi,vi,D,mi,u[bi+4],11,1272893353),mi=a(mi,gi,vi,D,u[bi+7],16,-155497632),D=a(D,mi,gi,vi,u[bi+10],23,-1094730640),vi=a(vi,D,mi,gi,u[bi+13],4,681279174),gi=a(gi,vi,D,mi,u[bi+0],11,-358537222),mi=a(mi,gi,vi,D,u[bi+3],16,-722521979),D=a(D,mi,gi,vi,u[bi+6],23,76029189),vi=a(vi,D,mi,gi,u[bi+9],4,-640364487),gi=a(gi,vi,D,mi,u[bi+12],11,-421815835),mi=a(mi,gi,vi,D,u[bi+15],16,530742520),D=a(D,mi,gi,vi,u[bi+2],23,-995338651),vi=h(vi,D,mi,gi,u[bi+0],6,-198630844),gi=h(gi,vi,D,mi,u[bi+7],10,1126891415),mi=h(mi,gi,vi,D,u[bi+14],15,-1416354905),D=h(D,mi,gi,vi,u[bi+5],21,-57434055),vi=h(vi,D,mi,gi,u[bi+12],6,1700485571),gi=h(gi,vi,D,mi,u[bi+3],10,-1894986606),mi=h(mi,gi,vi,D,u[bi+10],15,-1051523),D=h(D,mi,gi,vi,u[bi+1],21,-2054922799),vi=h(vi,D,mi,gi,u[bi+8],6,1873313359),gi=h(gi,vi,D,mi,u[bi+15],10,-30611744),mi=h(mi,gi,vi,D,u[bi+6],15,-1560198380),D=h(D,mi,gi,vi,u[bi+13],21,1309151649),vi=h(vi,D,mi,gi,u[bi+4],6,-145523070),gi=h(gi,vi,D,mi,u[bi+11],10,-1120210379),mi=h(mi,gi,vi,D,u[bi+2],15,718787259),D=h(D,mi,gi,vi,u[bi+9],21,-343485551),vi=v(vi,Ri),D=v(D,Ti),mi=v(mi,Ii),gi=v(gi,qi)}return[vi,D,mi,gi]}function i(u,l,vi,D,mi,gi){return v(hi(v(v(l,u),v(D,gi)),mi),vi)}function n(u,l,vi,D,mi,gi,bi){return i(l&vi|~l&D,u,l,mi,gi,bi)}function s(u,l,vi,D,mi,gi,bi){return i(l&D|vi&~D,u,l,mi,gi,bi)}function a(u,l,vi,D,mi,gi,bi){return i(l^vi^D,u,l,mi,gi,bi)}function h(u,l,vi,D,mi,gi,bi){return i(vi^(l|~D),u,l,mi,gi,bi)}function v(u,l){var vi=(u&65535)+(l&65535),D=(u>>16)+(l>>16)+(vi>>16);return D<<16|vi&65535}function hi(u,l){return u<<l|u>>>32-l}return md5$2=function(l){return r(l,t)},md5$2}var hashBase,hasRequiredHashBase;function requireHashBase(){if(hasRequiredHashBase)return hashBase;hasRequiredHashBase=1;var r=requireStreamBrowserify().Transform,t=requireInherits_browser();function i(n){r.call(this),this._block=new Buffer(n),this._blockSize=n,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}return t(i,r),i.prototype._transform=function(n,s,a){var h=null;try{s!=="buffer"&&(n=new Buffer(n,s)),this.update(n)}catch(v){h=v}a(h)},i.prototype._flush=function(n){var s=null;try{this.push(this._digest())}catch(a){s=a}n(s)},i.prototype.update=function(n,s){if(!Buffer.isBuffer(n)&&typeof n!="string")throw new TypeError("Data must be a string or a buffer");if(this._finalized)throw new Error("Digest already called");Buffer.isBuffer(n)||(n=new Buffer(n,s||"binary"));for(var a=this._block,h=0;this._blockOffset+n.length-h>=this._blockSize;){for(var v=this._blockOffset;v<this._blockSize;)a[v++]=n[h++];this._update(),this._blockOffset=0}for(;h<n.length;)a[this._blockOffset++]=n[h++];for(var hi=0,u=n.length*8;u>0;++hi)this._length[hi]+=u,u=this._length[hi]/4294967296|0,u>0&&(this._length[hi]-=4294967296*u);return this},i.prototype._update=function(n){throw new Error("_update is not implemented")},i.prototype.digest=function(n){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var s=this._digest();return n!==void 0&&(s=s.toString(n)),s},i.prototype._digest=function(){throw new Error("_digest is not implemented")},hashBase=i,hashBase}var ripemd160$2,hasRequiredRipemd160$1;function requireRipemd160$1(){if(hasRequiredRipemd160$1)return ripemd160$2;hasRequiredRipemd160$1=1;var r=requireInherits_browser(),t=requireHashBase();function i(){t.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}r(i,t),i.prototype._update=function(){for(var u=new Array(16),l=0;l<16;++l)u[l]=this._block.readInt32LE(l*4);var vi=this._a,D=this._b,mi=this._c,gi=this._d,bi=this._e;vi=s(vi,D,mi,gi,bi,u[0],0,11),mi=n(mi,10),bi=s(bi,vi,D,mi,gi,u[1],0,14),D=n(D,10),gi=s(gi,bi,vi,D,mi,u[2],0,15),vi=n(vi,10),mi=s(mi,gi,bi,vi,D,u[3],0,12),bi=n(bi,10),D=s(D,mi,gi,bi,vi,u[4],0,5),gi=n(gi,10),vi=s(vi,D,mi,gi,bi,u[5],0,8),mi=n(mi,10),bi=s(bi,vi,D,mi,gi,u[6],0,7),D=n(D,10),gi=s(gi,bi,vi,D,mi,u[7],0,9),vi=n(vi,10),mi=s(mi,gi,bi,vi,D,u[8],0,11),bi=n(bi,10),D=s(D,mi,gi,bi,vi,u[9],0,13),gi=n(gi,10),vi=s(vi,D,mi,gi,bi,u[10],0,14),mi=n(mi,10),bi=s(bi,vi,D,mi,gi,u[11],0,15),D=n(D,10),gi=s(gi,bi,vi,D,mi,u[12],0,6),vi=n(vi,10),mi=s(mi,gi,bi,vi,D,u[13],0,7),bi=n(bi,10),D=s(D,mi,gi,bi,vi,u[14],0,9),gi=n(gi,10),vi=s(vi,D,mi,gi,bi,u[15],0,8),mi=n(mi,10),bi=a(bi,vi,D,mi,gi,u[7],1518500249,7),D=n(D,10),gi=a(gi,bi,vi,D,mi,u[4],1518500249,6),vi=n(vi,10),mi=a(mi,gi,bi,vi,D,u[13],1518500249,8),bi=n(bi,10),D=a(D,mi,gi,bi,vi,u[1],1518500249,13),gi=n(gi,10),vi=a(vi,D,mi,gi,bi,u[10],1518500249,11),mi=n(mi,10),bi=a(bi,vi,D,mi,gi,u[6],1518500249,9),D=n(D,10),gi=a(gi,bi,vi,D,mi,u[15],1518500249,7),vi=n(vi,10),mi=a(mi,gi,bi,vi,D,u[3],1518500249,15),bi=n(bi,10),D=a(D,mi,gi,bi,vi,u[12],1518500249,7),gi=n(gi,10),vi=a(vi,D,mi,gi,bi,u[0],1518500249,12),mi=n(mi,10),bi=a(bi,vi,D,mi,gi,u[9],1518500249,15),D=n(D,10),gi=a(gi,bi,vi,D,mi,u[5],1518500249,9),vi=n(vi,10),mi=a(mi,gi,bi,vi,D,u[2],1518500249,11),bi=n(bi,10),D=a(D,mi,gi,bi,vi,u[14],1518500249,7),gi=n(gi,10),vi=a(vi,D,mi,gi,bi,u[11],1518500249,13),mi=n(mi,10),bi=a(bi,vi,D,mi,gi,u[8],1518500249,12),D=n(D,10),gi=h(gi,bi,vi,D,mi,u[3],1859775393,11),vi=n(vi,10),mi=h(mi,gi,bi,vi,D,u[10],1859775393,13),bi=n(bi,10),D=h(D,mi,gi,bi,vi,u[14],1859775393,6),gi=n(gi,10),vi=h(vi,D,mi,gi,bi,u[4],1859775393,7),mi=n(mi,10),bi=h(bi,vi,D,mi,gi,u[9],1859775393,14),D=n(D,10),gi=h(gi,bi,vi,D,mi,u[15],1859775393,9),vi=n(vi,10),mi=h(mi,gi,bi,vi,D,u[8],1859775393,13),bi=n(bi,10),D=h(D,mi,gi,bi,vi,u[1],1859775393,15),gi=n(gi,10),vi=h(vi,D,mi,gi,bi,u[2],1859775393,14),mi=n(mi,10),bi=h(bi,vi,D,mi,gi,u[7],1859775393,8),D=n(D,10),gi=h(gi,bi,vi,D,mi,u[0],1859775393,13),vi=n(vi,10),mi=h(mi,gi,bi,vi,D,u[6],1859775393,6),bi=n(bi,10),D=h(D,mi,gi,bi,vi,u[13],1859775393,5),gi=n(gi,10),vi=h(vi,D,mi,gi,bi,u[11],1859775393,12),mi=n(mi,10),bi=h(bi,vi,D,mi,gi,u[5],1859775393,7),D=n(D,10),gi=h(gi,bi,vi,D,mi,u[12],1859775393,5),vi=n(vi,10),mi=v(mi,gi,bi,vi,D,u[1],2400959708,11),bi=n(bi,10),D=v(D,mi,gi,bi,vi,u[9],2400959708,12),gi=n(gi,10),vi=v(vi,D,mi,gi,bi,u[11],2400959708,14),mi=n(mi,10),bi=v(bi,vi,D,mi,gi,u[10],2400959708,15),D=n(D,10),gi=v(gi,bi,vi,D,mi,u[0],2400959708,14),vi=n(vi,10),mi=v(mi,gi,bi,vi,D,u[8],2400959708,15),bi=n(bi,10),D=v(D,mi,gi,bi,vi,u[12],2400959708,9),gi=n(gi,10),vi=v(vi,D,mi,gi,bi,u[4],2400959708,8),mi=n(mi,10),bi=v(bi,vi,D,mi,gi,u[13],2400959708,9),D=n(D,10),gi=v(gi,bi,vi,D,mi,u[3],2400959708,14),vi=n(vi,10),mi=v(mi,gi,bi,vi,D,u[7],2400959708,5),bi=n(bi,10),D=v(D,mi,gi,bi,vi,u[15],2400959708,6),gi=n(gi,10),vi=v(vi,D,mi,gi,bi,u[14],2400959708,8),mi=n(mi,10),bi=v(bi,vi,D,mi,gi,u[5],2400959708,6),D=n(D,10),gi=v(gi,bi,vi,D,mi,u[6],2400959708,5),vi=n(vi,10),mi=v(mi,gi,bi,vi,D,u[2],2400959708,12),bi=n(bi,10),D=hi(D,mi,gi,bi,vi,u[4],2840853838,9),gi=n(gi,10),vi=hi(vi,D,mi,gi,bi,u[0],2840853838,15),mi=n(mi,10),bi=hi(bi,vi,D,mi,gi,u[5],2840853838,5),D=n(D,10),gi=hi(gi,bi,vi,D,mi,u[9],2840853838,11),vi=n(vi,10),mi=hi(mi,gi,bi,vi,D,u[7],2840853838,6),bi=n(bi,10),D=hi(D,mi,gi,bi,vi,u[12],2840853838,8),gi=n(gi,10),vi=hi(vi,D,mi,gi,bi,u[2],2840853838,13),mi=n(mi,10),bi=hi(bi,vi,D,mi,gi,u[10],2840853838,12),D=n(D,10),gi=hi(gi,bi,vi,D,mi,u[14],2840853838,5),vi=n(vi,10),mi=hi(mi,gi,bi,vi,D,u[1],2840853838,12),bi=n(bi,10),D=hi(D,mi,gi,bi,vi,u[3],2840853838,13),gi=n(gi,10),vi=hi(vi,D,mi,gi,bi,u[8],2840853838,14),mi=n(mi,10),bi=hi(bi,vi,D,mi,gi,u[11],2840853838,11),D=n(D,10),gi=hi(gi,bi,vi,D,mi,u[6],2840853838,8),vi=n(vi,10),mi=hi(mi,gi,bi,vi,D,u[15],2840853838,5),bi=n(bi,10),D=hi(D,mi,gi,bi,vi,u[13],2840853838,6),gi=n(gi,10);var Ri=this._a,Ti=this._b,Ii=this._c,qi=this._d,Oi=this._e;Ri=hi(Ri,Ti,Ii,qi,Oi,u[5],1352829926,8),Ii=n(Ii,10),Oi=hi(Oi,Ri,Ti,Ii,qi,u[14],1352829926,9),Ti=n(Ti,10),qi=hi(qi,Oi,Ri,Ti,Ii,u[7],1352829926,9),Ri=n(Ri,10),Ii=hi(Ii,qi,Oi,Ri,Ti,u[0],1352829926,11),Oi=n(Oi,10),Ti=hi(Ti,Ii,qi,Oi,Ri,u[9],1352829926,13),qi=n(qi,10),Ri=hi(Ri,Ti,Ii,qi,Oi,u[2],1352829926,15),Ii=n(Ii,10),Oi=hi(Oi,Ri,Ti,Ii,qi,u[11],1352829926,15),Ti=n(Ti,10),qi=hi(qi,Oi,Ri,Ti,Ii,u[4],1352829926,5),Ri=n(Ri,10),Ii=hi(Ii,qi,Oi,Ri,Ti,u[13],1352829926,7),Oi=n(Oi,10),Ti=hi(Ti,Ii,qi,Oi,Ri,u[6],1352829926,7),qi=n(qi,10),Ri=hi(Ri,Ti,Ii,qi,Oi,u[15],1352829926,8),Ii=n(Ii,10),Oi=hi(Oi,Ri,Ti,Ii,qi,u[8],1352829926,11),Ti=n(Ti,10),qi=hi(qi,Oi,Ri,Ti,Ii,u[1],1352829926,14),Ri=n(Ri,10),Ii=hi(Ii,qi,Oi,Ri,Ti,u[10],1352829926,14),Oi=n(Oi,10),Ti=hi(Ti,Ii,qi,Oi,Ri,u[3],1352829926,12),qi=n(qi,10),Ri=hi(Ri,Ti,Ii,qi,Oi,u[12],1352829926,6),Ii=n(Ii,10),Oi=v(Oi,Ri,Ti,Ii,qi,u[6],1548603684,9),Ti=n(Ti,10),qi=v(qi,Oi,Ri,Ti,Ii,u[11],1548603684,13),Ri=n(Ri,10),Ii=v(Ii,qi,Oi,Ri,Ti,u[3],1548603684,15),Oi=n(Oi,10),Ti=v(Ti,Ii,qi,Oi,Ri,u[7],1548603684,7),qi=n(qi,10),Ri=v(Ri,Ti,Ii,qi,Oi,u[0],1548603684,12),Ii=n(Ii,10),Oi=v(Oi,Ri,Ti,Ii,qi,u[13],1548603684,8),Ti=n(Ti,10),qi=v(qi,Oi,Ri,Ti,Ii,u[5],1548603684,9),Ri=n(Ri,10),Ii=v(Ii,qi,Oi,Ri,Ti,u[10],1548603684,11),Oi=n(Oi,10),Ti=v(Ti,Ii,qi,Oi,Ri,u[14],1548603684,7),qi=n(qi,10),Ri=v(Ri,Ti,Ii,qi,Oi,u[15],1548603684,7),Ii=n(Ii,10),Oi=v(Oi,Ri,Ti,Ii,qi,u[8],1548603684,12),Ti=n(Ti,10),qi=v(qi,Oi,Ri,Ti,Ii,u[12],1548603684,7),Ri=n(Ri,10),Ii=v(Ii,qi,Oi,Ri,Ti,u[4],1548603684,6),Oi=n(Oi,10),Ti=v(Ti,Ii,qi,Oi,Ri,u[9],1548603684,15),qi=n(qi,10),Ri=v(Ri,Ti,Ii,qi,Oi,u[1],1548603684,13),Ii=n(Ii,10),Oi=v(Oi,Ri,Ti,Ii,qi,u[2],1548603684,11),Ti=n(Ti,10),qi=h(qi,Oi,Ri,Ti,Ii,u[15],1836072691,9),Ri=n(Ri,10),Ii=h(Ii,qi,Oi,Ri,Ti,u[5],1836072691,7),Oi=n(Oi,10),Ti=h(Ti,Ii,qi,Oi,Ri,u[1],1836072691,15),qi=n(qi,10),Ri=h(Ri,Ti,Ii,qi,Oi,u[3],1836072691,11),Ii=n(Ii,10),Oi=h(Oi,Ri,Ti,Ii,qi,u[7],1836072691,8),Ti=n(Ti,10),qi=h(qi,Oi,Ri,Ti,Ii,u[14],1836072691,6),Ri=n(Ri,10),Ii=h(Ii,qi,Oi,Ri,Ti,u[6],1836072691,6),Oi=n(Oi,10),Ti=h(Ti,Ii,qi,Oi,Ri,u[9],1836072691,14),qi=n(qi,10),Ri=h(Ri,Ti,Ii,qi,Oi,u[11],1836072691,12),Ii=n(Ii,10),Oi=h(Oi,Ri,Ti,Ii,qi,u[8],1836072691,13),Ti=n(Ti,10),qi=h(qi,Oi,Ri,Ti,Ii,u[12],1836072691,5),Ri=n(Ri,10),Ii=h(Ii,qi,Oi,Ri,Ti,u[2],1836072691,14),Oi=n(Oi,10),Ti=h(Ti,Ii,qi,Oi,Ri,u[10],1836072691,13),qi=n(qi,10),Ri=h(Ri,Ti,Ii,qi,Oi,u[0],1836072691,13),Ii=n(Ii,10),Oi=h(Oi,Ri,Ti,Ii,qi,u[4],1836072691,7),Ti=n(Ti,10),qi=h(qi,Oi,Ri,Ti,Ii,u[13],1836072691,5),Ri=n(Ri,10),Ii=a(Ii,qi,Oi,Ri,Ti,u[8],2053994217,15),Oi=n(Oi,10),Ti=a(Ti,Ii,qi,Oi,Ri,u[6],2053994217,5),qi=n(qi,10),Ri=a(Ri,Ti,Ii,qi,Oi,u[4],2053994217,8),Ii=n(Ii,10),Oi=a(Oi,Ri,Ti,Ii,qi,u[1],2053994217,11),Ti=n(Ti,10),qi=a(qi,Oi,Ri,Ti,Ii,u[3],2053994217,14),Ri=n(Ri,10),Ii=a(Ii,qi,Oi,Ri,Ti,u[11],2053994217,14),Oi=n(Oi,10),Ti=a(Ti,Ii,qi,Oi,Ri,u[15],2053994217,6),qi=n(qi,10),Ri=a(Ri,Ti,Ii,qi,Oi,u[0],2053994217,14),Ii=n(Ii,10),Oi=a(Oi,Ri,Ti,Ii,qi,u[5],2053994217,6),Ti=n(Ti,10),qi=a(qi,Oi,Ri,Ti,Ii,u[12],2053994217,9),Ri=n(Ri,10),Ii=a(Ii,qi,Oi,Ri,Ti,u[2],2053994217,12),Oi=n(Oi,10),Ti=a(Ti,Ii,qi,Oi,Ri,u[13],2053994217,9),qi=n(qi,10),Ri=a(Ri,Ti,Ii,qi,Oi,u[9],2053994217,12),Ii=n(Ii,10),Oi=a(Oi,Ri,Ti,Ii,qi,u[7],2053994217,5),Ti=n(Ti,10),qi=a(qi,Oi,Ri,Ti,Ii,u[10],2053994217,15),Ri=n(Ri,10),Ii=a(Ii,qi,Oi,Ri,Ti,u[14],2053994217,8),Oi=n(Oi,10),Ti=s(Ti,Ii,qi,Oi,Ri,u[12],0,8),qi=n(qi,10),Ri=s(Ri,Ti,Ii,qi,Oi,u[15],0,5),Ii=n(Ii,10),Oi=s(Oi,Ri,Ti,Ii,qi,u[10],0,12),Ti=n(Ti,10),qi=s(qi,Oi,Ri,Ti,Ii,u[4],0,9),Ri=n(Ri,10),Ii=s(Ii,qi,Oi,Ri,Ti,u[1],0,12),Oi=n(Oi,10),Ti=s(Ti,Ii,qi,Oi,Ri,u[5],0,5),qi=n(qi,10),Ri=s(Ri,Ti,Ii,qi,Oi,u[8],0,14),Ii=n(Ii,10),Oi=s(Oi,Ri,Ti,Ii,qi,u[7],0,6),Ti=n(Ti,10),qi=s(qi,Oi,Ri,Ti,Ii,u[6],0,8),Ri=n(Ri,10),Ii=s(Ii,qi,Oi,Ri,Ti,u[2],0,13),Oi=n(Oi,10),Ti=s(Ti,Ii,qi,Oi,Ri,u[13],0,6),qi=n(qi,10),Ri=s(Ri,Ti,Ii,qi,Oi,u[14],0,5),Ii=n(Ii,10),Oi=s(Oi,Ri,Ti,Ii,qi,u[0],0,15),Ti=n(Ti,10),qi=s(qi,Oi,Ri,Ti,Ii,u[3],0,13),Ri=n(Ri,10),Ii=s(Ii,qi,Oi,Ri,Ti,u[9],0,11),Oi=n(Oi,10),Ti=s(Ti,Ii,qi,Oi,Ri,u[11],0,11),qi=n(qi,10);var ki=this._b+mi+qi|0;this._b=this._c+gi+Oi|0,this._c=this._d+bi+Ri|0,this._d=this._e+vi+Ti|0,this._e=this._a+D+Ii|0,this._a=ki},i.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var u=new Buffer(20);return u.writeInt32LE(this._a,0),u.writeInt32LE(this._b,4),u.writeInt32LE(this._c,8),u.writeInt32LE(this._d,12),u.writeInt32LE(this._e,16),u};function n(u,l){return u<<l|u>>>32-l}function s(u,l,vi,D,mi,gi,bi,Ri){return n(u+(l^vi^D)+gi+bi|0,Ri)+mi|0}function a(u,l,vi,D,mi,gi,bi,Ri){return n(u+(l&vi|~l&D)+gi+bi|0,Ri)+mi|0}function h(u,l,vi,D,mi,gi,bi,Ri){return n(u+((l|~vi)^D)+gi+bi|0,Ri)+mi|0}function v(u,l,vi,D,mi,gi,bi,Ri){return n(u+(l&D|vi&~D)+gi+bi|0,Ri)+mi|0}function hi(u,l,vi,D,mi,gi,bi,Ri){return n(u+(l^(vi|~D))+gi+bi|0,Ri)+mi|0}return ripemd160$2=i,ripemd160$2}var toBuffer_1,hasRequiredToBuffer;function requireToBuffer(){if(hasRequiredToBuffer)return toBuffer_1;hasRequiredToBuffer=1;var r=requireSafeBuffer$1().Buffer,t=requireToBuffer$1(),i=typeof Uint8Array<"u",n=i&&typeof ArrayBuffer<"u",s=n&&ArrayBuffer.isView;return toBuffer_1=function(a,h,v){if(typeof a=="string"||r.isBuffer(a)||i&&a instanceof Uint8Array||s&&s(a))return t(a,h);throw new TypeError(v+" must be a string, a Buffer, a Uint8Array, or a DataView")},toBuffer_1}var syncBrowser,hasRequiredSyncBrowser;function requireSyncBrowser(){if(hasRequiredSyncBrowser)return syncBrowser;hasRequiredSyncBrowser=1;var r=requireMd5$1(),t=requireRipemd160$1(),i=requireSha_js(),n=requireSafeBuffer$1().Buffer,s=requirePrecondition(),a=requireDefaultEncoding(),h=requireToBuffer(),v=n.alloc(128),hi={__proto__:null,md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,"sha512-256":32,ripemd160:20,rmd160:20},u={__proto__:null,"sha-1":"sha1","sha-224":"sha224","sha-256":"sha256","sha-384":"sha384","sha-512":"sha512","ripemd-160":"ripemd160"};function l(gi){return new t().update(gi).digest()}function vi(gi){function bi(Ri){return i(gi).update(Ri).digest()}return gi==="rmd160"||gi==="ripemd160"?l:gi==="md5"?r:bi}function D(gi,bi,Ri){var Ti=vi(gi),Ii=gi==="sha512"||gi==="sha384"?128:64;bi.length>Ii?bi=Ti(bi):bi.length<Ii&&(bi=n.concat([bi,v],Ii));for(var qi=n.allocUnsafe(Ii+hi[gi]),Oi=n.allocUnsafe(Ii+hi[gi]),ki=0;ki<Ii;ki++)qi[ki]=bi[ki]^54,Oi[ki]=bi[ki]^92;var Li=n.allocUnsafe(Ii+Ri+4);qi.copy(Li,0,0,Ii),this.ipad1=Li,this.ipad2=qi,this.opad=Oi,this.alg=gi,this.blocksize=Ii,this.hash=Ti,this.size=hi[gi]}D.prototype.run=function(gi,bi){gi.copy(bi,this.blocksize);var Ri=this.hash(bi);return Ri.copy(this.opad,this.blocksize),this.hash(this.opad)};function mi(gi,bi,Ri,Ti,Ii){s(Ri,Ti),gi=h(gi,a,"Password"),bi=h(bi,a,"Salt");var qi=(Ii||"sha1").toLowerCase(),Oi=u[qi]||qi,ki=hi[Oi];if(typeof ki!="number"||!ki)throw new TypeError("Digest algorithm not supported: "+Ii);var Li=new D(Oi,gi,bi.length),ji=n.allocUnsafe(Ti),Hi=n.allocUnsafe(bi.length+4);bi.copy(Hi,0,0,bi.length);for(var Ui=0,Qi=ki,$i=Math.ceil(Ti/Qi),wi=1;wi<=$i;wi++){Hi.writeUInt32BE(wi,bi.length);for(var xi=Li.run(Hi,Li.ipad1),yi=xi,Ei=1;Ei<Ri;Ei++){yi=Li.run(yi,Li.ipad2);for(var Ci=0;Ci<Qi;Ci++)xi[Ci]^=yi[Ci]}xi.copy(ji,Ui),Ui+=Qi}return ji}return syncBrowser=mi,syncBrowser}var async,hasRequiredAsync;function requireAsync(){if(hasRequiredAsync)return async;hasRequiredAsync=1;var r=requireSafeBuffer$1().Buffer,t=requirePrecondition(),i=requireDefaultEncoding(),n=requireSyncBrowser(),s=requireToBuffer(),a,h=commonjsGlobal.crypto&&commonjsGlobal.crypto.subtle,v={sha:"SHA-1","sha-1":"SHA-1",sha1:"SHA-1",sha256:"SHA-256","sha-256":"SHA-256",sha384:"SHA-384","sha-384":"SHA-384","sha-512":"SHA-512",sha512:"SHA-512"},hi=[],u;function l(){return u||(commonjsGlobal.process&&commonjsGlobal.process.nextTick?u=commonjsGlobal.process.nextTick:commonjsGlobal.queueMicrotask?u=commonjsGlobal.queueMicrotask:commonjsGlobal.setImmediate?u=commonjsGlobal.setImmediate:u=commonjsGlobal.setTimeout,u)}function vi(gi,bi,Ri,Ti,Ii){return h.importKey("raw",gi,{name:"PBKDF2"},!1,["deriveBits"]).then(function(qi){return h.deriveBits({name:"PBKDF2",salt:bi,iterations:Ri,hash:{name:Ii}},qi,Ti<<3)}).then(function(qi){return r.from(qi)})}function D(gi){if(commonjsGlobal.process&&!commonjsGlobal.process.browser||!h||!h.importKey||!h.deriveBits)return Promise.resolve(!1);if(hi[gi]!==void 0)return hi[gi];a=a||r.alloc(8);var bi=vi(a,a,10,128,gi).then(function(){return!0},function(){return!1});return hi[gi]=bi,bi}function mi(gi,bi){gi.then(function(Ri){l()(function(){bi(null,Ri)})},function(Ri){l()(function(){bi(Ri)})})}return async=function(gi,bi,Ri,Ti,Ii,qi){typeof Ii=="function"&&(qi=Ii,Ii=void 0),Ii=Ii||"sha1";var Oi=v[Ii.toLowerCase()];if(!Oi||typeof commonjsGlobal.Promise!="function"){l()(function(){var ki;try{ki=n(gi,bi,Ri,Ti,Ii)}catch(Li){qi(Li);return}qi(null,ki)});return}if(t(Ri,Ti),gi=s(gi,i,"Password"),bi=s(bi,i,"Salt"),typeof qi!="function")throw new Error("No callback provided to pbkdf2");mi(D(Oi).then(function(ki){return ki?vi(gi,bi,Ri,Ti,Oi):n(gi,bi,Ri,Ti,Ii)}),qi)},async}var hasRequiredBrowser$8;function requireBrowser$8(){return hasRequiredBrowser$8||(hasRequiredBrowser$8=1,browser$8.pbkdf2=requireAsync(),browser$8.pbkdf2Sync=requireSyncBrowser()),browser$8}var browser$7={},des$1={},utils$3={},hasRequiredUtils$3;function requireUtils$3(){if(hasRequiredUtils$3)return utils$3;hasRequiredUtils$3=1,utils$3.readUInt32BE=function(s,a){var h=s[0+a]<<24|s[1+a]<<16|s[2+a]<<8|s[3+a];return h>>>0},utils$3.writeUInt32BE=function(s,a,h){s[0+h]=a>>>24,s[1+h]=a>>>16&255,s[2+h]=a>>>8&255,s[3+h]=a&255},utils$3.ip=function(s,a,h,v){for(var hi=0,u=0,l=6;l>=0;l-=2){for(var vi=0;vi<=24;vi+=8)hi<<=1,hi|=a>>>vi+l&1;for(var vi=0;vi<=24;vi+=8)hi<<=1,hi|=s>>>vi+l&1}for(var l=6;l>=0;l-=2){for(var vi=1;vi<=25;vi+=8)u<<=1,u|=a>>>vi+l&1;for(var vi=1;vi<=25;vi+=8)u<<=1,u|=s>>>vi+l&1}h[v+0]=hi>>>0,h[v+1]=u>>>0},utils$3.rip=function(s,a,h,v){for(var hi=0,u=0,l=0;l<4;l++)for(var vi=24;vi>=0;vi-=8)hi<<=1,hi|=a>>>vi+l&1,hi<<=1,hi|=s>>>vi+l&1;for(var l=4;l<8;l++)for(var vi=24;vi>=0;vi-=8)u<<=1,u|=a>>>vi+l&1,u<<=1,u|=s>>>vi+l&1;h[v+0]=hi>>>0,h[v+1]=u>>>0},utils$3.pc1=function(s,a,h,v){for(var hi=0,u=0,l=7;l>=5;l--){for(var vi=0;vi<=24;vi+=8)hi<<=1,hi|=a>>vi+l&1;for(var vi=0;vi<=24;vi+=8)hi<<=1,hi|=s>>vi+l&1}for(var vi=0;vi<=24;vi+=8)hi<<=1,hi|=a>>vi+l&1;for(var l=1;l<=3;l++){for(var vi=0;vi<=24;vi+=8)u<<=1,u|=a>>vi+l&1;for(var vi=0;vi<=24;vi+=8)u<<=1,u|=s>>vi+l&1}for(var vi=0;vi<=24;vi+=8)u<<=1,u|=s>>vi+l&1;h[v+0]=hi>>>0,h[v+1]=u>>>0},utils$3.r28shl=function(s,a){return s<<a&268435455|s>>>28-a};var r=[14,11,17,4,27,23,25,0,13,22,7,18,5,9,16,24,2,20,12,21,1,8,15,26,15,4,25,19,9,1,26,16,5,11,23,8,12,7,17,0,22,3,10,14,6,20,27,24];utils$3.pc2=function(s,a,h,v){for(var hi=0,u=0,l=r.length>>>1,vi=0;vi<l;vi++)hi<<=1,hi|=s>>>r[vi]&1;for(var vi=l;vi<r.length;vi++)u<<=1,u|=a>>>r[vi]&1;h[v+0]=hi>>>0,h[v+1]=u>>>0},utils$3.expand=function(s,a,h){var v=0,hi=0;v=(s&1)<<5|s>>>27;for(var u=23;u>=15;u-=4)v<<=6,v|=s>>>u&63;for(var u=11;u>=3;u-=4)hi|=s>>>u&63,hi<<=6;hi|=(s&31)<<1|s>>>31,a[h+0]=v>>>0,a[h+1]=hi>>>0};var t=[14,0,4,15,13,7,1,4,2,14,15,2,11,13,8,1,3,10,10,6,6,12,12,11,5,9,9,5,0,3,7,8,4,15,1,12,14,8,8,2,13,4,6,9,2,1,11,7,15,5,12,11,9,3,7,14,3,10,10,0,5,6,0,13,15,3,1,13,8,4,14,7,6,15,11,2,3,8,4,14,9,12,7,0,2,1,13,10,12,6,0,9,5,11,10,5,0,13,14,8,7,10,11,1,10,3,4,15,13,4,1,2,5,11,8,6,12,7,6,12,9,0,3,5,2,14,15,9,10,13,0,7,9,0,14,9,6,3,3,4,15,6,5,10,1,2,13,8,12,5,7,14,11,12,4,11,2,15,8,1,13,1,6,10,4,13,9,0,8,6,15,9,3,8,0,7,11,4,1,15,2,14,12,3,5,11,10,5,14,2,7,12,7,13,13,8,14,11,3,5,0,6,6,15,9,0,10,3,1,4,2,7,8,2,5,12,11,1,12,10,4,14,15,9,10,3,6,15,9,0,0,6,12,10,11,1,7,13,13,8,15,9,1,4,3,5,14,11,5,12,2,7,8,2,4,14,2,14,12,11,4,2,1,12,7,4,10,7,11,13,6,1,8,5,5,0,3,15,15,10,13,3,0,9,14,8,9,6,4,11,2,8,1,12,11,7,10,1,13,14,7,2,8,13,15,6,9,15,12,0,5,9,6,10,3,4,0,5,14,3,12,10,1,15,10,4,15,2,9,7,2,12,6,9,8,5,0,6,13,1,3,13,4,14,14,0,7,11,5,3,11,8,9,4,14,3,15,2,5,12,2,9,8,5,12,15,3,10,7,11,0,14,4,1,10,7,1,6,13,0,11,8,6,13,4,13,11,0,2,11,14,7,15,4,0,9,8,1,13,10,3,14,12,3,9,5,7,12,5,2,10,15,6,8,1,6,1,6,4,11,11,13,13,8,12,1,3,4,7,10,14,7,10,9,15,5,6,0,8,15,0,14,5,2,9,3,2,12,13,1,2,15,8,13,4,8,6,10,15,3,11,7,1,4,10,12,9,5,3,6,14,11,5,0,0,14,12,9,7,2,7,2,11,1,4,14,1,7,9,4,12,10,14,8,2,13,0,15,6,12,10,9,13,0,15,3,3,5,5,6,8,11];utils$3.substitute=function(s,a){for(var h=0,v=0;v<4;v++){var hi=s>>>18-v*6&63,u=t[v*64+hi];h<<=4,h|=u}for(var v=0;v<4;v++){var hi=a>>>18-v*6&63,u=t[256+v*64+hi];h<<=4,h|=u}return h>>>0};var i=[16,25,12,11,3,20,4,15,31,17,9,6,27,14,1,22,30,24,8,18,0,5,29,23,13,19,2,26,10,21,28,7];return utils$3.permute=function(s){for(var a=0,h=0;h<i.length;h++)a<<=1,a|=s>>>i[h]&1;return a>>>0},utils$3.padSplit=function(s,a,h){for(var v=s.toString(2);v.length<a;)v="0"+v;for(var hi=[],u=0;u<a;u+=h)hi.push(v.slice(u,u+h));return hi.join(" ")},utils$3}var minimalisticAssert,hasRequiredMinimalisticAssert;function requireMinimalisticAssert(){if(hasRequiredMinimalisticAssert)return minimalisticAssert;hasRequiredMinimalisticAssert=1,minimalisticAssert=r;function r(t,i){if(!t)throw new Error(i||"Assertion failed")}return r.equal=function(i,n,s){if(i!=n)throw new Error(s||"Assertion failed: "+i+" != "+n)},minimalisticAssert}var cipher,hasRequiredCipher;function requireCipher(){if(hasRequiredCipher)return cipher;hasRequiredCipher=1;var r=requireMinimalisticAssert();function t(i){this.options=i,this.type=this.options.type,this.blockSize=8,this._init(),this.buffer=new Array(this.blockSize),this.bufferOff=0,this.padding=i.padding!==!1}return cipher=t,t.prototype._init=function(){},t.prototype.update=function(n){return n.length===0?[]:this.type==="decrypt"?this._updateDecrypt(n):this._updateEncrypt(n)},t.prototype._buffer=function(n,s){for(var a=Math.min(this.buffer.length-this.bufferOff,n.length-s),h=0;h<a;h++)this.buffer[this.bufferOff+h]=n[s+h];return this.bufferOff+=a,a},t.prototype._flushBuffer=function(n,s){return this._update(this.buffer,0,n,s),this.bufferOff=0,this.blockSize},t.prototype._updateEncrypt=function(n){var s=0,a=0,h=(this.bufferOff+n.length)/this.blockSize|0,v=new Array(h*this.blockSize);this.bufferOff!==0&&(s+=this._buffer(n,s),this.bufferOff===this.buffer.length&&(a+=this._flushBuffer(v,a)));for(var hi=n.length-(n.length-s)%this.blockSize;s<hi;s+=this.blockSize)this._update(n,s,v,a),a+=this.blockSize;for(;s<n.length;s++,this.bufferOff++)this.buffer[this.bufferOff]=n[s];return v},t.prototype._updateDecrypt=function(n){for(var s=0,a=0,h=Math.ceil((this.bufferOff+n.length)/this.blockSize)-1,v=new Array(h*this.blockSize);h>0;h--)s+=this._buffer(n,s),a+=this._flushBuffer(v,a);return s+=this._buffer(n,s),v},t.prototype.final=function(n){var s;n&&(s=this.update(n));var a;return this.type==="encrypt"?a=this._finalEncrypt():a=this._finalDecrypt(),s?s.concat(a):a},t.prototype._pad=function(n,s){if(s===0)return!1;for(;s<n.length;)n[s++]=0;return!0},t.prototype._finalEncrypt=function(){if(!this._pad(this.buffer,this.bufferOff))return[];var n=new Array(this.blockSize);return this._update(this.buffer,0,n,0),n},t.prototype._unpad=function(n){return n},t.prototype._finalDecrypt=function(){r.equal(this.bufferOff,this.blockSize,"Not enough data to decrypt");var n=new Array(this.blockSize);return this._flushBuffer(n,0),this._unpad(n)},cipher}var des,hasRequiredDes$1;function requireDes$1(){if(hasRequiredDes$1)return des;hasRequiredDes$1=1;var r=requireMinimalisticAssert(),t=requireInherits_browser(),i=requireUtils$3(),n=requireCipher();function s(){this.tmp=new Array(2),this.keys=null}function a(v){n.call(this,v);var hi=new s;this._desState=hi,this.deriveKeys(hi,v.key)}t(a,n),des=a,a.create=function(hi){return new a(hi)};var h=[1,1,2,2,2,2,2,2,1,2,2,2,2,2,2,1];return a.prototype.deriveKeys=function(hi,u){hi.keys=new Array(32),r.equal(u.length,this.blockSize,"Invalid key length");var l=i.readUInt32BE(u,0),vi=i.readUInt32BE(u,4);i.pc1(l,vi,hi.tmp,0),l=hi.tmp[0],vi=hi.tmp[1];for(var D=0;D<hi.keys.length;D+=2){var mi=h[D>>>1];l=i.r28shl(l,mi),vi=i.r28shl(vi,mi),i.pc2(l,vi,hi.keys,D)}},a.prototype._update=function(hi,u,l,vi){var D=this._desState,mi=i.readUInt32BE(hi,u),gi=i.readUInt32BE(hi,u+4);i.ip(mi,gi,D.tmp,0),mi=D.tmp[0],gi=D.tmp[1],this.type==="encrypt"?this._encrypt(D,mi,gi,D.tmp,0):this._decrypt(D,mi,gi,D.tmp,0),mi=D.tmp[0],gi=D.tmp[1],i.writeUInt32BE(l,mi,vi),i.writeUInt32BE(l,gi,vi+4)},a.prototype._pad=function(hi,u){if(this.padding===!1)return!1;for(var l=hi.length-u,vi=u;vi<hi.length;vi++)hi[vi]=l;return!0},a.prototype._unpad=function(hi){if(this.padding===!1)return hi;for(var u=hi[hi.length-1],l=hi.length-u;l<hi.length;l++)r.equal(hi[l],u);return hi.slice(0,hi.length-u)},a.prototype._encrypt=function(hi,u,l,vi,D){for(var mi=u,gi=l,bi=0;bi<hi.keys.length;bi+=2){var Ri=hi.keys[bi],Ti=hi.keys[bi+1];i.expand(gi,hi.tmp,0),Ri^=hi.tmp[0],Ti^=hi.tmp[1];var Ii=i.substitute(Ri,Ti),qi=i.permute(Ii),Oi=gi;gi=(mi^qi)>>>0,mi=Oi}i.rip(gi,mi,vi,D)},a.prototype._decrypt=function(hi,u,l,vi,D){for(var mi=l,gi=u,bi=hi.keys.length-2;bi>=0;bi-=2){var Ri=hi.keys[bi],Ti=hi.keys[bi+1];i.expand(mi,hi.tmp,0),Ri^=hi.tmp[0],Ti^=hi.tmp[1];var Ii=i.substitute(Ri,Ti),qi=i.permute(Ii),Oi=mi;mi=(gi^qi)>>>0,gi=Oi}i.rip(mi,gi,vi,D)},des}var cbc$1={},hasRequiredCbc$1;function requireCbc$1(){if(hasRequiredCbc$1)return cbc$1;hasRequiredCbc$1=1;var r=requireMinimalisticAssert(),t=requireInherits_browser(),i={};function n(a){r.equal(a.length,8,"Invalid IV length"),this.iv=new Array(8);for(var h=0;h<this.iv.length;h++)this.iv[h]=a[h]}function s(a){function h(l){a.call(this,l),this._cbcInit()}t(h,a);for(var v=Object.keys(i),hi=0;hi<v.length;hi++){var u=v[hi];h.prototype[u]=i[u]}return h.create=function(vi){return new h(vi)},h}return cbc$1.instantiate=s,i._cbcInit=function(){var h=new n(this.options.iv);this._cbcState=h},i._update=function(h,v,hi,u){var l=this._cbcState,vi=this.constructor.super_.prototype,D=l.iv;if(this.type==="encrypt"){for(var mi=0;mi<this.blockSize;mi++)D[mi]^=h[v+mi];vi._update.call(this,D,0,hi,u);for(var mi=0;mi<this.blockSize;mi++)D[mi]=hi[u+mi]}else{vi._update.call(this,h,v,hi,u);for(var mi=0;mi<this.blockSize;mi++)hi[u+mi]^=D[mi];for(var mi=0;mi<this.blockSize;mi++)D[mi]=h[v+mi]}},cbc$1}var ede,hasRequiredEde;function requireEde(){if(hasRequiredEde)return ede;hasRequiredEde=1;var r=requireMinimalisticAssert(),t=requireInherits_browser(),i=requireCipher(),n=requireDes$1();function s(h,v){r.equal(v.length,24,"Invalid key length");var hi=v.slice(0,8),u=v.slice(8,16),l=v.slice(16,24);h==="encrypt"?this.ciphers=[n.create({type:"encrypt",key:hi}),n.create({type:"decrypt",key:u}),n.create({type:"encrypt",key:l})]:this.ciphers=[n.create({type:"decrypt",key:l}),n.create({type:"encrypt",key:u}),n.create({type:"decrypt",key:hi})]}function a(h){i.call(this,h);var v=new s(this.type,this.options.key);this._edeState=v}return t(a,i),ede=a,a.create=function(v){return new a(v)},a.prototype._update=function(v,hi,u,l){var vi=this._edeState;vi.ciphers[0]._update(v,hi,u,l),vi.ciphers[1]._update(u,l,u,l),vi.ciphers[2]._update(u,l,u,l)},a.prototype._pad=n.prototype._pad,a.prototype._unpad=n.prototype._unpad,ede}var hasRequiredDes;function requireDes(){return hasRequiredDes||(hasRequiredDes=1,des$1.utils=requireUtils$3(),des$1.Cipher=requireCipher(),des$1.DES=requireDes$1(),des$1.CBC=requireCbc$1(),des$1.EDE=requireEde()),des$1}var browserifyDes,hasRequiredBrowserifyDes;function requireBrowserifyDes(){if(hasRequiredBrowserifyDes)return browserifyDes;hasRequiredBrowserifyDes=1;var r=requireCipherBase(),t=requireDes(),i=requireInherits_browser(),n=requireSafeBuffer$1().Buffer,s={"des-ede3-cbc":t.CBC.instantiate(t.EDE),"des-ede3":t.EDE,"des-ede-cbc":t.CBC.instantiate(t.EDE),"des-ede":t.EDE,"des-cbc":t.CBC.instantiate(t.DES),"des-ecb":t.DES};s.des=s["des-cbc"],s.des3=s["des-ede3-cbc"],browserifyDes=a,i(a,r);function a(h){r.call(this);var v=h.mode.toLowerCase(),hi=s[v],u;h.decrypt?u="decrypt":u="encrypt";var l=h.key;n.isBuffer(l)||(l=n.from(l)),(v==="des-ede"||v==="des-ede-cbc")&&(l=n.concat([l,l.slice(0,8)]));var vi=h.iv;n.isBuffer(vi)||(vi=n.from(vi)),this._des=hi.create({key:l,iv:vi,type:u})}return a.prototype._update=function(h){return n.from(this._des.update(h))},a.prototype._final=function(){return n.from(this._des.final())},browserifyDes}var browser$6={},encrypter={},ecb={},hasRequiredEcb;function requireEcb(){return hasRequiredEcb||(hasRequiredEcb=1,ecb.encrypt=function(r,t){return r._cipher.encryptBlock(t)},ecb.decrypt=function(r,t){return r._cipher.decryptBlock(t)}),ecb}var cbc={},bufferXor,hasRequiredBufferXor;function requireBufferXor(){return hasRequiredBufferXor||(hasRequiredBufferXor=1,bufferXor=function(t,i){for(var n=Math.min(t.length,i.length),s=new Buffer(n),a=0;a<n;++a)s[a]=t[a]^i[a];return s}),bufferXor}var hasRequiredCbc;function requireCbc(){if(hasRequiredCbc)return cbc;hasRequiredCbc=1;var r=requireBufferXor();return cbc.encrypt=function(t,i){var n=r(i,t._prev);return t._prev=t._cipher.encryptBlock(n),t._prev},cbc.decrypt=function(t,i){var n=t._prev;t._prev=i;var s=t._cipher.decryptBlock(i);return r(s,n)},cbc}var cfb={},hasRequiredCfb;function requireCfb(){if(hasRequiredCfb)return cfb;hasRequiredCfb=1;var r=requireSafeBuffer$1().Buffer,t=requireBufferXor();function i(n,s,a){var h=s.length,v=t(s,n._cache);return n._cache=n._cache.slice(h),n._prev=r.concat([n._prev,a?s:v]),v}return cfb.encrypt=function(n,s,a){for(var h=r.allocUnsafe(0),v;s.length;)if(n._cache.length===0&&(n._cache=n._cipher.encryptBlock(n._prev),n._prev=r.allocUnsafe(0)),n._cache.length<=s.length)v=n._cache.length,h=r.concat([h,i(n,s.slice(0,v),a)]),s=s.slice(v);else{h=r.concat([h,i(n,s,a)]);break}return h},cfb}var cfb8={},hasRequiredCfb8;function requireCfb8(){if(hasRequiredCfb8)return cfb8;hasRequiredCfb8=1;var r=requireSafeBuffer$1().Buffer;function t(i,n,s){var a=i._cipher.encryptBlock(i._prev),h=a[0]^n;return i._prev=r.concat([i._prev.slice(1),r.from([s?n:h])]),h}return cfb8.encrypt=function(i,n,s){for(var a=n.length,h=r.allocUnsafe(a),v=-1;++v<a;)h[v]=t(i,n[v],s);return h},cfb8}var cfb1={},hasRequiredCfb1;function requireCfb1(){if(hasRequiredCfb1)return cfb1;hasRequiredCfb1=1;var r=requireSafeBuffer$1().Buffer;function t(n,s,a){for(var h,v=-1,hi=8,u=0,l,vi;++v<hi;)h=n._cipher.encryptBlock(n._prev),l=s&1<<7-v?128:0,vi=h[0]^l,u+=(vi&128)>>v%8,n._prev=i(n._prev,a?l:vi);return u}function i(n,s){var a=n.length,h=-1,v=r.allocUnsafe(n.length);for(n=r.concat([n,r.from([s])]);++h<a;)v[h]=n[h]<<1|n[h+1]>>7;return v}return cfb1.encrypt=function(n,s,a){for(var h=s.length,v=r.allocUnsafe(h),hi=-1;++hi<h;)v[hi]=t(n,s[hi],a);return v},cfb1}var ofb={},hasRequiredOfb;function requireOfb(){if(hasRequiredOfb)return ofb;hasRequiredOfb=1;var r=requireBufferXor();function t(i){return i._prev=i._cipher.encryptBlock(i._prev),i._prev}return ofb.encrypt=function(i,n){for(;i._cache.length<n.length;)i._cache=Buffer.concat([i._cache,t(i)]);var s=i._cache.slice(0,n.length);return i._cache=i._cache.slice(n.length),r(n,s)},ofb}var ctr={},incr32_1,hasRequiredIncr32;function requireIncr32(){if(hasRequiredIncr32)return incr32_1;hasRequiredIncr32=1;function r(t){for(var i=t.length,n;i--;)if(n=t.readUInt8(i),n===255)t.writeUInt8(0,i);else{n++,t.writeUInt8(n,i);break}}return incr32_1=r,incr32_1}var hasRequiredCtr;function requireCtr(){if(hasRequiredCtr)return ctr;hasRequiredCtr=1;var r=requireBufferXor(),t=requireSafeBuffer$1().Buffer,i=requireIncr32();function n(a){var h=a._cipher.encryptBlockRaw(a._prev);return i(a._prev),h}var s=16;return ctr.encrypt=function(a,h){var v=Math.ceil(h.length/s),hi=a._cache.length;a._cache=t.concat([a._cache,t.allocUnsafe(v*s)]);for(var u=0;u<v;u++){var l=n(a),vi=hi+u*s;a._cache.writeUInt32BE(l[0],vi+0),a._cache.writeUInt32BE(l[1],vi+4),a._cache.writeUInt32BE(l[2],vi+8),a._cache.writeUInt32BE(l[3],vi+12)}var D=a._cache.slice(0,h.length);return a._cache=a._cache.slice(h.length),r(h,D)},ctr}const aes128={cipher:"AES",key:128,iv:16,mode:"CBC",type:"block"},aes192={cipher:"AES",key:192,iv:16,mode:"CBC",type:"block"},aes256={cipher:"AES",key:256,iv:16,mode:"CBC",type:"block"};var require$$2={"aes-128-ecb":{cipher:"AES",key:128,iv:0,mode:"ECB",type:"block"},"aes-192-ecb":{cipher:"AES",key:192,iv:0,mode:"ECB",type:"block"},"aes-256-ecb":{cipher:"AES",key:256,iv:0,mode:"ECB",type:"block"},"aes-128-cbc":{cipher:"AES",key:128,iv:16,mode:"CBC",type:"block"},"aes-192-cbc":{cipher:"AES",key:192,iv:16,mode:"CBC",type:"block"},"aes-256-cbc":{cipher:"AES",key:256,iv:16,mode:"CBC",type:"block"},aes128,aes192,aes256,"aes-128-cfb":{cipher:"AES",key:128,iv:16,mode:"CFB",type:"stream"},"aes-192-cfb":{cipher:"AES",key:192,iv:16,mode:"CFB",type:"stream"},"aes-256-cfb":{cipher:"AES",key:256,iv:16,mode:"CFB",type:"stream"},"aes-128-cfb8":{cipher:"AES",key:128,iv:16,mode:"CFB8",type:"stream"},"aes-192-cfb8":{cipher:"AES",key:192,iv:16,mode:"CFB8",type:"stream"},"aes-256-cfb8":{cipher:"AES",key:256,iv:16,mode:"CFB8",type:"stream"},"aes-128-cfb1":{cipher:"AES",key:128,iv:16,mode:"CFB1",type:"stream"},"aes-192-cfb1":{cipher:"AES",key:192,iv:16,mode:"CFB1",type:"stream"},"aes-256-cfb1":{cipher:"AES",key:256,iv:16,mode:"CFB1",type:"stream"},"aes-128-ofb":{cipher:"AES",key:128,iv:16,mode:"OFB",type:"stream"},"aes-192-ofb":{cipher:"AES",key:192,iv:16,mode:"OFB",type:"stream"},"aes-256-ofb":{cipher:"AES",key:256,iv:16,mode:"OFB",type:"stream"},"aes-128-ctr":{cipher:"AES",key:128,iv:16,mode:"CTR",type:"stream"},"aes-192-ctr":{cipher:"AES",key:192,iv:16,mode:"CTR",type:"stream"},"aes-256-ctr":{cipher:"AES",key:256,iv:16,mode:"CTR",type:"stream"},"aes-128-gcm":{cipher:"AES",key:128,iv:12,mode:"GCM",type:"auth"},"aes-192-gcm":{cipher:"AES",key:192,iv:12,mode:"GCM",type:"auth"},"aes-256-gcm":{cipher:"AES",key:256,iv:12,mode:"GCM",type:"auth"}},modes_1,hasRequiredModes$1;function requireModes$1(){if(hasRequiredModes$1)return modes_1;hasRequiredModes$1=1;var r={ECB:requireEcb(),CBC:requireCbc(),CFB:requireCfb(),CFB8:requireCfb8(),CFB1:requireCfb1(),OFB:requireOfb(),CTR:requireCtr(),GCM:requireCtr()},t=require$$2;for(var i in t)t[i].module=r[t[i].mode];return modes_1=t,modes_1}var aes$2={},hasRequiredAes$1;function requireAes$1(){if(hasRequiredAes$1)return aes$2;hasRequiredAes$1=1;var r=requireSafeBuffer$1().Buffer;function t(v){r.isBuffer(v)||(v=r.from(v));for(var hi=v.length/4|0,u=new Array(hi),l=0;l<hi;l++)u[l]=v.readUInt32BE(l*4);return u}function i(v){for(var hi=0;hi<v.length;v++)v[hi]=0}function n(v,hi,u,l,vi){for(var D=u[0],mi=u[1],gi=u[2],bi=u[3],Ri=v[0]^hi[0],Ti=v[1]^hi[1],Ii=v[2]^hi[2],qi=v[3]^hi[3],Oi,ki,Li,ji,Hi=4,Ui=1;Ui<vi;Ui++)Oi=D[Ri>>>24]^mi[Ti>>>16&255]^gi[Ii>>>8&255]^bi[qi&255]^hi[Hi++],ki=D[Ti>>>24]^mi[Ii>>>16&255]^gi[qi>>>8&255]^bi[Ri&255]^hi[Hi++],Li=D[Ii>>>24]^mi[qi>>>16&255]^gi[Ri>>>8&255]^bi[Ti&255]^hi[Hi++],ji=D[qi>>>24]^mi[Ri>>>16&255]^gi[Ti>>>8&255]^bi[Ii&255]^hi[Hi++],Ri=Oi,Ti=ki,Ii=Li,qi=ji;return Oi=(l[Ri>>>24]<<24|l[Ti>>>16&255]<<16|l[Ii>>>8&255]<<8|l[qi&255])^hi[Hi++],ki=(l[Ti>>>24]<<24|l[Ii>>>16&255]<<16|l[qi>>>8&255]<<8|l[Ri&255])^hi[Hi++],Li=(l[Ii>>>24]<<24|l[qi>>>16&255]<<16|l[Ri>>>8&255]<<8|l[Ti&255])^hi[Hi++],ji=(l[qi>>>24]<<24|l[Ri>>>16&255]<<16|l[Ti>>>8&255]<<8|l[Ii&255])^hi[Hi++],Oi=Oi>>>0,ki=ki>>>0,Li=Li>>>0,ji=ji>>>0,[Oi,ki,Li,ji]}var s=[0,1,2,4,8,16,32,64,128,27,54],a=function(){for(var v=new Array(256),hi=0;hi<256;hi++)hi<128?v[hi]=hi<<1:v[hi]=hi<<1^283;for(var u=[],l=[],vi=[[],[],[],[]],D=[[],[],[],[]],mi=0,gi=0,bi=0;bi<256;++bi){var Ri=gi^gi<<1^gi<<2^gi<<3^gi<<4;Ri=Ri>>>8^Ri&255^99,u[mi]=Ri,l[Ri]=mi;var Ti=v[mi],Ii=v[Ti],qi=v[Ii],Oi=v[Ri]*257^Ri*16843008;vi[0][mi]=Oi<<24|Oi>>>8,vi[1][mi]=Oi<<16|Oi>>>16,vi[2][mi]=Oi<<8|Oi>>>24,vi[3][mi]=Oi,Oi=qi*16843009^Ii*65537^Ti*257^mi*16843008,D[0][Ri]=Oi<<24|Oi>>>8,D[1][Ri]=Oi<<16|Oi>>>16,D[2][Ri]=Oi<<8|Oi>>>24,D[3][Ri]=Oi,mi===0?mi=gi=1:(mi=Ti^v[v[v[qi^Ti]]],gi^=v[v[gi]])}return{SBOX:u,INV_SBOX:l,SUB_MIX:vi,INV_SUB_MIX:D}}();function h(v){this._key=t(v),this._reset()}return h.blockSize=16,h.keySize=256/8,h.prototype.blockSize=h.blockSize,h.prototype.keySize=h.keySize,h.prototype._reset=function(){for(var v=this._key,hi=v.length,u=hi+6,l=(u+1)*4,vi=[],D=0;D<hi;D++)vi[D]=v[D];for(D=hi;D<l;D++){var mi=vi[D-1];D%hi===0?(mi=mi<<8|mi>>>24,mi=a.SBOX[mi>>>24]<<24|a.SBOX[mi>>>16&255]<<16|a.SBOX[mi>>>8&255]<<8|a.SBOX[mi&255],mi^=s[D/hi|0]<<24):hi>6&&D%hi===4&&(mi=a.SBOX[mi>>>24]<<24|a.SBOX[mi>>>16&255]<<16|a.SBOX[mi>>>8&255]<<8|a.SBOX[mi&255]),vi[D]=vi[D-hi]^mi}for(var gi=[],bi=0;bi<l;bi++){var Ri=l-bi,Ti=vi[Ri-(bi%4?0:4)];bi<4||Ri<=4?gi[bi]=Ti:gi[bi]=a.INV_SUB_MIX[0][a.SBOX[Ti>>>24]]^a.INV_SUB_MIX[1][a.SBOX[Ti>>>16&255]]^a.INV_SUB_MIX[2][a.SBOX[Ti>>>8&255]]^a.INV_SUB_MIX[3][a.SBOX[Ti&255]]}this._nRounds=u,this._keySchedule=vi,this._invKeySchedule=gi},h.prototype.encryptBlockRaw=function(v){return v=t(v),n(v,this._keySchedule,a.SUB_MIX,a.SBOX,this._nRounds)},h.prototype.encryptBlock=function(v){var hi=this.encryptBlockRaw(v),u=r.allocUnsafe(16);return u.writeUInt32BE(hi[0],0),u.writeUInt32BE(hi[1],4),u.writeUInt32BE(hi[2],8),u.writeUInt32BE(hi[3],12),u},h.prototype.decryptBlock=function(v){v=t(v);var hi=v[1];v[1]=v[3],v[3]=hi;var u=n(v,this._invKeySchedule,a.INV_SUB_MIX,a.INV_SBOX,this._nRounds),l=r.allocUnsafe(16);return l.writeUInt32BE(u[0],0),l.writeUInt32BE(u[3],4),l.writeUInt32BE(u[2],8),l.writeUInt32BE(u[1],12),l},h.prototype.scrub=function(){i(this._keySchedule),i(this._invKeySchedule),i(this._key)},aes$2.AES=h,aes$2}var ghash,hasRequiredGhash;function requireGhash(){if(hasRequiredGhash)return ghash;hasRequiredGhash=1;var r=requireSafeBuffer$1().Buffer,t=r.alloc(16,0);function i(a){return[a.readUInt32BE(0),a.readUInt32BE(4),a.readUInt32BE(8),a.readUInt32BE(12)]}function n(a){var h=r.allocUnsafe(16);return h.writeUInt32BE(a[0]>>>0,0),h.writeUInt32BE(a[1]>>>0,4),h.writeUInt32BE(a[2]>>>0,8),h.writeUInt32BE(a[3]>>>0,12),h}function s(a){this.h=a,this.state=r.alloc(16,0),this.cache=r.allocUnsafe(0)}return s.prototype.ghash=function(a){for(var h=-1;++h<a.length;)this.state[h]^=a[h];this._multiply()},s.prototype._multiply=function(){for(var a=i(this.h),h=[0,0,0,0],v,hi,u,l=-1;++l<128;){for(hi=(this.state[~~(l/8)]&1<<7-l%8)!==0,hi&&(h[0]^=a[0],h[1]^=a[1],h[2]^=a[2],h[3]^=a[3]),u=(a[3]&1)!==0,v=3;v>0;v--)a[v]=a[v]>>>1|(a[v-1]&1)<<31;a[0]=a[0]>>>1,u&&(a[0]=a[0]^225<<24)}this.state=n(h)},s.prototype.update=function(a){this.cache=r.concat([this.cache,a]);for(var h;this.cache.length>=16;)h=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(h)},s.prototype.final=function(a,h){return this.cache.length&&this.ghash(r.concat([this.cache,t],16)),this.ghash(n([0,a,0,h])),this.state},ghash=s,ghash}var authCipher,hasRequiredAuthCipher;function requireAuthCipher(){if(hasRequiredAuthCipher)return authCipher;hasRequiredAuthCipher=1;var r=requireAes$1(),t=requireSafeBuffer$1().Buffer,i=requireCipherBase(),n=requireInherits_browser(),s=requireGhash(),a=requireBufferXor(),h=requireIncr32();function v(l,vi){var D=0;l.length!==vi.length&&D++;for(var mi=Math.min(l.length,vi.length),gi=0;gi<mi;++gi)D+=l[gi]^vi[gi];return D}function hi(l,vi,D){if(vi.length===12)return l._finID=t.concat([vi,t.from([0,0,0,1])]),t.concat([vi,t.from([0,0,0,2])]);var mi=new s(D),gi=vi.length,bi=gi%16;mi.update(vi),bi&&(bi=16-bi,mi.update(t.alloc(bi,0))),mi.update(t.alloc(8,0));var Ri=gi*8,Ti=t.alloc(8);Ti.writeUIntBE(Ri,0,8),mi.update(Ti),l._finID=mi.state;var Ii=t.from(l._finID);return h(Ii),Ii}function u(l,vi,D,mi){i.call(this);var gi=t.alloc(4,0);this._cipher=new r.AES(vi);var bi=this._cipher.encryptBlock(gi);this._ghash=new s(bi),D=hi(this,D,bi),this._prev=t.from(D),this._cache=t.allocUnsafe(0),this._secCache=t.allocUnsafe(0),this._decrypt=mi,this._alen=0,this._len=0,this._mode=l,this._authTag=null,this._called=!1}return n(u,i),u.prototype._update=function(l){if(!this._called&&this._alen){var vi=16-this._alen%16;vi<16&&(vi=t.alloc(vi,0),this._ghash.update(vi))}this._called=!0;var D=this._mode.encrypt(this,l);return this._decrypt?this._ghash.update(l):this._ghash.update(D),this._len+=l.length,D},u.prototype._final=function(){if(this._decrypt&&!this._authTag)throw new Error("Unsupported state or unable to authenticate data");var l=a(this._ghash.final(this._alen*8,this._len*8),this._cipher.encryptBlock(this._finID));if(this._decrypt&&v(l,this._authTag))throw new Error("Unsupported state or unable to authenticate data");this._authTag=l,this._cipher.scrub()},u.prototype.getAuthTag=function(){if(this._decrypt||!t.isBuffer(this._authTag))throw new Error("Attempting to get auth tag in unsupported state");return this._authTag},u.prototype.setAuthTag=function(vi){if(!this._decrypt)throw new Error("Attempting to set auth tag in unsupported state");this._authTag=vi},u.prototype.setAAD=function(vi){if(this._called)throw new Error("Attempting to set AAD in unsupported state");this._ghash.update(vi),this._alen+=vi.length},authCipher=u,authCipher}var streamCipher,hasRequiredStreamCipher;function requireStreamCipher(){if(hasRequiredStreamCipher)return streamCipher;hasRequiredStreamCipher=1;var r=requireAes$1(),t=requireSafeBuffer$1().Buffer,i=requireCipherBase(),n=requireInherits_browser();function s(a,h,v,hi){i.call(this),this._cipher=new r.AES(h),this._prev=t.from(v),this._cache=t.allocUnsafe(0),this._secCache=t.allocUnsafe(0),this._decrypt=hi,this._mode=a}return n(s,i),s.prototype._update=function(a){return this._mode.encrypt(this,a,this._decrypt)},s.prototype._final=function(){this._cipher.scrub()},streamCipher=s,streamCipher}var evp_bytestokey,hasRequiredEvp_bytestokey;function requireEvp_bytestokey(){if(hasRequiredEvp_bytestokey)return evp_bytestokey;hasRequiredEvp_bytestokey=1;var r=requireSafeBuffer$1().Buffer,t=requireMd5_js();function i(n,s,a,h){if(r.isBuffer(n)||(n=r.from(n,"binary")),s&&(r.isBuffer(s)||(s=r.from(s,"binary")),s.length!==8))throw new RangeError("salt should be Buffer with 8 byte length");for(var v=a/8,hi=r.alloc(v),u=r.alloc(h||0),l=r.alloc(0);v>0||h>0;){var vi=new t;vi.update(l),vi.update(n),s&&vi.update(s),l=vi.digest();var D=0;if(v>0){var mi=hi.length-v;D=Math.min(v,l.length),l.copy(hi,mi,0,D),v-=D}if(D<l.length&&h>0){var gi=u.length-h,bi=Math.min(h,l.length-D);l.copy(u,gi,D,D+bi),h-=bi}}return l.fill(0),{key:hi,iv:u}}return evp_bytestokey=i,evp_bytestokey}var hasRequiredEncrypter;function requireEncrypter(){if(hasRequiredEncrypter)return encrypter;hasRequiredEncrypter=1;var r=requireModes$1(),t=requireAuthCipher(),i=requireSafeBuffer$1().Buffer,n=requireStreamCipher(),s=requireCipherBase(),a=requireAes$1(),h=requireEvp_bytestokey(),v=requireInherits_browser();function hi(mi,gi,bi){s.call(this),this._cache=new l,this._cipher=new a.AES(gi),this._prev=i.from(bi),this._mode=mi,this._autopadding=!0}v(hi,s),hi.prototype._update=function(mi){this._cache.add(mi);for(var gi,bi,Ri=[];gi=this._cache.get();)bi=this._mode.encrypt(this,gi),Ri.push(bi);return i.concat(Ri)};var u=i.alloc(16,16);hi.prototype._final=function(){var mi=this._cache.flush();if(this._autopadding)return mi=this._mode.encrypt(this,mi),this._cipher.scrub(),mi;if(!mi.equals(u))throw this._cipher.scrub(),new Error("data not multiple of block length")},hi.prototype.setAutoPadding=function(mi){return this._autopadding=!!mi,this};function l(){this.cache=i.allocUnsafe(0)}l.prototype.add=function(mi){this.cache=i.concat([this.cache,mi])},l.prototype.get=function(){if(this.cache.length>15){var mi=this.cache.slice(0,16);return this.cache=this.cache.slice(16),mi}return null},l.prototype.flush=function(){for(var mi=16-this.cache.length,gi=i.allocUnsafe(mi),bi=-1;++bi<mi;)gi.writeUInt8(mi,bi);return i.concat([this.cache,gi])};function vi(mi,gi,bi){var Ri=r[mi.toLowerCase()];if(!Ri)throw new TypeError("invalid suite type");if(typeof gi=="string"&&(gi=i.from(gi)),gi.length!==Ri.key/8)throw new TypeError("invalid key length "+gi.length);if(typeof bi=="string"&&(bi=i.from(bi)),Ri.mode!=="GCM"&&bi.length!==Ri.iv)throw new TypeError("invalid iv length "+bi.length);return Ri.type==="stream"?new n(Ri.module,gi,bi):Ri.type==="auth"?new t(Ri.module,gi,bi):new hi(Ri.module,gi,bi)}function D(mi,gi){var bi=r[mi.toLowerCase()];if(!bi)throw new TypeError("invalid suite type");var Ri=h(gi,!1,bi.key,bi.iv);return vi(mi,Ri.key,Ri.iv)}return encrypter.createCipheriv=vi,encrypter.createCipher=D,encrypter}var decrypter={},hasRequiredDecrypter;function requireDecrypter(){if(hasRequiredDecrypter)return decrypter;hasRequiredDecrypter=1;var r=requireAuthCipher(),t=requireSafeBuffer$1().Buffer,i=requireModes$1(),n=requireStreamCipher(),s=requireCipherBase(),a=requireAes$1(),h=requireEvp_bytestokey(),v=requireInherits_browser();function hi(mi,gi,bi){s.call(this),this._cache=new u,this._last=void 0,this._cipher=new a.AES(gi),this._prev=t.from(bi),this._mode=mi,this._autopadding=!0}v(hi,s),hi.prototype._update=function(mi){this._cache.add(mi);for(var gi,bi,Ri=[];gi=this._cache.get(this._autopadding);)bi=this._mode.decrypt(this,gi),Ri.push(bi);return t.concat(Ri)},hi.prototype._final=function(){var mi=this._cache.flush();if(this._autopadding)return l(this._mode.decrypt(this,mi));if(mi)throw new Error("data not multiple of block length")},hi.prototype.setAutoPadding=function(mi){return this._autopadding=!!mi,this};function u(){this.cache=t.allocUnsafe(0)}u.prototype.add=function(mi){this.cache=t.concat([this.cache,mi])},u.prototype.get=function(mi){var gi;if(mi){if(this.cache.length>16)return gi=this.cache.slice(0,16),this.cache=this.cache.slice(16),gi}else if(this.cache.length>=16)return gi=this.cache.slice(0,16),this.cache=this.cache.slice(16),gi;return null},u.prototype.flush=function(){if(this.cache.length)return this.cache};function l(mi){var gi=mi[15];if(gi<1||gi>16)throw new Error("unable to decrypt data");for(var bi=-1;++bi<gi;)if(mi[bi+(16-gi)]!==gi)throw new Error("unable to decrypt data");if(gi!==16)return mi.slice(0,16-gi)}function vi(mi,gi,bi){var Ri=i[mi.toLowerCase()];if(!Ri)throw new TypeError("invalid suite type");if(typeof bi=="string"&&(bi=t.from(bi)),Ri.mode!=="GCM"&&bi.length!==Ri.iv)throw new TypeError("invalid iv length "+bi.length);if(typeof gi=="string"&&(gi=t.from(gi)),gi.length!==Ri.key/8)throw new TypeError("invalid key length "+gi.length);return Ri.type==="stream"?new n(Ri.module,gi,bi,!0):Ri.type==="auth"?new r(Ri.module,gi,bi,!0):new hi(Ri.module,gi,bi)}function D(mi,gi){var bi=i[mi.toLowerCase()];if(!bi)throw new TypeError("invalid suite type");var Ri=h(gi,!1,bi.key,bi.iv);return vi(mi,Ri.key,Ri.iv)}return decrypter.createDecipher=D,decrypter.createDecipheriv=vi,decrypter}var hasRequiredBrowser$7;function requireBrowser$7(){if(hasRequiredBrowser$7)return browser$6;hasRequiredBrowser$7=1;var r=requireEncrypter(),t=requireDecrypter(),i=require$$2;function n(){return Object.keys(i)}return browser$6.createCipher=browser$6.Cipher=r.createCipher,browser$6.createCipheriv=browser$6.Cipheriv=r.createCipheriv,browser$6.createDecipher=browser$6.Decipher=t.createDecipher,browser$6.createDecipheriv=browser$6.Decipheriv=t.createDecipheriv,browser$6.listCiphers=browser$6.getCiphers=n,browser$6}var modes={},hasRequiredModes;function requireModes(){return hasRequiredModes||(hasRequiredModes=1,function(r){r["des-ecb"]={key:8,iv:0},r["des-cbc"]=r.des={key:8,iv:8},r["des-ede3-cbc"]=r.des3={key:24,iv:8},r["des-ede3"]={key:24,iv:0},r["des-ede-cbc"]={key:16,iv:8},r["des-ede"]={key:16,iv:0}}(modes)),modes}var hasRequiredBrowser$6;function requireBrowser$6(){if(hasRequiredBrowser$6)return browser$7;hasRequiredBrowser$6=1;var r=requireBrowserifyDes(),t=requireBrowser$7(),i=requireModes$1(),n=requireModes(),s=requireEvp_bytestokey();function a(l,vi){l=l.toLowerCase();var D,mi;if(i[l])D=i[l].key,mi=i[l].iv;else if(n[l])D=n[l].key*8,mi=n[l].iv;else throw new TypeError("invalid suite type");var gi=s(vi,!1,D,mi);return v(l,gi.key,gi.iv)}function h(l,vi){l=l.toLowerCase();var D,mi;if(i[l])D=i[l].key,mi=i[l].iv;else if(n[l])D=n[l].key*8,mi=n[l].iv;else throw new TypeError("invalid suite type");var gi=s(vi,!1,D,mi);return hi(l,gi.key,gi.iv)}function v(l,vi,D){if(l=l.toLowerCase(),i[l])return t.createCipheriv(l,vi,D);if(n[l])return new r({key:vi,iv:D,mode:l});throw new TypeError("invalid suite type")}function hi(l,vi,D){if(l=l.toLowerCase(),i[l])return t.createDecipheriv(l,vi,D);if(n[l])return new r({key:vi,iv:D,mode:l,decrypt:!0});throw new TypeError("invalid suite type")}function u(){return Object.keys(n).concat(t.getCiphers())}return browser$7.createCipher=browser$7.Cipher=a,browser$7.createCipheriv=browser$7.Cipheriv=v,browser$7.createDecipher=browser$7.Decipher=h,browser$7.createDecipheriv=browser$7.Decipheriv=hi,browser$7.listCiphers=browser$7.getCiphers=u,browser$7}var browser$5={},bn$5={exports:{}},bn$4=bn$5.exports,hasRequiredBn$2;function requireBn$2(){return hasRequiredBn$2||(hasRequiredBn$2=1,function(r){(function(t,i){function n($i,wi){if(!$i)throw new Error(wi||"Assertion failed")}function s($i,wi){$i.super_=wi;var xi=function(){};xi.prototype=wi.prototype,$i.prototype=new xi,$i.prototype.constructor=$i}function a($i,wi,xi){if(a.isBN($i))return $i;this.negative=0,this.words=null,this.length=0,this.red=null,$i!==null&&((wi==="le"||wi==="be")&&(xi=wi,wi=10),this._init($i||0,wi||10,xi||"be"))}typeof t=="object"?t.exports=a:i.BN=a,a.BN=a,a.wordSize=26;var h;try{typeof window<"u"&&typeof window.Buffer<"u"?h=window.Buffer:h=requireDist().Buffer}catch{}a.isBN=function(wi){return wi instanceof a?!0:wi!==null&&typeof wi=="object"&&wi.constructor.wordSize===a.wordSize&&Array.isArray(wi.words)},a.max=function(wi,xi){return wi.cmp(xi)>0?wi:xi},a.min=function(wi,xi){return wi.cmp(xi)<0?wi:xi},a.prototype._init=function(wi,xi,yi){if(typeof wi=="number")return this._initNumber(wi,xi,yi);if(typeof wi=="object")return this._initArray(wi,xi,yi);xi==="hex"&&(xi=16),n(xi===(xi|0)&&xi>=2&&xi<=36),wi=wi.toString().replace(/\s+/g,"");var Ei=0;wi[0]==="-"&&(Ei++,this.negative=1),Ei<wi.length&&(xi===16?this._parseHex(wi,Ei,yi):(this._parseBase(wi,xi,Ei),yi==="le"&&this._initArray(this.toArray(),xi,yi)))},a.prototype._initNumber=function(wi,xi,yi){wi<0&&(this.negative=1,wi=-wi),wi<67108864?(this.words=[wi&67108863],this.length=1):wi<4503599627370496?(this.words=[wi&67108863,wi/67108864&67108863],this.length=2):(n(wi<9007199254740992),this.words=[wi&67108863,wi/67108864&67108863,1],this.length=3),yi==="le"&&this._initArray(this.toArray(),xi,yi)},a.prototype._initArray=function(wi,xi,yi){if(n(typeof wi.length=="number"),wi.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(wi.length/3),this.words=new Array(this.length);for(var Ei=0;Ei<this.length;Ei++)this.words[Ei]=0;var Ci,Ni,Fi=0;if(yi==="be")for(Ei=wi.length-1,Ci=0;Ei>=0;Ei-=3)Ni=wi[Ei]|wi[Ei-1]<<8|wi[Ei-2]<<16,this.words[Ci]|=Ni<<Fi&67108863,this.words[Ci+1]=Ni>>>26-Fi&67108863,Fi+=24,Fi>=26&&(Fi-=26,Ci++);else if(yi==="le")for(Ei=0,Ci=0;Ei<wi.length;Ei+=3)Ni=wi[Ei]|wi[Ei+1]<<8|wi[Ei+2]<<16,this.words[Ci]|=Ni<<Fi&67108863,this.words[Ci+1]=Ni>>>26-Fi&67108863,Fi+=24,Fi>=26&&(Fi-=26,Ci++);return this.strip()};function v($i,wi){var xi=$i.charCodeAt(wi);return xi>=65&&xi<=70?xi-55:xi>=97&&xi<=102?xi-87:xi-48&15}function hi($i,wi,xi){var yi=v($i,xi);return xi-1>=wi&&(yi|=v($i,xi-1)<<4),yi}a.prototype._parseHex=function(wi,xi,yi){this.length=Math.ceil((wi.length-xi)/6),this.words=new Array(this.length);for(var Ei=0;Ei<this.length;Ei++)this.words[Ei]=0;var Ci=0,Ni=0,Fi;if(yi==="be")for(Ei=wi.length-1;Ei>=xi;Ei-=2)Fi=hi(wi,xi,Ei)<<Ci,this.words[Ni]|=Fi&67108863,Ci>=18?(Ci-=18,Ni+=1,this.words[Ni]|=Fi>>>26):Ci+=8;else{var Mi=wi.length-xi;for(Ei=Mi%2===0?xi+1:xi;Ei<wi.length;Ei+=2)Fi=hi(wi,xi,Ei)<<Ci,this.words[Ni]|=Fi&67108863,Ci>=18?(Ci-=18,Ni+=1,this.words[Ni]|=Fi>>>26):Ci+=8}this.strip()};function u($i,wi,xi,yi){for(var Ei=0,Ci=Math.min($i.length,xi),Ni=wi;Ni<Ci;Ni++){var Fi=$i.charCodeAt(Ni)-48;Ei*=yi,Fi>=49?Ei+=Fi-49+10:Fi>=17?Ei+=Fi-17+10:Ei+=Fi}return Ei}a.prototype._parseBase=function(wi,xi,yi){this.words=[0],this.length=1;for(var Ei=0,Ci=1;Ci<=67108863;Ci*=xi)Ei++;Ei--,Ci=Ci/xi|0;for(var Ni=wi.length-yi,Fi=Ni%Ei,Mi=Math.min(Ni,Ni-Fi)+yi,Si=0,Ai=yi;Ai<Mi;Ai+=Ei)Si=u(wi,Ai,Ai+Ei,xi),this.imuln(Ci),this.words[0]+Si<67108864?this.words[0]+=Si:this._iaddn(Si);if(Fi!==0){var _i=1;for(Si=u(wi,Ai,wi.length,xi),Ai=0;Ai<Fi;Ai++)_i*=xi;this.imuln(_i),this.words[0]+Si<67108864?this.words[0]+=Si:this._iaddn(Si)}this.strip()},a.prototype.copy=function(wi){wi.words=new Array(this.length);for(var xi=0;xi<this.length;xi++)wi.words[xi]=this.words[xi];wi.length=this.length,wi.negative=this.negative,wi.red=this.red},a.prototype.clone=function(){var wi=new a(null);return this.copy(wi),wi},a.prototype._expand=function(wi){for(;this.length<wi;)this.words[this.length++]=0;return this},a.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},a.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},a.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var l=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],vi=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],D=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];a.prototype.toString=function(wi,xi){wi=wi||10,xi=xi|0||1;var yi;if(wi===16||wi==="hex"){yi="";for(var Ei=0,Ci=0,Ni=0;Ni<this.length;Ni++){var Fi=this.words[Ni],Mi=((Fi<<Ei|Ci)&16777215).toString(16);Ci=Fi>>>24-Ei&16777215,Ei+=2,Ei>=26&&(Ei-=26,Ni--),Ci!==0||Ni!==this.length-1?yi=l[6-Mi.length]+Mi+yi:yi=Mi+yi}for(Ci!==0&&(yi=Ci.toString(16)+yi);yi.length%xi!==0;)yi="0"+yi;return this.negative!==0&&(yi="-"+yi),yi}if(wi===(wi|0)&&wi>=2&&wi<=36){var Si=vi[wi],Ai=D[wi];yi="";var _i=this.clone();for(_i.negative=0;!_i.isZero();){var Bi=_i.modn(Ai).toString(wi);_i=_i.idivn(Ai),_i.isZero()?yi=Bi+yi:yi=l[Si-Bi.length]+Bi+yi}for(this.isZero()&&(yi="0"+yi);yi.length%xi!==0;)yi="0"+yi;return this.negative!==0&&(yi="-"+yi),yi}n(!1,"Base should be between 2 and 36")},a.prototype.toNumber=function(){var wi=this.words[0];return this.length===2?wi+=this.words[1]*67108864:this.length===3&&this.words[2]===1?wi+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-wi:wi},a.prototype.toJSON=function(){return this.toString(16)},a.prototype.toBuffer=function(wi,xi){return n(typeof h<"u"),this.toArrayLike(h,wi,xi)},a.prototype.toArray=function(wi,xi){return this.toArrayLike(Array,wi,xi)},a.prototype.toArrayLike=function(wi,xi,yi){var Ei=this.byteLength(),Ci=yi||Math.max(1,Ei);n(Ei<=Ci,"byte array longer than desired length"),n(Ci>0,"Requested array length <= 0"),this.strip();var Ni=xi==="le",Fi=new wi(Ci),Mi,Si,Ai=this.clone();if(Ni){for(Si=0;!Ai.isZero();Si++)Mi=Ai.andln(255),Ai.iushrn(8),Fi[Si]=Mi;for(;Si<Ci;Si++)Fi[Si]=0}else{for(Si=0;Si<Ci-Ei;Si++)Fi[Si]=0;for(Si=0;!Ai.isZero();Si++)Mi=Ai.andln(255),Ai.iushrn(8),Fi[Ci-Si-1]=Mi}return Fi},Math.clz32?a.prototype._countBits=function(wi){return 32-Math.clz32(wi)}:a.prototype._countBits=function(wi){var xi=wi,yi=0;return xi>=4096&&(yi+=13,xi>>>=13),xi>=64&&(yi+=7,xi>>>=7),xi>=8&&(yi+=4,xi>>>=4),xi>=2&&(yi+=2,xi>>>=2),yi+xi},a.prototype._zeroBits=function(wi){if(wi===0)return 26;var xi=wi,yi=0;return(xi&8191)===0&&(yi+=13,xi>>>=13),(xi&127)===0&&(yi+=7,xi>>>=7),(xi&15)===0&&(yi+=4,xi>>>=4),(xi&3)===0&&(yi+=2,xi>>>=2),(xi&1)===0&&yi++,yi},a.prototype.bitLength=function(){var wi=this.words[this.length-1],xi=this._countBits(wi);return(this.length-1)*26+xi};function mi($i){for(var wi=new Array($i.bitLength()),xi=0;xi<wi.length;xi++){var yi=xi/26|0,Ei=xi%26;wi[xi]=($i.words[yi]&1<<Ei)>>>Ei}return wi}a.prototype.zeroBits=function(){if(this.isZero())return 0;for(var wi=0,xi=0;xi<this.length;xi++){var yi=this._zeroBits(this.words[xi]);if(wi+=yi,yi!==26)break}return wi},a.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},a.prototype.toTwos=function(wi){return this.negative!==0?this.abs().inotn(wi).iaddn(1):this.clone()},a.prototype.fromTwos=function(wi){return this.testn(wi-1)?this.notn(wi).iaddn(1).ineg():this.clone()},a.prototype.isNeg=function(){return this.negative!==0},a.prototype.neg=function(){return this.clone().ineg()},a.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},a.prototype.iuor=function(wi){for(;this.length<wi.length;)this.words[this.length++]=0;for(var xi=0;xi<wi.length;xi++)this.words[xi]=this.words[xi]|wi.words[xi];return this.strip()},a.prototype.ior=function(wi){return n((this.negative|wi.negative)===0),this.iuor(wi)},a.prototype.or=function(wi){return this.length>wi.length?this.clone().ior(wi):wi.clone().ior(this)},a.prototype.uor=function(wi){return this.length>wi.length?this.clone().iuor(wi):wi.clone().iuor(this)},a.prototype.iuand=function(wi){var xi;this.length>wi.length?xi=wi:xi=this;for(var yi=0;yi<xi.length;yi++)this.words[yi]=this.words[yi]&wi.words[yi];return this.length=xi.length,this.strip()},a.prototype.iand=function(wi){return n((this.negative|wi.negative)===0),this.iuand(wi)},a.prototype.and=function(wi){return this.length>wi.length?this.clone().iand(wi):wi.clone().iand(this)},a.prototype.uand=function(wi){return this.length>wi.length?this.clone().iuand(wi):wi.clone().iuand(this)},a.prototype.iuxor=function(wi){var xi,yi;this.length>wi.length?(xi=this,yi=wi):(xi=wi,yi=this);for(var Ei=0;Ei<yi.length;Ei++)this.words[Ei]=xi.words[Ei]^yi.words[Ei];if(this!==xi)for(;Ei<xi.length;Ei++)this.words[Ei]=xi.words[Ei];return this.length=xi.length,this.strip()},a.prototype.ixor=function(wi){return n((this.negative|wi.negative)===0),this.iuxor(wi)},a.prototype.xor=function(wi){return this.length>wi.length?this.clone().ixor(wi):wi.clone().ixor(this)},a.prototype.uxor=function(wi){return this.length>wi.length?this.clone().iuxor(wi):wi.clone().iuxor(this)},a.prototype.inotn=function(wi){n(typeof wi=="number"&&wi>=0);var xi=Math.ceil(wi/26)|0,yi=wi%26;this._expand(xi),yi>0&&xi--;for(var Ei=0;Ei<xi;Ei++)this.words[Ei]=~this.words[Ei]&67108863;return yi>0&&(this.words[Ei]=~this.words[Ei]&67108863>>26-yi),this.strip()},a.prototype.notn=function(wi){return this.clone().inotn(wi)},a.prototype.setn=function(wi,xi){n(typeof wi=="number"&&wi>=0);var yi=wi/26|0,Ei=wi%26;return this._expand(yi+1),xi?this.words[yi]=this.words[yi]|1<<Ei:this.words[yi]=this.words[yi]&~(1<<Ei),this.strip()},a.prototype.iadd=function(wi){var xi;if(this.negative!==0&&wi.negative===0)return this.negative=0,xi=this.isub(wi),this.negative^=1,this._normSign();if(this.negative===0&&wi.negative!==0)return wi.negative=0,xi=this.isub(wi),wi.negative=1,xi._normSign();var yi,Ei;this.length>wi.length?(yi=this,Ei=wi):(yi=wi,Ei=this);for(var Ci=0,Ni=0;Ni<Ei.length;Ni++)xi=(yi.words[Ni]|0)+(Ei.words[Ni]|0)+Ci,this.words[Ni]=xi&67108863,Ci=xi>>>26;for(;Ci!==0&&Ni<yi.length;Ni++)xi=(yi.words[Ni]|0)+Ci,this.words[Ni]=xi&67108863,Ci=xi>>>26;if(this.length=yi.length,Ci!==0)this.words[this.length]=Ci,this.length++;else if(yi!==this)for(;Ni<yi.length;Ni++)this.words[Ni]=yi.words[Ni];return this},a.prototype.add=function(wi){var xi;return wi.negative!==0&&this.negative===0?(wi.negative=0,xi=this.sub(wi),wi.negative^=1,xi):wi.negative===0&&this.negative!==0?(this.negative=0,xi=wi.sub(this),this.negative=1,xi):this.length>wi.length?this.clone().iadd(wi):wi.clone().iadd(this)},a.prototype.isub=function(wi){if(wi.negative!==0){wi.negative=0;var xi=this.iadd(wi);return wi.negative=1,xi._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(wi),this.negative=1,this._normSign();var yi=this.cmp(wi);if(yi===0)return this.negative=0,this.length=1,this.words[0]=0,this;var Ei,Ci;yi>0?(Ei=this,Ci=wi):(Ei=wi,Ci=this);for(var Ni=0,Fi=0;Fi<Ci.length;Fi++)xi=(Ei.words[Fi]|0)-(Ci.words[Fi]|0)+Ni,Ni=xi>>26,this.words[Fi]=xi&67108863;for(;Ni!==0&&Fi<Ei.length;Fi++)xi=(Ei.words[Fi]|0)+Ni,Ni=xi>>26,this.words[Fi]=xi&67108863;if(Ni===0&&Fi<Ei.length&&Ei!==this)for(;Fi<Ei.length;Fi++)this.words[Fi]=Ei.words[Fi];return this.length=Math.max(this.length,Fi),Ei!==this&&(this.negative=1),this.strip()},a.prototype.sub=function(wi){return this.clone().isub(wi)};function gi($i,wi,xi){xi.negative=wi.negative^$i.negative;var yi=$i.length+wi.length|0;xi.length=yi,yi=yi-1|0;var Ei=$i.words[0]|0,Ci=wi.words[0]|0,Ni=Ei*Ci,Fi=Ni&67108863,Mi=Ni/67108864|0;xi.words[0]=Fi;for(var Si=1;Si<yi;Si++){for(var Ai=Mi>>>26,_i=Mi&67108863,Bi=Math.min(Si,wi.length-1),Pi=Math.max(0,Si-$i.length+1);Pi<=Bi;Pi++){var zi=Si-Pi|0;Ei=$i.words[zi]|0,Ci=wi.words[Pi]|0,Ni=Ei*Ci+_i,Ai+=Ni/67108864|0,_i=Ni&67108863}xi.words[Si]=_i|0,Mi=Ai|0}return Mi!==0?xi.words[Si]=Mi|0:xi.length--,xi.strip()}var bi=function(wi,xi,yi){var Ei=wi.words,Ci=xi.words,Ni=yi.words,Fi=0,Mi,Si,Ai,_i=Ei[0]|0,Bi=_i&8191,Pi=_i>>>13,zi=Ei[1]|0,Gi=zi&8191,Vi=zi>>>13,Ki=Ei[2]|0,Zi=Ki&8191,In=Ki>>>13,Ji=Ei[3]|0,Xi=Ji&8191,on=Ji>>>13,jn=Ei[4]|0,Ln=jn&8191,Hn=jn>>>13,ea=Ei[5]|0,ia=ea&8191,Wn=ea>>>13,oa=Ei[6]|0,ta=oa&8191,aa=oa>>>13,sa=Ei[7]|0,ua=sa&8191,da=sa>>>13,ca=Ei[8]|0,la=ca&8191,Fa=ca>>>13,xa=Ei[9]|0,ha=xa&8191,Ca=xa>>>13,Ra=Ci[0]|0,pa=Ra&8191,Ma=Ra>>>13,wa=Ci[1]|0,ya=wa&8191,La=wa>>>13,Sa=Ci[2]|0,ga=Sa&8191,Pa=Sa>>>13,Ta=Ci[3]|0,va=Ta&8191,Ba=Ta>>>13,Aa=Ci[4]|0,_a=Aa&8191,ka=Aa>>>13,Na=Ci[5]|0,Rn=Na&8191,Wi=Na>>>13,Yi=Ci[6]|0,Mn=Yi&8191,Yn=Yi>>>13,ra=Ci[7]|0,na=ra&8191,Ea=ra>>>13,ba=Ci[8]|0,fa=ba&8191,Ia=ba>>>13,ma=Ci[9]|0,Da=ma&8191,$a=ma>>>13;yi.negative=wi.negative^xi.negative,yi.length=19,Mi=Math.imul(Bi,pa),Si=Math.imul(Bi,Ma),Si=Si+Math.imul(Pi,pa)|0,Ai=Math.imul(Pi,Ma);var qa=(Fi+Mi|0)+((Si&8191)<<13)|0;Fi=(Ai+(Si>>>13)|0)+(qa>>>26)|0,qa&=67108863,Mi=Math.imul(Gi,pa),Si=Math.imul(Gi,Ma),Si=Si+Math.imul(Vi,pa)|0,Ai=Math.imul(Vi,Ma),Mi=Mi+Math.imul(Bi,ya)|0,Si=Si+Math.imul(Bi,La)|0,Si=Si+Math.imul(Pi,ya)|0,Ai=Ai+Math.imul(Pi,La)|0;var Oa=(Fi+Mi|0)+((Si&8191)<<13)|0;Fi=(Ai+(Si>>>13)|0)+(Oa>>>26)|0,Oa&=67108863,Mi=Math.imul(Zi,pa),Si=Math.imul(Zi,Ma),Si=Si+Math.imul(In,pa)|0,Ai=Math.imul(In,Ma),Mi=Mi+Math.imul(Gi,ya)|0,Si=Si+Math.imul(Gi,La)|0,Si=Si+Math.imul(Vi,ya)|0,Ai=Ai+Math.imul(Vi,La)|0,Mi=Mi+Math.imul(Bi,ga)|0,Si=Si+Math.imul(Bi,Pa)|0,Si=Si+Math.imul(Pi,ga)|0,Ai=Ai+Math.imul(Pi,Pa)|0;var Ua=(Fi+Mi|0)+((Si&8191)<<13)|0;Fi=(Ai+(Si>>>13)|0)+(Ua>>>26)|0,Ua&=67108863,Mi=Math.imul(Xi,pa),Si=Math.imul(Xi,Ma),Si=Si+Math.imul(on,pa)|0,Ai=Math.imul(on,Ma),Mi=Mi+Math.imul(Zi,ya)|0,Si=Si+Math.imul(Zi,La)|0,Si=Si+Math.imul(In,ya)|0,Ai=Ai+Math.imul(In,La)|0,Mi=Mi+Math.imul(Gi,ga)|0,Si=Si+Math.imul(Gi,Pa)|0,Si=Si+Math.imul(Vi,ga)|0,Ai=Ai+Math.imul(Vi,Pa)|0,Mi=Mi+Math.imul(Bi,va)|0,Si=Si+Math.imul(Bi,Ba)|0,Si=Si+Math.imul(Pi,va)|0,Ai=Ai+Math.imul(Pi,Ba)|0;var ja=(Fi+Mi|0)+((Si&8191)<<13)|0;Fi=(Ai+(Si>>>13)|0)+(ja>>>26)|0,ja&=67108863,Mi=Math.imul(Ln,pa),Si=Math.imul(Ln,Ma),Si=Si+Math.imul(Hn,pa)|0,Ai=Math.imul(Hn,Ma),Mi=Mi+Math.imul(Xi,ya)|0,Si=Si+Math.imul(Xi,La)|0,Si=Si+Math.imul(on,ya)|0,Ai=Ai+Math.imul(on,La)|0,Mi=Mi+Math.imul(Zi,ga)|0,Si=Si+Math.imul(Zi,Pa)|0,Si=Si+Math.imul(In,ga)|0,Ai=Ai+Math.imul(In,Pa)|0,Mi=Mi+Math.imul(Gi,va)|0,Si=Si+Math.imul(Gi,Ba)|0,Si=Si+Math.imul(Vi,va)|0,Ai=Ai+Math.imul(Vi,Ba)|0,Mi=Mi+Math.imul(Bi,_a)|0,Si=Si+Math.imul(Bi,ka)|0,Si=Si+Math.imul(Pi,_a)|0,Ai=Ai+Math.imul(Pi,ka)|0;var Va=(Fi+Mi|0)+((Si&8191)<<13)|0;Fi=(Ai+(Si>>>13)|0)+(Va>>>26)|0,Va&=67108863,Mi=Math.imul(ia,pa),Si=Math.imul(ia,Ma),Si=Si+Math.imul(Wn,pa)|0,Ai=Math.imul(Wn,Ma),Mi=Mi+Math.imul(Ln,ya)|0,Si=Si+Math.imul(Ln,La)|0,Si=Si+Math.imul(Hn,ya)|0,Ai=Ai+Math.imul(Hn,La)|0,Mi=Mi+Math.imul(Xi,ga)|0,Si=Si+Math.imul(Xi,Pa)|0,Si=Si+Math.imul(on,ga)|0,Ai=Ai+Math.imul(on,Pa)|0,Mi=Mi+Math.imul(Zi,va)|0,Si=Si+Math.imul(Zi,Ba)|0,Si=Si+Math.imul(In,va)|0,Ai=Ai+Math.imul(In,Ba)|0,Mi=Mi+Math.imul(Gi,_a)|0,Si=Si+Math.imul(Gi,ka)|0,Si=Si+Math.imul(Vi,_a)|0,Ai=Ai+Math.imul(Vi,ka)|0,Mi=Mi+Math.imul(Bi,Rn)|0,Si=Si+Math.imul(Bi,Wi)|0,Si=Si+Math.imul(Pi,Rn)|0,Ai=Ai+Math.imul(Pi,Wi)|0;var Ga=(Fi+Mi|0)+((Si&8191)<<13)|0;Fi=(Ai+(Si>>>13)|0)+(Ga>>>26)|0,Ga&=67108863,Mi=Math.imul(ta,pa),Si=Math.imul(ta,Ma),Si=Si+Math.imul(aa,pa)|0,Ai=Math.imul(aa,Ma),Mi=Mi+Math.imul(ia,ya)|0,Si=Si+Math.imul(ia,La)|0,Si=Si+Math.imul(Wn,ya)|0,Ai=Ai+Math.imul(Wn,La)|0,Mi=Mi+Math.imul(Ln,ga)|0,Si=Si+Math.imul(Ln,Pa)|0,Si=Si+Math.imul(Hn,ga)|0,Ai=Ai+Math.imul(Hn,Pa)|0,Mi=Mi+Math.imul(Xi,va)|0,Si=Si+Math.imul(Xi,Ba)|0,Si=Si+Math.imul(on,va)|0,Ai=Ai+Math.imul(on,Ba)|0,Mi=Mi+Math.imul(Zi,_a)|0,Si=Si+Math.imul(Zi,ka)|0,Si=Si+Math.imul(In,_a)|0,Ai=Ai+Math.imul(In,ka)|0,Mi=Mi+Math.imul(Gi,Rn)|0,Si=Si+Math.imul(Gi,Wi)|0,Si=Si+Math.imul(Vi,Rn)|0,Ai=Ai+Math.imul(Vi,Wi)|0,Mi=Mi+Math.imul(Bi,Mn)|0,Si=Si+Math.imul(Bi,Yn)|0,Si=Si+Math.imul(Pi,Mn)|0,Ai=Ai+Math.imul(Pi,Yn)|0;var Ka=(Fi+Mi|0)+((Si&8191)<<13)|0;Fi=(Ai+(Si>>>13)|0)+(Ka>>>26)|0,Ka&=67108863,Mi=Math.imul(ua,pa),Si=Math.imul(ua,Ma),Si=Si+Math.imul(da,pa)|0,Ai=Math.imul(da,Ma),Mi=Mi+Math.imul(ta,ya)|0,Si=Si+Math.imul(ta,La)|0,Si=Si+Math.imul(aa,ya)|0,Ai=Ai+Math.imul(aa,La)|0,Mi=Mi+Math.imul(ia,ga)|0,Si=Si+Math.imul(ia,Pa)|0,Si=Si+Math.imul(Wn,ga)|0,Ai=Ai+Math.imul(Wn,Pa)|0,Mi=Mi+Math.imul(Ln,va)|0,Si=Si+Math.imul(Ln,Ba)|0,Si=Si+Math.imul(Hn,va)|0,Ai=Ai+Math.imul(Hn,Ba)|0,Mi=Mi+Math.imul(Xi,_a)|0,Si=Si+Math.imul(Xi,ka)|0,Si=Si+Math.imul(on,_a)|0,Ai=Ai+Math.imul(on,ka)|0,Mi=Mi+Math.imul(Zi,Rn)|0,Si=Si+Math.imul(Zi,Wi)|0,Si=Si+Math.imul(In,Rn)|0,Ai=Ai+Math.imul(In,Wi)|0,Mi=Mi+Math.imul(Gi,Mn)|0,Si=Si+Math.imul(Gi,Yn)|0,Si=Si+Math.imul(Vi,Mn)|0,Ai=Ai+Math.imul(Vi,Yn)|0,Mi=Mi+Math.imul(Bi,na)|0,Si=Si+Math.imul(Bi,Ea)|0,Si=Si+Math.imul(Pi,na)|0,Ai=Ai+Math.imul(Pi,Ea)|0;var Ha=(Fi+Mi|0)+((Si&8191)<<13)|0;Fi=(Ai+(Si>>>13)|0)+(Ha>>>26)|0,Ha&=67108863,Mi=Math.imul(la,pa),Si=Math.imul(la,Ma),Si=Si+Math.imul(Fa,pa)|0,Ai=Math.imul(Fa,Ma),Mi=Mi+Math.imul(ua,ya)|0,Si=Si+Math.imul(ua,La)|0,Si=Si+Math.imul(da,ya)|0,Ai=Ai+Math.imul(da,La)|0,Mi=Mi+Math.imul(ta,ga)|0,Si=Si+Math.imul(ta,Pa)|0,Si=Si+Math.imul(aa,ga)|0,Ai=Ai+Math.imul(aa,Pa)|0,Mi=Mi+Math.imul(ia,va)|0,Si=Si+Math.imul(ia,Ba)|0,Si=Si+Math.imul(Wn,va)|0,Ai=Ai+Math.imul(Wn,Ba)|0,Mi=Mi+Math.imul(Ln,_a)|0,Si=Si+Math.imul(Ln,ka)|0,Si=Si+Math.imul(Hn,_a)|0,Ai=Ai+Math.imul(Hn,ka)|0,Mi=Mi+Math.imul(Xi,Rn)|0,Si=Si+Math.imul(Xi,Wi)|0,Si=Si+Math.imul(on,Rn)|0,Ai=Ai+Math.imul(on,Wi)|0,Mi=Mi+Math.imul(Zi,Mn)|0,Si=Si+Math.imul(Zi,Yn)|0,Si=Si+Math.imul(In,Mn)|0,Ai=Ai+Math.imul(In,Yn)|0,Mi=Mi+Math.imul(Gi,na)|0,Si=Si+Math.imul(Gi,Ea)|0,Si=Si+Math.imul(Vi,na)|0,Ai=Ai+Math.imul(Vi,Ea)|0,Mi=Mi+Math.imul(Bi,fa)|0,Si=Si+Math.imul(Bi,Ia)|0,Si=Si+Math.imul(Pi,fa)|0,Ai=Ai+Math.imul(Pi,Ia)|0;var Qa=(Fi+Mi|0)+((Si&8191)<<13)|0;Fi=(Ai+(Si>>>13)|0)+(Qa>>>26)|0,Qa&=67108863,Mi=Math.imul(ha,pa),Si=Math.imul(ha,Ma),Si=Si+Math.imul(Ca,pa)|0,Ai=Math.imul(Ca,Ma),Mi=Mi+Math.imul(la,ya)|0,Si=Si+Math.imul(la,La)|0,Si=Si+Math.imul(Fa,ya)|0,Ai=Ai+Math.imul(Fa,La)|0,Mi=Mi+Math.imul(ua,ga)|0,Si=Si+Math.imul(ua,Pa)|0,Si=Si+Math.imul(da,ga)|0,Ai=Ai+Math.imul(da,Pa)|0,Mi=Mi+Math.imul(ta,va)|0,Si=Si+Math.imul(ta,Ba)|0,Si=Si+Math.imul(aa,va)|0,Ai=Ai+Math.imul(aa,Ba)|0,Mi=Mi+Math.imul(ia,_a)|0,Si=Si+Math.imul(ia,ka)|0,Si=Si+Math.imul(Wn,_a)|0,Ai=Ai+Math.imul(Wn,ka)|0,Mi=Mi+Math.imul(Ln,Rn)|0,Si=Si+Math.imul(Ln,Wi)|0,Si=Si+Math.imul(Hn,Rn)|0,Ai=Ai+Math.imul(Hn,Wi)|0,Mi=Mi+Math.imul(Xi,Mn)|0,Si=Si+Math.imul(Xi,Yn)|0,Si=Si+Math.imul(on,Mn)|0,Ai=Ai+Math.imul(on,Yn)|0,Mi=Mi+Math.imul(Zi,na)|0,Si=Si+Math.imul(Zi,Ea)|0,Si=Si+Math.imul(In,na)|0,Ai=Ai+Math.imul(In,Ea)|0,Mi=Mi+Math.imul(Gi,fa)|0,Si=Si+Math.imul(Gi,Ia)|0,Si=Si+Math.imul(Vi,fa)|0,Ai=Ai+Math.imul(Vi,Ia)|0,Mi=Mi+Math.imul(Bi,Da)|0,Si=Si+Math.imul(Bi,$a)|0,Si=Si+Math.imul(Pi,Da)|0,Ai=Ai+Math.imul(Pi,$a)|0;var za=(Fi+Mi|0)+((Si&8191)<<13)|0;Fi=(Ai+(Si>>>13)|0)+(za>>>26)|0,za&=67108863,Mi=Math.imul(ha,ya),Si=Math.imul(ha,La),Si=Si+Math.imul(Ca,ya)|0,Ai=Math.imul(Ca,La),Mi=Mi+Math.imul(la,ga)|0,Si=Si+Math.imul(la,Pa)|0,Si=Si+Math.imul(Fa,ga)|0,Ai=Ai+Math.imul(Fa,Pa)|0,Mi=Mi+Math.imul(ua,va)|0,Si=Si+Math.imul(ua,Ba)|0,Si=Si+Math.imul(da,va)|0,Ai=Ai+Math.imul(da,Ba)|0,Mi=Mi+Math.imul(ta,_a)|0,Si=Si+Math.imul(ta,ka)|0,Si=Si+Math.imul(aa,_a)|0,Ai=Ai+Math.imul(aa,ka)|0,Mi=Mi+Math.imul(ia,Rn)|0,Si=Si+Math.imul(ia,Wi)|0,Si=Si+Math.imul(Wn,Rn)|0,Ai=Ai+Math.imul(Wn,Wi)|0,Mi=Mi+Math.imul(Ln,Mn)|0,Si=Si+Math.imul(Ln,Yn)|0,Si=Si+Math.imul(Hn,Mn)|0,Ai=Ai+Math.imul(Hn,Yn)|0,Mi=Mi+Math.imul(Xi,na)|0,Si=Si+Math.imul(Xi,Ea)|0,Si=Si+Math.imul(on,na)|0,Ai=Ai+Math.imul(on,Ea)|0,Mi=Mi+Math.imul(Zi,fa)|0,Si=Si+Math.imul(Zi,Ia)|0,Si=Si+Math.imul(In,fa)|0,Ai=Ai+Math.imul(In,Ia)|0,Mi=Mi+Math.imul(Gi,Da)|0,Si=Si+Math.imul(Gi,$a)|0,Si=Si+Math.imul(Vi,Da)|0,Ai=Ai+Math.imul(Vi,$a)|0;var Wa=(Fi+Mi|0)+((Si&8191)<<13)|0;Fi=(Ai+(Si>>>13)|0)+(Wa>>>26)|0,Wa&=67108863,Mi=Math.imul(ha,ga),Si=Math.imul(ha,Pa),Si=Si+Math.imul(Ca,ga)|0,Ai=Math.imul(Ca,Pa),Mi=Mi+Math.imul(la,va)|0,Si=Si+Math.imul(la,Ba)|0,Si=Si+Math.imul(Fa,va)|0,Ai=Ai+Math.imul(Fa,Ba)|0,Mi=Mi+Math.imul(ua,_a)|0,Si=Si+Math.imul(ua,ka)|0,Si=Si+Math.imul(da,_a)|0,Ai=Ai+Math.imul(da,ka)|0,Mi=Mi+Math.imul(ta,Rn)|0,Si=Si+Math.imul(ta,Wi)|0,Si=Si+Math.imul(aa,Rn)|0,Ai=Ai+Math.imul(aa,Wi)|0,Mi=Mi+Math.imul(ia,Mn)|0,Si=Si+Math.imul(ia,Yn)|0,Si=Si+Math.imul(Wn,Mn)|0,Ai=Ai+Math.imul(Wn,Yn)|0,Mi=Mi+Math.imul(Ln,na)|0,Si=Si+Math.imul(Ln,Ea)|0,Si=Si+Math.imul(Hn,na)|0,Ai=Ai+Math.imul(Hn,Ea)|0,Mi=Mi+Math.imul(Xi,fa)|0,Si=Si+Math.imul(Xi,Ia)|0,Si=Si+Math.imul(on,fa)|0,Ai=Ai+Math.imul(on,Ia)|0,Mi=Mi+Math.imul(Zi,Da)|0,Si=Si+Math.imul(Zi,$a)|0,Si=Si+Math.imul(In,Da)|0,Ai=Ai+Math.imul(In,$a)|0;var Ya=(Fi+Mi|0)+((Si&8191)<<13)|0;Fi=(Ai+(Si>>>13)|0)+(Ya>>>26)|0,Ya&=67108863,Mi=Math.imul(ha,va),Si=Math.imul(ha,Ba),Si=Si+Math.imul(Ca,va)|0,Ai=Math.imul(Ca,Ba),Mi=Mi+Math.imul(la,_a)|0,Si=Si+Math.imul(la,ka)|0,Si=Si+Math.imul(Fa,_a)|0,Ai=Ai+Math.imul(Fa,ka)|0,Mi=Mi+Math.imul(ua,Rn)|0,Si=Si+Math.imul(ua,Wi)|0,Si=Si+Math.imul(da,Rn)|0,Ai=Ai+Math.imul(da,Wi)|0,Mi=Mi+Math.imul(ta,Mn)|0,Si=Si+Math.imul(ta,Yn)|0,Si=Si+Math.imul(aa,Mn)|0,Ai=Ai+Math.imul(aa,Yn)|0,Mi=Mi+Math.imul(ia,na)|0,Si=Si+Math.imul(ia,Ea)|0,Si=Si+Math.imul(Wn,na)|0,Ai=Ai+Math.imul(Wn,Ea)|0,Mi=Mi+Math.imul(Ln,fa)|0,Si=Si+Math.imul(Ln,Ia)|0,Si=Si+Math.imul(Hn,fa)|0,Ai=Ai+Math.imul(Hn,Ia)|0,Mi=Mi+Math.imul(Xi,Da)|0,Si=Si+Math.imul(Xi,$a)|0,Si=Si+Math.imul(on,Da)|0,Ai=Ai+Math.imul(on,$a)|0;var Xa=(Fi+Mi|0)+((Si&8191)<<13)|0;Fi=(Ai+(Si>>>13)|0)+(Xa>>>26)|0,Xa&=67108863,Mi=Math.imul(ha,_a),Si=Math.imul(ha,ka),Si=Si+Math.imul(Ca,_a)|0,Ai=Math.imul(Ca,ka),Mi=Mi+Math.imul(la,Rn)|0,Si=Si+Math.imul(la,Wi)|0,Si=Si+Math.imul(Fa,Rn)|0,Ai=Ai+Math.imul(Fa,Wi)|0,Mi=Mi+Math.imul(ua,Mn)|0,Si=Si+Math.imul(ua,Yn)|0,Si=Si+Math.imul(da,Mn)|0,Ai=Ai+Math.imul(da,Yn)|0,Mi=Mi+Math.imul(ta,na)|0,Si=Si+Math.imul(ta,Ea)|0,Si=Si+Math.imul(aa,na)|0,Ai=Ai+Math.imul(aa,Ea)|0,Mi=Mi+Math.imul(ia,fa)|0,Si=Si+Math.imul(ia,Ia)|0,Si=Si+Math.imul(Wn,fa)|0,Ai=Ai+Math.imul(Wn,Ia)|0,Mi=Mi+Math.imul(Ln,Da)|0,Si=Si+Math.imul(Ln,$a)|0,Si=Si+Math.imul(Hn,Da)|0,Ai=Ai+Math.imul(Hn,$a)|0;var Ja=(Fi+Mi|0)+((Si&8191)<<13)|0;Fi=(Ai+(Si>>>13)|0)+(Ja>>>26)|0,Ja&=67108863,Mi=Math.imul(ha,Rn),Si=Math.imul(ha,Wi),Si=Si+Math.imul(Ca,Rn)|0,Ai=Math.imul(Ca,Wi),Mi=Mi+Math.imul(la,Mn)|0,Si=Si+Math.imul(la,Yn)|0,Si=Si+Math.imul(Fa,Mn)|0,Ai=Ai+Math.imul(Fa,Yn)|0,Mi=Mi+Math.imul(ua,na)|0,Si=Si+Math.imul(ua,Ea)|0,Si=Si+Math.imul(da,na)|0,Ai=Ai+Math.imul(da,Ea)|0,Mi=Mi+Math.imul(ta,fa)|0,Si=Si+Math.imul(ta,Ia)|0,Si=Si+Math.imul(aa,fa)|0,Ai=Ai+Math.imul(aa,Ia)|0,Mi=Mi+Math.imul(ia,Da)|0,Si=Si+Math.imul(ia,$a)|0,Si=Si+Math.imul(Wn,Da)|0,Ai=Ai+Math.imul(Wn,$a)|0;var Za=(Fi+Mi|0)+((Si&8191)<<13)|0;Fi=(Ai+(Si>>>13)|0)+(Za>>>26)|0,Za&=67108863,Mi=Math.imul(ha,Mn),Si=Math.imul(ha,Yn),Si=Si+Math.imul(Ca,Mn)|0,Ai=Math.imul(Ca,Yn),Mi=Mi+Math.imul(la,na)|0,Si=Si+Math.imul(la,Ea)|0,Si=Si+Math.imul(Fa,na)|0,Ai=Ai+Math.imul(Fa,Ea)|0,Mi=Mi+Math.imul(ua,fa)|0,Si=Si+Math.imul(ua,Ia)|0,Si=Si+Math.imul(da,fa)|0,Ai=Ai+Math.imul(da,Ia)|0,Mi=Mi+Math.imul(ta,Da)|0,Si=Si+Math.imul(ta,$a)|0,Si=Si+Math.imul(aa,Da)|0,Ai=Ai+Math.imul(aa,$a)|0;var ao=(Fi+Mi|0)+((Si&8191)<<13)|0;Fi=(Ai+(Si>>>13)|0)+(ao>>>26)|0,ao&=67108863,Mi=Math.imul(ha,na),Si=Math.imul(ha,Ea),Si=Si+Math.imul(Ca,na)|0,Ai=Math.imul(Ca,Ea),Mi=Mi+Math.imul(la,fa)|0,Si=Si+Math.imul(la,Ia)|0,Si=Si+Math.imul(Fa,fa)|0,Ai=Ai+Math.imul(Fa,Ia)|0,Mi=Mi+Math.imul(ua,Da)|0,Si=Si+Math.imul(ua,$a)|0,Si=Si+Math.imul(da,Da)|0,Ai=Ai+Math.imul(da,$a)|0;var vo=(Fi+Mi|0)+((Si&8191)<<13)|0;Fi=(Ai+(Si>>>13)|0)+(vo>>>26)|0,vo&=67108863,Mi=Math.imul(ha,fa),Si=Math.imul(ha,Ia),Si=Si+Math.imul(Ca,fa)|0,Ai=Math.imul(Ca,Ia),Mi=Mi+Math.imul(la,Da)|0,Si=Si+Math.imul(la,$a)|0,Si=Si+Math.imul(Fa,Da)|0,Ai=Ai+Math.imul(Fa,$a)|0;var bo=(Fi+Mi|0)+((Si&8191)<<13)|0;Fi=(Ai+(Si>>>13)|0)+(bo>>>26)|0,bo&=67108863,Mi=Math.imul(ha,Da),Si=Math.imul(ha,$a),Si=Si+Math.imul(Ca,Da)|0,Ai=Math.imul(Ca,$a);var So=(Fi+Mi|0)+((Si&8191)<<13)|0;return Fi=(Ai+(Si>>>13)|0)+(So>>>26)|0,So&=67108863,Ni[0]=qa,Ni[1]=Oa,Ni[2]=Ua,Ni[3]=ja,Ni[4]=Va,Ni[5]=Ga,Ni[6]=Ka,Ni[7]=Ha,Ni[8]=Qa,Ni[9]=za,Ni[10]=Wa,Ni[11]=Ya,Ni[12]=Xa,Ni[13]=Ja,Ni[14]=Za,Ni[15]=ao,Ni[16]=vo,Ni[17]=bo,Ni[18]=So,Fi!==0&&(Ni[19]=Fi,yi.length++),yi};Math.imul||(bi=gi);function Ri($i,wi,xi){xi.negative=wi.negative^$i.negative,xi.length=$i.length+wi.length;for(var yi=0,Ei=0,Ci=0;Ci<xi.length-1;Ci++){var Ni=Ei;Ei=0;for(var Fi=yi&67108863,Mi=Math.min(Ci,wi.length-1),Si=Math.max(0,Ci-$i.length+1);Si<=Mi;Si++){var Ai=Ci-Si,_i=$i.words[Ai]|0,Bi=wi.words[Si]|0,Pi=_i*Bi,zi=Pi&67108863;Ni=Ni+(Pi/67108864|0)|0,zi=zi+Fi|0,Fi=zi&67108863,Ni=Ni+(zi>>>26)|0,Ei+=Ni>>>26,Ni&=67108863}xi.words[Ci]=Fi,yi=Ni,Ni=Ei}return yi!==0?xi.words[Ci]=yi:xi.length--,xi.strip()}function Ti($i,wi,xi){var yi=new Ii;return yi.mulp($i,wi,xi)}a.prototype.mulTo=function(wi,xi){var yi,Ei=this.length+wi.length;return this.length===10&&wi.length===10?yi=bi(this,wi,xi):Ei<63?yi=gi(this,wi,xi):Ei<1024?yi=Ri(this,wi,xi):yi=Ti(this,wi,xi),yi};function Ii($i,wi){this.x=$i,this.y=wi}Ii.prototype.makeRBT=function(wi){for(var xi=new Array(wi),yi=a.prototype._countBits(wi)-1,Ei=0;Ei<wi;Ei++)xi[Ei]=this.revBin(Ei,yi,wi);return xi},Ii.prototype.revBin=function(wi,xi,yi){if(wi===0||wi===yi-1)return wi;for(var Ei=0,Ci=0;Ci<xi;Ci++)Ei|=(wi&1)<<xi-Ci-1,wi>>=1;return Ei},Ii.prototype.permute=function(wi,xi,yi,Ei,Ci,Ni){for(var Fi=0;Fi<Ni;Fi++)Ei[Fi]=xi[wi[Fi]],Ci[Fi]=yi[wi[Fi]]},Ii.prototype.transform=function(wi,xi,yi,Ei,Ci,Ni){this.permute(Ni,wi,xi,yi,Ei,Ci);for(var Fi=1;Fi<Ci;Fi<<=1)for(var Mi=Fi<<1,Si=Math.cos(2*Math.PI/Mi),Ai=Math.sin(2*Math.PI/Mi),_i=0;_i<Ci;_i+=Mi)for(var Bi=Si,Pi=Ai,zi=0;zi<Fi;zi++){var Gi=yi[_i+zi],Vi=Ei[_i+zi],Ki=yi[_i+zi+Fi],Zi=Ei[_i+zi+Fi],In=Bi*Ki-Pi*Zi;Zi=Bi*Zi+Pi*Ki,Ki=In,yi[_i+zi]=Gi+Ki,Ei[_i+zi]=Vi+Zi,yi[_i+zi+Fi]=Gi-Ki,Ei[_i+zi+Fi]=Vi-Zi,zi!==Mi&&(In=Si*Bi-Ai*Pi,Pi=Si*Pi+Ai*Bi,Bi=In)}},Ii.prototype.guessLen13b=function(wi,xi){var yi=Math.max(xi,wi)|1,Ei=yi&1,Ci=0;for(yi=yi/2|0;yi;yi=yi>>>1)Ci++;return 1<<Ci+1+Ei},Ii.prototype.conjugate=function(wi,xi,yi){if(!(yi<=1))for(var Ei=0;Ei<yi/2;Ei++){var Ci=wi[Ei];wi[Ei]=wi[yi-Ei-1],wi[yi-Ei-1]=Ci,Ci=xi[Ei],xi[Ei]=-xi[yi-Ei-1],xi[yi-Ei-1]=-Ci}},Ii.prototype.normalize13b=function(wi,xi){for(var yi=0,Ei=0;Ei<xi/2;Ei++){var Ci=Math.round(wi[2*Ei+1]/xi)*8192+Math.round(wi[2*Ei]/xi)+yi;wi[Ei]=Ci&67108863,Ci<67108864?yi=0:yi=Ci/67108864|0}return wi},Ii.prototype.convert13b=function(wi,xi,yi,Ei){for(var Ci=0,Ni=0;Ni<xi;Ni++)Ci=Ci+(wi[Ni]|0),yi[2*Ni]=Ci&8191,Ci=Ci>>>13,yi[2*Ni+1]=Ci&8191,Ci=Ci>>>13;for(Ni=2*xi;Ni<Ei;++Ni)yi[Ni]=0;n(Ci===0),n((Ci&-8192)===0)},Ii.prototype.stub=function(wi){for(var xi=new Array(wi),yi=0;yi<wi;yi++)xi[yi]=0;return xi},Ii.prototype.mulp=function(wi,xi,yi){var Ei=2*this.guessLen13b(wi.length,xi.length),Ci=this.makeRBT(Ei),Ni=this.stub(Ei),Fi=new Array(Ei),Mi=new Array(Ei),Si=new Array(Ei),Ai=new Array(Ei),_i=new Array(Ei),Bi=new Array(Ei),Pi=yi.words;Pi.length=Ei,this.convert13b(wi.words,wi.length,Fi,Ei),this.convert13b(xi.words,xi.length,Ai,Ei),this.transform(Fi,Ni,Mi,Si,Ei,Ci),this.transform(Ai,Ni,_i,Bi,Ei,Ci);for(var zi=0;zi<Ei;zi++){var Gi=Mi[zi]*_i[zi]-Si[zi]*Bi[zi];Si[zi]=Mi[zi]*Bi[zi]+Si[zi]*_i[zi],Mi[zi]=Gi}return this.conjugate(Mi,Si,Ei),this.transform(Mi,Si,Pi,Ni,Ei,Ci),this.conjugate(Pi,Ni,Ei),this.normalize13b(Pi,Ei),yi.negative=wi.negative^xi.negative,yi.length=wi.length+xi.length,yi.strip()},a.prototype.mul=function(wi){var xi=new a(null);return xi.words=new Array(this.length+wi.length),this.mulTo(wi,xi)},a.prototype.mulf=function(wi){var xi=new a(null);return xi.words=new Array(this.length+wi.length),Ti(this,wi,xi)},a.prototype.imul=function(wi){return this.clone().mulTo(wi,this)},a.prototype.imuln=function(wi){n(typeof wi=="number"),n(wi<67108864);for(var xi=0,yi=0;yi<this.length;yi++){var Ei=(this.words[yi]|0)*wi,Ci=(Ei&67108863)+(xi&67108863);xi>>=26,xi+=Ei/67108864|0,xi+=Ci>>>26,this.words[yi]=Ci&67108863}return xi!==0&&(this.words[yi]=xi,this.length++),this.length=wi===0?1:this.length,this},a.prototype.muln=function(wi){return this.clone().imuln(wi)},a.prototype.sqr=function(){return this.mul(this)},a.prototype.isqr=function(){return this.imul(this.clone())},a.prototype.pow=function(wi){var xi=mi(wi);if(xi.length===0)return new a(1);for(var yi=this,Ei=0;Ei<xi.length&&xi[Ei]===0;Ei++,yi=yi.sqr());if(++Ei<xi.length)for(var Ci=yi.sqr();Ei<xi.length;Ei++,Ci=Ci.sqr())xi[Ei]!==0&&(yi=yi.mul(Ci));return yi},a.prototype.iushln=function(wi){n(typeof wi=="number"&&wi>=0);var xi=wi%26,yi=(wi-xi)/26,Ei=67108863>>>26-xi<<26-xi,Ci;if(xi!==0){var Ni=0;for(Ci=0;Ci<this.length;Ci++){var Fi=this.words[Ci]&Ei,Mi=(this.words[Ci]|0)-Fi<<xi;this.words[Ci]=Mi|Ni,Ni=Fi>>>26-xi}Ni&&(this.words[Ci]=Ni,this.length++)}if(yi!==0){for(Ci=this.length-1;Ci>=0;Ci--)this.words[Ci+yi]=this.words[Ci];for(Ci=0;Ci<yi;Ci++)this.words[Ci]=0;this.length+=yi}return this.strip()},a.prototype.ishln=function(wi){return n(this.negative===0),this.iushln(wi)},a.prototype.iushrn=function(wi,xi,yi){n(typeof wi=="number"&&wi>=0);var Ei;xi?Ei=(xi-xi%26)/26:Ei=0;var Ci=wi%26,Ni=Math.min((wi-Ci)/26,this.length),Fi=67108863^67108863>>>Ci<<Ci,Mi=yi;if(Ei-=Ni,Ei=Math.max(0,Ei),Mi){for(var Si=0;Si<Ni;Si++)Mi.words[Si]=this.words[Si];Mi.length=Ni}if(Ni!==0)if(this.length>Ni)for(this.length-=Ni,Si=0;Si<this.length;Si++)this.words[Si]=this.words[Si+Ni];else this.words[0]=0,this.length=1;var Ai=0;for(Si=this.length-1;Si>=0&&(Ai!==0||Si>=Ei);Si--){var _i=this.words[Si]|0;this.words[Si]=Ai<<26-Ci|_i>>>Ci,Ai=_i&Fi}return Mi&&Ai!==0&&(Mi.words[Mi.length++]=Ai),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},a.prototype.ishrn=function(wi,xi,yi){return n(this.negative===0),this.iushrn(wi,xi,yi)},a.prototype.shln=function(wi){return this.clone().ishln(wi)},a.prototype.ushln=function(wi){return this.clone().iushln(wi)},a.prototype.shrn=function(wi){return this.clone().ishrn(wi)},a.prototype.ushrn=function(wi){return this.clone().iushrn(wi)},a.prototype.testn=function(wi){n(typeof wi=="number"&&wi>=0);var xi=wi%26,yi=(wi-xi)/26,Ei=1<<xi;if(this.length<=yi)return!1;var Ci=this.words[yi];return!!(Ci&Ei)},a.prototype.imaskn=function(wi){n(typeof wi=="number"&&wi>=0);var xi=wi%26,yi=(wi-xi)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=yi)return this;if(xi!==0&&yi++,this.length=Math.min(yi,this.length),xi!==0){var Ei=67108863^67108863>>>xi<<xi;this.words[this.length-1]&=Ei}return this.strip()},a.prototype.maskn=function(wi){return this.clone().imaskn(wi)},a.prototype.iaddn=function(wi){return n(typeof wi=="number"),n(wi<67108864),wi<0?this.isubn(-wi):this.negative!==0?this.length===1&&(this.words[0]|0)<wi?(this.words[0]=wi-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(wi),this.negative=1,this):this._iaddn(wi)},a.prototype._iaddn=function(wi){this.words[0]+=wi;for(var xi=0;xi<this.length&&this.words[xi]>=67108864;xi++)this.words[xi]-=67108864,xi===this.length-1?this.words[xi+1]=1:this.words[xi+1]++;return this.length=Math.max(this.length,xi+1),this},a.prototype.isubn=function(wi){if(n(typeof wi=="number"),n(wi<67108864),wi<0)return this.iaddn(-wi);if(this.negative!==0)return this.negative=0,this.iaddn(wi),this.negative=1,this;if(this.words[0]-=wi,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var xi=0;xi<this.length&&this.words[xi]<0;xi++)this.words[xi]+=67108864,this.words[xi+1]-=1;return this.strip()},a.prototype.addn=function(wi){return this.clone().iaddn(wi)},a.prototype.subn=function(wi){return this.clone().isubn(wi)},a.prototype.iabs=function(){return this.negative=0,this},a.prototype.abs=function(){return this.clone().iabs()},a.prototype._ishlnsubmul=function(wi,xi,yi){var Ei=wi.length+yi,Ci;this._expand(Ei);var Ni,Fi=0;for(Ci=0;Ci<wi.length;Ci++){Ni=(this.words[Ci+yi]|0)+Fi;var Mi=(wi.words[Ci]|0)*xi;Ni-=Mi&67108863,Fi=(Ni>>26)-(Mi/67108864|0),this.words[Ci+yi]=Ni&67108863}for(;Ci<this.length-yi;Ci++)Ni=(this.words[Ci+yi]|0)+Fi,Fi=Ni>>26,this.words[Ci+yi]=Ni&67108863;if(Fi===0)return this.strip();for(n(Fi===-1),Fi=0,Ci=0;Ci<this.length;Ci++)Ni=-(this.words[Ci]|0)+Fi,Fi=Ni>>26,this.words[Ci]=Ni&67108863;return this.negative=1,this.strip()},a.prototype._wordDiv=function(wi,xi){var yi=this.length-wi.length,Ei=this.clone(),Ci=wi,Ni=Ci.words[Ci.length-1]|0,Fi=this._countBits(Ni);yi=26-Fi,yi!==0&&(Ci=Ci.ushln(yi),Ei.iushln(yi),Ni=Ci.words[Ci.length-1]|0);var Mi=Ei.length-Ci.length,Si;if(xi!=="mod"){Si=new a(null),Si.length=Mi+1,Si.words=new Array(Si.length);for(var Ai=0;Ai<Si.length;Ai++)Si.words[Ai]=0}var _i=Ei.clone()._ishlnsubmul(Ci,1,Mi);_i.negative===0&&(Ei=_i,Si&&(Si.words[Mi]=1));for(var Bi=Mi-1;Bi>=0;Bi--){var Pi=(Ei.words[Ci.length+Bi]|0)*67108864+(Ei.words[Ci.length+Bi-1]|0);for(Pi=Math.min(Pi/Ni|0,67108863),Ei._ishlnsubmul(Ci,Pi,Bi);Ei.negative!==0;)Pi--,Ei.negative=0,Ei._ishlnsubmul(Ci,1,Bi),Ei.isZero()||(Ei.negative^=1);Si&&(Si.words[Bi]=Pi)}return Si&&Si.strip(),Ei.strip(),xi!=="div"&&yi!==0&&Ei.iushrn(yi),{div:Si||null,mod:Ei}},a.prototype.divmod=function(wi,xi,yi){if(n(!wi.isZero()),this.isZero())return{div:new a(0),mod:new a(0)};var Ei,Ci,Ni;return this.negative!==0&&wi.negative===0?(Ni=this.neg().divmod(wi,xi),xi!=="mod"&&(Ei=Ni.div.neg()),xi!=="div"&&(Ci=Ni.mod.neg(),yi&&Ci.negative!==0&&Ci.iadd(wi)),{div:Ei,mod:Ci}):this.negative===0&&wi.negative!==0?(Ni=this.divmod(wi.neg(),xi),xi!=="mod"&&(Ei=Ni.div.neg()),{div:Ei,mod:Ni.mod}):(this.negative&wi.negative)!==0?(Ni=this.neg().divmod(wi.neg(),xi),xi!=="div"&&(Ci=Ni.mod.neg(),yi&&Ci.negative!==0&&Ci.isub(wi)),{div:Ni.div,mod:Ci}):wi.length>this.length||this.cmp(wi)<0?{div:new a(0),mod:this}:wi.length===1?xi==="div"?{div:this.divn(wi.words[0]),mod:null}:xi==="mod"?{div:null,mod:new a(this.modn(wi.words[0]))}:{div:this.divn(wi.words[0]),mod:new a(this.modn(wi.words[0]))}:this._wordDiv(wi,xi)},a.prototype.div=function(wi){return this.divmod(wi,"div",!1).div},a.prototype.mod=function(wi){return this.divmod(wi,"mod",!1).mod},a.prototype.umod=function(wi){return this.divmod(wi,"mod",!0).mod},a.prototype.divRound=function(wi){var xi=this.divmod(wi);if(xi.mod.isZero())return xi.div;var yi=xi.div.negative!==0?xi.mod.isub(wi):xi.mod,Ei=wi.ushrn(1),Ci=wi.andln(1),Ni=yi.cmp(Ei);return Ni<0||Ci===1&&Ni===0?xi.div:xi.div.negative!==0?xi.div.isubn(1):xi.div.iaddn(1)},a.prototype.modn=function(wi){n(wi<=67108863);for(var xi=(1<<26)%wi,yi=0,Ei=this.length-1;Ei>=0;Ei--)yi=(xi*yi+(this.words[Ei]|0))%wi;return yi},a.prototype.idivn=function(wi){n(wi<=67108863);for(var xi=0,yi=this.length-1;yi>=0;yi--){var Ei=(this.words[yi]|0)+xi*67108864;this.words[yi]=Ei/wi|0,xi=Ei%wi}return this.strip()},a.prototype.divn=function(wi){return this.clone().idivn(wi)},a.prototype.egcd=function(wi){n(wi.negative===0),n(!wi.isZero());var xi=this,yi=wi.clone();xi.negative!==0?xi=xi.umod(wi):xi=xi.clone();for(var Ei=new a(1),Ci=new a(0),Ni=new a(0),Fi=new a(1),Mi=0;xi.isEven()&&yi.isEven();)xi.iushrn(1),yi.iushrn(1),++Mi;for(var Si=yi.clone(),Ai=xi.clone();!xi.isZero();){for(var _i=0,Bi=1;(xi.words[0]&Bi)===0&&_i<26;++_i,Bi<<=1);if(_i>0)for(xi.iushrn(_i);_i-- >0;)(Ei.isOdd()||Ci.isOdd())&&(Ei.iadd(Si),Ci.isub(Ai)),Ei.iushrn(1),Ci.iushrn(1);for(var Pi=0,zi=1;(yi.words[0]&zi)===0&&Pi<26;++Pi,zi<<=1);if(Pi>0)for(yi.iushrn(Pi);Pi-- >0;)(Ni.isOdd()||Fi.isOdd())&&(Ni.iadd(Si),Fi.isub(Ai)),Ni.iushrn(1),Fi.iushrn(1);xi.cmp(yi)>=0?(xi.isub(yi),Ei.isub(Ni),Ci.isub(Fi)):(yi.isub(xi),Ni.isub(Ei),Fi.isub(Ci))}return{a:Ni,b:Fi,gcd:yi.iushln(Mi)}},a.prototype._invmp=function(wi){n(wi.negative===0),n(!wi.isZero());var xi=this,yi=wi.clone();xi.negative!==0?xi=xi.umod(wi):xi=xi.clone();for(var Ei=new a(1),Ci=new a(0),Ni=yi.clone();xi.cmpn(1)>0&&yi.cmpn(1)>0;){for(var Fi=0,Mi=1;(xi.words[0]&Mi)===0&&Fi<26;++Fi,Mi<<=1);if(Fi>0)for(xi.iushrn(Fi);Fi-- >0;)Ei.isOdd()&&Ei.iadd(Ni),Ei.iushrn(1);for(var Si=0,Ai=1;(yi.words[0]&Ai)===0&&Si<26;++Si,Ai<<=1);if(Si>0)for(yi.iushrn(Si);Si-- >0;)Ci.isOdd()&&Ci.iadd(Ni),Ci.iushrn(1);xi.cmp(yi)>=0?(xi.isub(yi),Ei.isub(Ci)):(yi.isub(xi),Ci.isub(Ei))}var _i;return xi.cmpn(1)===0?_i=Ei:_i=Ci,_i.cmpn(0)<0&&_i.iadd(wi),_i},a.prototype.gcd=function(wi){if(this.isZero())return wi.abs();if(wi.isZero())return this.abs();var xi=this.clone(),yi=wi.clone();xi.negative=0,yi.negative=0;for(var Ei=0;xi.isEven()&&yi.isEven();Ei++)xi.iushrn(1),yi.iushrn(1);do{for(;xi.isEven();)xi.iushrn(1);for(;yi.isEven();)yi.iushrn(1);var Ci=xi.cmp(yi);if(Ci<0){var Ni=xi;xi=yi,yi=Ni}else if(Ci===0||yi.cmpn(1)===0)break;xi.isub(yi)}while(!0);return yi.iushln(Ei)},a.prototype.invm=function(wi){return this.egcd(wi).a.umod(wi)},a.prototype.isEven=function(){return(this.words[0]&1)===0},a.prototype.isOdd=function(){return(this.words[0]&1)===1},a.prototype.andln=function(wi){return this.words[0]&wi},a.prototype.bincn=function(wi){n(typeof wi=="number");var xi=wi%26,yi=(wi-xi)/26,Ei=1<<xi;if(this.length<=yi)return this._expand(yi+1),this.words[yi]|=Ei,this;for(var Ci=Ei,Ni=yi;Ci!==0&&Ni<this.length;Ni++){var Fi=this.words[Ni]|0;Fi+=Ci,Ci=Fi>>>26,Fi&=67108863,this.words[Ni]=Fi}return Ci!==0&&(this.words[Ni]=Ci,this.length++),this},a.prototype.isZero=function(){return this.length===1&&this.words[0]===0},a.prototype.cmpn=function(wi){var xi=wi<0;if(this.negative!==0&&!xi)return-1;if(this.negative===0&&xi)return 1;this.strip();var yi;if(this.length>1)yi=1;else{xi&&(wi=-wi),n(wi<=67108863,"Number is too big");var Ei=this.words[0]|0;yi=Ei===wi?0:Ei<wi?-1:1}return this.negative!==0?-yi|0:yi},a.prototype.cmp=function(wi){if(this.negative!==0&&wi.negative===0)return-1;if(this.negative===0&&wi.negative!==0)return 1;var xi=this.ucmp(wi);return this.negative!==0?-xi|0:xi},a.prototype.ucmp=function(wi){if(this.length>wi.length)return 1;if(this.length<wi.length)return-1;for(var xi=0,yi=this.length-1;yi>=0;yi--){var Ei=this.words[yi]|0,Ci=wi.words[yi]|0;if(Ei!==Ci){Ei<Ci?xi=-1:Ei>Ci&&(xi=1);break}}return xi},a.prototype.gtn=function(wi){return this.cmpn(wi)===1},a.prototype.gt=function(wi){return this.cmp(wi)===1},a.prototype.gten=function(wi){return this.cmpn(wi)>=0},a.prototype.gte=function(wi){return this.cmp(wi)>=0},a.prototype.ltn=function(wi){return this.cmpn(wi)===-1},a.prototype.lt=function(wi){return this.cmp(wi)===-1},a.prototype.lten=function(wi){return this.cmpn(wi)<=0},a.prototype.lte=function(wi){return this.cmp(wi)<=0},a.prototype.eqn=function(wi){return this.cmpn(wi)===0},a.prototype.eq=function(wi){return this.cmp(wi)===0},a.red=function(wi){return new Ui(wi)},a.prototype.toRed=function(wi){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),wi.convertTo(this)._forceRed(wi)},a.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},a.prototype._forceRed=function(wi){return this.red=wi,this},a.prototype.forceRed=function(wi){return n(!this.red,"Already a number in reduction context"),this._forceRed(wi)},a.prototype.redAdd=function(wi){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,wi)},a.prototype.redIAdd=function(wi){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,wi)},a.prototype.redSub=function(wi){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,wi)},a.prototype.redISub=function(wi){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,wi)},a.prototype.redShl=function(wi){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,wi)},a.prototype.redMul=function(wi){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,wi),this.red.mul(this,wi)},a.prototype.redIMul=function(wi){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,wi),this.red.imul(this,wi)},a.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},a.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},a.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},a.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},a.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},a.prototype.redPow=function(wi){return n(this.red&&!wi.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,wi)};var qi={k256:null,p224:null,p192:null,p25519:null};function Oi($i,wi){this.name=$i,this.p=new a(wi,16),this.n=this.p.bitLength(),this.k=new a(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}Oi.prototype._tmp=function(){var wi=new a(null);return wi.words=new Array(Math.ceil(this.n/13)),wi},Oi.prototype.ireduce=function(wi){var xi=wi,yi;do this.split(xi,this.tmp),xi=this.imulK(xi),xi=xi.iadd(this.tmp),yi=xi.bitLength();while(yi>this.n);var Ei=yi<this.n?-1:xi.ucmp(this.p);return Ei===0?(xi.words[0]=0,xi.length=1):Ei>0?xi.isub(this.p):xi.strip!==void 0?xi.strip():xi._strip(),xi},Oi.prototype.split=function(wi,xi){wi.iushrn(this.n,0,xi)},Oi.prototype.imulK=function(wi){return wi.imul(this.k)};function ki(){Oi.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}s(ki,Oi),ki.prototype.split=function(wi,xi){for(var yi=4194303,Ei=Math.min(wi.length,9),Ci=0;Ci<Ei;Ci++)xi.words[Ci]=wi.words[Ci];if(xi.length=Ei,wi.length<=9){wi.words[0]=0,wi.length=1;return}var Ni=wi.words[9];for(xi.words[xi.length++]=Ni&yi,Ci=10;Ci<wi.length;Ci++){var Fi=wi.words[Ci]|0;wi.words[Ci-10]=(Fi&yi)<<4|Ni>>>22,Ni=Fi}Ni>>>=22,wi.words[Ci-10]=Ni,Ni===0&&wi.length>10?wi.length-=10:wi.length-=9},ki.prototype.imulK=function(wi){wi.words[wi.length]=0,wi.words[wi.length+1]=0,wi.length+=2;for(var xi=0,yi=0;yi<wi.length;yi++){var Ei=wi.words[yi]|0;xi+=Ei*977,wi.words[yi]=xi&67108863,xi=Ei*64+(xi/67108864|0)}return wi.words[wi.length-1]===0&&(wi.length--,wi.words[wi.length-1]===0&&wi.length--),wi};function Li(){Oi.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}s(Li,Oi);function ji(){Oi.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}s(ji,Oi);function Hi(){Oi.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}s(Hi,Oi),Hi.prototype.imulK=function(wi){for(var xi=0,yi=0;yi<wi.length;yi++){var Ei=(wi.words[yi]|0)*19+xi,Ci=Ei&67108863;Ei>>>=26,wi.words[yi]=Ci,xi=Ei}return xi!==0&&(wi.words[wi.length++]=xi),wi},a._prime=function(wi){if(qi[wi])return qi[wi];var xi;if(wi==="k256")xi=new ki;else if(wi==="p224")xi=new Li;else if(wi==="p192")xi=new ji;else if(wi==="p25519")xi=new Hi;else throw new Error("Unknown prime "+wi);return qi[wi]=xi,xi};function Ui($i){if(typeof $i=="string"){var wi=a._prime($i);this.m=wi.p,this.prime=wi}else n($i.gtn(1),"modulus must be greater than 1"),this.m=$i,this.prime=null}Ui.prototype._verify1=function(wi){n(wi.negative===0,"red works only with positives"),n(wi.red,"red works only with red numbers")},Ui.prototype._verify2=function(wi,xi){n((wi.negative|xi.negative)===0,"red works only with positives"),n(wi.red&&wi.red===xi.red,"red works only with red numbers")},Ui.prototype.imod=function(wi){return this.prime?this.prime.ireduce(wi)._forceRed(this):wi.umod(this.m)._forceRed(this)},Ui.prototype.neg=function(wi){return wi.isZero()?wi.clone():this.m.sub(wi)._forceRed(this)},Ui.prototype.add=function(wi,xi){this._verify2(wi,xi);var yi=wi.add(xi);return yi.cmp(this.m)>=0&&yi.isub(this.m),yi._forceRed(this)},Ui.prototype.iadd=function(wi,xi){this._verify2(wi,xi);var yi=wi.iadd(xi);return yi.cmp(this.m)>=0&&yi.isub(this.m),yi},Ui.prototype.sub=function(wi,xi){this._verify2(wi,xi);var yi=wi.sub(xi);return yi.cmpn(0)<0&&yi.iadd(this.m),yi._forceRed(this)},Ui.prototype.isub=function(wi,xi){this._verify2(wi,xi);var yi=wi.isub(xi);return yi.cmpn(0)<0&&yi.iadd(this.m),yi},Ui.prototype.shl=function(wi,xi){return this._verify1(wi),this.imod(wi.ushln(xi))},Ui.prototype.imul=function(wi,xi){return this._verify2(wi,xi),this.imod(wi.imul(xi))},Ui.prototype.mul=function(wi,xi){return this._verify2(wi,xi),this.imod(wi.mul(xi))},Ui.prototype.isqr=function(wi){return this.imul(wi,wi.clone())},Ui.prototype.sqr=function(wi){return this.mul(wi,wi)},Ui.prototype.sqrt=function(wi){if(wi.isZero())return wi.clone();var xi=this.m.andln(3);if(n(xi%2===1),xi===3){var yi=this.m.add(new a(1)).iushrn(2);return this.pow(wi,yi)}for(var Ei=this.m.subn(1),Ci=0;!Ei.isZero()&&Ei.andln(1)===0;)Ci++,Ei.iushrn(1);n(!Ei.isZero());var Ni=new a(1).toRed(this),Fi=Ni.redNeg(),Mi=this.m.subn(1).iushrn(1),Si=this.m.bitLength();for(Si=new a(2*Si*Si).toRed(this);this.pow(Si,Mi).cmp(Fi)!==0;)Si.redIAdd(Fi);for(var Ai=this.pow(Si,Ei),_i=this.pow(wi,Ei.addn(1).iushrn(1)),Bi=this.pow(wi,Ei),Pi=Ci;Bi.cmp(Ni)!==0;){for(var zi=Bi,Gi=0;zi.cmp(Ni)!==0;Gi++)zi=zi.redSqr();n(Gi<Pi);var Vi=this.pow(Ai,new a(1).iushln(Pi-Gi-1));_i=_i.redMul(Vi),Ai=Vi.redSqr(),Bi=Bi.redMul(Ai),Pi=Gi}return _i},Ui.prototype.invm=function(wi){var xi=wi._invmp(this.m);return xi.negative!==0?(xi.negative=0,this.imod(xi).redNeg()):this.imod(xi)},Ui.prototype.pow=function(wi,xi){if(xi.isZero())return new a(1).toRed(this);if(xi.cmpn(1)===0)return wi.clone();var yi=4,Ei=new Array(1<<yi);Ei[0]=new a(1).toRed(this),Ei[1]=wi;for(var Ci=2;Ci<Ei.length;Ci++)Ei[Ci]=this.mul(Ei[Ci-1],wi);var Ni=Ei[0],Fi=0,Mi=0,Si=xi.bitLength()%26;for(Si===0&&(Si=26),Ci=xi.length-1;Ci>=0;Ci--){for(var Ai=xi.words[Ci],_i=Si-1;_i>=0;_i--){var Bi=Ai>>_i&1;if(Ni!==Ei[0]&&(Ni=this.sqr(Ni)),Bi===0&&Fi===0){Mi=0;continue}Fi<<=1,Fi|=Bi,Mi++,!(Mi!==yi&&(Ci!==0||_i!==0))&&(Ni=this.mul(Ni,Ei[Fi]),Mi=0,Fi=0)}Si=26}return Ni},Ui.prototype.convertTo=function(wi){var xi=wi.umod(this.m);return xi===wi?xi.clone():xi},Ui.prototype.convertFrom=function(wi){var xi=wi.clone();return xi.red=null,xi},a.mont=function(wi){return new Qi(wi)};function Qi($i){Ui.call(this,$i),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new a(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}s(Qi,Ui),Qi.prototype.convertTo=function(wi){return this.imod(wi.ushln(this.shift))},Qi.prototype.convertFrom=function(wi){var xi=this.imod(wi.mul(this.rinv));return xi.red=null,xi},Qi.prototype.imul=function(wi,xi){if(wi.isZero()||xi.isZero())return wi.words[0]=0,wi.length=1,wi;var yi=wi.imul(xi),Ei=yi.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Ci=yi.isub(Ei).iushrn(this.shift),Ni=Ci;return Ci.cmp(this.m)>=0?Ni=Ci.isub(this.m):Ci.cmpn(0)<0&&(Ni=Ci.iadd(this.m)),Ni._forceRed(this)},Qi.prototype.mul=function(wi,xi){if(wi.isZero()||xi.isZero())return new a(0)._forceRed(this);var yi=wi.mul(xi),Ei=yi.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Ci=yi.isub(Ei).iushrn(this.shift),Ni=Ci;return Ci.cmp(this.m)>=0?Ni=Ci.isub(this.m):Ci.cmpn(0)<0&&(Ni=Ci.iadd(this.m)),Ni._forceRed(this)},Qi.prototype.invm=function(wi){var xi=this.imod(wi._invmp(this.m).mul(this.r2));return xi._forceRed(this)}})(r,bn$4)}(bn$5)),bn$5.exports}var brorand={exports:{}},hasRequiredBrorand;function requireBrorand(){if(hasRequiredBrorand)return brorand.exports;hasRequiredBrorand=1;var r;brorand.exports=function(s){return r||(r=new t(null)),r.generate(s)};function t(n){this.rand=n}if(brorand.exports.Rand=t,t.prototype.generate=function(s){return this._rand(s)},t.prototype._rand=function(s){if(this.rand.getBytes)return this.rand.getBytes(s);for(var a=new Uint8Array(s),h=0;h<a.length;h++)a[h]=this.rand.getByte();return a},typeof self=="object")self.crypto&&self.crypto.getRandomValues?t.prototype._rand=function(s){var a=new Uint8Array(s);return self.crypto.getRandomValues(a),a}:self.msCrypto&&self.msCrypto.getRandomValues?t.prototype._rand=function(s){var a=new Uint8Array(s);return self.msCrypto.getRandomValues(a),a}:typeof window=="object"&&(t.prototype._rand=function(){throw new Error("Not implemented yet")});else try{var i=requireCryptoBrowserify();if(typeof i.randomBytes!="function")throw new Error("Not supported");t.prototype._rand=function(s){return i.randomBytes(s)}}catch{}return brorand.exports}var mr,hasRequiredMr;function requireMr(){if(hasRequiredMr)return mr;hasRequiredMr=1;var r=requireBn$2(),t=requireBrorand();function i(n){this.rand=n||new t.Rand}return mr=i,i.create=function(s){return new i(s)},i.prototype._randbelow=function(s){var a=s.bitLength(),h=Math.ceil(a/8);do var v=new r(this.rand.generate(h));while(v.cmp(s)>=0);return v},i.prototype._randrange=function(s,a){var h=a.sub(s);return s.add(this._randbelow(h))},i.prototype.test=function(s,a,h){var v=s.bitLength(),hi=r.mont(s),u=new r(1).toRed(hi);a||(a=Math.max(1,v/48|0));for(var l=s.subn(1),vi=0;!l.testn(vi);vi++);for(var D=s.shrn(vi),mi=l.toRed(hi),gi=!0;a>0;a--){var bi=this._randrange(new r(2),l);h&&h(bi);var Ri=bi.toRed(hi).redPow(D);if(!(Ri.cmp(u)===0||Ri.cmp(mi)===0)){for(var Ti=1;Ti<vi;Ti++){if(Ri=Ri.redSqr(),Ri.cmp(u)===0)return!1;if(Ri.cmp(mi)===0)break}if(Ti===vi)return!1}}return gi},i.prototype.getDivisor=function(s,a){var h=s.bitLength(),v=r.mont(s),hi=new r(1).toRed(v);a||(a=Math.max(1,h/48|0));for(var u=s.subn(1),l=0;!u.testn(l);l++);for(var vi=s.shrn(l),D=u.toRed(v);a>0;a--){var mi=this._randrange(new r(2),u),gi=s.gcd(mi);if(gi.cmpn(1)!==0)return gi;var bi=mi.toRed(v).redPow(vi);if(!(bi.cmp(hi)===0||bi.cmp(D)===0)){for(var Ri=1;Ri<l;Ri++){if(bi=bi.redSqr(),bi.cmp(hi)===0)return bi.fromRed().subn(1).gcd(s);if(bi.cmp(D)===0)break}if(Ri===l)return bi=bi.redSqr(),bi.fromRed().subn(1).gcd(s)}}return!1},mr}var generatePrime,hasRequiredGeneratePrime;function requireGeneratePrime(){if(hasRequiredGeneratePrime)return generatePrime;hasRequiredGeneratePrime=1;var r=requireBrowser$b();generatePrime=Ri,Ri.simpleSieve=gi,Ri.fermatTest=bi;var t=requireBn$2(),i=new t(24),n=requireMr(),s=new n,a=new t(1),h=new t(2),v=new t(5);new t(16),new t(8);var hi=new t(10),u=new t(3);new t(7);var l=new t(11),vi=new t(4);new t(12);var D=null;function mi(){if(D!==null)return D;var Ti=1048576,Ii=[];Ii[0]=2;for(var qi=1,Oi=3;Oi<Ti;Oi+=2){for(var ki=Math.ceil(Math.sqrt(Oi)),Li=0;Li<qi&&Ii[Li]<=ki&&Oi%Ii[Li]!==0;Li++);qi!==Li&&Ii[Li]<=ki||(Ii[qi++]=Oi)}return D=Ii,Ii}function gi(Ti){for(var Ii=mi(),qi=0;qi<Ii.length;qi++)if(Ti.modn(Ii[qi])===0)return Ti.cmpn(Ii[qi])===0;return!0}function bi(Ti){var Ii=t.mont(Ti);return h.toRed(Ii).redPow(Ti.subn(1)).fromRed().cmpn(1)===0}function Ri(Ti,Ii){if(Ti<16)return Ii===2||Ii===5?new t([140,123]):new t([140,39]);Ii=new t(Ii);for(var qi,Oi;;){for(qi=new t(r(Math.ceil(Ti/8)));qi.bitLength()>Ti;)qi.ishrn(1);if(qi.isEven()&&qi.iadd(a),qi.testn(1)||qi.iadd(h),Ii.cmp(h)){if(!Ii.cmp(v))for(;qi.mod(hi).cmp(u);)qi.iadd(vi)}else for(;qi.mod(i).cmp(l);)qi.iadd(vi);if(Oi=qi.shrn(1),gi(Oi)&&gi(qi)&&bi(Oi)&&bi(qi)&&s.test(Oi)&&s.test(qi))return qi}}return generatePrime}const modp1={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a63a3620ffffffffffffffff"},modp2={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece65381ffffffffffffffff"},modp5={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca237327ffffffffffffffff"},modp14={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aacaa68ffffffffffffffff"},modp15={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a93ad2caffffffffffffffff"},modp16={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c934063199ffffffffffffffff"},modp17={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dcc4024ffffffffffffffff"},modp18={gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dbe115974a3926f12fee5e438777cb6a932df8cd8bec4d073b931ba3bc832b68d9dd300741fa7bf8afc47ed2576f6936ba424663aab639c5ae4f5683423b4742bf1c978238f16cbe39d652de3fdb8befc848ad922222e04a4037c0713eb57a81a23f0c73473fc646cea306b4bcbc8862f8385ddfa9d4b7fa2c087e879683303ed5bdd3a062b3cf5b3a278a66d2a13f83f44f82ddf310ee074ab6a364597e899a0255dc164f31cc50846851df9ab48195ded7ea1b1d510bd7ee74d73faf36bc31ecfa268359046f4eb879f924009438b481c6cd7889a002ed5ee382bc9190da6fc026e479558e4475677e9aa9e3050e2765694dfc81f56e880b96e7160c980dd98edd3dfffffffffffffffff"};var require$$1$1={modp1,modp2,modp5,modp14,modp15,modp16,modp17,modp18},dh,hasRequiredDh;function requireDh(){if(hasRequiredDh)return dh;hasRequiredDh=1;var r=requireBn$2(),t=requireMr(),i=new t,n=new r(24),s=new r(11),a=new r(10),h=new r(3),v=new r(7),hi=requireGeneratePrime(),u=requireBrowser$b();dh=gi;function l(Ri,Ti){return Ti=Ti||"utf8",Buffer.isBuffer(Ri)||(Ri=new Buffer(Ri,Ti)),this._pub=new r(Ri),this}function vi(Ri,Ti){return Ti=Ti||"utf8",Buffer.isBuffer(Ri)||(Ri=new Buffer(Ri,Ti)),this._priv=new r(Ri),this}var D={};function mi(Ri,Ti){var Ii=Ti.toString("hex"),qi=[Ii,Ri.toString(16)].join("_");if(qi in D)return D[qi];var Oi=0;if(Ri.isEven()||!hi.simpleSieve||!hi.fermatTest(Ri)||!i.test(Ri))return Oi+=1,Ii==="02"||Ii==="05"?Oi+=8:Oi+=4,D[qi]=Oi,Oi;i.test(Ri.shrn(1))||(Oi+=2);var ki;switch(Ii){case"02":Ri.mod(n).cmp(s)&&(Oi+=8);break;case"05":ki=Ri.mod(a),ki.cmp(h)&&ki.cmp(v)&&(Oi+=8);break;default:Oi+=4}return D[qi]=Oi,Oi}function gi(Ri,Ti,Ii){this.setGenerator(Ti),this.__prime=new r(Ri),this._prime=r.mont(this.__prime),this._primeLen=Ri.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,Ii?(this.setPublicKey=l,this.setPrivateKey=vi):this._primeCode=8}Object.defineProperty(gi.prototype,"verifyError",{enumerable:!0,get:function(){return typeof this._primeCode!="number"&&(this._primeCode=mi(this.__prime,this.__gen)),this._primeCode}}),gi.prototype.generateKeys=function(){return this._priv||(this._priv=new r(u(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},gi.prototype.computeSecret=function(Ri){Ri=new r(Ri),Ri=Ri.toRed(this._prime);var Ti=Ri.redPow(this._priv).fromRed(),Ii=new Buffer(Ti.toArray()),qi=this.getPrime();if(Ii.length<qi.length){var Oi=new Buffer(qi.length-Ii.length);Oi.fill(0),Ii=Buffer.concat([Oi,Ii])}return Ii},gi.prototype.getPublicKey=function(Ti){return bi(this._pub,Ti)},gi.prototype.getPrivateKey=function(Ti){return bi(this._priv,Ti)},gi.prototype.getPrime=function(Ri){return bi(this.__prime,Ri)},gi.prototype.getGenerator=function(Ri){return bi(this._gen,Ri)},gi.prototype.setGenerator=function(Ri,Ti){return Ti=Ti||"utf8",Buffer.isBuffer(Ri)||(Ri=new Buffer(Ri,Ti)),this.__gen=Ri,this._gen=new r(Ri),this};function bi(Ri,Ti){var Ii=new Buffer(Ri.toArray());return Ti?Ii.toString(Ti):Ii}return dh}var hasRequiredBrowser$5;function requireBrowser$5(){if(hasRequiredBrowser$5)return browser$5;hasRequiredBrowser$5=1;var r=requireGeneratePrime(),t=require$$1$1,i=requireDh();function n(h){var v=new Buffer(t[h].prime,"hex"),hi=new Buffer(t[h].gen,"hex");return new i(v,hi)}var s={binary:!0,hex:!0,base64:!0};function a(h,v,hi,u){return Buffer.isBuffer(v)||s[v]===void 0?a(h,"binary",v,hi):(v=v||"binary",u=u||"binary",hi=hi||new Buffer([2]),Buffer.isBuffer(hi)||(hi=new Buffer(hi,u)),typeof h=="number"?new i(r(h,hi),hi,!0):(Buffer.isBuffer(h)||(h=new Buffer(h,v)),new i(h,hi,!0)))}return browser$5.DiffieHellmanGroup=browser$5.createDiffieHellmanGroup=browser$5.getDiffieHellman=n,browser$5.createDiffieHellman=browser$5.DiffieHellman=a,browser$5}var readableBrowser={exports:{}},processNextickArgs={exports:{}},hasRequiredProcessNextickArgs;function requireProcessNextickArgs(){if(hasRequiredProcessNextickArgs)return processNextickArgs.exports;hasRequiredProcessNextickArgs=1,typeof process$1>"u"||!process$1.version||process$1.version.indexOf("v0.")===0||process$1.version.indexOf("v1.")===0&&process$1.version.indexOf("v1.8.")!==0?processNextickArgs.exports={nextTick:r}:processNextickArgs.exports=process$1;function r(t,i,n,s){if(typeof t!="function")throw new TypeError('"callback" argument must be a function');var a=arguments.length,h,v;switch(a){case 0:case 1:return process$1.nextTick(t);case 2:return process$1.nextTick(function(){t.call(null,i)});case 3:return process$1.nextTick(function(){t.call(null,i,n)});case 4:return process$1.nextTick(function(){t.call(null,i,n,s)});default:for(h=new Array(a-1),v=0;v<h.length;)h[v++]=arguments[v];return process$1.nextTick(function(){t.apply(null,h)})}}return processNextickArgs.exports}var isarray,hasRequiredIsarray;function requireIsarray(){if(hasRequiredIsarray)return isarray;hasRequiredIsarray=1;var r={}.toString;return isarray=Array.isArray||function(t){return r.call(t)=="[object Array]"},isarray}var streamBrowser,hasRequiredStreamBrowser;function requireStreamBrowser(){return hasRequiredStreamBrowser||(hasRequiredStreamBrowser=1,streamBrowser=requireEvents().EventEmitter),streamBrowser}var safeBuffer={exports:{}},hasRequiredSafeBuffer;function requireSafeBuffer(){return hasRequiredSafeBuffer||(hasRequiredSafeBuffer=1,function(r,t){var i=requireDist(),n=i.Buffer;function s(h,v){for(var hi in h)v[hi]=h[hi]}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?r.exports=i:(s(i,t),t.Buffer=a);function a(h,v,hi){return n(h,v,hi)}s(n,a),a.from=function(h,v,hi){if(typeof h=="number")throw new TypeError("Argument must not be a number");return n(h,v,hi)},a.alloc=function(h,v,hi){if(typeof h!="number")throw new TypeError("Argument must be a number");var u=n(h);return v!==void 0?typeof hi=="string"?u.fill(v,hi):u.fill(v):u.fill(0),u},a.allocUnsafe=function(h){if(typeof h!="number")throw new TypeError("Argument must be a number");return n(h)},a.allocUnsafeSlow=function(h){if(typeof h!="number")throw new TypeError("Argument must be a number");return i.SlowBuffer(h)}}(safeBuffer,safeBuffer.exports)),safeBuffer.exports}var util={},hasRequiredUtil;function requireUtil(){if(hasRequiredUtil)return util;hasRequiredUtil=1;function r(bi){return Array.isArray?Array.isArray(bi):gi(bi)==="[object Array]"}util.isArray=r;function t(bi){return typeof bi=="boolean"}util.isBoolean=t;function i(bi){return bi===null}util.isNull=i;function n(bi){return bi==null}util.isNullOrUndefined=n;function s(bi){return typeof bi=="number"}util.isNumber=s;function a(bi){return typeof bi=="string"}util.isString=a;function h(bi){return typeof bi=="symbol"}util.isSymbol=h;function v(bi){return bi===void 0}util.isUndefined=v;function hi(bi){return gi(bi)==="[object RegExp]"}util.isRegExp=hi;function u(bi){return typeof bi=="object"&&bi!==null}util.isObject=u;function l(bi){return gi(bi)==="[object Date]"}util.isDate=l;function vi(bi){return gi(bi)==="[object Error]"||bi instanceof Error}util.isError=vi;function D(bi){return typeof bi=="function"}util.isFunction=D;function mi(bi){return bi===null||typeof bi=="boolean"||typeof bi=="number"||typeof bi=="string"||typeof bi=="symbol"||typeof bi>"u"}util.isPrimitive=mi,util.isBuffer=requireDist().Buffer.isBuffer;function gi(bi){return Object.prototype.toString.call(bi)}return util}var BufferList={exports:{}},hasRequiredBufferList;function requireBufferList(){return hasRequiredBufferList||(hasRequiredBufferList=1,function(r){function t(a,h){if(!(a instanceof h))throw new TypeError("Cannot call a class as a function")}var i=requireSafeBuffer().Buffer,n=requireUtil$1();function s(a,h,v){a.copy(h,v)}r.exports=function(){function a(){t(this,a),this.head=null,this.tail=null,this.length=0}return a.prototype.push=function(v){var hi={data:v,next:null};this.length>0?this.tail.next=hi:this.head=hi,this.tail=hi,++this.length},a.prototype.unshift=function(v){var hi={data:v,next:this.head};this.length===0&&(this.tail=hi),this.head=hi,++this.length},a.prototype.shift=function(){if(this.length!==0){var v=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,v}},a.prototype.clear=function(){this.head=this.tail=null,this.length=0},a.prototype.join=function(v){if(this.length===0)return"";for(var hi=this.head,u=""+hi.data;hi=hi.next;)u+=v+hi.data;return u},a.prototype.concat=function(v){if(this.length===0)return i.alloc(0);for(var hi=i.allocUnsafe(v>>>0),u=this.head,l=0;u;)s(u.data,hi,l),l+=u.data.length,u=u.next;return hi},a}(),n&&n.inspect&&n.inspect.custom&&(r.exports.prototype[n.inspect.custom]=function(){var a=n.inspect({length:this.length});return this.constructor.name+" "+a})}(BufferList)),BufferList.exports}var destroy_1,hasRequiredDestroy;function requireDestroy(){if(hasRequiredDestroy)return destroy_1;hasRequiredDestroy=1;var r=requireProcessNextickArgs();function t(s,a){var h=this,v=this._readableState&&this._readableState.destroyed,hi=this._writableState&&this._writableState.destroyed;return v||hi?(a?a(s):s&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,r.nextTick(n,this,s)):r.nextTick(n,this,s)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(s||null,function(u){!a&&u?h._writableState?h._writableState.errorEmitted||(h._writableState.errorEmitted=!0,r.nextTick(n,h,u)):r.nextTick(n,h,u):a&&a(u)}),this)}function i(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function n(s,a){s.emit("error",a)}return destroy_1={destroy:t,undestroy:i},destroy_1}var _stream_writable,hasRequired_stream_writable;function require_stream_writable(){if(hasRequired_stream_writable)return _stream_writable;hasRequired_stream_writable=1;var r=requireProcessNextickArgs();_stream_writable=bi;function t(Ni){var Fi=this;this.next=null,this.entry=null,this.finish=function(){Ci(Fi,Ni)}}var i=!process$1.browser&&["v0.10","v0.9."].indexOf(process$1.version.slice(0,5))>-1?setImmediate:r.nextTick,n;bi.WritableState=mi;var s=Object.create(requireUtil());s.inherits=requireInherits_browser();var a={deprecate:requireBrowser$c()},h=requireStreamBrowser(),v=requireSafeBuffer().Buffer,hi=(typeof commonjsGlobal<"u"?commonjsGlobal:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function u(Ni){return v.from(Ni)}function l(Ni){return v.isBuffer(Ni)||Ni instanceof hi}var vi=requireDestroy();s.inherits(bi,h);function D(){}function mi(Ni,Fi){n=n||require_stream_duplex(),Ni=Ni||{};var Mi=Fi instanceof n;this.objectMode=!!Ni.objectMode,Mi&&(this.objectMode=this.objectMode||!!Ni.writableObjectMode);var Si=Ni.highWaterMark,Ai=Ni.writableHighWaterMark,_i=this.objectMode?16:16*1024;Si||Si===0?this.highWaterMark=Si:Mi&&(Ai||Ai===0)?this.highWaterMark=Ai:this.highWaterMark=_i,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var Bi=Ni.decodeStrings===!1;this.decodeStrings=!Bi,this.defaultEncoding=Ni.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(Pi){ji(Fi,Pi)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new t(this)}mi.prototype.getBuffer=function(){for(var Fi=this.bufferedRequest,Mi=[];Fi;)Mi.push(Fi),Fi=Fi.next;return Mi},function(){try{Object.defineProperty(mi.prototype,"buffer",{get:a.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}}();var gi;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(gi=Function.prototype[Symbol.hasInstance],Object.defineProperty(bi,Symbol.hasInstance,{value:function(Ni){return gi.call(this,Ni)?!0:this!==bi?!1:Ni&&Ni._writableState instanceof mi}})):gi=function(Ni){return Ni instanceof this};function bi(Ni){if(n=n||require_stream_duplex(),!gi.call(bi,this)&&!(this instanceof n))return new bi(Ni);this._writableState=new mi(Ni,this),this.writable=!0,Ni&&(typeof Ni.write=="function"&&(this._write=Ni.write),typeof Ni.writev=="function"&&(this._writev=Ni.writev),typeof Ni.destroy=="function"&&(this._destroy=Ni.destroy),typeof Ni.final=="function"&&(this._final=Ni.final)),h.call(this)}bi.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))};function Ri(Ni,Fi){var Mi=new Error("write after end");Ni.emit("error",Mi),r.nextTick(Fi,Mi)}function Ti(Ni,Fi,Mi,Si){var Ai=!0,_i=!1;return Mi===null?_i=new TypeError("May not write null values to stream"):typeof Mi!="string"&&Mi!==void 0&&!Fi.objectMode&&(_i=new TypeError("Invalid non-string/buffer chunk")),_i&&(Ni.emit("error",_i),r.nextTick(Si,_i),Ai=!1),Ai}bi.prototype.write=function(Ni,Fi,Mi){var Si=this._writableState,Ai=!1,_i=!Si.objectMode&&l(Ni);return _i&&!v.isBuffer(Ni)&&(Ni=u(Ni)),typeof Fi=="function"&&(Mi=Fi,Fi=null),_i?Fi="buffer":Fi||(Fi=Si.defaultEncoding),typeof Mi!="function"&&(Mi=D),Si.ended?Ri(this,Mi):(_i||Ti(this,Si,Ni,Mi))&&(Si.pendingcb++,Ai=qi(this,Si,_i,Ni,Fi,Mi)),Ai},bi.prototype.cork=function(){var Ni=this._writableState;Ni.corked++},bi.prototype.uncork=function(){var Ni=this._writableState;Ni.corked&&(Ni.corked--,!Ni.writing&&!Ni.corked&&!Ni.bufferProcessing&&Ni.bufferedRequest&&Qi(this,Ni))},bi.prototype.setDefaultEncoding=function(Fi){if(typeof Fi=="string"&&(Fi=Fi.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((Fi+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+Fi);return this._writableState.defaultEncoding=Fi,this};function Ii(Ni,Fi,Mi){return!Ni.objectMode&&Ni.decodeStrings!==!1&&typeof Fi=="string"&&(Fi=v.from(Fi,Mi)),Fi}Object.defineProperty(bi.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function qi(Ni,Fi,Mi,Si,Ai,_i){if(!Mi){var Bi=Ii(Fi,Si,Ai);Si!==Bi&&(Mi=!0,Ai="buffer",Si=Bi)}var Pi=Fi.objectMode?1:Si.length;Fi.length+=Pi;var zi=Fi.length<Fi.highWaterMark;if(zi||(Fi.needDrain=!0),Fi.writing||Fi.corked){var Gi=Fi.lastBufferedRequest;Fi.lastBufferedRequest={chunk:Si,encoding:Ai,isBuf:Mi,callback:_i,next:null},Gi?Gi.next=Fi.lastBufferedRequest:Fi.bufferedRequest=Fi.lastBufferedRequest,Fi.bufferedRequestCount+=1}else Oi(Ni,Fi,!1,Pi,Si,Ai,_i);return zi}function Oi(Ni,Fi,Mi,Si,Ai,_i,Bi){Fi.writelen=Si,Fi.writecb=Bi,Fi.writing=!0,Fi.sync=!0,Mi?Ni._writev(Ai,Fi.onwrite):Ni._write(Ai,_i,Fi.onwrite),Fi.sync=!1}function ki(Ni,Fi,Mi,Si,Ai){--Fi.pendingcb,Mi?(r.nextTick(Ai,Si),r.nextTick(yi,Ni,Fi),Ni._writableState.errorEmitted=!0,Ni.emit("error",Si)):(Ai(Si),Ni._writableState.errorEmitted=!0,Ni.emit("error",Si),yi(Ni,Fi))}function Li(Ni){Ni.writing=!1,Ni.writecb=null,Ni.length-=Ni.writelen,Ni.writelen=0}function ji(Ni,Fi){var Mi=Ni._writableState,Si=Mi.sync,Ai=Mi.writecb;if(Li(Mi),Fi)ki(Ni,Mi,Si,Fi,Ai);else{var _i=$i(Mi);!_i&&!Mi.corked&&!Mi.bufferProcessing&&Mi.bufferedRequest&&Qi(Ni,Mi),Si?i(Hi,Ni,Mi,_i,Ai):Hi(Ni,Mi,_i,Ai)}}function Hi(Ni,Fi,Mi,Si){Mi||Ui(Ni,Fi),Fi.pendingcb--,Si(),yi(Ni,Fi)}function Ui(Ni,Fi){Fi.length===0&&Fi.needDrain&&(Fi.needDrain=!1,Ni.emit("drain"))}function Qi(Ni,Fi){Fi.bufferProcessing=!0;var Mi=Fi.bufferedRequest;if(Ni._writev&&Mi&&Mi.next){var Si=Fi.bufferedRequestCount,Ai=new Array(Si),_i=Fi.corkedRequestsFree;_i.entry=Mi;for(var Bi=0,Pi=!0;Mi;)Ai[Bi]=Mi,Mi.isBuf||(Pi=!1),Mi=Mi.next,Bi+=1;Ai.allBuffers=Pi,Oi(Ni,Fi,!0,Fi.length,Ai,"",_i.finish),Fi.pendingcb++,Fi.lastBufferedRequest=null,_i.next?(Fi.corkedRequestsFree=_i.next,_i.next=null):Fi.corkedRequestsFree=new t(Fi),Fi.bufferedRequestCount=0}else{for(;Mi;){var zi=Mi.chunk,Gi=Mi.encoding,Vi=Mi.callback,Ki=Fi.objectMode?1:zi.length;if(Oi(Ni,Fi,!1,Ki,zi,Gi,Vi),Mi=Mi.next,Fi.bufferedRequestCount--,Fi.writing)break}Mi===null&&(Fi.lastBufferedRequest=null)}Fi.bufferedRequest=Mi,Fi.bufferProcessing=!1}bi.prototype._write=function(Ni,Fi,Mi){Mi(new Error("_write() is not implemented"))},bi.prototype._writev=null,bi.prototype.end=function(Ni,Fi,Mi){var Si=this._writableState;typeof Ni=="function"?(Mi=Ni,Ni=null,Fi=null):typeof Fi=="function"&&(Mi=Fi,Fi=null),Ni!=null&&this.write(Ni,Fi),Si.corked&&(Si.corked=1,this.uncork()),Si.ending||Ei(this,Si,Mi)};function $i(Ni){return Ni.ending&&Ni.length===0&&Ni.bufferedRequest===null&&!Ni.finished&&!Ni.writing}function wi(Ni,Fi){Ni._final(function(Mi){Fi.pendingcb--,Mi&&Ni.emit("error",Mi),Fi.prefinished=!0,Ni.emit("prefinish"),yi(Ni,Fi)})}function xi(Ni,Fi){!Fi.prefinished&&!Fi.finalCalled&&(typeof Ni._final=="function"?(Fi.pendingcb++,Fi.finalCalled=!0,r.nextTick(wi,Ni,Fi)):(Fi.prefinished=!0,Ni.emit("prefinish")))}function yi(Ni,Fi){var Mi=$i(Fi);return Mi&&(xi(Ni,Fi),Fi.pendingcb===0&&(Fi.finished=!0,Ni.emit("finish"))),Mi}function Ei(Ni,Fi,Mi){Fi.ending=!0,yi(Ni,Fi),Mi&&(Fi.finished?r.nextTick(Mi):Ni.once("finish",Mi)),Fi.ended=!0,Ni.writable=!1}function Ci(Ni,Fi,Mi){var Si=Ni.entry;for(Ni.entry=null;Si;){var Ai=Si.callback;Fi.pendingcb--,Ai(Mi),Si=Si.next}Fi.corkedRequestsFree.next=Ni}return Object.defineProperty(bi.prototype,"destroyed",{get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(Ni){this._writableState&&(this._writableState.destroyed=Ni)}}),bi.prototype.destroy=vi.destroy,bi.prototype._undestroy=vi.undestroy,bi.prototype._destroy=function(Ni,Fi){this.end(),Fi(Ni)},_stream_writable}var _stream_duplex,hasRequired_stream_duplex;function require_stream_duplex(){if(hasRequired_stream_duplex)return _stream_duplex;hasRequired_stream_duplex=1;var r=requireProcessNextickArgs(),t=Object.keys||function(vi){var D=[];for(var mi in vi)D.push(mi);return D};_stream_duplex=hi;var i=Object.create(requireUtil());i.inherits=requireInherits_browser();var n=require_stream_readable(),s=require_stream_writable();i.inherits(hi,n);for(var a=t(s.prototype),h=0;h<a.length;h++){var v=a[h];hi.prototype[v]||(hi.prototype[v]=s.prototype[v])}function hi(vi){if(!(this instanceof hi))return new hi(vi);n.call(this,vi),s.call(this,vi),vi&&vi.readable===!1&&(this.readable=!1),vi&&vi.writable===!1&&(this.writable=!1),this.allowHalfOpen=!0,vi&&vi.allowHalfOpen===!1&&(this.allowHalfOpen=!1),this.once("end",u)}Object.defineProperty(hi.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function u(){this.allowHalfOpen||this._writableState.ended||r.nextTick(l,this)}function l(vi){vi.end()}return Object.defineProperty(hi.prototype,"destroyed",{get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(vi){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=vi,this._writableState.destroyed=vi)}}),hi.prototype._destroy=function(vi,D){this.push(null),this.end(),r.nextTick(D,vi)},_stream_duplex}var _stream_readable,hasRequired_stream_readable;function require_stream_readable(){if(hasRequired_stream_readable)return _stream_readable;hasRequired_stream_readable=1;var r=requireProcessNextickArgs();_stream_readable=Ii;var t=requireIsarray(),i;Ii.ReadableState=Ti,requireEvents().EventEmitter;var n=function(Vi,Ki){return Vi.listeners(Ki).length},s=requireStreamBrowser(),a=requireSafeBuffer().Buffer,h=(typeof commonjsGlobal<"u"?commonjsGlobal:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){};function v(Vi){return a.from(Vi)}function hi(Vi){return a.isBuffer(Vi)||Vi instanceof h}var u=Object.create(requireUtil());u.inherits=requireInherits_browser();var l=requireUtil$1(),vi=void 0;l&&l.debuglog?vi=l.debuglog("stream"):vi=function(){};var D=requireBufferList(),mi=requireDestroy(),gi;u.inherits(Ii,s);var bi=["error","close","destroy","pause","resume"];function Ri(Vi,Ki,Zi){if(typeof Vi.prependListener=="function")return Vi.prependListener(Ki,Zi);!Vi._events||!Vi._events[Ki]?Vi.on(Ki,Zi):t(Vi._events[Ki])?Vi._events[Ki].unshift(Zi):Vi._events[Ki]=[Zi,Vi._events[Ki]]}function Ti(Vi,Ki){i=i||require_stream_duplex(),Vi=Vi||{};var Zi=Ki instanceof i;this.objectMode=!!Vi.objectMode,Zi&&(this.objectMode=this.objectMode||!!Vi.readableObjectMode);var In=Vi.highWaterMark,Ji=Vi.readableHighWaterMark,Xi=this.objectMode?16:16*1024;In||In===0?this.highWaterMark=In:Zi&&(Ji||Ji===0)?this.highWaterMark=Ji:this.highWaterMark=Xi,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new D,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=Vi.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,Vi.encoding&&(gi||(gi=requireString_decoder().StringDecoder),this.decoder=new gi(Vi.encoding),this.encoding=Vi.encoding)}function Ii(Vi){if(i=i||require_stream_duplex(),!(this instanceof Ii))return new Ii(Vi);this._readableState=new Ti(Vi,this),this.readable=!0,Vi&&(typeof Vi.read=="function"&&(this._read=Vi.read),typeof Vi.destroy=="function"&&(this._destroy=Vi.destroy)),s.call(this)}Object.defineProperty(Ii.prototype,"destroyed",{get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(Vi){this._readableState&&(this._readableState.destroyed=Vi)}}),Ii.prototype.destroy=mi.destroy,Ii.prototype._undestroy=mi.undestroy,Ii.prototype._destroy=function(Vi,Ki){this.push(null),Ki(Vi)},Ii.prototype.push=function(Vi,Ki){var Zi=this._readableState,In;return Zi.objectMode?In=!0:typeof Vi=="string"&&(Ki=Ki||Zi.defaultEncoding,Ki!==Zi.encoding&&(Vi=a.from(Vi,Ki),Ki=""),In=!0),qi(this,Vi,Ki,!1,In)},Ii.prototype.unshift=function(Vi){return qi(this,Vi,null,!0,!1)};function qi(Vi,Ki,Zi,In,Ji){var Xi=Vi._readableState;if(Ki===null)Xi.reading=!1,Qi(Vi,Xi);else{var on;Ji||(on=ki(Xi,Ki)),on?Vi.emit("error",on):Xi.objectMode||Ki&&Ki.length>0?(typeof Ki!="string"&&!Xi.objectMode&&Object.getPrototypeOf(Ki)!==a.prototype&&(Ki=v(Ki)),In?Xi.endEmitted?Vi.emit("error",new Error("stream.unshift() after end event")):Oi(Vi,Xi,Ki,!0):Xi.ended?Vi.emit("error",new Error("stream.push() after EOF")):(Xi.reading=!1,Xi.decoder&&!Zi?(Ki=Xi.decoder.write(Ki),Xi.objectMode||Ki.length!==0?Oi(Vi,Xi,Ki,!1):xi(Vi,Xi)):Oi(Vi,Xi,Ki,!1))):In||(Xi.reading=!1)}return Li(Xi)}function Oi(Vi,Ki,Zi,In){Ki.flowing&&Ki.length===0&&!Ki.sync?(Vi.emit("data",Zi),Vi.read(0)):(Ki.length+=Ki.objectMode?1:Zi.length,In?Ki.buffer.unshift(Zi):Ki.buffer.push(Zi),Ki.needReadable&&$i(Vi)),xi(Vi,Ki)}function ki(Vi,Ki){var Zi;return!hi(Ki)&&typeof Ki!="string"&&Ki!==void 0&&!Vi.objectMode&&(Zi=new TypeError("Invalid non-string/buffer chunk")),Zi}function Li(Vi){return!Vi.ended&&(Vi.needReadable||Vi.length<Vi.highWaterMark||Vi.length===0)}Ii.prototype.isPaused=function(){return this._readableState.flowing===!1},Ii.prototype.setEncoding=function(Vi){return gi||(gi=requireString_decoder().StringDecoder),this._readableState.decoder=new gi(Vi),this._readableState.encoding=Vi,this};var ji=8388608;function Hi(Vi){return Vi>=ji?Vi=ji:(Vi--,Vi|=Vi>>>1,Vi|=Vi>>>2,Vi|=Vi>>>4,Vi|=Vi>>>8,Vi|=Vi>>>16,Vi++),Vi}function Ui(Vi,Ki){return Vi<=0||Ki.length===0&&Ki.ended?0:Ki.objectMode?1:Vi!==Vi?Ki.flowing&&Ki.length?Ki.buffer.head.data.length:Ki.length:(Vi>Ki.highWaterMark&&(Ki.highWaterMark=Hi(Vi)),Vi<=Ki.length?Vi:Ki.ended?Ki.length:(Ki.needReadable=!0,0))}Ii.prototype.read=function(Vi){vi("read",Vi),Vi=parseInt(Vi,10);var Ki=this._readableState,Zi=Vi;if(Vi!==0&&(Ki.emittedReadable=!1),Vi===0&&Ki.needReadable&&(Ki.length>=Ki.highWaterMark||Ki.ended))return vi("read: emitReadable",Ki.length,Ki.ended),Ki.length===0&&Ki.ended?Pi(this):$i(this),null;if(Vi=Ui(Vi,Ki),Vi===0&&Ki.ended)return Ki.length===0&&Pi(this),null;var In=Ki.needReadable;vi("need readable",In),(Ki.length===0||Ki.length-Vi<Ki.highWaterMark)&&(In=!0,vi("length less than watermark",In)),Ki.ended||Ki.reading?(In=!1,vi("reading or ended",In)):In&&(vi("do read"),Ki.reading=!0,Ki.sync=!0,Ki.length===0&&(Ki.needReadable=!0),this._read(Ki.highWaterMark),Ki.sync=!1,Ki.reading||(Vi=Ui(Zi,Ki)));var Ji;return Vi>0?Ji=Si(Vi,Ki):Ji=null,Ji===null?(Ki.needReadable=!0,Vi=0):Ki.length-=Vi,Ki.length===0&&(Ki.ended||(Ki.needReadable=!0),Zi!==Vi&&Ki.ended&&Pi(this)),Ji!==null&&this.emit("data",Ji),Ji};function Qi(Vi,Ki){if(!Ki.ended){if(Ki.decoder){var Zi=Ki.decoder.end();Zi&&Zi.length&&(Ki.buffer.push(Zi),Ki.length+=Ki.objectMode?1:Zi.length)}Ki.ended=!0,$i(Vi)}}function $i(Vi){var Ki=Vi._readableState;Ki.needReadable=!1,Ki.emittedReadable||(vi("emitReadable",Ki.flowing),Ki.emittedReadable=!0,Ki.sync?r.nextTick(wi,Vi):wi(Vi))}function wi(Vi){vi("emit readable"),Vi.emit("readable"),Mi(Vi)}function xi(Vi,Ki){Ki.readingMore||(Ki.readingMore=!0,r.nextTick(yi,Vi,Ki))}function yi(Vi,Ki){for(var Zi=Ki.length;!Ki.reading&&!Ki.flowing&&!Ki.ended&&Ki.length<Ki.highWaterMark&&(vi("maybeReadMore read 0"),Vi.read(0),Zi!==Ki.length);)Zi=Ki.length;Ki.readingMore=!1}Ii.prototype._read=function(Vi){this.emit("error",new Error("_read() is not implemented"))},Ii.prototype.pipe=function(Vi,Ki){var Zi=this,In=this._readableState;switch(In.pipesCount){case 0:In.pipes=Vi;break;case 1:In.pipes=[In.pipes,Vi];break;default:In.pipes.push(Vi);break}In.pipesCount+=1,vi("pipe count=%d opts=%j",In.pipesCount,Ki);var Ji=(!Ki||Ki.end!==!1)&&Vi!==process$1.stdout&&Vi!==process$1.stderr,Xi=Ji?jn:sa;In.endEmitted?r.nextTick(Xi):Zi.once("end",Xi),Vi.on("unpipe",on);function on(ua,da){vi("onunpipe"),ua===Zi&&da&&da.hasUnpiped===!1&&(da.hasUnpiped=!0,ea())}function jn(){vi("onend"),Vi.end()}var Ln=Ei(Zi);Vi.on("drain",Ln);var Hn=!1;function ea(){vi("cleanup"),Vi.removeListener("close",ta),Vi.removeListener("finish",aa),Vi.removeListener("drain",Ln),Vi.removeListener("error",oa),Vi.removeListener("unpipe",on),Zi.removeListener("end",jn),Zi.removeListener("end",sa),Zi.removeListener("data",Wn),Hn=!0,In.awaitDrain&&(!Vi._writableState||Vi._writableState.needDrain)&&Ln()}var ia=!1;Zi.on("data",Wn);function Wn(ua){vi("ondata"),ia=!1;var da=Vi.write(ua);da===!1&&!ia&&((In.pipesCount===1&&In.pipes===Vi||In.pipesCount>1&&Gi(In.pipes,Vi)!==-1)&&!Hn&&(vi("false write response, pause",In.awaitDrain),In.awaitDrain++,ia=!0),Zi.pause())}function oa(ua){vi("onerror",ua),sa(),Vi.removeListener("error",oa),n(Vi,"error")===0&&Vi.emit("error",ua)}Ri(Vi,"error",oa);function ta(){Vi.removeListener("finish",aa),sa()}Vi.once("close",ta);function aa(){vi("onfinish"),Vi.removeListener("close",ta),sa()}Vi.once("finish",aa);function sa(){vi("unpipe"),Zi.unpipe(Vi)}return Vi.emit("pipe",Zi),In.flowing||(vi("pipe resume"),Zi.resume()),Vi};function Ei(Vi){return function(){var Ki=Vi._readableState;vi("pipeOnDrain",Ki.awaitDrain),Ki.awaitDrain&&Ki.awaitDrain--,Ki.awaitDrain===0&&n(Vi,"data")&&(Ki.flowing=!0,Mi(Vi))}}Ii.prototype.unpipe=function(Vi){var Ki=this._readableState,Zi={hasUnpiped:!1};if(Ki.pipesCount===0)return this;if(Ki.pipesCount===1)return Vi&&Vi!==Ki.pipes?this:(Vi||(Vi=Ki.pipes),Ki.pipes=null,Ki.pipesCount=0,Ki.flowing=!1,Vi&&Vi.emit("unpipe",this,Zi),this);if(!Vi){var In=Ki.pipes,Ji=Ki.pipesCount;Ki.pipes=null,Ki.pipesCount=0,Ki.flowing=!1;for(var Xi=0;Xi<Ji;Xi++)In[Xi].emit("unpipe",this,{hasUnpiped:!1});return this}var on=Gi(Ki.pipes,Vi);return on===-1?this:(Ki.pipes.splice(on,1),Ki.pipesCount-=1,Ki.pipesCount===1&&(Ki.pipes=Ki.pipes[0]),Vi.emit("unpipe",this,Zi),this)},Ii.prototype.on=function(Vi,Ki){var Zi=s.prototype.on.call(this,Vi,Ki);if(Vi==="data")this._readableState.flowing!==!1&&this.resume();else if(Vi==="readable"){var In=this._readableState;!In.endEmitted&&!In.readableListening&&(In.readableListening=In.needReadable=!0,In.emittedReadable=!1,In.reading?In.length&&$i(this):r.nextTick(Ci,this))}return Zi},Ii.prototype.addListener=Ii.prototype.on;function Ci(Vi){vi("readable nexttick read 0"),Vi.read(0)}Ii.prototype.resume=function(){var Vi=this._readableState;return Vi.flowing||(vi("resume"),Vi.flowing=!0,Ni(this,Vi)),this};function Ni(Vi,Ki){Ki.resumeScheduled||(Ki.resumeScheduled=!0,r.nextTick(Fi,Vi,Ki))}function Fi(Vi,Ki){Ki.reading||(vi("resume read 0"),Vi.read(0)),Ki.resumeScheduled=!1,Ki.awaitDrain=0,Vi.emit("resume"),Mi(Vi),Ki.flowing&&!Ki.reading&&Vi.read(0)}Ii.prototype.pause=function(){return vi("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(vi("pause"),this._readableState.flowing=!1,this.emit("pause")),this};function Mi(Vi){var Ki=Vi._readableState;for(vi("flow",Ki.flowing);Ki.flowing&&Vi.read()!==null;);}Ii.prototype.wrap=function(Vi){var Ki=this,Zi=this._readableState,In=!1;Vi.on("end",function(){if(vi("wrapped end"),Zi.decoder&&!Zi.ended){var on=Zi.decoder.end();on&&on.length&&Ki.push(on)}Ki.push(null)}),Vi.on("data",function(on){if(vi("wrapped data"),Zi.decoder&&(on=Zi.decoder.write(on)),!(Zi.objectMode&&on==null)&&!(!Zi.objectMode&&(!on||!on.length))){var jn=Ki.push(on);jn||(In=!0,Vi.pause())}});for(var Ji in Vi)this[Ji]===void 0&&typeof Vi[Ji]=="function"&&(this[Ji]=function(on){return function(){return Vi[on].apply(Vi,arguments)}}(Ji));for(var Xi=0;Xi<bi.length;Xi++)Vi.on(bi[Xi],this.emit.bind(this,bi[Xi]));return this._read=function(on){vi("wrapped _read",on),In&&(In=!1,Vi.resume())},this},Object.defineProperty(Ii.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Ii._fromList=Si;function Si(Vi,Ki){if(Ki.length===0)return null;var Zi;return Ki.objectMode?Zi=Ki.buffer.shift():!Vi||Vi>=Ki.length?(Ki.decoder?Zi=Ki.buffer.join(""):Ki.buffer.length===1?Zi=Ki.buffer.head.data:Zi=Ki.buffer.concat(Ki.length),Ki.buffer.clear()):Zi=Ai(Vi,Ki.buffer,Ki.decoder),Zi}function Ai(Vi,Ki,Zi){var In;return Vi<Ki.head.data.length?(In=Ki.head.data.slice(0,Vi),Ki.head.data=Ki.head.data.slice(Vi)):Vi===Ki.head.data.length?In=Ki.shift():In=Zi?_i(Vi,Ki):Bi(Vi,Ki),In}function _i(Vi,Ki){var Zi=Ki.head,In=1,Ji=Zi.data;for(Vi-=Ji.length;Zi=Zi.next;){var Xi=Zi.data,on=Vi>Xi.length?Xi.length:Vi;if(on===Xi.length?Ji+=Xi:Ji+=Xi.slice(0,Vi),Vi-=on,Vi===0){on===Xi.length?(++In,Zi.next?Ki.head=Zi.next:Ki.head=Ki.tail=null):(Ki.head=Zi,Zi.data=Xi.slice(on));break}++In}return Ki.length-=In,Ji}function Bi(Vi,Ki){var Zi=a.allocUnsafe(Vi),In=Ki.head,Ji=1;for(In.data.copy(Zi),Vi-=In.data.length;In=In.next;){var Xi=In.data,on=Vi>Xi.length?Xi.length:Vi;if(Xi.copy(Zi,Zi.length-Vi,0,on),Vi-=on,Vi===0){on===Xi.length?(++Ji,In.next?Ki.head=In.next:Ki.head=Ki.tail=null):(Ki.head=In,In.data=Xi.slice(on));break}++Ji}return Ki.length-=Ji,Zi}function Pi(Vi){var Ki=Vi._readableState;if(Ki.length>0)throw new Error('"endReadable()" called on non-empty stream');Ki.endEmitted||(Ki.ended=!0,r.nextTick(zi,Ki,Vi))}function zi(Vi,Ki){!Vi.endEmitted&&Vi.length===0&&(Vi.endEmitted=!0,Ki.readable=!1,Ki.emit("end"))}function Gi(Vi,Ki){for(var Zi=0,In=Vi.length;Zi<In;Zi++)if(Vi[Zi]===Ki)return Zi;return-1}return _stream_readable}var _stream_transform,hasRequired_stream_transform;function require_stream_transform(){if(hasRequired_stream_transform)return _stream_transform;hasRequired_stream_transform=1,_stream_transform=n;var r=require_stream_duplex(),t=Object.create(requireUtil());t.inherits=requireInherits_browser(),t.inherits(n,r);function i(h,v){var hi=this._transformState;hi.transforming=!1;var u=hi.writecb;if(!u)return this.emit("error",new Error("write callback called multiple times"));hi.writechunk=null,hi.writecb=null,v!=null&&this.push(v),u(h);var l=this._readableState;l.reading=!1,(l.needReadable||l.length<l.highWaterMark)&&this._read(l.highWaterMark)}function n(h){if(!(this instanceof n))return new n(h);r.call(this,h),this._transformState={afterTransform:i.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,h&&(typeof h.transform=="function"&&(this._transform=h.transform),typeof h.flush=="function"&&(this._flush=h.flush)),this.on("prefinish",s)}function s(){var h=this;typeof this._flush=="function"?this._flush(function(v,hi){a(h,v,hi)}):a(this,null,null)}n.prototype.push=function(h,v){return this._transformState.needTransform=!1,r.prototype.push.call(this,h,v)},n.prototype._transform=function(h,v,hi){throw new Error("_transform() is not implemented")},n.prototype._write=function(h,v,hi){var u=this._transformState;if(u.writecb=hi,u.writechunk=h,u.writeencoding=v,!u.transforming){var l=this._readableState;(u.needTransform||l.needReadable||l.length<l.highWaterMark)&&this._read(l.highWaterMark)}},n.prototype._read=function(h){var v=this._transformState;v.writechunk!==null&&v.writecb&&!v.transforming?(v.transforming=!0,this._transform(v.writechunk,v.writeencoding,v.afterTransform)):v.needTransform=!0},n.prototype._destroy=function(h,v){var hi=this;r.prototype._destroy.call(this,h,function(u){v(u),hi.emit("close")})};function a(h,v,hi){if(v)return h.emit("error",v);if(hi!=null&&h.push(hi),h._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(h._transformState.transforming)throw new Error("Calling transform done when still transforming");return h.push(null)}return _stream_transform}var _stream_passthrough,hasRequired_stream_passthrough;function require_stream_passthrough(){if(hasRequired_stream_passthrough)return _stream_passthrough;hasRequired_stream_passthrough=1,_stream_passthrough=i;var r=require_stream_transform(),t=Object.create(requireUtil());t.inherits=requireInherits_browser(),t.inherits(i,r);function i(n){if(!(this instanceof i))return new i(n);r.call(this,n)}return i.prototype._transform=function(n,s,a){a(null,n)},_stream_passthrough}var hasRequiredReadableBrowser;function requireReadableBrowser(){return hasRequiredReadableBrowser||(hasRequiredReadableBrowser=1,function(r,t){t=r.exports=require_stream_readable(),t.Stream=t,t.Readable=t,t.Writable=require_stream_writable(),t.Duplex=require_stream_duplex(),t.Transform=require_stream_transform(),t.PassThrough=require_stream_passthrough()}(readableBrowser,readableBrowser.exports)),readableBrowser.exports}var sign={exports:{}},bn$3={exports:{}},bn$2=bn$3.exports,hasRequiredBn$1;function requireBn$1(){return hasRequiredBn$1||(hasRequiredBn$1=1,function(r){(function(t,i){function n(xi,yi){if(!xi)throw new Error(yi||"Assertion failed")}function s(xi,yi){xi.super_=yi;var Ei=function(){};Ei.prototype=yi.prototype,xi.prototype=new Ei,xi.prototype.constructor=xi}function a(xi,yi,Ei){if(a.isBN(xi))return xi;this.negative=0,this.words=null,this.length=0,this.red=null,xi!==null&&((yi==="le"||yi==="be")&&(Ei=yi,yi=10),this._init(xi||0,yi||10,Ei||"be"))}typeof t=="object"?t.exports=a:i.BN=a,a.BN=a,a.wordSize=26;var h;try{typeof window<"u"&&typeof window.Buffer<"u"?h=window.Buffer:h=requireDist().Buffer}catch{}a.isBN=function(yi){return yi instanceof a?!0:yi!==null&&typeof yi=="object"&&yi.constructor.wordSize===a.wordSize&&Array.isArray(yi.words)},a.max=function(yi,Ei){return yi.cmp(Ei)>0?yi:Ei},a.min=function(yi,Ei){return yi.cmp(Ei)<0?yi:Ei},a.prototype._init=function(yi,Ei,Ci){if(typeof yi=="number")return this._initNumber(yi,Ei,Ci);if(typeof yi=="object")return this._initArray(yi,Ei,Ci);Ei==="hex"&&(Ei=16),n(Ei===(Ei|0)&&Ei>=2&&Ei<=36),yi=yi.toString().replace(/\s+/g,"");var Ni=0;yi[0]==="-"&&(Ni++,this.negative=1),Ni<yi.length&&(Ei===16?this._parseHex(yi,Ni,Ci):(this._parseBase(yi,Ei,Ni),Ci==="le"&&this._initArray(this.toArray(),Ei,Ci)))},a.prototype._initNumber=function(yi,Ei,Ci){yi<0&&(this.negative=1,yi=-yi),yi<67108864?(this.words=[yi&67108863],this.length=1):yi<4503599627370496?(this.words=[yi&67108863,yi/67108864&67108863],this.length=2):(n(yi<9007199254740992),this.words=[yi&67108863,yi/67108864&67108863,1],this.length=3),Ci==="le"&&this._initArray(this.toArray(),Ei,Ci)},a.prototype._initArray=function(yi,Ei,Ci){if(n(typeof yi.length=="number"),yi.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(yi.length/3),this.words=new Array(this.length);for(var Ni=0;Ni<this.length;Ni++)this.words[Ni]=0;var Fi,Mi,Si=0;if(Ci==="be")for(Ni=yi.length-1,Fi=0;Ni>=0;Ni-=3)Mi=yi[Ni]|yi[Ni-1]<<8|yi[Ni-2]<<16,this.words[Fi]|=Mi<<Si&67108863,this.words[Fi+1]=Mi>>>26-Si&67108863,Si+=24,Si>=26&&(Si-=26,Fi++);else if(Ci==="le")for(Ni=0,Fi=0;Ni<yi.length;Ni+=3)Mi=yi[Ni]|yi[Ni+1]<<8|yi[Ni+2]<<16,this.words[Fi]|=Mi<<Si&67108863,this.words[Fi+1]=Mi>>>26-Si&67108863,Si+=24,Si>=26&&(Si-=26,Fi++);return this._strip()};function v(xi,yi){var Ei=xi.charCodeAt(yi);if(Ei>=48&&Ei<=57)return Ei-48;if(Ei>=65&&Ei<=70)return Ei-55;if(Ei>=97&&Ei<=102)return Ei-87;n(!1,"Invalid character in "+xi)}function hi(xi,yi,Ei){var Ci=v(xi,Ei);return Ei-1>=yi&&(Ci|=v(xi,Ei-1)<<4),Ci}a.prototype._parseHex=function(yi,Ei,Ci){this.length=Math.ceil((yi.length-Ei)/6),this.words=new Array(this.length);for(var Ni=0;Ni<this.length;Ni++)this.words[Ni]=0;var Fi=0,Mi=0,Si;if(Ci==="be")for(Ni=yi.length-1;Ni>=Ei;Ni-=2)Si=hi(yi,Ei,Ni)<<Fi,this.words[Mi]|=Si&67108863,Fi>=18?(Fi-=18,Mi+=1,this.words[Mi]|=Si>>>26):Fi+=8;else{var Ai=yi.length-Ei;for(Ni=Ai%2===0?Ei+1:Ei;Ni<yi.length;Ni+=2)Si=hi(yi,Ei,Ni)<<Fi,this.words[Mi]|=Si&67108863,Fi>=18?(Fi-=18,Mi+=1,this.words[Mi]|=Si>>>26):Fi+=8}this._strip()};function u(xi,yi,Ei,Ci){for(var Ni=0,Fi=0,Mi=Math.min(xi.length,Ei),Si=yi;Si<Mi;Si++){var Ai=xi.charCodeAt(Si)-48;Ni*=Ci,Ai>=49?Fi=Ai-49+10:Ai>=17?Fi=Ai-17+10:Fi=Ai,n(Ai>=0&&Fi<Ci,"Invalid character"),Ni+=Fi}return Ni}a.prototype._parseBase=function(yi,Ei,Ci){this.words=[0],this.length=1;for(var Ni=0,Fi=1;Fi<=67108863;Fi*=Ei)Ni++;Ni--,Fi=Fi/Ei|0;for(var Mi=yi.length-Ci,Si=Mi%Ni,Ai=Math.min(Mi,Mi-Si)+Ci,_i=0,Bi=Ci;Bi<Ai;Bi+=Ni)_i=u(yi,Bi,Bi+Ni,Ei),this.imuln(Fi),this.words[0]+_i<67108864?this.words[0]+=_i:this._iaddn(_i);if(Si!==0){var Pi=1;for(_i=u(yi,Bi,yi.length,Ei),Bi=0;Bi<Si;Bi++)Pi*=Ei;this.imuln(Pi),this.words[0]+_i<67108864?this.words[0]+=_i:this._iaddn(_i)}this._strip()},a.prototype.copy=function(yi){yi.words=new Array(this.length);for(var Ei=0;Ei<this.length;Ei++)yi.words[Ei]=this.words[Ei];yi.length=this.length,yi.negative=this.negative,yi.red=this.red};function l(xi,yi){xi.words=yi.words,xi.length=yi.length,xi.negative=yi.negative,xi.red=yi.red}if(a.prototype._move=function(yi){l(yi,this)},a.prototype.clone=function(){var yi=new a(null);return this.copy(yi),yi},a.prototype._expand=function(yi){for(;this.length<yi;)this.words[this.length++]=0;return this},a.prototype._strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},a.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},typeof Symbol<"u"&&typeof Symbol.for=="function")try{a.prototype[Symbol.for("nodejs.util.inspect.custom")]=vi}catch{a.prototype.inspect=vi}else a.prototype.inspect=vi;function vi(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"}var D=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],mi=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],gi=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];a.prototype.toString=function(yi,Ei){yi=yi||10,Ei=Ei|0||1;var Ci;if(yi===16||yi==="hex"){Ci="";for(var Ni=0,Fi=0,Mi=0;Mi<this.length;Mi++){var Si=this.words[Mi],Ai=((Si<<Ni|Fi)&16777215).toString(16);Fi=Si>>>24-Ni&16777215,Ni+=2,Ni>=26&&(Ni-=26,Mi--),Fi!==0||Mi!==this.length-1?Ci=D[6-Ai.length]+Ai+Ci:Ci=Ai+Ci}for(Fi!==0&&(Ci=Fi.toString(16)+Ci);Ci.length%Ei!==0;)Ci="0"+Ci;return this.negative!==0&&(Ci="-"+Ci),Ci}if(yi===(yi|0)&&yi>=2&&yi<=36){var _i=mi[yi],Bi=gi[yi];Ci="";var Pi=this.clone();for(Pi.negative=0;!Pi.isZero();){var zi=Pi.modrn(Bi).toString(yi);Pi=Pi.idivn(Bi),Pi.isZero()?Ci=zi+Ci:Ci=D[_i-zi.length]+zi+Ci}for(this.isZero()&&(Ci="0"+Ci);Ci.length%Ei!==0;)Ci="0"+Ci;return this.negative!==0&&(Ci="-"+Ci),Ci}n(!1,"Base should be between 2 and 36")},a.prototype.toNumber=function(){var yi=this.words[0];return this.length===2?yi+=this.words[1]*67108864:this.length===3&&this.words[2]===1?yi+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-yi:yi},a.prototype.toJSON=function(){return this.toString(16,2)},h&&(a.prototype.toBuffer=function(yi,Ei){return this.toArrayLike(h,yi,Ei)}),a.prototype.toArray=function(yi,Ei){return this.toArrayLike(Array,yi,Ei)};var bi=function(yi,Ei){return yi.allocUnsafe?yi.allocUnsafe(Ei):new yi(Ei)};a.prototype.toArrayLike=function(yi,Ei,Ci){this._strip();var Ni=this.byteLength(),Fi=Ci||Math.max(1,Ni);n(Ni<=Fi,"byte array longer than desired length"),n(Fi>0,"Requested array length <= 0");var Mi=bi(yi,Fi),Si=Ei==="le"?"LE":"BE";return this["_toArrayLike"+Si](Mi,Ni),Mi},a.prototype._toArrayLikeLE=function(yi,Ei){for(var Ci=0,Ni=0,Fi=0,Mi=0;Fi<this.length;Fi++){var Si=this.words[Fi]<<Mi|Ni;yi[Ci++]=Si&255,Ci<yi.length&&(yi[Ci++]=Si>>8&255),Ci<yi.length&&(yi[Ci++]=Si>>16&255),Mi===6?(Ci<yi.length&&(yi[Ci++]=Si>>24&255),Ni=0,Mi=0):(Ni=Si>>>24,Mi+=2)}if(Ci<yi.length)for(yi[Ci++]=Ni;Ci<yi.length;)yi[Ci++]=0},a.prototype._toArrayLikeBE=function(yi,Ei){for(var Ci=yi.length-1,Ni=0,Fi=0,Mi=0;Fi<this.length;Fi++){var Si=this.words[Fi]<<Mi|Ni;yi[Ci--]=Si&255,Ci>=0&&(yi[Ci--]=Si>>8&255),Ci>=0&&(yi[Ci--]=Si>>16&255),Mi===6?(Ci>=0&&(yi[Ci--]=Si>>24&255),Ni=0,Mi=0):(Ni=Si>>>24,Mi+=2)}if(Ci>=0)for(yi[Ci--]=Ni;Ci>=0;)yi[Ci--]=0},Math.clz32?a.prototype._countBits=function(yi){return 32-Math.clz32(yi)}:a.prototype._countBits=function(yi){var Ei=yi,Ci=0;return Ei>=4096&&(Ci+=13,Ei>>>=13),Ei>=64&&(Ci+=7,Ei>>>=7),Ei>=8&&(Ci+=4,Ei>>>=4),Ei>=2&&(Ci+=2,Ei>>>=2),Ci+Ei},a.prototype._zeroBits=function(yi){if(yi===0)return 26;var Ei=yi,Ci=0;return(Ei&8191)===0&&(Ci+=13,Ei>>>=13),(Ei&127)===0&&(Ci+=7,Ei>>>=7),(Ei&15)===0&&(Ci+=4,Ei>>>=4),(Ei&3)===0&&(Ci+=2,Ei>>>=2),(Ei&1)===0&&Ci++,Ci},a.prototype.bitLength=function(){var yi=this.words[this.length-1],Ei=this._countBits(yi);return(this.length-1)*26+Ei};function Ri(xi){for(var yi=new Array(xi.bitLength()),Ei=0;Ei<yi.length;Ei++){var Ci=Ei/26|0,Ni=Ei%26;yi[Ei]=xi.words[Ci]>>>Ni&1}return yi}a.prototype.zeroBits=function(){if(this.isZero())return 0;for(var yi=0,Ei=0;Ei<this.length;Ei++){var Ci=this._zeroBits(this.words[Ei]);if(yi+=Ci,Ci!==26)break}return yi},a.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},a.prototype.toTwos=function(yi){return this.negative!==0?this.abs().inotn(yi).iaddn(1):this.clone()},a.prototype.fromTwos=function(yi){return this.testn(yi-1)?this.notn(yi).iaddn(1).ineg():this.clone()},a.prototype.isNeg=function(){return this.negative!==0},a.prototype.neg=function(){return this.clone().ineg()},a.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},a.prototype.iuor=function(yi){for(;this.length<yi.length;)this.words[this.length++]=0;for(var Ei=0;Ei<yi.length;Ei++)this.words[Ei]=this.words[Ei]|yi.words[Ei];return this._strip()},a.prototype.ior=function(yi){return n((this.negative|yi.negative)===0),this.iuor(yi)},a.prototype.or=function(yi){return this.length>yi.length?this.clone().ior(yi):yi.clone().ior(this)},a.prototype.uor=function(yi){return this.length>yi.length?this.clone().iuor(yi):yi.clone().iuor(this)},a.prototype.iuand=function(yi){var Ei;this.length>yi.length?Ei=yi:Ei=this;for(var Ci=0;Ci<Ei.length;Ci++)this.words[Ci]=this.words[Ci]&yi.words[Ci];return this.length=Ei.length,this._strip()},a.prototype.iand=function(yi){return n((this.negative|yi.negative)===0),this.iuand(yi)},a.prototype.and=function(yi){return this.length>yi.length?this.clone().iand(yi):yi.clone().iand(this)},a.prototype.uand=function(yi){return this.length>yi.length?this.clone().iuand(yi):yi.clone().iuand(this)},a.prototype.iuxor=function(yi){var Ei,Ci;this.length>yi.length?(Ei=this,Ci=yi):(Ei=yi,Ci=this);for(var Ni=0;Ni<Ci.length;Ni++)this.words[Ni]=Ei.words[Ni]^Ci.words[Ni];if(this!==Ei)for(;Ni<Ei.length;Ni++)this.words[Ni]=Ei.words[Ni];return this.length=Ei.length,this._strip()},a.prototype.ixor=function(yi){return n((this.negative|yi.negative)===0),this.iuxor(yi)},a.prototype.xor=function(yi){return this.length>yi.length?this.clone().ixor(yi):yi.clone().ixor(this)},a.prototype.uxor=function(yi){return this.length>yi.length?this.clone().iuxor(yi):yi.clone().iuxor(this)},a.prototype.inotn=function(yi){n(typeof yi=="number"&&yi>=0);var Ei=Math.ceil(yi/26)|0,Ci=yi%26;this._expand(Ei),Ci>0&&Ei--;for(var Ni=0;Ni<Ei;Ni++)this.words[Ni]=~this.words[Ni]&67108863;return Ci>0&&(this.words[Ni]=~this.words[Ni]&67108863>>26-Ci),this._strip()},a.prototype.notn=function(yi){return this.clone().inotn(yi)},a.prototype.setn=function(yi,Ei){n(typeof yi=="number"&&yi>=0);var Ci=yi/26|0,Ni=yi%26;return this._expand(Ci+1),Ei?this.words[Ci]=this.words[Ci]|1<<Ni:this.words[Ci]=this.words[Ci]&~(1<<Ni),this._strip()},a.prototype.iadd=function(yi){var Ei;if(this.negative!==0&&yi.negative===0)return this.negative=0,Ei=this.isub(yi),this.negative^=1,this._normSign();if(this.negative===0&&yi.negative!==0)return yi.negative=0,Ei=this.isub(yi),yi.negative=1,Ei._normSign();var Ci,Ni;this.length>yi.length?(Ci=this,Ni=yi):(Ci=yi,Ni=this);for(var Fi=0,Mi=0;Mi<Ni.length;Mi++)Ei=(Ci.words[Mi]|0)+(Ni.words[Mi]|0)+Fi,this.words[Mi]=Ei&67108863,Fi=Ei>>>26;for(;Fi!==0&&Mi<Ci.length;Mi++)Ei=(Ci.words[Mi]|0)+Fi,this.words[Mi]=Ei&67108863,Fi=Ei>>>26;if(this.length=Ci.length,Fi!==0)this.words[this.length]=Fi,this.length++;else if(Ci!==this)for(;Mi<Ci.length;Mi++)this.words[Mi]=Ci.words[Mi];return this},a.prototype.add=function(yi){var Ei;return yi.negative!==0&&this.negative===0?(yi.negative=0,Ei=this.sub(yi),yi.negative^=1,Ei):yi.negative===0&&this.negative!==0?(this.negative=0,Ei=yi.sub(this),this.negative=1,Ei):this.length>yi.length?this.clone().iadd(yi):yi.clone().iadd(this)},a.prototype.isub=function(yi){if(yi.negative!==0){yi.negative=0;var Ei=this.iadd(yi);return yi.negative=1,Ei._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(yi),this.negative=1,this._normSign();var Ci=this.cmp(yi);if(Ci===0)return this.negative=0,this.length=1,this.words[0]=0,this;var Ni,Fi;Ci>0?(Ni=this,Fi=yi):(Ni=yi,Fi=this);for(var Mi=0,Si=0;Si<Fi.length;Si++)Ei=(Ni.words[Si]|0)-(Fi.words[Si]|0)+Mi,Mi=Ei>>26,this.words[Si]=Ei&67108863;for(;Mi!==0&&Si<Ni.length;Si++)Ei=(Ni.words[Si]|0)+Mi,Mi=Ei>>26,this.words[Si]=Ei&67108863;if(Mi===0&&Si<Ni.length&&Ni!==this)for(;Si<Ni.length;Si++)this.words[Si]=Ni.words[Si];return this.length=Math.max(this.length,Si),Ni!==this&&(this.negative=1),this._strip()},a.prototype.sub=function(yi){return this.clone().isub(yi)};function Ti(xi,yi,Ei){Ei.negative=yi.negative^xi.negative;var Ci=xi.length+yi.length|0;Ei.length=Ci,Ci=Ci-1|0;var Ni=xi.words[0]|0,Fi=yi.words[0]|0,Mi=Ni*Fi,Si=Mi&67108863,Ai=Mi/67108864|0;Ei.words[0]=Si;for(var _i=1;_i<Ci;_i++){for(var Bi=Ai>>>26,Pi=Ai&67108863,zi=Math.min(_i,yi.length-1),Gi=Math.max(0,_i-xi.length+1);Gi<=zi;Gi++){var Vi=_i-Gi|0;Ni=xi.words[Vi]|0,Fi=yi.words[Gi]|0,Mi=Ni*Fi+Pi,Bi+=Mi/67108864|0,Pi=Mi&67108863}Ei.words[_i]=Pi|0,Ai=Bi|0}return Ai!==0?Ei.words[_i]=Ai|0:Ei.length--,Ei._strip()}var Ii=function(yi,Ei,Ci){var Ni=yi.words,Fi=Ei.words,Mi=Ci.words,Si=0,Ai,_i,Bi,Pi=Ni[0]|0,zi=Pi&8191,Gi=Pi>>>13,Vi=Ni[1]|0,Ki=Vi&8191,Zi=Vi>>>13,In=Ni[2]|0,Ji=In&8191,Xi=In>>>13,on=Ni[3]|0,jn=on&8191,Ln=on>>>13,Hn=Ni[4]|0,ea=Hn&8191,ia=Hn>>>13,Wn=Ni[5]|0,oa=Wn&8191,ta=Wn>>>13,aa=Ni[6]|0,sa=aa&8191,ua=aa>>>13,da=Ni[7]|0,ca=da&8191,la=da>>>13,Fa=Ni[8]|0,xa=Fa&8191,ha=Fa>>>13,Ca=Ni[9]|0,Ra=Ca&8191,pa=Ca>>>13,Ma=Fi[0]|0,wa=Ma&8191,ya=Ma>>>13,La=Fi[1]|0,Sa=La&8191,ga=La>>>13,Pa=Fi[2]|0,Ta=Pa&8191,va=Pa>>>13,Ba=Fi[3]|0,Aa=Ba&8191,_a=Ba>>>13,ka=Fi[4]|0,Na=ka&8191,Rn=ka>>>13,Wi=Fi[5]|0,Yi=Wi&8191,Mn=Wi>>>13,Yn=Fi[6]|0,ra=Yn&8191,na=Yn>>>13,Ea=Fi[7]|0,ba=Ea&8191,fa=Ea>>>13,Ia=Fi[8]|0,ma=Ia&8191,Da=Ia>>>13,$a=Fi[9]|0,qa=$a&8191,Oa=$a>>>13;Ci.negative=yi.negative^Ei.negative,Ci.length=19,Ai=Math.imul(zi,wa),_i=Math.imul(zi,ya),_i=_i+Math.imul(Gi,wa)|0,Bi=Math.imul(Gi,ya);var Ua=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Ua>>>26)|0,Ua&=67108863,Ai=Math.imul(Ki,wa),_i=Math.imul(Ki,ya),_i=_i+Math.imul(Zi,wa)|0,Bi=Math.imul(Zi,ya),Ai=Ai+Math.imul(zi,Sa)|0,_i=_i+Math.imul(zi,ga)|0,_i=_i+Math.imul(Gi,Sa)|0,Bi=Bi+Math.imul(Gi,ga)|0;var ja=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(ja>>>26)|0,ja&=67108863,Ai=Math.imul(Ji,wa),_i=Math.imul(Ji,ya),_i=_i+Math.imul(Xi,wa)|0,Bi=Math.imul(Xi,ya),Ai=Ai+Math.imul(Ki,Sa)|0,_i=_i+Math.imul(Ki,ga)|0,_i=_i+Math.imul(Zi,Sa)|0,Bi=Bi+Math.imul(Zi,ga)|0,Ai=Ai+Math.imul(zi,Ta)|0,_i=_i+Math.imul(zi,va)|0,_i=_i+Math.imul(Gi,Ta)|0,Bi=Bi+Math.imul(Gi,va)|0;var Va=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Va>>>26)|0,Va&=67108863,Ai=Math.imul(jn,wa),_i=Math.imul(jn,ya),_i=_i+Math.imul(Ln,wa)|0,Bi=Math.imul(Ln,ya),Ai=Ai+Math.imul(Ji,Sa)|0,_i=_i+Math.imul(Ji,ga)|0,_i=_i+Math.imul(Xi,Sa)|0,Bi=Bi+Math.imul(Xi,ga)|0,Ai=Ai+Math.imul(Ki,Ta)|0,_i=_i+Math.imul(Ki,va)|0,_i=_i+Math.imul(Zi,Ta)|0,Bi=Bi+Math.imul(Zi,va)|0,Ai=Ai+Math.imul(zi,Aa)|0,_i=_i+Math.imul(zi,_a)|0,_i=_i+Math.imul(Gi,Aa)|0,Bi=Bi+Math.imul(Gi,_a)|0;var Ga=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Ga>>>26)|0,Ga&=67108863,Ai=Math.imul(ea,wa),_i=Math.imul(ea,ya),_i=_i+Math.imul(ia,wa)|0,Bi=Math.imul(ia,ya),Ai=Ai+Math.imul(jn,Sa)|0,_i=_i+Math.imul(jn,ga)|0,_i=_i+Math.imul(Ln,Sa)|0,Bi=Bi+Math.imul(Ln,ga)|0,Ai=Ai+Math.imul(Ji,Ta)|0,_i=_i+Math.imul(Ji,va)|0,_i=_i+Math.imul(Xi,Ta)|0,Bi=Bi+Math.imul(Xi,va)|0,Ai=Ai+Math.imul(Ki,Aa)|0,_i=_i+Math.imul(Ki,_a)|0,_i=_i+Math.imul(Zi,Aa)|0,Bi=Bi+Math.imul(Zi,_a)|0,Ai=Ai+Math.imul(zi,Na)|0,_i=_i+Math.imul(zi,Rn)|0,_i=_i+Math.imul(Gi,Na)|0,Bi=Bi+Math.imul(Gi,Rn)|0;var Ka=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Ka>>>26)|0,Ka&=67108863,Ai=Math.imul(oa,wa),_i=Math.imul(oa,ya),_i=_i+Math.imul(ta,wa)|0,Bi=Math.imul(ta,ya),Ai=Ai+Math.imul(ea,Sa)|0,_i=_i+Math.imul(ea,ga)|0,_i=_i+Math.imul(ia,Sa)|0,Bi=Bi+Math.imul(ia,ga)|0,Ai=Ai+Math.imul(jn,Ta)|0,_i=_i+Math.imul(jn,va)|0,_i=_i+Math.imul(Ln,Ta)|0,Bi=Bi+Math.imul(Ln,va)|0,Ai=Ai+Math.imul(Ji,Aa)|0,_i=_i+Math.imul(Ji,_a)|0,_i=_i+Math.imul(Xi,Aa)|0,Bi=Bi+Math.imul(Xi,_a)|0,Ai=Ai+Math.imul(Ki,Na)|0,_i=_i+Math.imul(Ki,Rn)|0,_i=_i+Math.imul(Zi,Na)|0,Bi=Bi+Math.imul(Zi,Rn)|0,Ai=Ai+Math.imul(zi,Yi)|0,_i=_i+Math.imul(zi,Mn)|0,_i=_i+Math.imul(Gi,Yi)|0,Bi=Bi+Math.imul(Gi,Mn)|0;var Ha=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Ha>>>26)|0,Ha&=67108863,Ai=Math.imul(sa,wa),_i=Math.imul(sa,ya),_i=_i+Math.imul(ua,wa)|0,Bi=Math.imul(ua,ya),Ai=Ai+Math.imul(oa,Sa)|0,_i=_i+Math.imul(oa,ga)|0,_i=_i+Math.imul(ta,Sa)|0,Bi=Bi+Math.imul(ta,ga)|0,Ai=Ai+Math.imul(ea,Ta)|0,_i=_i+Math.imul(ea,va)|0,_i=_i+Math.imul(ia,Ta)|0,Bi=Bi+Math.imul(ia,va)|0,Ai=Ai+Math.imul(jn,Aa)|0,_i=_i+Math.imul(jn,_a)|0,_i=_i+Math.imul(Ln,Aa)|0,Bi=Bi+Math.imul(Ln,_a)|0,Ai=Ai+Math.imul(Ji,Na)|0,_i=_i+Math.imul(Ji,Rn)|0,_i=_i+Math.imul(Xi,Na)|0,Bi=Bi+Math.imul(Xi,Rn)|0,Ai=Ai+Math.imul(Ki,Yi)|0,_i=_i+Math.imul(Ki,Mn)|0,_i=_i+Math.imul(Zi,Yi)|0,Bi=Bi+Math.imul(Zi,Mn)|0,Ai=Ai+Math.imul(zi,ra)|0,_i=_i+Math.imul(zi,na)|0,_i=_i+Math.imul(Gi,ra)|0,Bi=Bi+Math.imul(Gi,na)|0;var Qa=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Qa>>>26)|0,Qa&=67108863,Ai=Math.imul(ca,wa),_i=Math.imul(ca,ya),_i=_i+Math.imul(la,wa)|0,Bi=Math.imul(la,ya),Ai=Ai+Math.imul(sa,Sa)|0,_i=_i+Math.imul(sa,ga)|0,_i=_i+Math.imul(ua,Sa)|0,Bi=Bi+Math.imul(ua,ga)|0,Ai=Ai+Math.imul(oa,Ta)|0,_i=_i+Math.imul(oa,va)|0,_i=_i+Math.imul(ta,Ta)|0,Bi=Bi+Math.imul(ta,va)|0,Ai=Ai+Math.imul(ea,Aa)|0,_i=_i+Math.imul(ea,_a)|0,_i=_i+Math.imul(ia,Aa)|0,Bi=Bi+Math.imul(ia,_a)|0,Ai=Ai+Math.imul(jn,Na)|0,_i=_i+Math.imul(jn,Rn)|0,_i=_i+Math.imul(Ln,Na)|0,Bi=Bi+Math.imul(Ln,Rn)|0,Ai=Ai+Math.imul(Ji,Yi)|0,_i=_i+Math.imul(Ji,Mn)|0,_i=_i+Math.imul(Xi,Yi)|0,Bi=Bi+Math.imul(Xi,Mn)|0,Ai=Ai+Math.imul(Ki,ra)|0,_i=_i+Math.imul(Ki,na)|0,_i=_i+Math.imul(Zi,ra)|0,Bi=Bi+Math.imul(Zi,na)|0,Ai=Ai+Math.imul(zi,ba)|0,_i=_i+Math.imul(zi,fa)|0,_i=_i+Math.imul(Gi,ba)|0,Bi=Bi+Math.imul(Gi,fa)|0;var za=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(za>>>26)|0,za&=67108863,Ai=Math.imul(xa,wa),_i=Math.imul(xa,ya),_i=_i+Math.imul(ha,wa)|0,Bi=Math.imul(ha,ya),Ai=Ai+Math.imul(ca,Sa)|0,_i=_i+Math.imul(ca,ga)|0,_i=_i+Math.imul(la,Sa)|0,Bi=Bi+Math.imul(la,ga)|0,Ai=Ai+Math.imul(sa,Ta)|0,_i=_i+Math.imul(sa,va)|0,_i=_i+Math.imul(ua,Ta)|0,Bi=Bi+Math.imul(ua,va)|0,Ai=Ai+Math.imul(oa,Aa)|0,_i=_i+Math.imul(oa,_a)|0,_i=_i+Math.imul(ta,Aa)|0,Bi=Bi+Math.imul(ta,_a)|0,Ai=Ai+Math.imul(ea,Na)|0,_i=_i+Math.imul(ea,Rn)|0,_i=_i+Math.imul(ia,Na)|0,Bi=Bi+Math.imul(ia,Rn)|0,Ai=Ai+Math.imul(jn,Yi)|0,_i=_i+Math.imul(jn,Mn)|0,_i=_i+Math.imul(Ln,Yi)|0,Bi=Bi+Math.imul(Ln,Mn)|0,Ai=Ai+Math.imul(Ji,ra)|0,_i=_i+Math.imul(Ji,na)|0,_i=_i+Math.imul(Xi,ra)|0,Bi=Bi+Math.imul(Xi,na)|0,Ai=Ai+Math.imul(Ki,ba)|0,_i=_i+Math.imul(Ki,fa)|0,_i=_i+Math.imul(Zi,ba)|0,Bi=Bi+Math.imul(Zi,fa)|0,Ai=Ai+Math.imul(zi,ma)|0,_i=_i+Math.imul(zi,Da)|0,_i=_i+Math.imul(Gi,ma)|0,Bi=Bi+Math.imul(Gi,Da)|0;var Wa=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Wa>>>26)|0,Wa&=67108863,Ai=Math.imul(Ra,wa),_i=Math.imul(Ra,ya),_i=_i+Math.imul(pa,wa)|0,Bi=Math.imul(pa,ya),Ai=Ai+Math.imul(xa,Sa)|0,_i=_i+Math.imul(xa,ga)|0,_i=_i+Math.imul(ha,Sa)|0,Bi=Bi+Math.imul(ha,ga)|0,Ai=Ai+Math.imul(ca,Ta)|0,_i=_i+Math.imul(ca,va)|0,_i=_i+Math.imul(la,Ta)|0,Bi=Bi+Math.imul(la,va)|0,Ai=Ai+Math.imul(sa,Aa)|0,_i=_i+Math.imul(sa,_a)|0,_i=_i+Math.imul(ua,Aa)|0,Bi=Bi+Math.imul(ua,_a)|0,Ai=Ai+Math.imul(oa,Na)|0,_i=_i+Math.imul(oa,Rn)|0,_i=_i+Math.imul(ta,Na)|0,Bi=Bi+Math.imul(ta,Rn)|0,Ai=Ai+Math.imul(ea,Yi)|0,_i=_i+Math.imul(ea,Mn)|0,_i=_i+Math.imul(ia,Yi)|0,Bi=Bi+Math.imul(ia,Mn)|0,Ai=Ai+Math.imul(jn,ra)|0,_i=_i+Math.imul(jn,na)|0,_i=_i+Math.imul(Ln,ra)|0,Bi=Bi+Math.imul(Ln,na)|0,Ai=Ai+Math.imul(Ji,ba)|0,_i=_i+Math.imul(Ji,fa)|0,_i=_i+Math.imul(Xi,ba)|0,Bi=Bi+Math.imul(Xi,fa)|0,Ai=Ai+Math.imul(Ki,ma)|0,_i=_i+Math.imul(Ki,Da)|0,_i=_i+Math.imul(Zi,ma)|0,Bi=Bi+Math.imul(Zi,Da)|0,Ai=Ai+Math.imul(zi,qa)|0,_i=_i+Math.imul(zi,Oa)|0,_i=_i+Math.imul(Gi,qa)|0,Bi=Bi+Math.imul(Gi,Oa)|0;var Ya=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Ya>>>26)|0,Ya&=67108863,Ai=Math.imul(Ra,Sa),_i=Math.imul(Ra,ga),_i=_i+Math.imul(pa,Sa)|0,Bi=Math.imul(pa,ga),Ai=Ai+Math.imul(xa,Ta)|0,_i=_i+Math.imul(xa,va)|0,_i=_i+Math.imul(ha,Ta)|0,Bi=Bi+Math.imul(ha,va)|0,Ai=Ai+Math.imul(ca,Aa)|0,_i=_i+Math.imul(ca,_a)|0,_i=_i+Math.imul(la,Aa)|0,Bi=Bi+Math.imul(la,_a)|0,Ai=Ai+Math.imul(sa,Na)|0,_i=_i+Math.imul(sa,Rn)|0,_i=_i+Math.imul(ua,Na)|0,Bi=Bi+Math.imul(ua,Rn)|0,Ai=Ai+Math.imul(oa,Yi)|0,_i=_i+Math.imul(oa,Mn)|0,_i=_i+Math.imul(ta,Yi)|0,Bi=Bi+Math.imul(ta,Mn)|0,Ai=Ai+Math.imul(ea,ra)|0,_i=_i+Math.imul(ea,na)|0,_i=_i+Math.imul(ia,ra)|0,Bi=Bi+Math.imul(ia,na)|0,Ai=Ai+Math.imul(jn,ba)|0,_i=_i+Math.imul(jn,fa)|0,_i=_i+Math.imul(Ln,ba)|0,Bi=Bi+Math.imul(Ln,fa)|0,Ai=Ai+Math.imul(Ji,ma)|0,_i=_i+Math.imul(Ji,Da)|0,_i=_i+Math.imul(Xi,ma)|0,Bi=Bi+Math.imul(Xi,Da)|0,Ai=Ai+Math.imul(Ki,qa)|0,_i=_i+Math.imul(Ki,Oa)|0,_i=_i+Math.imul(Zi,qa)|0,Bi=Bi+Math.imul(Zi,Oa)|0;var Xa=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Xa>>>26)|0,Xa&=67108863,Ai=Math.imul(Ra,Ta),_i=Math.imul(Ra,va),_i=_i+Math.imul(pa,Ta)|0,Bi=Math.imul(pa,va),Ai=Ai+Math.imul(xa,Aa)|0,_i=_i+Math.imul(xa,_a)|0,_i=_i+Math.imul(ha,Aa)|0,Bi=Bi+Math.imul(ha,_a)|0,Ai=Ai+Math.imul(ca,Na)|0,_i=_i+Math.imul(ca,Rn)|0,_i=_i+Math.imul(la,Na)|0,Bi=Bi+Math.imul(la,Rn)|0,Ai=Ai+Math.imul(sa,Yi)|0,_i=_i+Math.imul(sa,Mn)|0,_i=_i+Math.imul(ua,Yi)|0,Bi=Bi+Math.imul(ua,Mn)|0,Ai=Ai+Math.imul(oa,ra)|0,_i=_i+Math.imul(oa,na)|0,_i=_i+Math.imul(ta,ra)|0,Bi=Bi+Math.imul(ta,na)|0,Ai=Ai+Math.imul(ea,ba)|0,_i=_i+Math.imul(ea,fa)|0,_i=_i+Math.imul(ia,ba)|0,Bi=Bi+Math.imul(ia,fa)|0,Ai=Ai+Math.imul(jn,ma)|0,_i=_i+Math.imul(jn,Da)|0,_i=_i+Math.imul(Ln,ma)|0,Bi=Bi+Math.imul(Ln,Da)|0,Ai=Ai+Math.imul(Ji,qa)|0,_i=_i+Math.imul(Ji,Oa)|0,_i=_i+Math.imul(Xi,qa)|0,Bi=Bi+Math.imul(Xi,Oa)|0;var Ja=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Ja>>>26)|0,Ja&=67108863,Ai=Math.imul(Ra,Aa),_i=Math.imul(Ra,_a),_i=_i+Math.imul(pa,Aa)|0,Bi=Math.imul(pa,_a),Ai=Ai+Math.imul(xa,Na)|0,_i=_i+Math.imul(xa,Rn)|0,_i=_i+Math.imul(ha,Na)|0,Bi=Bi+Math.imul(ha,Rn)|0,Ai=Ai+Math.imul(ca,Yi)|0,_i=_i+Math.imul(ca,Mn)|0,_i=_i+Math.imul(la,Yi)|0,Bi=Bi+Math.imul(la,Mn)|0,Ai=Ai+Math.imul(sa,ra)|0,_i=_i+Math.imul(sa,na)|0,_i=_i+Math.imul(ua,ra)|0,Bi=Bi+Math.imul(ua,na)|0,Ai=Ai+Math.imul(oa,ba)|0,_i=_i+Math.imul(oa,fa)|0,_i=_i+Math.imul(ta,ba)|0,Bi=Bi+Math.imul(ta,fa)|0,Ai=Ai+Math.imul(ea,ma)|0,_i=_i+Math.imul(ea,Da)|0,_i=_i+Math.imul(ia,ma)|0,Bi=Bi+Math.imul(ia,Da)|0,Ai=Ai+Math.imul(jn,qa)|0,_i=_i+Math.imul(jn,Oa)|0,_i=_i+Math.imul(Ln,qa)|0,Bi=Bi+Math.imul(Ln,Oa)|0;var Za=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Za>>>26)|0,Za&=67108863,Ai=Math.imul(Ra,Na),_i=Math.imul(Ra,Rn),_i=_i+Math.imul(pa,Na)|0,Bi=Math.imul(pa,Rn),Ai=Ai+Math.imul(xa,Yi)|0,_i=_i+Math.imul(xa,Mn)|0,_i=_i+Math.imul(ha,Yi)|0,Bi=Bi+Math.imul(ha,Mn)|0,Ai=Ai+Math.imul(ca,ra)|0,_i=_i+Math.imul(ca,na)|0,_i=_i+Math.imul(la,ra)|0,Bi=Bi+Math.imul(la,na)|0,Ai=Ai+Math.imul(sa,ba)|0,_i=_i+Math.imul(sa,fa)|0,_i=_i+Math.imul(ua,ba)|0,Bi=Bi+Math.imul(ua,fa)|0,Ai=Ai+Math.imul(oa,ma)|0,_i=_i+Math.imul(oa,Da)|0,_i=_i+Math.imul(ta,ma)|0,Bi=Bi+Math.imul(ta,Da)|0,Ai=Ai+Math.imul(ea,qa)|0,_i=_i+Math.imul(ea,Oa)|0,_i=_i+Math.imul(ia,qa)|0,Bi=Bi+Math.imul(ia,Oa)|0;var ao=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(ao>>>26)|0,ao&=67108863,Ai=Math.imul(Ra,Yi),_i=Math.imul(Ra,Mn),_i=_i+Math.imul(pa,Yi)|0,Bi=Math.imul(pa,Mn),Ai=Ai+Math.imul(xa,ra)|0,_i=_i+Math.imul(xa,na)|0,_i=_i+Math.imul(ha,ra)|0,Bi=Bi+Math.imul(ha,na)|0,Ai=Ai+Math.imul(ca,ba)|0,_i=_i+Math.imul(ca,fa)|0,_i=_i+Math.imul(la,ba)|0,Bi=Bi+Math.imul(la,fa)|0,Ai=Ai+Math.imul(sa,ma)|0,_i=_i+Math.imul(sa,Da)|0,_i=_i+Math.imul(ua,ma)|0,Bi=Bi+Math.imul(ua,Da)|0,Ai=Ai+Math.imul(oa,qa)|0,_i=_i+Math.imul(oa,Oa)|0,_i=_i+Math.imul(ta,qa)|0,Bi=Bi+Math.imul(ta,Oa)|0;var vo=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(vo>>>26)|0,vo&=67108863,Ai=Math.imul(Ra,ra),_i=Math.imul(Ra,na),_i=_i+Math.imul(pa,ra)|0,Bi=Math.imul(pa,na),Ai=Ai+Math.imul(xa,ba)|0,_i=_i+Math.imul(xa,fa)|0,_i=_i+Math.imul(ha,ba)|0,Bi=Bi+Math.imul(ha,fa)|0,Ai=Ai+Math.imul(ca,ma)|0,_i=_i+Math.imul(ca,Da)|0,_i=_i+Math.imul(la,ma)|0,Bi=Bi+Math.imul(la,Da)|0,Ai=Ai+Math.imul(sa,qa)|0,_i=_i+Math.imul(sa,Oa)|0,_i=_i+Math.imul(ua,qa)|0,Bi=Bi+Math.imul(ua,Oa)|0;var bo=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(bo>>>26)|0,bo&=67108863,Ai=Math.imul(Ra,ba),_i=Math.imul(Ra,fa),_i=_i+Math.imul(pa,ba)|0,Bi=Math.imul(pa,fa),Ai=Ai+Math.imul(xa,ma)|0,_i=_i+Math.imul(xa,Da)|0,_i=_i+Math.imul(ha,ma)|0,Bi=Bi+Math.imul(ha,Da)|0,Ai=Ai+Math.imul(ca,qa)|0,_i=_i+Math.imul(ca,Oa)|0,_i=_i+Math.imul(la,qa)|0,Bi=Bi+Math.imul(la,Oa)|0;var So=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(So>>>26)|0,So&=67108863,Ai=Math.imul(Ra,ma),_i=Math.imul(Ra,Da),_i=_i+Math.imul(pa,ma)|0,Bi=Math.imul(pa,Da),Ai=Ai+Math.imul(xa,qa)|0,_i=_i+Math.imul(xa,Oa)|0,_i=_i+Math.imul(ha,qa)|0,Bi=Bi+Math.imul(ha,Oa)|0;var To=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(To>>>26)|0,To&=67108863,Ai=Math.imul(Ra,qa),_i=Math.imul(Ra,Oa),_i=_i+Math.imul(pa,qa)|0,Bi=Math.imul(pa,Oa);var Co=(Si+Ai|0)+((_i&8191)<<13)|0;return Si=(Bi+(_i>>>13)|0)+(Co>>>26)|0,Co&=67108863,Mi[0]=Ua,Mi[1]=ja,Mi[2]=Va,Mi[3]=Ga,Mi[4]=Ka,Mi[5]=Ha,Mi[6]=Qa,Mi[7]=za,Mi[8]=Wa,Mi[9]=Ya,Mi[10]=Xa,Mi[11]=Ja,Mi[12]=Za,Mi[13]=ao,Mi[14]=vo,Mi[15]=bo,Mi[16]=So,Mi[17]=To,Mi[18]=Co,Si!==0&&(Mi[19]=Si,Ci.length++),Ci};Math.imul||(Ii=Ti);function qi(xi,yi,Ei){Ei.negative=yi.negative^xi.negative,Ei.length=xi.length+yi.length;for(var Ci=0,Ni=0,Fi=0;Fi<Ei.length-1;Fi++){var Mi=Ni;Ni=0;for(var Si=Ci&67108863,Ai=Math.min(Fi,yi.length-1),_i=Math.max(0,Fi-xi.length+1);_i<=Ai;_i++){var Bi=Fi-_i,Pi=xi.words[Bi]|0,zi=yi.words[_i]|0,Gi=Pi*zi,Vi=Gi&67108863;Mi=Mi+(Gi/67108864|0)|0,Vi=Vi+Si|0,Si=Vi&67108863,Mi=Mi+(Vi>>>26)|0,Ni+=Mi>>>26,Mi&=67108863}Ei.words[Fi]=Si,Ci=Mi,Mi=Ni}return Ci!==0?Ei.words[Fi]=Ci:Ei.length--,Ei._strip()}function Oi(xi,yi,Ei){return qi(xi,yi,Ei)}a.prototype.mulTo=function(yi,Ei){var Ci,Ni=this.length+yi.length;return this.length===10&&yi.length===10?Ci=Ii(this,yi,Ei):Ni<63?Ci=Ti(this,yi,Ei):Ni<1024?Ci=qi(this,yi,Ei):Ci=Oi(this,yi,Ei),Ci},a.prototype.mul=function(yi){var Ei=new a(null);return Ei.words=new Array(this.length+yi.length),this.mulTo(yi,Ei)},a.prototype.mulf=function(yi){var Ei=new a(null);return Ei.words=new Array(this.length+yi.length),Oi(this,yi,Ei)},a.prototype.imul=function(yi){return this.clone().mulTo(yi,this)},a.prototype.imuln=function(yi){var Ei=yi<0;Ei&&(yi=-yi),n(typeof yi=="number"),n(yi<67108864);for(var Ci=0,Ni=0;Ni<this.length;Ni++){var Fi=(this.words[Ni]|0)*yi,Mi=(Fi&67108863)+(Ci&67108863);Ci>>=26,Ci+=Fi/67108864|0,Ci+=Mi>>>26,this.words[Ni]=Mi&67108863}return Ci!==0&&(this.words[Ni]=Ci,this.length++),this.length=yi===0?1:this.length,Ei?this.ineg():this},a.prototype.muln=function(yi){return this.clone().imuln(yi)},a.prototype.sqr=function(){return this.mul(this)},a.prototype.isqr=function(){return this.imul(this.clone())},a.prototype.pow=function(yi){var Ei=Ri(yi);if(Ei.length===0)return new a(1);for(var Ci=this,Ni=0;Ni<Ei.length&&Ei[Ni]===0;Ni++,Ci=Ci.sqr());if(++Ni<Ei.length)for(var Fi=Ci.sqr();Ni<Ei.length;Ni++,Fi=Fi.sqr())Ei[Ni]!==0&&(Ci=Ci.mul(Fi));return Ci},a.prototype.iushln=function(yi){n(typeof yi=="number"&&yi>=0);var Ei=yi%26,Ci=(yi-Ei)/26,Ni=67108863>>>26-Ei<<26-Ei,Fi;if(Ei!==0){var Mi=0;for(Fi=0;Fi<this.length;Fi++){var Si=this.words[Fi]&Ni,Ai=(this.words[Fi]|0)-Si<<Ei;this.words[Fi]=Ai|Mi,Mi=Si>>>26-Ei}Mi&&(this.words[Fi]=Mi,this.length++)}if(Ci!==0){for(Fi=this.length-1;Fi>=0;Fi--)this.words[Fi+Ci]=this.words[Fi];for(Fi=0;Fi<Ci;Fi++)this.words[Fi]=0;this.length+=Ci}return this._strip()},a.prototype.ishln=function(yi){return n(this.negative===0),this.iushln(yi)},a.prototype.iushrn=function(yi,Ei,Ci){n(typeof yi=="number"&&yi>=0);var Ni;Ei?Ni=(Ei-Ei%26)/26:Ni=0;var Fi=yi%26,Mi=Math.min((yi-Fi)/26,this.length),Si=67108863^67108863>>>Fi<<Fi,Ai=Ci;if(Ni-=Mi,Ni=Math.max(0,Ni),Ai){for(var _i=0;_i<Mi;_i++)Ai.words[_i]=this.words[_i];Ai.length=Mi}if(Mi!==0)if(this.length>Mi)for(this.length-=Mi,_i=0;_i<this.length;_i++)this.words[_i]=this.words[_i+Mi];else this.words[0]=0,this.length=1;var Bi=0;for(_i=this.length-1;_i>=0&&(Bi!==0||_i>=Ni);_i--){var Pi=this.words[_i]|0;this.words[_i]=Bi<<26-Fi|Pi>>>Fi,Bi=Pi&Si}return Ai&&Bi!==0&&(Ai.words[Ai.length++]=Bi),this.length===0&&(this.words[0]=0,this.length=1),this._strip()},a.prototype.ishrn=function(yi,Ei,Ci){return n(this.negative===0),this.iushrn(yi,Ei,Ci)},a.prototype.shln=function(yi){return this.clone().ishln(yi)},a.prototype.ushln=function(yi){return this.clone().iushln(yi)},a.prototype.shrn=function(yi){return this.clone().ishrn(yi)},a.prototype.ushrn=function(yi){return this.clone().iushrn(yi)},a.prototype.testn=function(yi){n(typeof yi=="number"&&yi>=0);var Ei=yi%26,Ci=(yi-Ei)/26,Ni=1<<Ei;if(this.length<=Ci)return!1;var Fi=this.words[Ci];return!!(Fi&Ni)},a.prototype.imaskn=function(yi){n(typeof yi=="number"&&yi>=0);var Ei=yi%26,Ci=(yi-Ei)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=Ci)return this;if(Ei!==0&&Ci++,this.length=Math.min(Ci,this.length),Ei!==0){var Ni=67108863^67108863>>>Ei<<Ei;this.words[this.length-1]&=Ni}return this._strip()},a.prototype.maskn=function(yi){return this.clone().imaskn(yi)},a.prototype.iaddn=function(yi){return n(typeof yi=="number"),n(yi<67108864),yi<0?this.isubn(-yi):this.negative!==0?this.length===1&&(this.words[0]|0)<=yi?(this.words[0]=yi-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(yi),this.negative=1,this):this._iaddn(yi)},a.prototype._iaddn=function(yi){this.words[0]+=yi;for(var Ei=0;Ei<this.length&&this.words[Ei]>=67108864;Ei++)this.words[Ei]-=67108864,Ei===this.length-1?this.words[Ei+1]=1:this.words[Ei+1]++;return this.length=Math.max(this.length,Ei+1),this},a.prototype.isubn=function(yi){if(n(typeof yi=="number"),n(yi<67108864),yi<0)return this.iaddn(-yi);if(this.negative!==0)return this.negative=0,this.iaddn(yi),this.negative=1,this;if(this.words[0]-=yi,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var Ei=0;Ei<this.length&&this.words[Ei]<0;Ei++)this.words[Ei]+=67108864,this.words[Ei+1]-=1;return this._strip()},a.prototype.addn=function(yi){return this.clone().iaddn(yi)},a.prototype.subn=function(yi){return this.clone().isubn(yi)},a.prototype.iabs=function(){return this.negative=0,this},a.prototype.abs=function(){return this.clone().iabs()},a.prototype._ishlnsubmul=function(yi,Ei,Ci){var Ni=yi.length+Ci,Fi;this._expand(Ni);var Mi,Si=0;for(Fi=0;Fi<yi.length;Fi++){Mi=(this.words[Fi+Ci]|0)+Si;var Ai=(yi.words[Fi]|0)*Ei;Mi-=Ai&67108863,Si=(Mi>>26)-(Ai/67108864|0),this.words[Fi+Ci]=Mi&67108863}for(;Fi<this.length-Ci;Fi++)Mi=(this.words[Fi+Ci]|0)+Si,Si=Mi>>26,this.words[Fi+Ci]=Mi&67108863;if(Si===0)return this._strip();for(n(Si===-1),Si=0,Fi=0;Fi<this.length;Fi++)Mi=-(this.words[Fi]|0)+Si,Si=Mi>>26,this.words[Fi]=Mi&67108863;return this.negative=1,this._strip()},a.prototype._wordDiv=function(yi,Ei){var Ci=this.length-yi.length,Ni=this.clone(),Fi=yi,Mi=Fi.words[Fi.length-1]|0,Si=this._countBits(Mi);Ci=26-Si,Ci!==0&&(Fi=Fi.ushln(Ci),Ni.iushln(Ci),Mi=Fi.words[Fi.length-1]|0);var Ai=Ni.length-Fi.length,_i;if(Ei!=="mod"){_i=new a(null),_i.length=Ai+1,_i.words=new Array(_i.length);for(var Bi=0;Bi<_i.length;Bi++)_i.words[Bi]=0}var Pi=Ni.clone()._ishlnsubmul(Fi,1,Ai);Pi.negative===0&&(Ni=Pi,_i&&(_i.words[Ai]=1));for(var zi=Ai-1;zi>=0;zi--){var Gi=(Ni.words[Fi.length+zi]|0)*67108864+(Ni.words[Fi.length+zi-1]|0);for(Gi=Math.min(Gi/Mi|0,67108863),Ni._ishlnsubmul(Fi,Gi,zi);Ni.negative!==0;)Gi--,Ni.negative=0,Ni._ishlnsubmul(Fi,1,zi),Ni.isZero()||(Ni.negative^=1);_i&&(_i.words[zi]=Gi)}return _i&&_i._strip(),Ni._strip(),Ei!=="div"&&Ci!==0&&Ni.iushrn(Ci),{div:_i||null,mod:Ni}},a.prototype.divmod=function(yi,Ei,Ci){if(n(!yi.isZero()),this.isZero())return{div:new a(0),mod:new a(0)};var Ni,Fi,Mi;return this.negative!==0&&yi.negative===0?(Mi=this.neg().divmod(yi,Ei),Ei!=="mod"&&(Ni=Mi.div.neg()),Ei!=="div"&&(Fi=Mi.mod.neg(),Ci&&Fi.negative!==0&&Fi.iadd(yi)),{div:Ni,mod:Fi}):this.negative===0&&yi.negative!==0?(Mi=this.divmod(yi.neg(),Ei),Ei!=="mod"&&(Ni=Mi.div.neg()),{div:Ni,mod:Mi.mod}):(this.negative&yi.negative)!==0?(Mi=this.neg().divmod(yi.neg(),Ei),Ei!=="div"&&(Fi=Mi.mod.neg(),Ci&&Fi.negative!==0&&Fi.isub(yi)),{div:Mi.div,mod:Fi}):yi.length>this.length||this.cmp(yi)<0?{div:new a(0),mod:this}:yi.length===1?Ei==="div"?{div:this.divn(yi.words[0]),mod:null}:Ei==="mod"?{div:null,mod:new a(this.modrn(yi.words[0]))}:{div:this.divn(yi.words[0]),mod:new a(this.modrn(yi.words[0]))}:this._wordDiv(yi,Ei)},a.prototype.div=function(yi){return this.divmod(yi,"div",!1).div},a.prototype.mod=function(yi){return this.divmod(yi,"mod",!1).mod},a.prototype.umod=function(yi){return this.divmod(yi,"mod",!0).mod},a.prototype.divRound=function(yi){var Ei=this.divmod(yi);if(Ei.mod.isZero())return Ei.div;var Ci=Ei.div.negative!==0?Ei.mod.isub(yi):Ei.mod,Ni=yi.ushrn(1),Fi=yi.andln(1),Mi=Ci.cmp(Ni);return Mi<0||Fi===1&&Mi===0?Ei.div:Ei.div.negative!==0?Ei.div.isubn(1):Ei.div.iaddn(1)},a.prototype.modrn=function(yi){var Ei=yi<0;Ei&&(yi=-yi),n(yi<=67108863);for(var Ci=(1<<26)%yi,Ni=0,Fi=this.length-1;Fi>=0;Fi--)Ni=(Ci*Ni+(this.words[Fi]|0))%yi;return Ei?-Ni:Ni},a.prototype.modn=function(yi){return this.modrn(yi)},a.prototype.idivn=function(yi){var Ei=yi<0;Ei&&(yi=-yi),n(yi<=67108863);for(var Ci=0,Ni=this.length-1;Ni>=0;Ni--){var Fi=(this.words[Ni]|0)+Ci*67108864;this.words[Ni]=Fi/yi|0,Ci=Fi%yi}return this._strip(),Ei?this.ineg():this},a.prototype.divn=function(yi){return this.clone().idivn(yi)},a.prototype.egcd=function(yi){n(yi.negative===0),n(!yi.isZero());var Ei=this,Ci=yi.clone();Ei.negative!==0?Ei=Ei.umod(yi):Ei=Ei.clone();for(var Ni=new a(1),Fi=new a(0),Mi=new a(0),Si=new a(1),Ai=0;Ei.isEven()&&Ci.isEven();)Ei.iushrn(1),Ci.iushrn(1),++Ai;for(var _i=Ci.clone(),Bi=Ei.clone();!Ei.isZero();){for(var Pi=0,zi=1;(Ei.words[0]&zi)===0&&Pi<26;++Pi,zi<<=1);if(Pi>0)for(Ei.iushrn(Pi);Pi-- >0;)(Ni.isOdd()||Fi.isOdd())&&(Ni.iadd(_i),Fi.isub(Bi)),Ni.iushrn(1),Fi.iushrn(1);for(var Gi=0,Vi=1;(Ci.words[0]&Vi)===0&&Gi<26;++Gi,Vi<<=1);if(Gi>0)for(Ci.iushrn(Gi);Gi-- >0;)(Mi.isOdd()||Si.isOdd())&&(Mi.iadd(_i),Si.isub(Bi)),Mi.iushrn(1),Si.iushrn(1);Ei.cmp(Ci)>=0?(Ei.isub(Ci),Ni.isub(Mi),Fi.isub(Si)):(Ci.isub(Ei),Mi.isub(Ni),Si.isub(Fi))}return{a:Mi,b:Si,gcd:Ci.iushln(Ai)}},a.prototype._invmp=function(yi){n(yi.negative===0),n(!yi.isZero());var Ei=this,Ci=yi.clone();Ei.negative!==0?Ei=Ei.umod(yi):Ei=Ei.clone();for(var Ni=new a(1),Fi=new a(0),Mi=Ci.clone();Ei.cmpn(1)>0&&Ci.cmpn(1)>0;){for(var Si=0,Ai=1;(Ei.words[0]&Ai)===0&&Si<26;++Si,Ai<<=1);if(Si>0)for(Ei.iushrn(Si);Si-- >0;)Ni.isOdd()&&Ni.iadd(Mi),Ni.iushrn(1);for(var _i=0,Bi=1;(Ci.words[0]&Bi)===0&&_i<26;++_i,Bi<<=1);if(_i>0)for(Ci.iushrn(_i);_i-- >0;)Fi.isOdd()&&Fi.iadd(Mi),Fi.iushrn(1);Ei.cmp(Ci)>=0?(Ei.isub(Ci),Ni.isub(Fi)):(Ci.isub(Ei),Fi.isub(Ni))}var Pi;return Ei.cmpn(1)===0?Pi=Ni:Pi=Fi,Pi.cmpn(0)<0&&Pi.iadd(yi),Pi},a.prototype.gcd=function(yi){if(this.isZero())return yi.abs();if(yi.isZero())return this.abs();var Ei=this.clone(),Ci=yi.clone();Ei.negative=0,Ci.negative=0;for(var Ni=0;Ei.isEven()&&Ci.isEven();Ni++)Ei.iushrn(1),Ci.iushrn(1);do{for(;Ei.isEven();)Ei.iushrn(1);for(;Ci.isEven();)Ci.iushrn(1);var Fi=Ei.cmp(Ci);if(Fi<0){var Mi=Ei;Ei=Ci,Ci=Mi}else if(Fi===0||Ci.cmpn(1)===0)break;Ei.isub(Ci)}while(!0);return Ci.iushln(Ni)},a.prototype.invm=function(yi){return this.egcd(yi).a.umod(yi)},a.prototype.isEven=function(){return(this.words[0]&1)===0},a.prototype.isOdd=function(){return(this.words[0]&1)===1},a.prototype.andln=function(yi){return this.words[0]&yi},a.prototype.bincn=function(yi){n(typeof yi=="number");var Ei=yi%26,Ci=(yi-Ei)/26,Ni=1<<Ei;if(this.length<=Ci)return this._expand(Ci+1),this.words[Ci]|=Ni,this;for(var Fi=Ni,Mi=Ci;Fi!==0&&Mi<this.length;Mi++){var Si=this.words[Mi]|0;Si+=Fi,Fi=Si>>>26,Si&=67108863,this.words[Mi]=Si}return Fi!==0&&(this.words[Mi]=Fi,this.length++),this},a.prototype.isZero=function(){return this.length===1&&this.words[0]===0},a.prototype.cmpn=function(yi){var Ei=yi<0;if(this.negative!==0&&!Ei)return-1;if(this.negative===0&&Ei)return 1;this._strip();var Ci;if(this.length>1)Ci=1;else{Ei&&(yi=-yi),n(yi<=67108863,"Number is too big");var Ni=this.words[0]|0;Ci=Ni===yi?0:Ni<yi?-1:1}return this.negative!==0?-Ci|0:Ci},a.prototype.cmp=function(yi){if(this.negative!==0&&yi.negative===0)return-1;if(this.negative===0&&yi.negative!==0)return 1;var Ei=this.ucmp(yi);return this.negative!==0?-Ei|0:Ei},a.prototype.ucmp=function(yi){if(this.length>yi.length)return 1;if(this.length<yi.length)return-1;for(var Ei=0,Ci=this.length-1;Ci>=0;Ci--){var Ni=this.words[Ci]|0,Fi=yi.words[Ci]|0;if(Ni!==Fi){Ni<Fi?Ei=-1:Ni>Fi&&(Ei=1);break}}return Ei},a.prototype.gtn=function(yi){return this.cmpn(yi)===1},a.prototype.gt=function(yi){return this.cmp(yi)===1},a.prototype.gten=function(yi){return this.cmpn(yi)>=0},a.prototype.gte=function(yi){return this.cmp(yi)>=0},a.prototype.ltn=function(yi){return this.cmpn(yi)===-1},a.prototype.lt=function(yi){return this.cmp(yi)===-1},a.prototype.lten=function(yi){return this.cmpn(yi)<=0},a.prototype.lte=function(yi){return this.cmp(yi)<=0},a.prototype.eqn=function(yi){return this.cmpn(yi)===0},a.prototype.eq=function(yi){return this.cmp(yi)===0},a.red=function(yi){return new $i(yi)},a.prototype.toRed=function(yi){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),yi.convertTo(this)._forceRed(yi)},a.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},a.prototype._forceRed=function(yi){return this.red=yi,this},a.prototype.forceRed=function(yi){return n(!this.red,"Already a number in reduction context"),this._forceRed(yi)},a.prototype.redAdd=function(yi){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,yi)},a.prototype.redIAdd=function(yi){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,yi)},a.prototype.redSub=function(yi){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,yi)},a.prototype.redISub=function(yi){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,yi)},a.prototype.redShl=function(yi){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,yi)},a.prototype.redMul=function(yi){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,yi),this.red.mul(this,yi)},a.prototype.redIMul=function(yi){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,yi),this.red.imul(this,yi)},a.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},a.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},a.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},a.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},a.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},a.prototype.redPow=function(yi){return n(this.red&&!yi.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,yi)};var ki={k256:null,p224:null,p192:null,p25519:null};function Li(xi,yi){this.name=xi,this.p=new a(yi,16),this.n=this.p.bitLength(),this.k=new a(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}Li.prototype._tmp=function(){var yi=new a(null);return yi.words=new Array(Math.ceil(this.n/13)),yi},Li.prototype.ireduce=function(yi){var Ei=yi,Ci;do this.split(Ei,this.tmp),Ei=this.imulK(Ei),Ei=Ei.iadd(this.tmp),Ci=Ei.bitLength();while(Ci>this.n);var Ni=Ci<this.n?-1:Ei.ucmp(this.p);return Ni===0?(Ei.words[0]=0,Ei.length=1):Ni>0?Ei.isub(this.p):Ei.strip!==void 0?Ei.strip():Ei._strip(),Ei},Li.prototype.split=function(yi,Ei){yi.iushrn(this.n,0,Ei)},Li.prototype.imulK=function(yi){return yi.imul(this.k)};function ji(){Li.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}s(ji,Li),ji.prototype.split=function(yi,Ei){for(var Ci=4194303,Ni=Math.min(yi.length,9),Fi=0;Fi<Ni;Fi++)Ei.words[Fi]=yi.words[Fi];if(Ei.length=Ni,yi.length<=9){yi.words[0]=0,yi.length=1;return}var Mi=yi.words[9];for(Ei.words[Ei.length++]=Mi&Ci,Fi=10;Fi<yi.length;Fi++){var Si=yi.words[Fi]|0;yi.words[Fi-10]=(Si&Ci)<<4|Mi>>>22,Mi=Si}Mi>>>=22,yi.words[Fi-10]=Mi,Mi===0&&yi.length>10?yi.length-=10:yi.length-=9},ji.prototype.imulK=function(yi){yi.words[yi.length]=0,yi.words[yi.length+1]=0,yi.length+=2;for(var Ei=0,Ci=0;Ci<yi.length;Ci++){var Ni=yi.words[Ci]|0;Ei+=Ni*977,yi.words[Ci]=Ei&67108863,Ei=Ni*64+(Ei/67108864|0)}return yi.words[yi.length-1]===0&&(yi.length--,yi.words[yi.length-1]===0&&yi.length--),yi};function Hi(){Li.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}s(Hi,Li);function Ui(){Li.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}s(Ui,Li);function Qi(){Li.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}s(Qi,Li),Qi.prototype.imulK=function(yi){for(var Ei=0,Ci=0;Ci<yi.length;Ci++){var Ni=(yi.words[Ci]|0)*19+Ei,Fi=Ni&67108863;Ni>>>=26,yi.words[Ci]=Fi,Ei=Ni}return Ei!==0&&(yi.words[yi.length++]=Ei),yi},a._prime=function(yi){if(ki[yi])return ki[yi];var Ei;if(yi==="k256")Ei=new ji;else if(yi==="p224")Ei=new Hi;else if(yi==="p192")Ei=new Ui;else if(yi==="p25519")Ei=new Qi;else throw new Error("Unknown prime "+yi);return ki[yi]=Ei,Ei};function $i(xi){if(typeof xi=="string"){var yi=a._prime(xi);this.m=yi.p,this.prime=yi}else n(xi.gtn(1),"modulus must be greater than 1"),this.m=xi,this.prime=null}$i.prototype._verify1=function(yi){n(yi.negative===0,"red works only with positives"),n(yi.red,"red works only with red numbers")},$i.prototype._verify2=function(yi,Ei){n((yi.negative|Ei.negative)===0,"red works only with positives"),n(yi.red&&yi.red===Ei.red,"red works only with red numbers")},$i.prototype.imod=function(yi){return this.prime?this.prime.ireduce(yi)._forceRed(this):(l(yi,yi.umod(this.m)._forceRed(this)),yi)},$i.prototype.neg=function(yi){return yi.isZero()?yi.clone():this.m.sub(yi)._forceRed(this)},$i.prototype.add=function(yi,Ei){this._verify2(yi,Ei);var Ci=yi.add(Ei);return Ci.cmp(this.m)>=0&&Ci.isub(this.m),Ci._forceRed(this)},$i.prototype.iadd=function(yi,Ei){this._verify2(yi,Ei);var Ci=yi.iadd(Ei);return Ci.cmp(this.m)>=0&&Ci.isub(this.m),Ci},$i.prototype.sub=function(yi,Ei){this._verify2(yi,Ei);var Ci=yi.sub(Ei);return Ci.cmpn(0)<0&&Ci.iadd(this.m),Ci._forceRed(this)},$i.prototype.isub=function(yi,Ei){this._verify2(yi,Ei);var Ci=yi.isub(Ei);return Ci.cmpn(0)<0&&Ci.iadd(this.m),Ci},$i.prototype.shl=function(yi,Ei){return this._verify1(yi),this.imod(yi.ushln(Ei))},$i.prototype.imul=function(yi,Ei){return this._verify2(yi,Ei),this.imod(yi.imul(Ei))},$i.prototype.mul=function(yi,Ei){return this._verify2(yi,Ei),this.imod(yi.mul(Ei))},$i.prototype.isqr=function(yi){return this.imul(yi,yi.clone())},$i.prototype.sqr=function(yi){return this.mul(yi,yi)},$i.prototype.sqrt=function(yi){if(yi.isZero())return yi.clone();var Ei=this.m.andln(3);if(n(Ei%2===1),Ei===3){var Ci=this.m.add(new a(1)).iushrn(2);return this.pow(yi,Ci)}for(var Ni=this.m.subn(1),Fi=0;!Ni.isZero()&&Ni.andln(1)===0;)Fi++,Ni.iushrn(1);n(!Ni.isZero());var Mi=new a(1).toRed(this),Si=Mi.redNeg(),Ai=this.m.subn(1).iushrn(1),_i=this.m.bitLength();for(_i=new a(2*_i*_i).toRed(this);this.pow(_i,Ai).cmp(Si)!==0;)_i.redIAdd(Si);for(var Bi=this.pow(_i,Ni),Pi=this.pow(yi,Ni.addn(1).iushrn(1)),zi=this.pow(yi,Ni),Gi=Fi;zi.cmp(Mi)!==0;){for(var Vi=zi,Ki=0;Vi.cmp(Mi)!==0;Ki++)Vi=Vi.redSqr();n(Ki<Gi);var Zi=this.pow(Bi,new a(1).iushln(Gi-Ki-1));Pi=Pi.redMul(Zi),Bi=Zi.redSqr(),zi=zi.redMul(Bi),Gi=Ki}return Pi},$i.prototype.invm=function(yi){var Ei=yi._invmp(this.m);return Ei.negative!==0?(Ei.negative=0,this.imod(Ei).redNeg()):this.imod(Ei)},$i.prototype.pow=function(yi,Ei){if(Ei.isZero())return new a(1).toRed(this);if(Ei.cmpn(1)===0)return yi.clone();var Ci=4,Ni=new Array(1<<Ci);Ni[0]=new a(1).toRed(this),Ni[1]=yi;for(var Fi=2;Fi<Ni.length;Fi++)Ni[Fi]=this.mul(Ni[Fi-1],yi);var Mi=Ni[0],Si=0,Ai=0,_i=Ei.bitLength()%26;for(_i===0&&(_i=26),Fi=Ei.length-1;Fi>=0;Fi--){for(var Bi=Ei.words[Fi],Pi=_i-1;Pi>=0;Pi--){var zi=Bi>>Pi&1;if(Mi!==Ni[0]&&(Mi=this.sqr(Mi)),zi===0&&Si===0){Ai=0;continue}Si<<=1,Si|=zi,Ai++,!(Ai!==Ci&&(Fi!==0||Pi!==0))&&(Mi=this.mul(Mi,Ni[Si]),Ai=0,Si=0)}_i=26}return Mi},$i.prototype.convertTo=function(yi){var Ei=yi.umod(this.m);return Ei===yi?Ei.clone():Ei},$i.prototype.convertFrom=function(yi){var Ei=yi.clone();return Ei.red=null,Ei},a.mont=function(yi){return new wi(yi)};function wi(xi){$i.call(this,xi),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new a(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}s(wi,$i),wi.prototype.convertTo=function(yi){return this.imod(yi.ushln(this.shift))},wi.prototype.convertFrom=function(yi){var Ei=this.imod(yi.mul(this.rinv));return Ei.red=null,Ei},wi.prototype.imul=function(yi,Ei){if(yi.isZero()||Ei.isZero())return yi.words[0]=0,yi.length=1,yi;var Ci=yi.imul(Ei),Ni=Ci.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Fi=Ci.isub(Ni).iushrn(this.shift),Mi=Fi;return Fi.cmp(this.m)>=0?Mi=Fi.isub(this.m):Fi.cmpn(0)<0&&(Mi=Fi.iadd(this.m)),Mi._forceRed(this)},wi.prototype.mul=function(yi,Ei){if(yi.isZero()||Ei.isZero())return new a(0)._forceRed(this);var Ci=yi.mul(Ei),Ni=Ci.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Fi=Ci.isub(Ni).iushrn(this.shift),Mi=Fi;return Fi.cmp(this.m)>=0?Mi=Fi.isub(this.m):Fi.cmpn(0)<0&&(Mi=Fi.iadd(this.m)),Mi._forceRed(this)},wi.prototype.invm=function(yi){var Ei=this.imod(yi._invmp(this.m).mul(this.r2));return Ei._forceRed(this)}})(r,bn$2)}(bn$3)),bn$3.exports}var browserifyRsa,hasRequiredBrowserifyRsa;function requireBrowserifyRsa(){if(hasRequiredBrowserifyRsa)return browserifyRsa;hasRequiredBrowserifyRsa=1;var r=requireBn$1(),t=requireBrowser$b(),i=requireSafeBuffer$1().Buffer;function n(h){var v=h.modulus.byteLength(),hi;do hi=new r(t(v));while(hi.cmp(h.modulus)>=0||!hi.umod(h.prime1)||!hi.umod(h.prime2));return hi}function s(h){var v=n(h),hi=v.toRed(r.mont(h.modulus)).redPow(new r(h.publicExponent)).fromRed();return{blinder:hi,unblinder:v.invm(h.modulus)}}function a(h,v){var hi=s(v),u=v.modulus.byteLength(),l=new r(h).mul(hi.blinder).umod(v.modulus),vi=l.toRed(r.mont(v.prime1)),D=l.toRed(r.mont(v.prime2)),mi=v.coefficient,gi=v.prime1,bi=v.prime2,Ri=vi.redPow(v.exponent1).fromRed(),Ti=D.redPow(v.exponent2).fromRed(),Ii=Ri.isub(Ti).imul(mi).umod(gi).imul(bi);return Ti.iadd(Ii).imul(hi.unblinder).umod(v.modulus).toArrayLike(i,"be",u)}return a.getr=n,browserifyRsa=a,browserifyRsa}var elliptic={};const version$1="6.6.1";var require$$0$1={version:version$1},utils$2={},utils$1={},hasRequiredUtils$2;function requireUtils$2(){return hasRequiredUtils$2||(hasRequiredUtils$2=1,function(r){var t=r;function i(a,h){if(Array.isArray(a))return a.slice();if(!a)return[];var v=[];if(typeof a!="string"){for(var hi=0;hi<a.length;hi++)v[hi]=a[hi]|0;return v}if(h==="hex"){a=a.replace(/[^a-z0-9]+/ig,""),a.length%2!==0&&(a="0"+a);for(var hi=0;hi<a.length;hi+=2)v.push(parseInt(a[hi]+a[hi+1],16))}else for(var hi=0;hi<a.length;hi++){var u=a.charCodeAt(hi),l=u>>8,vi=u&255;l?v.push(l,vi):v.push(vi)}return v}t.toArray=i;function n(a){return a.length===1?"0"+a:a}t.zero2=n;function s(a){for(var h="",v=0;v<a.length;v++)h+=n(a[v].toString(16));return h}t.toHex=s,t.encode=function(h,v){return v==="hex"?s(h):h}}(utils$1)),utils$1}var hasRequiredUtils$1;function requireUtils$1(){return hasRequiredUtils$1||(hasRequiredUtils$1=1,function(r){var t=r,i=requireBn$2(),n=requireMinimalisticAssert(),s=requireUtils$2();t.assert=n,t.toArray=s.toArray,t.zero2=s.zero2,t.toHex=s.toHex,t.encode=s.encode;function a(l,vi,D){var mi=new Array(Math.max(l.bitLength(),D)+1),gi;for(gi=0;gi<mi.length;gi+=1)mi[gi]=0;var bi=1<<vi+1,Ri=l.clone();for(gi=0;gi<mi.length;gi++){var Ti,Ii=Ri.andln(bi-1);Ri.isOdd()?(Ii>(bi>>1)-1?Ti=(bi>>1)-Ii:Ti=Ii,Ri.isubn(Ti)):Ti=0,mi[gi]=Ti,Ri.iushrn(1)}return mi}t.getNAF=a;function h(l,vi){var D=[[],[]];l=l.clone(),vi=vi.clone();for(var mi=0,gi=0,bi;l.cmpn(-mi)>0||vi.cmpn(-gi)>0;){var Ri=l.andln(3)+mi&3,Ti=vi.andln(3)+gi&3;Ri===3&&(Ri=-1),Ti===3&&(Ti=-1);var Ii;(Ri&1)===0?Ii=0:(bi=l.andln(7)+mi&7,(bi===3||bi===5)&&Ti===2?Ii=-Ri:Ii=Ri),D[0].push(Ii);var qi;(Ti&1)===0?qi=0:(bi=vi.andln(7)+gi&7,(bi===3||bi===5)&&Ri===2?qi=-Ti:qi=Ti),D[1].push(qi),2*mi===Ii+1&&(mi=1-mi),2*gi===qi+1&&(gi=1-gi),l.iushrn(1),vi.iushrn(1)}return D}t.getJSF=h;function v(l,vi,D){var mi="_"+vi;l.prototype[vi]=function(){return this[mi]!==void 0?this[mi]:this[mi]=D.call(this)}}t.cachedProperty=v;function hi(l){return typeof l=="string"?t.toArray(l,"hex"):l}t.parseBytes=hi;function u(l){return new i(l,"hex","le")}t.intFromLE=u}(utils$2)),utils$2}var curve={},base$1,hasRequiredBase$1;function requireBase$1(){if(hasRequiredBase$1)return base$1;hasRequiredBase$1=1;var r=requireBn$2(),t=requireUtils$1(),i=t.getNAF,n=t.getJSF,s=t.assert;function a(v,hi){this.type=v,this.p=new r(hi.p,16),this.red=hi.prime?r.red(hi.prime):r.mont(this.p),this.zero=new r(0).toRed(this.red),this.one=new r(1).toRed(this.red),this.two=new r(2).toRed(this.red),this.n=hi.n&&new r(hi.n,16),this.g=hi.g&&this.pointFromJSON(hi.g,hi.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var u=this.n&&this.p.div(this.n);!u||u.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}base$1=a,a.prototype.point=function(){throw new Error("Not implemented")},a.prototype.validate=function(){throw new Error("Not implemented")},a.prototype._fixedNafMul=function(hi,u){s(hi.precomputed);var l=hi._getDoubles(),vi=i(u,1,this._bitLength),D=(1<<l.step+1)-(l.step%2===0?2:1);D/=3;var mi=[],gi,bi;for(gi=0;gi<vi.length;gi+=l.step){bi=0;for(var Ri=gi+l.step-1;Ri>=gi;Ri--)bi=(bi<<1)+vi[Ri];mi.push(bi)}for(var Ti=this.jpoint(null,null,null),Ii=this.jpoint(null,null,null),qi=D;qi>0;qi--){for(gi=0;gi<mi.length;gi++)bi=mi[gi],bi===qi?Ii=Ii.mixedAdd(l.points[gi]):bi===-qi&&(Ii=Ii.mixedAdd(l.points[gi].neg()));Ti=Ti.add(Ii)}return Ti.toP()},a.prototype._wnafMul=function(hi,u){var l=4,vi=hi._getNAFPoints(l);l=vi.wnd;for(var D=vi.points,mi=i(u,l,this._bitLength),gi=this.jpoint(null,null,null),bi=mi.length-1;bi>=0;bi--){for(var Ri=0;bi>=0&&mi[bi]===0;bi--)Ri++;if(bi>=0&&Ri++,gi=gi.dblp(Ri),bi<0)break;var Ti=mi[bi];s(Ti!==0),hi.type==="affine"?Ti>0?gi=gi.mixedAdd(D[Ti-1>>1]):gi=gi.mixedAdd(D[-Ti-1>>1].neg()):Ti>0?gi=gi.add(D[Ti-1>>1]):gi=gi.add(D[-Ti-1>>1].neg())}return hi.type==="affine"?gi.toP():gi},a.prototype._wnafMulAdd=function(hi,u,l,vi,D){var mi=this._wnafT1,gi=this._wnafT2,bi=this._wnafT3,Ri=0,Ti,Ii,qi;for(Ti=0;Ti<vi;Ti++){qi=u[Ti];var Oi=qi._getNAFPoints(hi);mi[Ti]=Oi.wnd,gi[Ti]=Oi.points}for(Ti=vi-1;Ti>=1;Ti-=2){var ki=Ti-1,Li=Ti;if(mi[ki]!==1||mi[Li]!==1){bi[ki]=i(l[ki],mi[ki],this._bitLength),bi[Li]=i(l[Li],mi[Li],this._bitLength),Ri=Math.max(bi[ki].length,Ri),Ri=Math.max(bi[Li].length,Ri);continue}var ji=[u[ki],null,null,u[Li]];u[ki].y.cmp(u[Li].y)===0?(ji[1]=u[ki].add(u[Li]),ji[2]=u[ki].toJ().mixedAdd(u[Li].neg())):u[ki].y.cmp(u[Li].y.redNeg())===0?(ji[1]=u[ki].toJ().mixedAdd(u[Li]),ji[2]=u[ki].add(u[Li].neg())):(ji[1]=u[ki].toJ().mixedAdd(u[Li]),ji[2]=u[ki].toJ().mixedAdd(u[Li].neg()));var Hi=[-3,-1,-5,-7,0,7,5,1,3],Ui=n(l[ki],l[Li]);for(Ri=Math.max(Ui[0].length,Ri),bi[ki]=new Array(Ri),bi[Li]=new Array(Ri),Ii=0;Ii<Ri;Ii++){var Qi=Ui[0][Ii]|0,$i=Ui[1][Ii]|0;bi[ki][Ii]=Hi[(Qi+1)*3+($i+1)],bi[Li][Ii]=0,gi[ki]=ji}}var wi=this.jpoint(null,null,null),xi=this._wnafT4;for(Ti=Ri;Ti>=0;Ti--){for(var yi=0;Ti>=0;){var Ei=!0;for(Ii=0;Ii<vi;Ii++)xi[Ii]=bi[Ii][Ti]|0,xi[Ii]!==0&&(Ei=!1);if(!Ei)break;yi++,Ti--}if(Ti>=0&&yi++,wi=wi.dblp(yi),Ti<0)break;for(Ii=0;Ii<vi;Ii++){var Ci=xi[Ii];Ci!==0&&(Ci>0?qi=gi[Ii][Ci-1>>1]:Ci<0&&(qi=gi[Ii][-Ci-1>>1].neg()),qi.type==="affine"?wi=wi.mixedAdd(qi):wi=wi.add(qi))}}for(Ti=0;Ti<vi;Ti++)gi[Ti]=null;return D?wi:wi.toP()};function h(v,hi){this.curve=v,this.type=hi,this.precomputed=null}return a.BasePoint=h,h.prototype.eq=function(){throw new Error("Not implemented")},h.prototype.validate=function(){return this.curve.validate(this)},a.prototype.decodePoint=function(hi,u){hi=t.toArray(hi,u);var l=this.p.byteLength();if((hi[0]===4||hi[0]===6||hi[0]===7)&&hi.length-1===2*l){hi[0]===6?s(hi[hi.length-1]%2===0):hi[0]===7&&s(hi[hi.length-1]%2===1);var vi=this.point(hi.slice(1,1+l),hi.slice(1+l,1+2*l));return vi}else if((hi[0]===2||hi[0]===3)&&hi.length-1===l)return this.pointFromX(hi.slice(1,1+l),hi[0]===3);throw new Error("Unknown point format")},h.prototype.encodeCompressed=function(hi){return this.encode(hi,!0)},h.prototype._encode=function(hi){var u=this.curve.p.byteLength(),l=this.getX().toArray("be",u);return hi?[this.getY().isEven()?2:3].concat(l):[4].concat(l,this.getY().toArray("be",u))},h.prototype.encode=function(hi,u){return t.encode(this._encode(u),hi)},h.prototype.precompute=function(hi){if(this.precomputed)return this;var u={doubles:null,naf:null,beta:null};return u.naf=this._getNAFPoints(8),u.doubles=this._getDoubles(4,hi),u.beta=this._getBeta(),this.precomputed=u,this},h.prototype._hasDoubles=function(hi){if(!this.precomputed)return!1;var u=this.precomputed.doubles;return u?u.points.length>=Math.ceil((hi.bitLength()+1)/u.step):!1},h.prototype._getDoubles=function(hi,u){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var l=[this],vi=this,D=0;D<u;D+=hi){for(var mi=0;mi<hi;mi++)vi=vi.dbl();l.push(vi)}return{step:hi,points:l}},h.prototype._getNAFPoints=function(hi){if(this.precomputed&&this.precomputed.naf)return this.precomputed.naf;for(var u=[this],l=(1<<hi)-1,vi=l===1?null:this.dbl(),D=1;D<l;D++)u[D]=u[D-1].add(vi);return{wnd:hi,points:u}},h.prototype._getBeta=function(){return null},h.prototype.dblp=function(hi){for(var u=this,l=0;l<hi;l++)u=u.dbl();return u},base$1}var short,hasRequiredShort;function requireShort(){if(hasRequiredShort)return short;hasRequiredShort=1;var r=requireUtils$1(),t=requireBn$2(),i=requireInherits_browser(),n=requireBase$1(),s=r.assert;function a(hi){n.call(this,"short",hi),this.a=new t(hi.a,16).toRed(this.red),this.b=new t(hi.b,16).toRed(this.red),this.tinv=this.two.redInvm(),this.zeroA=this.a.fromRed().cmpn(0)===0,this.threeA=this.a.fromRed().sub(this.p).cmpn(-3)===0,this.endo=this._getEndomorphism(hi),this._endoWnafT1=new Array(4),this._endoWnafT2=new Array(4)}i(a,n),short=a,a.prototype._getEndomorphism=function(u){if(!(!this.zeroA||!this.g||!this.n||this.p.modn(3)!==1)){var l,vi;if(u.beta)l=new t(u.beta,16).toRed(this.red);else{var D=this._getEndoRoots(this.p);l=D[0].cmp(D[1])<0?D[0]:D[1],l=l.toRed(this.red)}if(u.lambda)vi=new t(u.lambda,16);else{var mi=this._getEndoRoots(this.n);this.g.mul(mi[0]).x.cmp(this.g.x.redMul(l))===0?vi=mi[0]:(vi=mi[1],s(this.g.mul(vi).x.cmp(this.g.x.redMul(l))===0))}var gi;return u.basis?gi=u.basis.map(function(bi){return{a:new t(bi.a,16),b:new t(bi.b,16)}}):gi=this._getEndoBasis(vi),{beta:l,lambda:vi,basis:gi}}},a.prototype._getEndoRoots=function(u){var l=u===this.p?this.red:t.mont(u),vi=new t(2).toRed(l).redInvm(),D=vi.redNeg(),mi=new t(3).toRed(l).redNeg().redSqrt().redMul(vi),gi=D.redAdd(mi).fromRed(),bi=D.redSub(mi).fromRed();return[gi,bi]},a.prototype._getEndoBasis=function(u){for(var l=this.n.ushrn(Math.floor(this.n.bitLength()/2)),vi=u,D=this.n.clone(),mi=new t(1),gi=new t(0),bi=new t(0),Ri=new t(1),Ti,Ii,qi,Oi,ki,Li,ji,Hi=0,Ui,Qi;vi.cmpn(0)!==0;){var $i=D.div(vi);Ui=D.sub($i.mul(vi)),Qi=bi.sub($i.mul(mi));var wi=Ri.sub($i.mul(gi));if(!qi&&Ui.cmp(l)<0)Ti=ji.neg(),Ii=mi,qi=Ui.neg(),Oi=Qi;else if(qi&&++Hi===2)break;ji=Ui,D=vi,vi=Ui,bi=mi,mi=Qi,Ri=gi,gi=wi}ki=Ui.neg(),Li=Qi;var xi=qi.sqr().add(Oi.sqr()),yi=ki.sqr().add(Li.sqr());return yi.cmp(xi)>=0&&(ki=Ti,Li=Ii),qi.negative&&(qi=qi.neg(),Oi=Oi.neg()),ki.negative&&(ki=ki.neg(),Li=Li.neg()),[{a:qi,b:Oi},{a:ki,b:Li}]},a.prototype._endoSplit=function(u){var l=this.endo.basis,vi=l[0],D=l[1],mi=D.b.mul(u).divRound(this.n),gi=vi.b.neg().mul(u).divRound(this.n),bi=mi.mul(vi.a),Ri=gi.mul(D.a),Ti=mi.mul(vi.b),Ii=gi.mul(D.b),qi=u.sub(bi).sub(Ri),Oi=Ti.add(Ii).neg();return{k1:qi,k2:Oi}},a.prototype.pointFromX=function(u,l){u=new t(u,16),u.red||(u=u.toRed(this.red));var vi=u.redSqr().redMul(u).redIAdd(u.redMul(this.a)).redIAdd(this.b),D=vi.redSqrt();if(D.redSqr().redSub(vi).cmp(this.zero)!==0)throw new Error("invalid point");var mi=D.fromRed().isOdd();return(l&&!mi||!l&&mi)&&(D=D.redNeg()),this.point(u,D)},a.prototype.validate=function(u){if(u.inf)return!0;var l=u.x,vi=u.y,D=this.a.redMul(l),mi=l.redSqr().redMul(l).redIAdd(D).redIAdd(this.b);return vi.redSqr().redISub(mi).cmpn(0)===0},a.prototype._endoWnafMulAdd=function(u,l,vi){for(var D=this._endoWnafT1,mi=this._endoWnafT2,gi=0;gi<u.length;gi++){var bi=this._endoSplit(l[gi]),Ri=u[gi],Ti=Ri._getBeta();bi.k1.negative&&(bi.k1.ineg(),Ri=Ri.neg(!0)),bi.k2.negative&&(bi.k2.ineg(),Ti=Ti.neg(!0)),D[gi*2]=Ri,D[gi*2+1]=Ti,mi[gi*2]=bi.k1,mi[gi*2+1]=bi.k2}for(var Ii=this._wnafMulAdd(1,D,mi,gi*2,vi),qi=0;qi<gi*2;qi++)D[qi]=null,mi[qi]=null;return Ii};function h(hi,u,l,vi){n.BasePoint.call(this,hi,"affine"),u===null&&l===null?(this.x=null,this.y=null,this.inf=!0):(this.x=new t(u,16),this.y=new t(l,16),vi&&(this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.inf=!1)}i(h,n.BasePoint),a.prototype.point=function(u,l,vi){return new h(this,u,l,vi)},a.prototype.pointFromJSON=function(u,l){return h.fromJSON(this,u,l)},h.prototype._getBeta=function(){if(this.curve.endo){var u=this.precomputed;if(u&&u.beta)return u.beta;var l=this.curve.point(this.x.redMul(this.curve.endo.beta),this.y);if(u){var vi=this.curve,D=function(mi){return vi.point(mi.x.redMul(vi.endo.beta),mi.y)};u.beta=l,l.precomputed={beta:null,naf:u.naf&&{wnd:u.naf.wnd,points:u.naf.points.map(D)},doubles:u.doubles&&{step:u.doubles.step,points:u.doubles.points.map(D)}}}return l}},h.prototype.toJSON=function(){return this.precomputed?[this.x,this.y,this.precomputed&&{doubles:this.precomputed.doubles&&{step:this.precomputed.doubles.step,points:this.precomputed.doubles.points.slice(1)},naf:this.precomputed.naf&&{wnd:this.precomputed.naf.wnd,points:this.precomputed.naf.points.slice(1)}}]:[this.x,this.y]},h.fromJSON=function(u,l,vi){typeof l=="string"&&(l=JSON.parse(l));var D=u.point(l[0],l[1],vi);if(!l[2])return D;function mi(bi){return u.point(bi[0],bi[1],vi)}var gi=l[2];return D.precomputed={beta:null,doubles:gi.doubles&&{step:gi.doubles.step,points:[D].concat(gi.doubles.points.map(mi))},naf:gi.naf&&{wnd:gi.naf.wnd,points:[D].concat(gi.naf.points.map(mi))}},D},h.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+">"},h.prototype.isInfinity=function(){return this.inf},h.prototype.add=function(u){if(this.inf)return u;if(u.inf)return this;if(this.eq(u))return this.dbl();if(this.neg().eq(u))return this.curve.point(null,null);if(this.x.cmp(u.x)===0)return this.curve.point(null,null);var l=this.y.redSub(u.y);l.cmpn(0)!==0&&(l=l.redMul(this.x.redSub(u.x).redInvm()));var vi=l.redSqr().redISub(this.x).redISub(u.x),D=l.redMul(this.x.redSub(vi)).redISub(this.y);return this.curve.point(vi,D)},h.prototype.dbl=function(){if(this.inf)return this;var u=this.y.redAdd(this.y);if(u.cmpn(0)===0)return this.curve.point(null,null);var l=this.curve.a,vi=this.x.redSqr(),D=u.redInvm(),mi=vi.redAdd(vi).redIAdd(vi).redIAdd(l).redMul(D),gi=mi.redSqr().redISub(this.x.redAdd(this.x)),bi=mi.redMul(this.x.redSub(gi)).redISub(this.y);return this.curve.point(gi,bi)},h.prototype.getX=function(){return this.x.fromRed()},h.prototype.getY=function(){return this.y.fromRed()},h.prototype.mul=function(u){return u=new t(u,16),this.isInfinity()?this:this._hasDoubles(u)?this.curve._fixedNafMul(this,u):this.curve.endo?this.curve._endoWnafMulAdd([this],[u]):this.curve._wnafMul(this,u)},h.prototype.mulAdd=function(u,l,vi){var D=[this,l],mi=[u,vi];return this.curve.endo?this.curve._endoWnafMulAdd(D,mi):this.curve._wnafMulAdd(1,D,mi,2)},h.prototype.jmulAdd=function(u,l,vi){var D=[this,l],mi=[u,vi];return this.curve.endo?this.curve._endoWnafMulAdd(D,mi,!0):this.curve._wnafMulAdd(1,D,mi,2,!0)},h.prototype.eq=function(u){return this===u||this.inf===u.inf&&(this.inf||this.x.cmp(u.x)===0&&this.y.cmp(u.y)===0)},h.prototype.neg=function(u){if(this.inf)return this;var l=this.curve.point(this.x,this.y.redNeg());if(u&&this.precomputed){var vi=this.precomputed,D=function(mi){return mi.neg()};l.precomputed={naf:vi.naf&&{wnd:vi.naf.wnd,points:vi.naf.points.map(D)},doubles:vi.doubles&&{step:vi.doubles.step,points:vi.doubles.points.map(D)}}}return l},h.prototype.toJ=function(){if(this.inf)return this.curve.jpoint(null,null,null);var u=this.curve.jpoint(this.x,this.y,this.curve.one);return u};function v(hi,u,l,vi){n.BasePoint.call(this,hi,"jacobian"),u===null&&l===null&&vi===null?(this.x=this.curve.one,this.y=this.curve.one,this.z=new t(0)):(this.x=new t(u,16),this.y=new t(l,16),this.z=new t(vi,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}return i(v,n.BasePoint),a.prototype.jpoint=function(u,l,vi){return new v(this,u,l,vi)},v.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var u=this.z.redInvm(),l=u.redSqr(),vi=this.x.redMul(l),D=this.y.redMul(l).redMul(u);return this.curve.point(vi,D)},v.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},v.prototype.add=function(u){if(this.isInfinity())return u;if(u.isInfinity())return this;var l=u.z.redSqr(),vi=this.z.redSqr(),D=this.x.redMul(l),mi=u.x.redMul(vi),gi=this.y.redMul(l.redMul(u.z)),bi=u.y.redMul(vi.redMul(this.z)),Ri=D.redSub(mi),Ti=gi.redSub(bi);if(Ri.cmpn(0)===0)return Ti.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var Ii=Ri.redSqr(),qi=Ii.redMul(Ri),Oi=D.redMul(Ii),ki=Ti.redSqr().redIAdd(qi).redISub(Oi).redISub(Oi),Li=Ti.redMul(Oi.redISub(ki)).redISub(gi.redMul(qi)),ji=this.z.redMul(u.z).redMul(Ri);return this.curve.jpoint(ki,Li,ji)},v.prototype.mixedAdd=function(u){if(this.isInfinity())return u.toJ();if(u.isInfinity())return this;var l=this.z.redSqr(),vi=this.x,D=u.x.redMul(l),mi=this.y,gi=u.y.redMul(l).redMul(this.z),bi=vi.redSub(D),Ri=mi.redSub(gi);if(bi.cmpn(0)===0)return Ri.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var Ti=bi.redSqr(),Ii=Ti.redMul(bi),qi=vi.redMul(Ti),Oi=Ri.redSqr().redIAdd(Ii).redISub(qi).redISub(qi),ki=Ri.redMul(qi.redISub(Oi)).redISub(mi.redMul(Ii)),Li=this.z.redMul(bi);return this.curve.jpoint(Oi,ki,Li)},v.prototype.dblp=function(u){if(u===0)return this;if(this.isInfinity())return this;if(!u)return this.dbl();var l;if(this.curve.zeroA||this.curve.threeA){var vi=this;for(l=0;l<u;l++)vi=vi.dbl();return vi}var D=this.curve.a,mi=this.curve.tinv,gi=this.x,bi=this.y,Ri=this.z,Ti=Ri.redSqr().redSqr(),Ii=bi.redAdd(bi);for(l=0;l<u;l++){var qi=gi.redSqr(),Oi=Ii.redSqr(),ki=Oi.redSqr(),Li=qi.redAdd(qi).redIAdd(qi).redIAdd(D.redMul(Ti)),ji=gi.redMul(Oi),Hi=Li.redSqr().redISub(ji.redAdd(ji)),Ui=ji.redISub(Hi),Qi=Li.redMul(Ui);Qi=Qi.redIAdd(Qi).redISub(ki);var $i=Ii.redMul(Ri);l+1<u&&(Ti=Ti.redMul(ki)),gi=Hi,Ri=$i,Ii=Qi}return this.curve.jpoint(gi,Ii.redMul(mi),Ri)},v.prototype.dbl=function(){return this.isInfinity()?this:this.curve.zeroA?this._zeroDbl():this.curve.threeA?this._threeDbl():this._dbl()},v.prototype._zeroDbl=function(){var u,l,vi;if(this.zOne){var D=this.x.redSqr(),mi=this.y.redSqr(),gi=mi.redSqr(),bi=this.x.redAdd(mi).redSqr().redISub(D).redISub(gi);bi=bi.redIAdd(bi);var Ri=D.redAdd(D).redIAdd(D),Ti=Ri.redSqr().redISub(bi).redISub(bi),Ii=gi.redIAdd(gi);Ii=Ii.redIAdd(Ii),Ii=Ii.redIAdd(Ii),u=Ti,l=Ri.redMul(bi.redISub(Ti)).redISub(Ii),vi=this.y.redAdd(this.y)}else{var qi=this.x.redSqr(),Oi=this.y.redSqr(),ki=Oi.redSqr(),Li=this.x.redAdd(Oi).redSqr().redISub(qi).redISub(ki);Li=Li.redIAdd(Li);var ji=qi.redAdd(qi).redIAdd(qi),Hi=ji.redSqr(),Ui=ki.redIAdd(ki);Ui=Ui.redIAdd(Ui),Ui=Ui.redIAdd(Ui),u=Hi.redISub(Li).redISub(Li),l=ji.redMul(Li.redISub(u)).redISub(Ui),vi=this.y.redMul(this.z),vi=vi.redIAdd(vi)}return this.curve.jpoint(u,l,vi)},v.prototype._threeDbl=function(){var u,l,vi;if(this.zOne){var D=this.x.redSqr(),mi=this.y.redSqr(),gi=mi.redSqr(),bi=this.x.redAdd(mi).redSqr().redISub(D).redISub(gi);bi=bi.redIAdd(bi);var Ri=D.redAdd(D).redIAdd(D).redIAdd(this.curve.a),Ti=Ri.redSqr().redISub(bi).redISub(bi);u=Ti;var Ii=gi.redIAdd(gi);Ii=Ii.redIAdd(Ii),Ii=Ii.redIAdd(Ii),l=Ri.redMul(bi.redISub(Ti)).redISub(Ii),vi=this.y.redAdd(this.y)}else{var qi=this.z.redSqr(),Oi=this.y.redSqr(),ki=this.x.redMul(Oi),Li=this.x.redSub(qi).redMul(this.x.redAdd(qi));Li=Li.redAdd(Li).redIAdd(Li);var ji=ki.redIAdd(ki);ji=ji.redIAdd(ji);var Hi=ji.redAdd(ji);u=Li.redSqr().redISub(Hi),vi=this.y.redAdd(this.z).redSqr().redISub(Oi).redISub(qi);var Ui=Oi.redSqr();Ui=Ui.redIAdd(Ui),Ui=Ui.redIAdd(Ui),Ui=Ui.redIAdd(Ui),l=Li.redMul(ji.redISub(u)).redISub(Ui)}return this.curve.jpoint(u,l,vi)},v.prototype._dbl=function(){var u=this.curve.a,l=this.x,vi=this.y,D=this.z,mi=D.redSqr().redSqr(),gi=l.redSqr(),bi=vi.redSqr(),Ri=gi.redAdd(gi).redIAdd(gi).redIAdd(u.redMul(mi)),Ti=l.redAdd(l);Ti=Ti.redIAdd(Ti);var Ii=Ti.redMul(bi),qi=Ri.redSqr().redISub(Ii.redAdd(Ii)),Oi=Ii.redISub(qi),ki=bi.redSqr();ki=ki.redIAdd(ki),ki=ki.redIAdd(ki),ki=ki.redIAdd(ki);var Li=Ri.redMul(Oi).redISub(ki),ji=vi.redAdd(vi).redMul(D);return this.curve.jpoint(qi,Li,ji)},v.prototype.trpl=function(){if(!this.curve.zeroA)return this.dbl().add(this);var u=this.x.redSqr(),l=this.y.redSqr(),vi=this.z.redSqr(),D=l.redSqr(),mi=u.redAdd(u).redIAdd(u),gi=mi.redSqr(),bi=this.x.redAdd(l).redSqr().redISub(u).redISub(D);bi=bi.redIAdd(bi),bi=bi.redAdd(bi).redIAdd(bi),bi=bi.redISub(gi);var Ri=bi.redSqr(),Ti=D.redIAdd(D);Ti=Ti.redIAdd(Ti),Ti=Ti.redIAdd(Ti),Ti=Ti.redIAdd(Ti);var Ii=mi.redIAdd(bi).redSqr().redISub(gi).redISub(Ri).redISub(Ti),qi=l.redMul(Ii);qi=qi.redIAdd(qi),qi=qi.redIAdd(qi);var Oi=this.x.redMul(Ri).redISub(qi);Oi=Oi.redIAdd(Oi),Oi=Oi.redIAdd(Oi);var ki=this.y.redMul(Ii.redMul(Ti.redISub(Ii)).redISub(bi.redMul(Ri)));ki=ki.redIAdd(ki),ki=ki.redIAdd(ki),ki=ki.redIAdd(ki);var Li=this.z.redAdd(bi).redSqr().redISub(vi).redISub(Ri);return this.curve.jpoint(Oi,ki,Li)},v.prototype.mul=function(u,l){return u=new t(u,l),this.curve._wnafMul(this,u)},v.prototype.eq=function(u){if(u.type==="affine")return this.eq(u.toJ());if(this===u)return!0;var l=this.z.redSqr(),vi=u.z.redSqr();if(this.x.redMul(vi).redISub(u.x.redMul(l)).cmpn(0)!==0)return!1;var D=l.redMul(this.z),mi=vi.redMul(u.z);return this.y.redMul(mi).redISub(u.y.redMul(D)).cmpn(0)===0},v.prototype.eqXToP=function(u){var l=this.z.redSqr(),vi=u.toRed(this.curve.red).redMul(l);if(this.x.cmp(vi)===0)return!0;for(var D=u.clone(),mi=this.curve.redN.redMul(l);;){if(D.iadd(this.curve.n),D.cmp(this.curve.p)>=0)return!1;if(vi.redIAdd(mi),this.x.cmp(vi)===0)return!0}},v.prototype.inspect=function(){return this.isInfinity()?"<EC JPoint Infinity>":"<EC JPoint x: "+this.x.toString(16,2)+" y: "+this.y.toString(16,2)+" z: "+this.z.toString(16,2)+">"},v.prototype.isInfinity=function(){return this.z.cmpn(0)===0},short}var mont,hasRequiredMont;function requireMont(){if(hasRequiredMont)return mont;hasRequiredMont=1;var r=requireBn$2(),t=requireInherits_browser(),i=requireBase$1(),n=requireUtils$1();function s(h){i.call(this,"mont",h),this.a=new r(h.a,16).toRed(this.red),this.b=new r(h.b,16).toRed(this.red),this.i4=new r(4).toRed(this.red).redInvm(),this.two=new r(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}t(s,i),mont=s,s.prototype.validate=function(v){var hi=v.normalize().x,u=hi.redSqr(),l=u.redMul(hi).redAdd(u.redMul(this.a)).redAdd(hi),vi=l.redSqrt();return vi.redSqr().cmp(l)===0};function a(h,v,hi){i.BasePoint.call(this,h,"projective"),v===null&&hi===null?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new r(v,16),this.z=new r(hi,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}return t(a,i.BasePoint),s.prototype.decodePoint=function(v,hi){return this.point(n.toArray(v,hi),1)},s.prototype.point=function(v,hi){return new a(this,v,hi)},s.prototype.pointFromJSON=function(v){return a.fromJSON(this,v)},a.prototype.precompute=function(){},a.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},a.fromJSON=function(v,hi){return new a(v,hi[0],hi[1]||v.one)},a.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},a.prototype.isInfinity=function(){return this.z.cmpn(0)===0},a.prototype.dbl=function(){var v=this.x.redAdd(this.z),hi=v.redSqr(),u=this.x.redSub(this.z),l=u.redSqr(),vi=hi.redSub(l),D=hi.redMul(l),mi=vi.redMul(l.redAdd(this.curve.a24.redMul(vi)));return this.curve.point(D,mi)},a.prototype.add=function(){throw new Error("Not supported on Montgomery curve")},a.prototype.diffAdd=function(v,hi){var u=this.x.redAdd(this.z),l=this.x.redSub(this.z),vi=v.x.redAdd(v.z),D=v.x.redSub(v.z),mi=D.redMul(u),gi=vi.redMul(l),bi=hi.z.redMul(mi.redAdd(gi).redSqr()),Ri=hi.x.redMul(mi.redISub(gi).redSqr());return this.curve.point(bi,Ri)},a.prototype.mul=function(v){for(var hi=v.clone(),u=this,l=this.curve.point(null,null),vi=this,D=[];hi.cmpn(0)!==0;hi.iushrn(1))D.push(hi.andln(1));for(var mi=D.length-1;mi>=0;mi--)D[mi]===0?(u=u.diffAdd(l,vi),l=l.dbl()):(l=u.diffAdd(l,vi),u=u.dbl());return l},a.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")},a.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")},a.prototype.eq=function(v){return this.getX().cmp(v.getX())===0},a.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},a.prototype.getX=function(){return this.normalize(),this.x.fromRed()},mont}var edwards,hasRequiredEdwards;function requireEdwards(){if(hasRequiredEdwards)return edwards;hasRequiredEdwards=1;var r=requireUtils$1(),t=requireBn$2(),i=requireInherits_browser(),n=requireBase$1(),s=r.assert;function a(v){this.twisted=(v.a|0)!==1,this.mOneA=this.twisted&&(v.a|0)===-1,this.extended=this.mOneA,n.call(this,"edwards",v),this.a=new t(v.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new t(v.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new t(v.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),s(!this.twisted||this.c.fromRed().cmpn(1)===0),this.oneC=(v.c|0)===1}i(a,n),edwards=a,a.prototype._mulA=function(hi){return this.mOneA?hi.redNeg():this.a.redMul(hi)},a.prototype._mulC=function(hi){return this.oneC?hi:this.c.redMul(hi)},a.prototype.jpoint=function(hi,u,l,vi){return this.point(hi,u,l,vi)},a.prototype.pointFromX=function(hi,u){hi=new t(hi,16),hi.red||(hi=hi.toRed(this.red));var l=hi.redSqr(),vi=this.c2.redSub(this.a.redMul(l)),D=this.one.redSub(this.c2.redMul(this.d).redMul(l)),mi=vi.redMul(D.redInvm()),gi=mi.redSqrt();if(gi.redSqr().redSub(mi).cmp(this.zero)!==0)throw new Error("invalid point");var bi=gi.fromRed().isOdd();return(u&&!bi||!u&&bi)&&(gi=gi.redNeg()),this.point(hi,gi)},a.prototype.pointFromY=function(hi,u){hi=new t(hi,16),hi.red||(hi=hi.toRed(this.red));var l=hi.redSqr(),vi=l.redSub(this.c2),D=l.redMul(this.d).redMul(this.c2).redSub(this.a),mi=vi.redMul(D.redInvm());if(mi.cmp(this.zero)===0){if(u)throw new Error("invalid point");return this.point(this.zero,hi)}var gi=mi.redSqrt();if(gi.redSqr().redSub(mi).cmp(this.zero)!==0)throw new Error("invalid point");return gi.fromRed().isOdd()!==u&&(gi=gi.redNeg()),this.point(gi,hi)},a.prototype.validate=function(hi){if(hi.isInfinity())return!0;hi.normalize();var u=hi.x.redSqr(),l=hi.y.redSqr(),vi=u.redMul(this.a).redAdd(l),D=this.c2.redMul(this.one.redAdd(this.d.redMul(u).redMul(l)));return vi.cmp(D)===0};function h(v,hi,u,l,vi){n.BasePoint.call(this,v,"projective"),hi===null&&u===null&&l===null?(this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0):(this.x=new t(hi,16),this.y=new t(u,16),this.z=l?new t(l,16):this.curve.one,this.t=vi&&new t(vi,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.t&&!this.t.red&&(this.t=this.t.toRed(this.curve.red)),this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t&&(this.t=this.x.redMul(this.y),this.zOne||(this.t=this.t.redMul(this.z.redInvm()))))}return i(h,n.BasePoint),a.prototype.pointFromJSON=function(hi){return h.fromJSON(this,hi)},a.prototype.point=function(hi,u,l,vi){return new h(this,hi,u,l,vi)},h.fromJSON=function(hi,u){return new h(hi,u[0],u[1],u[2])},h.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},h.prototype.isInfinity=function(){return this.x.cmpn(0)===0&&(this.y.cmp(this.z)===0||this.zOne&&this.y.cmp(this.curve.c)===0)},h.prototype._extDbl=function(){var hi=this.x.redSqr(),u=this.y.redSqr(),l=this.z.redSqr();l=l.redIAdd(l);var vi=this.curve._mulA(hi),D=this.x.redAdd(this.y).redSqr().redISub(hi).redISub(u),mi=vi.redAdd(u),gi=mi.redSub(l),bi=vi.redSub(u),Ri=D.redMul(gi),Ti=mi.redMul(bi),Ii=D.redMul(bi),qi=gi.redMul(mi);return this.curve.point(Ri,Ti,qi,Ii)},h.prototype._projDbl=function(){var hi=this.x.redAdd(this.y).redSqr(),u=this.x.redSqr(),l=this.y.redSqr(),vi,D,mi,gi,bi,Ri;if(this.curve.twisted){gi=this.curve._mulA(u);var Ti=gi.redAdd(l);this.zOne?(vi=hi.redSub(u).redSub(l).redMul(Ti.redSub(this.curve.two)),D=Ti.redMul(gi.redSub(l)),mi=Ti.redSqr().redSub(Ti).redSub(Ti)):(bi=this.z.redSqr(),Ri=Ti.redSub(bi).redISub(bi),vi=hi.redSub(u).redISub(l).redMul(Ri),D=Ti.redMul(gi.redSub(l)),mi=Ti.redMul(Ri))}else gi=u.redAdd(l),bi=this.curve._mulC(this.z).redSqr(),Ri=gi.redSub(bi).redSub(bi),vi=this.curve._mulC(hi.redISub(gi)).redMul(Ri),D=this.curve._mulC(gi).redMul(u.redISub(l)),mi=gi.redMul(Ri);return this.curve.point(vi,D,mi)},h.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()},h.prototype._extAdd=function(hi){var u=this.y.redSub(this.x).redMul(hi.y.redSub(hi.x)),l=this.y.redAdd(this.x).redMul(hi.y.redAdd(hi.x)),vi=this.t.redMul(this.curve.dd).redMul(hi.t),D=this.z.redMul(hi.z.redAdd(hi.z)),mi=l.redSub(u),gi=D.redSub(vi),bi=D.redAdd(vi),Ri=l.redAdd(u),Ti=mi.redMul(gi),Ii=bi.redMul(Ri),qi=mi.redMul(Ri),Oi=gi.redMul(bi);return this.curve.point(Ti,Ii,Oi,qi)},h.prototype._projAdd=function(hi){var u=this.z.redMul(hi.z),l=u.redSqr(),vi=this.x.redMul(hi.x),D=this.y.redMul(hi.y),mi=this.curve.d.redMul(vi).redMul(D),gi=l.redSub(mi),bi=l.redAdd(mi),Ri=this.x.redAdd(this.y).redMul(hi.x.redAdd(hi.y)).redISub(vi).redISub(D),Ti=u.redMul(gi).redMul(Ri),Ii,qi;return this.curve.twisted?(Ii=u.redMul(bi).redMul(D.redSub(this.curve._mulA(vi))),qi=gi.redMul(bi)):(Ii=u.redMul(bi).redMul(D.redSub(vi)),qi=this.curve._mulC(gi).redMul(bi)),this.curve.point(Ti,Ii,qi)},h.prototype.add=function(hi){return this.isInfinity()?hi:hi.isInfinity()?this:this.curve.extended?this._extAdd(hi):this._projAdd(hi)},h.prototype.mul=function(hi){return this._hasDoubles(hi)?this.curve._fixedNafMul(this,hi):this.curve._wnafMul(this,hi)},h.prototype.mulAdd=function(hi,u,l){return this.curve._wnafMulAdd(1,[this,u],[hi,l],2,!1)},h.prototype.jmulAdd=function(hi,u,l){return this.curve._wnafMulAdd(1,[this,u],[hi,l],2,!0)},h.prototype.normalize=function(){if(this.zOne)return this;var hi=this.z.redInvm();return this.x=this.x.redMul(hi),this.y=this.y.redMul(hi),this.t&&(this.t=this.t.redMul(hi)),this.z=this.curve.one,this.zOne=!0,this},h.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},h.prototype.getX=function(){return this.normalize(),this.x.fromRed()},h.prototype.getY=function(){return this.normalize(),this.y.fromRed()},h.prototype.eq=function(hi){return this===hi||this.getX().cmp(hi.getX())===0&&this.getY().cmp(hi.getY())===0},h.prototype.eqXToP=function(hi){var u=hi.toRed(this.curve.red).redMul(this.z);if(this.x.cmp(u)===0)return!0;for(var l=hi.clone(),vi=this.curve.redN.redMul(this.z);;){if(l.iadd(this.curve.n),l.cmp(this.curve.p)>=0)return!1;if(u.redIAdd(vi),this.x.cmp(u)===0)return!0}},h.prototype.toP=h.prototype.normalize,h.prototype.mixedAdd=h.prototype.add,edwards}var hasRequiredCurve;function requireCurve(){return hasRequiredCurve||(hasRequiredCurve=1,function(r){var t=r;t.base=requireBase$1(),t.short=requireShort(),t.mont=requireMont(),t.edwards=requireEdwards()}(curve)),curve}var curves={},hash={},utils={},hasRequiredUtils;function requireUtils(){if(hasRequiredUtils)return utils;hasRequiredUtils=1;var r=requireMinimalisticAssert(),t=requireInherits_browser();utils.inherits=t;function i(wi,xi){return(wi.charCodeAt(xi)&64512)!==55296||xi<0||xi+1>=wi.length?!1:(wi.charCodeAt(xi+1)&64512)===56320}function n(wi,xi){if(Array.isArray(wi))return wi.slice();if(!wi)return[];var yi=[];if(typeof wi=="string")if(xi){if(xi==="hex")for(wi=wi.replace(/[^a-z0-9]+/ig,""),wi.length%2!==0&&(wi="0"+wi),Ci=0;Ci<wi.length;Ci+=2)yi.push(parseInt(wi[Ci]+wi[Ci+1],16))}else for(var Ei=0,Ci=0;Ci<wi.length;Ci++){var Ni=wi.charCodeAt(Ci);Ni<128?yi[Ei++]=Ni:Ni<2048?(yi[Ei++]=Ni>>6|192,yi[Ei++]=Ni&63|128):i(wi,Ci)?(Ni=65536+((Ni&1023)<<10)+(wi.charCodeAt(++Ci)&1023),yi[Ei++]=Ni>>18|240,yi[Ei++]=Ni>>12&63|128,yi[Ei++]=Ni>>6&63|128,yi[Ei++]=Ni&63|128):(yi[Ei++]=Ni>>12|224,yi[Ei++]=Ni>>6&63|128,yi[Ei++]=Ni&63|128)}else for(Ci=0;Ci<wi.length;Ci++)yi[Ci]=wi[Ci]|0;return yi}utils.toArray=n;function s(wi){for(var xi="",yi=0;yi<wi.length;yi++)xi+=v(wi[yi].toString(16));return xi}utils.toHex=s;function a(wi){var xi=wi>>>24|wi>>>8&65280|wi<<8&16711680|(wi&255)<<24;return xi>>>0}utils.htonl=a;function h(wi,xi){for(var yi="",Ei=0;Ei<wi.length;Ei++){var Ci=wi[Ei];xi==="little"&&(Ci=a(Ci)),yi+=hi(Ci.toString(16))}return yi}utils.toHex32=h;function v(wi){return wi.length===1?"0"+wi:wi}utils.zero2=v;function hi(wi){return wi.length===7?"0"+wi:wi.length===6?"00"+wi:wi.length===5?"000"+wi:wi.length===4?"0000"+wi:wi.length===3?"00000"+wi:wi.length===2?"000000"+wi:wi.length===1?"0000000"+wi:wi}utils.zero8=hi;function u(wi,xi,yi,Ei){var Ci=yi-xi;r(Ci%4===0);for(var Ni=new Array(Ci/4),Fi=0,Mi=xi;Fi<Ni.length;Fi++,Mi+=4){var Si;Ei==="big"?Si=wi[Mi]<<24|wi[Mi+1]<<16|wi[Mi+2]<<8|wi[Mi+3]:Si=wi[Mi+3]<<24|wi[Mi+2]<<16|wi[Mi+1]<<8|wi[Mi],Ni[Fi]=Si>>>0}return Ni}utils.join32=u;function l(wi,xi){for(var yi=new Array(wi.length*4),Ei=0,Ci=0;Ei<wi.length;Ei++,Ci+=4){var Ni=wi[Ei];xi==="big"?(yi[Ci]=Ni>>>24,yi[Ci+1]=Ni>>>16&255,yi[Ci+2]=Ni>>>8&255,yi[Ci+3]=Ni&255):(yi[Ci+3]=Ni>>>24,yi[Ci+2]=Ni>>>16&255,yi[Ci+1]=Ni>>>8&255,yi[Ci]=Ni&255)}return yi}utils.split32=l;function vi(wi,xi){return wi>>>xi|wi<<32-xi}utils.rotr32=vi;function D(wi,xi){return wi<<xi|wi>>>32-xi}utils.rotl32=D;function mi(wi,xi){return wi+xi>>>0}utils.sum32=mi;function gi(wi,xi,yi){return wi+xi+yi>>>0}utils.sum32_3=gi;function bi(wi,xi,yi,Ei){return wi+xi+yi+Ei>>>0}utils.sum32_4=bi;function Ri(wi,xi,yi,Ei,Ci){return wi+xi+yi+Ei+Ci>>>0}utils.sum32_5=Ri;function Ti(wi,xi,yi,Ei){var Ci=wi[xi],Ni=wi[xi+1],Fi=Ei+Ni>>>0,Mi=(Fi<Ei?1:0)+yi+Ci;wi[xi]=Mi>>>0,wi[xi+1]=Fi}utils.sum64=Ti;function Ii(wi,xi,yi,Ei){var Ci=xi+Ei>>>0,Ni=(Ci<xi?1:0)+wi+yi;return Ni>>>0}utils.sum64_hi=Ii;function qi(wi,xi,yi,Ei){var Ci=xi+Ei;return Ci>>>0}utils.sum64_lo=qi;function Oi(wi,xi,yi,Ei,Ci,Ni,Fi,Mi){var Si=0,Ai=xi;Ai=Ai+Ei>>>0,Si+=Ai<xi?1:0,Ai=Ai+Ni>>>0,Si+=Ai<Ni?1:0,Ai=Ai+Mi>>>0,Si+=Ai<Mi?1:0;var _i=wi+yi+Ci+Fi+Si;return _i>>>0}utils.sum64_4_hi=Oi;function ki(wi,xi,yi,Ei,Ci,Ni,Fi,Mi){var Si=xi+Ei+Ni+Mi;return Si>>>0}utils.sum64_4_lo=ki;function Li(wi,xi,yi,Ei,Ci,Ni,Fi,Mi,Si,Ai){var _i=0,Bi=xi;Bi=Bi+Ei>>>0,_i+=Bi<xi?1:0,Bi=Bi+Ni>>>0,_i+=Bi<Ni?1:0,Bi=Bi+Mi>>>0,_i+=Bi<Mi?1:0,Bi=Bi+Ai>>>0,_i+=Bi<Ai?1:0;var Pi=wi+yi+Ci+Fi+Si+_i;return Pi>>>0}utils.sum64_5_hi=Li;function ji(wi,xi,yi,Ei,Ci,Ni,Fi,Mi,Si,Ai){var _i=xi+Ei+Ni+Mi+Ai;return _i>>>0}utils.sum64_5_lo=ji;function Hi(wi,xi,yi){var Ei=xi<<32-yi|wi>>>yi;return Ei>>>0}utils.rotr64_hi=Hi;function Ui(wi,xi,yi){var Ei=wi<<32-yi|xi>>>yi;return Ei>>>0}utils.rotr64_lo=Ui;function Qi(wi,xi,yi){return wi>>>yi}utils.shr64_hi=Qi;function $i(wi,xi,yi){var Ei=wi<<32-yi|xi>>>yi;return Ei>>>0}return utils.shr64_lo=$i,utils}var common$1={},hasRequiredCommon$1;function requireCommon$1(){if(hasRequiredCommon$1)return common$1;hasRequiredCommon$1=1;var r=requireUtils(),t=requireMinimalisticAssert();function i(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}return common$1.BlockHash=i,i.prototype.update=function(s,a){if(s=r.toArray(s,a),this.pending?this.pending=this.pending.concat(s):this.pending=s,this.pendingTotal+=s.length,this.pending.length>=this._delta8){s=this.pending;var h=s.length%this._delta8;this.pending=s.slice(s.length-h,s.length),this.pending.length===0&&(this.pending=null),s=r.join32(s,0,s.length-h,this.endian);for(var v=0;v<s.length;v+=this._delta32)this._update(s,v,v+this._delta32)}return this},i.prototype.digest=function(s){return this.update(this._pad()),t(this.pending===null),this._digest(s)},i.prototype._pad=function(){var s=this.pendingTotal,a=this._delta8,h=a-(s+this.padLength)%a,v=new Array(h+this.padLength);v[0]=128;for(var hi=1;hi<h;hi++)v[hi]=0;if(s<<=3,this.endian==="big"){for(var u=8;u<this.padLength;u++)v[hi++]=0;v[hi++]=0,v[hi++]=0,v[hi++]=0,v[hi++]=0,v[hi++]=s>>>24&255,v[hi++]=s>>>16&255,v[hi++]=s>>>8&255,v[hi++]=s&255}else for(v[hi++]=s&255,v[hi++]=s>>>8&255,v[hi++]=s>>>16&255,v[hi++]=s>>>24&255,v[hi++]=0,v[hi++]=0,v[hi++]=0,v[hi++]=0,u=8;u<this.padLength;u++)v[hi++]=0;return v},common$1}var sha={},common={},hasRequiredCommon;function requireCommon(){if(hasRequiredCommon)return common;hasRequiredCommon=1;var r=requireUtils(),t=r.rotr32;function i(l,vi,D,mi){if(l===0)return n(vi,D,mi);if(l===1||l===3)return a(vi,D,mi);if(l===2)return s(vi,D,mi)}common.ft_1=i;function n(l,vi,D){return l&vi^~l&D}common.ch32=n;function s(l,vi,D){return l&vi^l&D^vi&D}common.maj32=s;function a(l,vi,D){return l^vi^D}common.p32=a;function h(l){return t(l,2)^t(l,13)^t(l,22)}common.s0_256=h;function v(l){return t(l,6)^t(l,11)^t(l,25)}common.s1_256=v;function hi(l){return t(l,7)^t(l,18)^l>>>3}common.g0_256=hi;function u(l){return t(l,17)^t(l,19)^l>>>10}return common.g1_256=u,common}var _1,hasRequired_1;function require_1(){if(hasRequired_1)return _1;hasRequired_1=1;var r=requireUtils(),t=requireCommon$1(),i=requireCommon(),n=r.rotl32,s=r.sum32,a=r.sum32_5,h=i.ft_1,v=t.BlockHash,hi=[1518500249,1859775393,2400959708,3395469782];function u(){if(!(this instanceof u))return new u;v.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}return r.inherits(u,v),_1=u,u.blockSize=512,u.outSize=160,u.hmacStrength=80,u.padLength=64,u.prototype._update=function(vi,D){for(var mi=this.W,gi=0;gi<16;gi++)mi[gi]=vi[D+gi];for(;gi<mi.length;gi++)mi[gi]=n(mi[gi-3]^mi[gi-8]^mi[gi-14]^mi[gi-16],1);var bi=this.h[0],Ri=this.h[1],Ti=this.h[2],Ii=this.h[3],qi=this.h[4];for(gi=0;gi<mi.length;gi++){var Oi=~~(gi/20),ki=a(n(bi,5),h(Oi,Ri,Ti,Ii),qi,mi[gi],hi[Oi]);qi=Ii,Ii=Ti,Ti=n(Ri,30),Ri=bi,bi=ki}this.h[0]=s(this.h[0],bi),this.h[1]=s(this.h[1],Ri),this.h[2]=s(this.h[2],Ti),this.h[3]=s(this.h[3],Ii),this.h[4]=s(this.h[4],qi)},u.prototype._digest=function(vi){return vi==="hex"?r.toHex32(this.h,"big"):r.split32(this.h,"big")},_1}var _256,hasRequired_256;function require_256(){if(hasRequired_256)return _256;hasRequired_256=1;var r=requireUtils(),t=requireCommon$1(),i=requireCommon(),n=requireMinimalisticAssert(),s=r.sum32,a=r.sum32_4,h=r.sum32_5,v=i.ch32,hi=i.maj32,u=i.s0_256,l=i.s1_256,vi=i.g0_256,D=i.g1_256,mi=t.BlockHash,gi=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298];function bi(){if(!(this instanceof bi))return new bi;mi.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=gi,this.W=new Array(64)}return r.inherits(bi,mi),_256=bi,bi.blockSize=512,bi.outSize=256,bi.hmacStrength=192,bi.padLength=64,bi.prototype._update=function(Ti,Ii){for(var qi=this.W,Oi=0;Oi<16;Oi++)qi[Oi]=Ti[Ii+Oi];for(;Oi<qi.length;Oi++)qi[Oi]=a(D(qi[Oi-2]),qi[Oi-7],vi(qi[Oi-15]),qi[Oi-16]);var ki=this.h[0],Li=this.h[1],ji=this.h[2],Hi=this.h[3],Ui=this.h[4],Qi=this.h[5],$i=this.h[6],wi=this.h[7];for(n(this.k.length===qi.length),Oi=0;Oi<qi.length;Oi++){var xi=h(wi,l(Ui),v(Ui,Qi,$i),this.k[Oi],qi[Oi]),yi=s(u(ki),hi(ki,Li,ji));wi=$i,$i=Qi,Qi=Ui,Ui=s(Hi,xi),Hi=ji,ji=Li,Li=ki,ki=s(xi,yi)}this.h[0]=s(this.h[0],ki),this.h[1]=s(this.h[1],Li),this.h[2]=s(this.h[2],ji),this.h[3]=s(this.h[3],Hi),this.h[4]=s(this.h[4],Ui),this.h[5]=s(this.h[5],Qi),this.h[6]=s(this.h[6],$i),this.h[7]=s(this.h[7],wi)},bi.prototype._digest=function(Ti){return Ti==="hex"?r.toHex32(this.h,"big"):r.split32(this.h,"big")},_256}var _224,hasRequired_224;function require_224(){if(hasRequired_224)return _224;hasRequired_224=1;var r=requireUtils(),t=require_256();function i(){if(!(this instanceof i))return new i;t.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}return r.inherits(i,t),_224=i,i.blockSize=512,i.outSize=224,i.hmacStrength=192,i.padLength=64,i.prototype._digest=function(s){return s==="hex"?r.toHex32(this.h.slice(0,7),"big"):r.split32(this.h.slice(0,7),"big")},_224}var _512,hasRequired_512;function require_512(){if(hasRequired_512)return _512;hasRequired_512=1;var r=requireUtils(),t=requireCommon$1(),i=requireMinimalisticAssert(),n=r.rotr64_hi,s=r.rotr64_lo,a=r.shr64_hi,h=r.shr64_lo,v=r.sum64,hi=r.sum64_hi,u=r.sum64_lo,l=r.sum64_4_hi,vi=r.sum64_4_lo,D=r.sum64_5_hi,mi=r.sum64_5_lo,gi=t.BlockHash,bi=[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,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591];function Ri(){if(!(this instanceof Ri))return new Ri;gi.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=bi,this.W=new Array(160)}r.inherits(Ri,gi),_512=Ri,Ri.blockSize=1024,Ri.outSize=512,Ri.hmacStrength=192,Ri.padLength=128,Ri.prototype._prepareBlock=function(yi,Ei){for(var Ci=this.W,Ni=0;Ni<32;Ni++)Ci[Ni]=yi[Ei+Ni];for(;Ni<Ci.length;Ni+=2){var Fi=$i(Ci[Ni-4],Ci[Ni-3]),Mi=wi(Ci[Ni-4],Ci[Ni-3]),Si=Ci[Ni-14],Ai=Ci[Ni-13],_i=Ui(Ci[Ni-30],Ci[Ni-29]),Bi=Qi(Ci[Ni-30],Ci[Ni-29]),Pi=Ci[Ni-32],zi=Ci[Ni-31];Ci[Ni]=l(Fi,Mi,Si,Ai,_i,Bi,Pi,zi),Ci[Ni+1]=vi(Fi,Mi,Si,Ai,_i,Bi,Pi,zi)}},Ri.prototype._update=function(yi,Ei){this._prepareBlock(yi,Ei);var Ci=this.W,Ni=this.h[0],Fi=this.h[1],Mi=this.h[2],Si=this.h[3],Ai=this.h[4],_i=this.h[5],Bi=this.h[6],Pi=this.h[7],zi=this.h[8],Gi=this.h[9],Vi=this.h[10],Ki=this.h[11],Zi=this.h[12],In=this.h[13],Ji=this.h[14],Xi=this.h[15];i(this.k.length===Ci.length);for(var on=0;on<Ci.length;on+=2){var jn=Ji,Ln=Xi,Hn=ji(zi,Gi),ea=Hi(zi,Gi),ia=Ti(zi,Gi,Vi,Ki,Zi),Wn=Ii(zi,Gi,Vi,Ki,Zi,In),oa=this.k[on],ta=this.k[on+1],aa=Ci[on],sa=Ci[on+1],ua=D(jn,Ln,Hn,ea,ia,Wn,oa,ta,aa,sa),da=mi(jn,Ln,Hn,ea,ia,Wn,oa,ta,aa,sa);jn=ki(Ni,Fi),Ln=Li(Ni,Fi),Hn=qi(Ni,Fi,Mi,Si,Ai),ea=Oi(Ni,Fi,Mi,Si,Ai,_i);var ca=hi(jn,Ln,Hn,ea),la=u(jn,Ln,Hn,ea);Ji=Zi,Xi=In,Zi=Vi,In=Ki,Vi=zi,Ki=Gi,zi=hi(Bi,Pi,ua,da),Gi=u(Pi,Pi,ua,da),Bi=Ai,Pi=_i,Ai=Mi,_i=Si,Mi=Ni,Si=Fi,Ni=hi(ua,da,ca,la),Fi=u(ua,da,ca,la)}v(this.h,0,Ni,Fi),v(this.h,2,Mi,Si),v(this.h,4,Ai,_i),v(this.h,6,Bi,Pi),v(this.h,8,zi,Gi),v(this.h,10,Vi,Ki),v(this.h,12,Zi,In),v(this.h,14,Ji,Xi)},Ri.prototype._digest=function(yi){return yi==="hex"?r.toHex32(this.h,"big"):r.split32(this.h,"big")};function Ti(xi,yi,Ei,Ci,Ni){var Fi=xi&Ei^~xi&Ni;return Fi<0&&(Fi+=4294967296),Fi}function Ii(xi,yi,Ei,Ci,Ni,Fi){var Mi=yi&Ci^~yi&Fi;return Mi<0&&(Mi+=4294967296),Mi}function qi(xi,yi,Ei,Ci,Ni){var Fi=xi&Ei^xi&Ni^Ei&Ni;return Fi<0&&(Fi+=4294967296),Fi}function Oi(xi,yi,Ei,Ci,Ni,Fi){var Mi=yi&Ci^yi&Fi^Ci&Fi;return Mi<0&&(Mi+=4294967296),Mi}function ki(xi,yi){var Ei=n(xi,yi,28),Ci=n(yi,xi,2),Ni=n(yi,xi,7),Fi=Ei^Ci^Ni;return Fi<0&&(Fi+=4294967296),Fi}function Li(xi,yi){var Ei=s(xi,yi,28),Ci=s(yi,xi,2),Ni=s(yi,xi,7),Fi=Ei^Ci^Ni;return Fi<0&&(Fi+=4294967296),Fi}function ji(xi,yi){var Ei=n(xi,yi,14),Ci=n(xi,yi,18),Ni=n(yi,xi,9),Fi=Ei^Ci^Ni;return Fi<0&&(Fi+=4294967296),Fi}function Hi(xi,yi){var Ei=s(xi,yi,14),Ci=s(xi,yi,18),Ni=s(yi,xi,9),Fi=Ei^Ci^Ni;return Fi<0&&(Fi+=4294967296),Fi}function Ui(xi,yi){var Ei=n(xi,yi,1),Ci=n(xi,yi,8),Ni=a(xi,yi,7),Fi=Ei^Ci^Ni;return Fi<0&&(Fi+=4294967296),Fi}function Qi(xi,yi){var Ei=s(xi,yi,1),Ci=s(xi,yi,8),Ni=h(xi,yi,7),Fi=Ei^Ci^Ni;return Fi<0&&(Fi+=4294967296),Fi}function $i(xi,yi){var Ei=n(xi,yi,19),Ci=n(yi,xi,29),Ni=a(xi,yi,6),Fi=Ei^Ci^Ni;return Fi<0&&(Fi+=4294967296),Fi}function wi(xi,yi){var Ei=s(xi,yi,19),Ci=s(yi,xi,29),Ni=h(xi,yi,6),Fi=Ei^Ci^Ni;return Fi<0&&(Fi+=4294967296),Fi}return _512}var _384,hasRequired_384;function require_384(){if(hasRequired_384)return _384;hasRequired_384=1;var r=requireUtils(),t=require_512();function i(){if(!(this instanceof i))return new i;t.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}return r.inherits(i,t),_384=i,i.blockSize=1024,i.outSize=384,i.hmacStrength=192,i.padLength=128,i.prototype._digest=function(s){return s==="hex"?r.toHex32(this.h.slice(0,12),"big"):r.split32(this.h.slice(0,12),"big")},_384}var hasRequiredSha;function requireSha(){return hasRequiredSha||(hasRequiredSha=1,sha.sha1=require_1(),sha.sha224=require_224(),sha.sha256=require_256(),sha.sha384=require_384(),sha.sha512=require_512()),sha}var ripemd={},hasRequiredRipemd;function requireRipemd(){if(hasRequiredRipemd)return ripemd;hasRequiredRipemd=1;var r=requireUtils(),t=requireCommon$1(),i=r.rotl32,n=r.sum32,s=r.sum32_3,a=r.sum32_4,h=t.BlockHash;function v(){if(!(this instanceof v))return new v;h.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}r.inherits(v,h),ripemd.ripemd160=v,v.blockSize=512,v.outSize=160,v.hmacStrength=192,v.padLength=64,v.prototype._update=function(Ri,Ti){for(var Ii=this.h[0],qi=this.h[1],Oi=this.h[2],ki=this.h[3],Li=this.h[4],ji=Ii,Hi=qi,Ui=Oi,Qi=ki,$i=Li,wi=0;wi<80;wi++){var xi=n(i(a(Ii,hi(wi,qi,Oi,ki),Ri[vi[wi]+Ti],u(wi)),mi[wi]),Li);Ii=Li,Li=ki,ki=i(Oi,10),Oi=qi,qi=xi,xi=n(i(a(ji,hi(79-wi,Hi,Ui,Qi),Ri[D[wi]+Ti],l(wi)),gi[wi]),$i),ji=$i,$i=Qi,Qi=i(Ui,10),Ui=Hi,Hi=xi}xi=s(this.h[1],Oi,Qi),this.h[1]=s(this.h[2],ki,$i),this.h[2]=s(this.h[3],Li,ji),this.h[3]=s(this.h[4],Ii,Hi),this.h[4]=s(this.h[0],qi,Ui),this.h[0]=xi},v.prototype._digest=function(Ri){return Ri==="hex"?r.toHex32(this.h,"little"):r.split32(this.h,"little")};function hi(bi,Ri,Ti,Ii){return bi<=15?Ri^Ti^Ii:bi<=31?Ri&Ti|~Ri&Ii:bi<=47?(Ri|~Ti)^Ii:bi<=63?Ri&Ii|Ti&~Ii:Ri^(Ti|~Ii)}function u(bi){return bi<=15?0:bi<=31?1518500249:bi<=47?1859775393:bi<=63?2400959708:2840853838}function l(bi){return bi<=15?1352829926:bi<=31?1548603684:bi<=47?1836072691:bi<=63?2053994217:0}var vi=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],D=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],mi=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],gi=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11];return ripemd}var hmac$2,hasRequiredHmac$1;function requireHmac$1(){if(hasRequiredHmac$1)return hmac$2;hasRequiredHmac$1=1;var r=requireUtils(),t=requireMinimalisticAssert();function i(n,s,a){if(!(this instanceof i))return new i(n,s,a);this.Hash=n,this.blockSize=n.blockSize/8,this.outSize=n.outSize/8,this.inner=null,this.outer=null,this._init(r.toArray(s,a))}return hmac$2=i,i.prototype._init=function(s){s.length>this.blockSize&&(s=new this.Hash().update(s).digest()),t(s.length<=this.blockSize);for(var a=s.length;a<this.blockSize;a++)s.push(0);for(a=0;a<s.length;a++)s[a]^=54;for(this.inner=new this.Hash().update(s),a=0;a<s.length;a++)s[a]^=106;this.outer=new this.Hash().update(s)},i.prototype.update=function(s,a){return this.inner.update(s,a),this},i.prototype.digest=function(s){return this.outer.update(this.inner.digest()),this.outer.digest(s)},hmac$2}var hasRequiredHash;function requireHash(){return hasRequiredHash||(hasRequiredHash=1,function(r){var t=r;t.utils=requireUtils(),t.common=requireCommon$1(),t.sha=requireSha(),t.ripemd=requireRipemd(),t.hmac=requireHmac$1(),t.sha1=t.sha.sha1,t.sha256=t.sha.sha256,t.sha224=t.sha.sha224,t.sha384=t.sha.sha384,t.sha512=t.sha.sha512,t.ripemd160=t.ripemd.ripemd160}(hash)),hash}var secp256k1,hasRequiredSecp256k1;function requireSecp256k1(){return hasRequiredSecp256k1||(hasRequiredSecp256k1=1,secp256k1={doubles:{step:4,points:[["e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a","f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821"],["8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508","11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf"],["175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739","d3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695"],["363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640","4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9"],["8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c","4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36"],["723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda","96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f"],["eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa","5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999"],["100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0","cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09"],["e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d","9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d"],["feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d","e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088"],["da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1","9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d"],["53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0","5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8"],["8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047","10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a"],["385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862","283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453"],["6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7","7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160"],["3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd","56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0"],["85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83","7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6"],["948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a","53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589"],["6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8","bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17"],["e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d","4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda"],["e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725","7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd"],["213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754","4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2"],["4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c","17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6"],["fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6","6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f"],["76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39","c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01"],["c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891","893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3"],["d895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b","febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f"],["b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03","2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7"],["e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d","eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78"],["a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070","7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1"],["90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4","e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150"],["8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da","662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82"],["e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11","1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc"],["8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e","efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b"],["e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41","2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51"],["b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef","67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45"],["d68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8","db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120"],["324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d","648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84"],["4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96","35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d"],["9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd","ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d"],["6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5","9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8"],["a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266","40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8"],["7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71","34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac"],["928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac","c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f"],["85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751","1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962"],["ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e","493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907"],["827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241","c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec"],["eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3","be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d"],["e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f","4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414"],["1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19","aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd"],["146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be","b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0"],["fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9","6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811"],["da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2","8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1"],["a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13","7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c"],["174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c","ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73"],["959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba","2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd"],["d2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151","e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405"],["64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073","d99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589"],["8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458","38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e"],["13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b","69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27"],["bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366","d3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1"],["8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa","40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482"],["8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0","620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945"],["dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787","7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573"],["f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e","ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82"]]},naf:{wnd:7,points:[["f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9","388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672"],["2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4","d8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6"],["5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc","6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da"],["acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe","cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37"],["774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb","d984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b"],["f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8","ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81"],["d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e","581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58"],["defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34","4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77"],["2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c","85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a"],["352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5","321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c"],["2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f","2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67"],["9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714","73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402"],["daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729","a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55"],["c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db","2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482"],["6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4","e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82"],["1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5","b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396"],["605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479","2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49"],["62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d","80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf"],["80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f","1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a"],["7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb","d0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7"],["d528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9","eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933"],["49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963","758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a"],["77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74","958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6"],["f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530","e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37"],["463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b","5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e"],["f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247","cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6"],["caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1","cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476"],["2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120","4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40"],["7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435","91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61"],["754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18","673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683"],["e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8","59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5"],["186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb","3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b"],["df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f","55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417"],["5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143","efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868"],["290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba","e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a"],["af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45","f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6"],["766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a","744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996"],["59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e","c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e"],["f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8","e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d"],["7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c","30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2"],["948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519","e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e"],["7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab","100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437"],["3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca","ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311"],["d3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf","8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4"],["1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610","68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575"],["733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4","f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d"],["15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c","d56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d"],["a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940","edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629"],["e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980","a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06"],["311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3","66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374"],["34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf","9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee"],["f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63","4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1"],["d7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448","fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b"],["32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf","5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661"],["7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5","8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6"],["ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6","8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e"],["16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5","5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d"],["eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99","f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc"],["78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51","f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4"],["494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5","42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c"],["a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5","204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b"],["c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997","4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913"],["841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881","73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154"],["5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5","39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865"],["36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66","d2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc"],["336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726","ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224"],["8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede","6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e"],["1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94","60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6"],["85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31","3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511"],["29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51","b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b"],["a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252","ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2"],["4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5","cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c"],["d24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b","6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3"],["ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4","322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d"],["af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f","6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700"],["e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889","2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4"],["591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246","b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196"],["11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984","998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4"],["3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a","b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257"],["cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030","bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13"],["c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197","6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096"],["c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593","c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38"],["a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef","21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f"],["347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38","60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448"],["da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a","49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a"],["c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111","5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4"],["4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502","7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437"],["3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea","be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7"],["cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26","8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d"],["b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986","39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a"],["d4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e","62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54"],["48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4","25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77"],["dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda","ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517"],["6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859","cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10"],["e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f","f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125"],["eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c","6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e"],["13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942","fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1"],["ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a","1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2"],["b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80","5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423"],["ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d","438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8"],["8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1","cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758"],["52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63","c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375"],["e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352","6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d"],["7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193","ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec"],["5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00","9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0"],["32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58","ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c"],["e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7","d3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4"],["8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8","c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f"],["4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e","67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649"],["3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d","cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826"],["674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b","299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5"],["d32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f","f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87"],["30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6","462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b"],["be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297","62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc"],["93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a","7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c"],["b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c","ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f"],["d5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52","4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a"],["d3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb","bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46"],["463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065","bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f"],["7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917","603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03"],["74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9","cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08"],["30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3","553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8"],["9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57","712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373"],["176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66","ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3"],["75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8","9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8"],["809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721","9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1"],["1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180","4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9"]]}}),secp256k1}var hasRequiredCurves;function requireCurves(){return hasRequiredCurves||(hasRequiredCurves=1,function(r){var t=r,i=requireHash(),n=requireCurve(),s=requireUtils$1(),a=s.assert;function h(u){u.type==="short"?this.curve=new n.short(u):u.type==="edwards"?this.curve=new n.edwards(u):this.curve=new n.mont(u),this.g=this.curve.g,this.n=this.curve.n,this.hash=u.hash,a(this.g.validate(),"Invalid curve"),a(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}t.PresetCurve=h;function v(u,l){Object.defineProperty(t,u,{configurable:!0,enumerable:!0,get:function(){var vi=new h(l);return Object.defineProperty(t,u,{configurable:!0,enumerable:!0,value:vi}),vi}})}v("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:i.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),v("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:i.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),v("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:i.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),v("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:i.sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),v("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:i.sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),v("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:i.sha256,gRed:!1,g:["9"]}),v("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:i.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});var hi;try{hi=requireSecp256k1()}catch{hi=void 0}v("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:i.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",hi]})}(curves)),curves}var hmacDrbg,hasRequiredHmacDrbg;function requireHmacDrbg(){if(hasRequiredHmacDrbg)return hmacDrbg;hasRequiredHmacDrbg=1;var r=requireHash(),t=requireUtils$2(),i=requireMinimalisticAssert();function n(s){if(!(this instanceof n))return new n(s);this.hash=s.hash,this.predResist=!!s.predResist,this.outLen=this.hash.outSize,this.minEntropy=s.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var a=t.toArray(s.entropy,s.entropyEnc||"hex"),h=t.toArray(s.nonce,s.nonceEnc||"hex"),v=t.toArray(s.pers,s.persEnc||"hex");i(a.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(a,h,v)}return hmacDrbg=n,n.prototype._init=function(a,h,v){var hi=a.concat(h).concat(v);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var u=0;u<this.V.length;u++)this.K[u]=0,this.V[u]=1;this._update(hi),this._reseed=1,this.reseedInterval=281474976710656},n.prototype._hmac=function(){return new r.hmac(this.hash,this.K)},n.prototype._update=function(a){var h=this._hmac().update(this.V).update([0]);a&&(h=h.update(a)),this.K=h.digest(),this.V=this._hmac().update(this.V).digest(),a&&(this.K=this._hmac().update(this.V).update([1]).update(a).digest(),this.V=this._hmac().update(this.V).digest())},n.prototype.reseed=function(a,h,v,hi){typeof h!="string"&&(hi=v,v=h,h=null),a=t.toArray(a,h),v=t.toArray(v,hi),i(a.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(a.concat(v||[])),this._reseed=1},n.prototype.generate=function(a,h,v,hi){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");typeof h!="string"&&(hi=v,v=h,h=null),v&&(v=t.toArray(v,hi||"hex"),this._update(v));for(var u=[];u.length<a;)this.V=this._hmac().update(this.V).digest(),u=u.concat(this.V);var l=u.slice(0,a);return this._update(v),this._reseed++,t.encode(l,h)},hmacDrbg}var key$1,hasRequiredKey$1;function requireKey$1(){if(hasRequiredKey$1)return key$1;hasRequiredKey$1=1;var r=requireBn$2(),t=requireUtils$1(),i=t.assert;function n(s,a){this.ec=s,this.priv=null,this.pub=null,a.priv&&this._importPrivate(a.priv,a.privEnc),a.pub&&this._importPublic(a.pub,a.pubEnc)}return key$1=n,n.fromPublic=function(a,h,v){return h instanceof n?h:new n(a,{pub:h,pubEnc:v})},n.fromPrivate=function(a,h,v){return h instanceof n?h:new n(a,{priv:h,privEnc:v})},n.prototype.validate=function(){var a=this.getPublic();return a.isInfinity()?{result:!1,reason:"Invalid public key"}:a.validate()?a.mul(this.ec.curve.n).isInfinity()?{result:!0,reason:null}:{result:!1,reason:"Public key * N != O"}:{result:!1,reason:"Public key is not a point"}},n.prototype.getPublic=function(a,h){return typeof a=="string"&&(h=a,a=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),h?this.pub.encode(h,a):this.pub},n.prototype.getPrivate=function(a){return a==="hex"?this.priv.toString(16,2):this.priv},n.prototype._importPrivate=function(a,h){this.priv=new r(a,h||16),this.priv=this.priv.umod(this.ec.curve.n)},n.prototype._importPublic=function(a,h){if(a.x||a.y){this.ec.curve.type==="mont"?i(a.x,"Need x coordinate"):(this.ec.curve.type==="short"||this.ec.curve.type==="edwards")&&i(a.x&&a.y,"Need both x and y coordinate"),this.pub=this.ec.curve.point(a.x,a.y);return}this.pub=this.ec.curve.decodePoint(a,h)},n.prototype.derive=function(a){return a.validate()||i(a.validate(),"public point not validated"),a.mul(this.priv).getX()},n.prototype.sign=function(a,h,v){return this.ec.sign(a,this,h,v)},n.prototype.verify=function(a,h,v){return this.ec.verify(a,h,this,void 0,v)},n.prototype.inspect=function(){return"<Key priv: "+(this.priv&&this.priv.toString(16,2))+" pub: "+(this.pub&&this.pub.inspect())+" >"},key$1}var signature$1,hasRequiredSignature$1;function requireSignature$1(){if(hasRequiredSignature$1)return signature$1;hasRequiredSignature$1=1;var r=requireBn$2(),t=requireUtils$1(),i=t.assert;function n(hi,u){if(hi instanceof n)return hi;this._importDER(hi,u)||(i(hi.r&&hi.s,"Signature without r or s"),this.r=new r(hi.r,16),this.s=new r(hi.s,16),hi.recoveryParam===void 0?this.recoveryParam=null:this.recoveryParam=hi.recoveryParam)}signature$1=n;function s(){this.place=0}function a(hi,u){var l=hi[u.place++];if(!(l&128))return l;var vi=l&15;if(vi===0||vi>4||hi[u.place]===0)return!1;for(var D=0,mi=0,gi=u.place;mi<vi;mi++,gi++)D<<=8,D|=hi[gi],D>>>=0;return D<=127?!1:(u.place=gi,D)}function h(hi){for(var u=0,l=hi.length-1;!hi[u]&&!(hi[u+1]&128)&&u<l;)u++;return u===0?hi:hi.slice(u)}n.prototype._importDER=function(u,l){u=t.toArray(u,l);var vi=new s;if(u[vi.place++]!==48)return!1;var D=a(u,vi);if(D===!1||D+vi.place!==u.length||u[vi.place++]!==2)return!1;var mi=a(u,vi);if(mi===!1||(u[vi.place]&128)!==0)return!1;var gi=u.slice(vi.place,mi+vi.place);if(vi.place+=mi,u[vi.place++]!==2)return!1;var bi=a(u,vi);if(bi===!1||u.length!==bi+vi.place||(u[vi.place]&128)!==0)return!1;var Ri=u.slice(vi.place,bi+vi.place);if(gi[0]===0)if(gi[1]&128)gi=gi.slice(1);else return!1;if(Ri[0]===0)if(Ri[1]&128)Ri=Ri.slice(1);else return!1;return this.r=new r(gi),this.s=new r(Ri),this.recoveryParam=null,!0};function v(hi,u){if(u<128){hi.push(u);return}var l=1+(Math.log(u)/Math.LN2>>>3);for(hi.push(l|128);--l;)hi.push(u>>>(l<<3)&255);hi.push(u)}return n.prototype.toDER=function(u){var l=this.r.toArray(),vi=this.s.toArray();for(l[0]&128&&(l=[0].concat(l)),vi[0]&128&&(vi=[0].concat(vi)),l=h(l),vi=h(vi);!vi[0]&&!(vi[1]&128);)vi=vi.slice(1);var D=[2];v(D,l.length),D=D.concat(l),D.push(2),v(D,vi.length);var mi=D.concat(vi),gi=[48];return v(gi,mi.length),gi=gi.concat(mi),t.encode(gi,u)},signature$1}var ec,hasRequiredEc;function requireEc(){if(hasRequiredEc)return ec;hasRequiredEc=1;var r=requireBn$2(),t=requireHmacDrbg(),i=requireUtils$1(),n=requireCurves(),s=requireBrorand(),a=i.assert,h=requireKey$1(),v=requireSignature$1();function hi(u){if(!(this instanceof hi))return new hi(u);typeof u=="string"&&(a(Object.prototype.hasOwnProperty.call(n,u),"Unknown curve "+u),u=n[u]),u instanceof n.PresetCurve&&(u={curve:u}),this.curve=u.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=u.curve.g,this.g.precompute(u.curve.n.bitLength()+1),this.hash=u.hash||u.curve.hash}return ec=hi,hi.prototype.keyPair=function(l){return new h(this,l)},hi.prototype.keyFromPrivate=function(l,vi){return h.fromPrivate(this,l,vi)},hi.prototype.keyFromPublic=function(l,vi){return h.fromPublic(this,l,vi)},hi.prototype.genKeyPair=function(l){l||(l={});for(var vi=new t({hash:this.hash,pers:l.pers,persEnc:l.persEnc||"utf8",entropy:l.entropy||s(this.hash.hmacStrength),entropyEnc:l.entropy&&l.entropyEnc||"utf8",nonce:this.n.toArray()}),D=this.n.byteLength(),mi=this.n.sub(new r(2));;){var gi=new r(vi.generate(D));if(!(gi.cmp(mi)>0))return gi.iaddn(1),this.keyFromPrivate(gi)}},hi.prototype._truncateToN=function(l,vi,D){var mi;if(r.isBN(l)||typeof l=="number")l=new r(l,16),mi=l.byteLength();else if(typeof l=="object")mi=l.length,l=new r(l,16);else{var gi=l.toString();mi=gi.length+1>>>1,l=new r(gi,16)}typeof D!="number"&&(D=mi*8);var bi=D-this.n.bitLength();return bi>0&&(l=l.ushrn(bi)),!vi&&l.cmp(this.n)>=0?l.sub(this.n):l},hi.prototype.sign=function(l,vi,D,mi){if(typeof D=="object"&&(mi=D,D=null),mi||(mi={}),typeof l!="string"&&typeof l!="number"&&!r.isBN(l)){a(typeof l=="object"&&l&&typeof l.length=="number","Expected message to be an array-like, a hex string, or a BN instance"),a(l.length>>>0===l.length);for(var gi=0;gi<l.length;gi++)a((l[gi]&255)===l[gi])}vi=this.keyFromPrivate(vi,D),l=this._truncateToN(l,!1,mi.msgBitLength),a(!l.isNeg(),"Can not sign a negative message");var bi=this.n.byteLength(),Ri=vi.getPrivate().toArray("be",bi),Ti=l.toArray("be",bi);a(new r(Ti).eq(l),"Can not sign message");for(var Ii=new t({hash:this.hash,entropy:Ri,nonce:Ti,pers:mi.pers,persEnc:mi.persEnc||"utf8"}),qi=this.n.sub(new r(1)),Oi=0;;Oi++){var ki=mi.k?mi.k(Oi):new r(Ii.generate(this.n.byteLength()));if(ki=this._truncateToN(ki,!0),!(ki.cmpn(1)<=0||ki.cmp(qi)>=0)){var Li=this.g.mul(ki);if(!Li.isInfinity()){var ji=Li.getX(),Hi=ji.umod(this.n);if(Hi.cmpn(0)!==0){var Ui=ki.invm(this.n).mul(Hi.mul(vi.getPrivate()).iadd(l));if(Ui=Ui.umod(this.n),Ui.cmpn(0)!==0){var Qi=(Li.getY().isOdd()?1:0)|(ji.cmp(Hi)!==0?2:0);return mi.canonical&&Ui.cmp(this.nh)>0&&(Ui=this.n.sub(Ui),Qi^=1),new v({r:Hi,s:Ui,recoveryParam:Qi})}}}}}},hi.prototype.verify=function(l,vi,D,mi,gi){gi||(gi={}),l=this._truncateToN(l,!1,gi.msgBitLength),D=this.keyFromPublic(D,mi),vi=new v(vi,"hex");var bi=vi.r,Ri=vi.s;if(bi.cmpn(1)<0||bi.cmp(this.n)>=0||Ri.cmpn(1)<0||Ri.cmp(this.n)>=0)return!1;var Ti=Ri.invm(this.n),Ii=Ti.mul(l).umod(this.n),qi=Ti.mul(bi).umod(this.n),Oi;return this.curve._maxwellTrick?(Oi=this.g.jmulAdd(Ii,D.getPublic(),qi),Oi.isInfinity()?!1:Oi.eqXToP(bi)):(Oi=this.g.mulAdd(Ii,D.getPublic(),qi),Oi.isInfinity()?!1:Oi.getX().umod(this.n).cmp(bi)===0)},hi.prototype.recoverPubKey=function(u,l,vi,D){a((3&vi)===vi,"The recovery param is more than two bits"),l=new v(l,D);var mi=this.n,gi=new r(u),bi=l.r,Ri=l.s,Ti=vi&1,Ii=vi>>1;if(bi.cmp(this.curve.p.umod(this.curve.n))>=0&&Ii)throw new Error("Unable to find sencond key candinate");Ii?bi=this.curve.pointFromX(bi.add(this.curve.n),Ti):bi=this.curve.pointFromX(bi,Ti);var qi=l.r.invm(mi),Oi=mi.sub(gi).mul(qi).umod(mi),ki=Ri.mul(qi).umod(mi);return this.g.mulAdd(Oi,bi,ki)},hi.prototype.getKeyRecoveryParam=function(u,l,vi,D){if(l=new v(l,D),l.recoveryParam!==null)return l.recoveryParam;for(var mi=0;mi<4;mi++){var gi;try{gi=this.recoverPubKey(u,l,mi)}catch{continue}if(gi.eq(vi))return mi}throw new Error("Unable to find valid recovery factor")},ec}var key,hasRequiredKey;function requireKey(){if(hasRequiredKey)return key;hasRequiredKey=1;var r=requireUtils$1(),t=r.assert,i=r.parseBytes,n=r.cachedProperty;function s(a,h){this.eddsa=a,this._secret=i(h.secret),a.isPoint(h.pub)?this._pub=h.pub:this._pubBytes=i(h.pub)}return s.fromPublic=function(h,v){return v instanceof s?v:new s(h,{pub:v})},s.fromSecret=function(h,v){return v instanceof s?v:new s(h,{secret:v})},s.prototype.secret=function(){return this._secret},n(s,"pubBytes",function(){return this.eddsa.encodePoint(this.pub())}),n(s,"pub",function(){return this._pubBytes?this.eddsa.decodePoint(this._pubBytes):this.eddsa.g.mul(this.priv())}),n(s,"privBytes",function(){var h=this.eddsa,v=this.hash(),hi=h.encodingLength-1,u=v.slice(0,h.encodingLength);return u[0]&=248,u[hi]&=127,u[hi]|=64,u}),n(s,"priv",function(){return this.eddsa.decodeInt(this.privBytes())}),n(s,"hash",function(){return this.eddsa.hash().update(this.secret()).digest()}),n(s,"messagePrefix",function(){return this.hash().slice(this.eddsa.encodingLength)}),s.prototype.sign=function(h){return t(this._secret,"KeyPair can only verify"),this.eddsa.sign(h,this)},s.prototype.verify=function(h,v){return this.eddsa.verify(h,v,this)},s.prototype.getSecret=function(h){return t(this._secret,"KeyPair is public only"),r.encode(this.secret(),h)},s.prototype.getPublic=function(h){return r.encode(this.pubBytes(),h)},key=s,key}var signature,hasRequiredSignature;function requireSignature(){if(hasRequiredSignature)return signature;hasRequiredSignature=1;var r=requireBn$2(),t=requireUtils$1(),i=t.assert,n=t.cachedProperty,s=t.parseBytes;function a(h,v){this.eddsa=h,typeof v!="object"&&(v=s(v)),Array.isArray(v)&&(i(v.length===h.encodingLength*2,"Signature has invalid size"),v={R:v.slice(0,h.encodingLength),S:v.slice(h.encodingLength)}),i(v.R&&v.S,"Signature without R or S"),h.isPoint(v.R)&&(this._R=v.R),v.S instanceof r&&(this._S=v.S),this._Rencoded=Array.isArray(v.R)?v.R:v.Rencoded,this._Sencoded=Array.isArray(v.S)?v.S:v.Sencoded}return n(a,"S",function(){return this.eddsa.decodeInt(this.Sencoded())}),n(a,"R",function(){return this.eddsa.decodePoint(this.Rencoded())}),n(a,"Rencoded",function(){return this.eddsa.encodePoint(this.R())}),n(a,"Sencoded",function(){return this.eddsa.encodeInt(this.S())}),a.prototype.toBytes=function(){return this.Rencoded().concat(this.Sencoded())},a.prototype.toHex=function(){return t.encode(this.toBytes(),"hex").toUpperCase()},signature=a,signature}var eddsa,hasRequiredEddsa;function requireEddsa(){if(hasRequiredEddsa)return eddsa;hasRequiredEddsa=1;var r=requireHash(),t=requireCurves(),i=requireUtils$1(),n=i.assert,s=i.parseBytes,a=requireKey(),h=requireSignature();function v(hi){if(n(hi==="ed25519","only tested with ed25519 so far"),!(this instanceof v))return new v(hi);hi=t[hi].curve,this.curve=hi,this.g=hi.g,this.g.precompute(hi.n.bitLength()+1),this.pointClass=hi.point().constructor,this.encodingLength=Math.ceil(hi.n.bitLength()/8),this.hash=r.sha512}return eddsa=v,v.prototype.sign=function(u,l){u=s(u);var vi=this.keyFromSecret(l),D=this.hashInt(vi.messagePrefix(),u),mi=this.g.mul(D),gi=this.encodePoint(mi),bi=this.hashInt(gi,vi.pubBytes(),u).mul(vi.priv()),Ri=D.add(bi).umod(this.curve.n);return this.makeSignature({R:mi,S:Ri,Rencoded:gi})},v.prototype.verify=function(u,l,vi){if(u=s(u),l=this.makeSignature(l),l.S().gte(l.eddsa.curve.n)||l.S().isNeg())return!1;var D=this.keyFromPublic(vi),mi=this.hashInt(l.Rencoded(),D.pubBytes(),u),gi=this.g.mul(l.S()),bi=l.R().add(D.pub().mul(mi));return bi.eq(gi)},v.prototype.hashInt=function(){for(var u=this.hash(),l=0;l<arguments.length;l++)u.update(arguments[l]);return i.intFromLE(u.digest()).umod(this.curve.n)},v.prototype.keyFromPublic=function(u){return a.fromPublic(this,u)},v.prototype.keyFromSecret=function(u){return a.fromSecret(this,u)},v.prototype.makeSignature=function(u){return u instanceof h?u:new h(this,u)},v.prototype.encodePoint=function(u){var l=u.getY().toArray("le",this.encodingLength);return l[this.encodingLength-1]|=u.getX().isOdd()?128:0,l},v.prototype.decodePoint=function(u){u=i.parseBytes(u);var l=u.length-1,vi=u.slice(0,l).concat(u[l]&-129),D=(u[l]&128)!==0,mi=i.intFromLE(vi);return this.curve.pointFromY(mi,D)},v.prototype.encodeInt=function(u){return u.toArray("le",this.encodingLength)},v.prototype.decodeInt=function(u){return i.intFromLE(u)},v.prototype.isPoint=function(u){return u instanceof this.pointClass},eddsa}var hasRequiredElliptic;function requireElliptic(){return hasRequiredElliptic||(hasRequiredElliptic=1,function(r){var t=r;t.version=require$$0$1.version,t.utils=requireUtils$1(),t.rand=requireBrorand(),t.curve=requireCurve(),t.curves=requireCurves(),t.ec=requireEc(),t.eddsa=requireEddsa()}(elliptic)),elliptic}var bn$1={exports:{}},bn=bn$1.exports,hasRequiredBn;function requireBn(){return hasRequiredBn||(hasRequiredBn=1,function(r){(function(t,i){function n(xi,yi){if(!xi)throw new Error(yi||"Assertion failed")}function s(xi,yi){xi.super_=yi;var Ei=function(){};Ei.prototype=yi.prototype,xi.prototype=new Ei,xi.prototype.constructor=xi}function a(xi,yi,Ei){if(a.isBN(xi))return xi;this.negative=0,this.words=null,this.length=0,this.red=null,xi!==null&&((yi==="le"||yi==="be")&&(Ei=yi,yi=10),this._init(xi||0,yi||10,Ei||"be"))}typeof t=="object"?t.exports=a:i.BN=a,a.BN=a,a.wordSize=26;var h;try{typeof window<"u"&&typeof window.Buffer<"u"?h=window.Buffer:h=requireDist().Buffer}catch{}a.isBN=function(yi){return yi instanceof a?!0:yi!==null&&typeof yi=="object"&&yi.constructor.wordSize===a.wordSize&&Array.isArray(yi.words)},a.max=function(yi,Ei){return yi.cmp(Ei)>0?yi:Ei},a.min=function(yi,Ei){return yi.cmp(Ei)<0?yi:Ei},a.prototype._init=function(yi,Ei,Ci){if(typeof yi=="number")return this._initNumber(yi,Ei,Ci);if(typeof yi=="object")return this._initArray(yi,Ei,Ci);Ei==="hex"&&(Ei=16),n(Ei===(Ei|0)&&Ei>=2&&Ei<=36),yi=yi.toString().replace(/\s+/g,"");var Ni=0;yi[0]==="-"&&(Ni++,this.negative=1),Ni<yi.length&&(Ei===16?this._parseHex(yi,Ni,Ci):(this._parseBase(yi,Ei,Ni),Ci==="le"&&this._initArray(this.toArray(),Ei,Ci)))},a.prototype._initNumber=function(yi,Ei,Ci){yi<0&&(this.negative=1,yi=-yi),yi<67108864?(this.words=[yi&67108863],this.length=1):yi<4503599627370496?(this.words=[yi&67108863,yi/67108864&67108863],this.length=2):(n(yi<9007199254740992),this.words=[yi&67108863,yi/67108864&67108863,1],this.length=3),Ci==="le"&&this._initArray(this.toArray(),Ei,Ci)},a.prototype._initArray=function(yi,Ei,Ci){if(n(typeof yi.length=="number"),yi.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(yi.length/3),this.words=new Array(this.length);for(var Ni=0;Ni<this.length;Ni++)this.words[Ni]=0;var Fi,Mi,Si=0;if(Ci==="be")for(Ni=yi.length-1,Fi=0;Ni>=0;Ni-=3)Mi=yi[Ni]|yi[Ni-1]<<8|yi[Ni-2]<<16,this.words[Fi]|=Mi<<Si&67108863,this.words[Fi+1]=Mi>>>26-Si&67108863,Si+=24,Si>=26&&(Si-=26,Fi++);else if(Ci==="le")for(Ni=0,Fi=0;Ni<yi.length;Ni+=3)Mi=yi[Ni]|yi[Ni+1]<<8|yi[Ni+2]<<16,this.words[Fi]|=Mi<<Si&67108863,this.words[Fi+1]=Mi>>>26-Si&67108863,Si+=24,Si>=26&&(Si-=26,Fi++);return this._strip()};function v(xi,yi){var Ei=xi.charCodeAt(yi);if(Ei>=48&&Ei<=57)return Ei-48;if(Ei>=65&&Ei<=70)return Ei-55;if(Ei>=97&&Ei<=102)return Ei-87;n(!1,"Invalid character in "+xi)}function hi(xi,yi,Ei){var Ci=v(xi,Ei);return Ei-1>=yi&&(Ci|=v(xi,Ei-1)<<4),Ci}a.prototype._parseHex=function(yi,Ei,Ci){this.length=Math.ceil((yi.length-Ei)/6),this.words=new Array(this.length);for(var Ni=0;Ni<this.length;Ni++)this.words[Ni]=0;var Fi=0,Mi=0,Si;if(Ci==="be")for(Ni=yi.length-1;Ni>=Ei;Ni-=2)Si=hi(yi,Ei,Ni)<<Fi,this.words[Mi]|=Si&67108863,Fi>=18?(Fi-=18,Mi+=1,this.words[Mi]|=Si>>>26):Fi+=8;else{var Ai=yi.length-Ei;for(Ni=Ai%2===0?Ei+1:Ei;Ni<yi.length;Ni+=2)Si=hi(yi,Ei,Ni)<<Fi,this.words[Mi]|=Si&67108863,Fi>=18?(Fi-=18,Mi+=1,this.words[Mi]|=Si>>>26):Fi+=8}this._strip()};function u(xi,yi,Ei,Ci){for(var Ni=0,Fi=0,Mi=Math.min(xi.length,Ei),Si=yi;Si<Mi;Si++){var Ai=xi.charCodeAt(Si)-48;Ni*=Ci,Ai>=49?Fi=Ai-49+10:Ai>=17?Fi=Ai-17+10:Fi=Ai,n(Ai>=0&&Fi<Ci,"Invalid character"),Ni+=Fi}return Ni}a.prototype._parseBase=function(yi,Ei,Ci){this.words=[0],this.length=1;for(var Ni=0,Fi=1;Fi<=67108863;Fi*=Ei)Ni++;Ni--,Fi=Fi/Ei|0;for(var Mi=yi.length-Ci,Si=Mi%Ni,Ai=Math.min(Mi,Mi-Si)+Ci,_i=0,Bi=Ci;Bi<Ai;Bi+=Ni)_i=u(yi,Bi,Bi+Ni,Ei),this.imuln(Fi),this.words[0]+_i<67108864?this.words[0]+=_i:this._iaddn(_i);if(Si!==0){var Pi=1;for(_i=u(yi,Bi,yi.length,Ei),Bi=0;Bi<Si;Bi++)Pi*=Ei;this.imuln(Pi),this.words[0]+_i<67108864?this.words[0]+=_i:this._iaddn(_i)}this._strip()},a.prototype.copy=function(yi){yi.words=new Array(this.length);for(var Ei=0;Ei<this.length;Ei++)yi.words[Ei]=this.words[Ei];yi.length=this.length,yi.negative=this.negative,yi.red=this.red};function l(xi,yi){xi.words=yi.words,xi.length=yi.length,xi.negative=yi.negative,xi.red=yi.red}if(a.prototype._move=function(yi){l(yi,this)},a.prototype.clone=function(){var yi=new a(null);return this.copy(yi),yi},a.prototype._expand=function(yi){for(;this.length<yi;)this.words[this.length++]=0;return this},a.prototype._strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},a.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},typeof Symbol<"u"&&typeof Symbol.for=="function")try{a.prototype[Symbol.for("nodejs.util.inspect.custom")]=vi}catch{a.prototype.inspect=vi}else a.prototype.inspect=vi;function vi(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"}var D=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],mi=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],gi=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];a.prototype.toString=function(yi,Ei){yi=yi||10,Ei=Ei|0||1;var Ci;if(yi===16||yi==="hex"){Ci="";for(var Ni=0,Fi=0,Mi=0;Mi<this.length;Mi++){var Si=this.words[Mi],Ai=((Si<<Ni|Fi)&16777215).toString(16);Fi=Si>>>24-Ni&16777215,Ni+=2,Ni>=26&&(Ni-=26,Mi--),Fi!==0||Mi!==this.length-1?Ci=D[6-Ai.length]+Ai+Ci:Ci=Ai+Ci}for(Fi!==0&&(Ci=Fi.toString(16)+Ci);Ci.length%Ei!==0;)Ci="0"+Ci;return this.negative!==0&&(Ci="-"+Ci),Ci}if(yi===(yi|0)&&yi>=2&&yi<=36){var _i=mi[yi],Bi=gi[yi];Ci="";var Pi=this.clone();for(Pi.negative=0;!Pi.isZero();){var zi=Pi.modrn(Bi).toString(yi);Pi=Pi.idivn(Bi),Pi.isZero()?Ci=zi+Ci:Ci=D[_i-zi.length]+zi+Ci}for(this.isZero()&&(Ci="0"+Ci);Ci.length%Ei!==0;)Ci="0"+Ci;return this.negative!==0&&(Ci="-"+Ci),Ci}n(!1,"Base should be between 2 and 36")},a.prototype.toNumber=function(){var yi=this.words[0];return this.length===2?yi+=this.words[1]*67108864:this.length===3&&this.words[2]===1?yi+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-yi:yi},a.prototype.toJSON=function(){return this.toString(16,2)},h&&(a.prototype.toBuffer=function(yi,Ei){return this.toArrayLike(h,yi,Ei)}),a.prototype.toArray=function(yi,Ei){return this.toArrayLike(Array,yi,Ei)};var bi=function(yi,Ei){return yi.allocUnsafe?yi.allocUnsafe(Ei):new yi(Ei)};a.prototype.toArrayLike=function(yi,Ei,Ci){this._strip();var Ni=this.byteLength(),Fi=Ci||Math.max(1,Ni);n(Ni<=Fi,"byte array longer than desired length"),n(Fi>0,"Requested array length <= 0");var Mi=bi(yi,Fi),Si=Ei==="le"?"LE":"BE";return this["_toArrayLike"+Si](Mi,Ni),Mi},a.prototype._toArrayLikeLE=function(yi,Ei){for(var Ci=0,Ni=0,Fi=0,Mi=0;Fi<this.length;Fi++){var Si=this.words[Fi]<<Mi|Ni;yi[Ci++]=Si&255,Ci<yi.length&&(yi[Ci++]=Si>>8&255),Ci<yi.length&&(yi[Ci++]=Si>>16&255),Mi===6?(Ci<yi.length&&(yi[Ci++]=Si>>24&255),Ni=0,Mi=0):(Ni=Si>>>24,Mi+=2)}if(Ci<yi.length)for(yi[Ci++]=Ni;Ci<yi.length;)yi[Ci++]=0},a.prototype._toArrayLikeBE=function(yi,Ei){for(var Ci=yi.length-1,Ni=0,Fi=0,Mi=0;Fi<this.length;Fi++){var Si=this.words[Fi]<<Mi|Ni;yi[Ci--]=Si&255,Ci>=0&&(yi[Ci--]=Si>>8&255),Ci>=0&&(yi[Ci--]=Si>>16&255),Mi===6?(Ci>=0&&(yi[Ci--]=Si>>24&255),Ni=0,Mi=0):(Ni=Si>>>24,Mi+=2)}if(Ci>=0)for(yi[Ci--]=Ni;Ci>=0;)yi[Ci--]=0},Math.clz32?a.prototype._countBits=function(yi){return 32-Math.clz32(yi)}:a.prototype._countBits=function(yi){var Ei=yi,Ci=0;return Ei>=4096&&(Ci+=13,Ei>>>=13),Ei>=64&&(Ci+=7,Ei>>>=7),Ei>=8&&(Ci+=4,Ei>>>=4),Ei>=2&&(Ci+=2,Ei>>>=2),Ci+Ei},a.prototype._zeroBits=function(yi){if(yi===0)return 26;var Ei=yi,Ci=0;return(Ei&8191)===0&&(Ci+=13,Ei>>>=13),(Ei&127)===0&&(Ci+=7,Ei>>>=7),(Ei&15)===0&&(Ci+=4,Ei>>>=4),(Ei&3)===0&&(Ci+=2,Ei>>>=2),(Ei&1)===0&&Ci++,Ci},a.prototype.bitLength=function(){var yi=this.words[this.length-1],Ei=this._countBits(yi);return(this.length-1)*26+Ei};function Ri(xi){for(var yi=new Array(xi.bitLength()),Ei=0;Ei<yi.length;Ei++){var Ci=Ei/26|0,Ni=Ei%26;yi[Ei]=xi.words[Ci]>>>Ni&1}return yi}a.prototype.zeroBits=function(){if(this.isZero())return 0;for(var yi=0,Ei=0;Ei<this.length;Ei++){var Ci=this._zeroBits(this.words[Ei]);if(yi+=Ci,Ci!==26)break}return yi},a.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},a.prototype.toTwos=function(yi){return this.negative!==0?this.abs().inotn(yi).iaddn(1):this.clone()},a.prototype.fromTwos=function(yi){return this.testn(yi-1)?this.notn(yi).iaddn(1).ineg():this.clone()},a.prototype.isNeg=function(){return this.negative!==0},a.prototype.neg=function(){return this.clone().ineg()},a.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},a.prototype.iuor=function(yi){for(;this.length<yi.length;)this.words[this.length++]=0;for(var Ei=0;Ei<yi.length;Ei++)this.words[Ei]=this.words[Ei]|yi.words[Ei];return this._strip()},a.prototype.ior=function(yi){return n((this.negative|yi.negative)===0),this.iuor(yi)},a.prototype.or=function(yi){return this.length>yi.length?this.clone().ior(yi):yi.clone().ior(this)},a.prototype.uor=function(yi){return this.length>yi.length?this.clone().iuor(yi):yi.clone().iuor(this)},a.prototype.iuand=function(yi){var Ei;this.length>yi.length?Ei=yi:Ei=this;for(var Ci=0;Ci<Ei.length;Ci++)this.words[Ci]=this.words[Ci]&yi.words[Ci];return this.length=Ei.length,this._strip()},a.prototype.iand=function(yi){return n((this.negative|yi.negative)===0),this.iuand(yi)},a.prototype.and=function(yi){return this.length>yi.length?this.clone().iand(yi):yi.clone().iand(this)},a.prototype.uand=function(yi){return this.length>yi.length?this.clone().iuand(yi):yi.clone().iuand(this)},a.prototype.iuxor=function(yi){var Ei,Ci;this.length>yi.length?(Ei=this,Ci=yi):(Ei=yi,Ci=this);for(var Ni=0;Ni<Ci.length;Ni++)this.words[Ni]=Ei.words[Ni]^Ci.words[Ni];if(this!==Ei)for(;Ni<Ei.length;Ni++)this.words[Ni]=Ei.words[Ni];return this.length=Ei.length,this._strip()},a.prototype.ixor=function(yi){return n((this.negative|yi.negative)===0),this.iuxor(yi)},a.prototype.xor=function(yi){return this.length>yi.length?this.clone().ixor(yi):yi.clone().ixor(this)},a.prototype.uxor=function(yi){return this.length>yi.length?this.clone().iuxor(yi):yi.clone().iuxor(this)},a.prototype.inotn=function(yi){n(typeof yi=="number"&&yi>=0);var Ei=Math.ceil(yi/26)|0,Ci=yi%26;this._expand(Ei),Ci>0&&Ei--;for(var Ni=0;Ni<Ei;Ni++)this.words[Ni]=~this.words[Ni]&67108863;return Ci>0&&(this.words[Ni]=~this.words[Ni]&67108863>>26-Ci),this._strip()},a.prototype.notn=function(yi){return this.clone().inotn(yi)},a.prototype.setn=function(yi,Ei){n(typeof yi=="number"&&yi>=0);var Ci=yi/26|0,Ni=yi%26;return this._expand(Ci+1),Ei?this.words[Ci]=this.words[Ci]|1<<Ni:this.words[Ci]=this.words[Ci]&~(1<<Ni),this._strip()},a.prototype.iadd=function(yi){var Ei;if(this.negative!==0&&yi.negative===0)return this.negative=0,Ei=this.isub(yi),this.negative^=1,this._normSign();if(this.negative===0&&yi.negative!==0)return yi.negative=0,Ei=this.isub(yi),yi.negative=1,Ei._normSign();var Ci,Ni;this.length>yi.length?(Ci=this,Ni=yi):(Ci=yi,Ni=this);for(var Fi=0,Mi=0;Mi<Ni.length;Mi++)Ei=(Ci.words[Mi]|0)+(Ni.words[Mi]|0)+Fi,this.words[Mi]=Ei&67108863,Fi=Ei>>>26;for(;Fi!==0&&Mi<Ci.length;Mi++)Ei=(Ci.words[Mi]|0)+Fi,this.words[Mi]=Ei&67108863,Fi=Ei>>>26;if(this.length=Ci.length,Fi!==0)this.words[this.length]=Fi,this.length++;else if(Ci!==this)for(;Mi<Ci.length;Mi++)this.words[Mi]=Ci.words[Mi];return this},a.prototype.add=function(yi){var Ei;return yi.negative!==0&&this.negative===0?(yi.negative=0,Ei=this.sub(yi),yi.negative^=1,Ei):yi.negative===0&&this.negative!==0?(this.negative=0,Ei=yi.sub(this),this.negative=1,Ei):this.length>yi.length?this.clone().iadd(yi):yi.clone().iadd(this)},a.prototype.isub=function(yi){if(yi.negative!==0){yi.negative=0;var Ei=this.iadd(yi);return yi.negative=1,Ei._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(yi),this.negative=1,this._normSign();var Ci=this.cmp(yi);if(Ci===0)return this.negative=0,this.length=1,this.words[0]=0,this;var Ni,Fi;Ci>0?(Ni=this,Fi=yi):(Ni=yi,Fi=this);for(var Mi=0,Si=0;Si<Fi.length;Si++)Ei=(Ni.words[Si]|0)-(Fi.words[Si]|0)+Mi,Mi=Ei>>26,this.words[Si]=Ei&67108863;for(;Mi!==0&&Si<Ni.length;Si++)Ei=(Ni.words[Si]|0)+Mi,Mi=Ei>>26,this.words[Si]=Ei&67108863;if(Mi===0&&Si<Ni.length&&Ni!==this)for(;Si<Ni.length;Si++)this.words[Si]=Ni.words[Si];return this.length=Math.max(this.length,Si),Ni!==this&&(this.negative=1),this._strip()},a.prototype.sub=function(yi){return this.clone().isub(yi)};function Ti(xi,yi,Ei){Ei.negative=yi.negative^xi.negative;var Ci=xi.length+yi.length|0;Ei.length=Ci,Ci=Ci-1|0;var Ni=xi.words[0]|0,Fi=yi.words[0]|0,Mi=Ni*Fi,Si=Mi&67108863,Ai=Mi/67108864|0;Ei.words[0]=Si;for(var _i=1;_i<Ci;_i++){for(var Bi=Ai>>>26,Pi=Ai&67108863,zi=Math.min(_i,yi.length-1),Gi=Math.max(0,_i-xi.length+1);Gi<=zi;Gi++){var Vi=_i-Gi|0;Ni=xi.words[Vi]|0,Fi=yi.words[Gi]|0,Mi=Ni*Fi+Pi,Bi+=Mi/67108864|0,Pi=Mi&67108863}Ei.words[_i]=Pi|0,Ai=Bi|0}return Ai!==0?Ei.words[_i]=Ai|0:Ei.length--,Ei._strip()}var Ii=function(yi,Ei,Ci){var Ni=yi.words,Fi=Ei.words,Mi=Ci.words,Si=0,Ai,_i,Bi,Pi=Ni[0]|0,zi=Pi&8191,Gi=Pi>>>13,Vi=Ni[1]|0,Ki=Vi&8191,Zi=Vi>>>13,In=Ni[2]|0,Ji=In&8191,Xi=In>>>13,on=Ni[3]|0,jn=on&8191,Ln=on>>>13,Hn=Ni[4]|0,ea=Hn&8191,ia=Hn>>>13,Wn=Ni[5]|0,oa=Wn&8191,ta=Wn>>>13,aa=Ni[6]|0,sa=aa&8191,ua=aa>>>13,da=Ni[7]|0,ca=da&8191,la=da>>>13,Fa=Ni[8]|0,xa=Fa&8191,ha=Fa>>>13,Ca=Ni[9]|0,Ra=Ca&8191,pa=Ca>>>13,Ma=Fi[0]|0,wa=Ma&8191,ya=Ma>>>13,La=Fi[1]|0,Sa=La&8191,ga=La>>>13,Pa=Fi[2]|0,Ta=Pa&8191,va=Pa>>>13,Ba=Fi[3]|0,Aa=Ba&8191,_a=Ba>>>13,ka=Fi[4]|0,Na=ka&8191,Rn=ka>>>13,Wi=Fi[5]|0,Yi=Wi&8191,Mn=Wi>>>13,Yn=Fi[6]|0,ra=Yn&8191,na=Yn>>>13,Ea=Fi[7]|0,ba=Ea&8191,fa=Ea>>>13,Ia=Fi[8]|0,ma=Ia&8191,Da=Ia>>>13,$a=Fi[9]|0,qa=$a&8191,Oa=$a>>>13;Ci.negative=yi.negative^Ei.negative,Ci.length=19,Ai=Math.imul(zi,wa),_i=Math.imul(zi,ya),_i=_i+Math.imul(Gi,wa)|0,Bi=Math.imul(Gi,ya);var Ua=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Ua>>>26)|0,Ua&=67108863,Ai=Math.imul(Ki,wa),_i=Math.imul(Ki,ya),_i=_i+Math.imul(Zi,wa)|0,Bi=Math.imul(Zi,ya),Ai=Ai+Math.imul(zi,Sa)|0,_i=_i+Math.imul(zi,ga)|0,_i=_i+Math.imul(Gi,Sa)|0,Bi=Bi+Math.imul(Gi,ga)|0;var ja=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(ja>>>26)|0,ja&=67108863,Ai=Math.imul(Ji,wa),_i=Math.imul(Ji,ya),_i=_i+Math.imul(Xi,wa)|0,Bi=Math.imul(Xi,ya),Ai=Ai+Math.imul(Ki,Sa)|0,_i=_i+Math.imul(Ki,ga)|0,_i=_i+Math.imul(Zi,Sa)|0,Bi=Bi+Math.imul(Zi,ga)|0,Ai=Ai+Math.imul(zi,Ta)|0,_i=_i+Math.imul(zi,va)|0,_i=_i+Math.imul(Gi,Ta)|0,Bi=Bi+Math.imul(Gi,va)|0;var Va=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Va>>>26)|0,Va&=67108863,Ai=Math.imul(jn,wa),_i=Math.imul(jn,ya),_i=_i+Math.imul(Ln,wa)|0,Bi=Math.imul(Ln,ya),Ai=Ai+Math.imul(Ji,Sa)|0,_i=_i+Math.imul(Ji,ga)|0,_i=_i+Math.imul(Xi,Sa)|0,Bi=Bi+Math.imul(Xi,ga)|0,Ai=Ai+Math.imul(Ki,Ta)|0,_i=_i+Math.imul(Ki,va)|0,_i=_i+Math.imul(Zi,Ta)|0,Bi=Bi+Math.imul(Zi,va)|0,Ai=Ai+Math.imul(zi,Aa)|0,_i=_i+Math.imul(zi,_a)|0,_i=_i+Math.imul(Gi,Aa)|0,Bi=Bi+Math.imul(Gi,_a)|0;var Ga=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Ga>>>26)|0,Ga&=67108863,Ai=Math.imul(ea,wa),_i=Math.imul(ea,ya),_i=_i+Math.imul(ia,wa)|0,Bi=Math.imul(ia,ya),Ai=Ai+Math.imul(jn,Sa)|0,_i=_i+Math.imul(jn,ga)|0,_i=_i+Math.imul(Ln,Sa)|0,Bi=Bi+Math.imul(Ln,ga)|0,Ai=Ai+Math.imul(Ji,Ta)|0,_i=_i+Math.imul(Ji,va)|0,_i=_i+Math.imul(Xi,Ta)|0,Bi=Bi+Math.imul(Xi,va)|0,Ai=Ai+Math.imul(Ki,Aa)|0,_i=_i+Math.imul(Ki,_a)|0,_i=_i+Math.imul(Zi,Aa)|0,Bi=Bi+Math.imul(Zi,_a)|0,Ai=Ai+Math.imul(zi,Na)|0,_i=_i+Math.imul(zi,Rn)|0,_i=_i+Math.imul(Gi,Na)|0,Bi=Bi+Math.imul(Gi,Rn)|0;var Ka=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Ka>>>26)|0,Ka&=67108863,Ai=Math.imul(oa,wa),_i=Math.imul(oa,ya),_i=_i+Math.imul(ta,wa)|0,Bi=Math.imul(ta,ya),Ai=Ai+Math.imul(ea,Sa)|0,_i=_i+Math.imul(ea,ga)|0,_i=_i+Math.imul(ia,Sa)|0,Bi=Bi+Math.imul(ia,ga)|0,Ai=Ai+Math.imul(jn,Ta)|0,_i=_i+Math.imul(jn,va)|0,_i=_i+Math.imul(Ln,Ta)|0,Bi=Bi+Math.imul(Ln,va)|0,Ai=Ai+Math.imul(Ji,Aa)|0,_i=_i+Math.imul(Ji,_a)|0,_i=_i+Math.imul(Xi,Aa)|0,Bi=Bi+Math.imul(Xi,_a)|0,Ai=Ai+Math.imul(Ki,Na)|0,_i=_i+Math.imul(Ki,Rn)|0,_i=_i+Math.imul(Zi,Na)|0,Bi=Bi+Math.imul(Zi,Rn)|0,Ai=Ai+Math.imul(zi,Yi)|0,_i=_i+Math.imul(zi,Mn)|0,_i=_i+Math.imul(Gi,Yi)|0,Bi=Bi+Math.imul(Gi,Mn)|0;var Ha=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Ha>>>26)|0,Ha&=67108863,Ai=Math.imul(sa,wa),_i=Math.imul(sa,ya),_i=_i+Math.imul(ua,wa)|0,Bi=Math.imul(ua,ya),Ai=Ai+Math.imul(oa,Sa)|0,_i=_i+Math.imul(oa,ga)|0,_i=_i+Math.imul(ta,Sa)|0,Bi=Bi+Math.imul(ta,ga)|0,Ai=Ai+Math.imul(ea,Ta)|0,_i=_i+Math.imul(ea,va)|0,_i=_i+Math.imul(ia,Ta)|0,Bi=Bi+Math.imul(ia,va)|0,Ai=Ai+Math.imul(jn,Aa)|0,_i=_i+Math.imul(jn,_a)|0,_i=_i+Math.imul(Ln,Aa)|0,Bi=Bi+Math.imul(Ln,_a)|0,Ai=Ai+Math.imul(Ji,Na)|0,_i=_i+Math.imul(Ji,Rn)|0,_i=_i+Math.imul(Xi,Na)|0,Bi=Bi+Math.imul(Xi,Rn)|0,Ai=Ai+Math.imul(Ki,Yi)|0,_i=_i+Math.imul(Ki,Mn)|0,_i=_i+Math.imul(Zi,Yi)|0,Bi=Bi+Math.imul(Zi,Mn)|0,Ai=Ai+Math.imul(zi,ra)|0,_i=_i+Math.imul(zi,na)|0,_i=_i+Math.imul(Gi,ra)|0,Bi=Bi+Math.imul(Gi,na)|0;var Qa=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Qa>>>26)|0,Qa&=67108863,Ai=Math.imul(ca,wa),_i=Math.imul(ca,ya),_i=_i+Math.imul(la,wa)|0,Bi=Math.imul(la,ya),Ai=Ai+Math.imul(sa,Sa)|0,_i=_i+Math.imul(sa,ga)|0,_i=_i+Math.imul(ua,Sa)|0,Bi=Bi+Math.imul(ua,ga)|0,Ai=Ai+Math.imul(oa,Ta)|0,_i=_i+Math.imul(oa,va)|0,_i=_i+Math.imul(ta,Ta)|0,Bi=Bi+Math.imul(ta,va)|0,Ai=Ai+Math.imul(ea,Aa)|0,_i=_i+Math.imul(ea,_a)|0,_i=_i+Math.imul(ia,Aa)|0,Bi=Bi+Math.imul(ia,_a)|0,Ai=Ai+Math.imul(jn,Na)|0,_i=_i+Math.imul(jn,Rn)|0,_i=_i+Math.imul(Ln,Na)|0,Bi=Bi+Math.imul(Ln,Rn)|0,Ai=Ai+Math.imul(Ji,Yi)|0,_i=_i+Math.imul(Ji,Mn)|0,_i=_i+Math.imul(Xi,Yi)|0,Bi=Bi+Math.imul(Xi,Mn)|0,Ai=Ai+Math.imul(Ki,ra)|0,_i=_i+Math.imul(Ki,na)|0,_i=_i+Math.imul(Zi,ra)|0,Bi=Bi+Math.imul(Zi,na)|0,Ai=Ai+Math.imul(zi,ba)|0,_i=_i+Math.imul(zi,fa)|0,_i=_i+Math.imul(Gi,ba)|0,Bi=Bi+Math.imul(Gi,fa)|0;var za=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(za>>>26)|0,za&=67108863,Ai=Math.imul(xa,wa),_i=Math.imul(xa,ya),_i=_i+Math.imul(ha,wa)|0,Bi=Math.imul(ha,ya),Ai=Ai+Math.imul(ca,Sa)|0,_i=_i+Math.imul(ca,ga)|0,_i=_i+Math.imul(la,Sa)|0,Bi=Bi+Math.imul(la,ga)|0,Ai=Ai+Math.imul(sa,Ta)|0,_i=_i+Math.imul(sa,va)|0,_i=_i+Math.imul(ua,Ta)|0,Bi=Bi+Math.imul(ua,va)|0,Ai=Ai+Math.imul(oa,Aa)|0,_i=_i+Math.imul(oa,_a)|0,_i=_i+Math.imul(ta,Aa)|0,Bi=Bi+Math.imul(ta,_a)|0,Ai=Ai+Math.imul(ea,Na)|0,_i=_i+Math.imul(ea,Rn)|0,_i=_i+Math.imul(ia,Na)|0,Bi=Bi+Math.imul(ia,Rn)|0,Ai=Ai+Math.imul(jn,Yi)|0,_i=_i+Math.imul(jn,Mn)|0,_i=_i+Math.imul(Ln,Yi)|0,Bi=Bi+Math.imul(Ln,Mn)|0,Ai=Ai+Math.imul(Ji,ra)|0,_i=_i+Math.imul(Ji,na)|0,_i=_i+Math.imul(Xi,ra)|0,Bi=Bi+Math.imul(Xi,na)|0,Ai=Ai+Math.imul(Ki,ba)|0,_i=_i+Math.imul(Ki,fa)|0,_i=_i+Math.imul(Zi,ba)|0,Bi=Bi+Math.imul(Zi,fa)|0,Ai=Ai+Math.imul(zi,ma)|0,_i=_i+Math.imul(zi,Da)|0,_i=_i+Math.imul(Gi,ma)|0,Bi=Bi+Math.imul(Gi,Da)|0;var Wa=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Wa>>>26)|0,Wa&=67108863,Ai=Math.imul(Ra,wa),_i=Math.imul(Ra,ya),_i=_i+Math.imul(pa,wa)|0,Bi=Math.imul(pa,ya),Ai=Ai+Math.imul(xa,Sa)|0,_i=_i+Math.imul(xa,ga)|0,_i=_i+Math.imul(ha,Sa)|0,Bi=Bi+Math.imul(ha,ga)|0,Ai=Ai+Math.imul(ca,Ta)|0,_i=_i+Math.imul(ca,va)|0,_i=_i+Math.imul(la,Ta)|0,Bi=Bi+Math.imul(la,va)|0,Ai=Ai+Math.imul(sa,Aa)|0,_i=_i+Math.imul(sa,_a)|0,_i=_i+Math.imul(ua,Aa)|0,Bi=Bi+Math.imul(ua,_a)|0,Ai=Ai+Math.imul(oa,Na)|0,_i=_i+Math.imul(oa,Rn)|0,_i=_i+Math.imul(ta,Na)|0,Bi=Bi+Math.imul(ta,Rn)|0,Ai=Ai+Math.imul(ea,Yi)|0,_i=_i+Math.imul(ea,Mn)|0,_i=_i+Math.imul(ia,Yi)|0,Bi=Bi+Math.imul(ia,Mn)|0,Ai=Ai+Math.imul(jn,ra)|0,_i=_i+Math.imul(jn,na)|0,_i=_i+Math.imul(Ln,ra)|0,Bi=Bi+Math.imul(Ln,na)|0,Ai=Ai+Math.imul(Ji,ba)|0,_i=_i+Math.imul(Ji,fa)|0,_i=_i+Math.imul(Xi,ba)|0,Bi=Bi+Math.imul(Xi,fa)|0,Ai=Ai+Math.imul(Ki,ma)|0,_i=_i+Math.imul(Ki,Da)|0,_i=_i+Math.imul(Zi,ma)|0,Bi=Bi+Math.imul(Zi,Da)|0,Ai=Ai+Math.imul(zi,qa)|0,_i=_i+Math.imul(zi,Oa)|0,_i=_i+Math.imul(Gi,qa)|0,Bi=Bi+Math.imul(Gi,Oa)|0;var Ya=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Ya>>>26)|0,Ya&=67108863,Ai=Math.imul(Ra,Sa),_i=Math.imul(Ra,ga),_i=_i+Math.imul(pa,Sa)|0,Bi=Math.imul(pa,ga),Ai=Ai+Math.imul(xa,Ta)|0,_i=_i+Math.imul(xa,va)|0,_i=_i+Math.imul(ha,Ta)|0,Bi=Bi+Math.imul(ha,va)|0,Ai=Ai+Math.imul(ca,Aa)|0,_i=_i+Math.imul(ca,_a)|0,_i=_i+Math.imul(la,Aa)|0,Bi=Bi+Math.imul(la,_a)|0,Ai=Ai+Math.imul(sa,Na)|0,_i=_i+Math.imul(sa,Rn)|0,_i=_i+Math.imul(ua,Na)|0,Bi=Bi+Math.imul(ua,Rn)|0,Ai=Ai+Math.imul(oa,Yi)|0,_i=_i+Math.imul(oa,Mn)|0,_i=_i+Math.imul(ta,Yi)|0,Bi=Bi+Math.imul(ta,Mn)|0,Ai=Ai+Math.imul(ea,ra)|0,_i=_i+Math.imul(ea,na)|0,_i=_i+Math.imul(ia,ra)|0,Bi=Bi+Math.imul(ia,na)|0,Ai=Ai+Math.imul(jn,ba)|0,_i=_i+Math.imul(jn,fa)|0,_i=_i+Math.imul(Ln,ba)|0,Bi=Bi+Math.imul(Ln,fa)|0,Ai=Ai+Math.imul(Ji,ma)|0,_i=_i+Math.imul(Ji,Da)|0,_i=_i+Math.imul(Xi,ma)|0,Bi=Bi+Math.imul(Xi,Da)|0,Ai=Ai+Math.imul(Ki,qa)|0,_i=_i+Math.imul(Ki,Oa)|0,_i=_i+Math.imul(Zi,qa)|0,Bi=Bi+Math.imul(Zi,Oa)|0;var Xa=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Xa>>>26)|0,Xa&=67108863,Ai=Math.imul(Ra,Ta),_i=Math.imul(Ra,va),_i=_i+Math.imul(pa,Ta)|0,Bi=Math.imul(pa,va),Ai=Ai+Math.imul(xa,Aa)|0,_i=_i+Math.imul(xa,_a)|0,_i=_i+Math.imul(ha,Aa)|0,Bi=Bi+Math.imul(ha,_a)|0,Ai=Ai+Math.imul(ca,Na)|0,_i=_i+Math.imul(ca,Rn)|0,_i=_i+Math.imul(la,Na)|0,Bi=Bi+Math.imul(la,Rn)|0,Ai=Ai+Math.imul(sa,Yi)|0,_i=_i+Math.imul(sa,Mn)|0,_i=_i+Math.imul(ua,Yi)|0,Bi=Bi+Math.imul(ua,Mn)|0,Ai=Ai+Math.imul(oa,ra)|0,_i=_i+Math.imul(oa,na)|0,_i=_i+Math.imul(ta,ra)|0,Bi=Bi+Math.imul(ta,na)|0,Ai=Ai+Math.imul(ea,ba)|0,_i=_i+Math.imul(ea,fa)|0,_i=_i+Math.imul(ia,ba)|0,Bi=Bi+Math.imul(ia,fa)|0,Ai=Ai+Math.imul(jn,ma)|0,_i=_i+Math.imul(jn,Da)|0,_i=_i+Math.imul(Ln,ma)|0,Bi=Bi+Math.imul(Ln,Da)|0,Ai=Ai+Math.imul(Ji,qa)|0,_i=_i+Math.imul(Ji,Oa)|0,_i=_i+Math.imul(Xi,qa)|0,Bi=Bi+Math.imul(Xi,Oa)|0;var Ja=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Ja>>>26)|0,Ja&=67108863,Ai=Math.imul(Ra,Aa),_i=Math.imul(Ra,_a),_i=_i+Math.imul(pa,Aa)|0,Bi=Math.imul(pa,_a),Ai=Ai+Math.imul(xa,Na)|0,_i=_i+Math.imul(xa,Rn)|0,_i=_i+Math.imul(ha,Na)|0,Bi=Bi+Math.imul(ha,Rn)|0,Ai=Ai+Math.imul(ca,Yi)|0,_i=_i+Math.imul(ca,Mn)|0,_i=_i+Math.imul(la,Yi)|0,Bi=Bi+Math.imul(la,Mn)|0,Ai=Ai+Math.imul(sa,ra)|0,_i=_i+Math.imul(sa,na)|0,_i=_i+Math.imul(ua,ra)|0,Bi=Bi+Math.imul(ua,na)|0,Ai=Ai+Math.imul(oa,ba)|0,_i=_i+Math.imul(oa,fa)|0,_i=_i+Math.imul(ta,ba)|0,Bi=Bi+Math.imul(ta,fa)|0,Ai=Ai+Math.imul(ea,ma)|0,_i=_i+Math.imul(ea,Da)|0,_i=_i+Math.imul(ia,ma)|0,Bi=Bi+Math.imul(ia,Da)|0,Ai=Ai+Math.imul(jn,qa)|0,_i=_i+Math.imul(jn,Oa)|0,_i=_i+Math.imul(Ln,qa)|0,Bi=Bi+Math.imul(Ln,Oa)|0;var Za=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(Za>>>26)|0,Za&=67108863,Ai=Math.imul(Ra,Na),_i=Math.imul(Ra,Rn),_i=_i+Math.imul(pa,Na)|0,Bi=Math.imul(pa,Rn),Ai=Ai+Math.imul(xa,Yi)|0,_i=_i+Math.imul(xa,Mn)|0,_i=_i+Math.imul(ha,Yi)|0,Bi=Bi+Math.imul(ha,Mn)|0,Ai=Ai+Math.imul(ca,ra)|0,_i=_i+Math.imul(ca,na)|0,_i=_i+Math.imul(la,ra)|0,Bi=Bi+Math.imul(la,na)|0,Ai=Ai+Math.imul(sa,ba)|0,_i=_i+Math.imul(sa,fa)|0,_i=_i+Math.imul(ua,ba)|0,Bi=Bi+Math.imul(ua,fa)|0,Ai=Ai+Math.imul(oa,ma)|0,_i=_i+Math.imul(oa,Da)|0,_i=_i+Math.imul(ta,ma)|0,Bi=Bi+Math.imul(ta,Da)|0,Ai=Ai+Math.imul(ea,qa)|0,_i=_i+Math.imul(ea,Oa)|0,_i=_i+Math.imul(ia,qa)|0,Bi=Bi+Math.imul(ia,Oa)|0;var ao=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(ao>>>26)|0,ao&=67108863,Ai=Math.imul(Ra,Yi),_i=Math.imul(Ra,Mn),_i=_i+Math.imul(pa,Yi)|0,Bi=Math.imul(pa,Mn),Ai=Ai+Math.imul(xa,ra)|0,_i=_i+Math.imul(xa,na)|0,_i=_i+Math.imul(ha,ra)|0,Bi=Bi+Math.imul(ha,na)|0,Ai=Ai+Math.imul(ca,ba)|0,_i=_i+Math.imul(ca,fa)|0,_i=_i+Math.imul(la,ba)|0,Bi=Bi+Math.imul(la,fa)|0,Ai=Ai+Math.imul(sa,ma)|0,_i=_i+Math.imul(sa,Da)|0,_i=_i+Math.imul(ua,ma)|0,Bi=Bi+Math.imul(ua,Da)|0,Ai=Ai+Math.imul(oa,qa)|0,_i=_i+Math.imul(oa,Oa)|0,_i=_i+Math.imul(ta,qa)|0,Bi=Bi+Math.imul(ta,Oa)|0;var vo=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(vo>>>26)|0,vo&=67108863,Ai=Math.imul(Ra,ra),_i=Math.imul(Ra,na),_i=_i+Math.imul(pa,ra)|0,Bi=Math.imul(pa,na),Ai=Ai+Math.imul(xa,ba)|0,_i=_i+Math.imul(xa,fa)|0,_i=_i+Math.imul(ha,ba)|0,Bi=Bi+Math.imul(ha,fa)|0,Ai=Ai+Math.imul(ca,ma)|0,_i=_i+Math.imul(ca,Da)|0,_i=_i+Math.imul(la,ma)|0,Bi=Bi+Math.imul(la,Da)|0,Ai=Ai+Math.imul(sa,qa)|0,_i=_i+Math.imul(sa,Oa)|0,_i=_i+Math.imul(ua,qa)|0,Bi=Bi+Math.imul(ua,Oa)|0;var bo=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(bo>>>26)|0,bo&=67108863,Ai=Math.imul(Ra,ba),_i=Math.imul(Ra,fa),_i=_i+Math.imul(pa,ba)|0,Bi=Math.imul(pa,fa),Ai=Ai+Math.imul(xa,ma)|0,_i=_i+Math.imul(xa,Da)|0,_i=_i+Math.imul(ha,ma)|0,Bi=Bi+Math.imul(ha,Da)|0,Ai=Ai+Math.imul(ca,qa)|0,_i=_i+Math.imul(ca,Oa)|0,_i=_i+Math.imul(la,qa)|0,Bi=Bi+Math.imul(la,Oa)|0;var So=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(So>>>26)|0,So&=67108863,Ai=Math.imul(Ra,ma),_i=Math.imul(Ra,Da),_i=_i+Math.imul(pa,ma)|0,Bi=Math.imul(pa,Da),Ai=Ai+Math.imul(xa,qa)|0,_i=_i+Math.imul(xa,Oa)|0,_i=_i+Math.imul(ha,qa)|0,Bi=Bi+Math.imul(ha,Oa)|0;var To=(Si+Ai|0)+((_i&8191)<<13)|0;Si=(Bi+(_i>>>13)|0)+(To>>>26)|0,To&=67108863,Ai=Math.imul(Ra,qa),_i=Math.imul(Ra,Oa),_i=_i+Math.imul(pa,qa)|0,Bi=Math.imul(pa,Oa);var Co=(Si+Ai|0)+((_i&8191)<<13)|0;return Si=(Bi+(_i>>>13)|0)+(Co>>>26)|0,Co&=67108863,Mi[0]=Ua,Mi[1]=ja,Mi[2]=Va,Mi[3]=Ga,Mi[4]=Ka,Mi[5]=Ha,Mi[6]=Qa,Mi[7]=za,Mi[8]=Wa,Mi[9]=Ya,Mi[10]=Xa,Mi[11]=Ja,Mi[12]=Za,Mi[13]=ao,Mi[14]=vo,Mi[15]=bo,Mi[16]=So,Mi[17]=To,Mi[18]=Co,Si!==0&&(Mi[19]=Si,Ci.length++),Ci};Math.imul||(Ii=Ti);function qi(xi,yi,Ei){Ei.negative=yi.negative^xi.negative,Ei.length=xi.length+yi.length;for(var Ci=0,Ni=0,Fi=0;Fi<Ei.length-1;Fi++){var Mi=Ni;Ni=0;for(var Si=Ci&67108863,Ai=Math.min(Fi,yi.length-1),_i=Math.max(0,Fi-xi.length+1);_i<=Ai;_i++){var Bi=Fi-_i,Pi=xi.words[Bi]|0,zi=yi.words[_i]|0,Gi=Pi*zi,Vi=Gi&67108863;Mi=Mi+(Gi/67108864|0)|0,Vi=Vi+Si|0,Si=Vi&67108863,Mi=Mi+(Vi>>>26)|0,Ni+=Mi>>>26,Mi&=67108863}Ei.words[Fi]=Si,Ci=Mi,Mi=Ni}return Ci!==0?Ei.words[Fi]=Ci:Ei.length--,Ei._strip()}function Oi(xi,yi,Ei){return qi(xi,yi,Ei)}a.prototype.mulTo=function(yi,Ei){var Ci,Ni=this.length+yi.length;return this.length===10&&yi.length===10?Ci=Ii(this,yi,Ei):Ni<63?Ci=Ti(this,yi,Ei):Ni<1024?Ci=qi(this,yi,Ei):Ci=Oi(this,yi,Ei),Ci},a.prototype.mul=function(yi){var Ei=new a(null);return Ei.words=new Array(this.length+yi.length),this.mulTo(yi,Ei)},a.prototype.mulf=function(yi){var Ei=new a(null);return Ei.words=new Array(this.length+yi.length),Oi(this,yi,Ei)},a.prototype.imul=function(yi){return this.clone().mulTo(yi,this)},a.prototype.imuln=function(yi){var Ei=yi<0;Ei&&(yi=-yi),n(typeof yi=="number"),n(yi<67108864);for(var Ci=0,Ni=0;Ni<this.length;Ni++){var Fi=(this.words[Ni]|0)*yi,Mi=(Fi&67108863)+(Ci&67108863);Ci>>=26,Ci+=Fi/67108864|0,Ci+=Mi>>>26,this.words[Ni]=Mi&67108863}return Ci!==0&&(this.words[Ni]=Ci,this.length++),this.length=yi===0?1:this.length,Ei?this.ineg():this},a.prototype.muln=function(yi){return this.clone().imuln(yi)},a.prototype.sqr=function(){return this.mul(this)},a.prototype.isqr=function(){return this.imul(this.clone())},a.prototype.pow=function(yi){var Ei=Ri(yi);if(Ei.length===0)return new a(1);for(var Ci=this,Ni=0;Ni<Ei.length&&Ei[Ni]===0;Ni++,Ci=Ci.sqr());if(++Ni<Ei.length)for(var Fi=Ci.sqr();Ni<Ei.length;Ni++,Fi=Fi.sqr())Ei[Ni]!==0&&(Ci=Ci.mul(Fi));return Ci},a.prototype.iushln=function(yi){n(typeof yi=="number"&&yi>=0);var Ei=yi%26,Ci=(yi-Ei)/26,Ni=67108863>>>26-Ei<<26-Ei,Fi;if(Ei!==0){var Mi=0;for(Fi=0;Fi<this.length;Fi++){var Si=this.words[Fi]&Ni,Ai=(this.words[Fi]|0)-Si<<Ei;this.words[Fi]=Ai|Mi,Mi=Si>>>26-Ei}Mi&&(this.words[Fi]=Mi,this.length++)}if(Ci!==0){for(Fi=this.length-1;Fi>=0;Fi--)this.words[Fi+Ci]=this.words[Fi];for(Fi=0;Fi<Ci;Fi++)this.words[Fi]=0;this.length+=Ci}return this._strip()},a.prototype.ishln=function(yi){return n(this.negative===0),this.iushln(yi)},a.prototype.iushrn=function(yi,Ei,Ci){n(typeof yi=="number"&&yi>=0);var Ni;Ei?Ni=(Ei-Ei%26)/26:Ni=0;var Fi=yi%26,Mi=Math.min((yi-Fi)/26,this.length),Si=67108863^67108863>>>Fi<<Fi,Ai=Ci;if(Ni-=Mi,Ni=Math.max(0,Ni),Ai){for(var _i=0;_i<Mi;_i++)Ai.words[_i]=this.words[_i];Ai.length=Mi}if(Mi!==0)if(this.length>Mi)for(this.length-=Mi,_i=0;_i<this.length;_i++)this.words[_i]=this.words[_i+Mi];else this.words[0]=0,this.length=1;var Bi=0;for(_i=this.length-1;_i>=0&&(Bi!==0||_i>=Ni);_i--){var Pi=this.words[_i]|0;this.words[_i]=Bi<<26-Fi|Pi>>>Fi,Bi=Pi&Si}return Ai&&Bi!==0&&(Ai.words[Ai.length++]=Bi),this.length===0&&(this.words[0]=0,this.length=1),this._strip()},a.prototype.ishrn=function(yi,Ei,Ci){return n(this.negative===0),this.iushrn(yi,Ei,Ci)},a.prototype.shln=function(yi){return this.clone().ishln(yi)},a.prototype.ushln=function(yi){return this.clone().iushln(yi)},a.prototype.shrn=function(yi){return this.clone().ishrn(yi)},a.prototype.ushrn=function(yi){return this.clone().iushrn(yi)},a.prototype.testn=function(yi){n(typeof yi=="number"&&yi>=0);var Ei=yi%26,Ci=(yi-Ei)/26,Ni=1<<Ei;if(this.length<=Ci)return!1;var Fi=this.words[Ci];return!!(Fi&Ni)},a.prototype.imaskn=function(yi){n(typeof yi=="number"&&yi>=0);var Ei=yi%26,Ci=(yi-Ei)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=Ci)return this;if(Ei!==0&&Ci++,this.length=Math.min(Ci,this.length),Ei!==0){var Ni=67108863^67108863>>>Ei<<Ei;this.words[this.length-1]&=Ni}return this._strip()},a.prototype.maskn=function(yi){return this.clone().imaskn(yi)},a.prototype.iaddn=function(yi){return n(typeof yi=="number"),n(yi<67108864),yi<0?this.isubn(-yi):this.negative!==0?this.length===1&&(this.words[0]|0)<=yi?(this.words[0]=yi-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(yi),this.negative=1,this):this._iaddn(yi)},a.prototype._iaddn=function(yi){this.words[0]+=yi;for(var Ei=0;Ei<this.length&&this.words[Ei]>=67108864;Ei++)this.words[Ei]-=67108864,Ei===this.length-1?this.words[Ei+1]=1:this.words[Ei+1]++;return this.length=Math.max(this.length,Ei+1),this},a.prototype.isubn=function(yi){if(n(typeof yi=="number"),n(yi<67108864),yi<0)return this.iaddn(-yi);if(this.negative!==0)return this.negative=0,this.iaddn(yi),this.negative=1,this;if(this.words[0]-=yi,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var Ei=0;Ei<this.length&&this.words[Ei]<0;Ei++)this.words[Ei]+=67108864,this.words[Ei+1]-=1;return this._strip()},a.prototype.addn=function(yi){return this.clone().iaddn(yi)},a.prototype.subn=function(yi){return this.clone().isubn(yi)},a.prototype.iabs=function(){return this.negative=0,this},a.prototype.abs=function(){return this.clone().iabs()},a.prototype._ishlnsubmul=function(yi,Ei,Ci){var Ni=yi.length+Ci,Fi;this._expand(Ni);var Mi,Si=0;for(Fi=0;Fi<yi.length;Fi++){Mi=(this.words[Fi+Ci]|0)+Si;var Ai=(yi.words[Fi]|0)*Ei;Mi-=Ai&67108863,Si=(Mi>>26)-(Ai/67108864|0),this.words[Fi+Ci]=Mi&67108863}for(;Fi<this.length-Ci;Fi++)Mi=(this.words[Fi+Ci]|0)+Si,Si=Mi>>26,this.words[Fi+Ci]=Mi&67108863;if(Si===0)return this._strip();for(n(Si===-1),Si=0,Fi=0;Fi<this.length;Fi++)Mi=-(this.words[Fi]|0)+Si,Si=Mi>>26,this.words[Fi]=Mi&67108863;return this.negative=1,this._strip()},a.prototype._wordDiv=function(yi,Ei){var Ci=this.length-yi.length,Ni=this.clone(),Fi=yi,Mi=Fi.words[Fi.length-1]|0,Si=this._countBits(Mi);Ci=26-Si,Ci!==0&&(Fi=Fi.ushln(Ci),Ni.iushln(Ci),Mi=Fi.words[Fi.length-1]|0);var Ai=Ni.length-Fi.length,_i;if(Ei!=="mod"){_i=new a(null),_i.length=Ai+1,_i.words=new Array(_i.length);for(var Bi=0;Bi<_i.length;Bi++)_i.words[Bi]=0}var Pi=Ni.clone()._ishlnsubmul(Fi,1,Ai);Pi.negative===0&&(Ni=Pi,_i&&(_i.words[Ai]=1));for(var zi=Ai-1;zi>=0;zi--){var Gi=(Ni.words[Fi.length+zi]|0)*67108864+(Ni.words[Fi.length+zi-1]|0);for(Gi=Math.min(Gi/Mi|0,67108863),Ni._ishlnsubmul(Fi,Gi,zi);Ni.negative!==0;)Gi--,Ni.negative=0,Ni._ishlnsubmul(Fi,1,zi),Ni.isZero()||(Ni.negative^=1);_i&&(_i.words[zi]=Gi)}return _i&&_i._strip(),Ni._strip(),Ei!=="div"&&Ci!==0&&Ni.iushrn(Ci),{div:_i||null,mod:Ni}},a.prototype.divmod=function(yi,Ei,Ci){if(n(!yi.isZero()),this.isZero())return{div:new a(0),mod:new a(0)};var Ni,Fi,Mi;return this.negative!==0&&yi.negative===0?(Mi=this.neg().divmod(yi,Ei),Ei!=="mod"&&(Ni=Mi.div.neg()),Ei!=="div"&&(Fi=Mi.mod.neg(),Ci&&Fi.negative!==0&&Fi.iadd(yi)),{div:Ni,mod:Fi}):this.negative===0&&yi.negative!==0?(Mi=this.divmod(yi.neg(),Ei),Ei!=="mod"&&(Ni=Mi.div.neg()),{div:Ni,mod:Mi.mod}):(this.negative&yi.negative)!==0?(Mi=this.neg().divmod(yi.neg(),Ei),Ei!=="div"&&(Fi=Mi.mod.neg(),Ci&&Fi.negative!==0&&Fi.isub(yi)),{div:Mi.div,mod:Fi}):yi.length>this.length||this.cmp(yi)<0?{div:new a(0),mod:this}:yi.length===1?Ei==="div"?{div:this.divn(yi.words[0]),mod:null}:Ei==="mod"?{div:null,mod:new a(this.modrn(yi.words[0]))}:{div:this.divn(yi.words[0]),mod:new a(this.modrn(yi.words[0]))}:this._wordDiv(yi,Ei)},a.prototype.div=function(yi){return this.divmod(yi,"div",!1).div},a.prototype.mod=function(yi){return this.divmod(yi,"mod",!1).mod},a.prototype.umod=function(yi){return this.divmod(yi,"mod",!0).mod},a.prototype.divRound=function(yi){var Ei=this.divmod(yi);if(Ei.mod.isZero())return Ei.div;var Ci=Ei.div.negative!==0?Ei.mod.isub(yi):Ei.mod,Ni=yi.ushrn(1),Fi=yi.andln(1),Mi=Ci.cmp(Ni);return Mi<0||Fi===1&&Mi===0?Ei.div:Ei.div.negative!==0?Ei.div.isubn(1):Ei.div.iaddn(1)},a.prototype.modrn=function(yi){var Ei=yi<0;Ei&&(yi=-yi),n(yi<=67108863);for(var Ci=(1<<26)%yi,Ni=0,Fi=this.length-1;Fi>=0;Fi--)Ni=(Ci*Ni+(this.words[Fi]|0))%yi;return Ei?-Ni:Ni},a.prototype.modn=function(yi){return this.modrn(yi)},a.prototype.idivn=function(yi){var Ei=yi<0;Ei&&(yi=-yi),n(yi<=67108863);for(var Ci=0,Ni=this.length-1;Ni>=0;Ni--){var Fi=(this.words[Ni]|0)+Ci*67108864;this.words[Ni]=Fi/yi|0,Ci=Fi%yi}return this._strip(),Ei?this.ineg():this},a.prototype.divn=function(yi){return this.clone().idivn(yi)},a.prototype.egcd=function(yi){n(yi.negative===0),n(!yi.isZero());var Ei=this,Ci=yi.clone();Ei.negative!==0?Ei=Ei.umod(yi):Ei=Ei.clone();for(var Ni=new a(1),Fi=new a(0),Mi=new a(0),Si=new a(1),Ai=0;Ei.isEven()&&Ci.isEven();)Ei.iushrn(1),Ci.iushrn(1),++Ai;for(var _i=Ci.clone(),Bi=Ei.clone();!Ei.isZero();){for(var Pi=0,zi=1;(Ei.words[0]&zi)===0&&Pi<26;++Pi,zi<<=1);if(Pi>0)for(Ei.iushrn(Pi);Pi-- >0;)(Ni.isOdd()||Fi.isOdd())&&(Ni.iadd(_i),Fi.isub(Bi)),Ni.iushrn(1),Fi.iushrn(1);for(var Gi=0,Vi=1;(Ci.words[0]&Vi)===0&&Gi<26;++Gi,Vi<<=1);if(Gi>0)for(Ci.iushrn(Gi);Gi-- >0;)(Mi.isOdd()||Si.isOdd())&&(Mi.iadd(_i),Si.isub(Bi)),Mi.iushrn(1),Si.iushrn(1);Ei.cmp(Ci)>=0?(Ei.isub(Ci),Ni.isub(Mi),Fi.isub(Si)):(Ci.isub(Ei),Mi.isub(Ni),Si.isub(Fi))}return{a:Mi,b:Si,gcd:Ci.iushln(Ai)}},a.prototype._invmp=function(yi){n(yi.negative===0),n(!yi.isZero());var Ei=this,Ci=yi.clone();Ei.negative!==0?Ei=Ei.umod(yi):Ei=Ei.clone();for(var Ni=new a(1),Fi=new a(0),Mi=Ci.clone();Ei.cmpn(1)>0&&Ci.cmpn(1)>0;){for(var Si=0,Ai=1;(Ei.words[0]&Ai)===0&&Si<26;++Si,Ai<<=1);if(Si>0)for(Ei.iushrn(Si);Si-- >0;)Ni.isOdd()&&Ni.iadd(Mi),Ni.iushrn(1);for(var _i=0,Bi=1;(Ci.words[0]&Bi)===0&&_i<26;++_i,Bi<<=1);if(_i>0)for(Ci.iushrn(_i);_i-- >0;)Fi.isOdd()&&Fi.iadd(Mi),Fi.iushrn(1);Ei.cmp(Ci)>=0?(Ei.isub(Ci),Ni.isub(Fi)):(Ci.isub(Ei),Fi.isub(Ni))}var Pi;return Ei.cmpn(1)===0?Pi=Ni:Pi=Fi,Pi.cmpn(0)<0&&Pi.iadd(yi),Pi},a.prototype.gcd=function(yi){if(this.isZero())return yi.abs();if(yi.isZero())return this.abs();var Ei=this.clone(),Ci=yi.clone();Ei.negative=0,Ci.negative=0;for(var Ni=0;Ei.isEven()&&Ci.isEven();Ni++)Ei.iushrn(1),Ci.iushrn(1);do{for(;Ei.isEven();)Ei.iushrn(1);for(;Ci.isEven();)Ci.iushrn(1);var Fi=Ei.cmp(Ci);if(Fi<0){var Mi=Ei;Ei=Ci,Ci=Mi}else if(Fi===0||Ci.cmpn(1)===0)break;Ei.isub(Ci)}while(!0);return Ci.iushln(Ni)},a.prototype.invm=function(yi){return this.egcd(yi).a.umod(yi)},a.prototype.isEven=function(){return(this.words[0]&1)===0},a.prototype.isOdd=function(){return(this.words[0]&1)===1},a.prototype.andln=function(yi){return this.words[0]&yi},a.prototype.bincn=function(yi){n(typeof yi=="number");var Ei=yi%26,Ci=(yi-Ei)/26,Ni=1<<Ei;if(this.length<=Ci)return this._expand(Ci+1),this.words[Ci]|=Ni,this;for(var Fi=Ni,Mi=Ci;Fi!==0&&Mi<this.length;Mi++){var Si=this.words[Mi]|0;Si+=Fi,Fi=Si>>>26,Si&=67108863,this.words[Mi]=Si}return Fi!==0&&(this.words[Mi]=Fi,this.length++),this},a.prototype.isZero=function(){return this.length===1&&this.words[0]===0},a.prototype.cmpn=function(yi){var Ei=yi<0;if(this.negative!==0&&!Ei)return-1;if(this.negative===0&&Ei)return 1;this._strip();var Ci;if(this.length>1)Ci=1;else{Ei&&(yi=-yi),n(yi<=67108863,"Number is too big");var Ni=this.words[0]|0;Ci=Ni===yi?0:Ni<yi?-1:1}return this.negative!==0?-Ci|0:Ci},a.prototype.cmp=function(yi){if(this.negative!==0&&yi.negative===0)return-1;if(this.negative===0&&yi.negative!==0)return 1;var Ei=this.ucmp(yi);return this.negative!==0?-Ei|0:Ei},a.prototype.ucmp=function(yi){if(this.length>yi.length)return 1;if(this.length<yi.length)return-1;for(var Ei=0,Ci=this.length-1;Ci>=0;Ci--){var Ni=this.words[Ci]|0,Fi=yi.words[Ci]|0;if(Ni!==Fi){Ni<Fi?Ei=-1:Ni>Fi&&(Ei=1);break}}return Ei},a.prototype.gtn=function(yi){return this.cmpn(yi)===1},a.prototype.gt=function(yi){return this.cmp(yi)===1},a.prototype.gten=function(yi){return this.cmpn(yi)>=0},a.prototype.gte=function(yi){return this.cmp(yi)>=0},a.prototype.ltn=function(yi){return this.cmpn(yi)===-1},a.prototype.lt=function(yi){return this.cmp(yi)===-1},a.prototype.lten=function(yi){return this.cmpn(yi)<=0},a.prototype.lte=function(yi){return this.cmp(yi)<=0},a.prototype.eqn=function(yi){return this.cmpn(yi)===0},a.prototype.eq=function(yi){return this.cmp(yi)===0},a.red=function(yi){return new $i(yi)},a.prototype.toRed=function(yi){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),yi.convertTo(this)._forceRed(yi)},a.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},a.prototype._forceRed=function(yi){return this.red=yi,this},a.prototype.forceRed=function(yi){return n(!this.red,"Already a number in reduction context"),this._forceRed(yi)},a.prototype.redAdd=function(yi){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,yi)},a.prototype.redIAdd=function(yi){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,yi)},a.prototype.redSub=function(yi){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,yi)},a.prototype.redISub=function(yi){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,yi)},a.prototype.redShl=function(yi){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,yi)},a.prototype.redMul=function(yi){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,yi),this.red.mul(this,yi)},a.prototype.redIMul=function(yi){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,yi),this.red.imul(this,yi)},a.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},a.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},a.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},a.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},a.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},a.prototype.redPow=function(yi){return n(this.red&&!yi.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,yi)};var ki={k256:null,p224:null,p192:null,p25519:null};function Li(xi,yi){this.name=xi,this.p=new a(yi,16),this.n=this.p.bitLength(),this.k=new a(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}Li.prototype._tmp=function(){var yi=new a(null);return yi.words=new Array(Math.ceil(this.n/13)),yi},Li.prototype.ireduce=function(yi){var Ei=yi,Ci;do this.split(Ei,this.tmp),Ei=this.imulK(Ei),Ei=Ei.iadd(this.tmp),Ci=Ei.bitLength();while(Ci>this.n);var Ni=Ci<this.n?-1:Ei.ucmp(this.p);return Ni===0?(Ei.words[0]=0,Ei.length=1):Ni>0?Ei.isub(this.p):Ei.strip!==void 0?Ei.strip():Ei._strip(),Ei},Li.prototype.split=function(yi,Ei){yi.iushrn(this.n,0,Ei)},Li.prototype.imulK=function(yi){return yi.imul(this.k)};function ji(){Li.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}s(ji,Li),ji.prototype.split=function(yi,Ei){for(var Ci=4194303,Ni=Math.min(yi.length,9),Fi=0;Fi<Ni;Fi++)Ei.words[Fi]=yi.words[Fi];if(Ei.length=Ni,yi.length<=9){yi.words[0]=0,yi.length=1;return}var Mi=yi.words[9];for(Ei.words[Ei.length++]=Mi&Ci,Fi=10;Fi<yi.length;Fi++){var Si=yi.words[Fi]|0;yi.words[Fi-10]=(Si&Ci)<<4|Mi>>>22,Mi=Si}Mi>>>=22,yi.words[Fi-10]=Mi,Mi===0&&yi.length>10?yi.length-=10:yi.length-=9},ji.prototype.imulK=function(yi){yi.words[yi.length]=0,yi.words[yi.length+1]=0,yi.length+=2;for(var Ei=0,Ci=0;Ci<yi.length;Ci++){var Ni=yi.words[Ci]|0;Ei+=Ni*977,yi.words[Ci]=Ei&67108863,Ei=Ni*64+(Ei/67108864|0)}return yi.words[yi.length-1]===0&&(yi.length--,yi.words[yi.length-1]===0&&yi.length--),yi};function Hi(){Li.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}s(Hi,Li);function Ui(){Li.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}s(Ui,Li);function Qi(){Li.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}s(Qi,Li),Qi.prototype.imulK=function(yi){for(var Ei=0,Ci=0;Ci<yi.length;Ci++){var Ni=(yi.words[Ci]|0)*19+Ei,Fi=Ni&67108863;Ni>>>=26,yi.words[Ci]=Fi,Ei=Ni}return Ei!==0&&(yi.words[yi.length++]=Ei),yi},a._prime=function(yi){if(ki[yi])return ki[yi];var Ei;if(yi==="k256")Ei=new ji;else if(yi==="p224")Ei=new Hi;else if(yi==="p192")Ei=new Ui;else if(yi==="p25519")Ei=new Qi;else throw new Error("Unknown prime "+yi);return ki[yi]=Ei,Ei};function $i(xi){if(typeof xi=="string"){var yi=a._prime(xi);this.m=yi.p,this.prime=yi}else n(xi.gtn(1),"modulus must be greater than 1"),this.m=xi,this.prime=null}$i.prototype._verify1=function(yi){n(yi.negative===0,"red works only with positives"),n(yi.red,"red works only with red numbers")},$i.prototype._verify2=function(yi,Ei){n((yi.negative|Ei.negative)===0,"red works only with positives"),n(yi.red&&yi.red===Ei.red,"red works only with red numbers")},$i.prototype.imod=function(yi){return this.prime?this.prime.ireduce(yi)._forceRed(this):(l(yi,yi.umod(this.m)._forceRed(this)),yi)},$i.prototype.neg=function(yi){return yi.isZero()?yi.clone():this.m.sub(yi)._forceRed(this)},$i.prototype.add=function(yi,Ei){this._verify2(yi,Ei);var Ci=yi.add(Ei);return Ci.cmp(this.m)>=0&&Ci.isub(this.m),Ci._forceRed(this)},$i.prototype.iadd=function(yi,Ei){this._verify2(yi,Ei);var Ci=yi.iadd(Ei);return Ci.cmp(this.m)>=0&&Ci.isub(this.m),Ci},$i.prototype.sub=function(yi,Ei){this._verify2(yi,Ei);var Ci=yi.sub(Ei);return Ci.cmpn(0)<0&&Ci.iadd(this.m),Ci._forceRed(this)},$i.prototype.isub=function(yi,Ei){this._verify2(yi,Ei);var Ci=yi.isub(Ei);return Ci.cmpn(0)<0&&Ci.iadd(this.m),Ci},$i.prototype.shl=function(yi,Ei){return this._verify1(yi),this.imod(yi.ushln(Ei))},$i.prototype.imul=function(yi,Ei){return this._verify2(yi,Ei),this.imod(yi.imul(Ei))},$i.prototype.mul=function(yi,Ei){return this._verify2(yi,Ei),this.imod(yi.mul(Ei))},$i.prototype.isqr=function(yi){return this.imul(yi,yi.clone())},$i.prototype.sqr=function(yi){return this.mul(yi,yi)},$i.prototype.sqrt=function(yi){if(yi.isZero())return yi.clone();var Ei=this.m.andln(3);if(n(Ei%2===1),Ei===3){var Ci=this.m.add(new a(1)).iushrn(2);return this.pow(yi,Ci)}for(var Ni=this.m.subn(1),Fi=0;!Ni.isZero()&&Ni.andln(1)===0;)Fi++,Ni.iushrn(1);n(!Ni.isZero());var Mi=new a(1).toRed(this),Si=Mi.redNeg(),Ai=this.m.subn(1).iushrn(1),_i=this.m.bitLength();for(_i=new a(2*_i*_i).toRed(this);this.pow(_i,Ai).cmp(Si)!==0;)_i.redIAdd(Si);for(var Bi=this.pow(_i,Ni),Pi=this.pow(yi,Ni.addn(1).iushrn(1)),zi=this.pow(yi,Ni),Gi=Fi;zi.cmp(Mi)!==0;){for(var Vi=zi,Ki=0;Vi.cmp(Mi)!==0;Ki++)Vi=Vi.redSqr();n(Ki<Gi);var Zi=this.pow(Bi,new a(1).iushln(Gi-Ki-1));Pi=Pi.redMul(Zi),Bi=Zi.redSqr(),zi=zi.redMul(Bi),Gi=Ki}return Pi},$i.prototype.invm=function(yi){var Ei=yi._invmp(this.m);return Ei.negative!==0?(Ei.negative=0,this.imod(Ei).redNeg()):this.imod(Ei)},$i.prototype.pow=function(yi,Ei){if(Ei.isZero())return new a(1).toRed(this);if(Ei.cmpn(1)===0)return yi.clone();var Ci=4,Ni=new Array(1<<Ci);Ni[0]=new a(1).toRed(this),Ni[1]=yi;for(var Fi=2;Fi<Ni.length;Fi++)Ni[Fi]=this.mul(Ni[Fi-1],yi);var Mi=Ni[0],Si=0,Ai=0,_i=Ei.bitLength()%26;for(_i===0&&(_i=26),Fi=Ei.length-1;Fi>=0;Fi--){for(var Bi=Ei.words[Fi],Pi=_i-1;Pi>=0;Pi--){var zi=Bi>>Pi&1;if(Mi!==Ni[0]&&(Mi=this.sqr(Mi)),zi===0&&Si===0){Ai=0;continue}Si<<=1,Si|=zi,Ai++,!(Ai!==Ci&&(Fi!==0||Pi!==0))&&(Mi=this.mul(Mi,Ni[Si]),Ai=0,Si=0)}_i=26}return Mi},$i.prototype.convertTo=function(yi){var Ei=yi.umod(this.m);return Ei===yi?Ei.clone():Ei},$i.prototype.convertFrom=function(yi){var Ei=yi.clone();return Ei.red=null,Ei},a.mont=function(yi){return new wi(yi)};function wi(xi){$i.call(this,xi),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new a(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}s(wi,$i),wi.prototype.convertTo=function(yi){return this.imod(yi.ushln(this.shift))},wi.prototype.convertFrom=function(yi){var Ei=this.imod(yi.mul(this.rinv));return Ei.red=null,Ei},wi.prototype.imul=function(yi,Ei){if(yi.isZero()||Ei.isZero())return yi.words[0]=0,yi.length=1,yi;var Ci=yi.imul(Ei),Ni=Ci.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Fi=Ci.isub(Ni).iushrn(this.shift),Mi=Fi;return Fi.cmp(this.m)>=0?Mi=Fi.isub(this.m):Fi.cmpn(0)<0&&(Mi=Fi.iadd(this.m)),Mi._forceRed(this)},wi.prototype.mul=function(yi,Ei){if(yi.isZero()||Ei.isZero())return new a(0)._forceRed(this);var Ci=yi.mul(Ei),Ni=Ci.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Fi=Ci.isub(Ni).iushrn(this.shift),Mi=Fi;return Fi.cmp(this.m)>=0?Mi=Fi.isub(this.m):Fi.cmpn(0)<0&&(Mi=Fi.iadd(this.m)),Mi._forceRed(this)},wi.prototype.invm=function(yi){var Ei=this.imod(yi._invmp(this.m).mul(this.r2));return Ei._forceRed(this)}})(r,bn)}(bn$1)),bn$1.exports}var asn1$1={},asn1={},api$1={},vmBrowserify={},hasRequiredVmBrowserify;function requireVmBrowserify(){return hasRequiredVmBrowserify||(hasRequiredVmBrowserify=1,function(exports){var indexOf=function(r,t){if(r.indexOf)return r.indexOf(t);for(var i=0;i<r.length;i++)if(r[i]===t)return i;return-1},Object_keys=function(r){if(Object.keys)return Object.keys(r);var t=[];for(var i in r)t.push(i);return t},forEach=function(r,t){if(r.forEach)return r.forEach(t);for(var i=0;i<r.length;i++)t(r[i],i,r)},defineProp=function(){try{return Object.defineProperty({},"_",{}),function(r,t,i){Object.defineProperty(r,t,{writable:!0,enumerable:!1,configurable:!0,value:i})}}catch{return function(t,i,n){t[i]=n}}}(),globals=["Array","Boolean","Date","Error","EvalError","Function","Infinity","JSON","Math","NaN","Number","Object","RangeError","ReferenceError","RegExp","String","SyntaxError","TypeError","URIError","decodeURI","decodeURIComponent","encodeURI","encodeURIComponent","escape","eval","isFinite","isNaN","parseFloat","parseInt","undefined","unescape"];function Context(){}Context.prototype={};var Script=exports.Script=function(t){if(!(this instanceof Script))return new Script(t);this.code=t};Script.prototype.runInContext=function(r){if(!(r instanceof Context))throw new TypeError("needs a 'context' argument.");var t=document.createElement("iframe");t.style||(t.style={}),t.style.display="none",document.body.appendChild(t);var i=t.contentWindow,n=i.eval,s=i.execScript;!n&&s&&(s.call(i,"null"),n=i.eval),forEach(Object_keys(r),function(v){i[v]=r[v]}),forEach(globals,function(v){r[v]&&(i[v]=r[v])});var a=Object_keys(i),h=n.call(i,this.code);return forEach(Object_keys(i),function(v){(v in r||indexOf(a,v)===-1)&&(r[v]=i[v])}),forEach(globals,function(v){v in r||defineProp(r,v,i[v])}),document.body.removeChild(t),h},Script.prototype.runInThisContext=function(){return eval(this.code)},Script.prototype.runInNewContext=function(r){var t=Script.createContext(r),i=this.runInContext(t);return r&&forEach(Object_keys(t),function(n){r[n]=t[n]}),i},forEach(Object_keys(Script.prototype),function(r){exports[r]=Script[r]=function(t){var i=Script(t);return i[r].apply(i,[].slice.call(arguments,1))}}),exports.isContext=function(r){return r instanceof Context},exports.createScript=function(r){return exports.Script(r)},exports.createContext=Script.createContext=function(r){var t=new Context;return typeof r=="object"&&forEach(Object_keys(r),function(i){t[i]=r[i]}),t}}(vmBrowserify)),vmBrowserify}var hasRequiredApi$1;function requireApi$1(){return hasRequiredApi$1||(hasRequiredApi$1=1,function(r){var t=requireAsn1$1(),i=requireInherits_browser(),n=r;n.define=function(h,v){return new s(h,v)};function s(a,h){this.name=a,this.body=h,this.decoders={},this.encoders={}}s.prototype._createNamed=function(h){var v;try{v=requireVmBrowserify().runInThisContext("(function "+this.name+`(entity) {
99
+ this._initNamed(entity);
100
+ })`)}catch{v=function(u){this._initNamed(u)}}return i(v,h),v.prototype._initNamed=function(u){h.call(this,u)},new v(this)},s.prototype._getDecoder=function(h){return h=h||"der",this.decoders.hasOwnProperty(h)||(this.decoders[h]=this._createNamed(t.decoders[h])),this.decoders[h]},s.prototype.decode=function(h,v,hi){return this._getDecoder(v).decode(h,hi)},s.prototype._getEncoder=function(h){return h=h||"der",this.encoders.hasOwnProperty(h)||(this.encoders[h]=this._createNamed(t.encoders[h])),this.encoders[h]},s.prototype.encode=function(h,v,hi){return this._getEncoder(v).encode(h,hi)}}(api$1)),api$1}var base={},reporter={},hasRequiredReporter;function requireReporter(){if(hasRequiredReporter)return reporter;hasRequiredReporter=1;var r=requireInherits_browser();function t(n){this._reporterState={obj:null,path:[],options:n||{},errors:[]}}reporter.Reporter=t,t.prototype.isError=function(s){return s instanceof i},t.prototype.save=function(){var s=this._reporterState;return{obj:s.obj,pathLen:s.path.length}},t.prototype.restore=function(s){var a=this._reporterState;a.obj=s.obj,a.path=a.path.slice(0,s.pathLen)},t.prototype.enterKey=function(s){return this._reporterState.path.push(s)},t.prototype.exitKey=function(s){var a=this._reporterState;a.path=a.path.slice(0,s-1)},t.prototype.leaveKey=function(s,a,h){var v=this._reporterState;this.exitKey(s),v.obj!==null&&(v.obj[a]=h)},t.prototype.path=function(){return this._reporterState.path.join("/")},t.prototype.enterObject=function(){var s=this._reporterState,a=s.obj;return s.obj={},a},t.prototype.leaveObject=function(s){var a=this._reporterState,h=a.obj;return a.obj=s,h},t.prototype.error=function(s){var a,h=this._reporterState,v=s instanceof i;if(v?a=s:a=new i(h.path.map(function(hi){return"["+JSON.stringify(hi)+"]"}).join(""),s.message||s,s.stack),!h.options.partial)throw a;return v||h.errors.push(a),a},t.prototype.wrapResult=function(s){var a=this._reporterState;return a.options.partial?{result:this.isError(s)?null:s,errors:a.errors}:s};function i(n,s){this.path=n,this.rethrow(s)}return r(i,Error),i.prototype.rethrow=function(s){if(this.message=s+" at: "+(this.path||"(shallow)"),Error.captureStackTrace&&Error.captureStackTrace(this,i),!this.stack)try{throw new Error(this.message)}catch(a){this.stack=a.stack}return this},reporter}var buffer={},hasRequiredBuffer;function requireBuffer(){if(hasRequiredBuffer)return buffer;hasRequiredBuffer=1;var r=requireInherits_browser(),t=requireBase().Reporter,i=requireDist().Buffer;function n(a,h){if(t.call(this,h),!i.isBuffer(a)){this.error("Input not Buffer");return}this.base=a,this.offset=0,this.length=a.length}r(n,t),buffer.DecoderBuffer=n,n.prototype.save=function(){return{offset:this.offset,reporter:t.prototype.save.call(this)}},n.prototype.restore=function(h){var v=new n(this.base);return v.offset=h.offset,v.length=this.offset,this.offset=h.offset,t.prototype.restore.call(this,h.reporter),v},n.prototype.isEmpty=function(){return this.offset===this.length},n.prototype.readUInt8=function(h){return this.offset+1<=this.length?this.base.readUInt8(this.offset++,!0):this.error(h||"DecoderBuffer overrun")},n.prototype.skip=function(h,v){if(!(this.offset+h<=this.length))return this.error(v||"DecoderBuffer overrun");var hi=new n(this.base);return hi._reporterState=this._reporterState,hi.offset=this.offset,hi.length=this.offset+h,this.offset+=h,hi},n.prototype.raw=function(h){return this.base.slice(h?h.offset:this.offset,this.length)};function s(a,h){if(Array.isArray(a))this.length=0,this.value=a.map(function(v){return v instanceof s||(v=new s(v,h)),this.length+=v.length,v},this);else if(typeof a=="number"){if(!(0<=a&&a<=255))return h.error("non-byte EncoderBuffer value");this.value=a,this.length=1}else if(typeof a=="string")this.value=a,this.length=i.byteLength(a);else if(i.isBuffer(a))this.value=a,this.length=a.length;else return h.error("Unsupported type: "+typeof a)}return buffer.EncoderBuffer=s,s.prototype.join=function(h,v){return h||(h=new i(this.length)),v||(v=0),this.length===0||(Array.isArray(this.value)?this.value.forEach(function(hi){hi.join(h,v),v+=hi.length}):(typeof this.value=="number"?h[v]=this.value:typeof this.value=="string"?h.write(this.value,v):i.isBuffer(this.value)&&this.value.copy(h,v),v+=this.length)),h},buffer}var node,hasRequiredNode;function requireNode(){if(hasRequiredNode)return node;hasRequiredNode=1;var r=requireBase().Reporter,t=requireBase().EncoderBuffer,i=requireBase().DecoderBuffer,n=requireMinimalisticAssert(),s=["seq","seqof","set","setof","objid","bool","gentime","utctime","null_","enum","int","objDesc","bitstr","bmpstr","charstr","genstr","graphstr","ia5str","iso646str","numstr","octstr","printstr","t61str","unistr","utf8str","videostr"],a=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(s),h=["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"];function v(u,l){var vi={};this._baseState=vi,vi.enc=u,vi.parent=l||null,vi.children=null,vi.tag=null,vi.args=null,vi.reverseArgs=null,vi.choice=null,vi.optional=!1,vi.any=!1,vi.obj=!1,vi.use=null,vi.useDecoder=null,vi.key=null,vi.default=null,vi.explicit=null,vi.implicit=null,vi.contains=null,vi.parent||(vi.children=[],this._wrap())}node=v;var hi=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];return v.prototype.clone=function(){var l=this._baseState,vi={};hi.forEach(function(mi){vi[mi]=l[mi]});var D=new this.constructor(vi.parent);return D._baseState=vi,D},v.prototype._wrap=function(){var l=this._baseState;a.forEach(function(vi){this[vi]=function(){var mi=new this.constructor(this);return l.children.push(mi),mi[vi].apply(mi,arguments)}},this)},v.prototype._init=function(l){var vi=this._baseState;n(vi.parent===null),l.call(this),vi.children=vi.children.filter(function(D){return D._baseState.parent===this},this),n.equal(vi.children.length,1,"Root node can have only one child")},v.prototype._useArgs=function(l){var vi=this._baseState,D=l.filter(function(mi){return mi instanceof this.constructor},this);l=l.filter(function(mi){return!(mi instanceof this.constructor)},this),D.length!==0&&(n(vi.children===null),vi.children=D,D.forEach(function(mi){mi._baseState.parent=this},this)),l.length!==0&&(n(vi.args===null),vi.args=l,vi.reverseArgs=l.map(function(mi){if(typeof mi!="object"||mi.constructor!==Object)return mi;var gi={};return Object.keys(mi).forEach(function(bi){bi==(bi|0)&&(bi|=0);var Ri=mi[bi];gi[Ri]=bi}),gi}))},h.forEach(function(u){v.prototype[u]=function(){var vi=this._baseState;throw new Error(u+" not implemented for encoding: "+vi.enc)}}),s.forEach(function(u){v.prototype[u]=function(){var vi=this._baseState,D=Array.prototype.slice.call(arguments);return n(vi.tag===null),vi.tag=u,this._useArgs(D),this}}),v.prototype.use=function(l){n(l);var vi=this._baseState;return n(vi.use===null),vi.use=l,this},v.prototype.optional=function(){var l=this._baseState;return l.optional=!0,this},v.prototype.def=function(l){var vi=this._baseState;return n(vi.default===null),vi.default=l,vi.optional=!0,this},v.prototype.explicit=function(l){var vi=this._baseState;return n(vi.explicit===null&&vi.implicit===null),vi.explicit=l,this},v.prototype.implicit=function(l){var vi=this._baseState;return n(vi.explicit===null&&vi.implicit===null),vi.implicit=l,this},v.prototype.obj=function(){var l=this._baseState,vi=Array.prototype.slice.call(arguments);return l.obj=!0,vi.length!==0&&this._useArgs(vi),this},v.prototype.key=function(l){var vi=this._baseState;return n(vi.key===null),vi.key=l,this},v.prototype.any=function(){var l=this._baseState;return l.any=!0,this},v.prototype.choice=function(l){var vi=this._baseState;return n(vi.choice===null),vi.choice=l,this._useArgs(Object.keys(l).map(function(D){return l[D]})),this},v.prototype.contains=function(l){var vi=this._baseState;return n(vi.use===null),vi.contains=l,this},v.prototype._decode=function(l,vi){var D=this._baseState;if(D.parent===null)return l.wrapResult(D.children[0]._decode(l,vi));var mi=D.default,gi=!0,bi=null;if(D.key!==null&&(bi=l.enterKey(D.key)),D.optional){var Ri=null;if(D.explicit!==null?Ri=D.explicit:D.implicit!==null?Ri=D.implicit:D.tag!==null&&(Ri=D.tag),Ri===null&&!D.any){var Ti=l.save();try{D.choice===null?this._decodeGeneric(D.tag,l,vi):this._decodeChoice(l,vi),gi=!0}catch{gi=!1}l.restore(Ti)}else if(gi=this._peekTag(l,Ri,D.any),l.isError(gi))return gi}var Ii;if(D.obj&&gi&&(Ii=l.enterObject()),gi){if(D.explicit!==null){var qi=this._decodeTag(l,D.explicit);if(l.isError(qi))return qi;l=qi}var Oi=l.offset;if(D.use===null&&D.choice===null){if(D.any)var Ti=l.save();var ki=this._decodeTag(l,D.implicit!==null?D.implicit:D.tag,D.any);if(l.isError(ki))return ki;D.any?mi=l.raw(Ti):l=ki}if(vi&&vi.track&&D.tag!==null&&vi.track(l.path(),Oi,l.length,"tagged"),vi&&vi.track&&D.tag!==null&&vi.track(l.path(),l.offset,l.length,"content"),D.any?mi=mi:D.choice===null?mi=this._decodeGeneric(D.tag,l,vi):mi=this._decodeChoice(l,vi),l.isError(mi))return mi;if(!D.any&&D.choice===null&&D.children!==null&&D.children.forEach(function(Hi){Hi._decode(l,vi)}),D.contains&&(D.tag==="octstr"||D.tag==="bitstr")){var Li=new i(mi);mi=this._getUse(D.contains,l._reporterState.obj)._decode(Li,vi)}}return D.obj&&gi&&(mi=l.leaveObject(Ii)),D.key!==null&&(mi!==null||gi===!0)?l.leaveKey(bi,D.key,mi):bi!==null&&l.exitKey(bi),mi},v.prototype._decodeGeneric=function(l,vi,D){var mi=this._baseState;return l==="seq"||l==="set"?null:l==="seqof"||l==="setof"?this._decodeList(vi,l,mi.args[0],D):/str$/.test(l)?this._decodeStr(vi,l,D):l==="objid"&&mi.args?this._decodeObjid(vi,mi.args[0],mi.args[1],D):l==="objid"?this._decodeObjid(vi,null,null,D):l==="gentime"||l==="utctime"?this._decodeTime(vi,l,D):l==="null_"?this._decodeNull(vi,D):l==="bool"?this._decodeBool(vi,D):l==="objDesc"?this._decodeStr(vi,l,D):l==="int"||l==="enum"?this._decodeInt(vi,mi.args&&mi.args[0],D):mi.use!==null?this._getUse(mi.use,vi._reporterState.obj)._decode(vi,D):vi.error("unknown tag: "+l)},v.prototype._getUse=function(l,vi){var D=this._baseState;return D.useDecoder=this._use(l,vi),n(D.useDecoder._baseState.parent===null),D.useDecoder=D.useDecoder._baseState.children[0],D.implicit!==D.useDecoder._baseState.implicit&&(D.useDecoder=D.useDecoder.clone(),D.useDecoder._baseState.implicit=D.implicit),D.useDecoder},v.prototype._decodeChoice=function(l,vi){var D=this._baseState,mi=null,gi=!1;return Object.keys(D.choice).some(function(bi){var Ri=l.save(),Ti=D.choice[bi];try{var Ii=Ti._decode(l,vi);if(l.isError(Ii))return!1;mi={type:bi,value:Ii},gi=!0}catch{return l.restore(Ri),!1}return!0},this),gi?mi:l.error("Choice not matched")},v.prototype._createEncoderBuffer=function(l){return new t(l,this.reporter)},v.prototype._encode=function(l,vi,D){var mi=this._baseState;if(!(mi.default!==null&&mi.default===l)){var gi=this._encodeValue(l,vi,D);if(gi!==void 0&&!this._skipDefault(gi,vi,D))return gi}},v.prototype._encodeValue=function(l,vi,D){var mi=this._baseState;if(mi.parent===null)return mi.children[0]._encode(l,vi||new r);var Ti=null;if(this.reporter=vi,mi.optional&&l===void 0)if(mi.default!==null)l=mi.default;else return;var gi=null,bi=!1;if(mi.any)Ti=this._createEncoderBuffer(l);else if(mi.choice)Ti=this._encodeChoice(l,vi);else if(mi.contains)gi=this._getUse(mi.contains,D)._encode(l,vi),bi=!0;else if(mi.children)gi=mi.children.map(function(Oi){if(Oi._baseState.tag==="null_")return Oi._encode(null,vi,l);if(Oi._baseState.key===null)return vi.error("Child should have a key");var ki=vi.enterKey(Oi._baseState.key);if(typeof l!="object")return vi.error("Child expected, but input is not object");var Li=Oi._encode(l[Oi._baseState.key],vi,l);return vi.leaveKey(ki),Li},this).filter(function(Oi){return Oi}),gi=this._createEncoderBuffer(gi);else if(mi.tag==="seqof"||mi.tag==="setof"){if(!(mi.args&&mi.args.length===1))return vi.error("Too many args for : "+mi.tag);if(!Array.isArray(l))return vi.error("seqof/setof, but data is not Array");var Ri=this.clone();Ri._baseState.implicit=null,gi=this._createEncoderBuffer(l.map(function(Oi){var ki=this._baseState;return this._getUse(ki.args[0],l)._encode(Oi,vi)},Ri))}else mi.use!==null?Ti=this._getUse(mi.use,D)._encode(l,vi):(gi=this._encodePrimitive(mi.tag,l),bi=!0);var Ti;if(!mi.any&&mi.choice===null){var Ii=mi.implicit!==null?mi.implicit:mi.tag,qi=mi.implicit===null?"universal":"context";Ii===null?mi.use===null&&vi.error("Tag could be omitted only for .use()"):mi.use===null&&(Ti=this._encodeComposite(Ii,bi,qi,gi))}return mi.explicit!==null&&(Ti=this._encodeComposite(mi.explicit,!1,"context",Ti)),Ti},v.prototype._encodeChoice=function(l,vi){var D=this._baseState,mi=D.choice[l.type];return mi||n(!1,l.type+" not found in "+JSON.stringify(Object.keys(D.choice))),mi._encode(l.value,vi)},v.prototype._encodePrimitive=function(l,vi){var D=this._baseState;if(/str$/.test(l))return this._encodeStr(vi,l);if(l==="objid"&&D.args)return this._encodeObjid(vi,D.reverseArgs[0],D.args[1]);if(l==="objid")return this._encodeObjid(vi,null,null);if(l==="gentime"||l==="utctime")return this._encodeTime(vi,l);if(l==="null_")return this._encodeNull();if(l==="int"||l==="enum")return this._encodeInt(vi,D.args&&D.reverseArgs[0]);if(l==="bool")return this._encodeBool(vi);if(l==="objDesc")return this._encodeStr(vi,l);throw new Error("Unsupported tag: "+l)},v.prototype._isNumstr=function(l){return/^[0-9 ]*$/.test(l)},v.prototype._isPrintstr=function(l){return/^[A-Za-z0-9 '\(\)\+,\-\.\/:=\?]*$/.test(l)},node}var hasRequiredBase;function requireBase(){return hasRequiredBase||(hasRequiredBase=1,function(r){var t=r;t.Reporter=requireReporter().Reporter,t.DecoderBuffer=requireBuffer().DecoderBuffer,t.EncoderBuffer=requireBuffer().EncoderBuffer,t.Node=requireNode()}(base)),base}var constants={},der={},hasRequiredDer$2;function requireDer$2(){return hasRequiredDer$2||(hasRequiredDer$2=1,function(r){var t=requireConstants();r.tagClass={0:"universal",1:"application",2:"context",3:"private"},r.tagClassByName=t._reverse(r.tagClass),r.tag={0:"end",1:"bool",2:"int",3:"bitstr",4:"octstr",5:"null_",6:"objid",7:"objDesc",8:"external",9:"real",10:"enum",11:"embed",12:"utf8str",13:"relativeOid",16:"seq",17:"set",18:"numstr",19:"printstr",20:"t61str",21:"videostr",22:"ia5str",23:"utctime",24:"gentime",25:"graphstr",26:"iso646str",27:"genstr",28:"unistr",29:"charstr",30:"bmpstr"},r.tagByName=t._reverse(r.tag)}(der)),der}var hasRequiredConstants;function requireConstants(){return hasRequiredConstants||(hasRequiredConstants=1,function(r){var t=r;t._reverse=function(n){var s={};return Object.keys(n).forEach(function(a){(a|0)==a&&(a=a|0);var h=n[a];s[h]=a}),s},t.der=requireDer$2()}(constants)),constants}var decoders={},der_1$1,hasRequiredDer$1;function requireDer$1(){if(hasRequiredDer$1)return der_1$1;hasRequiredDer$1=1;var r=requireInherits_browser(),t=requireAsn1$1(),i=t.base,n=t.bignum,s=t.constants.der;function a(u){this.enc="der",this.name=u.name,this.entity=u,this.tree=new h,this.tree._init(u.body)}der_1$1=a,a.prototype.decode=function(l,vi){return l instanceof i.DecoderBuffer||(l=new i.DecoderBuffer(l,vi)),this.tree._decode(l,vi)};function h(u){i.Node.call(this,"der",u)}r(h,i.Node),h.prototype._peekTag=function(l,vi,D){if(l.isEmpty())return!1;var mi=l.save(),gi=v(l,'Failed to peek tag: "'+vi+'"');return l.isError(gi)?gi:(l.restore(mi),gi.tag===vi||gi.tagStr===vi||gi.tagStr+"of"===vi||D)},h.prototype._decodeTag=function(l,vi,D){var mi=v(l,'Failed to decode tag of "'+vi+'"');if(l.isError(mi))return mi;var gi=hi(l,mi.primitive,'Failed to get length of "'+vi+'"');if(l.isError(gi))return gi;if(!D&&mi.tag!==vi&&mi.tagStr!==vi&&mi.tagStr+"of"!==vi)return l.error('Failed to match tag: "'+vi+'"');if(mi.primitive||gi!==null)return l.skip(gi,'Failed to match body of: "'+vi+'"');var bi=l.save(),Ri=this._skipUntilEnd(l,'Failed to skip indefinite length body: "'+this.tag+'"');return l.isError(Ri)?Ri:(gi=l.offset-bi.offset,l.restore(bi),l.skip(gi,'Failed to match body of: "'+vi+'"'))},h.prototype._skipUntilEnd=function(l,vi){for(;;){var D=v(l,vi);if(l.isError(D))return D;var mi=hi(l,D.primitive,vi);if(l.isError(mi))return mi;var gi;if(D.primitive||mi!==null?gi=l.skip(mi):gi=this._skipUntilEnd(l,vi),l.isError(gi))return gi;if(D.tagStr==="end")break}},h.prototype._decodeList=function(l,vi,D,mi){for(var gi=[];!l.isEmpty();){var bi=this._peekTag(l,"end");if(l.isError(bi))return bi;var Ri=D.decode(l,"der",mi);if(l.isError(Ri)&&bi)break;gi.push(Ri)}return gi},h.prototype._decodeStr=function(l,vi){if(vi==="bitstr"){var D=l.readUInt8();return l.isError(D)?D:{unused:D,data:l.raw()}}else if(vi==="bmpstr"){var mi=l.raw();if(mi.length%2===1)return l.error("Decoding of string type: bmpstr length mismatch");for(var gi="",bi=0;bi<mi.length/2;bi++)gi+=String.fromCharCode(mi.readUInt16BE(bi*2));return gi}else if(vi==="numstr"){var Ri=l.raw().toString("ascii");return this._isNumstr(Ri)?Ri:l.error("Decoding of string type: numstr unsupported characters")}else{if(vi==="octstr")return l.raw();if(vi==="objDesc")return l.raw();if(vi==="printstr"){var Ti=l.raw().toString("ascii");return this._isPrintstr(Ti)?Ti:l.error("Decoding of string type: printstr unsupported characters")}else return/str$/.test(vi)?l.raw().toString():l.error("Decoding of string type: "+vi+" unsupported")}},h.prototype._decodeObjid=function(l,vi,D){for(var mi,gi=[],bi=0;!l.isEmpty();){var Ri=l.readUInt8();bi<<=7,bi|=Ri&127,(Ri&128)===0&&(gi.push(bi),bi=0)}Ri&128&&gi.push(bi);var Ti=gi[0]/40|0,Ii=gi[0]%40;if(D?mi=gi:mi=[Ti,Ii].concat(gi.slice(1)),vi){var qi=vi[mi.join(" ")];qi===void 0&&(qi=vi[mi.join(".")]),qi!==void 0&&(mi=qi)}return mi},h.prototype._decodeTime=function(l,vi){var D=l.raw().toString();if(vi==="gentime")var mi=D.slice(0,4)|0,gi=D.slice(4,6)|0,bi=D.slice(6,8)|0,Ri=D.slice(8,10)|0,Ti=D.slice(10,12)|0,Ii=D.slice(12,14)|0;else if(vi==="utctime"){var mi=D.slice(0,2)|0,gi=D.slice(2,4)|0,bi=D.slice(4,6)|0,Ri=D.slice(6,8)|0,Ti=D.slice(8,10)|0,Ii=D.slice(10,12)|0;mi<70?mi=2e3+mi:mi=1900+mi}else return l.error("Decoding "+vi+" time is not supported yet");return Date.UTC(mi,gi-1,bi,Ri,Ti,Ii,0)},h.prototype._decodeNull=function(l){return null},h.prototype._decodeBool=function(l){var vi=l.readUInt8();return l.isError(vi)?vi:vi!==0},h.prototype._decodeInt=function(l,vi){var D=l.raw(),mi=new n(D);return vi&&(mi=vi[mi.toString(10)]||mi),mi},h.prototype._use=function(l,vi){return typeof l=="function"&&(l=l(vi)),l._getDecoder("der").tree};function v(u,l){var vi=u.readUInt8(l);if(u.isError(vi))return vi;var D=s.tagClass[vi>>6],mi=(vi&32)===0;if((vi&31)===31){var gi=vi;for(vi=0;(gi&128)===128;){if(gi=u.readUInt8(l),u.isError(gi))return gi;vi<<=7,vi|=gi&127}}else vi&=31;var bi=s.tag[vi];return{cls:D,primitive:mi,tag:vi,tagStr:bi}}function hi(u,l,vi){var D=u.readUInt8(vi);if(u.isError(D))return D;if(!l&&D===128)return null;if((D&128)===0)return D;var mi=D&127;if(mi>4)return u.error("length octect is too long");D=0;for(var gi=0;gi<mi;gi++){D<<=8;var bi=u.readUInt8(vi);if(u.isError(bi))return bi;D|=bi}return D}return der_1$1}var pem$1,hasRequiredPem$1;function requirePem$1(){if(hasRequiredPem$1)return pem$1;hasRequiredPem$1=1;var r=requireInherits_browser(),t=requireDist().Buffer,i=requireDer$1();function n(s){i.call(this,s),this.enc="pem"}return r(n,i),pem$1=n,n.prototype.decode=function(a,h){for(var v=a.toString().split(/[\r\n]+/g),hi=h.label.toUpperCase(),u=/^-----(BEGIN|END) ([^-]+)-----$/,l=-1,vi=-1,D=0;D<v.length;D++){var mi=v[D].match(u);if(mi!==null&&mi[2]===hi)if(l===-1){if(mi[1]!=="BEGIN")break;l=D}else{if(mi[1]!=="END")break;vi=D;break}}if(l===-1||vi===-1)throw new Error("PEM section not found for: "+hi);var gi=v.slice(l+1,vi).join("");gi.replace(/[^a-z0-9\+\/=]+/gi,"");var bi=new t(gi,"base64");return i.prototype.decode.call(this,bi,h)},pem$1}var hasRequiredDecoders;function requireDecoders(){return hasRequiredDecoders||(hasRequiredDecoders=1,function(r){var t=r;t.der=requireDer$1(),t.pem=requirePem$1()}(decoders)),decoders}var encoders={},der_1,hasRequiredDer;function requireDer(){if(hasRequiredDer)return der_1;hasRequiredDer=1;var r=requireInherits_browser(),t=requireDist().Buffer,i=requireAsn1$1(),n=i.base,s=i.constants.der;function a(u){this.enc="der",this.name=u.name,this.entity=u,this.tree=new h,this.tree._init(u.body)}der_1=a,a.prototype.encode=function(l,vi){return this.tree._encode(l,vi).join()};function h(u){n.Node.call(this,"der",u)}r(h,n.Node),h.prototype._encodeComposite=function(l,vi,D,mi){var gi=hi(l,vi,D,this.reporter);if(mi.length<128){var Ti=new t(2);return Ti[0]=gi,Ti[1]=mi.length,this._createEncoderBuffer([Ti,mi])}for(var bi=1,Ri=mi.length;Ri>=256;Ri>>=8)bi++;var Ti=new t(2+bi);Ti[0]=gi,Ti[1]=128|bi;for(var Ri=1+bi,Ii=mi.length;Ii>0;Ri--,Ii>>=8)Ti[Ri]=Ii&255;return this._createEncoderBuffer([Ti,mi])},h.prototype._encodeStr=function(l,vi){if(vi==="bitstr")return this._createEncoderBuffer([l.unused|0,l.data]);if(vi==="bmpstr"){for(var D=new t(l.length*2),mi=0;mi<l.length;mi++)D.writeUInt16BE(l.charCodeAt(mi),mi*2);return this._createEncoderBuffer(D)}else return vi==="numstr"?this._isNumstr(l)?this._createEncoderBuffer(l):this.reporter.error("Encoding of string type: numstr supports only digits and space"):vi==="printstr"?this._isPrintstr(l)?this._createEncoderBuffer(l):this.reporter.error("Encoding of string type: printstr supports only latin upper and lower case letters, digits, space, apostrophe, left and rigth parenthesis, plus sign, comma, hyphen, dot, slash, colon, equal sign, question mark"):/str$/.test(vi)?this._createEncoderBuffer(l):vi==="objDesc"?this._createEncoderBuffer(l):this.reporter.error("Encoding of string type: "+vi+" unsupported")},h.prototype._encodeObjid=function(l,vi,D){if(typeof l=="string"){if(!vi)return this.reporter.error("string objid given, but no values map found");if(!vi.hasOwnProperty(l))return this.reporter.error("objid not found in values map");l=vi[l].split(/[\s\.]+/g);for(var mi=0;mi<l.length;mi++)l[mi]|=0}else if(Array.isArray(l)){l=l.slice();for(var mi=0;mi<l.length;mi++)l[mi]|=0}if(!Array.isArray(l))return this.reporter.error("objid() should be either array or string, got: "+JSON.stringify(l));if(!D){if(l[1]>=40)return this.reporter.error("Second objid identifier OOB");l.splice(0,2,l[0]*40+l[1])}for(var gi=0,mi=0;mi<l.length;mi++){var bi=l[mi];for(gi++;bi>=128;bi>>=7)gi++}for(var Ri=new t(gi),Ti=Ri.length-1,mi=l.length-1;mi>=0;mi--){var bi=l[mi];for(Ri[Ti--]=bi&127;(bi>>=7)>0;)Ri[Ti--]=128|bi&127}return this._createEncoderBuffer(Ri)};function v(u){return u<10?"0"+u:u}h.prototype._encodeTime=function(l,vi){var D,mi=new Date(l);return vi==="gentime"?D=[v(mi.getFullYear()),v(mi.getUTCMonth()+1),v(mi.getUTCDate()),v(mi.getUTCHours()),v(mi.getUTCMinutes()),v(mi.getUTCSeconds()),"Z"].join(""):vi==="utctime"?D=[v(mi.getFullYear()%100),v(mi.getUTCMonth()+1),v(mi.getUTCDate()),v(mi.getUTCHours()),v(mi.getUTCMinutes()),v(mi.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+vi+" time is not supported yet"),this._encodeStr(D,"octstr")},h.prototype._encodeNull=function(){return this._createEncoderBuffer("")},h.prototype._encodeInt=function(l,vi){if(typeof l=="string"){if(!vi)return this.reporter.error("String int or enum given, but no values map");if(!vi.hasOwnProperty(l))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(l));l=vi[l]}if(typeof l!="number"&&!t.isBuffer(l)){var D=l.toArray();!l.sign&&D[0]&128&&D.unshift(0),l=new t(D)}if(t.isBuffer(l)){var mi=l.length;l.length===0&&mi++;var bi=new t(mi);return l.copy(bi),l.length===0&&(bi[0]=0),this._createEncoderBuffer(bi)}if(l<128)return this._createEncoderBuffer(l);if(l<256)return this._createEncoderBuffer([0,l]);for(var mi=1,gi=l;gi>=256;gi>>=8)mi++;for(var bi=new Array(mi),gi=bi.length-1;gi>=0;gi--)bi[gi]=l&255,l>>=8;return bi[0]&128&&bi.unshift(0),this._createEncoderBuffer(new t(bi))},h.prototype._encodeBool=function(l){return this._createEncoderBuffer(l?255:0)},h.prototype._use=function(l,vi){return typeof l=="function"&&(l=l(vi)),l._getEncoder("der").tree},h.prototype._skipDefault=function(l,vi,D){var mi=this._baseState,gi;if(mi.default===null)return!1;var bi=l.join();if(mi.defaultBuffer===void 0&&(mi.defaultBuffer=this._encodeValue(mi.default,vi,D).join()),bi.length!==mi.defaultBuffer.length)return!1;for(gi=0;gi<bi.length;gi++)if(bi[gi]!==mi.defaultBuffer[gi])return!1;return!0};function hi(u,l,vi,D){var mi;if(u==="seqof"?u="seq":u==="setof"&&(u="set"),s.tagByName.hasOwnProperty(u))mi=s.tagByName[u];else if(typeof u=="number"&&(u|0)===u)mi=u;else return D.error("Unknown tag: "+u);return mi>=31?D.error("Multi-octet tag encoding unsupported"):(l||(mi|=32),mi|=s.tagClassByName[vi||"universal"]<<6,mi)}return der_1}var pem,hasRequiredPem;function requirePem(){if(hasRequiredPem)return pem;hasRequiredPem=1;var r=requireInherits_browser(),t=requireDer();function i(n){t.call(this,n),this.enc="pem"}return r(i,t),pem=i,i.prototype.encode=function(s,a){for(var h=t.prototype.encode.call(this,s),v=h.toString("base64"),hi=["-----BEGIN "+a.label+"-----"],u=0;u<v.length;u+=64)hi.push(v.slice(u,u+64));return hi.push("-----END "+a.label+"-----"),hi.join(`
101
+ `)},pem}var hasRequiredEncoders;function requireEncoders(){return hasRequiredEncoders||(hasRequiredEncoders=1,function(r){var t=r;t.der=requireDer(),t.pem=requirePem()}(encoders)),encoders}var hasRequiredAsn1$1;function requireAsn1$1(){return hasRequiredAsn1$1||(hasRequiredAsn1$1=1,function(r){var t=r;t.bignum=requireBn$2(),t.define=requireApi$1().define,t.base=requireBase(),t.constants=requireConstants(),t.decoders=requireDecoders(),t.encoders=requireEncoders()}(asn1)),asn1}var certificate,hasRequiredCertificate;function requireCertificate(){if(hasRequiredCertificate)return certificate;hasRequiredCertificate=1;var r=requireAsn1$1(),t=r.define("Time",function(){this.choice({utcTime:this.utctime(),generalTime:this.gentime()})}),i=r.define("AttributeTypeValue",function(){this.seq().obj(this.key("type").objid(),this.key("value").any())}),n=r.define("AlgorithmIdentifier",function(){this.seq().obj(this.key("algorithm").objid(),this.key("parameters").optional(),this.key("curve").objid().optional())}),s=r.define("SubjectPublicKeyInfo",function(){this.seq().obj(this.key("algorithm").use(n),this.key("subjectPublicKey").bitstr())}),a=r.define("RelativeDistinguishedName",function(){this.setof(i)}),h=r.define("RDNSequence",function(){this.seqof(a)}),v=r.define("Name",function(){this.choice({rdnSequence:this.use(h)})}),hi=r.define("Validity",function(){this.seq().obj(this.key("notBefore").use(t),this.key("notAfter").use(t))}),u=r.define("Extension",function(){this.seq().obj(this.key("extnID").objid(),this.key("critical").bool().def(!1),this.key("extnValue").octstr())}),l=r.define("TBSCertificate",function(){this.seq().obj(this.key("version").explicit(0).int().optional(),this.key("serialNumber").int(),this.key("signature").use(n),this.key("issuer").use(v),this.key("validity").use(hi),this.key("subject").use(v),this.key("subjectPublicKeyInfo").use(s),this.key("issuerUniqueID").implicit(1).bitstr().optional(),this.key("subjectUniqueID").implicit(2).bitstr().optional(),this.key("extensions").explicit(3).seqof(u).optional())}),vi=r.define("X509Certificate",function(){this.seq().obj(this.key("tbsCertificate").use(l),this.key("signatureAlgorithm").use(n),this.key("signatureValue").bitstr())});return certificate=vi,certificate}var hasRequiredAsn1;function requireAsn1(){if(hasRequiredAsn1)return asn1$1;hasRequiredAsn1=1;var r=requireAsn1$1();asn1$1.certificate=requireCertificate();var t=r.define("RSAPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("modulus").int(),this.key("publicExponent").int(),this.key("privateExponent").int(),this.key("prime1").int(),this.key("prime2").int(),this.key("exponent1").int(),this.key("exponent2").int(),this.key("coefficient").int())});asn1$1.RSAPrivateKey=t;var i=r.define("RSAPublicKey",function(){this.seq().obj(this.key("modulus").int(),this.key("publicExponent").int())});asn1$1.RSAPublicKey=i;var n=r.define("AlgorithmIdentifier",function(){this.seq().obj(this.key("algorithm").objid(),this.key("none").null_().optional(),this.key("curve").objid().optional(),this.key("params").seq().obj(this.key("p").int(),this.key("q").int(),this.key("g").int()).optional())}),s=r.define("SubjectPublicKeyInfo",function(){this.seq().obj(this.key("algorithm").use(n),this.key("subjectPublicKey").bitstr())});asn1$1.PublicKey=s;var a=r.define("PrivateKeyInfo",function(){this.seq().obj(this.key("version").int(),this.key("algorithm").use(n),this.key("subjectPrivateKey").octstr())});asn1$1.PrivateKey=a;var h=r.define("EncryptedPrivateKeyInfo",function(){this.seq().obj(this.key("algorithm").seq().obj(this.key("id").objid(),this.key("decrypt").seq().obj(this.key("kde").seq().obj(this.key("id").objid(),this.key("kdeparams").seq().obj(this.key("salt").octstr(),this.key("iters").int())),this.key("cipher").seq().obj(this.key("algo").objid(),this.key("iv").octstr()))),this.key("subjectPrivateKey").octstr())});asn1$1.EncryptedPrivateKey=h;var v=r.define("DSAPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("p").int(),this.key("q").int(),this.key("g").int(),this.key("pub_key").int(),this.key("priv_key").int())});asn1$1.DSAPrivateKey=v,asn1$1.DSAparam=r.define("DSAparam",function(){this.int()});var hi=r.define("ECParameters",function(){this.choice({namedCurve:this.objid()})}),u=r.define("ECPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("privateKey").octstr(),this.key("parameters").optional().explicit(0).use(hi),this.key("publicKey").optional().explicit(1).bitstr())});return asn1$1.ECPrivateKey=u,asn1$1.signature=r.define("signature",function(){this.seq().obj(this.key("r").int(),this.key("s").int())}),asn1$1}var require$$1={"2.16.840.1.101.3.4.1.1":"aes-128-ecb","2.16.840.1.101.3.4.1.2":"aes-128-cbc","2.16.840.1.101.3.4.1.3":"aes-128-ofb","2.16.840.1.101.3.4.1.4":"aes-128-cfb","2.16.840.1.101.3.4.1.21":"aes-192-ecb","2.16.840.1.101.3.4.1.22":"aes-192-cbc","2.16.840.1.101.3.4.1.23":"aes-192-ofb","2.16.840.1.101.3.4.1.24":"aes-192-cfb","2.16.840.1.101.3.4.1.41":"aes-256-ecb","2.16.840.1.101.3.4.1.42":"aes-256-cbc","2.16.840.1.101.3.4.1.43":"aes-256-ofb","2.16.840.1.101.3.4.1.44":"aes-256-cfb"},fixProc,hasRequiredFixProc;function requireFixProc(){if(hasRequiredFixProc)return fixProc;hasRequiredFixProc=1;var r=/Proc-Type: 4,ENCRYPTED[\n\r]+DEK-Info: AES-((?:128)|(?:192)|(?:256))-CBC,([0-9A-H]+)[\n\r]+([0-9A-z\n\r+/=]+)[\n\r]+/m,t=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----/m,i=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----([0-9A-z\n\r+/=]+)-----END \1-----$/m,n=requireEvp_bytestokey(),s=requireBrowser$7(),a=requireSafeBuffer$1().Buffer;return fixProc=function(h,v){var hi=h.toString(),u=hi.match(r),l;if(u){var D="aes"+u[1],mi=a.from(u[2],"hex"),gi=a.from(u[3].replace(/[\r\n]/g,""),"base64"),bi=n(v,mi.slice(0,8),parseInt(u[1],10)).key,Ri=[],Ti=s.createDecipheriv(D,bi,mi);Ri.push(Ti.update(gi)),Ri.push(Ti.final()),l=a.concat(Ri)}else{var vi=hi.match(i);l=a.from(vi[2].replace(/[\r\n]/g,""),"base64")}var Ii=hi.match(t)[1];return{tag:Ii,data:l}},fixProc}var parseAsn1,hasRequiredParseAsn1;function requireParseAsn1(){if(hasRequiredParseAsn1)return parseAsn1;hasRequiredParseAsn1=1;var r=requireAsn1(),t=require$$1,i=requireFixProc(),n=requireBrowser$7(),s=requireBrowser$8(),a=requireSafeBuffer$1().Buffer;function h(hi,u){var l=hi.algorithm.decrypt.kde.kdeparams.salt,vi=parseInt(hi.algorithm.decrypt.kde.kdeparams.iters.toString(),10),D=t[hi.algorithm.decrypt.cipher.algo.join(".")],mi=hi.algorithm.decrypt.cipher.iv,gi=hi.subjectPrivateKey,bi=parseInt(D.split("-")[1],10)/8,Ri=s.pbkdf2Sync(u,l,vi,bi,"sha1"),Ti=n.createDecipheriv(D,Ri,mi),Ii=[];return Ii.push(Ti.update(gi)),Ii.push(Ti.final()),a.concat(Ii)}function v(hi){var u;typeof hi=="object"&&!a.isBuffer(hi)&&(u=hi.passphrase,hi=hi.key),typeof hi=="string"&&(hi=a.from(hi));var l=i(hi,u),vi=l.tag,D=l.data,mi,gi;switch(vi){case"CERTIFICATE":gi=r.certificate.decode(D,"der").tbsCertificate.subjectPublicKeyInfo;case"PUBLIC KEY":switch(gi||(gi=r.PublicKey.decode(D,"der")),mi=gi.algorithm.algorithm.join("."),mi){case"1.2.840.113549.1.1.1":return r.RSAPublicKey.decode(gi.subjectPublicKey.data,"der");case"1.2.840.10045.2.1":return gi.subjectPrivateKey=gi.subjectPublicKey,{type:"ec",data:gi};case"1.2.840.10040.4.1":return gi.algorithm.params.pub_key=r.DSAparam.decode(gi.subjectPublicKey.data,"der"),{type:"dsa",data:gi.algorithm.params};default:throw new Error("unknown key id "+mi)}case"ENCRYPTED PRIVATE KEY":D=r.EncryptedPrivateKey.decode(D,"der"),D=h(D,u);case"PRIVATE KEY":switch(gi=r.PrivateKey.decode(D,"der"),mi=gi.algorithm.algorithm.join("."),mi){case"1.2.840.113549.1.1.1":return r.RSAPrivateKey.decode(gi.subjectPrivateKey,"der");case"1.2.840.10045.2.1":return{curve:gi.algorithm.curve,privateKey:r.ECPrivateKey.decode(gi.subjectPrivateKey,"der").privateKey};case"1.2.840.10040.4.1":return gi.algorithm.params.priv_key=r.DSAparam.decode(gi.subjectPrivateKey,"der"),{type:"dsa",params:gi.algorithm.params};default:throw new Error("unknown key id "+mi)}case"RSA PUBLIC KEY":return r.RSAPublicKey.decode(D,"der");case"RSA PRIVATE KEY":return r.RSAPrivateKey.decode(D,"der");case"DSA PRIVATE KEY":return{type:"dsa",params:r.DSAPrivateKey.decode(D,"der")};case"EC PRIVATE KEY":return D=r.ECPrivateKey.decode(D,"der"),{curve:D.parameters.value,privateKey:D.privateKey};default:throw new Error("unknown key type "+vi)}}return v.signature=r.signature,parseAsn1=v,parseAsn1}var require$$4={"1.3.132.0.10":"secp256k1","1.3.132.0.33":"p224","1.2.840.10045.3.1.1":"p192","1.2.840.10045.3.1.7":"p256","1.3.132.0.34":"p384","1.3.132.0.35":"p521"},hasRequiredSign;function requireSign(){if(hasRequiredSign)return sign.exports;hasRequiredSign=1;var r=requireSafeBuffer$1().Buffer,t=requireBrowser$9(),i=requireBrowserifyRsa(),n=requireElliptic().ec,s=requireBn(),a=requireParseAsn1(),h=require$$4,v=1;function hi(Ti,Ii,qi,Oi,ki){var Li=a(Ii);if(Li.curve){if(Oi!=="ecdsa"&&Oi!=="ecdsa/rsa")throw new Error("wrong private key type");return u(Ti,Li)}else if(Li.type==="dsa"){if(Oi!=="dsa")throw new Error("wrong private key type");return l(Ti,Li,qi)}if(Oi!=="rsa"&&Oi!=="ecdsa/rsa")throw new Error("wrong private key type");if(Ii.padding!==void 0&&Ii.padding!==v)throw new Error("illegal or unsupported padding mode");Ti=r.concat([ki,Ti]);for(var ji=Li.modulus.byteLength(),Hi=[0,1];Ti.length+Hi.length+1<ji;)Hi.push(255);Hi.push(0);for(var Ui=-1;++Ui<Ti.length;)Hi.push(Ti[Ui]);var Qi=i(Hi,Li);return Qi}function u(Ti,Ii){var qi=h[Ii.curve.join(".")];if(!qi)throw new Error("unknown curve "+Ii.curve.join("."));var Oi=new n(qi),ki=Oi.keyFromPrivate(Ii.privateKey),Li=ki.sign(Ti);return r.from(Li.toDER())}function l(Ti,Ii,qi){for(var Oi=Ii.params.priv_key,ki=Ii.params.p,Li=Ii.params.q,ji=Ii.params.g,Hi=new s(0),Ui,Qi=mi(Ti,Li).mod(Li),$i=!1,wi=D(Oi,Li,Ti,qi);$i===!1;)Ui=bi(Li,wi,qi),Hi=Ri(ji,Ui,ki,Li),$i=Ui.invm(Li).imul(Qi.add(Oi.mul(Hi))).mod(Li),$i.cmpn(0)===0&&($i=!1,Hi=new s(0));return vi(Hi,$i)}function vi(Ti,Ii){Ti=Ti.toArray(),Ii=Ii.toArray(),Ti[0]&128&&(Ti=[0].concat(Ti)),Ii[0]&128&&(Ii=[0].concat(Ii));var qi=Ti.length+Ii.length+4,Oi=[48,qi,2,Ti.length];return Oi=Oi.concat(Ti,[2,Ii.length],Ii),r.from(Oi)}function D(Ti,Ii,qi,Oi){if(Ti=r.from(Ti.toArray()),Ti.length<Ii.byteLength()){var ki=r.alloc(Ii.byteLength()-Ti.length);Ti=r.concat([ki,Ti])}var Li=qi.length,ji=gi(qi,Ii),Hi=r.alloc(Li);Hi.fill(1);var Ui=r.alloc(Li);return Ui=t(Oi,Ui).update(Hi).update(r.from([0])).update(Ti).update(ji).digest(),Hi=t(Oi,Ui).update(Hi).digest(),Ui=t(Oi,Ui).update(Hi).update(r.from([1])).update(Ti).update(ji).digest(),Hi=t(Oi,Ui).update(Hi).digest(),{k:Ui,v:Hi}}function mi(Ti,Ii){var qi=new s(Ti),Oi=(Ti.length<<3)-Ii.bitLength();return Oi>0&&qi.ishrn(Oi),qi}function gi(Ti,Ii){Ti=mi(Ti,Ii),Ti=Ti.mod(Ii);var qi=r.from(Ti.toArray());if(qi.length<Ii.byteLength()){var Oi=r.alloc(Ii.byteLength()-qi.length);qi=r.concat([Oi,qi])}return qi}function bi(Ti,Ii,qi){var Oi,ki;do{for(Oi=r.alloc(0);Oi.length*8<Ti.bitLength();)Ii.v=t(qi,Ii.k).update(Ii.v).digest(),Oi=r.concat([Oi,Ii.v]);ki=mi(Oi,Ti),Ii.k=t(qi,Ii.k).update(Ii.v).update(r.from([0])).digest(),Ii.v=t(qi,Ii.k).update(Ii.v).digest()}while(ki.cmp(Ti)!==-1);return ki}function Ri(Ti,Ii,qi,Oi){return Ti.toRed(s.mont(qi)).redPow(Ii).fromRed().mod(Oi)}return sign.exports=hi,sign.exports.getKey=D,sign.exports.makeKey=bi,sign.exports}var verify_1,hasRequiredVerify;function requireVerify(){if(hasRequiredVerify)return verify_1;hasRequiredVerify=1;var r=requireSafeBuffer$1().Buffer,t=requireBn(),i=requireElliptic().ec,n=requireParseAsn1(),s=require$$4;function a(u,l,vi,D,mi){var gi=n(vi);if(gi.type==="ec"){if(D!=="ecdsa"&&D!=="ecdsa/rsa")throw new Error("wrong public key type");return h(u,l,gi)}else if(gi.type==="dsa"){if(D!=="dsa")throw new Error("wrong public key type");return v(u,l,gi)}if(D!=="rsa"&&D!=="ecdsa/rsa")throw new Error("wrong public key type");l=r.concat([mi,l]);for(var bi=gi.modulus.byteLength(),Ri=[1],Ti=0;l.length+Ri.length+2<bi;)Ri.push(255),Ti+=1;Ri.push(0);for(var Ii=-1;++Ii<l.length;)Ri.push(l[Ii]);Ri=r.from(Ri);var qi=t.mont(gi.modulus);u=new t(u).toRed(qi),u=u.redPow(new t(gi.publicExponent)),u=r.from(u.fromRed().toArray());var Oi=Ti<8?1:0;for(bi=Math.min(u.length,Ri.length),u.length!==Ri.length&&(Oi=1),Ii=-1;++Ii<bi;)Oi|=u[Ii]^Ri[Ii];return Oi===0}function h(u,l,vi){var D=s[vi.data.algorithm.curve.join(".")];if(!D)throw new Error("unknown curve "+vi.data.algorithm.curve.join("."));var mi=new i(D),gi=vi.data.subjectPrivateKey.data;return mi.verify(l,u,gi)}function v(u,l,vi){var D=vi.data.p,mi=vi.data.q,gi=vi.data.g,bi=vi.data.pub_key,Ri=n.signature.decode(u,"der"),Ti=Ri.s,Ii=Ri.r;hi(Ti,mi),hi(Ii,mi);var qi=t.mont(D),Oi=Ti.invm(mi),ki=gi.toRed(qi).redPow(new t(l).mul(Oi).mod(mi)).fromRed().mul(bi.toRed(qi).redPow(Ii.mul(Oi).mod(mi)).fromRed()).mod(D).mod(mi);return ki.cmp(Ii)===0}function hi(u,l){if(u.cmpn(0)<=0)throw new Error("invalid sig");if(u.cmp(l)>=0)throw new Error("invalid sig")}return verify_1=a,verify_1}var browser$4,hasRequiredBrowser$4;function requireBrowser$4(){if(hasRequiredBrowser$4)return browser$4;hasRequiredBrowser$4=1;var r=requireSafeBuffer$1().Buffer,t=requireBrowser$a(),i=requireReadableBrowser(),n=requireInherits_browser(),s=requireSign(),a=requireVerify(),h=require$$6;Object.keys(h).forEach(function(vi){h[vi].id=r.from(h[vi].id,"hex"),h[vi.toLowerCase()]=h[vi]});function v(vi){i.Writable.call(this);var D=h[vi];if(!D)throw new Error("Unknown message digest");this._hashType=D.hash,this._hash=t(D.hash),this._tag=D.id,this._signType=D.sign}n(v,i.Writable),v.prototype._write=function(D,mi,gi){this._hash.update(D),gi()},v.prototype.update=function(D,mi){return this._hash.update(typeof D=="string"?r.from(D,mi):D),this},v.prototype.sign=function(D,mi){this.end();var gi=this._hash.digest(),bi=s(gi,D,this._hashType,this._signType,this._tag);return mi?bi.toString(mi):bi};function hi(vi){i.Writable.call(this);var D=h[vi];if(!D)throw new Error("Unknown message digest");this._hash=t(D.hash),this._tag=D.id,this._signType=D.sign}n(hi,i.Writable),hi.prototype._write=function(D,mi,gi){this._hash.update(D),gi()},hi.prototype.update=function(D,mi){return this._hash.update(typeof D=="string"?r.from(D,mi):D),this},hi.prototype.verify=function(D,mi,gi){var bi=typeof mi=="string"?r.from(mi,gi):mi;this.end();var Ri=this._hash.digest();return a(bi,Ri,D,this._signType,this._tag)};function u(vi){return new v(vi)}function l(vi){return new hi(vi)}return browser$4={Sign:u,Verify:l,createSign:u,createVerify:l},browser$4}var browser$3,hasRequiredBrowser$3;function requireBrowser$3(){if(hasRequiredBrowser$3)return browser$3;hasRequiredBrowser$3=1;var r=requireElliptic(),t=requireBn$2();browser$3=function(h){return new n(h)};var i={secp256k1:{name:"secp256k1",byteLength:32},secp224r1:{name:"p224",byteLength:28},prime256v1:{name:"p256",byteLength:32},prime192v1:{name:"p192",byteLength:24},ed25519:{name:"ed25519",byteLength:32},secp384r1:{name:"p384",byteLength:48},secp521r1:{name:"p521",byteLength:66}};i.p224=i.secp224r1,i.p256=i.secp256r1=i.prime256v1,i.p192=i.secp192r1=i.prime192v1,i.p384=i.secp384r1,i.p521=i.secp521r1;function n(a){this.curveType=i[a],this.curveType||(this.curveType={name:a}),this.curve=new r.ec(this.curveType.name),this.keys=void 0}n.prototype.generateKeys=function(a,h){return this.keys=this.curve.genKeyPair(),this.getPublicKey(a,h)},n.prototype.computeSecret=function(a,h,v){h=h||"utf8",Buffer.isBuffer(a)||(a=new Buffer(a,h));var hi=this.curve.keyFromPublic(a).getPublic(),u=hi.mul(this.keys.getPrivate()).getX();return s(u,v,this.curveType.byteLength)},n.prototype.getPublicKey=function(a,h){var v=this.keys.getPublic(h==="compressed",!0);return h==="hybrid"&&(v[v.length-1]%2?v[0]=7:v[0]=6),s(v,a)},n.prototype.getPrivateKey=function(a){return s(this.keys.getPrivate(),a)},n.prototype.setPublicKey=function(a,h){return h=h||"utf8",Buffer.isBuffer(a)||(a=new Buffer(a,h)),this.keys._importPublic(a),this},n.prototype.setPrivateKey=function(a,h){h=h||"utf8",Buffer.isBuffer(a)||(a=new Buffer(a,h));var v=new t(a);return v=v.toString(16),this.keys=this.curve.genKeyPair(),this.keys._importPrivate(v),this};function s(a,h,v){Array.isArray(a)||(a=a.toArray());var hi=new Buffer(a);if(v&&hi.length<v){var u=new Buffer(v-hi.length);u.fill(0),hi=Buffer.concat([u,hi])}return h?hi.toString(h):hi}return browser$3}var browser$2={},mgf,hasRequiredMgf;function requireMgf(){if(hasRequiredMgf)return mgf;hasRequiredMgf=1;var r=requireBrowser$a(),t=requireSafeBuffer$1().Buffer;mgf=function(n,s){for(var a=t.alloc(0),h=0,v;a.length<s;)v=i(h++),a=t.concat([a,r("sha1").update(n).update(v).digest()]);return a.slice(0,s)};function i(n){var s=t.allocUnsafe(4);return s.writeUInt32BE(n,0),s}return mgf}var xor,hasRequiredXor;function requireXor(){return hasRequiredXor||(hasRequiredXor=1,xor=function(t,i){for(var n=t.length,s=-1;++s<n;)t[s]^=i[s];return t}),xor}var withPublic_1,hasRequiredWithPublic;function requireWithPublic(){if(hasRequiredWithPublic)return withPublic_1;hasRequiredWithPublic=1;var r=requireBn$2(),t=requireSafeBuffer$1().Buffer;function i(n,s){return t.from(n.toRed(r.mont(s.modulus)).redPow(new r(s.publicExponent)).fromRed().toArray())}return withPublic_1=i,withPublic_1}var publicEncrypt,hasRequiredPublicEncrypt;function requirePublicEncrypt(){if(hasRequiredPublicEncrypt)return publicEncrypt;hasRequiredPublicEncrypt=1;var r=requireParseAsn1(),t=requireBrowser$b(),i=requireBrowser$a(),n=requireMgf(),s=requireXor(),a=requireBn$2(),h=requireWithPublic(),v=requireBrowserifyRsa(),hi=requireSafeBuffer$1().Buffer;publicEncrypt=function(mi,gi,bi){var Ri;mi.padding?Ri=mi.padding:bi?Ri=1:Ri=4;var Ti=r(mi),Ii;if(Ri===4)Ii=u(Ti,gi);else if(Ri===1)Ii=l(Ti,gi,bi);else if(Ri===3){if(Ii=new a(gi),Ii.cmp(Ti.modulus)>=0)throw new Error("data too long for modulus")}else throw new Error("unknown padding");return bi?v(Ii,Ti):h(Ii,Ti)};function u(D,mi){var gi=D.modulus.byteLength(),bi=mi.length,Ri=i("sha1").update(hi.alloc(0)).digest(),Ti=Ri.length,Ii=2*Ti;if(bi>gi-Ii-2)throw new Error("message too long");var qi=hi.alloc(gi-bi-Ii-2),Oi=gi-Ti-1,ki=t(Ti),Li=s(hi.concat([Ri,qi,hi.alloc(1,1),mi],Oi),n(ki,Oi)),ji=s(ki,n(Li,Ti));return new a(hi.concat([hi.alloc(1),ji,Li],gi))}function l(D,mi,gi){var bi=mi.length,Ri=D.modulus.byteLength();if(bi>Ri-11)throw new Error("message too long");var Ti;return gi?Ti=hi.alloc(Ri-bi-3,255):Ti=vi(Ri-bi-3),new a(hi.concat([hi.from([0,gi?1:2]),Ti,hi.alloc(1),mi],Ri))}function vi(D){for(var mi=hi.allocUnsafe(D),gi=0,bi=t(D*2),Ri=0,Ti;gi<D;)Ri===bi.length&&(bi=t(D*2),Ri=0),Ti=bi[Ri++],Ti&&(mi[gi++]=Ti);return mi}return publicEncrypt}var privateDecrypt,hasRequiredPrivateDecrypt;function requirePrivateDecrypt(){if(hasRequiredPrivateDecrypt)return privateDecrypt;hasRequiredPrivateDecrypt=1;var r=requireParseAsn1(),t=requireMgf(),i=requireXor(),n=requireBn$2(),s=requireBrowserifyRsa(),a=requireBrowser$a(),h=requireWithPublic(),v=requireSafeBuffer$1().Buffer;privateDecrypt=function(D,mi,gi){var bi;D.padding?bi=D.padding:gi?bi=1:bi=4;var Ri=r(D),Ti=Ri.modulus.byteLength();if(mi.length>Ti||new n(mi).cmp(Ri.modulus)>=0)throw new Error("decryption error");var Ii;gi?Ii=h(new n(mi),Ri):Ii=s(mi,Ri);var qi=v.alloc(Ti-Ii.length);if(Ii=v.concat([qi,Ii],Ti),bi===4)return hi(Ri,Ii);if(bi===1)return u(Ri,Ii,gi);if(bi===3)return Ii;throw new Error("unknown padding")};function hi(vi,D){var mi=vi.modulus.byteLength(),gi=a("sha1").update(v.alloc(0)).digest(),bi=gi.length;if(D[0]!==0)throw new Error("decryption error");var Ri=D.slice(1,bi+1),Ti=D.slice(bi+1),Ii=i(Ri,t(Ti,bi)),qi=i(Ti,t(Ii,mi-bi-1));if(l(gi,qi.slice(0,bi)))throw new Error("decryption error");for(var Oi=bi;qi[Oi]===0;)Oi++;if(qi[Oi++]!==1)throw new Error("decryption error");return qi.slice(Oi)}function u(vi,D,mi){for(var gi=D.slice(0,2),bi=2,Ri=0;D[bi++]!==0;)if(bi>=D.length){Ri++;break}var Ti=D.slice(2,bi-1);if((gi.toString("hex")!=="0002"&&!mi||gi.toString("hex")!=="0001"&&mi)&&Ri++,Ti.length<8&&Ri++,Ri)throw new Error("decryption error");return D.slice(bi)}function l(vi,D){vi=v.from(vi),D=v.from(D);var mi=0,gi=vi.length;vi.length!==D.length&&(mi++,gi=Math.min(vi.length,D.length));for(var bi=-1;++bi<gi;)mi+=vi[bi]^D[bi];return mi}return privateDecrypt}var hasRequiredBrowser$2;function requireBrowser$2(){return hasRequiredBrowser$2||(hasRequiredBrowser$2=1,function(r){r.publicEncrypt=requirePublicEncrypt(),r.privateDecrypt=requirePrivateDecrypt(),r.privateEncrypt=function(i,n){return r.publicEncrypt(i,n,!0)},r.publicDecrypt=function(i,n){return r.privateDecrypt(i,n,!0)}}(browser$2)),browser$2}var browser$1={},hasRequiredBrowser$1;function requireBrowser$1(){if(hasRequiredBrowser$1)return browser$1;hasRequiredBrowser$1=1;function r(){throw new Error(`secure random number generation not supported by this browser
102
+ use chrome, FireFox or Internet Explorer 11`)}var t=requireSafeBuffer$1(),i=requireBrowser$b(),n=t.Buffer,s=t.kMaxLength,a=commonjsGlobal.crypto||commonjsGlobal.msCrypto,h=Math.pow(2,32)-1;function v(D,mi){if(typeof D!="number"||D!==D)throw new TypeError("offset must be a number");if(D>h||D<0)throw new TypeError("offset must be a uint32");if(D>s||D>mi)throw new RangeError("offset out of range")}function hi(D,mi,gi){if(typeof D!="number"||D!==D)throw new TypeError("size must be a number");if(D>h||D<0)throw new TypeError("size must be a uint32");if(D+mi>gi||D>s)throw new RangeError("buffer too small")}a&&a.getRandomValues||!process$1.browser?(browser$1.randomFill=u,browser$1.randomFillSync=vi):(browser$1.randomFill=r,browser$1.randomFillSync=r);function u(D,mi,gi,bi){if(!n.isBuffer(D)&&!(D instanceof commonjsGlobal.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if(typeof mi=="function")bi=mi,mi=0,gi=D.length;else if(typeof gi=="function")bi=gi,gi=D.length-mi;else if(typeof bi!="function")throw new TypeError('"cb" argument must be a function');return v(mi,D.length),hi(gi,mi,D.length),l(D,mi,gi,bi)}function l(D,mi,gi,bi){if(process$1.browser){var Ri=D.buffer,Ti=new Uint8Array(Ri,mi,gi);if(a.getRandomValues(Ti),bi){process$1.nextTick(function(){bi(null,D)});return}return D}if(bi){i(gi,function(qi,Oi){if(qi)return bi(qi);Oi.copy(D,mi),bi(null,D)});return}var Ii=i(gi);return Ii.copy(D,mi),D}function vi(D,mi,gi){if(typeof mi>"u"&&(mi=0),!n.isBuffer(D)&&!(D instanceof commonjsGlobal.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');return v(mi,D.length),gi===void 0&&(gi=D.length-mi),hi(gi,mi,D.length),l(D,mi,gi)}return browser$1}var hasRequiredCryptoBrowserify;function requireCryptoBrowserify(){if(hasRequiredCryptoBrowserify)return cryptoBrowserify;hasRequiredCryptoBrowserify=1,cryptoBrowserify.randomBytes=cryptoBrowserify.rng=cryptoBrowserify.pseudoRandomBytes=cryptoBrowserify.prng=requireBrowser$b(),cryptoBrowserify.createHash=cryptoBrowserify.Hash=requireBrowser$a(),cryptoBrowserify.createHmac=cryptoBrowserify.Hmac=requireBrowser$9();var r=requireAlgos(),t=Object.keys(r),i=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(t);cryptoBrowserify.getHashes=function(){return i};var n=requireBrowser$8();cryptoBrowserify.pbkdf2=n.pbkdf2,cryptoBrowserify.pbkdf2Sync=n.pbkdf2Sync;var s=requireBrowser$6();cryptoBrowserify.Cipher=s.Cipher,cryptoBrowserify.createCipher=s.createCipher,cryptoBrowserify.Cipheriv=s.Cipheriv,cryptoBrowserify.createCipheriv=s.createCipheriv,cryptoBrowserify.Decipher=s.Decipher,cryptoBrowserify.createDecipher=s.createDecipher,cryptoBrowserify.Decipheriv=s.Decipheriv,cryptoBrowserify.createDecipheriv=s.createDecipheriv,cryptoBrowserify.getCiphers=s.getCiphers,cryptoBrowserify.listCiphers=s.listCiphers;var a=requireBrowser$5();cryptoBrowserify.DiffieHellmanGroup=a.DiffieHellmanGroup,cryptoBrowserify.createDiffieHellmanGroup=a.createDiffieHellmanGroup,cryptoBrowserify.getDiffieHellman=a.getDiffieHellman,cryptoBrowserify.createDiffieHellman=a.createDiffieHellman,cryptoBrowserify.DiffieHellman=a.DiffieHellman;var h=requireBrowser$4();cryptoBrowserify.createSign=h.createSign,cryptoBrowserify.Sign=h.Sign,cryptoBrowserify.createVerify=h.createVerify,cryptoBrowserify.Verify=h.Verify,cryptoBrowserify.createECDH=requireBrowser$3();var v=requireBrowser$2();cryptoBrowserify.publicEncrypt=v.publicEncrypt,cryptoBrowserify.privateEncrypt=v.privateEncrypt,cryptoBrowserify.publicDecrypt=v.publicDecrypt,cryptoBrowserify.privateDecrypt=v.privateDecrypt;var hi=requireBrowser$1();return cryptoBrowserify.randomFill=hi.randomFill,cryptoBrowserify.randomFillSync=hi.randomFillSync,cryptoBrowserify.createCredentials=function(){throw new Error(`sorry, createCredentials is not implemented yet
103
+ we accept pull requests
104
+ https://github.com/browserify/crypto-browserify`)},cryptoBrowserify.constants={DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,ALPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6},cryptoBrowserify}var core=core$1.exports,hasRequiredCore;function requireCore(){return hasRequiredCore||(hasRequiredCore=1,function(r,t){(function(i,n){r.exports=n()})(core,function(){var i=i||function(n,s){var a;if(typeof window<"u"&&window.crypto&&(a=window.crypto),typeof self<"u"&&self.crypto&&(a=self.crypto),typeof globalThis<"u"&&globalThis.crypto&&(a=globalThis.crypto),!a&&typeof window<"u"&&window.msCrypto&&(a=window.msCrypto),!a&&typeof commonjsGlobal<"u"&&commonjsGlobal.crypto&&(a=commonjsGlobal.crypto),!a&&typeof commonjsRequire=="function")try{a=requireCryptoBrowserify()}catch{}var h=function(){if(a){if(typeof a.getRandomValues=="function")try{return a.getRandomValues(new Uint32Array(1))[0]}catch{}if(typeof a.randomBytes=="function")try{return a.randomBytes(4).readInt32LE()}catch{}}throw new Error("Native crypto module could not be used to get secure random number.")},v=Object.create||function(){function Ii(){}return function(qi){var Oi;return Ii.prototype=qi,Oi=new Ii,Ii.prototype=null,Oi}}(),hi={},u=hi.lib={},l=u.Base=function(){return{extend:function(Ii){var qi=v(this);return Ii&&qi.mixIn(Ii),(!qi.hasOwnProperty("init")||this.init===qi.init)&&(qi.init=function(){qi.$super.init.apply(this,arguments)}),qi.init.prototype=qi,qi.$super=this,qi},create:function(){var Ii=this.extend();return Ii.init.apply(Ii,arguments),Ii},init:function(){},mixIn:function(Ii){for(var qi in Ii)Ii.hasOwnProperty(qi)&&(this[qi]=Ii[qi]);Ii.hasOwnProperty("toString")&&(this.toString=Ii.toString)},clone:function(){return this.init.prototype.extend(this)}}}(),vi=u.WordArray=l.extend({init:function(Ii,qi){Ii=this.words=Ii||[],qi!=s?this.sigBytes=qi:this.sigBytes=Ii.length*4},toString:function(Ii){return(Ii||mi).stringify(this)},concat:function(Ii){var qi=this.words,Oi=Ii.words,ki=this.sigBytes,Li=Ii.sigBytes;if(this.clamp(),ki%4)for(var ji=0;ji<Li;ji++){var Hi=Oi[ji>>>2]>>>24-ji%4*8&255;qi[ki+ji>>>2]|=Hi<<24-(ki+ji)%4*8}else for(var Ui=0;Ui<Li;Ui+=4)qi[ki+Ui>>>2]=Oi[Ui>>>2];return this.sigBytes+=Li,this},clamp:function(){var Ii=this.words,qi=this.sigBytes;Ii[qi>>>2]&=4294967295<<32-qi%4*8,Ii.length=n.ceil(qi/4)},clone:function(){var Ii=l.clone.call(this);return Ii.words=this.words.slice(0),Ii},random:function(Ii){for(var qi=[],Oi=0;Oi<Ii;Oi+=4)qi.push(h());return new vi.init(qi,Ii)}}),D=hi.enc={},mi=D.Hex={stringify:function(Ii){for(var qi=Ii.words,Oi=Ii.sigBytes,ki=[],Li=0;Li<Oi;Li++){var ji=qi[Li>>>2]>>>24-Li%4*8&255;ki.push((ji>>>4).toString(16)),ki.push((ji&15).toString(16))}return ki.join("")},parse:function(Ii){for(var qi=Ii.length,Oi=[],ki=0;ki<qi;ki+=2)Oi[ki>>>3]|=parseInt(Ii.substr(ki,2),16)<<24-ki%8*4;return new vi.init(Oi,qi/2)}},gi=D.Latin1={stringify:function(Ii){for(var qi=Ii.words,Oi=Ii.sigBytes,ki=[],Li=0;Li<Oi;Li++){var ji=qi[Li>>>2]>>>24-Li%4*8&255;ki.push(String.fromCharCode(ji))}return ki.join("")},parse:function(Ii){for(var qi=Ii.length,Oi=[],ki=0;ki<qi;ki++)Oi[ki>>>2]|=(Ii.charCodeAt(ki)&255)<<24-ki%4*8;return new vi.init(Oi,qi)}},bi=D.Utf8={stringify:function(Ii){try{return decodeURIComponent(escape(gi.stringify(Ii)))}catch{throw new Error("Malformed UTF-8 data")}},parse:function(Ii){return gi.parse(unescape(encodeURIComponent(Ii)))}},Ri=u.BufferedBlockAlgorithm=l.extend({reset:function(){this._data=new vi.init,this._nDataBytes=0},_append:function(Ii){typeof Ii=="string"&&(Ii=bi.parse(Ii)),this._data.concat(Ii),this._nDataBytes+=Ii.sigBytes},_process:function(Ii){var qi,Oi=this._data,ki=Oi.words,Li=Oi.sigBytes,ji=this.blockSize,Hi=ji*4,Ui=Li/Hi;Ii?Ui=n.ceil(Ui):Ui=n.max((Ui|0)-this._minBufferSize,0);var Qi=Ui*ji,$i=n.min(Qi*4,Li);if(Qi){for(var wi=0;wi<Qi;wi+=ji)this._doProcessBlock(ki,wi);qi=ki.splice(0,Qi),Oi.sigBytes-=$i}return new vi.init(qi,$i)},clone:function(){var Ii=l.clone.call(this);return Ii._data=this._data.clone(),Ii},_minBufferSize:0});u.Hasher=Ri.extend({cfg:l.extend(),init:function(Ii){this.cfg=this.cfg.extend(Ii),this.reset()},reset:function(){Ri.reset.call(this),this._doReset()},update:function(Ii){return this._append(Ii),this._process(),this},finalize:function(Ii){Ii&&this._append(Ii);var qi=this._doFinalize();return qi},blockSize:16,_createHelper:function(Ii){return function(qi,Oi){return new Ii.init(Oi).finalize(qi)}},_createHmacHelper:function(Ii){return function(qi,Oi){return new Ti.HMAC.init(Ii,Oi).finalize(qi)}}});var Ti=hi.algo={};return hi}(Math);return i})}(core$1)),core$1.exports}var x64Core$1={exports:{}},x64Core=x64Core$1.exports,hasRequiredX64Core;function requireX64Core(){return hasRequiredX64Core||(hasRequiredX64Core=1,function(r,t){(function(i,n){r.exports=n(requireCore())})(x64Core,function(i){return function(n){var s=i,a=s.lib,h=a.Base,v=a.WordArray,hi=s.x64={};hi.Word=h.extend({init:function(u,l){this.high=u,this.low=l}}),hi.WordArray=h.extend({init:function(u,l){u=this.words=u||[],l!=n?this.sigBytes=l:this.sigBytes=u.length*8},toX32:function(){for(var u=this.words,l=u.length,vi=[],D=0;D<l;D++){var mi=u[D];vi.push(mi.high),vi.push(mi.low)}return v.create(vi,this.sigBytes)},clone:function(){for(var u=h.clone.call(this),l=u.words=this.words.slice(0),vi=l.length,D=0;D<vi;D++)l[D]=l[D].clone();return u}})}(),i})}(x64Core$1)),x64Core$1.exports}var libTypedarrays$1={exports:{}},libTypedarrays=libTypedarrays$1.exports,hasRequiredLibTypedarrays;function requireLibTypedarrays(){return hasRequiredLibTypedarrays||(hasRequiredLibTypedarrays=1,function(r,t){(function(i,n){r.exports=n(requireCore())})(libTypedarrays,function(i){return function(){if(typeof ArrayBuffer=="function"){var n=i,s=n.lib,a=s.WordArray,h=a.init,v=a.init=function(hi){if(hi instanceof ArrayBuffer&&(hi=new Uint8Array(hi)),(hi instanceof Int8Array||typeof Uint8ClampedArray<"u"&&hi instanceof Uint8ClampedArray||hi instanceof Int16Array||hi instanceof Uint16Array||hi instanceof Int32Array||hi instanceof Uint32Array||hi instanceof Float32Array||hi instanceof Float64Array)&&(hi=new Uint8Array(hi.buffer,hi.byteOffset,hi.byteLength)),hi instanceof Uint8Array){for(var u=hi.byteLength,l=[],vi=0;vi<u;vi++)l[vi>>>2]|=hi[vi]<<24-vi%4*8;h.call(this,l,u)}else h.apply(this,arguments)};v.prototype=a}}(),i.lib.WordArray})}(libTypedarrays$1)),libTypedarrays$1.exports}var encUtf16$1={exports:{}},encUtf16=encUtf16$1.exports,hasRequiredEncUtf16;function requireEncUtf16(){return hasRequiredEncUtf16||(hasRequiredEncUtf16=1,function(r,t){(function(i,n){r.exports=n(requireCore())})(encUtf16,function(i){return function(){var n=i,s=n.lib,a=s.WordArray,h=n.enc;h.Utf16=h.Utf16BE={stringify:function(hi){for(var u=hi.words,l=hi.sigBytes,vi=[],D=0;D<l;D+=2){var mi=u[D>>>2]>>>16-D%4*8&65535;vi.push(String.fromCharCode(mi))}return vi.join("")},parse:function(hi){for(var u=hi.length,l=[],vi=0;vi<u;vi++)l[vi>>>1]|=hi.charCodeAt(vi)<<16-vi%2*16;return a.create(l,u*2)}},h.Utf16LE={stringify:function(hi){for(var u=hi.words,l=hi.sigBytes,vi=[],D=0;D<l;D+=2){var mi=v(u[D>>>2]>>>16-D%4*8&65535);vi.push(String.fromCharCode(mi))}return vi.join("")},parse:function(hi){for(var u=hi.length,l=[],vi=0;vi<u;vi++)l[vi>>>1]|=v(hi.charCodeAt(vi)<<16-vi%2*16);return a.create(l,u*2)}};function v(hi){return hi<<8&4278255360|hi>>>8&16711935}}(),i.enc.Utf16})}(encUtf16$1)),encUtf16$1.exports}var encBase64$1={exports:{}},encBase64=encBase64$1.exports,hasRequiredEncBase64;function requireEncBase64(){return hasRequiredEncBase64||(hasRequiredEncBase64=1,function(r,t){(function(i,n){r.exports=n(requireCore())})(encBase64,function(i){return function(){var n=i,s=n.lib,a=s.WordArray,h=n.enc;h.Base64={stringify:function(hi){var u=hi.words,l=hi.sigBytes,vi=this._map;hi.clamp();for(var D=[],mi=0;mi<l;mi+=3)for(var gi=u[mi>>>2]>>>24-mi%4*8&255,bi=u[mi+1>>>2]>>>24-(mi+1)%4*8&255,Ri=u[mi+2>>>2]>>>24-(mi+2)%4*8&255,Ti=gi<<16|bi<<8|Ri,Ii=0;Ii<4&&mi+Ii*.75<l;Ii++)D.push(vi.charAt(Ti>>>6*(3-Ii)&63));var qi=vi.charAt(64);if(qi)for(;D.length%4;)D.push(qi);return D.join("")},parse:function(hi){var u=hi.length,l=this._map,vi=this._reverseMap;if(!vi){vi=this._reverseMap=[];for(var D=0;D<l.length;D++)vi[l.charCodeAt(D)]=D}var mi=l.charAt(64);if(mi){var gi=hi.indexOf(mi);gi!==-1&&(u=gi)}return v(hi,u,vi)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="};function v(hi,u,l){for(var vi=[],D=0,mi=0;mi<u;mi++)if(mi%4){var gi=l[hi.charCodeAt(mi-1)]<<mi%4*2,bi=l[hi.charCodeAt(mi)]>>>6-mi%4*2,Ri=gi|bi;vi[D>>>2]|=Ri<<24-D%4*8,D++}return a.create(vi,D)}}(),i.enc.Base64})}(encBase64$1)),encBase64$1.exports}var encBase64url$1={exports:{}},encBase64url=encBase64url$1.exports,hasRequiredEncBase64url;function requireEncBase64url(){return hasRequiredEncBase64url||(hasRequiredEncBase64url=1,function(r,t){(function(i,n){r.exports=n(requireCore())})(encBase64url,function(i){return function(){var n=i,s=n.lib,a=s.WordArray,h=n.enc;h.Base64url={stringify:function(hi,u){u===void 0&&(u=!0);var l=hi.words,vi=hi.sigBytes,D=u?this._safe_map:this._map;hi.clamp();for(var mi=[],gi=0;gi<vi;gi+=3)for(var bi=l[gi>>>2]>>>24-gi%4*8&255,Ri=l[gi+1>>>2]>>>24-(gi+1)%4*8&255,Ti=l[gi+2>>>2]>>>24-(gi+2)%4*8&255,Ii=bi<<16|Ri<<8|Ti,qi=0;qi<4&&gi+qi*.75<vi;qi++)mi.push(D.charAt(Ii>>>6*(3-qi)&63));var Oi=D.charAt(64);if(Oi)for(;mi.length%4;)mi.push(Oi);return mi.join("")},parse:function(hi,u){u===void 0&&(u=!0);var l=hi.length,vi=u?this._safe_map:this._map,D=this._reverseMap;if(!D){D=this._reverseMap=[];for(var mi=0;mi<vi.length;mi++)D[vi.charCodeAt(mi)]=mi}var gi=vi.charAt(64);if(gi){var bi=hi.indexOf(gi);bi!==-1&&(l=bi)}return v(hi,l,D)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",_safe_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"};function v(hi,u,l){for(var vi=[],D=0,mi=0;mi<u;mi++)if(mi%4){var gi=l[hi.charCodeAt(mi-1)]<<mi%4*2,bi=l[hi.charCodeAt(mi)]>>>6-mi%4*2,Ri=gi|bi;vi[D>>>2]|=Ri<<24-D%4*8,D++}return a.create(vi,D)}}(),i.enc.Base64url})}(encBase64url$1)),encBase64url$1.exports}var md5$1={exports:{}},md5=md5$1.exports,hasRequiredMd5;function requireMd5(){return hasRequiredMd5||(hasRequiredMd5=1,function(r,t){(function(i,n){r.exports=n(requireCore())})(md5,function(i){return function(n){var s=i,a=s.lib,h=a.WordArray,v=a.Hasher,hi=s.algo,u=[];(function(){for(var bi=0;bi<64;bi++)u[bi]=n.abs(n.sin(bi+1))*4294967296|0})();var l=hi.MD5=v.extend({_doReset:function(){this._hash=new h.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(bi,Ri){for(var Ti=0;Ti<16;Ti++){var Ii=Ri+Ti,qi=bi[Ii];bi[Ii]=(qi<<8|qi>>>24)&16711935|(qi<<24|qi>>>8)&4278255360}var Oi=this._hash.words,ki=bi[Ri+0],Li=bi[Ri+1],ji=bi[Ri+2],Hi=bi[Ri+3],Ui=bi[Ri+4],Qi=bi[Ri+5],$i=bi[Ri+6],wi=bi[Ri+7],xi=bi[Ri+8],yi=bi[Ri+9],Ei=bi[Ri+10],Ci=bi[Ri+11],Ni=bi[Ri+12],Fi=bi[Ri+13],Mi=bi[Ri+14],Si=bi[Ri+15],Ai=Oi[0],_i=Oi[1],Bi=Oi[2],Pi=Oi[3];Ai=vi(Ai,_i,Bi,Pi,ki,7,u[0]),Pi=vi(Pi,Ai,_i,Bi,Li,12,u[1]),Bi=vi(Bi,Pi,Ai,_i,ji,17,u[2]),_i=vi(_i,Bi,Pi,Ai,Hi,22,u[3]),Ai=vi(Ai,_i,Bi,Pi,Ui,7,u[4]),Pi=vi(Pi,Ai,_i,Bi,Qi,12,u[5]),Bi=vi(Bi,Pi,Ai,_i,$i,17,u[6]),_i=vi(_i,Bi,Pi,Ai,wi,22,u[7]),Ai=vi(Ai,_i,Bi,Pi,xi,7,u[8]),Pi=vi(Pi,Ai,_i,Bi,yi,12,u[9]),Bi=vi(Bi,Pi,Ai,_i,Ei,17,u[10]),_i=vi(_i,Bi,Pi,Ai,Ci,22,u[11]),Ai=vi(Ai,_i,Bi,Pi,Ni,7,u[12]),Pi=vi(Pi,Ai,_i,Bi,Fi,12,u[13]),Bi=vi(Bi,Pi,Ai,_i,Mi,17,u[14]),_i=vi(_i,Bi,Pi,Ai,Si,22,u[15]),Ai=D(Ai,_i,Bi,Pi,Li,5,u[16]),Pi=D(Pi,Ai,_i,Bi,$i,9,u[17]),Bi=D(Bi,Pi,Ai,_i,Ci,14,u[18]),_i=D(_i,Bi,Pi,Ai,ki,20,u[19]),Ai=D(Ai,_i,Bi,Pi,Qi,5,u[20]),Pi=D(Pi,Ai,_i,Bi,Ei,9,u[21]),Bi=D(Bi,Pi,Ai,_i,Si,14,u[22]),_i=D(_i,Bi,Pi,Ai,Ui,20,u[23]),Ai=D(Ai,_i,Bi,Pi,yi,5,u[24]),Pi=D(Pi,Ai,_i,Bi,Mi,9,u[25]),Bi=D(Bi,Pi,Ai,_i,Hi,14,u[26]),_i=D(_i,Bi,Pi,Ai,xi,20,u[27]),Ai=D(Ai,_i,Bi,Pi,Fi,5,u[28]),Pi=D(Pi,Ai,_i,Bi,ji,9,u[29]),Bi=D(Bi,Pi,Ai,_i,wi,14,u[30]),_i=D(_i,Bi,Pi,Ai,Ni,20,u[31]),Ai=mi(Ai,_i,Bi,Pi,Qi,4,u[32]),Pi=mi(Pi,Ai,_i,Bi,xi,11,u[33]),Bi=mi(Bi,Pi,Ai,_i,Ci,16,u[34]),_i=mi(_i,Bi,Pi,Ai,Mi,23,u[35]),Ai=mi(Ai,_i,Bi,Pi,Li,4,u[36]),Pi=mi(Pi,Ai,_i,Bi,Ui,11,u[37]),Bi=mi(Bi,Pi,Ai,_i,wi,16,u[38]),_i=mi(_i,Bi,Pi,Ai,Ei,23,u[39]),Ai=mi(Ai,_i,Bi,Pi,Fi,4,u[40]),Pi=mi(Pi,Ai,_i,Bi,ki,11,u[41]),Bi=mi(Bi,Pi,Ai,_i,Hi,16,u[42]),_i=mi(_i,Bi,Pi,Ai,$i,23,u[43]),Ai=mi(Ai,_i,Bi,Pi,yi,4,u[44]),Pi=mi(Pi,Ai,_i,Bi,Ni,11,u[45]),Bi=mi(Bi,Pi,Ai,_i,Si,16,u[46]),_i=mi(_i,Bi,Pi,Ai,ji,23,u[47]),Ai=gi(Ai,_i,Bi,Pi,ki,6,u[48]),Pi=gi(Pi,Ai,_i,Bi,wi,10,u[49]),Bi=gi(Bi,Pi,Ai,_i,Mi,15,u[50]),_i=gi(_i,Bi,Pi,Ai,Qi,21,u[51]),Ai=gi(Ai,_i,Bi,Pi,Ni,6,u[52]),Pi=gi(Pi,Ai,_i,Bi,Hi,10,u[53]),Bi=gi(Bi,Pi,Ai,_i,Ei,15,u[54]),_i=gi(_i,Bi,Pi,Ai,Li,21,u[55]),Ai=gi(Ai,_i,Bi,Pi,xi,6,u[56]),Pi=gi(Pi,Ai,_i,Bi,Si,10,u[57]),Bi=gi(Bi,Pi,Ai,_i,$i,15,u[58]),_i=gi(_i,Bi,Pi,Ai,Fi,21,u[59]),Ai=gi(Ai,_i,Bi,Pi,Ui,6,u[60]),Pi=gi(Pi,Ai,_i,Bi,Ci,10,u[61]),Bi=gi(Bi,Pi,Ai,_i,ji,15,u[62]),_i=gi(_i,Bi,Pi,Ai,yi,21,u[63]),Oi[0]=Oi[0]+Ai|0,Oi[1]=Oi[1]+_i|0,Oi[2]=Oi[2]+Bi|0,Oi[3]=Oi[3]+Pi|0},_doFinalize:function(){var bi=this._data,Ri=bi.words,Ti=this._nDataBytes*8,Ii=bi.sigBytes*8;Ri[Ii>>>5]|=128<<24-Ii%32;var qi=n.floor(Ti/4294967296),Oi=Ti;Ri[(Ii+64>>>9<<4)+15]=(qi<<8|qi>>>24)&16711935|(qi<<24|qi>>>8)&4278255360,Ri[(Ii+64>>>9<<4)+14]=(Oi<<8|Oi>>>24)&16711935|(Oi<<24|Oi>>>8)&4278255360,bi.sigBytes=(Ri.length+1)*4,this._process();for(var ki=this._hash,Li=ki.words,ji=0;ji<4;ji++){var Hi=Li[ji];Li[ji]=(Hi<<8|Hi>>>24)&16711935|(Hi<<24|Hi>>>8)&4278255360}return ki},clone:function(){var bi=v.clone.call(this);return bi._hash=this._hash.clone(),bi}});function vi(bi,Ri,Ti,Ii,qi,Oi,ki){var Li=bi+(Ri&Ti|~Ri&Ii)+qi+ki;return(Li<<Oi|Li>>>32-Oi)+Ri}function D(bi,Ri,Ti,Ii,qi,Oi,ki){var Li=bi+(Ri&Ii|Ti&~Ii)+qi+ki;return(Li<<Oi|Li>>>32-Oi)+Ri}function mi(bi,Ri,Ti,Ii,qi,Oi,ki){var Li=bi+(Ri^Ti^Ii)+qi+ki;return(Li<<Oi|Li>>>32-Oi)+Ri}function gi(bi,Ri,Ti,Ii,qi,Oi,ki){var Li=bi+(Ti^(Ri|~Ii))+qi+ki;return(Li<<Oi|Li>>>32-Oi)+Ri}s.MD5=v._createHelper(l),s.HmacMD5=v._createHmacHelper(l)}(Math),i.MD5})}(md5$1)),md5$1.exports}var sha1$1={exports:{}},sha1=sha1$1.exports,hasRequiredSha1;function requireSha1(){return hasRequiredSha1||(hasRequiredSha1=1,function(r,t){(function(i,n){r.exports=n(requireCore())})(sha1,function(i){return function(){var n=i,s=n.lib,a=s.WordArray,h=s.Hasher,v=n.algo,hi=[],u=v.SHA1=h.extend({_doReset:function(){this._hash=new a.init([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(l,vi){for(var D=this._hash.words,mi=D[0],gi=D[1],bi=D[2],Ri=D[3],Ti=D[4],Ii=0;Ii<80;Ii++){if(Ii<16)hi[Ii]=l[vi+Ii]|0;else{var qi=hi[Ii-3]^hi[Ii-8]^hi[Ii-14]^hi[Ii-16];hi[Ii]=qi<<1|qi>>>31}var Oi=(mi<<5|mi>>>27)+Ti+hi[Ii];Ii<20?Oi+=(gi&bi|~gi&Ri)+1518500249:Ii<40?Oi+=(gi^bi^Ri)+1859775393:Ii<60?Oi+=(gi&bi|gi&Ri|bi&Ri)-1894007588:Oi+=(gi^bi^Ri)-899497514,Ti=Ri,Ri=bi,bi=gi<<30|gi>>>2,gi=mi,mi=Oi}D[0]=D[0]+mi|0,D[1]=D[1]+gi|0,D[2]=D[2]+bi|0,D[3]=D[3]+Ri|0,D[4]=D[4]+Ti|0},_doFinalize:function(){var l=this._data,vi=l.words,D=this._nDataBytes*8,mi=l.sigBytes*8;return vi[mi>>>5]|=128<<24-mi%32,vi[(mi+64>>>9<<4)+14]=Math.floor(D/4294967296),vi[(mi+64>>>9<<4)+15]=D,l.sigBytes=vi.length*4,this._process(),this._hash},clone:function(){var l=h.clone.call(this);return l._hash=this._hash.clone(),l}});n.SHA1=h._createHelper(u),n.HmacSHA1=h._createHmacHelper(u)}(),i.SHA1})}(sha1$1)),sha1$1.exports}var sha256$1={exports:{}},sha256=sha256$1.exports,hasRequiredSha256;function requireSha256(){return hasRequiredSha256||(hasRequiredSha256=1,function(r,t){(function(i,n){r.exports=n(requireCore())})(sha256,function(i){return function(n){var s=i,a=s.lib,h=a.WordArray,v=a.Hasher,hi=s.algo,u=[],l=[];(function(){function mi(Ti){for(var Ii=n.sqrt(Ti),qi=2;qi<=Ii;qi++)if(!(Ti%qi))return!1;return!0}function gi(Ti){return(Ti-(Ti|0))*4294967296|0}for(var bi=2,Ri=0;Ri<64;)mi(bi)&&(Ri<8&&(u[Ri]=gi(n.pow(bi,1/2))),l[Ri]=gi(n.pow(bi,1/3)),Ri++),bi++})();var vi=[],D=hi.SHA256=v.extend({_doReset:function(){this._hash=new h.init(u.slice(0))},_doProcessBlock:function(mi,gi){for(var bi=this._hash.words,Ri=bi[0],Ti=bi[1],Ii=bi[2],qi=bi[3],Oi=bi[4],ki=bi[5],Li=bi[6],ji=bi[7],Hi=0;Hi<64;Hi++){if(Hi<16)vi[Hi]=mi[gi+Hi]|0;else{var Ui=vi[Hi-15],Qi=(Ui<<25|Ui>>>7)^(Ui<<14|Ui>>>18)^Ui>>>3,$i=vi[Hi-2],wi=($i<<15|$i>>>17)^($i<<13|$i>>>19)^$i>>>10;vi[Hi]=Qi+vi[Hi-7]+wi+vi[Hi-16]}var xi=Oi&ki^~Oi&Li,yi=Ri&Ti^Ri&Ii^Ti&Ii,Ei=(Ri<<30|Ri>>>2)^(Ri<<19|Ri>>>13)^(Ri<<10|Ri>>>22),Ci=(Oi<<26|Oi>>>6)^(Oi<<21|Oi>>>11)^(Oi<<7|Oi>>>25),Ni=ji+Ci+xi+l[Hi]+vi[Hi],Fi=Ei+yi;ji=Li,Li=ki,ki=Oi,Oi=qi+Ni|0,qi=Ii,Ii=Ti,Ti=Ri,Ri=Ni+Fi|0}bi[0]=bi[0]+Ri|0,bi[1]=bi[1]+Ti|0,bi[2]=bi[2]+Ii|0,bi[3]=bi[3]+qi|0,bi[4]=bi[4]+Oi|0,bi[5]=bi[5]+ki|0,bi[6]=bi[6]+Li|0,bi[7]=bi[7]+ji|0},_doFinalize:function(){var mi=this._data,gi=mi.words,bi=this._nDataBytes*8,Ri=mi.sigBytes*8;return gi[Ri>>>5]|=128<<24-Ri%32,gi[(Ri+64>>>9<<4)+14]=n.floor(bi/4294967296),gi[(Ri+64>>>9<<4)+15]=bi,mi.sigBytes=gi.length*4,this._process(),this._hash},clone:function(){var mi=v.clone.call(this);return mi._hash=this._hash.clone(),mi}});s.SHA256=v._createHelper(D),s.HmacSHA256=v._createHmacHelper(D)}(Math),i.SHA256})}(sha256$1)),sha256$1.exports}var sha224$1={exports:{}},sha224=sha224$1.exports,hasRequiredSha224;function requireSha224(){return hasRequiredSha224||(hasRequiredSha224=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireSha256())})(sha224,function(i){return function(){var n=i,s=n.lib,a=s.WordArray,h=n.algo,v=h.SHA256,hi=h.SHA224=v.extend({_doReset:function(){this._hash=new a.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var u=v._doFinalize.call(this);return u.sigBytes-=4,u}});n.SHA224=v._createHelper(hi),n.HmacSHA224=v._createHmacHelper(hi)}(),i.SHA224})}(sha224$1)),sha224$1.exports}var sha512$1={exports:{}},sha512=sha512$1.exports,hasRequiredSha512;function requireSha512(){return hasRequiredSha512||(hasRequiredSha512=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireX64Core())})(sha512,function(i){return function(){var n=i,s=n.lib,a=s.Hasher,h=n.x64,v=h.Word,hi=h.WordArray,u=n.algo;function l(){return v.create.apply(v,arguments)}var vi=[l(1116352408,3609767458),l(1899447441,602891725),l(3049323471,3964484399),l(3921009573,2173295548),l(961987163,4081628472),l(1508970993,3053834265),l(2453635748,2937671579),l(2870763221,3664609560),l(3624381080,2734883394),l(310598401,1164996542),l(607225278,1323610764),l(1426881987,3590304994),l(1925078388,4068182383),l(2162078206,991336113),l(2614888103,633803317),l(3248222580,3479774868),l(3835390401,2666613458),l(4022224774,944711139),l(264347078,2341262773),l(604807628,2007800933),l(770255983,1495990901),l(1249150122,1856431235),l(1555081692,3175218132),l(1996064986,2198950837),l(2554220882,3999719339),l(2821834349,766784016),l(2952996808,2566594879),l(3210313671,3203337956),l(3336571891,1034457026),l(3584528711,2466948901),l(113926993,3758326383),l(338241895,168717936),l(666307205,1188179964),l(773529912,1546045734),l(1294757372,1522805485),l(1396182291,2643833823),l(1695183700,2343527390),l(1986661051,1014477480),l(2177026350,1206759142),l(2456956037,344077627),l(2730485921,1290863460),l(2820302411,3158454273),l(3259730800,3505952657),l(3345764771,106217008),l(3516065817,3606008344),l(3600352804,1432725776),l(4094571909,1467031594),l(275423344,851169720),l(430227734,3100823752),l(506948616,1363258195),l(659060556,3750685593),l(883997877,3785050280),l(958139571,3318307427),l(1322822218,3812723403),l(1537002063,2003034995),l(1747873779,3602036899),l(1955562222,1575990012),l(2024104815,1125592928),l(2227730452,2716904306),l(2361852424,442776044),l(2428436474,593698344),l(2756734187,3733110249),l(3204031479,2999351573),l(3329325298,3815920427),l(3391569614,3928383900),l(3515267271,566280711),l(3940187606,3454069534),l(4118630271,4000239992),l(116418474,1914138554),l(174292421,2731055270),l(289380356,3203993006),l(460393269,320620315),l(685471733,587496836),l(852142971,1086792851),l(1017036298,365543100),l(1126000580,2618297676),l(1288033470,3409855158),l(1501505948,4234509866),l(1607167915,987167468),l(1816402316,1246189591)],D=[];(function(){for(var gi=0;gi<80;gi++)D[gi]=l()})();var mi=u.SHA512=a.extend({_doReset:function(){this._hash=new hi.init([new v.init(1779033703,4089235720),new v.init(3144134277,2227873595),new v.init(1013904242,4271175723),new v.init(2773480762,1595750129),new v.init(1359893119,2917565137),new v.init(2600822924,725511199),new v.init(528734635,4215389547),new v.init(1541459225,327033209)])},_doProcessBlock:function(gi,bi){for(var Ri=this._hash.words,Ti=Ri[0],Ii=Ri[1],qi=Ri[2],Oi=Ri[3],ki=Ri[4],Li=Ri[5],ji=Ri[6],Hi=Ri[7],Ui=Ti.high,Qi=Ti.low,$i=Ii.high,wi=Ii.low,xi=qi.high,yi=qi.low,Ei=Oi.high,Ci=Oi.low,Ni=ki.high,Fi=ki.low,Mi=Li.high,Si=Li.low,Ai=ji.high,_i=ji.low,Bi=Hi.high,Pi=Hi.low,zi=Ui,Gi=Qi,Vi=$i,Ki=wi,Zi=xi,In=yi,Ji=Ei,Xi=Ci,on=Ni,jn=Fi,Ln=Mi,Hn=Si,ea=Ai,ia=_i,Wn=Bi,oa=Pi,ta=0;ta<80;ta++){var aa,sa,ua=D[ta];if(ta<16)sa=ua.high=gi[bi+ta*2]|0,aa=ua.low=gi[bi+ta*2+1]|0;else{var da=D[ta-15],ca=da.high,la=da.low,Fa=(ca>>>1|la<<31)^(ca>>>8|la<<24)^ca>>>7,xa=(la>>>1|ca<<31)^(la>>>8|ca<<24)^(la>>>7|ca<<25),ha=D[ta-2],Ca=ha.high,Ra=ha.low,pa=(Ca>>>19|Ra<<13)^(Ca<<3|Ra>>>29)^Ca>>>6,Ma=(Ra>>>19|Ca<<13)^(Ra<<3|Ca>>>29)^(Ra>>>6|Ca<<26),wa=D[ta-7],ya=wa.high,La=wa.low,Sa=D[ta-16],ga=Sa.high,Pa=Sa.low;aa=xa+La,sa=Fa+ya+(aa>>>0<xa>>>0?1:0),aa=aa+Ma,sa=sa+pa+(aa>>>0<Ma>>>0?1:0),aa=aa+Pa,sa=sa+ga+(aa>>>0<Pa>>>0?1:0),ua.high=sa,ua.low=aa}var Ta=on&Ln^~on&ea,va=jn&Hn^~jn&ia,Ba=zi&Vi^zi&Zi^Vi&Zi,Aa=Gi&Ki^Gi&In^Ki&In,_a=(zi>>>28|Gi<<4)^(zi<<30|Gi>>>2)^(zi<<25|Gi>>>7),ka=(Gi>>>28|zi<<4)^(Gi<<30|zi>>>2)^(Gi<<25|zi>>>7),Na=(on>>>14|jn<<18)^(on>>>18|jn<<14)^(on<<23|jn>>>9),Rn=(jn>>>14|on<<18)^(jn>>>18|on<<14)^(jn<<23|on>>>9),Wi=vi[ta],Yi=Wi.high,Mn=Wi.low,Yn=oa+Rn,ra=Wn+Na+(Yn>>>0<oa>>>0?1:0),Yn=Yn+va,ra=ra+Ta+(Yn>>>0<va>>>0?1:0),Yn=Yn+Mn,ra=ra+Yi+(Yn>>>0<Mn>>>0?1:0),Yn=Yn+aa,ra=ra+sa+(Yn>>>0<aa>>>0?1:0),na=ka+Aa,Ea=_a+Ba+(na>>>0<ka>>>0?1:0);Wn=ea,oa=ia,ea=Ln,ia=Hn,Ln=on,Hn=jn,jn=Xi+Yn|0,on=Ji+ra+(jn>>>0<Xi>>>0?1:0)|0,Ji=Zi,Xi=In,Zi=Vi,In=Ki,Vi=zi,Ki=Gi,Gi=Yn+na|0,zi=ra+Ea+(Gi>>>0<Yn>>>0?1:0)|0}Qi=Ti.low=Qi+Gi,Ti.high=Ui+zi+(Qi>>>0<Gi>>>0?1:0),wi=Ii.low=wi+Ki,Ii.high=$i+Vi+(wi>>>0<Ki>>>0?1:0),yi=qi.low=yi+In,qi.high=xi+Zi+(yi>>>0<In>>>0?1:0),Ci=Oi.low=Ci+Xi,Oi.high=Ei+Ji+(Ci>>>0<Xi>>>0?1:0),Fi=ki.low=Fi+jn,ki.high=Ni+on+(Fi>>>0<jn>>>0?1:0),Si=Li.low=Si+Hn,Li.high=Mi+Ln+(Si>>>0<Hn>>>0?1:0),_i=ji.low=_i+ia,ji.high=Ai+ea+(_i>>>0<ia>>>0?1:0),Pi=Hi.low=Pi+oa,Hi.high=Bi+Wn+(Pi>>>0<oa>>>0?1:0)},_doFinalize:function(){var gi=this._data,bi=gi.words,Ri=this._nDataBytes*8,Ti=gi.sigBytes*8;bi[Ti>>>5]|=128<<24-Ti%32,bi[(Ti+128>>>10<<5)+30]=Math.floor(Ri/4294967296),bi[(Ti+128>>>10<<5)+31]=Ri,gi.sigBytes=bi.length*4,this._process();var Ii=this._hash.toX32();return Ii},clone:function(){var gi=a.clone.call(this);return gi._hash=this._hash.clone(),gi},blockSize:1024/32});n.SHA512=a._createHelper(mi),n.HmacSHA512=a._createHmacHelper(mi)}(),i.SHA512})}(sha512$1)),sha512$1.exports}var sha384$1={exports:{}},sha384=sha384$1.exports,hasRequiredSha384;function requireSha384(){return hasRequiredSha384||(hasRequiredSha384=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireX64Core(),requireSha512())})(sha384,function(i){return function(){var n=i,s=n.x64,a=s.Word,h=s.WordArray,v=n.algo,hi=v.SHA512,u=v.SHA384=hi.extend({_doReset:function(){this._hash=new h.init([new a.init(3418070365,3238371032),new a.init(1654270250,914150663),new a.init(2438529370,812702999),new a.init(355462360,4144912697),new a.init(1731405415,4290775857),new a.init(2394180231,1750603025),new a.init(3675008525,1694076839),new a.init(1203062813,3204075428)])},_doFinalize:function(){var l=hi._doFinalize.call(this);return l.sigBytes-=16,l}});n.SHA384=hi._createHelper(u),n.HmacSHA384=hi._createHmacHelper(u)}(),i.SHA384})}(sha384$1)),sha384$1.exports}var sha3$1={exports:{}},sha3=sha3$1.exports,hasRequiredSha3;function requireSha3(){return hasRequiredSha3||(hasRequiredSha3=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireX64Core())})(sha3,function(i){return function(n){var s=i,a=s.lib,h=a.WordArray,v=a.Hasher,hi=s.x64,u=hi.Word,l=s.algo,vi=[],D=[],mi=[];(function(){for(var Ri=1,Ti=0,Ii=0;Ii<24;Ii++){vi[Ri+5*Ti]=(Ii+1)*(Ii+2)/2%64;var qi=Ti%5,Oi=(2*Ri+3*Ti)%5;Ri=qi,Ti=Oi}for(var Ri=0;Ri<5;Ri++)for(var Ti=0;Ti<5;Ti++)D[Ri+5*Ti]=Ti+(2*Ri+3*Ti)%5*5;for(var ki=1,Li=0;Li<24;Li++){for(var ji=0,Hi=0,Ui=0;Ui<7;Ui++){if(ki&1){var Qi=(1<<Ui)-1;Qi<32?Hi^=1<<Qi:ji^=1<<Qi-32}ki&128?ki=ki<<1^113:ki<<=1}mi[Li]=u.create(ji,Hi)}})();var gi=[];(function(){for(var Ri=0;Ri<25;Ri++)gi[Ri]=u.create()})();var bi=l.SHA3=v.extend({cfg:v.cfg.extend({outputLength:512}),_doReset:function(){for(var Ri=this._state=[],Ti=0;Ti<25;Ti++)Ri[Ti]=new u.init;this.blockSize=(1600-2*this.cfg.outputLength)/32},_doProcessBlock:function(Ri,Ti){for(var Ii=this._state,qi=this.blockSize/2,Oi=0;Oi<qi;Oi++){var ki=Ri[Ti+2*Oi],Li=Ri[Ti+2*Oi+1];ki=(ki<<8|ki>>>24)&16711935|(ki<<24|ki>>>8)&4278255360,Li=(Li<<8|Li>>>24)&16711935|(Li<<24|Li>>>8)&4278255360;var ji=Ii[Oi];ji.high^=Li,ji.low^=ki}for(var Hi=0;Hi<24;Hi++){for(var Ui=0;Ui<5;Ui++){for(var Qi=0,$i=0,wi=0;wi<5;wi++){var ji=Ii[Ui+5*wi];Qi^=ji.high,$i^=ji.low}var xi=gi[Ui];xi.high=Qi,xi.low=$i}for(var Ui=0;Ui<5;Ui++)for(var yi=gi[(Ui+4)%5],Ei=gi[(Ui+1)%5],Ci=Ei.high,Ni=Ei.low,Qi=yi.high^(Ci<<1|Ni>>>31),$i=yi.low^(Ni<<1|Ci>>>31),wi=0;wi<5;wi++){var ji=Ii[Ui+5*wi];ji.high^=Qi,ji.low^=$i}for(var Fi=1;Fi<25;Fi++){var Qi,$i,ji=Ii[Fi],Mi=ji.high,Si=ji.low,Ai=vi[Fi];Ai<32?(Qi=Mi<<Ai|Si>>>32-Ai,$i=Si<<Ai|Mi>>>32-Ai):(Qi=Si<<Ai-32|Mi>>>64-Ai,$i=Mi<<Ai-32|Si>>>64-Ai);var _i=gi[D[Fi]];_i.high=Qi,_i.low=$i}var Bi=gi[0],Pi=Ii[0];Bi.high=Pi.high,Bi.low=Pi.low;for(var Ui=0;Ui<5;Ui++)for(var wi=0;wi<5;wi++){var Fi=Ui+5*wi,ji=Ii[Fi],zi=gi[Fi],Gi=gi[(Ui+1)%5+5*wi],Vi=gi[(Ui+2)%5+5*wi];ji.high=zi.high^~Gi.high&Vi.high,ji.low=zi.low^~Gi.low&Vi.low}var ji=Ii[0],Ki=mi[Hi];ji.high^=Ki.high,ji.low^=Ki.low}},_doFinalize:function(){var Ri=this._data,Ti=Ri.words;this._nDataBytes*8;var Ii=Ri.sigBytes*8,qi=this.blockSize*32;Ti[Ii>>>5]|=1<<24-Ii%32,Ti[(n.ceil((Ii+1)/qi)*qi>>>5)-1]|=128,Ri.sigBytes=Ti.length*4,this._process();for(var Oi=this._state,ki=this.cfg.outputLength/8,Li=ki/8,ji=[],Hi=0;Hi<Li;Hi++){var Ui=Oi[Hi],Qi=Ui.high,$i=Ui.low;Qi=(Qi<<8|Qi>>>24)&16711935|(Qi<<24|Qi>>>8)&4278255360,$i=($i<<8|$i>>>24)&16711935|($i<<24|$i>>>8)&4278255360,ji.push($i),ji.push(Qi)}return new h.init(ji,ki)},clone:function(){for(var Ri=v.clone.call(this),Ti=Ri._state=this._state.slice(0),Ii=0;Ii<25;Ii++)Ti[Ii]=Ti[Ii].clone();return Ri}});s.SHA3=v._createHelper(bi),s.HmacSHA3=v._createHmacHelper(bi)}(Math),i.SHA3})}(sha3$1)),sha3$1.exports}var ripemd160$1={exports:{}},ripemd160=ripemd160$1.exports,hasRequiredRipemd160;function requireRipemd160(){return hasRequiredRipemd160||(hasRequiredRipemd160=1,function(r,t){(function(i,n){r.exports=n(requireCore())})(ripemd160,function(i){/** @preserve
105
+ (c) 2012 by Cédric Mesnil. All rights reserved.
106
+
107
+ Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
108
+
109
+ - Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
110
+ - Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
111
+
112
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
113
+ */return function(n){var s=i,a=s.lib,h=a.WordArray,v=a.Hasher,hi=s.algo,u=h.create([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13]),l=h.create([5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11]),vi=h.create([11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6]),D=h.create([8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11]),mi=h.create([0,1518500249,1859775393,2400959708,2840853838]),gi=h.create([1352829926,1548603684,1836072691,2053994217,0]),bi=hi.RIPEMD160=v.extend({_doReset:function(){this._hash=h.create([1732584193,4023233417,2562383102,271733878,3285377520])},_doProcessBlock:function(Li,ji){for(var Hi=0;Hi<16;Hi++){var Ui=ji+Hi,Qi=Li[Ui];Li[Ui]=(Qi<<8|Qi>>>24)&16711935|(Qi<<24|Qi>>>8)&4278255360}var $i=this._hash.words,wi=mi.words,xi=gi.words,yi=u.words,Ei=l.words,Ci=vi.words,Ni=D.words,Fi,Mi,Si,Ai,_i,Bi,Pi,zi,Gi,Vi;Bi=Fi=$i[0],Pi=Mi=$i[1],zi=Si=$i[2],Gi=Ai=$i[3],Vi=_i=$i[4];for(var Ki,Hi=0;Hi<80;Hi+=1)Ki=Fi+Li[ji+yi[Hi]]|0,Hi<16?Ki+=Ri(Mi,Si,Ai)+wi[0]:Hi<32?Ki+=Ti(Mi,Si,Ai)+wi[1]:Hi<48?Ki+=Ii(Mi,Si,Ai)+wi[2]:Hi<64?Ki+=qi(Mi,Si,Ai)+wi[3]:Ki+=Oi(Mi,Si,Ai)+wi[4],Ki=Ki|0,Ki=ki(Ki,Ci[Hi]),Ki=Ki+_i|0,Fi=_i,_i=Ai,Ai=ki(Si,10),Si=Mi,Mi=Ki,Ki=Bi+Li[ji+Ei[Hi]]|0,Hi<16?Ki+=Oi(Pi,zi,Gi)+xi[0]:Hi<32?Ki+=qi(Pi,zi,Gi)+xi[1]:Hi<48?Ki+=Ii(Pi,zi,Gi)+xi[2]:Hi<64?Ki+=Ti(Pi,zi,Gi)+xi[3]:Ki+=Ri(Pi,zi,Gi)+xi[4],Ki=Ki|0,Ki=ki(Ki,Ni[Hi]),Ki=Ki+Vi|0,Bi=Vi,Vi=Gi,Gi=ki(zi,10),zi=Pi,Pi=Ki;Ki=$i[1]+Si+Gi|0,$i[1]=$i[2]+Ai+Vi|0,$i[2]=$i[3]+_i+Bi|0,$i[3]=$i[4]+Fi+Pi|0,$i[4]=$i[0]+Mi+zi|0,$i[0]=Ki},_doFinalize:function(){var Li=this._data,ji=Li.words,Hi=this._nDataBytes*8,Ui=Li.sigBytes*8;ji[Ui>>>5]|=128<<24-Ui%32,ji[(Ui+64>>>9<<4)+14]=(Hi<<8|Hi>>>24)&16711935|(Hi<<24|Hi>>>8)&4278255360,Li.sigBytes=(ji.length+1)*4,this._process();for(var Qi=this._hash,$i=Qi.words,wi=0;wi<5;wi++){var xi=$i[wi];$i[wi]=(xi<<8|xi>>>24)&16711935|(xi<<24|xi>>>8)&4278255360}return Qi},clone:function(){var Li=v.clone.call(this);return Li._hash=this._hash.clone(),Li}});function Ri(Li,ji,Hi){return Li^ji^Hi}function Ti(Li,ji,Hi){return Li&ji|~Li&Hi}function Ii(Li,ji,Hi){return(Li|~ji)^Hi}function qi(Li,ji,Hi){return Li&Hi|ji&~Hi}function Oi(Li,ji,Hi){return Li^(ji|~Hi)}function ki(Li,ji){return Li<<ji|Li>>>32-ji}s.RIPEMD160=v._createHelper(bi),s.HmacRIPEMD160=v._createHmacHelper(bi)}(),i.RIPEMD160})}(ripemd160$1)),ripemd160$1.exports}var hmac$1={exports:{}},hmac=hmac$1.exports,hasRequiredHmac;function requireHmac(){return hasRequiredHmac||(hasRequiredHmac=1,function(r,t){(function(i,n){r.exports=n(requireCore())})(hmac,function(i){(function(){var n=i,s=n.lib,a=s.Base,h=n.enc,v=h.Utf8,hi=n.algo;hi.HMAC=a.extend({init:function(u,l){u=this._hasher=new u.init,typeof l=="string"&&(l=v.parse(l));var vi=u.blockSize,D=vi*4;l.sigBytes>D&&(l=u.finalize(l)),l.clamp();for(var mi=this._oKey=l.clone(),gi=this._iKey=l.clone(),bi=mi.words,Ri=gi.words,Ti=0;Ti<vi;Ti++)bi[Ti]^=1549556828,Ri[Ti]^=909522486;mi.sigBytes=gi.sigBytes=D,this.reset()},reset:function(){var u=this._hasher;u.reset(),u.update(this._iKey)},update:function(u){return this._hasher.update(u),this},finalize:function(u){var l=this._hasher,vi=l.finalize(u);l.reset();var D=l.finalize(this._oKey.clone().concat(vi));return D}})})()})}(hmac$1)),hmac$1.exports}var pbkdf2$1={exports:{}},pbkdf2=pbkdf2$1.exports,hasRequiredPbkdf2;function requirePbkdf2(){return hasRequiredPbkdf2||(hasRequiredPbkdf2=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireSha256(),requireHmac())})(pbkdf2,function(i){return function(){var n=i,s=n.lib,a=s.Base,h=s.WordArray,v=n.algo,hi=v.SHA256,u=v.HMAC,l=v.PBKDF2=a.extend({cfg:a.extend({keySize:128/32,hasher:hi,iterations:25e4}),init:function(vi){this.cfg=this.cfg.extend(vi)},compute:function(vi,D){for(var mi=this.cfg,gi=u.create(mi.hasher,vi),bi=h.create(),Ri=h.create([1]),Ti=bi.words,Ii=Ri.words,qi=mi.keySize,Oi=mi.iterations;Ti.length<qi;){var ki=gi.update(D).finalize(Ri);gi.reset();for(var Li=ki.words,ji=Li.length,Hi=ki,Ui=1;Ui<Oi;Ui++){Hi=gi.finalize(Hi),gi.reset();for(var Qi=Hi.words,$i=0;$i<ji;$i++)Li[$i]^=Qi[$i]}bi.concat(ki),Ii[0]++}return bi.sigBytes=qi*4,bi}});n.PBKDF2=function(vi,D,mi){return l.create(mi).compute(vi,D)}}(),i.PBKDF2})}(pbkdf2$1)),pbkdf2$1.exports}var evpkdf$1={exports:{}},evpkdf=evpkdf$1.exports,hasRequiredEvpkdf;function requireEvpkdf(){return hasRequiredEvpkdf||(hasRequiredEvpkdf=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireSha1(),requireHmac())})(evpkdf,function(i){return function(){var n=i,s=n.lib,a=s.Base,h=s.WordArray,v=n.algo,hi=v.MD5,u=v.EvpKDF=a.extend({cfg:a.extend({keySize:128/32,hasher:hi,iterations:1}),init:function(l){this.cfg=this.cfg.extend(l)},compute:function(l,vi){for(var D,mi=this.cfg,gi=mi.hasher.create(),bi=h.create(),Ri=bi.words,Ti=mi.keySize,Ii=mi.iterations;Ri.length<Ti;){D&&gi.update(D),D=gi.update(l).finalize(vi),gi.reset();for(var qi=1;qi<Ii;qi++)D=gi.finalize(D),gi.reset();bi.concat(D)}return bi.sigBytes=Ti*4,bi}});n.EvpKDF=function(l,vi,D){return u.create(D).compute(l,vi)}}(),i.EvpKDF})}(evpkdf$1)),evpkdf$1.exports}var cipherCore$1={exports:{}},cipherCore=cipherCore$1.exports,hasRequiredCipherCore;function requireCipherCore(){return hasRequiredCipherCore||(hasRequiredCipherCore=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireEvpkdf())})(cipherCore,function(i){i.lib.Cipher||function(n){var s=i,a=s.lib,h=a.Base,v=a.WordArray,hi=a.BufferedBlockAlgorithm,u=s.enc;u.Utf8;var l=u.Base64,vi=s.algo,D=vi.EvpKDF,mi=a.Cipher=hi.extend({cfg:h.extend(),createEncryptor:function(Qi,$i){return this.create(this._ENC_XFORM_MODE,Qi,$i)},createDecryptor:function(Qi,$i){return this.create(this._DEC_XFORM_MODE,Qi,$i)},init:function(Qi,$i,wi){this.cfg=this.cfg.extend(wi),this._xformMode=Qi,this._key=$i,this.reset()},reset:function(){hi.reset.call(this),this._doReset()},process:function(Qi){return this._append(Qi),this._process()},finalize:function(Qi){Qi&&this._append(Qi);var $i=this._doFinalize();return $i},keySize:128/32,ivSize:128/32,_ENC_XFORM_MODE:1,_DEC_XFORM_MODE:2,_createHelper:function(){function Qi($i){return typeof $i=="string"?Ui:Li}return function($i){return{encrypt:function(wi,xi,yi){return Qi(xi).encrypt($i,wi,xi,yi)},decrypt:function(wi,xi,yi){return Qi(xi).decrypt($i,wi,xi,yi)}}}}()});a.StreamCipher=mi.extend({_doFinalize:function(){var Qi=this._process(!0);return Qi},blockSize:1});var gi=s.mode={},bi=a.BlockCipherMode=h.extend({createEncryptor:function(Qi,$i){return this.Encryptor.create(Qi,$i)},createDecryptor:function(Qi,$i){return this.Decryptor.create(Qi,$i)},init:function(Qi,$i){this._cipher=Qi,this._iv=$i}}),Ri=gi.CBC=function(){var Qi=bi.extend();Qi.Encryptor=Qi.extend({processBlock:function(wi,xi){var yi=this._cipher,Ei=yi.blockSize;$i.call(this,wi,xi,Ei),yi.encryptBlock(wi,xi),this._prevBlock=wi.slice(xi,xi+Ei)}}),Qi.Decryptor=Qi.extend({processBlock:function(wi,xi){var yi=this._cipher,Ei=yi.blockSize,Ci=wi.slice(xi,xi+Ei);yi.decryptBlock(wi,xi),$i.call(this,wi,xi,Ei),this._prevBlock=Ci}});function $i(wi,xi,yi){var Ei,Ci=this._iv;Ci?(Ei=Ci,this._iv=n):Ei=this._prevBlock;for(var Ni=0;Ni<yi;Ni++)wi[xi+Ni]^=Ei[Ni]}return Qi}(),Ti=s.pad={},Ii=Ti.Pkcs7={pad:function(Qi,$i){for(var wi=$i*4,xi=wi-Qi.sigBytes%wi,yi=xi<<24|xi<<16|xi<<8|xi,Ei=[],Ci=0;Ci<xi;Ci+=4)Ei.push(yi);var Ni=v.create(Ei,xi);Qi.concat(Ni)},unpad:function(Qi){var $i=Qi.words[Qi.sigBytes-1>>>2]&255;Qi.sigBytes-=$i}};a.BlockCipher=mi.extend({cfg:mi.cfg.extend({mode:Ri,padding:Ii}),reset:function(){var Qi;mi.reset.call(this);var $i=this.cfg,wi=$i.iv,xi=$i.mode;this._xformMode==this._ENC_XFORM_MODE?Qi=xi.createEncryptor:(Qi=xi.createDecryptor,this._minBufferSize=1),this._mode&&this._mode.__creator==Qi?this._mode.init(this,wi&&wi.words):(this._mode=Qi.call(xi,this,wi&&wi.words),this._mode.__creator=Qi)},_doProcessBlock:function(Qi,$i){this._mode.processBlock(Qi,$i)},_doFinalize:function(){var Qi,$i=this.cfg.padding;return this._xformMode==this._ENC_XFORM_MODE?($i.pad(this._data,this.blockSize),Qi=this._process(!0)):(Qi=this._process(!0),$i.unpad(Qi)),Qi},blockSize:128/32});var qi=a.CipherParams=h.extend({init:function(Qi){this.mixIn(Qi)},toString:function(Qi){return(Qi||this.formatter).stringify(this)}}),Oi=s.format={},ki=Oi.OpenSSL={stringify:function(Qi){var $i,wi=Qi.ciphertext,xi=Qi.salt;return xi?$i=v.create([1398893684,1701076831]).concat(xi).concat(wi):$i=wi,$i.toString(l)},parse:function(Qi){var $i,wi=l.parse(Qi),xi=wi.words;return xi[0]==1398893684&&xi[1]==1701076831&&($i=v.create(xi.slice(2,4)),xi.splice(0,4),wi.sigBytes-=16),qi.create({ciphertext:wi,salt:$i})}},Li=a.SerializableCipher=h.extend({cfg:h.extend({format:ki}),encrypt:function(Qi,$i,wi,xi){xi=this.cfg.extend(xi);var yi=Qi.createEncryptor(wi,xi),Ei=yi.finalize($i),Ci=yi.cfg;return qi.create({ciphertext:Ei,key:wi,iv:Ci.iv,algorithm:Qi,mode:Ci.mode,padding:Ci.padding,blockSize:Qi.blockSize,formatter:xi.format})},decrypt:function(Qi,$i,wi,xi){xi=this.cfg.extend(xi),$i=this._parse($i,xi.format);var yi=Qi.createDecryptor(wi,xi).finalize($i.ciphertext);return yi},_parse:function(Qi,$i){return typeof Qi=="string"?$i.parse(Qi,this):Qi}}),ji=s.kdf={},Hi=ji.OpenSSL={execute:function(Qi,$i,wi,xi,yi){if(xi||(xi=v.random(64/8)),yi)var Ei=D.create({keySize:$i+wi,hasher:yi}).compute(Qi,xi);else var Ei=D.create({keySize:$i+wi}).compute(Qi,xi);var Ci=v.create(Ei.words.slice($i),wi*4);return Ei.sigBytes=$i*4,qi.create({key:Ei,iv:Ci,salt:xi})}},Ui=a.PasswordBasedCipher=Li.extend({cfg:Li.cfg.extend({kdf:Hi}),encrypt:function(Qi,$i,wi,xi){xi=this.cfg.extend(xi);var yi=xi.kdf.execute(wi,Qi.keySize,Qi.ivSize,xi.salt,xi.hasher);xi.iv=yi.iv;var Ei=Li.encrypt.call(this,Qi,$i,yi.key,xi);return Ei.mixIn(yi),Ei},decrypt:function(Qi,$i,wi,xi){xi=this.cfg.extend(xi),$i=this._parse($i,xi.format);var yi=xi.kdf.execute(wi,Qi.keySize,Qi.ivSize,$i.salt,xi.hasher);xi.iv=yi.iv;var Ei=Li.decrypt.call(this,Qi,$i,yi.key,xi);return Ei}})}()})}(cipherCore$1)),cipherCore$1.exports}var modeCfb$1={exports:{}},modeCfb=modeCfb$1.exports,hasRequiredModeCfb;function requireModeCfb(){return hasRequiredModeCfb||(hasRequiredModeCfb=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireCipherCore())})(modeCfb,function(i){return i.mode.CFB=function(){var n=i.lib.BlockCipherMode.extend();n.Encryptor=n.extend({processBlock:function(a,h){var v=this._cipher,hi=v.blockSize;s.call(this,a,h,hi,v),this._prevBlock=a.slice(h,h+hi)}}),n.Decryptor=n.extend({processBlock:function(a,h){var v=this._cipher,hi=v.blockSize,u=a.slice(h,h+hi);s.call(this,a,h,hi,v),this._prevBlock=u}});function s(a,h,v,hi){var u,l=this._iv;l?(u=l.slice(0),this._iv=void 0):u=this._prevBlock,hi.encryptBlock(u,0);for(var vi=0;vi<v;vi++)a[h+vi]^=u[vi]}return n}(),i.mode.CFB})}(modeCfb$1)),modeCfb$1.exports}var modeCtr$1={exports:{}},modeCtr=modeCtr$1.exports,hasRequiredModeCtr;function requireModeCtr(){return hasRequiredModeCtr||(hasRequiredModeCtr=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireCipherCore())})(modeCtr,function(i){return i.mode.CTR=function(){var n=i.lib.BlockCipherMode.extend(),s=n.Encryptor=n.extend({processBlock:function(a,h){var v=this._cipher,hi=v.blockSize,u=this._iv,l=this._counter;u&&(l=this._counter=u.slice(0),this._iv=void 0);var vi=l.slice(0);v.encryptBlock(vi,0),l[hi-1]=l[hi-1]+1|0;for(var D=0;D<hi;D++)a[h+D]^=vi[D]}});return n.Decryptor=s,n}(),i.mode.CTR})}(modeCtr$1)),modeCtr$1.exports}var modeCtrGladman$1={exports:{}},modeCtrGladman=modeCtrGladman$1.exports,hasRequiredModeCtrGladman;function requireModeCtrGladman(){return hasRequiredModeCtrGladman||(hasRequiredModeCtrGladman=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireCipherCore())})(modeCtrGladman,function(i){/** @preserve
114
+ * Counter block mode compatible with Dr Brian Gladman fileenc.c
115
+ * derived from CryptoJS.mode.CTR
116
+ * Jan Hruby jhruby.web@gmail.com
117
+ */return i.mode.CTRGladman=function(){var n=i.lib.BlockCipherMode.extend();function s(v){if((v>>24&255)===255){var hi=v>>16&255,u=v>>8&255,l=v&255;hi===255?(hi=0,u===255?(u=0,l===255?l=0:++l):++u):++hi,v=0,v+=hi<<16,v+=u<<8,v+=l}else v+=1<<24;return v}function a(v){return(v[0]=s(v[0]))===0&&(v[1]=s(v[1])),v}var h=n.Encryptor=n.extend({processBlock:function(v,hi){var u=this._cipher,l=u.blockSize,vi=this._iv,D=this._counter;vi&&(D=this._counter=vi.slice(0),this._iv=void 0),a(D);var mi=D.slice(0);u.encryptBlock(mi,0);for(var gi=0;gi<l;gi++)v[hi+gi]^=mi[gi]}});return n.Decryptor=h,n}(),i.mode.CTRGladman})}(modeCtrGladman$1)),modeCtrGladman$1.exports}var modeOfb$1={exports:{}},modeOfb=modeOfb$1.exports,hasRequiredModeOfb;function requireModeOfb(){return hasRequiredModeOfb||(hasRequiredModeOfb=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireCipherCore())})(modeOfb,function(i){return i.mode.OFB=function(){var n=i.lib.BlockCipherMode.extend(),s=n.Encryptor=n.extend({processBlock:function(a,h){var v=this._cipher,hi=v.blockSize,u=this._iv,l=this._keystream;u&&(l=this._keystream=u.slice(0),this._iv=void 0),v.encryptBlock(l,0);for(var vi=0;vi<hi;vi++)a[h+vi]^=l[vi]}});return n.Decryptor=s,n}(),i.mode.OFB})}(modeOfb$1)),modeOfb$1.exports}var modeEcb$1={exports:{}},modeEcb=modeEcb$1.exports,hasRequiredModeEcb;function requireModeEcb(){return hasRequiredModeEcb||(hasRequiredModeEcb=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireCipherCore())})(modeEcb,function(i){return i.mode.ECB=function(){var n=i.lib.BlockCipherMode.extend();return n.Encryptor=n.extend({processBlock:function(s,a){this._cipher.encryptBlock(s,a)}}),n.Decryptor=n.extend({processBlock:function(s,a){this._cipher.decryptBlock(s,a)}}),n}(),i.mode.ECB})}(modeEcb$1)),modeEcb$1.exports}var padAnsix923$1={exports:{}},padAnsix923=padAnsix923$1.exports,hasRequiredPadAnsix923;function requirePadAnsix923(){return hasRequiredPadAnsix923||(hasRequiredPadAnsix923=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireCipherCore())})(padAnsix923,function(i){return i.pad.AnsiX923={pad:function(n,s){var a=n.sigBytes,h=s*4,v=h-a%h,hi=a+v-1;n.clamp(),n.words[hi>>>2]|=v<<24-hi%4*8,n.sigBytes+=v},unpad:function(n){var s=n.words[n.sigBytes-1>>>2]&255;n.sigBytes-=s}},i.pad.Ansix923})}(padAnsix923$1)),padAnsix923$1.exports}var padIso10126$1={exports:{}},padIso10126=padIso10126$1.exports,hasRequiredPadIso10126;function requirePadIso10126(){return hasRequiredPadIso10126||(hasRequiredPadIso10126=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireCipherCore())})(padIso10126,function(i){return i.pad.Iso10126={pad:function(n,s){var a=s*4,h=a-n.sigBytes%a;n.concat(i.lib.WordArray.random(h-1)).concat(i.lib.WordArray.create([h<<24],1))},unpad:function(n){var s=n.words[n.sigBytes-1>>>2]&255;n.sigBytes-=s}},i.pad.Iso10126})}(padIso10126$1)),padIso10126$1.exports}var padIso97971$1={exports:{}},padIso97971=padIso97971$1.exports,hasRequiredPadIso97971;function requirePadIso97971(){return hasRequiredPadIso97971||(hasRequiredPadIso97971=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireCipherCore())})(padIso97971,function(i){return i.pad.Iso97971={pad:function(n,s){n.concat(i.lib.WordArray.create([2147483648],1)),i.pad.ZeroPadding.pad(n,s)},unpad:function(n){i.pad.ZeroPadding.unpad(n),n.sigBytes--}},i.pad.Iso97971})}(padIso97971$1)),padIso97971$1.exports}var padZeropadding$1={exports:{}},padZeropadding=padZeropadding$1.exports,hasRequiredPadZeropadding;function requirePadZeropadding(){return hasRequiredPadZeropadding||(hasRequiredPadZeropadding=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireCipherCore())})(padZeropadding,function(i){return i.pad.ZeroPadding={pad:function(n,s){var a=s*4;n.clamp(),n.sigBytes+=a-(n.sigBytes%a||a)},unpad:function(n){for(var s=n.words,a=n.sigBytes-1,a=n.sigBytes-1;a>=0;a--)if(s[a>>>2]>>>24-a%4*8&255){n.sigBytes=a+1;break}}},i.pad.ZeroPadding})}(padZeropadding$1)),padZeropadding$1.exports}var padNopadding$1={exports:{}},padNopadding=padNopadding$1.exports,hasRequiredPadNopadding;function requirePadNopadding(){return hasRequiredPadNopadding||(hasRequiredPadNopadding=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireCipherCore())})(padNopadding,function(i){return i.pad.NoPadding={pad:function(){},unpad:function(){}},i.pad.NoPadding})}(padNopadding$1)),padNopadding$1.exports}var formatHex$1={exports:{}},formatHex=formatHex$1.exports,hasRequiredFormatHex;function requireFormatHex(){return hasRequiredFormatHex||(hasRequiredFormatHex=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireCipherCore())})(formatHex,function(i){return function(n){var s=i,a=s.lib,h=a.CipherParams,v=s.enc,hi=v.Hex,u=s.format;u.Hex={stringify:function(l){return l.ciphertext.toString(hi)},parse:function(l){var vi=hi.parse(l);return h.create({ciphertext:vi})}}}(),i.format.Hex})}(formatHex$1)),formatHex$1.exports}var aes$1={exports:{}},aes=aes$1.exports,hasRequiredAes;function requireAes(){return hasRequiredAes||(hasRequiredAes=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireEncBase64(),requireMd5(),requireEvpkdf(),requireCipherCore())})(aes,function(i){return function(){var n=i,s=n.lib,a=s.BlockCipher,h=n.algo,v=[],hi=[],u=[],l=[],vi=[],D=[],mi=[],gi=[],bi=[],Ri=[];(function(){for(var qi=[],Oi=0;Oi<256;Oi++)Oi<128?qi[Oi]=Oi<<1:qi[Oi]=Oi<<1^283;for(var ki=0,Li=0,Oi=0;Oi<256;Oi++){var ji=Li^Li<<1^Li<<2^Li<<3^Li<<4;ji=ji>>>8^ji&255^99,v[ki]=ji,hi[ji]=ki;var Hi=qi[ki],Ui=qi[Hi],Qi=qi[Ui],$i=qi[ji]*257^ji*16843008;u[ki]=$i<<24|$i>>>8,l[ki]=$i<<16|$i>>>16,vi[ki]=$i<<8|$i>>>24,D[ki]=$i;var $i=Qi*16843009^Ui*65537^Hi*257^ki*16843008;mi[ji]=$i<<24|$i>>>8,gi[ji]=$i<<16|$i>>>16,bi[ji]=$i<<8|$i>>>24,Ri[ji]=$i,ki?(ki=Hi^qi[qi[qi[Qi^Hi]]],Li^=qi[qi[Li]]):ki=Li=1}})();var Ti=[0,1,2,4,8,16,32,64,128,27,54],Ii=h.AES=a.extend({_doReset:function(){var qi;if(!(this._nRounds&&this._keyPriorReset===this._key)){for(var Oi=this._keyPriorReset=this._key,ki=Oi.words,Li=Oi.sigBytes/4,ji=this._nRounds=Li+6,Hi=(ji+1)*4,Ui=this._keySchedule=[],Qi=0;Qi<Hi;Qi++)Qi<Li?Ui[Qi]=ki[Qi]:(qi=Ui[Qi-1],Qi%Li?Li>6&&Qi%Li==4&&(qi=v[qi>>>24]<<24|v[qi>>>16&255]<<16|v[qi>>>8&255]<<8|v[qi&255]):(qi=qi<<8|qi>>>24,qi=v[qi>>>24]<<24|v[qi>>>16&255]<<16|v[qi>>>8&255]<<8|v[qi&255],qi^=Ti[Qi/Li|0]<<24),Ui[Qi]=Ui[Qi-Li]^qi);for(var $i=this._invKeySchedule=[],wi=0;wi<Hi;wi++){var Qi=Hi-wi;if(wi%4)var qi=Ui[Qi];else var qi=Ui[Qi-4];wi<4||Qi<=4?$i[wi]=qi:$i[wi]=mi[v[qi>>>24]]^gi[v[qi>>>16&255]]^bi[v[qi>>>8&255]]^Ri[v[qi&255]]}}},encryptBlock:function(qi,Oi){this._doCryptBlock(qi,Oi,this._keySchedule,u,l,vi,D,v)},decryptBlock:function(qi,Oi){var ki=qi[Oi+1];qi[Oi+1]=qi[Oi+3],qi[Oi+3]=ki,this._doCryptBlock(qi,Oi,this._invKeySchedule,mi,gi,bi,Ri,hi);var ki=qi[Oi+1];qi[Oi+1]=qi[Oi+3],qi[Oi+3]=ki},_doCryptBlock:function(qi,Oi,ki,Li,ji,Hi,Ui,Qi){for(var $i=this._nRounds,wi=qi[Oi]^ki[0],xi=qi[Oi+1]^ki[1],yi=qi[Oi+2]^ki[2],Ei=qi[Oi+3]^ki[3],Ci=4,Ni=1;Ni<$i;Ni++){var Fi=Li[wi>>>24]^ji[xi>>>16&255]^Hi[yi>>>8&255]^Ui[Ei&255]^ki[Ci++],Mi=Li[xi>>>24]^ji[yi>>>16&255]^Hi[Ei>>>8&255]^Ui[wi&255]^ki[Ci++],Si=Li[yi>>>24]^ji[Ei>>>16&255]^Hi[wi>>>8&255]^Ui[xi&255]^ki[Ci++],Ai=Li[Ei>>>24]^ji[wi>>>16&255]^Hi[xi>>>8&255]^Ui[yi&255]^ki[Ci++];wi=Fi,xi=Mi,yi=Si,Ei=Ai}var Fi=(Qi[wi>>>24]<<24|Qi[xi>>>16&255]<<16|Qi[yi>>>8&255]<<8|Qi[Ei&255])^ki[Ci++],Mi=(Qi[xi>>>24]<<24|Qi[yi>>>16&255]<<16|Qi[Ei>>>8&255]<<8|Qi[wi&255])^ki[Ci++],Si=(Qi[yi>>>24]<<24|Qi[Ei>>>16&255]<<16|Qi[wi>>>8&255]<<8|Qi[xi&255])^ki[Ci++],Ai=(Qi[Ei>>>24]<<24|Qi[wi>>>16&255]<<16|Qi[xi>>>8&255]<<8|Qi[yi&255])^ki[Ci++];qi[Oi]=Fi,qi[Oi+1]=Mi,qi[Oi+2]=Si,qi[Oi+3]=Ai},keySize:256/32});n.AES=a._createHelper(Ii)}(),i.AES})}(aes$1)),aes$1.exports}var tripledes$1={exports:{}},tripledes=tripledes$1.exports,hasRequiredTripledes;function requireTripledes(){return hasRequiredTripledes||(hasRequiredTripledes=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireEncBase64(),requireMd5(),requireEvpkdf(),requireCipherCore())})(tripledes,function(i){return function(){var n=i,s=n.lib,a=s.WordArray,h=s.BlockCipher,v=n.algo,hi=[57,49,41,33,25,17,9,1,58,50,42,34,26,18,10,2,59,51,43,35,27,19,11,3,60,52,44,36,63,55,47,39,31,23,15,7,62,54,46,38,30,22,14,6,61,53,45,37,29,21,13,5,28,20,12,4],u=[14,17,11,24,1,5,3,28,15,6,21,10,23,19,12,4,26,8,16,7,27,20,13,2,41,52,31,37,47,55,30,40,51,45,33,48,44,49,39,56,34,53,46,42,50,36,29,32],l=[1,2,4,6,8,10,12,14,15,17,19,21,23,25,27,28],vi=[{0:8421888,268435456:32768,536870912:8421378,805306368:2,1073741824:512,1342177280:8421890,1610612736:8389122,1879048192:8388608,2147483648:514,2415919104:8389120,2684354560:33280,2952790016:8421376,3221225472:32770,3489660928:8388610,3758096384:0,4026531840:33282,134217728:0,402653184:8421890,671088640:33282,939524096:32768,1207959552:8421888,1476395008:512,1744830464:8421378,2013265920:2,2281701376:8389120,2550136832:33280,2818572288:8421376,3087007744:8389122,3355443200:8388610,3623878656:32770,3892314112:514,4160749568:8388608,1:32768,268435457:2,536870913:8421888,805306369:8388608,1073741825:8421378,1342177281:33280,1610612737:512,1879048193:8389122,2147483649:8421890,2415919105:8421376,2684354561:8388610,2952790017:33282,3221225473:514,3489660929:8389120,3758096385:32770,4026531841:0,134217729:8421890,402653185:8421376,671088641:8388608,939524097:512,1207959553:32768,1476395009:8388610,1744830465:2,2013265921:33282,2281701377:32770,2550136833:8389122,2818572289:514,3087007745:8421888,3355443201:8389120,3623878657:0,3892314113:33280,4160749569:8421378},{0:1074282512,16777216:16384,33554432:524288,50331648:1074266128,67108864:1073741840,83886080:1074282496,100663296:1073758208,117440512:16,134217728:540672,150994944:1073758224,167772160:1073741824,184549376:540688,201326592:524304,218103808:0,234881024:16400,251658240:1074266112,8388608:1073758208,25165824:540688,41943040:16,58720256:1073758224,75497472:1074282512,92274688:1073741824,109051904:524288,125829120:1074266128,142606336:524304,159383552:0,176160768:16384,192937984:1074266112,209715200:1073741840,226492416:540672,243269632:1074282496,260046848:16400,268435456:0,285212672:1074266128,301989888:1073758224,318767104:1074282496,335544320:1074266112,352321536:16,369098752:540688,385875968:16384,402653184:16400,419430400:524288,436207616:524304,452984832:1073741840,469762048:540672,486539264:1073758208,503316480:1073741824,520093696:1074282512,276824064:540688,293601280:524288,310378496:1074266112,327155712:16384,343932928:1073758208,360710144:1074282512,377487360:16,394264576:1073741824,411041792:1074282496,427819008:1073741840,444596224:1073758224,461373440:524304,478150656:0,494927872:16400,511705088:1074266128,528482304:540672},{0:260,1048576:0,2097152:67109120,3145728:65796,4194304:65540,5242880:67108868,6291456:67174660,7340032:67174400,8388608:67108864,9437184:67174656,10485760:65792,11534336:67174404,12582912:67109124,13631488:65536,14680064:4,15728640:256,524288:67174656,1572864:67174404,2621440:0,3670016:67109120,4718592:67108868,5767168:65536,6815744:65540,7864320:260,8912896:4,9961472:256,11010048:67174400,12058624:65796,13107200:65792,14155776:67109124,15204352:67174660,16252928:67108864,16777216:67174656,17825792:65540,18874368:65536,19922944:67109120,20971520:256,22020096:67174660,23068672:67108868,24117248:0,25165824:67109124,26214400:67108864,27262976:4,28311552:65792,29360128:67174400,30408704:260,31457280:65796,32505856:67174404,17301504:67108864,18350080:260,19398656:67174656,20447232:0,21495808:65540,22544384:67109120,23592960:256,24641536:67174404,25690112:65536,26738688:67174660,27787264:65796,28835840:67108868,29884416:67109124,30932992:67174400,31981568:4,33030144:65792},{0:2151682048,65536:2147487808,131072:4198464,196608:2151677952,262144:0,327680:4198400,393216:2147483712,458752:4194368,524288:2147483648,589824:4194304,655360:64,720896:2147487744,786432:2151678016,851968:4160,917504:4096,983040:2151682112,32768:2147487808,98304:64,163840:2151678016,229376:2147487744,294912:4198400,360448:2151682112,425984:0,491520:2151677952,557056:4096,622592:2151682048,688128:4194304,753664:4160,819200:2147483648,884736:4194368,950272:4198464,1015808:2147483712,1048576:4194368,1114112:4198400,1179648:2147483712,1245184:0,1310720:4160,1376256:2151678016,1441792:2151682048,1507328:2147487808,1572864:2151682112,1638400:2147483648,1703936:2151677952,1769472:4198464,1835008:2147487744,1900544:4194304,1966080:64,2031616:4096,1081344:2151677952,1146880:2151682112,1212416:0,1277952:4198400,1343488:4194368,1409024:2147483648,1474560:2147487808,1540096:64,1605632:2147483712,1671168:4096,1736704:2147487744,1802240:2151678016,1867776:4160,1933312:2151682048,1998848:4194304,2064384:4198464},{0:128,4096:17039360,8192:262144,12288:536870912,16384:537133184,20480:16777344,24576:553648256,28672:262272,32768:16777216,36864:537133056,40960:536871040,45056:553910400,49152:553910272,53248:0,57344:17039488,61440:553648128,2048:17039488,6144:553648256,10240:128,14336:17039360,18432:262144,22528:537133184,26624:553910272,30720:536870912,34816:537133056,38912:0,43008:553910400,47104:16777344,51200:536871040,55296:553648128,59392:16777216,63488:262272,65536:262144,69632:128,73728:536870912,77824:553648256,81920:16777344,86016:553910272,90112:537133184,94208:16777216,98304:553910400,102400:553648128,106496:17039360,110592:537133056,114688:262272,118784:536871040,122880:0,126976:17039488,67584:553648256,71680:16777216,75776:17039360,79872:537133184,83968:536870912,88064:17039488,92160:128,96256:553910272,100352:262272,104448:553910400,108544:0,112640:553648128,116736:16777344,120832:262144,124928:537133056,129024:536871040},{0:268435464,256:8192,512:270532608,768:270540808,1024:268443648,1280:2097152,1536:2097160,1792:268435456,2048:0,2304:268443656,2560:2105344,2816:8,3072:270532616,3328:2105352,3584:8200,3840:270540800,128:270532608,384:270540808,640:8,896:2097152,1152:2105352,1408:268435464,1664:268443648,1920:8200,2176:2097160,2432:8192,2688:268443656,2944:270532616,3200:0,3456:270540800,3712:2105344,3968:268435456,4096:268443648,4352:270532616,4608:270540808,4864:8200,5120:2097152,5376:268435456,5632:268435464,5888:2105344,6144:2105352,6400:0,6656:8,6912:270532608,7168:8192,7424:268443656,7680:270540800,7936:2097160,4224:8,4480:2105344,4736:2097152,4992:268435464,5248:268443648,5504:8200,5760:270540808,6016:270532608,6272:270540800,6528:270532616,6784:8192,7040:2105352,7296:2097160,7552:0,7808:268435456,8064:268443656},{0:1048576,16:33555457,32:1024,48:1049601,64:34604033,80:0,96:1,112:34603009,128:33555456,144:1048577,160:33554433,176:34604032,192:34603008,208:1025,224:1049600,240:33554432,8:34603009,24:0,40:33555457,56:34604032,72:1048576,88:33554433,104:33554432,120:1025,136:1049601,152:33555456,168:34603008,184:1048577,200:1024,216:34604033,232:1,248:1049600,256:33554432,272:1048576,288:33555457,304:34603009,320:1048577,336:33555456,352:34604032,368:1049601,384:1025,400:34604033,416:1049600,432:1,448:0,464:34603008,480:33554433,496:1024,264:1049600,280:33555457,296:34603009,312:1,328:33554432,344:1048576,360:1025,376:34604032,392:33554433,408:34603008,424:0,440:34604033,456:1049601,472:1024,488:33555456,504:1048577},{0:134219808,1:131072,2:134217728,3:32,4:131104,5:134350880,6:134350848,7:2048,8:134348800,9:134219776,10:133120,11:134348832,12:2080,13:0,14:134217760,15:133152,2147483648:2048,2147483649:134350880,2147483650:134219808,2147483651:134217728,2147483652:134348800,2147483653:133120,2147483654:133152,2147483655:32,2147483656:134217760,2147483657:2080,2147483658:131104,2147483659:134350848,2147483660:0,2147483661:134348832,2147483662:134219776,2147483663:131072,16:133152,17:134350848,18:32,19:2048,20:134219776,21:134217760,22:134348832,23:131072,24:0,25:131104,26:134348800,27:134219808,28:134350880,29:133120,30:2080,31:134217728,2147483664:131072,2147483665:2048,2147483666:134348832,2147483667:133152,2147483668:32,2147483669:134348800,2147483670:134217728,2147483671:134219808,2147483672:134350880,2147483673:134217760,2147483674:134219776,2147483675:0,2147483676:133120,2147483677:2080,2147483678:131104,2147483679:134350848}],D=[4160749569,528482304,33030144,2064384,129024,8064,504,2147483679],mi=v.DES=h.extend({_doReset:function(){for(var Ti=this._key,Ii=Ti.words,qi=[],Oi=0;Oi<56;Oi++){var ki=hi[Oi]-1;qi[Oi]=Ii[ki>>>5]>>>31-ki%32&1}for(var Li=this._subKeys=[],ji=0;ji<16;ji++){for(var Hi=Li[ji]=[],Ui=l[ji],Oi=0;Oi<24;Oi++)Hi[Oi/6|0]|=qi[(u[Oi]-1+Ui)%28]<<31-Oi%6,Hi[4+(Oi/6|0)]|=qi[28+(u[Oi+24]-1+Ui)%28]<<31-Oi%6;Hi[0]=Hi[0]<<1|Hi[0]>>>31;for(var Oi=1;Oi<7;Oi++)Hi[Oi]=Hi[Oi]>>>(Oi-1)*4+3;Hi[7]=Hi[7]<<5|Hi[7]>>>27}for(var Qi=this._invSubKeys=[],Oi=0;Oi<16;Oi++)Qi[Oi]=Li[15-Oi]},encryptBlock:function(Ti,Ii){this._doCryptBlock(Ti,Ii,this._subKeys)},decryptBlock:function(Ti,Ii){this._doCryptBlock(Ti,Ii,this._invSubKeys)},_doCryptBlock:function(Ti,Ii,qi){this._lBlock=Ti[Ii],this._rBlock=Ti[Ii+1],gi.call(this,4,252645135),gi.call(this,16,65535),bi.call(this,2,858993459),bi.call(this,8,16711935),gi.call(this,1,1431655765);for(var Oi=0;Oi<16;Oi++){for(var ki=qi[Oi],Li=this._lBlock,ji=this._rBlock,Hi=0,Ui=0;Ui<8;Ui++)Hi|=vi[Ui][((ji^ki[Ui])&D[Ui])>>>0];this._lBlock=ji,this._rBlock=Li^Hi}var Qi=this._lBlock;this._lBlock=this._rBlock,this._rBlock=Qi,gi.call(this,1,1431655765),bi.call(this,8,16711935),bi.call(this,2,858993459),gi.call(this,16,65535),gi.call(this,4,252645135),Ti[Ii]=this._lBlock,Ti[Ii+1]=this._rBlock},keySize:64/32,ivSize:64/32,blockSize:64/32});function gi(Ti,Ii){var qi=(this._lBlock>>>Ti^this._rBlock)&Ii;this._rBlock^=qi,this._lBlock^=qi<<Ti}function bi(Ti,Ii){var qi=(this._rBlock>>>Ti^this._lBlock)&Ii;this._lBlock^=qi,this._rBlock^=qi<<Ti}n.DES=h._createHelper(mi);var Ri=v.TripleDES=h.extend({_doReset:function(){var Ti=this._key,Ii=Ti.words;if(Ii.length!==2&&Ii.length!==4&&Ii.length<6)throw new Error("Invalid key length - 3DES requires the key length to be 64, 128, 192 or >192.");var qi=Ii.slice(0,2),Oi=Ii.length<4?Ii.slice(0,2):Ii.slice(2,4),ki=Ii.length<6?Ii.slice(0,2):Ii.slice(4,6);this._des1=mi.createEncryptor(a.create(qi)),this._des2=mi.createEncryptor(a.create(Oi)),this._des3=mi.createEncryptor(a.create(ki))},encryptBlock:function(Ti,Ii){this._des1.encryptBlock(Ti,Ii),this._des2.decryptBlock(Ti,Ii),this._des3.encryptBlock(Ti,Ii)},decryptBlock:function(Ti,Ii){this._des3.decryptBlock(Ti,Ii),this._des2.encryptBlock(Ti,Ii),this._des1.decryptBlock(Ti,Ii)},keySize:192/32,ivSize:64/32,blockSize:64/32});n.TripleDES=h._createHelper(Ri)}(),i.TripleDES})}(tripledes$1)),tripledes$1.exports}var rc4$1={exports:{}},rc4=rc4$1.exports,hasRequiredRc4;function requireRc4(){return hasRequiredRc4||(hasRequiredRc4=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireEncBase64(),requireMd5(),requireEvpkdf(),requireCipherCore())})(rc4,function(i){return function(){var n=i,s=n.lib,a=s.StreamCipher,h=n.algo,v=h.RC4=a.extend({_doReset:function(){for(var l=this._key,vi=l.words,D=l.sigBytes,mi=this._S=[],gi=0;gi<256;gi++)mi[gi]=gi;for(var gi=0,bi=0;gi<256;gi++){var Ri=gi%D,Ti=vi[Ri>>>2]>>>24-Ri%4*8&255;bi=(bi+mi[gi]+Ti)%256;var Ii=mi[gi];mi[gi]=mi[bi],mi[bi]=Ii}this._i=this._j=0},_doProcessBlock:function(l,vi){l[vi]^=hi.call(this)},keySize:256/32,ivSize:0});function hi(){for(var l=this._S,vi=this._i,D=this._j,mi=0,gi=0;gi<4;gi++){vi=(vi+1)%256,D=(D+l[vi])%256;var bi=l[vi];l[vi]=l[D],l[D]=bi,mi|=l[(l[vi]+l[D])%256]<<24-gi*8}return this._i=vi,this._j=D,mi}n.RC4=a._createHelper(v);var u=h.RC4Drop=v.extend({cfg:v.cfg.extend({drop:192}),_doReset:function(){v._doReset.call(this);for(var l=this.cfg.drop;l>0;l--)hi.call(this)}});n.RC4Drop=a._createHelper(u)}(),i.RC4})}(rc4$1)),rc4$1.exports}var rabbit$1={exports:{}},rabbit=rabbit$1.exports,hasRequiredRabbit;function requireRabbit(){return hasRequiredRabbit||(hasRequiredRabbit=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireEncBase64(),requireMd5(),requireEvpkdf(),requireCipherCore())})(rabbit,function(i){return function(){var n=i,s=n.lib,a=s.StreamCipher,h=n.algo,v=[],hi=[],u=[],l=h.Rabbit=a.extend({_doReset:function(){for(var D=this._key.words,mi=this.cfg.iv,gi=0;gi<4;gi++)D[gi]=(D[gi]<<8|D[gi]>>>24)&16711935|(D[gi]<<24|D[gi]>>>8)&4278255360;var bi=this._X=[D[0],D[3]<<16|D[2]>>>16,D[1],D[0]<<16|D[3]>>>16,D[2],D[1]<<16|D[0]>>>16,D[3],D[2]<<16|D[1]>>>16],Ri=this._C=[D[2]<<16|D[2]>>>16,D[0]&4294901760|D[1]&65535,D[3]<<16|D[3]>>>16,D[1]&4294901760|D[2]&65535,D[0]<<16|D[0]>>>16,D[2]&4294901760|D[3]&65535,D[1]<<16|D[1]>>>16,D[3]&4294901760|D[0]&65535];this._b=0;for(var gi=0;gi<4;gi++)vi.call(this);for(var gi=0;gi<8;gi++)Ri[gi]^=bi[gi+4&7];if(mi){var Ti=mi.words,Ii=Ti[0],qi=Ti[1],Oi=(Ii<<8|Ii>>>24)&16711935|(Ii<<24|Ii>>>8)&4278255360,ki=(qi<<8|qi>>>24)&16711935|(qi<<24|qi>>>8)&4278255360,Li=Oi>>>16|ki&4294901760,ji=ki<<16|Oi&65535;Ri[0]^=Oi,Ri[1]^=Li,Ri[2]^=ki,Ri[3]^=ji,Ri[4]^=Oi,Ri[5]^=Li,Ri[6]^=ki,Ri[7]^=ji;for(var gi=0;gi<4;gi++)vi.call(this)}},_doProcessBlock:function(D,mi){var gi=this._X;vi.call(this),v[0]=gi[0]^gi[5]>>>16^gi[3]<<16,v[1]=gi[2]^gi[7]>>>16^gi[5]<<16,v[2]=gi[4]^gi[1]>>>16^gi[7]<<16,v[3]=gi[6]^gi[3]>>>16^gi[1]<<16;for(var bi=0;bi<4;bi++)v[bi]=(v[bi]<<8|v[bi]>>>24)&16711935|(v[bi]<<24|v[bi]>>>8)&4278255360,D[mi+bi]^=v[bi]},blockSize:128/32,ivSize:64/32});function vi(){for(var D=this._X,mi=this._C,gi=0;gi<8;gi++)hi[gi]=mi[gi];mi[0]=mi[0]+1295307597+this._b|0,mi[1]=mi[1]+3545052371+(mi[0]>>>0<hi[0]>>>0?1:0)|0,mi[2]=mi[2]+886263092+(mi[1]>>>0<hi[1]>>>0?1:0)|0,mi[3]=mi[3]+1295307597+(mi[2]>>>0<hi[2]>>>0?1:0)|0,mi[4]=mi[4]+3545052371+(mi[3]>>>0<hi[3]>>>0?1:0)|0,mi[5]=mi[5]+886263092+(mi[4]>>>0<hi[4]>>>0?1:0)|0,mi[6]=mi[6]+1295307597+(mi[5]>>>0<hi[5]>>>0?1:0)|0,mi[7]=mi[7]+3545052371+(mi[6]>>>0<hi[6]>>>0?1:0)|0,this._b=mi[7]>>>0<hi[7]>>>0?1:0;for(var gi=0;gi<8;gi++){var bi=D[gi]+mi[gi],Ri=bi&65535,Ti=bi>>>16,Ii=((Ri*Ri>>>17)+Ri*Ti>>>15)+Ti*Ti,qi=((bi&4294901760)*bi|0)+((bi&65535)*bi|0);u[gi]=Ii^qi}D[0]=u[0]+(u[7]<<16|u[7]>>>16)+(u[6]<<16|u[6]>>>16)|0,D[1]=u[1]+(u[0]<<8|u[0]>>>24)+u[7]|0,D[2]=u[2]+(u[1]<<16|u[1]>>>16)+(u[0]<<16|u[0]>>>16)|0,D[3]=u[3]+(u[2]<<8|u[2]>>>24)+u[1]|0,D[4]=u[4]+(u[3]<<16|u[3]>>>16)+(u[2]<<16|u[2]>>>16)|0,D[5]=u[5]+(u[4]<<8|u[4]>>>24)+u[3]|0,D[6]=u[6]+(u[5]<<16|u[5]>>>16)+(u[4]<<16|u[4]>>>16)|0,D[7]=u[7]+(u[6]<<8|u[6]>>>24)+u[5]|0}n.Rabbit=a._createHelper(l)}(),i.Rabbit})}(rabbit$1)),rabbit$1.exports}var rabbitLegacy$1={exports:{}},rabbitLegacy=rabbitLegacy$1.exports,hasRequiredRabbitLegacy;function requireRabbitLegacy(){return hasRequiredRabbitLegacy||(hasRequiredRabbitLegacy=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireEncBase64(),requireMd5(),requireEvpkdf(),requireCipherCore())})(rabbitLegacy,function(i){return function(){var n=i,s=n.lib,a=s.StreamCipher,h=n.algo,v=[],hi=[],u=[],l=h.RabbitLegacy=a.extend({_doReset:function(){var D=this._key.words,mi=this.cfg.iv,gi=this._X=[D[0],D[3]<<16|D[2]>>>16,D[1],D[0]<<16|D[3]>>>16,D[2],D[1]<<16|D[0]>>>16,D[3],D[2]<<16|D[1]>>>16],bi=this._C=[D[2]<<16|D[2]>>>16,D[0]&4294901760|D[1]&65535,D[3]<<16|D[3]>>>16,D[1]&4294901760|D[2]&65535,D[0]<<16|D[0]>>>16,D[2]&4294901760|D[3]&65535,D[1]<<16|D[1]>>>16,D[3]&4294901760|D[0]&65535];this._b=0;for(var Ri=0;Ri<4;Ri++)vi.call(this);for(var Ri=0;Ri<8;Ri++)bi[Ri]^=gi[Ri+4&7];if(mi){var Ti=mi.words,Ii=Ti[0],qi=Ti[1],Oi=(Ii<<8|Ii>>>24)&16711935|(Ii<<24|Ii>>>8)&4278255360,ki=(qi<<8|qi>>>24)&16711935|(qi<<24|qi>>>8)&4278255360,Li=Oi>>>16|ki&4294901760,ji=ki<<16|Oi&65535;bi[0]^=Oi,bi[1]^=Li,bi[2]^=ki,bi[3]^=ji,bi[4]^=Oi,bi[5]^=Li,bi[6]^=ki,bi[7]^=ji;for(var Ri=0;Ri<4;Ri++)vi.call(this)}},_doProcessBlock:function(D,mi){var gi=this._X;vi.call(this),v[0]=gi[0]^gi[5]>>>16^gi[3]<<16,v[1]=gi[2]^gi[7]>>>16^gi[5]<<16,v[2]=gi[4]^gi[1]>>>16^gi[7]<<16,v[3]=gi[6]^gi[3]>>>16^gi[1]<<16;for(var bi=0;bi<4;bi++)v[bi]=(v[bi]<<8|v[bi]>>>24)&16711935|(v[bi]<<24|v[bi]>>>8)&4278255360,D[mi+bi]^=v[bi]},blockSize:128/32,ivSize:64/32});function vi(){for(var D=this._X,mi=this._C,gi=0;gi<8;gi++)hi[gi]=mi[gi];mi[0]=mi[0]+1295307597+this._b|0,mi[1]=mi[1]+3545052371+(mi[0]>>>0<hi[0]>>>0?1:0)|0,mi[2]=mi[2]+886263092+(mi[1]>>>0<hi[1]>>>0?1:0)|0,mi[3]=mi[3]+1295307597+(mi[2]>>>0<hi[2]>>>0?1:0)|0,mi[4]=mi[4]+3545052371+(mi[3]>>>0<hi[3]>>>0?1:0)|0,mi[5]=mi[5]+886263092+(mi[4]>>>0<hi[4]>>>0?1:0)|0,mi[6]=mi[6]+1295307597+(mi[5]>>>0<hi[5]>>>0?1:0)|0,mi[7]=mi[7]+3545052371+(mi[6]>>>0<hi[6]>>>0?1:0)|0,this._b=mi[7]>>>0<hi[7]>>>0?1:0;for(var gi=0;gi<8;gi++){var bi=D[gi]+mi[gi],Ri=bi&65535,Ti=bi>>>16,Ii=((Ri*Ri>>>17)+Ri*Ti>>>15)+Ti*Ti,qi=((bi&4294901760)*bi|0)+((bi&65535)*bi|0);u[gi]=Ii^qi}D[0]=u[0]+(u[7]<<16|u[7]>>>16)+(u[6]<<16|u[6]>>>16)|0,D[1]=u[1]+(u[0]<<8|u[0]>>>24)+u[7]|0,D[2]=u[2]+(u[1]<<16|u[1]>>>16)+(u[0]<<16|u[0]>>>16)|0,D[3]=u[3]+(u[2]<<8|u[2]>>>24)+u[1]|0,D[4]=u[4]+(u[3]<<16|u[3]>>>16)+(u[2]<<16|u[2]>>>16)|0,D[5]=u[5]+(u[4]<<8|u[4]>>>24)+u[3]|0,D[6]=u[6]+(u[5]<<16|u[5]>>>16)+(u[4]<<16|u[4]>>>16)|0,D[7]=u[7]+(u[6]<<8|u[6]>>>24)+u[5]|0}n.RabbitLegacy=a._createHelper(l)}(),i.RabbitLegacy})}(rabbitLegacy$1)),rabbitLegacy$1.exports}var blowfish$1={exports:{}},blowfish=blowfish$1.exports,hasRequiredBlowfish;function requireBlowfish(){return hasRequiredBlowfish||(hasRequiredBlowfish=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireEncBase64(),requireMd5(),requireEvpkdf(),requireCipherCore())})(blowfish,function(i){return function(){var n=i,s=n.lib,a=s.BlockCipher,h=n.algo;const v=16,hi=[608135816,2242054355,320440878,57701188,2752067618,698298832,137296536,3964562569,1160258022,953160567,3193202383,887688300,3232508343,3380367581,1065670069,3041331479,2450970073,2306472731],u=[[3509652390,2564797868,805139163,3491422135,3101798381,1780907670,3128725573,4046225305,614570311,3012652279,134345442,2240740374,1667834072,1901547113,2757295779,4103290238,227898511,1921955416,1904987480,2182433518,2069144605,3260701109,2620446009,720527379,3318853667,677414384,3393288472,3101374703,2390351024,1614419982,1822297739,2954791486,3608508353,3174124327,2024746970,1432378464,3864339955,2857741204,1464375394,1676153920,1439316330,715854006,3033291828,289532110,2706671279,2087905683,3018724369,1668267050,732546397,1947742710,3462151702,2609353502,2950085171,1814351708,2050118529,680887927,999245976,1800124847,3300911131,1713906067,1641548236,4213287313,1216130144,1575780402,4018429277,3917837745,3693486850,3949271944,596196993,3549867205,258830323,2213823033,772490370,2760122372,1774776394,2652871518,566650946,4142492826,1728879713,2882767088,1783734482,3629395816,2517608232,2874225571,1861159788,326777828,3124490320,2130389656,2716951837,967770486,1724537150,2185432712,2364442137,1164943284,2105845187,998989502,3765401048,2244026483,1075463327,1455516326,1322494562,910128902,469688178,1117454909,936433444,3490320968,3675253459,1240580251,122909385,2157517691,634681816,4142456567,3825094682,3061402683,2540495037,79693498,3249098678,1084186820,1583128258,426386531,1761308591,1047286709,322548459,995290223,1845252383,2603652396,3431023940,2942221577,3202600964,3727903485,1712269319,422464435,3234572375,1170764815,3523960633,3117677531,1434042557,442511882,3600875718,1076654713,1738483198,4213154764,2393238008,3677496056,1014306527,4251020053,793779912,2902807211,842905082,4246964064,1395751752,1040244610,2656851899,3396308128,445077038,3742853595,3577915638,679411651,2892444358,2354009459,1767581616,3150600392,3791627101,3102740896,284835224,4246832056,1258075500,768725851,2589189241,3069724005,3532540348,1274779536,3789419226,2764799539,1660621633,3471099624,4011903706,913787905,3497959166,737222580,2514213453,2928710040,3937242737,1804850592,3499020752,2949064160,2386320175,2390070455,2415321851,4061277028,2290661394,2416832540,1336762016,1754252060,3520065937,3014181293,791618072,3188594551,3933548030,2332172193,3852520463,3043980520,413987798,3465142937,3030929376,4245938359,2093235073,3534596313,375366246,2157278981,2479649556,555357303,3870105701,2008414854,3344188149,4221384143,3956125452,2067696032,3594591187,2921233993,2428461,544322398,577241275,1471733935,610547355,4027169054,1432588573,1507829418,2025931657,3646575487,545086370,48609733,2200306550,1653985193,298326376,1316178497,3007786442,2064951626,458293330,2589141269,3591329599,3164325604,727753846,2179363840,146436021,1461446943,4069977195,705550613,3059967265,3887724982,4281599278,3313849956,1404054877,2845806497,146425753,1854211946],[1266315497,3048417604,3681880366,3289982499,290971e4,1235738493,2632868024,2414719590,3970600049,1771706367,1449415276,3266420449,422970021,1963543593,2690192192,3826793022,1062508698,1531092325,1804592342,2583117782,2714934279,4024971509,1294809318,4028980673,1289560198,2221992742,1669523910,35572830,157838143,1052438473,1016535060,1802137761,1753167236,1386275462,3080475397,2857371447,1040679964,2145300060,2390574316,1461121720,2956646967,4031777805,4028374788,33600511,2920084762,1018524850,629373528,3691585981,3515945977,2091462646,2486323059,586499841,988145025,935516892,3367335476,2599673255,2839830854,265290510,3972581182,2759138881,3795373465,1005194799,847297441,406762289,1314163512,1332590856,1866599683,4127851711,750260880,613907577,1450815602,3165620655,3734664991,3650291728,3012275730,3704569646,1427272223,778793252,1343938022,2676280711,2052605720,1946737175,3164576444,3914038668,3967478842,3682934266,1661551462,3294938066,4011595847,840292616,3712170807,616741398,312560963,711312465,1351876610,322626781,1910503582,271666773,2175563734,1594956187,70604529,3617834859,1007753275,1495573769,4069517037,2549218298,2663038764,504708206,2263041392,3941167025,2249088522,1514023603,1998579484,1312622330,694541497,2582060303,2151582166,1382467621,776784248,2618340202,3323268794,2497899128,2784771155,503983604,4076293799,907881277,423175695,432175456,1378068232,4145222326,3954048622,3938656102,3820766613,2793130115,2977904593,26017576,3274890735,3194772133,1700274565,1756076034,4006520079,3677328699,720338349,1533947780,354530856,688349552,3973924725,1637815568,332179504,3949051286,53804574,2852348879,3044236432,1282449977,3583942155,3416972820,4006381244,1617046695,2628476075,3002303598,1686838959,431878346,2686675385,1700445008,1080580658,1009431731,832498133,3223435511,2605976345,2271191193,2516031870,1648197032,4164389018,2548247927,300782431,375919233,238389289,3353747414,2531188641,2019080857,1475708069,455242339,2609103871,448939670,3451063019,1395535956,2413381860,1841049896,1491858159,885456874,4264095073,4001119347,1565136089,3898914787,1108368660,540939232,1173283510,2745871338,3681308437,4207628240,3343053890,4016749493,1699691293,1103962373,3625875870,2256883143,3830138730,1031889488,3479347698,1535977030,4236805024,3251091107,2132092099,1774941330,1199868427,1452454533,157007616,2904115357,342012276,595725824,1480756522,206960106,497939518,591360097,863170706,2375253569,3596610801,1814182875,2094937945,3421402208,1082520231,3463918190,2785509508,435703966,3908032597,1641649973,2842273706,3305899714,1510255612,2148256476,2655287854,3276092548,4258621189,236887753,3681803219,274041037,1734335097,3815195456,3317970021,1899903192,1026095262,4050517792,356393447,2410691914,3873677099,3682840055],[3913112168,2491498743,4132185628,2489919796,1091903735,1979897079,3170134830,3567386728,3557303409,857797738,1136121015,1342202287,507115054,2535736646,337727348,3213592640,1301675037,2528481711,1895095763,1721773893,3216771564,62756741,2142006736,835421444,2531993523,1442658625,3659876326,2882144922,676362277,1392781812,170690266,3921047035,1759253602,3611846912,1745797284,664899054,1329594018,3901205900,3045908486,2062866102,2865634940,3543621612,3464012697,1080764994,553557557,3656615353,3996768171,991055499,499776247,1265440854,648242737,3940784050,980351604,3713745714,1749149687,3396870395,4211799374,3640570775,1161844396,3125318951,1431517754,545492359,4268468663,3499529547,1437099964,2702547544,3433638243,2581715763,2787789398,1060185593,1593081372,2418618748,4260947970,69676912,2159744348,86519011,2512459080,3838209314,1220612927,3339683548,133810670,1090789135,1078426020,1569222167,845107691,3583754449,4072456591,1091646820,628848692,1613405280,3757631651,526609435,236106946,48312990,2942717905,3402727701,1797494240,859738849,992217954,4005476642,2243076622,3870952857,3732016268,765654824,3490871365,2511836413,1685915746,3888969200,1414112111,2273134842,3281911079,4080962846,172450625,2569994100,980381355,4109958455,2819808352,2716589560,2568741196,3681446669,3329971472,1835478071,660984891,3704678404,4045999559,3422617507,3040415634,1762651403,1719377915,3470491036,2693910283,3642056355,3138596744,1364962596,2073328063,1983633131,926494387,3423689081,2150032023,4096667949,1749200295,3328846651,309677260,2016342300,1779581495,3079819751,111262694,1274766160,443224088,298511866,1025883608,3806446537,1145181785,168956806,3641502830,3584813610,1689216846,3666258015,3200248200,1692713982,2646376535,4042768518,1618508792,1610833997,3523052358,4130873264,2001055236,3610705100,2202168115,4028541809,2961195399,1006657119,2006996926,3186142756,1430667929,3210227297,1314452623,4074634658,4101304120,2273951170,1399257539,3367210612,3027628629,1190975929,2062231137,2333990788,2221543033,2438960610,1181637006,548689776,2362791313,3372408396,3104550113,3145860560,296247880,1970579870,3078560182,3769228297,1714227617,3291629107,3898220290,166772364,1251581989,493813264,448347421,195405023,2709975567,677966185,3703036547,1463355134,2715995803,1338867538,1343315457,2802222074,2684532164,233230375,2599980071,2000651841,3277868038,1638401717,4028070440,3237316320,6314154,819756386,300326615,590932579,1405279636,3267499572,3150704214,2428286686,3959192993,3461946742,1862657033,1266418056,963775037,2089974820,2263052895,1917689273,448879540,3550394620,3981727096,150775221,3627908307,1303187396,508620638,2975983352,2726630617,1817252668,1876281319,1457606340,908771278,3720792119,3617206836,2455994898,1729034894,1080033504],[976866871,3556439503,2881648439,1522871579,1555064734,1336096578,3548522304,2579274686,3574697629,3205460757,3593280638,3338716283,3079412587,564236357,2993598910,1781952180,1464380207,3163844217,3332601554,1699332808,1393555694,1183702653,3581086237,1288719814,691649499,2847557200,2895455976,3193889540,2717570544,1781354906,1676643554,2592534050,3230253752,1126444790,2770207658,2633158820,2210423226,2615765581,2414155088,3127139286,673620729,2805611233,1269405062,4015350505,3341807571,4149409754,1057255273,2012875353,2162469141,2276492801,2601117357,993977747,3918593370,2654263191,753973209,36408145,2530585658,25011837,3520020182,2088578344,530523599,2918365339,1524020338,1518925132,3760827505,3759777254,1202760957,3985898139,3906192525,674977740,4174734889,2031300136,2019492241,3983892565,4153806404,3822280332,352677332,2297720250,60907813,90501309,3286998549,1016092578,2535922412,2839152426,457141659,509813237,4120667899,652014361,1966332200,2975202805,55981186,2327461051,676427537,3255491064,2882294119,3433927263,1307055953,942726286,933058658,2468411793,3933900994,4215176142,1361170020,2001714738,2830558078,3274259782,1222529897,1679025792,2729314320,3714953764,1770335741,151462246,3013232138,1682292957,1483529935,471910574,1539241949,458788160,3436315007,1807016891,3718408830,978976581,1043663428,3165965781,1927990952,4200891579,2372276910,3208408903,3533431907,1412390302,2931980059,4132332400,1947078029,3881505623,4168226417,2941484381,1077988104,1320477388,886195818,18198404,3786409e3,2509781533,112762804,3463356488,1866414978,891333506,18488651,661792760,1628790961,3885187036,3141171499,876946877,2693282273,1372485963,791857591,2686433993,3759982718,3167212022,3472953795,2716379847,445679433,3561995674,3504004811,3574258232,54117162,3331405415,2381918588,3769707343,4154350007,1140177722,4074052095,668550556,3214352940,367459370,261225585,2610173221,4209349473,3468074219,3265815641,314222801,3066103646,3808782860,282218597,3406013506,3773591054,379116347,1285071038,846784868,2669647154,3771962079,3550491691,2305946142,453669953,1268987020,3317592352,3279303384,3744833421,2610507566,3859509063,266596637,3847019092,517658769,3462560207,3443424879,370717030,4247526661,2224018117,4143653529,4112773975,2788324899,2477274417,1456262402,2901442914,1517677493,1846949527,2295493580,3734397586,2176403920,1280348187,1908823572,3871786941,846861322,1172426758,3287448474,3383383037,1655181056,3139813346,901632758,1897031941,2986607138,3066810236,3447102507,1393639104,373351379,950779232,625454576,3124240540,4148612726,2007998917,544563296,2244738638,2330496472,2058025392,1291430526,424198748,50039436,29584100,3605783033,2429876329,2791104160,1057563949,3255363231,3075367218,3463963227,1469046755,985887462]];var l={pbox:[],sbox:[]};function vi(Ri,Ti){let Ii=Ti>>24&255,qi=Ti>>16&255,Oi=Ti>>8&255,ki=Ti&255,Li=Ri.sbox[0][Ii]+Ri.sbox[1][qi];return Li=Li^Ri.sbox[2][Oi],Li=Li+Ri.sbox[3][ki],Li}function D(Ri,Ti,Ii){let qi=Ti,Oi=Ii,ki;for(let Li=0;Li<v;++Li)qi=qi^Ri.pbox[Li],Oi=vi(Ri,qi)^Oi,ki=qi,qi=Oi,Oi=ki;return ki=qi,qi=Oi,Oi=ki,Oi=Oi^Ri.pbox[v],qi=qi^Ri.pbox[v+1],{left:qi,right:Oi}}function mi(Ri,Ti,Ii){let qi=Ti,Oi=Ii,ki;for(let Li=v+1;Li>1;--Li)qi=qi^Ri.pbox[Li],Oi=vi(Ri,qi)^Oi,ki=qi,qi=Oi,Oi=ki;return ki=qi,qi=Oi,Oi=ki,Oi=Oi^Ri.pbox[1],qi=qi^Ri.pbox[0],{left:qi,right:Oi}}function gi(Ri,Ti,Ii){for(let ji=0;ji<4;ji++){Ri.sbox[ji]=[];for(let Hi=0;Hi<256;Hi++)Ri.sbox[ji][Hi]=u[ji][Hi]}let qi=0;for(let ji=0;ji<v+2;ji++)Ri.pbox[ji]=hi[ji]^Ti[qi],qi++,qi>=Ii&&(qi=0);let Oi=0,ki=0,Li=0;for(let ji=0;ji<v+2;ji+=2)Li=D(Ri,Oi,ki),Oi=Li.left,ki=Li.right,Ri.pbox[ji]=Oi,Ri.pbox[ji+1]=ki;for(let ji=0;ji<4;ji++)for(let Hi=0;Hi<256;Hi+=2)Li=D(Ri,Oi,ki),Oi=Li.left,ki=Li.right,Ri.sbox[ji][Hi]=Oi,Ri.sbox[ji][Hi+1]=ki;return!0}var bi=h.Blowfish=a.extend({_doReset:function(){if(this._keyPriorReset!==this._key){var Ri=this._keyPriorReset=this._key,Ti=Ri.words,Ii=Ri.sigBytes/4;gi(l,Ti,Ii)}},encryptBlock:function(Ri,Ti){var Ii=D(l,Ri[Ti],Ri[Ti+1]);Ri[Ti]=Ii.left,Ri[Ti+1]=Ii.right},decryptBlock:function(Ri,Ti){var Ii=mi(l,Ri[Ti],Ri[Ti+1]);Ri[Ti]=Ii.left,Ri[Ti+1]=Ii.right},blockSize:64/32,keySize:128/32,ivSize:64/32});n.Blowfish=a._createHelper(bi)}(),i.Blowfish})}(blowfish$1)),blowfish$1.exports}var cryptoJs=cryptoJs$1.exports,hasRequiredCryptoJs;function requireCryptoJs(){return hasRequiredCryptoJs||(hasRequiredCryptoJs=1,function(r,t){(function(i,n,s){r.exports=n(requireCore(),requireX64Core(),requireLibTypedarrays(),requireEncUtf16(),requireEncBase64(),requireEncBase64url(),requireMd5(),requireSha1(),requireSha256(),requireSha224(),requireSha512(),requireSha384(),requireSha3(),requireRipemd160(),requireHmac(),requirePbkdf2(),requireEvpkdf(),requireCipherCore(),requireModeCfb(),requireModeCtr(),requireModeCtrGladman(),requireModeOfb(),requireModeEcb(),requirePadAnsix923(),requirePadIso10126(),requirePadIso97971(),requirePadZeropadding(),requirePadNopadding(),requireFormatHex(),requireAes(),requireTripledes(),requireRc4(),requireRabbit(),requireRabbitLegacy(),requireBlowfish())})(cryptoJs,function(i){return i})}(cryptoJs$1)),cryptoJs$1.exports}requireCryptoJs();requireBrowser$b();function tryAcquireLock(r,t,i){return openDatabaseWithTransactionScope(["mutex"],"readwrite",async n=>{const s=await n.store.mutex.get(r),a=()=>n.store.mutex.put({resource:r,owner:t,expiresAt:now()+i});return s?s.owner===t||s.expiresAt<now()?(await a(),!0):!1:(await a(),!0)})}function releaseLock(r){return openDatabaseScope(t=>t.delete("mutex",r))}var GraphQLSchemaAttachmentKind=(r=>(r.SDL_SCHEMA="sdl-schema",r.STATISTICS="statistics",r.ITEMS="items",r))(GraphQLSchemaAttachmentKind||{});function isGraphQLSchemaSdlAttachmentEntity(r){return!!r&&r.kind===GraphQLSchemaAttachmentKind.SDL_SCHEMA}function setIndexedGraphQLSchemaEntity(r,t,i,n){return openDatabaseWithTransactionScope(["schema","schema-attachment"],"readwrite",async s=>{const a=await s.store.schema.get(r);!a||a.hash!==t||a.indexed||await Promise.all([s.store.schema.put({...a,indexed:!0}),s.store.schemaAttachment.put({endpoint:r,kind:GraphQLSchemaAttachmentKind.ITEMS,value:i}),s.store.schemaAttachment.put({endpoint:r,kind:GraphQLSchemaAttachmentKind.STATISTICS,value:n}),s.done])})}function getGraphQLSchemaEntity(r){const t=harmonizeSchemaUrl(r);return getEntityByKey("schema",t)}async function getGraphQLSdlSchema(r){const t=harmonizeSchemaUrl(r),i=await getEntityByKey("schema-attachment",[t,GraphQLSchemaAttachmentKind.SDL_SCHEMA]);return isGraphQLSchemaSdlAttachmentEntity(i)?i.value:void 0}RelativeDateTimeRange.last30Minutes;RelativeDateTimeRange.last30Minutes,RelativeDateTimeRange.today,RelativeDateTimeRange.today,RelativeDateTimeRange.today;function requireLock(r,t,i){const n=FIVE_SECONDS,s=createId("mutex");return acquireLock(r,s,n).then(async()=>{const a=new TimeoutAbortController(n);try{const[h]=await Promise.all([t(a.signal.toAbortSignal()).then(v=>(a.cancel(),v)),a.signal.toPromise()]);return h}catch(h){throw isTimeoutAbortError(h)?new LockExpiredError(r):h}finally{a.cancel(),await releaseLock(r)}})}async function acquireLock(r,t,i){for(;!await tryAcquireLock(r,t,i);)await delay(FIFTY_MILLISECONDS)}class LockExpiredError extends Error{constructor(t){super(`Lock for resource "${t}" has been expired`)}}async function tryGetUserSessionAndRefresh(r){const t=await getCurrentTenant();if(!t)return null;let i=await getUserSession(t);if(!i)return null;if(isSessionExpired(i)&&(i=await refreshSession(i),isSessionExpired(i)))throw new UserSessionExpiredError;return i}async function refreshSession(r,t){return requireLock("refresh-session",i);async function i(n){const s=n;let a=await getUserSession(r)||r;if(!isSessionExpired(a)&&a.requiresSignIn)return a;const h=new Headers,v=new URLSearchParams;h.append(HEADER_CONTENT_TYPE,"application/x-www-form-urlencoded"),v.append("client_id","d8b1d8dd-c26d-4b54-8cde-5f3c8eb054ba"),v.append("grant_type","refresh_token"),v.append("refresh_token",a.refreshToken);try{const hi=await fetch(`${a.issuer}/connect/token`,{method:"POST",headers:h,body:v,signal:s});if(hi.ok){const u=await hi.json();if(isToken(u))return replaceUserSession({...a,requiresSignIn:!1,idToken:u.id_token,accessToken:u.access_token,refreshToken:u.refresh_token,expiresAt:now()+u.expires_in*ONE_SECOND})}else if(hi.status===400&&(a=await getUserSession(r)||r,isSessionExpired(a)))return replaceUserSession({...a,requiresSignIn:!0,lastTriedToRefresh:now()});return a}catch(hi){console.error(hi)}return a=await getUserSession(r)||r,isSessionExpired(a)?replaceUserSession({...a,lastTriedToRefresh:now()}):a}}function isToken(r){return isDictionary(r)&&"access_token"in r}class UserSessionExpiredError extends Error{constructor(){super("User session has been expired")}}async function getHttpOptions(r){const t=await tryGetUserSessionAndRefresh(),i=isURL(r)?r:new URL(r,t?.apiUrl??"https://api.chillicream.com").href,n=getHeaders(t?.accessToken);return{uri:i,headers:n}}function getHeaders(r){const t=new Headers;if(t.set("CCC-Agent",APP_AGENT),t.set("GraphQL-Agent",APP_AGENT),t.set("GraphQL-Client-Id",APP_GRAPHQL_CLIENT_ID),t.set("GraphQL-Client-Version",APP_VERSION),t.set("GraphQL-Defer-RFC","v2"),r)t.set("Authorization",`Bearer ${r}`);else throw new UserSessionExpiredError;return t}var RelayConcreteNode_1,hasRequiredRelayConcreteNode;function requireRelayConcreteNode(){if(hasRequiredRelayConcreteNode)return RelayConcreteNode_1;hasRequiredRelayConcreteNode=1;var r={ACTOR_CHANGE:"ActorChange",CATCH_FIELD:"CatchField",CONDITION:"Condition",CLIENT_COMPONENT:"ClientComponent",CLIENT_EDGE_TO_SERVER_OBJECT:"ClientEdgeToServerObject",CLIENT_EDGE_TO_CLIENT_OBJECT:"ClientEdgeToClientObject",CLIENT_EXTENSION:"ClientExtension",DEFER:"Defer",CONNECTION:"Connection",FRAGMENT:"Fragment",FRAGMENT_SPREAD:"FragmentSpread",INLINE_DATA_FRAGMENT_SPREAD:"InlineDataFragmentSpread",INLINE_DATA_FRAGMENT:"InlineDataFragment",INLINE_FRAGMENT:"InlineFragment",LINKED_FIELD:"LinkedField",LINKED_HANDLE:"LinkedHandle",LITERAL:"Literal",LIST_VALUE:"ListValue",LOCAL_ARGUMENT:"LocalArgument",MODULE_IMPORT:"ModuleImport",ALIASED_FRAGMENT_SPREAD:"AliasedFragmentSpread",ALIASED_INLINE_FRAGMENT_SPREAD:"AliasedInlineFragmentSpread",RELAY_RESOLVER:"RelayResolver",RELAY_LIVE_RESOLVER:"RelayLiveResolver",REQUIRED_FIELD:"RequiredField",OBJECT_VALUE:"ObjectValue",OPERATION:"Operation",REQUEST:"Request",ROOT_ARGUMENT:"RootArgument",SCALAR_FIELD:"ScalarField",SCALAR_HANDLE:"ScalarHandle",SPLIT_OPERATION:"SplitOperation",STREAM:"Stream",TYPE_DISCRIMINATOR:"TypeDiscriminator",UPDATABLE_QUERY:"UpdatableQuery",VARIABLE:"Variable"};return RelayConcreteNode_1=r,RelayConcreteNode_1}var browser,hasRequiredBrowser;function requireBrowser(){if(hasRequiredBrowser)return browser;hasRequiredBrowser=1;var r=function(t,i,n,s,a,h,v,hi){if(!t){var u;if(i===void 0)u=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var l=[n,s,a,h,v,hi],vi=0;u=new Error(i.replace(/%s/g,function(){return l[vi++]})),u.name="Invariant Violation"}throw u.framesToPop=1,u}};return browser=r,browser}var emptyFunction_1,hasRequiredEmptyFunction;function requireEmptyFunction(){if(hasRequiredEmptyFunction)return emptyFunction_1;hasRequiredEmptyFunction=1;function r(i){return function(){return i}}var t=function(){};return t.thatReturns=r,t.thatReturnsFalse=r(!1),t.thatReturnsTrue=r(!0),t.thatReturnsNull=r(null),t.thatReturnsThis=function(){return this},t.thatReturnsArgument=function(i){return i},emptyFunction_1=t,emptyFunction_1}var warning_1,hasRequiredWarning;function requireWarning(){if(hasRequiredWarning)return warning_1;hasRequiredWarning=1;var r=requireEmptyFunction(),t=r;return warning_1=t,warning_1}var GraphQLTag,hasRequiredGraphQLTag;function requireGraphQLTag(){if(hasRequiredGraphQLTag)return GraphQLTag;hasRequiredGraphQLTag=1;var r=requireRelayConcreteNode(),t=requireBrowser();requireWarning();function i(gi){t(!1)}function n(gi){var bi=gi;return typeof bi=="function"?bi=bi():bi.default&&(bi=bi.default),bi}function s(gi){var bi=n(gi);return typeof bi=="object"&&bi!==null&&bi.kind===r.FRAGMENT}function a(gi){var bi=n(gi);return typeof bi=="object"&&bi!==null&&bi.kind===r.REQUEST}function h(gi){var bi=n(gi);return typeof bi=="object"&&bi!==null&&bi.kind===r.UPDATABLE_QUERY}function v(gi){var bi=n(gi);return typeof bi=="object"&&bi!==null&&bi.kind===r.INLINE_DATA_FRAGMENT}function hi(gi){var bi=n(gi);return s(bi)||t(!1),bi}function u(gi){var bi,Ri=hi(gi),Ti=(bi=Ri.metadata)===null||bi===void 0?void 0:bi.refetch,Ii=Ti?.connection;return Ti===null||typeof Ti!="object"||Ii===null||typeof Ii!="object"?null:Ri}function l(gi){var bi,Ri=hi(gi),Ti=(bi=Ri.metadata)===null||bi===void 0?void 0:bi.refetch;return Ti===null||typeof Ti!="object"?null:Ri}function vi(gi){var bi=n(gi);return a(bi)||t(!1),bi}function D(gi){var bi=n(gi);return h(bi)||t(!1),bi}function mi(gi){var bi=n(gi);return v(bi)||t(!1),bi}return GraphQLTag={getFragment:hi,getInlineDataFragment:mi,getNode:n,getPaginationFragment:u,getRefetchableFragment:l,getRequest:vi,getUpdatableQuery:D,graphql:i,isFragment:s,isInlineDataFragment:v,isRequest:a,isUpdatableQuery:h},GraphQLTag}var interopRequireDefault={exports:{}},hasRequiredInteropRequireDefault;function requireInteropRequireDefault(){return hasRequiredInteropRequireDefault||(hasRequiredInteropRequireDefault=1,function(r){function t(i){return i&&i.__esModule?i:{default:i}}r.exports=t,r.exports.__esModule=!0,r.exports.default=r.exports}(interopRequireDefault)),interopRequireDefault.exports}var objectSpread2={exports:{}},defineProperty={exports:{}},toPropertyKey={exports:{}},_typeof={exports:{}},hasRequired_typeof;function require_typeof(){return hasRequired_typeof||(hasRequired_typeof=1,function(r){function t(i){"@babel/helpers - typeof";return r.exports=t=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},r.exports.__esModule=!0,r.exports.default=r.exports,t(i)}r.exports=t,r.exports.__esModule=!0,r.exports.default=r.exports}(_typeof)),_typeof.exports}var toPrimitive={exports:{}},hasRequiredToPrimitive;function requireToPrimitive(){return hasRequiredToPrimitive||(hasRequiredToPrimitive=1,function(r){var t=require_typeof().default;function i(n,s){if(t(n)!="object"||!n)return n;var a=n[Symbol.toPrimitive];if(a!==void 0){var h=a.call(n,s||"default");if(t(h)!="object")return h;throw new TypeError("@@toPrimitive must return a primitive value.")}return(s==="string"?String:Number)(n)}r.exports=i,r.exports.__esModule=!0,r.exports.default=r.exports}(toPrimitive)),toPrimitive.exports}var hasRequiredToPropertyKey;function requireToPropertyKey(){return hasRequiredToPropertyKey||(hasRequiredToPropertyKey=1,function(r){var t=require_typeof().default,i=requireToPrimitive();function n(s){var a=i(s,"string");return t(a)=="symbol"?a:a+""}r.exports=n,r.exports.__esModule=!0,r.exports.default=r.exports}(toPropertyKey)),toPropertyKey.exports}var hasRequiredDefineProperty;function requireDefineProperty(){return hasRequiredDefineProperty||(hasRequiredDefineProperty=1,function(r){var t=requireToPropertyKey();function i(n,s,a){return(s=t(s))in n?Object.defineProperty(n,s,{value:a,enumerable:!0,configurable:!0,writable:!0}):n[s]=a,n}r.exports=i,r.exports.__esModule=!0,r.exports.default=r.exports}(defineProperty)),defineProperty.exports}var hasRequiredObjectSpread2;function requireObjectSpread2(){return hasRequiredObjectSpread2||(hasRequiredObjectSpread2=1,function(r){var t=requireDefineProperty();function i(s,a){var h=Object.keys(s);if(Object.getOwnPropertySymbols){var v=Object.getOwnPropertySymbols(s);a&&(v=v.filter(function(hi){return Object.getOwnPropertyDescriptor(s,hi).enumerable})),h.push.apply(h,v)}return h}function n(s){for(var a=1;a<arguments.length;a++){var h=arguments[a]!=null?arguments[a]:{};a%2?i(Object(h),!0).forEach(function(v){t(s,v,h[v])}):Object.getOwnPropertyDescriptors?Object.defineProperties(s,Object.getOwnPropertyDescriptors(h)):i(Object(h)).forEach(function(v){Object.defineProperty(s,v,Object.getOwnPropertyDescriptor(h,v))})}return s}r.exports=n,r.exports.__esModule=!0,r.exports.default=r.exports}(objectSpread2)),objectSpread2.exports}var createForOfIteratorHelper={exports:{}},unsupportedIterableToArray={exports:{}},arrayLikeToArray={exports:{}},hasRequiredArrayLikeToArray;function requireArrayLikeToArray(){return hasRequiredArrayLikeToArray||(hasRequiredArrayLikeToArray=1,function(r){function t(i,n){(n==null||n>i.length)&&(n=i.length);for(var s=0,a=Array(n);s<n;s++)a[s]=i[s];return a}r.exports=t,r.exports.__esModule=!0,r.exports.default=r.exports}(arrayLikeToArray)),arrayLikeToArray.exports}var hasRequiredUnsupportedIterableToArray;function requireUnsupportedIterableToArray(){return hasRequiredUnsupportedIterableToArray||(hasRequiredUnsupportedIterableToArray=1,function(r){var t=requireArrayLikeToArray();function i(n,s){if(n){if(typeof n=="string")return t(n,s);var a={}.toString.call(n).slice(8,-1);return a==="Object"&&n.constructor&&(a=n.constructor.name),a==="Map"||a==="Set"?Array.from(n):a==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(a)?t(n,s):void 0}}r.exports=i,r.exports.__esModule=!0,r.exports.default=r.exports}(unsupportedIterableToArray)),unsupportedIterableToArray.exports}var hasRequiredCreateForOfIteratorHelper;function requireCreateForOfIteratorHelper(){return hasRequiredCreateForOfIteratorHelper||(hasRequiredCreateForOfIteratorHelper=1,function(r){var t=requireUnsupportedIterableToArray();function i(n,s){var a=typeof Symbol<"u"&&n[Symbol.iterator]||n["@@iterator"];if(!a){if(Array.isArray(n)||(a=t(n))||s&&n&&typeof n.length=="number"){a&&(n=a);var h=0,v=function(){};return{s:v,n:function(){return h>=n.length?{done:!0}:{done:!1,value:n[h++]}},e:function(D){throw D},f:v}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
118
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var hi,u=!0,l=!1;return{s:function(){a=a.call(n)},n:function(){var D=a.next();return u=D.done,D},e:function(D){l=!0,hi=D},f:function(){try{u||a.return==null||a.return()}finally{if(l)throw hi}}}}r.exports=i,r.exports.__esModule=!0,r.exports.default=r.exports}(createForOfIteratorHelper)),createForOfIteratorHelper.exports}var handlePotentialSnapshotErrors_1,hasRequiredHandlePotentialSnapshotErrors;function requireHandlePotentialSnapshotErrors(){if(hasRequiredHandlePotentialSnapshotErrors)return handlePotentialSnapshotErrors_1;hasRequiredHandlePotentialSnapshotErrors=1;var r=requireInteropRequireDefault().default,t=r(requireObjectSpread2()),i=r(requireCreateForOfIteratorHelper()),n=requireBrowser();function s(v,hi,u){var l=(0,i.default)(hi),vi;try{for(l.s();!(vi=l.n()).done;){var D=vi.value;v.relayFieldLogger((0,t.default)((0,t.default)({},D),{},{uiContext:u}))}}catch(Ri){l.e(Ri)}finally{l.f()}var mi=(0,i.default)(hi),gi;try{for(mi.s();!(gi=mi.n()).done;){var bi=gi.value;if(a(bi))switch(bi.kind){case"relay_resolver.error":throw new Error("Relay: Resolver error at path '".concat(bi.fieldPath,"' in '").concat(bi.owner,"'. Message: ").concat(bi.error.message));case"relay_field_payload.error":throw new Error("Relay: Unexpected response payload - check server logs for details.");case"missing_expected_data.throw":throw new Error("Relay: Missing expected data at path '".concat(bi.fieldPath,"' in '").concat(bi.owner,"'."));case"missing_required_field.throw":throw new Error("Relay: Missing @required value at path '".concat(bi.fieldPath,"' in '").concat(bi.owner,"'."));case"missing_required_field.log":case"missing_expected_data.log":break;default:bi.kind,n(!1)}}}catch(Ri){mi.e(Ri)}finally{mi.f()}}function a(v){switch(v.kind){case"relay_resolver.error":case"relay_field_payload.error":return v.shouldThrow&&!v.handled;case"missing_expected_data.throw":case"missing_required_field.throw":return!v.handled;case"missing_required_field.log":case"missing_expected_data.log":return!1;default:throw v.kind,new Error("Relay: Unexpected event kind")}}function h(v,hi,u){hi!=null&&s(v,hi,u)}return handlePotentialSnapshotErrors_1={eventShouldThrow:a,handlePotentialSnapshotErrors:h},handlePotentialSnapshotErrors_1}var toConsumableArray={exports:{}},arrayWithoutHoles={exports:{}},hasRequiredArrayWithoutHoles;function requireArrayWithoutHoles(){return hasRequiredArrayWithoutHoles||(hasRequiredArrayWithoutHoles=1,function(r){var t=requireArrayLikeToArray();function i(n){if(Array.isArray(n))return t(n)}r.exports=i,r.exports.__esModule=!0,r.exports.default=r.exports}(arrayWithoutHoles)),arrayWithoutHoles.exports}var iterableToArray={exports:{}},hasRequiredIterableToArray;function requireIterableToArray(){return hasRequiredIterableToArray||(hasRequiredIterableToArray=1,function(r){function t(i){if(typeof Symbol<"u"&&i[Symbol.iterator]!=null||i["@@iterator"]!=null)return Array.from(i)}r.exports=t,r.exports.__esModule=!0,r.exports.default=r.exports}(iterableToArray)),iterableToArray.exports}var nonIterableSpread={exports:{}},hasRequiredNonIterableSpread;function requireNonIterableSpread(){return hasRequiredNonIterableSpread||(hasRequiredNonIterableSpread=1,function(r){function t(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
119
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}r.exports=t,r.exports.__esModule=!0,r.exports.default=r.exports}(nonIterableSpread)),nonIterableSpread.exports}var hasRequiredToConsumableArray;function requireToConsumableArray(){return hasRequiredToConsumableArray||(hasRequiredToConsumableArray=1,function(r){var t=requireArrayWithoutHoles(),i=requireIterableToArray(),n=requireUnsupportedIterableToArray(),s=requireNonIterableSpread();function a(h){return t(h)||i(h)||n(h)||s()}r.exports=a,r.exports.__esModule=!0,r.exports.default=r.exports}(toConsumableArray)),toConsumableArray.exports}var RelayDefaultHandleKey,hasRequiredRelayDefaultHandleKey;function requireRelayDefaultHandleKey(){return hasRequiredRelayDefaultHandleKey||(hasRequiredRelayDefaultHandleKey=1,RelayDefaultHandleKey={DEFAULT_HANDLE_KEY:""}),RelayDefaultHandleKey}var getRelayHandleKey_1,hasRequiredGetRelayHandleKey;function requireGetRelayHandleKey(){if(hasRequiredGetRelayHandleKey)return getRelayHandleKey_1;hasRequiredGetRelayHandleKey=1;var r=requireRelayDefaultHandleKey(),t=r.DEFAULT_HANDLE_KEY,i=requireBrowser();function n(s,a,h){return a&&a!==t?"__".concat(a,"_").concat(s):(h==null&&i(!1),"__".concat(h,"_").concat(s))}return getRelayHandleKey_1=n,getRelayHandleKey_1}var RelayFeatureFlags_1,hasRequiredRelayFeatureFlags;function requireRelayFeatureFlags(){if(hasRequiredRelayFeatureFlags)return RelayFeatureFlags_1;hasRequiredRelayFeatureFlags=1;var r={ENABLE_VARIABLE_CONNECTION_KEY:!1,ENABLE_RELAY_RESOLVERS:!1,ENABLE_GETFRAGMENTIDENTIFIER_OPTIMIZATION:!1,ENABLE_FRIENDLY_QUERY_NAME_GQL_URL:!1,ENABLE_DO_NOT_WRAP_LIVE_QUERY:!1,ENABLE_NOTIFY_SUBSCRIPTION:!1,BATCH_ASYNC_MODULE_UPDATES_FN:null,ENABLE_CONTAINERS_SUBSCRIBE_ON_COMMIT:!1,MAX_DATA_ID_LENGTH:null,STRING_INTERN_LEVEL:0,LOG_MISSING_RECORDS_IN_PROD:!1,ENABLE_STORE_ID_COLLISION_LOGGING:!1,ENABLE_NONCOMPLIANT_ERROR_HANDLING_ON_LISTS:!1,ENABLE_LOOSE_SUBSCRIPTION_ATTRIBUTION:!1,ENABLE_OPERATION_TRACKER_OPTIMISTIC_UPDATES:!1,ENABLE_RELAY_OPERATION_TRACKER_SUSPENSE:!1,PROCESS_OPTIMISTIC_UPDATE_BEFORE_SUBSCRIPTION:!1,MARK_RESOLVER_VALUES_AS_CLEAN_AFTER_FRAGMENT_REREAD:!1,ENABLE_CYLE_DETECTION_IN_VARIABLES:!1,ENABLE_ACTIVITY_COMPATIBILITY:!0,ENABLE_READ_TIME_RESOLVER_STORAGE_KEY_PREFIX:!0,ENABLE_USE_PAGINATION_IS_LOADING_FIX:!1,DISALLOW_NESTED_UPDATES:!1,ENABLE_TYPENAME_PREFIXED_DATA_ID:!1,ENABLE_UI_CONTEXT_ON_RELAY_LOGGER:!1,CHECK_ALL_FRAGMENTS_FOR_MISSING_CLIENT_EDGES:!1,FILTER_OUT_RELAY_RESOLVER_RECORDS:!1,OPTIMIZE_NOTIFY:!1,ENABLE_FIELD_GRANULAR_NOTIFICATIONS:!1,ENABLE_READER_FRAGMENTS_LOGGING:!1};return RelayFeatureFlags_1=r,RelayFeatureFlags_1}var stableCopy_1,hasRequiredStableCopy;function requireStableCopy(){if(hasRequiredStableCopy)return stableCopy_1;hasRequiredStableCopy=1;function r(i){if(!i||typeof i!="object")return i;if(Array.isArray(i))return i.map(r);for(var n=Object.keys(i).sort(),s={},a=0;a<n.length;a++)s[n[a]]=r(i[n[a]]);return s}function t(i){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:new Set;if(!i||typeof i!="object")return!1;if(n.has(i))return!0;var s=new Set(n);s.add(i);var a=Array.isArray(i)?i:Object.values(i);return a.some(function(h){return t(h,s)})}return stableCopy_1={hasCycle:t,stableCopy:r},stableCopy_1}var RelayStoreUtils_1,hasRequiredRelayStoreUtils;function requireRelayStoreUtils(){if(hasRequiredRelayStoreUtils)return RelayStoreUtils_1;hasRequiredRelayStoreUtils=1;var r=requireInteropRequireDefault().default,t=r(requireToConsumableArray()),i=requireGetRelayHandleKey(),n=requireRelayConcreteNode(),s=requireRelayFeatureFlags(),a=requireStableCopy(),h=a.stableCopy,v=requireBrowser(),hi=n.VARIABLE,u=n.LITERAL,l=n.OBJECT_VALUE,vi=n.LIST_VALUE,D="__errors",mi="__fieldGranularNotifications",gi="__module_component_",bi="__module_operation_",Ri="$r:";function Ti(yi,Ei){if(yi.kind===hi)return Ui(yi.variableName,Ei);if(yi.kind===u)return yi.value;if(yi.kind===l){var Ci={};return yi.fields.forEach(function(Fi){Ci[Fi.name]=Ti(Fi,Ei)}),Ci}else if(yi.kind===vi){var Ni=[];return yi.items.forEach(function(Fi){Fi!=null&&Ni.push(Ti(Fi,Ei))}),Ni}}function Ii(yi,Ei,Ci){var Ni={};return Ci&&(Ni[xi.FRAGMENT_POINTER_IS_WITHIN_UNMATCHED_TYPE_REFINEMENT]=!0),yi&&yi.forEach(function(Fi){Ni[Fi.name]=Ti(Fi,Ei)}),Ni}function qi(yi,Ei){var Ci=yi.dynamicKey,Ni=yi.handle,Fi=yi.key,Mi=yi.name,Si=yi.args,Ai=yi.filters,_i=i(Ni,Fi,Mi),Bi=null;return Si&&Ai&&Si.length!==0&&Ai.length!==0&&(Bi=Si.filter(function(Pi){return Ai.indexOf(Pi.name)>-1})),Ci&&(Bi=Bi!=null?[Ci].concat((0,t.default)(Bi)):[Ci]),Bi===null?_i:Hi(_i,Ii(Bi,Ei))}function Oi(yi,Ei){if(yi.storageKey)return yi.storageKey;var Ci=Li(yi),Ni=yi.name;return Ci&&Ci.length!==0?Hi(Ni,Ii(Ci,Ei)):Ni}function ki(yi,Ei){var Ci=Oi(yi,Ei);return s.ENABLE_READ_TIME_RESOLVER_STORAGE_KEY_PREFIX?"$r:"+Ci:Ci}function Li(yi){if(yi.kind==="RelayResolver"||yi.kind==="RelayLiveResolver"){var Ei;if(yi.args==null){var Ci;return(Ci=yi.fragment)===null||Ci===void 0?void 0:Ci.args}return((Ei=yi.fragment)===null||Ei===void 0?void 0:Ei.args)==null?yi.args:yi.args.concat(yi.fragment.args)}var Ni=typeof yi.args>"u"?void 0:yi.args;return Ni}function ji(yi,Ei){return Hi(yi,h(Ei))}function Hi(yi,Ei){if(!Ei)return yi;var Ci=[];for(var Ni in Ei)if(Ei.hasOwnProperty(Ni)){var Fi=Ei[Ni];if(Fi!=null){var Mi;Ci.push(Ni+":"+((Mi=JSON.stringify(Fi))!==null&&Mi!==void 0?Mi:"undefined"))}}return Ci.length===0?yi:yi+"(".concat(Ci.join(","),")")}function Ui(yi,Ei){return Ei.hasOwnProperty(yi)||v(!1),h(Ei[yi])}function Qi(yi){return"".concat(gi).concat(yi)}function $i(yi){return"".concat(bi).concat(yi)}function wi(yi,Ei){return"__fn:".concat(yi,":").concat(Ei)}var xi={ACTOR_IDENTIFIER_KEY:"__actorIdentifier",CLIENT_EDGE_TRAVERSAL_PATH:"__clientEdgeTraversalPath",FRAGMENTS_KEY:"__fragments",FRAGMENT_OWNER_KEY:"__fragmentOwner",FRAGMENT_POINTER_IS_WITHIN_UNMATCHED_TYPE_REFINEMENT:"$isWithinUnmatchedTypeRefinement",FRAGMENT_PROP_NAME_KEY:"__fragmentPropName",MODULE_COMPONENT_KEY:"__module_component",ERRORS_KEY:D,FIELD_GRANULAR_NOTIFICATIONS_KEY:mi,ID_KEY:"__id",REF_KEY:"__ref",REFS_KEY:"__refs",ROOT_ID:"client:root",ROOT_TYPE:"__Root",TYPENAME_KEY:"__typename",INVALIDATED_AT_KEY:"__invalidated_at",RELAY_RESOLVER_VALUE_KEY:"__resolverValue",RELAY_RESOLVER_INVALIDATION_KEY:"__resolverValueMayBeInvalid",RELAY_RESOLVER_SNAPSHOT_KEY:"__resolverSnapshot",RELAY_RESOLVER_ERROR_KEY:"__resolverError",RELAY_RESOLVER_OUTPUT_TYPE_RECORD_IDS:"__resolverOutputTypeRecordIDs",RELAY_RESOLVER_RECORD_TYPENAME:"__RELAY_RESOLVER__",RELAY_READ_TIME_RESOLVER_KEY_PREFIX:Ri,formatStorageKey:Hi,getArgumentValue:Ti,getArgumentValues:Ii,getHandleStorageKey:qi,getStorageKey:Oi,getReadTimeResolverStorageKey:ki,getStableStorageKey:ji,getModuleComponentKey:Qi,getModuleOperationKey:$i,getFieldNotificationKey:wi};return RelayStoreUtils_1=xi,RelayStoreUtils_1}var RelayConcreteVariables,hasRequiredRelayConcreteVariables;function requireRelayConcreteVariables(){if(hasRequiredRelayConcreteVariables)return RelayConcreteVariables;hasRequiredRelayConcreteVariables=1;var r=requireInteropRequireDefault().default,t=r(requireObjectSpread2()),i=requireRelayStoreUtils(),n=i.getArgumentValues,s=requireBrowser();function a(hi,u,l){if(hi.argumentDefinitions==null)return l;var vi;return hi.argumentDefinitions.forEach(function(D){if(!l.hasOwnProperty(D.name))switch(vi=vi||(0,t.default)({},l),D.kind){case"LocalArgument":vi[D.name]=D.defaultValue;break;case"RootArgument":if(!u.hasOwnProperty(D.name)){vi[D.name]=void 0;break}vi[D.name]=u[D.name];break;default:s(!1)}}),vi||l}function h(hi,u,l){var vi={};return hi.argumentDefinitions.forEach(function(D){var mi=D.defaultValue;l[D.name]!=null&&(mi=l[D.name]),vi[D.name]=mi}),u!=null&&Object.keys(u).forEach(function(D){vi[D]=u[D].get()}),vi}function v(hi,u,l){if(u==null)return hi;var vi=(0,t.default)({},hi),D=l?n(l,hi):{};return u.forEach(function(mi){var gi,bi=(gi=D[mi.name])!==null&&gi!==void 0?gi:mi.defaultValue;vi[mi.name]=bi}),vi}return RelayConcreteVariables={getFragmentVariables:a,getLocalVariables:v,getOperationVariables:h},RelayConcreteVariables}var areEqual_1,hasRequiredAreEqual;function requireAreEqual(){if(hasRequiredAreEqual)return areEqual_1;hasRequiredAreEqual=1;var r=[],t=[];/**
120
+ * Checks if two values are equal. Values may be primitives, arrays, or objects.
121
+ * Returns true if both arguments have the same keys and values.
122
+ *
123
+ * @see http://underscorejs.org
124
+ * @copyright 2009-2013 Jeremy Ashkenas, DocumentCloud Inc.
125
+ * @license MIT
126
+ */function i(s,a){var h=r.length?r.pop():[],v=t.length?t.pop():[],hi=n(s,a,h,v);return h.length=0,v.length=0,r.push(h),t.push(v),hi}function n(s,a,h,v){if(s===a)return s!==0||1/s==1/a;if(s==null||a==null||typeof s!="object"||typeof a!="object")return!1;var hi=Object.prototype.toString,u=hi.call(s);if(u!=hi.call(a))return!1;switch(u){case"[object String]":return s==String(a);case"[object Number]":return isNaN(s)||isNaN(a)?!1:s==Number(a);case"[object Date]":case"[object Boolean]":return+s==+a;case"[object RegExp]":return s.source==a.source&&s.global==a.global&&s.multiline==a.multiline&&s.ignoreCase==a.ignoreCase}for(var l=h.length;l--;)if(h[l]==s)return v[l]==a;h.push(s),v.push(a);var vi=0;if(u==="[object Array]"){if(vi=s.length,vi!==a.length)return!1;for(;vi--;)if(!n(s[vi],a[vi],h,v))return!1}else{if(s.constructor!==a.constructor)return!1;if(s.hasOwnProperty("valueOf")&&a.hasOwnProperty("valueOf"))return s.valueOf()==a.valueOf();var D=Object.keys(s);if(D.length!=Object.keys(a).length)return!1;for(var mi=0;mi<D.length;mi++)if(!n(s[D[mi]],a[D[mi]],h,v))return!1}return h.pop(),v.pop(),!0}return areEqual_1=i,areEqual_1}var RelayModernSelector,hasRequiredRelayModernSelector;function requireRelayModernSelector(){if(hasRequiredRelayModernSelector)return RelayModernSelector;hasRequiredRelayModernSelector=1;var r=requireRelayConcreteVariables(),t=r.getFragmentVariables,i=requireRelayStoreUtils(),n=i.CLIENT_EDGE_TRAVERSAL_PATH,s=i.FRAGMENT_OWNER_KEY,a=i.FRAGMENT_POINTER_IS_WITHIN_UNMATCHED_TYPE_REFINEMENT,h=i.FRAGMENTS_KEY,v=i.ID_KEY,hi=requireAreEqual(),u=requireBrowser();requireWarning();function l(wi,xi){typeof xi=="object"&&xi!==null&&!Array.isArray(xi)||u(!1);var yi=xi[v],Ei=xi[h],Ci=xi[s],Ni=xi[n];if(typeof yi=="string"&&typeof Ei=="object"&&Ei!==null&&typeof Ei[wi.name]=="object"&&Ei[wi.name]!==null&&typeof Ci=="object"&&Ci!==null&&(Ni==null||Array.isArray(Ni))){var Fi=Ci,Mi=Ni,Si=Ei[wi.name],Ai=t(wi,Fi.variables,Si),_i=Si[a]===!0;return Qi(wi,yi,Ai,Fi,_i,Mi)}return null}function vi(wi,xi){var yi=null;return xi.forEach(function(Ei,Ci){var Ni=Ei!=null?l(wi,Ei):null;Ni!=null&&(yi=yi||[],yi.push(Ni))}),yi==null?null:{kind:"PluralReaderSelector",selectors:yi}}function D(wi,xi){return xi==null?xi:wi.metadata&&wi.metadata.plural===!0?(Array.isArray(xi)||u(!1),vi(wi,xi)):(Array.isArray(xi)&&u(!1),l(wi,xi))}function mi(wi,xi){var yi={};for(var Ei in wi)if(wi.hasOwnProperty(Ei)){var Ci=wi[Ei],Ni=xi[Ei];yi[Ei]=D(Ci,Ni)}return yi}function gi(wi,xi){var yi={};for(var Ei in wi)if(wi.hasOwnProperty(Ei)){var Ci=wi[Ei],Ni=xi[Ei];yi[Ei]=bi(Ci,Ni)}return yi}function bi(wi,xi){return xi==null?xi:wi.metadata&&wi.metadata.plural===!0?(Array.isArray(xi)||u(!1),Ri(wi,xi)):(Array.isArray(xi)&&u(!1),Ti(wi,xi))}function Ri(wi,xi){var yi=null;return xi.forEach(function(Ei){var Ci=Ei!=null?Ti(wi,Ei):null;Ci!=null&&(yi=yi||[],yi.push(Ci))}),yi}function Ti(wi,xi){typeof xi=="object"&&xi!==null&&!Array.isArray(xi)||u(!1);var yi=xi[v];return typeof yi=="string"?yi:null}function Ii(wi,xi){var yi={};for(var Ei in wi)if(wi.hasOwnProperty(Ei)){var Ci=wi[Ei],Ni=xi[Ei],Fi=qi(Ci,Ni);Object.assign(yi,Fi)}return yi}function qi(wi,xi){var yi;return xi==null?{}:((yi=wi.metadata)===null||yi===void 0?void 0:yi.plural)===!0?(Array.isArray(xi)||u(!1),ki(wi,xi)):(Array.isArray(xi)&&u(!1),Oi(wi,xi)||{})}function Oi(wi,xi){var yi=l(wi,xi);return yi?yi.variables:null}function ki(wi,xi){var yi={};return xi.forEach(function(Ei,Ci){if(Ei!=null){var Ni=Oi(wi,Ei);Ni!=null&&Object.assign(yi,Ni)}}),yi}function Li(wi,xi){return wi.dataID===xi.dataID&&wi.node===xi.node&&hi(wi.variables,xi.variables)&&ji(wi.owner,xi.owner)&&wi.isWithinUnmatchedTypeRefinement===xi.isWithinUnmatchedTypeRefinement&&Hi(wi.clientEdgeTraversalPath,xi.clientEdgeTraversalPath)}function ji(wi,xi){return wi===xi?!0:wi.identifier===xi.identifier&&hi(wi.cacheConfig,xi.cacheConfig)}function Hi(wi,xi){if(wi===xi)return!0;if(wi==null||xi==null||wi.length!==xi.length)return!1;for(var yi=wi.length;yi--;){var Ei=wi[yi],Ci=xi[yi];if(Ei!==Ci&&(Ei==null||Ci==null||Ei.clientEdgeDestinationID!==Ci.clientEdgeDestinationID||Ei.readerClientEdge!==Ci.readerClientEdge))return!1}return!0}function Ui(wi,xi){return wi===xi?!0:wi==null?xi==null:xi==null?wi==null:wi.kind==="SingularReaderSelector"&&xi.kind==="SingularReaderSelector"?Li(wi,xi):wi.kind==="PluralReaderSelector"&&xi.kind==="PluralReaderSelector"?wi.selectors.length===xi.selectors.length&&wi.selectors.every(function(yi,Ei){return Li(yi,xi.selectors[Ei])}):!1}function Qi(wi,xi,yi,Ei){var Ci=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1,Ni=arguments.length>5?arguments[5]:void 0;return{clientEdgeTraversalPath:Ni??null,dataID:xi,isWithinUnmatchedTypeRefinement:Ci,kind:"SingularReaderSelector",node:wi,owner:Ei,variables:yi}}function $i(wi,xi,yi){return{dataID:xi,node:wi,variables:yi}}return RelayModernSelector={areEqualSelectors:Ui,createNormalizationSelector:$i,createReaderSelector:Qi,getDataIDsFromFragment:bi,getDataIDsFromObject:gi,getPluralSelector:vi,getSelector:D,getSelectorsFromObject:mi,getSingularSelector:l,getVariablesFromFragment:qi,getVariablesFromObject:Ii,getVariablesFromPluralFragment:ki,getVariablesFromSingularFragment:Oi},RelayModernSelector}var ResolverFragments,hasRequiredResolverFragments;function requireResolverFragments(){if(hasRequiredResolverFragments)return ResolverFragments;hasRequiredResolverFragments=1;var r=requireGraphQLTag(),t=r.getFragment,i=requireHandlePotentialSnapshotErrors(),n=i.eventShouldThrow,s=requireRelayModernSelector(),a=s.getSelector,h=requireBrowser(),v=[];function hi(vi,D){v.push(vi);try{return D()}finally{v.pop()}}function u(vi,D){if(!v.length)throw new Error("readFragment should be called only from within a Relay Resolver function.");var mi=v[v.length-1],gi=t(vi),bi=a(gi,D);bi==null&&h(!1),bi.kind!=="SingularReaderSelector"&&h(!1);var Ri=mi.getDataForResolverFragment(bi,D),Ti=Ri.data,Ii=Ri.isMissingData,qi=Ri.fieldErrors;if(Ii||qi!=null&&qi.some(n))throw l;return Ti}var l={};return ResolverFragments={RESOLVER_FRAGMENT_ERRORED_SENTINEL:l,readFragment:u,withResolverContext:hi},ResolverFragments}var resolverDataInjector_1,hasRequiredResolverDataInjector;function requireResolverDataInjector(){if(hasRequiredResolverDataInjector)return resolverDataInjector_1;hasRequiredResolverDataInjector=1;var r=requireResolverFragments(),t=r.readFragment,i=requireBrowser();function n(s,a,h,v){var hi=a;return function(u,l,vi){var D=t(s,u);if(h!=null){if(D==null)if(v===!0)i(!1);else return hi(null,l,vi);if(h in D)return v===!0&&D[h]==null&&i(!1),hi(D[h],l,vi);i(!1)}else return hi(null,l,vi)}}return resolverDataInjector_1=n,resolverDataInjector_1}var asyncToGenerator={exports:{}},hasRequiredAsyncToGenerator;function requireAsyncToGenerator(){return hasRequiredAsyncToGenerator||(hasRequiredAsyncToGenerator=1,function(r){function t(n,s,a,h,v,hi,u){try{var l=n[hi](u),vi=l.value}catch(D){return void a(D)}l.done?s(vi):Promise.resolve(vi).then(h,v)}function i(n){return function(){var s=this,a=arguments;return new Promise(function(h,v){var hi=n.apply(s,a);function u(vi){t(hi,h,v,u,l,"next",vi)}function l(vi){t(hi,h,v,u,l,"throw",vi)}u(void 0)})}}r.exports=i,r.exports.__esModule=!0,r.exports.default=r.exports}(asyncToGenerator)),asyncToGenerator.exports}var isPromise_1,hasRequiredIsPromise;function requireIsPromise(){if(hasRequiredIsPromise)return isPromise_1;hasRequiredIsPromise=1;function r(t){return t!=null&&typeof t=="object"&&typeof t.then=="function"}return isPromise_1=r,isPromise_1}var RelayObservable_1,hasRequiredRelayObservable;function requireRelayObservable(){if(hasRequiredRelayObservable)return RelayObservable_1;hasRequiredRelayObservable=1;var r=requireIsPromise(),t=hi,i=function(){u.create=function(D){return new u(D)};function u(vi){this._source=vi}u.onUnhandledError=function(D){t=D},u.from=function(D){return n(D)?s(D):r(D)?a(D):h(D)};var l=u.prototype;return l.catch=function(D){var mi=this;return u.create(function(gi){var bi;return mi.subscribe({start:function(Ti){bi=Ti},next:gi.next,complete:gi.complete,error:function(Ti){try{D(Ti).subscribe({start:function(qi){bi=qi},next:gi.next,complete:gi.complete,error:gi.error})}catch(Ii){gi.error(Ii,!0)}}}),function(){return bi.unsubscribe()}})},l.concat=function(D){var mi=this;return u.create(function(gi){var bi;return mi.subscribe({start:function(Ti){bi=Ti},next:gi.next,error:gi.error,complete:function(){bi=D.subscribe(gi)}}),function(){bi&&bi.unsubscribe()}})},l.do=function(D){var mi=this;return u.create(function(gi){var bi=function(Ti){return function(){try{D[Ti]&&D[Ti].apply(D,arguments)}catch(Ii){t(Ii,!0)}gi[Ti]&&gi[Ti].apply(gi,arguments)}};return mi.subscribe({start:bi("start"),next:bi("next"),error:bi("error"),complete:bi("complete"),unsubscribe:bi("unsubscribe")})})},l.finally=function(D){var mi=this;return u.create(function(gi){var bi=mi.subscribe(gi);return function(){bi.unsubscribe(),D()}})},l.ifEmpty=function(D){var mi=this;return u.create(function(gi){var bi=!1,Ri;return Ri=mi.subscribe({next:function(Ii){bi=!0,gi.next(Ii)},error:gi.error,complete:function(){bi?gi.complete():Ri=D.subscribe(gi)}}),function(){Ri&&Ri.unsubscribe()}})},l.subscribe=function(D){return v(this._source,D)},l.map=function(D){var mi=this;return u.create(function(gi){var bi=mi.subscribe({complete:gi.complete,error:gi.error,next:function(Ti){try{var Ii=D(Ti);gi.next(Ii)}catch(qi){gi.error(qi,!0)}}});return function(){bi.unsubscribe()}})},l.mergeMap=function(D){var mi=this;return u.create(function(gi){var bi=[];function Ri(Ii){this._sub=Ii,bi.push(Ii)}function Ti(){bi.splice(bi.indexOf(this._sub),1),bi.length===0&&gi.complete()}return mi.subscribe({start:Ri,next:function(qi){try{gi.closed||u.from(D(qi)).subscribe({start:Ri,next:gi.next,error:gi.error,complete:Ti})}catch(Oi){gi.error(Oi,!0)}},error:gi.error,complete:Ti}),function(){bi.forEach(function(Ii){return Ii.unsubscribe()}),bi.length=0}})},l.poll=function(D){var mi=this;return u.create(function(gi){var bi,Ri,Ti=function Ii(){bi=mi.subscribe({next:gi.next,error:gi.error,complete:function(){Ri=setTimeout(Ii,D)}})};return Ti(),function(){clearTimeout(Ri),bi.unsubscribe()}})},l.toPromise=function(){var D=this;return new Promise(function(mi,gi){var bi=!1;D.subscribe({next:function(Ti){bi||(bi=!0,mi(Ti))},error:gi,complete:mi})})},u}();function n(u){return typeof u=="object"&&u!==null&&typeof u.subscribe=="function"}function s(u){return u instanceof i?u:i.create(function(l){return u.subscribe(l)})}function a(u){return i.create(function(l){u.then(function(vi){l.next(vi),l.complete()},l.error)})}function h(u){return i.create(function(l){l.next(u),l.complete()})}function v(u,l){var vi=!1,D,mi=function(Ii){return Object.defineProperty(Ii,"closed",{get:function(){return vi}})};function gi(){if(D){if(D.unsubscribe)D.unsubscribe();else try{D()}catch(Ti){t(Ti,!0)}D=void 0}}var bi=mi({unsubscribe:function(){if(!vi){vi=!0;try{l.unsubscribe&&l.unsubscribe(bi)}catch(Ii){t(Ii,!0)}finally{gi()}}}});try{l.start&&l.start(bi)}catch(Ti){t(Ti,!0)}if(vi)return bi;var Ri=mi({next:function(Ii){if(!vi&&l.next)try{l.next(Ii)}catch(qi){t(qi,!0)}},error:function(Ii,qi){if(vi||!l.error)vi=!0,t(Ii,qi||!1),gi();else{vi=!0;try{l.error(Ii)}catch(Oi){t(Oi,!0)}finally{gi()}}},complete:function(){if(!vi){vi=!0;try{l.complete&&l.complete()}catch(Ii){t(Ii,!0)}finally{gi()}}}});try{D=u(Ri)}catch(Ti){Ri.error(Ti,!0)}return vi&&gi(),bi}function hi(u,l){}return RelayObservable_1=i,RelayObservable_1}var RelayReplaySubject_1,hasRequiredRelayReplaySubject;function requireRelayReplaySubject(){if(hasRequiredRelayReplaySubject)return RelayReplaySubject_1;hasRequiredRelayReplaySubject=1;var r=requireInteropRequireDefault().default,t=r(requireCreateForOfIteratorHelper()),i=r(requireDefineProperty()),n=requireRelayObservable(),s=requireBrowser(),a=function(){function h(){var hi=this;(0,i.default)(this,"_complete",!1),(0,i.default)(this,"_events",[]),(0,i.default)(this,"_sinks",new Set),(0,i.default)(this,"_subscription",[]),this._observable=n.create(function(u){hi._sinks.add(u);for(var l=hi._events,vi=0;vi<l.length&&!u.closed;vi++){var D=l[vi];switch(D.kind){case"complete":u.complete();break;case"error":u.error(D.error);break;case"next":u.next(D.data);break;default:D.kind,s(!1)}}return function(){hi._sinks.delete(u)}})}var v=h.prototype;return v.complete=function(){this._complete!==!0&&(this._complete=!0,this._events.push({kind:"complete"}),this._sinks.forEach(function(u){return u.complete()}))},v.error=function(u){this._complete!==!0&&(this._complete=!0,this._events.push({error:u,kind:"error"}),this._sinks.forEach(function(l){return l.error(u)}))},v.next=function(u){this._complete!==!0&&(this._events.push({data:u,kind:"next"}),this._sinks.forEach(function(l){return l.next(u)}))},v.subscribe=function(u){var l=this._observable.subscribe(u);return this._subscription.push(l),l},v.unsubscribe=function(){var u=(0,t.default)(this._subscription),l;try{for(u.s();!(l=u.n()).done;){var vi=l.value;vi.unsubscribe()}}catch(D){u.e(D)}finally{u.f()}this._subscription=[]},v.getObserverCount=function(){return this._sinks.size},h}();return RelayReplaySubject_1=a,RelayReplaySubject_1}var fetchQueryInternal,hasRequiredFetchQueryInternal;function requireFetchQueryInternal(){if(hasRequiredFetchQueryInternal)return fetchQueryInternal;hasRequiredFetchQueryInternal=1;var r=requireRelayObservable(),t=requireRelayReplaySubject(),i=requireBrowser(),n=typeof WeakMap=="function",s=n?new WeakMap:new Map;function a(mi,gi){return h(mi,gi.request.identifier,function(){return mi.execute({operation:gi})})}function h(mi,gi,bi){return r.create(function(Ri){var Ti=vi(mi),Ii=Ti.get(gi);return Ii||bi().finally(function(){return Ti.delete(gi)}).subscribe({start:function(Oi){Ii={identifier:gi,subject:new t,subjectForInFlightStatus:new t,subscription:Oi,promise:null},Ti.set(gi,Ii)},next:function(Oi){var ki=D(Ti,gi);ki.subject.next(Oi),ki.subjectForInFlightStatus.next(Oi)},error:function(Oi){var ki=D(Ti,gi);ki.subject.error(Oi),ki.subjectForInFlightStatus.error(Oi)},complete:function(){var Oi=D(Ti,gi);Oi.subject.complete(),Oi.subjectForInFlightStatus.complete()},unsubscribe:function(Oi){var ki=D(Ti,gi);ki.subject.unsubscribe(),ki.subjectForInFlightStatus.unsubscribe()}}),Ii==null&&i(!1),v(Ti,Ii).subscribe(Ri)})}function v(mi,gi){return r.create(function(bi){var Ri=gi.subject.subscribe(bi);return function(){Ri.unsubscribe();var Ti=mi.get(gi.identifier);if(Ti){var Ii=Ti.subscription;Ii!=null&&Ti.subject.getObserverCount()===0&&(Ii.unsubscribe(),mi.delete(gi.identifier))}}})}function hi(mi,gi,bi){return r.create(function(Ri){var Ti=bi.subjectForInFlightStatus.subscribe({error:Ri.error,next:function(qi){if(!mi.isRequestActive(bi.identifier)){Ri.complete();return}Ri.next()},complete:Ri.complete,unsubscribe:Ri.complete});return function(){Ti.unsubscribe()}})}function u(mi,gi){var bi=vi(mi),Ri=bi.get(gi.identifier);if(!Ri||!mi.isRequestActive(Ri.identifier))return null;var Ti=new Promise(function(Ii,qi){var Oi=!1;hi(mi,bi,Ri).subscribe({complete:Ii,error:qi,next:function(Li){Oi&&Ii(Li)}}),Oi=!0});return Ti}function l(mi,gi){var bi=vi(mi),Ri=bi.get(gi.identifier);return!Ri||!mi.isRequestActive(Ri.identifier)?null:hi(mi,bi,Ri)}function vi(mi){var gi=s.get(mi);if(gi!=null)return gi;var bi=new Map;return s.set(mi,bi),bi}function D(mi,gi){var bi=mi.get(gi);return bi==null&&i(!1),bi}return fetchQueryInternal={fetchQuery:a,fetchQueryDeduped:h,getPromiseForActiveRequest:u,getObservableForActiveRequest:l},fetchQueryInternal}var observeFragmentExperimental,hasRequiredObserveFragmentExperimental;function requireObserveFragmentExperimental(){if(hasRequiredObserveFragmentExperimental)return observeFragmentExperimental;hasRequiredObserveFragmentExperimental=1;var r=requireInteropRequireDefault().default,t=requireAsyncToGenerator().default,i=r(requireCreateForOfIteratorHelper()),n=requireRelayObservable(),s=requireFetchQueryInternal(),a=s.getObservableForActiveRequest,h=requireGraphQLTag(),v=h.getFragment,hi=requireHandlePotentialSnapshotErrors(),u=hi.handlePotentialSnapshotErrors,l=requireRelayModernSelector(),vi=l.getSelector,D=requireBrowser();function mi(ki,Li,ji){return gi.apply(this,arguments)}function gi(){return gi=t(function*(ki,Li,ji){var Hi;try{var Ui,Qi=yield new Promise(function(wi,xi){Hi=bi(ki,Li,ji).subscribe({next:function(Ei){Ei.state==="ok"?wi(Ei.value):Ei.state==="error"&&xi(Ei.error)}})});return(Ui=Hi)===null||Ui===void 0||Ui.unsubscribe(),Qi}catch(wi){var $i;throw($i=Hi)===null||$i===void 0||$i.unsubscribe(),wi}}),gi.apply(this,arguments)}function bi(ki,Li,ji){var Hi,Ui=v(Li),Qi=vi(Ui,ji);switch(Qi==null&&D(!1),((Hi=Ui.metadata)===null||Hi===void 0?void 0:Hi.hasClientEdges)==null||Ri(Qi)||D(!1),Qi.kind){case"SingularReaderSelector":return Ti(ki,Li,Qi);case"PluralReaderSelector":return Ii(ki,Li,Qi)}D(!1)}function Ri(ki){var Li,ji,Hi,Ui;switch(ki?.kind){case"SingularReaderSelector":return((Li=(ji=ki.owner.node.operation)===null||ji===void 0?void 0:ji.use_exec_time_resolvers)!==null&&Li!==void 0?Li:(Hi=ki.owner.node.operation)===null||Hi===void 0||(Ui=Hi.exec_time_resolvers_enabled_provider)===null||Ui===void 0?void 0:Ui.get())===!0;case"PluralReaderSelector":{var Qi;return(Qi=ki.selectors)===null||Qi===void 0?void 0:Qi.every(function($i){var wi,xi,yi;return((wi=$i.owner.node.operation.use_exec_time_resolvers)!==null&&wi!==void 0?wi:(xi=$i.owner.node.operation)===null||xi===void 0||(yi=xi.exec_time_resolvers_enabled_provider)===null||yi===void 0?void 0:yi.get())===!0})}}return!1}function Ti(ki,Li,ji){var Hi=ki.lookup(ji);return n.create(function(Ui){Ui.next(qi(ki,Li,ji.owner,Hi));var Qi=ki.subscribe(Hi,function($i){Ui.next(qi(ki,Li,ji.owner,$i))});return function(){return Qi.dispose()}})}function Ii(ki,Li,ji){var Hi=ji.selectors.map(function(Ui){return ki.lookup(Ui)});return n.create(function(Ui){var Qi=Hi.map(function(wi,xi){return qi(ki,Li,ji.selectors[xi].owner,wi)});Ui.next(Oi(Qi));var $i=Hi.map(function(wi,xi){return ki.subscribe(wi,function(yi){Qi[xi]=qi(ki,Li,ji.selectors[xi].owner,yi),Ui.next(Oi(Qi))})});return function(){return $i.forEach(function(wi){return wi.dispose()})}})}function qi(ki,Li,ji,Hi){var Ui=Hi.missingLiveResolverFields!=null&&Hi.missingLiveResolverFields.length>0,Qi=Hi.missingClientEdges!=null&&Hi.missingClientEdges.length>0;if(Ui||Qi)return{state:"loading"};if(Hi.isMissingData&&(a(ki,ji)!=null||ki.getOperationTracker().getPendingOperationsAffectingOwner(ji)!=null))return{state:"loading"};try{u(ki,Hi.fieldErrors)}catch($i){return{error:$i,state:"error"}}return Hi.data==null&&D(!1),{state:"ok",value:Hi.data}}function Oi(ki){var Li=[],ji=(0,i.default)(ki),Hi;try{for(ji.s();!(Hi=ji.n()).done;){var Ui=Hi.value;if(Ui.state==="ok")Li.push(Ui.value);else return Ui}}catch(Qi){ji.e(Qi)}finally{ji.f()}return{state:"ok",value:Li}}return observeFragmentExperimental={observeFragment:bi,waitForFragmentData:mi},observeFragmentExperimental}var deepFreeze_1,hasRequiredDeepFreeze;function requireDeepFreeze(){if(hasRequiredDeepFreeze)return deepFreeze_1;hasRequiredDeepFreeze=1;function r(i){return t(i)&&(Object.freeze(i),Object.getOwnPropertyNames(i).forEach(function(n){var s=i[n];s&&typeof s=="object"&&!Object.isFrozen(s)&&r(s)})),i}function t(i){return i!=null&&(Array.isArray(i)||typeof i=="object"&&i.constructor===Object)}return deepFreeze_1=r,deepFreeze_1}var getRequestIdentifier_1,hasRequiredGetRequestIdentifier;function requireGetRequestIdentifier(){if(hasRequiredGetRequestIdentifier)return getRequestIdentifier_1;hasRequiredGetRequestIdentifier=1;var r=requireStableCopy(),t=r.stableCopy,i=requireBrowser();function n(s,a){var h=s.cacheID!=null?s.cacheID:s.id;return h==null&&i(!1),h+JSON.stringify(t(a))}return getRequestIdentifier_1=n,getRequestIdentifier_1}var RelayModernOperationDescriptor,hasRequiredRelayModernOperationDescriptor;function requireRelayModernOperationDescriptor(){if(hasRequiredRelayModernOperationDescriptor)return RelayModernOperationDescriptor;hasRequiredRelayModernOperationDescriptor=1,requireDeepFreeze();var r=requireGetRequestIdentifier(),t=requireRelayFeatureFlags(),i=requireStableCopy(),n=i.hasCycle,s=requireRelayConcreteVariables(),a=s.getOperationVariables,h=requireRelayModernSelector(),v=h.createNormalizationSelector,hi=h.createReaderSelector,u=requireRelayStoreUtils(),l=u.ROOT_ID,vi=requireBrowser();function D(gi,bi,Ri){var Ti=arguments.length>3&&arguments[3]!==void 0?arguments[3]:l,Ii=gi.operation,qi=a(Ii,gi.params.providedVariables,bi);t.ENABLE_CYLE_DETECTION_IN_VARIABLES&&n(qi)&&vi(!1);var Oi=mi(gi,qi,Ri),ki={fragment:hi(gi.fragment,Ti,qi,Oi),request:Oi,root:v(Ii,Ti,qi)};return ki}function mi(gi,bi,Ri){var Ti={identifier:r(gi.params,bi),node:gi,variables:bi,cacheConfig:Ri};return Ti}return RelayModernOperationDescriptor={createOperationDescriptor:D,createRequestDescriptor:mi},RelayModernOperationDescriptor}var observeQueryExperimental,hasRequiredObserveQueryExperimental;function requireObserveQueryExperimental(){if(hasRequiredObserveQueryExperimental)return observeQueryExperimental;hasRequiredObserveQueryExperimental=1;var r=requireInteropRequireDefault().default,t=r(requireDefineProperty()),i=requireObserveFragmentExperimental(),n=i.observeFragment,s=requireRelayModernOperationDescriptor(),a=s.createOperationDescriptor;function h(v,hi,u){var l=a(hi,u),vi={__fragmentOwner:l.request,__fragments:(0,t.default)({},l.fragment.node.name,l.request.variables),__id:l.fragment.dataID},D=l.request.node.fragment;return n(v,D,vi)}return observeQueryExperimental={observeQuery:h},observeQueryExperimental}var waitForFragmentExperimental,hasRequiredWaitForFragmentExperimental;function requireWaitForFragmentExperimental(){if(hasRequiredWaitForFragmentExperimental)return waitForFragmentExperimental;hasRequiredWaitForFragmentExperimental=1;var r=requireAsyncToGenerator().default,t=requireObserveFragmentExperimental(),i=t.observeFragment;function n(a,h,v){return s.apply(this,arguments)}function s(){return s=r(function*(a,h,v){var hi;try{var u,l=yield new Promise(function(D,mi){hi=i(a,h,v).subscribe({next:function(bi){bi.state==="ok"?D(bi.value):bi.state==="error"&&mi(bi.error)}})});return(u=hi)===null||u===void 0||u.unsubscribe(),l}catch(D){var vi;throw(vi=hi)===null||vi===void 0||vi.unsubscribe(),D}}),s.apply(this,arguments)}return waitForFragmentExperimental={waitForFragmentData:n},waitForFragmentExperimental}var experimental,hasRequiredExperimental;function requireExperimental(){if(hasRequiredExperimental)return experimental;hasRequiredExperimental=1;var r=requireResolverDataInjector(),t=requireObserveFragmentExperimental(),i=t.observeFragment,n=requireObserveQueryExperimental(),s=n.observeQuery,a=requireWaitForFragmentExperimental(),h=a.waitForFragmentData;function v(u){return u.ok===!0}function hi(u){return u.ok===!1}return experimental={isErrorResult:hi,isValueResult:v,observeFragment:i,observeQuery:s,resolverDataInjector:r,waitForFragmentData:h},experimental}var StringInterner,hasRequiredStringInterner;function requireStringInterner(){if(hasRequiredStringInterner)return StringInterner;hasRequiredStringInterner=1;var r=new Map,t=1,i=a(),n=" ",s="\v";function a(){for(var hi=new Set,u=0;u<10;++u)hi.add(u.toString());return hi}function h(hi){return hi[0]===n&&i.has(hi[1])||hi[0]===s?s+hi:hi}function v(hi,u){if(u==null||hi.length<u)return h(hi);var l=r.get(hi);return l!=null||(l=n+t++,r.set(hi,l)),l}return StringInterner={intern:v},StringInterner}var ClientID,hasRequiredClientID;function requireClientID(){if(hasRequiredClientID)return ClientID;hasRequiredClientID=1;var r=requireRelayFeatureFlags(),t=requireStringInterner(),i=t.intern,n="client:";function s(u,l,vi){var D=r.STRING_INTERN_LEVEL<=0?u:i(u,r.MAX_DATA_ID_LENGTH),mi=D+":"+l;return vi!=null&&(mi+=":"+vi),mi.indexOf(n)!==0&&(mi=n+mi),mi}function a(u){return u.indexOf(n)===0}var h=0;function v(){return"".concat(n,"local:").concat(h++)}function hi(u,l,vi){var D="".concat(n).concat(u,":").concat(l);return vi!=null&&(D+=":"+vi),D}return ClientID={generateClientID:s,generateClientObjectClientID:hi,generateUniqueClientID:v,isClientID:a},ClientID}var ConnectionInterface_1,hasRequiredConnectionInterface;function requireConnectionInterface(){if(hasRequiredConnectionInterface)return ConnectionInterface_1;hasRequiredConnectionInterface=1;var r={after:!0,before:!0,find:!0,first:!0,last:!0,surrounds:!0},t={CURSOR:"cursor",EDGES:"edges",END_CURSOR:"endCursor",HAS_NEXT_PAGE:"hasNextPage",HAS_PREV_PAGE:"hasPreviousPage",NODE:"node",PAGE_INFO_TYPE:"PageInfo",PAGE_INFO:"pageInfo",START_CURSOR:"startCursor"},i={inject:function(s){t=s},get:function(){return t},isConnectionCall:function(s){return r.hasOwnProperty(s.name)}};return ConnectionInterface_1=i,ConnectionInterface_1}var ConnectionHandler,hasRequiredConnectionHandler;function requireConnectionHandler(){if(hasRequiredConnectionHandler)return ConnectionHandler;hasRequiredConnectionHandler=1;var r=requireClientID(),t=r.generateClientID,i=requireRelayStoreUtils(),n=i.getStableStorageKey,s=requireGetRelayHandleKey(),a=requireConnectionInterface(),h=requireBrowser();requireWarning();var v="connection",hi="__connection_next_edge_index";function u(Ii,qi){var Oi=Ii.get(qi.dataID);if(Oi){var ki=a.get(),Li=ki.EDGES,ji=ki.END_CURSOR,Hi=ki.HAS_NEXT_PAGE,Ui=ki.HAS_PREV_PAGE,Qi=ki.PAGE_INFO,$i=ki.PAGE_INFO_TYPE,wi=ki.START_CURSOR,xi=Oi.getLinkedRecord(qi.fieldKey),yi=xi&&xi.getLinkedRecord(Qi);if(!xi){Oi.setValue(null,qi.handleKey,void 0,Oi.getErrors(qi.fieldKey));return}var Ei=t(Oi.getDataID(),qi.handleKey),Ci=Oi.getLinkedRecord(qi.handleKey),Ni=Ci??Ii.get(Ei),Fi=Ni&&Ni.getLinkedRecord(Qi);if(Ni){Ci==null&&Oi.setLinkedRecord(Ni,qi.handleKey);var Ai=Ni,_i=xi.getLinkedRecords(Li);_i&&(_i=_i.map(function(Hn){return Ri(Ii,Ai,Hn)}));var Bi=Ai.getLinkedRecords(Li),Pi=Ai.getLinkedRecord(Qi);Ai.copyFieldsFrom(xi),Bi&&Ai.setLinkedRecords(Bi,Li),Pi&&Ai.setLinkedRecord(Pi,Qi);var zi=[],Gi=qi.args;if(Bi&&_i)if(Gi.after!=null){var Vi,Ki=(Vi=Fi)===null||Vi===void 0?void 0:Vi.getValue(ji),Zi=yi?.getValue(ji),In=Fi&&Gi.after===Ki,Ji=Fi&&Ki===Zi;if(In||Ji){var Xi=new Set;Ti(Bi,zi,Xi),Ti(_i,zi,Xi)}else return}else if(Gi.before!=null)if(Fi&&Gi.before===Fi.getValue(wi)){var on=new Set;Ti(_i,zi,on),Ti(Bi,zi,on)}else return;else zi=_i;else _i?zi=_i:zi=Bi;if(zi!=null&&zi!==Bi&&Ai.setLinkedRecords(zi,Li),Fi&&yi){if(Gi.after==null&&Gi.before==null)Fi.copyFieldsFrom(yi);else if(Gi.before!=null||Gi.after==null&&Gi.last){Fi.setValue(!!yi.getValue(Ui),Ui);var jn=yi.getValue(wi);typeof jn=="string"&&Fi.setValue(jn,wi)}else if(Gi.after!=null||Gi.before==null&&Gi.first){Fi.setValue(!!yi.getValue(Hi),Hi);var Ln=yi.getValue(ji);typeof Ln=="string"&&Fi.setValue(Ln,ji)}}}else{var Mi=Ii.create(Ei,xi.getType());Mi.setValue(0,hi),Mi.copyFieldsFrom(xi);var Si=xi.getLinkedRecords(Li);Si&&(Si=Si.map(function(Hn){return Ri(Ii,Mi,Hn)}),Mi.setLinkedRecords(Si,Li)),Oi.setLinkedRecord(Mi,qi.handleKey),Fi=Ii.create(t(Mi.getDataID(),Qi),$i),Fi.setValue(!1,Hi),Fi.setValue(!1,Ui),Fi.setValue(null,ji),Fi.setValue(null,wi),yi&&Fi.copyFieldsFrom(yi),Mi.setLinkedRecord(Fi,Qi)}}}function l(Ii,qi,Oi){var ki=s(v,qi,null);return Ii.getLinkedRecord(ki,Oi)}function vi(Ii,qi,Oi){var ki=s(v,qi,null),Li=n(ki,Oi);return t(Ii,Li)}function D(Ii,qi,Oi){var ki=a.get(),Li=ki.CURSOR,ji=ki.EDGES,Hi=Ii.getLinkedRecords(ji);if(!Hi){Ii.setLinkedRecords([qi],ji);return}var Ui;if(Oi==null)Ui=Hi.concat(qi);else{Ui=[];for(var Qi=!1,$i=0;$i<Hi.length;$i++){var wi=Hi[$i];if(Ui.push(wi),wi!=null){var xi=wi.getValue(Li);Oi===xi&&(Ui.push(qi),Qi=!0)}}Qi||Ui.push(qi)}Ii.setLinkedRecords(Ui,ji)}function mi(Ii,qi,Oi,ki){var Li=a.get(),ji=Li.NODE,Hi=t(qi.getDataID(),Oi.getDataID()),Ui=Ii.get(Hi);return Ui||(Ui=Ii.create(Hi,ki)),Ui.setLinkedRecord(Oi,ji),Ui.getValue("cursor")==null&&Ui.setValue(null,"cursor"),Ui}function gi(Ii,qi,Oi){var ki=a.get(),Li=ki.CURSOR,ji=ki.EDGES,Hi=Ii.getLinkedRecords(ji);if(!Hi){Ii.setLinkedRecords([qi],ji);return}var Ui;if(Oi==null)Ui=[qi].concat(Hi);else{Ui=[];for(var Qi=!1,$i=0;$i<Hi.length;$i++){var wi=Hi[$i];if(wi!=null){var xi=wi.getValue(Li);Oi===xi&&(Ui.push(qi),Qi=!0)}Ui.push(wi)}Qi||Ui.unshift(qi)}Ii.setLinkedRecords(Ui,ji)}function bi(Ii,qi){var Oi=a.get(),ki=Oi.EDGES,Li=Oi.NODE,ji=Ii.getLinkedRecords(ki);if(ji){for(var Hi,Ui=0;Ui<ji.length;Ui++){var Qi=ji[Ui],$i=Qi&&Qi.getLinkedRecord(Li);$i!=null&&$i.getDataID()===qi?Hi===void 0&&(Hi=ji.slice(0,Ui)):Hi!==void 0&&Hi.push(Qi)}Hi!==void 0&&Ii.setLinkedRecords(Hi,ki)}}function Ri(Ii,qi,Oi){if(Oi==null)return Oi;var ki=a.get(),Li=ki.EDGES,ji=qi.getValue(hi);typeof ji!="number"&&h(!1);var Hi=t(qi.getDataID(),Li,ji),Ui=Ii.create(Hi,Oi.getType());return Ui.copyFieldsFrom(Oi),Ui.getValue("cursor")==null&&Ui.setValue(null,"cursor"),qi.setValue(ji+1,hi),Ui}function Ti(Ii,qi,Oi){for(var ki=a.get(),Li=ki.NODE,ji=0;ji<Ii.length;ji++){var Hi=Ii[ji];if(Hi){var Ui=Hi.getLinkedRecord(Li),Qi=Ui&&Ui.getDataID();if(Qi){if(Oi.has(Qi))continue;Oi.add(Qi)}qi.push(Hi)}}}return ConnectionHandler={buildConnectionEdge:Ri,createEdge:mi,deleteNode:bi,getConnection:l,getConnectionID:vi,insertEdgeAfter:D,insertEdgeBefore:gi,update:u},ConnectionHandler}var MutationHandlers,hasRequiredMutationHandlers;function requireMutationHandlers(){if(hasRequiredMutationHandlers)return MutationHandlers;hasRequiredMutationHandlers=1;var r=requireInteropRequireDefault().default,t=r(requireCreateForOfIteratorHelper()),i=requireConnectionHandler(),n=requireConnectionInterface(),s=requireBrowser(),a=requireWarning(),h={update:function(bi,Ri){var Ti=bi.get(Ri.dataID);if(Ti!=null){var Ii=Ti.getValue(Ri.fieldKey);typeof Ii=="string"?bi.delete(Ii):Array.isArray(Ii)&&Ii.forEach(function(qi){typeof qi=="string"&&bi.delete(qi)})}}},v={update:function(bi,Ri){var Ti=bi.get(Ri.dataID);if(Ti!=null){var Ii=Ri.handleArgs.connections;Ii==null&&s(!1);var qi=Ti.getValue(Ri.fieldKey),Oi=Array.isArray(qi)?qi:[qi];Oi.forEach(function(ki){if(typeof ki=="string"){var Li=(0,t.default)(Ii),ji;try{for(Li.s();!(ji=Li.n()).done;){var Hi=ji.value,Ui=bi.get(Hi);Ui!=null&&i.deleteNode(Ui,ki)}}catch(Qi){Li.e(Qi)}finally{Li.f()}}})}}},hi={update:D(i.insertEdgeAfter)},u={update:D(i.insertEdgeBefore)},l={update:mi(i.insertEdgeAfter)},vi={update:mi(i.insertEdgeBefore)};function D(gi){return function(bi,Ri){var Ti,Ii=bi.get(Ri.dataID);if(Ii!=null){var qi=Ri.handleArgs.connections;qi==null&&s(!1);var Oi,ki;try{Oi=Ii.getLinkedRecord(Ri.fieldKey)}catch{}if(!Oi)try{ki=Ii.getLinkedRecords(Ri.fieldKey)}catch{}if(!(Oi==null&&ki==null)){var Li=n.get(),ji=Li.NODE,Hi=Li.EDGES,Ui=(Ti=ki)!==null&&Ti!==void 0?Ti:[Oi],Qi=(0,t.default)(Ui),$i;try{var wi=function(){var Ci=$i.value;if(Ci==null)return"continue";var Ni=Ci.getLinkedRecord("node");if(!Ni)return"continue";var Fi=Ni.getDataID(),Mi=(0,t.default)(qi),Si;try{for(Mi.s();!(Si=Mi.n()).done;){var Ai=Si.value,_i=bi.get(Ai);if(_i!=null){var Bi=(xi=_i.getLinkedRecords(Hi))===null||xi===void 0?void 0:xi.some(function(zi){var Gi;return(zi==null||(Gi=zi.getLinkedRecord(ji))===null||Gi===void 0?void 0:Gi.getDataID())===Fi});if(!Bi){var Pi=i.buildConnectionEdge(bi,_i,Ci);Pi==null&&s(!1),gi(_i,Pi)}}}}catch(zi){Mi.e(zi)}finally{Mi.f()}};for(Qi.s();!($i=Qi.n()).done;)var xi,yi=wi()}catch(Ei){Qi.e(Ei)}finally{Qi.f()}}}}}function mi(gi){return function(bi,Ri){var Ti,Ii=bi.get(Ri.dataID);if(Ii!=null){var qi=Ri.handleArgs,Oi=qi.connections,ki=qi.edgeTypeName;Oi==null&&s(!1),ki==null&&s(!1);var Li,ji;try{Li=Ii.getLinkedRecord(Ri.fieldKey)}catch{}if(!Li)try{ji=Ii.getLinkedRecords(Ri.fieldKey)}catch{}if(!(Li==null&&ji==null)){var Hi=n.get(),Ui=Hi.NODE,Qi=Hi.EDGES,$i=(Ti=ji)!==null&&Ti!==void 0?Ti:[Li],wi=(0,t.default)($i),xi;try{var yi=function(){var Fi=xi.value;if(Fi==null)return"continue";var Mi=Fi.getDataID(),Si=(0,t.default)(Oi),Ai;try{for(Si.s();!(Ai=Si.n()).done;){var _i=Ai.value,Bi=bi.get(_i);if(Bi!=null){var Pi=(Ei=Bi.getLinkedRecords(Qi))===null||Ei===void 0?void 0:Ei.some(function(Gi){var Vi;return(Gi==null||(Vi=Gi.getLinkedRecord(Ui))===null||Vi===void 0?void 0:Vi.getDataID())===Mi});if(!Pi){var zi=i.createEdge(bi,Bi,Fi,ki);zi==null&&s(!1),gi(Bi,zi)}}}}catch(Gi){Si.e(Gi)}finally{Si.f()}};for(wi.s();!(xi=wi.n()).done;)var Ei,Ci=yi()}catch(Ni){wi.e(Ni)}finally{wi.f()}}}}}return MutationHandlers={AppendEdgeHandler:hi,DeleteRecordHandler:h,PrependEdgeHandler:u,AppendNodeHandler:l,PrependNodeHandler:vi,DeleteEdgeHandler:v},MutationHandlers}var RelayDefaultHandlerProvider_1,hasRequiredRelayDefaultHandlerProvider;function requireRelayDefaultHandlerProvider(){if(hasRequiredRelayDefaultHandlerProvider)return RelayDefaultHandlerProvider_1;hasRequiredRelayDefaultHandlerProvider=1;var r=requireConnectionHandler(),t=requireMutationHandlers(),i=requireBrowser();function n(s){switch(s){case"connection":return r;case"deleteRecord":return t.DeleteRecordHandler;case"deleteEdge":return t.DeleteEdgeHandler;case"appendEdge":return t.AppendEdgeHandler;case"prependEdge":return t.PrependEdgeHandler;case"appendNode":return t.AppendNodeHandler;case"prependNode":return t.PrependNodeHandler}i(!1)}return RelayDefaultHandlerProvider_1=n,RelayDefaultHandlerProvider_1}var isRelayModernEnvironment_1,hasRequiredIsRelayModernEnvironment;function requireIsRelayModernEnvironment(){if(hasRequiredIsRelayModernEnvironment)return isRelayModernEnvironment_1;hasRequiredIsRelayModernEnvironment=1;function r(t){return!!(t&&t["@@RelayModernEnvironment"])}return isRelayModernEnvironment_1=r,isRelayModernEnvironment_1}var RelayDeclarativeMutationConfig,hasRequiredRelayDeclarativeMutationConfig;function requireRelayDeclarativeMutationConfig(){if(hasRequiredRelayDeclarativeMutationConfig)return RelayDeclarativeMutationConfig;hasRequiredRelayDeclarativeMutationConfig=1;var r=requireInteropRequireDefault().default,t=r(requireCreateForOfIteratorHelper()),i=requireConnectionHandler(),n=requireWarning(),s=Object.freeze({RANGE_ADD:"RANGE_ADD",RANGE_DELETE:"RANGE_DELETE",NODE_DELETE:"NODE_DELETE"}),a=Object.freeze({APPEND:"append",PREPEND:"prepend"});function h(D,mi,gi,bi){var Ri=gi?[gi]:[],Ti=bi?[bi]:[];return D.forEach(function(Ii){switch(Ii.type){case"NODE_DELETE":var qi=v(Ii,mi);qi&&(Ri.push(qi),Ti.push(qi));break;case"RANGE_ADD":var Oi=hi(Ii,mi);Oi&&(Ri.push(Oi),Ti.push(Oi));break;case"RANGE_DELETE":var ki=u(Ii,mi);ki&&(Ri.push(ki),Ti.push(ki));break}}),{optimisticUpdater:function(qi,Oi){Ri.forEach(function(ki){ki(qi,Oi)})},updater:function(qi,Oi){Ti.forEach(function(ki){ki(qi,Oi)})}}}function v(D,mi){var gi=D.deletedIDFieldName,bi=vi(mi);return bi?function(Ri,Ti){var Ii=Ri.getRootField(bi);if(Ii){var qi=Ii.getValue(gi),Oi=Array.isArray(qi)?qi:[qi];Oi.forEach(function(ki){ki&&typeof ki=="string"&&Ri.delete(ki)})}}:null}function hi(D,mi){var gi=D.parentID,bi=D.connectionInfo,Ri=D.edgeName;if(!gi)return null;var Ti=vi(mi);return!bi||!Ti?null:function(Ii,qi){var Oi=Ii.get(gi);if(Oi){var ki=Ii.getRootField(Ti);if(ki){var Li=ki.getLinkedRecord(Ri),ji=(0,t.default)(bi),Hi;try{for(ji.s();!(Hi=ji.n()).done;){var Ui=Hi.value;if(Li){var Qi=i.getConnection(Oi,Ui.key,Ui.filters);if(Qi){var $i=i.buildConnectionEdge(Ii,Qi,Li);if($i)switch(Ui.rangeBehavior){case"append":i.insertEdgeAfter(Qi,$i);break;case"prepend":i.insertEdgeBefore(Qi,$i);break;default:break}}}}}catch(wi){ji.e(wi)}finally{ji.f()}}}}}function u(D,mi){var gi=D.parentID,bi=D.connectionKeys,Ri=D.pathToConnection,Ti=D.deletedIDFieldName;if(!gi)return null;var Ii=vi(mi);return Ii?function(qi,Oi){if(Oi){var ki=[],Li=Oi[Ii];if(Li&&Array.isArray(Ti)){var ji=(0,t.default)(Ti),Hi;try{for(ji.s();!(Hi=ji.n()).done;){var Ui=Hi.value;Li&&typeof Li=="object"&&(Li=Li[Ui])}}catch(Qi){ji.e(Qi)}finally{ji.f()}Array.isArray(Li)?Li.forEach(function(Qi){Qi&&Qi.id&&typeof Qi=="object"&&typeof Qi.id=="string"&&ki.push(Qi.id)}):Li&&Li.id&&typeof Li.id=="string"&&ki.push(Li.id)}else Li&&typeof Ti=="string"&&typeof Li=="object"&&(Li=Li[Ti],typeof Li=="string"?ki.push(Li):Array.isArray(Li)&&Li.forEach(function(Qi){typeof Qi=="string"&&ki.push(Qi)}));l(gi,bi,Ri,qi,ki)}}:null}function l(D,mi,gi,bi,Ri){var Ti=bi.get(D);if(Ti&&!(gi.length<2)){for(var Ii=Ti,qi=1;qi<gi.length-1;qi++)Ii&&(Ii=Ii.getLinkedRecord(gi[qi]));if(!(!mi||!Ii)){var Oi=(0,t.default)(mi),ki;try{var Li=function(){var Hi=ki.value,Ui=i.getConnection(Ii,Hi.key,Hi.filters);Ui&&Ri.forEach(function(Qi){i.deleteNode(Ui,Qi)})};for(Oi.s();!(ki=Oi.n()).done;)Li()}catch(ji){Oi.e(ji)}finally{Oi.f()}}}}function vi(D){return D.fragment.selections&&D.fragment.selections.length>0&&D.fragment.selections[0].kind==="LinkedField"?D.fragment.selections[0].name:null}return RelayDeclarativeMutationConfig={MutationTypes:s,RangeOperations:a,convert:h},RelayDeclarativeMutationConfig}var applyOptimisticMutation_1,hasRequiredApplyOptimisticMutation;function requireApplyOptimisticMutation(){if(hasRequiredApplyOptimisticMutation)return applyOptimisticMutation_1;hasRequiredApplyOptimisticMutation=1;var r=requireGraphQLTag(),t=r.getRequest,i=requireIsRelayModernEnvironment(),n=requireRelayModernOperationDescriptor(),s=n.createOperationDescriptor,a=requireRelayDeclarativeMutationConfig(),h=requireBrowser();function v(hi,u){i(hi)||h(!1);var l=t(u.mutation);if(l.params.operationKind!=="mutation")throw new Error("commitMutation: Expected mutation operation");var vi=u.optimisticUpdater,D=u.configs,mi=u.optimisticResponse,gi=u.variables,bi=s(l,gi);if(D){var Ri=a.convert(D,l,vi);vi=Ri.optimisticUpdater}return hi.applyMutation({operation:bi,response:mi,updater:vi})}return applyOptimisticMutation_1=v,applyOptimisticMutation_1}var commitLocalUpdate_1,hasRequiredCommitLocalUpdate;function requireCommitLocalUpdate(){if(hasRequiredCommitLocalUpdate)return commitLocalUpdate_1;hasRequiredCommitLocalUpdate=1;function r(t,i){t.commitUpdate(i)}return commitLocalUpdate_1=r,commitLocalUpdate_1}var validateMutation_1,hasRequiredValidateMutation;function requireValidateMutation(){if(hasRequiredValidateMutation)return validateMutation_1;hasRequiredValidateMutation=1;var r=requireInteropRequireDefault().default;r(requireObjectSpread2()),requireWarning();var t=function(){};return validateMutation_1=t,validateMutation_1}var commitMutation_1,hasRequiredCommitMutation;function requireCommitMutation(){if(hasRequiredCommitMutation)return commitMutation_1;hasRequiredCommitMutation=1;var r=requireInteropRequireDefault().default,t=r(requireToConsumableArray()),i=requireGraphQLTag(),n=i.getRequest,s=requireClientID(),a=s.generateUniqueClientID,h=requireIsRelayModernEnvironment(),v=requireRelayModernOperationDescriptor(),hi=v.createOperationDescriptor,u=requireRelayDeclarativeMutationConfig();requireValidateMutation();var l=requireBrowser();requireWarning();function vi(D,mi){h(D)||l(!1);var gi=n(mi.mutation);if(gi.params.operationKind!=="mutation")throw new Error("commitMutation: Expected mutation operation");if(gi.kind!=="Request")throw new Error("commitMutation: Expected mutation to be of type request");var bi=mi.optimisticResponse,Ri=mi.optimisticUpdater,Ti=mi.updater,Ii=mi.configs,qi=mi.cacheConfig,Oi=mi.onError,ki=mi.onUnsubscribe,Li=mi.variables,ji=mi.uploadables,Hi=hi(gi,Li,qi,a());if(typeof bi=="function"&&(bi=bi()),Ii){var Ui=u.convert(Ii,gi,Ri,Ti);Ri=Ui.optimisticUpdater,Ti=Ui.updater}var Qi=[],$i=D.executeMutation({operation:Hi,optimisticResponse:bi,optimisticUpdater:Ri,updater:Ti,uploadables:ji}).subscribe({complete:function(){var xi=mi.onCompleted;if(xi){var yi=D.lookup(Hi.fragment);xi(yi.data,Qi.length!==0?Qi:null)}},error:Oi,next:function(xi){var yi;Array.isArray(xi)?xi.forEach(function(Ei){Ei.errors&&Qi.push.apply(Qi,(0,t.default)(Ei.errors))}):xi.errors&&Qi.push.apply(Qi,(0,t.default)(xi.errors)),(yi=mi.onNext)===null||yi===void 0||yi.call(mi)},unsubscribe:ki});return{dispose:$i.unsubscribe}}return commitMutation_1=vi,commitMutation_1}var withProvidedVariables_1,hasRequiredWithProvidedVariables;function requireWithProvidedVariables(){if(hasRequiredWithProvidedVariables)return withProvidedVariables_1;hasRequiredWithProvidedVariables=1,requireAreEqual(),requireWarning();var r=typeof WeakMap=="function",t=r?new WeakMap:new Map;function i(n,s){if(s!=null){var a={};return Object.assign(a,n),Object.keys(s).forEach(function(h){var v=s[h].get,hi=v();if(!t.has(v))t.set(v,hi),a[h]=hi;else{var u=t.get(v);a[h]=u}}),a}else return n}return i.tests_only_resetDebugCache=void 0,withProvidedVariables_1=i,withProvidedVariables_1}var ConvertToExecuteFunction,hasRequiredConvertToExecuteFunction;function requireConvertToExecuteFunction(){if(hasRequiredConvertToExecuteFunction)return ConvertToExecuteFunction;hasRequiredConvertToExecuteFunction=1;var r=requireRelayObservable();function t(i){return function(s,a,h,v,hi){var u=i(s,a,h,v,hi);return u instanceof Error?r.create(function(l){return l.error(u)}):r.from(u)}}return ConvertToExecuteFunction={convertFetch:t},ConvertToExecuteFunction}var RelayNetwork,hasRequiredRelayNetwork;function requireRelayNetwork(){if(hasRequiredRelayNetwork)return RelayNetwork;hasRequiredRelayNetwork=1;var r=requireWithProvidedVariables(),t=requireConvertToExecuteFunction(),i=t.convertFetch,n=requireBrowser();function s(a,h){var v=i(a);function hi(u,l,vi,D,mi){var gi=r(l,u.providedVariables);if(u.operationKind==="subscription")return h||n(!1),D&&n(!1),h(u,gi,vi);var bi=vi.poll;return bi!=null?(D&&n(!1),v(u,gi,{force:!0}).poll(bi)):v(u,gi,vi,D,mi)}return{execute:hi}}return RelayNetwork={create:s},RelayNetwork}var RelayQueryResponseCache_1,hasRequiredRelayQueryResponseCache;function requireRelayQueryResponseCache(){if(hasRequiredRelayQueryResponseCache)return RelayQueryResponseCache_1;hasRequiredRelayQueryResponseCache=1;var r=requireInteropRequireDefault().default,t=r(requireObjectSpread2()),i=requireStableCopy(),n=i.stableCopy,s=requireBrowser(),a=function(){function hi(l){var vi=l.size,D=l.ttl;vi>0||s(!1),D>0||s(!1),this._responses=new Map,this._size=vi,this._ttl=D}var u=hi.prototype;return u.clear=function(){this._responses.clear()},u.get=function(vi,D){var mi=this,gi=h(vi,D);this._responses.forEach(function(Ri,Ti){v(Ri.fetchTime,mi._ttl)||mi._responses.delete(Ti)});var bi=this._responses.get(gi);return bi==null?null:Array.isArray(bi.payload)?bi.payload.map(function(Ri){return(0,t.default)((0,t.default)({},Ri),{},{extensions:(0,t.default)((0,t.default)({},Ri.extensions),{},{cacheTimestamp:bi.fetchTime})})}):(0,t.default)((0,t.default)({},bi.payload),{},{extensions:(0,t.default)((0,t.default)({},bi.payload.extensions),{},{cacheTimestamp:bi.fetchTime})})},u.set=function(vi,D,mi){var gi=Date.now(),bi=h(vi,D);if(this._responses.delete(bi),this._responses.set(bi,{fetchTime:gi,payload:mi}),this._responses.size>this._size){var Ri=this._responses.keys().next();Ri.done||this._responses.delete(Ri.value)}},hi}();function h(hi,u){return JSON.stringify(n({queryID:hi,variables:u}))}function v(hi,u){return hi+u>=Date.now()}return RelayQueryResponseCache_1=a,RelayQueryResponseCache_1}var fetchQuery_1,hasRequiredFetchQuery;function requireFetchQuery(){if(hasRequiredFetchQuery)return fetchQuery_1;hasRequiredFetchQuery=1;var r=requireInteropRequireDefault().default,t=r(requireObjectSpread2()),i=requireRelayObservable(),n=requireRelayModernOperationDescriptor(),s=n.createOperationDescriptor,a=requireHandlePotentialSnapshotErrors(),h=a.handlePotentialSnapshotErrors,v=requireFetchQueryInternal(),hi=requireGraphQLTag(),u=hi.getRequest,l=requireBrowser();function vi(mi,gi,bi,Ri){var Ti,Ii=u(gi);Ii.params.operationKind!=="query"&&l(!1);var qi=(0,t.default)({force:!0},Ri?.networkCacheConfig),Oi=s(Ii,bi,qi),ki=(Ti=Ri?.fetchPolicy)!==null&&Ti!==void 0?Ti:"network-only";function Li(Qi){return h(mi,Qi.fieldErrors),Qi.data}switch(ki){case"network-only":return D(mi,Oi).map(Li);case"store-or-network":{var ji=mi.check(Oi),Hi=ji.status!=="available",Ui;return Hi?Ui=D(mi,Oi).map(Li):Ui=i.from(mi.lookup(Oi.fragment)).map(Li),mi.__log({name:"fetchquery.fetch",operation:Oi,fetchPolicy:ki,queryAvailability:ji,shouldFetch:Hi}),Ui}default:throw new Error("fetchQuery: Invalid fetchPolicy "+ki)}}function D(mi,gi){return v.fetchQuery(mi,gi).map(function(){return mi.lookup(gi.fragment)})}return fetchQuery_1=vi,fetchQuery_1}var fetchQuery_DEPRECATED_1,hasRequiredFetchQuery_DEPRECATED;function requireFetchQuery_DEPRECATED(){if(hasRequiredFetchQuery_DEPRECATED)return fetchQuery_DEPRECATED_1;hasRequiredFetchQuery_DEPRECATED=1;var r=requireRelayModernOperationDescriptor(),t=r.createOperationDescriptor,i=requireGraphQLTag(),n=i.getRequest;function s(a,h,v,hi){var u=n(h);if(u.params.operationKind!=="query")throw new Error("fetchQuery: Expected query operation");var l=t(u,v,hi);return a.execute({operation:l}).map(function(){return a.lookup(l.fragment).data}).toPromise()}return fetchQuery_DEPRECATED_1=s,fetchQuery_DEPRECATED_1}var PreloadableQueryRegistry_1,hasRequiredPreloadableQueryRegistry;function requirePreloadableQueryRegistry(){if(hasRequiredPreloadableQueryRegistry)return PreloadableQueryRegistry_1;hasRequiredPreloadableQueryRegistry=1;var r=function(){function i(){this._preloadableQueries=new Map,this._callbacks=new Map}var n=i.prototype;return n.set=function(a,h){this._preloadableQueries.set(a,h);var v=this._callbacks.get(a);v?.forEach(function(hi){try{hi(h)}catch(u){setTimeout(function(){throw u},0)}})},n.get=function(a){return this._preloadableQueries.get(a)},n.onLoad=function(a,h){var v,hi=(v=this._callbacks.get(a))!==null&&v!==void 0?v:new Set;hi.add(h);var u=function(){hi.delete(h)};return this._callbacks.set(a,hi),{dispose:u}},n.clear=function(){this._preloadableQueries.clear()},i}(),t=new r;return PreloadableQueryRegistry_1=t,PreloadableQueryRegistry_1}var getPendingOperationsForFragment_1,hasRequiredGetPendingOperationsForFragment;function requireGetPendingOperationsForFragment(){if(hasRequiredGetPendingOperationsForFragment)return getPendingOperationsForFragment_1;hasRequiredGetPendingOperationsForFragment=1;var r=requireFetchQueryInternal(),t=r.getPromiseForActiveRequest;function i(n,s,a){var h,v,hi=[],u=t(n,a);if(u!=null)hi=[a];else{var l,vi,D=n.getOperationTracker(),mi=D.getPendingOperationsAffectingOwner(a);hi=(l=mi?.pendingOperations)!==null&&l!==void 0?l:[],u=(vi=mi?.promise)!==null&&vi!==void 0?vi:null}if(!u)return null;var gi=(h=(v=hi)===null||v===void 0?void 0:v.map(function(Ti){return Ti.node.params.name}).join(","))!==null&&h!==void 0?h:null;(gi==null||gi.length===0)&&(gi="Unknown pending operation");var bi=s.name,Ri=gi===bi?"Relay(".concat(gi,")"):"Relay(".concat(gi,":").concat(bi,")");return u.displayName=Ri,n.__log({name:"pendingoperation.found",fragment:s,fragmentOwner:a,pendingOperations:hi}),{promise:u,pendingOperations:hi}}return getPendingOperationsForFragment_1=i,getPendingOperationsForFragment_1}var isScalarAndEqual_1,hasRequiredIsScalarAndEqual;function requireIsScalarAndEqual(){if(hasRequiredIsScalarAndEqual)return isScalarAndEqual_1;hasRequiredIsScalarAndEqual=1;function r(t,i){return t===i&&(t===null||typeof t!="object")}return isScalarAndEqual_1=r,isScalarAndEqual_1}var recycleNodesInto_1,hasRequiredRecycleNodesInto;function requireRecycleNodesInto(){if(hasRequiredRecycleNodesInto)return recycleNodesInto_1;hasRequiredRecycleNodesInto=1;function r(i,n){return t(i,n,!0)}function t(i,n,s){if(i===n||typeof i!="object"||!i||i.constructor!==Object&&!Array.isArray(i)||typeof n!="object"||!n||n.constructor!==Object&&!Array.isArray(n))return n;var a=!1,h=Array.isArray(i)?i:null,v=Array.isArray(n)?n:null;if(h&&v){var hi=s&&!Object.isFrozen(v);a=v.reduce(function(gi,bi,Ri){var Ti=h[Ri],Ii=t(Ti,bi,hi);return Ii!==v[Ri]&&hi&&(v[Ri]=Ii),gi&&Ii===h[Ri]},!0)&&h.length===v.length}else if(!h&&!v){var u=i,l=n,vi=Object.keys(u),D=Object.keys(l),mi=s&&!Object.isFrozen(l);a=D.reduce(function(gi,bi){var Ri=u[bi],Ti=t(Ri,l[bi],mi);return Ti!==l[bi]&&mi&&(l[bi]=Ti),gi&&Ti===u[bi]},!0)&&vi.length===D.length}return a?i:n}return recycleNodesInto_1=r,recycleNodesInto_1}var RelayModernFragmentSpecResolver_1,hasRequiredRelayModernFragmentSpecResolver;function requireRelayModernFragmentSpecResolver(){if(hasRequiredRelayModernFragmentSpecResolver)return RelayModernFragmentSpecResolver_1;hasRequiredRelayModernFragmentSpecResolver=1;var r=requireInteropRequireDefault().default,t=r(requireObjectSpread2()),i=r(requireDefineProperty()),n=requireGetPendingOperationsForFragment(),s=requireHandlePotentialSnapshotErrors(),a=s.handlePotentialSnapshotErrors,h=requireIsScalarAndEqual(),v=requireRecycleNodesInto(),hi=requireRelayFeatureFlags(),u=requireRelayModernOperationDescriptor(),l=u.createRequestDescriptor,vi=requireRelayModernSelector(),D=vi.areEqualSelectors,mi=vi.createReaderSelector,gi=vi.getSelectorsFromObject,bi=requireAreEqual(),Ri=requireBrowser();requireWarning();var Ti=function(){function ki(ji,Hi,Ui,Qi,$i){var wi=this;(0,i.default)(this,"_onChange",function(){wi._stale=!0,typeof wi._callback=="function"&&wi._callback()}),this._callback=Qi,this._context=ji,this._data={},this._fragments=Hi,this._props={},this._resolvers={},this._stale=!1,this._rootIsQueryRenderer=$i,this.setProps(Ui)}var Li=ki.prototype;return Li.dispose=function(){for(var Hi in this._resolvers)this._resolvers.hasOwnProperty(Hi)&&Oi(this._resolvers[Hi])},Li.resolve=function(){if(this._stale){var Hi=this._data,Ui;for(var Qi in this._resolvers)if(this._resolvers.hasOwnProperty(Qi)){var $i=this._resolvers[Qi],wi=Hi[Qi];if($i){var xi=$i.resolve();(Ui||xi!==wi)&&(Ui=Ui||(0,t.default)({},Hi),Ui[Qi]=xi)}else{var yi=this._props[Qi],Ei=yi!==void 0?yi:null;(Ui||!h(Ei,wi))&&(Ui=Ui||(0,t.default)({},Hi),Ui[Qi]=Ei)}}this._data=Ui||Hi,this._stale=!1}return this._data},Li.setCallback=function(Hi,Ui){this._callback=Ui,hi.ENABLE_CONTAINERS_SUBSCRIBE_ON_COMMIT===!0&&this.setProps(Hi)},Li.setProps=function(Hi){this._props={};var Ui=gi(this._fragments,Hi);for(var Qi in Ui)if(Ui.hasOwnProperty(Qi)){var $i=Ui[Qi],wi=this._resolvers[Qi];$i==null?(wi?.dispose(),wi=null):$i.kind==="PluralReaderSelector"?wi==null?wi=new qi(this._context.environment,this._rootIsQueryRenderer,$i,this._callback!=null,this._onChange):(wi instanceof qi||Ri(!1),wi.setSelector($i)):wi==null?wi=new Ii(this._context.environment,this._rootIsQueryRenderer,$i,this._callback!=null,this._onChange):(wi instanceof Ii||Ri(!1),wi.setSelector($i)),this._props[Qi]=Hi[Qi],this._resolvers[Qi]=wi}this._stale=!0},Li.setVariables=function(Hi,Ui){for(var Qi in this._resolvers)if(this._resolvers.hasOwnProperty(Qi)){var $i=this._resolvers[Qi];$i&&$i.setVariables(Hi,Ui)}this._stale=!0},ki}(),Ii=function(){function ki(ji,Hi,Ui,Qi,$i){var wi=this;(0,i.default)(this,"_onChange",function(yi){wi._data=yi.data,wi._isMissingData=yi.isMissingData,wi._fieldErrors=yi.fieldErrors,wi._callback()});var xi=ji.lookup(Ui);this._callback=$i,this._data=xi.data,this._isMissingData=xi.isMissingData,this._fieldErrors=xi.fieldErrors,this._environment=ji,this._rootIsQueryRenderer=Hi,this._selector=Ui,hi.ENABLE_CONTAINERS_SUBSCRIBE_ON_COMMIT===!0?Qi&&(this._subscription=ji.subscribe(xi,this._onChange)):this._subscription=ji.subscribe(xi,this._onChange)}var Li=ki.prototype;return Li.dispose=function(){this._subscription&&(this._subscription.dispose(),this._subscription=null)},Li.resolve=function(){if(this._isMissingData===!0){var Hi=n(this._environment,this._selector.node,this._selector.owner),Ui=Hi?.promise;if(Ui!=null&&!this._rootIsQueryRenderer){var Qi,$i=(Qi=Hi?.pendingOperations)!==null&&Qi!==void 0?Qi:[];throw this._environment.__log({name:"suspense.fragment",data:this._data,fragment:this._selector.node,isRelayHooks:!1,isMissingData:this._isMissingData,isPromiseCached:!1,pendingOperations:$i}),Ui}}return a(this._environment,this._fieldErrors),this._data},Li.setSelector=function(Hi){if(!(this._subscription!=null&&D(Hi,this._selector))){this.dispose();var Ui=this._environment.lookup(Hi);this._data=v(this._data,Ui.data),this._isMissingData=Ui.isMissingData,this._fieldErrors=Ui.fieldErrors,this._selector=Hi,this._subscription=this._environment.subscribe(Ui,this._onChange)}},Li.setVariables=function(Hi,Ui){if(!bi(Hi,this._selector.variables)){var Qi=l(Ui,Hi),$i=mi(this._selector.node,this._selector.dataID,Hi,Qi);this.setSelector($i)}},ki}(),qi=function(){function ki(ji,Hi,Ui,Qi,$i){var wi=this;(0,i.default)(this,"_onChange",function(xi){wi._stale=!0,wi._callback()}),this._callback=$i,this._data=[],this._environment=ji,this._resolvers=[],this._stale=!0,this._rootIsQueryRenderer=Hi,this._subscribeOnConstruction=Qi,this.setSelector(Ui)}var Li=ki.prototype;return Li.dispose=function(){this._resolvers.forEach(Oi)},Li.resolve=function(){if(this._stale){for(var Hi=this._data,Ui,Qi=0;Qi<this._resolvers.length;Qi++){var $i=Hi[Qi],wi=this._resolvers[Qi].resolve();(Ui||wi!==$i)&&(Ui=Ui||Hi.slice(0,Qi),Ui.push(wi))}!Ui&&this._resolvers.length!==Hi.length&&(Ui=Hi.slice(0,this._resolvers.length)),this._data=Ui||Hi,this._stale=!1}return this._data},Li.setSelector=function(Hi){for(var Ui=Hi.selectors;this._resolvers.length>Ui.length;){var Qi=this._resolvers.pop();Qi.dispose()}for(var $i=0;$i<Ui.length;$i++)$i<this._resolvers.length?this._resolvers[$i].setSelector(Ui[$i]):this._resolvers[$i]=new Ii(this._environment,this._rootIsQueryRenderer,Ui[$i],this._subscribeOnConstruction,this._onChange);this._stale=!0},Li.setVariables=function(Hi,Ui){this._resolvers.forEach(function(Qi){return Qi.setVariables(Hi,Ui)}),this._stale=!0},ki}();function Oi(ki){ki&&ki.dispose()}return RelayModernFragmentSpecResolver_1=Ti,RelayModernFragmentSpecResolver_1}var createFragmentSpecResolver_1,hasRequiredCreateFragmentSpecResolver;function requireCreateFragmentSpecResolver(){if(hasRequiredCreateFragmentSpecResolver)return createFragmentSpecResolver_1;hasRequiredCreateFragmentSpecResolver=1;var r=requireRelayModernFragmentSpecResolver();requireWarning();function t(i,n,s,a,h,v){return new r(i,s,a,v,h)}return createFragmentSpecResolver_1=t,createFragmentSpecResolver_1}var createRelayContext_1,hasRequiredCreateRelayContext;function requireCreateRelayContext(){if(hasRequiredCreateRelayContext)return createRelayContext_1;hasRequiredCreateRelayContext=1;var r=requireBrowser(),t,i;function n(s){return t||(t=s.createContext(null),i=s),s!==i&&r(!1),t}return createRelayContext_1=n,createRelayContext_1}var createRelayLoggingContext_1,hasRequiredCreateRelayLoggingContext;function requireCreateRelayLoggingContext(){if(hasRequiredCreateRelayLoggingContext)return createRelayLoggingContext_1;hasRequiredCreateRelayLoggingContext=1;var r=requireBrowser(),t,i;function n(s){return t||(t=s.createContext(null),i=s),s!==i&&r(!1),t}return createRelayLoggingContext_1=n,createRelayLoggingContext_1}var ViewerPattern,hasRequiredViewerPattern;function requireViewerPattern(){if(hasRequiredViewerPattern)return ViewerPattern;hasRequiredViewerPattern=1;var r=requireClientID(),t=r.generateClientID,i=requireRelayStoreUtils(),n=i.ROOT_ID,s=t(n,"viewer"),a="Viewer";return ViewerPattern={VIEWER_ID:s,VIEWER_TYPE:a},ViewerPattern}var defaultGetDataID_1,hasRequiredDefaultGetDataID;function requireDefaultGetDataID(){if(hasRequiredDefaultGetDataID)return defaultGetDataID_1;hasRequiredDefaultGetDataID=1;var r=requireViewerPattern(),t=r.VIEWER_ID,i=r.VIEWER_TYPE;function n(s,a){return a===i&&s.id==null?t:s.id}return defaultGetDataID_1=n,defaultGetDataID_1}var LiveResolverSuspenseSentinel,hasRequiredLiveResolverSuspenseSentinel;function requireLiveResolverSuspenseSentinel(){if(hasRequiredLiveResolverSuspenseSentinel)return LiveResolverSuspenseSentinel;hasRequiredLiveResolverSuspenseSentinel=1;var r=Object.freeze({__LIVE_RESOLVER_SUSPENSE_SENTINEL:!0});function t(){return r}function i(n){return n===r}return LiveResolverSuspenseSentinel={isSuspenseSentinel:i,suspenseSentinel:t},LiveResolverSuspenseSentinel}var objectWithoutPropertiesLoose={exports:{}},hasRequiredObjectWithoutPropertiesLoose;function requireObjectWithoutPropertiesLoose(){return hasRequiredObjectWithoutPropertiesLoose||(hasRequiredObjectWithoutPropertiesLoose=1,function(r){function t(i,n){if(i==null)return{};var s={};for(var a in i)if({}.hasOwnProperty.call(i,a)){if(n.indexOf(a)!==-1)continue;s[a]=i[a]}return s}r.exports=t,r.exports.__esModule=!0,r.exports.default=r.exports}(objectWithoutPropertiesLoose)),objectWithoutPropertiesLoose.exports}var RelayModernRecord,hasRequiredRelayModernRecord;function requireRelayModernRecord(){if(hasRequiredRelayModernRecord)return RelayModernRecord;hasRequiredRelayModernRecord=1;var r=requireInteropRequireDefault().default,t=r(requireDefineProperty()),i=r(requireObjectWithoutPropertiesLoose()),n=r(requireToPropertyKey()),s=r(requireObjectSpread2()),a=requireDeepFreeze(),h=requireClientID(),v=h.generateClientObjectClientID;h.isClientID;var hi=requireLiveResolverSuspenseSentinel(),u=hi.isSuspenseSentinel,l=requireRelayStoreUtils(),vi=l.ACTOR_IDENTIFIER_KEY,D=l.ERRORS_KEY,mi=l.ID_KEY,gi=l.INVALIDATED_AT_KEY,bi=l.REF_KEY,Ri=l.REFS_KEY,Ti=l.RELAY_RESOLVER_VALUE_KEY;l.ROOT_ID;var Ii=l.TYPENAME_KEY,qi=requireAreEqual(),Oi=requireBrowser();requireWarning();function ki(on){return(0,s.default)({},on)}function Li(on,jn){for(var Ln in on)on.hasOwnProperty(Ln)&&Ln!==mi&&Ln!==Ii&&(jn[Ln]=on[Ln])}function ji(on,jn){var Ln={};return Ln[mi]=on,Ln[Ii]=jn,Ln}function Hi(on){return on}function Ui(on){return on[mi]}function Qi(on){return D in on?Object.keys(on).filter(function(jn){return jn!==D}):Object.keys(on)}function $i(on){return on[Ii]}function wi(on,jn){var Ln;return(Ln=on[D])===null||Ln===void 0?void 0:Ln[jn]}function xi(on,jn){var Ln=on[jn];return Ln&&typeof Ln=="object"&&(!Ln.hasOwnProperty(bi)&&!Ln.hasOwnProperty(Ri)||Oi(!1)),Ln}function yi(on,jn){return jn in on}function Ei(on,jn){var Ln=on[jn];if(Ln==null)return Ln;var Hn=Ln;return typeof Hn=="object"&&Hn&&typeof Hn[bi]=="string"||Oi(!1),Hn[bi]}function Ci(on,jn){var Ln=on[jn];if(Ln==null)return!1;var Hn=Ln;return typeof Hn=="object"&&Hn&&typeof Hn[bi]=="string"}function Ni(on,jn){var Ln=on[jn];return Ln==null?Ln:(typeof Ln=="object"&&Array.isArray(Ln[Ri])||Oi(!1),Ln[Ri])}function Fi(on,jn){var Ln=on[jn];return Ln==null?!1:typeof Ln=="object"&&Array.isArray(Ln[Ri])&&Ln[Ri].every(function(Hn){return typeof Hn=="string"})}function Mi(on){if(on==null)return null;var jn=on[gi];return typeof jn!="number"?null:jn}function Si(on,jn){var Ln,Hn=on[D],ea=jn[D],ia=null;if(Hn==null&&ea==null){var Wn;for(var oa in jn)(ia||!qi(on[oa],jn[oa]))&&(ia=ia!==null?ia:(0,s.default)({},on),ia[oa]=jn[oa]);return(Wn=ia)!==null&&Wn!==void 0?Wn:on}for(var ta in jn)if(ta!==D){var aa=jn[ta],sa=ea?.[ta];if(ia==null){var ua=on[ta],da=Hn?.[ta];if(qi(ua,aa)&&qi(da,sa))continue;ia=(0,s.default)({},on),Hn!=null&&(ia[D]=(0,s.default)({},Hn))}Pi(ia,ta,aa),Bi(ia,ta,sa)}return(Ln=ia)!==null&&Ln!==void 0?Ln:on}function Ai(on,jn){if(D in on||D in jn){var Ln=on[D],Hn=(0,i.default)(on,[D].map(n.default)),ea=jn[D],ia=(0,i.default)(jn,[D].map(n.default)),Wn=(0,s.default)((0,s.default)({},Hn),ia);if(Ln==null&&ea==null)return Wn;var oa={};for(var ta in Ln)ia.hasOwnProperty(ta)||(oa[ta]=Ln[ta]);for(var aa in ea)oa[aa]=ea[aa];for(var sa in oa){Wn[D]=oa;break}return Wn}else return(0,s.default)((0,s.default)({},on),jn)}function _i(on){a(on)}function Bi(on,jn,Ln){var Hn=on[D];if(Ln!=null&&Ln.length>0)Hn==null?on[D]=(0,t.default)({},jn,Ln):Hn[jn]=Ln;else if(Hn!=null&&delete Hn[jn]){for(var ea in Hn)if(Hn.hasOwnProperty(ea))return;delete on[D]}}function Pi(on,jn,Ln){on[jn]=Ln}function zi(on,jn,Ln){var Hn={};Hn[bi]=Ln,on[jn]=Hn}function Gi(on,jn,Ln){var Hn={};Hn[Ri]=Ln,on[jn]=Hn}function Vi(on,jn,Ln,Hn){var ea={};ea[bi]=Hn,ea[vi]=Ln,on[jn]=ea}function Ki(on,jn){var Ln=on[jn];return Ln==null?Ln:(typeof Ln=="object"&&typeof Ln[bi]=="string"&&Ln[vi]!=null||Oi(!1),[Ln[vi],Ln[bi]])}function Zi(on,jn){var Ln=xi(on,Ti);return Ln==null||u(Ln)?null:(typeof Ln=="object"&&(Ln=Ln.id),typeof Ln!="string"&&Oi(!1),v(jn,Ln))}function In(on,jn){var Ln=xi(on,Ti);return Ln==null||u(Ln)?null:(Array.isArray(Ln)||Oi(!1),Ln.map(function(Hn){return Hn==null?null:(typeof Hn=="object"&&(Hn=Hn.id),typeof Hn!="string"&&Oi(!1),v(jn,Hn))}))}function Ji(on,jn,Ln){var Hn,ea;if(!qi(on[Ln],jn[Ln]))return!0;var ia=(Hn=on[D])===null||Hn===void 0?void 0:Hn[Ln],Wn=(ea=jn[D])===null||ea===void 0?void 0:ea[Ln];return!qi(ia,Wn)}function Xi(on){return on}return RelayModernRecord={clone:ki,copyFields:Li,create:ji,freeze:_i,fromObject:Hi,getActorLinkedRecordID:Ki,getDataID:Ui,getErrors:wi,getFields:Qi,getInvalidationEpoch:Mi,getLinkedRecordID:Ei,getLinkedRecordIDs:Ni,getResolverLinkedRecordID:Zi,getResolverLinkedRecordIDs:In,getType:$i,getValue:xi,hasFieldChanged:Ji,hasLinkedRecordID:Ci,hasLinkedRecordIDs:Fi,hasValue:yi,merge:Ai,setActorLinkedRecordID:Vi,setErrors:Bi,setLinkedRecordID:zi,setLinkedRecordIDs:Gi,setValue:Pi,toJSON:Xi,update:Si},RelayModernRecord}var NormalizationEngine_1,hasRequiredNormalizationEngine;function requireNormalizationEngine(){if(hasRequiredNormalizationEngine)return NormalizationEngine_1;hasRequiredNormalizationEngine=1;var r=requireInteropRequireDefault().default,t=r(requireObjectSpread2()),i=r(requireToConsumableArray()),n=requireStableCopy(),s=n.stableCopy,a=requireClientID(),h=a.generateClientID,v=requireDefaultGetDataID(),hi=requireRelayModernRecord(),u=requireRelayModernSelector(),l=u.createNormalizationSelector,vi=requireRelayStoreUtils(),D=vi.ROOT_ID,mi=vi.ROOT_TYPE,gi=vi.getStorageKey;function bi(qi){var Oi=new Error(qi);return Oi.stack,Oi}function Ri(qi){var Oi;return(Oi=JSON.stringify(s(qi)))!==null&&Oi!==void 0?Oi:""}var Ti=function(){function qi(ki){var Li,ji,Hi,Ui,Qi,$i;this._normalizeResponse=ki.normalizeResponse,this._operationLoader=(Li=ki.operationLoader)!==null&&Li!==void 0?Li:null,this._rootSelector={dataID:D,node:ki.operation,variables:ki.variables},this._options={deferDeduplicatedFields:!1,getDataID:(ji=ki.getDataID)!==null&&ji!==void 0?ji:v,log:null,path:[],treatMissingFieldsAsNull:(Hi=ki.treatMissingFieldsAsNull)!==null&&Hi!==void 0?Hi:!1},this._useExecTimeResolvers=(Ui=(Qi=ki.operation.use_exec_time_resolvers)!==null&&Qi!==void 0?Qi:(($i=ki.operation.exec_time_resolvers_enabled_provider)===null||$i===void 0?void 0:$i.get())===!0)!==null&&Ui!==void 0?Ui:!1,this._placeholders=new Map,this._bufferedResponses=new Map,this._parentRecords=new Map,this._serverComplete=!1}var Oi=qi.prototype;return Oi.processResponse=function(Li){var ji=this._normalizeResponse(Li,this._rootSelector,mi,this._options,this._useExecTimeResolvers),Hi=[],Ui=[];ji.incrementalPlaceholders!=null&&ji.incrementalPlaceholders.length>0&&this._registerPlaceholders(ji.incrementalPlaceholders,ji.source,ji.fieldPayloads,Hi,Ui),ji.followupPayloads!=null&&ji.followupPayloads.length>0&&this._processFollowups(ji.followupPayloads,Hi,Ui);var Qi=(0,t.default)((0,t.default)({},ji),{},{followupPayloads:null,incrementalPlaceholders:null,isFinal:this._computeIsFinal(ji.isFinal),isPreNormalized:!0});return{payloads:[Qi].concat(Hi),pendingModules:Ui}},Oi.processIncrementalResponse=function(Li){var ji=Li.label,Hi=Li.path;if(ji==null||Hi==null)throw bi("NormalizationEngine: Expected incremental response to have `label` and `path` properties.");var Ui=ji.indexOf("$defer$")!==-1,Qi=Ui?Hi.map(String).join("."):Hi.slice(0,-2).map(String).join("."),$i=Ii(ji,Qi),wi=this._placeholders.get($i);if(wi==null){var xi=this._bufferedResponses.get($i);return xi==null&&(xi=[],this._bufferedResponses.set($i,xi)),xi.push(Li),null}return wi.kind==="defer"?this._processDefer(Li,Hi,wi):this._processStream(Li,Hi,wi)},Oi.setServerComplete=function(){this._serverComplete=!0},Oi.isFinal=function(){return this._serverComplete&&this._bufferedResponses.size===0&&this._placeholders.size===0},Oi._processDefer=function(Li,ji,Hi){var Ui=this._normalizeResponse(Li,Hi.selector,Hi.typeName,(0,t.default)((0,t.default)({},this._options),{},{deferDeduplicatedFields:!0,path:Hi.path}),this._useExecTimeResolvers),Qi=[],$i=[];Ui.incrementalPlaceholders!=null&&Ui.incrementalPlaceholders.length>0&&this._registerPlaceholders(Ui.incrementalPlaceholders,Ui.source,Ui.fieldPayloads,Qi,$i),Ui.followupPayloads!=null&&Ui.followupPayloads.length>0&&this._processFollowups(Ui.followupPayloads,Qi,$i);var wi=Hi.selector.dataID,xi=this._parentRecords.get(wi),yi=Ui.fieldPayloads;if(xi!=null&&xi.fieldPayloads.length>0){var Ei;yi=((Ei=yi)!==null&&Ei!==void 0?Ei:[]).concat(xi.fieldPayloads)}var Ci=(0,t.default)((0,t.default)({},Ui),{},{fieldPayloads:yi,followupPayloads:null,incrementalPlaceholders:null,isFinal:this._computeIsFinal(Ui.isFinal),isPreNormalized:!0});return{payloads:[Ci].concat(Qi),pendingModules:$i}},Oi._processStream=function(Li,ji,Hi){var Ui=Hi.node,Qi=Hi.parentID,$i=Hi.variables,wi=Ui.selections[0];if(wi==null||wi.kind!=="LinkedField"||wi.plural!==!0)throw bi("NormalizationEngine: Expected @stream to be used on a plural field.");var xi=this._normalizeStreamItem(Li,Qi,wi,$i,ji,Hi.path),yi=xi.fieldPayloads,Ei=xi.itemID,Ci=xi.itemIndex,Ni=xi.prevIDs,Fi=xi.relayPayload,Mi=xi.storageKey,Si=function(Pi){var zi=Pi.get(Qi);if(zi!=null){var Gi=zi.getLinkedRecords(Mi);if(Gi!=null&&!(Gi.length!==Ni.length||Gi.some(function(Ki,Zi){return Ni[Zi]!==(Ki&&Ki.getDataID())}))){var Vi=(0,i.default)(Gi);Vi[Ci]=Pi.get(Ei),zi.setLinkedRecords(Vi,Mi)}}},Ai=Fi.fieldPayloads;if(yi.length>0){var _i;Ai=((_i=Ai)!==null&&_i!==void 0?_i:[]).concat(yi)}return{payloads:[(0,t.default)((0,t.default)({},Fi),{},{fieldPayloads:Ai,followupPayloads:null,incrementalPlaceholders:null,isFinal:this._computeIsFinal(Fi.isFinal),isPreNormalized:!0,storeUpdater:Si})],pendingModules:[]}},Oi._normalizeStreamItem=function(Li,ji,Hi,Ui,Qi,$i){var wi,xi,yi,Ei,Ci=Li.data;if(typeof Ci!="object")throw bi("NormalizationEngine: Expected the GraphQL @stream payload `data` value to be an object.");var Ni=(wi=Hi.alias)!==null&&wi!==void 0?wi:Hi.name,Fi=gi(Hi,Ui),Mi=this._parentRecords.get(ji);if(Mi==null)throw bi("NormalizationEngine: Expected the parent record `"+ji+"` for @stream data to exist.");var Si=Mi.fieldPayloads,Ai=Mi.record,_i=hi.getLinkedRecordIDs(Ai,Fi);if(_i==null)throw bi("NormalizationEngine: Expected record `"+ji+"` to have fetched field `"+Hi.name+"` with @stream.");var Bi=Qi[Qi.length-1],Pi=parseInt(Bi,10);if(Pi!==Bi||Pi<0)throw bi("NormalizationEngine: Expected path for @stream to end in a positive integer index, got `"+String(Bi)+"`");var zi=(xi=Hi.concreteType)!==null&&xi!==void 0?xi:Ci.__typename;if(typeof zi!="string")throw bi("NormalizationEngine: Expected @stream field `"+Hi.name+"` to have a __typename.");var Gi=this._options.getDataID,Vi=(yi=(Ei=typeof Gi=="function"?Gi(Ci,zi):null)!==null&&Ei!==void 0?Ei:_i?.[Pi])!==null&&yi!==void 0?yi:h(ji,Fi,Pi);if(typeof Vi!="string")throw bi("NormalizationEngine: Expected id of elements of field `"+Fi+"` to be strings.");var Ki=l(Hi,Vi,Ui),Zi=hi.clone(Ai),In=(0,i.default)(_i);In[Pi]=Vi,hi.setLinkedRecordIDs(Zi,Fi,In),this._parentRecords.set(ji,{fieldPayloads:Si,record:Zi});var Ji=this._normalizeResponse(Li,Ki,zi,(0,t.default)((0,t.default)({},this._options),{},{path:[].concat((0,i.default)($i),[Ni,String(Pi)])}),this._useExecTimeResolvers);return{fieldPayloads:Si,itemID:Vi,itemIndex:Pi,prevIDs:_i,relayPayload:Ji,storageKey:Fi}},Oi._registerPlaceholders=function(Li,ji,Hi,Ui,Qi){for(var $i=this,wi=function(Ni){var Fi=Li[Ni],Mi=Fi.label,Si=Fi.path,Ai=Si.map(String).join("."),_i=Ii(Mi,Ai);$i._placeholders.set(_i,Fi);var Bi=void 0;Fi.kind==="stream"?Bi=Fi.parentID:Bi=Fi.selector.dataID;var Pi=ji.get(Bi);if(Pi==null)throw bi("NormalizationEngine: Expected record `"+Bi+"` to exist.");var zi=(Hi??[]).filter(function(ea){var ia=h(ea.dataID,ea.fieldKey);return ea.dataID===Bi||ia===Bi}),Gi=$i._parentRecords.get(Bi);if(Gi!=null){for(var Vi=hi.update(Gi.record,Pi),Ki=new Map,Zi=0;Zi<Gi.fieldPayloads.length;Zi++){var In=Gi.fieldPayloads[Zi];Ki.set(Ri(In),In)}for(var Ji=0;Ji<zi.length;Ji++){var Xi=zi[Ji];Ki.set(Ri(Xi),Xi)}$i._parentRecords.set(Bi,{fieldPayloads:Array.from(Ki.values()),record:Vi})}else $i._parentRecords.set(Bi,{fieldPayloads:zi,record:Pi});var on=$i._bufferedResponses.get(_i);if(on!=null){$i._bufferedResponses.delete(_i);for(var jn=0;jn<on.length;jn++){var Ln=on[jn],Hn=void 0;Fi.kind==="defer"?Hn=$i._processDefer(Ln,(yi=Ln.path)!==null&&yi!==void 0?yi:[],Fi):Hn=$i._processStream(Ln,(Ei=Ln.path)!==null&&Ei!==void 0?Ei:[],Fi),Hn!=null&&(Ui.push.apply(Ui,(0,i.default)(Hn.payloads)),Qi.push.apply(Qi,(0,i.default)(Hn.pendingModules)))}}},xi=0;xi<Li.length;xi++){var yi,Ei;wi(xi)}},Oi._processFollowups=function(Li,ji,Hi){for(var Ui=0;Ui<Li.length;Ui++){var Qi=Li[Ui];Qi.kind==="ModuleImportPayload"&&this._processModuleImport(Qi,ji,Hi)}},Oi._processModuleImport=function(Li,ji,Hi){var Ui=this,Qi=this._operationLoader;if(Qi!=null){var $i=Qi.get(Li.operationReference);if($i!=null){var wi=this._normalizeFollowup(Li,$i);ji.push.apply(ji,(0,i.default)(wi.payloads)),Hi.push.apply(Hi,(0,i.default)(wi.pendingModules));return}var xi={payloads:[],pendingModules:[]};Hi.push(Qi.load(Li.operationReference).then(function(yi){return yi!=null?Ui._normalizeFollowup(Li,yi):xi}).catch(function(yi){return xi}))}},Oi._normalizeFollowup=function(Li,ji){var Hi=ji.kind==="SplitOperation"?ji:ji.operation,Ui=l(Hi,Li.dataID,Li.variables),Qi=this._normalizeResponse({data:Li.data},Ui,Li.typeName,(0,t.default)((0,t.default)({},this._options),{},{path:Li.path}),this._useExecTimeResolvers),$i=[],wi=[];Qi.incrementalPlaceholders!=null&&Qi.incrementalPlaceholders.length>0&&this._registerPlaceholders(Qi.incrementalPlaceholders,Qi.source,Qi.fieldPayloads,$i,wi),Qi.followupPayloads!=null&&Qi.followupPayloads.length>0&&this._processFollowups(Qi.followupPayloads,$i,wi);var xi=(0,t.default)((0,t.default)({},Qi),{},{followupPayloads:null,incrementalPlaceholders:null,isFinal:this._computeIsFinal(Qi.isFinal),isPreNormalized:!0});return{payloads:[xi].concat($i),pendingModules:wi}},Oi._computeIsFinal=function(Li){return(Li||this._serverComplete)&&this._bufferedResponses.size===0},qi}();function Ii(qi,Oi){return"".concat(qi,"::").concat(Oi)}return NormalizationEngine_1=Ti,NormalizationEngine_1}var RelayRecordState_1,hasRequiredRelayRecordState;function requireRelayRecordState(){if(hasRequiredRelayRecordState)return RelayRecordState_1;hasRequiredRelayRecordState=1;var r={EXISTENT:"EXISTENT",NONEXISTENT:"NONEXISTENT",UNKNOWN:"UNKNOWN"};return RelayRecordState_1=r,RelayRecordState_1}var RelayRecordSource_1,hasRequiredRelayRecordSource;function requireRelayRecordSource(){if(hasRequiredRelayRecordSource)return RelayRecordSource_1;hasRequiredRelayRecordSource=1;var r=requireInteropRequireDefault().default,t=r(requireCreateForOfIteratorHelper()),i=requireRelayFeatureFlags(),n=requireRelayModernRecord(),s=requireRelayRecordState(),a=requireRelayStoreUtils(),h=a.RELAY_RESOLVER_RECORD_TYPENAME,v=s.EXISTENT,hi=s.NONEXISTENT,u=s.UNKNOWN,l=function(){function vi(mi){var gi=this;this._records=new Map,mi!=null&&Object.keys(mi).forEach(function(bi){var Ri=mi[bi],Ti=n.fromObject(Ri);gi._records.set(bi,Ti)})}vi.create=function(gi){return new vi(gi)};var D=vi.prototype;return D.clear=function(){this._records=new Map},D.delete=function(gi){this._records.set(gi,null)},D.get=function(gi){return this._records.get(gi)},D.getRecordIDs=function(){return Array.from(this._records.keys())},D.getStatus=function(gi){return this._records.has(gi)?this._records.get(gi)==null?hi:v:u},D.has=function(gi){return this._records.has(gi)},D.remove=function(gi){this._records.delete(gi)},D.set=function(gi,bi){this._records.set(gi,bi)},D.size=function(){return this._records.size},D.toJSON=function(){var gi={},bi=(0,t.default)(this._records),Ri;try{for(bi.s();!(Ri=bi.n()).done;){var Ti=Ri.value,Ii=Ti[0],qi=Ti[1];i.FILTER_OUT_RELAY_RESOLVER_RECORDS&&qi!=null&&n.getType(qi)===h||(gi[Ii]=n.toJSON(qi))}}catch(Oi){bi.e(Oi)}finally{bi.f()}return gi},vi}();return RelayRecordSource_1=l,RelayRecordSource_1}var ActorIdentifier,hasRequiredActorIdentifier;function requireActorIdentifier(){if(hasRequiredActorIdentifier)return ActorIdentifier;hasRequiredActorIdentifier=1;var r=requireBrowser(),t="INTERNAL_ACTOR_IDENTIFIER_DO_NOT_USE";function i(n){n!==t&&r(!1)}return ActorIdentifier={INTERNAL_ACTOR_IDENTIFIER_DO_NOT_USE:t,assertInternalActorIdentifier:i,getActorIdentifier:function(s){return s},getDefaultActorIdentifier:function(){throw new Error("Not Implemented")}},ActorIdentifier}var ActorUtils,hasRequiredActorUtils;function requireActorUtils(){if(hasRequiredActorUtils)return ActorUtils;hasRequiredActorUtils=1;var r="actor_key",t=requireActorIdentifier(),i=t.getActorIdentifier;function n(s){if(s!=null&&typeof s=="object"&&typeof s[r]=="string")return i(s[r])}return ActorUtils={ACTOR_IDENTIFIER_FIELD_NAME:r,getActorIdentifierFromPayload:n},ActorUtils}var RelayErrorTrie,hasRequiredRelayErrorTrie;function requireRelayErrorTrie(){if(hasRequiredRelayErrorTrie)return RelayErrorTrie;hasRequiredRelayErrorTrie=1;var r=requireInteropRequireDefault().default,t=r(requireObjectSpread2()),i=r(requireObjectWithoutPropertiesLoose()),n=r(requireCreateForOfIteratorHelper()),s=r(requireToConsumableArray()),a=["path","locations"],h=Symbol("$SELF");function v(vi){if(vi==null)return null;var D=new Map,mi=(0,n.default)(vi),gi;try{for(mi.s();!(gi=mi.n()).done;){var bi=gi.value,Ri=bi.path,Ti=bi.locations,Ii=(0,i.default)(bi,a);if(Ri!=null){var qi=Ri.length;if(qi!==0){for(var Oi=qi-1,ki=D,Li=0;Li<Oi;Li++){var ji=Ri[Li],Hi=ki.get(ji);if(Hi instanceof Map){ki=Hi;continue}var Ui=new Map;Array.isArray(Hi)&&Ui.set(h,Hi),ki.set(ji,Ui),ki=Ui}var Qi=Ri[Oi],$i=ki.get(Qi);$i instanceof Map&&(ki=$i,$i=ki.get(Qi),Qi=h),Array.isArray($i)?$i.push(Ii):ki.set(Qi,[Ii])}}}}catch(wi){mi.e(wi)}finally{mi.f()}return D}function hi(vi,D){var mi=vi.get(D);if(mi==null)return null;if(Array.isArray(mi))return mi;var gi=[];return u(mi,gi),gi}function u(vi,D){var mi=(0,n.default)(vi),gi;try{for(mi.s();!(gi=mi.n()).done;){var bi=gi.value,Ri=bi[0],Ti=bi[1],Ii=D.length;if(Array.isArray(Ti)?D.push.apply(D,(0,s.default)(Ti)):u(Ti,D),Ri!==h)for(var qi=D.length,Oi=Ii;Oi<qi;Oi++){var ki=D[Oi];ki.path==null?D[Oi]=(0,t.default)((0,t.default)({},ki),{},{path:[Ri]}):ki.path.unshift(Ri)}}}catch(Li){mi.e(Li)}finally{mi.f()}}function l(vi,D){var mi=vi.get(D);return mi instanceof Map?mi:null}return RelayErrorTrie={SELF:h,buildErrorTrie:v,getErrorsByKey:hi,getNestedErrorTrieByKey:l},RelayErrorTrie}var TypeID,hasRequiredTypeID;function requireTypeID(){if(hasRequiredTypeID)return TypeID;hasRequiredTypeID=1;var r="client:__type:",t="__TypeSchema";function i(s){return r+s}function n(s){return s.indexOf(r)===0}return TypeID={generateTypeID:i,isTypeID:n,TYPE_SCHEMA_TYPE:t},TypeID}var RelayResponseNormalizer_1,hasRequiredRelayResponseNormalizer;function requireRelayResponseNormalizer(){if(hasRequiredRelayResponseNormalizer)return RelayResponseNormalizer_1;hasRequiredRelayResponseNormalizer=1;var r=requireInteropRequireDefault().default,t=r(requireCreateForOfIteratorHelper()),i=r(requireToConsumableArray()),n=requireActorUtils();n.ACTOR_IDENTIFIER_FIELD_NAME;var s=n.getActorIdentifierFromPayload,a=requireRelayFeatureFlags(),h=requireClientID(),v=h.generateClientID,hi=h.isClientID,u=requireRelayConcreteVariables(),l=u.getLocalVariables,vi=requireRelayErrorTrie(),D=vi.buildErrorTrie,mi=vi.getErrorsByKey,gi=vi.getNestedErrorTrieByKey,bi=requireRelayModernRecord(),Ri=requireRelayModernSelector(),Ti=Ri.createNormalizationSelector,Ii=requireRelayStoreUtils(),qi=Ii.ROOT_ID,Oi=Ii.ROOT_TYPE,ki=Ii.TYPENAME_KEY,Li=Ii.getArgumentValues,ji=Ii.getHandleStorageKey,Hi=Ii.getModuleComponentKey,Ui=Ii.getModuleOperationKey,Qi=Ii.getStorageKey,$i=requireTypeID(),wi=$i.TYPE_SCHEMA_TYPE,xi=$i.generateTypeID;requireAreEqual();var yi=requireBrowser();requireWarning();function Ei(Ni,Fi,Mi,Si,Ai,_i){var Bi=Fi.dataID,Pi=Fi.node,zi=Fi.variables,Gi=new Ci(Ni,zi,Si,_i??!1);return Gi.normalizeResponse(Pi,Bi,Mi,Ai)}var Ci=function(){function Ni(Mi,Si,Ai,_i){this._actorIdentifier=Ai.actorIdentifier,this._getDataId=Ai.getDataID,this._handleFieldPayloads=[],this._treatMissingFieldsAsNull=Ai.treatMissingFieldsAsNull,this._deferDeduplicatedFields=Ai.deferDeduplicatedFields,this._incrementalPlaceholders=[],this._isClientExtension=!1,this._isUnmatchedAbstractType=!1,this._useExecTimeResolvers=_i,this._followupPayloads=[],this._path=Ai.path?(0,i.default)(Ai.path):[],this._recordSource=Mi,this._variables=Si,this._shouldProcessClientComponents=Ai.shouldProcessClientComponents,this._log=Ai.log,this._s2cExecutions=new Map}var Fi=Ni.prototype;return Fi.normalizeResponse=function(Si,Ai,_i,Bi){var Pi=this._recordSource.get(Ai);return Pi||yi(!1),this._assignClientAbstractTypes(Si),this._errorTrie=D(Bi),this._traverseSelections(Si,Pi,_i),{errors:Bi,fieldPayloads:this._handleFieldPayloads,followupPayloads:this._followupPayloads,incrementalPlaceholders:this._incrementalPlaceholders,isFinal:!1,s2cExecutions:this._s2cExecutions.size>0?Array.from(this._s2cExecutions.entries()).map(function(zi){var Gi=zi[0],Vi=zi[1];return{recordID:Gi,selections:Vi.selections,typeName:Vi.typeName}}):void 0,source:this._recordSource}},Fi._assignClientAbstractTypes=function(Si){var Ai=Si.clientAbstractTypes;if(Ai!=null)for(var _i=0,Bi=Object.keys(Ai);_i<Bi.length;_i++){var Pi=Bi[_i],zi=(0,t.default)(Ai[Pi]),Gi;try{for(zi.s();!(Gi=zi.n()).done;){var Vi=Gi.value,Ki=xi(Vi),Zi=this._recordSource.get(Ki);Zi==null&&(Zi=bi.create(Ki,wi),this._recordSource.set(Ki,Zi)),bi.setValue(Zi,Pi,!0)}}catch(In){zi.e(In)}finally{zi.f()}}},Fi._getVariableValue=function(Si){return this._variables.hasOwnProperty(Si)||yi(!1),this._variables[Si]},Fi._getRecordType=function(Si){var Ai=Si[ki];return Ai==null&&yi(!1),Ai},Fi._traverseSelections=function(Si,Ai,_i){for(var Bi,Pi,zi=0;zi<Si.selections.length;zi++){var Gi=Si.selections[zi];switch(Gi.kind){case"ScalarField":case"LinkedField":this._normalizeField(Gi,Ai,_i);break;case"Condition":var Vi=!!this._getVariableValue(Gi.condition);Vi===Gi.passingValue&&this._traverseSelections(Gi,Ai,_i);break;case"FragmentSpread":{var Ki=this._variables;this._variables=l(this._variables,Gi.fragment.argumentDefinitions,Gi.args),this._traverseSelections(Gi.fragment,Ai,_i),this._variables=Ki;break}case"InlineFragment":{this._normalizeInlineFragment(Gi,Ai,_i);break}case"TypeDiscriminator":{var Zi=Gi.abstractKey,In=Object.prototype.hasOwnProperty.call(_i,Zi),Ji=bi.getType(Ai),Xi=xi(Ji),on=this._recordSource.get(Xi);on==null&&(on=bi.create(Xi,wi),this._recordSource.set(Xi,on)),bi.setValue(on,Zi,In);break}case"LinkedHandle":case"ScalarHandle":var jn=Gi.args?Li(Gi.args,this._variables):{},Ln=Qi(Gi,this._variables),Hn=ji(Gi,this._variables);this._handleFieldPayloads.push({args:jn,dataID:bi.getDataID(Ai),fieldKey:Ln,handle:Gi.handle,handleArgs:Gi.handleArgs?Li(Gi.handleArgs,this._variables):{},handleKey:Hn});break;case"ModuleImport":this._normalizeModuleImport(Gi,Ai,_i);break;case"Defer":this._normalizeDefer(Gi,Ai,_i);break;case"Stream":this._normalizeStream(Gi,Ai,_i);break;case"ClientExtension":var ea=this._isClientExtension;this._isClientExtension=!0,this._traverseSelections(Gi,Ai,_i),this._isClientExtension=ea;break;case"ClientComponent":if(this._shouldProcessClientComponents===!1)break;this._traverseSelections(Gi.fragment,Ai,_i);break;case"ActorChange":this._normalizeActorChange(Gi,Ai,_i);break;case"RelayResolver":case"RelayLiveResolver":this._useExecTimeResolvers?((Bi=Gi.resolverInfo)===null||Bi===void 0?void 0:Bi.rootFragment)!=null&&this._collectS2CExecution(Gi,Ai):this._normalizeResolver(Gi,Ai,_i);break;case"ClientEdgeToClientObject":this._useExecTimeResolvers?((Pi=Gi.backingField.resolverInfo)===null||Pi===void 0?void 0:Pi.rootFragment)!=null&&this._collectS2CExecution(Gi,Ai):this._normalizeResolver(Gi.backingField,Ai,_i);break;default:yi(!1)}}},Fi._normalizeInlineFragment=function(Si,Ai,_i){var Bi=Si.abstractKey;if(Bi==null){var Pi=bi.getType(Ai);(Pi===Si.type||Pi===Oi)&&this._traverseSelections(Si,Ai,_i)}else{var zi=Object.prototype.hasOwnProperty.call(_i,Bi),Gi=bi.getType(Ai),Vi=xi(Gi),Ki=this._recordSource.get(Vi);Ki==null&&(Ki=bi.create(Vi,wi),this._recordSource.set(Vi,Ki)),bi.setValue(Ki,Bi,zi),zi&&this._traverseSelections(Si,Ai,_i)}},Fi._normalizeResolver=function(Si,Ai,_i){Si.fragment!=null&&this._normalizeInlineFragment(Si.fragment,Ai,_i)},Fi._collectS2CExecution=function(Si,Ai){var _i=bi.getDataID(Ai),Bi=bi.getType(Ai),Pi=this._s2cExecutions.get(_i);Pi==null&&(Pi={selections:[],typeName:Bi},this._s2cExecutions.set(_i,Pi)),Pi.selections.push(Si)},Fi._normalizeDefer=function(Si,Ai,_i){var Bi=Si.if===null||this._getVariableValue(Si.if);Bi===!1?this._traverseSelections(Si,Ai,_i):this._incrementalPlaceholders.push({actorIdentifier:this._actorIdentifier,data:_i,kind:"defer",label:Si.label,path:(0,i.default)(this._path),selector:Ti(Si,bi.getDataID(Ai),this._variables),typeName:bi.getType(Ai)})},Fi._normalizeStream=function(Si,Ai,_i){this._traverseSelections(Si,Ai,_i);var Bi=Si.if===null||this._getVariableValue(Si.if);Bi===!0&&this._incrementalPlaceholders.push({actorIdentifier:this._actorIdentifier,kind:"stream",label:Si.label,node:Si,parentID:bi.getDataID(Ai),path:(0,i.default)(this._path),variables:this._variables})},Fi._normalizeModuleImport=function(Si,Ai,_i){typeof _i=="object"&&_i||yi(!1);var Bi=bi.getType(Ai),Pi=Hi(Si.documentName),zi=Si.componentModuleProvider||_i[Pi];bi.setValue(Ai,Pi,zi??null);var Gi=Ui(Si.documentName),Vi=Si.operationModuleProvider||_i[Gi];bi.setValue(Ai,Gi,Vi??null),Vi!=null&&this._followupPayloads.push({actorIdentifier:this._actorIdentifier,args:Si.args,data:_i,dataID:bi.getDataID(Ai),kind:"ModuleImportPayload",operationReference:Vi,path:(0,i.default)(this._path),typeName:Bi,variables:this._variables})},Fi._normalizeField=function(Si,Ai,_i){typeof _i=="object"&&_i||yi(!1);var Bi=Si.alias||Si.name,Pi=Qi(Si,this._variables),zi=_i[Bi],Gi=a.ENABLE_NONCOMPLIANT_ERROR_HANDLING_ON_LISTS&&Array.isArray(zi)&&zi.length===0;if(zi==null||Gi){if(zi===void 0){var Vi=this._isClientExtension||this._isUnmatchedAbstractType||this._deferDeduplicatedFields;if(Vi)return;if(!this._treatMissingFieldsAsNull)return}Si.kind==="ScalarField"&&this._validateConflictingFieldsWithIdenticalId(Ai,Pi,null),Gi?Si.kind==="LinkedField"?bi.setLinkedRecordIDs(Ai,Pi,[]):bi.setValue(Ai,Pi,[]):bi.setValue(Ai,Pi,null);var Ki=this._errorTrie;if(Ki!=null){var Zi=mi(Ki,Bi);Zi!=null&&bi.setErrors(Ai,Pi,Zi)}return}if(Si.kind==="ScalarField")this._validateConflictingFieldsWithIdenticalId(Ai,Pi,zi),bi.setValue(Ai,Pi,zi);else if(Si.kind==="LinkedField"){this._path.push(Bi);var In=this._errorTrie;this._errorTrie=In==null?null:gi(In,Bi),Si.plural?this._normalizePluralLink(Si,Ai,Pi,zi):this._normalizeLink(Si,Ai,Pi,zi),this._errorTrie=In,this._path.pop()}else yi(!1)},Fi._normalizeActorChange=function(Si,Ai,_i){var Bi,Pi=Si.linkedField;typeof _i=="object"&&_i||yi(!1);var zi=Pi.alias||Pi.name,Gi=Qi(Pi,this._variables),Vi=_i[zi];if(Vi==null){if(Vi===void 0){var Ki=this._isClientExtension||this._isUnmatchedAbstractType;if(Ki)return;if(!this._treatMissingFieldsAsNull)return}bi.setValue(Ai,Gi,null);return}var Zi=s(Vi);if(Zi==null){bi.setValue(Ai,Gi,null);return}var In=(Bi=Pi.concreteType)!==null&&Bi!==void 0?Bi:this._getRecordType(Vi),Ji=this._getDataId(Vi,In)||bi.getLinkedRecordID(Ai,Gi)||v(bi.getDataID(Ai),Gi);typeof Ji!="string"&&yi(!1),bi.setActorLinkedRecordID(Ai,Gi,Zi,Ji),this._followupPayloads.push({actorIdentifier:Zi,data:Vi,dataID:Ji,kind:"ActorPayload",node:Pi,path:[].concat((0,i.default)(this._path),[zi]),typeName:In,variables:this._variables})},Fi._normalizeLink=function(Si,Ai,_i,Bi){var Pi;typeof Bi=="object"&&Bi||yi(!1);var zi=this._getDataId(Bi,(Pi=Si.concreteType)!==null&&Pi!==void 0?Pi:this._getRecordType(Bi))||bi.getLinkedRecordID(Ai,_i)||v(bi.getDataID(Ai),_i);typeof zi!="string"&&yi(!1),this._validateConflictingLinkedFieldsWithIdenticalId(bi.getLinkedRecordID(Ai,_i),zi,_i),bi.setLinkedRecordID(Ai,_i,zi);var Gi=this._recordSource.get(zi);if(Gi)this._validateRecordType(Gi,Si,Bi);else{var Vi=Si.concreteType||this._getRecordType(Bi);Gi=bi.create(zi,Vi),this._recordSource.set(zi,Gi)}this._traverseSelections(Si,Gi,Bi)},Fi._normalizePluralLink=function(Si,Ai,_i,Bi){var Pi=this;Array.isArray(Bi)||yi(!1);var zi=bi.getLinkedRecordIDs(Ai,_i),Gi=[];Bi.forEach(function(Vi,Ki){var Zi;if(Vi==null){Gi.push(Vi);return}Pi._path.push(String(Ki));var In=Pi._errorTrie;Pi._errorTrie=In==null?null:gi(In,Ki),typeof Vi!="object"&&yi(!1);var Ji=Pi._getDataId(Vi,(Zi=Si.concreteType)!==null&&Zi!==void 0?Zi:Pi._getRecordType(Vi))||zi&&zi[Ki]||v(bi.getDataID(Ai),_i,Ki);typeof Ji!="string"&&yi(!1),Gi.push(Ji);var Xi=Pi._recordSource.get(Ji);if(Xi)Pi._validateRecordType(Xi,Si,Vi);else{var on=Si.concreteType||Pi._getRecordType(Vi);Xi=bi.create(Ji,on),Pi._recordSource.set(Ji,Xi)}zi&&Pi._validateConflictingLinkedFieldsWithIdenticalId(zi[Ki],Ji,_i),Pi._traverseSelections(Si,Xi,Vi),Pi._errorTrie=In,Pi._path.pop()}),bi.setLinkedRecordIDs(Ai,_i,Gi)},Fi._validateRecordType=function(Si,Ai,_i){if(a.ENABLE_STORE_ID_COLLISION_LOGGING){var Bi,Pi=(Bi=Ai.concreteType)!==null&&Bi!==void 0?Bi:this._getRecordType(_i),zi=bi.getDataID(Si),Gi=hi(zi)&&zi!==qi||bi.getType(Si)===Pi;if(!Gi){var Vi={name:"idCollision.typename",new_typename:Pi,previous_typename:bi.getType(Si)};this._log!=null&&this._log(Vi)}}},Fi._validateConflictingFieldsWithIdenticalId=function(Si,Ai,_i){},Fi._validateConflictingLinkedFieldsWithIdenticalId=function(Si,Ai,_i){},Ni}();return RelayResponseNormalizer_1={normalize:Ei},RelayResponseNormalizer_1}var normalizeResponse_1,hasRequiredNormalizeResponse;function requireNormalizeResponse(){if(hasRequiredNormalizeResponse)return normalizeResponse_1;hasRequiredNormalizeResponse=1;var r=requireInteropRequireDefault().default,t=r(requireObjectSpread2()),i=r(requireRelayModernRecord()),n=r(requireRelayRecordSource()),s=r(requireRelayResponseNormalizer());function a(h,v,hi,u,l){var vi,D=h.data,mi=h.errors,gi=n.default.create(),bi=i.default.create(v.dataID,hi);gi.set(v.dataID,bi);var Ri=s.default.normalize(gi,v,D,u,mi,l);return(0,t.default)((0,t.default)({},Ri),{},{isFinal:((vi=h.extensions)===null||vi===void 0?void 0:vi.is_final)===!0})}return normalizeResponse_1=a,normalizeResponse_1}var readInlineData_1,hasRequiredReadInlineData;function requireReadInlineData(){if(hasRequiredReadInlineData)return readInlineData_1;hasRequiredReadInlineData=1;var r=requireGraphQLTag(),t=r.getInlineDataFragment,i=requireRelayStoreUtils(),n=i.FRAGMENTS_KEY,s=requireBrowser();function a(h,v){var hi,u=t(h);if(v==null)return v;typeof v!="object"&&s(!1);var l=(hi=v[n])===null||hi===void 0?void 0:hi[u.name];return l==null&&s(!1),l}return readInlineData_1=a,readInlineData_1}var generateID_1,hasRequiredGenerateID;function requireGenerateID(){if(hasRequiredGenerateID)return generateID_1;hasRequiredGenerateID=1;var r=1e5;function t(){return r++}return generateID_1=t,generateID_1}var wrapNetworkWithLogObserver_1,hasRequiredWrapNetworkWithLogObserver;function requireWrapNetworkWithLogObserver(){if(hasRequiredWrapNetworkWithLogObserver)return wrapNetworkWithLogObserver_1;hasRequiredWrapNetworkWithLogObserver=1;var r=requireGenerateID();function t(i,n){return{execute:function(a,h,v,hi,u,l,vi,D){var mi=r(),gi={start:function(Ti){i.__log({name:"network.start",networkRequestId:mi,params:a,variables:h,cacheConfig:v})},next:function(Ti){i.__log({name:"network.next",networkRequestId:mi,response:Ti})},error:function(Ti){i.__log({name:"network.error",networkRequestId:mi,error:Ti})},complete:function(){i.__log({name:"network.complete",networkRequestId:mi})},unsubscribe:function(){i.__log({name:"network.unsubscribe",networkRequestId:mi})}},bi=function(Ti){i.__log({name:"network.info",networkRequestId:mi,info:Ti})};return n.execute(a,h,v,hi,bi,l,vi,D).do(gi)}}}return wrapNetworkWithLogObserver_1=t,wrapNetworkWithLogObserver_1}var RelayOperationTracker_1,hasRequiredRelayOperationTracker;function requireRelayOperationTracker(){if(hasRequiredRelayOperationTracker)return RelayOperationTracker_1;hasRequiredRelayOperationTracker=1;var r=requireInteropRequireDefault().default,t=r(requireCreateForOfIteratorHelper()),i=requireBrowser(),n=function(){function s(){this._ownersToPendingOperations=new Map,this._pendingOperationsToOwners=new Map,this._ownersToPendingPromise=new Map}var a=s.prototype;return a.update=function(v,hi){if(hi.size!==0){var u=v.identifier,l=new Set,vi=(0,t.default)(hi),D;try{for(vi.s();!(D=vi.n()).done;){var mi=D.value,gi=mi.identifier,bi=this._ownersToPendingOperations.get(gi);bi!=null?bi.has(u)||(bi.set(u,v),l.add(gi)):(this._ownersToPendingOperations.set(gi,new Map([[u,v]])),l.add(gi))}}catch(Oi){vi.e(Oi)}finally{vi.f()}if(l.size!==0){var Ri=this._pendingOperationsToOwners.get(u)||new Set,Ti=(0,t.default)(l),Ii;try{for(Ti.s();!(Ii=Ti.n()).done;){var qi=Ii.value;this._resolveOwnerResolvers(qi),Ri.add(qi)}}catch(Oi){Ti.e(Oi)}finally{Ti.f()}this._pendingOperationsToOwners.set(u,Ri)}}},a.complete=function(v){var hi=v.identifier,u=this._pendingOperationsToOwners.get(hi);if(u!=null){var l=new Set,vi=new Set,D=(0,t.default)(u),mi;try{for(D.s();!(mi=D.n()).done;){var gi=mi.value,bi=this._ownersToPendingOperations.get(gi);bi&&(bi.delete(hi),bi.size>0?vi.add(gi):l.add(gi))}}catch(Li){D.e(Li)}finally{D.f()}var Ri=(0,t.default)(l),Ti;try{for(Ri.s();!(Ti=Ri.n()).done;){var Ii=Ti.value;this._resolveOwnerResolvers(Ii),this._ownersToPendingOperations.delete(Ii)}}catch(Li){Ri.e(Li)}finally{Ri.f()}var qi=(0,t.default)(vi),Oi;try{for(qi.s();!(Oi=qi.n()).done;){var ki=Oi.value;this._resolveOwnerResolvers(ki)}}catch(Li){qi.e(Li)}finally{qi.f()}this._pendingOperationsToOwners.delete(hi)}},a._resolveOwnerResolvers=function(v){var hi=this._ownersToPendingPromise.get(v);hi?.resolve(),this._ownersToPendingPromise.delete(v)},a.getPendingOperationsAffectingOwner=function(v){var hi=v.identifier,u=this._ownersToPendingOperations.get(hi);if(u==null||u.size===0)return null;var l=this._ownersToPendingPromise.get(hi);if(l!=null)return{promise:l.promise,pendingOperations:l.pendingOperations};var vi,D=new Promise(function(gi){vi=gi});vi==null&&i(!1);var mi=Array.from(u.values());return this._ownersToPendingPromise.set(hi,{promise:D,resolve:vi,pendingOperations:mi}),{promise:D,pendingOperations:mi}},s}();return RelayOperationTracker_1=n,RelayOperationTracker_1}var registerEnvironmentWithDevTools_1,hasRequiredRegisterEnvironmentWithDevTools;function requireRegisterEnvironmentWithDevTools(){if(hasRequiredRegisterEnvironmentWithDevTools)return registerEnvironmentWithDevTools_1;hasRequiredRegisterEnvironmentWithDevTools=1;function r(t){var i=typeof commonjsGlobal<"u"?commonjsGlobal:typeof window<"u"?window:void 0,n=i&&i.__RELAY_DEVTOOLS_HOOK__;n&&n.registerEnvironment(t)}return registerEnvironmentWithDevTools_1=r,registerEnvironmentWithDevTools_1}var defaultRelayFieldLogger_1,hasRequiredDefaultRelayFieldLogger;function requireDefaultRelayFieldLogger(){if(hasRequiredDefaultRelayFieldLogger)return defaultRelayFieldLogger_1;hasRequiredDefaultRelayFieldLogger=1;var r=function(i){};return defaultRelayFieldLogger_1=r,defaultRelayFieldLogger_1}var getOperation_1,hasRequiredGetOperation;function requireGetOperation(){if(hasRequiredGetOperation)return getOperation_1;hasRequiredGetOperation=1;var r=requireRelayConcreteNode(),t=r.REQUEST,i=r.SPLIT_OPERATION;function n(s){switch(s.kind){case t:return s.operation;case i:default:return s}}return getOperation_1=n,getOperation_1}var RelayError,hasRequiredRelayError;function requireRelayError(){if(hasRequiredRelayError)return RelayError;hasRequiredRelayError=1;function r(t,i,n){for(var s,a=arguments.length,h=new Array(a>3?a-3:0),v=3;v<a;v++)h[v-3]=arguments[v];var hi=0,u=n.replace(/%s/g,function(){return String(h[hi++])}),l=new Error(u),vi=(s=h[2])!==null&&s!==void 0?s:null,D=Object.assign(l,{name:i,messageFormat:n,messageParams:h,type:t,operation:vi,taalOpcodes:[2,2]});if(D.stack===void 0)try{throw D}catch{}return D}return RelayError={create:function(i,n){for(var s=arguments.length,a=new Array(s>2?s-2:0),h=2;h<s;h++)a[h-2]=arguments[h];return r.apply(void 0,["error",i,n].concat(a))},createWarning:function(i,n){for(var s=arguments.length,a=new Array(s>2?s-2:0),h=2;h<s;h++)a[h-2]=arguments[h];return r.apply(void 0,["warn",i,n].concat(a))}},RelayError}var withStartAndDuration_1,hasRequiredWithStartAndDuration;function requireWithStartAndDuration(){if(hasRequiredWithStartAndDuration)return withStartAndDuration_1;hasRequiredWithStartAndDuration=1;var r,t,i=typeof window<"u"&&typeof((r=window)===null||r===void 0||(t=r.performance)===null||t===void 0?void 0:t.now)=="function";function n(){return i?window.performance.now():Date.now()}function s(a){var h=n(),v=a();return[h,n()-h,v]}return withStartAndDuration_1=s,withStartAndDuration_1}var OperationExecutor,hasRequiredOperationExecutor;function requireOperationExecutor(){if(hasRequiredOperationExecutor)return OperationExecutor;hasRequiredOperationExecutor=1;var r=requireInteropRequireDefault().default,t=r(requireCreateForOfIteratorHelper()),i=r(requireToConsumableArray()),n=requireRelayObservable(),s=requireGenerateID(),a=requireGetOperation(),h=requireRelayError(),v=requireRelayFeatureFlags(),hi=requireStableCopy(),u=hi.stableCopy,l=requireWithStartAndDuration(),vi=requireClientID(),D=vi.generateClientID,mi=vi.generateUniqueClientID,gi=requireRelayConcreteVariables(),bi=gi.getLocalVariables,Ri=requireRelayModernRecord(),Ti=requireRelayModernSelector(),Ii=Ti.createNormalizationSelector,qi=Ti.createReaderSelector,Oi=requireRelayRecordSource(),ki=requireRelayStoreUtils(),Li=ki.ROOT_TYPE,ji=ki.TYPENAME_KEY,Hi=ki.getStorageKey,Ui=requireBrowser(),Qi=requireWarning();function $i(Ci){return new wi(Ci)}var wi=function(){function Ci(Fi){var Mi=this,Si,Ai,_i,Bi=Fi.actorIdentifier,Pi=Fi.getDataID,zi=Fi.getPublishQueue,Gi=Fi.getStore,Vi=Fi.isClientPayload,Ki=Fi.operation,Zi=Fi.operationExecutions,In=Fi.operationLoader,Ji=Fi.operationTracker,Xi=Fi.optimisticConfig,on=Fi.scheduler,jn=Fi.shouldProcessClientComponents,Ln=Fi.sink,Hn=Fi.source,ea=Fi.treatMissingFieldsAsNull,ia=Fi.deferDeduplicatedFields,Wn=Fi.updater,oa=Fi.log,ta=Fi.normalizeResponse;this._actorIdentifier=Bi,this._getDataID=Pi,this._treatMissingFieldsAsNull=ea,this._deferDeduplicatedFields=ia,this._incrementalPayloadsPending=!1,this._incrementalResults=new Map,this._log=oa,this._executeId=s(),this._nextSubscriptionId=0,this._operation=Ki,this._operationExecutions=Zi,this._operationLoader=In,this._operationTracker=Ji,this._operationUpdateEpochs=new Map,this._optimisticUpdates=null,this._useExecTimeResolvers=(Si=(Ai=this._operation.request.node.operation.use_exec_time_resolvers)!==null&&Ai!==void 0?Ai:((_i=this._operation.request.node.operation.exec_time_resolvers_enabled_provider)===null||_i===void 0?void 0:_i.get())===!0)!==null&&Si!==void 0?Si:!1,this._execTimeResolverResponseComplete=!1,this._pendingModulePayloadsCount=0,this._getPublishQueue=zi,this._scheduler=on,this._sink=Ln,this._source=new Map,this._state="started",this._getStore=Gi,this._subscriptions=new Map,this._updater=Wn,this._isClientPayload=Vi===!0,this._isSubscriptionOperation=this._operation.request.node.params.operationKind==="subscription",this._shouldProcessClientComponents=jn,this._retainDisposables=new Map,this._seenActors=new Set,this._completeFns=[],this._normalizeResponse=ta,this._isClientQuery=this._operation.request.node.params.id==null&&this._operation.request.node.params.text==null;var aa=this._nextSubscriptionId++;v.PROCESS_OPTIMISTIC_UPDATE_BEFORE_SUBSCRIPTION&&Xi!=null&&this._processOptimisticResponse(Xi.response!=null?{data:Xi.response}:null,Xi.updater,!1),Hn.subscribe({complete:function(){return Mi._complete(aa)},error:function(ua){return Mi._error(ua)},next:function(ua){try{Mi._next(aa,ua)}catch(da){Ln.error(da)}},start:function(ua){var da;Mi._start(aa,ua),Mi._log({cacheConfig:(da=Mi._operation.request.cacheConfig)!==null&&da!==void 0?da:{},executeId:Mi._executeId,name:"execute.start",params:Mi._operation.request.node.params,variables:Mi._operation.request.variables})},unsubscribe:function(){Mi._log({executeId:Mi._executeId,name:"execute.unsubscribe"})}}),!v.PROCESS_OPTIMISTIC_UPDATE_BEFORE_SUBSCRIPTION&&Xi!=null&&this._processOptimisticResponse(Xi.response!=null?{data:Xi.response}:null,Xi.updater,!1)}var Ni=Ci.prototype;return Ni.cancel=function(){var Mi=this;if(this._state!=="completed"){this._state="completed",this._operationExecutions.delete(this._operation.request.identifier),this._subscriptions.size!==0&&(this._subscriptions.forEach(function(Ai){return Ai.unsubscribe()}),this._subscriptions.clear());var Si=this._optimisticUpdates;Si!==null&&(this._optimisticUpdates=null,Si.forEach(function(Ai){return Mi._getPublishQueueAndSaveActor().revertUpdate(Ai)}),this._runPublishQueue()),this._incrementalResults.clear(),this._asyncStoreUpdateDisposable!=null&&(this._asyncStoreUpdateDisposable.dispose(),this._asyncStoreUpdateDisposable=null),this._completeFns=[],this._completeOperationTracker(),this._disposeRetainedData()}},Ni._updateActiveState=function(){var Mi;switch(this._state){case"started":{Mi="active";break}case"loading_incremental":{Mi="active";break}case"completed":{Mi="inactive";break}case"loading_final":{Mi=this._pendingModulePayloadsCount>0||this._useExecTimeResolvers&&!this._execTimeResolverResponseComplete?"active":"inactive";break}default:this._state,Ui(!1)}this._operationExecutions.set(this._operation.request.identifier,Mi)},Ni._schedule=function(Mi,Si){var Ai=this,_i=this._scheduler;if(_i!=null){var Bi=this._nextSubscriptionId++;n.create(function(Pi){var zi=_i.schedule(function(){try{Mi(),Pi.complete()}catch(Gi){Pi.error(Gi)}},Si);return function(){return _i.cancel(zi)}}).subscribe({complete:function(){return Ai._complete(Bi)},error:function(zi){return Ai._error(zi)},start:function(zi){return Ai._start(Bi,zi)}})}else Mi()},Ni._complete=function(Mi){this._subscriptions.delete(Mi),this._subscriptions.size===0&&(this.cancel(),this._sink.complete(),this._log({executeId:this._executeId,name:"execute.complete"}))},Ni._error=function(Mi){this.cancel(),this._sink.error(Mi),this._log({error:Mi,executeId:this._executeId,name:"execute.error"})},Ni._start=function(Mi,Si){this._subscriptions.set(Mi,Si),this._updateActiveState()},Ni._next=function(Mi,Si){var Ai=this,_i=this._state==="loading_incremental"?"low":"default";this._schedule(function(){if(!Array.isArray(Si)&&Si.isPreNormalized===!0){Ai._handlePreNormalizedPayload(Si);return}var Bi=Si;Ai._log({executeId:Ai._executeId,name:"execute.next.start",operation:Ai._operation,response:Bi}),Ai._handleNext(Bi),Ai._maybeCompleteSubscriptionOperationTracking(),Ai._log({executeId:Ai._executeId,name:"execute.next.end",operation:Ai._operation,response:Bi})},_i)},Ni._handleErrorResponse=function(Mi){var Si=this,Ai=[];return Mi.forEach(function(_i){if(!(_i.data===null&&_i.extensions!=null&&!_i.hasOwnProperty("errors")))if(_i.data==null){var Bi=_i.hasOwnProperty("errors")&&_i.errors!=null?_i.errors:null,Pi=Bi?Bi.map(function(Vi){var Ki=Vi.message;return Ki}).join(`
127
+ `):"(No errors)",zi=h.create("RelayNetwork","No data returned for operation `"+Si._operation.request.node.params.name+"`, got error(s):\n"+Pi+"\n\nSee the error `source` property for more information.");throw zi.source={errors:Bi,operation:Si._operation.request.node,variables:Si._operation.request.variables},zi.stack,zi}else{var Gi=_i;Ai.push(Gi)}}),Ai},Ni._handleOptimisticResponses=function(Mi){var Si;if(Mi.length>1)return Mi.some(function(Bi){var Pi;return((Pi=Bi.extensions)===null||Pi===void 0?void 0:Pi.isOptimistic)===!0})&&Ui(!1),!1;var Ai=Mi[0],_i=((Si=Ai.extensions)===null||Si===void 0?void 0:Si.isOptimistic)===!0;return _i&&this._state!=="started"&&Ui(!1),_i?(this._processOptimisticResponse(Ai,null,this._treatMissingFieldsAsNull),this._sink.next(Ai),!0):!1},Ni._handlePreNormalizedPayload=function(Mi){var Si=this,Ai;if(this._state!=="completed"){this._seenActors.clear(),this._optimisticUpdates!==null&&(this._optimisticUpdates.forEach(function(Bi){return Si._getPublishQueueAndSaveActor().revertUpdate(Bi)}),this._optimisticUpdates=null),this._getPublishQueueAndSaveActor().commitPayload(this._operation,Mi,(Ai=Mi.storeUpdater)!==null&&Ai!==void 0?Ai:this._updater),Mi.isFinal?this._state="loading_final":this._state==="started"&&(this._state="loading_incremental");var _i=this._runPublishQueue(this._operation);this._updateActiveState(),this._updateOperationTracker(_i)}},Ni._handleNext=function(Mi){if(this._state!=="completed"){this._seenActors.clear();var Si=Array.isArray(Mi)?Mi:[Mi],Ai=this._handleErrorResponse(Si);if(Ai.length===0){var _i=Si.some(function(ta){var aa;return((aa=ta.extensions)===null||aa===void 0?void 0:aa.is_final)===!0});_i&&(this._useExecTimeResolvers&&this._state!=="loading_final"&&Si.some(function(ta){var aa;return((aa=ta.extensions)===null||aa===void 0?void 0:aa.is_normalized)===!0})?(this._execTimeResolverResponseComplete=!0,!this._isClientQuery&&Si.some(function(ta){var aa;return((aa=ta.extensions)===null||aa===void 0?void 0:aa.is_client_only)===!0})&&(this._isClientQuery=!0),this._isClientQuery&&(this._state="loading_final"),this._updateActiveState()):(this._state="loading_final",this._updateActiveState(),this._incrementalPayloadsPending=!1)),this._sink.next(Mi);return}var Bi=this._handleOptimisticResponses(Ai);if(!Bi){var Pi=xi(Ai),zi=Pi[0],Gi=Pi[1],Vi=Pi[2],Ki=zi.length>0,Zi=Vi.length>0;if(Ki){if(this._isSubscriptionOperation){var In=mi();this._operation={fragment:qi(this._operation.fragment.node,In,this._operation.fragment.variables,this._operation.fragment.owner),request:this._operation.request,root:Ii(this._operation.root.node,In,this._operation.root.variables)}}var Ji=this._processResponses(zi);this._processPayloadFollowups(Ji)}if(Zi)for(var Xi=[],on=0;on<Vi.length;on++){var jn,Ln,Hn=Vi[on],ea=new Oi(Hn.data),_i=((jn=Hn.extensions)===null||jn===void 0?void 0:jn.is_final)===!0;((Ln=Hn.extensions)===null||Ln===void 0?void 0:Ln.is_client_only)===!0&&(this._isClientQuery=!0);var ia={errors:[],fieldPayloads:[],followupPayloads:[],incrementalPlaceholders:[],isFinal:_i,source:ea};this._getPublishQueueAndSaveActor().commitPayload(this._operation,ia,this._updater),Xi.push(ia),this._execTimeResolverResponseComplete=_i,_i&&(this._isClientQuery&&(this._state="loading_final"),this._updateActiveState())}if(Gi.length>0){var Wn=this._processIncrementalResponses(Gi);this._processPayloadFollowups(Wn)}this._isSubscriptionOperation&&(Ai[0].extensions==null?Ai[0].extensions={__relay_subscription_root_id:this._operation.fragment.dataID}:Ai[0].extensions.__relay_subscription_root_id=this._operation.fragment.dataID);var oa=this._runPublishQueue(Ki||Zi?this._operation:void 0);Ki&&this._incrementalPayloadsPending&&this._retainData(),this._updateOperationTracker(oa),this._sink.next(Mi)}}},Ni._processOptimisticResponse=function(Mi,Si,Ai){var _i=this;if(this._optimisticUpdates!==null&&Ui(!1),!(Mi==null&&Si==null)){var Bi=[];if(Mi){var Pi=this._normalizeResponse(Mi,this._operation.root,Li,{actorIdentifier:this._actorIdentifier,deferDeduplicatedFields:!1,getDataID:this._getDataID,log:this._log,path:[],shouldProcessClientComponents:this._shouldProcessClientComponents,treatMissingFieldsAsNull:Ai},this._useExecTimeResolvers);Ei(Pi),Bi.push({operation:this._operation,payload:Pi,updater:Si}),this._processOptimisticFollowups(Pi,Bi)}else Si&&Bi.push({operation:this._operation,payload:{errors:null,fieldPayloads:null,followupPayloads:null,incrementalPlaceholders:null,isFinal:!1,source:Oi.create()},updater:Si});this._optimisticUpdates=Bi,Bi.forEach(function(Gi){return _i._getPublishQueueAndSaveActor().applyUpdate(Gi)});var zi=this._runPublishQueue();v.ENABLE_OPERATION_TRACKER_OPTIMISTIC_UPDATES&&this._updateOperationTracker(zi)}},Ni._processOptimisticFollowups=function(Mi,Si){if(Mi.followupPayloads&&Mi.followupPayloads.length){var Ai=Mi.followupPayloads,_i=(0,t.default)(Ai),Bi;try{for(_i.s();!(Bi=_i.n()).done;){var Pi=Bi.value;switch(Pi.kind){case"ModuleImportPayload":var zi=this._expectOperationLoader(),Gi=zi.get(Pi.operationReference);if(Gi==null)this._processAsyncOptimisticModuleImport(Pi);else{var Vi=this._processOptimisticModuleImport(Gi,Pi);Si.push.apply(Si,(0,i.default)(Vi))}break;case"ActorPayload":break;default:Ui(!1)}}}catch(Ki){_i.e(Ki)}finally{_i.f()}}},Ni._normalizeFollowupPayload=function(Mi,Si){var Ai;Si.kind==="SplitOperation"&&Mi.kind==="ModuleImportPayload"?Ai=bi(Mi.variables,Si.argumentDefinitions,Mi.args):Ai=Mi.variables;var _i=Ii(Si,Mi.dataID,Ai),Bi={data:Mi.data,extensions:this._state==="loading_final"?{is_final:!0}:void 0};return this._normalizeResponse(Bi,_i,Mi.typeName,{actorIdentifier:this._actorIdentifier,deferDeduplicatedFields:!1,getDataID:this._getDataID,log:this._log,path:Mi.path,shouldProcessClientComponents:this._shouldProcessClientComponents,treatMissingFieldsAsNull:this._treatMissingFieldsAsNull},this._useExecTimeResolvers)},Ni._processOptimisticModuleImport=function(Mi,Si){var Ai=a(Mi),_i=[],Bi=this._normalizeFollowupPayload(Si,Ai);return Ei(Bi),_i.push({operation:this._operation,payload:Bi,updater:null}),this._processOptimisticFollowups(Bi,_i),_i},Ni._processAsyncOptimisticModuleImport=function(Mi){var Si=this;this._expectOperationLoader().load(Mi.operationReference).then(function(Ai){if(!(Ai==null||Si._state!=="started")){var _i=Si._processOptimisticModuleImport(Ai,Mi);if(_i.forEach(function(Pi){return Si._getPublishQueueAndSaveActor().applyUpdate(Pi)}),Si._optimisticUpdates!=null){var Bi;(Bi=Si._optimisticUpdates).push.apply(Bi,(0,i.default)(_i)),Si._runPublishQueue()}}})},Ni._processResponses=function(Mi){var Si=this;return this._log({name:"execute.normalize.start",operation:this._operation}),this._optimisticUpdates!==null&&(this._optimisticUpdates.forEach(function(Ai){Si._getPublishQueueAndSaveActor().revertUpdate(Ai)}),this._optimisticUpdates=null),this._incrementalPayloadsPending=!1,this._incrementalResults.clear(),this._source.clear(),Mi.map(function(Ai){var _i=Si._normalizeResponse(Ai,Si._operation.root,Li,{actorIdentifier:Si._actorIdentifier,deferDeduplicatedFields:!1,getDataID:Si._getDataID,log:Si._log,path:[],shouldProcessClientComponents:Si._shouldProcessClientComponents,treatMissingFieldsAsNull:Si._treatMissingFieldsAsNull},Si._useExecTimeResolvers);return Si._getPublishQueueAndSaveActor().commitPayload(Si._operation,_i,Si._updater),Si._log({name:"execute.normalize.end",operation:Si._operation}),_i})},Ni._processPayloadFollowups=function(Mi){var Si=this;this._state!=="completed"&&Mi.forEach(function(Ai){var _i=Ai.incrementalPlaceholders,Bi=Ai.followupPayloads,Pi=Ai.isFinal;if(Si._state=Pi?"loading_final":"loading_incremental",Si._updateActiveState(),Pi&&(Si._incrementalPayloadsPending=!1),Bi&&Bi.length!==0&&Bi.forEach(function(Gi){var Vi,Ki=Si._actorIdentifier;Si._actorIdentifier=(Vi=Gi.actorIdentifier)!==null&&Vi!==void 0?Vi:Si._actorIdentifier,Si._processFollowupPayload(Gi),Si._actorIdentifier=Ki}),_i&&_i.length!==0&&(Si._incrementalPayloadsPending=Si._state!=="loading_final",_i.forEach(function(Gi){var Vi,Ki=Si._actorIdentifier;Si._actorIdentifier=(Vi=Gi.actorIdentifier)!==null&&Vi!==void 0?Vi:Si._actorIdentifier,Si._processIncrementalPlaceholder(Ai,Gi),Si._actorIdentifier=Ki}),Si._isClientPayload||Si._state==="loading_final")){var zi=[];_i.forEach(function(Gi){Gi.kind==="defer"&&zi.push(Si._processDeferResponse(Gi.label,Gi.path,Gi,{data:Gi.data,extensions:{is_final:!0}}))}),zi.length>0&&Si._processPayloadFollowups(zi)}})},Ni._maybeCompleteSubscriptionOperationTracking=function(){!this._isSubscriptionOperation&&!(this._useExecTimeResolvers&&this._execTimeResolverResponseComplete&&this._state==="loading_final")||this._pendingModulePayloadsCount===0&&this._incrementalPayloadsPending===!1&&this._completeOperationTracker()},Ni._processFollowupPayload=function(Mi){var Si=this;switch(Mi.kind){case"ModuleImportPayload":var Ai=this._expectOperationLoader(),_i=Ai.get(Mi.operationReference);if(_i!=null)this._processFollowupPayloadWithNormalizationNode(Mi,a(_i));else{var Bi=this._nextSubscriptionId++;this._pendingModulePayloadsCount++;var Pi=function(){Si._pendingModulePayloadsCount--,Si._maybeCompleteSubscriptionOperationTracking()},zi=n.from(new Promise(function(Gi,Vi){Ai.load(Mi.operationReference).then(Gi,Vi)}));n.create(function(Gi){var Vi,Ki=zi.subscribe({error:Gi.error,next:function(In){if(In!=null){var Ji=function(){try{var jn=a(In),Ln=v.BATCH_ASYNC_MODULE_UPDATES_FN,Hn=Ln!=null&&Si._pendingModulePayloadsCount>1,ea=l(function(){if(Si._handleFollowupPayload(Mi,jn),Hn)Si._scheduleAsyncStoreUpdate(Ln,Gi.complete);else{var oa=Si._runPublishQueue();Si._updateOperationTracker(oa)}}),ia=ea[0],Wn=ea[1];Si._log({duration:Wn,executeId:Si._executeId,name:"execute.async.module",operationName:jn.name}),Hn||Gi.complete()}catch(oa){Gi.error(oa)}},Xi=Si._scheduler;Xi==null?Ji():Vi=Xi.schedule(Ji)}else Gi.complete()}});return function(){Ki.unsubscribe(),Si._scheduler!=null&&Vi!=null&&Si._scheduler.cancel(Vi)}}).subscribe({complete:function(){Si._complete(Bi),Pi()},error:function(Vi){Si._error(Vi),Pi()},start:function(Vi){return Si._start(Bi,Vi)}})}break;case"ActorPayload":this._processFollowupPayloadWithNormalizationNode(Mi,Mi.node);break;default:Ui(!1)}},Ni._processFollowupPayloadWithNormalizationNode=function(Mi,Si){this._handleFollowupPayload(Mi,Si),this._maybeCompleteSubscriptionOperationTracking()},Ni._handleFollowupPayload=function(Mi,Si){var Ai=this._normalizeFollowupPayload(Mi,Si);this._getPublishQueueAndSaveActor().commitPayload(this._operation,Ai),this._processPayloadFollowups([Ai])},Ni._processIncrementalPlaceholder=function(Mi,Si){var Ai,_i=Si.label,Bi=Si.path,Pi=Bi.map(String).join("."),zi=this._incrementalResults.get(_i);zi==null&&(zi=new Map,this._incrementalResults.set(_i,zi));var Gi=zi.get(Pi),Vi=Gi!=null&&Gi.kind==="response"?Gi.responses:null;zi.set(Pi,{kind:"placeholder",placeholder:Si});var Ki;Si.kind==="stream"?Ki=Si.parentID:Si.kind==="defer"?Ki=Si.selector.dataID:Ui(!1);var Zi=Mi.source.get(Ki),In=((Ai=Mi.fieldPayloads)!==null&&Ai!==void 0?Ai:[]).filter(function(ea){var ia=D(ea.dataID,ea.fieldKey);return ea.dataID===Ki||ia===Ki});Zi==null&&Ui(!1);var Ji,Xi,on=this._source.get(Ki);if(on!=null){Ji=Ri.update(on.record,Zi);var jn=new Map,Ln=function(ia){var Wn=yi(ia);jn.set(Wn,ia)};on.fieldPayloads.forEach(Ln),In.forEach(Ln),Xi=Array.from(jn.values())}else Ji=Zi,Xi=In;if(this._source.set(Ki,{fieldPayloads:Xi,record:Ji}),Vi!=null){var Hn=this._processIncrementalResponses(Vi);this._processPayloadFollowups(Hn)}},Ni._processIncrementalResponses=function(Mi){var Si=this,Ai=[];return Mi.forEach(function(_i){var Bi=_i.label,Pi=_i.path,zi=_i.response,Gi=Si._incrementalResults.get(Bi);if(Gi==null&&(Gi=new Map,Si._incrementalResults.set(Bi,Gi)),Bi.indexOf("$defer$")!==-1){var Vi=Pi.map(String).join("."),Ki=Gi.get(Vi);if(Ki==null){Ki={kind:"response",responses:[_i]},Gi.set(Vi,Ki);return}else if(Ki.kind==="response"){Ki.responses.push(_i);return}var Zi=Ki.placeholder;Zi.kind!=="defer"&&Ui(!1),Ai.push(Si._processDeferResponse(Bi,Pi,Zi,zi))}else{var In=Pi.slice(0,-2).map(String).join("."),Ji=Gi.get(In);if(Ji==null){Ji={kind:"response",responses:[_i]},Gi.set(In,Ji);return}else if(Ji.kind==="response"){Ji.responses.push(_i);return}var Xi=Ji.placeholder;Xi.kind!=="stream"&&Ui(!1),Ai.push(Si._processStreamResponse(Bi,Pi,Xi,zi))}}),Ai},Ni._processDeferResponse=function(Mi,Si,Ai,_i){var Bi,Pi=Ai.selector.dataID,zi=this._actorIdentifier;this._actorIdentifier=(Bi=Ai.actorIdentifier)!==null&&Bi!==void 0?Bi:this._actorIdentifier;var Gi=this._normalizeResponse(_i,Ai.selector,Ai.typeName,{actorIdentifier:this._actorIdentifier,deferDeduplicatedFields:this._deferDeduplicatedFields,getDataID:this._getDataID,log:this._log,path:Ai.path,shouldProcessClientComponents:this._shouldProcessClientComponents,treatMissingFieldsAsNull:this._treatMissingFieldsAsNull},this._useExecTimeResolvers);this._getPublishQueueAndSaveActor().commitPayload(this._operation,Gi);var Vi=this._source.get(Pi);Vi==null&&Ui(!1);var Ki=Vi.fieldPayloads;if(Ki.length!==0){var Zi,In={errors:null,fieldPayloads:Ki,followupPayloads:null,incrementalPlaceholders:null,isFinal:((Zi=_i.extensions)===null||Zi===void 0?void 0:Zi.is_final)===!0,source:Oi.create()};this._getPublishQueueAndSaveActor().commitPayload(this._operation,In)}return this._actorIdentifier=zi,Gi},Ni._processStreamResponse=function(Mi,Si,Ai,_i){var Bi=Ai.parentID,Pi=Ai.node,zi=Ai.variables,Gi=Ai.actorIdentifier,Vi=this._actorIdentifier;this._actorIdentifier=Gi??this._actorIdentifier;var Ki=Pi.selections[0];Ki!=null&&Ki.kind==="LinkedField"&&Ki.plural===!0||Ui(!1);var Zi=this._normalizeStreamItem(_i,Bi,Ki,zi,Si,Ai.path),In=Zi.fieldPayloads,Ji=Zi.itemID,Xi=Zi.itemIndex,on=Zi.prevIDs,jn=Zi.relayPayload,Ln=Zi.storageKey;if(this._getPublishQueueAndSaveActor().commitPayload(this._operation,jn,function(ea){var ia=ea.get(Bi);if(ia!=null){var Wn=ia.getLinkedRecords(Ln);if(Wn!=null&&!(Wn.length!==on.length||Wn.some(function(ta,aa){return on[aa]!==(ta&&ta.getDataID())}))){var oa=(0,i.default)(Wn);oa[Xi]=ea.get(Ji),ia.setLinkedRecords(oa,Ln)}}}),In.length!==0){var Hn={errors:null,fieldPayloads:In,followupPayloads:null,incrementalPlaceholders:null,isFinal:!1,source:Oi.create()};this._getPublishQueueAndSaveActor().commitPayload(this._operation,Hn)}return this._actorIdentifier=Vi,jn},Ni._normalizeStreamItem=function(Mi,Si,Ai,_i,Bi,Pi){var zi,Gi,Vi,Ki,Zi=Mi.data;typeof Zi!="object"&&Ui(!1);var In=(zi=Ai.alias)!==null&&zi!==void 0?zi:Ai.name,Ji=Hi(Ai,_i),Xi=this._source.get(Si);Xi==null&&Ui(!1);var on=Xi.record,jn=Xi.fieldPayloads,Ln=Ri.getLinkedRecordIDs(on,Ji);Ln==null&&Ui(!1);var Hn=Bi[Bi.length-1],ea=parseInt(Hn,10);ea===Hn&&ea>=0||Ui(!1);var ia=(Gi=Ai.concreteType)!==null&&Gi!==void 0?Gi:Zi[ji];typeof ia!="string"&&Ui(!1);var Wn=(Vi=(Ki=this._getDataID(Zi,ia))!==null&&Ki!==void 0?Ki:Ln?.[ea])!==null&&Vi!==void 0?Vi:D(Si,Ji,ea);typeof Wn!="string"&&Ui(!1);var oa=Ii(Ai,Wn,_i),ta=Ri.clone(on),aa=(0,i.default)(Ln);aa[ea]=Wn,Ri.setLinkedRecordIDs(ta,Ji,aa),this._source.set(Si,{fieldPayloads:jn,record:ta});var sa=this._normalizeResponse(Mi,oa,ia,{actorIdentifier:this._actorIdentifier,deferDeduplicatedFields:!1,getDataID:this._getDataID,log:this._log,path:[].concat((0,i.default)(Pi),[In,String(ea)]),shouldProcessClientComponents:this._shouldProcessClientComponents,treatMissingFieldsAsNull:this._treatMissingFieldsAsNull},this._useExecTimeResolvers);return{fieldPayloads:jn,itemID:Wn,itemIndex:ea,prevIDs:Ln,relayPayload:sa,storageKey:Ji}},Ni._scheduleAsyncStoreUpdate=function(Mi,Si){var Ai=this;this._completeFns.push(Si),this._asyncStoreUpdateDisposable==null&&(this._asyncStoreUpdateDisposable=Mi(function(){Ai._asyncStoreUpdateDisposable=null;var _i=Ai._runPublishQueue();Ai._updateOperationTracker(_i);var Bi=(0,t.default)(Ai._completeFns),Pi;try{for(Bi.s();!(Pi=Bi.n()).done;){var zi=Pi.value;zi()}}catch(Gi){Bi.e(Gi)}finally{Bi.f()}Ai._completeFns=[]}))},Ni._updateOperationTracker=function(Mi){Mi!=null&&Mi.length>0&&this._operationTracker.update(this._operation.request,new Set(Mi))},Ni._completeOperationTracker=function(){this._operationTracker.complete(this._operation.request)},Ni._getPublishQueueAndSaveActor=function(){return this._seenActors.add(this._actorIdentifier),this._getPublishQueue(this._actorIdentifier)},Ni._getActorsToVisit=function(){return this._seenActors.size===0?new Set([this._actorIdentifier]):this._seenActors},Ni._runPublishQueue=function(Mi){var Si=new Set,Ai=(0,t.default)(this._getActorsToVisit()),_i;try{for(Ai.s();!(_i=Ai.n()).done;){var Bi=_i.value,Pi=this._getPublishQueue(Bi).run(Mi);Pi.forEach(function(zi){return Si.add(zi)})}}catch(zi){Ai.e(zi)}finally{Ai.f()}return Array.from(Si)},Ni._retainData=function(){var Mi=(0,t.default)(this._getActorsToVisit()),Si;try{for(Mi.s();!(Si=Mi.n()).done;){var Ai=Si.value;this._retainDisposables.has(Ai)||this._retainDisposables.set(Ai,this._getStore(Ai).retain(this._operation))}}catch(_i){Mi.e(_i)}finally{Mi.f()}},Ni._disposeRetainedData=function(){var Mi=(0,t.default)(this._retainDisposables.values()),Si;try{for(Mi.s();!(Si=Mi.n()).done;){var Ai=Si.value;Ai.dispose()}}catch(_i){Mi.e(_i)}finally{Mi.f()}this._retainDisposables.clear()},Ni._expectOperationLoader=function(){var Mi=this._operationLoader;return Mi||Ui(!1),Mi},Ci}();function xi(Ci){var Ni=[],Fi=[],Mi=[];return Ci.forEach(function(Si){var Ai;if(Si.path!=null||Si.label!=null){var _i=Si.label,Bi=Si.path;(_i==null||Bi==null)&&Ui(!1),Fi.push({label:_i,path:Bi,response:Si})}else((Ai=Si.extensions)===null||Ai===void 0?void 0:Ai.is_normalized)===!0?Mi.push(Si):Ni.push(Si)}),[Ni,Fi,Mi]}function yi(Ci){var Ni;return(Ni=JSON.stringify(u(Ci)))!==null&&Ni!==void 0?Ni:""}function Ei(Ci){var Ni=Ci.incrementalPlaceholders;Ni!=null&&Ni.length!==0&&Ui(!1)}return OperationExecutor={execute:$i},OperationExecutor}var resolveImmediate_1,hasRequiredResolveImmediate;function requireResolveImmediate(){if(hasRequiredResolveImmediate)return resolveImmediate_1;hasRequiredResolveImmediate=1;var r=Promise.resolve();function t(n){r.then(n).catch(i)}function i(n){setTimeout(function(){throw n},0)}return resolveImmediate_1=t,resolveImmediate_1}var RelayRecordSourceMutator_1,hasRequiredRelayRecordSourceMutator;function requireRelayRecordSourceMutator(){if(hasRequiredRelayRecordSourceMutator)return RelayRecordSourceMutator_1;hasRequiredRelayRecordSourceMutator=1;var r=requireRelayModernRecord(),t=requireRelayRecordState(),i=t.EXISTENT,n=requireBrowser(),s=function(){function a(v,hi){this.__sources=[hi,v],this._base=v,this._sink=hi}var h=a.prototype;return h.unstable_getRawRecordWithChanges=function(hi){var u=this._base.get(hi),l=this._sink.get(hi);if(l===void 0){if(u==null)return u;var vi=r.clone(u);return vi}else{if(l===null)return null;if(u!=null){var D=r.update(u,l);return D}else{var mi=r.clone(l);return mi}}},h._getSinkRecord=function(hi){var u=this._sink.get(hi);if(!u){var l=this._base.get(hi);l||n(!1),u=r.create(hi,r.getType(l)),this._sink.set(hi,u)}return u},h.copyFields=function(hi,u){var l=this._sink.get(hi),vi=this._base.get(hi);l||vi||n(!1);var D=this._getSinkRecord(u);vi&&r.copyFields(vi,D),l&&r.copyFields(l,D)},h.copyFieldsFromRecord=function(hi,u){var l=this._getSinkRecord(u);r.copyFields(hi,l)},h.create=function(hi,u){this._base.getStatus(hi)!==i&&this._sink.getStatus(hi)!==i||n(!1);var l=r.create(hi,u);this._sink.set(hi,l)},h.delete=function(hi){this._sink.delete(hi)},h.getStatus=function(hi){return this._sink.has(hi)?this._sink.getStatus(hi):this._base.getStatus(hi)},h.getType=function(hi){for(var u=0;u<this.__sources.length;u++){var l=this.__sources[u].get(hi);if(l)return r.getType(l);if(l===null)return null}},h.getValue=function(hi,u){for(var l=0;l<this.__sources.length;l++){var vi=this.__sources[l].get(hi);if(vi){var D=r.getValue(vi,u);if(D!==void 0)return D}else if(vi===null)return null}},h.setValue=function(hi,u,l){var vi=this._getSinkRecord(hi);r.setValue(vi,u,l)},h.getErrors=function(hi,u){for(var l=0;l<this.__sources.length;l++){var vi=this.__sources[l].get(hi);if(vi){var D=r.getErrors(vi,u);if(D!==void 0)return D}else if(vi===null)return null}},h.setErrors=function(hi,u,l){var vi=this._getSinkRecord(hi);r.setErrors(vi,u,l)},h.getLinkedRecordID=function(hi,u){for(var l=0;l<this.__sources.length;l++){var vi=this.__sources[l].get(hi);if(vi){var D=r.getLinkedRecordID(vi,u);if(D!==void 0)return D}else if(vi===null)return null}},h.setLinkedRecordID=function(hi,u,l){var vi=this._getSinkRecord(hi);r.setLinkedRecordID(vi,u,l)},h.getLinkedRecordIDs=function(hi,u){for(var l=0;l<this.__sources.length;l++){var vi=this.__sources[l].get(hi);if(vi){var D=r.getLinkedRecordIDs(vi,u);if(D!==void 0)return D}else if(vi===null)return null}},h.setLinkedRecordIDs=function(hi,u,l){var vi=this._getSinkRecord(hi);r.setLinkedRecordIDs(vi,u,l)},a}();return RelayRecordSourceMutator_1=s,RelayRecordSourceMutator_1}var createUpdatableProxy_1,hasRequiredCreateUpdatableProxy;function requireCreateUpdatableProxy(){if(hasRequiredCreateUpdatableProxy)return createUpdatableProxy_1;hasRequiredCreateUpdatableProxy=1;var r=requireInteropRequireDefault().default,t=r(requireCreateForOfIteratorHelper()),i=requireRelayStoreUtils(),n=i.getArgumentValues,s=["id","__id","__typename","js"];function a(gi,bi,Ri,Ti,Ii){var qi={};return h(qi,gi,bi,Ri,Ti,Ii),qi}function h(gi,bi,Ri,Ti,Ii,qi){var Oi,ki=(0,t.default)(Ti),Li;try{var ji=function(){var $i=Li.value;switch($i.kind){case"LinkedField":$i.plural?Object.defineProperty(gi,(Hi=$i.alias)!==null&&Hi!==void 0?Hi:$i.name,{get:u($i,Ri,bi,Ii,qi),set:v($i,Ri,bi,Ii)}):Object.defineProperty(gi,(Ui=$i.alias)!==null&&Ui!==void 0?Ui:$i.name,{get:l($i,Ri,bi,Ii,qi),set:hi($i,Ri,bi,Ii)});break;case"ScalarField":var wi=(Oi=$i.alias)!==null&&Oi!==void 0?Oi:$i.name;Object.defineProperty(gi,wi,{get:function(){var yi,Ei=n((yi=$i.args)!==null&&yi!==void 0?yi:[],Ri),Ci=bi.getValue($i.name,Ei);return Ci==null&&(Ci=mi($i,Ei,bi,Ii,qi)),Ci},set:s.includes($i.name)?void 0:function(xi){var yi,Ei=n((yi=$i.args)!==null&&yi!==void 0?yi:[],Ri);bi.setValue__UNSAFE(xi,$i.name,Ei)}});break;case"InlineFragment":bi.getType()===$i.type&&h(gi,bi,Ri,$i.selections,Ii,qi);break;case"ClientExtension":h(gi,bi,Ri,$i.selections,Ii,qi);break;case"FragmentSpread":break;case"Condition":case"ActorChange":case"InlineDataFragmentSpread":case"AliasedInlineFragmentSpread":case"ClientEdgeToClientObject":case"ClientEdgeToServerObject":case"Defer":case"ModuleImport":case"RequiredField":case"CatchField":case"Stream":case"RelayResolver":case"RelayLiveResolver":throw new Error("Encountered an unexpected ReaderSelection variant in RelayRecordSourceProxy. This indicates a bug in Relay.");default:throw $i.kind,new Error("Encountered an unexpected ReaderSelection variant in RelayRecordSourceProxy. This indicates a bug in Relay.")}};for(ki.s();!(Li=ki.n()).done;){var Hi,Ui;ji()}}catch(Qi){ki.e(Qi)}finally{ki.f()}}function v(gi,bi,Ri,Ti){return function(qi){var Oi,ki=n((Oi=gi.args)!==null&&Oi!==void 0?Oi:[],bi);if(qi==null)throw new Error("Do not assign null to plural linked fields; assign an empty array instead.");var Li=qi.map(function(ji){if(ji==null)throw new Error("When assigning an array of items, none of the items should be null or undefined.");var Hi=ji.__id;if(Hi==null)throw new Error("The __id field must be present on each item passed to the setter. This indicates a bug in Relay.");var Ui=Ti.get(Hi);if(Ui==null)throw new Error("Did not find item with data id ".concat(Hi," in the store."));return Ui});Ri.setLinkedRecords(Li,gi.name,ki)}}function hi(gi,bi,Ri,Ti){return function(qi){var Oi,ki=n((Oi=gi.args)!==null&&Oi!==void 0?Oi:[],bi);if(qi==null)Ri.setValue(qi,gi.name,ki);else{var Li=qi.__id;if(Li==null)throw new Error("The __id field must be present on the argument. This indicates a bug in Relay.");var ji=Ti.get(Li);if(ji==null)throw new Error("Did not find item with data id ".concat(Li," in the store."));Ri.setLinkedRecord(ji,gi.name,ki)}}}function u(gi,bi,Ri,Ti,Ii){return function(){var qi,Oi=n((qi=gi.args)!==null&&qi!==void 0?qi:[],bi),ki=Ri.getLinkedRecords(gi.name,Oi);return ki===void 0&&(ki=D(gi,Oi,Ri,Ti,Ii)),ki!=null?ki.map(function(Li){if(Li!=null){var ji={};return h(ji,Li,bi,gi.selections,Ti,Ii),ji}else return Li}):ki}}function l(gi,bi,Ri,Ti,Ii){return function(){var qi,Oi=n((qi=gi.args)!==null&&qi!==void 0?qi:[],bi),ki=Ri.getLinkedRecord(gi.name,Oi);if(ki===void 0&&(ki=vi(gi,Oi,Ri,Ti,Ii)),ki!=null){var Li={};return h(Li,ki,bi,gi.selections,Ti,Ii),Li}else return ki}}function vi(gi,bi,Ri,Ti,Ii){var qi=(0,t.default)(Ii),Oi;try{for(qi.s();!(Oi=qi.n()).done;){var ki=Oi.value;if(ki.kind==="linked"){var Li=ki.handle(gi,Ri,bi,Ti);if(Li!=null)return Ti.get(Li)}}}catch(ji){qi.e(ji)}finally{qi.f()}}function D(gi,bi,Ri,Ti,Ii){var qi=(0,t.default)(Ii),Oi;try{for(qi.s();!(Oi=qi.n()).done;){var ki=Oi.value;if(ki.kind==="pluralLinked"){var Li=ki.handle(gi,Ri,bi,Ti);if(Li!=null)return Li.map(function(ji){if(ji!=null)return Ti.get(ji)})}}}catch(ji){qi.e(ji)}finally{qi.f()}}function mi(gi,bi,Ri,Ti,Ii){var qi=(0,t.default)(Ii),Oi;try{for(qi.s();!(Oi=qi.n()).done;){var ki=Oi.value;if(ki.kind==="scalar"){var Li=ki.handle(gi,Ri,bi,Ti);if(Li!==void 0)return Li}}}catch(ji){qi.e(ji)}finally{qi.f()}}return createUpdatableProxy_1={createUpdatableProxy:a},createUpdatableProxy_1}var readUpdatableFragment_1,hasRequiredReadUpdatableFragment;function requireReadUpdatableFragment(){if(hasRequiredReadUpdatableFragment)return readUpdatableFragment_1;hasRequiredReadUpdatableFragment=1;var r=requireGraphQLTag(),t=r.getFragment,i=requireRelayModernSelector(),n=i.getVariablesFromFragment,s=requireRelayStoreUtils(),a=s.ID_KEY,h=requireCreateUpdatableProxy(),v=h.createUpdatableProxy,hi=requireBrowser();function u(l,vi,D,mi){var gi=t(l),bi=n(gi,vi),Ri=vi[a],Ti=D.get(Ri);return Ti==null&&hi(!1),{updatableData:v(Ti,bi,gi.selections,D,mi)}}return readUpdatableFragment_1={readUpdatableFragment:u},readUpdatableFragment_1}var readUpdatableQuery_1,hasRequiredReadUpdatableQuery;function requireReadUpdatableQuery(){if(hasRequiredReadUpdatableQuery)return readUpdatableQuery_1;hasRequiredReadUpdatableQuery=1;var r=requireGraphQLTag(),t=r.getUpdatableQuery,i=requireCreateUpdatableProxy(),n=i.createUpdatableProxy;function s(a,h,v,hi){var u=t(a);return{updatableData:n(v.getRoot(),h,u.fragment.selections,v,hi)}}return readUpdatableQuery_1={readUpdatableQuery:s},readUpdatableQuery_1}var RelayRecordProxy_1,hasRequiredRelayRecordProxy;function requireRelayRecordProxy(){if(hasRequiredRelayRecordProxy)return RelayRecordProxy_1;hasRequiredRelayRecordProxy=1;var r=requireClientID(),t=r.generateClientID,i=requireRelayStoreUtils(),n=i.getStableStorageKey,s=requireBrowser(),a=function(){function v(u,l,vi){this._dataID=vi,this._mutator=l,this._source=u}var hi=v.prototype;return hi.copyFieldsFrom=function(l){this._mutator.copyFields(l.getDataID(),this._dataID)},hi.getDataID=function(){return this._dataID},hi.getType=function(){var l=this._mutator.getType(this._dataID);return l==null&&s(!1),l},hi.getValue=function(l,vi){var D=n(l,vi);return this._mutator.getValue(this._dataID,D)},hi.setValue=function(l,vi,D,mi){return h(l)||s(!1),this.setValue__UNSAFE(l,vi,D,mi)},hi.getErrors=function(l,vi){var D=n(l,vi);return this._mutator.getErrors(this._dataID,D)},hi.setValue__UNSAFE=function(l,vi,D,mi){var gi=n(vi,D);return this._mutator.setValue(this._dataID,gi,l),mi!=null&&(mi.length===0?this._mutator.setErrors(this._dataID,gi):this._mutator.setErrors(this._dataID,gi,mi)),this},hi.getLinkedRecord=function(l,vi){var D=n(l,vi),mi=this._mutator.getLinkedRecordID(this._dataID,D);return mi!=null?this._source.get(mi):mi},hi.setLinkedRecord=function(l,vi,D){l instanceof v||s(!1);var mi=n(vi,D),gi=l.getDataID();return this._mutator.setLinkedRecordID(this._dataID,mi,gi),this},hi.getOrCreateLinkedRecord=function(l,vi,D){var mi=this.getLinkedRecord(l,D);if(!mi){var gi,bi=n(l,D),Ri=t(this.getDataID(),bi);mi=(gi=this._source.get(Ri))!==null&&gi!==void 0?gi:this._source.create(Ri,vi),this.setLinkedRecord(mi,l,D)}return mi},hi.getLinkedRecords=function(l,vi){var D=this,mi=n(l,vi),gi=this._mutator.getLinkedRecordIDs(this._dataID,mi);return gi==null?gi:gi.map(function(bi){return bi!=null?D._source.get(bi):bi})},hi.setLinkedRecords=function(l,vi,D){Array.isArray(l)||s(!1);var mi=n(vi,D),gi=l.map(function(bi){return bi&&bi.getDataID()});return this._mutator.setLinkedRecordIDs(this._dataID,mi,gi),this},hi.invalidateRecord=function(){this._source.markIDForInvalidation(this._dataID)},v}();function h(v){return v==null||typeof v!="object"||Array.isArray(v)&&v.every(h)}return RelayRecordProxy_1=a,RelayRecordProxy_1}var RelayRecordSourceProxy_1,hasRequiredRelayRecordSourceProxy;function requireRelayRecordSourceProxy(){if(hasRequiredRelayRecordSourceProxy)return RelayRecordSourceProxy_1;hasRequiredRelayRecordSourceProxy=1;var r=requireRelayModernRecord(),t=requireRelayRecordState(),i=t.EXISTENT,n=t.NONEXISTENT,s=requireRelayStoreUtils(),a=s.ROOT_ID,h=s.ROOT_TYPE,v=requireReadUpdatableFragment(),hi=v.readUpdatableFragment,u=requireReadUpdatableQuery(),l=u.readUpdatableQuery,vi=requireRelayRecordProxy(),D=requireBrowser(),mi=function(){function gi(Ri,Ti,Ii,qi,Oi){this.__mutator=Ri,this._handlerProvider=Ii||null,this._proxies={},this._getDataID=Ti,this._invalidatedStore=!1,this._idsMarkedForInvalidation=new Set,this._missingFieldHandlers=qi,this._log=Oi??function(ki){}}var bi=gi.prototype;return bi.publishSource=function(Ti,Ii){var qi=this,Oi=Ti.getRecordIDs();Oi.forEach(function(ki){var Li=Ti.getStatus(ki);if(Li===i){var ji=Ti.get(ki);ji&&(qi.__mutator.getStatus(ki)!==i&&qi.create(ki,r.getType(ji)),qi.__mutator.copyFieldsFromRecord(ji,ki))}else Li===n&&qi.delete(ki)}),Ii&&Ii.length&&Ii.forEach(function(ki){var Li=qi._handlerProvider&&qi._handlerProvider(ki.handle);Li||D(!1),Li.update(qi,ki)})},bi.create=function(Ti,Ii){this.__mutator.create(Ti,Ii),delete this._proxies[Ti];var qi=this.get(Ti);return qi||D(!1),qi},bi.delete=function(Ti){Ti===a&&D(!1),delete this._proxies[Ti],this.__mutator.delete(Ti)},bi.get=function(Ti){if(!this._proxies.hasOwnProperty(Ti)){var Ii=this.__mutator.getStatus(Ti);Ii===i?this._proxies[Ti]=new vi(this,this.__mutator,Ti):this._proxies[Ti]=Ii===n?null:void 0}return this._proxies[Ti]},bi.getRoot=function(){var Ti=this.get(a);return Ti||(Ti=this.create(a,h)),Ti&&Ti.getType()===h||D(!1),Ti},bi.invalidateStore=function(){this._invalidatedStore=!0},bi.isStoreMarkedForInvalidation=function(){return this._invalidatedStore},bi.markIDForInvalidation=function(Ti){this._idsMarkedForInvalidation.add(Ti)},bi.getIDsMarkedForInvalidation=function(){return this._idsMarkedForInvalidation},bi.readUpdatableQuery=function(Ti,Ii){return l(Ti,Ii,this,this._missingFieldHandlers)},bi.readUpdatableFragment=function(Ti,Ii){return hi(Ti,Ii,this,this._missingFieldHandlers)},gi}();return RelayRecordSourceProxy_1=mi,RelayRecordSourceProxy_1}var cloneRelayHandleSourceField_1,hasRequiredCloneRelayHandleSourceField;function requireCloneRelayHandleSourceField(){if(hasRequiredCloneRelayHandleSourceField)return cloneRelayHandleSourceField_1;hasRequiredCloneRelayHandleSourceField=1;var r=requireRelayConcreteNode(),t=r.LINKED_FIELD,i=requireRelayStoreUtils(),n=i.getHandleStorageKey,s=requireAreEqual(),a=requireBrowser();function h(v,hi,u){var l=hi.find(function(D){return D.kind===t&&D.name===v.name&&D.alias===v.alias&&s(D.args,v.args)});l&&l.kind===t||a(!1);var vi=n(v,u);return{kind:"LinkedField",alias:l.alias,name:vi,storageKey:vi,args:null,concreteType:l.concreteType,plural:l.plural,selections:l.selections}}return cloneRelayHandleSourceField_1=h,cloneRelayHandleSourceField_1}var cloneRelayScalarHandleSourceField_1,hasRequiredCloneRelayScalarHandleSourceField;function requireCloneRelayScalarHandleSourceField(){if(hasRequiredCloneRelayScalarHandleSourceField)return cloneRelayScalarHandleSourceField_1;hasRequiredCloneRelayScalarHandleSourceField=1;var r=requireRelayConcreteNode(),t=r.SCALAR_FIELD,i=requireRelayStoreUtils(),n=i.getHandleStorageKey,s=requireAreEqual(),a=requireBrowser();function h(v,hi,u){var l=hi.find(function(D){return D.kind===t&&D.name===v.name&&D.alias===v.alias&&s(D.args,v.args)});l&&l.kind===t||a(!1);var vi=n(v,u);return{kind:"ScalarField",alias:l.alias,name:vi,storageKey:vi,args:null}}return cloneRelayScalarHandleSourceField_1=h,cloneRelayScalarHandleSourceField_1}var DataChecker_1,hasRequiredDataChecker;function requireDataChecker(){if(hasRequiredDataChecker)return DataChecker_1;hasRequiredDataChecker=1;var r=requireInteropRequireDefault().default,t=r(requireCreateForOfIteratorHelper()),i=requireRelayRecordSourceMutator(),n=requireRelayRecordSourceProxy(),s=requireGetOperation(),a=requireClientID(),h=a.isClientID,v=requireCloneRelayHandleSourceField(),hi=requireCloneRelayScalarHandleSourceField(),u=requireRelayConcreteVariables(),l=u.getLocalVariables,vi=requireRelayModernRecord(),D=requireRelayRecordState(),mi=D.EXISTENT,gi=D.UNKNOWN,bi=requireRelayStoreUtils(),Ri=requireTypeID(),Ti=Ri.TYPE_SCHEMA_TYPE,Ii=Ri.generateTypeID,qi=requireBrowser(),Oi=bi.getModuleOperationKey,ki=bi.getStorageKey,Li=bi.getArgumentValues;function ji(Ui,Qi,$i,wi,xi,yi,Ei,Ci,Ni,Fi){Ni?.({name:"store.datachecker.start",selector:wi});var Mi=wi.dataID,Si=wi.node,Ai=wi.variables,_i=new Hi(Ui,Qi,$i,Ai,xi,yi,Ei,Ci,Ni,Fi),Bi=_i.check(Si,Mi);return Ni?.({name:"store.datachecker.end",selector:wi}),Bi}var Hi=function(){function Ui($i,wi,xi,yi,Ei,Ci,Ni,Fi,Mi,Si){this._getSourceForActor=$i,this._getTargetForActor=wi,this._getDataID=Ni,this._source=$i(xi),this._mutatorRecordSourceProxyCache=new Map;var Ai=this._getMutatorAndRecordProxyForActor(xi),_i=Ai[0],Bi=Ai[1];this._useExecTimeResolvers=Si??!1,this._mostRecentlyInvalidatedAt=null,this._handlers=Ei,this._mutator=_i,this._operationLoader=Ci??null,this._recordSourceProxy=Bi,this._recordWasMissing=!1,this._variables=yi,this._shouldProcessClientComponents=Fi,this._log=Mi}var Qi=Ui.prototype;return Qi._getMutatorAndRecordProxyForActor=function(wi){var xi=this._mutatorRecordSourceProxyCache.get(wi);if(xi==null){var yi=this._getTargetForActor(wi),Ei=new i(this._getSourceForActor(wi),yi),Ci=new n(Ei,this._getDataID,void 0,this._handlers,this._log);xi=[Ei,Ci],this._mutatorRecordSourceProxyCache.set(wi,xi)}return xi},Qi.check=function(wi,xi){return this._assignClientAbstractTypes(wi),this._traverse(wi,xi),this._recordWasMissing===!0?{mostRecentlyInvalidatedAt:this._mostRecentlyInvalidatedAt,status:"missing"}:{mostRecentlyInvalidatedAt:this._mostRecentlyInvalidatedAt,status:"available"}},Qi._getVariableValue=function(wi){return this._variables.hasOwnProperty(wi)||qi(!1),this._variables[wi]},Qi._handleMissing=function(){this._recordWasMissing=!0},Qi._handleMissingScalarField=function(wi,xi){if(!(wi.name==="id"&&wi.alias==null&&h(xi))){var yi=wi.args!=null?Li(wi.args,this._variables):{},Ei=(0,t.default)(this._handlers),Ci;try{for(Ei.s();!(Ci=Ei.n()).done;){var Ni=Ci.value;if(Ni.kind==="scalar"){var Fi=Ni.handle(wi,this._recordSourceProxy.get(xi),yi,this._recordSourceProxy);if(Fi!==void 0)return Fi}}}catch(Mi){Ei.e(Mi)}finally{Ei.f()}this._log!=null&&this._log({name:"store.datachecker.missing",kind:"scalar",dataID:xi,fieldName:wi.name,storageKey:ki(wi,this._variables)}),this._handleMissing()}},Qi._handleMissingLinkField=function(wi,xi){var yi=wi.args!=null?Li(wi.args,this._variables):{},Ei=(0,t.default)(this._handlers),Ci;try{for(Ei.s();!(Ci=Ei.n()).done;){var Ni=Ci.value;if(Ni.kind==="linked"){var Fi=Ni.handle(wi,this._recordSourceProxy.get(xi),yi,this._recordSourceProxy);if(Fi!==void 0&&(Fi===null||this._mutator.getStatus(Fi)===mi))return Fi}}}catch(Mi){Ei.e(Mi)}finally{Ei.f()}this._log!=null&&this._log({name:"store.datachecker.missing",kind:"linked",dataID:xi,fieldName:wi.name,storageKey:ki(wi,this._variables)}),this._handleMissing()},Qi._handleMissingPluralLinkField=function(wi,xi){var yi=this,Ei=wi.args!=null?Li(wi.args,this._variables):{},Ci=(0,t.default)(this._handlers),Ni;try{for(Ci.s();!(Ni=Ci.n()).done;){var Fi=Ni.value;if(Fi.kind==="pluralLinked"){var Mi=Fi.handle(wi,this._recordSourceProxy.get(xi),Ei,this._recordSourceProxy);if(Mi!=null){var Si=Mi.every(function(Ai){return Ai!=null&&yi._mutator.getStatus(Ai)===mi});if(Si)return Mi}else if(Mi===null)return null}}}catch(Ai){Ci.e(Ai)}finally{Ci.f()}this._log!=null&&this._log({name:"store.datachecker.missing",kind:"pluralLinked",dataID:xi,fieldName:wi.name,storageKey:ki(wi,this._variables)}),this._handleMissing()},Qi._traverse=function(wi,xi){var yi=this._mutator.getStatus(xi);if(yi===gi&&(this._log!=null&&this._log({name:"store.datachecker.missing",kind:"unknown_record",dataID:xi}),this._handleMissing()),yi===mi){var Ei=this._source.get(xi),Ci=vi.getInvalidationEpoch(Ei);Ci!=null&&(this._mostRecentlyInvalidatedAt=this._mostRecentlyInvalidatedAt!=null?Math.max(this._mostRecentlyInvalidatedAt,Ci):Ci),this._traverseSelections(wi.selections,xi)}},Qi._traverseSelections=function(wi,xi){var yi=this;wi.forEach(function(Ei){switch(Ei.kind){case"ScalarField":yi._checkScalar(Ei,xi);break;case"LinkedField":Ei.plural?yi._checkPluralLink(Ei,xi):yi._checkLink(Ei,xi);break;case"ActorChange":yi._checkActorChange(Ei.linkedField,xi);break;case"Condition":var Ci=!!yi._getVariableValue(Ei.condition);Ci===Ei.passingValue&&yi._traverseSelections(Ei.selections,xi);break;case"InlineFragment":{var Ni=Ei.abstractKey;if(Ni==null){var Fi=yi._mutator.getType(xi);Fi===Ei.type&&yi._traverseSelections(Ei.selections,xi)}else{var Mi=yi._mutator.getType(xi);Mi==null&&qi(!1);var Si=Ii(Mi),Ai=yi._mutator.getValue(Si,Ni);Ai===!0?yi._traverseSelections(Ei.selections,xi):Ai==null&&yi._handleMissing()}break}case"LinkedHandle":{var _i=v(Ei,wi,yi._variables);_i.plural?yi._checkPluralLink(_i,xi):yi._checkLink(_i,xi);break}case"ScalarHandle":{var Bi=hi(Ei,wi,yi._variables);yi._checkScalar(Bi,xi);break}case"ModuleImport":yi._checkModuleImport(Ei,xi);break;case"Defer":case"Stream":yi._traverseSelections(Ei.selections,xi);break;case"FragmentSpread":var Pi=yi._variables;yi._variables=l(yi._variables,Ei.fragment.argumentDefinitions,Ei.args),yi._traverseSelections(Ei.fragment.selections,xi),yi._variables=Pi;break;case"ClientExtension":var zi=yi._recordWasMissing;yi._traverseSelections(Ei.selections,xi),yi._recordWasMissing=zi;break;case"TypeDiscriminator":var Gi=Ei.abstractKey,Vi=yi._mutator.getType(xi);Vi==null&&qi(!1);var Ki=Ii(Vi),Zi=yi._mutator.getValue(Ki,Gi);Zi==null&&yi._handleMissing();break;case"ClientComponent":if(yi._shouldProcessClientComponents===!1)break;yi._traverseSelections(Ei.fragment.selections,xi);break;case"RelayResolver":case"RelayLiveResolver":yi._useExecTimeResolvers||yi._checkResolver(Ei,xi);break;case"ClientEdgeToClientObject":yi._useExecTimeResolvers||yi._checkResolver(Ei.backingField,xi);break;default:qi(!1)}})},Qi._checkResolver=function(wi,xi){wi.fragment&&this._traverseSelections([wi.fragment],xi)},Qi._checkModuleImport=function(wi,xi){var yi=this._operationLoader;yi===null&&qi(!1);var Ei=Oi(wi.documentName),Ci=this._mutator.getValue(xi,Ei);if(Ci==null){Ci===void 0&&this._handleMissing();return}var Ni=yi.get(Ci);if(Ni!=null){var Fi=s(Ni),Mi=this._variables;this._variables=l(this._variables,Fi.argumentDefinitions,wi.args),this._traverse(Fi,xi),this._variables=Mi}else this._handleMissing()},Qi._checkScalar=function(wi,xi){var yi=ki(wi,this._variables),Ei=this._mutator.getValue(xi,yi);Ei===void 0&&(Ei=this._handleMissingScalarField(wi,xi),Ei!==void 0&&this._mutator.setValue(xi,yi,Ei))},Qi._checkLink=function(wi,xi){var yi=ki(wi,this._variables),Ei=this._mutator.getLinkedRecordID(xi,yi);Ei===void 0&&(Ei=this._handleMissingLinkField(wi,xi),Ei!=null?this._mutator.setLinkedRecordID(xi,yi,Ei):Ei===null&&this._mutator.setValue(xi,yi,null)),Ei!=null&&this._traverse(wi,Ei)},Qi._checkPluralLink=function(wi,xi){var yi=this,Ei=ki(wi,this._variables),Ci=this._mutator.getLinkedRecordIDs(xi,Ei);Ci===void 0&&(Ci=this._handleMissingPluralLinkField(wi,xi),Ci!=null?this._mutator.setLinkedRecordIDs(xi,Ei,Ci):Ci===null&&this._mutator.setValue(xi,Ei,null)),Ci&&Ci.forEach(function(Ni){Ni!=null&&yi._traverse(wi,Ni)})},Qi._checkActorChange=function(wi,xi){var yi=ki(wi,this._variables),Ei=this._source.get(xi),Ci=Ei!=null?vi.getActorLinkedRecordID(Ei,yi):Ei;if(Ci==null)Ci===void 0&&this._handleMissing();else{var Ni=Ci[0],Fi=Ci[1],Mi=this._source,Si=this._mutator,Ai=this._recordSourceProxy,_i=this._getMutatorAndRecordProxyForActor(Ni),Bi=_i[0],Pi=_i[1];this._source=this._getSourceForActor(Ni),this._mutator=Bi,this._recordSourceProxy=Pi,this._assignClientAbstractTypes(wi),this._traverse(wi,Fi),this._source=Mi,this._mutator=Si,this._recordSourceProxy=Ai}},Qi._assignClientAbstractTypes=function(wi){var xi=wi.clientAbstractTypes;if(xi!=null)for(var yi=0,Ei=Object.keys(xi);yi<Ei.length;yi++){var Ci=Ei[yi],Ni=(0,t.default)(xi[Ci]),Fi;try{for(Ni.s();!(Fi=Ni.n()).done;){var Mi=Fi.value,Si=Ii(Mi);this._source.get(Si)==null&&this._mutator.create(Si,Ti),this._mutator.getValue(Si,Ci)==null&&this._mutator.setValue(Si,Ci,!0)}}catch(Ai){Ni.e(Ai)}finally{Ni.f()}}},Ui}();return DataChecker_1={check:ji},DataChecker_1}var shallowFreeze,hasRequiredShallowFreeze;function requireShallowFreeze(){return hasRequiredShallowFreeze||(hasRequiredShallowFreeze=1,shallowFreeze=function(t){typeof t=="object"&&t!=null&&(Array.isArray(t)||t.constructor===Object)&&Object.freeze(t)}),shallowFreeze}var getOutputTypeRecordIDs_1,hasRequiredGetOutputTypeRecordIDs;function requireGetOutputTypeRecordIDs(){if(hasRequiredGetOutputTypeRecordIDs)return getOutputTypeRecordIDs_1;hasRequiredGetOutputTypeRecordIDs=1;var r=requireRelayModernRecord(),t=requireRelayStoreUtils(),i=t.RELAY_RESOLVER_OUTPUT_TYPE_RECORD_IDS,n=requireBrowser();function s(a){var h=r.getValue(a,i);return h==null?null:(h instanceof Set||n(!1),h)}return getOutputTypeRecordIDs_1=s,getOutputTypeRecordIDs_1}var isLiveStateValue_1,hasRequiredIsLiveStateValue;function requireIsLiveStateValue(){if(hasRequiredIsLiveStateValue)return isLiveStateValue_1;hasRequiredIsLiveStateValue=1;function r(t){return t!=null&&typeof t=="object"&&typeof t.read=="function"&&typeof t.subscribe=="function"}return isLiveStateValue_1=r,isLiveStateValue_1}var LiveResolverCache_1,hasRequiredLiveResolverCache;function requireLiveResolverCache(){if(hasRequiredLiveResolverCache)return LiveResolverCache_1;hasRequiredLiveResolverCache=1;var r=requireInteropRequireDefault().default,t=r(requireCreateForOfIteratorHelper()),i=requireRecycleNodesInto(),n=requireRelayConcreteNode(),s=n.RELAY_LIVE_RESOLVER,a=requireRelayFeatureFlags(),h=requireShallowFreeze(),v=requireClientID(),hi=v.generateClientID,u=v.generateClientObjectClientID,l=requireRelayModernRecord(),vi=requireRelayModernSelector(),D=vi.createNormalizationSelector,mi=requireRelayRecordSource(),gi=requireRelayResponseNormalizer(),bi=gi.normalize,Ri=requireRelayStoreUtils(),Ti=Ri.RELAY_RESOLVER_ERROR_KEY,Ii=Ri.RELAY_RESOLVER_INVALIDATION_KEY,qi=Ri.RELAY_RESOLVER_OUTPUT_TYPE_RECORD_IDS,Oi=Ri.RELAY_RESOLVER_RECORD_TYPENAME,ki=Ri.RELAY_RESOLVER_SNAPSHOT_KEY,Li=Ri.RELAY_RESOLVER_VALUE_KEY,ji=Ri.getReadTimeResolverStorageKey,Hi=Ri.getStorageKey,Ui=requireGetOutputTypeRecordIDs(),Qi=requireIsLiveStateValue(),$i=requireLiveResolverSuspenseSentinel(),wi=$i.isSuspenseSentinel,xi=requireBrowser();requireWarning();var yi="__resolverLiveStateSubscription",Ei="__resolverLiveStateValue",Ci="__resolverLiveStateDirty",Ni="__relay_model_instance";function Fi(In,Ji,Xi){var on=In.get(Ji);on||(on=new Set,In.set(Ji,on)),on.add(Xi)}var Mi=function(){function In(Xi,on){this._resolverIDToRecordIDs=new Map,this._recordIDToResolverIDs=new Map,this._getRecordSource=Xi,this._store=on,this._handlingBatch=!1,this._liveResolverBatchRecordSource=null}var Ji=In.prototype;return Ji.readFromCacheOrEvaluate=function(on,jn,Ln,Hn,ea){var ia=this._getRecordSource(),Wn=Vi(ia,on),oa=ji(jn,Ln),ta=l.getLinkedRecordID(Wn,oa),aa=ta==null?null:ia.get(ta),sa;if(aa==null||this._isInvalid(aa,ea)){var ua;aa!=null&&Gi(aa),ta=(ua=ta)!==null&&ua!==void 0?ua:hi(on,oa),aa=l.create(ta,Oi);var da=Hn();if(l.setValue(aa,ki,da.snapshot),l.setValue(aa,Ti,da.error),jn.kind===s){if(da.resolverResult!=null){da.error!=null&&xi(!1);var ca=da.resolverResult;sa=this._setLiveStateValue(aa,ta,ca,jn,Ln)}}else sa=this._setResolverValue(aa,da.resolverResult,jn,Ln);ia.set(ta,aa);var la=Vi(ia,on),Fa=l.clone(la);if(l.setLinkedRecordID(Fa,oa,ta),ia.set(on,Fa),jn.fragment!=null){var xa,ha=Hi(jn.fragment,Ln),Ca=hi(on,ha);Fi(this._resolverIDToRecordIDs,Ca,ta),Fi(this._recordIDToResolverIDs,on,Ca);var Ra=(xa=da.snapshot)===null||xa===void 0?void 0:xa.seenRecords;if(Ra!=null){var pa=(0,t.default)(Ra),Ma;try{for(pa.s();!(Ma=pa.n()).done;){var wa=Ma.value;Fi(this._recordIDToResolverIDs,wa,Ca)}}catch(Ba){pa.e(Ba)}finally{pa.f()}}}}else if(jn.kind===s&&l.getValue(aa,Ci)){var ya;ta=(ya=ta)!==null&&ya!==void 0?ya:hi(on,oa),aa=l.clone(aa);var La=l.getValue(aa,Ei);Qi(La)||xi(!1),sa=this._setLiveResolverValue(aa,La,jn,Ln),l.setValue(aa,Ci,!1),ia.set(ta,aa)}var Sa=this._getResolverValue(aa),ga=l.getValue(aa,ki),Pa=l.getValue(aa,Ti),Ta=null;if(wi(Sa)){var va;Ta=(va=ta)!==null&&va!==void 0?va:hi(on,oa)}return[Sa,ta,Pa,ga,Ta,sa]},Ji.getLiveResolverPromise=function(on){var jn=this._getRecordSource(),Ln=jn.get(on);Ln==null&&xi(!1);var Hn=l.getValue(Ln,Ei);return new Promise(function(ea){var ia=Hn.subscribe(function(){ia(),ea()})})},Ji._setLiveStateValue=function(on,jn,Ln,Hn,ea){var ia=this._makeLiveStateHandler(jn),Wn=Ln.subscribe(ia);l.setValue(on,Ei,Ln);var oa=this._setLiveResolverValue(on,Ln,Hn,ea);return l.setValue(on,Ci,!1),l.setValue(on,yi,Wn),oa},Ji._makeLiveStateHandler=function(on){var jn=this;return function(){var Ln=jn._getRecordSource(),Hn=Ln.get(on);if(Hn&&l.hasValue(Hn,Ei)){var ea=l.clone(Hn);l.setValue(ea,Ci,!0),jn._setLiveResolverUpdate(on,ea)}}},Ji._setLiveResolverUpdate=function(on,jn){if(this._handlingBatch)this._liveResolverBatchRecordSource==null&&(this._liveResolverBatchRecordSource=mi.create()),this._liveResolverBatchRecordSource.set(on,jn);else{var Ln=mi.create();Ln.set(on,jn),this._store.publish(Ln),this._store.notify()}},Ji.batchLiveStateUpdates=function(on){this._handlingBatch&&xi(!1),this._handlingBatch=!0;try{on()}finally{this._liveResolverBatchRecordSource!=null&&(this._store.publish(this._liveResolverBatchRecordSource),this._store.notify()),this._liveResolverBatchRecordSource=null,this._handlingBatch=!1}},Ji.batchLiveStateUpdatesWithoutNotify=function(on){this._handlingBatch&&xi(!1),this._handlingBatch=!0;try{on()}finally{var jn=this._liveResolverBatchRecordSource!=null;return jn&&this._store.publish(this._liveResolverBatchRecordSource),this._liveResolverBatchRecordSource=null,this._handlingBatch=!1,jn}},Ji._setLiveResolverValue=function(on,jn,Ln,Hn){var ea=null,ia=null;try{ea=jn.read()}catch(Wn){ia=Wn}return l.setValue(on,Ti,ia),this._setResolverValue(on,ea,Ln,Hn)},Ji._setResolverValue=function(on,jn,Ln,Hn){var ea=Ln.normalizationInfo,ia=null;if(jn!=null&&ea!=null&&!wi(jn)){var Wn,oa=Ui(on),ta=new Set,aa=this._getRecordSource();if(ea.plural){Array.isArray(jn)||xi(!1),Wn=[];for(var sa=mi.create(),ua=0;ua<jn.length;ua++){var da=jn[ua];if(da!=null){typeof da!="object"&&xi(!1);var ca=Zi(ea,da),la=u(ca,l.getDataID(on),ua),Fa=this._normalizeOutputTypeValue(la,da,Hn,ea,[Ln.path,String(ua)],ca),xa=(0,t.default)(Fa.getRecordIDs()),ha;try{for(xa.s();!(ha=xa.n()).done;){var Ca=ha.value;sa.set(Ca,Vi(Fa,Ca)),ta.add(Ca)}}catch(Sa){xa.e(Sa)}finally{xa.f()}Wn.push(la)}}ia=Si(aa,sa,oa)}else{typeof jn!="object"&&xi(!1);var Ra=Zi(ea,jn),pa=u(Ra,l.getDataID(on)),Ma=this._normalizeOutputTypeValue(pa,jn,Hn,ea,[Ln.path],Ra),wa=(0,t.default)(Ma.getRecordIDs()),ya;try{for(wa.s();!(ya=wa.n()).done;){var La=ya.value;ta.add(La)}}catch(Sa){wa.e(Sa)}finally{wa.f()}Wn=pa,ia=Si(aa,Ma,oa)}l.setValue(on,qi,ta),h(Wn),l.setValue(on,Li,Wn)}else h(jn),l.setValue(on,Li,jn),l.setValue(on,qi,new Set);return ia},Ji.notifyUpdatedSubscribers=function(on){this._store.__notifyUpdatedSubscribers(on)},Ji._getResolverValue=function(on){return l.getValue(on,Li)},Ji.invalidateDataIDs=function(on){for(var jn=this._getRecordSource(),Ln=new Set,Hn=Array.from(on);Hn.length;){var ea=Hn.pop();Ln.add(ea),on.add(ea);var ia=this._recordIDToResolverIDs.get(ea);if(ia!=null){var Wn=(0,t.default)(ia),oa;try{for(Wn.s();!(oa=Wn.n()).done;){var ta=oa.value;if(!Ln.has(ta)){Ln.add(ta);var aa=this._resolverIDToRecordIDs.get(ta);if(aa==null)continue;var sa=(0,t.default)(aa),ua;try{for(sa.s();!(ua=sa.n()).done;){var da=ua.value;_i(da,jn),Ln.has(da)||(Ln.add(da),Hn.push(da))}}catch(ca){sa.e(ca)}finally{sa.f()}}}}catch(ca){Wn.e(ca)}finally{Wn.f()}}}},Ji._isInvalid=function(on,jn){if(!l.getValue(on,Ii))return!1;var Ln=l.getValue(on,ki),Hn=Ln?.data,ea=Ln?.selector;if(Hn==null||ea==null)return!0;var ia=jn(ea),Wn=ia.data,oa=i(Hn,Wn);if(oa!==Hn)return!0;if(a.MARK_RESOLVER_VALUES_AS_CLEAN_AFTER_FRAGMENT_REREAD){var ta=l.clone(on);l.setValue(ta,Ii,!1);var aa=this._getRecordSource();aa.set(l.getDataID(on),ta)}return!1},Ji._normalizeOutputTypeValue=function(on,jn,Ln,Hn,ea,ia){var Wn=mi.create();switch(Hn.kind){case"OutputType":{var oa=l.create(on,ia);Wn.set(on,oa);var ta=D(Hn.normalizationNode,on,Ln),aa=!1,sa=this._store.__getNormalizationOptions(ea);return bi(Wn,ta,jn,sa,void 0,aa).source}case"WeakModel":{var ua=l.create(on,ia);return l.setValue(ua,Ni,jn),Wn.set(on,ua),Wn}default:Hn.kind,xi(!1)}},Ji.ensureClientRecord=function(on,jn){var Ln=u(jn,on),Hn=this._getRecordSource();if(!Hn.has(Ln)){var ea=l.create(Ln,jn);l.setValue(ea,"id",on),Hn.set(Ln,ea)}return Ln},Ji.unsubscribeFromLiveResolverRecords=function(on){return Pi(this._getRecordSource(),on)},Ji.invalidateResolverRecords=function(on){if(on.size!==0){var jn=(0,t.default)(on),Ln;try{for(jn.s();!(Ln=jn.n()).done;){var Hn=Ln.value,ea=this._getRecordSource().get(Hn);ea!=null&&zi(ea)&&this._getRecordSource().delete(Hn)}}catch(ia){jn.e(ia)}finally{jn.f()}}},In}();function Si(In,Ji,Xi){var on=new Set;if(Xi!=null){var jn=(0,t.default)(Xi),Ln;try{for(jn.s();!(Ln=jn.n()).done;){var Hn=Ln.value;Ji.has(Hn)||(on.add(Hn),In.remove(Hn))}}catch(sa){jn.e(sa)}finally{jn.f()}}var ea=(0,t.default)(Ji.getRecordIDs()),ia;try{for(ea.s();!(ia=ea.n()).done;){var Wn=ia.value,oa=Vi(Ji,Wn);if(In.has(Wn)){var ta=Vi(In,Wn),aa=l.update(ta,oa);aa!==ta&&(on.add(Wn),In.set(Wn,aa),Bi(ta,In))}else In.set(Wn,oa)}}catch(sa){ea.e(sa)}finally{ea.f()}return on}function Ai(In){var Ji=new Set;return l.getFields(In).forEach(function(Xi){if(l.hasLinkedRecordID(In,Xi)){var on=l.getLinkedRecordID(In,Xi);on!=null&&Ji.add(on)}else if(l.hasLinkedRecordIDs(In,Xi)){var jn;(jn=l.getLinkedRecordIDs(In,Xi))===null||jn===void 0||jn.forEach(function(Ln){Ln!=null&&Ji.add(Ln)})}}),Ji}function _i(In,Ji){var Xi=Ji.get(In);if(Xi){var on=l.clone(Xi);l.setValue(on,Ii,!0),Ji.set(In,on)}}function Bi(In,Ji){var Xi=Ai(In),on=(0,t.default)(Xi),jn;try{for(on.s();!(jn=on.n()).done;){var Ln=jn.value,Hn=Ji.get(Ln);Hn!=null&&zi(Hn)&&_i(Ln,Ji)}}catch(ea){on.e(ea)}finally{on.f()}}function Pi(In,Ji){if(Ji.size!==0){var Xi=(0,t.default)(Ji),on;try{for(Xi.s();!(on=Xi.n()).done;){var jn=on.value,Ln=In.get(jn);Ln!=null&&zi(Ln)&&Gi(Ln)}}catch(Hn){Xi.e(Hn)}finally{Xi.f()}}}function zi(In){return l.getType(In)===Oi}function Gi(In){var Ji=l.getValue(In,yi);Ji?.()}function Vi(In,Ji){var Xi=In.get(Ji);return Xi==null&&xi(!1),Xi}function Ki(In){return In}function Zi(In,Ji){var Xi,on=(Xi=In.concreteType)!==null&&Xi!==void 0?Xi:Ji.__typename;return on==null&&xi(!1),on}return LiveResolverCache_1={LiveResolverCache:Mi,RELAY_RESOLVER_LIVE_STATE_SUBSCRIPTION_KEY:yi,getUpdatedDataIDs:Ki},LiveResolverCache_1}var RelayOptimisticRecordSource_1,hasRequiredRelayOptimisticRecordSource;function requireRelayOptimisticRecordSource(){if(hasRequiredRelayOptimisticRecordSource)return RelayOptimisticRecordSource_1;hasRequiredRelayOptimisticRecordSource=1;var r=requireInteropRequireDefault().default,t=r(requireObjectSpread2()),i=requireRelayModernRecord(),n=requireRelayRecordSource(),s=requireBrowser(),a=i.fromObject(Object.freeze({__UNPUBLISH_RECORD_SENTINEL:!0})),h=function(){function u(vi){this._base=vi,this._sink=n.create()}var l=u.prototype;return l.has=function(D){if(this._sink.has(D)){var mi=this._sink.get(D);return mi!==a}else return this._base.has(D)},l.get=function(D){if(this._sink.has(D)){var mi=this._sink.get(D);return mi===a?void 0:mi}else return this._base.get(D)},l.getStatus=function(D){var mi=this.get(D);return mi===void 0?"UNKNOWN":mi===null?"NONEXISTENT":"EXISTENT"},l.clear=function(){this._base=n.create(),this._sink.clear()},l.delete=function(D){this._sink.delete(D)},l.remove=function(D){this._sink.set(D,a)},l.set=function(D,mi){this._sink.set(D,mi)},l.getRecordIDs=function(){return Object.keys(this.toJSON())},l.size=function(){return Object.keys(this.toJSON()).length},l.toJSON=function(){var D=this,mi=(0,t.default)({},this._base.toJSON());return this._sink.getRecordIDs().forEach(function(gi){var bi=D.get(gi);bi===void 0?delete mi[gi]:mi[gi]=i.toJSON(bi)}),mi},l.getOptimisticRecordIDs=function(){return new Set(this._sink.getRecordIDs())},u}();function v(u){return new h(u)}function hi(u){return u instanceof h||s(!1),u.getOptimisticRecordIDs()}return RelayOptimisticRecordSource_1={create:v,getOptimisticRecordIDs:hi},RelayOptimisticRecordSource_1}var ResolverCache,hasRequiredResolverCache;function requireResolverCache(){if(hasRequiredResolverCache)return ResolverCache;hasRequiredResolverCache=1;var r=requireRelayConcreteNode(),t=r.RELAY_LIVE_RESOLVER,i=requireBrowser(),n=function(){function s(){}var a=s.prototype;return a.readFromCacheOrEvaluate=function(v,hi,u,l,vi){hi.kind===t&&i(!1);var D=l(),mi=D.resolverResult,gi=D.snapshot,bi=D.error;return[mi,void 0,bi,gi,void 0,void 0]},a.invalidateDataIDs=function(v){},a.ensureClientRecord=function(v,hi){i(!1)},a.notifyUpdatedSubscribers=function(v){},s}();return ResolverCache={NoopResolverCache:n},ResolverCache}var RelayReader_1,hasRequiredRelayReader;function requireRelayReader(){if(hasRequiredRelayReader)return RelayReader_1;hasRequiredRelayReader=1;var r=requireInteropRequireDefault().default,t=r(requireObjectSpread2()),i=r(requireDefineProperty()),n=r(requireObjectWithoutPropertiesLoose()),s=r(requireToConsumableArray()),a=["message"],h=requireRelayFeatureFlags(),v=requireLiveResolverSuspenseSentinel(),hi=v.isSuspenseSentinel,u=requireRelayConcreteVariables(),l=requireRelayModernRecord(),vi=requireRelayStoreUtils(),D=vi.CLIENT_EDGE_TRAVERSAL_PATH,mi=vi.FIELD_GRANULAR_NOTIFICATIONS_KEY,gi=vi.FRAGMENT_OWNER_KEY,bi=vi.FRAGMENT_PROP_NAME_KEY,Ri=vi.FRAGMENTS_KEY,Ti=vi.ID_KEY,Ii=vi.MODULE_COMPONENT_KEY,qi=vi.ROOT_ID,Oi=vi.getArgumentValues,ki=vi.getFieldNotificationKey,Li=vi.getModuleComponentKey,ji=vi.getStorageKey,Hi=requireResolverCache(),Ui=Hi.NoopResolverCache,Qi=requireResolverFragments(),$i=Qi.RESOLVER_FRAGMENT_ERRORED_SENTINEL,wi=Qi.withResolverContext,xi=requireTypeID(),yi=xi.generateTypeID,Ei=requireBrowser();function Ci(Ai,_i,Bi,Pi,zi){var Gi=new Ni(Ai,_i,Bi,Pi??new Ui,zi);return Gi.read()}var Ni=function(){function Ai(Bi,Pi,zi,Gi,Vi){var Ki,Zi,In,Ji;this._clientEdgeTraversalPath=(Ki=Pi.clientEdgeTraversalPath)!==null&&Ki!==void 0&&Ki.length?(0,s.default)(Pi.clientEdgeTraversalPath):[],this._missingClientEdges=[],this._missingLiveResolverFields=[],this._isMissingData=!1,this._isWithinUnmatchedTypeRefinement=!1,this._fieldErrors=null,this._fieldGranularNotificationDataID=null,this._owner=Pi.owner,this._useExecTimeResolvers=(Zi=(In=this._owner.node.operation.use_exec_time_resolvers)!==null&&In!==void 0?In:((Ji=this._owner.node.operation.exec_time_resolvers_enabled_provider)===null||Ji===void 0?void 0:Ji.get())===!0)!==null&&Zi!==void 0?Zi:!1,this._recordSource=Bi,this._seenRecords=new Set,this._selector=Pi,this._variables=Pi.variables,this._resolverCache=Gi,this._fragmentName=Pi.node.name,this._updatedDataIDs=new Set,this._resolverContext=Vi,this._log=zi}var _i=Ai.prototype;return _i.read=function(){var Pi,zi=this._selector,Gi=zi.node,Vi=zi.dataID,Ki=zi.isWithinUnmatchedTypeRefinement,Zi=Gi.abstractKey,In=this._recordSource.get(Vi),Ji=!Ki;if(Ji&&Zi==null&&In!=null&&(this._recordMatchesTypeCondition(In,Gi.type)||(Ji=!1)),Ji&&Zi!=null&&In!=null){var Xi=this._implementsInterface(In,Zi);Xi===!1&&(Ji=!1)}this._isWithinUnmatchedTypeRefinement=!Ji;var on=this._traverse(Gi,Vi,null),jn=(Pi=this._selector.node.metadata)===null||Pi===void 0?void 0:Pi.catchTo;if(jn!=null&&(on=this._catchErrors(on,jn,null)),this._updatedDataIDs.size>0&&(this._resolverCache.notifyUpdatedSubscribers(this._updatedDataIDs),this._updatedDataIDs.clear()),h.ENABLE_READER_FRAGMENTS_LOGGING){var Ln;(Ln=this._log)===null||Ln===void 0||Ln.call(this,{name:"reader.read",selector:this._selector})}return{data:on,fieldErrors:this._fieldErrors,isMissingData:this._isMissingData&&Ji,missingClientEdges:this._missingClientEdges.length?this._missingClientEdges:null,missingLiveResolverFields:this._missingLiveResolverFields,seenRecords:this._seenRecords,selector:this._selector}},_i._maybeAddFieldErrors=function(Pi,zi){var Gi=l.getErrors(Pi,zi);if(Gi!=null){var Vi=this._fragmentName;this._fieldErrors==null&&(this._fieldErrors=[]);for(var Ki=0;Ki<Gi.length;Ki++){var Zi,In,Ji,Xi=Gi[Ki];this._fieldErrors.push({error:Xi,fieldPath:((Zi=Xi.path)!==null&&Zi!==void 0?Zi:[]).join("."),handled:!1,kind:"relay_field_payload.error",owner:Vi,shouldThrow:(In=(Ji=this._selector.node.metadata)===null||Ji===void 0?void 0:Ji.throwOnFieldError)!==null&&In!==void 0?In:!1,uiContext:void 0})}}},_i._markDataAsMissing=function(Pi){var zi,Gi;if(!this._isWithinUnmatchedTypeRefinement){this._fieldErrors==null&&(this._fieldErrors=[]);var Vi=this._fragmentName;if(this._fieldErrors.push((zi=(Gi=this._selector.node.metadata)===null||Gi===void 0?void 0:Gi.throwOnFieldError)!==null&&zi!==void 0&&zi?{fieldPath:Pi,handled:!1,kind:"missing_expected_data.throw",owner:Vi,uiContext:void 0}:{fieldPath:Pi,kind:"missing_expected_data.log",owner:Vi,uiContext:void 0}),this._isMissingData=!0,this._clientEdgeTraversalPath.length){var Ki=this._clientEdgeTraversalPath[this._clientEdgeTraversalPath.length-1];Ki!==null&&this._missingClientEdges.push({clientEdgeDestinationID:Ki.clientEdgeDestinationID,request:Ki.readerClientEdge.operation})}}},_i._traverse=function(Pi,zi,Gi){var Vi=this._recordSource.get(zi),Ki=this._fieldGranularNotificationDataID;if(Vi!=null&&l.getValue(Vi,mi)?this._fieldGranularNotificationDataID=zi:(this._seenRecords.add(zi),this._fieldGranularNotificationDataID=null),Vi==null)return Vi===void 0&&this._markDataAsMissing("<record>"),this._fieldGranularNotificationDataID=Ki,Vi;var Zi=Gi||{},In=this._traverseSelections(Pi.selections,Vi,Zi);return this._fieldGranularNotificationDataID=Ki,In?Zi:null},_i._getVariableValue=function(Pi){return this._variables.hasOwnProperty(Pi)||Ei(!1),this._variables[Pi]},_i._maybeReportUnexpectedNull=function(Pi){if(Pi.action!=="NONE"){var zi=this._fragmentName;this._fieldErrors==null&&(this._fieldErrors=[]);var Gi;if(Pi.field.linkedField!=null){var Vi;Gi=(Vi=Pi.field.linkedField.alias)!==null&&Vi!==void 0?Vi:Pi.field.linkedField.name}else{var Ki;Gi=(Ki=Pi.field.alias)!==null&&Ki!==void 0?Ki:Pi.field.name}switch(Pi.action){case"THROW":this._fieldErrors.push({fieldPath:Gi,handled:!1,kind:"missing_required_field.throw",owner:zi,uiContext:void 0});return;case"LOG":this._fieldErrors.push({fieldPath:Gi,kind:"missing_required_field.log",owner:zi,uiContext:void 0});return;default:Pi.action}}},_i._handleRequiredFieldValue=function(Pi,zi){return zi==null?(this._maybeReportUnexpectedNull(Pi),!1):!0},_i._catchErrors=function(Pi,zi,Gi){var Vi=Pi;switch(zi){case"RESULT":Vi=this._asResult(Pi);break;case"NULL":this._fieldErrors!=null&&this._fieldErrors.length>0&&(Vi=null);break}var Ki=this._fieldErrors;if(this._fieldErrors=Gi,Ki!=null){this._fieldErrors==null&&(this._fieldErrors=[]);for(var Zi=0;Zi<Ki.length;Zi++)this._fieldErrors.push(Fi(Ki[Zi]))}return Vi},_i._asResult=function(Pi){if(this._fieldErrors==null||this._fieldErrors.length===0)return{ok:!0,value:Pi};var zi=this._fieldErrors.map(function(Gi){switch(Gi.kind){case"relay_field_payload.error":var Vi=Gi.error;Vi.message;var Ki=(0,n.default)(Vi,a);return Ki;case"missing_expected_data.throw":case"missing_expected_data.log":return{path:Gi.fieldPath.split(".")};case"relay_resolver.error":return{message:"Relay: Error in resolver for field at ".concat(Gi.fieldPath," in ").concat(Gi.owner)};case"missing_required_field.throw":return{message:"Relay: Missing @required value at path '".concat(Gi.fieldPath,"' in '").concat(Gi.owner,"'.")};case"missing_required_field.log":return null;default:Gi.kind,Ei(!1)}}).filter(Boolean);return{errors:zi,ok:!1}},_i._traverseSelections=function(Pi,zi,Gi){for(var Vi=0;Vi<Pi.length;Vi++){var Ki=Pi[Vi];switch(Ki.kind){case"RequiredField":var Zi=this._readClientSideDirectiveField(Ki,zi,Gi);if(!this._handleRequiredFieldValue(Ki,Zi))return!1;break;case"CatchField":{var In,Ji,Xi,on=this._fieldErrors;this._fieldErrors=null;var jn=this._readClientSideDirectiveField(Ki,zi,Gi),Ln=(In=(Ji=Ki.field)===null||Ji===void 0?void 0:Ji.backingField)!==null&&In!==void 0?In:Ki.field,Hn=(Xi=Ln?.alias)!==null&&Xi!==void 0?Xi:Ln?.name;Hn==null&&Ei(!1),Gi[Hn]=this._catchErrors(jn,Ki.to,on);break}case"ScalarField":this._readScalar(Ki,zi,Gi);break;case"LinkedField":Ki.plural?this._readPluralLink(Ki,zi,Gi):this._readLink(Ki,zi,Gi);break;case"Condition":var ea=!!this._getVariableValue(Ki.condition);if(ea===Ki.passingValue){var ia=this._traverseSelections(Ki.selections,zi,Gi);if(!ia)return!1}break;case"InlineFragment":{var Wn=this._readInlineFragment(Ki,zi,Gi,!1);if(Wn===!1)return!1;break}case"RelayLiveResolver":case"RelayResolver":{this._useExecTimeResolvers?this._readScalar(Ki,zi,Gi):this._readResolverField(Ki,zi,Gi);break}case"FragmentSpread":this._createFragmentPointer(Ki,zi,Gi);break;case"AliasedInlineFragmentSpread":{this._readAliasedInlineFragment(Ki,zi,Gi);break}case"ModuleImport":this._readModuleImport(Ki,zi,Gi);break;case"InlineDataFragmentSpread":this._createInlineDataOrResolverFragmentPointer(Ki,zi,Gi);break;case"Defer":case"ClientExtension":{var oa=this._isMissingData,ta=this._missingClientEdges.length;this._clientEdgeTraversalPath.push(null);var aa=this._traverseSelections(Ki.selections,zi,Gi);if(this._isMissingData=oa||this._missingClientEdges.length>ta||this._missingLiveResolverFields.length>0,this._clientEdgeTraversalPath.pop(),!aa)return!1;break}case"Stream":{var sa=this._traverseSelections(Ki.selections,zi,Gi);if(!sa)return!1;break}case"ActorChange":this._readActorChange(Ki,zi,Gi);break;case"ClientEdgeToClientObject":case"ClientEdgeToServerObject":if(this._useExecTimeResolvers&&(Ki.backingField.kind==="RelayResolver"||Ki.backingField.kind==="RelayLiveResolver")){var ua=Ki.linkedField;ua.plural?this._readPluralLink(ua,zi,Gi):this._readLink(ua,zi,Gi)}else this._readClientEdge(Ki,zi,Gi);break;default:Ei(!1)}}return!0},_i._readClientSideDirectiveField=function(Pi,zi,Gi){switch(Pi.field.kind){case"ScalarField":return this._readScalar(Pi.field,zi,Gi);case"LinkedField":return Pi.field.plural?this._readPluralLink(Pi.field,zi,Gi):this._readLink(Pi.field,zi,Gi);case"RelayResolver":case"RelayLiveResolver":return this._useExecTimeResolvers?this._readScalar(Pi.field,zi,Gi):this._readResolverField(Pi.field,zi,Gi);case"ClientEdgeToClientObject":case"ClientEdgeToServerObject":if(this._useExecTimeResolvers&&(Pi.field.backingField.kind==="RelayResolver"||Pi.field.backingField.kind==="RelayLiveResolver")){var Vi=Pi.field;return Vi.linkedField.plural?this._readPluralLink(Vi.linkedField,zi,Gi):this._readLink(Vi.linkedField,zi,Gi)}else return this._readClientEdge(Pi.field,zi,Gi);case"AliasedInlineFragmentSpread":return this._readAliasedInlineFragment(Pi.field,zi,Gi);default:Pi.field.kind,Ei(!1)}},_i._readResolverField=function(Pi,zi,Gi){var Vi,Ki=l.getDataID(zi),Zi=this._fieldErrors;this._fieldErrors=null;var In=this._readResolverFieldImpl(Pi,Ki),Ji=(Vi=Pi.alias)!==null&&Vi!==void 0?Vi:Pi.name;return this._prependPreviousErrors(Zi,Ji),Gi[Ji]=In,In},_i._readResolverFieldImpl=function(Pi,zi){var Gi=this,Vi=Pi.fragment,Ki,Zi=function(Wn){return Ki!=null?{data:Ki.data,fieldErrors:Ki.fieldErrors,isMissingData:Ki.isMissingData}:(Ki=Ci(Gi._recordSource,Wn,null,Gi._resolverCache,void 0),{data:Ki.data,fieldErrors:Ki.fieldErrors,isMissingData:Ki.isMissingData})},In=function(){if(Vi!=null){var Wn={__fragmentOwner:Gi._owner,__fragments:(0,i.default)({},Vi.name,Vi.args?Oi(Vi.args,Gi._variables):{}),__id:zi};Gi._clientEdgeTraversalPath.length>0&&Gi._clientEdgeTraversalPath[Gi._clientEdgeTraversalPath.length-1]!==null&&(Wn[D]=(0,s.default)(Gi._clientEdgeTraversalPath));var oa={getDataForResolverFragment:Zi};return wi(oa,function(){var ua=Mi(Pi,Gi._variables,Wn,Gi._resolverContext),da=ua[0],ca=ua[1];return{error:ca,resolverResult:da,snapshot:Ki}})}else{var ta=Mi(Pi,Gi._variables,null,Gi._resolverContext),aa=ta[0],sa=ta[1];return{error:sa,resolverResult:aa,snapshot:void 0}}},Ji=this._resolverCache.readFromCacheOrEvaluate(zi,Pi,this._variables,In,Zi),Xi=Ji[0],on=Ji[1],jn=Ji[2],Ln=Ji[3],Hn=Ji[4],ea=Ji[5];return this._propagateResolverMetadata(Pi.path,Ln,jn,on,Hn,ea),Xi},_i._propagateResolverMetadata=function(Pi,zi,Gi,Vi,Ki,Zi){var In=this;if(zi!=null){if(zi.missingClientEdges!=null)for(var Ji=0;Ji<zi.missingClientEdges.length;Ji++){var Xi=zi.missingClientEdges[Ji];this._missingClientEdges.push(Xi)}if(zi.missingLiveResolverFields!=null){this._isMissingData=this._isMissingData||zi.missingLiveResolverFields.length>0;for(var on=0;on<zi.missingLiveResolverFields.length;on++){var jn=zi.missingLiveResolverFields[on];this._missingLiveResolverFields.push(jn)}}if(zi.fieldErrors!=null){this._fieldErrors==null&&(this._fieldErrors=[]);for(var Ln=0;Ln<zi.fieldErrors.length;Ln++){var Hn,ea=zi.fieldErrors[Ln];((Hn=this._selector.node.metadata)===null||Hn===void 0?void 0:Hn.throwOnFieldError)===!0?this._fieldErrors.push(ea):this._fieldErrors.push(Fi(ea))}}this._isMissingData=this._isMissingData||zi.isMissingData}if(Gi){var ia,Wn,oa={error:Gi,fieldPath:Pi,handled:!1,kind:"relay_resolver.error",owner:this._fragmentName,shouldThrow:(ia=(Wn=this._selector.node.metadata)===null||Wn===void 0?void 0:Wn.throwOnFieldError)!==null&&ia!==void 0?ia:!1,uiContext:void 0};this._fieldErrors==null?this._fieldErrors=[oa]:this._fieldErrors.push(oa)}Vi!=null&&this._seenRecords.add(Vi),Ki!=null&&(this._isMissingData=!0,this._missingLiveResolverFields.push(Ki)),Zi?.forEach(function(ta){In._updatedDataIDs.add(ta)})},_i._readClientEdge=function(Pi,zi,Gi){var Vi=this,Ki,Zi=Pi.backingField;Zi.kind==="ClientExtension"&&Ei(!1);var In=(Ki=Zi.alias)!==null&&Ki!==void 0?Ki:Zi.name,Ji={};this._traverseSelections([Zi],zi,Ji);var Xi=Ji[In];if(Xi==null||hi(Xi))return Gi[In]=Xi,Xi;if(Pi.linkedField.plural){Array.isArray(Xi)||Ei(!1);var on;Pi.kind!=="ClientEdgeToClientObject"&&Ei(!1),Pi.backingField.normalizationInfo==null?on=Xi.map(function(ca){var la,Fa=(la=Pi.concreteType)!==null&&la!==void 0?la:ca.__typename;typeof Fa!="string"&&Ei(!1);var xa=Si(ca,Zi.path,Vi._owner.identifier),ha=Vi._resolverCache.ensureClientRecord(xa,Fa),Ca=Pi.modelResolvers;if(Ca!=null){var Ra=Ca[Fa];Ra===void 0&&Ei(!1);var pa=Vi._readResolverFieldImpl(Ra,ha);return pa!=null?ha:null}return ha}):on=Xi.map(function(ca){return Si(ca,Zi.path,Vi._owner.identifier)}),this._clientEdgeTraversalPath.push(null);var jn=this._readLinkedIds(Pi.linkedField,on,zi,Gi);return this._clientEdgeTraversalPath.pop(),Gi[In]=jn,jn}else{var Ln,Hn=Si(Xi,Zi.path,this._owner.identifier),ea,ia=(Ln=Pi.concreteType)!==null&&Ln!==void 0?Ln:Xi.__typename,Wn;Pi.kind==="ClientEdgeToClientObject"?Pi.backingField.normalizationInfo==null?(typeof ia!="string"&&Ei(!1),ea=this._resolverCache.ensureClientRecord(Hn,ia),Wn=null):(ea=Hn,Wn=null):(ea=Hn,Wn={clientEdgeDestinationID:Hn,readerClientEdge:Pi});var oa=Pi.modelResolvers;if(oa!=null){typeof ia!="string"&&Ei(!1);var ta=oa[ia];ta===void 0&&Ei(!1);var aa=this._readResolverFieldImpl(ta,ea);if(aa==null)return Gi[In]=null,null}this._clientEdgeTraversalPath.push(Wn);var sa=Gi[In];sa==null||typeof sa=="object"||Ei(!1);var ua=this._fieldErrors;this._fieldErrors=null;var da=this._traverse(Pi.linkedField,ea,sa);return this._prependPreviousErrors(ua,In),this._clientEdgeTraversalPath.pop(),Gi[In]=da,da}},_i._readScalar=function(Pi,zi,Gi){var Vi,Ki=(Vi=Pi.alias)!==null&&Vi!==void 0?Vi:Pi.name,Zi=ji(Pi,this._variables);this._fieldGranularNotificationDataID!=null&&this._seenRecords.add(ki(this._fieldGranularNotificationDataID,Zi));var In=l.getValue(zi,Zi);return In===null||h.ENABLE_NONCOMPLIANT_ERROR_HANDLING_ON_LISTS&&Array.isArray(In)&&In.length===0?this._maybeAddFieldErrors(zi,Zi):In===void 0&&this._markDataAsMissing(Ki),Gi[Ki]=In,In},_i._readLink=function(Pi,zi,Gi){var Vi,Ki=(Vi=Pi.alias)!==null&&Vi!==void 0?Vi:Pi.name,Zi=ji(Pi,this._variables);this._fieldGranularNotificationDataID!=null&&this._seenRecords.add(ki(this._fieldGranularNotificationDataID,Zi));var In=l.getLinkedRecordID(zi,Zi);if(In==null)return Gi[Ki]=In,In===null?this._maybeAddFieldErrors(zi,Zi):In===void 0&&this._markDataAsMissing(Ki),In;var Ji=Gi[Ki];Ji==null||typeof Ji=="object"||Ei(!1);var Xi=this._fieldErrors;this._fieldErrors=null;var on=this._traverse(Pi,In,Ji);return this._prependPreviousErrors(Xi,Ki),Gi[Ki]=on,on},_i._prependPreviousErrors=function(Pi,zi){if(this._fieldErrors!=null){for(var Gi=0;Gi<this._fieldErrors.length;Gi++){var Vi=this._fieldErrors[Gi];Vi.owner===this._fragmentName&&(Vi.kind==="missing_expected_data.throw"||Vi.kind==="missing_expected_data.log"||Vi.kind==="missing_required_field.throw"||Vi.kind==="missing_required_field.log")&&(Vi.fieldPath="".concat(zi,".").concat(Vi.fieldPath))}if(Pi!=null){for(var Ki=this._fieldErrors.length-1;Ki>=0;Ki--)Pi.push(this._fieldErrors[Ki]);this._fieldErrors=Pi}}else this._fieldErrors=Pi},_i._readActorChange=function(Pi,zi,Gi){var Vi,Ki=(Vi=Pi.alias)!==null&&Vi!==void 0?Vi:Pi.name,Zi=ji(Pi,this._variables),In=l.getActorLinkedRecordID(zi,Zi);if(In==null)return Gi[Ki]=In,In===void 0?this._markDataAsMissing(Ki):In===null&&this._maybeAddFieldErrors(zi,Zi),Gi[Ki];var Ji=In[0],Xi=In[1],on={};return this._createFragmentPointer(Pi.fragmentSpread,l.fromObject({__id:Xi}),on),Gi[Ki]={__fragmentRef:on,__viewer:Ji},Gi[Ki]},_i._readPluralLink=function(Pi,zi,Gi){var Vi=ji(Pi,this._variables);this._fieldGranularNotificationDataID!=null&&this._seenRecords.add(ki(this._fieldGranularNotificationDataID,Vi));var Ki=l.getLinkedRecordIDs(zi,Vi);return(Ki===null||h.ENABLE_NONCOMPLIANT_ERROR_HANDLING_ON_LISTS&&Array.isArray(Ki)&&Ki.length===0)&&this._maybeAddFieldErrors(zi,Vi),this._readLinkedIds(Pi,Ki,zi,Gi)},_i._readLinkedIds=function(Pi,zi,Gi,Vi){var Ki=this,Zi,In=(Zi=Pi.alias)!==null&&Zi!==void 0?Zi:Pi.name;if(zi==null)return Vi[In]=zi,zi===void 0&&this._markDataAsMissing(In),zi;var Ji=Vi[In];Ji==null||Array.isArray(Ji)||Ei(!1);var Xi=this._fieldErrors;this._fieldErrors=null;var on=Ji||[];return zi.forEach(function(jn,Ln){if(jn==null){jn===void 0&&Ki._markDataAsMissing(String(Ln)),on[Ln]=jn;return}var Hn=on[Ln];Hn==null||typeof Hn=="object"||Ei(!1);var ea=Ki._fieldErrors;Ki._fieldErrors=null,on[Ln]=Ki._traverse(Pi,jn,Hn),Ki._prependPreviousErrors(ea,Ln)}),this._prependPreviousErrors(Xi,In),Vi[In]=on,on},_i._readModuleImport=function(Pi,zi,Gi){var Vi=Li(Pi.documentName),Ki=l.getValue(zi,Vi),Zi=Ki!==void 0?Ki:Pi.componentModuleProvider;if(Zi==null){Zi===void 0&&this._markDataAsMissing("<module-import>");return}this._createFragmentPointer({args:Pi.args,kind:"FragmentSpread",name:Pi.fragmentName},zi,Gi),Gi[bi]=Pi.fragmentPropName,Gi[Ii]=Zi},_i._readAliasedInlineFragment=function(Pi,zi,Gi){var Vi=this._fieldErrors;this._fieldErrors=null;var Ki=this._readInlineFragment(Pi.fragment,zi,{},!0);return this._prependPreviousErrors(Vi,Pi.name),Ki===!1&&(Ki=null),Gi[Pi.name]=Ki,Ki},_i._readInlineFragment=function(Pi,zi,Gi,Vi){if(Pi.type==null){var Ki=this._traverseSelections(Pi.selections,zi,Gi);return Ki===!1?!1:Gi}var Zi=Pi.abstractKey;if(Zi==null)if(this._recordMatchesTypeCondition(zi,Pi.type)){var Ki=this._traverseSelections(Pi.selections,zi,Gi);if(!Ki)return!1}else return null;else{var In=this._implementsInterface(zi,Zi);if(In===!1&&Vi)return null;var Ji=this._isMissingData,Xi=this._isWithinUnmatchedTypeRefinement;this._isWithinUnmatchedTypeRefinement=Xi||In===!1;var on=this._traverseSelections(Pi.selections,zi,Gi);if(this._isWithinUnmatchedTypeRefinement=Xi,In===!1)return this._isMissingData=Ji,null;if(In==null)return;if(on===!1)return!1}return Gi},_i._recordMatchesTypeCondition=function(Pi,zi){var Gi=l.getType(Pi);return Gi!=null&&Gi===zi||l.getDataID(Pi)===qi},_i._createFragmentPointer=function(Pi,zi,Gi){var Vi=Gi[Ri];Vi==null&&(Vi=Gi[Ri]={}),typeof Vi=="object"&&Vi!=null||Ei(!1),Gi[Ti]==null&&(Gi[Ti]=l.getDataID(zi));var Ki=Oi(Pi.args,this._variables,this._isWithinUnmatchedTypeRefinement);if(Vi[Pi.name]=Ki,Gi[gi]=this._owner,this._clientEdgeTraversalPath.length>0&&this._clientEdgeTraversalPath[this._clientEdgeTraversalPath.length-1]!==null&&(Gi[D]=(0,s.default)(this._clientEdgeTraversalPath)),h.ENABLE_READER_FRAGMENTS_LOGGING){var Zi;(Zi=this._log)===null||Zi===void 0||Zi.call(this,{name:"reader.fragmentSpread",fragmentName:Pi.name,data:Gi})}},_i._createInlineDataOrResolverFragmentPointer=function(Pi,zi,Gi){var Vi=Gi[Ri];Vi==null&&(Vi=Gi[Ri]={}),typeof Vi=="object"&&Vi!=null||Ei(!1),Gi[Ti]==null&&(Gi[Ti]=l.getDataID(zi));var Ki={},Zi=this._fragmentName;this._fragmentName=Pi.name;var In=this._variables,Ji=Pi.args?Oi(Pi.args,this._variables):{};this._variables=u.getFragmentVariables(Pi,this._owner.variables,Ji),this._traverseSelections(Pi.selections,zi,Ki),this._variables=In,this._fragmentName=Zi,Vi[Pi.name]=Ki},_i._implementsInterface=function(Pi,zi){var Gi=l.getType(Pi),Vi=this._recordSource.get(yi(Gi)),Ki=Vi!=null?l.getValue(Vi,zi):null;return Ki==null&&this._markDataAsMissing("<abstract-type-hint>"),Ki},Ai}();function Fi(Ai){switch(Ai.kind){case"missing_expected_data.throw":case"missing_required_field.throw":case"relay_field_payload.error":case"relay_resolver.error":return(0,t.default)((0,t.default)({},Ai),{},{handled:!0});case"missing_expected_data.log":case"missing_required_field.log":return Ai;default:Ai.kind,Ei(!1)}}function Mi(Ai,_i,Bi,Pi){var zi=typeof Ai.resolverModule=="function"?Ai.resolverModule:Ai.resolverModule.default,Gi=null,Vi=null;try{var Ki=[];Ai.fragment!=null&&Ki.push(Bi);var Zi=Ai.args?Oi(Ai.args,_i):void 0;Ki.push(Zi),Ki.push(Pi),Gi=zi.apply(null,Ki)}catch(In){Gi=null,In!==$i&&(Vi=In)}return[Gi,Vi]}function Si(Ai,_i,Bi){if(typeof Ai=="string")return Ai;if(typeof Ai=="object"&&Ai!=null&&typeof Ai.id=="string")return Ai.id;Ei(!1)}return RelayReader_1={read:Ci},RelayReader_1}var RelayReferenceMarker_1,hasRequiredRelayReferenceMarker;function requireRelayReferenceMarker(){if(hasRequiredRelayReferenceMarker)return RelayReferenceMarker_1;hasRequiredRelayReferenceMarker=1;var r=requireInteropRequireDefault().default,t=r(requireCreateForOfIteratorHelper()),i=requireGetOperation(),n=requireCloneRelayHandleSourceField(),s=requireGetOutputTypeRecordIDs(),a=requireRelayConcreteVariables(),h=a.getLocalVariables,v=requireRelayModernRecord(),hi=requireRelayStoreUtils(),u=requireTypeID(),l=u.generateTypeID,vi=requireBrowser(),D=hi.getReadTimeResolverStorageKey,mi=hi.getStorageKey,gi=hi.getModuleOperationKey;function bi(Ti,Ii,qi,Oi,ki,Li){var ji=Ii.dataID,Hi=Ii.node,Ui=Ii.variables,Qi=new Ri(Ti,Ui,qi,Oi,ki,Li);Qi.mark(Hi,ji)}var Ri=function(){function Ti(qi,Oi,ki,Li,ji,Hi){this._operationLoader=Li??null,this._operationName=null,this._useExecTimeResolvers=Hi??!1,this._recordSource=qi,this._references=ki,this._variables=Oi,this._shouldProcessClientComponents=ji}var Ii=Ti.prototype;return Ii.mark=function(Oi,ki){(Oi.kind==="Operation"||Oi.kind==="SplitOperation")&&(this._operationName=Oi.name),this._traverse(Oi,ki)},Ii._traverse=function(Oi,ki){this._references.add(ki);var Li=this._recordSource.get(ki);Li!=null&&this._traverseSelections(Oi.selections,Li)},Ii._getVariableValue=function(Oi){return this._variables.hasOwnProperty(Oi)||vi(!1),this._variables[Oi]},Ii._traverseSelections=function(Oi,ki){var Li=this;Oi.forEach(function(ji){switch(ji.kind){case"ActorChange":Li._traverseLink(ji.linkedField,ki);break;case"LinkedField":ji.plural?Li._traversePluralLink(ji,ki):Li._traverseLink(ji,ki);break;case"Condition":var Hi=!!Li._getVariableValue(ji.condition);Hi===ji.passingValue&&Li._traverseSelections(ji.selections,ki);break;case"InlineFragment":if(ji.abstractKey==null){var Ui=v.getType(ki);(Ui!=null&&Ui===ji.type||Ui===hi.ROOT_TYPE)&&Li._traverseSelections(ji.selections,ki)}else{var Qi=v.getType(ki),$i=l(Qi);Li._references.add($i),Li._traverseSelections(ji.selections,ki)}break;case"FragmentSpread":var wi=Li._variables;Li._variables=h(Li._variables,ji.fragment.argumentDefinitions,ji.args),Li._traverseSelections(ji.fragment.selections,ki),Li._variables=wi;break;case"LinkedHandle":var xi=n(ji,Oi,Li._variables);xi.plural?Li._traversePluralLink(xi,ki):Li._traverseLink(xi,ki);break;case"Defer":case"Stream":Li._traverseSelections(ji.selections,ki);break;case"ScalarField":case"ScalarHandle":break;case"TypeDiscriminator":{var yi=v.getType(ki),Ei=l(yi);Li._references.add(Ei);break}case"ModuleImport":Li._traverseModuleImport(ji,ki);break;case"ClientExtension":Li._traverseSelections(ji.selections,ki);break;case"ClientComponent":if(Li._shouldProcessClientComponents===!1)break;Li._traverseSelections(ji.fragment.selections,ki);break;case"RelayResolver":case"RelayLiveResolver":Li._traverseResolverField(ji,ki);break;case"ClientEdgeToClientObject":Li._traverseClientEdgeToClientObject(ji,ki);break;default:vi(!1)}})},Ii._traverseClientEdgeToClientObject=function(Oi,ki){if(this._useExecTimeResolvers){this._traverseLink(Oi.linkedField,ki);return}var Li=this._traverseResolverField(Oi.backingField,ki);if(Li!=null){var ji=this._recordSource.get(Li);if(ji!=null){var Hi=Oi.linkedField;if(Oi.backingField.isOutputType){var Ui=s(ji);if(Ui!=null){var Qi=(0,t.default)(Ui),$i;try{for(Qi.s();!($i=Qi.n()).done;){var wi=$i.value;this._references.add(wi),this._traverse(Hi,wi)}}catch(Mi){Qi.e(Mi)}finally{Qi.f()}}}else{var xi=Hi.concreteType;if(xi==null)return;if(Hi.plural){var yi=v.getResolverLinkedRecordIDs(ji,xi);if(yi!=null){var Ei=(0,t.default)(yi),Ci;try{for(Ei.s();!(Ci=Ei.n()).done;){var Ni=Ci.value;Ni!=null&&this._traverse(Hi,Ni)}}catch(Mi){Ei.e(Mi)}finally{Ei.f()}}}else{var Fi=v.getResolverLinkedRecordID(ji,xi);Fi!=null&&this._traverse(Hi,Fi)}}}}},Ii._traverseResolverField=function(Oi,ki){if(!this._useExecTimeResolvers){var Li=D(Oi,this._variables),ji=v.getLinkedRecordID(ki,Li);ji!=null&&this._references.add(ji);var Hi=Oi.fragment;return Hi!=null&&this._traverseSelections([Hi],ki),ji}},Ii._traverseModuleImport=function(Oi,ki){var Li=this._operationLoader;Li===null&&vi(!1);var ji=gi(Oi.documentName),Hi=v.getValue(ki,ji);if(Hi!=null){var Ui=Li.get(Hi);if(Ui!=null){var Qi=i(Ui),$i=this._variables;this._variables=h(this._variables,Qi.argumentDefinitions,Oi.args),this._traverseSelections(Qi.selections,ki),this._variables=$i}}},Ii._traverseLink=function(Oi,ki){var Li=mi(Oi,this._variables),ji=v.getLinkedRecordID(ki,Li);ji!=null&&this._traverse(Oi,ji)},Ii._traversePluralLink=function(Oi,ki){var Li=this,ji=mi(Oi,this._variables),Hi=v.getLinkedRecordIDs(ki,ji);Hi?.forEach(function(Ui){Ui!=null&&Li._traverse(Oi,Ui)})},Ti}();return RelayReferenceMarker_1={mark:bi},RelayReferenceMarker_1}var hasOverlappingIDs_1,hasRequiredHasOverlappingIDs;function requireHasOverlappingIDs(){if(hasRequiredHasOverlappingIDs)return hasOverlappingIDs_1;hasRequiredHasOverlappingIDs=1;var r=Symbol.iterator;function t(i,n){for(var s=i[r](),a=s.next();!a.done;){var h=a.value;if(n.has(h))return!0;a=s.next()}return!1}return hasOverlappingIDs_1=t,hasOverlappingIDs_1}var hasSignificantOverlappingIDs_1,hasRequiredHasSignificantOverlappingIDs;function requireHasSignificantOverlappingIDs(){if(hasRequiredHasSignificantOverlappingIDs)return hasSignificantOverlappingIDs_1;hasRequiredHasSignificantOverlappingIDs=1;var r=requireRelayStoreUtils(),t=r.ROOT_ID,i=requireViewerPattern(),n=i.VIEWER_ID,s=Symbol.iterator;function a(h,v){for(var hi=h[s](),u=hi.next();!u.done;){var l=u.value;if(v.has(l)&&l!==t&&l!==n)return!0;u=hi.next()}return!1}return hasSignificantOverlappingIDs_1=a,hasSignificantOverlappingIDs_1}var RelayStoreSubscriptions_1,hasRequiredRelayStoreSubscriptions;function requireRelayStoreSubscriptions(){if(hasRequiredRelayStoreSubscriptions)return RelayStoreSubscriptions_1;hasRequiredRelayStoreSubscriptions=1,requireDeepFreeze();var r=requireRecycleNodesInto(),t=requireRelayFeatureFlags(),i=requireHasOverlappingIDs(),n=requireHasSignificantOverlappingIDs(),s=requireRelayReader(),a=function(){function h(hi,u,l){this._subscriptions=new Set,this._staleSubscriptions=new Set,this.__log=hi,this._resolverCache=u,this._resolverContext=l}var v=h.prototype;return v.subscribe=function(u,l){var vi=this,D={backup:null,callback:l,snapshot:u,stale:!1},mi=function(){vi._subscriptions.delete(D),t.OPTIMIZE_NOTIFY&&D.stale&&vi._staleSubscriptions.delete(D)};return this._subscriptions.add(D),{dispose:mi}},v.snapshotSubscriptions=function(u){var l=this;this._subscriptions.forEach(function(vi){if(!vi.stale){vi.backup=vi.snapshot;return}var D=vi.snapshot,mi=s.read(u,D.selector,l.__log,l._resolverCache,l._resolverContext),gi=r(D.data,mi.data);mi.data=gi,vi.backup=mi})},v.restoreSubscriptions=function(){var u=this;this._subscriptions.forEach(function(l){var vi=l.backup;l.backup=null,vi?(vi.data!==l.snapshot.data&&(l.stale=!0,t.OPTIMIZE_NOTIFY&&u._staleSubscriptions.add(l)),l.snapshot={data:l.snapshot.data,fieldErrors:vi.fieldErrors,isMissingData:vi.isMissingData,missingClientEdges:vi.missingClientEdges,missingLiveResolverFields:vi.missingLiveResolverFields,seenRecords:vi.seenRecords,selector:vi.selector}):(l.stale=!0,t.OPTIMIZE_NOTIFY&&u._staleSubscriptions.add(l))})},v.updateSubscriptions=function(u,l,vi,D){var mi=this,gi=l.size!==0;this._subscriptions.forEach(function(bi){var Ri=mi._updateSubscription(u,bi,l,gi,D);Ri!=null&&vi.push(Ri)})},v.updateStaleSubscriptions=function(u,l,vi,D){var mi=this,gi=l.size!==0;this._staleSubscriptions.forEach(function(bi){var Ri=mi._updateSubscription(u,bi,l,gi,D);Ri!=null&&vi.push(Ri)})},v._updateSubscription=function(u,l,vi,D,mi){var gi=l.backup,bi=l.callback,Ri=l.snapshot,Ti=l.stale,Ii=D&&i(Ri.seenRecords,vi);if(!(!Ti&&!Ii)){var qi=Ii||!gi?s.read(u,Ri.selector,this.__log,this._resolverCache,this._resolverContext):gi,Oi=r(Ri.data,qi.data);if(qi={data:Oi,fieldErrors:qi.fieldErrors,isMissingData:qi.isMissingData,missingClientEdges:qi.missingClientEdges,missingLiveResolverFields:qi.missingLiveResolverFields,seenRecords:qi.seenRecords,selector:qi.selector},l.snapshot=qi,l.stale=!1,t.OPTIMIZE_NOTIFY&&Ti&&this._staleSubscriptions.delete(l),qi.data!==Ri.data)return this.__log&&t.ENABLE_NOTIFY_SUBSCRIPTION&&this.__log({name:"store.notify.subscription",nextSnapshot:qi,snapshot:Ri,sourceOperation:mi}),bi(qi),Ri.selector.owner;if(t.ENABLE_LOOSE_SUBSCRIPTION_ATTRIBUTION&&(Ti||n(Ri.seenRecords,vi)))return Ri.selector.owner}},v.size=function(){return this._subscriptions.size},h}();return RelayStoreSubscriptions_1=a,RelayStoreSubscriptions_1}var RelayModernStore_1,hasRequiredRelayModernStore;function requireRelayModernStore(){if(hasRequiredRelayModernStore)return RelayModernStore_1;hasRequiredRelayModernStore=1;var r=requireInteropRequireDefault().default,t=r(requireCreateForOfIteratorHelper()),i=r(requireDefineProperty()),n=requireActorIdentifier(),s=n.INTERNAL_ACTOR_IDENTIFIER_DO_NOT_USE,a=n.assertInternalActorIdentifier;requireDeepFreeze();var h=requireRelayFeatureFlags(),v=requireResolveImmediate(),hi=requireDataChecker(),u=requireDefaultGetDataID(),l=requireLiveResolverCache(),vi=l.LiveResolverCache,D=l.RELAY_RESOLVER_LIVE_STATE_SUBSCRIPTION_KEY,mi=l.getUpdatedDataIDs,gi=requireRelayModernRecord(),bi=requireRelayOptimisticRecordSource(),Ri=requireRelayReader(),Ti=requireRelayReferenceMarker(),Ii=requireRelayStoreSubscriptions(),qi=requireRelayStoreUtils(),Oi=requireRelayStoreUtils(),ki=Oi.FIELD_GRANULAR_NOTIFICATIONS_KEY,Li=Oi.ROOT_ID,ji=Oi.ROOT_TYPE,Hi=Oi.getFieldNotificationKey,Ui=requireBrowser(),Qi=10,$i=function(){function Ei(Ni,Fi){var Mi=this,Si,Ai,_i,Bi,Pi,zi,Gi,Vi,Ki;(0,i.default)(this,"_gcStep",function(){Mi._gcRun&&(Mi._gcRun.next().done?Mi._gcRun=null:Mi._gcScheduler(Mi._gcStep))}),this._currentWriteEpoch=0,this._gcHoldCounter=0,this._gcReleaseBufferSize=(Si=Fi?.gcReleaseBufferSize)!==null&&Si!==void 0?Si:Qi,this._shouldRetainWithinTTL_EXPERIMENTAL=(Ai=Fi?.shouldRetainWithinTTL_EXPERIMENTAL)!==null&&Ai!==void 0?Ai:!1,this._gcRun=null,this._gcScheduler=(_i=Fi?.gcScheduler)!==null&&_i!==void 0?_i:v,this._getDataID=(Bi=Fi?.getDataID)!==null&&Bi!==void 0?Bi:u,this._globalInvalidationEpoch=null,this._invalidationSubscriptions=new Set,this._invalidatedRecordIDs=new Set,this.__log=(Pi=Fi?.log)!==null&&Pi!==void 0?Pi:null,this._queryCacheExpirationTime=Fi?.queryCacheExpirationTime,this._operationLoader=(zi=Fi?.operationLoader)!==null&&zi!==void 0?zi:null,this._optimisticSource=null,this._recordSource=Ni,this._releaseBuffer=[],this._roots=new Map,this._shouldScheduleGC=!1,this._resolverCache=new vi(function(){return Mi._getMutableRecordSource()},this),this._resolverContext=Fi?.resolverContext,this._storeSubscriptions=new Ii(Fi?.log,this._resolverCache,this._resolverContext),this._updatedRecordIDs=new Set,this._shouldProcessClientComponents=(Gi=Fi?.shouldProcessClientComponents)!==null&&Gi!==void 0?Gi:!1,this._treatMissingFieldsAsNull=(Vi=Fi?.treatMissingFieldsAsNull)!==null&&Vi!==void 0?Vi:!1,this._deferDeduplicatedFields=(Ki=Fi?.deferDeduplicatedFields)!==null&&Ki!==void 0?Ki:!1,this._actorIdentifier=Fi?.actorIdentifier,this._batch=null,wi(this._recordSource)}var Ci=Ei.prototype;return Ci.getSource=function(){var Fi;return(Fi=this._optimisticSource)!==null&&Fi!==void 0?Fi:this._recordSource},Ci.getOperationLoader=function(){return this._operationLoader},Ci._getMutableRecordSource=function(){var Fi;return(Fi=this._optimisticSource)!==null&&Fi!==void 0?Fi:this._recordSource},Ci.getLiveResolverPromise=function(Fi){return this._resolverCache.getLiveResolverPromise(Fi)},Ci.batchLiveStateUpdates=function(Fi){this.__log!=null&&this.__log({name:"liveresolver.batch.start"});try{this._resolverCache.batchLiveStateUpdates(Fi)}finally{this.__log!=null&&this.__log({name:"liveresolver.batch.end"})}},Ci.experimental_batchUpdates=function(Fi){if(this._batch!=null)throw new Error("RelayModernStore: Cannot batch updates while already batching updates.");var Mi=this.__log;Mi?.({name:"store.batch.start"});var Si={sourceOperations:[],invalidateStore:!1};this._batch=Si;try{Fi()}finally{this._batch=null,this.notify(void 0,Si.invalidateStore);var Ai=(0,t.default)(Si.sourceOperations),_i;try{for(Ai.s();!(_i=Ai.n()).done;){var Bi=_i.value;this._recordSourceOperation(Bi)}}catch(Pi){Ai.e(Pi)}finally{Ai.f()}Mi?.({name:"store.batch.complete",sourceOperations:Si.sourceOperations,invalidateStore:Si.invalidateStore})}},Ci.batchLiveStateUpdatesWithoutNotify=function(Fi){this.__log!=null&&this.__log({name:"liveresolver.batch.start"});var Mi=!1;try{Mi=this._resolverCache.batchLiveStateUpdatesWithoutNotify(Fi)}finally{this.__log!=null&&this.__log({name:"liveresolver.batch.end"})}return Mi},Ci.check=function(Fi,Mi){var Si,Ai,_i,Bi,Pi,zi,Gi,Vi=Fi.root,Ki=this._getMutableRecordSource(),Zi=this._globalInvalidationEpoch,In=(Si=(Ai=Fi.request.node.operation.use_exec_time_resolvers)!==null&&Ai!==void 0?Ai:((_i=Fi.request.node.operation.exec_time_resolvers_enabled_provider)===null||_i===void 0?void 0:_i.get())===!0)!==null&&Si!==void 0?Si:!1,Ji=this._roots.get(Fi.request.identifier),Xi=Ji!=null?Ji.epoch:null;if(Zi!=null&&(Xi==null||Xi<=Zi))return{status:"stale"};var on=(Bi=Mi?.handlers)!==null&&Bi!==void 0?Bi:[],jn=(Pi=Mi?.getSourceForActor)!==null&&Pi!==void 0?Pi:function(ea){return a(ea),Ki},Ln=(zi=Mi?.getTargetForActor)!==null&&zi!==void 0?zi:function(ea){return a(ea),Ki},Hn=hi.check(jn,Ln,(Gi=Mi?.defaultActorIdentifier)!==null&&Gi!==void 0?Gi:s,Vi,on,this._operationLoader,this._getDataID,this._shouldProcessClientComponents,this.__log,In);return yi(Hn,Xi,Ji?.fetchTime,this._queryCacheExpirationTime)},Ci.retain=function(Fi){var Mi=this,Si=Fi.request.identifier,Ai=!1,_i=function(){if(!Ai){Ai=!0;var zi=Mi._roots.get(Si);if(zi!=null&&(zi.refCount--,zi.refCount===0)){var Gi=Mi._queryCacheExpirationTime,Vi=zi.fetchTime!=null&&Gi!=null&&zi.fetchTime<=Date.now()-Gi;if(Vi)Mi._shouldRetainWithinTTL_EXPERIMENTAL||Mi._roots.delete(Si),Mi.scheduleGC();else if(Mi._releaseBuffer.push(Si),Mi._releaseBuffer.length>Mi._gcReleaseBufferSize){var Ki=Mi._releaseBuffer.shift();Mi._shouldRetainWithinTTL_EXPERIMENTAL||Mi._roots.delete(Ki),Mi.scheduleGC()}}}},Bi=this._roots.get(Si);return Bi!=null?(Bi.refCount===0&&(this._releaseBuffer=this._releaseBuffer.filter(function(Pi){return Pi!==Si})),Bi.refCount+=1):this._roots.set(Si,{operation:Fi,refCount:1,epoch:null,fetchTime:null}),{dispose:_i}},Ci.lookup=function(Fi){var Mi=this.__log;Mi?.({name:"store.lookup.start",selector:Fi});var Si=this.getSource(),Ai=Ri.read(Si,Fi,Mi,this._resolverCache,this._resolverContext);return Mi?.({name:"store.lookup.end",selector:Fi}),Ai},Ci.notify=function(Fi,Mi){var Si=this,Ai=this._batch;if(Ai!=null)return Fi!=null&&Ai.sourceOperations.push(Fi),Mi===!0&&(Ai.invalidateStore=!0),[];var _i=this.__log;_i?.({name:"store.notify.start",sourceOperation:Fi}),h.OPTIMIZE_NOTIFY||(this._currentWriteEpoch++,Mi===!0&&(this._globalInvalidationEpoch=this._currentWriteEpoch)),(!h.OPTIMIZE_NOTIFY||this._updatedRecordIDs.size>0)&&this._resolverCache.invalidateDataIDs(this._updatedRecordIDs);var Bi=this.getSource(),Pi=[];return!h.OPTIMIZE_NOTIFY||this._updatedRecordIDs.size>0?this._storeSubscriptions.updateSubscriptions(Bi,this._updatedRecordIDs,Pi,Fi):this._storeSubscriptions.updateStaleSubscriptions(Bi,this._updatedRecordIDs,Pi,Fi),h.OPTIMIZE_NOTIFY&&(this._updatedRecordIDs.size>0||Pi.length>0||this._invalidatedRecordIDs.size>0||Mi===!0||this._globalInvalidationEpoch===this._currentWriteEpoch)&&(this._currentWriteEpoch++,Mi===!0&&(this._globalInvalidationEpoch=this._currentWriteEpoch)),(!h.OPTIMIZE_NOTIFY||this._invalidatedRecordIDs.size>0||Mi===!0)&&this._invalidationSubscriptions.forEach(function(zi){Si._updateInvalidationSubscription(zi,Mi===!0)}),Fi!=null&&this._recordSourceOperation(Fi),_i?.({name:"store.notify.complete",sourceOperation:Fi,updatedRecordIDs:this._updatedRecordIDs,invalidatedRecordIDs:this._invalidatedRecordIDs,subscriptionsSize:this._storeSubscriptions.size(),updatedOwners:Pi}),this._updatedRecordIDs.clear(),this._invalidatedRecordIDs.clear(),Pi},Ci._recordSourceOperation=function(Fi){var Mi=Fi.request.identifier,Si=this._roots.get(Mi);if(Si!=null)Si.epoch=this._currentWriteEpoch,Si.fetchTime=Date.now();else if(Fi.request.node.params.operationKind==="query"&&this._gcReleaseBufferSize>0&&this._releaseBuffer.length<this._gcReleaseBufferSize){var Ai={operation:Fi,refCount:0,epoch:this._currentWriteEpoch,fetchTime:Date.now()};this._releaseBuffer.push(Mi),this._roots.set(Mi,Ai)}},Ci.publish=function(Fi,Mi){var Si=this._getMutableRecordSource();xi(Si,Fi,this._currentWriteEpoch+1,Mi,this._updatedRecordIDs,this._invalidatedRecordIDs);var Ai=this.__log;Ai?.({name:"store.publish",source:Fi,optimistic:Si===this._optimisticSource})},Ci.subscribe=function(Fi,Mi){return this._storeSubscriptions.subscribe(Fi,Mi)},Ci.holdGC=function(){var Fi=this;this._gcRun&&(this._gcRun=null,this._shouldScheduleGC=!0),this._gcHoldCounter++;var Mi=function(){Fi._gcHoldCounter>0&&(Fi._gcHoldCounter--,Fi._gcHoldCounter===0&&Fi._shouldScheduleGC&&(Fi.scheduleGC(),Fi._shouldScheduleGC=!1))};return{dispose:Mi}},Ci.toJSON=function(){return"RelayModernStore()"},Ci.getEpoch=function(){return this._currentWriteEpoch},Ci.__getUpdatedRecordIDs=function(){return this._updatedRecordIDs},Ci.lookupInvalidationState=function(Fi){var Mi=this,Si=new Map;return Fi.forEach(function(Ai){var _i,Bi=Mi.getSource().get(Ai);Si.set(Ai,(_i=gi.getInvalidationEpoch(Bi))!==null&&_i!==void 0?_i:null)}),Si.set("global",this._globalInvalidationEpoch),{dataIDs:Fi,invalidations:Si}},Ci.checkInvalidationState=function(Fi){var Mi=this.lookupInvalidationState(Fi.dataIDs),Si=Mi.invalidations,Ai=Fi.invalidations;if(Si.get("global")!==Ai.get("global"))return!0;var _i=(0,t.default)(Fi.dataIDs),Bi;try{for(_i.s();!(Bi=_i.n()).done;){var Pi=Bi.value;if(Si.get(Pi)!==Ai.get(Pi))return!0}}catch(zi){_i.e(zi)}finally{_i.f()}return!1},Ci.subscribeToInvalidationState=function(Fi,Mi){var Si=this,Ai={callback:Mi,invalidationState:Fi},_i=function(){Si._invalidationSubscriptions.delete(Ai)};return this._invalidationSubscriptions.add(Ai),{dispose:_i}},Ci._updateInvalidationSubscription=function(Fi,Mi){var Si=this,Ai=Fi.callback,_i=Fi.invalidationState,Bi=_i.dataIDs,Pi=Mi||Bi.some(function(zi){return Si._invalidatedRecordIDs.has(zi)});Pi&&Ai()},Ci.snapshot=function(){this._optimisticSource!=null&&Ui(!1);var Fi=this.__log;Fi?.({name:"store.snapshot"}),this._storeSubscriptions.snapshotSubscriptions(this.getSource()),this._gcRun&&(this._gcRun=null,this._shouldScheduleGC=!0),this._optimisticSource=bi.create(this.getSource())},Ci.restore=function(){var Fi=this._optimisticSource;Fi||Ui(!1);var Mi=this.__log;Mi?.({name:"store.restore"});var Si=bi.getOptimisticRecordIDs(Fi);this._resolverCache.unsubscribeFromLiveResolverRecords(Si),this._optimisticSource=null,this._shouldScheduleGC&&this.scheduleGC(),this._storeSubscriptions.restoreSubscriptions(),this._resolverCache.invalidateResolverRecords(Si)},Ci.scheduleGC=function(){if(this._gcHoldCounter>0){this._shouldScheduleGC=!0;return}this._gcRun||(this._gcRun=this._collect(),this._gcScheduler(this._gcStep))},Ci.__gc=function(){if(this._optimisticSource==null)for(var Fi=this._collect();!Fi.next().done;);},Ci._collect=function*(){if(!(this._shouldRetainWithinTTL_EXPERIMENTAL&&this._queryCacheExpirationTime==null)){var Fi=this.__log;e:for(;;){Fi?.({name:"store.gc.start"});var Mi=this._currentWriteEpoch,Si=new Set,Ai=(0,t.default)(this._roots.entries()),_i;try{for(Ai.s();!(_i=Ai.n()).done;){var Bi,Pi,zi,Gi=_i.value,Vi=Gi[0],Ki=Gi[1],Zi=Ki.operation,In=Ki.refCount,Ji=Ki.fetchTime;if(this._shouldRetainWithinTTL_EXPERIMENTAL){var Xi=this._queryCacheExpirationTime;Xi==null&&Ui(!1);var on=Ji==null||Ji<=Date.now()-Xi,jn=on&&In===0&&!this._releaseBuffer.includes(Vi);if(jn)continue}var Ln=Zi.root,Hn=(Bi=(Pi=Zi.request.node.operation.use_exec_time_resolvers)!==null&&Pi!==void 0?Pi:((zi=Zi.request.node.operation.exec_time_resolvers_enabled_provider)===null||zi===void 0?void 0:zi.get())===!0)!==null&&Bi!==void 0?Bi:!1;if(Ti.mark(this._recordSource,Ln,Si,this._operationLoader,this._shouldProcessClientComponents,Hn),yield,Mi!==this._currentWriteEpoch){Fi?.({name:"store.gc.interrupted"});continue e}}}catch(aa){Ai.e(aa)}finally{Ai.f()}for(var ea=this._recordSource.getRecordIDs(),ia=0;ia<ea.length;ia++){var Wn=ea[ia];if(!Si.has(Wn)){var oa=this._recordSource.get(Wn);if(oa!=null){var ta=gi.getValue(oa,D);ta?.()}this._recordSource.remove(Wn),this._shouldRetainWithinTTL_EXPERIMENTAL&&this._roots.delete(Wn)}}Fi?.({name:"store.gc.end",references:Si});return}}},Ci.__getNormalizationOptions=function(Fi){return{path:Fi,getDataID:this._getDataID,log:this.__log,treatMissingFieldsAsNull:this._treatMissingFieldsAsNull,deferDeduplicatedFields:this._deferDeduplicatedFields,shouldProcessClientComponents:this._shouldProcessClientComponents,actorIdentifier:this._actorIdentifier}},Ci.__notifyUpdatedSubscribers=function(Fi){var Mi=mi(Fi),Si=this._updatedRecordIDs;this._updatedRecordIDs=Mi,this.notify(),this._updatedRecordIDs=Si},Ei}();function wi(Ei){if(!Ei.has(Li)){var Ci=gi.create(Li,ji);h.ENABLE_FIELD_GRANULAR_NOTIFICATIONS&&gi.setValue(Ci,ki,!0),Ei.set(Li,Ci)}}function xi(Ei,Ci,Ni,Fi,Mi,Si){Fi&&Fi.forEach(function(In){var Ji=Ei.get(In),Xi=Ci.get(In);if(Xi!==null){var on;Ji!=null?on=gi.clone(Ji):on=Xi!=null?gi.clone(Xi):null,on&&(gi.setValue(on,qi.INVALIDATED_AT_KEY,Ni),Si.add(In),Ei.set(In,on))}});for(var Ai=Ci.getRecordIDs(),_i=0;_i<Ai.length;_i++){var Bi=Ai[_i],Pi=Ci.get(Bi),zi=Ei.get(Bi);if(Pi&&zi){var Gi=gi.update(zi,Pi);if(Gi!==zi&&(Mi.add(Bi),Ei.set(Bi,Gi),gi.getValue(Gi,ki)))for(var Vi=gi.getFields(Gi),Ki=0;Ki<Vi.length;Ki++){var Zi=Vi[Ki];Zi.startsWith("__")||gi.hasFieldChanged(zi,Gi,Zi)&&Mi.add(Hi(Bi,Zi))}}else Pi===null?(Ei.delete(Bi),zi!==null&&Mi.add(Bi)):Pi&&(Ei.set(Bi,Pi),Mi.add(Bi))}}function yi(Ei,Ci,Ni,Fi){var Mi=Ei.mostRecentlyInvalidatedAt,Si=Ei.status;if(typeof Mi=="number"&&(Ci==null||Mi>Ci))return{status:"stale"};if(Si==="missing")return{status:"missing"};if(Ni!=null&&Fi!=null){var Ai=Ni<=Date.now()-Fi;if(Ai)return{status:"stale"}}return{status:"available",fetchTime:Ni??null}}return RelayModernStore_1=$i,RelayModernStore_1}var RelayRecordSourceSelectorProxy_1,hasRequiredRelayRecordSourceSelectorProxy;function requireRelayRecordSourceSelectorProxy(){if(hasRequiredRelayRecordSourceSelectorProxy)return RelayRecordSourceSelectorProxy_1;hasRequiredRelayRecordSourceSelectorProxy=1;var r=requireRelayStoreUtils(),t=r.ROOT_TYPE,i=r.getStorageKey,n=requireReadUpdatableFragment(),s=n.readUpdatableFragment,a=requireReadUpdatableQuery(),h=a.readUpdatableQuery,v=requireBrowser(),hi=function(){function u(vi,D,mi,gi){this.__mutator=vi,this.__recordSource=D,this._readSelector=mi,this._missingFieldHandlers=gi}var l=u.prototype;return l.create=function(D,mi){return this.__recordSource.create(D,mi)},l.delete=function(D){this.__recordSource.delete(D)},l.get=function(D){return this.__recordSource.get(D)},l.getRoot=function(){return this.__recordSource.getRoot()},l.getOperationRoot=function(){var D=this.__recordSource.get(this._readSelector.dataID);return D||(D=this.__recordSource.create(this._readSelector.dataID,t)),D},l._getRootField=function(D,mi,gi){var bi=D.node.selections.find(function(Ri){return Ri.kind==="LinkedField"&&Ri.name===mi||Ri.kind==="RequiredField"&&Ri.field.name===mi});return bi&&bi.kind==="RequiredField"&&(bi=bi.field),bi&&bi.kind==="LinkedField"||v(!1),bi.plural!==gi&&v(!1),bi},l.getRootField=function(D){var mi=this._getRootField(this._readSelector,D,!1),gi=i(mi,this._readSelector.variables);return this.getOperationRoot().getLinkedRecord(gi)},l.getPluralRootField=function(D){var mi=this._getRootField(this._readSelector,D,!0),gi=i(mi,this._readSelector.variables);return this.getOperationRoot().getLinkedRecords(gi)},l.invalidateStore=function(){this.__recordSource.invalidateStore()},l.readUpdatableQuery=function(D,mi){return h(D,mi,this,this._missingFieldHandlers)},l.readUpdatableFragment=function(D,mi){return s(D,mi,this,this._missingFieldHandlers)},u}();return RelayRecordSourceSelectorProxy_1=hi,RelayRecordSourceSelectorProxy_1}var RelayPublishQueue_1,hasRequiredRelayPublishQueue;function requireRelayPublishQueue(){if(hasRequiredRelayPublishQueue)return RelayPublishQueue_1;hasRequiredRelayPublishQueue=1;var r,t,i=requireRelayRecordSourceMutator(),n=requireRelayRecordSourceProxy(),s=requireRelayRecordSourceSelectorProxy(),a=requireRelayFeatureFlags(),h=requireRelayReader(),v=requireRelayRecordSource(),hi=requireBrowser();requireWarning();var u=typeof commonjsGlobal<"u"?commonjsGlobal:typeof window<"u"?window:void 0,l=(r=u==null||(t=u.ErrorUtils)===null||t===void 0?void 0:t.applyWithGuard)!==null&&r!==void 0?r:function(mi,gi,bi,Ri,Ti){return mi.apply(gi,bi)},vi=function(){function mi(bi,Ri,Ti,Ii,qi){this._hasStoreSnapshot=!1,this._handlerProvider=Ri||null,this._pendingBackupRebase=!1,this._pendingData=new Set,this._pendingOptimisticUpdates=new Set,this._store=bi,this._appliedOptimisticUpdates=new Set,this._gcHold=null,this._getDataID=Ti,this._missingFieldHandlers=Ii,this._log=qi}var gi=mi.prototype;return gi.applyUpdate=function(Ri){!this._appliedOptimisticUpdates.has(Ri)&&!this._pendingOptimisticUpdates.has(Ri)||hi(!1),this._pendingOptimisticUpdates.add(Ri)},gi.revertUpdate=function(Ri){this._pendingOptimisticUpdates.has(Ri)?this._pendingOptimisticUpdates.delete(Ri):this._appliedOptimisticUpdates.has(Ri)&&(this._pendingBackupRebase=!0,this._appliedOptimisticUpdates.delete(Ri))},gi.revertAll=function(){this._pendingBackupRebase=!0,this._pendingOptimisticUpdates.clear(),this._appliedOptimisticUpdates.clear()},gi.commitPayload=function(Ri,Ti,Ii){this._pendingBackupRebase=!0,this._pendingData.add({kind:"payload",operation:Ri,payload:Ti,updater:Ii})},gi.commitUpdate=function(Ri){this._pendingBackupRebase=!0,this._pendingData.add({kind:"updater",updater:Ri})},gi.commitSource=function(Ri){this._pendingBackupRebase=!0,this._pendingData.add({kind:"source",source:Ri})},gi.run=function(Ri){var Ti=this._appliedOptimisticUpdates===0&&!!this._gcHold,Ii=!this._pendingBackupRebase&&this._pendingOptimisticUpdates.size===0&&!Ti;if(a.DISALLOW_NESTED_UPDATES&&this._isRunning===!0&&hi(!1),this._isRunning=!0,Ii)return this._isRunning=!1,[];this._pendingBackupRebase&&this._hasStoreSnapshot&&(this._store.restore(),this._hasStoreSnapshot=!1);var qi=this._commitData();return(this._pendingOptimisticUpdates.size||this._pendingBackupRebase&&this._appliedOptimisticUpdates.size)&&(this._hasStoreSnapshot||(this._store.snapshot(),this._hasStoreSnapshot=!0),this._applyUpdates()),this._pendingBackupRebase=!1,this._appliedOptimisticUpdates.size>0?this._gcHold||(this._gcHold=this._store.holdGC()):this._gcHold&&(this._gcHold.dispose(),this._gcHold=null),this._isRunning=!1,this._store.notify(Ri,qi)},gi._publishSourceFromPayload=function(Ri){var Ti=this,Ii=Ri.payload,qi=Ri.operation,Oi=Ri.updater,ki=Ii.source,Li=Ii.fieldPayloads,ji=new i(this._store.getSource(),ki),Hi=new n(ji,this._getDataID,this._handlerProvider,this._missingFieldHandlers,this._log);if(Li&&Li.length&&Li.forEach(function(xi){var yi=Ti._handlerProvider&&Ti._handlerProvider(xi.handle);yi||hi(!1),yi.update(Hi,xi)}),Oi){var Ui=qi.fragment;Ui==null&&hi(!1);var Qi=new s(ji,Hi,Ui,this._missingFieldHandlers),$i=D(ki,Ui);Oi(Qi,$i)}var wi=Hi.getIDsMarkedForInvalidation();return this._store.publish(ki,wi),Hi.isStoreMarkedForInvalidation()},gi._commitData=function(){var Ri=this;if(!this._pendingData.size)return!1;var Ti=!1;return this._pendingData.forEach(function(Ii){if(Ii.kind==="payload"){var qi=Ri._publishSourceFromPayload(Ii);Ti=Ti||qi}else if(Ii.kind==="source"){var Oi=Ii.source;Ri._store.publish(Oi)}else{var ki=Ii.updater,Li=v.create(),ji=new i(Ri._store.getSource(),Li),Hi=new n(ji,Ri._getDataID,Ri._handlerProvider,Ri._missingFieldHandlers,Ri._log);l(ki,null,[Hi],null,"RelayPublishQueue:commitData"),Ti=Ti||Hi.isStoreMarkedForInvalidation();var Ui=Hi.getIDsMarkedForInvalidation();Ri._store.publish(Li,Ui)}}),this._pendingData.clear(),Ti},gi._applyUpdates=function(){var Ri=this,Ti=v.create(),Ii=new i(this._store.getSource(),Ti),qi=new n(Ii,this._getDataID,this._handlerProvider,this._missingFieldHandlers,this._log),Oi=function(Li){if(Li.storeUpdater){var ji=Li.storeUpdater;l(ji,null,[qi],null,"RelayPublishQueue:applyUpdates")}else{var Hi=Li.operation,Ui=Li.payload,Qi=Li.updater,$i=Ui.source,wi=Ui.fieldPayloads;if($i&&qi.publishSource($i,wi),Qi){var xi;$i&&(xi=D($i,Hi.fragment));var yi=new s(Ii,qi,Hi.fragment,Ri._missingFieldHandlers);l(Qi,null,[yi,xi],null,"RelayPublishQueue:applyUpdates")}}};this._pendingBackupRebase&&this._appliedOptimisticUpdates.size&&this._appliedOptimisticUpdates.forEach(Oi),this._pendingOptimisticUpdates.size&&(this._pendingOptimisticUpdates.forEach(function(ki){Oi(ki),Ri._appliedOptimisticUpdates.add(ki)}),this._pendingOptimisticUpdates.clear()),this._store.publish(Ti)},mi}();function D(mi,gi){var bi=h.read(mi,gi,null,void 0,void 0).data;return bi}return RelayPublishQueue_1=vi,RelayPublishQueue_1}var RelayModernEnvironment_1,hasRequiredRelayModernEnvironment;function requireRelayModernEnvironment(){if(hasRequiredRelayModernEnvironment)return RelayModernEnvironment_1;hasRequiredRelayModernEnvironment=1;var r=requireInteropRequireDefault().default,t=r(requireObjectSpread2()),i=requireRelayDefaultHandlerProvider(),n=requireActorIdentifier(),s=n.INTERNAL_ACTOR_IDENTIFIER_DO_NOT_USE,a=n.assertInternalActorIdentifier,h=requireRelayObservable(),v=requireWrapNetworkWithLogObserver(),hi=requireRelayOperationTracker(),u=requireRegisterEnvironmentWithDevTools(),l=requireDefaultGetDataID(),vi=requireDefaultRelayFieldLogger(),D=requireNormalizeResponse(),mi=requireOperationExecutor(),gi=requireRelayModernStore(),bi=requireRelayPublishQueue(),Ri=requireRelayRecordSource(),Ti=requireBrowser(),Ii=function(){function ki(ji){var Hi=this,Ui,Qi,$i,wi,xi,yi,Ei,Ci,Ni,Fi,Mi;this.configName=ji.configName,this._treatMissingFieldsAsNull=ji.treatMissingFieldsAsNull===!0,this._deferDeduplicatedFields=ji.deferDeduplicatedFields===!0;var Si=ji.operationLoader,Ai=(Ui=ji.store)!==null&&Ui!==void 0?Ui:new gi(new Ri,{getDataID:ji.getDataID,log:ji.log,operationLoader:ji.operationLoader,shouldProcessClientComponents:ji.shouldProcessClientComponents});this.__log=(Qi=ji.log)!==null&&Qi!==void 0?Qi:Oi,this.relayFieldLogger=($i=ji.relayFieldLogger)!==null&&$i!==void 0?$i:vi,this._defaultRenderPolicy=(wi=ji.UNSTABLE_defaultRenderPolicy)!==null&&wi!==void 0?wi:"partial",this._operationLoader=Si,this._operationExecutions=new Map,this._network=v(this,ji.network),this._getDataID=(xi=ji.getDataID)!==null&&xi!==void 0?xi:l,this._missingFieldHandlers=(yi=ji.missingFieldHandlers)!==null&&yi!==void 0?yi:[],this._publishQueue=new bi(Ai,(Ei=ji.handlerProvider)!==null&&Ei!==void 0?Ei:i,this._getDataID,this._missingFieldHandlers,this.__log),this._scheduler=(Ci=ji.scheduler)!==null&&Ci!==void 0?Ci:null,this._store=Ai,this.options=ji.options,this._isServer=(Ni=ji.isServer)!==null&&Ni!==void 0?Ni:!1,this._normalizeResponse=(Fi=ji.normalizeResponse)!==null&&Fi!==void 0?Fi:D,this.__setNet=function(_i){return Hi._network=v(Hi,_i)},this._operationTracker=(Mi=ji.operationTracker)!==null&&Mi!==void 0?Mi:new hi,this._shouldProcessClientComponents=ji.shouldProcessClientComponents,u(this)}var Li=ki.prototype;return Li.getStore=function(){return this._store},Li.getNetwork=function(){return this._network},Li.getOperationTracker=function(){return this._operationTracker},Li.getScheduler=function(){return this._scheduler},Li.isRequestActive=function(Hi){var Ui=this._operationExecutions.get(Hi);return Ui==="active"},Li.UNSTABLE_getDefaultRenderPolicy=function(){return this._defaultRenderPolicy},Li.applyUpdate=function(Hi){var Ui=this,Qi=function(){Ui._scheduleUpdates(function(){Ui._publishQueue.revertUpdate(Hi),Ui._publishQueue.run()})};return this._scheduleUpdates(function(){Ui._publishQueue.applyUpdate(Hi),Ui._publishQueue.run()}),{dispose:Qi}},Li.revertUpdate=function(Hi){var Ui=this;this._scheduleUpdates(function(){Ui._publishQueue.revertUpdate(Hi),Ui._publishQueue.run()})},Li.replaceUpdate=function(Hi,Ui){var Qi=this;this._scheduleUpdates(function(){Qi._publishQueue.revertUpdate(Hi),Qi._publishQueue.applyUpdate(Ui),Qi._publishQueue.run()})},Li.applyMutation=function(Hi){var Ui=this._execute({createSource:function(){return h.create(function($i){})},isClientPayload:!1,operation:Hi.operation,optimisticConfig:Hi,updater:null}).subscribe({});return{dispose:function(){return Ui.unsubscribe()}}},Li.check=function(Hi){return this._missingFieldHandlers.length===0&&!qi(Hi)?this._store.check(Hi):this._checkSelectorAndHandleMissingFields(Hi,this._missingFieldHandlers)},Li.commitPayload=function(Hi,Ui){this._execute({createSource:function(){return h.from({data:Ui})},isClientPayload:!0,operation:Hi,optimisticConfig:null,updater:null}).subscribe({})},Li.commitUpdate=function(Hi){var Ui=this;this._scheduleUpdates(function(){Ui._publishQueue.commitUpdate(Hi),Ui._publishQueue.run()})},Li.lookup=function(Hi){return this._store.lookup(Hi)},Li.subscribe=function(Hi,Ui){return this._store.subscribe(Hi,Ui)},Li.retain=function(Hi){return this._store.retain(Hi)},Li.experimental_batchUpdates=function(Hi){var Ui=this._store.experimental_batchUpdates;typeof Ui!="function"&&Ti(!1),Ui.call(this._store,Hi)},Li.isServer=function(){return this._isServer},Li._checkSelectorAndHandleMissingFields=function(Hi,Ui){var Qi=this,$i=Ri.create(),wi=this._store.getSource(),xi=this._store.check(Hi,{defaultActorIdentifier:s,getSourceForActor:function(Ei){return a(Ei),wi},getTargetForActor:function(Ei){return a(Ei),$i},handlers:Ui});return $i.size()>0&&this._scheduleUpdates(function(){Qi._publishQueue.commitSource($i),Qi._publishQueue.run()}),xi},Li._scheduleUpdates=function(Hi){var Ui=this._scheduler;Ui!=null?Ui.schedule(Hi):Hi()},Li.execute=function(Hi){var Ui=this,Qi=Hi.operation;return this._execute({createSource:function(){return Ui.getNetwork().execute(Qi.request.node.params,Qi.request.variables,Qi.request.cacheConfig||{},null,void 0,void 0,void 0,function(){return Ui.check(Qi)})},isClientPayload:!1,operation:Qi,optimisticConfig:null,updater:null})},Li.executeSubscription=function(Hi){var Ui=this,Qi=Hi.operation,$i=Hi.updater;return this._execute({createSource:function(){return Ui.getNetwork().execute(Qi.request.node.params,Qi.request.variables,Qi.request.cacheConfig||{},null)},isClientPayload:!1,operation:Qi,optimisticConfig:null,updater:$i})},Li.executeMutation=function(Hi){var Ui=this,Qi=Hi.operation,$i=Hi.optimisticResponse,wi=Hi.optimisticUpdater,xi=Hi.updater,yi=Hi.uploadables,Ei;return($i||wi)&&(Ei={operation:Qi,response:$i,updater:wi}),this._execute({createSource:function(){return Ui.getNetwork().execute(Qi.request.node.params,Qi.request.variables,(0,t.default)((0,t.default)({},Qi.request.cacheConfig),{},{force:!0}),yi)},isClientPayload:!1,operation:Qi,optimisticConfig:Ei,updater:xi})},Li.executeWithSource=function(Hi){var Ui=Hi.operation,Qi=Hi.source;return this._execute({createSource:function(){return Qi},isClientPayload:!1,operation:Ui,optimisticConfig:null,updater:null})},Li.toJSON=function(){var Hi;return"RelayModernEnvironment(".concat((Hi=this.configName)!==null&&Hi!==void 0?Hi:"",")")},Li._execute=function(Hi){var Ui=this,Qi=Hi.createSource,$i=Hi.isClientPayload,wi=Hi.operation,xi=Hi.optimisticConfig,yi=Hi.updater,Ei=this._publishQueue,Ci=this._store;return h.create(function(Ni){var Fi=mi.execute({actorIdentifier:s,getDataID:Ui._getDataID,getPublishQueue:function(Si){return a(Si),Ei},getStore:function(Si){return a(Si),Ci},isClientPayload:$i,log:Ui.__log,normalizeResponse:Ui._normalizeResponse,operation:wi,operationExecutions:Ui._operationExecutions,operationLoader:Ui._operationLoader,operationTracker:Ui._operationTracker,optimisticConfig:xi,scheduler:Ui._scheduler,shouldProcessClientComponents:Ui._shouldProcessClientComponents,sink:Ni,source:Qi(),treatMissingFieldsAsNull:Ui._treatMissingFieldsAsNull,deferDeduplicatedFields:Ui._deferDeduplicatedFields,updater:yi});return function(){return Fi.cancel()}})},ki}();function qi(ki){return ki.root.node.kind==="Operation"&&ki.root.node.clientAbstractTypes!=null}Ii.prototype["@@RelayModernEnvironment"]=!0;function Oi(){}return RelayModernEnvironment_1=Ii,RelayModernEnvironment_1}var requestSubscription_1,hasRequiredRequestSubscription;function requireRequestSubscription(){if(hasRequiredRequestSubscription)return requestSubscription_1;hasRequiredRequestSubscription=1;var r=requireRelayDeclarativeMutationConfig(),t=requireGraphQLTag(),i=t.getRequest,n=requireRelayModernOperationDescriptor(),s=n.createOperationDescriptor,a=requireRelayModernSelector(),h=a.createReaderSelector;requireWarning();function v(hi,u){var l=i(u.subscription);if(l.params.operationKind!=="subscription")throw new Error("requestSubscription: Must use Subscription operation");var vi=u.configs,D=u.onCompleted,mi=u.onError,gi=u.onNext,bi=u.variables,Ri=u.cacheConfig,Ti=s(l,bi,Ri),Ii=vi?r.convert(vi,l,null,u.updater):u,qi=Ii.updater,Oi=hi.executeSubscription({operation:Ti,updater:qi}).subscribe({complete:D,error:mi,next:function(Li){if(gi!=null){var ji=Ti.fragment,Hi;if(Array.isArray(Li)){var Ui,Qi;Hi=(Ui=Li[0])===null||Ui===void 0||(Qi=Ui.extensions)===null||Qi===void 0?void 0:Qi.__relay_subscription_root_id}else{var $i;Hi=($i=Li.extensions)===null||$i===void 0?void 0:$i.__relay_subscription_root_id}typeof Hi=="string"&&(ji=h(ji.node,Hi,ji.variables,ji.owner));var wi=hi.lookup(ji).data;gi(wi)}}});return{dispose:Oi.unsubscribe}}return requestSubscription_1=v,requestSubscription_1}var createPayloadFor3DField_1,hasRequiredCreatePayloadFor3DField;function requireCreatePayloadFor3DField(){if(hasRequiredCreatePayloadFor3DField)return createPayloadFor3DField_1;hasRequiredCreatePayloadFor3DField=1;var r=requireInteropRequireDefault().default,t=r(requireObjectSpread2()),i=requireRelayStoreUtils(),n=i.getModuleComponentKey,s=i.getModuleOperationKey;function a(h,v,hi,u){var l=(0,t.default)({},u);return l[n(h)]=hi,l[s(h)]=v,l}return createPayloadFor3DField_1=a,createPayloadFor3DField_1}var isEmptyObject_1,hasRequiredIsEmptyObject;function requireIsEmptyObject(){if(hasRequiredIsEmptyObject)return isEmptyObject_1;hasRequiredIsEmptyObject=1;var r=Object.prototype.hasOwnProperty;function t(i){for(var n in i)if(r.call(i,n))return!1;return!0}return isEmptyObject_1=t,isEmptyObject_1}var getFragmentIdentifier_1,hasRequiredGetFragmentIdentifier;function requireGetFragmentIdentifier(){if(hasRequiredGetFragmentIdentifier)return getFragmentIdentifier_1;hasRequiredGetFragmentIdentifier=1;var r=requireRelayModernSelector(),t=r.getDataIDsFromFragment,i=r.getSelector,n=r.getVariablesFromFragment,s=requireIsEmptyObject(),a=requireRelayFeatureFlags(),h=requireStableCopy(),v=h.stableCopy,hi=requireStringInterner(),u=hi.intern;function l(vi,D){var mi=i(vi,D),gi=mi==null?"null":mi.kind==="SingularReaderSelector"?mi.owner.identifier:"["+mi.selectors.map(function(Oi){return Oi.owner.identifier}).join(",")+"]",bi=n(vi,D),Ri=t(vi,D);if(a.ENABLE_GETFRAGMENTIDENTIFIER_OPTIMIZATION){var Ti=typeof Ri>"u"?"missing":Ri==null?"null":Array.isArray(Ri)?"["+Ri.join(",")+"]":Ri;return Ti=a.STRING_INTERN_LEVEL<=1?Ti:u(Ti,a.MAX_DATA_ID_LENGTH),gi+"/"+vi.name+"/"+(bi==null||s(bi)?"{}":JSON.stringify(v(bi)))+"/"+Ti}else{var Ii,qi=(Ii=JSON.stringify(Ri))!==null&&Ii!==void 0?Ii:"missing";return qi=a.STRING_INTERN_LEVEL<=1?qi:u(qi,a.MAX_DATA_ID_LENGTH),gi+"/"+vi.name+"/"+JSON.stringify(v(bi))+"/"+qi}}return getFragmentIdentifier_1=l,getFragmentIdentifier_1}var getRefetchMetadata_1,hasRequiredGetRefetchMetadata;function requireGetRefetchMetadata(){if(hasRequiredGetRefetchMetadata)return getRefetchMetadata_1;hasRequiredGetRefetchMetadata=1;var r=requireBrowser();function t(i,n){var s,a;((s=i.metadata)===null||s===void 0?void 0:s.plural)===!0&&r(!1);var h=(a=i.metadata)===null||a===void 0?void 0:a.refetch;h==null&&r(!1);var v=h.operation.default?h.operation.default:h.operation,hi=h.fragmentPathInResult;typeof v=="string"&&r(!1);var u=h.identifierInfo;return u!=null&&(u.identifierField==null||typeof u.identifierField=="string"||r(!1),u.identifierQueryVariableName==null||typeof u.identifierQueryVariableName=="string"||r(!1)),{fragmentRefPathInResponse:hi,identifierInfo:u,refetchableRequest:v,refetchMetadata:h}}return getRefetchMetadata_1=t,getRefetchMetadata_1}var getPaginationMetadata_1,hasRequiredGetPaginationMetadata;function requireGetPaginationMetadata(){if(hasRequiredGetPaginationMetadata)return getPaginationMetadata_1;hasRequiredGetPaginationMetadata=1;var r=requireGetRefetchMetadata(),t=requireBrowser();function i(n,s){var a,h,v=r(n,s),hi=v.refetchableRequest,u=v.refetchMetadata,l=u.connection;l==null&&t(!1);var vi=l.path,D=((a=(h=n.metadata)===null||h===void 0?void 0:h.connection)!==null&&a!==void 0?a:[])[0];D==null&&t(!1);var mi=u.identifierInfo;return mi?.identifierField==null||typeof mi.identifierField=="string"||t(!1),{connectionPathInFragmentData:vi,identifierField:mi?.identifierField,paginationRequest:hi,paginationMetadata:l,stream:D.stream===!0}}return getPaginationMetadata_1=i,getPaginationMetadata_1}var getPaginationVariables_1,hasRequiredGetPaginationVariables;function requireGetPaginationVariables(){if(hasRequiredGetPaginationVariables)return getPaginationVariables_1;hasRequiredGetPaginationVariables=1;var r=requireInteropRequireDefault().default,t=r(requireDefineProperty()),i=r(requireObjectSpread2()),n=requireBrowser();requireWarning();function s(a,h,v,hi,u,l){var vi,D=l.backward,mi=l.forward;if(a==="backward"){var gi;D!=null&&D.count!=null&&D.cursor!=null||n(!1);var bi=(0,i.default)((0,i.default)((0,i.default)({},hi),u),{},(gi={},(0,t.default)(gi,D.cursor,v),(0,t.default)(gi,D.count,h),gi));return mi&&mi.cursor&&(bi[mi.cursor]=null),mi&&mi.count&&(bi[mi.count]=null),bi}mi!=null&&mi.count!=null&&mi.cursor!=null||n(!1);var Ri=(0,i.default)((0,i.default)((0,i.default)({},hi),u),{},(vi={},(0,t.default)(vi,mi.cursor,v),(0,t.default)(vi,mi.count,h),vi));return D&&D.cursor&&(Ri[D.cursor]=null),D&&D.count&&(Ri[D.count]=null),Ri}return getPaginationVariables_1=s,getPaginationVariables_1}var getValueAtPath_1,hasRequiredGetValueAtPath;function requireGetValueAtPath(){if(hasRequiredGetValueAtPath)return getValueAtPath_1;hasRequiredGetValueAtPath=1;var r=requireInteropRequireDefault().default,t=r(requireCreateForOfIteratorHelper()),i=requireBrowser();function n(s,a){var h=s,v=(0,t.default)(a),hi;try{for(v.s();!(hi=v.n()).done;){var u=hi.value;if(h==null)return null;typeof u=="number"?(Array.isArray(h)||i(!1),h=h[u]):(typeof h=="object"&&!Array.isArray(h)||i(!1),h=h[u])}}catch(l){v.e(l)}finally{v.f()}return h}return getValueAtPath_1=n,getValueAtPath_1}var RelayProfiler_1,hasRequiredRelayProfiler;function requireRelayProfiler(){if(hasRequiredRelayProfiler)return RelayProfiler_1;hasRequiredRelayProfiler=1;var r={},t={stop:function(){}},i={profile:function(a,h){var v=r[a];if(v&&v.length>0){for(var hi=[],u=v.length-1;u>=0;u--){var l=v[u](a,h);hi.unshift(l)}return{stop:function(D){hi.forEach(function(mi){return mi(D)})}}}return t},attachProfileHandler:function(a,h){r.hasOwnProperty(a)||(r[a]=[]),r[a].push(h)},detachProfileHandler:function(a,h){r.hasOwnProperty(a)&&n(r[a],h)}};function n(s,a){var h=s.indexOf(a);h!==-1&&s.splice(h,1)}return RelayProfiler_1=i,RelayProfiler_1}var lib,hasRequiredLib;function requireLib(){if(hasRequiredLib)return lib;hasRequiredLib=1;var r=requireExperimental(),t=r.isErrorResult,i=r.isValueResult,n=requireConnectionHandler(),s=requireConnectionInterface(),a=requireMutationHandlers(),h=requireRelayDefaultHandlerProvider(),v=requireApplyOptimisticMutation(),hi=requireCommitLocalUpdate(),u=requireCommitMutation(),l=requireRelayDeclarativeMutationConfig(),vi=requireRelayNetwork(),D=requireRelayObservable(),mi=requireRelayQueryResponseCache(),gi=requireFetchQuery(),bi=requireFetchQuery_DEPRECATED(),Ri=requireFetchQueryInternal(),Ti=requireGraphQLTag(),Ii=requirePreloadableQueryRegistry(),qi=requireClientID(),Oi=qi.generateClientID,ki=qi.generateUniqueClientID,Li=qi.isClientID,ji=requireCreateFragmentSpecResolver(),Hi=requireCreateRelayContext(),Ui=requireCreateRelayLoggingContext(),Qi=requireDefaultGetDataID(),$i=requireIsRelayModernEnvironment(),wi=requireLiveResolverSuspenseSentinel(),xi=wi.isSuspenseSentinel,yi=wi.suspenseSentinel,Ei=requireNormalizationEngine(),Ci=requireNormalizeResponse(),Ni=requireReadInlineData(),Fi=requireRelayConcreteVariables(),Mi=requireRelayModernEnvironment(),Si=requireRelayModernOperationDescriptor(),Ai=requireRelayModernRecord(),_i=requireRelayModernSelector(),Bi=requireRelayModernStore(),Pi=requireRelayOperationTracker(),zi=requireRelayRecordSource(),Gi=requireRelayStoreUtils(),Vi=requireResolverFragments(),Ki=requireViewerPattern(),Zi=requireRequestSubscription(),In=requireCreatePayloadFor3DField(),Ji=requireDeepFreeze(),Xi=requireGetFragmentIdentifier(),on=requireGetPaginationMetadata(),jn=requireGetPaginationVariables(),Ln=requireGetPendingOperationsForFragment(),Hn=requireGetRefetchMetadata(),ea=requireGetRelayHandleKey(),ia=requireGetRequestIdentifier(),Wn=requireGetValueAtPath(),oa=requireHandlePotentialSnapshotErrors(),ta=oa.handlePotentialSnapshotErrors,aa=requireIsPromise(),sa=requireIsScalarAndEqual(),ua=requireRecycleNodesInto(),da=requireRelayConcreteNode(),ca=requireRelayDefaultHandleKey(),la=requireRelayError(),Fa=requireRelayFeatureFlags(),xa=requireRelayProfiler(),ha=requireRelayReplaySubject(),Ca=requireStableCopy(),Ra=Ca.hasCycle,pa=Ca.stableCopy,Ma=requireWithProvidedVariables(),wa=_i.areEqualSelectors,ya=_i.createNormalizationSelector,La=_i.createReaderSelector,Sa=_i.getDataIDsFromFragment,ga=_i.getDataIDsFromObject,Pa=_i.getPluralSelector,Ta=_i.getSelector,va=_i.getSelectorsFromObject,Ba=_i.getSingularSelector,Aa=_i.getVariablesFromFragment,_a=_i.getVariablesFromObject,ka=_i.getVariablesFromPluralFragment,Na=_i.getVariablesFromSingularFragment,Rn=Si.createOperationDescriptor,Wi=Si.createRequestDescriptor,Yi=Gi.getArgumentValues,Mn=Gi.getModuleComponentKey,Yn=Gi.getModuleOperationKey,ra=Gi.getStorageKey,na=Gi.FRAGMENTS_KEY,Ea=Gi.FRAGMENT_OWNER_KEY,ba=Gi.ID_KEY,fa=Gi.REF_KEY,Ia=Gi.REFS_KEY,ma=Gi.ROOT_ID,Da=Gi.ROOT_TYPE,$a=Gi.TYPENAME_KEY,qa=Ti.getNode,Oa=Ti.getFragment,Ua=Ti.getInlineDataFragment,ja=Ti.getPaginationFragment,Va=Ti.getRefetchableFragment,Ga=Ti.getRequest,Ka=Ti.graphql,Ha=Ti.isFragment,Qa=Ti.isInlineDataFragment,za=Ti.isRequest,Wa=Vi.readFragment,Ya=ca.DEFAULT_HANDLE_KEY,Xa=l.MutationTypes,Ja=l.RangeOperations,Za=Ki.VIEWER_ID,ao=Ki.VIEWER_TYPE,vo={ResolverFragments:Vi,OperationTracker:Pi,createRelayContext:Hi,createRelayLoggingContext:Ui,defaultGetDataID:Qi,getOperationVariables:Fi.getOperationVariables,getLocalVariables:Fi.getLocalVariables,fetchQuery:Ri.fetchQuery,fetchQueryDeduped:Ri.fetchQueryDeduped,getPromiseForActiveRequest:Ri.getPromiseForActiveRequest,getObservableForActiveRequest:Ri.getObservableForActiveRequest,NormalizationEngine:Ei,normalizeResponse:Ci,withProvidedVariables:Ma};return lib={Environment:Mi,Network:vi,Observable:D,QueryResponseCache:mi,RecordSource:zi,Record:Ai,ReplaySubject:ha,Store:Bi,areEqualSelectors:wa,createFragmentSpecResolver:ji,createNormalizationSelector:ya,createOperationDescriptor:Rn,createReaderSelector:La,createRequestDescriptor:Wi,getArgumentValues:Yi,getDataIDsFromFragment:Sa,getDataIDsFromObject:ga,getNode:qa,getFragment:Oa,getInlineDataFragment:Ua,getModuleComponentKey:Mn,getModuleOperationKey:Yn,getPaginationFragment:ja,getPluralSelector:Pa,getRefetchableFragment:Va,getRequest:Ga,getRequestIdentifier:ia,getSelector:Ta,getSelectorsFromObject:va,getSingularSelector:Ba,getStorageKey:ra,getVariablesFromFragment:Aa,getVariablesFromObject:_a,getVariablesFromPluralFragment:ka,getVariablesFromSingularFragment:Na,handlePotentialSnapshotErrors:ta,graphql:Ka,isErrorResult:t,isValueResult:i,isFragment:Ha,isInlineDataFragment:Qa,isSuspenseSentinel:xi,suspenseSentinel:yi,isRequest:za,readInlineData:Ni,readFragment:Wa,MutationTypes:Xa,RangeOperations:Ja,DefaultHandlerProvider:h,ConnectionHandler:n,MutationHandlers:a,VIEWER_ID:Za,VIEWER_TYPE:ao,applyOptimisticMutation:v,commitLocalUpdate:hi,commitMutation:u,fetchQuery:gi,fetchQuery_DEPRECATED:bi,isRelayModernEnvironment:$i,requestSubscription:Zi,ConnectionInterface:s,PreloadableQueryRegistry:Ii,RelayProfiler:xa,createPayloadFor3DField:In,RelayConcreteNode:da,RelayError:la,RelayFeatureFlags:Fa,DEFAULT_HANDLE_KEY:Ya,FRAGMENTS_KEY:na,FRAGMENT_OWNER_KEY:Ea,ID_KEY:ba,REF_KEY:fa,REFS_KEY:Ia,ROOT_ID:ma,ROOT_TYPE:Da,TYPENAME_KEY:$a,deepFreeze:Ji,generateClientID:Oi,generateUniqueClientID:ki,getRelayHandleKey:ea,isClientID:Li,isPromise:aa,isScalarAndEqual:sa,recycleNodesInto:ua,stableCopy:pa,hasCycle:Ra,getFragmentIdentifier:Xi,getRefetchMetadata:Hn,getPaginationMetadata:on,getPaginationVariables:jn,getPendingOperationsForFragment:Ln,getValueAtPath:Wn,__internal:vo},lib}var relayRuntime,hasRequiredRelayRuntime;function requireRelayRuntime(){return hasRequiredRelayRuntime||(hasRequiredRelayRuntime=1,relayRuntime=requireLib()),relayRuntime}var relayRuntimeExports=requireRelayRuntime();const TOKEN_HEADER_KEY="x-graphql-event-stream-token";function validateStreamEvent(r){if(r=r,r!=="next"&&r!=="complete")throw new Error(`Invalid stream event "${r}"`);return r}function parseStreamData(r,t){if(t)try{t=JSON.parse(t)}catch{throw new Error("Invalid stream data")}if(r==="next"&&!t)throw new Error('Stream data must be an object for "next" events');return t||null}const version="16.9.0",versionInfo=Object.freeze({major:16,minor:9,patch:0,preReleaseTag:null});function devAssert(r,t){if(!!!r)throw new Error(t)}function isPromise(r){return typeof r?.then=="function"}function isObjectLike(r){return typeof r=="object"&&r!==null}function invariant(r,t){if(!!!r)throw new Error(t??"Unexpected invariant triggered.")}const LineRegExp=/\r\n|[\n\r]/g;function getLocation(r,t){let i=0,n=1;for(const s of r.body.matchAll(LineRegExp)){if(typeof s.index=="number"||invariant(!1),s.index>=t)break;i=s.index+s[0].length,n+=1}return{line:n,column:t+1-i}}function printLocation(r){return printSourceLocation(r.source,getLocation(r.source,r.start))}function printSourceLocation(r,t){const i=r.locationOffset.column-1,n="".padStart(i)+r.body,s=t.line-1,a=r.locationOffset.line-1,h=t.line+a,v=t.line===1?i:0,hi=t.column+v,u=`${r.name}:${h}:${hi}
128
+ `,l=n.split(/\r\n|[\n\r]/g),vi=l[s];if(vi.length>120){const D=Math.floor(hi/80),mi=hi%80,gi=[];for(let bi=0;bi<vi.length;bi+=80)gi.push(vi.slice(bi,bi+80));return u+printPrefixedLines([[`${h} |`,gi[0]],...gi.slice(1,D+1).map(bi=>["|",bi]),["|","^".padStart(mi)],["|",gi[D+1]]])}return u+printPrefixedLines([[`${h-1} |`,l[s-1]],[`${h} |`,vi],["|","^".padStart(hi)],[`${h+1} |`,l[s+1]]])}function printPrefixedLines(r){const t=r.filter(([n,s])=>s!==void 0),i=Math.max(...t.map(([n])=>n.length));return t.map(([n,s])=>n.padStart(i)+(s?" "+s:"")).join(`
129
+ `)}function toNormalizedOptions(r){const t=r[0];return t==null||"kind"in t||"length"in t?{nodes:t,source:r[1],positions:r[2],path:r[3],originalError:r[4],extensions:r[5]}:t}class GraphQLError extends Error{constructor(t,...i){var n,s,a;const{nodes:h,source:v,positions:hi,path:u,originalError:l,extensions:vi}=toNormalizedOptions(i);super(t),this.name="GraphQLError",this.path=u??void 0,this.originalError=l??void 0,this.nodes=undefinedIfEmpty(Array.isArray(h)?h:h?[h]:void 0);const D=undefinedIfEmpty((n=this.nodes)===null||n===void 0?void 0:n.map(gi=>gi.loc).filter(gi=>gi!=null));this.source=v??(D==null||(s=D[0])===null||s===void 0?void 0:s.source),this.positions=hi??D?.map(gi=>gi.start),this.locations=hi&&v?hi.map(gi=>getLocation(v,gi)):D?.map(gi=>getLocation(gi.source,gi.start));const mi=isObjectLike(l?.extensions)?l?.extensions:void 0;this.extensions=(a=vi??mi)!==null&&a!==void 0?a:Object.create(null),Object.defineProperties(this,{message:{writable:!0,enumerable:!0},name:{enumerable:!1},nodes:{enumerable:!1},source:{enumerable:!1},positions:{enumerable:!1},originalError:{enumerable:!1}}),l!=null&&l.stack?Object.defineProperty(this,"stack",{value:l.stack,writable:!0,configurable:!0}):Error.captureStackTrace?Error.captureStackTrace(this,GraphQLError):Object.defineProperty(this,"stack",{value:Error().stack,writable:!0,configurable:!0})}get[Symbol.toStringTag](){return"GraphQLError"}toString(){let t=this.message;if(this.nodes)for(const i of this.nodes)i.loc&&(t+=`
130
+
131
+ `+printLocation(i.loc));else if(this.source&&this.locations)for(const i of this.locations)t+=`
132
+
133
+ `+printSourceLocation(this.source,i);return t}toJSON(){const t={message:this.message};return this.locations!=null&&(t.locations=this.locations),this.path!=null&&(t.path=this.path),this.extensions!=null&&Object.keys(this.extensions).length>0&&(t.extensions=this.extensions),t}}function undefinedIfEmpty(r){return r===void 0||r.length===0?void 0:r}function printError(r){return r.toString()}function formatError(r){return r.toJSON()}function syntaxError(r,t,i){return new GraphQLError(`Syntax Error: ${i}`,{source:r,positions:[t]})}let Location$1=class{constructor(t,i,n){this.start=t.start,this.end=i.end,this.startToken=t,this.endToken=i,this.source=n}get[Symbol.toStringTag](){return"Location"}toJSON(){return{start:this.start,end:this.end}}};class Token{constructor(t,i,n,s,a,h){this.kind=t,this.start=i,this.end=n,this.line=s,this.column=a,this.value=h,this.prev=null,this.next=null}get[Symbol.toStringTag](){return"Token"}toJSON(){return{kind:this.kind,value:this.value,line:this.line,column:this.column}}}const QueryDocumentKeys={Name:[],Document:["definitions"],OperationDefinition:["name","variableDefinitions","directives","selectionSet"],VariableDefinition:["variable","type","defaultValue","directives"],Variable:["name"],SelectionSet:["selections"],Field:["alias","name","arguments","directives","selectionSet"],Argument:["name","value"],FragmentSpread:["name","directives"],InlineFragment:["typeCondition","directives","selectionSet"],FragmentDefinition:["name","variableDefinitions","typeCondition","directives","selectionSet"],IntValue:[],FloatValue:[],StringValue:[],BooleanValue:[],NullValue:[],EnumValue:[],ListValue:["values"],ObjectValue:["fields"],ObjectField:["name","value"],Directive:["name","arguments"],NamedType:["name"],ListType:["type"],NonNullType:["type"],SchemaDefinition:["description","directives","operationTypes"],OperationTypeDefinition:["type"],ScalarTypeDefinition:["description","name","directives"],ObjectTypeDefinition:["description","name","interfaces","directives","fields"],FieldDefinition:["description","name","arguments","type","directives"],InputValueDefinition:["description","name","type","defaultValue","directives"],InterfaceTypeDefinition:["description","name","interfaces","directives","fields"],UnionTypeDefinition:["description","name","directives","types"],EnumTypeDefinition:["description","name","directives","values"],EnumValueDefinition:["description","name","directives"],InputObjectTypeDefinition:["description","name","directives","fields"],DirectiveDefinition:["description","name","arguments","locations"],SchemaExtension:["directives","operationTypes"],ScalarTypeExtension:["name","directives"],ObjectTypeExtension:["name","interfaces","directives","fields"],InterfaceTypeExtension:["name","interfaces","directives","fields"],UnionTypeExtension:["name","directives","types"],EnumTypeExtension:["name","directives","values"],InputObjectTypeExtension:["name","directives","fields"]},kindValues=new Set(Object.keys(QueryDocumentKeys));function isNode(r){const t=r?.kind;return typeof t=="string"&&kindValues.has(t)}var OperationTypeNode;(function(r){r.QUERY="query",r.MUTATION="mutation",r.SUBSCRIPTION="subscription"})(OperationTypeNode||(OperationTypeNode={}));var DirectiveLocation;(function(r){r.QUERY="QUERY",r.MUTATION="MUTATION",r.SUBSCRIPTION="SUBSCRIPTION",r.FIELD="FIELD",r.FRAGMENT_DEFINITION="FRAGMENT_DEFINITION",r.FRAGMENT_SPREAD="FRAGMENT_SPREAD",r.INLINE_FRAGMENT="INLINE_FRAGMENT",r.VARIABLE_DEFINITION="VARIABLE_DEFINITION",r.SCHEMA="SCHEMA",r.SCALAR="SCALAR",r.OBJECT="OBJECT",r.FIELD_DEFINITION="FIELD_DEFINITION",r.ARGUMENT_DEFINITION="ARGUMENT_DEFINITION",r.INTERFACE="INTERFACE",r.UNION="UNION",r.ENUM="ENUM",r.ENUM_VALUE="ENUM_VALUE",r.INPUT_OBJECT="INPUT_OBJECT",r.INPUT_FIELD_DEFINITION="INPUT_FIELD_DEFINITION"})(DirectiveLocation||(DirectiveLocation={}));var Kind;(function(r){r.NAME="Name",r.DOCUMENT="Document",r.OPERATION_DEFINITION="OperationDefinition",r.VARIABLE_DEFINITION="VariableDefinition",r.SELECTION_SET="SelectionSet",r.FIELD="Field",r.ARGUMENT="Argument",r.FRAGMENT_SPREAD="FragmentSpread",r.INLINE_FRAGMENT="InlineFragment",r.FRAGMENT_DEFINITION="FragmentDefinition",r.VARIABLE="Variable",r.INT="IntValue",r.FLOAT="FloatValue",r.STRING="StringValue",r.BOOLEAN="BooleanValue",r.NULL="NullValue",r.ENUM="EnumValue",r.LIST="ListValue",r.OBJECT="ObjectValue",r.OBJECT_FIELD="ObjectField",r.DIRECTIVE="Directive",r.NAMED_TYPE="NamedType",r.LIST_TYPE="ListType",r.NON_NULL_TYPE="NonNullType",r.SCHEMA_DEFINITION="SchemaDefinition",r.OPERATION_TYPE_DEFINITION="OperationTypeDefinition",r.SCALAR_TYPE_DEFINITION="ScalarTypeDefinition",r.OBJECT_TYPE_DEFINITION="ObjectTypeDefinition",r.FIELD_DEFINITION="FieldDefinition",r.INPUT_VALUE_DEFINITION="InputValueDefinition",r.INTERFACE_TYPE_DEFINITION="InterfaceTypeDefinition",r.UNION_TYPE_DEFINITION="UnionTypeDefinition",r.ENUM_TYPE_DEFINITION="EnumTypeDefinition",r.ENUM_VALUE_DEFINITION="EnumValueDefinition",r.INPUT_OBJECT_TYPE_DEFINITION="InputObjectTypeDefinition",r.DIRECTIVE_DEFINITION="DirectiveDefinition",r.SCHEMA_EXTENSION="SchemaExtension",r.SCALAR_TYPE_EXTENSION="ScalarTypeExtension",r.OBJECT_TYPE_EXTENSION="ObjectTypeExtension",r.INTERFACE_TYPE_EXTENSION="InterfaceTypeExtension",r.UNION_TYPE_EXTENSION="UnionTypeExtension",r.ENUM_TYPE_EXTENSION="EnumTypeExtension",r.INPUT_OBJECT_TYPE_EXTENSION="InputObjectTypeExtension"})(Kind||(Kind={}));function isWhiteSpace(r){return r===9||r===32}function isDigit$1(r){return r>=48&&r<=57}function isLetter(r){return r>=97&&r<=122||r>=65&&r<=90}function isNameStart(r){return isLetter(r)||r===95}function isNameContinue(r){return isLetter(r)||isDigit$1(r)||r===95}function dedentBlockStringLines(r){var t;let i=Number.MAX_SAFE_INTEGER,n=null,s=-1;for(let h=0;h<r.length;++h){var a;const v=r[h],hi=leadingWhitespace(v);hi!==v.length&&(n=(a=n)!==null&&a!==void 0?a:h,s=h,h!==0&&hi<i&&(i=hi))}return r.map((h,v)=>v===0?h:h.slice(i)).slice((t=n)!==null&&t!==void 0?t:0,s+1)}function leadingWhitespace(r){let t=0;for(;t<r.length&&isWhiteSpace(r.charCodeAt(t));)++t;return t}function isPrintableAsBlockString(r){if(r==="")return!0;let t=!0,i=!1,n=!0,s=!1;for(let a=0;a<r.length;++a)switch(r.codePointAt(a)){case 0:case 1:case 2:case 3:case 4:case 5:case 6:case 7:case 8:case 11:case 12:case 14:case 15:return!1;case 13:return!1;case 10:if(t&&!s)return!1;s=!0,t=!0,i=!1;break;case 9:case 32:i||(i=t);break;default:n&&(n=i),t=!1}return!(t||n&&s)}function printBlockString(r,t){const i=r.replace(/"""/g,'\\"""'),n=i.split(/\r\n|[\n\r]/g),s=n.length===1,a=n.length>1&&n.slice(1).every(mi=>mi.length===0||isWhiteSpace(mi.charCodeAt(0))),h=i.endsWith('\\"""'),v=r.endsWith('"')&&!h,hi=r.endsWith("\\"),u=v||hi,l=!(t!=null&&t.minimize)&&(!s||r.length>70||u||a||h);let vi="";const D=s&&isWhiteSpace(r.charCodeAt(0));return(l&&!D||a)&&(vi+=`
134
+ `),vi+=i,(l||u)&&(vi+=`
135
+ `),'"""'+vi+'"""'}var TokenKind;(function(r){r.SOF="<SOF>",r.EOF="<EOF>",r.BANG="!",r.DOLLAR="$",r.AMP="&",r.PAREN_L="(",r.PAREN_R=")",r.SPREAD="...",r.COLON=":",r.EQUALS="=",r.AT="@",r.BRACKET_L="[",r.BRACKET_R="]",r.BRACE_L="{",r.PIPE="|",r.BRACE_R="}",r.NAME="Name",r.INT="Int",r.FLOAT="Float",r.STRING="String",r.BLOCK_STRING="BlockString",r.COMMENT="Comment"})(TokenKind||(TokenKind={}));class Lexer{constructor(t){const i=new Token(TokenKind.SOF,0,0,0,0);this.source=t,this.lastToken=i,this.token=i,this.line=1,this.lineStart=0}get[Symbol.toStringTag](){return"Lexer"}advance(){return this.lastToken=this.token,this.token=this.lookahead()}lookahead(){let t=this.token;if(t.kind!==TokenKind.EOF)do if(t.next)t=t.next;else{const i=readNextToken(this,t.end);t.next=i,i.prev=t,t=i}while(t.kind===TokenKind.COMMENT);return t}}function isPunctuatorTokenKind(r){return r===TokenKind.BANG||r===TokenKind.DOLLAR||r===TokenKind.AMP||r===TokenKind.PAREN_L||r===TokenKind.PAREN_R||r===TokenKind.SPREAD||r===TokenKind.COLON||r===TokenKind.EQUALS||r===TokenKind.AT||r===TokenKind.BRACKET_L||r===TokenKind.BRACKET_R||r===TokenKind.BRACE_L||r===TokenKind.PIPE||r===TokenKind.BRACE_R}function isUnicodeScalarValue(r){return r>=0&&r<=55295||r>=57344&&r<=1114111}function isSupplementaryCodePoint(r,t){return isLeadingSurrogate(r.charCodeAt(t))&&isTrailingSurrogate(r.charCodeAt(t+1))}function isLeadingSurrogate(r){return r>=55296&&r<=56319}function isTrailingSurrogate(r){return r>=56320&&r<=57343}function printCodePointAt(r,t){const i=r.source.body.codePointAt(t);if(i===void 0)return TokenKind.EOF;if(i>=32&&i<=126){const n=String.fromCodePoint(i);return n==='"'?`'"'`:`"${n}"`}return"U+"+i.toString(16).toUpperCase().padStart(4,"0")}function createToken(r,t,i,n,s){const a=r.line,h=1+i-r.lineStart;return new Token(t,i,n,a,h,s)}function readNextToken(r,t){const i=r.source.body,n=i.length;let s=t;for(;s<n;){const a=i.charCodeAt(s);switch(a){case 65279:case 9:case 32:case 44:++s;continue;case 10:++s,++r.line,r.lineStart=s;continue;case 13:i.charCodeAt(s+1)===10?s+=2:++s,++r.line,r.lineStart=s;continue;case 35:return readComment(r,s);case 33:return createToken(r,TokenKind.BANG,s,s+1);case 36:return createToken(r,TokenKind.DOLLAR,s,s+1);case 38:return createToken(r,TokenKind.AMP,s,s+1);case 40:return createToken(r,TokenKind.PAREN_L,s,s+1);case 41:return createToken(r,TokenKind.PAREN_R,s,s+1);case 46:if(i.charCodeAt(s+1)===46&&i.charCodeAt(s+2)===46)return createToken(r,TokenKind.SPREAD,s,s+3);break;case 58:return createToken(r,TokenKind.COLON,s,s+1);case 61:return createToken(r,TokenKind.EQUALS,s,s+1);case 64:return createToken(r,TokenKind.AT,s,s+1);case 91:return createToken(r,TokenKind.BRACKET_L,s,s+1);case 93:return createToken(r,TokenKind.BRACKET_R,s,s+1);case 123:return createToken(r,TokenKind.BRACE_L,s,s+1);case 124:return createToken(r,TokenKind.PIPE,s,s+1);case 125:return createToken(r,TokenKind.BRACE_R,s,s+1);case 34:return i.charCodeAt(s+1)===34&&i.charCodeAt(s+2)===34?readBlockString(r,s):readString(r,s)}if(isDigit$1(a)||a===45)return readNumber(r,s,a);if(isNameStart(a))return readName(r,s);throw syntaxError(r.source,s,a===39?`Unexpected single quote character ('), did you mean to use a double quote (")?`:isUnicodeScalarValue(a)||isSupplementaryCodePoint(i,s)?`Unexpected character: ${printCodePointAt(r,s)}.`:`Invalid character: ${printCodePointAt(r,s)}.`)}return createToken(r,TokenKind.EOF,n,n)}function readComment(r,t){const i=r.source.body,n=i.length;let s=t+1;for(;s<n;){const a=i.charCodeAt(s);if(a===10||a===13)break;if(isUnicodeScalarValue(a))++s;else if(isSupplementaryCodePoint(i,s))s+=2;else break}return createToken(r,TokenKind.COMMENT,t,s,i.slice(t+1,s))}function readNumber(r,t,i){const n=r.source.body;let s=t,a=i,h=!1;if(a===45&&(a=n.charCodeAt(++s)),a===48){if(a=n.charCodeAt(++s),isDigit$1(a))throw syntaxError(r.source,s,`Invalid number, unexpected digit after 0: ${printCodePointAt(r,s)}.`)}else s=readDigits(r,s,a),a=n.charCodeAt(s);if(a===46&&(h=!0,a=n.charCodeAt(++s),s=readDigits(r,s,a),a=n.charCodeAt(s)),(a===69||a===101)&&(h=!0,a=n.charCodeAt(++s),(a===43||a===45)&&(a=n.charCodeAt(++s)),s=readDigits(r,s,a),a=n.charCodeAt(s)),a===46||isNameStart(a))throw syntaxError(r.source,s,`Invalid number, expected digit but got: ${printCodePointAt(r,s)}.`);return createToken(r,h?TokenKind.FLOAT:TokenKind.INT,t,s,n.slice(t,s))}function readDigits(r,t,i){if(!isDigit$1(i))throw syntaxError(r.source,t,`Invalid number, expected digit but got: ${printCodePointAt(r,t)}.`);const n=r.source.body;let s=t+1;for(;isDigit$1(n.charCodeAt(s));)++s;return s}function readString(r,t){const i=r.source.body,n=i.length;let s=t+1,a=s,h="";for(;s<n;){const v=i.charCodeAt(s);if(v===34)return h+=i.slice(a,s),createToken(r,TokenKind.STRING,t,s+1,h);if(v===92){h+=i.slice(a,s);const hi=i.charCodeAt(s+1)===117?i.charCodeAt(s+2)===123?readEscapedUnicodeVariableWidth(r,s):readEscapedUnicodeFixedWidth(r,s):readEscapedCharacter(r,s);h+=hi.value,s+=hi.size,a=s;continue}if(v===10||v===13)break;if(isUnicodeScalarValue(v))++s;else if(isSupplementaryCodePoint(i,s))s+=2;else throw syntaxError(r.source,s,`Invalid character within String: ${printCodePointAt(r,s)}.`)}throw syntaxError(r.source,s,"Unterminated string.")}function readEscapedUnicodeVariableWidth(r,t){const i=r.source.body;let n=0,s=3;for(;s<12;){const a=i.charCodeAt(t+s++);if(a===125){if(s<5||!isUnicodeScalarValue(n))break;return{value:String.fromCodePoint(n),size:s}}if(n=n<<4|readHexDigit(a),n<0)break}throw syntaxError(r.source,t,`Invalid Unicode escape sequence: "${i.slice(t,t+s)}".`)}function readEscapedUnicodeFixedWidth(r,t){const i=r.source.body,n=read16BitHexCode(i,t+2);if(isUnicodeScalarValue(n))return{value:String.fromCodePoint(n),size:6};if(isLeadingSurrogate(n)&&i.charCodeAt(t+6)===92&&i.charCodeAt(t+7)===117){const s=read16BitHexCode(i,t+8);if(isTrailingSurrogate(s))return{value:String.fromCodePoint(n,s),size:12}}throw syntaxError(r.source,t,`Invalid Unicode escape sequence: "${i.slice(t,t+6)}".`)}function read16BitHexCode(r,t){return readHexDigit(r.charCodeAt(t))<<12|readHexDigit(r.charCodeAt(t+1))<<8|readHexDigit(r.charCodeAt(t+2))<<4|readHexDigit(r.charCodeAt(t+3))}function readHexDigit(r){return r>=48&&r<=57?r-48:r>=65&&r<=70?r-55:r>=97&&r<=102?r-87:-1}function readEscapedCharacter(r,t){const i=r.source.body;switch(i.charCodeAt(t+1)){case 34:return{value:'"',size:2};case 92:return{value:"\\",size:2};case 47:return{value:"/",size:2};case 98:return{value:"\b",size:2};case 102:return{value:"\f",size:2};case 110:return{value:`
136
+ `,size:2};case 114:return{value:"\r",size:2};case 116:return{value:" ",size:2}}throw syntaxError(r.source,t,`Invalid character escape sequence: "${i.slice(t,t+2)}".`)}function readBlockString(r,t){const i=r.source.body,n=i.length;let s=r.lineStart,a=t+3,h=a,v="";const hi=[];for(;a<n;){const u=i.charCodeAt(a);if(u===34&&i.charCodeAt(a+1)===34&&i.charCodeAt(a+2)===34){v+=i.slice(h,a),hi.push(v);const l=createToken(r,TokenKind.BLOCK_STRING,t,a+3,dedentBlockStringLines(hi).join(`
137
+ `));return r.line+=hi.length-1,r.lineStart=s,l}if(u===92&&i.charCodeAt(a+1)===34&&i.charCodeAt(a+2)===34&&i.charCodeAt(a+3)===34){v+=i.slice(h,a),h=a+1,a+=4;continue}if(u===10||u===13){v+=i.slice(h,a),hi.push(v),u===13&&i.charCodeAt(a+1)===10?a+=2:++a,v="",h=a,s=a;continue}if(isUnicodeScalarValue(u))++a;else if(isSupplementaryCodePoint(i,a))a+=2;else throw syntaxError(r.source,a,`Invalid character within String: ${printCodePointAt(r,a)}.`)}throw syntaxError(r.source,a,"Unterminated string.")}function readName(r,t){const i=r.source.body,n=i.length;let s=t+1;for(;s<n;){const a=i.charCodeAt(s);if(isNameContinue(a))++s;else break}return createToken(r,TokenKind.NAME,t,s,i.slice(t,s))}const MAX_ARRAY_LENGTH=10,MAX_RECURSIVE_DEPTH=2;function inspect(r){return formatValue(r,[])}function formatValue(r,t){switch(typeof r){case"string":return JSON.stringify(r);case"function":return r.name?`[function ${r.name}]`:"[function]";case"object":return formatObjectValue(r,t);default:return String(r)}}function formatObjectValue(r,t){if(r===null)return"null";if(t.includes(r))return"[Circular]";const i=[...t,r];if(isJSONable(r)){const n=r.toJSON();if(n!==r)return typeof n=="string"?n:formatValue(n,i)}else if(Array.isArray(r))return formatArray(r,i);return formatObject(r,i)}function isJSONable(r){return typeof r.toJSON=="function"}function formatObject(r,t){const i=Object.entries(r);return i.length===0?"{}":t.length>MAX_RECURSIVE_DEPTH?"["+getObjectTag(r)+"]":"{ "+i.map(([s,a])=>s+": "+formatValue(a,t)).join(", ")+" }"}function formatArray(r,t){if(r.length===0)return"[]";if(t.length>MAX_RECURSIVE_DEPTH)return"[Array]";const i=Math.min(MAX_ARRAY_LENGTH,r.length),n=r.length-i,s=[];for(let a=0;a<i;++a)s.push(formatValue(r[a],t));return n===1?s.push("... 1 more item"):n>1&&s.push(`... ${n} more items`),"["+s.join(", ")+"]"}function getObjectTag(r){const t=Object.prototype.toString.call(r).replace(/^\[object /,"").replace(/]$/,"");if(t==="Object"&&typeof r.constructor=="function"){const i=r.constructor.name;if(typeof i=="string"&&i!=="")return i}return t}const isProduction=globalThis.process&&!0,instanceOf=isProduction?function r(t,i){return t instanceof i}:function r(t,i){if(t instanceof i)return!0;if(typeof t=="object"&&t!==null){var n;const s=i.prototype[Symbol.toStringTag],a=Symbol.toStringTag in t?t[Symbol.toStringTag]:(n=t.constructor)===null||n===void 0?void 0:n.name;if(s===a){const h=inspect(t);throw new Error(`Cannot use ${s} "${h}" from another module or realm.
138
+
139
+ Ensure that there is only one instance of "graphql" in the node_modules
140
+ directory. If different versions of "graphql" are the dependencies of other
141
+ relied on modules, use "resolutions" to ensure only one version is installed.
142
+
143
+ https://yarnpkg.com/en/docs/selective-version-resolutions
144
+
145
+ Duplicate "graphql" modules cannot be used at the same time since different
146
+ versions may have different capabilities and behavior. The data from one
147
+ version used in the function from another could produce confusing and
148
+ spurious results.`)}}return!1};class Source{constructor(t,i="GraphQL request",n={line:1,column:1}){typeof t=="string"||devAssert(!1,`Body must be a string. Received: ${inspect(t)}.`),this.body=t,this.name=i,this.locationOffset=n,this.locationOffset.line>0||devAssert(!1,"line in locationOffset is 1-indexed and must be positive."),this.locationOffset.column>0||devAssert(!1,"column in locationOffset is 1-indexed and must be positive.")}get[Symbol.toStringTag](){return"Source"}}function isSource(r){return instanceOf(r,Source)}function parse(r,t){return new Parser(r,t).parseDocument()}function parseValue(r,t){const i=new Parser(r,t);i.expectToken(TokenKind.SOF);const n=i.parseValueLiteral(!1);return i.expectToken(TokenKind.EOF),n}function parseConstValue(r,t){const i=new Parser(r,t);i.expectToken(TokenKind.SOF);const n=i.parseConstValueLiteral();return i.expectToken(TokenKind.EOF),n}function parseType(r,t){const i=new Parser(r,t);i.expectToken(TokenKind.SOF);const n=i.parseTypeReference();return i.expectToken(TokenKind.EOF),n}class Parser{constructor(t,i={}){const n=isSource(t)?t:new Source(t);this._lexer=new Lexer(n),this._options=i,this._tokenCounter=0}parseName(){const t=this.expectToken(TokenKind.NAME);return this.node(t,{kind:Kind.NAME,value:t.value})}parseDocument(){return this.node(this._lexer.token,{kind:Kind.DOCUMENT,definitions:this.many(TokenKind.SOF,this.parseDefinition,TokenKind.EOF)})}parseDefinition(){if(this.peek(TokenKind.BRACE_L))return this.parseOperationDefinition();const t=this.peekDescription(),i=t?this._lexer.lookahead():this._lexer.token;if(i.kind===TokenKind.NAME){switch(i.value){case"schema":return this.parseSchemaDefinition();case"scalar":return this.parseScalarTypeDefinition();case"type":return this.parseObjectTypeDefinition();case"interface":return this.parseInterfaceTypeDefinition();case"union":return this.parseUnionTypeDefinition();case"enum":return this.parseEnumTypeDefinition();case"input":return this.parseInputObjectTypeDefinition();case"directive":return this.parseDirectiveDefinition()}if(t)throw syntaxError(this._lexer.source,this._lexer.token.start,"Unexpected description, descriptions are supported only on type definitions.");switch(i.value){case"query":case"mutation":case"subscription":return this.parseOperationDefinition();case"fragment":return this.parseFragmentDefinition();case"extend":return this.parseTypeSystemExtension()}}throw this.unexpected(i)}parseOperationDefinition(){const t=this._lexer.token;if(this.peek(TokenKind.BRACE_L))return this.node(t,{kind:Kind.OPERATION_DEFINITION,operation:OperationTypeNode.QUERY,name:void 0,variableDefinitions:[],directives:[],selectionSet:this.parseSelectionSet()});const i=this.parseOperationType();let n;return this.peek(TokenKind.NAME)&&(n=this.parseName()),this.node(t,{kind:Kind.OPERATION_DEFINITION,operation:i,name:n,variableDefinitions:this.parseVariableDefinitions(),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseOperationType(){const t=this.expectToken(TokenKind.NAME);switch(t.value){case"query":return OperationTypeNode.QUERY;case"mutation":return OperationTypeNode.MUTATION;case"subscription":return OperationTypeNode.SUBSCRIPTION}throw this.unexpected(t)}parseVariableDefinitions(){return this.optionalMany(TokenKind.PAREN_L,this.parseVariableDefinition,TokenKind.PAREN_R)}parseVariableDefinition(){return this.node(this._lexer.token,{kind:Kind.VARIABLE_DEFINITION,variable:this.parseVariable(),type:(this.expectToken(TokenKind.COLON),this.parseTypeReference()),defaultValue:this.expectOptionalToken(TokenKind.EQUALS)?this.parseConstValueLiteral():void 0,directives:this.parseConstDirectives()})}parseVariable(){const t=this._lexer.token;return this.expectToken(TokenKind.DOLLAR),this.node(t,{kind:Kind.VARIABLE,name:this.parseName()})}parseSelectionSet(){return this.node(this._lexer.token,{kind:Kind.SELECTION_SET,selections:this.many(TokenKind.BRACE_L,this.parseSelection,TokenKind.BRACE_R)})}parseSelection(){return this.peek(TokenKind.SPREAD)?this.parseFragment():this.parseField()}parseField(){const t=this._lexer.token,i=this.parseName();let n,s;return this.expectOptionalToken(TokenKind.COLON)?(n=i,s=this.parseName()):s=i,this.node(t,{kind:Kind.FIELD,alias:n,name:s,arguments:this.parseArguments(!1),directives:this.parseDirectives(!1),selectionSet:this.peek(TokenKind.BRACE_L)?this.parseSelectionSet():void 0})}parseArguments(t){const i=t?this.parseConstArgument:this.parseArgument;return this.optionalMany(TokenKind.PAREN_L,i,TokenKind.PAREN_R)}parseArgument(t=!1){const i=this._lexer.token,n=this.parseName();return this.expectToken(TokenKind.COLON),this.node(i,{kind:Kind.ARGUMENT,name:n,value:this.parseValueLiteral(t)})}parseConstArgument(){return this.parseArgument(!0)}parseFragment(){const t=this._lexer.token;this.expectToken(TokenKind.SPREAD);const i=this.expectOptionalKeyword("on");return!i&&this.peek(TokenKind.NAME)?this.node(t,{kind:Kind.FRAGMENT_SPREAD,name:this.parseFragmentName(),directives:this.parseDirectives(!1)}):this.node(t,{kind:Kind.INLINE_FRAGMENT,typeCondition:i?this.parseNamedType():void 0,directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentDefinition(){const t=this._lexer.token;return this.expectKeyword("fragment"),this._options.allowLegacyFragmentVariables===!0?this.node(t,{kind:Kind.FRAGMENT_DEFINITION,name:this.parseFragmentName(),variableDefinitions:this.parseVariableDefinitions(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()}):this.node(t,{kind:Kind.FRAGMENT_DEFINITION,name:this.parseFragmentName(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentName(){if(this._lexer.token.value==="on")throw this.unexpected();return this.parseName()}parseValueLiteral(t){const i=this._lexer.token;switch(i.kind){case TokenKind.BRACKET_L:return this.parseList(t);case TokenKind.BRACE_L:return this.parseObject(t);case TokenKind.INT:return this.advanceLexer(),this.node(i,{kind:Kind.INT,value:i.value});case TokenKind.FLOAT:return this.advanceLexer(),this.node(i,{kind:Kind.FLOAT,value:i.value});case TokenKind.STRING:case TokenKind.BLOCK_STRING:return this.parseStringLiteral();case TokenKind.NAME:switch(this.advanceLexer(),i.value){case"true":return this.node(i,{kind:Kind.BOOLEAN,value:!0});case"false":return this.node(i,{kind:Kind.BOOLEAN,value:!1});case"null":return this.node(i,{kind:Kind.NULL});default:return this.node(i,{kind:Kind.ENUM,value:i.value})}case TokenKind.DOLLAR:if(t)if(this.expectToken(TokenKind.DOLLAR),this._lexer.token.kind===TokenKind.NAME){const n=this._lexer.token.value;throw syntaxError(this._lexer.source,i.start,`Unexpected variable "$${n}" in constant value.`)}else throw this.unexpected(i);return this.parseVariable();default:throw this.unexpected()}}parseConstValueLiteral(){return this.parseValueLiteral(!0)}parseStringLiteral(){const t=this._lexer.token;return this.advanceLexer(),this.node(t,{kind:Kind.STRING,value:t.value,block:t.kind===TokenKind.BLOCK_STRING})}parseList(t){const i=()=>this.parseValueLiteral(t);return this.node(this._lexer.token,{kind:Kind.LIST,values:this.any(TokenKind.BRACKET_L,i,TokenKind.BRACKET_R)})}parseObject(t){const i=()=>this.parseObjectField(t);return this.node(this._lexer.token,{kind:Kind.OBJECT,fields:this.any(TokenKind.BRACE_L,i,TokenKind.BRACE_R)})}parseObjectField(t){const i=this._lexer.token,n=this.parseName();return this.expectToken(TokenKind.COLON),this.node(i,{kind:Kind.OBJECT_FIELD,name:n,value:this.parseValueLiteral(t)})}parseDirectives(t){const i=[];for(;this.peek(TokenKind.AT);)i.push(this.parseDirective(t));return i}parseConstDirectives(){return this.parseDirectives(!0)}parseDirective(t){const i=this._lexer.token;return this.expectToken(TokenKind.AT),this.node(i,{kind:Kind.DIRECTIVE,name:this.parseName(),arguments:this.parseArguments(t)})}parseTypeReference(){const t=this._lexer.token;let i;if(this.expectOptionalToken(TokenKind.BRACKET_L)){const n=this.parseTypeReference();this.expectToken(TokenKind.BRACKET_R),i=this.node(t,{kind:Kind.LIST_TYPE,type:n})}else i=this.parseNamedType();return this.expectOptionalToken(TokenKind.BANG)?this.node(t,{kind:Kind.NON_NULL_TYPE,type:i}):i}parseNamedType(){return this.node(this._lexer.token,{kind:Kind.NAMED_TYPE,name:this.parseName()})}peekDescription(){return this.peek(TokenKind.STRING)||this.peek(TokenKind.BLOCK_STRING)}parseDescription(){if(this.peekDescription())return this.parseStringLiteral()}parseSchemaDefinition(){const t=this._lexer.token,i=this.parseDescription();this.expectKeyword("schema");const n=this.parseConstDirectives(),s=this.many(TokenKind.BRACE_L,this.parseOperationTypeDefinition,TokenKind.BRACE_R);return this.node(t,{kind:Kind.SCHEMA_DEFINITION,description:i,directives:n,operationTypes:s})}parseOperationTypeDefinition(){const t=this._lexer.token,i=this.parseOperationType();this.expectToken(TokenKind.COLON);const n=this.parseNamedType();return this.node(t,{kind:Kind.OPERATION_TYPE_DEFINITION,operation:i,type:n})}parseScalarTypeDefinition(){const t=this._lexer.token,i=this.parseDescription();this.expectKeyword("scalar");const n=this.parseName(),s=this.parseConstDirectives();return this.node(t,{kind:Kind.SCALAR_TYPE_DEFINITION,description:i,name:n,directives:s})}parseObjectTypeDefinition(){const t=this._lexer.token,i=this.parseDescription();this.expectKeyword("type");const n=this.parseName(),s=this.parseImplementsInterfaces(),a=this.parseConstDirectives(),h=this.parseFieldsDefinition();return this.node(t,{kind:Kind.OBJECT_TYPE_DEFINITION,description:i,name:n,interfaces:s,directives:a,fields:h})}parseImplementsInterfaces(){return this.expectOptionalKeyword("implements")?this.delimitedMany(TokenKind.AMP,this.parseNamedType):[]}parseFieldsDefinition(){return this.optionalMany(TokenKind.BRACE_L,this.parseFieldDefinition,TokenKind.BRACE_R)}parseFieldDefinition(){const t=this._lexer.token,i=this.parseDescription(),n=this.parseName(),s=this.parseArgumentDefs();this.expectToken(TokenKind.COLON);const a=this.parseTypeReference(),h=this.parseConstDirectives();return this.node(t,{kind:Kind.FIELD_DEFINITION,description:i,name:n,arguments:s,type:a,directives:h})}parseArgumentDefs(){return this.optionalMany(TokenKind.PAREN_L,this.parseInputValueDef,TokenKind.PAREN_R)}parseInputValueDef(){const t=this._lexer.token,i=this.parseDescription(),n=this.parseName();this.expectToken(TokenKind.COLON);const s=this.parseTypeReference();let a;this.expectOptionalToken(TokenKind.EQUALS)&&(a=this.parseConstValueLiteral());const h=this.parseConstDirectives();return this.node(t,{kind:Kind.INPUT_VALUE_DEFINITION,description:i,name:n,type:s,defaultValue:a,directives:h})}parseInterfaceTypeDefinition(){const t=this._lexer.token,i=this.parseDescription();this.expectKeyword("interface");const n=this.parseName(),s=this.parseImplementsInterfaces(),a=this.parseConstDirectives(),h=this.parseFieldsDefinition();return this.node(t,{kind:Kind.INTERFACE_TYPE_DEFINITION,description:i,name:n,interfaces:s,directives:a,fields:h})}parseUnionTypeDefinition(){const t=this._lexer.token,i=this.parseDescription();this.expectKeyword("union");const n=this.parseName(),s=this.parseConstDirectives(),a=this.parseUnionMemberTypes();return this.node(t,{kind:Kind.UNION_TYPE_DEFINITION,description:i,name:n,directives:s,types:a})}parseUnionMemberTypes(){return this.expectOptionalToken(TokenKind.EQUALS)?this.delimitedMany(TokenKind.PIPE,this.parseNamedType):[]}parseEnumTypeDefinition(){const t=this._lexer.token,i=this.parseDescription();this.expectKeyword("enum");const n=this.parseName(),s=this.parseConstDirectives(),a=this.parseEnumValuesDefinition();return this.node(t,{kind:Kind.ENUM_TYPE_DEFINITION,description:i,name:n,directives:s,values:a})}parseEnumValuesDefinition(){return this.optionalMany(TokenKind.BRACE_L,this.parseEnumValueDefinition,TokenKind.BRACE_R)}parseEnumValueDefinition(){const t=this._lexer.token,i=this.parseDescription(),n=this.parseEnumValueName(),s=this.parseConstDirectives();return this.node(t,{kind:Kind.ENUM_VALUE_DEFINITION,description:i,name:n,directives:s})}parseEnumValueName(){if(this._lexer.token.value==="true"||this._lexer.token.value==="false"||this._lexer.token.value==="null")throw syntaxError(this._lexer.source,this._lexer.token.start,`${getTokenDesc(this._lexer.token)} is reserved and cannot be used for an enum value.`);return this.parseName()}parseInputObjectTypeDefinition(){const t=this._lexer.token,i=this.parseDescription();this.expectKeyword("input");const n=this.parseName(),s=this.parseConstDirectives(),a=this.parseInputFieldsDefinition();return this.node(t,{kind:Kind.INPUT_OBJECT_TYPE_DEFINITION,description:i,name:n,directives:s,fields:a})}parseInputFieldsDefinition(){return this.optionalMany(TokenKind.BRACE_L,this.parseInputValueDef,TokenKind.BRACE_R)}parseTypeSystemExtension(){const t=this._lexer.lookahead();if(t.kind===TokenKind.NAME)switch(t.value){case"schema":return this.parseSchemaExtension();case"scalar":return this.parseScalarTypeExtension();case"type":return this.parseObjectTypeExtension();case"interface":return this.parseInterfaceTypeExtension();case"union":return this.parseUnionTypeExtension();case"enum":return this.parseEnumTypeExtension();case"input":return this.parseInputObjectTypeExtension()}throw this.unexpected(t)}parseSchemaExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("schema");const i=this.parseConstDirectives(),n=this.optionalMany(TokenKind.BRACE_L,this.parseOperationTypeDefinition,TokenKind.BRACE_R);if(i.length===0&&n.length===0)throw this.unexpected();return this.node(t,{kind:Kind.SCHEMA_EXTENSION,directives:i,operationTypes:n})}parseScalarTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("scalar");const i=this.parseName(),n=this.parseConstDirectives();if(n.length===0)throw this.unexpected();return this.node(t,{kind:Kind.SCALAR_TYPE_EXTENSION,name:i,directives:n})}parseObjectTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("type");const i=this.parseName(),n=this.parseImplementsInterfaces(),s=this.parseConstDirectives(),a=this.parseFieldsDefinition();if(n.length===0&&s.length===0&&a.length===0)throw this.unexpected();return this.node(t,{kind:Kind.OBJECT_TYPE_EXTENSION,name:i,interfaces:n,directives:s,fields:a})}parseInterfaceTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("interface");const i=this.parseName(),n=this.parseImplementsInterfaces(),s=this.parseConstDirectives(),a=this.parseFieldsDefinition();if(n.length===0&&s.length===0&&a.length===0)throw this.unexpected();return this.node(t,{kind:Kind.INTERFACE_TYPE_EXTENSION,name:i,interfaces:n,directives:s,fields:a})}parseUnionTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("union");const i=this.parseName(),n=this.parseConstDirectives(),s=this.parseUnionMemberTypes();if(n.length===0&&s.length===0)throw this.unexpected();return this.node(t,{kind:Kind.UNION_TYPE_EXTENSION,name:i,directives:n,types:s})}parseEnumTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("enum");const i=this.parseName(),n=this.parseConstDirectives(),s=this.parseEnumValuesDefinition();if(n.length===0&&s.length===0)throw this.unexpected();return this.node(t,{kind:Kind.ENUM_TYPE_EXTENSION,name:i,directives:n,values:s})}parseInputObjectTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("input");const i=this.parseName(),n=this.parseConstDirectives(),s=this.parseInputFieldsDefinition();if(n.length===0&&s.length===0)throw this.unexpected();return this.node(t,{kind:Kind.INPUT_OBJECT_TYPE_EXTENSION,name:i,directives:n,fields:s})}parseDirectiveDefinition(){const t=this._lexer.token,i=this.parseDescription();this.expectKeyword("directive"),this.expectToken(TokenKind.AT);const n=this.parseName(),s=this.parseArgumentDefs(),a=this.expectOptionalKeyword("repeatable");this.expectKeyword("on");const h=this.parseDirectiveLocations();return this.node(t,{kind:Kind.DIRECTIVE_DEFINITION,description:i,name:n,arguments:s,repeatable:a,locations:h})}parseDirectiveLocations(){return this.delimitedMany(TokenKind.PIPE,this.parseDirectiveLocation)}parseDirectiveLocation(){const t=this._lexer.token,i=this.parseName();if(Object.prototype.hasOwnProperty.call(DirectiveLocation,i.value))return i;throw this.unexpected(t)}node(t,i){return this._options.noLocation!==!0&&(i.loc=new Location$1(t,this._lexer.lastToken,this._lexer.source)),i}peek(t){return this._lexer.token.kind===t}expectToken(t){const i=this._lexer.token;if(i.kind===t)return this.advanceLexer(),i;throw syntaxError(this._lexer.source,i.start,`Expected ${getTokenKindDesc(t)}, found ${getTokenDesc(i)}.`)}expectOptionalToken(t){return this._lexer.token.kind===t?(this.advanceLexer(),!0):!1}expectKeyword(t){const i=this._lexer.token;if(i.kind===TokenKind.NAME&&i.value===t)this.advanceLexer();else throw syntaxError(this._lexer.source,i.start,`Expected "${t}", found ${getTokenDesc(i)}.`)}expectOptionalKeyword(t){const i=this._lexer.token;return i.kind===TokenKind.NAME&&i.value===t?(this.advanceLexer(),!0):!1}unexpected(t){const i=t??this._lexer.token;return syntaxError(this._lexer.source,i.start,`Unexpected ${getTokenDesc(i)}.`)}any(t,i,n){this.expectToken(t);const s=[];for(;!this.expectOptionalToken(n);)s.push(i.call(this));return s}optionalMany(t,i,n){if(this.expectOptionalToken(t)){const s=[];do s.push(i.call(this));while(!this.expectOptionalToken(n));return s}return[]}many(t,i,n){this.expectToken(t);const s=[];do s.push(i.call(this));while(!this.expectOptionalToken(n));return s}delimitedMany(t,i){this.expectOptionalToken(t);const n=[];do n.push(i.call(this));while(this.expectOptionalToken(t));return n}advanceLexer(){const{maxTokens:t}=this._options,i=this._lexer.advance();if(t!==void 0&&i.kind!==TokenKind.EOF&&(++this._tokenCounter,this._tokenCounter>t))throw syntaxError(this._lexer.source,i.start,`Document contains more that ${t} tokens. Parsing aborted.`)}}function getTokenDesc(r){const t=r.value;return getTokenKindDesc(r.kind)+(t!=null?` "${t}"`:"")}function getTokenKindDesc(r){return isPunctuatorTokenKind(r)?`"${r}"`:r}const MAX_SUGGESTIONS=5;function didYouMean(r,t){const[i,n]=t?[r,t]:[void 0,r];let s=" Did you mean ";i&&(s+=i+" ");const a=n.map(hi=>`"${hi}"`);switch(a.length){case 0:return"";case 1:return s+a[0]+"?";case 2:return s+a[0]+" or "+a[1]+"?"}const h=a.slice(0,MAX_SUGGESTIONS),v=h.pop();return s+h.join(", ")+", or "+v+"?"}function identityFunc(r){return r}function keyMap(r,t){const i=Object.create(null);for(const n of r)i[t(n)]=n;return i}function keyValMap(r,t,i){const n=Object.create(null);for(const s of r)n[t(s)]=i(s);return n}function mapValue(r,t){const i=Object.create(null);for(const n of Object.keys(r))i[n]=t(r[n],n);return i}function naturalCompare(r,t){let i=0,n=0;for(;i<r.length&&n<t.length;){let s=r.charCodeAt(i),a=t.charCodeAt(n);if(isDigit(s)&&isDigit(a)){let h=0;do++i,h=h*10+s-DIGIT_0,s=r.charCodeAt(i);while(isDigit(s)&&h>0);let v=0;do++n,v=v*10+a-DIGIT_0,a=t.charCodeAt(n);while(isDigit(a)&&v>0);if(h<v)return-1;if(h>v)return 1}else{if(s<a)return-1;if(s>a)return 1;++i,++n}}return r.length-t.length}const DIGIT_0=48,DIGIT_9=57;function isDigit(r){return!isNaN(r)&&DIGIT_0<=r&&r<=DIGIT_9}function suggestionList(r,t){const i=Object.create(null),n=new LexicalDistance(r),s=Math.floor(r.length*.4)+1;for(const a of t){const h=n.measure(a,s);h!==void 0&&(i[a]=h)}return Object.keys(i).sort((a,h)=>{const v=i[a]-i[h];return v!==0?v:naturalCompare(a,h)})}class LexicalDistance{constructor(t){this._input=t,this._inputLowerCase=t.toLowerCase(),this._inputArray=stringToArray(this._inputLowerCase),this._rows=[new Array(t.length+1).fill(0),new Array(t.length+1).fill(0),new Array(t.length+1).fill(0)]}measure(t,i){if(this._input===t)return 0;const n=t.toLowerCase();if(this._inputLowerCase===n)return 1;let s=stringToArray(n),a=this._inputArray;if(s.length<a.length){const l=s;s=a,a=l}const h=s.length,v=a.length;if(h-v>i)return;const hi=this._rows;for(let l=0;l<=v;l++)hi[0][l]=l;for(let l=1;l<=h;l++){const vi=hi[(l-1)%3],D=hi[l%3];let mi=D[0]=l;for(let gi=1;gi<=v;gi++){const bi=s[l-1]===a[gi-1]?0:1;let Ri=Math.min(vi[gi]+1,D[gi-1]+1,vi[gi-1]+bi);if(l>1&&gi>1&&s[l-1]===a[gi-2]&&s[l-2]===a[gi-1]){const Ti=hi[(l-2)%3][gi-2];Ri=Math.min(Ri,Ti+1)}Ri<mi&&(mi=Ri),D[gi]=Ri}if(mi>i)return}const u=hi[h%3][v];return u<=i?u:void 0}}function stringToArray(r){const t=r.length,i=new Array(t);for(let n=0;n<t;++n)i[n]=r.charCodeAt(n);return i}function toObjMap(r){if(r==null)return Object.create(null);if(Object.getPrototypeOf(r)===null)return r;const t=Object.create(null);for(const[i,n]of Object.entries(r))t[i]=n;return t}function printString(r){return`"${r.replace(escapedRegExp,escapedReplacer)}"`}const escapedRegExp=/[\x00-\x1f\x22\x5c\x7f-\x9f]/g;function escapedReplacer(r){return escapeSequences[r.charCodeAt(0)]}const escapeSequences=["\\u0000","\\u0001","\\u0002","\\u0003","\\u0004","\\u0005","\\u0006","\\u0007","\\b","\\t","\\n","\\u000B","\\f","\\r","\\u000E","\\u000F","\\u0010","\\u0011","\\u0012","\\u0013","\\u0014","\\u0015","\\u0016","\\u0017","\\u0018","\\u0019","\\u001A","\\u001B","\\u001C","\\u001D","\\u001E","\\u001F","","",'\\"',"","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\\\","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\u007F","\\u0080","\\u0081","\\u0082","\\u0083","\\u0084","\\u0085","\\u0086","\\u0087","\\u0088","\\u0089","\\u008A","\\u008B","\\u008C","\\u008D","\\u008E","\\u008F","\\u0090","\\u0091","\\u0092","\\u0093","\\u0094","\\u0095","\\u0096","\\u0097","\\u0098","\\u0099","\\u009A","\\u009B","\\u009C","\\u009D","\\u009E","\\u009F"],BREAK=Object.freeze({});function visit(r,t,i=QueryDocumentKeys){const n=new Map;for(const Ti of Object.values(Kind))n.set(Ti,getEnterLeaveForKind(t,Ti));let s,a=Array.isArray(r),h=[r],v=-1,hi=[],u=r,l,vi;const D=[],mi=[];do{v++;const Ti=v===h.length,Ii=Ti&&hi.length!==0;if(Ti){if(l=mi.length===0?void 0:D[D.length-1],u=vi,vi=mi.pop(),Ii)if(a){u=u.slice();let Oi=0;for(const[ki,Li]of hi){const ji=ki-Oi;Li===null?(u.splice(ji,1),Oi++):u[ji]=Li}}else{u=Object.defineProperties({},Object.getOwnPropertyDescriptors(u));for(const[Oi,ki]of hi)u[Oi]=ki}v=s.index,h=s.keys,hi=s.edits,a=s.inArray,s=s.prev}else if(vi){if(l=a?v:h[v],u=vi[l],u==null)continue;D.push(l)}let qi;if(!Array.isArray(u)){var gi,bi;isNode(u)||devAssert(!1,`Invalid AST Node: ${inspect(u)}.`);const Oi=Ti?(gi=n.get(u.kind))===null||gi===void 0?void 0:gi.leave:(bi=n.get(u.kind))===null||bi===void 0?void 0:bi.enter;if(qi=Oi?.call(t,u,l,vi,D,mi),qi===BREAK)break;if(qi===!1){if(!Ti){D.pop();continue}}else if(qi!==void 0&&(hi.push([l,qi]),!Ti))if(isNode(qi))u=qi;else{D.pop();continue}}if(qi===void 0&&Ii&&hi.push([l,u]),Ti)D.pop();else{var Ri;s={inArray:a,index:v,keys:h,edits:hi,prev:s},a=Array.isArray(u),h=a?u:(Ri=i[u.kind])!==null&&Ri!==void 0?Ri:[],v=-1,hi=[],vi&&mi.push(vi),vi=u}}while(s!==void 0);return hi.length!==0?hi[hi.length-1][1]:r}function visitInParallel(r){const t=new Array(r.length).fill(null),i=Object.create(null);for(const n of Object.values(Kind)){let s=!1;const a=new Array(r.length).fill(void 0),h=new Array(r.length).fill(void 0);for(let hi=0;hi<r.length;++hi){const{enter:u,leave:l}=getEnterLeaveForKind(r[hi],n);s||(s=u!=null||l!=null),a[hi]=u,h[hi]=l}if(!s)continue;const v={enter(...hi){const u=hi[0];for(let vi=0;vi<r.length;vi++)if(t[vi]===null){var l;const D=(l=a[vi])===null||l===void 0?void 0:l.apply(r[vi],hi);if(D===!1)t[vi]=u;else if(D===BREAK)t[vi]=BREAK;else if(D!==void 0)return D}},leave(...hi){const u=hi[0];for(let vi=0;vi<r.length;vi++)if(t[vi]===null){var l;const D=(l=h[vi])===null||l===void 0?void 0:l.apply(r[vi],hi);if(D===BREAK)t[vi]=BREAK;else if(D!==void 0&&D!==!1)return D}else t[vi]===u&&(t[vi]=null)}};i[n]=v}return i}function getEnterLeaveForKind(r,t){const i=r[t];return typeof i=="object"?i:typeof i=="function"?{enter:i,leave:void 0}:{enter:r.enter,leave:r.leave}}function getVisitFn(r,t,i){const{enter:n,leave:s}=getEnterLeaveForKind(r,t);return i?s:n}function print(r){return visit(r,printDocASTReducer$1)}const MAX_LINE_LENGTH=80,printDocASTReducer$1={Name:{leave:r=>r.value},Variable:{leave:r=>"$"+r.name},Document:{leave:r=>join$1(r.definitions,`
149
+
150
+ `)},OperationDefinition:{leave(r){const t=wrap$1("(",join$1(r.variableDefinitions,", "),")"),i=join$1([r.operation,join$1([r.name,t]),join$1(r.directives," ")]," ");return(i==="query"?"":i+" ")+r.selectionSet}},VariableDefinition:{leave:({variable:r,type:t,defaultValue:i,directives:n})=>r+": "+t+wrap$1(" = ",i)+wrap$1(" ",join$1(n," "))},SelectionSet:{leave:({selections:r})=>block$1(r)},Field:{leave({alias:r,name:t,arguments:i,directives:n,selectionSet:s}){const a=wrap$1("",r,": ")+t;let h=a+wrap$1("(",join$1(i,", "),")");return h.length>MAX_LINE_LENGTH&&(h=a+wrap$1(`(
151
+ `,indent$1(join$1(i,`
152
+ `)),`
153
+ )`)),join$1([h,join$1(n," "),s]," ")}},Argument:{leave:({name:r,value:t})=>r+": "+t},FragmentSpread:{leave:({name:r,directives:t})=>"..."+r+wrap$1(" ",join$1(t," "))},InlineFragment:{leave:({typeCondition:r,directives:t,selectionSet:i})=>join$1(["...",wrap$1("on ",r),join$1(t," "),i]," ")},FragmentDefinition:{leave:({name:r,typeCondition:t,variableDefinitions:i,directives:n,selectionSet:s})=>`fragment ${r}${wrap$1("(",join$1(i,", "),")")} on ${t} ${wrap$1("",join$1(n," ")," ")}`+s},IntValue:{leave:({value:r})=>r},FloatValue:{leave:({value:r})=>r},StringValue:{leave:({value:r,block:t})=>t?printBlockString(r):printString(r)},BooleanValue:{leave:({value:r})=>r?"true":"false"},NullValue:{leave:()=>"null"},EnumValue:{leave:({value:r})=>r},ListValue:{leave:({values:r})=>"["+join$1(r,", ")+"]"},ObjectValue:{leave:({fields:r})=>"{"+join$1(r,", ")+"}"},ObjectField:{leave:({name:r,value:t})=>r+": "+t},Directive:{leave:({name:r,arguments:t})=>"@"+r+wrap$1("(",join$1(t,", "),")")},NamedType:{leave:({name:r})=>r},ListType:{leave:({type:r})=>"["+r+"]"},NonNullType:{leave:({type:r})=>r+"!"},SchemaDefinition:{leave:({description:r,directives:t,operationTypes:i})=>wrap$1("",r,`
154
+ `)+join$1(["schema",join$1(t," "),block$1(i)]," ")},OperationTypeDefinition:{leave:({operation:r,type:t})=>r+": "+t},ScalarTypeDefinition:{leave:({description:r,name:t,directives:i})=>wrap$1("",r,`
155
+ `)+join$1(["scalar",t,join$1(i," ")]," ")},ObjectTypeDefinition:{leave:({description:r,name:t,interfaces:i,directives:n,fields:s})=>wrap$1("",r,`
156
+ `)+join$1(["type",t,wrap$1("implements ",join$1(i," & ")),join$1(n," "),block$1(s)]," ")},FieldDefinition:{leave:({description:r,name:t,arguments:i,type:n,directives:s})=>wrap$1("",r,`
157
+ `)+t+(hasMultilineItems(i)?wrap$1(`(
158
+ `,indent$1(join$1(i,`
159
+ `)),`
160
+ )`):wrap$1("(",join$1(i,", "),")"))+": "+n+wrap$1(" ",join$1(s," "))},InputValueDefinition:{leave:({description:r,name:t,type:i,defaultValue:n,directives:s})=>wrap$1("",r,`
161
+ `)+join$1([t+": "+i,wrap$1("= ",n),join$1(s," ")]," ")},InterfaceTypeDefinition:{leave:({description:r,name:t,interfaces:i,directives:n,fields:s})=>wrap$1("",r,`
162
+ `)+join$1(["interface",t,wrap$1("implements ",join$1(i," & ")),join$1(n," "),block$1(s)]," ")},UnionTypeDefinition:{leave:({description:r,name:t,directives:i,types:n})=>wrap$1("",r,`
163
+ `)+join$1(["union",t,join$1(i," "),wrap$1("= ",join$1(n," | "))]," ")},EnumTypeDefinition:{leave:({description:r,name:t,directives:i,values:n})=>wrap$1("",r,`
164
+ `)+join$1(["enum",t,join$1(i," "),block$1(n)]," ")},EnumValueDefinition:{leave:({description:r,name:t,directives:i})=>wrap$1("",r,`
165
+ `)+join$1([t,join$1(i," ")]," ")},InputObjectTypeDefinition:{leave:({description:r,name:t,directives:i,fields:n})=>wrap$1("",r,`
166
+ `)+join$1(["input",t,join$1(i," "),block$1(n)]," ")},DirectiveDefinition:{leave:({description:r,name:t,arguments:i,repeatable:n,locations:s})=>wrap$1("",r,`
167
+ `)+"directive @"+t+(hasMultilineItems(i)?wrap$1(`(
168
+ `,indent$1(join$1(i,`
169
+ `)),`
170
+ )`):wrap$1("(",join$1(i,", "),")"))+(n?" repeatable":"")+" on "+join$1(s," | ")},SchemaExtension:{leave:({directives:r,operationTypes:t})=>join$1(["extend schema",join$1(r," "),block$1(t)]," ")},ScalarTypeExtension:{leave:({name:r,directives:t})=>join$1(["extend scalar",r,join$1(t," ")]," ")},ObjectTypeExtension:{leave:({name:r,interfaces:t,directives:i,fields:n})=>join$1(["extend type",r,wrap$1("implements ",join$1(t," & ")),join$1(i," "),block$1(n)]," ")},InterfaceTypeExtension:{leave:({name:r,interfaces:t,directives:i,fields:n})=>join$1(["extend interface",r,wrap$1("implements ",join$1(t," & ")),join$1(i," "),block$1(n)]," ")},UnionTypeExtension:{leave:({name:r,directives:t,types:i})=>join$1(["extend union",r,join$1(t," "),wrap$1("= ",join$1(i," | "))]," ")},EnumTypeExtension:{leave:({name:r,directives:t,values:i})=>join$1(["extend enum",r,join$1(t," "),block$1(i)]," ")},InputObjectTypeExtension:{leave:({name:r,directives:t,fields:i})=>join$1(["extend input",r,join$1(t," "),block$1(i)]," ")}};function join$1(r,t=""){var i;return(i=r?.filter(n=>n).join(t))!==null&&i!==void 0?i:""}function block$1(r){return wrap$1(`{
171
+ `,indent$1(join$1(r,`
172
+ `)),`
173
+ }`)}function wrap$1(r,t,i=""){return t!=null&&t!==""?r+t+i:""}function indent$1(r){return wrap$1(" ",r.replace(/\n/g,`
174
+ `))}function hasMultilineItems(r){var t;return(t=r?.some(i=>i.includes(`
175
+ `)))!==null&&t!==void 0?t:!1}function valueFromASTUntyped(r,t){switch(r.kind){case Kind.NULL:return null;case Kind.INT:return parseInt(r.value,10);case Kind.FLOAT:return parseFloat(r.value);case Kind.STRING:case Kind.ENUM:case Kind.BOOLEAN:return r.value;case Kind.LIST:return r.values.map(i=>valueFromASTUntyped(i,t));case Kind.OBJECT:return keyValMap(r.fields,i=>i.name.value,i=>valueFromASTUntyped(i.value,t));case Kind.VARIABLE:return t?.[r.name.value]}}function assertName(r){if(r!=null||devAssert(!1,"Must provide name."),typeof r=="string"||devAssert(!1,"Expected name to be a string."),r.length===0)throw new GraphQLError("Expected name to be a non-empty string.");for(let t=1;t<r.length;++t)if(!isNameContinue(r.charCodeAt(t)))throw new GraphQLError(`Names must only contain [_a-zA-Z0-9] but "${r}" does not.`);if(!isNameStart(r.charCodeAt(0)))throw new GraphQLError(`Names must start with [_a-zA-Z] but "${r}" does not.`);return r}function assertEnumValueName(r){if(r==="true"||r==="false"||r==="null")throw new GraphQLError(`Enum values cannot be named: ${r}`);return assertName(r)}function isType(r){return isScalarType(r)||isObjectType(r)||isInterfaceType(r)||isUnionType(r)||isEnumType(r)||isInputObjectType(r)||isListType(r)||isNonNullType(r)}function assertType(r){if(!isType(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL type.`);return r}function isScalarType(r){return instanceOf(r,GraphQLScalarType)}function assertScalarType(r){if(!isScalarType(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL Scalar type.`);return r}function isObjectType(r){return instanceOf(r,GraphQLObjectType)}function assertObjectType(r){if(!isObjectType(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL Object type.`);return r}function isInterfaceType(r){return instanceOf(r,GraphQLInterfaceType)}function assertInterfaceType(r){if(!isInterfaceType(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL Interface type.`);return r}function isUnionType(r){return instanceOf(r,GraphQLUnionType)}function assertUnionType(r){if(!isUnionType(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL Union type.`);return r}function isEnumType(r){return instanceOf(r,GraphQLEnumType)}function assertEnumType(r){if(!isEnumType(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL Enum type.`);return r}function isInputObjectType(r){return instanceOf(r,GraphQLInputObjectType)}function assertInputObjectType(r){if(!isInputObjectType(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL Input Object type.`);return r}function isListType(r){return instanceOf(r,GraphQLList)}function assertListType(r){if(!isListType(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL List type.`);return r}function isNonNullType(r){return instanceOf(r,GraphQLNonNull)}function assertNonNullType(r){if(!isNonNullType(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL Non-Null type.`);return r}function isInputType(r){return isScalarType(r)||isEnumType(r)||isInputObjectType(r)||isWrappingType(r)&&isInputType(r.ofType)}function assertInputType(r){if(!isInputType(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL input type.`);return r}function isOutputType(r){return isScalarType(r)||isObjectType(r)||isInterfaceType(r)||isUnionType(r)||isEnumType(r)||isWrappingType(r)&&isOutputType(r.ofType)}function assertOutputType(r){if(!isOutputType(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL output type.`);return r}function isLeafType(r){return isScalarType(r)||isEnumType(r)}function assertLeafType(r){if(!isLeafType(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL leaf type.`);return r}function isCompositeType(r){return isObjectType(r)||isInterfaceType(r)||isUnionType(r)}function assertCompositeType(r){if(!isCompositeType(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL composite type.`);return r}function isAbstractType(r){return isInterfaceType(r)||isUnionType(r)}function assertAbstractType(r){if(!isAbstractType(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL abstract type.`);return r}class GraphQLList{constructor(t){isType(t)||devAssert(!1,`Expected ${inspect(t)} to be a GraphQL type.`),this.ofType=t}get[Symbol.toStringTag](){return"GraphQLList"}toString(){return"["+String(this.ofType)+"]"}toJSON(){return this.toString()}}class GraphQLNonNull{constructor(t){isNullableType(t)||devAssert(!1,`Expected ${inspect(t)} to be a GraphQL nullable type.`),this.ofType=t}get[Symbol.toStringTag](){return"GraphQLNonNull"}toString(){return String(this.ofType)+"!"}toJSON(){return this.toString()}}function isWrappingType(r){return isListType(r)||isNonNullType(r)}function assertWrappingType(r){if(!isWrappingType(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL wrapping type.`);return r}function isNullableType(r){return isType(r)&&!isNonNullType(r)}function assertNullableType(r){if(!isNullableType(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL nullable type.`);return r}function getNullableType(r){if(r)return isNonNullType(r)?r.ofType:r}function isNamedType(r){return isScalarType(r)||isObjectType(r)||isInterfaceType(r)||isUnionType(r)||isEnumType(r)||isInputObjectType(r)}function assertNamedType(r){if(!isNamedType(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL named type.`);return r}function getNamedType(r){if(r){let t=r;for(;isWrappingType(t);)t=t.ofType;return t}}function resolveReadonlyArrayThunk(r){return typeof r=="function"?r():r}function resolveObjMapThunk(r){return typeof r=="function"?r():r}class GraphQLScalarType{constructor(t){var i,n,s,a;const h=(i=t.parseValue)!==null&&i!==void 0?i:identityFunc;this.name=assertName(t.name),this.description=t.description,this.specifiedByURL=t.specifiedByURL,this.serialize=(n=t.serialize)!==null&&n!==void 0?n:identityFunc,this.parseValue=h,this.parseLiteral=(s=t.parseLiteral)!==null&&s!==void 0?s:(v,hi)=>h(valueFromASTUntyped(v,hi)),this.extensions=toObjMap(t.extensions),this.astNode=t.astNode,this.extensionASTNodes=(a=t.extensionASTNodes)!==null&&a!==void 0?a:[],t.specifiedByURL==null||typeof t.specifiedByURL=="string"||devAssert(!1,`${this.name} must provide "specifiedByURL" as a string, but got: ${inspect(t.specifiedByURL)}.`),t.serialize==null||typeof t.serialize=="function"||devAssert(!1,`${this.name} must provide "serialize" function. If this custom Scalar is also used as an input type, ensure "parseValue" and "parseLiteral" functions are also provided.`),t.parseLiteral&&(typeof t.parseValue=="function"&&typeof t.parseLiteral=="function"||devAssert(!1,`${this.name} must provide both "parseValue" and "parseLiteral" functions.`))}get[Symbol.toStringTag](){return"GraphQLScalarType"}toConfig(){return{name:this.name,description:this.description,specifiedByURL:this.specifiedByURL,serialize:this.serialize,parseValue:this.parseValue,parseLiteral:this.parseLiteral,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}class GraphQLObjectType{constructor(t){var i;this.name=assertName(t.name),this.description=t.description,this.isTypeOf=t.isTypeOf,this.extensions=toObjMap(t.extensions),this.astNode=t.astNode,this.extensionASTNodes=(i=t.extensionASTNodes)!==null&&i!==void 0?i:[],this._fields=()=>defineFieldMap(t),this._interfaces=()=>defineInterfaces(t),t.isTypeOf==null||typeof t.isTypeOf=="function"||devAssert(!1,`${this.name} must provide "isTypeOf" as a function, but got: ${inspect(t.isTypeOf)}.`)}get[Symbol.toStringTag](){return"GraphQLObjectType"}getFields(){return typeof this._fields=="function"&&(this._fields=this._fields()),this._fields}getInterfaces(){return typeof this._interfaces=="function"&&(this._interfaces=this._interfaces()),this._interfaces}toConfig(){return{name:this.name,description:this.description,interfaces:this.getInterfaces(),fields:fieldsToFieldsConfig(this.getFields()),isTypeOf:this.isTypeOf,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}function defineInterfaces(r){var t;const i=resolveReadonlyArrayThunk((t=r.interfaces)!==null&&t!==void 0?t:[]);return Array.isArray(i)||devAssert(!1,`${r.name} interfaces must be an Array or a function which returns an Array.`),i}function defineFieldMap(r){const t=resolveObjMapThunk(r.fields);return isPlainObj(t)||devAssert(!1,`${r.name} fields must be an object with field names as keys or a function which returns such an object.`),mapValue(t,(i,n)=>{var s;isPlainObj(i)||devAssert(!1,`${r.name}.${n} field config must be an object.`),i.resolve==null||typeof i.resolve=="function"||devAssert(!1,`${r.name}.${n} field resolver must be a function if provided, but got: ${inspect(i.resolve)}.`);const a=(s=i.args)!==null&&s!==void 0?s:{};return isPlainObj(a)||devAssert(!1,`${r.name}.${n} args must be an object with argument names as keys.`),{name:assertName(n),description:i.description,type:i.type,args:defineArguments(a),resolve:i.resolve,subscribe:i.subscribe,deprecationReason:i.deprecationReason,extensions:toObjMap(i.extensions),astNode:i.astNode}})}function defineArguments(r){return Object.entries(r).map(([t,i])=>({name:assertName(t),description:i.description,type:i.type,defaultValue:i.defaultValue,deprecationReason:i.deprecationReason,extensions:toObjMap(i.extensions),astNode:i.astNode}))}function isPlainObj(r){return isObjectLike(r)&&!Array.isArray(r)}function fieldsToFieldsConfig(r){return mapValue(r,t=>({description:t.description,type:t.type,args:argsToArgsConfig(t.args),resolve:t.resolve,subscribe:t.subscribe,deprecationReason:t.deprecationReason,extensions:t.extensions,astNode:t.astNode}))}function argsToArgsConfig(r){return keyValMap(r,t=>t.name,t=>({description:t.description,type:t.type,defaultValue:t.defaultValue,deprecationReason:t.deprecationReason,extensions:t.extensions,astNode:t.astNode}))}function isRequiredArgument(r){return isNonNullType(r.type)&&r.defaultValue===void 0}class GraphQLInterfaceType{constructor(t){var i;this.name=assertName(t.name),this.description=t.description,this.resolveType=t.resolveType,this.extensions=toObjMap(t.extensions),this.astNode=t.astNode,this.extensionASTNodes=(i=t.extensionASTNodes)!==null&&i!==void 0?i:[],this._fields=defineFieldMap.bind(void 0,t),this._interfaces=defineInterfaces.bind(void 0,t),t.resolveType==null||typeof t.resolveType=="function"||devAssert(!1,`${this.name} must provide "resolveType" as a function, but got: ${inspect(t.resolveType)}.`)}get[Symbol.toStringTag](){return"GraphQLInterfaceType"}getFields(){return typeof this._fields=="function"&&(this._fields=this._fields()),this._fields}getInterfaces(){return typeof this._interfaces=="function"&&(this._interfaces=this._interfaces()),this._interfaces}toConfig(){return{name:this.name,description:this.description,interfaces:this.getInterfaces(),fields:fieldsToFieldsConfig(this.getFields()),resolveType:this.resolveType,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}class GraphQLUnionType{constructor(t){var i;this.name=assertName(t.name),this.description=t.description,this.resolveType=t.resolveType,this.extensions=toObjMap(t.extensions),this.astNode=t.astNode,this.extensionASTNodes=(i=t.extensionASTNodes)!==null&&i!==void 0?i:[],this._types=defineTypes.bind(void 0,t),t.resolveType==null||typeof t.resolveType=="function"||devAssert(!1,`${this.name} must provide "resolveType" as a function, but got: ${inspect(t.resolveType)}.`)}get[Symbol.toStringTag](){return"GraphQLUnionType"}getTypes(){return typeof this._types=="function"&&(this._types=this._types()),this._types}toConfig(){return{name:this.name,description:this.description,types:this.getTypes(),resolveType:this.resolveType,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}function defineTypes(r){const t=resolveReadonlyArrayThunk(r.types);return Array.isArray(t)||devAssert(!1,`Must provide Array of types or a function which returns such an array for Union ${r.name}.`),t}class GraphQLEnumType{constructor(t){var i;this.name=assertName(t.name),this.description=t.description,this.extensions=toObjMap(t.extensions),this.astNode=t.astNode,this.extensionASTNodes=(i=t.extensionASTNodes)!==null&&i!==void 0?i:[],this._values=typeof t.values=="function"?t.values:defineEnumValues(this.name,t.values),this._valueLookup=null,this._nameLookup=null}get[Symbol.toStringTag](){return"GraphQLEnumType"}getValues(){return typeof this._values=="function"&&(this._values=defineEnumValues(this.name,this._values())),this._values}getValue(t){return this._nameLookup===null&&(this._nameLookup=keyMap(this.getValues(),i=>i.name)),this._nameLookup[t]}serialize(t){this._valueLookup===null&&(this._valueLookup=new Map(this.getValues().map(n=>[n.value,n])));const i=this._valueLookup.get(t);if(i===void 0)throw new GraphQLError(`Enum "${this.name}" cannot represent value: ${inspect(t)}`);return i.name}parseValue(t){if(typeof t!="string"){const n=inspect(t);throw new GraphQLError(`Enum "${this.name}" cannot represent non-string value: ${n}.`+didYouMeanEnumValue(this,n))}const i=this.getValue(t);if(i==null)throw new GraphQLError(`Value "${t}" does not exist in "${this.name}" enum.`+didYouMeanEnumValue(this,t));return i.value}parseLiteral(t,i){if(t.kind!==Kind.ENUM){const s=print(t);throw new GraphQLError(`Enum "${this.name}" cannot represent non-enum value: ${s}.`+didYouMeanEnumValue(this,s),{nodes:t})}const n=this.getValue(t.value);if(n==null){const s=print(t);throw new GraphQLError(`Value "${s}" does not exist in "${this.name}" enum.`+didYouMeanEnumValue(this,s),{nodes:t})}return n.value}toConfig(){const t=keyValMap(this.getValues(),i=>i.name,i=>({description:i.description,value:i.value,deprecationReason:i.deprecationReason,extensions:i.extensions,astNode:i.astNode}));return{name:this.name,description:this.description,values:t,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes}}toString(){return this.name}toJSON(){return this.toString()}}function didYouMeanEnumValue(r,t){const i=r.getValues().map(s=>s.name),n=suggestionList(t,i);return didYouMean("the enum value",n)}function defineEnumValues(r,t){return isPlainObj(t)||devAssert(!1,`${r} values must be an object with value names as keys.`),Object.entries(t).map(([i,n])=>(isPlainObj(n)||devAssert(!1,`${r}.${i} must refer to an object with a "value" key representing an internal value but got: ${inspect(n)}.`),{name:assertEnumValueName(i),description:n.description,value:n.value!==void 0?n.value:i,deprecationReason:n.deprecationReason,extensions:toObjMap(n.extensions),astNode:n.astNode}))}class GraphQLInputObjectType{constructor(t){var i,n;this.name=assertName(t.name),this.description=t.description,this.extensions=toObjMap(t.extensions),this.astNode=t.astNode,this.extensionASTNodes=(i=t.extensionASTNodes)!==null&&i!==void 0?i:[],this.isOneOf=(n=t.isOneOf)!==null&&n!==void 0?n:!1,this._fields=defineInputFieldMap.bind(void 0,t)}get[Symbol.toStringTag](){return"GraphQLInputObjectType"}getFields(){return typeof this._fields=="function"&&(this._fields=this._fields()),this._fields}toConfig(){const t=mapValue(this.getFields(),i=>({description:i.description,type:i.type,defaultValue:i.defaultValue,deprecationReason:i.deprecationReason,extensions:i.extensions,astNode:i.astNode}));return{name:this.name,description:this.description,fields:t,extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes,isOneOf:this.isOneOf}}toString(){return this.name}toJSON(){return this.toString()}}function defineInputFieldMap(r){const t=resolveObjMapThunk(r.fields);return isPlainObj(t)||devAssert(!1,`${r.name} fields must be an object with field names as keys or a function which returns such an object.`),mapValue(t,(i,n)=>(!("resolve"in i)||devAssert(!1,`${r.name}.${n} field has a resolve property, but Input Types cannot define resolvers.`),{name:assertName(n),description:i.description,type:i.type,defaultValue:i.defaultValue,deprecationReason:i.deprecationReason,extensions:toObjMap(i.extensions),astNode:i.astNode}))}function isRequiredInputField(r){return isNonNullType(r.type)&&r.defaultValue===void 0}function isEqualType(r,t){return r===t?!0:isNonNullType(r)&&isNonNullType(t)||isListType(r)&&isListType(t)?isEqualType(r.ofType,t.ofType):!1}function isTypeSubTypeOf(r,t,i){return t===i?!0:isNonNullType(i)?isNonNullType(t)?isTypeSubTypeOf(r,t.ofType,i.ofType):!1:isNonNullType(t)?isTypeSubTypeOf(r,t.ofType,i):isListType(i)?isListType(t)?isTypeSubTypeOf(r,t.ofType,i.ofType):!1:isListType(t)?!1:isAbstractType(i)&&(isInterfaceType(t)||isObjectType(t))&&r.isSubType(i,t)}function doTypesOverlap(r,t,i){return t===i?!0:isAbstractType(t)?isAbstractType(i)?r.getPossibleTypes(t).some(n=>r.isSubType(i,n)):r.isSubType(t,i):isAbstractType(i)?r.isSubType(i,t):!1}const GRAPHQL_MAX_INT=2147483647,GRAPHQL_MIN_INT=-2147483648,GraphQLInt=new GraphQLScalarType({name:"Int",description:"The `Int` scalar type represents non-fractional signed whole numeric values. Int can represent values between -(2^31) and 2^31 - 1.",serialize(r){const t=serializeObject(r);if(typeof t=="boolean")return t?1:0;let i=t;if(typeof t=="string"&&t!==""&&(i=Number(t)),typeof i!="number"||!Number.isInteger(i))throw new GraphQLError(`Int cannot represent non-integer value: ${inspect(t)}`);if(i>GRAPHQL_MAX_INT||i<GRAPHQL_MIN_INT)throw new GraphQLError("Int cannot represent non 32-bit signed integer value: "+inspect(t));return i},parseValue(r){if(typeof r!="number"||!Number.isInteger(r))throw new GraphQLError(`Int cannot represent non-integer value: ${inspect(r)}`);if(r>GRAPHQL_MAX_INT||r<GRAPHQL_MIN_INT)throw new GraphQLError(`Int cannot represent non 32-bit signed integer value: ${r}`);return r},parseLiteral(r){if(r.kind!==Kind.INT)throw new GraphQLError(`Int cannot represent non-integer value: ${print(r)}`,{nodes:r});const t=parseInt(r.value,10);if(t>GRAPHQL_MAX_INT||t<GRAPHQL_MIN_INT)throw new GraphQLError(`Int cannot represent non 32-bit signed integer value: ${r.value}`,{nodes:r});return t}}),GraphQLFloat=new GraphQLScalarType({name:"Float",description:"The `Float` scalar type represents signed double-precision fractional values as specified by [IEEE 754](https://en.wikipedia.org/wiki/IEEE_floating_point).",serialize(r){const t=serializeObject(r);if(typeof t=="boolean")return t?1:0;let i=t;if(typeof t=="string"&&t!==""&&(i=Number(t)),typeof i!="number"||!Number.isFinite(i))throw new GraphQLError(`Float cannot represent non numeric value: ${inspect(t)}`);return i},parseValue(r){if(typeof r!="number"||!Number.isFinite(r))throw new GraphQLError(`Float cannot represent non numeric value: ${inspect(r)}`);return r},parseLiteral(r){if(r.kind!==Kind.FLOAT&&r.kind!==Kind.INT)throw new GraphQLError(`Float cannot represent non numeric value: ${print(r)}`,r);return parseFloat(r.value)}}),GraphQLString=new GraphQLScalarType({name:"String",description:"The `String` scalar type represents textual data, represented as UTF-8 character sequences. The String type is most often used by GraphQL to represent free-form human-readable text.",serialize(r){const t=serializeObject(r);if(typeof t=="string")return t;if(typeof t=="boolean")return t?"true":"false";if(typeof t=="number"&&Number.isFinite(t))return t.toString();throw new GraphQLError(`String cannot represent value: ${inspect(r)}`)},parseValue(r){if(typeof r!="string")throw new GraphQLError(`String cannot represent a non string value: ${inspect(r)}`);return r},parseLiteral(r){if(r.kind!==Kind.STRING)throw new GraphQLError(`String cannot represent a non string value: ${print(r)}`,{nodes:r});return r.value}}),GraphQLBoolean=new GraphQLScalarType({name:"Boolean",description:"The `Boolean` scalar type represents `true` or `false`.",serialize(r){const t=serializeObject(r);if(typeof t=="boolean")return t;if(Number.isFinite(t))return t!==0;throw new GraphQLError(`Boolean cannot represent a non boolean value: ${inspect(t)}`)},parseValue(r){if(typeof r!="boolean")throw new GraphQLError(`Boolean cannot represent a non boolean value: ${inspect(r)}`);return r},parseLiteral(r){if(r.kind!==Kind.BOOLEAN)throw new GraphQLError(`Boolean cannot represent a non boolean value: ${print(r)}`,{nodes:r});return r.value}}),GraphQLID=new GraphQLScalarType({name:"ID",description:'The `ID` scalar type represents a unique identifier, often used to refetch an object or as key for a cache. The ID type appears in a JSON response as a String; however, it is not intended to be human-readable. When expected as an input type, any string (such as `"4"`) or integer (such as `4`) input value will be accepted as an ID.',serialize(r){const t=serializeObject(r);if(typeof t=="string")return t;if(Number.isInteger(t))return String(t);throw new GraphQLError(`ID cannot represent value: ${inspect(r)}`)},parseValue(r){if(typeof r=="string")return r;if(typeof r=="number"&&Number.isInteger(r))return r.toString();throw new GraphQLError(`ID cannot represent value: ${inspect(r)}`)},parseLiteral(r){if(r.kind!==Kind.STRING&&r.kind!==Kind.INT)throw new GraphQLError("ID cannot represent a non-string and non-integer value: "+print(r),{nodes:r});return r.value}}),specifiedScalarTypes=Object.freeze([GraphQLString,GraphQLInt,GraphQLFloat,GraphQLBoolean,GraphQLID]);function isSpecifiedScalarType(r){return specifiedScalarTypes.some(({name:t})=>r.name===t)}function serializeObject(r){if(isObjectLike(r)){if(typeof r.valueOf=="function"){const t=r.valueOf();if(!isObjectLike(t))return t}if(typeof r.toJSON=="function")return r.toJSON()}return r}function isDirective(r){return instanceOf(r,GraphQLDirective)}function assertDirective(r){if(!isDirective(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL directive.`);return r}class GraphQLDirective{constructor(t){var i,n;this.name=assertName(t.name),this.description=t.description,this.locations=t.locations,this.isRepeatable=(i=t.isRepeatable)!==null&&i!==void 0?i:!1,this.extensions=toObjMap(t.extensions),this.astNode=t.astNode,Array.isArray(t.locations)||devAssert(!1,`@${t.name} locations must be an Array.`);const s=(n=t.args)!==null&&n!==void 0?n:{};isObjectLike(s)&&!Array.isArray(s)||devAssert(!1,`@${t.name} args must be an object with argument names as keys.`),this.args=defineArguments(s)}get[Symbol.toStringTag](){return"GraphQLDirective"}toConfig(){return{name:this.name,description:this.description,locations:this.locations,args:argsToArgsConfig(this.args),isRepeatable:this.isRepeatable,extensions:this.extensions,astNode:this.astNode}}toString(){return"@"+this.name}toJSON(){return this.toString()}}const GraphQLIncludeDirective=new GraphQLDirective({name:"include",description:"Directs the executor to include this field or fragment only when the `if` argument is true.",locations:[DirectiveLocation.FIELD,DirectiveLocation.FRAGMENT_SPREAD,DirectiveLocation.INLINE_FRAGMENT],args:{if:{type:new GraphQLNonNull(GraphQLBoolean),description:"Included when true."}}}),GraphQLSkipDirective=new GraphQLDirective({name:"skip",description:"Directs the executor to skip this field or fragment when the `if` argument is true.",locations:[DirectiveLocation.FIELD,DirectiveLocation.FRAGMENT_SPREAD,DirectiveLocation.INLINE_FRAGMENT],args:{if:{type:new GraphQLNonNull(GraphQLBoolean),description:"Skipped when true."}}}),DEFAULT_DEPRECATION_REASON="No longer supported",GraphQLDeprecatedDirective=new GraphQLDirective({name:"deprecated",description:"Marks an element of a GraphQL schema as no longer supported.",locations:[DirectiveLocation.FIELD_DEFINITION,DirectiveLocation.ARGUMENT_DEFINITION,DirectiveLocation.INPUT_FIELD_DEFINITION,DirectiveLocation.ENUM_VALUE],args:{reason:{type:GraphQLString,description:"Explains why this element was deprecated, usually also including a suggestion for how to access supported similar data. Formatted using the Markdown syntax, as specified by [CommonMark](https://commonmark.org/).",defaultValue:DEFAULT_DEPRECATION_REASON}}}),GraphQLSpecifiedByDirective=new GraphQLDirective({name:"specifiedBy",description:"Exposes a URL that specifies the behavior of this scalar.",locations:[DirectiveLocation.SCALAR],args:{url:{type:new GraphQLNonNull(GraphQLString),description:"The URL that specifies the behavior of this scalar."}}}),GraphQLOneOfDirective=new GraphQLDirective({name:"oneOf",description:"Indicates exactly one field must be supplied and this field must not be `null`.",locations:[DirectiveLocation.INPUT_OBJECT],args:{}}),specifiedDirectives=Object.freeze([GraphQLIncludeDirective,GraphQLSkipDirective,GraphQLDeprecatedDirective,GraphQLSpecifiedByDirective,GraphQLOneOfDirective]);function isSpecifiedDirective(r){return specifiedDirectives.some(({name:t})=>t===r.name)}function isIterableObject(r){return typeof r=="object"&&typeof r?.[Symbol.iterator]=="function"}function astFromValue(r,t){if(isNonNullType(t)){const i=astFromValue(r,t.ofType);return i?.kind===Kind.NULL?null:i}if(r===null)return{kind:Kind.NULL};if(r===void 0)return null;if(isListType(t)){const i=t.ofType;if(isIterableObject(r)){const n=[];for(const s of r){const a=astFromValue(s,i);a!=null&&n.push(a)}return{kind:Kind.LIST,values:n}}return astFromValue(r,i)}if(isInputObjectType(t)){if(!isObjectLike(r))return null;const i=[];for(const n of Object.values(t.getFields())){const s=astFromValue(r[n.name],n.type);s&&i.push({kind:Kind.OBJECT_FIELD,name:{kind:Kind.NAME,value:n.name},value:s})}return{kind:Kind.OBJECT,fields:i}}if(isLeafType(t)){const i=t.serialize(r);if(i==null)return null;if(typeof i=="boolean")return{kind:Kind.BOOLEAN,value:i};if(typeof i=="number"&&Number.isFinite(i)){const n=String(i);return integerStringRegExp.test(n)?{kind:Kind.INT,value:n}:{kind:Kind.FLOAT,value:n}}if(typeof i=="string")return isEnumType(t)?{kind:Kind.ENUM,value:i}:t===GraphQLID&&integerStringRegExp.test(i)?{kind:Kind.INT,value:i}:{kind:Kind.STRING,value:i};throw new TypeError(`Cannot convert value to AST: ${inspect(i)}.`)}invariant(!1,"Unexpected input type: "+inspect(t))}const integerStringRegExp=/^-?(?:0|[1-9][0-9]*)$/,__Schema=new GraphQLObjectType({name:"__Schema",description:"A GraphQL Schema defines the capabilities of a GraphQL server. It exposes all available types and directives on the server, as well as the entry points for query, mutation, and subscription operations.",fields:()=>({description:{type:GraphQLString,resolve:r=>r.description},types:{description:"A list of all types supported by this server.",type:new GraphQLNonNull(new GraphQLList(new GraphQLNonNull(__Type))),resolve(r){return Object.values(r.getTypeMap())}},queryType:{description:"The type that query operations will be rooted at.",type:new GraphQLNonNull(__Type),resolve:r=>r.getQueryType()},mutationType:{description:"If this server supports mutation, the type that mutation operations will be rooted at.",type:__Type,resolve:r=>r.getMutationType()},subscriptionType:{description:"If this server support subscription, the type that subscription operations will be rooted at.",type:__Type,resolve:r=>r.getSubscriptionType()},directives:{description:"A list of all directives supported by this server.",type:new GraphQLNonNull(new GraphQLList(new GraphQLNonNull(__Directive))),resolve:r=>r.getDirectives()}})}),__Directive=new GraphQLObjectType({name:"__Directive",description:`A Directive provides a way to describe alternate runtime execution and type validation behavior in a GraphQL document.
176
+
177
+ In some cases, you need to provide options to alter GraphQL's execution behavior in ways field arguments will not suffice, such as conditionally including or skipping a field. Directives provide this by describing additional information to the executor.`,fields:()=>({name:{type:new GraphQLNonNull(GraphQLString),resolve:r=>r.name},description:{type:GraphQLString,resolve:r=>r.description},isRepeatable:{type:new GraphQLNonNull(GraphQLBoolean),resolve:r=>r.isRepeatable},locations:{type:new GraphQLNonNull(new GraphQLList(new GraphQLNonNull(__DirectiveLocation))),resolve:r=>r.locations},args:{type:new GraphQLNonNull(new GraphQLList(new GraphQLNonNull(__InputValue))),args:{includeDeprecated:{type:GraphQLBoolean,defaultValue:!1}},resolve(r,{includeDeprecated:t}){return t?r.args:r.args.filter(i=>i.deprecationReason==null)}}})}),__DirectiveLocation=new GraphQLEnumType({name:"__DirectiveLocation",description:"A Directive can be adjacent to many parts of the GraphQL language, a __DirectiveLocation describes one such possible adjacencies.",values:{QUERY:{value:DirectiveLocation.QUERY,description:"Location adjacent to a query operation."},MUTATION:{value:DirectiveLocation.MUTATION,description:"Location adjacent to a mutation operation."},SUBSCRIPTION:{value:DirectiveLocation.SUBSCRIPTION,description:"Location adjacent to a subscription operation."},FIELD:{value:DirectiveLocation.FIELD,description:"Location adjacent to a field."},FRAGMENT_DEFINITION:{value:DirectiveLocation.FRAGMENT_DEFINITION,description:"Location adjacent to a fragment definition."},FRAGMENT_SPREAD:{value:DirectiveLocation.FRAGMENT_SPREAD,description:"Location adjacent to a fragment spread."},INLINE_FRAGMENT:{value:DirectiveLocation.INLINE_FRAGMENT,description:"Location adjacent to an inline fragment."},VARIABLE_DEFINITION:{value:DirectiveLocation.VARIABLE_DEFINITION,description:"Location adjacent to a variable definition."},SCHEMA:{value:DirectiveLocation.SCHEMA,description:"Location adjacent to a schema definition."},SCALAR:{value:DirectiveLocation.SCALAR,description:"Location adjacent to a scalar definition."},OBJECT:{value:DirectiveLocation.OBJECT,description:"Location adjacent to an object type definition."},FIELD_DEFINITION:{value:DirectiveLocation.FIELD_DEFINITION,description:"Location adjacent to a field definition."},ARGUMENT_DEFINITION:{value:DirectiveLocation.ARGUMENT_DEFINITION,description:"Location adjacent to an argument definition."},INTERFACE:{value:DirectiveLocation.INTERFACE,description:"Location adjacent to an interface definition."},UNION:{value:DirectiveLocation.UNION,description:"Location adjacent to a union definition."},ENUM:{value:DirectiveLocation.ENUM,description:"Location adjacent to an enum definition."},ENUM_VALUE:{value:DirectiveLocation.ENUM_VALUE,description:"Location adjacent to an enum value definition."},INPUT_OBJECT:{value:DirectiveLocation.INPUT_OBJECT,description:"Location adjacent to an input object type definition."},INPUT_FIELD_DEFINITION:{value:DirectiveLocation.INPUT_FIELD_DEFINITION,description:"Location adjacent to an input object field definition."}}}),__Type=new GraphQLObjectType({name:"__Type",description:"The fundamental unit of any GraphQL Schema is the type. There are many kinds of types in GraphQL as represented by the `__TypeKind` enum.\n\nDepending on the kind of a type, certain fields describe information about that type. Scalar types provide no information beyond a name, description and optional `specifiedByURL`, while Enum types provide their values. Object and Interface types provide the fields they describe. Abstract types, Union and Interface, provide the Object types possible at runtime. List and NonNull types compose other types.",fields:()=>({kind:{type:new GraphQLNonNull(__TypeKind),resolve(r){if(isScalarType(r))return TypeKind.SCALAR;if(isObjectType(r))return TypeKind.OBJECT;if(isInterfaceType(r))return TypeKind.INTERFACE;if(isUnionType(r))return TypeKind.UNION;if(isEnumType(r))return TypeKind.ENUM;if(isInputObjectType(r))return TypeKind.INPUT_OBJECT;if(isListType(r))return TypeKind.LIST;if(isNonNullType(r))return TypeKind.NON_NULL;invariant(!1,`Unexpected type: "${inspect(r)}".`)}},name:{type:GraphQLString,resolve:r=>"name"in r?r.name:void 0},description:{type:GraphQLString,resolve:r=>"description"in r?r.description:void 0},specifiedByURL:{type:GraphQLString,resolve:r=>"specifiedByURL"in r?r.specifiedByURL:void 0},fields:{type:new GraphQLList(new GraphQLNonNull(__Field)),args:{includeDeprecated:{type:GraphQLBoolean,defaultValue:!1}},resolve(r,{includeDeprecated:t}){if(isObjectType(r)||isInterfaceType(r)){const i=Object.values(r.getFields());return t?i:i.filter(n=>n.deprecationReason==null)}}},interfaces:{type:new GraphQLList(new GraphQLNonNull(__Type)),resolve(r){if(isObjectType(r)||isInterfaceType(r))return r.getInterfaces()}},possibleTypes:{type:new GraphQLList(new GraphQLNonNull(__Type)),resolve(r,t,i,{schema:n}){if(isAbstractType(r))return n.getPossibleTypes(r)}},enumValues:{type:new GraphQLList(new GraphQLNonNull(__EnumValue)),args:{includeDeprecated:{type:GraphQLBoolean,defaultValue:!1}},resolve(r,{includeDeprecated:t}){if(isEnumType(r)){const i=r.getValues();return t?i:i.filter(n=>n.deprecationReason==null)}}},inputFields:{type:new GraphQLList(new GraphQLNonNull(__InputValue)),args:{includeDeprecated:{type:GraphQLBoolean,defaultValue:!1}},resolve(r,{includeDeprecated:t}){if(isInputObjectType(r)){const i=Object.values(r.getFields());return t?i:i.filter(n=>n.deprecationReason==null)}}},ofType:{type:__Type,resolve:r=>"ofType"in r?r.ofType:void 0},isOneOf:{type:GraphQLBoolean,resolve:r=>{if(isInputObjectType(r))return r.isOneOf}}})}),__Field=new GraphQLObjectType({name:"__Field",description:"Object and Interface types are described by a list of Fields, each of which has a name, potentially a list of arguments, and a return type.",fields:()=>({name:{type:new GraphQLNonNull(GraphQLString),resolve:r=>r.name},description:{type:GraphQLString,resolve:r=>r.description},args:{type:new GraphQLNonNull(new GraphQLList(new GraphQLNonNull(__InputValue))),args:{includeDeprecated:{type:GraphQLBoolean,defaultValue:!1}},resolve(r,{includeDeprecated:t}){return t?r.args:r.args.filter(i=>i.deprecationReason==null)}},type:{type:new GraphQLNonNull(__Type),resolve:r=>r.type},isDeprecated:{type:new GraphQLNonNull(GraphQLBoolean),resolve:r=>r.deprecationReason!=null},deprecationReason:{type:GraphQLString,resolve:r=>r.deprecationReason}})}),__InputValue=new GraphQLObjectType({name:"__InputValue",description:"Arguments provided to Fields or Directives and the input fields of an InputObject are represented as Input Values which describe their type and optionally a default value.",fields:()=>({name:{type:new GraphQLNonNull(GraphQLString),resolve:r=>r.name},description:{type:GraphQLString,resolve:r=>r.description},type:{type:new GraphQLNonNull(__Type),resolve:r=>r.type},defaultValue:{type:GraphQLString,description:"A GraphQL-formatted string representing the default value for this input value.",resolve(r){const{type:t,defaultValue:i}=r,n=astFromValue(i,t);return n?print(n):null}},isDeprecated:{type:new GraphQLNonNull(GraphQLBoolean),resolve:r=>r.deprecationReason!=null},deprecationReason:{type:GraphQLString,resolve:r=>r.deprecationReason}})}),__EnumValue=new GraphQLObjectType({name:"__EnumValue",description:"One possible value for a given Enum. Enum values are unique values, not a placeholder for a string or numeric value. However an Enum value is returned in a JSON response as a string.",fields:()=>({name:{type:new GraphQLNonNull(GraphQLString),resolve:r=>r.name},description:{type:GraphQLString,resolve:r=>r.description},isDeprecated:{type:new GraphQLNonNull(GraphQLBoolean),resolve:r=>r.deprecationReason!=null},deprecationReason:{type:GraphQLString,resolve:r=>r.deprecationReason}})});var TypeKind;(function(r){r.SCALAR="SCALAR",r.OBJECT="OBJECT",r.INTERFACE="INTERFACE",r.UNION="UNION",r.ENUM="ENUM",r.INPUT_OBJECT="INPUT_OBJECT",r.LIST="LIST",r.NON_NULL="NON_NULL"})(TypeKind||(TypeKind={}));const __TypeKind=new GraphQLEnumType({name:"__TypeKind",description:"An enum describing what kind of type a given `__Type` is.",values:{SCALAR:{value:TypeKind.SCALAR,description:"Indicates this type is a scalar."},OBJECT:{value:TypeKind.OBJECT,description:"Indicates this type is an object. `fields` and `interfaces` are valid fields."},INTERFACE:{value:TypeKind.INTERFACE,description:"Indicates this type is an interface. `fields`, `interfaces`, and `possibleTypes` are valid fields."},UNION:{value:TypeKind.UNION,description:"Indicates this type is a union. `possibleTypes` is a valid field."},ENUM:{value:TypeKind.ENUM,description:"Indicates this type is an enum. `enumValues` is a valid field."},INPUT_OBJECT:{value:TypeKind.INPUT_OBJECT,description:"Indicates this type is an input object. `inputFields` is a valid field."},LIST:{value:TypeKind.LIST,description:"Indicates this type is a list. `ofType` is a valid field."},NON_NULL:{value:TypeKind.NON_NULL,description:"Indicates this type is a non-null. `ofType` is a valid field."}}}),SchemaMetaFieldDef={name:"__schema",type:new GraphQLNonNull(__Schema),description:"Access the current type schema of this server.",args:[],resolve:(r,t,i,{schema:n})=>n,deprecationReason:void 0,extensions:Object.create(null),astNode:void 0},TypeMetaFieldDef={name:"__type",type:__Type,description:"Request the type information of a single type.",args:[{name:"name",description:void 0,type:new GraphQLNonNull(GraphQLString),defaultValue:void 0,deprecationReason:void 0,extensions:Object.create(null),astNode:void 0}],resolve:(r,{name:t},i,{schema:n})=>n.getType(t),deprecationReason:void 0,extensions:Object.create(null),astNode:void 0},TypeNameMetaFieldDef={name:"__typename",type:new GraphQLNonNull(GraphQLString),description:"The name of the current Object type at runtime.",args:[],resolve:(r,t,i,{parentType:n})=>n.name,deprecationReason:void 0,extensions:Object.create(null),astNode:void 0},introspectionTypes=Object.freeze([__Schema,__Directive,__DirectiveLocation,__Type,__Field,__InputValue,__EnumValue,__TypeKind]);function isIntrospectionType(r){return introspectionTypes.some(({name:t})=>r.name===t)}function isSchema(r){return instanceOf(r,GraphQLSchema)}function assertSchema(r){if(!isSchema(r))throw new Error(`Expected ${inspect(r)} to be a GraphQL schema.`);return r}class GraphQLSchema{constructor(t){var i,n;this.__validationErrors=t.assumeValid===!0?[]:void 0,isObjectLike(t)||devAssert(!1,"Must provide configuration object."),!t.types||Array.isArray(t.types)||devAssert(!1,`"types" must be Array if provided but got: ${inspect(t.types)}.`),!t.directives||Array.isArray(t.directives)||devAssert(!1,`"directives" must be Array if provided but got: ${inspect(t.directives)}.`),this.description=t.description,this.extensions=toObjMap(t.extensions),this.astNode=t.astNode,this.extensionASTNodes=(i=t.extensionASTNodes)!==null&&i!==void 0?i:[],this._queryType=t.query,this._mutationType=t.mutation,this._subscriptionType=t.subscription,this._directives=(n=t.directives)!==null&&n!==void 0?n:specifiedDirectives;const s=new Set(t.types);if(t.types!=null)for(const a of t.types)s.delete(a),collectReferencedTypes(a,s);this._queryType!=null&&collectReferencedTypes(this._queryType,s),this._mutationType!=null&&collectReferencedTypes(this._mutationType,s),this._subscriptionType!=null&&collectReferencedTypes(this._subscriptionType,s);for(const a of this._directives)if(isDirective(a))for(const h of a.args)collectReferencedTypes(h.type,s);collectReferencedTypes(__Schema,s),this._typeMap=Object.create(null),this._subTypeMap=Object.create(null),this._implementationsMap=Object.create(null);for(const a of s){if(a==null)continue;const h=a.name;if(h||devAssert(!1,"One of the provided types for building the Schema is missing a name."),this._typeMap[h]!==void 0)throw new Error(`Schema must contain uniquely named types but contains multiple types named "${h}".`);if(this._typeMap[h]=a,isInterfaceType(a)){for(const v of a.getInterfaces())if(isInterfaceType(v)){let hi=this._implementationsMap[v.name];hi===void 0&&(hi=this._implementationsMap[v.name]={objects:[],interfaces:[]}),hi.interfaces.push(a)}}else if(isObjectType(a)){for(const v of a.getInterfaces())if(isInterfaceType(v)){let hi=this._implementationsMap[v.name];hi===void 0&&(hi=this._implementationsMap[v.name]={objects:[],interfaces:[]}),hi.objects.push(a)}}}}get[Symbol.toStringTag](){return"GraphQLSchema"}getQueryType(){return this._queryType}getMutationType(){return this._mutationType}getSubscriptionType(){return this._subscriptionType}getRootType(t){switch(t){case OperationTypeNode.QUERY:return this.getQueryType();case OperationTypeNode.MUTATION:return this.getMutationType();case OperationTypeNode.SUBSCRIPTION:return this.getSubscriptionType()}}getTypeMap(){return this._typeMap}getType(t){return this.getTypeMap()[t]}getPossibleTypes(t){return isUnionType(t)?t.getTypes():this.getImplementations(t).objects}getImplementations(t){const i=this._implementationsMap[t.name];return i??{objects:[],interfaces:[]}}isSubType(t,i){let n=this._subTypeMap[t.name];if(n===void 0){if(n=Object.create(null),isUnionType(t))for(const s of t.getTypes())n[s.name]=!0;else{const s=this.getImplementations(t);for(const a of s.objects)n[a.name]=!0;for(const a of s.interfaces)n[a.name]=!0}this._subTypeMap[t.name]=n}return n[i.name]!==void 0}getDirectives(){return this._directives}getDirective(t){return this.getDirectives().find(i=>i.name===t)}toConfig(){return{description:this.description,query:this.getQueryType(),mutation:this.getMutationType(),subscription:this.getSubscriptionType(),types:Object.values(this.getTypeMap()),directives:this.getDirectives(),extensions:this.extensions,astNode:this.astNode,extensionASTNodes:this.extensionASTNodes,assumeValid:this.__validationErrors!==void 0}}}function collectReferencedTypes(r,t){const i=getNamedType(r);if(!t.has(i)){if(t.add(i),isUnionType(i))for(const n of i.getTypes())collectReferencedTypes(n,t);else if(isObjectType(i)||isInterfaceType(i)){for(const n of i.getInterfaces())collectReferencedTypes(n,t);for(const n of Object.values(i.getFields())){collectReferencedTypes(n.type,t);for(const s of n.args)collectReferencedTypes(s.type,t)}}else if(isInputObjectType(i))for(const n of Object.values(i.getFields()))collectReferencedTypes(n.type,t)}return t}function validateSchema(r){if(assertSchema(r),r.__validationErrors)return r.__validationErrors;const t=new SchemaValidationContext(r);validateRootTypes(t),validateDirectives(t),validateTypes(t);const i=t.getErrors();return r.__validationErrors=i,i}function assertValidSchema(r){const t=validateSchema(r);if(t.length!==0)throw new Error(t.map(i=>i.message).join(`
178
+
179
+ `))}class SchemaValidationContext{constructor(t){this._errors=[],this.schema=t}reportError(t,i){const n=Array.isArray(i)?i.filter(Boolean):i;this._errors.push(new GraphQLError(t,{nodes:n}))}getErrors(){return this._errors}}function validateRootTypes(r){const t=r.schema,i=t.getQueryType();if(!i)r.reportError("Query root type must be provided.",t.astNode);else if(!isObjectType(i)){var n;r.reportError(`Query root type must be Object type, it cannot be ${inspect(i)}.`,(n=getOperationTypeNode(t,OperationTypeNode.QUERY))!==null&&n!==void 0?n:i.astNode)}const s=t.getMutationType();if(s&&!isObjectType(s)){var a;r.reportError(`Mutation root type must be Object type if provided, it cannot be ${inspect(s)}.`,(a=getOperationTypeNode(t,OperationTypeNode.MUTATION))!==null&&a!==void 0?a:s.astNode)}const h=t.getSubscriptionType();if(h&&!isObjectType(h)){var v;r.reportError(`Subscription root type must be Object type if provided, it cannot be ${inspect(h)}.`,(v=getOperationTypeNode(t,OperationTypeNode.SUBSCRIPTION))!==null&&v!==void 0?v:h.astNode)}}function getOperationTypeNode(r,t){var i;return(i=[r.astNode,...r.extensionASTNodes].flatMap(n=>{var s;return(s=n?.operationTypes)!==null&&s!==void 0?s:[]}).find(n=>n.operation===t))===null||i===void 0?void 0:i.type}function validateDirectives(r){for(const i of r.schema.getDirectives()){if(!isDirective(i)){r.reportError(`Expected directive but got: ${inspect(i)}.`,i?.astNode);continue}validateName(r,i);for(const n of i.args)if(validateName(r,n),isInputType(n.type)||r.reportError(`The type of @${i.name}(${n.name}:) must be Input Type but got: ${inspect(n.type)}.`,n.astNode),isRequiredArgument(n)&&n.deprecationReason!=null){var t;r.reportError(`Required argument @${i.name}(${n.name}:) cannot be deprecated.`,[getDeprecatedDirectiveNode(n.astNode),(t=n.astNode)===null||t===void 0?void 0:t.type])}}}function validateName(r,t){t.name.startsWith("__")&&r.reportError(`Name "${t.name}" must not begin with "__", which is reserved by GraphQL introspection.`,t.astNode)}function validateTypes(r){const t=createInputObjectCircularRefsValidator(r),i=r.schema.getTypeMap();for(const n of Object.values(i)){if(!isNamedType(n)){r.reportError(`Expected GraphQL named type but got: ${inspect(n)}.`,n.astNode);continue}isIntrospectionType(n)||validateName(r,n),isObjectType(n)||isInterfaceType(n)?(validateFields(r,n),validateInterfaces(r,n)):isUnionType(n)?validateUnionMembers(r,n):isEnumType(n)?validateEnumValues(r,n):isInputObjectType(n)&&(validateInputFields(r,n),t(n))}}function validateFields(r,t){const i=Object.values(t.getFields());i.length===0&&r.reportError(`Type ${t.name} must define one or more fields.`,[t.astNode,...t.extensionASTNodes]);for(const h of i){if(validateName(r,h),!isOutputType(h.type)){var n;r.reportError(`The type of ${t.name}.${h.name} must be Output Type but got: ${inspect(h.type)}.`,(n=h.astNode)===null||n===void 0?void 0:n.type)}for(const v of h.args){const hi=v.name;if(validateName(r,v),!isInputType(v.type)){var s;r.reportError(`The type of ${t.name}.${h.name}(${hi}:) must be Input Type but got: ${inspect(v.type)}.`,(s=v.astNode)===null||s===void 0?void 0:s.type)}if(isRequiredArgument(v)&&v.deprecationReason!=null){var a;r.reportError(`Required argument ${t.name}.${h.name}(${hi}:) cannot be deprecated.`,[getDeprecatedDirectiveNode(v.astNode),(a=v.astNode)===null||a===void 0?void 0:a.type])}}}}function validateInterfaces(r,t){const i=Object.create(null);for(const n of t.getInterfaces()){if(!isInterfaceType(n)){r.reportError(`Type ${inspect(t)} must only implement Interface types, it cannot implement ${inspect(n)}.`,getAllImplementsInterfaceNodes(t,n));continue}if(t===n){r.reportError(`Type ${t.name} cannot implement itself because it would create a circular reference.`,getAllImplementsInterfaceNodes(t,n));continue}if(i[n.name]){r.reportError(`Type ${t.name} can only implement ${n.name} once.`,getAllImplementsInterfaceNodes(t,n));continue}i[n.name]=!0,validateTypeImplementsAncestors(r,t,n),validateTypeImplementsInterface(r,t,n)}}function validateTypeImplementsInterface(r,t,i){const n=t.getFields();for(const hi of Object.values(i.getFields())){const u=hi.name,l=n[u];if(!l){r.reportError(`Interface field ${i.name}.${u} expected but ${t.name} does not provide it.`,[hi.astNode,t.astNode,...t.extensionASTNodes]);continue}if(!isTypeSubTypeOf(r.schema,l.type,hi.type)){var s,a;r.reportError(`Interface field ${i.name}.${u} expects type ${inspect(hi.type)} but ${t.name}.${u} is type ${inspect(l.type)}.`,[(s=hi.astNode)===null||s===void 0?void 0:s.type,(a=l.astNode)===null||a===void 0?void 0:a.type])}for(const vi of hi.args){const D=vi.name,mi=l.args.find(gi=>gi.name===D);if(!mi){r.reportError(`Interface field argument ${i.name}.${u}(${D}:) expected but ${t.name}.${u} does not provide it.`,[vi.astNode,l.astNode]);continue}if(!isEqualType(vi.type,mi.type)){var h,v;r.reportError(`Interface field argument ${i.name}.${u}(${D}:) expects type ${inspect(vi.type)} but ${t.name}.${u}(${D}:) is type ${inspect(mi.type)}.`,[(h=vi.astNode)===null||h===void 0?void 0:h.type,(v=mi.astNode)===null||v===void 0?void 0:v.type])}}for(const vi of l.args){const D=vi.name;!hi.args.find(gi=>gi.name===D)&&isRequiredArgument(vi)&&r.reportError(`Object field ${t.name}.${u} includes required argument ${D} that is missing from the Interface field ${i.name}.${u}.`,[vi.astNode,hi.astNode])}}}function validateTypeImplementsAncestors(r,t,i){const n=t.getInterfaces();for(const s of i.getInterfaces())n.includes(s)||r.reportError(s===t?`Type ${t.name} cannot implement ${i.name} because it would create a circular reference.`:`Type ${t.name} must implement ${s.name} because it is implemented by ${i.name}.`,[...getAllImplementsInterfaceNodes(i,s),...getAllImplementsInterfaceNodes(t,i)])}function validateUnionMembers(r,t){const i=t.getTypes();i.length===0&&r.reportError(`Union type ${t.name} must define one or more member types.`,[t.astNode,...t.extensionASTNodes]);const n=Object.create(null);for(const s of i){if(n[s.name]){r.reportError(`Union type ${t.name} can only include type ${s.name} once.`,getUnionMemberTypeNodes(t,s.name));continue}n[s.name]=!0,isObjectType(s)||r.reportError(`Union type ${t.name} can only include Object types, it cannot include ${inspect(s)}.`,getUnionMemberTypeNodes(t,String(s)))}}function validateEnumValues(r,t){const i=t.getValues();i.length===0&&r.reportError(`Enum type ${t.name} must define one or more values.`,[t.astNode,...t.extensionASTNodes]);for(const n of i)validateName(r,n)}function validateInputFields(r,t){const i=Object.values(t.getFields());i.length===0&&r.reportError(`Input Object type ${t.name} must define one or more fields.`,[t.astNode,...t.extensionASTNodes]);for(const a of i){if(validateName(r,a),!isInputType(a.type)){var n;r.reportError(`The type of ${t.name}.${a.name} must be Input Type but got: ${inspect(a.type)}.`,(n=a.astNode)===null||n===void 0?void 0:n.type)}if(isRequiredInputField(a)&&a.deprecationReason!=null){var s;r.reportError(`Required input field ${t.name}.${a.name} cannot be deprecated.`,[getDeprecatedDirectiveNode(a.astNode),(s=a.astNode)===null||s===void 0?void 0:s.type])}t.isOneOf&&validateOneOfInputObjectField(t,a,r)}}function validateOneOfInputObjectField(r,t,i){if(isNonNullType(t.type)){var n;i.reportError(`OneOf input field ${r.name}.${t.name} must be nullable.`,(n=t.astNode)===null||n===void 0?void 0:n.type)}t.defaultValue!==void 0&&i.reportError(`OneOf input field ${r.name}.${t.name} cannot have a default value.`,t.astNode)}function createInputObjectCircularRefsValidator(r){const t=Object.create(null),i=[],n=Object.create(null);return s;function s(a){if(t[a.name])return;t[a.name]=!0,n[a.name]=i.length;const h=Object.values(a.getFields());for(const v of h)if(isNonNullType(v.type)&&isInputObjectType(v.type.ofType)){const hi=v.type.ofType,u=n[hi.name];if(i.push(v),u===void 0)s(hi);else{const l=i.slice(u),vi=l.map(D=>D.name).join(".");r.reportError(`Cannot reference Input Object "${hi.name}" within itself through a series of non-null fields: "${vi}".`,l.map(D=>D.astNode))}i.pop()}n[a.name]=void 0}}function getAllImplementsInterfaceNodes(r,t){const{astNode:i,extensionASTNodes:n}=r;return(i!=null?[i,...n]:n).flatMap(a=>{var h;return(h=a.interfaces)!==null&&h!==void 0?h:[]}).filter(a=>a.name.value===t.name)}function getUnionMemberTypeNodes(r,t){const{astNode:i,extensionASTNodes:n}=r;return(i!=null?[i,...n]:n).flatMap(a=>{var h;return(h=a.types)!==null&&h!==void 0?h:[]}).filter(a=>a.name.value===t)}function getDeprecatedDirectiveNode(r){var t;return r==null||(t=r.directives)===null||t===void 0?void 0:t.find(i=>i.name.value===GraphQLDeprecatedDirective.name)}function typeFromAST(r,t){switch(t.kind){case Kind.LIST_TYPE:{const i=typeFromAST(r,t.type);return i&&new GraphQLList(i)}case Kind.NON_NULL_TYPE:{const i=typeFromAST(r,t.type);return i&&new GraphQLNonNull(i)}case Kind.NAMED_TYPE:return r.getType(t.name.value)}}class TypeInfo{constructor(t,i,n){this._schema=t,this._typeStack=[],this._parentTypeStack=[],this._inputTypeStack=[],this._fieldDefStack=[],this._defaultValueStack=[],this._directive=null,this._argument=null,this._enumValue=null,this._getFieldDef=n??getFieldDef$1,i&&(isInputType(i)&&this._inputTypeStack.push(i),isCompositeType(i)&&this._parentTypeStack.push(i),isOutputType(i)&&this._typeStack.push(i))}get[Symbol.toStringTag](){return"TypeInfo"}getType(){if(this._typeStack.length>0)return this._typeStack[this._typeStack.length-1]}getParentType(){if(this._parentTypeStack.length>0)return this._parentTypeStack[this._parentTypeStack.length-1]}getInputType(){if(this._inputTypeStack.length>0)return this._inputTypeStack[this._inputTypeStack.length-1]}getParentInputType(){if(this._inputTypeStack.length>1)return this._inputTypeStack[this._inputTypeStack.length-2]}getFieldDef(){if(this._fieldDefStack.length>0)return this._fieldDefStack[this._fieldDefStack.length-1]}getDefaultValue(){if(this._defaultValueStack.length>0)return this._defaultValueStack[this._defaultValueStack.length-1]}getDirective(){return this._directive}getArgument(){return this._argument}getEnumValue(){return this._enumValue}enter(t){const i=this._schema;switch(t.kind){case Kind.SELECTION_SET:{const s=getNamedType(this.getType());this._parentTypeStack.push(isCompositeType(s)?s:void 0);break}case Kind.FIELD:{const s=this.getParentType();let a,h;s&&(a=this._getFieldDef(i,s,t),a&&(h=a.type)),this._fieldDefStack.push(a),this._typeStack.push(isOutputType(h)?h:void 0);break}case Kind.DIRECTIVE:this._directive=i.getDirective(t.name.value);break;case Kind.OPERATION_DEFINITION:{const s=i.getRootType(t.operation);this._typeStack.push(isObjectType(s)?s:void 0);break}case Kind.INLINE_FRAGMENT:case Kind.FRAGMENT_DEFINITION:{const s=t.typeCondition,a=s?typeFromAST(i,s):getNamedType(this.getType());this._typeStack.push(isOutputType(a)?a:void 0);break}case Kind.VARIABLE_DEFINITION:{const s=typeFromAST(i,t.type);this._inputTypeStack.push(isInputType(s)?s:void 0);break}case Kind.ARGUMENT:{var n;let s,a;const h=(n=this.getDirective())!==null&&n!==void 0?n:this.getFieldDef();h&&(s=h.args.find(v=>v.name===t.name.value),s&&(a=s.type)),this._argument=s,this._defaultValueStack.push(s?s.defaultValue:void 0),this._inputTypeStack.push(isInputType(a)?a:void 0);break}case Kind.LIST:{const s=getNullableType(this.getInputType()),a=isListType(s)?s.ofType:s;this._defaultValueStack.push(void 0),this._inputTypeStack.push(isInputType(a)?a:void 0);break}case Kind.OBJECT_FIELD:{const s=getNamedType(this.getInputType());let a,h;isInputObjectType(s)&&(h=s.getFields()[t.name.value],h&&(a=h.type)),this._defaultValueStack.push(h?h.defaultValue:void 0),this._inputTypeStack.push(isInputType(a)?a:void 0);break}case Kind.ENUM:{const s=getNamedType(this.getInputType());let a;isEnumType(s)&&(a=s.getValue(t.value)),this._enumValue=a;break}}}leave(t){switch(t.kind){case Kind.SELECTION_SET:this._parentTypeStack.pop();break;case Kind.FIELD:this._fieldDefStack.pop(),this._typeStack.pop();break;case Kind.DIRECTIVE:this._directive=null;break;case Kind.OPERATION_DEFINITION:case Kind.INLINE_FRAGMENT:case Kind.FRAGMENT_DEFINITION:this._typeStack.pop();break;case Kind.VARIABLE_DEFINITION:this._inputTypeStack.pop();break;case Kind.ARGUMENT:this._argument=null,this._defaultValueStack.pop(),this._inputTypeStack.pop();break;case Kind.LIST:case Kind.OBJECT_FIELD:this._defaultValueStack.pop(),this._inputTypeStack.pop();break;case Kind.ENUM:this._enumValue=null;break}}}function getFieldDef$1(r,t,i){const n=i.name.value;if(n===SchemaMetaFieldDef.name&&r.getQueryType()===t)return SchemaMetaFieldDef;if(n===TypeMetaFieldDef.name&&r.getQueryType()===t)return TypeMetaFieldDef;if(n===TypeNameMetaFieldDef.name&&isCompositeType(t))return TypeNameMetaFieldDef;if(isObjectType(t)||isInterfaceType(t))return t.getFields()[n]}function visitWithTypeInfo(r,t){return{enter(...i){const n=i[0];r.enter(n);const s=getEnterLeaveForKind(t,n.kind).enter;if(s){const a=s.apply(t,i);return a!==void 0&&(r.leave(n),isNode(a)&&r.enter(a)),a}},leave(...i){const n=i[0],s=getEnterLeaveForKind(t,n.kind).leave;let a;return s&&(a=s.apply(t,i)),r.leave(n),a}}}function isDefinitionNode(r){return isExecutableDefinitionNode(r)||isTypeSystemDefinitionNode(r)||isTypeSystemExtensionNode(r)}function isExecutableDefinitionNode(r){return r.kind===Kind.OPERATION_DEFINITION||r.kind===Kind.FRAGMENT_DEFINITION}function isSelectionNode(r){return r.kind===Kind.FIELD||r.kind===Kind.FRAGMENT_SPREAD||r.kind===Kind.INLINE_FRAGMENT}function isValueNode(r){return r.kind===Kind.VARIABLE||r.kind===Kind.INT||r.kind===Kind.FLOAT||r.kind===Kind.STRING||r.kind===Kind.BOOLEAN||r.kind===Kind.NULL||r.kind===Kind.ENUM||r.kind===Kind.LIST||r.kind===Kind.OBJECT}function isConstValueNode(r){return isValueNode(r)&&(r.kind===Kind.LIST?r.values.some(isConstValueNode):r.kind===Kind.OBJECT?r.fields.some(t=>isConstValueNode(t.value)):r.kind!==Kind.VARIABLE)}function isTypeNode(r){return r.kind===Kind.NAMED_TYPE||r.kind===Kind.LIST_TYPE||r.kind===Kind.NON_NULL_TYPE}function isTypeSystemDefinitionNode(r){return r.kind===Kind.SCHEMA_DEFINITION||isTypeDefinitionNode(r)||r.kind===Kind.DIRECTIVE_DEFINITION}function isTypeDefinitionNode(r){return r.kind===Kind.SCALAR_TYPE_DEFINITION||r.kind===Kind.OBJECT_TYPE_DEFINITION||r.kind===Kind.INTERFACE_TYPE_DEFINITION||r.kind===Kind.UNION_TYPE_DEFINITION||r.kind===Kind.ENUM_TYPE_DEFINITION||r.kind===Kind.INPUT_OBJECT_TYPE_DEFINITION}function isTypeSystemExtensionNode(r){return r.kind===Kind.SCHEMA_EXTENSION||isTypeExtensionNode(r)}function isTypeExtensionNode(r){return r.kind===Kind.SCALAR_TYPE_EXTENSION||r.kind===Kind.OBJECT_TYPE_EXTENSION||r.kind===Kind.INTERFACE_TYPE_EXTENSION||r.kind===Kind.UNION_TYPE_EXTENSION||r.kind===Kind.ENUM_TYPE_EXTENSION||r.kind===Kind.INPUT_OBJECT_TYPE_EXTENSION}function ExecutableDefinitionsRule(r){return{Document(t){for(const i of t.definitions)if(!isExecutableDefinitionNode(i)){const n=i.kind===Kind.SCHEMA_DEFINITION||i.kind===Kind.SCHEMA_EXTENSION?"schema":'"'+i.name.value+'"';r.reportError(new GraphQLError(`The ${n} definition is not executable.`,{nodes:i}))}return!1}}}function FieldsOnCorrectTypeRule(r){return{Field(t){const i=r.getParentType();if(i&&!r.getFieldDef()){const s=r.getSchema(),a=t.name.value;let h=didYouMean("to use an inline fragment on",getSuggestedTypeNames(s,i,a));h===""&&(h=didYouMean(getSuggestedFieldNames(i,a))),r.reportError(new GraphQLError(`Cannot query field "${a}" on type "${i.name}".`+h,{nodes:t}))}}}}function getSuggestedTypeNames(r,t,i){if(!isAbstractType(t))return[];const n=new Set,s=Object.create(null);for(const h of r.getPossibleTypes(t))if(h.getFields()[i]){n.add(h),s[h.name]=1;for(const v of h.getInterfaces()){var a;v.getFields()[i]&&(n.add(v),s[v.name]=((a=s[v.name])!==null&&a!==void 0?a:0)+1)}}return[...n].sort((h,v)=>{const hi=s[v.name]-s[h.name];return hi!==0?hi:isInterfaceType(h)&&r.isSubType(h,v)?-1:isInterfaceType(v)&&r.isSubType(v,h)?1:naturalCompare(h.name,v.name)}).map(h=>h.name)}function getSuggestedFieldNames(r,t){if(isObjectType(r)||isInterfaceType(r)){const i=Object.keys(r.getFields());return suggestionList(t,i)}return[]}function FragmentsOnCompositeTypesRule(r){return{InlineFragment(t){const i=t.typeCondition;if(i){const n=typeFromAST(r.getSchema(),i);if(n&&!isCompositeType(n)){const s=print(i);r.reportError(new GraphQLError(`Fragment cannot condition on non composite type "${s}".`,{nodes:i}))}}},FragmentDefinition(t){const i=typeFromAST(r.getSchema(),t.typeCondition);if(i&&!isCompositeType(i)){const n=print(t.typeCondition);r.reportError(new GraphQLError(`Fragment "${t.name.value}" cannot condition on non composite type "${n}".`,{nodes:t.typeCondition}))}}}}function KnownArgumentNamesRule(r){return{...KnownArgumentNamesOnDirectivesRule(r),Argument(t){const i=r.getArgument(),n=r.getFieldDef(),s=r.getParentType();if(!i&&n&&s){const a=t.name.value,h=n.args.map(hi=>hi.name),v=suggestionList(a,h);r.reportError(new GraphQLError(`Unknown argument "${a}" on field "${s.name}.${n.name}".`+didYouMean(v),{nodes:t}))}}}}function KnownArgumentNamesOnDirectivesRule(r){const t=Object.create(null),i=r.getSchema(),n=i?i.getDirectives():specifiedDirectives;for(const h of n)t[h.name]=h.args.map(v=>v.name);const s=r.getDocument().definitions;for(const h of s)if(h.kind===Kind.DIRECTIVE_DEFINITION){var a;const v=(a=h.arguments)!==null&&a!==void 0?a:[];t[h.name.value]=v.map(hi=>hi.name.value)}return{Directive(h){const v=h.name.value,hi=t[v];if(h.arguments&&hi)for(const u of h.arguments){const l=u.name.value;if(!hi.includes(l)){const vi=suggestionList(l,hi);r.reportError(new GraphQLError(`Unknown argument "${l}" on directive "@${v}".`+didYouMean(vi),{nodes:u}))}}return!1}}}function KnownDirectivesRule(r){const t=Object.create(null),i=r.getSchema(),n=i?i.getDirectives():specifiedDirectives;for(const a of n)t[a.name]=a.locations;const s=r.getDocument().definitions;for(const a of s)a.kind===Kind.DIRECTIVE_DEFINITION&&(t[a.name.value]=a.locations.map(h=>h.value));return{Directive(a,h,v,hi,u){const l=a.name.value,vi=t[l];if(!vi){r.reportError(new GraphQLError(`Unknown directive "@${l}".`,{nodes:a}));return}const D=getDirectiveLocationForASTPath(u);D&&!vi.includes(D)&&r.reportError(new GraphQLError(`Directive "@${l}" may not be used on ${D}.`,{nodes:a}))}}}function getDirectiveLocationForASTPath(r){const t=r[r.length-1];switch("kind"in t||invariant(!1),t.kind){case Kind.OPERATION_DEFINITION:return getDirectiveLocationForOperation(t.operation);case Kind.FIELD:return DirectiveLocation.FIELD;case Kind.FRAGMENT_SPREAD:return DirectiveLocation.FRAGMENT_SPREAD;case Kind.INLINE_FRAGMENT:return DirectiveLocation.INLINE_FRAGMENT;case Kind.FRAGMENT_DEFINITION:return DirectiveLocation.FRAGMENT_DEFINITION;case Kind.VARIABLE_DEFINITION:return DirectiveLocation.VARIABLE_DEFINITION;case Kind.SCHEMA_DEFINITION:case Kind.SCHEMA_EXTENSION:return DirectiveLocation.SCHEMA;case Kind.SCALAR_TYPE_DEFINITION:case Kind.SCALAR_TYPE_EXTENSION:return DirectiveLocation.SCALAR;case Kind.OBJECT_TYPE_DEFINITION:case Kind.OBJECT_TYPE_EXTENSION:return DirectiveLocation.OBJECT;case Kind.FIELD_DEFINITION:return DirectiveLocation.FIELD_DEFINITION;case Kind.INTERFACE_TYPE_DEFINITION:case Kind.INTERFACE_TYPE_EXTENSION:return DirectiveLocation.INTERFACE;case Kind.UNION_TYPE_DEFINITION:case Kind.UNION_TYPE_EXTENSION:return DirectiveLocation.UNION;case Kind.ENUM_TYPE_DEFINITION:case Kind.ENUM_TYPE_EXTENSION:return DirectiveLocation.ENUM;case Kind.ENUM_VALUE_DEFINITION:return DirectiveLocation.ENUM_VALUE;case Kind.INPUT_OBJECT_TYPE_DEFINITION:case Kind.INPUT_OBJECT_TYPE_EXTENSION:return DirectiveLocation.INPUT_OBJECT;case Kind.INPUT_VALUE_DEFINITION:{const i=r[r.length-3];return"kind"in i||invariant(!1),i.kind===Kind.INPUT_OBJECT_TYPE_DEFINITION?DirectiveLocation.INPUT_FIELD_DEFINITION:DirectiveLocation.ARGUMENT_DEFINITION}default:invariant(!1,"Unexpected kind: "+inspect(t.kind))}}function getDirectiveLocationForOperation(r){switch(r){case OperationTypeNode.QUERY:return DirectiveLocation.QUERY;case OperationTypeNode.MUTATION:return DirectiveLocation.MUTATION;case OperationTypeNode.SUBSCRIPTION:return DirectiveLocation.SUBSCRIPTION}}function KnownFragmentNamesRule(r){return{FragmentSpread(t){const i=t.name.value;r.getFragment(i)||r.reportError(new GraphQLError(`Unknown fragment "${i}".`,{nodes:t.name}))}}}function KnownTypeNamesRule(r){const t=r.getSchema(),i=t?t.getTypeMap():Object.create(null),n=Object.create(null);for(const a of r.getDocument().definitions)isTypeDefinitionNode(a)&&(n[a.name.value]=!0);const s=[...Object.keys(i),...Object.keys(n)];return{NamedType(a,h,v,hi,u){const l=a.name.value;if(!i[l]&&!n[l]){var vi;const D=(vi=u[2])!==null&&vi!==void 0?vi:v,mi=D!=null&&isSDLNode(D);if(mi&&standardTypeNames.includes(l))return;const gi=suggestionList(l,mi?standardTypeNames.concat(s):s);r.reportError(new GraphQLError(`Unknown type "${l}".`+didYouMean(gi),{nodes:a}))}}}}const standardTypeNames=[...specifiedScalarTypes,...introspectionTypes].map(r=>r.name);function isSDLNode(r){return"kind"in r&&(isTypeSystemDefinitionNode(r)||isTypeSystemExtensionNode(r))}function LoneAnonymousOperationRule(r){let t=0;return{Document(i){t=i.definitions.filter(n=>n.kind===Kind.OPERATION_DEFINITION).length},OperationDefinition(i){!i.name&&t>1&&r.reportError(new GraphQLError("This anonymous operation must be the only defined operation.",{nodes:i}))}}}function LoneSchemaDefinitionRule(r){var t,i,n;const s=r.getSchema(),a=(t=(i=(n=s?.astNode)!==null&&n!==void 0?n:s?.getQueryType())!==null&&i!==void 0?i:s?.getMutationType())!==null&&t!==void 0?t:s?.getSubscriptionType();let h=0;return{SchemaDefinition(v){if(a){r.reportError(new GraphQLError("Cannot define a new schema within a schema extension.",{nodes:v}));return}h>0&&r.reportError(new GraphQLError("Must provide only one schema definition.",{nodes:v})),++h}}}const MAX_LISTS_DEPTH=3;function MaxIntrospectionDepthRule(r){function t(i,n=Object.create(null),s=0){if(i.kind===Kind.FRAGMENT_SPREAD){const a=i.name.value;if(n[a]===!0)return!1;const h=r.getFragment(a);if(!h)return!1;try{return n[a]=!0,t(h,n,s)}finally{n[a]=void 0}}if(i.kind===Kind.FIELD&&(i.name.value==="fields"||i.name.value==="interfaces"||i.name.value==="possibleTypes"||i.name.value==="inputFields")&&(s++,s>=MAX_LISTS_DEPTH))return!0;if("selectionSet"in i&&i.selectionSet){for(const a of i.selectionSet.selections)if(t(a,n,s))return!0}return!1}return{Field(i){if((i.name.value==="__schema"||i.name.value==="__type")&&t(i))return r.reportError(new GraphQLError("Maximum introspection depth exceeded",{nodes:[i]})),!1}}}function NoFragmentCyclesRule(r){const t=Object.create(null),i=[],n=Object.create(null);return{OperationDefinition:()=>!1,FragmentDefinition(a){return s(a),!1}};function s(a){if(t[a.name.value])return;const h=a.name.value;t[h]=!0;const v=r.getFragmentSpreads(a.selectionSet);if(v.length!==0){n[h]=i.length;for(const hi of v){const u=hi.name.value,l=n[u];if(i.push(hi),l===void 0){const vi=r.getFragment(u);vi&&s(vi)}else{const vi=i.slice(l),D=vi.slice(0,-1).map(mi=>'"'+mi.name.value+'"').join(", ");r.reportError(new GraphQLError(`Cannot spread fragment "${u}" within itself`+(D!==""?` via ${D}.`:"."),{nodes:vi}))}i.pop()}n[h]=void 0}}}function NoUndefinedVariablesRule(r){let t=Object.create(null);return{OperationDefinition:{enter(){t=Object.create(null)},leave(i){const n=r.getRecursiveVariableUsages(i);for(const{node:s}of n){const a=s.name.value;t[a]!==!0&&r.reportError(new GraphQLError(i.name?`Variable "$${a}" is not defined by operation "${i.name.value}".`:`Variable "$${a}" is not defined.`,{nodes:[s,i]}))}}},VariableDefinition(i){t[i.variable.name.value]=!0}}}function NoUnusedFragmentsRule(r){const t=[],i=[];return{OperationDefinition(n){return t.push(n),!1},FragmentDefinition(n){return i.push(n),!1},Document:{leave(){const n=Object.create(null);for(const s of t)for(const a of r.getRecursivelyReferencedFragments(s))n[a.name.value]=!0;for(const s of i){const a=s.name.value;n[a]!==!0&&r.reportError(new GraphQLError(`Fragment "${a}" is never used.`,{nodes:s}))}}}}}function NoUnusedVariablesRule(r){let t=[];return{OperationDefinition:{enter(){t=[]},leave(i){const n=Object.create(null),s=r.getRecursiveVariableUsages(i);for(const{node:a}of s)n[a.name.value]=!0;for(const a of t){const h=a.variable.name.value;n[h]!==!0&&r.reportError(new GraphQLError(i.name?`Variable "$${h}" is never used in operation "${i.name.value}".`:`Variable "$${h}" is never used.`,{nodes:a}))}}},VariableDefinition(i){t.push(i)}}}function sortValueNode(r){switch(r.kind){case Kind.OBJECT:return{...r,fields:sortFields(r.fields)};case Kind.LIST:return{...r,values:r.values.map(sortValueNode)};case Kind.INT:case Kind.FLOAT:case Kind.STRING:case Kind.BOOLEAN:case Kind.NULL:case Kind.ENUM:case Kind.VARIABLE:return r}}function sortFields(r){return r.map(t=>({...t,value:sortValueNode(t.value)})).sort((t,i)=>naturalCompare(t.name.value,i.name.value))}function reasonMessage(r){return Array.isArray(r)?r.map(([t,i])=>`subfields "${t}" conflict because `+reasonMessage(i)).join(" and "):r}function OverlappingFieldsCanBeMergedRule(r){const t=new PairSet,i=new Map;return{SelectionSet(n){const s=findConflictsWithinSelectionSet(r,i,t,r.getParentType(),n);for(const[[a,h],v,hi]of s){const u=reasonMessage(h);r.reportError(new GraphQLError(`Fields "${a}" conflict because ${u}. Use different aliases on the fields to fetch both if this was intentional.`,{nodes:v.concat(hi)}))}}}}function findConflictsWithinSelectionSet(r,t,i,n,s){const a=[],[h,v]=getFieldsAndFragmentNames(r,t,n,s);if(collectConflictsWithin(r,a,t,i,h),v.length!==0)for(let hi=0;hi<v.length;hi++){collectConflictsBetweenFieldsAndFragment(r,a,t,i,!1,h,v[hi]);for(let u=hi+1;u<v.length;u++)collectConflictsBetweenFragments(r,a,t,i,!1,v[hi],v[u])}return a}function collectConflictsBetweenFieldsAndFragment(r,t,i,n,s,a,h){const v=r.getFragment(h);if(!v)return;const[hi,u]=getReferencedFieldsAndFragmentNames(r,i,v);if(a!==hi){collectConflictsBetween(r,t,i,n,s,a,hi);for(const l of u)n.has(l,h,s)||(n.add(l,h,s),collectConflictsBetweenFieldsAndFragment(r,t,i,n,s,a,l))}}function collectConflictsBetweenFragments(r,t,i,n,s,a,h){if(a===h||n.has(a,h,s))return;n.add(a,h,s);const v=r.getFragment(a),hi=r.getFragment(h);if(!v||!hi)return;const[u,l]=getReferencedFieldsAndFragmentNames(r,i,v),[vi,D]=getReferencedFieldsAndFragmentNames(r,i,hi);collectConflictsBetween(r,t,i,n,s,u,vi);for(const mi of D)collectConflictsBetweenFragments(r,t,i,n,s,a,mi);for(const mi of l)collectConflictsBetweenFragments(r,t,i,n,s,mi,h)}function findConflictsBetweenSubSelectionSets(r,t,i,n,s,a,h,v){const hi=[],[u,l]=getFieldsAndFragmentNames(r,t,s,a),[vi,D]=getFieldsAndFragmentNames(r,t,h,v);collectConflictsBetween(r,hi,t,i,n,u,vi);for(const mi of D)collectConflictsBetweenFieldsAndFragment(r,hi,t,i,n,u,mi);for(const mi of l)collectConflictsBetweenFieldsAndFragment(r,hi,t,i,n,vi,mi);for(const mi of l)for(const gi of D)collectConflictsBetweenFragments(r,hi,t,i,n,mi,gi);return hi}function collectConflictsWithin(r,t,i,n,s){for(const[a,h]of Object.entries(s))if(h.length>1)for(let v=0;v<h.length;v++)for(let hi=v+1;hi<h.length;hi++){const u=findConflict(r,i,n,!1,a,h[v],h[hi]);u&&t.push(u)}}function collectConflictsBetween(r,t,i,n,s,a,h){for(const[v,hi]of Object.entries(a)){const u=h[v];if(u)for(const l of hi)for(const vi of u){const D=findConflict(r,i,n,s,v,l,vi);D&&t.push(D)}}}function findConflict(r,t,i,n,s,a,h){const[v,hi,u]=a,[l,vi,D]=h,mi=n||v!==l&&isObjectType(v)&&isObjectType(l);if(!mi){const Ii=hi.name.value,qi=vi.name.value;if(Ii!==qi)return[[s,`"${Ii}" and "${qi}" are different fields`],[hi],[vi]];if(!sameArguments(hi,vi))return[[s,"they have differing arguments"],[hi],[vi]]}const gi=u?.type,bi=D?.type;if(gi&&bi&&doTypesConflict(gi,bi))return[[s,`they return conflicting types "${inspect(gi)}" and "${inspect(bi)}"`],[hi],[vi]];const Ri=hi.selectionSet,Ti=vi.selectionSet;if(Ri&&Ti){const Ii=findConflictsBetweenSubSelectionSets(r,t,i,mi,getNamedType(gi),Ri,getNamedType(bi),Ti);return subfieldConflicts(Ii,s,hi,vi)}}function sameArguments(r,t){const i=r.arguments,n=t.arguments;if(i===void 0||i.length===0)return n===void 0||n.length===0;if(n===void 0||n.length===0||i.length!==n.length)return!1;const s=new Map(n.map(({name:a,value:h})=>[a.value,h]));return i.every(a=>{const h=a.value,v=s.get(a.name.value);return v===void 0?!1:stringifyValue$1(h)===stringifyValue$1(v)})}function stringifyValue$1(r){return print(sortValueNode(r))}function doTypesConflict(r,t){return isListType(r)?isListType(t)?doTypesConflict(r.ofType,t.ofType):!0:isListType(t)?!0:isNonNullType(r)?isNonNullType(t)?doTypesConflict(r.ofType,t.ofType):!0:isNonNullType(t)?!0:isLeafType(r)||isLeafType(t)?r!==t:!1}function getFieldsAndFragmentNames(r,t,i,n){const s=t.get(n);if(s)return s;const a=Object.create(null),h=Object.create(null);_collectFieldsAndFragmentNames(r,i,n,a,h);const v=[a,Object.keys(h)];return t.set(n,v),v}function getReferencedFieldsAndFragmentNames(r,t,i){const n=t.get(i.selectionSet);if(n)return n;const s=typeFromAST(r.getSchema(),i.typeCondition);return getFieldsAndFragmentNames(r,t,s,i.selectionSet)}function _collectFieldsAndFragmentNames(r,t,i,n,s){for(const a of i.selections)switch(a.kind){case Kind.FIELD:{const h=a.name.value;let v;(isObjectType(t)||isInterfaceType(t))&&(v=t.getFields()[h]);const hi=a.alias?a.alias.value:h;n[hi]||(n[hi]=[]),n[hi].push([t,a,v]);break}case Kind.FRAGMENT_SPREAD:s[a.name.value]=!0;break;case Kind.INLINE_FRAGMENT:{const h=a.typeCondition,v=h?typeFromAST(r.getSchema(),h):t;_collectFieldsAndFragmentNames(r,v,a.selectionSet,n,s);break}}}function subfieldConflicts(r,t,i,n){if(r.length>0)return[[t,r.map(([s])=>s)],[i,...r.map(([,s])=>s).flat()],[n,...r.map(([,,s])=>s).flat()]]}class PairSet{constructor(){this._data=new Map}has(t,i,n){var s;const[a,h]=t<i?[t,i]:[i,t],v=(s=this._data.get(a))===null||s===void 0?void 0:s.get(h);return v===void 0?!1:n?!0:n===v}add(t,i,n){const[s,a]=t<i?[t,i]:[i,t],h=this._data.get(s);h===void 0?this._data.set(s,new Map([[a,n]])):h.set(a,n)}}function PossibleFragmentSpreadsRule(r){return{InlineFragment(t){const i=r.getType(),n=r.getParentType();if(isCompositeType(i)&&isCompositeType(n)&&!doTypesOverlap(r.getSchema(),i,n)){const s=inspect(n),a=inspect(i);r.reportError(new GraphQLError(`Fragment cannot be spread here as objects of type "${s}" can never be of type "${a}".`,{nodes:t}))}},FragmentSpread(t){const i=t.name.value,n=getFragmentType(r,i),s=r.getParentType();if(n&&s&&!doTypesOverlap(r.getSchema(),n,s)){const a=inspect(s),h=inspect(n);r.reportError(new GraphQLError(`Fragment "${i}" cannot be spread here as objects of type "${a}" can never be of type "${h}".`,{nodes:t}))}}}}function getFragmentType(r,t){const i=r.getFragment(t);if(i){const n=typeFromAST(r.getSchema(),i.typeCondition);if(isCompositeType(n))return n}}function PossibleTypeExtensionsRule(r){const t=r.getSchema(),i=Object.create(null);for(const s of r.getDocument().definitions)isTypeDefinitionNode(s)&&(i[s.name.value]=s);return{ScalarTypeExtension:n,ObjectTypeExtension:n,InterfaceTypeExtension:n,UnionTypeExtension:n,EnumTypeExtension:n,InputObjectTypeExtension:n};function n(s){const a=s.name.value,h=i[a],v=t?.getType(a);let hi;if(h?hi=defKindToExtKind[h.kind]:v&&(hi=typeToExtKind(v)),hi){if(hi!==s.kind){const u=extensionKindToTypeName(s.kind);r.reportError(new GraphQLError(`Cannot extend non-${u} type "${a}".`,{nodes:h?[h,s]:s}))}}else{const u=Object.keys({...i,...t?.getTypeMap()}),l=suggestionList(a,u);r.reportError(new GraphQLError(`Cannot extend type "${a}" because it is not defined.`+didYouMean(l),{nodes:s.name}))}}}const defKindToExtKind={[Kind.SCALAR_TYPE_DEFINITION]:Kind.SCALAR_TYPE_EXTENSION,[Kind.OBJECT_TYPE_DEFINITION]:Kind.OBJECT_TYPE_EXTENSION,[Kind.INTERFACE_TYPE_DEFINITION]:Kind.INTERFACE_TYPE_EXTENSION,[Kind.UNION_TYPE_DEFINITION]:Kind.UNION_TYPE_EXTENSION,[Kind.ENUM_TYPE_DEFINITION]:Kind.ENUM_TYPE_EXTENSION,[Kind.INPUT_OBJECT_TYPE_DEFINITION]:Kind.INPUT_OBJECT_TYPE_EXTENSION};function typeToExtKind(r){if(isScalarType(r))return Kind.SCALAR_TYPE_EXTENSION;if(isObjectType(r))return Kind.OBJECT_TYPE_EXTENSION;if(isInterfaceType(r))return Kind.INTERFACE_TYPE_EXTENSION;if(isUnionType(r))return Kind.UNION_TYPE_EXTENSION;if(isEnumType(r))return Kind.ENUM_TYPE_EXTENSION;if(isInputObjectType(r))return Kind.INPUT_OBJECT_TYPE_EXTENSION;invariant(!1,"Unexpected type: "+inspect(r))}function extensionKindToTypeName(r){switch(r){case Kind.SCALAR_TYPE_EXTENSION:return"scalar";case Kind.OBJECT_TYPE_EXTENSION:return"object";case Kind.INTERFACE_TYPE_EXTENSION:return"interface";case Kind.UNION_TYPE_EXTENSION:return"union";case Kind.ENUM_TYPE_EXTENSION:return"enum";case Kind.INPUT_OBJECT_TYPE_EXTENSION:return"input object";default:invariant(!1,"Unexpected kind: "+inspect(r))}}function ProvidedRequiredArgumentsRule(r){return{...ProvidedRequiredArgumentsOnDirectivesRule(r),Field:{leave(t){var i;const n=r.getFieldDef();if(!n)return!1;const s=new Set((i=t.arguments)===null||i===void 0?void 0:i.map(a=>a.name.value));for(const a of n.args)if(!s.has(a.name)&&isRequiredArgument(a)){const h=inspect(a.type);r.reportError(new GraphQLError(`Field "${n.name}" argument "${a.name}" of type "${h}" is required, but it was not provided.`,{nodes:t}))}}}}}function ProvidedRequiredArgumentsOnDirectivesRule(r){var t;const i=Object.create(null),n=r.getSchema(),s=(t=n?.getDirectives())!==null&&t!==void 0?t:specifiedDirectives;for(const v of s)i[v.name]=keyMap(v.args.filter(isRequiredArgument),hi=>hi.name);const a=r.getDocument().definitions;for(const v of a)if(v.kind===Kind.DIRECTIVE_DEFINITION){var h;const hi=(h=v.arguments)!==null&&h!==void 0?h:[];i[v.name.value]=keyMap(hi.filter(isRequiredArgumentNode),u=>u.name.value)}return{Directive:{leave(v){const hi=v.name.value,u=i[hi];if(u){var l;const vi=(l=v.arguments)!==null&&l!==void 0?l:[],D=new Set(vi.map(mi=>mi.name.value));for(const[mi,gi]of Object.entries(u))if(!D.has(mi)){const bi=isType(gi.type)?inspect(gi.type):print(gi.type);r.reportError(new GraphQLError(`Directive "@${hi}" argument "${mi}" of type "${bi}" is required, but it was not provided.`,{nodes:v}))}}}}}}function isRequiredArgumentNode(r){return r.type.kind===Kind.NON_NULL_TYPE&&r.defaultValue==null}function ScalarLeafsRule(r){return{Field(t){const i=r.getType(),n=t.selectionSet;if(i){if(isLeafType(getNamedType(i))){if(n){const s=t.name.value,a=inspect(i);r.reportError(new GraphQLError(`Field "${s}" must not have a selection since type "${a}" has no subfields.`,{nodes:n}))}}else if(!n){const s=t.name.value,a=inspect(i);r.reportError(new GraphQLError(`Field "${s}" of type "${a}" must have a selection of subfields. Did you mean "${s} { ... }"?`,{nodes:t}))}}}}}function printPathArray(r){return r.map(t=>typeof t=="number"?"["+t.toString()+"]":"."+t).join("")}function addPath(r,t,i){return{prev:r,key:t,typename:i}}function pathToArray(r){const t=[];let i=r;for(;i;)t.push(i.key),i=i.prev;return t.reverse()}function coerceInputValue(r,t,i=defaultOnError){return coerceInputValueImpl(r,t,i,void 0)}function defaultOnError(r,t,i){let n="Invalid value "+inspect(t);throw r.length>0&&(n+=` at "value${printPathArray(r)}"`),i.message=n+": "+i.message,i}function coerceInputValueImpl(r,t,i,n){if(isNonNullType(t)){if(r!=null)return coerceInputValueImpl(r,t.ofType,i,n);i(pathToArray(n),r,new GraphQLError(`Expected non-nullable type "${inspect(t)}" not to be null.`));return}if(r==null)return null;if(isListType(t)){const s=t.ofType;return isIterableObject(r)?Array.from(r,(a,h)=>{const v=addPath(n,h,void 0);return coerceInputValueImpl(a,s,i,v)}):[coerceInputValueImpl(r,s,i,n)]}if(isInputObjectType(t)){if(!isObjectLike(r)){i(pathToArray(n),r,new GraphQLError(`Expected type "${t.name}" to be an object.`));return}const s={},a=t.getFields();for(const h of Object.values(a)){const v=r[h.name];if(v===void 0){if(h.defaultValue!==void 0)s[h.name]=h.defaultValue;else if(isNonNullType(h.type)){const hi=inspect(h.type);i(pathToArray(n),r,new GraphQLError(`Field "${h.name}" of required type "${hi}" was not provided.`))}continue}s[h.name]=coerceInputValueImpl(v,h.type,i,addPath(n,h.name,t.name))}for(const h of Object.keys(r))if(!a[h]){const v=suggestionList(h,Object.keys(t.getFields()));i(pathToArray(n),r,new GraphQLError(`Field "${h}" is not defined by type "${t.name}".`+didYouMean(v)))}if(t.isOneOf){const h=Object.keys(s);h.length!==1&&i(pathToArray(n),r,new GraphQLError(`Exactly one key must be specified for OneOf type "${t.name}".`));const v=h[0],hi=s[v];hi===null&&i(pathToArray(n).concat(v),hi,new GraphQLError(`Field "${v}" must be non-null.`))}return s}if(isLeafType(t)){let s;try{s=t.parseValue(r)}catch(a){a instanceof GraphQLError?i(pathToArray(n),r,a):i(pathToArray(n),r,new GraphQLError(`Expected type "${t.name}". `+a.message,{originalError:a}));return}return s===void 0&&i(pathToArray(n),r,new GraphQLError(`Expected type "${t.name}".`)),s}invariant(!1,"Unexpected input type: "+inspect(t))}function valueFromAST(r,t,i){if(r){if(r.kind===Kind.VARIABLE){const n=r.name.value;if(i==null||i[n]===void 0)return;const s=i[n];return s===null&&isNonNullType(t)?void 0:s}if(isNonNullType(t))return r.kind===Kind.NULL?void 0:valueFromAST(r,t.ofType,i);if(r.kind===Kind.NULL)return null;if(isListType(t)){const n=t.ofType;if(r.kind===Kind.LIST){const a=[];for(const h of r.values)if(isMissingVariable(h,i)){if(isNonNullType(n))return;a.push(null)}else{const v=valueFromAST(h,n,i);if(v===void 0)return;a.push(v)}return a}const s=valueFromAST(r,n,i);return s===void 0?void 0:[s]}if(isInputObjectType(t)){if(r.kind!==Kind.OBJECT)return;const n=Object.create(null),s=keyMap(r.fields,a=>a.name.value);for(const a of Object.values(t.getFields())){const h=s[a.name];if(!h||isMissingVariable(h.value,i)){if(a.defaultValue!==void 0)n[a.name]=a.defaultValue;else if(isNonNullType(a.type))return;continue}const v=valueFromAST(h.value,a.type,i);if(v===void 0)return;n[a.name]=v}if(t.isOneOf){const a=Object.keys(n);if(a.length!==1||n[a[0]]===null)return}return n}if(isLeafType(t)){let n;try{n=t.parseLiteral(r,i)}catch{return}return n===void 0?void 0:n}invariant(!1,"Unexpected input type: "+inspect(t))}}function isMissingVariable(r,t){return r.kind===Kind.VARIABLE&&(t==null||t[r.name.value]===void 0)}function getVariableValues(r,t,i,n){const s=[],a=n?.maxErrors;try{const h=coerceVariableValues(r,t,i,v=>{if(a!=null&&s.length>=a)throw new GraphQLError("Too many errors processing variables, error limit reached. Execution aborted.");s.push(v)});if(s.length===0)return{coerced:h}}catch(h){s.push(h)}return{errors:s}}function coerceVariableValues(r,t,i,n){const s={};for(const a of t){const h=a.variable.name.value,v=typeFromAST(r,a.type);if(!isInputType(v)){const u=print(a.type);n(new GraphQLError(`Variable "$${h}" expected value of type "${u}" which cannot be used as an input type.`,{nodes:a.type}));continue}if(!hasOwnProperty(i,h)){if(a.defaultValue)s[h]=valueFromAST(a.defaultValue,v);else if(isNonNullType(v)){const u=inspect(v);n(new GraphQLError(`Variable "$${h}" of required type "${u}" was not provided.`,{nodes:a}))}continue}const hi=i[h];if(hi===null&&isNonNullType(v)){const u=inspect(v);n(new GraphQLError(`Variable "$${h}" of non-null type "${u}" must not be null.`,{nodes:a}));continue}s[h]=coerceInputValue(hi,v,(u,l,vi)=>{let D=`Variable "$${h}" got invalid value `+inspect(l);u.length>0&&(D+=` at "${h}${printPathArray(u)}"`),n(new GraphQLError(D+"; "+vi.message,{nodes:a,originalError:vi}))})}return s}function getArgumentValues(r,t,i){var n;const s={},a=(n=t.arguments)!==null&&n!==void 0?n:[],h=keyMap(a,v=>v.name.value);for(const v of r.args){const hi=v.name,u=v.type,l=h[hi];if(!l){if(v.defaultValue!==void 0)s[hi]=v.defaultValue;else if(isNonNullType(u))throw new GraphQLError(`Argument "${hi}" of required type "${inspect(u)}" was not provided.`,{nodes:t});continue}const vi=l.value;let D=vi.kind===Kind.NULL;if(vi.kind===Kind.VARIABLE){const gi=vi.name.value;if(i==null||!hasOwnProperty(i,gi)){if(v.defaultValue!==void 0)s[hi]=v.defaultValue;else if(isNonNullType(u))throw new GraphQLError(`Argument "${hi}" of required type "${inspect(u)}" was provided the variable "$${gi}" which was not provided a runtime value.`,{nodes:vi});continue}D=i[gi]==null}if(D&&isNonNullType(u))throw new GraphQLError(`Argument "${hi}" of non-null type "${inspect(u)}" must not be null.`,{nodes:vi});const mi=valueFromAST(vi,u,i);if(mi===void 0)throw new GraphQLError(`Argument "${hi}" has invalid value ${print(vi)}.`,{nodes:vi});s[hi]=mi}return s}function getDirectiveValues(r,t,i){var n;const s=(n=t.directives)===null||n===void 0?void 0:n.find(a=>a.name.value===r.name);if(s)return getArgumentValues(r,s,i)}function hasOwnProperty(r,t){return Object.prototype.hasOwnProperty.call(r,t)}function collectFields(r,t,i,n,s){const a=new Map;return collectFieldsImpl(r,t,i,n,s,a,new Set),a}function collectSubfields$1(r,t,i,n,s){const a=new Map,h=new Set;for(const v of s)v.selectionSet&&collectFieldsImpl(r,t,i,n,v.selectionSet,a,h);return a}function collectFieldsImpl(r,t,i,n,s,a,h){for(const v of s.selections)switch(v.kind){case Kind.FIELD:{if(!shouldIncludeNode(i,v))continue;const hi=getFieldEntryKey(v),u=a.get(hi);u!==void 0?u.push(v):a.set(hi,[v]);break}case Kind.INLINE_FRAGMENT:{if(!shouldIncludeNode(i,v)||!doesFragmentConditionMatch(r,v,n))continue;collectFieldsImpl(r,t,i,n,v.selectionSet,a,h);break}case Kind.FRAGMENT_SPREAD:{const hi=v.name.value;if(h.has(hi)||!shouldIncludeNode(i,v))continue;h.add(hi);const u=t[hi];if(!u||!doesFragmentConditionMatch(r,u,n))continue;collectFieldsImpl(r,t,i,n,u.selectionSet,a,h);break}}}function shouldIncludeNode(r,t){const i=getDirectiveValues(GraphQLSkipDirective,t,r);if(i?.if===!0)return!1;const n=getDirectiveValues(GraphQLIncludeDirective,t,r);return n?.if!==!1}function doesFragmentConditionMatch(r,t,i){const n=t.typeCondition;if(!n)return!0;const s=typeFromAST(r,n);return s===i?!0:isAbstractType(s)?r.isSubType(s,i):!1}function getFieldEntryKey(r){return r.alias?r.alias.value:r.name.value}function SingleFieldSubscriptionsRule(r){return{OperationDefinition(t){if(t.operation==="subscription"){const i=r.getSchema(),n=i.getSubscriptionType();if(n){const s=t.name?t.name.value:null,a=Object.create(null),h=r.getDocument(),v=Object.create(null);for(const u of h.definitions)u.kind===Kind.FRAGMENT_DEFINITION&&(v[u.name.value]=u);const hi=collectFields(i,v,a,n,t.selectionSet);if(hi.size>1){const vi=[...hi.values()].slice(1).flat();r.reportError(new GraphQLError(s!=null?`Subscription "${s}" must select only one top level field.`:"Anonymous Subscription must select only one top level field.",{nodes:vi}))}for(const u of hi.values())u[0].name.value.startsWith("__")&&r.reportError(new GraphQLError(s!=null?`Subscription "${s}" must not select an introspection top level field.`:"Anonymous Subscription must not select an introspection top level field.",{nodes:u}))}}}}}function groupBy(r,t){const i=new Map;for(const n of r){const s=t(n),a=i.get(s);a===void 0?i.set(s,[n]):a.push(n)}return i}function UniqueArgumentDefinitionNamesRule(r){return{DirectiveDefinition(n){var s;const a=(s=n.arguments)!==null&&s!==void 0?s:[];return i(`@${n.name.value}`,a)},InterfaceTypeDefinition:t,InterfaceTypeExtension:t,ObjectTypeDefinition:t,ObjectTypeExtension:t};function t(n){var s;const a=n.name.value,h=(s=n.fields)!==null&&s!==void 0?s:[];for(const hi of h){var v;const u=hi.name.value,l=(v=hi.arguments)!==null&&v!==void 0?v:[];i(`${a}.${u}`,l)}return!1}function i(n,s){const a=groupBy(s,h=>h.name.value);for(const[h,v]of a)v.length>1&&r.reportError(new GraphQLError(`Argument "${n}(${h}:)" can only be defined once.`,{nodes:v.map(hi=>hi.name)}));return!1}}function UniqueArgumentNamesRule(r){return{Field:t,Directive:t};function t(i){var n;const s=(n=i.arguments)!==null&&n!==void 0?n:[],a=groupBy(s,h=>h.name.value);for(const[h,v]of a)v.length>1&&r.reportError(new GraphQLError(`There can be only one argument named "${h}".`,{nodes:v.map(hi=>hi.name)}))}}function UniqueDirectiveNamesRule(r){const t=Object.create(null),i=r.getSchema();return{DirectiveDefinition(n){const s=n.name.value;if(i!=null&&i.getDirective(s)){r.reportError(new GraphQLError(`Directive "@${s}" already exists in the schema. It cannot be redefined.`,{nodes:n.name}));return}return t[s]?r.reportError(new GraphQLError(`There can be only one directive named "@${s}".`,{nodes:[t[s],n.name]})):t[s]=n.name,!1}}}function UniqueDirectivesPerLocationRule(r){const t=Object.create(null),i=r.getSchema(),n=i?i.getDirectives():specifiedDirectives;for(const v of n)t[v.name]=!v.isRepeatable;const s=r.getDocument().definitions;for(const v of s)v.kind===Kind.DIRECTIVE_DEFINITION&&(t[v.name.value]=!v.repeatable);const a=Object.create(null),h=Object.create(null);return{enter(v){if(!("directives"in v)||!v.directives)return;let hi;if(v.kind===Kind.SCHEMA_DEFINITION||v.kind===Kind.SCHEMA_EXTENSION)hi=a;else if(isTypeDefinitionNode(v)||isTypeExtensionNode(v)){const u=v.name.value;hi=h[u],hi===void 0&&(h[u]=hi=Object.create(null))}else hi=Object.create(null);for(const u of v.directives){const l=u.name.value;t[l]&&(hi[l]?r.reportError(new GraphQLError(`The directive "@${l}" can only be used once at this location.`,{nodes:[hi[l],u]})):hi[l]=u)}}}}function UniqueEnumValueNamesRule(r){const t=r.getSchema(),i=t?t.getTypeMap():Object.create(null),n=Object.create(null);return{EnumTypeDefinition:s,EnumTypeExtension:s};function s(a){var h;const v=a.name.value;n[v]||(n[v]=Object.create(null));const hi=(h=a.values)!==null&&h!==void 0?h:[],u=n[v];for(const l of hi){const vi=l.name.value,D=i[v];isEnumType(D)&&D.getValue(vi)?r.reportError(new GraphQLError(`Enum value "${v}.${vi}" already exists in the schema. It cannot also be defined in this type extension.`,{nodes:l.name})):u[vi]?r.reportError(new GraphQLError(`Enum value "${v}.${vi}" can only be defined once.`,{nodes:[u[vi],l.name]})):u[vi]=l.name}return!1}}function UniqueFieldDefinitionNamesRule(r){const t=r.getSchema(),i=t?t.getTypeMap():Object.create(null),n=Object.create(null);return{InputObjectTypeDefinition:s,InputObjectTypeExtension:s,InterfaceTypeDefinition:s,InterfaceTypeExtension:s,ObjectTypeDefinition:s,ObjectTypeExtension:s};function s(a){var h;const v=a.name.value;n[v]||(n[v]=Object.create(null));const hi=(h=a.fields)!==null&&h!==void 0?h:[],u=n[v];for(const l of hi){const vi=l.name.value;hasField(i[v],vi)?r.reportError(new GraphQLError(`Field "${v}.${vi}" already exists in the schema. It cannot also be defined in this type extension.`,{nodes:l.name})):u[vi]?r.reportError(new GraphQLError(`Field "${v}.${vi}" can only be defined once.`,{nodes:[u[vi],l.name]})):u[vi]=l.name}return!1}}function hasField(r,t){return isObjectType(r)||isInterfaceType(r)||isInputObjectType(r)?r.getFields()[t]!=null:!1}function UniqueFragmentNamesRule(r){const t=Object.create(null);return{OperationDefinition:()=>!1,FragmentDefinition(i){const n=i.name.value;return t[n]?r.reportError(new GraphQLError(`There can be only one fragment named "${n}".`,{nodes:[t[n],i.name]})):t[n]=i.name,!1}}}function UniqueInputFieldNamesRule(r){const t=[];let i=Object.create(null);return{ObjectValue:{enter(){t.push(i),i=Object.create(null)},leave(){const n=t.pop();n||invariant(!1),i=n}},ObjectField(n){const s=n.name.value;i[s]?r.reportError(new GraphQLError(`There can be only one input field named "${s}".`,{nodes:[i[s],n.name]})):i[s]=n.name}}}function UniqueOperationNamesRule(r){const t=Object.create(null);return{OperationDefinition(i){const n=i.name;return n&&(t[n.value]?r.reportError(new GraphQLError(`There can be only one operation named "${n.value}".`,{nodes:[t[n.value],n]})):t[n.value]=n),!1},FragmentDefinition:()=>!1}}function UniqueOperationTypesRule(r){const t=r.getSchema(),i=Object.create(null),n=t?{query:t.getQueryType(),mutation:t.getMutationType(),subscription:t.getSubscriptionType()}:{};return{SchemaDefinition:s,SchemaExtension:s};function s(a){var h;const v=(h=a.operationTypes)!==null&&h!==void 0?h:[];for(const hi of v){const u=hi.operation,l=i[u];n[u]?r.reportError(new GraphQLError(`Type for ${u} already defined in the schema. It cannot be redefined.`,{nodes:hi})):l?r.reportError(new GraphQLError(`There can be only one ${u} type in schema.`,{nodes:[l,hi]})):i[u]=hi}return!1}}function UniqueTypeNamesRule(r){const t=Object.create(null),i=r.getSchema();return{ScalarTypeDefinition:n,ObjectTypeDefinition:n,InterfaceTypeDefinition:n,UnionTypeDefinition:n,EnumTypeDefinition:n,InputObjectTypeDefinition:n};function n(s){const a=s.name.value;if(i!=null&&i.getType(a)){r.reportError(new GraphQLError(`Type "${a}" already exists in the schema. It cannot also be defined in this type definition.`,{nodes:s.name}));return}return t[a]?r.reportError(new GraphQLError(`There can be only one type named "${a}".`,{nodes:[t[a],s.name]})):t[a]=s.name,!1}}function UniqueVariableNamesRule(r){return{OperationDefinition(t){var i;const n=(i=t.variableDefinitions)!==null&&i!==void 0?i:[],s=groupBy(n,a=>a.variable.name.value);for(const[a,h]of s)h.length>1&&r.reportError(new GraphQLError(`There can be only one variable named "$${a}".`,{nodes:h.map(v=>v.variable.name)}))}}}function ValuesOfCorrectTypeRule(r){let t={};return{OperationDefinition:{enter(){t={}}},VariableDefinition(i){t[i.variable.name.value]=i},ListValue(i){const n=getNullableType(r.getParentInputType());if(!isListType(n))return isValidValueNode(r,i),!1},ObjectValue(i){const n=getNamedType(r.getInputType());if(!isInputObjectType(n))return isValidValueNode(r,i),!1;const s=keyMap(i.fields,a=>a.name.value);for(const a of Object.values(n.getFields()))if(!s[a.name]&&isRequiredInputField(a)){const v=inspect(a.type);r.reportError(new GraphQLError(`Field "${n.name}.${a.name}" of required type "${v}" was not provided.`,{nodes:i}))}n.isOneOf&&validateOneOfInputObject(r,i,n,s,t)},ObjectField(i){const n=getNamedType(r.getParentInputType());if(!r.getInputType()&&isInputObjectType(n)){const a=suggestionList(i.name.value,Object.keys(n.getFields()));r.reportError(new GraphQLError(`Field "${i.name.value}" is not defined by type "${n.name}".`+didYouMean(a),{nodes:i}))}},NullValue(i){const n=r.getInputType();isNonNullType(n)&&r.reportError(new GraphQLError(`Expected value of type "${inspect(n)}", found ${print(i)}.`,{nodes:i}))},EnumValue:i=>isValidValueNode(r,i),IntValue:i=>isValidValueNode(r,i),FloatValue:i=>isValidValueNode(r,i),StringValue:i=>isValidValueNode(r,i),BooleanValue:i=>isValidValueNode(r,i)}}function isValidValueNode(r,t){const i=r.getInputType();if(!i)return;const n=getNamedType(i);if(!isLeafType(n)){const s=inspect(i);r.reportError(new GraphQLError(`Expected value of type "${s}", found ${print(t)}.`,{nodes:t}));return}try{if(n.parseLiteral(t,void 0)===void 0){const a=inspect(i);r.reportError(new GraphQLError(`Expected value of type "${a}", found ${print(t)}.`,{nodes:t}))}}catch(s){const a=inspect(i);s instanceof GraphQLError?r.reportError(s):r.reportError(new GraphQLError(`Expected value of type "${a}", found ${print(t)}; `+s.message,{nodes:t,originalError:s}))}}function validateOneOfInputObject(r,t,i,n,s){var a;const h=Object.keys(n);if(h.length!==1){r.reportError(new GraphQLError(`OneOf Input Object "${i.name}" must specify exactly one key.`,{nodes:[t]}));return}const hi=(a=n[h[0]])===null||a===void 0?void 0:a.value,u=!hi||hi.kind===Kind.NULL,l=hi?.kind===Kind.VARIABLE;if(u){r.reportError(new GraphQLError(`Field "${i.name}.${h[0]}" must be non-null.`,{nodes:[t]}));return}if(l){const vi=hi.name.value;s[vi].type.kind!==Kind.NON_NULL_TYPE&&r.reportError(new GraphQLError(`Variable "${vi}" must be non-nullable to be used for OneOf Input Object "${i.name}".`,{nodes:[t]}))}}function VariablesAreInputTypesRule(r){return{VariableDefinition(t){const i=typeFromAST(r.getSchema(),t.type);if(i!==void 0&&!isInputType(i)){const n=t.variable.name.value,s=print(t.type);r.reportError(new GraphQLError(`Variable "$${n}" cannot be non-input type "${s}".`,{nodes:t.type}))}}}}function VariablesInAllowedPositionRule(r){let t=Object.create(null);return{OperationDefinition:{enter(){t=Object.create(null)},leave(i){const n=r.getRecursiveVariableUsages(i);for(const{node:s,type:a,defaultValue:h}of n){const v=s.name.value,hi=t[v];if(hi&&a){const u=r.getSchema(),l=typeFromAST(u,hi.type);if(l&&!allowedVariableUsage(u,l,hi.defaultValue,a,h)){const vi=inspect(l),D=inspect(a);r.reportError(new GraphQLError(`Variable "$${v}" of type "${vi}" used in position expecting type "${D}".`,{nodes:[hi,s]}))}}}}},VariableDefinition(i){t[i.variable.name.value]=i}}}function allowedVariableUsage(r,t,i,n,s){if(isNonNullType(n)&&!isNonNullType(t)){if(!(i!=null&&i.kind!==Kind.NULL)&&!(s!==void 0))return!1;const v=n.ofType;return isTypeSubTypeOf(r,t,v)}return isTypeSubTypeOf(r,t,n)}const recommendedRules=Object.freeze([MaxIntrospectionDepthRule]),specifiedRules=Object.freeze([ExecutableDefinitionsRule,UniqueOperationNamesRule,LoneAnonymousOperationRule,SingleFieldSubscriptionsRule,KnownTypeNamesRule,FragmentsOnCompositeTypesRule,VariablesAreInputTypesRule,ScalarLeafsRule,FieldsOnCorrectTypeRule,UniqueFragmentNamesRule,KnownFragmentNamesRule,NoUnusedFragmentsRule,PossibleFragmentSpreadsRule,NoFragmentCyclesRule,UniqueVariableNamesRule,NoUndefinedVariablesRule,NoUnusedVariablesRule,KnownDirectivesRule,UniqueDirectivesPerLocationRule,KnownArgumentNamesRule,UniqueArgumentNamesRule,ValuesOfCorrectTypeRule,ProvidedRequiredArgumentsRule,VariablesInAllowedPositionRule,OverlappingFieldsCanBeMergedRule,UniqueInputFieldNamesRule,...recommendedRules]),specifiedSDLRules=Object.freeze([LoneSchemaDefinitionRule,UniqueOperationTypesRule,UniqueTypeNamesRule,UniqueEnumValueNamesRule,UniqueFieldDefinitionNamesRule,UniqueArgumentDefinitionNamesRule,UniqueDirectiveNamesRule,KnownTypeNamesRule,KnownDirectivesRule,UniqueDirectivesPerLocationRule,PossibleTypeExtensionsRule,KnownArgumentNamesOnDirectivesRule,UniqueArgumentNamesRule,UniqueInputFieldNamesRule,ProvidedRequiredArgumentsOnDirectivesRule]);class ASTValidationContext{constructor(t,i){this._ast=t,this._fragments=void 0,this._fragmentSpreads=new Map,this._recursivelyReferencedFragments=new Map,this._onError=i}get[Symbol.toStringTag](){return"ASTValidationContext"}reportError(t){this._onError(t)}getDocument(){return this._ast}getFragment(t){let i;if(this._fragments)i=this._fragments;else{i=Object.create(null);for(const n of this.getDocument().definitions)n.kind===Kind.FRAGMENT_DEFINITION&&(i[n.name.value]=n);this._fragments=i}return i[t]}getFragmentSpreads(t){let i=this._fragmentSpreads.get(t);if(!i){i=[];const n=[t];let s;for(;s=n.pop();)for(const a of s.selections)a.kind===Kind.FRAGMENT_SPREAD?i.push(a):a.selectionSet&&n.push(a.selectionSet);this._fragmentSpreads.set(t,i)}return i}getRecursivelyReferencedFragments(t){let i=this._recursivelyReferencedFragments.get(t);if(!i){i=[];const n=Object.create(null),s=[t.selectionSet];let a;for(;a=s.pop();)for(const h of this.getFragmentSpreads(a)){const v=h.name.value;if(n[v]!==!0){n[v]=!0;const hi=this.getFragment(v);hi&&(i.push(hi),s.push(hi.selectionSet))}}this._recursivelyReferencedFragments.set(t,i)}return i}}class SDLValidationContext extends ASTValidationContext{constructor(t,i,n){super(t,n),this._schema=i}get[Symbol.toStringTag](){return"SDLValidationContext"}getSchema(){return this._schema}}class ValidationContext extends ASTValidationContext{constructor(t,i,n,s){super(i,s),this._schema=t,this._typeInfo=n,this._variableUsages=new Map,this._recursiveVariableUsages=new Map}get[Symbol.toStringTag](){return"ValidationContext"}getSchema(){return this._schema}getVariableUsages(t){let i=this._variableUsages.get(t);if(!i){const n=[],s=new TypeInfo(this._schema);visit(t,visitWithTypeInfo(s,{VariableDefinition:()=>!1,Variable(a){n.push({node:a,type:s.getInputType(),defaultValue:s.getDefaultValue()})}})),i=n,this._variableUsages.set(t,i)}return i}getRecursiveVariableUsages(t){let i=this._recursiveVariableUsages.get(t);if(!i){i=this.getVariableUsages(t);for(const n of this.getRecursivelyReferencedFragments(t))i=i.concat(this.getVariableUsages(n));this._recursiveVariableUsages.set(t,i)}return i}getType(){return this._typeInfo.getType()}getParentType(){return this._typeInfo.getParentType()}getInputType(){return this._typeInfo.getInputType()}getParentInputType(){return this._typeInfo.getParentInputType()}getFieldDef(){return this._typeInfo.getFieldDef()}getDirective(){return this._typeInfo.getDirective()}getArgument(){return this._typeInfo.getArgument()}getEnumValue(){return this._typeInfo.getEnumValue()}}function validate(r,t,i=specifiedRules,n,s=new TypeInfo(r)){var a;const h=(a=n?.maxErrors)!==null&&a!==void 0?a:100;t||devAssert(!1,"Must provide document."),assertValidSchema(r);const v=Object.freeze({}),hi=[],u=new ValidationContext(r,t,s,vi=>{if(hi.length>=h)throw hi.push(new GraphQLError("Too many validation errors, error limit reached. Validation aborted.")),v;hi.push(vi)}),l=visitInParallel(i.map(vi=>vi(u)));try{visit(t,visitWithTypeInfo(s,l))}catch(vi){if(vi!==v)throw vi}return hi}function validateSDL(r,t,i=specifiedSDLRules){const n=[],s=new SDLValidationContext(r,t,h=>{n.push(h)}),a=i.map(h=>h(s));return visit(r,visitInParallel(a)),n}function assertValidSDL(r){const t=validateSDL(r);if(t.length!==0)throw new Error(t.map(i=>i.message).join(`
180
+
181
+ `))}function assertValidSDLExtension(r,t){const i=validateSDL(r,t);if(i.length!==0)throw new Error(i.map(n=>n.message).join(`
182
+
183
+ `))}function memoize3(r){let t;return function(n,s,a){t===void 0&&(t=new WeakMap);let h=t.get(n);h===void 0&&(h=new WeakMap,t.set(n,h));let v=h.get(s);v===void 0&&(v=new WeakMap,h.set(s,v));let hi=v.get(a);return hi===void 0&&(hi=r(n,s,a),v.set(a,hi)),hi}}function promiseForObject(r){return Promise.all(Object.values(r)).then(t=>{const i=Object.create(null);for(const[n,s]of Object.keys(r).entries())i[s]=t[n];return i})}function promiseReduce(r,t,i){let n=i;for(const s of r)n=isPromise(n)?n.then(a=>t(a,s)):t(n,s);return n}function toError(r){return r instanceof Error?r:new NonErrorThrown(r)}class NonErrorThrown extends Error{constructor(t){super("Unexpected error value: "+inspect(t)),this.name="NonErrorThrown",this.thrownValue=t}}function locatedError(r,t,i){var n;const s=toError(r);return isLocatedGraphQLError(s)?s:new GraphQLError(s.message,{nodes:(n=s.nodes)!==null&&n!==void 0?n:t,source:s.source,positions:s.positions,path:i,originalError:s})}function isLocatedGraphQLError(r){return Array.isArray(r.path)}const collectSubfields=memoize3((r,t,i)=>collectSubfields$1(r.schema,r.fragments,r.variableValues,t,i));function execute(r){arguments.length<2||devAssert(!1,"graphql@16 dropped long-deprecated support for positional arguments, please pass an object instead.");const{schema:t,document:i,variableValues:n,rootValue:s}=r;assertValidExecutionArguments(t,i,n);const a=buildExecutionContext(r);if(!("schema"in a))return{errors:a};try{const{operation:h}=a,v=executeOperation(a,h,s);return isPromise(v)?v.then(hi=>buildResponse(hi,a.errors),hi=>(a.errors.push(hi),buildResponse(null,a.errors))):buildResponse(v,a.errors)}catch(h){return a.errors.push(h),buildResponse(null,a.errors)}}function executeSync(r){const t=execute(r);if(isPromise(t))throw new Error("GraphQL execution failed to complete synchronously.");return t}function buildResponse(r,t){return t.length===0?{data:r}:{errors:t,data:r}}function assertValidExecutionArguments(r,t,i){t||devAssert(!1,"Must provide document."),assertValidSchema(r),i==null||isObjectLike(i)||devAssert(!1,"Variables must be provided as an Object where each property is a variable value. Perhaps look to see if an unparsed JSON string was provided.")}function buildExecutionContext(r){var t,i;const{schema:n,document:s,rootValue:a,contextValue:h,variableValues:v,operationName:hi,fieldResolver:u,typeResolver:l,subscribeFieldResolver:vi}=r;let D;const mi=Object.create(null);for(const Ri of s.definitions)switch(Ri.kind){case Kind.OPERATION_DEFINITION:if(hi==null){if(D!==void 0)return[new GraphQLError("Must provide operation name if query contains multiple operations.")];D=Ri}else((t=Ri.name)===null||t===void 0?void 0:t.value)===hi&&(D=Ri);break;case Kind.FRAGMENT_DEFINITION:mi[Ri.name.value]=Ri;break}if(!D)return hi!=null?[new GraphQLError(`Unknown operation named "${hi}".`)]:[new GraphQLError("Must provide an operation.")];const gi=(i=D.variableDefinitions)!==null&&i!==void 0?i:[],bi=getVariableValues(n,gi,v??{},{maxErrors:50});return bi.errors?bi.errors:{schema:n,fragments:mi,rootValue:a,contextValue:h,operation:D,variableValues:bi.coerced,fieldResolver:u??defaultFieldResolver,typeResolver:l??defaultTypeResolver,subscribeFieldResolver:vi??defaultFieldResolver,errors:[]}}function executeOperation(r,t,i){const n=r.schema.getRootType(t.operation);if(n==null)throw new GraphQLError(`Schema is not configured to execute ${t.operation} operation.`,{nodes:t});const s=collectFields(r.schema,r.fragments,r.variableValues,n,t.selectionSet),a=void 0;switch(t.operation){case OperationTypeNode.QUERY:return executeFields(r,n,i,a,s);case OperationTypeNode.MUTATION:return executeFieldsSerially(r,n,i,a,s);case OperationTypeNode.SUBSCRIPTION:return executeFields(r,n,i,a,s)}}function executeFieldsSerially(r,t,i,n,s){return promiseReduce(s.entries(),(a,[h,v])=>{const hi=addPath(n,h,t.name),u=executeField(r,t,i,v,hi);return u===void 0?a:isPromise(u)?u.then(l=>(a[h]=l,a)):(a[h]=u,a)},Object.create(null))}function executeFields(r,t,i,n,s){const a=Object.create(null);let h=!1;try{for(const[v,hi]of s.entries()){const u=addPath(n,v,t.name),l=executeField(r,t,i,hi,u);l!==void 0&&(a[v]=l,isPromise(l)&&(h=!0))}}catch(v){if(h)return promiseForObject(a).finally(()=>{throw v});throw v}return h?promiseForObject(a):a}function executeField(r,t,i,n,s){var a;const h=getFieldDef(r.schema,t,n[0]);if(!h)return;const v=h.type,hi=(a=h.resolve)!==null&&a!==void 0?a:r.fieldResolver,u=buildResolveInfo(r,h,n,t,s);try{const l=getArgumentValues(h,n[0],r.variableValues),vi=r.contextValue,D=hi(i,l,vi,u);let mi;return isPromise(D)?mi=D.then(gi=>completeValue(r,v,n,u,s,gi)):mi=completeValue(r,v,n,u,s,D),isPromise(mi)?mi.then(void 0,gi=>{const bi=locatedError(gi,n,pathToArray(s));return handleFieldError(bi,v,r)}):mi}catch(l){const vi=locatedError(l,n,pathToArray(s));return handleFieldError(vi,v,r)}}function buildResolveInfo(r,t,i,n,s){return{fieldName:t.name,fieldNodes:i,returnType:t.type,parentType:n,path:s,schema:r.schema,fragments:r.fragments,rootValue:r.rootValue,operation:r.operation,variableValues:r.variableValues}}function handleFieldError(r,t,i){if(isNonNullType(t))throw r;return i.errors.push(r),null}function completeValue(r,t,i,n,s,a){if(a instanceof Error)throw a;if(isNonNullType(t)){const h=completeValue(r,t.ofType,i,n,s,a);if(h===null)throw new Error(`Cannot return null for non-nullable field ${n.parentType.name}.${n.fieldName}.`);return h}if(a==null)return null;if(isListType(t))return completeListValue(r,t,i,n,s,a);if(isLeafType(t))return completeLeafValue(t,a);if(isAbstractType(t))return completeAbstractValue(r,t,i,n,s,a);if(isObjectType(t))return completeObjectValue(r,t,i,n,s,a);invariant(!1,"Cannot complete value of unexpected output type: "+inspect(t))}function completeListValue(r,t,i,n,s,a){if(!isIterableObject(a))throw new GraphQLError(`Expected Iterable, but did not find one for field "${n.parentType.name}.${n.fieldName}".`);const h=t.ofType;let v=!1;const hi=Array.from(a,(u,l)=>{const vi=addPath(s,l,void 0);try{let D;return isPromise(u)?D=u.then(mi=>completeValue(r,h,i,n,vi,mi)):D=completeValue(r,h,i,n,vi,u),isPromise(D)?(v=!0,D.then(void 0,mi=>{const gi=locatedError(mi,i,pathToArray(vi));return handleFieldError(gi,h,r)})):D}catch(D){const mi=locatedError(D,i,pathToArray(vi));return handleFieldError(mi,h,r)}});return v?Promise.all(hi):hi}function completeLeafValue(r,t){const i=r.serialize(t);if(i==null)throw new Error(`Expected \`${inspect(r)}.serialize(${inspect(t)})\` to return non-nullable value, returned: ${inspect(i)}`);return i}function completeAbstractValue(r,t,i,n,s,a){var h;const v=(h=t.resolveType)!==null&&h!==void 0?h:r.typeResolver,hi=r.contextValue,u=v(a,hi,n,t);return isPromise(u)?u.then(l=>completeObjectValue(r,ensureValidRuntimeType(l,r,t,i,n,a),i,n,s,a)):completeObjectValue(r,ensureValidRuntimeType(u,r,t,i,n,a),i,n,s,a)}function ensureValidRuntimeType(r,t,i,n,s,a){if(r==null)throw new GraphQLError(`Abstract type "${i.name}" must resolve to an Object type at runtime for field "${s.parentType.name}.${s.fieldName}". Either the "${i.name}" type should provide a "resolveType" function or each possible type should provide an "isTypeOf" function.`,n);if(isObjectType(r))throw new GraphQLError("Support for returning GraphQLObjectType from resolveType was removed in graphql-js@16.0.0 please return type name instead.");if(typeof r!="string")throw new GraphQLError(`Abstract type "${i.name}" must resolve to an Object type at runtime for field "${s.parentType.name}.${s.fieldName}" with value ${inspect(a)}, received "${inspect(r)}".`);const h=t.schema.getType(r);if(h==null)throw new GraphQLError(`Abstract type "${i.name}" was resolved to a type "${r}" that does not exist inside the schema.`,{nodes:n});if(!isObjectType(h))throw new GraphQLError(`Abstract type "${i.name}" was resolved to a non-object type "${r}".`,{nodes:n});if(!t.schema.isSubType(i,h))throw new GraphQLError(`Runtime Object type "${h.name}" is not a possible type for "${i.name}".`,{nodes:n});return h}function completeObjectValue(r,t,i,n,s,a){const h=collectSubfields(r,t,i);if(t.isTypeOf){const v=t.isTypeOf(a,r.contextValue,n);if(isPromise(v))return v.then(hi=>{if(!hi)throw invalidReturnTypeError(t,a,i);return executeFields(r,t,a,s,h)});if(!v)throw invalidReturnTypeError(t,a,i)}return executeFields(r,t,a,s,h)}function invalidReturnTypeError(r,t,i){return new GraphQLError(`Expected value of type "${r.name}" but got: ${inspect(t)}.`,{nodes:i})}const defaultTypeResolver=function(r,t,i,n){if(isObjectLike(r)&&typeof r.__typename=="string")return r.__typename;const s=i.schema.getPossibleTypes(n),a=[];for(let h=0;h<s.length;h++){const v=s[h];if(v.isTypeOf){const hi=v.isTypeOf(r,t,i);if(isPromise(hi))a[h]=hi;else if(hi)return v.name}}if(a.length)return Promise.all(a).then(h=>{for(let v=0;v<h.length;v++)if(h[v])return s[v].name})},defaultFieldResolver=function(r,t,i,n){if(isObjectLike(r)||typeof r=="function"){const s=r[n.fieldName];return typeof s=="function"?r[n.fieldName](t,i,n):s}};function getFieldDef(r,t,i){const n=i.name.value;return n===SchemaMetaFieldDef.name&&r.getQueryType()===t?SchemaMetaFieldDef:n===TypeMetaFieldDef.name&&r.getQueryType()===t?TypeMetaFieldDef:n===TypeNameMetaFieldDef.name?TypeNameMetaFieldDef:t.getFields()[n]}function graphql$1(r){return new Promise(t=>t(graphqlImpl(r)))}function graphqlSync(r){const t=graphqlImpl(r);if(isPromise(t))throw new Error("GraphQL execution failed to complete synchronously.");return t}function graphqlImpl(r){arguments.length<2||devAssert(!1,"graphql@16 dropped long-deprecated support for positional arguments, please pass an object instead.");const{schema:t,source:i,rootValue:n,contextValue:s,variableValues:a,operationName:h,fieldResolver:v,typeResolver:hi}=r,u=validateSchema(t);if(u.length>0)return{errors:u};let l;try{l=parse(i)}catch(D){return{errors:[D]}}const vi=validate(t,l);return vi.length>0?{errors:vi}:execute({schema:t,document:l,rootValue:n,contextValue:s,variableValues:a,operationName:h,fieldResolver:v,typeResolver:hi})}function isAsyncIterable(r){return typeof r?.[Symbol.asyncIterator]=="function"}function mapAsyncIterator(r,t){const i=r[Symbol.asyncIterator]();async function n(s){if(s.done)return s;try{return{value:await t(s.value),done:!1}}catch(a){if(typeof i.return=="function")try{await i.return()}catch{}throw a}}return{async next(){return n(await i.next())},async return(){return typeof i.return=="function"?n(await i.return()):{value:void 0,done:!0}},async throw(s){if(typeof i.throw=="function")return n(await i.throw(s));throw s},[Symbol.asyncIterator](){return this}}}async function subscribe(r){arguments.length<2||devAssert(!1,"graphql@16 dropped long-deprecated support for positional arguments, please pass an object instead.");const t=await createSourceEventStream(r);return isAsyncIterable(t)?mapAsyncIterator(t,n=>execute({...r,rootValue:n})):t}function toNormalizedArgs(r){const t=r[0];return t&&"document"in t?t:{schema:t,document:r[1],rootValue:r[2],contextValue:r[3],variableValues:r[4],operationName:r[5],subscribeFieldResolver:r[6]}}async function createSourceEventStream(...r){const t=toNormalizedArgs(r),{schema:i,document:n,variableValues:s}=t;assertValidExecutionArguments(i,n,s);const a=buildExecutionContext(t);if(!("schema"in a))return{errors:a};try{const h=await executeSubscription(a);if(!isAsyncIterable(h))throw new Error(`Subscription field must return Async Iterable. Received: ${inspect(h)}.`);return h}catch(h){if(h instanceof GraphQLError)return{errors:[h]};throw h}}async function executeSubscription(r){const{schema:t,fragments:i,operation:n,variableValues:s,rootValue:a}=r,h=t.getSubscriptionType();if(h==null)throw new GraphQLError("Schema is not configured to execute subscription operation.",{nodes:n});const v=collectFields(t,i,s,h,n.selectionSet),[hi,u]=[...v.entries()][0],l=getFieldDef(t,h,u[0]);if(!l){const gi=u[0].name.value;throw new GraphQLError(`The subscription field "${gi}" is not defined.`,{nodes:u})}const vi=addPath(void 0,hi,h.name),D=buildResolveInfo(r,l,u,h,vi);try{var mi;const gi=getArgumentValues(l,u[0],s),bi=r.contextValue,Ti=await((mi=l.subscribe)!==null&&mi!==void 0?mi:r.subscribeFieldResolver)(a,gi,bi,D);if(Ti instanceof Error)throw Ti;return Ti}catch(gi){throw locatedError(gi,u,pathToArray(vi))}}function NoDeprecatedCustomRule(r){return{Field(t){const i=r.getFieldDef(),n=i?.deprecationReason;if(i&&n!=null){const s=r.getParentType();s!=null||invariant(!1),r.reportError(new GraphQLError(`The field ${s.name}.${i.name} is deprecated. ${n}`,{nodes:t}))}},Argument(t){const i=r.getArgument(),n=i?.deprecationReason;if(i&&n!=null){const s=r.getDirective();if(s!=null)r.reportError(new GraphQLError(`Directive "@${s.name}" argument "${i.name}" is deprecated. ${n}`,{nodes:t}));else{const a=r.getParentType(),h=r.getFieldDef();a!=null&&h!=null||invariant(!1),r.reportError(new GraphQLError(`Field "${a.name}.${h.name}" argument "${i.name}" is deprecated. ${n}`,{nodes:t}))}}},ObjectField(t){const i=getNamedType(r.getParentInputType());if(isInputObjectType(i)){const n=i.getFields()[t.name.value],s=n?.deprecationReason;s!=null&&r.reportError(new GraphQLError(`The input field ${i.name}.${n.name} is deprecated. ${s}`,{nodes:t}))}},EnumValue(t){const i=r.getEnumValue(),n=i?.deprecationReason;if(i&&n!=null){const s=getNamedType(r.getInputType());s!=null||invariant(!1),r.reportError(new GraphQLError(`The enum value "${s.name}.${i.name}" is deprecated. ${n}`,{nodes:t}))}}}}function NoSchemaIntrospectionCustomRule(r){return{Field(t){const i=getNamedType(r.getType());i&&isIntrospectionType(i)&&r.reportError(new GraphQLError(`GraphQL introspection has been disabled, but the requested query contained the field "${t.name.value}".`,{nodes:t}))}}}function getIntrospectionQuery(r){const t={descriptions:!0,specifiedByUrl:!1,directiveIsRepeatable:!1,schemaDescription:!1,inputValueDeprecation:!1,oneOf:!1,...r},i=t.descriptions?"description":"",n=t.specifiedByUrl?"specifiedByURL":"",s=t.directiveIsRepeatable?"isRepeatable":"",a=t.schemaDescription?i:"";function h(hi){return t.inputValueDeprecation?hi:""}const v=t.oneOf?"isOneOf":"";return`
184
+ query IntrospectionQuery {
185
+ __schema {
186
+ ${a}
187
+ queryType { name }
188
+ mutationType { name }
189
+ subscriptionType { name }
190
+ types {
191
+ ...FullType
192
+ }
193
+ directives {
194
+ name
195
+ ${i}
196
+ ${s}
197
+ locations
198
+ args${h("(includeDeprecated: true)")} {
199
+ ...InputValue
200
+ }
201
+ }
202
+ }
203
+ }
204
+
205
+ fragment FullType on __Type {
206
+ kind
207
+ name
208
+ ${i}
209
+ ${n}
210
+ ${v}
211
+ fields(includeDeprecated: true) {
212
+ name
213
+ ${i}
214
+ args${h("(includeDeprecated: true)")} {
215
+ ...InputValue
216
+ }
217
+ type {
218
+ ...TypeRef
219
+ }
220
+ isDeprecated
221
+ deprecationReason
222
+ }
223
+ inputFields${h("(includeDeprecated: true)")} {
224
+ ...InputValue
225
+ }
226
+ interfaces {
227
+ ...TypeRef
228
+ }
229
+ enumValues(includeDeprecated: true) {
230
+ name
231
+ ${i}
232
+ isDeprecated
233
+ deprecationReason
234
+ }
235
+ possibleTypes {
236
+ ...TypeRef
237
+ }
238
+ }
239
+
240
+ fragment InputValue on __InputValue {
241
+ name
242
+ ${i}
243
+ type { ...TypeRef }
244
+ defaultValue
245
+ ${h("isDeprecated")}
246
+ ${h("deprecationReason")}
247
+ }
248
+
249
+ fragment TypeRef on __Type {
250
+ kind
251
+ name
252
+ ofType {
253
+ kind
254
+ name
255
+ ofType {
256
+ kind
257
+ name
258
+ ofType {
259
+ kind
260
+ name
261
+ ofType {
262
+ kind
263
+ name
264
+ ofType {
265
+ kind
266
+ name
267
+ ofType {
268
+ kind
269
+ name
270
+ ofType {
271
+ kind
272
+ name
273
+ ofType {
274
+ kind
275
+ name
276
+ ofType {
277
+ kind
278
+ name
279
+ }
280
+ }
281
+ }
282
+ }
283
+ }
284
+ }
285
+ }
286
+ }
287
+ }
288
+ }
289
+ `}function getOperationAST(r,t){let i=null;for(const s of r.definitions)if(s.kind===Kind.OPERATION_DEFINITION){var n;if(t==null){if(i)return null;i=s}else if(((n=s.name)===null||n===void 0?void 0:n.value)===t)return s}return i}function getOperationRootType(r,t){if(t.operation==="query"){const i=r.getQueryType();if(!i)throw new GraphQLError("Schema does not define the required query root type.",{nodes:t});return i}if(t.operation==="mutation"){const i=r.getMutationType();if(!i)throw new GraphQLError("Schema is not configured for mutations.",{nodes:t});return i}if(t.operation==="subscription"){const i=r.getSubscriptionType();if(!i)throw new GraphQLError("Schema is not configured for subscriptions.",{nodes:t});return i}throw new GraphQLError("Can only have query, mutation and subscription operations.",{nodes:t})}function introspectionFromSchema(r,t){const i={specifiedByUrl:!0,directiveIsRepeatable:!0,schemaDescription:!0,inputValueDeprecation:!0,oneOf:!0,...t},n=parse(getIntrospectionQuery(i)),s=executeSync({schema:r,document:n});return!s.errors&&s.data||invariant(!1),s.data}function buildClientSchema(r,t){isObjectLike(r)&&isObjectLike(r.__schema)||devAssert(!1,`Invalid or incomplete introspection result. Ensure that you are passing "data" property of introspection response and no "errors" was returned alongside: ${inspect(r)}.`);const i=r.__schema,n=keyValMap(i.types,Ui=>Ui.name,Ui=>D(Ui));for(const Ui of[...specifiedScalarTypes,...introspectionTypes])n[Ui.name]&&(n[Ui.name]=Ui);const s=i.queryType?l(i.queryType):null,a=i.mutationType?l(i.mutationType):null,h=i.subscriptionType?l(i.subscriptionType):null,v=i.directives?i.directives.map(Hi):[];return new GraphQLSchema({description:i.description,query:s,mutation:a,subscription:h,types:Object.values(n),directives:v,assumeValid:t?.assumeValid});function hi(Ui){if(Ui.kind===TypeKind.LIST){const Qi=Ui.ofType;if(!Qi)throw new Error("Decorated type deeper than introspection query.");return new GraphQLList(hi(Qi))}if(Ui.kind===TypeKind.NON_NULL){const Qi=Ui.ofType;if(!Qi)throw new Error("Decorated type deeper than introspection query.");const $i=hi(Qi);return new GraphQLNonNull(assertNullableType($i))}return u(Ui)}function u(Ui){const Qi=Ui.name;if(!Qi)throw new Error(`Unknown type reference: ${inspect(Ui)}.`);const $i=n[Qi];if(!$i)throw new Error(`Invalid or incomplete schema, unknown type: ${Qi}. Ensure that a full introspection query is used in order to build a client schema.`);return $i}function l(Ui){return assertObjectType(u(Ui))}function vi(Ui){return assertInterfaceType(u(Ui))}function D(Ui){if(Ui!=null&&Ui.name!=null&&Ui.kind!=null)switch(Ui.kind){case TypeKind.SCALAR:return mi(Ui);case TypeKind.OBJECT:return bi(Ui);case TypeKind.INTERFACE:return Ri(Ui);case TypeKind.UNION:return Ti(Ui);case TypeKind.ENUM:return Ii(Ui);case TypeKind.INPUT_OBJECT:return qi(Ui)}const Qi=inspect(Ui);throw new Error(`Invalid or incomplete introspection result. Ensure that a full introspection query is used in order to build a client schema: ${Qi}.`)}function mi(Ui){return new GraphQLScalarType({name:Ui.name,description:Ui.description,specifiedByURL:Ui.specifiedByURL})}function gi(Ui){if(Ui.interfaces===null&&Ui.kind===TypeKind.INTERFACE)return[];if(!Ui.interfaces){const Qi=inspect(Ui);throw new Error(`Introspection result missing interfaces: ${Qi}.`)}return Ui.interfaces.map(vi)}function bi(Ui){return new GraphQLObjectType({name:Ui.name,description:Ui.description,interfaces:()=>gi(Ui),fields:()=>Oi(Ui)})}function Ri(Ui){return new GraphQLInterfaceType({name:Ui.name,description:Ui.description,interfaces:()=>gi(Ui),fields:()=>Oi(Ui)})}function Ti(Ui){if(!Ui.possibleTypes){const Qi=inspect(Ui);throw new Error(`Introspection result missing possibleTypes: ${Qi}.`)}return new GraphQLUnionType({name:Ui.name,description:Ui.description,types:()=>Ui.possibleTypes.map(l)})}function Ii(Ui){if(!Ui.enumValues){const Qi=inspect(Ui);throw new Error(`Introspection result missing enumValues: ${Qi}.`)}return new GraphQLEnumType({name:Ui.name,description:Ui.description,values:keyValMap(Ui.enumValues,Qi=>Qi.name,Qi=>({description:Qi.description,deprecationReason:Qi.deprecationReason}))})}function qi(Ui){if(!Ui.inputFields){const Qi=inspect(Ui);throw new Error(`Introspection result missing inputFields: ${Qi}.`)}return new GraphQLInputObjectType({name:Ui.name,description:Ui.description,fields:()=>Li(Ui.inputFields),isOneOf:Ui.isOneOf})}function Oi(Ui){if(!Ui.fields)throw new Error(`Introspection result missing fields: ${inspect(Ui)}.`);return keyValMap(Ui.fields,Qi=>Qi.name,ki)}function ki(Ui){const Qi=hi(Ui.type);if(!isOutputType(Qi)){const $i=inspect(Qi);throw new Error(`Introspection must provide output type for fields, but received: ${$i}.`)}if(!Ui.args){const $i=inspect(Ui);throw new Error(`Introspection result missing field args: ${$i}.`)}return{description:Ui.description,deprecationReason:Ui.deprecationReason,type:Qi,args:Li(Ui.args)}}function Li(Ui){return keyValMap(Ui,Qi=>Qi.name,ji)}function ji(Ui){const Qi=hi(Ui.type);if(!isInputType(Qi)){const wi=inspect(Qi);throw new Error(`Introspection must provide input type for arguments, but received: ${wi}.`)}const $i=Ui.defaultValue!=null?valueFromAST(parseValue(Ui.defaultValue),Qi):void 0;return{description:Ui.description,type:Qi,defaultValue:$i,deprecationReason:Ui.deprecationReason}}function Hi(Ui){if(!Ui.args){const Qi=inspect(Ui);throw new Error(`Introspection result missing directive args: ${Qi}.`)}if(!Ui.locations){const Qi=inspect(Ui);throw new Error(`Introspection result missing directive locations: ${Qi}.`)}return new GraphQLDirective({name:Ui.name,description:Ui.description,isRepeatable:Ui.isRepeatable,locations:Ui.locations.slice(),args:Li(Ui.args)})}}function extendSchema(r,t,i){assertSchema(r),t!=null&&t.kind===Kind.DOCUMENT||devAssert(!1,"Must provide valid Document AST."),i?.assumeValid!==!0&&i?.assumeValidSDL!==!0&&assertValidSDLExtension(t,r);const n=r.toConfig(),s=extendSchemaImpl(n,t,i);return n===s?r:new GraphQLSchema(s)}function extendSchemaImpl(r,t,i){var n,s,a,h;const v=[],hi=Object.create(null),u=[];let l;const vi=[];for(const _i of t.definitions)if(_i.kind===Kind.SCHEMA_DEFINITION)l=_i;else if(_i.kind===Kind.SCHEMA_EXTENSION)vi.push(_i);else if(isTypeDefinitionNode(_i))v.push(_i);else if(isTypeExtensionNode(_i)){const Bi=_i.name.value,Pi=hi[Bi];hi[Bi]=Pi?Pi.concat([_i]):[_i]}else _i.kind===Kind.DIRECTIVE_DEFINITION&&u.push(_i);if(Object.keys(hi).length===0&&v.length===0&&u.length===0&&vi.length===0&&l==null)return r;const D=Object.create(null);for(const _i of r.types)D[_i.name]=Ii(_i);for(const _i of v){var mi;const Bi=_i.name.value;D[Bi]=(mi=stdTypeMap[Bi])!==null&&mi!==void 0?mi:Ai(_i)}const gi={query:r.query&&Ri(r.query),mutation:r.mutation&&Ri(r.mutation),subscription:r.subscription&&Ri(r.subscription),...l&&$i([l]),...$i(vi)};return{description:(n=l)===null||n===void 0||(s=n.description)===null||s===void 0?void 0:s.value,...gi,types:Object.values(D),directives:[...r.directives.map(Ti),...u.map(yi)],extensions:Object.create(null),astNode:(a=l)!==null&&a!==void 0?a:r.astNode,extensionASTNodes:r.extensionASTNodes.concat(vi),assumeValid:(h=i?.assumeValid)!==null&&h!==void 0?h:!1};function bi(_i){return isListType(_i)?new GraphQLList(bi(_i.ofType)):isNonNullType(_i)?new GraphQLNonNull(bi(_i.ofType)):Ri(_i)}function Ri(_i){return D[_i.name]}function Ti(_i){const Bi=_i.toConfig();return new GraphQLDirective({...Bi,args:mapValue(Bi.args,Qi)})}function Ii(_i){if(isIntrospectionType(_i)||isSpecifiedScalarType(_i))return _i;if(isScalarType(_i))return ki(_i);if(isObjectType(_i))return Li(_i);if(isInterfaceType(_i))return ji(_i);if(isUnionType(_i))return Hi(_i);if(isEnumType(_i))return Oi(_i);if(isInputObjectType(_i))return qi(_i);invariant(!1,"Unexpected type: "+inspect(_i))}function qi(_i){var Bi;const Pi=_i.toConfig(),zi=(Bi=hi[Pi.name])!==null&&Bi!==void 0?Bi:[];return new GraphQLInputObjectType({...Pi,fields:()=>({...mapValue(Pi.fields,Gi=>({...Gi,type:bi(Gi.type)})),...Ni(zi)}),extensionASTNodes:Pi.extensionASTNodes.concat(zi)})}function Oi(_i){var Bi;const Pi=_i.toConfig(),zi=(Bi=hi[_i.name])!==null&&Bi!==void 0?Bi:[];return new GraphQLEnumType({...Pi,values:{...Pi.values,...Fi(zi)},extensionASTNodes:Pi.extensionASTNodes.concat(zi)})}function ki(_i){var Bi;const Pi=_i.toConfig(),zi=(Bi=hi[Pi.name])!==null&&Bi!==void 0?Bi:[];let Gi=Pi.specifiedByURL;for(const Ki of zi){var Vi;Gi=(Vi=getSpecifiedByURL(Ki))!==null&&Vi!==void 0?Vi:Gi}return new GraphQLScalarType({...Pi,specifiedByURL:Gi,extensionASTNodes:Pi.extensionASTNodes.concat(zi)})}function Li(_i){var Bi;const Pi=_i.toConfig(),zi=(Bi=hi[Pi.name])!==null&&Bi!==void 0?Bi:[];return new GraphQLObjectType({...Pi,interfaces:()=>[..._i.getInterfaces().map(Ri),...Mi(zi)],fields:()=>({...mapValue(Pi.fields,Ui),...Ei(zi)}),extensionASTNodes:Pi.extensionASTNodes.concat(zi)})}function ji(_i){var Bi;const Pi=_i.toConfig(),zi=(Bi=hi[Pi.name])!==null&&Bi!==void 0?Bi:[];return new GraphQLInterfaceType({...Pi,interfaces:()=>[..._i.getInterfaces().map(Ri),...Mi(zi)],fields:()=>({...mapValue(Pi.fields,Ui),...Ei(zi)}),extensionASTNodes:Pi.extensionASTNodes.concat(zi)})}function Hi(_i){var Bi;const Pi=_i.toConfig(),zi=(Bi=hi[Pi.name])!==null&&Bi!==void 0?Bi:[];return new GraphQLUnionType({...Pi,types:()=>[..._i.getTypes().map(Ri),...Si(zi)],extensionASTNodes:Pi.extensionASTNodes.concat(zi)})}function Ui(_i){return{..._i,type:bi(_i.type),args:_i.args&&mapValue(_i.args,Qi)}}function Qi(_i){return{..._i,type:bi(_i.type)}}function $i(_i){const Bi={};for(const zi of _i){var Pi;const Gi=(Pi=zi.operationTypes)!==null&&Pi!==void 0?Pi:[];for(const Vi of Gi)Bi[Vi.operation]=wi(Vi.type)}return Bi}function wi(_i){var Bi;const Pi=_i.name.value,zi=(Bi=stdTypeMap[Pi])!==null&&Bi!==void 0?Bi:D[Pi];if(zi===void 0)throw new Error(`Unknown type: "${Pi}".`);return zi}function xi(_i){return _i.kind===Kind.LIST_TYPE?new GraphQLList(xi(_i.type)):_i.kind===Kind.NON_NULL_TYPE?new GraphQLNonNull(xi(_i.type)):wi(_i)}function yi(_i){var Bi;return new GraphQLDirective({name:_i.name.value,description:(Bi=_i.description)===null||Bi===void 0?void 0:Bi.value,locations:_i.locations.map(({value:Pi})=>Pi),isRepeatable:_i.repeatable,args:Ci(_i.arguments),astNode:_i})}function Ei(_i){const Bi=Object.create(null);for(const Gi of _i){var Pi;const Vi=(Pi=Gi.fields)!==null&&Pi!==void 0?Pi:[];for(const Ki of Vi){var zi;Bi[Ki.name.value]={type:xi(Ki.type),description:(zi=Ki.description)===null||zi===void 0?void 0:zi.value,args:Ci(Ki.arguments),deprecationReason:getDeprecationReason(Ki),astNode:Ki}}}return Bi}function Ci(_i){const Bi=_i??[],Pi=Object.create(null);for(const Gi of Bi){var zi;const Vi=xi(Gi.type);Pi[Gi.name.value]={type:Vi,description:(zi=Gi.description)===null||zi===void 0?void 0:zi.value,defaultValue:valueFromAST(Gi.defaultValue,Vi),deprecationReason:getDeprecationReason(Gi),astNode:Gi}}return Pi}function Ni(_i){const Bi=Object.create(null);for(const Gi of _i){var Pi;const Vi=(Pi=Gi.fields)!==null&&Pi!==void 0?Pi:[];for(const Ki of Vi){var zi;const Zi=xi(Ki.type);Bi[Ki.name.value]={type:Zi,description:(zi=Ki.description)===null||zi===void 0?void 0:zi.value,defaultValue:valueFromAST(Ki.defaultValue,Zi),deprecationReason:getDeprecationReason(Ki),astNode:Ki}}}return Bi}function Fi(_i){const Bi=Object.create(null);for(const Gi of _i){var Pi;const Vi=(Pi=Gi.values)!==null&&Pi!==void 0?Pi:[];for(const Ki of Vi){var zi;Bi[Ki.name.value]={description:(zi=Ki.description)===null||zi===void 0?void 0:zi.value,deprecationReason:getDeprecationReason(Ki),astNode:Ki}}}return Bi}function Mi(_i){return _i.flatMap(Bi=>{var Pi,zi;return(Pi=(zi=Bi.interfaces)===null||zi===void 0?void 0:zi.map(wi))!==null&&Pi!==void 0?Pi:[]})}function Si(_i){return _i.flatMap(Bi=>{var Pi,zi;return(Pi=(zi=Bi.types)===null||zi===void 0?void 0:zi.map(wi))!==null&&Pi!==void 0?Pi:[]})}function Ai(_i){var Bi;const Pi=_i.name.value,zi=(Bi=hi[Pi])!==null&&Bi!==void 0?Bi:[];switch(_i.kind){case Kind.OBJECT_TYPE_DEFINITION:{var Gi;const Xi=[_i,...zi];return new GraphQLObjectType({name:Pi,description:(Gi=_i.description)===null||Gi===void 0?void 0:Gi.value,interfaces:()=>Mi(Xi),fields:()=>Ei(Xi),astNode:_i,extensionASTNodes:zi})}case Kind.INTERFACE_TYPE_DEFINITION:{var Vi;const Xi=[_i,...zi];return new GraphQLInterfaceType({name:Pi,description:(Vi=_i.description)===null||Vi===void 0?void 0:Vi.value,interfaces:()=>Mi(Xi),fields:()=>Ei(Xi),astNode:_i,extensionASTNodes:zi})}case Kind.ENUM_TYPE_DEFINITION:{var Ki;const Xi=[_i,...zi];return new GraphQLEnumType({name:Pi,description:(Ki=_i.description)===null||Ki===void 0?void 0:Ki.value,values:Fi(Xi),astNode:_i,extensionASTNodes:zi})}case Kind.UNION_TYPE_DEFINITION:{var Zi;const Xi=[_i,...zi];return new GraphQLUnionType({name:Pi,description:(Zi=_i.description)===null||Zi===void 0?void 0:Zi.value,types:()=>Si(Xi),astNode:_i,extensionASTNodes:zi})}case Kind.SCALAR_TYPE_DEFINITION:{var In;return new GraphQLScalarType({name:Pi,description:(In=_i.description)===null||In===void 0?void 0:In.value,specifiedByURL:getSpecifiedByURL(_i),astNode:_i,extensionASTNodes:zi})}case Kind.INPUT_OBJECT_TYPE_DEFINITION:{var Ji;const Xi=[_i,...zi];return new GraphQLInputObjectType({name:Pi,description:(Ji=_i.description)===null||Ji===void 0?void 0:Ji.value,fields:()=>Ni(Xi),astNode:_i,extensionASTNodes:zi,isOneOf:isOneOf(_i)})}}}}const stdTypeMap=keyMap([...specifiedScalarTypes,...introspectionTypes],r=>r.name);function getDeprecationReason(r){const t=getDirectiveValues(GraphQLDeprecatedDirective,r);return t?.reason}function getSpecifiedByURL(r){const t=getDirectiveValues(GraphQLSpecifiedByDirective,r);return t?.url}function isOneOf(r){return!!getDirectiveValues(GraphQLOneOfDirective,r)}function buildASTSchema(r,t){r!=null&&r.kind===Kind.DOCUMENT||devAssert(!1,"Must provide valid Document AST."),t?.assumeValid!==!0&&t?.assumeValidSDL!==!0&&assertValidSDL(r);const n=extendSchemaImpl({description:void 0,types:[],directives:[],extensions:Object.create(null),extensionASTNodes:[],assumeValid:!1},r,t);if(n.astNode==null)for(const a of n.types)switch(a.name){case"Query":n.query=a;break;case"Mutation":n.mutation=a;break;case"Subscription":n.subscription=a;break}const s=[...n.directives,...specifiedDirectives.filter(a=>n.directives.every(h=>h.name!==a.name))];return new GraphQLSchema({...n,directives:s})}function buildSchema(r,t){const i=parse(r,{noLocation:t?.noLocation,allowLegacyFragmentVariables:t?.allowLegacyFragmentVariables});return buildASTSchema(i,{assumeValidSDL:t?.assumeValidSDL,assumeValid:t?.assumeValid})}function lexicographicSortSchema(r){const t=r.toConfig(),i=keyValMap(sortByName(t.types),D=>D.name,vi);return new GraphQLSchema({...t,types:Object.values(i),directives:sortByName(t.directives).map(h),query:a(t.query),mutation:a(t.mutation),subscription:a(t.subscription)});function n(D){return isListType(D)?new GraphQLList(n(D.ofType)):isNonNullType(D)?new GraphQLNonNull(n(D.ofType)):s(D)}function s(D){return i[D.name]}function a(D){return D&&s(D)}function h(D){const mi=D.toConfig();return new GraphQLDirective({...mi,locations:sortBy(mi.locations,gi=>gi),args:v(mi.args)})}function v(D){return sortObjMap(D,mi=>({...mi,type:n(mi.type)}))}function hi(D){return sortObjMap(D,mi=>({...mi,type:n(mi.type),args:mi.args&&v(mi.args)}))}function u(D){return sortObjMap(D,mi=>({...mi,type:n(mi.type)}))}function l(D){return sortByName(D).map(s)}function vi(D){if(isScalarType(D)||isIntrospectionType(D))return D;if(isObjectType(D)){const mi=D.toConfig();return new GraphQLObjectType({...mi,interfaces:()=>l(mi.interfaces),fields:()=>hi(mi.fields)})}if(isInterfaceType(D)){const mi=D.toConfig();return new GraphQLInterfaceType({...mi,interfaces:()=>l(mi.interfaces),fields:()=>hi(mi.fields)})}if(isUnionType(D)){const mi=D.toConfig();return new GraphQLUnionType({...mi,types:()=>l(mi.types)})}if(isEnumType(D)){const mi=D.toConfig();return new GraphQLEnumType({...mi,values:sortObjMap(mi.values,gi=>gi)})}if(isInputObjectType(D)){const mi=D.toConfig();return new GraphQLInputObjectType({...mi,fields:()=>u(mi.fields)})}invariant(!1,"Unexpected type: "+inspect(D))}}function sortObjMap(r,t){const i=Object.create(null);for(const n of Object.keys(r).sort(naturalCompare))i[n]=t(r[n]);return i}function sortByName(r){return sortBy(r,t=>t.name)}function sortBy(r,t){return r.slice().sort((i,n)=>{const s=t(i),a=t(n);return naturalCompare(s,a)})}function printSchema(r){return printFilteredSchema(r,t=>!isSpecifiedDirective(t),isDefinedType)}function printIntrospectionSchema(r){return printFilteredSchema(r,isSpecifiedDirective,isIntrospectionType)}function isDefinedType(r){return!isSpecifiedScalarType(r)&&!isIntrospectionType(r)}function printFilteredSchema(r,t,i){const n=r.getDirectives().filter(t),s=Object.values(r.getTypeMap()).filter(i);return[printSchemaDefinition(r),...n.map(a=>printDirective(a)),...s.map(a=>printType(a))].filter(Boolean).join(`
290
+
291
+ `)}function printSchemaDefinition(r){if(r.description==null&&isSchemaOfCommonNames(r))return;const t=[],i=r.getQueryType();i&&t.push(` query: ${i.name}`);const n=r.getMutationType();n&&t.push(` mutation: ${n.name}`);const s=r.getSubscriptionType();return s&&t.push(` subscription: ${s.name}`),printDescription(r)+`schema {
292
+ ${t.join(`
293
+ `)}
294
+ }`}function isSchemaOfCommonNames(r){const t=r.getQueryType();if(t&&t.name!=="Query")return!1;const i=r.getMutationType();if(i&&i.name!=="Mutation")return!1;const n=r.getSubscriptionType();return!(n&&n.name!=="Subscription")}function printType(r){if(isScalarType(r))return printScalar(r);if(isObjectType(r))return printObject(r);if(isInterfaceType(r))return printInterface(r);if(isUnionType(r))return printUnion(r);if(isEnumType(r))return printEnum(r);if(isInputObjectType(r))return printInputObject(r);invariant(!1,"Unexpected type: "+inspect(r))}function printScalar(r){return printDescription(r)+`scalar ${r.name}`+printSpecifiedByURL(r)}function printImplementedInterfaces(r){const t=r.getInterfaces();return t.length?" implements "+t.map(i=>i.name).join(" & "):""}function printObject(r){return printDescription(r)+`type ${r.name}`+printImplementedInterfaces(r)+printFields(r)}function printInterface(r){return printDescription(r)+`interface ${r.name}`+printImplementedInterfaces(r)+printFields(r)}function printUnion(r){const t=r.getTypes(),i=t.length?" = "+t.join(" | "):"";return printDescription(r)+"union "+r.name+i}function printEnum(r){const t=r.getValues().map((i,n)=>printDescription(i," ",!n)+" "+i.name+printDeprecated(i.deprecationReason));return printDescription(r)+`enum ${r.name}`+printBlock(t)}function printInputObject(r){const t=Object.values(r.getFields()).map((i,n)=>printDescription(i," ",!n)+" "+printInputValue(i));return printDescription(r)+`input ${r.name}`+(r.isOneOf?" @oneOf":"")+printBlock(t)}function printFields(r){const t=Object.values(r.getFields()).map((i,n)=>printDescription(i," ",!n)+" "+i.name+printArgs(i.args," ")+": "+String(i.type)+printDeprecated(i.deprecationReason));return printBlock(t)}function printBlock(r){return r.length!==0?` {
295
+ `+r.join(`
296
+ `)+`
297
+ }`:""}function printArgs(r,t=""){return r.length===0?"":r.every(i=>!i.description)?"("+r.map(printInputValue).join(", ")+")":`(
298
+ `+r.map((i,n)=>printDescription(i," "+t,!n)+" "+t+printInputValue(i)).join(`
299
+ `)+`
300
+ `+t+")"}function printInputValue(r){const t=astFromValue(r.defaultValue,r.type);let i=r.name+": "+String(r.type);return t&&(i+=` = ${print(t)}`),i+printDeprecated(r.deprecationReason)}function printDirective(r){return printDescription(r)+"directive @"+r.name+printArgs(r.args)+(r.isRepeatable?" repeatable":"")+" on "+r.locations.join(" | ")}function printDeprecated(r){return r==null?"":r!==DEFAULT_DEPRECATION_REASON?` @deprecated(reason: ${print({kind:Kind.STRING,value:r})})`:" @deprecated"}function printSpecifiedByURL(r){return r.specifiedByURL==null?"":` @specifiedBy(url: ${print({kind:Kind.STRING,value:r.specifiedByURL})})`}function printDescription(r,t="",i=!0){const{description:n}=r;if(n==null)return"";const s=print({kind:Kind.STRING,value:n,block:isPrintableAsBlockString(n)});return(t&&!i?`
301
+ `+t:t)+s.replace(/\n/g,`
302
+ `+t)+`
303
+ `}function concatAST(r){const t=[];for(const i of r)t.push(...i.definitions);return{kind:Kind.DOCUMENT,definitions:t}}function separateOperations(r){const t=[],i=Object.create(null);for(const s of r.definitions)switch(s.kind){case Kind.OPERATION_DEFINITION:t.push(s);break;case Kind.FRAGMENT_DEFINITION:i[s.name.value]=collectDependencies(s.selectionSet);break}const n=Object.create(null);for(const s of t){const a=new Set;for(const v of collectDependencies(s.selectionSet))collectTransitiveDependencies(a,i,v);const h=s.name?s.name.value:"";n[h]={kind:Kind.DOCUMENT,definitions:r.definitions.filter(v=>v===s||v.kind===Kind.FRAGMENT_DEFINITION&&a.has(v.name.value))}}return n}function collectTransitiveDependencies(r,t,i){if(!r.has(i)){r.add(i);const n=t[i];if(n!==void 0)for(const s of n)collectTransitiveDependencies(r,t,s)}}function collectDependencies(r){const t=[];return visit(r,{FragmentSpread(i){t.push(i.name.value)}}),t}function stripIgnoredCharacters(r){const t=isSource(r)?r:new Source(r),i=t.body,n=new Lexer(t);let s="",a=!1;for(;n.advance().kind!==TokenKind.EOF;){const h=n.token,v=h.kind,hi=!isPunctuatorTokenKind(h.kind);a&&(hi||h.kind===TokenKind.SPREAD)&&(s+=" ");const u=i.slice(h.start,h.end);v===TokenKind.BLOCK_STRING?s+=printBlockString(h.value,{minimize:!0}):s+=u,a=hi}return s}function assertValidName(r){const t=isValidNameError(r);if(t)throw t;return r}function isValidNameError(r){if(typeof r=="string"||devAssert(!1,"Expected name to be a string."),r.startsWith("__"))return new GraphQLError(`Name "${r}" must not begin with "__", which is reserved by GraphQL introspection.`);try{assertName(r)}catch(t){return t}}var BreakingChangeType;(function(r){r.TYPE_REMOVED="TYPE_REMOVED",r.TYPE_CHANGED_KIND="TYPE_CHANGED_KIND",r.TYPE_REMOVED_FROM_UNION="TYPE_REMOVED_FROM_UNION",r.VALUE_REMOVED_FROM_ENUM="VALUE_REMOVED_FROM_ENUM",r.REQUIRED_INPUT_FIELD_ADDED="REQUIRED_INPUT_FIELD_ADDED",r.IMPLEMENTED_INTERFACE_REMOVED="IMPLEMENTED_INTERFACE_REMOVED",r.FIELD_REMOVED="FIELD_REMOVED",r.FIELD_CHANGED_KIND="FIELD_CHANGED_KIND",r.REQUIRED_ARG_ADDED="REQUIRED_ARG_ADDED",r.ARG_REMOVED="ARG_REMOVED",r.ARG_CHANGED_KIND="ARG_CHANGED_KIND",r.DIRECTIVE_REMOVED="DIRECTIVE_REMOVED",r.DIRECTIVE_ARG_REMOVED="DIRECTIVE_ARG_REMOVED",r.REQUIRED_DIRECTIVE_ARG_ADDED="REQUIRED_DIRECTIVE_ARG_ADDED",r.DIRECTIVE_REPEATABLE_REMOVED="DIRECTIVE_REPEATABLE_REMOVED",r.DIRECTIVE_LOCATION_REMOVED="DIRECTIVE_LOCATION_REMOVED"})(BreakingChangeType||(BreakingChangeType={}));var DangerousChangeType;(function(r){r.VALUE_ADDED_TO_ENUM="VALUE_ADDED_TO_ENUM",r.TYPE_ADDED_TO_UNION="TYPE_ADDED_TO_UNION",r.OPTIONAL_INPUT_FIELD_ADDED="OPTIONAL_INPUT_FIELD_ADDED",r.OPTIONAL_ARG_ADDED="OPTIONAL_ARG_ADDED",r.IMPLEMENTED_INTERFACE_ADDED="IMPLEMENTED_INTERFACE_ADDED",r.ARG_DEFAULT_VALUE_CHANGE="ARG_DEFAULT_VALUE_CHANGE"})(DangerousChangeType||(DangerousChangeType={}));function findBreakingChanges(r,t){return findSchemaChanges(r,t).filter(i=>i.type in BreakingChangeType)}function findDangerousChanges(r,t){return findSchemaChanges(r,t).filter(i=>i.type in DangerousChangeType)}function findSchemaChanges(r,t){return[...findTypeChanges(r,t),...findDirectiveChanges(r,t)]}function findDirectiveChanges(r,t){const i=[],n=diff(r.getDirectives(),t.getDirectives());for(const s of n.removed)i.push({type:BreakingChangeType.DIRECTIVE_REMOVED,description:`${s.name} was removed.`});for(const[s,a]of n.persisted){const h=diff(s.args,a.args);for(const v of h.added)isRequiredArgument(v)&&i.push({type:BreakingChangeType.REQUIRED_DIRECTIVE_ARG_ADDED,description:`A required arg ${v.name} on directive ${s.name} was added.`});for(const v of h.removed)i.push({type:BreakingChangeType.DIRECTIVE_ARG_REMOVED,description:`${v.name} was removed from ${s.name}.`});s.isRepeatable&&!a.isRepeatable&&i.push({type:BreakingChangeType.DIRECTIVE_REPEATABLE_REMOVED,description:`Repeatable flag was removed from ${s.name}.`});for(const v of s.locations)a.locations.includes(v)||i.push({type:BreakingChangeType.DIRECTIVE_LOCATION_REMOVED,description:`${v} was removed from ${s.name}.`})}return i}function findTypeChanges(r,t){const i=[],n=diff(Object.values(r.getTypeMap()),Object.values(t.getTypeMap()));for(const s of n.removed)i.push({type:BreakingChangeType.TYPE_REMOVED,description:isSpecifiedScalarType(s)?`Standard scalar ${s.name} was removed because it is not referenced anymore.`:`${s.name} was removed.`});for(const[s,a]of n.persisted)isEnumType(s)&&isEnumType(a)?i.push(...findEnumTypeChanges(s,a)):isUnionType(s)&&isUnionType(a)?i.push(...findUnionTypeChanges(s,a)):isInputObjectType(s)&&isInputObjectType(a)?i.push(...findInputObjectTypeChanges(s,a)):isObjectType(s)&&isObjectType(a)?i.push(...findFieldChanges(s,a),...findImplementedInterfacesChanges(s,a)):isInterfaceType(s)&&isInterfaceType(a)?i.push(...findFieldChanges(s,a),...findImplementedInterfacesChanges(s,a)):s.constructor!==a.constructor&&i.push({type:BreakingChangeType.TYPE_CHANGED_KIND,description:`${s.name} changed from ${typeKindName(s)} to ${typeKindName(a)}.`});return i}function findInputObjectTypeChanges(r,t){const i=[],n=diff(Object.values(r.getFields()),Object.values(t.getFields()));for(const s of n.added)isRequiredInputField(s)?i.push({type:BreakingChangeType.REQUIRED_INPUT_FIELD_ADDED,description:`A required field ${s.name} on input type ${r.name} was added.`}):i.push({type:DangerousChangeType.OPTIONAL_INPUT_FIELD_ADDED,description:`An optional field ${s.name} on input type ${r.name} was added.`});for(const s of n.removed)i.push({type:BreakingChangeType.FIELD_REMOVED,description:`${r.name}.${s.name} was removed.`});for(const[s,a]of n.persisted)isChangeSafeForInputObjectFieldOrFieldArg(s.type,a.type)||i.push({type:BreakingChangeType.FIELD_CHANGED_KIND,description:`${r.name}.${s.name} changed type from ${String(s.type)} to ${String(a.type)}.`});return i}function findUnionTypeChanges(r,t){const i=[],n=diff(r.getTypes(),t.getTypes());for(const s of n.added)i.push({type:DangerousChangeType.TYPE_ADDED_TO_UNION,description:`${s.name} was added to union type ${r.name}.`});for(const s of n.removed)i.push({type:BreakingChangeType.TYPE_REMOVED_FROM_UNION,description:`${s.name} was removed from union type ${r.name}.`});return i}function findEnumTypeChanges(r,t){const i=[],n=diff(r.getValues(),t.getValues());for(const s of n.added)i.push({type:DangerousChangeType.VALUE_ADDED_TO_ENUM,description:`${s.name} was added to enum type ${r.name}.`});for(const s of n.removed)i.push({type:BreakingChangeType.VALUE_REMOVED_FROM_ENUM,description:`${s.name} was removed from enum type ${r.name}.`});return i}function findImplementedInterfacesChanges(r,t){const i=[],n=diff(r.getInterfaces(),t.getInterfaces());for(const s of n.added)i.push({type:DangerousChangeType.IMPLEMENTED_INTERFACE_ADDED,description:`${s.name} added to interfaces implemented by ${r.name}.`});for(const s of n.removed)i.push({type:BreakingChangeType.IMPLEMENTED_INTERFACE_REMOVED,description:`${r.name} no longer implements interface ${s.name}.`});return i}function findFieldChanges(r,t){const i=[],n=diff(Object.values(r.getFields()),Object.values(t.getFields()));for(const s of n.removed)i.push({type:BreakingChangeType.FIELD_REMOVED,description:`${r.name}.${s.name} was removed.`});for(const[s,a]of n.persisted)i.push(...findArgChanges(r,s,a)),isChangeSafeForObjectOrInterfaceField(s.type,a.type)||i.push({type:BreakingChangeType.FIELD_CHANGED_KIND,description:`${r.name}.${s.name} changed type from ${String(s.type)} to ${String(a.type)}.`});return i}function findArgChanges(r,t,i){const n=[],s=diff(t.args,i.args);for(const a of s.removed)n.push({type:BreakingChangeType.ARG_REMOVED,description:`${r.name}.${t.name} arg ${a.name} was removed.`});for(const[a,h]of s.persisted)if(!isChangeSafeForInputObjectFieldOrFieldArg(a.type,h.type))n.push({type:BreakingChangeType.ARG_CHANGED_KIND,description:`${r.name}.${t.name} arg ${a.name} has changed type from ${String(a.type)} to ${String(h.type)}.`});else if(a.defaultValue!==void 0)if(h.defaultValue===void 0)n.push({type:DangerousChangeType.ARG_DEFAULT_VALUE_CHANGE,description:`${r.name}.${t.name} arg ${a.name} defaultValue was removed.`});else{const hi=stringifyValue(a.defaultValue,a.type),u=stringifyValue(h.defaultValue,h.type);hi!==u&&n.push({type:DangerousChangeType.ARG_DEFAULT_VALUE_CHANGE,description:`${r.name}.${t.name} arg ${a.name} has changed defaultValue from ${hi} to ${u}.`})}for(const a of s.added)isRequiredArgument(a)?n.push({type:BreakingChangeType.REQUIRED_ARG_ADDED,description:`A required arg ${a.name} on ${r.name}.${t.name} was added.`}):n.push({type:DangerousChangeType.OPTIONAL_ARG_ADDED,description:`An optional arg ${a.name} on ${r.name}.${t.name} was added.`});return n}function isChangeSafeForObjectOrInterfaceField(r,t){return isListType(r)?isListType(t)&&isChangeSafeForObjectOrInterfaceField(r.ofType,t.ofType)||isNonNullType(t)&&isChangeSafeForObjectOrInterfaceField(r,t.ofType):isNonNullType(r)?isNonNullType(t)&&isChangeSafeForObjectOrInterfaceField(r.ofType,t.ofType):isNamedType(t)&&r.name===t.name||isNonNullType(t)&&isChangeSafeForObjectOrInterfaceField(r,t.ofType)}function isChangeSafeForInputObjectFieldOrFieldArg(r,t){return isListType(r)?isListType(t)&&isChangeSafeForInputObjectFieldOrFieldArg(r.ofType,t.ofType):isNonNullType(r)?isNonNullType(t)&&isChangeSafeForInputObjectFieldOrFieldArg(r.ofType,t.ofType)||!isNonNullType(t)&&isChangeSafeForInputObjectFieldOrFieldArg(r.ofType,t):isNamedType(t)&&r.name===t.name}function typeKindName(r){if(isScalarType(r))return"a Scalar type";if(isObjectType(r))return"an Object type";if(isInterfaceType(r))return"an Interface type";if(isUnionType(r))return"a Union type";if(isEnumType(r))return"an Enum type";if(isInputObjectType(r))return"an Input type";invariant(!1,"Unexpected type: "+inspect(r))}function stringifyValue(r,t){const i=astFromValue(r,t);return i!=null||invariant(!1),print(sortValueNode(i))}function diff(r,t){const i=[],n=[],s=[],a=keyMap(r,({name:v})=>v),h=keyMap(t,({name:v})=>v);for(const v of r){const hi=h[v.name];hi===void 0?n.push(v):s.push([v,hi])}for(const v of t)a[v.name]===void 0&&i.push(v);return{added:i,persisted:s,removed:n}}var graphql=Object.freeze({__proto__:null,BREAK,get BreakingChangeType(){return BreakingChangeType},DEFAULT_DEPRECATION_REASON,get DangerousChangeType(){return DangerousChangeType},get DirectiveLocation(){return DirectiveLocation},ExecutableDefinitionsRule,FieldsOnCorrectTypeRule,FragmentsOnCompositeTypesRule,GRAPHQL_MAX_INT,GRAPHQL_MIN_INT,GraphQLBoolean,GraphQLDeprecatedDirective,GraphQLDirective,GraphQLEnumType,GraphQLError,GraphQLFloat,GraphQLID,GraphQLIncludeDirective,GraphQLInputObjectType,GraphQLInt,GraphQLInterfaceType,GraphQLList,GraphQLNonNull,GraphQLObjectType,GraphQLOneOfDirective,GraphQLScalarType,GraphQLSchema,GraphQLSkipDirective,GraphQLSpecifiedByDirective,GraphQLString,GraphQLUnionType,get Kind(){return Kind},KnownArgumentNamesRule,KnownDirectivesRule,KnownFragmentNamesRule,KnownTypeNamesRule,Lexer,Location:Location$1,LoneAnonymousOperationRule,LoneSchemaDefinitionRule,MaxIntrospectionDepthRule,NoDeprecatedCustomRule,NoFragmentCyclesRule,NoSchemaIntrospectionCustomRule,NoUndefinedVariablesRule,NoUnusedFragmentsRule,NoUnusedVariablesRule,get OperationTypeNode(){return OperationTypeNode},OverlappingFieldsCanBeMergedRule,PossibleFragmentSpreadsRule,PossibleTypeExtensionsRule,ProvidedRequiredArgumentsRule,ScalarLeafsRule,SchemaMetaFieldDef,SingleFieldSubscriptionsRule,Source,Token,get TokenKind(){return TokenKind},TypeInfo,get TypeKind(){return TypeKind},TypeMetaFieldDef,TypeNameMetaFieldDef,UniqueArgumentDefinitionNamesRule,UniqueArgumentNamesRule,UniqueDirectiveNamesRule,UniqueDirectivesPerLocationRule,UniqueEnumValueNamesRule,UniqueFieldDefinitionNamesRule,UniqueFragmentNamesRule,UniqueInputFieldNamesRule,UniqueOperationNamesRule,UniqueOperationTypesRule,UniqueTypeNamesRule,UniqueVariableNamesRule,ValidationContext,ValuesOfCorrectTypeRule,VariablesAreInputTypesRule,VariablesInAllowedPositionRule,__Directive,__DirectiveLocation,__EnumValue,__Field,__InputValue,__Schema,__Type,__TypeKind,assertAbstractType,assertCompositeType,assertDirective,assertEnumType,assertEnumValueName,assertInputObjectType,assertInputType,assertInterfaceType,assertLeafType,assertListType,assertName,assertNamedType,assertNonNullType,assertNullableType,assertObjectType,assertOutputType,assertScalarType,assertSchema,assertType,assertUnionType,assertValidName,assertValidSchema,assertWrappingType,astFromValue,buildASTSchema,buildClientSchema,buildSchema,coerceInputValue,concatAST,createSourceEventStream,defaultFieldResolver,defaultTypeResolver,doTypesOverlap,execute,executeSync,extendSchema,findBreakingChanges,findDangerousChanges,formatError,getArgumentValues,getDirectiveValues,getEnterLeaveForKind,getIntrospectionQuery,getLocation,getNamedType,getNullableType,getOperationAST,getOperationRootType,getVariableValues,getVisitFn,graphql:graphql$1,graphqlSync,introspectionFromSchema,introspectionTypes,isAbstractType,isCompositeType,isConstValueNode,isDefinitionNode,isDirective,isEnumType,isEqualType,isExecutableDefinitionNode,isInputObjectType,isInputType,isInterfaceType,isIntrospectionType,isLeafType,isListType,isNamedType,isNonNullType,isNullableType,isObjectType,isOutputType,isRequiredArgument,isRequiredInputField,isScalarType,isSchema,isSelectionNode,isSpecifiedDirective,isSpecifiedScalarType,isType,isTypeDefinitionNode,isTypeExtensionNode,isTypeNode,isTypeSubTypeOf,isTypeSystemDefinitionNode,isTypeSystemExtensionNode,isUnionType,isValidNameError,isValueNode,isWrappingType,lexicographicSortSchema,locatedError,parse,parseConstValue,parseType,parseValue,print,printError,printIntrospectionSchema,printLocation,printSchema,printSourceLocation,printType,recommendedRules,resolveObjMapThunk,resolveReadonlyArrayThunk,responsePathAsArray:pathToArray,separateOperations,specifiedDirectives,specifiedRules,specifiedScalarTypes,stripIgnoredCharacters,subscribe,syntaxError,typeFromAST,validate,validateSchema,valueFromAST,valueFromASTUntyped,version,versionInfo,visit,visitInParallel,visitWithTypeInfo});function isObject(r){return typeof r=="object"&&r!==null}var ControlChars;(function(r){r[r.NewLine=10]="NewLine",r[r.CchunkiageReturn=13]="CchunkiageReturn",r[r.Space=32]="Space",r[r.Colon=58]="Colon"})(ControlChars||(ControlChars={}));function createParser(){let r,t,i,n=!1,s={event:"",data:""},a=[];const h=new TextDecoder;return function(hi){if(r===void 0)r=hi,t=0,i=-1;else{const vi=new Uint8Array(r.length+hi.length);vi.set(r),vi.set(hi,r.length),r=vi}const u=r.length;let l=0;for(;t<u;){n&&(r[t]===ControlChars.NewLine&&(l=++t),n=!1);let vi=-1;for(;t<u&&vi===-1;++t)switch(r[t]){case ControlChars.Colon:i===-1&&(i=t-l);break;case ControlChars.CchunkiageReturn:n=!0;case ControlChars.NewLine:vi=t;break}if(vi===-1)break;if(l===vi){if(s.event||s.data){if(!s.event)throw new Error("Missing message event");const D=validateStreamEvent(s.event),mi=parseStreamData(D,s.data);a.push({event:D,data:mi}),s={event:"",data:""}}}else if(i>0){const D=r.subarray(l,vi),mi=h.decode(D.subarray(0,i)),gi=i+(D[i+1]===ControlChars.Space?2:1),bi=h.decode(D.subarray(gi));switch(mi){case"event":s.event=bi;break;case"data":s.data=s.data?s.data+`
304
+ `+bi:bi;break}}l=t,i=-1}if(l===u){r=void 0;const vi=[...a];return a=[],vi}else l!==0&&(r=r.subarray(l),t-=l)}}var __asyncValues=function(r){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=r[Symbol.asyncIterator],i;return t?t.call(r):(r=typeof __values=="function"?__values(r):r[Symbol.iterator](),i={},n("next"),n("throw"),n("return"),i[Symbol.asyncIterator]=function(){return this},i);function n(a){i[a]=r[a]&&function(h){return new Promise(function(v,hi){h=r[a](h),s(v,hi,h.done,h.value)})}}function s(a,h,v,hi){Promise.resolve(hi).then(function(u){a({value:u,done:v})},h)}},__await=function(r){return this instanceof __await?(this.v=r,this):new __await(r)},__asyncGenerator=function(r,t,i){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n=i.apply(r,t||[]),s,a=[];return s={},h("next"),h("throw"),h("return"),s[Symbol.asyncIterator]=function(){return this},s;function h(D){n[D]&&(s[D]=function(mi){return new Promise(function(gi,bi){a.push([D,mi,gi,bi])>1||v(D,mi)})})}function v(D,mi){try{hi(n[D](mi))}catch(gi){vi(a[0][3],gi)}}function hi(D){D.value instanceof __await?Promise.resolve(D.value.v).then(u,l):vi(a[0][2],D)}function u(D){v("next",D)}function l(D){v("throw",D)}function vi(D,mi){D(mi),a.shift(),a.length&&v(a[0][0],a[0][1])}};function createClient(r){const{singleConnection:t=!1,lazy:i=!0,lazyCloseTimeout:n=0,onNonLazyError:s=console.error,generateID:a=function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,Li=>{const ji=Math.random()*16|0;return(Li=="x"?ji:ji&3|8).toString(16)})},retryAttempts:h=5,retry:v=async function(Li){let ji=1e3;for(let Hi=0;Hi<Li;Hi++)ji*=2;await new Promise(Hi=>setTimeout(Hi,ji+Math.floor(Math.random()*2700+300)))},credentials:hi="same-origin",referrer:u,referrerPolicy:l,onMessage:vi}=r,D=r.fetchFn||fetch,mi=r.abortControllerImpl||AbortController,gi=(()=>{let ki=!1;const Li=[];return{get disposed(){return ki},onDispose(ji){return ki?(setTimeout(()=>ji(),0),()=>{}):(Li.push(ji),()=>{Li.splice(Li.indexOf(ji),1)})},dispose(){if(!ki){ki=!0;for(const ji of[...Li])ji()}}}})();let bi,Ri,Ti=0,Ii=null,qi=0;async function Oi(){try{if(gi.disposed)throw new Error("Client has been disposed");return await(Ri??(Ri=(async()=>{var ki;if(Ii){if(await v(qi),bi.signal.aborted)throw new Error("Connection aborted by the client");qi++}bi=new mi;const Li=gi.onDispose(()=>bi.abort());bi.signal.addEventListener("abort",()=>{Li(),Ri=void 0});const ji=typeof r.url=="function"?await r.url():r.url;if(bi.signal.aborted)throw new Error("Connection aborted by the client");const Hi=typeof r.headers=="function"?await r.headers():(ki=r.headers)!==null&&ki!==void 0?ki:{};if(bi.signal.aborted)throw new Error("Connection aborted by the client");let Ui;try{Ui=await D(ji,{signal:bi.signal,method:"PUT",credentials:hi,referrer:u,referrerPolicy:l,headers:Hi})}catch(wi){throw new NetworkError(wi)}if(Ui.status!==201)throw new NetworkError(Ui);const Qi=await Ui.text();Hi[TOKEN_HEADER_KEY]=Qi;const $i=await connect({signal:bi.signal,headers:Hi,credentials:hi,referrer:u,referrerPolicy:l,url:ji,fetchFn:D,onMessage:vi});return Ii=null,qi=0,$i.waitForThrow().catch(()=>Ri=void 0),$i})()))}catch(ki){throw Ri=void 0,ki}}return t&&!i&&(async()=>{for(Ti++;;)try{const{waitForThrow:ki}=await Oi();await ki()}catch(ki){if(gi.disposed)return;if(!(ki instanceof NetworkError)||(Ri=void 0,!h||qi>=h))return s?.(ki);Ii=ki}})(),{subscribe(ki,Li){if(!t){const Ui=new mi,Qi=gi.onDispose(()=>{Qi(),Ui.abort()});return(async()=>{var $i,wi,xi,yi,Ei;let Ci=null,Ni=0;for(;;)try{if(Ci){if(await v(Ni),Ui.signal.aborted)throw new Error("Connection aborted by the client");Ni++}const Ai=typeof r.url=="function"?await r.url():r.url;if(Ui.signal.aborted)throw new Error("Connection aborted by the client");const _i=typeof r.headers=="function"?await r.headers():(Ei=r.headers)!==null&&Ei!==void 0?Ei:{};if(Ui.signal.aborted)throw new Error("Connection aborted by the client");const{getResults:Bi}=await connect({signal:Ui.signal,headers:Object.assign(Object.assign({},_i),{"content-type":"application/json; charset=utf-8"}),credentials:hi,referrer:u,referrerPolicy:l,url:Ai,body:JSON.stringify(ki),fetchFn:D,onMessage:vi});Ci=null,Ni=0;try{for(var Fi=!0,Mi=(wi=void 0,__asyncValues(Bi())),Si;Si=await Mi.next(),$i=Si.done,!$i;){yi=Si.value,Fi=!1;try{const Pi=yi;Li.next(Pi)}finally{Fi=!0}}}catch(Pi){wi={error:Pi}}finally{try{!Fi&&!$i&&(xi=Mi.return)&&await xi.call(Mi)}finally{if(wi)throw wi.error}}return Ui.abort()}catch(Ai){if(Ui.signal.aborted)return;if(!(Ai instanceof NetworkError)||!h||Ni>=h)throw Ai;Ci=Ai}})().then(()=>Li.complete()).catch($i=>Li.error($i)),()=>Ui.abort()}Ti++;const ji=new mi,Hi=gi.onDispose(()=>{Hi(),ji.abort()});return(async()=>{var Ui,Qi,$i,wi;const xi=a();ki=Object.assign(Object.assign({},ki),{extensions:Object.assign(Object.assign({},ki.extensions),{operationId:xi})});let yi=null;for(;;){yi=null;try{const{url:Fi,headers:Mi,getResults:Si}=await Oi();let Ai;try{Ai=await D(Fi,{signal:ji.signal,method:"POST",credentials:hi,referrer:u,referrerPolicy:l,headers:Object.assign(Object.assign({},Mi),{"content-type":"application/json; charset=utf-8"}),body:JSON.stringify(ki)})}catch(_i){throw new NetworkError(_i)}if(Ai.status!==202)throw new NetworkError(Ai);yi=async()=>{let _i;try{const Bi=new mi,Pi=gi.onDispose(()=>{Pi(),Bi.abort()});_i=await D(Fi+"?operationId="+xi,{signal:Bi.signal,method:"DELETE",credentials:hi,referrer:u,referrerPolicy:l,headers:Mi})}catch(Bi){throw new NetworkError(Bi)}if(_i.status!==200)throw new NetworkError(_i)};try{for(var Ei=!0,Ci=(Qi=void 0,__asyncValues(Si({signal:ji.signal,operationId:xi}))),Ni;Ni=await Ci.next(),Ui=Ni.done,!Ui;){wi=Ni.value,Ei=!1;try{const _i=wi;Li.next(_i)}finally{Ei=!0}}}catch(_i){Qi={error:_i}}finally{try{!Ei&&!Ui&&($i=Ci.return)&&await $i.call(Ci)}finally{if(Qi)throw Qi.error}}return yi=null,ji.abort()}catch(Fi){if(ji.signal.aborted)return await yi?.();if(!(Fi instanceof NetworkError)||(i&&(Ri=void 0),!h||qi>=h))throw ji.abort(),Fi;Ii=Fi}finally{ji.signal.aborted&&--Ti===0&&(isFinite(n)&&n>0?setTimeout(()=>{Ti||bi.abort()},n):bi.abort())}}})().then(()=>Li.complete()).catch(Ui=>Li.error(Ui)),()=>ji.abort()},dispose(){gi.dispose()}}}class NetworkError extends Error{constructor(t){let i,n;isResponseLike(t)?(n=t,i="Server responded with "+t.status+": "+t.statusText):t instanceof Error?i=t.message:i=String(t),super(i),this.name=this.constructor.name,this.response=n}}function isResponseLike(r){return isObject(r)&&typeof r.ok=="boolean"&&typeof r.status=="number"&&typeof r.statusText=="string"}async function connect(r){const{signal:t,url:i,credentials:n,headers:s,body:a,referrer:h,referrerPolicy:v,fetchFn:hi,onMessage:u}=r,l={},vi={};let D;try{D=await hi(i,{signal:t,method:a?"POST":"GET",credentials:n,referrer:h,referrerPolicy:v,headers:Object.assign(Object.assign({},s),{accept:"text/event-stream"}),body:a})}catch(bi){throw new NetworkError(bi)}if(!D.ok)throw new NetworkError(D);if(!D.body)throw new Error("Missing response body");let mi=null,gi;return(async()=>{var bi,Ri,Ti,Ii,qi;try{const ji=createParser();try{for(var Oi=!0,ki=__asyncValues(toAsyncIterator(D.body)),Li;Li=await ki.next(),bi=Li.done,!bi;){Ii=Li.value,Oi=!1;try{const Hi=Ii;if(typeof Hi=="string")throw mi=new Error(`Unexpected string chunk "${Hi}"`);let Ui;try{Ui=ji(Hi)}catch(Qi){throw mi=Qi}if(!Ui)continue;for(const Qi of Ui){try{u?.(Qi)}catch(wi){throw mi=wi}const $i=Qi.data&&"id"in Qi.data?Qi.data.id:"";switch($i in vi||(vi[$i]=[]),Qi.event){case"next":$i?vi[$i].push(Qi.data.payload):vi[$i].push(Qi.data);break;case"complete":vi[$i].push("complete");break;default:throw mi=new Error(`Unexpected message event "${Qi.event}"`)}(qi=l[$i])===null||qi===void 0||qi.proceed()}}finally{Oi=!0}}}catch(Hi){Ri={error:Hi}}finally{try{!Oi&&!bi&&(Ti=ki.return)&&await Ti.call(ki)}finally{if(Ri)throw Ri.error}}if(Object.keys(l).length)throw new Error("Connection closed while having active streams")}catch(ji){!mi&&Object.keys(l).length?mi=new NetworkError(ji):mi=ji,gi?.(mi)}finally{Object.values(l).forEach(({proceed:ji})=>ji())}})(),{url:i,headers:s,waitForThrow:()=>new Promise((bi,Ri)=>{if(mi)return Ri(mi);gi=Ri}),getResults(bi){var Ri;return __asyncGenerator(this,arguments,function*(){const{signal:Ii,operationId:qi=""}=bi??{};try{for(;;){for(;!((Ri=vi[qi])===null||Ri===void 0)&&Ri.length;){const Oi=vi[qi].shift();if(Oi==="complete")return yield __await(void 0);yield yield __await(Oi)}if(mi)throw mi;if(Ii?.aborted)throw new Error("Getting results aborted by the client");yield __await(new Promise(Oi=>{const ki=()=>{Ii?.removeEventListener("abort",ki),delete l[qi],Oi()};Ii?.addEventListener("abort",ki),l[qi]={proceed:ki}}))}}finally{delete vi[qi]}})}}}function toAsyncIterator(r){return typeof Object(r)[Symbol.asyncIterator]=="function"?(r=r,r[Symbol.asyncIterator]()):function(){return __asyncGenerator(this,arguments,function*(){const t=r.getReader();let i;do i=yield __await(t.read()),i.value!==void 0&&(yield yield __await(i.value));while(!i.done)})}()}async function e(r,t){if(!r.ok||!r.body||r.bodyUsed)return r;let i=r.headers.get("content-type");if(!i||!~i.indexOf("multipart/"))return r;let n=i.indexOf("boundary="),s="-";if(~n){let a=n+9,h=i.indexOf(";",a);s=i.slice(a,h>-1?h:void 0).trim().replace(/"/g,"")}return async function*(a,h,v){let hi,u,l,vi=new TextDecoder("utf8"),D=a.getReader(),mi=!0,gi=h.length,bi="",Ri=[];try{let Ti;e:for(;!(Ti=await D.read()).done;){let Ii=vi.decode(Ti.value,{stream:!0});hi=bi.length,bi+=Ii;let qi=Ii.indexOf(h);for(~qi?hi+=qi:hi=bi.indexOf(h),Ri=[];~hi;){let Oi=bi.slice(0,hi),ki=bi.slice(hi+gi);if(u){let Li=Oi.indexOf(`\r
305
+ \r
306
+ `)+4,ji=Oi.lastIndexOf(`\r
307
+ `,Li),Hi=!1,Ui=Oi.slice(Li,ji>-1?void 0:ji),Qi=String(Oi.slice(0,Li)).trim().split(`\r
308
+ `),$i={},wi=Qi.length;for(;l=Qi[--wi];l=l.split(": "),$i[l.shift().toLowerCase()]=l.join(": "));if(l=$i["content-type"],l&&~l.indexOf("application/json"))try{Ui=JSON.parse(Ui),Hi=!0}catch{}if(l={headers:$i,body:Ui,json:Hi},mi?yield l:Ri.push(l),ki.slice(0,2)==="--")break e}else h=`\r
309
+ `+h,u=gi+=2;bi=ki,hi=bi.indexOf(h)}Ri.length&&(yield Ri)}}finally{Ri.length&&(yield Ri),await D.cancel()}}(r.body,`--${s}`)}const fetchGraphQL=(r,t)=>{async function i(n,s){try{const{uri:a,headers:h}=s;h.set(HEADER_CONTENT_TYPE,"application/json");const v=await fetch(a,{body:JSON.stringify(r.id?{id:r.id,variables:t}:{query:r.text,variables:t}),headers:h,method:"POST"}),hi=await e(v);if(isAsyncIterable$1(hi))for await(const u of hi){if(!u.json){n.error(new Error("Failed to parse part as json."));break}if("data"in u.body&&n.next(u.body),"incremental"in u.body)for(const l of u.body.incremental)if("data"in l)n.next({...l,hasNext:u.body.hasNext});else if(l.items){const vi=l.path.slice(0,-1);let D=l.path.at(-1);for(const mi of l.items)n.next({...l,path:vi.concat(D++),data:mi,hasNext:u.body.hasNext})}else n.next({...l,data:l.items,hasNext:u.body.hasNext})}else n.next(await hi.json());n.complete()}catch(a){a instanceof Error?n.error(a,!0):n.error(new Error("Unknown error"),!0)}}return relayRuntimeExports.Observable.from(getHttpOptions("/graphql")).mergeMap(n=>relayRuntimeExports.Observable.create(s=>relayRuntimeExports.Observable.from(new Promise((a,h)=>{i(s,n).then(a,h)})).subscribe({})))},subscribeGraphQL=(r,t)=>relayRuntimeExports.Observable.from(getHttpOptions("/graphql")).map(({uri:i,headers:n})=>{const s={};return n.forEach((a,h)=>{s[h]=a}),createClient({url:i,headers:s})}).mergeMap(i=>relayRuntimeExports.Observable.create(n=>{const s=i.subscribe({id:r.id??void 0,query:r.text??"",variables:t},{next:({data:a,errors:h,extensions:v})=>n.next({data:a??void 0,errors:h?.map(hi=>({message:hi.message,locations:hi.locations?.map(({line:u,column:l})=>({line:u,column:l}))}))??[],extensions:v}),complete:n.complete,error:a=>{a instanceof Error?n.error(a,!0):n.error(new Error("Unknown error"),!0)}});return{closed:n.closed,unsubscribe:s}}));new relayRuntimeExports.Environment({network:relayRuntimeExports.Network.create(fetchGraphQL,subscribeGraphQL),store:new relayRuntimeExports.Store(new relayRuntimeExports.RecordSource),deferDeduplicatedFields:!0});var DocumentUri;(function(r){function t(i){return typeof i=="string"}r.is=t})(DocumentUri||(DocumentUri={}));var URI;(function(r){function t(i){return typeof i=="string"}r.is=t})(URI||(URI={}));var integer;(function(r){r.MIN_VALUE=-2147483648,r.MAX_VALUE=2147483647;function t(i){return typeof i=="number"&&r.MIN_VALUE<=i&&i<=r.MAX_VALUE}r.is=t})(integer||(integer={}));var uinteger;(function(r){r.MIN_VALUE=0,r.MAX_VALUE=2147483647;function t(i){return typeof i=="number"&&r.MIN_VALUE<=i&&i<=r.MAX_VALUE}r.is=t})(uinteger||(uinteger={}));var Position;(function(r){function t(n,s){return n===Number.MAX_VALUE&&(n=uinteger.MAX_VALUE),s===Number.MAX_VALUE&&(s=uinteger.MAX_VALUE),{line:n,character:s}}r.create=t;function i(n){let s=n;return Is.objectLiteral(s)&&Is.uinteger(s.line)&&Is.uinteger(s.character)}r.is=i})(Position||(Position={}));var Range;(function(r){function t(n,s,a,h){if(Is.uinteger(n)&&Is.uinteger(s)&&Is.uinteger(a)&&Is.uinteger(h))return{start:Position.create(n,s),end:Position.create(a,h)};if(Position.is(n)&&Position.is(s))return{start:n,end:s};throw new Error(`Range#create called with invalid arguments[${n}, ${s}, ${a}, ${h}]`)}r.create=t;function i(n){let s=n;return Is.objectLiteral(s)&&Position.is(s.start)&&Position.is(s.end)}r.is=i})(Range||(Range={}));var Location;(function(r){function t(n,s){return{uri:n,range:s}}r.create=t;function i(n){let s=n;return Is.objectLiteral(s)&&Range.is(s.range)&&(Is.string(s.uri)||Is.undefined(s.uri))}r.is=i})(Location||(Location={}));var LocationLink;(function(r){function t(n,s,a,h){return{targetUri:n,targetRange:s,targetSelectionRange:a,originSelectionRange:h}}r.create=t;function i(n){let s=n;return Is.objectLiteral(s)&&Range.is(s.targetRange)&&Is.string(s.targetUri)&&Range.is(s.targetSelectionRange)&&(Range.is(s.originSelectionRange)||Is.undefined(s.originSelectionRange))}r.is=i})(LocationLink||(LocationLink={}));var Color;(function(r){function t(n,s,a,h){return{red:n,green:s,blue:a,alpha:h}}r.create=t;function i(n){const s=n;return Is.objectLiteral(s)&&Is.numberRange(s.red,0,1)&&Is.numberRange(s.green,0,1)&&Is.numberRange(s.blue,0,1)&&Is.numberRange(s.alpha,0,1)}r.is=i})(Color||(Color={}));var ColorInformation;(function(r){function t(n,s){return{range:n,color:s}}r.create=t;function i(n){const s=n;return Is.objectLiteral(s)&&Range.is(s.range)&&Color.is(s.color)}r.is=i})(ColorInformation||(ColorInformation={}));var ColorPresentation;(function(r){function t(n,s,a){return{label:n,textEdit:s,additionalTextEdits:a}}r.create=t;function i(n){const s=n;return Is.objectLiteral(s)&&Is.string(s.label)&&(Is.undefined(s.textEdit)||TextEdit.is(s))&&(Is.undefined(s.additionalTextEdits)||Is.typedArray(s.additionalTextEdits,TextEdit.is))}r.is=i})(ColorPresentation||(ColorPresentation={}));var FoldingRangeKind;(function(r){r.Comment="comment",r.Imports="imports",r.Region="region"})(FoldingRangeKind||(FoldingRangeKind={}));var FoldingRange;(function(r){function t(n,s,a,h,v,hi){const u={startLine:n,endLine:s};return Is.defined(a)&&(u.startCharacter=a),Is.defined(h)&&(u.endCharacter=h),Is.defined(v)&&(u.kind=v),Is.defined(hi)&&(u.collapsedText=hi),u}r.create=t;function i(n){const s=n;return Is.objectLiteral(s)&&Is.uinteger(s.startLine)&&Is.uinteger(s.startLine)&&(Is.undefined(s.startCharacter)||Is.uinteger(s.startCharacter))&&(Is.undefined(s.endCharacter)||Is.uinteger(s.endCharacter))&&(Is.undefined(s.kind)||Is.string(s.kind))}r.is=i})(FoldingRange||(FoldingRange={}));var DiagnosticRelatedInformation;(function(r){function t(n,s){return{location:n,message:s}}r.create=t;function i(n){let s=n;return Is.defined(s)&&Location.is(s.location)&&Is.string(s.message)}r.is=i})(DiagnosticRelatedInformation||(DiagnosticRelatedInformation={}));var DiagnosticSeverity;(function(r){r.Error=1,r.Warning=2,r.Information=3,r.Hint=4})(DiagnosticSeverity||(DiagnosticSeverity={}));var DiagnosticTag;(function(r){r.Unnecessary=1,r.Deprecated=2})(DiagnosticTag||(DiagnosticTag={}));var CodeDescription;(function(r){function t(i){const n=i;return Is.objectLiteral(n)&&Is.string(n.href)}r.is=t})(CodeDescription||(CodeDescription={}));var Diagnostic;(function(r){function t(n,s,a,h,v,hi){let u={range:n,message:s};return Is.defined(a)&&(u.severity=a),Is.defined(h)&&(u.code=h),Is.defined(v)&&(u.source=v),Is.defined(hi)&&(u.relatedInformation=hi),u}r.create=t;function i(n){var s;let a=n;return Is.defined(a)&&Range.is(a.range)&&Is.string(a.message)&&(Is.number(a.severity)||Is.undefined(a.severity))&&(Is.integer(a.code)||Is.string(a.code)||Is.undefined(a.code))&&(Is.undefined(a.codeDescription)||Is.string((s=a.codeDescription)===null||s===void 0?void 0:s.href))&&(Is.string(a.source)||Is.undefined(a.source))&&(Is.undefined(a.relatedInformation)||Is.typedArray(a.relatedInformation,DiagnosticRelatedInformation.is))}r.is=i})(Diagnostic||(Diagnostic={}));var Command;(function(r){function t(n,s,...a){let h={title:n,command:s};return Is.defined(a)&&a.length>0&&(h.arguments=a),h}r.create=t;function i(n){let s=n;return Is.defined(s)&&Is.string(s.title)&&Is.string(s.command)}r.is=i})(Command||(Command={}));var TextEdit;(function(r){function t(a,h){return{range:a,newText:h}}r.replace=t;function i(a,h){return{range:{start:a,end:a},newText:h}}r.insert=i;function n(a){return{range:a,newText:""}}r.del=n;function s(a){const h=a;return Is.objectLiteral(h)&&Is.string(h.newText)&&Range.is(h.range)}r.is=s})(TextEdit||(TextEdit={}));var ChangeAnnotation;(function(r){function t(n,s,a){const h={label:n};return s!==void 0&&(h.needsConfirmation=s),a!==void 0&&(h.description=a),h}r.create=t;function i(n){const s=n;return Is.objectLiteral(s)&&Is.string(s.label)&&(Is.boolean(s.needsConfirmation)||s.needsConfirmation===void 0)&&(Is.string(s.description)||s.description===void 0)}r.is=i})(ChangeAnnotation||(ChangeAnnotation={}));var ChangeAnnotationIdentifier;(function(r){function t(i){const n=i;return Is.string(n)}r.is=t})(ChangeAnnotationIdentifier||(ChangeAnnotationIdentifier={}));var AnnotatedTextEdit;(function(r){function t(a,h,v){return{range:a,newText:h,annotationId:v}}r.replace=t;function i(a,h,v){return{range:{start:a,end:a},newText:h,annotationId:v}}r.insert=i;function n(a,h){return{range:a,newText:"",annotationId:h}}r.del=n;function s(a){const h=a;return TextEdit.is(h)&&(ChangeAnnotation.is(h.annotationId)||ChangeAnnotationIdentifier.is(h.annotationId))}r.is=s})(AnnotatedTextEdit||(AnnotatedTextEdit={}));var TextDocumentEdit;(function(r){function t(n,s){return{textDocument:n,edits:s}}r.create=t;function i(n){let s=n;return Is.defined(s)&&OptionalVersionedTextDocumentIdentifier.is(s.textDocument)&&Array.isArray(s.edits)}r.is=i})(TextDocumentEdit||(TextDocumentEdit={}));var CreateFile;(function(r){function t(n,s,a){let h={kind:"create",uri:n};return s!==void 0&&(s.overwrite!==void 0||s.ignoreIfExists!==void 0)&&(h.options=s),a!==void 0&&(h.annotationId=a),h}r.create=t;function i(n){let s=n;return s&&s.kind==="create"&&Is.string(s.uri)&&(s.options===void 0||(s.options.overwrite===void 0||Is.boolean(s.options.overwrite))&&(s.options.ignoreIfExists===void 0||Is.boolean(s.options.ignoreIfExists)))&&(s.annotationId===void 0||ChangeAnnotationIdentifier.is(s.annotationId))}r.is=i})(CreateFile||(CreateFile={}));var RenameFile;(function(r){function t(n,s,a,h){let v={kind:"rename",oldUri:n,newUri:s};return a!==void 0&&(a.overwrite!==void 0||a.ignoreIfExists!==void 0)&&(v.options=a),h!==void 0&&(v.annotationId=h),v}r.create=t;function i(n){let s=n;return s&&s.kind==="rename"&&Is.string(s.oldUri)&&Is.string(s.newUri)&&(s.options===void 0||(s.options.overwrite===void 0||Is.boolean(s.options.overwrite))&&(s.options.ignoreIfExists===void 0||Is.boolean(s.options.ignoreIfExists)))&&(s.annotationId===void 0||ChangeAnnotationIdentifier.is(s.annotationId))}r.is=i})(RenameFile||(RenameFile={}));var DeleteFile;(function(r){function t(n,s,a){let h={kind:"delete",uri:n};return s!==void 0&&(s.recursive!==void 0||s.ignoreIfNotExists!==void 0)&&(h.options=s),a!==void 0&&(h.annotationId=a),h}r.create=t;function i(n){let s=n;return s&&s.kind==="delete"&&Is.string(s.uri)&&(s.options===void 0||(s.options.recursive===void 0||Is.boolean(s.options.recursive))&&(s.options.ignoreIfNotExists===void 0||Is.boolean(s.options.ignoreIfNotExists)))&&(s.annotationId===void 0||ChangeAnnotationIdentifier.is(s.annotationId))}r.is=i})(DeleteFile||(DeleteFile={}));var WorkspaceEdit;(function(r){function t(i){let n=i;return n&&(n.changes!==void 0||n.documentChanges!==void 0)&&(n.documentChanges===void 0||n.documentChanges.every(s=>Is.string(s.kind)?CreateFile.is(s)||RenameFile.is(s)||DeleteFile.is(s):TextDocumentEdit.is(s)))}r.is=t})(WorkspaceEdit||(WorkspaceEdit={}));var TextDocumentIdentifier;(function(r){function t(n){return{uri:n}}r.create=t;function i(n){let s=n;return Is.defined(s)&&Is.string(s.uri)}r.is=i})(TextDocumentIdentifier||(TextDocumentIdentifier={}));var VersionedTextDocumentIdentifier;(function(r){function t(n,s){return{uri:n,version:s}}r.create=t;function i(n){let s=n;return Is.defined(s)&&Is.string(s.uri)&&Is.integer(s.version)}r.is=i})(VersionedTextDocumentIdentifier||(VersionedTextDocumentIdentifier={}));var OptionalVersionedTextDocumentIdentifier;(function(r){function t(n,s){return{uri:n,version:s}}r.create=t;function i(n){let s=n;return Is.defined(s)&&Is.string(s.uri)&&(s.version===null||Is.integer(s.version))}r.is=i})(OptionalVersionedTextDocumentIdentifier||(OptionalVersionedTextDocumentIdentifier={}));var TextDocumentItem;(function(r){function t(n,s,a,h){return{uri:n,languageId:s,version:a,text:h}}r.create=t;function i(n){let s=n;return Is.defined(s)&&Is.string(s.uri)&&Is.string(s.languageId)&&Is.integer(s.version)&&Is.string(s.text)}r.is=i})(TextDocumentItem||(TextDocumentItem={}));var MarkupKind;(function(r){r.PlainText="plaintext",r.Markdown="markdown";function t(i){const n=i;return n===r.PlainText||n===r.Markdown}r.is=t})(MarkupKind||(MarkupKind={}));var MarkupContent;(function(r){function t(i){const n=i;return Is.objectLiteral(i)&&MarkupKind.is(n.kind)&&Is.string(n.value)}r.is=t})(MarkupContent||(MarkupContent={}));var CompletionItemKind$1;(function(r){r.Text=1,r.Method=2,r.Function=3,r.Constructor=4,r.Field=5,r.Variable=6,r.Class=7,r.Interface=8,r.Module=9,r.Property=10,r.Unit=11,r.Value=12,r.Enum=13,r.Keyword=14,r.Snippet=15,r.Color=16,r.File=17,r.Reference=18,r.Folder=19,r.EnumMember=20,r.Constant=21,r.Struct=22,r.Event=23,r.Operator=24,r.TypeParameter=25})(CompletionItemKind$1||(CompletionItemKind$1={}));var InsertTextFormat;(function(r){r.PlainText=1,r.Snippet=2})(InsertTextFormat||(InsertTextFormat={}));var CompletionItemTag;(function(r){r.Deprecated=1})(CompletionItemTag||(CompletionItemTag={}));var InsertReplaceEdit;(function(r){function t(n,s,a){return{newText:n,insert:s,replace:a}}r.create=t;function i(n){const s=n;return s&&Is.string(s.newText)&&Range.is(s.insert)&&Range.is(s.replace)}r.is=i})(InsertReplaceEdit||(InsertReplaceEdit={}));var InsertTextMode;(function(r){r.asIs=1,r.adjustIndentation=2})(InsertTextMode||(InsertTextMode={}));var CompletionItemLabelDetails;(function(r){function t(i){const n=i;return n&&(Is.string(n.detail)||n.detail===void 0)&&(Is.string(n.description)||n.description===void 0)}r.is=t})(CompletionItemLabelDetails||(CompletionItemLabelDetails={}));var CompletionItem;(function(r){function t(i){return{label:i}}r.create=t})(CompletionItem||(CompletionItem={}));var CompletionList;(function(r){function t(i,n){return{items:i||[],isIncomplete:!!n}}r.create=t})(CompletionList||(CompletionList={}));var MarkedString;(function(r){function t(n){return n.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")}r.fromPlainText=t;function i(n){const s=n;return Is.string(s)||Is.objectLiteral(s)&&Is.string(s.language)&&Is.string(s.value)}r.is=i})(MarkedString||(MarkedString={}));var Hover;(function(r){function t(i){let n=i;return!!n&&Is.objectLiteral(n)&&(MarkupContent.is(n.contents)||MarkedString.is(n.contents)||Is.typedArray(n.contents,MarkedString.is))&&(i.range===void 0||Range.is(i.range))}r.is=t})(Hover||(Hover={}));var ParameterInformation;(function(r){function t(i,n){return n?{label:i,documentation:n}:{label:i}}r.create=t})(ParameterInformation||(ParameterInformation={}));var SignatureInformation;(function(r){function t(i,n,...s){let a={label:i};return Is.defined(n)&&(a.documentation=n),Is.defined(s)?a.parameters=s:a.parameters=[],a}r.create=t})(SignatureInformation||(SignatureInformation={}));var DocumentHighlightKind;(function(r){r.Text=1,r.Read=2,r.Write=3})(DocumentHighlightKind||(DocumentHighlightKind={}));var DocumentHighlight;(function(r){function t(i,n){let s={range:i};return Is.number(n)&&(s.kind=n),s}r.create=t})(DocumentHighlight||(DocumentHighlight={}));var SymbolKind;(function(r){r.File=1,r.Module=2,r.Namespace=3,r.Package=4,r.Class=5,r.Method=6,r.Property=7,r.Field=8,r.Constructor=9,r.Enum=10,r.Interface=11,r.Function=12,r.Variable=13,r.Constant=14,r.String=15,r.Number=16,r.Boolean=17,r.Array=18,r.Object=19,r.Key=20,r.Null=21,r.EnumMember=22,r.Struct=23,r.Event=24,r.Operator=25,r.TypeParameter=26})(SymbolKind||(SymbolKind={}));var SymbolTag;(function(r){r.Deprecated=1})(SymbolTag||(SymbolTag={}));var SymbolInformation;(function(r){function t(i,n,s,a,h){let v={name:i,kind:n,location:{uri:a,range:s}};return h&&(v.containerName=h),v}r.create=t})(SymbolInformation||(SymbolInformation={}));var WorkspaceSymbol;(function(r){function t(i,n,s,a){return a!==void 0?{name:i,kind:n,location:{uri:s,range:a}}:{name:i,kind:n,location:{uri:s}}}r.create=t})(WorkspaceSymbol||(WorkspaceSymbol={}));var DocumentSymbol;(function(r){function t(n,s,a,h,v,hi){let u={name:n,detail:s,kind:a,range:h,selectionRange:v};return hi!==void 0&&(u.children=hi),u}r.create=t;function i(n){let s=n;return s&&Is.string(s.name)&&Is.number(s.kind)&&Range.is(s.range)&&Range.is(s.selectionRange)&&(s.detail===void 0||Is.string(s.detail))&&(s.deprecated===void 0||Is.boolean(s.deprecated))&&(s.children===void 0||Array.isArray(s.children))&&(s.tags===void 0||Array.isArray(s.tags))}r.is=i})(DocumentSymbol||(DocumentSymbol={}));var CodeActionKind;(function(r){r.Empty="",r.QuickFix="quickfix",r.Refactor="refactor",r.RefactorExtract="refactor.extract",r.RefactorInline="refactor.inline",r.RefactorRewrite="refactor.rewrite",r.Source="source",r.SourceOrganizeImports="source.organizeImports",r.SourceFixAll="source.fixAll"})(CodeActionKind||(CodeActionKind={}));var CodeActionTriggerKind;(function(r){r.Invoked=1,r.Automatic=2})(CodeActionTriggerKind||(CodeActionTriggerKind={}));var CodeActionContext;(function(r){function t(n,s,a){let h={diagnostics:n};return s!=null&&(h.only=s),a!=null&&(h.triggerKind=a),h}r.create=t;function i(n){let s=n;return Is.defined(s)&&Is.typedArray(s.diagnostics,Diagnostic.is)&&(s.only===void 0||Is.typedArray(s.only,Is.string))&&(s.triggerKind===void 0||s.triggerKind===CodeActionTriggerKind.Invoked||s.triggerKind===CodeActionTriggerKind.Automatic)}r.is=i})(CodeActionContext||(CodeActionContext={}));var CodeAction;(function(r){function t(n,s,a){let h={title:n},v=!0;return typeof s=="string"?(v=!1,h.kind=s):Command.is(s)?h.command=s:h.edit=s,v&&a!==void 0&&(h.kind=a),h}r.create=t;function i(n){let s=n;return s&&Is.string(s.title)&&(s.diagnostics===void 0||Is.typedArray(s.diagnostics,Diagnostic.is))&&(s.kind===void 0||Is.string(s.kind))&&(s.edit!==void 0||s.command!==void 0)&&(s.command===void 0||Command.is(s.command))&&(s.isPreferred===void 0||Is.boolean(s.isPreferred))&&(s.edit===void 0||WorkspaceEdit.is(s.edit))}r.is=i})(CodeAction||(CodeAction={}));var CodeLens;(function(r){function t(n,s){let a={range:n};return Is.defined(s)&&(a.data=s),a}r.create=t;function i(n){let s=n;return Is.defined(s)&&Range.is(s.range)&&(Is.undefined(s.command)||Command.is(s.command))}r.is=i})(CodeLens||(CodeLens={}));var FormattingOptions;(function(r){function t(n,s){return{tabSize:n,insertSpaces:s}}r.create=t;function i(n){let s=n;return Is.defined(s)&&Is.uinteger(s.tabSize)&&Is.boolean(s.insertSpaces)}r.is=i})(FormattingOptions||(FormattingOptions={}));var DocumentLink;(function(r){function t(n,s,a){return{range:n,target:s,data:a}}r.create=t;function i(n){let s=n;return Is.defined(s)&&Range.is(s.range)&&(Is.undefined(s.target)||Is.string(s.target))}r.is=i})(DocumentLink||(DocumentLink={}));var SelectionRange;(function(r){function t(n,s){return{range:n,parent:s}}r.create=t;function i(n){let s=n;return Is.objectLiteral(s)&&Range.is(s.range)&&(s.parent===void 0||r.is(s.parent))}r.is=i})(SelectionRange||(SelectionRange={}));var SemanticTokenTypes;(function(r){r.namespace="namespace",r.type="type",r.class="class",r.enum="enum",r.interface="interface",r.struct="struct",r.typeParameter="typeParameter",r.parameter="parameter",r.variable="variable",r.property="property",r.enumMember="enumMember",r.event="event",r.function="function",r.method="method",r.macro="macro",r.keyword="keyword",r.modifier="modifier",r.comment="comment",r.string="string",r.number="number",r.regexp="regexp",r.operator="operator",r.decorator="decorator"})(SemanticTokenTypes||(SemanticTokenTypes={}));var SemanticTokenModifiers;(function(r){r.declaration="declaration",r.definition="definition",r.readonly="readonly",r.static="static",r.deprecated="deprecated",r.abstract="abstract",r.async="async",r.modification="modification",r.documentation="documentation",r.defaultLibrary="defaultLibrary"})(SemanticTokenModifiers||(SemanticTokenModifiers={}));var SemanticTokens;(function(r){function t(i){const n=i;return Is.objectLiteral(n)&&(n.resultId===void 0||typeof n.resultId=="string")&&Array.isArray(n.data)&&(n.data.length===0||typeof n.data[0]=="number")}r.is=t})(SemanticTokens||(SemanticTokens={}));var InlineValueText;(function(r){function t(n,s){return{range:n,text:s}}r.create=t;function i(n){const s=n;return s!=null&&Range.is(s.range)&&Is.string(s.text)}r.is=i})(InlineValueText||(InlineValueText={}));var InlineValueVariableLookup;(function(r){function t(n,s,a){return{range:n,variableName:s,caseSensitiveLookup:a}}r.create=t;function i(n){const s=n;return s!=null&&Range.is(s.range)&&Is.boolean(s.caseSensitiveLookup)&&(Is.string(s.variableName)||s.variableName===void 0)}r.is=i})(InlineValueVariableLookup||(InlineValueVariableLookup={}));var InlineValueEvaluatableExpression;(function(r){function t(n,s){return{range:n,expression:s}}r.create=t;function i(n){const s=n;return s!=null&&Range.is(s.range)&&(Is.string(s.expression)||s.expression===void 0)}r.is=i})(InlineValueEvaluatableExpression||(InlineValueEvaluatableExpression={}));var InlineValueContext;(function(r){function t(n,s){return{frameId:n,stoppedLocation:s}}r.create=t;function i(n){const s=n;return Is.defined(s)&&Range.is(n.stoppedLocation)}r.is=i})(InlineValueContext||(InlineValueContext={}));var InlayHintKind;(function(r){r.Type=1,r.Parameter=2;function t(i){return i===1||i===2}r.is=t})(InlayHintKind||(InlayHintKind={}));var InlayHintLabelPart;(function(r){function t(n){return{value:n}}r.create=t;function i(n){const s=n;return Is.objectLiteral(s)&&(s.tooltip===void 0||Is.string(s.tooltip)||MarkupContent.is(s.tooltip))&&(s.location===void 0||Location.is(s.location))&&(s.command===void 0||Command.is(s.command))}r.is=i})(InlayHintLabelPart||(InlayHintLabelPart={}));var InlayHint;(function(r){function t(n,s,a){const h={position:n,label:s};return a!==void 0&&(h.kind=a),h}r.create=t;function i(n){const s=n;return Is.objectLiteral(s)&&Position.is(s.position)&&(Is.string(s.label)||Is.typedArray(s.label,InlayHintLabelPart.is))&&(s.kind===void 0||InlayHintKind.is(s.kind))&&s.textEdits===void 0||Is.typedArray(s.textEdits,TextEdit.is)&&(s.tooltip===void 0||Is.string(s.tooltip)||MarkupContent.is(s.tooltip))&&(s.paddingLeft===void 0||Is.boolean(s.paddingLeft))&&(s.paddingRight===void 0||Is.boolean(s.paddingRight))}r.is=i})(InlayHint||(InlayHint={}));var StringValue;(function(r){function t(i){return{kind:"snippet",value:i}}r.createSnippet=t})(StringValue||(StringValue={}));var InlineCompletionItem;(function(r){function t(i,n,s,a){return{insertText:i,filterText:n,range:s,command:a}}r.create=t})(InlineCompletionItem||(InlineCompletionItem={}));var InlineCompletionList;(function(r){function t(i){return{items:i}}r.create=t})(InlineCompletionList||(InlineCompletionList={}));var InlineCompletionTriggerKind;(function(r){r.Invoked=0,r.Automatic=1})(InlineCompletionTriggerKind||(InlineCompletionTriggerKind={}));var SelectedCompletionInfo;(function(r){function t(i,n){return{range:i,text:n}}r.create=t})(SelectedCompletionInfo||(SelectedCompletionInfo={}));var InlineCompletionContext;(function(r){function t(i,n){return{triggerKind:i,selectedCompletionInfo:n}}r.create=t})(InlineCompletionContext||(InlineCompletionContext={}));var WorkspaceFolder;(function(r){function t(i){const n=i;return Is.objectLiteral(n)&&URI.is(n.uri)&&Is.string(n.name)}r.is=t})(WorkspaceFolder||(WorkspaceFolder={}));var TextDocument;(function(r){function t(a,h,v,hi){return new FullTextDocument(a,h,v,hi)}r.create=t;function i(a){let h=a;return!!(Is.defined(h)&&Is.string(h.uri)&&(Is.undefined(h.languageId)||Is.string(h.languageId))&&Is.uinteger(h.lineCount)&&Is.func(h.getText)&&Is.func(h.positionAt)&&Is.func(h.offsetAt))}r.is=i;function n(a,h){let v=a.getText(),hi=s(h,(l,vi)=>{let D=l.range.start.line-vi.range.start.line;return D===0?l.range.start.character-vi.range.start.character:D}),u=v.length;for(let l=hi.length-1;l>=0;l--){let vi=hi[l],D=a.offsetAt(vi.range.start),mi=a.offsetAt(vi.range.end);if(mi<=u)v=v.substring(0,D)+vi.newText+v.substring(mi,v.length);else throw new Error("Overlapping edit");u=D}return v}r.applyEdits=n;function s(a,h){if(a.length<=1)return a;const v=a.length/2|0,hi=a.slice(0,v),u=a.slice(v);s(hi,h),s(u,h);let l=0,vi=0,D=0;for(;l<hi.length&&vi<u.length;)h(hi[l],u[vi])<=0?a[D++]=hi[l++]:a[D++]=u[vi++];for(;l<hi.length;)a[D++]=hi[l++];for(;vi<u.length;)a[D++]=u[vi++];return a}})(TextDocument||(TextDocument={}));class FullTextDocument{constructor(t,i,n,s){this._uri=t,this._languageId=i,this._version=n,this._content=s,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(t){if(t){let i=this.offsetAt(t.start),n=this.offsetAt(t.end);return this._content.substring(i,n)}return this._content}update(t,i){this._content=t.text,this._version=i,this._lineOffsets=void 0}getLineOffsets(){if(this._lineOffsets===void 0){let t=[],i=this._content,n=!0;for(let s=0;s<i.length;s++){n&&(t.push(s),n=!1);let a=i.charAt(s);n=a==="\r"||a===`
310
+ `,a==="\r"&&s+1<i.length&&i.charAt(s+1)===`
311
+ `&&s++}n&&i.length>0&&t.push(i.length),this._lineOffsets=t}return this._lineOffsets}positionAt(t){t=Math.max(Math.min(t,this._content.length),0);let i=this.getLineOffsets(),n=0,s=i.length;if(s===0)return Position.create(0,t);for(;n<s;){let h=Math.floor((n+s)/2);i[h]>t?s=h:n=h+1}let a=n-1;return Position.create(a,t-i[a])}offsetAt(t){let i=this.getLineOffsets();if(t.line>=i.length)return this._content.length;if(t.line<0)return 0;let n=i[t.line],s=t.line+1<i.length?i[t.line+1]:this._content.length;return Math.max(Math.min(n+t.character,s),n)}get lineCount(){return this.getLineOffsets().length}}var Is;(function(r){const t=Object.prototype.toString;function i(mi){return typeof mi<"u"}r.defined=i;function n(mi){return typeof mi>"u"}r.undefined=n;function s(mi){return mi===!0||mi===!1}r.boolean=s;function a(mi){return t.call(mi)==="[object String]"}r.string=a;function h(mi){return t.call(mi)==="[object Number]"}r.number=h;function v(mi,gi,bi){return t.call(mi)==="[object Number]"&&gi<=mi&&mi<=bi}r.numberRange=v;function hi(mi){return t.call(mi)==="[object Number]"&&-2147483648<=mi&&mi<=2147483647}r.integer=hi;function u(mi){return t.call(mi)==="[object Number]"&&0<=mi&&mi<=2147483647}r.uinteger=u;function l(mi){return t.call(mi)==="[object Function]"}r.func=l;function vi(mi){return mi!==null&&typeof mi=="object"}r.objectLiteral=vi;function D(mi,gi){return Array.isArray(mi)&&mi.every(gi)}r.typedArray=D})(Is||(Is={}));function opt(r){return{ofRule:r}}function list(r,t){return{ofRule:r,isList:!0,separator:t}}function butNot(r,t){const i=r.match;return r.match=n=>{let s=!1;return i&&(s=i(n)),s&&t.every(a=>a.match&&!a.match(n))},r}word("fragment"),opt(butNot(name$1("def"),[word("on")])),list("Directive"),Kind.SCHEMA_EXTENSION+"",Kind.SCALAR_TYPE_EXTENSION+"",Kind.OBJECT_TYPE_EXTENSION+"",Kind.INTERFACE_TYPE_EXTENSION+"",Kind.UNION_TYPE_EXTENSION+"",Kind.ENUM_TYPE_EXTENSION+"",Kind.INPUT_OBJECT_TYPE_EXTENSION+"";function word(r){return{style:"keyword",match:t=>t.kind==="Name"&&t.value===r}}function name$1(r){return{style:r,match:t=>t.kind==="Name",update(t,i){t.name=i.value}}}var GraphQLDocumentMode;(function(r){r.TYPE_SYSTEM="TYPE_SYSTEM",r.EXECUTABLE="EXECUTABLE",r.UNKNOWN="UNKNOWN"})(GraphQLDocumentMode||(GraphQLDocumentMode={}));Kind.SCHEMA_DEFINITION,Kind.OPERATION_TYPE_DEFINITION,Kind.SCALAR_TYPE_DEFINITION,Kind.OBJECT_TYPE_DEFINITION,Kind.INTERFACE_TYPE_DEFINITION,Kind.UNION_TYPE_DEFINITION,Kind.ENUM_TYPE_DEFINITION,Kind.INPUT_OBJECT_TYPE_DEFINITION,Kind.DIRECTIVE_DEFINITION,Kind.SCHEMA_EXTENSION,Kind.SCALAR_TYPE_EXTENSION,Kind.OBJECT_TYPE_EXTENSION,Kind.INTERFACE_TYPE_EXTENSION,Kind.UNION_TYPE_EXTENSION,Kind.ENUM_TYPE_EXTENSION,Kind.INPUT_OBJECT_TYPE_EXTENSION;const AdditionalRuleKinds={ALIASED_FIELD:"AliasedField",ARGUMENTS:"Arguments",SHORT_QUERY:"ShortQuery",QUERY:"Query",MUTATION:"Mutation",SUBSCRIPTION:"Subscription",TYPE_CONDITION:"TypeCondition",INVALID:"Invalid",COMMENT:"Comment",SCHEMA_DEF:"SchemaDef",SCALAR_DEF:"ScalarDef",OBJECT_TYPE_DEF:"ObjectTypeDef",OBJECT_VALUE:"ObjectValue",LIST_VALUE:"ListValue",INTERFACE_DEF:"InterfaceDef",UNION_DEF:"UnionDef",ENUM_DEF:"EnumDef",ENUM_VALUE:"EnumValue",FIELD_DEF:"FieldDef",INPUT_DEF:"InputDef",INPUT_VALUE_DEF:"InputValueDef",ARGUMENTS_DEF:"ArgumentsDef",EXTEND_DEF:"ExtendDef",EXTENSION_DEFINITION:"ExtensionDefinition",DIRECTIVE_DEF:"DirectiveDef",IMPLEMENTS:"Implements",VARIABLE_DEFINITIONS:"VariableDefinitions",TYPE:"Type",VARIABLE:"Variable"},RuleKinds=Object.assign(Object.assign({},Kind),AdditionalRuleKinds);var CompletionItemKind;(function(r){r.Text=1,r.Method=2,r.Function=3,r.Constructor=4,r.Field=5,r.Variable=6,r.Class=7,r.Interface=8,r.Module=9,r.Property=10,r.Unit=11,r.Value=12,r.Enum=13,r.Keyword=14,r.Snippet=15,r.Color=16,r.File=17,r.Reference=18,r.Folder=19,r.EnumMember=20,r.Constant=21,r.Struct=22,r.Event=23,r.Operator=24,r.TypeParameter=25})(CompletionItemKind||(CompletionItemKind={}));CompletionItemKind.Function,CompletionItemKind.Function,CompletionItemKind.Function,CompletionItemKind.Function,CompletionItemKind.Function,CompletionItemKind.Function;CompletionItemKind.Function,CompletionItemKind.Function,CompletionItemKind.Function,CompletionItemKind.Function,CompletionItemKind.Constructor;var nullthrows={exports:{}},hasRequiredNullthrows;function requireNullthrows(){if(hasRequiredNullthrows)return nullthrows.exports;hasRequiredNullthrows=1;function r(t,i){if(t!=null)return t;var n=new Error(i!==void 0?i:"Got unexpected "+t);throw n.framesToPop=1,n}return nullthrows.exports=r,nullthrows.exports.default=r,Object.defineProperty(nullthrows.exports,"__esModule",{value:!0}),nullthrows.exports}requireNullthrows();const{INLINE_FRAGMENT}=Kind;var parser={},CharacterStream={},hasRequiredCharacterStream;function requireCharacterStream(){if(hasRequiredCharacterStream)return CharacterStream;hasRequiredCharacterStream=1,Object.defineProperty(CharacterStream,"__esModule",{value:!0});let r=class{constructor(i){this._start=0,this._pos=0,this.getStartOfToken=()=>this._start,this.getCurrentPosition=()=>this._pos,this.eol=()=>this._sourceText.length===this._pos,this.sol=()=>this._pos===0,this.peek=()=>this._sourceText.charAt(this._pos)||null,this.next=()=>{const n=this._sourceText.charAt(this._pos);return this._pos++,n},this.eat=n=>{if(this._testNextCharacter(n))return this._start=this._pos,this._pos++,this._sourceText.charAt(this._pos-1)},this.eatWhile=n=>{let s=this._testNextCharacter(n),a=!1;for(s&&(a=s,this._start=this._pos);s;)this._pos++,s=this._testNextCharacter(n),a=!0;return a},this.eatSpace=()=>this.eatWhile(/[\s\u00a0]/),this.skipToEnd=()=>{this._pos=this._sourceText.length},this.skipTo=n=>{this._pos=n},this.match=(n,s=!0,a=!1)=>{let h=null,v=null;return typeof n=="string"?(v=new RegExp(n,a?"i":"g").test(this._sourceText.slice(this._pos,this._pos+n.length)),h=n):n instanceof RegExp&&(v=this._sourceText.slice(this._pos).match(n),h=v?.[0]),v!=null&&(typeof n=="string"||v instanceof Array&&this._sourceText.startsWith(v[0],this._pos))?(s&&(this._start=this._pos,h&&h.length&&(this._pos+=h.length)),v):!1},this.backUp=n=>{this._pos-=n},this.column=()=>this._pos,this.indentation=()=>{const n=this._sourceText.match(/\s*/);let s=0;if(n&&n.length!==0){const a=n[0];let h=0;for(;a.length>h;)a.charCodeAt(h)===9?s+=2:s++,h++}return s},this.current=()=>this._sourceText.slice(this._start,this._pos),this._sourceText=i}_testNextCharacter(i){const n=this._sourceText.charAt(this._pos);let s=!1;return typeof i=="string"?s=n===i:s=i instanceof RegExp?i.test(n):i(n),s}};return CharacterStream.default=r,CharacterStream}var Rules={},RuleHelpers={},hasRequiredRuleHelpers;function requireRuleHelpers(){if(hasRequiredRuleHelpers)return RuleHelpers;hasRequiredRuleHelpers=1,Object.defineProperty(RuleHelpers,"__esModule",{value:!0}),RuleHelpers.p=RuleHelpers.t=RuleHelpers.butNot=RuleHelpers.list=RuleHelpers.opt=void 0;function r(a){return{ofRule:a}}RuleHelpers.opt=r;function t(a,h){return{ofRule:a,isList:!0,separator:h}}RuleHelpers.list=t;function i(a,h){const v=a.match;return a.match=hi=>{let u=!1;return v&&(u=v(hi)),u&&h.every(l=>l.match&&!l.match(hi))},a}RuleHelpers.butNot=i;function n(a,h){return{style:h,match:v=>v.kind===a}}RuleHelpers.t=n;function s(a,h){return{style:h||"punctuation",match:v=>v.kind==="Punctuation"&&v.value===a}}return RuleHelpers.p=s,RuleHelpers}var require$$0=getAugmentedNamespace(graphql),hasRequiredRules;function requireRules(){if(hasRequiredRules)return Rules;hasRequiredRules=1,Object.defineProperty(Rules,"__esModule",{value:!0}),Rules.ParseRules=Rules.LexRules=Rules.isIgnored=void 0;const r=requireRuleHelpers(),t=require$$0,i=h=>h===" "||h===" "||h===","||h===`
312
+ `||h==="\r"||h==="\uFEFF"||h===" ";Rules.isIgnored=i,Rules.LexRules={Name:/^[_A-Za-z][_0-9A-Za-z]*/,Punctuation:/^(?:!|\$|\(|\)|\.\.\.|:|=|&|@|\[|]|\{|\||\})/,Number:/^-?(?:0|(?:[1-9][0-9]*))(?:\.[0-9]*)?(?:[eE][+-]?[0-9]+)?/,String:/^(?:"""(?:\\"""|[^"]|"[^"]|""[^"])*(?:""")?|"(?:[^"\\]|\\(?:"|\/|\\|b|f|n|r|t|u[0-9a-fA-F]{4}))*"?)/,Comment:/^#.*/},Rules.ParseRules={Document:[(0,r.list)("Definition")],Definition(h){switch(h.value){case"{":return"ShortQuery";case"query":return"Query";case"mutation":return"Mutation";case"subscription":return"Subscription";case"fragment":return t.Kind.FRAGMENT_DEFINITION;case"schema":return"SchemaDef";case"scalar":return"ScalarDef";case"type":return"ObjectTypeDef";case"interface":return"InterfaceDef";case"union":return"UnionDef";case"enum":return"EnumDef";case"input":return"InputDef";case"extend":return"ExtendDef";case"directive":return"DirectiveDef"}},ShortQuery:["SelectionSet"],Query:[n("query"),(0,r.opt)(s("def")),(0,r.opt)("VariableDefinitions"),(0,r.list)("Directive"),"SelectionSet"],Mutation:[n("mutation"),(0,r.opt)(s("def")),(0,r.opt)("VariableDefinitions"),(0,r.list)("Directive"),"SelectionSet"],Subscription:[n("subscription"),(0,r.opt)(s("def")),(0,r.opt)("VariableDefinitions"),(0,r.list)("Directive"),"SelectionSet"],VariableDefinitions:[(0,r.p)("("),(0,r.list)("VariableDefinition"),(0,r.p)(")")],VariableDefinition:["Variable",(0,r.p)(":"),"Type",(0,r.opt)("DefaultValue")],Variable:[(0,r.p)("$","variable"),s("variable")],DefaultValue:[(0,r.p)("="),"Value"],SelectionSet:[(0,r.p)("{"),(0,r.list)("Selection"),(0,r.p)("}")],Selection(h,v){return h.value==="..."?v.match(/[\s\u00a0,]*(on\b|@|{)/,!1)?"InlineFragment":"FragmentSpread":v.match(/[\s\u00a0,]*:/,!1)?"AliasedField":"Field"},AliasedField:[s("property"),(0,r.p)(":"),s("qualifier"),(0,r.opt)("Arguments"),(0,r.list)("Directive"),(0,r.opt)("SelectionSet")],Field:[s("property"),(0,r.opt)("Arguments"),(0,r.list)("Directive"),(0,r.opt)("SelectionSet")],Arguments:[(0,r.p)("("),(0,r.list)("Argument"),(0,r.p)(")")],Argument:[s("attribute"),(0,r.p)(":"),"Value"],FragmentSpread:[(0,r.p)("..."),s("def"),(0,r.list)("Directive")],InlineFragment:[(0,r.p)("..."),(0,r.opt)("TypeCondition"),(0,r.list)("Directive"),"SelectionSet"],FragmentDefinition:[n("fragment"),(0,r.opt)((0,r.butNot)(s("def"),[n("on")])),"TypeCondition",(0,r.list)("Directive"),"SelectionSet"],TypeCondition:[n("on"),"NamedType"],Value(h){switch(h.kind){case"Number":return"NumberValue";case"String":return"StringValue";case"Punctuation":switch(h.value){case"[":return"ListValue";case"{":return"ObjectValue";case"$":return"Variable";case"&":return"NamedType"}return null;case"Name":switch(h.value){case"true":case"false":return"BooleanValue"}return h.value==="null"?"NullValue":"EnumValue"}},NumberValue:[(0,r.t)("Number","number")],StringValue:[{style:"string",match:h=>h.kind==="String",update(h,v){v.value.startsWith('"""')&&(h.inBlockstring=!v.value.slice(3).endsWith('"""'))}}],BooleanValue:[(0,r.t)("Name","builtin")],NullValue:[(0,r.t)("Name","keyword")],EnumValue:[s("string-2")],ListValue:[(0,r.p)("["),(0,r.list)("Value"),(0,r.p)("]")],ObjectValue:[(0,r.p)("{"),(0,r.list)("ObjectField"),(0,r.p)("}")],ObjectField:[s("attribute"),(0,r.p)(":"),"Value"],Type(h){return h.value==="["?"ListType":"NonNullType"},ListType:[(0,r.p)("["),"Type",(0,r.p)("]"),(0,r.opt)((0,r.p)("!"))],NonNullType:["NamedType",(0,r.opt)((0,r.p)("!"))],NamedType:[a("atom")],Directive:[(0,r.p)("@","meta"),s("meta"),(0,r.opt)("Arguments")],DirectiveDef:[n("directive"),(0,r.p)("@","meta"),s("meta"),(0,r.opt)("ArgumentsDef"),n("on"),(0,r.list)("DirectiveLocation",(0,r.p)("|"))],InterfaceDef:[n("interface"),s("atom"),(0,r.opt)("Implements"),(0,r.list)("Directive"),(0,r.p)("{"),(0,r.list)("FieldDef"),(0,r.p)("}")],Implements:[n("implements"),(0,r.list)("NamedType",(0,r.p)("&"))],DirectiveLocation:[s("string-2")],SchemaDef:[n("schema"),(0,r.list)("Directive"),(0,r.p)("{"),(0,r.list)("OperationTypeDef"),(0,r.p)("}")],OperationTypeDef:[s("keyword"),(0,r.p)(":"),s("atom")],ScalarDef:[n("scalar"),s("atom"),(0,r.list)("Directive")],ObjectTypeDef:[n("type"),s("atom"),(0,r.opt)("Implements"),(0,r.list)("Directive"),(0,r.p)("{"),(0,r.list)("FieldDef"),(0,r.p)("}")],FieldDef:[s("property"),(0,r.opt)("ArgumentsDef"),(0,r.p)(":"),"Type",(0,r.list)("Directive")],ArgumentsDef:[(0,r.p)("("),(0,r.list)("InputValueDef"),(0,r.p)(")")],InputValueDef:[s("attribute"),(0,r.p)(":"),"Type",(0,r.opt)("DefaultValue"),(0,r.list)("Directive")],UnionDef:[n("union"),s("atom"),(0,r.list)("Directive"),(0,r.p)("="),(0,r.list)("UnionMember",(0,r.p)("|"))],UnionMember:["NamedType"],EnumDef:[n("enum"),s("atom"),(0,r.list)("Directive"),(0,r.p)("{"),(0,r.list)("EnumValueDef"),(0,r.p)("}")],EnumValueDef:[s("string-2"),(0,r.list)("Directive")],InputDef:[n("input"),s("atom"),(0,r.list)("Directive"),(0,r.p)("{"),(0,r.list)("InputValueDef"),(0,r.p)("}")],ExtendDef:[n("extend"),"ExtensionDefinition"],ExtensionDefinition(h){switch(h.value){case"schema":return t.Kind.SCHEMA_EXTENSION;case"scalar":return t.Kind.SCALAR_TYPE_EXTENSION;case"type":return t.Kind.OBJECT_TYPE_EXTENSION;case"interface":return t.Kind.INTERFACE_TYPE_EXTENSION;case"union":return t.Kind.UNION_TYPE_EXTENSION;case"enum":return t.Kind.ENUM_TYPE_EXTENSION;case"input":return t.Kind.INPUT_OBJECT_TYPE_EXTENSION}},[t.Kind.SCHEMA_EXTENSION]:["SchemaDef"],[t.Kind.SCALAR_TYPE_EXTENSION]:["ScalarDef"],[t.Kind.OBJECT_TYPE_EXTENSION]:["ObjectTypeDef"],[t.Kind.INTERFACE_TYPE_EXTENSION]:["InterfaceDef"],[t.Kind.UNION_TYPE_EXTENSION]:["UnionDef"],[t.Kind.ENUM_TYPE_EXTENSION]:["EnumDef"],[t.Kind.INPUT_OBJECT_TYPE_EXTENSION]:["InputDef"]};function n(h){return{style:"keyword",match:v=>v.kind==="Name"&&v.value===h}}function s(h){return{style:h,match:v=>v.kind==="Name",update(v,hi){v.name=hi.value}}}function a(h){return{style:h,match:v=>v.kind==="Name",update(v,hi){var u;!((u=v.prevState)===null||u===void 0)&&u.prevState&&(v.name=hi.value,v.prevState.prevState.type=hi.value)}}}return Rules}var onlineParser={},hasRequiredOnlineParser;function requireOnlineParser(){if(hasRequiredOnlineParser)return onlineParser;hasRequiredOnlineParser=1,Object.defineProperty(onlineParser,"__esModule",{value:!0});const r=requireRules(),t=require$$0;function i(D={eatWhitespace:mi=>mi.eatWhile(r.isIgnored),lexRules:r.LexRules,parseRules:r.ParseRules,editorConfig:{}}){return{startState(){const mi={level:0,step:0,name:null,kind:null,type:null,rule:null,needsSeparator:!1,prevState:null};return h(D.parseRules,mi,t.Kind.DOCUMENT),mi},token(mi,gi){return n(mi,gi,D)}}}onlineParser.default=i;function n(D,mi,gi){var bi;if(mi.inBlockstring)return D.match(/.*"""/)?(mi.inBlockstring=!1,"string"):(D.skipToEnd(),"string");const{lexRules:Ri,parseRules:Ti,eatWhitespace:Ii,editorConfig:qi}=gi;if(mi.rule&&mi.rule.length===0?v(mi):mi.needsAdvance&&(mi.needsAdvance=!1,hi(mi,!0)),D.sol()){const Li=qi?.tabSize||2;mi.indentLevel=Math.floor(D.indentation()/Li)}if(Ii(D))return"ws";const Oi=vi(Ri,D);if(!Oi)return D.match(/\S+/)||D.match(/\s/),h(a,mi,"Invalid"),"invalidchar";if(Oi.kind==="Comment")return h(a,mi,"Comment"),"comment";const ki=s({},mi);if(Oi.kind==="Punctuation"){if(/^[{([]/.test(Oi.value))mi.indentLevel!==void 0&&(mi.levels=(mi.levels||[]).concat(mi.indentLevel+1));else if(/^[})\]]/.test(Oi.value)){const Li=mi.levels=(mi.levels||[]).slice(0,-1);mi.indentLevel&&Li.length>0&&Li.at(-1)<mi.indentLevel&&(mi.indentLevel=Li.at(-1))}}for(;mi.rule;){let Li=typeof mi.rule=="function"?mi.step===0?mi.rule(Oi,D):null:mi.rule[mi.step];if(mi.needsSeparator&&(Li=Li?.separator),Li){if(Li.ofRule&&(Li=Li.ofRule),typeof Li=="string"){h(Ti,mi,Li);continue}if(!((bi=Li.match)===null||bi===void 0)&&bi.call(Li,Oi))return Li.update&&Li.update(mi,Oi),Oi.kind==="Punctuation"?hi(mi,!0):mi.needsAdvance=!0,Li.style}l(mi)}return s(mi,ki),h(a,mi,"Invalid"),"invalidchar"}function s(D,mi){const gi=Object.keys(mi);for(let bi=0;bi<gi.length;bi++)D[gi[bi]]=mi[gi[bi]];return D}const a={Invalid:[],Comment:[]};function h(D,mi,gi){if(!D[gi])throw new TypeError("Unknown rule: "+gi);mi.prevState=Object.assign({},mi),mi.kind=gi,mi.name=null,mi.type=null,mi.rule=D[gi],mi.step=0,mi.needsSeparator=!1}function v(D){D.prevState&&(D.kind=D.prevState.kind,D.name=D.prevState.name,D.type=D.prevState.type,D.rule=D.prevState.rule,D.step=D.prevState.step,D.needsSeparator=D.prevState.needsSeparator,D.prevState=D.prevState.prevState)}function hi(D,mi){var gi;if(u(D)&&D.rule){const bi=D.rule[D.step];if(bi.separator){const{separator:Ri}=bi;if(D.needsSeparator=!D.needsSeparator,!D.needsSeparator&&Ri.ofRule)return}if(mi)return}for(D.needsSeparator=!1,D.step++;D.rule&&!(Array.isArray(D.rule)&&D.step<D.rule.length);)v(D),D.rule&&(u(D)?!((gi=D.rule)===null||gi===void 0)&&gi[D.step].separator&&(D.needsSeparator=!D.needsSeparator):(D.needsSeparator=!1,D.step++))}function u(D){const mi=Array.isArray(D.rule)&&typeof D.rule[D.step]!="string"&&D.rule[D.step];return mi&&mi.isList}function l(D){for(;D.rule&&!(Array.isArray(D.rule)&&D.rule[D.step].ofRule);)v(D);D.rule&&hi(D,!1)}function vi(D,mi){const gi=Object.keys(D);for(let bi=0;bi<gi.length;bi++){const Ri=mi.match(D[gi[bi]]);if(Ri&&Ri instanceof Array)return{kind:gi[bi],value:Ri[0]}}}return onlineParser}var api={},hasRequiredApi;function requireApi(){return hasRequiredApi||(hasRequiredApi=1,function(r){Object.defineProperty(r,"__esModule",{value:!0}),r.getContextAtPosition=r.getTokenAtPosition=r.getDocumentMode=r.TYPE_SYSTEM_KINDS=r.GraphQLDocumentMode=r.runOnlineParser=void 0;const t=requireParser(),i=require$$0;function n(u,l){const vi=u.split(`
313
+ `),D=(0,t.onlineParser)();let mi=D.startState(),gi="",bi=new t.CharacterStream("");for(let Ri=0;Ri<vi.length;Ri++){for(bi=new t.CharacterStream(vi[Ri]);!bi.eol()&&(gi=D.token(bi,mi),l(bi,mi,gi,Ri)!=="BREAK"););l(bi,mi,gi,Ri),mi.kind||(mi=D.startState())}return{start:bi.getStartOfToken(),end:bi.getCurrentPosition(),string:bi.current(),state:mi,style:gi}}r.runOnlineParser=n;var s;(function(u){u.TYPE_SYSTEM="TYPE_SYSTEM",u.EXECUTABLE="EXECUTABLE",u.UNKNOWN="UNKNOWN"})(s=r.GraphQLDocumentMode||(r.GraphQLDocumentMode={})),r.TYPE_SYSTEM_KINDS=[i.Kind.SCHEMA_DEFINITION,i.Kind.OPERATION_TYPE_DEFINITION,i.Kind.SCALAR_TYPE_DEFINITION,i.Kind.OBJECT_TYPE_DEFINITION,i.Kind.INTERFACE_TYPE_DEFINITION,i.Kind.UNION_TYPE_DEFINITION,i.Kind.ENUM_TYPE_DEFINITION,i.Kind.INPUT_OBJECT_TYPE_DEFINITION,i.Kind.DIRECTIVE_DEFINITION,i.Kind.SCHEMA_EXTENSION,i.Kind.SCALAR_TYPE_EXTENSION,i.Kind.OBJECT_TYPE_EXTENSION,i.Kind.INTERFACE_TYPE_EXTENSION,i.Kind.UNION_TYPE_EXTENSION,i.Kind.ENUM_TYPE_EXTENSION,i.Kind.INPUT_OBJECT_TYPE_EXTENSION];const a=u=>{let l=s.UNKNOWN;if(u)try{(0,i.visit)((0,i.parse)(u),{enter(vi){if(vi.kind==="Document"){l=s.EXECUTABLE;return}return r.TYPE_SYSTEM_KINDS.includes(vi.kind)?(l=s.TYPE_SYSTEM,i.BREAK):!1}})}catch{return l}return l};function h(u,l){return l?.endsWith(".graphqls")?s.TYPE_SYSTEM:a(u)}r.getDocumentMode=h;function v(u,l,vi=0){let D=null,mi=null,gi=null;const bi=n(u,(Ri,Ti,Ii,qi)=>{if(!(qi!==l.line||Ri.getCurrentPosition()+vi<l.character+1))return D=Ii,mi=Object.assign({},Ti),gi=Ri.current(),"BREAK"});return{start:bi.start,end:bi.end,string:gi||bi.string,state:mi||bi.state,style:D||bi.style}}r.getTokenAtPosition=v;function hi(u,l,vi,D,mi){const gi=D||v(u,l,1);if(!gi)return null;const bi=gi.state.kind==="Invalid"?gi.state.prevState:gi.state;if(!bi)return null;const Ri=(0,t.getTypeInfo)(vi,gi.state),Ti=mi?.mode||h(u,mi?.uri);return{token:gi,state:bi,typeInfo:Ri,mode:Ti}}r.getContextAtPosition=hi}(api)),api}var getTypeInfo={},hasRequiredGetTypeInfo;function requireGetTypeInfo(){if(hasRequiredGetTypeInfo)return getTypeInfo;hasRequiredGetTypeInfo=1,Object.defineProperty(getTypeInfo,"__esModule",{value:!0}),getTypeInfo.getTypeInfo=getTypeInfo.getDefinitionState=getTypeInfo.forEachState=getTypeInfo.getFieldDef=void 0;const r=require$$0,t=requireParser();function i(h,v,hi){return hi===r.SchemaMetaFieldDef.name&&h.getQueryType()===v?r.SchemaMetaFieldDef:hi===r.TypeMetaFieldDef.name&&h.getQueryType()===v?r.TypeMetaFieldDef:hi===r.TypeNameMetaFieldDef.name&&(0,r.isCompositeType)(v)?r.TypeNameMetaFieldDef:"getFields"in v?v.getFields()[hi]:null}getTypeInfo.getFieldDef=i;function n(h,v){const hi=[];let u=h;for(;u?.kind;)hi.push(u),u=u.prevState;for(let l=hi.length-1;l>=0;l--)v(hi[l])}getTypeInfo.forEachState=n;function s(h){let v;return n(h,hi=>{switch(hi.kind){case"Query":case"ShortQuery":case"Mutation":case"Subscription":case"FragmentDefinition":v=hi;break}}),v}getTypeInfo.getDefinitionState=s;function a(h,v){let hi,u,l,vi,D,mi,gi,bi,Ri,Ti,Ii;return n(v,qi=>{var Oi;switch(qi.kind){case t.RuleKinds.QUERY:case"ShortQuery":Ti=h.getQueryType();break;case t.RuleKinds.MUTATION:Ti=h.getMutationType();break;case t.RuleKinds.SUBSCRIPTION:Ti=h.getSubscriptionType();break;case t.RuleKinds.INLINE_FRAGMENT:case t.RuleKinds.FRAGMENT_DEFINITION:qi.type&&(Ti=h.getType(qi.type));break;case t.RuleKinds.FIELD:case t.RuleKinds.ALIASED_FIELD:{!Ti||!qi.name?D=null:(D=Ri?i(h,Ri,qi.name):null,Ti=D?D.type:null);break}case t.RuleKinds.SELECTION_SET:Ri=(0,r.getNamedType)(Ti);break;case t.RuleKinds.DIRECTIVE:l=qi.name?h.getDirective(qi.name):null;break;case t.RuleKinds.INTERFACE_DEF:qi.name&&(gi=null,Ii=new r.GraphQLInterfaceType({name:qi.name,interfaces:[],fields:{}}));break;case t.RuleKinds.OBJECT_TYPE_DEF:qi.name&&(Ii=null,gi=new r.GraphQLObjectType({name:qi.name,interfaces:[],fields:{}}));break;case t.RuleKinds.ARGUMENTS:{if(qi.prevState)switch(qi.prevState.kind){case t.RuleKinds.FIELD:u=D&&D.args;break;case t.RuleKinds.DIRECTIVE:u=l&&l.args;break;case t.RuleKinds.ALIASED_FIELD:{const Ui=(Oi=qi.prevState)===null||Oi===void 0?void 0:Oi.name;if(!Ui){u=null;break}const Qi=Ri?i(h,Ri,Ui):null;if(!Qi){u=null;break}u=Qi.args;break}default:u=null;break}else u=null;break}case t.RuleKinds.ARGUMENT:if(u){for(let Ui=0;Ui<u.length;Ui++)if(u[Ui].name===qi.name){hi=u[Ui];break}}mi=hi?.type;break;case t.RuleKinds.VARIABLE_DEFINITION:case t.RuleKinds.VARIABLE:Ti=mi;break;case t.RuleKinds.ENUM_VALUE:const ki=(0,r.getNamedType)(mi);vi=ki instanceof r.GraphQLEnumType?ki.getValues().find(Ui=>Ui.value===qi.name):null;break;case t.RuleKinds.LIST_VALUE:const Li=(0,r.getNullableType)(mi);mi=Li instanceof r.GraphQLList?Li.ofType:null;break;case t.RuleKinds.OBJECT_VALUE:const ji=(0,r.getNamedType)(mi);bi=ji instanceof r.GraphQLInputObjectType?ji.getFields():null;break;case t.RuleKinds.OBJECT_FIELD:const Hi=qi.name&&bi?bi[qi.name]:null;mi=Hi?.type,D=Hi,Ti=D?D.type:null;break;case t.RuleKinds.NAMED_TYPE:qi.name&&(Ti=h.getType(qi.name));break}}),{argDef:hi,argDefs:u,directiveDef:l,enumValue:vi,fieldDef:D,inputType:mi,objectFieldDefs:bi,parentType:Ri,type:Ti,interfaceDef:Ii,objectTypeDef:gi}}return getTypeInfo.getTypeInfo=a,getTypeInfo}var types={},hasRequiredTypes;function requireTypes(){return hasRequiredTypes||(hasRequiredTypes=1,function(r){Object.defineProperty(r,"__esModule",{value:!0}),r.RuleKinds=r.AdditionalRuleKinds=void 0;const t=require$$0;r.AdditionalRuleKinds={ALIASED_FIELD:"AliasedField",ARGUMENTS:"Arguments",SHORT_QUERY:"ShortQuery",QUERY:"Query",MUTATION:"Mutation",SUBSCRIPTION:"Subscription",TYPE_CONDITION:"TypeCondition",INVALID:"Invalid",COMMENT:"Comment",SCHEMA_DEF:"SchemaDef",SCALAR_DEF:"ScalarDef",OBJECT_TYPE_DEF:"ObjectTypeDef",OBJECT_VALUE:"ObjectValue",LIST_VALUE:"ListValue",INTERFACE_DEF:"InterfaceDef",UNION_DEF:"UnionDef",ENUM_DEF:"EnumDef",ENUM_VALUE:"EnumValue",FIELD_DEF:"FieldDef",INPUT_DEF:"InputDef",INPUT_VALUE_DEF:"InputValueDef",ARGUMENTS_DEF:"ArgumentsDef",EXTEND_DEF:"ExtendDef",EXTENSION_DEFINITION:"ExtensionDefinition",DIRECTIVE_DEF:"DirectiveDef",IMPLEMENTS:"Implements",VARIABLE_DEFINITIONS:"VariableDefinitions",TYPE:"Type",VARIABLE:"Variable"},r.RuleKinds=Object.assign(Object.assign({},t.Kind),r.AdditionalRuleKinds)}(types)),types}var hasRequiredParser;function requireParser(){return hasRequiredParser||(hasRequiredParser=1,function(r){var t=parser&&parser.__createBinding||(Object.create?function(l,vi,D,mi){mi===void 0&&(mi=D);var gi=Object.getOwnPropertyDescriptor(vi,D);(!gi||("get"in gi?!vi.__esModule:gi.writable||gi.configurable))&&(gi={enumerable:!0,get:function(){return vi[D]}}),Object.defineProperty(l,mi,gi)}:function(l,vi,D,mi){mi===void 0&&(mi=D),l[mi]=vi[D]}),i=parser&&parser.__exportStar||function(l,vi){for(var D in l)D!=="default"&&!Object.prototype.hasOwnProperty.call(vi,D)&&t(vi,l,D)},n=parser&&parser.__importDefault||function(l){return l&&l.__esModule?l:{default:l}};Object.defineProperty(r,"__esModule",{value:!0}),r.getFieldDef=r.getDefinitionState=r.getTypeInfo=r.getDocumentMode=r.GraphQLDocumentMode=r.getContextAtPosition=r.getTokenAtPosition=r.runOnlineParser=r.onlineParser=r.t=r.p=r.opt=r.list=r.butNot=r.isIgnored=r.ParseRules=r.LexRules=r.CharacterStream=void 0;var s=requireCharacterStream();Object.defineProperty(r,"CharacterStream",{enumerable:!0,get:function(){return n(s).default}});var a=requireRules();Object.defineProperty(r,"LexRules",{enumerable:!0,get:function(){return a.LexRules}}),Object.defineProperty(r,"ParseRules",{enumerable:!0,get:function(){return a.ParseRules}}),Object.defineProperty(r,"isIgnored",{enumerable:!0,get:function(){return a.isIgnored}});var h=requireRuleHelpers();Object.defineProperty(r,"butNot",{enumerable:!0,get:function(){return h.butNot}}),Object.defineProperty(r,"list",{enumerable:!0,get:function(){return h.list}}),Object.defineProperty(r,"opt",{enumerable:!0,get:function(){return h.opt}}),Object.defineProperty(r,"p",{enumerable:!0,get:function(){return h.p}}),Object.defineProperty(r,"t",{enumerable:!0,get:function(){return h.t}});var v=requireOnlineParser();Object.defineProperty(r,"onlineParser",{enumerable:!0,get:function(){return n(v).default}});var hi=requireApi();Object.defineProperty(r,"runOnlineParser",{enumerable:!0,get:function(){return hi.runOnlineParser}}),Object.defineProperty(r,"getTokenAtPosition",{enumerable:!0,get:function(){return hi.getTokenAtPosition}}),Object.defineProperty(r,"getContextAtPosition",{enumerable:!0,get:function(){return hi.getContextAtPosition}}),Object.defineProperty(r,"GraphQLDocumentMode",{enumerable:!0,get:function(){return hi.GraphQLDocumentMode}}),Object.defineProperty(r,"getDocumentMode",{enumerable:!0,get:function(){return hi.getDocumentMode}});var u=requireGetTypeInfo();Object.defineProperty(r,"getTypeInfo",{enumerable:!0,get:function(){return u.getTypeInfo}}),Object.defineProperty(r,"getDefinitionState",{enumerable:!0,get:function(){return u.getDefinitionState}}),Object.defineProperty(r,"getFieldDef",{enumerable:!0,get:function(){return u.getFieldDef}}),i(requireTypes(),r)}(parser)),parser}var parserExports=requireParser();({...RuleKinds});({...parserExports.ParseRules});parserExports.p("@"),name("directiveName"),parserExports.opt("Argument"),name("typeName"),parserExports.opt("Member"),parserExports.p("."),name("memberName"),parserExports.opt("Argument"),parserExports.p("("),name("argumentName"),parserExports.p(":"),parserExports.p(")");function name(r){return{style:r,match:t=>t.kind==="Name",update(t,i){t.name=i.value}}}var IntrospectionField=(r=>(r.SCHEMA_FIELD="__schema",r.TYPENAME_FIELD="__typename",r.TYPE_FIELD="__type",r.TYPE_FIELDS_FIELD="fields",r.TYPE_INTERFACES_FIELD="interfaces",r.TYPE_POSSIBLE_TYPES_FIELD="possibleTypes",r.TYPE_INPUT_FIELDS_FIELD="inputFields",r))(IntrospectionField||{});const AT="@",COLON=":",DOT=".",PAREN_L="(",PAREN_R=")";function createSchemaDirectiveCoordinate(r,t){const i=AT+r;return t?withArgument(i,t):i}function createSchemaMemberCoordinate(r,t,i){const n=r+DOT+t;return i?withArgument(n,i):n}function withArgument(r,t){return r+PAREN_L+t+COLON+PAREN_R}function getInnerType(r){let t=r.kind==="argument"?r.type:r.kind==="field"?r.valueType:r;for(;t.kind==="value-type";)t=t.type;return t}IntrospectionField.TYPE_FIELDS_FIELD,IntrospectionField.TYPE_INTERFACES_FIELD,IntrospectionField.TYPE_POSSIBLE_TYPES_FIELD,IntrospectionField.TYPE_INPUT_FIELDS_FIELD;class MessageObserver{#e=[];#t=new Map;handleMessage(t,i){const n=this.#t.get(i.id);if(n){n(i,t);return}this.#e.filter(s=>s.type===i.type).forEach(({handle:s})=>s(i,t))}registerReceiveMessageHandler(t,i){const n={type:t,handle:i};return this.#e.push(n),()=>{const s=this.#e.indexOf(n);this.#e.splice(s,1)}}sendAndReceiveMessage(t,i=!1,n){let s,a;return createAbortScope(()=>a?.(),()=>new Promise((h,v)=>{a=()=>{self.clearTimeout(s),v(ABORT_ERROR),cancelTask$1(this.getContext(),t.id),this.#t.delete(t.id)},s=i?void 0:self.setTimeout(()=>{v("Timeout exceeded 60 sec."),this.#t.delete(t.id)},ONE_MINUTE),this.#t.set(t.id,hi=>{if(!n?.aborted){if(isTaskFailedMessage(hi)){const{errorMessage:u,kind:l,details:vi}=hi.payload;v(new TaskFailedError(u,l,vi))}else h(hi.payload);self.clearTimeout(s),this.#t.delete(hi.id)}}),this.getContext().sendMessage(t)}),n)}sendMessage(t){this.getContext().sendMessage(t)}}class Message{constructor(t,i,n){this.type=t,this.payload=i,this.id=n||createId(),this.createdAt=now()}id;createdAt}const CANCEL_TASK_MESSAGE_TYPE="cancel-task";function cancelTask$1(r,t){r.sendMessage(new Message(CANCEL_TASK_MESSAGE_TYPE,{taskId:t}))}const TASK_FAILED_MESSAGE_TYPE="task-failed";function failTask(r,t,i,n,s){r.sendMessage(new Message(TASK_FAILED_MESSAGE_TYPE,{errorMessage:i,kind:n,details:s},t))}class TaskFailedError extends Error{constructor(t,i,n){super(t),this.kind=i,this.details=n}}function isTaskFailedMessage(r){return r.type===TASK_FAILED_MESSAGE_TYPE}const INITIALIZE_WORKER_MESSAGE_TYPE="initialize-worker",_gql_source$4=`query IntrospectionQuery {
314
+ __type(name: "__Directive") {
315
+ name
316
+ fields {
317
+ name
318
+ }
319
+ }
320
+ }
321
+ `,_gql_doc$4={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"IntrospectionQuery"},variableDefinitions:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"__type"},arguments:[{kind:"Argument",name:{kind:"Name",value:"name"},value:{kind:"StringValue",value:"__Directive",block:!1}}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"fields"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]}]}}]}}]}}],loc:{start:0,end:142,source:{name:"GraphQL request",locationOffset:{line:1,column:1},body:_gql_source$4}}},_gql_source$3=`query IntrospectionQuery {
322
+ __type(name: "__InputValue") {
323
+ name
324
+ fields {
325
+ name
326
+ }
327
+ }
328
+ }
329
+ `,_gql_doc$3={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"IntrospectionQuery"},variableDefinitions:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"__type"},arguments:[{kind:"Argument",name:{kind:"Name",value:"name"},value:{kind:"StringValue",value:"__InputValue",block:!1}}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"fields"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]}]}}]}}]}}],loc:{start:0,end:143,source:{name:"GraphQL request",locationOffset:{line:1,column:1},body:_gql_source$3}}},_gql_source$2=`query IntrospectionQuery {
330
+ __type(name: "__Schema") {
331
+ name
332
+ fields {
333
+ name
334
+ }
335
+ }
336
+ }
337
+ `,_gql_doc$2={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"IntrospectionQuery"},variableDefinitions:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"__type"},arguments:[{kind:"Argument",name:{kind:"Name",value:"name"},value:{kind:"StringValue",value:"__Schema",block:!1}}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"fields"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]}]}}]}}]}}],loc:{start:0,end:139,source:{name:"GraphQL request",locationOffset:{line:1,column:1},body:_gql_source$2}}},_gql_source$1=`query IntrospectionQuery {
338
+ __type(name: "__SearchResult") {
339
+ name
340
+ }
341
+ }
342
+ `,_gql_doc$1={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"IntrospectionQuery"},variableDefinitions:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"__type"},arguments:[{kind:"Argument",name:{kind:"Name",value:"name"},value:{kind:"StringValue",value:"__SearchResult",block:!1}}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]}]}}]}}],loc:{start:0,end:115,source:{name:"GraphQL request",locationOffset:{line:1,column:1},body:_gql_source$1}}},_gql_source=`query IntrospectionQuery {
343
+ __type(name: "__Type") {
344
+ name
345
+ fields {
346
+ name
347
+ }
348
+ }
349
+ }
350
+ `,_gql_doc={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"IntrospectionQuery"},variableDefinitions:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"__type"},arguments:[{kind:"Argument",name:{kind:"Name",value:"name"},value:{kind:"StringValue",value:"__Type",block:!1}}],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]},{kind:"Field",name:{kind:"Name",value:"fields"},arguments:[],directives:[],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"},arguments:[],directives:[]}]}}]}}]}}],loc:{start:0,end:137,source:{name:"GraphQL request",locationOffset:{line:1,column:1},body:_gql_source}}};print(_gql_doc$4);print(_gql_doc$3);print(_gql_doc$2);print(_gql_doc$1);print(_gql_doc);class SchemaCache{#e=new LRUMap;get(t){return this.#e.get(t)??null}set(t,i){const n=new SchemaCacheItem(i);return this.#e.get(t)?.dispose(),this.#e.set(t,n),n}remove(t){this.#e.get(t)?.dispose(),this.#e.delete(t)}}class SchemaCacheItem{#e;#t;#r;#i;constructor(t){this.#e=new Map(t.directives),this.#t=new Map(t.fields),this.#r=new Map(t.types),this.#i=new Map(t.fields)}getDirective(t){return this.#e.get(t)??null}getDirectives(t){const i=[];if(t?.length){const n=t.toLocaleLowerCase();this.#e.forEach(s=>{!INTROSPECTION_PREFIX.test(s.name)&&s.name.toLocaleLowerCase().includes(n)&&i.push(s)})}else this.#e.forEach(n=>{INTROSPECTION_PREFIX.test(n.name)||i.push(n)});return i.sort(objectNameComparer)}getField(t){return this.#t.get(t)??null}getFields(t,i){const n=t+".",s=[];if(i?.includeIntrospectionFields&&this.addIntrospectionFields(t,s),i?.filter?.length){const a=i.filter.toLocaleLowerCase();this.#t.forEach(h=>{h.coordinate.startsWith(n)&&h.name.toLocaleLowerCase().includes(a)&&s.push(h)})}else this.#t.forEach(a=>{a.coordinate.startsWith(n)&&s.push(a)});return s.sort(objectNameComparer)}getType(t){return this.#r.get(t)??null}getTypes(t){const i=[];if(t?.length){const n=t.toLocaleLowerCase();this.#r.forEach(s=>{!INTROSPECTION_PREFIX.test(s.name)&&s.name.toLocaleLowerCase().includes(n)&&i.push(s)})}else this.#r.forEach(n=>{INTROSPECTION_PREFIX.test(n.name)||i.push(n)});return i.sort(objectNameComparer)}getInterfaces(t,i){const n=this.#r.get(t);if(!n?.interfaces?.length)return[];if(i?.length){const s=i.toLocaleLowerCase();return n.interfaces.filter(({name:a})=>a.toLocaleLowerCase().includes(s)).sort(objectNameComparer)}return n.interfaces.sort(objectNameComparer)}getPossibleTypes(t,i){const n=this.#r.get(t);if(!n?.types?.length)return[];if(i?.length){const s=i.toLocaleLowerCase();return n.types.map(getInnerType).filter(({name:a})=>a.toLocaleLowerCase().includes(s)).sort(objectNameComparer)}return n.types.map(getInnerType).sort(objectNameComparer)}getTypesByTypeKind(t,i){const n=[];if(i?.length){const s=i.toLocaleLowerCase();this.#r.forEach(a=>{a.typeKind===t&&!INTROSPECTION_PREFIX.test(a.name)&&a.name.toLocaleLowerCase().includes(s)&&n.push(a)})}else this.#r.forEach(s=>{s.typeKind===t&&!INTROSPECTION_PREFIX.test(s.name)&&n.push(s)});return n.sort(objectNameComparer)}dispose(){this.#e.clear(),this.#t.clear(),this.#r.clear()}addIntrospectionFields(t,i){const n=this.#r.get(t),s=n?.kind==="query-type",a=n?.kind==="subscription-type";if(s){const h=this.getIntrospectionSchemaField(n.name);h&&i.push(h);const v=this.getIntrospectionTypeField(n.name);v&&i.push(v)}if(!a&&n){const h=this.getIntrospectionTypenameField(n.name);h&&i.push(h)}}getIntrospectionSchemaField(t){const i=IntrospectionField.SCHEMA_FIELD;let n=this.#i.get(i);if(!n){const s=this.#r.get("__Schema");s&&(n={kind:"field",name:i,coordinate:createSchemaMemberCoordinate(t,i),valueType:{kind:"value-type",isList:!1,isOptional:!1,type:s}},this.#i.set(i,n))}return n}getIntrospectionTypeField(t){const i=IntrospectionField.TYPE_FIELD;let n=this.#i.get(i);if(!n){const s=this.#r.get("__Type"),a=this.#r.get("String");s&&a&&(n={kind:"field",name:i,coordinate:createSchemaMemberCoordinate(t,i),valueType:{kind:"value-type",isList:!1,isOptional:!0,type:s},arguments:[{kind:"argument",name:"name",coordinate:createSchemaMemberCoordinate(t,i,"name"),type:{kind:"value-type",isList:!1,isOptional:!1,type:a}}]},this.#i.set(i,n))}return n}getIntrospectionTypenameField(t){const i=IntrospectionField.TYPENAME_FIELD;let n=this.#i.get(i);if(n)n={...n,coordinate:createSchemaMemberCoordinate(t,IntrospectionField.TYPE_FIELD)};else{const s=this.#r.get("String");s&&(n={kind:"field",name:i,coordinate:createSchemaMemberCoordinate(t,i),valueType:{kind:"value-type",isList:!1,isOptional:!1,type:s}},this.#i.set(i,n))}return n}}const schemaCache=new SchemaCache;function setSchemaCacheItem(r,t){schemaCache.set(harmonizeSchemaUrl(r),t)}const LINE_BREAK="<br />",SPACE=" ";function printAsHTML(r){return visit(r,printDocASTReducer)}const printDocASTReducer={Name:{leave:r=>r.value},Argument:{leave:({name:r,value:t})=>wrapArgumentName(r)+wrapDelimiter(":")+SPACE+t},IntValue:{leave:({value:r})=>wrapNumberValue(r)},FloatValue:{leave:({value:r})=>wrapNumberValue(r)},StringValue:{leave:({value:r,block:t})=>wrapStringValue(t?printBlockString(r):printString(r))},BooleanValue:{leave:({value:r})=>wrapLiteral(r?"true":"false")},NullValue:{leave:()=>wrapLiteral("null")},EnumValue:{leave:({value:r})=>wrapEnumValue(r)},ListValue:{leave:({values:r})=>block(r,"[]")},ObjectValue:{leave:({fields:r})=>block(r,"{}")},ObjectField:{leave:({name:r,value:t})=>wrapKey(r)+wrapDelimiter(":")+SPACE+t},Directive:{leave:({name:r,arguments:t})=>r.startsWith("fusion__")?"":LINE_BREAK+indent(wrapDirectiveName("@"+r)+block(t,"()"))},NamedType:{leave:({name:r})=>wrapTypeName(r)},ListType:{leave:({type:r})=>wrapDelimiter("[")+r+wrapDelimiter("]")},NonNullType:{leave:({type:r})=>r+wrapDelimiter("!")},DirectiveDefinition:{leave:({name:r,arguments:t})=>wrapKeyword("directive")+SPACE+wrapDirectiveName(r)+block(t,"()")},ScalarTypeDefinition:{leave:({name:r,directives:t})=>join([wrapKeyword("scalar"),wrapTypeName(r),join(t,SPACE)],SPACE)},ObjectTypeDefinition:{leave:({name:r,interfaces:t,directives:i})=>join([wrapKeyword("type"),wrapTypeName(r),wrap(wrapKeyword("implements")+SPACE,join(t,LINE_BREAK+wrapDelimiter("&")+SPACE)),join(i,SPACE)],SPACE)},FieldDefinition:{leave:({name:r,arguments:t,type:i,directives:n})=>wrapFieldName(r)+block(t,"()")+wrapDelimiter(":")+SPACE+i+wrap(SPACE,join(n,SPACE))},InputValueDefinition:{leave:({name:r,type:t,defaultValue:i,directives:n})=>join([wrapArgumentName(r)+wrapDelimiter(":")+SPACE+t,wrap(wrapDelimiter("=")+SPACE,i),join(n,SPACE)],SPACE)},InterfaceTypeDefinition:{leave:({name:r,interfaces:t,directives:i})=>join([wrapKeyword("interface"),wrapTypeName(r),wrap(wrapKeyword("implements")+SPACE,join(t,`${LINE_BREAK}${wrapDelimiter("&")} `)),join(i,SPACE)],SPACE)},UnionTypeDefinition:{leave:({name:r,directives:t})=>join([wrapKeyword("union"),wrapTypeName(r),join(t,SPACE)],SPACE)},EnumTypeDefinition:{leave:({name:r,directives:t})=>join([wrapKeyword("enum"),wrapTypeName(r),join(t,SPACE)],SPACE)},EnumValueDefinition:{leave:({name:r,directives:t})=>join([wrapEnumValue(r),join(t,SPACE)],SPACE)},InputObjectTypeDefinition:{leave:({name:r,directives:t})=>join([wrapKeyword("input"),wrapTypeName(r),join(t,SPACE)],SPACE)}};function join(r,t=""){return r?.filter(i=>i).join(t)??""}function block(r,t){switch(t){case"{}":return wrap(wrapDelimiter("{")+LINE_BREAK,indent(join(r,LINE_BREAK)),LINE_BREAK+wrapDelimiter("}"));case"[]":return wrap(wrapDelimiter("[")+LINE_BREAK,indent(join(r,LINE_BREAK)),LINE_BREAK+wrapDelimiter("]"));case"()":return wrap(wrapDelimiter("(")+LINE_BREAK,indent(join(r,LINE_BREAK)),LINE_BREAK+wrapDelimiter(")"))}}function wrap(r,t,i=""){return t!=null&&t!==""?r+t+i:""}function indent(r){return wrap(SPACE+SPACE,r.replaceAll(LINE_BREAK,LINE_BREAK+SPACE+SPACE))}function wrapArgumentName(r){return`<span class="argument">${r}</span>`}function wrapDelimiter(r){return`<span class="delimiter">${r}</span>`}function wrapDirectiveName(r){return`<span class="directive">${r}</span>`}function wrapEnumValue(r){return`<span class="enum-value">${r}</span>`}function wrapFieldName(r){return`<span class="field">${r}</span>`}function wrapKey(r){return`<span class="key">${r}</span>`}function wrapKeyword(r){return`<span class="keyword">${r}</span>`}function wrapLiteral(r){return`<span class="literal">${r}</span>`}function wrapNumberValue(r){return`<span class="number">${r}</span>`}function wrapStringValue(r){return`<span class="string">${r}</span>`}function wrapTypeName(r){return`<span class="type">${r}</span>`}function buildSchemaInfosAndItems(r){const t=[],i=[],n=[],s=Object.values(r.getTypeMap()).filter(vi=>!INTROSPECTION_PREFIX.test(vi.name)&&!vi.name.startsWith("fusion__")),a=r.getQueryType(),h=r.getMutationType(),v=r.getSubscriptionType(),hi=(a?1:0)+(h?1:0)+(v?1:0),u=Object.values(r.getTypeMap()).find(vi=>vi.name==="fusion__Schema")?.getValues().reduce((vi,D)=>{const mi=D.astNode?.directives?.find(gi=>gi.name.value==="fusion__schema_metadata")?.arguments?.find(gi=>gi.name.value==="name")?.value;return vi[D.name]=mi?.kind===Kind.STRING?mi.value:D.name,vi},{});for(const vi of s){const D=buildSchemaType(r,vi,u);n.push([D.coordinate,D]);const mi=buildSchemaFieldTypes(r,vi,void 0,u);for(const gi of mi)i.push([gi.coordinate,gi])}for(const vi of r.getDirectives()){if(vi.name.startsWith("fusion__"))continue;const D=buildSchemaDirective(r,vi);t.push([D.coordinate,D])}const l={queryCount:getCountForOperationType(a),mutationCount:getCountForOperationType(h),subscriptionCount:getCountForOperationType(v),directiveCount:t.length,enumCount:s.filter(vi=>vi instanceof GraphQLEnumType).length,fieldCount:i.length,inputObjectCount:s.filter(vi=>vi instanceof GraphQLInputObjectType).length,interfaceCount:s.filter(vi=>vi instanceof GraphQLInterfaceType).length,objectCount:s.filter(vi=>vi instanceof GraphQLObjectType).length,rootTypeCount:hi,scalarCount:s.filter(vi=>vi instanceof GraphQLScalarType).length,typeCount:s.length,unionCount:s.filter(vi=>vi instanceof GraphQLUnionType).length};return{queryTypeName:a?.name,mutationTypeName:h?.name,subscriptionTypeName:v?.name,statistics:l,items:{directives:t,fields:i,types:n}}}function getKind(r){return r instanceof GraphQLEnumType?"enum":r instanceof GraphQLInputObjectType?"input-object":r instanceof GraphQLInterfaceType?"interface":r instanceof GraphQLScalarType?"scalar":r instanceof GraphQLUnionType?"union":r instanceof GraphQLList||r instanceof GraphQLNonNull?getKind(r.ofType):"object"}function buildSchemaFieldType(r,t,i,n){if(t instanceof GraphQLInputObjectType){const s=t.getFields()[i];if(s)return{coordinate:createSchemaMemberCoordinate(t.name,s.name),name:s.name,kind:"field",description:s.description||void 0,valueType:buildSchemaValueType(r,s.type,n),defaultValue:s.defaultValue,isDeprecated:!!s.deprecationReason?.length,deprecationReason:s.deprecationReason??void 0,sdlAsHTML:s.astNode?printAsHTML(s.astNode):void 0,directives:buildConstDirective(s.astNode?.directives,n)}}else if(t instanceof GraphQLInterfaceType||t instanceof GraphQLObjectType){const s=t.getFields()[i];if(s){const a=s.args.length?s.args.map(h=>{const v=buildSchemaValueType(r,h.type,n);return{coordinate:createSchemaMemberCoordinate(t.name,s.name,h.name),name:h.name,kind:"argument",description:h.description||void 0,defaultValue:h.defaultValue||void 0,type:v,isDeprecated:!!s.deprecationReason?.length,deprecationReason:h.deprecationReason||void 0,sdlAsHTML:h.astNode?printAsHTML(h.astNode):void 0,directives:buildConstDirective(h.astNode?.directives,n)}}):void 0;return{coordinate:createSchemaMemberCoordinate(t.name,s.name),name:s.name,kind:"field",description:s.description??void 0,arguments:a,valueType:buildSchemaValueType(r,s.type,n),isDeprecated:!!s.deprecationReason?.length,deprecationReason:s.deprecationReason??void 0,sdlAsHTML:s.astNode?printAsHTML(s.astNode):void 0,directives:buildConstDirective(s.astNode?.directives,n)}}}}function buildSchemaFieldTypes(r,t,i,n){const s=[];if(t instanceof GraphQLInputObjectType){const a=t.getFields();for(const h in a){const v=a[h];s.push({coordinate:createSchemaMemberCoordinate(t.name,v.name),name:v.name,kind:"field",description:v.description||void 0,valueType:buildSchemaValueType(r,v.type,n),defaultValue:v.defaultValue,isDeprecated:!!v.deprecationReason?.length,deprecationReason:v.deprecationReason??void 0,sdlAsHTML:v.astNode?printAsHTML(v.astNode):void 0,directives:buildConstDirective(v.astNode?.directives,n)})}}else if(t instanceof GraphQLInterfaceType||t instanceof GraphQLObjectType){const a=t.getFields();for(const h in a){const v=a[h];{const hi=v.args.length===0?void 0:v.args.map(u=>{const l=buildSchemaValueType(r,u.type,n);return{coordinate:createSchemaMemberCoordinate(t.name,v.name,u.name),name:u.name,kind:"argument",description:u.description||void 0,defaultValue:u.defaultValue||void 0,type:l,isDeprecated:!!u.deprecationReason?.length,deprecationReason:u.deprecationReason||void 0,sdlAsHTML:u.astNode?printAsHTML(u.astNode):void 0,directives:buildConstDirective(u.astNode?.directives,n)}});s.push({coordinate:createSchemaMemberCoordinate(t.name,v.name),name:v.name,kind:"field",description:v.description||void 0,arguments:hi,valueType:buildSchemaValueType(r,v.type,n),isDeprecated:!!v.deprecationReason?.length,deprecationReason:v.deprecationReason||void 0,sdlAsHTML:v.astNode?printAsHTML(v.astNode):void 0,directives:buildConstDirective(v.astNode?.directives,n)})}}}return s.sort(objectNameComparer)}function buildSchemaDirective(r,t){const i=t.args.length?t.args.map(n=>{const s=buildSchemaValueType(r,n.type,void 0);return{coordinate:createSchemaDirectiveCoordinate(t.name,n.name),name:n.name,kind:"argument",description:n.description??void 0,defaultValue:n.defaultValue??void 0,type:s,isDeprecated:!!n.deprecationReason?.length,deprecationReason:n.deprecationReason??void 0,sdlAsHTML:n.astNode?printAsHTML(n.astNode):void 0}}):void 0;return{coordinate:createSchemaDirectiveCoordinate(t.name),name:t.name,kind:"directive",description:t.description??void 0,arguments:i,sdlAsHTML:t.astNode?printAsHTML(t.astNode):void 0}}function buildSchemaType(r,t,i){let n,s,a,h=!1;return t instanceof GraphQLEnumType&&(n=t.getValues().map(v=>v).sort(objectNameComparer).map(v=>({coordinate:createSchemaMemberCoordinate(t.name,v.name),name:v.name,kind:"enum-value",description:v.description||void 0,value:v.value,isDeprecated:!!v.deprecationReason?.length,deprecationReason:v.deprecationReason??void 0,sdlAsHTML:v.astNode?printAsHTML(v.astNode):void 0,directives:buildConstDirective(v.astNode?.directives,i)}))),t instanceof GraphQLInterfaceType&&(h=isRelayInterface(r,t),a=r.getPossibleTypes(t).map(v=>v).sort(objectNameComparer).map(v=>buildSchemaValueType(r,v,i))),t instanceof GraphQLObjectType&&(h=isRelayObject(r,t),s=t.getInterfaces().map(v=>({coordinate:v.name,name:v.name,kind:"type",description:v.description||void 0,typeKind:"interface",isRelayType:isRelayObject(r,t),sdlAsHTML:v.astNode?printAsHTML(v.astNode):void 0,directives:buildConstDirective(v.astNode?.directives,i)}))),t instanceof GraphQLUnionType&&(a=t.getTypes().map(v=>v).sort(objectNameComparer).map(v=>buildSchemaValueType(r,v,i))),{coordinate:t.name,name:t.name,kind:t instanceof GraphQLObjectType?resolveObjectKind(r,t):"type",description:t.description||void 0,typeKind:getKind(t),enumValues:n,interfaces:s,isRelayType:h,types:a,sdlAsHTML:t.astNode?printAsHTML(t.astNode):void 0,directives:buildConstDirective(t.astNode?.directives,i)}}function buildConstDirective(r,t){return r?.map(({name:i,arguments:n})=>({name:i.value,arguments:n?.map(({name:s,value:a})=>({name:s.value,value:buildConstValue(a,t)}))}))}function buildConstValue(r,t){switch(r?.kind){case Kind.OBJECT:return r.fields.reduce((i,n)=>(i[n.name.value]=buildConstValue(n.value,t),i),{});case Kind.LIST:return r.values.map(i=>buildConstValue(i,t));case Kind.ENUM:return t?.[r.value]??r.value;case Kind.BOOLEAN:case Kind.FLOAT:case Kind.INT:case Kind.STRING:return r.value;default:return null}}function isRelayInterface(r,t){return t.name==="Node"&&!!buildSchemaFieldType(r,t,"id",void 0)}function isRelayObject(r,t){if(t.name.endsWith("Connection")){const i=buildSchemaFieldTypes(r,t,void 0,void 0).map(n=>n.name);return i.includes("edges")&&i.includes("pageInfo")}if(t.name.endsWith("Edge")){const i=buildSchemaFieldTypes(r,t,void 0,void 0).map(n=>n.name);return i.includes("cursor")&&i.includes("node")}if(t.name==="PageInfo"){const i=buildSchemaFieldTypes(r,t,void 0,void 0).map(n=>n.name);return i.includes("hasNextPage")&&i.includes("hasPreviousPage")&&i.includes("startCursor")&&i.includes("endCursor")}return!1}function buildSchemaValueType(r,t,i){let n,s=!1,a=!0,h;return t instanceof GraphQLNonNull?(a=!1,t.ofType instanceof GraphQLList?(n=t.ofType.ofType,s=!0):n=t.ofType):t instanceof GraphQLList?(n=t.ofType,s=!0):n=t,n instanceof GraphQLList||n instanceof GraphQLNonNull?h=buildSchemaValueType(r,n,i):h=buildSchemaType(r,n,i),{kind:"value-type",isList:s,isOptional:a,type:h}}function resolveObjectKind(r,t){switch(!0){case t===r.getQueryType():return"query-type";case t===r.getMutationType():return"mutation-type";case t===r.getSubscriptionType():return"subscription-type";default:return"type"}}function getCountForOperationType(r){return r?Object.keys(r.getFields()).length:0}const runningTasks=new Map;function cancelTask(r){runningTasks.get(r)?.cancel()}function enqueueTask(r){runningTasks.has(r.id)||(runningTasks.set(r.id,r),SCHEDULER_CONTEXT.sendMessage(new Message("scheduler-status-updated",{idling:!1,lastUpdated:now()})),deferWork(()=>{r.execute().catch(t=>{t instanceof TaskFailedError?failTask(SCHEDULER_CONTEXT,r.id,t.message,t.kind,t.details):t instanceof Error?failTask(SCHEDULER_CONTEXT,r.id,t.message,"UNEXPECTED_ERROR"):failTask(SCHEDULER_CONTEXT,r.id,"There was a unexpected error in the task","UNEXPECTED_ERROR")}).finally(()=>{runningTasks.delete(r.id),SCHEDULER_CONTEXT.sendMessage(new Message("scheduler-status-updated",{idling:runningTasks.size===0,lastUpdated:now()}))})}))}function deferWork(r){self.setTimeout(r,0)}const SCHEDULER_CONTEXT={sendMessage:r=>self.postMessage(r)};class SchedulerBase extends MessageObserver{#e={sendMessage:t=>self.postMessage(t)};constructor(){super(),this.initialize()}getContext(){return this.#e}initialize(){self.onmessage=({data:t})=>{this.handleMessage(this.#e,t)},this.registerReceiveMessageHandler(CANCEL_TASK_MESSAGE_TYPE,t=>{cancelTask(t.payload.taskId)}),this.registerReceiveMessageHandler(INITIALIZE_WORKER_MESSAGE_TYPE,t=>{self.appNamespace=t.payload.appNamespace}),this.registerMessageReceiveHandlers()}}const INDEX_SCHEMA_MESSAGE_TYPE="index-schema",SCHEMA_INDEXED_MESSAGE_TYPE="schema-indexed",runningIndexingJobs=new Map;function indexSchema({id:r,payload:{schemaEndpoint:t,schemaHash:i,schemaUpdatedAt:n}},s){const a=runningIndexingJobs.get(t);if(a){if(a.schemaHash===i||a.schemaUpdatedAt>n)return;cancelTask(a.taskId)}runningIndexingJobs.set(t,{taskId:r,schemaHash:i,schemaUpdatedAt:n});const h=new AbortController;enqueueTask({id:r,cancel:()=>h.abort(),execute:async()=>{const[v,hi]=await Promise.all([getGraphQLSchemaEntity(t),getGraphQLSdlSchema(t)]);if(!v||!hi||v.indexed||h.signal.aborted){s.sendMessage(new Message(SCHEMA_INDEXED_MESSAGE_TYPE,{schemaEndpoint:v?.endpoint??t,schemaHash:v?.hash??"",schemaIndexed:v?.indexed??!1}));return}let u=!1;try{const{statistics:l,items:vi}=buildSchemaInfosAndItems(buildSchema(hi));setSchemaCacheItem(v.endpoint,vi),await setIndexedGraphQLSchemaEntity(v.endpoint,v.hash,vi,l),u=!0}finally{s.sendMessage(new Message(SCHEMA_INDEXED_MESSAGE_TYPE,{schemaEndpoint:v.endpoint,schemaHash:v.hash,schemaIndexed:u}))}}})}class GraphQLIndexerScheduler extends SchedulerBase{registerMessageReceiveHandlers(){this.registerReceiveMessageHandler(INDEX_SCHEMA_MESSAGE_TYPE,indexSchema)}}new GraphQLIndexerScheduler;