1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5572],{9838:function(e,t,r){var n="/",i=r(6035),o=r(1580).Buffer;(()=>{var t={383:e=>{"use strict";function t(e,t){let r=Array.from(e.matchAll(t));return r.length>0?r.slice(-1)[0].index:-1}function r(e,n,i){let o=t(e,/(?!(?<=\\))\$/g);if(-1===o)return e;let s=e.slice(o),a=/((?!(?<=\\))\${?([\w]+)(?::-([^}\\]*))?}?)/,u=s.match(a);if(null!=u){let[,t,o,s]=u;return r(e.replace(t,n[o]||s||i.parsed[o]||""),n,i)}return e}function n(e){return e.replace(/\\\$/g,"$")}function o(e){let t=e.ignoreProcessEnv?{}:i.env;for(let i in e.parsed){let o=Object.prototype.hasOwnProperty.call(t,i)?t[i]:e.parsed[i];e.parsed[i]=n(r(o,t,e))}for(let r in e.parsed)t[r]=e.parsed[r];return e}e.exports.j=o},234:(e,t,r)=>{let n=r(147),s=r(17),a=r(37),u=r(113),c=r(803).version,l=/(?:^|^)\s*(?:export\s+)?([\w.-]+)(?:\s*=\s*?|:\s+?)(\s*'(?:\\'|[^'])*'|\s*"(?:\\"|[^"])*"|\s*`(?:\\`|[^`])*`|[^#\r\n]+)?\s*(?:#.*)?(?:$|$)/gm;function f(e){console.log(`[dotenv@${c}][INFO] ${e}`)}function p(e){console.log(`[dotenv@${c}][WARN] ${e}`)}function h(e){console.log(`[dotenv@${c}][DEBUG] ${e}`)}function d(e){return e&&e.DOTENV_KEY&&e.DOTENV_KEY.length>0?e.DOTENV_KEY:i.env.DOTENV_KEY&&i.env.DOTENV_KEY.length>0?i.env.DOTENV_KEY:""}function y(e,t){let r;try{r=new URL(t)}catch(e){if("ERR_INVALID_URL"===e.code)throw Error("INVALID_DOTENV_KEY: Wrong format. Must be in valid uri format like dotenv://:[email protected]/vault/.env.vault?environment=development");throw e}let n=r.password;if(!n)throw Error("INVALID_DOTENV_KEY: Missing key part");let i=r.searchParams.get("environment");if(!i)throw Error("INVALID_DOTENV_KEY: Missing environment part");let o=`DOTENV_VAULT_${i.toUpperCase()}`,s=e.parsed[o];
1if(!s)throw Error(`NOT_FOUND_DOTENV_ENVIRONMENT: Cannot locate environment ${o} in your .env.vault file.`);return{ciphertext:s,key:n}}function g(e){let t=s.resolve(i.cwd(),".env");return e&&e.path&&e.path.length>0&&(t=e.path),t.endsWith(".vault")?t:`${t}.vault`}function b(e){return"~"===e[0]?s.join(a.homedir(),e.slice(1)):e}let m={configDotenv:function(e){let t=s.resolve(i.cwd(),".env"),r="utf8",o=!!(e&&e.debug);e&&(null!=e.path&&(t=b(e.path)),null!=e.encoding&&(r=e.encoding));try{let o=m.parse(n.readFileSync(t,{encoding:r})),s=i.env;return e&&null!=e.processEnv&&(s=e.processEnv),m.populate(s,o,e),{parsed:o}}catch(e){return o&&h(`Failed to load ${t} ${e.message}`),{error:e}}},_configVault:function(e){f("Loading env from encrypted .env.vault");let t=m._parseVault(e),r=i.env;return e&&null!=e.processEnv&&(r=e.processEnv),m.populate(r,t,e),{parsed:t}},_parseVault:function(e){let t;let r=g(e),n=m.configDotenv({path:r});if(!n.parsed)throw Error(`MISSING_DATA: Cannot parse ${r} for an unknown reason`);let i=d(e).split(","),o=i.length;for(let e=0;e<o;e++)try{let r=i[e].trim(),o=y(n,r);t=m.decrypt(o.ciphertext,o.key);break}catch(t){if(e+1>=o)throw t}return m.parse(t)},config:function(e){let t=g(e);return 0===d(e).length?m.configDotenv(e):n.existsSync(t)?m._configVault(e):(p(`You set DOTENV_KEY but you are missing a .env.vault file at ${t}. Did you forget to build it?`),m.configDotenv(e))},decrypt:function(e,t){let r=o.from(t.slice(-64),"hex"),n=o.from(e,"base64"),i=n.slice(0,12),s=n.slice(-16);n=n.slice(12,-16);try{let e=u.createDecipheriv("aes-256-gcm",r,i);return e.setAuthTag(s),`${e.update(n)}${e.final()}`}catch(n){let e=n instanceof RangeError,t="Invalid key length"===n.message,r="Unsupported state or unable to authenticate data"===n.message;if(e||t)throw Error("INVALID_DOTENV_KEY: It must be 64 characters long (or more)");if(r)throw Error("DECRYPTION_FAILED: Please check your DOTENV_KEY");throw console.error("Error: ",n.code),console.error("Error: ",n.message),n}},parse:function(e){let t;let r={},n=e.toString();for(n=n.replace(/\r\n?/gm,"\n");null!=(t=l.exec(n));){let e=t[1],n=t[2]||"",i=(n=n.trim())[0];n=n.replace(/^(['"`])([\s\S]*)\1$/gm,"$2"),'"'===i&&(n=(n=n.replace(/\\n
1/g,"\n")).replace(/\\r/g,"\r")),r[e]=n}return r},populate:function(e,t,r={}){let n=!!(r&&r.debug),i=!!(r&&r.override);if("object"!=typeof t)throw Error("OBJECT_REQUIRED: Please check the processEnv argument being passed to populate");for(let r of Object.keys(t))Object.prototype.hasOwnProperty.call(e,r)?(!0===i&&(e[r]=t[r]),n&&(!0===i?h(`"${r}" is already defined and WAS overwritten`):h(`"${r}" is already defined and was NOT overwritten`))):e[r]=t[r]}};e.exports.configDotenv=m.configDotenv,e.exports._configVault=m._configVault,e.exports._parseVault=m._parseVault,e.exports.config=m.config,e.exports.decrypt=m.decrypt,e.exports.parse=m.parse,e.exports.populate=m.populate,e.exports=m},113:e=>{"use strict";e.exports=r(194)},147:e=>{"use strict";e.exports=r(4780)},37:e=>{"use strict";e.exports=r(2285)},17:e=>{"use strict";e.exports=r(3720)},803:e=>{"use strict";e.exports=JSON.parse('{"name":"dotenv","version":"16.3.1","description":"Loads environment variables from .env file","main":"lib/main.js","types":"lib/main.d.ts","exports":{".":{"types":"./lib/main.d.ts","require":"./lib/main.js","default":"./lib/main.js"},"./config":"./config.js","./config.js":"./config.js","./lib/env-options":"./lib/env-options.js","./lib/env-options.js":"./lib/env-options.js","./lib/cli-options":"./lib/cli-options.js","./lib/cli-options.js":"./lib/cli-options.js","./package.json":"./package.json"},"scripts":{"dts-check":"tsc --project tests/types/tsconfig.json","lint":"standard","lint-readme":"standard-markdown","pretest":"npm run lint && npm run dts-check","test":"tap tests/*.js --100 -Rspec","prerelease":"npm test","release":"standard-version"},"repository":{"type":"git","url":"git://github.com/motdotla/dotenv.git"},"funding":"https://github.com/motdotla/dotenv?sponsor=1","keywords":["dotenv","env",".env","environment","variables","config","settings"],"readmeFilename":"README.md","license":"BSD-2-Clause","devDependencies":{"@definitelytyped/dtslint":"^0.0.133","@types/node":"^18.11.3","decache":"^4.6.1","sinon":"^14.0.1","standard":"^17.0.0","standard-markdown":"^7.1.0","standard-version":"^9.5.0","tap":"^16.3.0","tar":"^6.1.11","typescript":"^4.8.4"},"engines":{"node":">=12"},"browser":{"fs":false}}')}},s={};function a(e){var r=s[e];if(void 0!==r)return r.exports;var n=s[e]={exports:{}},i=!0;try{t[e](n,n.exports,a),i=!1}finally{i&&delete s[e]}return n.exports}(()=>{a.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return a.d(t,{a:t}),t}})(),(()=>{a.d=(e,t)=>{for(var r in t)a.o(t,r)&&!a.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}})(),(()=>{a.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t)})(),(()=>{a.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}})(),a.ab=n+"/";var u={};(()=>{"use strict";let e,t;a.r(u),a.d(u,{initialEnv:()=>e,updateInitialEnv:()=>f,processEnv:()=>h,resetEnv:()=>d,loadEnvConfig:()=>y});var r=a(147);a.n(r);var n=a(17);a.n(n);var o=a(234);a.n(o);var s=a(383);let c=[],l=[];function f(t){Object.assign(e||{},t)}function p(e){Object.keys(i.env).forEach(t=>{t.startsWith("__NEXT_PRIVATE")||void 0!==e[t]&&""!==e[t]||delete i.env[t]}),Object.entries(e).forEach(([e,t])=>{i.env[e]=t})}function h(t,r,a=console,u=!1,c){var f;if(e||(e=Object.assign({},i.env)),!u&&(i.env.__NEXT_PROCESSED_ENV||0===t.length))return i.env;i.env.__NEXT_PROCESSED_ENV="true";let p=Object.assign({},e),h={};for(let e of t)try{let t={};for(let r of(t.parsed=o.parse(e.contents),(t=(0,s.j)(t)).parsed&&!l.some(t=>t.contents===e.contents&&t.path===e.path)&&(null==c||c(e.path)),Object.keys(t.parsed||{})))void 0===h[r]&&void 0===p[r]&&(h[r]=null===(f=t.parsed)||void 0===f?void 0:f[r])}catch(t){a.error(`Failed to load env from ${n.join(r||"",e.path)}`,t)}return Object.assign(i.env,h)}function d(){e&&p(e)}function y(o,s,a=console,u=!1,f){if(e||(e=Object.assign({},i.env)),t&&!u)return{combinedEnv:t,loadedEnvFiles:c};p(e),l=c,c=[];let d=s?"development":"production";for(let e of[`.env.${d}.local`,"test"!==d&&".env.local",`.env.${d}`,".env"].filter(Boolean)){let t=n.join(o,e);try{if(!r.statSync(t).isFile())continue;let n=r.readFileSync(t,"utf8");c.push({path:e,contents:n})}catch(t){"ENOENT"!==t.code&&a.error(`Failed to load env from ${e}`,t)}}return{combinedEnv:t=h(c,o,a,u,f),loadedEnvFiles:c}}})(),e.exports=u})()},3810:function(e){var t="/";!function(){"use strict";var r={864:function(e){var t,r="object"==typeof Reflect?Reflect:null,n=r&&"function"==typeof r.apply?r.apply:function(e,t,r){return Function.prototype.apply.call(e,t,r)};function i(e){console&&console.warn&&console.warn(e)}t=r&&"function"==typeof r.ownKeys?r.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var o=Number.isNaN||function(e){return e!=e};function s(){s.init.call(this)}e.exports=s,e.exports.once=m,s.EventEmitter=s,s.prototype._events=void 0,s.prototype._eventsCount=0,s.prototype._maxListeners=void 0;var a=10;function u(e){if("function"!=typeof e)throw TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function c(e){return void 0===e._maxListeners?s.defaultMaxListeners:e._maxListeners}function l(e,t,r,n){if(u(r),void 0===(s=e._events)?(s=e._events=Object.create(null),e._eventsCount=0):(void 0!==s.newListener&&(e.emit("newListener",t,r.listener?r.listener:r),s=e._events),a=s[t]),void 0===a)a=s[t]=r,++e._eventsCount;else if("function"==typeof a?a=s[t]=n?[r,a]:[a,r]:n?a.unshift(r):a.push(r),(o=c(e))>0&&a.length>o&&!a.warned){a.warned=!0;var o,s,a,l=Error("Possible EventEmitter memory leak detected. "+a.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");l.name="MaxListenersExceededWarning",l.emitter=e,l.type=t,l.count=a.length,i(l)}return e}function f(){if(!this.fired)return(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0==arguments.length)?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function p(e,t,r){var n={fired:!1,wrapFn:void 0,target:e,type:t,listener:r},i=f.bind(n);return i.listener=r,n.wrapFn=i,i}function h(e,t,r){var n=e._events;if(void 0===n)return[];var i=n[t];return void 0===i?[]:"function"==typeof i?r?[i.listener||i]:[i]:r?b(i):y(i,i.length)}function d(e){var t=this._events;if(void 0!==t){var r=t[e];if("function"==typeof r)return 1;if(void 0!==r)return r.length}return 0}function y(e,t){for(var r=Array(t),n=0;n<t;++n)r[n]=e[n];return r}function g(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}function b(e){for(var t=Array(e.length),r=0;r<t.length;++r)t[r]=e[r].listener||e[r];return t}function m(e,t){return new Promise(function(r,n){function i(r){e.removeListener(t,o),n(r)}function o(){"function"==typeof e.removeListener&&e.removeListener("error",i),r([].slice.call(arguments))}w(e,t,o,{once:!0}),"error"!==t&&v(e,i,{once:!0})})}function v(e,t,r){"function"==typeof e.on&&w(e,"error",t,r)}function w(e,t,r,n){if("function"==typeof e.on)n.once?e.once(t,r):e.on(t,r);else if("function"==typeof e.addEventListener)e.addEventListener(t,function i(o){n.once&&e.removeEventListener(t,i),r(o)});else throw TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e)}Object.defineProperty(s,"defaultMaxListeners",{enumerable:!0,get:function(){return a}
1,set:function(e){if("number"!=typeof e||e<0||o(e))throw RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");a=e}}),s.init=function(){(void 0===this._events||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},s.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||o(e))throw RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},s.prototype.getMaxListeners=function(){return c(this)},s.prototype.emit=function(e){for(var t=[],r=1;r<arguments.length;r++)t.push(arguments[r]);var i="error"===e,o=this._events;if(void 0!==o)i=i&&void 0===o.error;else if(!i)return!1;if(i){if(t.length>0&&(s=t[0]),s instanceof Error)throw s;var s,a=Error("Unhandled error."+(s?" ("+s.message+")":""));throw a.context=s,a}var u=o[e];if(void 0===u)return!1;if("function"==typeof u)n(u,this,t);else for(var c=u.length,l=y(u,c),r=0;r<c;++r)n(l[r],this,t);return!0},s.prototype.addListener=function(e,t){return l(this,e,t,!1)},s.prototype.on=s.prototype.addListener,s.prototype.prependListener=function(e,t){return l(this,e,t,!0)},s.prototype.once=function(e,t){return u(t),this.on(e,p(this,e,t)),this},s.prototype.prependOnceListener=function(e,t){return u(t),this.prependListener(e,p(this,e,t)),this},s.prototype.removeListener=function(e,t){var r,n,i,o,s;if(u(t),void 0===(n=this._events)||void 0===(r=n[e]))return this;if(r===t||r.listener===t)0==--this._eventsCount?this._events=Object.create(null):(delete n[e],n.removeListener&&this.emit("removeListener",e,r.listener||t));else if("function"!=typeof r){for(i=-1,o=r.length-1;o>=0;o--)if(r[o]===t||r[o].listener===t){s=r[o].listener,i=o;break}if(i<0)return this;0===i?r.shift():g(r,i),1===r.length&&(n[e]=r[0]),void 0!==n.removeListener&&this.emit("removeListener",e,s||t)}return this},s.prototype.off=s.prototype.removeListener,s.prototype.removeAllListeners=function(e){var t,r,n;if(void 0===(r=this._events))return this;if(void 0===r.removeListener)return 0==arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==r[e]&&(0==--this._eventsCount?this._events=Object.create(null):delete r[e]),this;if(0==arguments.length){var i,o=Object.keys(r);for(n=0;n<o.length;++n)"removeListener"!==(i=o[n])&&this.removeAllListeners(i);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(t=r[e]))this.removeListener(e,t);else if(void 0!==t)for(n=t.length-1;n>=0;n--)this.removeListener(e,t[n]);return this},s.prototype.listeners=function(e){return h(this,e,!0)},s.prototype.rawListeners=function(e){return h(this,e,!1)},s.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):d.call(e,t)},s.prototype.listenerCount=d,s.prototype.eventNames=function(){return this._eventsCount>0?t(this._events):[]}}},n={};function i(e){var t=n[e];if(void 0!==t)return t.exports;var o=n[e]={exports:{}},s=!0;try{r[e](o,o.exports,i),s=!1}finally{s&&delete n[e]}return o.exports}i.ab=t+"/";var o=i(864);e.exports=o}()},3502:function(e,t,r){var n="/",i=r(6035);!function(){var t={782:function(e){"function"==typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}},646:function(e){"use strict";let t={};function r(e,r,n){function i(e,t,n){return"string"==typeof r?r:r(e,t,n)}n||(n=Error);class o extends n{constructor(e,t,r){super(i(e,t,r))}}o.prototype.name=n.name,o.prototype.code=e,t[e]=o}function n(e,t){if(!Array.isArray(e))return`of ${t} ${String(e)}`;{let r=e.length;return(e=e.map(e=>String(e)),r>2)?`one of ${t} ${e.slice(0,r-1).join(", ")}, or `+e[r-1]:2===r?`one of ${t} ${e[0]} or ${e[1]}`:`of ${t} ${e[0]}`}}function i(e,t,r){return e.substr(!r||r<0?0:+r,t.length)===t}function o(e,t,r){return(void 0===r||r>e.length)&&(r=e.length),e.substring(r-t.length,r)===t}function s(e,t,r){return"number"!=typeof r&&(r=0),!(r+t.length>e.length)&&-1!==e.indexOf(t,r)}r("ERR_INVALID_OPT_VALUE",function(e,t){return'The value "'+t+'" is invali
1d for option "'+e+'"'},TypeError),r("ERR_INVALID_ARG_TYPE",function(e,t,r){let a,u;if("string"==typeof t&&i(t,"not ")?(a="must not be",t=t.replace(/^not /,"")):a="must be",o(e," argument"))u=`The ${e} ${a} ${n(t,"type")}`;else{let r=s(e,".")?"property":"argument";u=`The "${e}" ${r} ${a} ${n(t,"type")}`}return u+`. Received type ${typeof r}`},TypeError),r("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),r("ERR_METHOD_NOT_IMPLEMENTED",function(e){return"The "+e+" method is not implemented"}),r("ERR_STREAM_PREMATURE_CLOSE","Premature close"),r("ERR_STREAM_DESTROYED",function(e){return"Cannot call "+e+" after a stream was destroyed"}),r("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),r("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),r("ERR_STREAM_WRITE_AFTER_END","write after end"),r("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),r("ERR_UNKNOWN_ENCODING",function(e){return"Unknown encoding: "+e},TypeError),r("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),e.exports.q=t},403:function(e,t,r){"use strict";var n=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};e.exports=l;var o=r(709),s=r(337);r(782)(l,o);for(var a=n(s.prototype),u=0;u<a.length;u++){var c=a[u];l.prototype[c]||(l.prototype[c]=s.prototype[c])}function l(e){if(!(this instanceof l))return new l(e);o.call(this,e),s.call(this,e),this.allowHalfOpen=!0,e&&(!1===e.readable&&(this.readable=!1),!1===e.writable&&(this.writable=!1),!1===e.allowHalfOpen&&(this.allowHalfOpen=!1,this.once("end",f)))}function f(){this._writableState.ended||i.nextTick(p,this)}function p(e){e.end()}Object.defineProperty(l.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(l.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(l.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(l.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&this._readableState.destroyed&&this._writableState.destroyed},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}})},889:function(e,t,r){"use strict";e.exports=i;var n=r(170);function i(e){if(!(this instanceof i))return new i(e);n.call(this,e)}r(782)(i,n),i.prototype._transform=function(e,t,r){r(null,e)}},709:function(e,t,n){"use strict";e.exports=C,C.ReadableState=j,n(361).EventEmitter;var o,s,a,u,c,l=function(e,t){return e.listeners(t).length},f=n(678),p=n(300).Buffer,h=r.g.Uint8Array||function(){};function d(e){return p.from(e)}function y(e){return p.isBuffer(e)||e instanceof h}var g=n(837);s=g&&g.debuglog?g.debuglog("stream"):function(){};var b=n(379),m=n(25),v=n(776).getHighWaterMark,w=n(646).q,_=w.ERR_INVALID_ARG_TYPE,E=w.ERR_STREAM_PUSH_AFTER_EOF,S=w.ERR_METHOD_NOT_IMPLEMENTED,A=w.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;n(782)(C,f);var O=m.errorOrDestroy,R=["error","close","destroy","pause","resume"];function x(e,t,r){if("function"==typeof e.prependListener)return e.prepe
vendor: 29,056 bytes, line 1
1ndListener(t,r);e._events&&e._events[t]?Array.isArray(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r)}function j(e,t,r){o=o||n(403),e=e||{},"boolean"!=typeof r&&(r=t instanceof o),this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=v(this,e,"readableHighWaterMark",r),this.buffer=new b,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=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(a||(a=n(704).s),this.decoder=new a(e.encoding),this.encoding=e.encoding)}function C(e){if(o=o||n(403),!(this instanceof C))return new C(e);var t=this instanceof o;this._readableState=new j(e,this,t),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),f.call(this)}function P(e,t,r,n,i){s("readableAddChunk",t);var o,a=e._readableState;if(null===t)a.reading=!1,M(e,a);else if(i||(o=T(a,t)),o)O(e,o);else if(a.objectMode||t&&t.length>0){if("string"==typeof t||a.objectMode||Object.getPrototypeOf(t)===p.prototype||(t=d(t)),n)a.endEmitted?O(e,new A):I(e,a,t,!0);else if(a.ended)O(e,new E);else{if(a.destroyed)return!1;a.reading=!1,a.decoder&&!r?(t=a.decoder.write(t),a.objectMode||0!==t.length?I(e,a,t,!1):F(e,a)):I(e,a,t,!1)}}else n||(a.reading=!1,F(e,a));return!a.ended&&(a.length<a.highWaterMark||0===a.length)}function I(e,t,r,n){t.flowing&&0===t.length&&!t.sync?(t.awaitDrain=0,e.emit("data",r)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&q(e)),F(e,t)}function T(e,t){var r;return y(t)||"string"==typeof t||void 0===t||e.objectMode||(r=new _("chunk",["string","Buffer","Uint8Array"],t)),r}Object.defineProperty(C.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),C.prototype.destroy=m.destroy,C.prototype._undestroy=m.undestroy,C.prototype._destroy=function(e,t){t(e)},C.prototype.push=function(e,t){var r,n=this._readableState;return n.objectMode?r=!0:"string"==typeof e&&((t=t||n.defaultEncoding)!==n.encoding&&(e=p.from(e,t),t=""),r=!0),P(this,e,t,!1,r)},C.prototype.unshift=function(e){return P(this,e,null,!0,!1)},C.prototype.isPaused=function(){return!1===this._readableState.flowing},C.prototype.setEncoding=function(e){a||(a=n(704).s);var t=new a(e);this._readableState.decoder=t,this._readableState.encoding=this._readableState.decoder.encoding;for(var r=this._readableState.buffer.head,i="";null!==r;)i+=t.write(r.data),r=r.next;return this._readableState.buffer.clear(),""!==i&&this._readableState.buffer.push(i),this._readableState.length=i.length,this};var $=1073741824;function k(e){return e>=$?e=$:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function N(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=k(e)),e<=t.length)?e:t.ended?t.length:(t.needReadable=!0,0)}function M(e,t){if(s("onEofChunk"),!t.ended){if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,t.sync?q(e):(t.needReadable=!1,t.emittedReadable||(t.emittedReadable=!0,D(e)))}}function q(e){var t=e._readableState;s("emitReadable",t.needReadable,t.emittedReadable),t.needReadable=!1,t.emittedReadable||(s("emitReadable",t.flowing),t.emittedReadable=!0,i.nextTick(D,e))}function D(e){var t=e._readableState;s("emitReadable_",t.destroyed,t.length,t.ended),!t.destroyed&&(t.length||t.ended)&&(e.emit("readable"),t.emittedReadable=!1),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,H(e)}function F(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(U,e,t))}function U(e,t){for(;!t.reading&&!t.ended&&(t.length<t.highWaterMark||t.flowing&&0===t.length);){var r=t.length;if(s("maybeReadMore read 0"),e.read(0),r===t.length)break}t.readingMore=!1}function L(e){return function(){var t=e._readableState;s("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&l(e,"data")&&(t.flowing=!0,H(e))}}function B(e){var t=e._readableState;t.readableListening=e.listenerCount("readable")>0,t.resumeScheduled&&!t.paused?t.flowing=!0:e.listenerCount("data")>0&&e.resume()}function V(e){s("readable nexttick read 0"),e.read(0)}function W(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(z,e,t))}function z(e,t){s("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),H(e),t.flowing&&!t.reading&&e.read(0)}function H(e){var t=e._readableState;for(s("flow",t.flowing);t.flowing&&null!==e.read(););}function G(e,t){var r;return 0===t.length?null:(t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.first():t.buffer.concat(t.length),t.buffer.clear()):r=t.buffer.consume(e,t.decoder),r)}function J(e){var t=e._readableState;s("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,i.nextTick(Y,t,e))}function Y(e,t){if(s("endReadableNT",e.endEmitted,e.length),!e.endEmitted&&0===e.length&&(e.endEmitted=!0,t.readable=!1,t.emit("end"),e.autoDestroy)){var r=t._writableState;(!r||r.autoDestroy&&r.finished)&&t.destroy()}}function K(e,t){for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return -1}C.prototype.read=function(e){s("read",e),e=parseInt(e,10);var t,r=this._readableState,n=e;if(0!==e&&(r.emittedReadable=!1),0===e&&r.needReadable&&((0!==r.highWaterMark?r.length>=r.highWaterMark:r.length>0)||r.ended))return s("read: emitReadable",r.length,r.ended),0===r.length&&r.ended?J(this):q(this),null;if(0===(e=N(e,r))&&r.ended)return 0===r.length&&J(this),null;var i=r.needReadable;return s("need readable",i),(0===r.length||r.length-e<r.highWaterMark)&&s("length less than watermark",i=!0),r.ended||r.reading?s("reading or ended",i=!1):i&&(s("do read"),r.reading=!0,r.sync=!0,0===r.length&&(r.needReadable=!0),this._read(r.highWaterMark),r.sync=!1,r.reading||(e=N(n,r))),null===(t=e>0?G(e,r):null)?(r.needReadable=r.length<=r.highWaterMark,e=0):(r.length-=e,r.awaitDrain=0),0===r.length&&(r.ended||(r.needReadable=!0),n!==e&&r.ended&&J(this)),null!==t&&this.emit("data",t),t},C.prototype._read=function(e){O(this,new S("_read()"))},C.prototype.pipe=function(e,t){var r=this,n=this._readableState;switch(n.pipesCount){case 0:n.pipes=e;break;case 1:n.pipes=[n.pipes,e];break;default:n.pipes.push(e)}n.pipesCount+=1,s("pipe count=%d opts=%j",n.pipesCount,t);var o=t&&!1===t.end||e===i.stdout||e===i.stderr?b:u;function a(e,t){s("onunpipe"),e===r&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,p())}function u(){s("onend"),e.end()}n.endEmitted?i.nextTick(o):r.once("end",o),e.on("unpipe",a);var c=L(r);e.on("drain",c);var f=!1;function p(){s("cleanup"),e.removeListener("close",y),e.removeListener("finish",g),e.removeListener("drain",c),e.removeListener("error",d),e.removeListener("unpipe",a),r.removeListener("end",u),r.removeListener("end",b),r.removeListener("data",h),f=!0,n.awaitDrain&&(!e._writableState||e._writableState.needDrain)&&c()}function h(t){s("ondata");var i=e.write(t);s("dest.write",i),!1===i&&((1===n.pipesCount&&n.pipes===e||n.pipesCount>1&&-1!==K(n.pipes,e))&&!f&&(s("false write response, pause",n.awaitDrain),n.awaitDrain++),r.pause())}function d(t){s("onerror",t),b(),e.removeListener("error",d),0===l(e,"error")&&O(e,t)}function y(){e.removeListener("finish",g),b()}function g(){s("onfinish"),e.removeListener("close",y),b()}function b(){s("unpipe"),r.unpipe(e)}return r.on("data",h),x(e,"error",d),e.once("close",y),e.once("finish",g),e.emit("pipe",r),n.flowing||(s("pipe resume"),r.resume()),e},C.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r)),this;if(!e){var n=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)n[o].emit("unpipe",this,{hasUnpiped:!1});return this}var s=K(t.pipes,e);return -1===s||(t.pipes.splice(s,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,r)),this},C.prototype.on=function(e,t){var r=f.prototype.on.call(this,e,t),n=this._readableState;return"data"===e?(n.readableListening=this.listenerCount("readable")>0,!1!==n.flowing&&this.resume()):"readable"!==e||n.endEmitted||n.readableListening||(n.readableListening=n.needReadable=!0,n.flowing=!1,n.emittedReadable=!1,s("on readable",n.length,n.reading),n.length?q(this):n.reading||i.nextTick(V,this)),r},C.prototype.addListener=C.prototype.on,C.prototype.removeListener=function(e,t){var r=f.prototype.removeListener.call(this,e,t);return"readable"===e&&i.nextTick(B,this),r},C.prototype.removeAllListeners=function(e){var t=f.prototype.removeAllListeners.apply(this,arguments);return("readable"===e||void 0===e)&&i.nextTick(B,this),t},C.prototype.resume=function(){var e=this._readableState;return e.flowing||(s("resume"),e.flowing=!e.readableListening,W(this,e)),e.paused=!1,this},C.prototype.pause=function(){return s("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(s("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},C.prototype.wrap=function(e){var t=this,r=this._readableState,n=!1;for(var i in e.on("end",function(){if(s("wrapped end"),r.decoder&&!r.ended){var e=r.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(i){s("wrapped data"),r.decoder&&(i=r.decoder.write(i)),(!r.objectMode||null!=i)&&(r.objectMode||i&&i.length)&&(t.push(i)||(n=!0,e.pause()))}),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o<R.length;o++)e.on(R[o],this.emit.bind(this,R[o]));return this._read=function(t){s("wrapped _read",t),n&&(n=!1,e.resume())},this},"function"==typeof Symbol&&(C.prototype[Symbol.asyncIterator]=function(){return void 0===u&&(u=n(871)),u(this)}),Object.defineProperty(C.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(C.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(C.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(e){this._readableState&&(this._readableState.flowing=e)}}),C._fromList=G,Object.defineProperty(C.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}}),"function"==typeof Symbol&&(C.from=function(e,t){return void 0===c&&(c=n(727)),c(C,e,t)})},170:function(e,t,r){"use strict";e.exports=l;var n=r(646).q,i=n.ERR_METHOD_NOT_IMPLEMENTED,o=n.ERR_MULTIPLE_CALLBACK,s=n.ERR_TRANSFORM_ALREADY_TRANSFORMING,a=n.ERR_TRANSFORM_WITH_LENGTH_0,u=r(403);function c(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(null===n)return this.emit("error",new o);r.writechunk=null,r.writecb=null,null!=t&&this.push(t),n(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function l(e){if(!(this instanceof l))return new l(e);u.call(this,e),this._transformState={afterTransform:c.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",f)}function f(){var e=this;"function"!=typeof this._flush||this._readableState.destroyed?p(this,null,null):this._flush(function(t,r){p(e,t,r)})}function p(e,t,r){if(t)return e.emit("error",t);if(null!=r&&e.push(r),e._writableState.length)throw new a;if(e._transformState.transforming)throw new s;return e.push(null)}r(782)(l,u),l.prototype.push=function(e,t){return this._transformState.needTransform=!1,u.prototype.push.call(this,e,t)},l.prototype._transform=function(e,t,r){r(new i("_transform()"))},l.prototype._write=function(e,t,r){var n=this._transformState;if(n.writecb=r,n.writechunk=e,n.writeencoding=t,!n.transforming){var i=this._readableState;(n.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},l.prototype._read=function(e){var t=this._transformState;null===t.writechunk||t.transforming?t.needTransform=!0:(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform))},l.prototype._destroy=function(e,t){u.prototype._destroy.call(this,e,function(e){t(e)})}},337:function(e,t,n){"use strict";function o(e){var t=this;this.next=null,this.entry=null,this.finish=function(){z(t,e)}}e.exports=j,j.WritableState=x;var s,a,u={deprecate:n(769)},c=n(678),l=n(300).Buffer,f=r.g.Uint8Array||function(){};function p(e){return l.from(e)}function h(e){return l.isBuffer(e)||e instanceof f}var d=n(25),y=n(776).getHighWaterMark,g=n(646).q,b=g.ERR_INVALID_ARG_TYPE,m=g.ERR_METHOD_NOT_IMPLEMENTED,v=g.ERR_MULTIPLE_CALLBACK,w=g.ERR_STREAM_CANNOT_PIPE,_=g.ERR_STREAM_DESTROYED,E=g.ERR_STREAM_NULL_VALUES,S=g.ERR_STREAM_WRITE_AFTER_END,A=g.ERR_UNKNOWN_ENCODING,O=d.errorOrDestroy;function R(){}function x(e,t,r){s=s||n(403),e=e||{},"boolean"!=typeof r&&(r=t instanceof s),this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=y(this,e,"writableHighWaterMark",r),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var i=!1===e.decodeStrings;this.decodeStrings=!i,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){M(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!1!==e.emitClose,this.autoDestroy=!!e.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new o(this)}function j(e){var t=this instanceof(s=s||n(403));if(!t&&!a.call(j,this))return new j(e);this._writableState=new x(e,this,t),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),c.call(this)}function C(e,t){var r=new S;O(e,r),i.nextTick(t,r)}function P(e,t,r,n){var o;return null===r?o=new E:"string"==typeof r||t.objectMode||(o=new b("chunk",["string","Buffer"],r)),!o||(O(e,o),i.nextTick(n,o),!1)}function I(e,t,r){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=l.from(t,r)),t}function T(e,t,r,n,i,o){if(!r){var s=I(t,n,i);n!==s&&(r=!0,i="buffer",n=s)}var a=t.objectMode?1:n.length;t.length+=a;var u=t.length<t.highWaterMark;if(u||(t.needDrain=!0),t.writing||t.corked){var c=t.lastBufferedRequest;t.lastBufferedRequest={chunk:n,encoding:i,isBuf:r,callback:o,next:null},c?c.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else $(e,t,!1,a,n,i,o);return u}function $(e,t,r,n,i,o,s){t.writelen=n,t.writecb=s,t.writing=!0,t.sync=!0,t.destroyed?t.onwrite(new _("write")):r?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function k(e,t,r,n,o){--t.pendingcb,r?(i.nextTick(o,n),i.nextTick(V,e,t),e._writableState.errorEmitted=!0,O(e,n)):(o(n),e._writableState.errorEmitted=!0,O(e,n),V(e,t))}function N(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function M(e,t){var r=e._writableState,n=r.sync,o=r.writecb;if("function"!=typeof o)throw new v;if(N(r),t)k(e,r,n,t,o);else{var s=U(r)||e.destroyed;s||r.corked||r.bufferProcessing||!r.bufferedRequest||F(e,r),n?i.nextTick(q,e,r,s,o):q(e,r,s,o)}}function q(e,t,r,n){r||D(e,t),t.pendingcb--,n(),V(e,t)}function D(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function F(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=Array(t.bufferedRequestCount),i=t.corkedRequestsFree;i.entry=r;for(var s=0,a=!0;r;)n[s]=r,r.isBuf||(a=!1),r=r.next,s+=1;n.allBuffers=a,$(e,t,!0,t.length,n,"",i.finish),t.pendingcb++,t.lastBufferedRequest=null,i.next?(t.corkedRequestsFree=i.next,i.next=null):t.corkedRequestsFree=new o(t),t.bufferedRequestCount=0}else{for(;r;){var u=r.chunk,c=r.encoding,l=r.callback,f=t.objectMode?1:u.length;if($(e,t,!1,f,u,c,l),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function U(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function L(e,t){e._final(function(r){t.pendingcb--,r&&O(e,r),t.prefinished=!0,e.emit("prefinish"),V(e,t)})}function B(e,t){t.prefinished||t.finalCalled||("function"!=typeof e._final||t.destroyed?(t.prefinished=!0,e.emit("prefinish")):(t.pendingcb++,t.finalCalled=!0,i.nextTick(L,e,t)))}function V(e,t){var r=U(t);if(r&&(B(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"),t.autoDestroy))){var n=e._readableState;(!n||n.autoDestroy&&n.endEmitted)&&e.destroy()}return r}function W(e,t,r){t.ending=!0,V(e,t),r&&(t.finished?i.nextTick(r):e.once("finish",r)),t.ended=!0,e.writable=!1}function z(e,t,r){var n=e.entry;for(e.entry=null;n;){var i=n.callback;t.pendingcb--,i(r),n=n.next}t.corkedRequestsFree.next=e}n(782)(j,c),x.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(x.prototype,"buffer",{get:u.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(a=Function.prototype[Symbol.hasInstance],Object.defineProperty(j,Symbol.hasInstance,{value:function(e){return!!a.call(this,e)||this===j&&e&&e._writableState instanceof x}})):a=function(e){return e instanceof this},j.prototype.pipe=function(){O(this,new w)},j.prototype.write=function(e,t,r){var n=this._writableState,i=!1,o=!n.objectMode&&h(e);return o&&!l.isBuffer(e)&&(e=p(e)),"function"==typeof t&&(r=t,t=null),o?t="buffer":t||(t=n.defaultEncoding),"function"!=typeof r&&(r=R),n.ending?C(this,r):(o||P(this,n,e,r))&&(n.pendingcb++,i=T(this,n,o,e,t,r)),i},j.prototype.cork=function(){this._writableState.corked++},j.prototype.uncork=function(){var e=this._writableState;!e.corked||(e.corked--,e.writing||e.corked||e.bufferProcessing||!e.bufferedRequest||F(this,e))},j.prototype.setDefaultEncoding=function(e){if("string"==typeof e&&(e=e.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new A(e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(j.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(j.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),j.prototype._write=function(e,t,r){r(new m("_write()"))},j.prototype._writev=null,j.prototype.end=function(e,t,r){var n=this._writableState;return"function"==typeof e?(r=e,e=null,t=null):"function"==typeof t&&(r=t,t=null),null!=e&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||W(this,n,r),this},Object.defineProperty(j.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(j.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),j.prototype.destroy=d.destroy,j.prototype._undestroy=d.undestroy,j.prototype._destroy=function(e,t){t(e)}},871:function(e,t,r){"use strict";function n(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var o,s=r(698),a=Symbol("lastResolve"),u=Symbol("lastReject"),c=Symbol("error"),l=Symbol("ended"),f=Symbol("lastPromise"),p=Symbol("handlePromise"),h=Symbol("stream");function d(e,t){return{value:e,done:t}}function y(e){var t=e[a];if(null!==t){var r=e[h].read();null!==r&&(e[f]=null,e[a]=null,e[u]=null,t(d(r,!1)))}}function g(e){i.nextTick(y,e)}function b(e,t){return function(r,n){e.then(function(){if(t[l]){r(d(void 0,!0));return}t[p](r,n)},n)}}var m=Object.getPrototypeOf(function(){}),v=Object.setPrototypeOf((n(o={get stream(){return this[h]},next:function(){var e,t=this,r=this[c];if(null!==r)return Promise.reject(r);if(this[l])return Promise.resolve(d(void 0,!0));if(this[h].destroyed)return new Promise(function(e,r){i.nextTick(function(){t[c]?r(t[c]):e(d(void 0,!0))})});var n=this[f];if(n)e=new Promise(b(n,this));else{var o=this[h].read();if(null!==o)return Promise.resolve(d(o,!1));e=new Promise(this[p])}return this[f]=e,e}},Symbol.asyncIterator,function(){return this}),n(o,"return",function(){var e=this;return new Promise(function(t,r){e[h].destroy(null,function(e){if(e){r(e);return}t(d(void 0,!0))})})}),o),m),w=function(e){var t,r=Object.create(v,(n(t={},h,{value:e,writable:!0}),n(t,a,{value:null,writable:!0}),n(t,u,{value:null,writable:!0}),n(t,c,{value:null,writable:!0}),n(t,l,{value:e._readableState.endEmitted,writable:!0}),n(t,p,{value:function(e,t){var n=r[h].read();n?(r[f]=null,r[a]=null,r[u]=null,e(d(n,!1))):(r[a]=e,r[u]=t)},writable:!0}),t));return r[f]=null,s(e,function(e){if(e&&"ERR_STREAM_PREMATURE_CLOSE"!==e.code){var t=r[u];null!==t&&(r[f]=null,r[a]=null,r[u]=null,t(e)),r[c]=e;return}var n=r[a];null!==n&&(r[f]=null,r[a]=null,r[u]=null,n(d(void 0,!0))),r[l]=!0}),e.on("readable",g.bind(null,r)),r};e.exports=w},379:function(e,t,r){"use strict";function n(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function i(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?n(Object(r),!0).forEach(function(t){o(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):n(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function o(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function s(e,t){if(!(e instanceof t))throw TypeError("Cannot call a class as a function")}function a(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}function u(e,t,r){return t&&a(e.prototype,t),r&&a(e,r),e}var c=r(300).Buffer,l=r(837).inspect,f=l&&l.custom||"inspect";function p(e,t,r){c.prototype.copy.call(e,t,r)}e.exports=function(){function e(){s(this,e),this.head=null,this.tail=null,this.length=0}return u(e,[{key:"push",value:function(e){var t={data:e,next:null};this.length>0?this.tail.next=t:this.head=t,this.tail=t,++this.length}},{key:"unshift",value:function(e){var t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length}},{key:"shift",value:function(){if(0!==this.length){var e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(e){if(0===this.length)return"";for(var t=this.head,r=""+t.data;t=t.next;)r+=e+t.data;return r}},{key:"concat",value:function(e){if(0===this.length)return c.alloc(0);for(var t=c.allocUnsafe(e>>>0),r=this.head,n=0;r;)p(r.data,t,n),n+=r.data.length,r=r.next;return t}},{key:"consume",value:function(e,t){var r;return e<this.head.data.length?(r=this.head.data.slice(0,e),this.head.data=this.head.data.slice(e)):r=e===this.head.data.length?this.shift():t?this._getString(e):this._getBuffer(e),r}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(e){var t=this.head,r=1,n=t.data;for(e-=n.length;t=t.next;){var i=t.data,o=e>i.length?i.length:e;if(o===i.length?n+=i:n+=i.slice(0,e),0==(e-=o)){o===i.length?(++r,t.next?this.head=t.next:this.head=this.tail=null):(this.head=t,t.data=i.slice(o));break}++r}return this.length-=r,n}},{key:"_getBuffer",value:function(e){var t=c.allocUnsafe(e),r=this.head,n=1;for(r.data.copy(t),e-=r.data.length;r=r.next;){var i=r.data,o=e>i.length?i.length:e;if(i.copy(t,t.length-e,0,o),0==(e-=o)){o===i.length?(++n,r.next?this.head=r.next:this.head=this.tail=null):(this.head=r,r.data=i.slice(o));break}++n}return this.length-=n,t}},{key:f,value:function(e,t){return l(this,i({},t,{depth:0,customInspect:!1}))}}]),e}()},25:function(e){"use strict";function t(e,t){var o=this,a=this._readableState&&this._readableState.destroyed,u=this._writableState&&this._writableState.destroyed;return a||u?t?t(e):e&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,i.nextTick(s,this,e)):i.nextTick(s,this,e)):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?o._writableState?o._writableState.errorEmitted?i.nextTick(n,o):(o._writableState.errorEmitted=!0,i.nextTick(r,o,e)):i.nextTick(r,o,e):t?(i.nextTick(n,o),t(e)):i.nextTick(n,o)})),this}function r(e,t){s(e,t),n(e)}function n(e){(!e._writableState||e._writableState.emitClose)&&(!e._readableState||e._readableState.emitClose)&&e.emit("close")}function o(){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(e,t){e.emit("error",t)}function a(e,t){var r=e._readableState,n=e._writableState;r&&r.autoDestroy||n&&n.autoDestroy?e.destroy(t):e.emit("error",t)}e.exports={destroy:t,undestroy:o,errorOrDestroy:a}},698:function(e,t,r){"use strict";var n=r(646).q.ERR_STREAM_PREMATURE_CLOSE;function i(e){var t=!1;return function(){if(!t){t=!0;for(var r=arguments.length,n=Array(r),i=0;i<r;i++)n[i]=arguments[i];e.apply(this,n)}}}function o(){}function s(e){return e.setHeader&&"function"==typeof e.abort}function a(e,t,r){if("function"==typeof t)return a(e,null,t);t||(t={}),r=i(r||o);var u=t.readable||!1!==t.readable&&e.readable,c=t.writable||!1!==t.writable&&e.writable,l=function(){e.writable||p()},f=e._writableState&&e._writableState.finished,p=function(){c=!1,f=!0,u||r.call(e)},h=e._readableState&&e._readableState.endEmitted,d=function(){u=!1,h=!0,c||r.call(e)},y=function(t){r.call(e,t)},g=function(){var t;return u&&!h?(e._readableState&&e._readableState.ended||(t=new n),r.call(e,t)):c&&!f?(e._writableState&&e._writableState.ended||(t=new n),r.call(e,t)):void 0},b=function(){e.req.on("finish",p)};return s(e)?(e.on("complete",p),e.on("abort",g),e.req?b():e.on("request",b)):c&&!e._writableState&&(e.on("end",l),e.on("close",l)),e.on("end",d),e.on("finish",p),!1!==t.error&&e.on("error",y),e.on("close",g),function(){e.removeListener("complete",p),e.removeListener("abort",g),e.removeListener("request",b),e.req&&e.req.removeListener("finish",p),e.removeListener("end",l),e.removeListener("close",l),e.removeListener("finish",p),e.removeListener("end",d),e.removeListener("error",y),e.removeListener("close",g)}}e.exports=a},727:function(e,t,r){"use strict";function n(e,t,r,n,i,o,s){try{var a=e[o](s),u=a.value}catch(e){r(e);return}a.done?t(u):Promise.resolve(u).then(n,i)}function i(e){return function(){var t=this,r=arguments;return new Promise(function(i,o){var s=e.apply(t,r);function a(e){n(s,i,o,a,u,"next",e)}function u(e){n(s,i,o,a,u,"throw",e)}a(void 0)})}}function o(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function s(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?o(Object(r),!0).forEach(function(t){a(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):o(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function a(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}
1var u=r(646).q.ERR_INVALID_ARG_TYPE;function c(e,t,r){if(t&&"function"==typeof t.next)n=t;else if(t&&t[Symbol.asyncIterator])n=t[Symbol.asyncIterator]();else if(t&&t[Symbol.iterator])n=t[Symbol.iterator]();else throw new u("iterable",["Iterable"],t);var n,o=new e(s({objectMode:!0},r)),a=!1;function c(){return l.apply(this,arguments)}function l(){return(l=i(function*(){try{var e=yield n.next(),t=e.value;e.done?o.push(null):o.push((yield t))?c():a=!1}catch(e){o.destroy(e)}})).apply(this,arguments)}return o._read=function(){a||(a=!0,c())},o}e.exports=c},442:function(e,t,r){"use strict";function n(e){var t=!1;return function(){t||(t=!0,e.apply(void 0,arguments))}}var i,o=r(646).q,s=o.ERR_MISSING_ARGS,a=o.ERR_STREAM_DESTROYED;function u(e){if(e)throw e}function c(e){return e.setHeader&&"function"==typeof e.abort}function l(e,t,o,s){s=n(s);var u=!1;e.on("close",function(){u=!0}),void 0===i&&(i=r(698)),i(e,{readable:t,writable:o},function(e){if(e)return s(e);u=!0,s()});var l=!1;return function(t){if(!u&&!l){if(l=!0,c(e))return e.abort();if("function"==typeof e.destroy)return e.destroy();s(t||new a("pipe"))}}}function f(e){e()}function p(e,t){return e.pipe(t)}function h(e){return e.length&&"function"==typeof e[e.length-1]?e.pop():u}function d(){for(var e,t=arguments.length,r=Array(t),n=0;n<t;n++)r[n]=arguments[n];var i=h(r);if(Array.isArray(r[0])&&(r=r[0]),r.length<2)throw new s("streams");var o=r.map(function(t,n){var s=n<r.length-1;return l(t,s,n>0,function(t){e||(e=t),t&&o.forEach(f),s||(o.forEach(f),i(e))})});return r.reduce(p)}e.exports=d},776:function(e,t,r){"use strict";var n=r(646).q.ERR_INVALID_OPT_VALUE;function i(e,t,r){return null!=e.highWaterMark?e.highWaterMark:t?e[r]:null}function o(e,t,r,o){var s=i(t,o,r);if(null!=s){if(!(isFinite(s)&&Math.floor(s)===s)||s<0)throw new n(o?r:"highWaterMark",s);return Math.floor(s)}return e.objectMode?16:16384}e.exports={getHighWaterMark:o}},678:function(e,t,r){e.exports=r(781)},55:function(e,t,r){var n=r(300),i=n.Buffer;function o(e,t){for(var r in e)t[r]=e[r]}function s(e,t,r){return i(e,t,r)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?e.exports=n:(o(n,t),t.Buffer=s),s.prototype=Object.create(i.prototype),o(i,s),s.from=function(e,t,r){if("number"==typeof e)throw TypeError("Argument must not be a number");return i(e,t,r)},s.alloc=function(e,t,r){if("number"!=typeof e)throw TypeError("Argument must be a number");var n=i(e);return void 0!==t?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},s.allocUnsafe=function(e){if("number"!=typeof e)throw TypeError("Argument must be a number");return i(e)},s.allocUnsafeSlow=function(e){if("number"!=typeof e)throw TypeError("Argument must be a number");return n.SlowBuffer(e)}},173:function(e,t,r){e.exports=i;var n=r(361).EventEmitter;function i(){n.call(this)}r(782)(i,n),i.Readable=r(709),i.Writable=r(337),i.Duplex=r(403),i.Transform=r(170),i.PassThrough=r(889),i.finished=r(698),i.pipeline=r(442),i.Stream=i,i.prototype.pipe=function(e,t){var r=this;function i(t){e.writable&&!1===e.write(t)&&r.pause&&r.pause()}function o(){r.readable&&r.resume&&r.resume()}r.on("data",i),e.on("drain",o),e._isStdio||t&&!1===t.end||(r.on("end",a),r.on("close",u));var s=!1;function a(){s||(s=!0,e.end())}function u(){s||(s=!0,"function"==typeof e.destroy&&e.destroy())}function c(e){if(l(),0===n.listenerCount(this,"error"))throw e}function l(){r.removeListener("data",i),e.removeListener("drain",o),r.removeListener("end",a),r.removeListener("close",u),r.removeListener("error",c),e.removeListener("error",c),r.removeListener("end",l),r.removeListener("close",l),e.removeListener("close",l)}return r.on("error",c),e.on("error",c),r.on("end",l),r.on("close",l),e.on("close",l),e.emit("pipe",r),e}},704:function(e,t,r){"use strict";var n=r(55).Buffer,i=n.isEncoding||function(e){switch((e=""+e)&&e.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 o(e){var t;if(!e)return"utf8";for(;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";
1case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}function s(e){var t=o(e);if("string"!=typeof t&&(n.isEncoding===i||!i(e)))throw Error("Unknown encoding: "+e);return t||e}function a(e){var t;switch(this.encoding=s(e),this.encoding){case"utf16le":this.text=d,this.end=y,t=4;break;case"utf8":this.fillLast=f,t=4;break;case"base64":this.text=g,this.end=b,t=3;break;default:this.write=m,this.end=v;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=n.allocUnsafe(t)}function u(e){return e<=127?0:e>>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function c(e,t,r){var n=t.length-1;if(n<r)return 0;var i=u(t[n]);return i>=0?(i>0&&(e.lastNeed=i-1),i):--n<r||-2===i?0:(i=u(t[n]))>=0?(i>0&&(e.lastNeed=i-2),i):--n<r||-2===i?0:(i=u(t[n]))>=0?(i>0&&(2===i?i=0:e.lastNeed=i-3),i):0}function l(e,t,r){if((192&t[0])!=128)return e.lastNeed=0,"�";if(e.lastNeed>1&&t.length>1){if((192&t[1])!=128)return e.lastNeed=1,"�";if(e.lastNeed>2&&t.length>2&&(192&t[2])!=128)return e.lastNeed=2,"�"}}function f(e){var t=this.lastTotal-this.lastNeed,r=l(this,e,t);return void 0!==r?r:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):void(e.copy(this.lastChar,t,0,e.length),this.lastNeed-=e.length)}function p(e,t){var r=c(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)}function h(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"�":t}function d(e,t){if((e.length-t)%2==0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function y(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function g(e,t){var r=(e.length-t)%3;return 0===r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function b(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function m(e){return e.toString(this.encoding)}function v(e){return e&&e.length?this.write(e):""}t.s=a,a.prototype.write=function(e){var t,r;if(0===e.length)return"";if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<e.length?t?t+this.text(e,r):this.text(e,r):t||""},a.prototype.end=h,a.prototype.text=p,a.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}},769:function(e){function t(e,t){if(n("noDeprecation"))return e;var r=!1;return function(){if(!r){if(n("throwDeprecation"))throw Error(t);n("traceDeprecation")?console.trace(t):console.warn(t),r=!0}return e.apply(this,arguments)}}function n(e){try{if(!r.g.localStorage)return!1}catch(e){return!1}var t=r.g.localStorage[e];return null!=t&&"true"===String(t).toLowerCase()}e.exports=t},300:function(e){"use strict";e.exports=r(1580)},361:function(e){"use strict";e.exports=r(3810)},781:function(e){"use strict";e.exports=r(3810).EventEmitter},837:function(e){"use strict";e.exports=r(9523)}},o={};function s(e){var r=o[e];if(void 0!==r)return r.exports;var n=o[e]={exports:{}},i=!0;try{t[e](n,n.exports,s),i=!1}finally{i&&delete o[e]}return n.exports}s.ab=n+"/";var a=s(173);e.exports=a}()},9523:function(e,t,r){var n="/",i=r(1580).Buffer,o=r(6035);!function(){var t={992:function(e){e.exports=function(e,r,n){if(e.filter)return e.filter(r,n);if(null==e||"function"!=typeof r)throw TypeError();for(var i=[],o=0;o<e.length;o++)if(t.call(e,o)){var s=e[o];r.call(n,s,o,e)&&i.push(s)}return i};var t=Object.prototype.hasOwnProperty},256:function(e,t,r){"use strict";var n=r(925),i=r(139),o=i(n("String.prototype.indexOf"));e.exports=function(e,t){var r=n(e,!!t);return"function"==typeof r&&o(e,".prototype.")>-1?i(r):r}},139:function(e,t,r){"use strict";var n=r(174),i=r(925),o=i("%Function.prototype.apply%"),s=i("%Function.prototype.call%"),a=i("%Reflect.apply%",!0)||n.call(s,o),u=i("%Object.getOwnPropertyDescriptor%",!0),c=i("%Object.defineProperty%",!0),l=i("%Math.max%");if(c)try{c({},"a",{value:1})}catch(e){c=null}e.exports=function(e){var t=a(n,s,arguments);return u&&c&&u(t,"length").configurable&&c(t,"length",{value:1+l(0,e.length-(arguments.length-1))}),t};var f=function(){return a(n,o,arguments)};c?c(e.exports,"apply",{value:f}):e.exports.apply=f},144:function(e){var t=Object.prototype.hasOwnProperty,r=Object.prototype.toString;e.exports=function(e,n,i){if("[object Function]"!==r.call(n))throw TypeError("iterator must be a function");var o=e.length;if(o===+o)for(var s=0;s<o;s++)n.call(i,e[s],s,e);else for(var a in e)t.call(e,a)&&n.call(i,e[a],a,e)}},426:function(e){"use strict";var t="Function.prototype.bind called on incompatible ",r=Array.prototype.slice,n=Object.prototype.toString,i="[object Function]";e.exports=function(e){var o,s=this;if("function"!=typeof s||n.call(s)!==i)throw TypeError(t+s);
1for(var a=r.call(arguments,1),u=function(){if(!(this instanceof o))return s.apply(e,a.concat(r.call(arguments)));var t=s.apply(this,a.concat(r.call(arguments)));return Object(t)===t?t:this},c=Math.max(0,s.length-a.length),l=[],f=0;f<c;f++)l.push("$"+f);if(o=Function("binder","return function ("+l.join(",")+"){ return binder.apply(this,arguments); }")(u),s.prototype){var p=function(){};p.prototype=s.prototype,o.prototype=new p,p.prototype=null}return o}},174:function(e,t,r){"use strict";var n=r(426);e.exports=Function.prototype.bind||n},500:function(e,t,r){"use strict";var n,i=SyntaxError,o=Function,s=TypeError,a=function(e){try{return o('"use strict"; return ('+e+").constructor;")()}catch(e){}},u=Object.getOwnPropertyDescriptor;if(u)try{u({},"")}catch(e){u=null}var c=function(){throw new s},l=u?function(){try{return arguments.callee,c}catch(e){try{return u(arguments,"callee").get}catch(e){return c}}}():c,f=r(115)(),p=Object.getPrototypeOf||function(e){return e.__proto__},h={},d="undefined"==typeof Uint8Array?n:p(Uint8Array),y={"%AggregateError%":"undefined"==typeof AggregateError?n:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?n:ArrayBuffer,"%ArrayIteratorPrototype%":f?p([][Symbol.iterator]()):n,"%AsyncFromSyncIteratorPrototype%":n,"%AsyncFunction%":h,"%AsyncGenerator%":h,"%AsyncGeneratorFunction%":h,"%AsyncIteratorPrototype%":h,"%Atomics%":"undefined"==typeof Atomics?n:Atomics,"%BigInt%":"undefined"==typeof BigInt?n:BigInt,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?n:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"==typeof Float32Array?n:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?n:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?n:FinalizationRegistry,"%Function%":o,"%GeneratorFunction%":h,"%Int8Array%":"undefined"==typeof Int8Array?n:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?n:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?n:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%
1IteratorPrototype%":f?p(p([][Symbol.iterator]())):n,"%JSON%":"object"==typeof JSON?JSON:n,"%Map%":"undefined"==typeof Map?n:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&f?p((new Map)[Symbol.iterator]()):n,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?n:Promise,"%Proxy%":"undefined"==typeof Proxy?n:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"==typeof Reflect?n:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?n:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&f?p((new Set)[Symbol.iterator]()):n,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?n:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":f?p(""[Symbol.iterator]()):n,"%Symbol%":f?Symbol:n,"%SyntaxError%":i,"%ThrowTypeError%":l,"%TypedArray%":d,"%TypeError%":s,"%Uint8Array%":"undefined"==typeof Uint8Array?n:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?n:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?n:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?n:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"==typeof WeakMap?n:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?n:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?n:WeakSet},g=function e(t){var r;if("%AsyncFunction%"===t)r=a("async function () {}");else if("%GeneratorFunction%"===t)r=a("function* () {}");else if("%AsyncGeneratorFunction%"===t)r=a("async function* () {}");else if("%AsyncGenerator%"===t){var n=e("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if("%AsyncIteratorPrototype%"===t){var i=e("%AsyncGenerator%");i&&(r=p(i.prototype))}return y[t]=r,r},b={"%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"]},m=r(174),v=r(101),w=m.call(Function.call,Array.prototype.concat),_=m.call(Function.apply,Array.prototype.splice),E=m.call(Function.call,String.prototype.replace),S=m.call(Function.call,String.prototype.slice),A=m.call(Function.call,RegExp.prototype.exec),O=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,R=/\\(\\)?/g,x=function(e){var t=S(e,0,1),r=S(e,-1);if("%"===t&&"%"!==r)throw new i("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==t)throw new i("invalid intrinsic syntax, expected opening `%`");var n=[];return E(e,O,function(e,t,r,i){n[n.length]=r?E(i,R,"$1"):t||e}),n},j=function(e,t){var r,n=e;if(v(b,n)&&(n="%"+(r=b[n])[0]+"%"),v(y,n)){var o=y[n];if(o===h&&(o=g(n)),void 0===o&&!t)throw new s("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:r,name:n,value:o}}throw new i("intrinsic "+e+" does not exist!")};e.exports=function(e,t){if("string"!=typeof e||0===e.length)throw new s("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof t)throw new s('"allowMissing" argument must be a boolean');if(null===A(/^%?[^%]*%?$/g,e))throw new i("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var r=x(e),n=r.length>0?r[0]:"",o=j("%"+n+"%",t),a=o.name,c=o.value,l=!1,f=o.alias;f&&(n=f[0],_(r,w([0,1],f)));for(var p=1,h=!0;p<r.length;p+=1){var d=r[p],g=S(d,0,1),b=S(d,-1);if(('"'===g||"'"===g||"`"===g||'"'===b||"'"===b||"`"===b)&&g!==b)throw new i("property names with quotes must have matching quotes");if("constructor"!==d&&h||(l=!0),n+="."+d,v(y,a="%"+n+"%"))c=y[a];else if(null!=c){if(!(d in c)){if(!t)throw new s("base intrinsic for "+e+" exists, but the property is not available.");return}if(u&&p+1>=r.length){var m=u(c,d);c=(h=!!m)&&"get"in m&&!("originalValue"in m.get)?m.get:c[d]}else h=v(c,d),c=c[d];h&&!l&&(y[a]=c)}}return c}},925:function(e,t,r){"use strict";var n,i=SyntaxError,o=Function,s=TypeError,a=function(e){try{return o('"use strict"; return ('+e+").constructor;")()}catch(e){}},u=Object.getOwnPropertyDescriptor;if(u)try{u({},"")}catch(e){u=null}var c=function(){throw new s},l=u?function(){try{return arguments.callee,c}catch(e){try{return u(arguments,"callee").get}catch(e){return c}}}():c,f=r(115)(),p=r(504)(),h=Object.getPrototypeOf||(p?function(e){return e.__proto__}:null),d={},y="undefined"!=typeof Uint8Array&&h?h(Uint8Array):n,g={"%AggregateError%":"undefined"==typeof AggregateError?n:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?n:ArrayBuffer,"%ArrayIteratorPrototype%":f&&h?h([][Symbol.iterator]()):n,"%AsyncFromSyncIteratorPrototype%":n,"%AsyncFunction%":d,"%AsyncGenerator%":d,"%AsyncGeneratorFunction%":d,"%AsyncIteratorPrototype%":d,"%Atomics%":"undefined"==typeof Atomics?n:Atomics,"%BigInt%":"undefined"==typeof BigInt?n:BigInt,"%BigInt64Array%":"undefined"==typeof BigInt64Array?n:BigInt64Array,"%BigUint64Array%":"undefined"==typeof BigUint64Array?n:BigUint64Array,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?n:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":"undefined"==typeof Float32Array?n:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?n:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?n:FinalizationRegistry,"%Function%":o,"%GeneratorFunction%":d,"%Int8Array%":"undefined"==typeof Int8Array?n:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?n:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?n:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%
1IteratorPrototype%":f&&h?h(h([][Symbol.iterator]())):n,"%JSON%":"object"==typeof JSON?JSON:n,"%Map%":"undefined"==typeof Map?n:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&f&&h?h((new Map)[Symbol.iterator]()):n,"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?n:Promise,"%Proxy%":"undefined"==typeof Proxy?n:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":"undefined"==typeof Reflect?n:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?n:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&f&&h?h((new Set)[Symbol.iterator]()):n,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?n:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":f&&h?h(""[Symbol.iterator]()):n,"%Symbol%":f?Symbol:n,"%SyntaxError%":i,"%ThrowTypeError%":l,"%TypedArray%":y,"%TypeError%":s,"%Uint8Array%":"undefined"==typeof Uint8Array?n:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?n:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?n:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?n:Uint32Array,"%URIError%":URIError,"%WeakMap%":"undefined"==typeof WeakMap?n:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?n:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?n:WeakSet};if(h)try{null.error}catch(e){var b=h(h(e));g["%Error.prototype%"]=b}var m=function e(t){var r;if("%AsyncFunction%"===t)r=a("async function () {}");else if("%GeneratorFunction%"===t)r=a("function* () {}");else if("%AsyncGeneratorFunction%"===t)r=a("async function* () {}");else if("%AsyncGenerator%"===t){var n=e("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if("%AsyncIteratorPrototype%"===t){var i=e("%AsyncGenerator%");i&&h&&(r=h(i.prototype))}return g[t]=r,r},v={"%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"]},w=r(174),_=r(101),E=w.call(Function.call,Array.prototype.concat),S=w.call(Function.apply,Array.prototype.splice),A=w.call(Function.call,String.prototype.replace),O=w.call(Function.call,String.prototype.slice),R=w.call(Function.call,RegExp.prototype.exec),x=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,j=/\\(\\)?/g,C=function(e){var t=O(e,0,1
1),r=O(e,-1);if("%"===t&&"%"!==r)throw new i("invalid intrinsic syntax, expected closing `%`");if("%"===r&&"%"!==t)throw new i("invalid intrinsic syntax, expected opening `%`");var n=[];return A(e,x,function(e,t,r,i){n[n.length]=r?A(i,j,"$1"):t||e}),n},P=function(e,t){var r,n=e;if(_(v,n)&&(n="%"+(r=v[n])[0]+"%"),_(g,n)){var o=g[n];if(o===d&&(o=m(n)),void 0===o&&!t)throw new s("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:r,name:n,value:o}}throw new i("intrinsic "+e+" does not exist!")};e.exports=function(e,t){if("string"!=typeof e||0===e.length)throw new s("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof t)throw new s('"allowMissing" argument must be a boolean');if(null===R(/^%?[^%]*%?$/,e))throw new i("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var r=C(e),n=r.length>0?r[0]:"",o=P("%"+n+"%",t),a=o.name,c=o.value,l=!1,f=o.alias;f&&(n=f[0],S(r,E([0,1],f)));for(var p=1,h=!0;p<r.length;p+=1){var d=r[p],y=O(d,0,1),b=O(d,-1);if(('"'===y||"'"===y||"`"===y||'"'===b||"'"===b||"`"===b)&&y!==b)throw new i("property names with quotes must have matching quotes");if("constructor"!==d&&h||(l=!0),n+="."+d,_(g,a="%"+n+"%"))c=g[a];else if(null!=c){if(!(d in c)){if(!t)throw new s("base intrinsic for "+e+" exists, but the property is not available.");return}if(u&&p+1>=r.length){var m=u(c,d);c=(h=!!m)&&"get"in m&&!("originalValue"in m.get)?m.get:c[d]}else h=_(c,d),c=c[d];h&&!l&&(g[a]=c)}}return c}},504:function(e){"use strict";var t={foo:{}},r=Object;e.exports=function(){return({__proto__:t}).foo===t.foo&&!(({__proto__:null})instanceof r)}},942:function(e,t,r){"use strict";var n="undefined"!=typeof Symbol&&Symbol,i=r(773);e.exports=function(){return"function"==typeof n&&"function"==typeof Symbol&&"symbol"==typeof n("foo")&&"symbol"==typeof Symbol("bar")&&i()}},773:function(e){"use strict";e.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var e={},t=Symbol("test"),r=Object(t);if("string"==typeof t||"[object Symbol]"!==Object.prototype.toString.call(t)||"[object Symbol]"!==Object.prototype.toString.call(r))return!1;var n=42;for(t in e[t]=n,e)return!1;if("function"==typeof Object.keys&&0!==Object.keys(e).length||"function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;var i=Object.getOwnPropertySymbols(e);if(1!==i.length||i[0]!==t||!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var o=Object.getOwnPropertyDescriptor(e,t);if(o.value!==n||!0!==o.enumerable)return!1}return!0}},115:function(e,t,r){"use strict";var n="undefined"!=typeof Symbol&&Symbol,i=r(832);e.exports=function(){return"function"==typeof n&&"function"==typeof Symbol&&"symbol"==typeof n("foo")&&"symbol"==typeof Symbol("bar")&&i()}},832:function(e){"use strict";e.exports=function(){if("function"!=typeof Symbol||"function"!=typeof Object.getOwnPropertySymbols)return!1;if("symbol"==typeof Symbol.iterator)return!0;var e={},t=Symbol("test"),r=Object(t);if("string"==typeof t||"[object Symbol]"!==Object.prototype.toString.call(t)||"[object Symbol]"!==Object.prototype.toString.call(r))return!1;var n=42;for(t in e[t]=n,e)return!1;if("function"==typeof Object.keys&&0!==Object.keys(e).length||"function"==typeof Object.getOwnPropertyNames&&0!==Object.getOwnPropertyNames(e).length)return!1;var i=Object.getOwnPropertySymbols(e);if(1!==i.length||i[0]!==t||!Object.prototype.propertyIsEnumerable.call(e,t))return!1;if("function"==typeof Object.getOwnPropertyDescriptor){var o=Object.getOwnPropertyDescriptor(e,t);if(o.value!==n||!0!==o.enumerable)return!1}return!0}},101:function(e,t,r){"use strict";var n=r(174);e.exports=n.call(Function.call,Object.prototype.hasOwnProperty)},782:function(e){"function"==typeof Object.create?e.exports=function(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function(e,t){if(t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}}},157:function(e){"use strict";var t="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,r=Object.prototype.toString,n=function(e){return(!t||!e||"object"!=typeof e||!(Symbol.toStringTag in e))&&"[object Arguments]"===r.call(e)},i=function(e){return!!n(e)||null!==e&&"object"==typeof e&&"number"==typeof e.length&&e.length>=0&&"[object Array]"!==r.call(e)&&"[object Function]"===r.call(e.callee)},o=function(){return n(arguments)}();n.isLegacyArguments=i,e.exports=o?n:i},391:function(e){"use strict";var t=Object.prototype.toString,r=Function.prototype.toString,n=/^\s*(?:function)?\*/,i="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,o=Object.getPrototypeOf,s=function(){if(!i)return!1;try{return Function("return function*() {}")()}catch(e){}}(),a=s?o(s):{};e.exports=function(e){return"function"==typeof e&&(!!n.test(r.call(e))||(i?o(e)===a:"[object GeneratorFunction]"===t.call(e)))}},994:function(e,t,n){"use strict";var i=n(144),o=n(349),s=n(256),a=s("Object.prototype.toString"),u=n(942)()&&"symbol"==typeof Symbol.toStringTag,c=o(),l=s("Array.prototype.indexOf",!0)||function(e,t){for(var r=0;r<e.length;r+=1)if(e[r]===t)return r;return -1},f=s("String.prototype.slice"),p={},h=n(24),d=Object.getPrototypeOf;u&&h&&d&&i(c,function(e){var t=new r.g[e];
1if(!(Symbol.toStringTag in t))throw EvalError("this engine has support for Symbol.toStringTag, but "+e+" does not have the property! Please report this.");var n=d(t),i=h(n,Symbol.toStringTag);i||(i=h(d(n),Symbol.toStringTag)),p[e]=i.get});var y=function(e){var t=!1;return i(p,function(r,n){if(!t)try{t=r.call(e)===n}catch(e){}}),t};e.exports=function(e){return!!e&&"object"==typeof e&&(u?!!h&&y(e):l(c,f(a(e),8,-1))>-1)}},369:function(e){e.exports=function(e){return e instanceof i}},584:function(e,t,r){"use strict";var n=r(157),i=r(391),o=r(490),s=r(994);function a(e){return e.call.bind(e)}var u="undefined"!=typeof BigInt,c="undefined"!=typeof Symbol,l=a(Object.prototype.toString),f=a(Number.prototype.valueOf),p=a(String.prototype.valueOf),h=a(Boolean.prototype.valueOf);if(u)var d=a(BigInt.prototype.valueOf);if(c)var y=a(Symbol.prototype.valueOf);function g(e,t){if("object"!=typeof e)return!1;try{return t(e),!0}catch(e){return!1}}function b(e){return"undefined"!=typeof Promise&&e instanceof Promise||null!==e&&"object"==typeof e&&"function"==typeof e.then&&"function"==typeof e.catch}function m(e){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):s(e)||L(e)}function v(e){return"Uint8Array"===o(e)}function w(e){return"Uint8ClampedArray"===o(e)}function _(e){return"Uint16Array"===o(e)}function E(e){return"Uint32Array"===o(e)}function S(e){return"Int8Array"===o(e)}function A(e){return"Int16Array"===o(e)}function O(e){return"Int32Array"===o(e)}function R(e){return"Float32Array"===o(e)}function x(e){return"Float64Array"===o(e)}function j(e){return"BigInt64Array"===o(e)}function C(e){return"BigUint64Array"===o(e)}function P(e){return"[object Map]"===l(e)}function I(e){return"undefined"!=typeof Map&&(P.working?P(e):e instanceof Map)}function T(e){return"[object Set]"===l(e)}function $(e){return"undefined"!=typeof Set&&(T.working?T(e):e instanceof Set)}function k(e){return"[object WeakMap]"===l(e)}function N(e){return"undefined"!=typeof WeakMap&&(k.working?k(e):e instanceof WeakMap)}function M(e){return"[object WeakSet]"===l(e)}function q(e){return M(e)}function D(e){return"[object ArrayBuffer]"===l(e)}function F(e){return"undefined"!=typeof ArrayBuffer&&(D.working?D(e):e instanceof ArrayBuffer)}function U(e){return"[object DataView]"===l(e)}function L(e){return"undefined"!=typeof DataView&&(U.working?U(e):e instanceof DataView)}t.isArgumentsObject=n,t.isGeneratorFunction=i,t.isTypedArray=s,t.isPromise=b,t.isArrayBufferView=m,t.isUint8Array=v,t.isUint8ClampedArray=w,t.isUint16Array=_,t.isUint32Array=E,t.isInt8Array=S,t.isInt16Array=A,t.isInt32Array=O,t.isFloat32Array=R,t.isFloat64Array=x,t.isBigInt64Array=j,t.isBigUint64Array=C,P.working="undefined"!=typeof Map&&P(new Map),t.isMap=I,T.working="undefined"!=typeof Set&&T(new Set),t.isSet=$,k.working="undefined"!=typeof WeakMap&&k(new WeakMap),t.isWeakMap=N,M.working="undefined"!=typeof WeakSet&&M(new WeakSet),t.isWeakSet=q,D.working="undefined"!=typeof ArrayBuffer&&D(new ArrayBuffer),t.isArrayBuffer=F,U.working="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof DataView&&U(new DataView(new ArrayBuffer(1),0,1)),t.isDataView=L;var B="undefined"!=typeof SharedArrayBuffer?SharedArrayBuffer:void 0;function V(e){return"[object SharedArrayBuffer]"===l(e)}function W(e){return void 0!==B&&(void 0===V.working&&(V.working=V(new B)),V.working?V(e):e instanceof B)}function z(e){return"[object AsyncFunction]"===l(e)}function H(e){return"[object Map Iterator]"===l(e)}function G(e){return"[object Set Iterator]"===l(e)}function J(e){return"[object Generator]"===l(e)}function Y(e){return"[object WebAssembly.Module]"===l(e)}function K(e){return g(e,f)}function Q(e){return g(e,p)}function X(e){return g(e,h)}function Z(e){return u&&g(e,d)}function ee(e){return c&&g(e,y)}function et(e){return K(e)||Q(e)||X(e)||Z(e)||ee(e)}function er(e){return"undefined"!=typeof Uint8Array&&(F(e)||W(e))}t.isSharedArrayBuffer=W,t.isAsyncFunction=z,t.isMapIterator=H,t.isSetIterator=G,t.isGeneratorObject=J,t.isWebAssemblyCompiledModule=Y,t.isNumberObject=K,t.isStringObject=Q,t.isBooleanObject=X,t.isBigIntObject=Z,t.isSymbolObject=ee,t.isBoxedPrimitive=et,t.isAnyArrayBuffer=er,["isProxy","isExternal","isModuleNamespaceObject"].forEach(function(e){Object.defineProperty(t,e,{enumerable:!1,value:function(){throw Error(e+" is not supported in userland")}})})},177:function(e,t,r){var n=Object.getOwnPropertyDescriptors||function(e){for(var t=Object.keys(e),r={},n=0;n<t.length;n++)r[t[n]]=Object.getOwnPropertyDescriptor(e,t[n]);return r},i=/%[sdj%]/g;t.format=function(e){if(!A(e)){for(var t=[],r=0;r<arguments.length;r++)t.push(c(arguments[r]));return t.join(" ")}for(var r=1,n=arguments,o=n.length,s=String(e).replace(i,function(e){if("%%"===e)return"%";if(r>=o)return e;switch(e){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch(e){return"[Circular]"}default:return e}}),a=n[r];r<o;a=n[++r])_(a)||!j(a)?s+=" "+a:s+=" "+c(a);return s},t.deprecate=function(e,r){if(void 0!==o&&!0===o.noDeprecation)return e;if(void 0===o)return function(){return t.deprecate(e,r).apply(this,arguments)};var n=!1;
vendor: 4,911 bytes, line 1
1return function(){if(!n){if(o.throwDeprecation)throw Error(r);o.traceDeprecation?console.trace(r):console.error(r),n=!0}return e.apply(this,arguments)}};var s={},a=/^$/;if(o.env.NODE_DEBUG){var u=o.env.NODE_DEBUG;a=RegExp("^"+(u=u.replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase())+"$","i")}function c(e,r){var n={seen:[],stylize:f};return arguments.length>=3&&(n.depth=arguments[2]),arguments.length>=4&&(n.colors=arguments[3]),w(r)?n.showHidden=r:r&&t._extend(n,r),R(n.showHidden)&&(n.showHidden=!1),R(n.depth)&&(n.depth=2),R(n.colors)&&(n.colors=!1),R(n.customInspect)&&(n.customInspect=!0),n.colors&&(n.stylize=l),h(n,e,n.depth)}function l(e,t){var r=c.styles[t];return r?"\x1b["+c.colors[r][0]+"m"+e+"\x1b["+c.colors[r][1]+"m":e}function f(e,t){return e}function p(e){var t={};return e.forEach(function(e,r){t[e]=!0}),t}function h(e,r,n){if(e.customInspect&&r&&I(r.inspect)&&r.inspect!==t.inspect&&!(r.constructor&&r.constructor.prototype===r)){var i,o=r.inspect(n,e);return A(o)||(o=h(e,o,n)),o}var s=d(e,r);if(s)return s;var a=Object.keys(r),u=p(a);if(e.showHidden&&(a=Object.getOwnPropertyNames(r)),P(r)&&(a.indexOf("message")>=0||a.indexOf("description")>=0))return y(r);if(0===a.length){if(I(r)){var c=r.name?": "+r.name:"";return e.stylize("[Function"+c+"]","special")}if(x(r))return e.stylize(RegExp.prototype.toString.call(r),"regexp");if(C(r))return e.stylize(Date.prototype.toString.call(r),"date");if(P(r))return y(r)}var l="",f=!1,w=["{","}"];return(v(r)&&(f=!0,w=["[","]"]),I(r)&&(l=" [Function"+(r.name?": "+r.name:"")+"]"),x(r)&&(l=" "+RegExp.prototype.toString.call(r)),C(r)&&(l=" "+Date.prototype.toUTCString.call(r)),P(r)&&(l=" "+y(r)),0!==a.length||f&&0!=r.length)?n<0?x(r)?e.stylize(RegExp.prototype.toString.call(r),"regexp"):e.stylize("[Object]","special"):(e.seen.push(r),i=f?g(e,r,n,u,a):a.map(function(t){return b(e,r,n,u,t,f)}),e.seen.pop(),m(i,l,w)):w[0]+l+w[1]}function d(e,t){if(R(t))return e.stylize("undefined","undefined");if(A(t)){var r="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(r,"string")}return S(t)?e.stylize(""+t,"number"):w(t)?e.stylize(""+t,"boolean"):_(t)?e.stylize("null","null"):void 0}function y(e){return"["+Error.prototype.toString.call(e)+"]"}function g(e,t,r,n,i){for(var o=[],s=0,a=t.length;s<a;++s)q(t,String(s))?o.push(b(e,t,r,n,String(s),!0)):o.push("");return i.forEach(function(i){i.match(/^\d+$/)||o.push(b(e,t,r,n,i,!0))}),o}function b(e,t,r,n,i,o){var s,a,u;if((u=Object.getOwnPropertyDescriptor(t,i)||{value:t[i]}).get?a=u.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):u.set&&(a=e.stylize("[Setter]","special")),q(n,i)||(s="["+i+"]"),!a&&(0>e.seen.indexOf(u.value)?(a=_(r)?h(e,u.value,null):h(e,u.value,r-1)).indexOf("\n")>-1&&(a=o?a.split("\n").map(function(e){return" "+e}).join("\n").substr(2):"\n"+a.split("\n").map(function(e){return" "+e}).join("\n")):a=e.stylize("[Circular]","special")),R(s)){if(o&&i.match(/^\d+$/))return a;(s=JSON.stringify(""+i)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(s=s.substr(1,s.length-2),s=e.stylize(s,"name")):(s=s.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),s=e.stylize(s,"string"))}return s+": "+a}function m(e,t,r){var n=0;return e.reduce(function(e,t){return n++,t.indexOf("\n")>=0&&n++,e+t.replace(/\u001b\[\d\d?m/g,"").length+1},0)>60?r[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+r[1]:r[0]+t+" "+e.join(", ")+" "+r[1]}function v(e){return Array.isArray(e)}function w(e){return"boolean"==typeof e}function _(e){return null===e}function E(e){return null==e}function S(e){return"number"==typeof e}function A(e){return"string"==typeof e}function O(e){return"symbol"==typeof e}function R(e){return void 0===e}function x(e){return j(e)&&"[object RegExp]"===$(e)}function j(e){return"object"==typeof e&&null!==e}function C(e){return j(e)&&"[object Date]"===$(e)}function P(e){return j(e)&&("[object Error]"===$(e)||e instanceof Error)}function I(e){return"function"==typeof e}function T(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e}function $(e){return Object.prototype.toString.call(e)}function k(e){return e<10?"0"+e.toString(10):e.toString(10)}t.debuglog=function(e){if(!s[e=e.toUpperCase()]){if(a.test(e)){var r=o.pid;s[e]=function(){var n=t.format.apply(t,arguments);console.error("%s %d: %s",e,r,n)}}else s[e]=function(){}}return s[e]},t.inspect=c,c.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]},c.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},t.types=r(584),t.isArray=v,t.isBoolean=w,t.isNull=_,t.isNullOrUndefined=E,t.isNumber=S,t.isString=A,t.isSymbol
1=O,t.isUndefined=R,t.isRegExp=x,t.types.isRegExp=x,t.isObject=j,t.isDate=C,t.types.isDate=C,t.isError=P,t.types.isNativeError=P,t.isFunction=I,t.isPrimitive=T,t.isBuffer=r(369);var N=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function M(){var e=new Date,t=[k(e.getHours()),k(e.getMinutes()),k(e.getSeconds())].join(":");return[e.getDate(),N[e.getMonth()],t].join(" ")}function q(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.log=function(){console.log("%s - %s",M(),t.format.apply(t,arguments))},t.inherits=r(782),t._extend=function(e,t){if(!t||!j(t))return e;for(var r=Object.keys(t),n=r.length;n--;)e[r[n]]=t[r[n]];return e};var D="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function F(e,t){if(!e){var r=Error("Promise was rejected with a falsy value");r.reason=e,e=r}return t(e)}function U(e){if("function"!=typeof e)throw TypeError('The "original" argument must be of type Function');function t(){for(var t=[],r=0;r<arguments.length;r++)t.push(arguments[r]);var n=t.pop();if("function"!=typeof n)throw TypeError("The last argument must be of type Function");var i=this,s=function(){return n.apply(i,arguments)};e.apply(this,t).then(function(e){o.nextTick(s.bind(null,null,e))},function(e){o.nextTick(F.bind(null,e,s))})}return Object.setPrototypeOf(t,Object.getPrototypeOf(e)),Object.defineProperties(t,n(e)),t}t.promisify=function(e){if("function"!=typeof e)throw TypeError('The "original" argument must be of type Function');if(D&&e[D]){var t=e[D];if("function"!=typeof t)throw TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(t,D,{value:t,enumerable:!1,writable:!1,configurable:!0}),t}function t(){for(var t,r,n=new Promise(function(e,n){t=e,r=n}),i=[],o=0;o<arguments.length;o++)i.push(arguments[o]);i.push(function(e,n){e?r(e):t(n)});try{e.apply(this,i)}catch(e){r(e)}return n}return Object.setPrototypeOf(t,Object.getPrototypeOf(e)),D&&Object.defineProperty(t,D,{value:t,enumerable:!1,writable:!1,configurable:!0}),Object.defineProperties(t,n(e))},t.promisify.custom=D,t.callbackify=U},490:function(e,t,n){"use strict";var i=n(144),o=n(349),s=n(256),a=s("Object.prototype.toString"),u=n(942)()&&"symbol"==typeof Symbol.toStringTag,c=o(),l=s("String.prototype.slice"),f={},p=n(24),h=Object.getPrototypeOf;u&&p&&h&&i(c,function(e){if("function"==typeof r.g[e]){var t=new r.g[e];if(!(Symbol.toStringTag in t))throw EvalError("this engine has support for Symbol.toStringTag, but "+e+" does not have the property! Please report this.");var n=h(t),i=p(n,Symbol.toStringTag);i||(i=p(h(n),Symbol.toStringTag)),f[e]=i.get}});var d=function(e){var t=!1;return i(f,function(r,n){if(!t)try{var i=r.call(e);i===n&&(t=i)}catch(e){}}),t},y=n(994);e.exports=function(e){return!!y(e)&&(u?d(e):l(a(e),8,-1))}},349:function(e,t,n){"use strict";var i=n(992);e.exports=function(){return i(["BigInt64Array","BigUint64Array","Float32Array","Float64Array","Int16Array","Int32Array","Int8Array","Uint16Array","Uint32Array","Uint8Array","Uint8ClampedArray"],function(e){return"function"==typeof r.g[e]})}},24:function(e,t,r){"use strict";var n=r(500)("%Object.getOwnPropertyDescriptor%",!0);if(n)try{n([],"length")}catch(e){n=null}e.exports=n}},s={};function a(e){var r=s[e];if(void 0!==r)return r.exports;var n=s[e]={exports:{}},i=!0;try{t[e](n,n.exports,a),i=!1}finally{i&&delete s[e]}return n.exports}a.ab=n+"/";var u=a(177);e.exports=u}()},8743:function(module){var __dirname="/";!function(){var __webpack_modules__={950:function(__unused_webpack_module,exports){var indexOf=function(e,t){if(e.indexOf)return e.indexOf(t);for(var r=0;r<e.length;r++)if(e[r]===t)return r;return -1},Object_keys=function(e){if(Object.keys)return Object.keys(e);var t=[];for(var r in e)t.push(r);return t},forEach=function(e,t){if(e.forEach)return e.forEach(t);for(var r=0;r<e.length;r++)t(e[r],r,e)},defineProp=function(){try{return Object.defineProperty({},"_",{}),function(e,t,r){Object.defineProperty(e,t,{writable:!0,enumerable:!1,configurable:!0,value:r})}}catch(e){return function(e,t,r){e[t]=r}}}(),globals=["Array","Boolean","Date","Error","EvalError","Function","Infinity","JSON","Math","NaN","Number","Object","RangeError","ReferenceError","RegExp","String","SyntaxError","TypeError","URIError","decode
1URI","decodeURIComponent","encodeURI","encodeURIComponent","escape","eval","isFinite","isNaN","parseFloat","parseInt","undefined","unescape"];function Context(){}Context.prototype={};var Script=exports.Script=function(e){if(!(this instanceof Script))return new Script(e);this.code=e};Script.prototype.runInContext=function(e){if(!(e instanceof Context))throw TypeError("needs a 'context' argument.");var t=document.createElement("iframe");t.style||(t.style={}),t.style.display="none",document.body.appendChild(t);var r=t.contentWindow,n=r.eval,i=r.execScript;!n&&i&&(i.call(r,"null"),n=r.eval),forEach(Object_keys(e),function(t){r[t]=e[t]}),forEach(globals,function(t){e[t]&&(r[t]=e[t])});var o=Object_keys(r),s=n.call(r,this.code);return forEach(Object_keys(r),function(t){(t in e||-1===indexOf(o,t))&&(e[t]=r[t])}),forEach(globals,function(t){t in e||defineProp(e,t,r[t])}),document.body.removeChild(t),s},Script.prototype.runInThisContext=function(){return eval(this.code)},Script.prototype.runInNewContext=function(e){var t=Script.createContext(e),r=this.runInContext(t);return e&&forEach(Object_keys(t),function(r){e[r]=t[r]}),r},forEach(Object_keys(Script.prototype),function(e){exports[e]=Script[e]=function(t){var r=Script(t);return r[e].apply(r,[].slice.call(arguments,1))}}),exports.isContext=function(e){return e instanceof Context},exports.createScript=function(e){return exports.Script(e)},exports.createContext=Script.createContext=function(e){var t=new Context;return"object"==typeof e&&forEach(Object_keys(e),function(r){t[r]=e[r]}),t}}};"undefined"!=typeof __nccwpck_require__&&(__nccwpck_require__.ab=__dirname+"/");var __nested_webpack_exports__={};__webpack_modules__[950](0,__nested_webpack_exports__),module.exports=__nested_webpack_exports__}()},6966:function(e,t,r){var n=r(1580),i=n.Buffer;function o(e,t){for(var r in e)t[r]=e[r]}function s(e,t,r){return i(e,t,r)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?e.exports=n:(o(n,t),t.Buffer=s),s.prototype=Object.create(i.prototype),o(i,s),s.from=function(e,t,r){if("number"==typeof e)throw TypeError("Argument must not be a number");return i(e,t,r)},s.alloc=function(e,t,r){if("number"!=typeof e)throw TypeError("Argument must be a number");var n=i(e);return void 0!==t?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},s.allocUnsafe=function(e){if("number"!=typeof e)throw TypeError("Argument must be a number");return i(e)},s.allocUnsafeSlow=function(e){if("number"!=typeof e)throw TypeError("Argument must be a number");return n.SlowBuffer(e)}},1022:function(e,t,r){"use strict";var n=r(6966).Buffer,i=n.isEncoding||function(e){switch((e=""+e)&&e.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 o(e){var t;if(!e)return"utf8";for(;;)switch(e){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 e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}function s(e){var t=o(e);if("string"!=typeof t&&(n.isEncoding===i||!i(e)))throw Error("Unknown encoding: "+e);return t||e}function a(e){var t;switch(this.encoding=s(e),this.encoding){case"utf16le":this.text=d,this.end=y,t=4;break;case"utf8":this.fillLast=f,t=4;break;case"base64":this.text=g,this.end=b,t=3;break;default:this.write=m,this.end=v;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=n.allocUnsafe(t)}function u(e){return e<=127?0:e>>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function c(e,t,r){var n=t.length-1;if(n<r)return 0;var i=u(t[n]);return i>=0?(i>0&&(e.lastNeed=i-1),i):--n<r||-2===i?0:(i=u(t[n]))>=0?(i>0&&(e.lastNeed=i-2),i):--n<r||-2===i?0:(i=u(t[n]))>=0?(i>0&&(2===i?i=0:e.lastNeed=i-3),i):0}function l(e,t,r){if((192&t[0])!=128)return e.lastNeed=0,"�";if(e.lastNeed>1&&t.length>1){if((192&t[1])!=128)return e.lastNeed=1,"�";if(e.lastNeed>2&&t.length>2&&(192&t[2])!=128)return e.lastNeed=2,"�"}}function f(e){var t=this.lastTotal-this.lastNeed,r=l(this,e,t);return void 0!==r?r:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):void(e.copy(this.lastChar,t,0,e.length),this.lastNeed-=e.length)}function p(e,t){var r=c(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)}function h(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"�":t}function d(e,t){if((e.length-t)%2==0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(n>=55296&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function y(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function g(e,t){var r=(e.length-t)%3;return 0===r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-r))}function b(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function m(e){return e.toString(this.encoding)}function v(e){return e&&e.length?this.write(e):""}t.StringDecoder=a,a.prototype.write=function(e){var t,r;if(0===e.length)return"";if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<e.length?t?t+this.text(e,r):this.text(e,r):t||""},a.prototype.end=h,a.prototype.text=p,a.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}},8156:function(e,t,r){"use strict";function n(e){return"object"==typeof e&&null!==e&&!Array.isArray(e)}r.d(t,{NG:function(){return g},Uy:function(){return n},y:function(){return f}});var i={0:8203,1:8204,2:8205,3:8290,4:8291,5:8288,6:65279,7:8289,8:119155,9:119156,a:119157,b:119158,c:119159,d:119160,e:119161,f:119162},o={0:8203,1:8204,2:8205,3:65279},s={0:String.fromCodePoint(o[0]),1:String.fromCodePoint(o[1]),2:String.fromCodePoint(o[2]),3:String.fromCodePoint(o[3])},a=[,,,,].fill(String.fromCodePoint(o[0])).join("");function u(e){let t=JSON.stringify(e),r=new TextEncoder().encode(t),n="";for(let e=0;e<r.length;e++){let t=r[e];n+=s[t>>6&3]+s[t>>4&3]+s[t>>2&3]+s[3&t]}return a+n}function c(e){return!(!Number.isNaN(Number(e))||/[a-z]/i.test(e)&&!/\d+(?:[-:\/]\d+){2}(?:T\d+(?:[-:\/]\d+){1,2}(\.\d+)?Z?)?/.test(e))&&!!Date.parse(e)}function l(e){try{new URL(e,e.startsWith("/")?"https://acme.com":void 0)}catch{return!1}return!0}function f(e,t,r="auto"){return!0===r||"auto"===r&&(c(e)||l(e))?e:`${e}${u(t)}`}Object.fromEntries(Object.entries(s).map(e=>[e[1],+e[0]])),Object.fromEntries(Object.entries(i).map(e=>e.reverse()));var p=`${Object.values(i).map(e=>`\\u{${e.toString(16)}}`).join("")}`,h=RegExp(`[${p}]{4,}`,"gu");function d(e){var t;return{cleaned:e.replace(h,""),encoded:(null==(t=e.match(h))?void 0:t[0])||""}}function y(e){return e&&JSON.parse(d(JSON.stringify(e)).cleaned)}function g(e){return y(e)}},5018:function(e,t,r){"use strict";r.d(t,{eI:function(){return i1}});let n=!(typeof navigator>"u")&&"ReactNative"===navigator.product,i={timeout:n?6e4:12e4},o=function(e){let t={...i,..."string"==typeof e?{url:e}:e};if(t.timeout=a(t.timeout),t.query){let{url:e,searchParams:r}=function(e){let t=e.indexOf("?");if(-1===t)return{url:e,searchParams:new URLSearchParams};let r=e.slice(0,t),i=e.slice(t+1);if(!n)return{url:r,searchParams:new URLSearchParams(i)};if("function"!=typeof decodeURIComponent)throw Error("Broken `URLSearchParams` implementation, and `decodeURIComponent` is not defined");let o=new URLSearchParams;for(let e of i.split("&")){let[t,r]=e.split("=");t&&o.append(s(t),s(r||""))}return{url:r,searchParams:o}}(t.url);for(let[n,i]of Object.entries(t.query)){if(void 0!==i){if(Array.isArray(i))for(let e of i)r.append(n,e);else r.append(n,i)}let o=r.toString();o&&(t.url=`${e}?${o}`)}}return t.method=t.body&&!t.method?"POST":(t.method||"GET").toUpperCase(),t};function s(e){return decodeURIComponent(e.replace(/\+/g," "))}function a(e){if(!1===e||0===e)return!1;if(e.connect||e.socket)return e;let t=Number(e);return isNaN(t)?a(i.timeout):{connect:t,socket:t}}let u=/^https?:\/\//i,c=function(e){if(!u.test(e.url))throw Error(`"${e.url}" is not a valid URL`)},l=["request","response","progress","error","abort"],f=["processOptions","validateOptions","interceptRequest","finalizeOptions","onRequest","onResponse","onError","onReturn","onHeaders"];function p(e,t){let r=[],n=f.reduce((e,t)=>
1(e[t]=e[t]||[],e),{processOptions:[o],validateOptions:[c]});function i(e){let r,i;let o="object"==typeof e&&e.callSiteStack?e.callSiteStack:void 0,s=o?void 0:Error(),a=l.reduce((e,t)=>(e[t]=function(){let e=Object.create(null),t=0;return{publish:function(t){for(let r in e)e[r](t)},subscribe:function(r){let n=t++;return e[n]=r,function(){delete e[n]}}}}(),e),{}),u=(i=n,function(e,t,...r){let n="onError"===e,o=t;for(let t=0;t<i[e].length&&(o=(0,i[e][t])(o,...r),!n||o);t++);return o}),c=u("processOptions",e);u("validateOptions",c);let f={options:c,channels:a,applyMiddleware:u},p=a.request.subscribe(e=>{r=t(e,(t,r)=>((e,t,r)=>{let n=e,i=t;if(!n)try{i=u("onResponse",t,r)}catch(e){i=null,n=e}if(n=n&&u("onError",n,r)){if(n instanceof Error){let e=o?.stack||s?.stack;if("string"==typeof e){let t=e.split("\n").slice(o?1:2);t.length>0&&(n.stack+="\n"+t.join("\n"))}}a.error.publish(n)}else i&&a.response.publish(i)})(t,r,e))});a.abort.subscribe(()=>{p(),r&&r.abort()});let h=u("onReturn",a,f);return h===a&&a.request.publish(f),h}return i.use=function(e){if(!e)throw Error("Tried to add middleware that resolved to falsey value");if("function"==typeof e)throw Error("Tried to add middleware that was a function. It probably expects you to pass options to it.");if(e.onReturn&&n.onReturn.length>0)throw Error("Tried to add new middleware with `onReturn` handler, but another handler has already been registered for this event");return f.forEach(t=>{e[t]&&n[t].push(e[t])}),r.push(e),i},i.clone=()=>p(r,t),e.forEach(i.use),i}var h,d,y,g=function(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}(function(){if(y)return d;y=1;var e=function(e){return e.replace(/^\s+|\s+$/g,"")},t=function(e){return"[object Array]"===Object.prototype.toString.call(e)};return d=function(r){if(!r)return{};for(var n=Object.create(null),i=e(r).split("\n"),o=0;o<i.length;o++){var s=i[o],a=s.indexOf(":"),u=e(s.slice(0,a)).toLowerCase(),c=e(s.slice(a+1));typeof n[u]>"u"?n[u]=c:t(n[u])?n[u].push(c):n[u]=[n[u],c]}return n}}());class b{onabort;onerror;onreadystatechange;ontimeout;readyState=0;response;responseText="";responseType="";status;statusText;withCredentials;#e;#t;#r;#n={};#i;#o={};#s;open(e,t,r){this.#e=e,this.#t=t,this.#r="",this.readyState=1,this.onreadystatechange?.(),this.#i=void 0}abort(){this.#i&&this.#i.abort()}getAllResponseHeaders(){return this.#r}setRequestHeader(e,t){this.#n[e]=t}setInit(e,t=!0){this.#o=e,this.#s=t}send(e){let t="arraybuffer"!==this.responseType,r={...this.#o,method:this.#e,headers:this.#n,body:e};"function"==typeof AbortController&&this.#s&&(this.#i=new AbortController,"u">typeof EventTarget&&this.#i.signal instanceof EventTarget&&(r.signal=this.#i.signal)),"u">typeof document&&(r.credentials=this.withCredentials?"include":"omit"),fetch(this.#t,r).then(e=>(e.headers.forEach((e,t)=>{this.#r+=`${t}: ${e}\r 2`}),this.status=e.status,this.statusText=e.statusText,this.readyState=3,this.onreadystatechange?.(),t?e.text():e.arrayBuffer())).then(e=>{"string"==typeof e?this.responseText=e:this.response=e,this.readyState=4,this.onreadystatechange?.()}).catch(e=>{"AbortError"!==e.name?this.onerror?.(e):this.onabort?.()})}}let m="function"==typeof XMLHttpRequest?"xhr":"fetch",v="xhr"===m?XMLHttpRequest:b,w=(e,t)=>{let r=e.options,n=e.applyMiddleware("finalizeOptions",r),i={},o=e.applyMiddleware("interceptRequest",void 0,{adapter:m,context:e});if(o){let e=setTimeout(t,0,null,o);return{abort:()=>clearTimeout(e)}}let s=new v;s instanceof b&&"object"==typeof n.fetch&&s.setInit(n.fetch,n.useAbortSignal??!0);let a=n.headers,u=n.timeout,c=!1,l=!1,f=!1;if(s.onerror=e=>{d(s instanceof b?e instanceof Error?e:Error(`Request error while attempting to reach ${n.url}`,{cause:e}):Error(`Request error while attempting to reach is ${n.url}${e.lengthComputable?`(${e.loaded} of ${e.total} bytes transferred)`:""}`))},s.ontimeout=e=>{d(Error(`Request timeout while attempting to reach ${n.url}${e.lengthComputable?`(${e.loaded} of ${e.total} bytes transferred)`:""}`))},s.onabort=()=>{h(!0),c=!0},s.onreadystatechange=function(){u&&(h(),i.socket=setTimeout(()=>p("ESOCKETTIMEDOUT"),u.socket)),!c&&s&&4===s.readyState&&0!==s.status&&function(){if(!(c||l||f)){if(0===s.status)return void d(Error("Unknown XHR error"));h(),l=!0,t(null,{body:s.response||(""===s.responseType||"text"===s.responseType?s.responseText:""),url:n.url,method:n.method,headers:g(s.getAllResponseHeaders()),statusCode:s.status,statusMessage:s.statusText})}}()},s.open(n.method,n.url,!0),s.withCredentials=!!n.withCredentials,a&&s.setRequestHeader)for(let e in a)a.hasOwnProperty(e)&&s.setRequestHeader(e,a[e]);return n.rawBody&&(s.responseType="arraybuffer"),e.applyMiddleware("onRequest",{options:n,adapter:m,request:s,context:e}),s.send(n.body||null),u&&(i.connect=setTimeout(()=>p("ETIMEDOUT"),u.connect)),{abort:function(){c=!0,s&&s.abort()}};function p(t){f=!0,s.abort();let r=Error("ESOCKETTIMEDOUT"===t?`Socket timed out on request to ${n.url}`:`Connection timed out on request to ${n.url}`);r.code=t,e.channels.error.publish(r)}function h(e){(e||c||s&&s.readyState>=2&&i.connect)&&clearTimeout(i.connect),i.socket&&clearTimeout(i.socket)}function d(e){if(l)return;h(!0),l=!0,s=null;let r=e||Error(`Network error while attempting to reach ${n.url}`);r.isNetworkError=!0,r.request=n,t(r)}},_=(e=[],t=w)=>p(e,t);var E=r(6035),S=r(1580).Buffer;function A(e){return{}}var O,R,x,j,C,P={exports:{}};C||(C=1,function(e,t){t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;let r="color: "+this.color;t.splice(1,0,r,"color: inherit");let n=0,i=0;t[0].replace(/%[a-zA-Z%]/g,e=>{"%%"!==e&&(n++,"%c"===e&&(i=n))}),t.splice(i,0,r)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch{}},t.load=function(){let e;try{e=t.storage.getItem("debug")||t.storage.getItem("DEBUG")}catch{}return!e&&"u">typeof E&&"env"in E&&(e=E.env.DEBUG),e},t.useColors=function(){let e;return"u">typeof window&&!!window.process&&("renderer"===window.process.type||!!window.process.__nwjs)||!("u">typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&
2("u">typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"u">typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"u">typeof navigator&&navigator.userAgent&&(e=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt(e[1],10)>=31||"u">typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},t.storage=function(){try{return localStorage}catch{}}(),t.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.log=console.debug||console.log||(()=>{}),e.exports=(j?x:(j=1,x=function(e){function t(e){let n,i,o,s=null;function a(...e){if(!a.enabled)return;let r=a,i=Number(new Date),o=i-(n||i);r.diff=o,r.prev=n,r.curr=i,n=i,e[0]=t.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let s=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,(n,i)=>{if("%%"===n)return"%";s++;let o=t.formatters[i];if("function"==typeof o){let t=e[s];n=o.call(r,t),e.splice(s,1),s--}return n}),t.formatArgs.call(r,e),(r.log||t.log).apply(r,e)}return a.namespace=e,a.useColors=t.useColors(),a.color=t.selectColor(e),a.extend=r,a.destroy=t.destroy,Object.defineProperty(a,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==s?s:(i!==t.namespaces&&(i=t.namespaces,o=t.enabled(e)),o),set:e=>{s=e}}),"function"==typeof t.init&&t.init(a),a}function r(e,r){let n=t(this.namespace+(typeof r>"u"?":":r)+e);return n.log=this.log,n}function n(e,t){let r=0,n=0,i=-1,o=0;for(;r<e.length;)if(n<t.length&&(t[n]===e[r]||"*"===t[n]))"*"===t[n]?(i=n,o=r):r++,n++;else{if(-1===i)return!1;n=i+1,r=++o}for(;n<t.length&&"*"===t[n];)n++;return n===t.length}return t.debug=t,t.default=t,t.coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){let e=[...t.names,...t.skips.map(e=>"-"+e)].join(",");return t.enable(""),e},t.enable=function(e){for(let r of(t.save(e),t.namespaces=e,t.names=[],t.skips=[],("string"==typeof e?e:"").trim().replace(/\s+/g,",").split(",").filter(Boolean)))"-"===r[0]?t.skips.push(r.slice(1)):t.names.push(r)},t.enabled=function(e){for(let r of t.skips)if(n(e,r))return!1;for(let r of t.names)if(n(e,r))return!0;return!1},t.humanize=function(){if(R)return O;R=1;var e=1e3,t=6e4,r=36e5,n=864e5,i=6048e5;function o(e,t,r,n){var i=t>=1.5*r;return Math.round(e/r)+" "+n+(i?"s":"")}return O=function(s,a){a=a||{};var u,c,l=typeof s;if("string"===l&&s.length>0)return function(o){if(!((o=String(o)).length>100)){var s=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(o);if(s){var a=parseFloat(s[1]);switch((s[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*a;case"weeks":case"week":case"w":return a*i;case"days":case"day":case"d":return a*n;case"hours":case"hour":case"hrs":case"hr":case"h":return a*r;case"minutes":case"minute":case"mins":case"min":case"m":return a*t;case"seconds":case"second":case"secs":case"sec":case"s":return a*e;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return a;default:return}}}}(s);if("number"===l&&isFinite(s))return a.long?(c=Math.abs(u=s))>=n?o(u,c,n,"day"):c>=r?o(u,c,r,"hour"):c>=t?o(u,c,t,"minute"):c>=e?o(u,c,e,"second"):u+" ms":function(i){var o=Math.abs(i);return o>=n?Math.round(i/n)+"d":o>=r?Math.round(i/r)+"h":o>=t?Math.round(i/t)+"m":o>=e?Math.round(i/e)+"s":i+"ms"}(s);throw Error("val is not a non-empty string or a valid number. val="+JSON.stringify(s))}}(),t.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(e).forEach(r=>{t[r]=e[r]}),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){let r=0;for(let t=0;t<e.length;t++)r=(r<<5)-r+e.charCodeAt(t)|0;return t.colors[Math.abs(r)%t.colors.length]},t.enable(t.load()),t}))(t);let{formatters:r}=e.exports;r.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}(P,P.exports)),P.exports,Object.prototype.hasOwnProperty;let I=typeof S>"u"?()=>!1:e=>S.isBuffer(e);function T(e){return"[object Object]"===Object.prototype.toString.call(e)}function $(e){if(!1===T(e))return!1;let t=e.constructor;if(void 0===t)return!0;let r=t.prototype;return!(!1===T(r)||!1===r.hasOwnProperty("isPrototypeOf"))}let k=["boolean","string","number"];function N(){return{processOptions:e=>{let t=e.body;return!t||"function"==typeof t.pipe||I(t)||-1===k.indexOf(typeof t)&&!Array.isArray(t)&&!$(t)?e:Object.assign({},e,{body:JSON.stringify(e.body),headers:Object.assign({},e.headers,{"Content-Type":"application/json"})})}}}function M(e){return{onResponse:r=>{let n=r.headers["content-type"]||"",i=e&&e.force||-1!==n.indexOf("application/json");return r.body&&n&&i?Object.assign({},r,{body:t(r.body)}):r},processOptions:e=>Object.assign({},e,{headers:Object.assign({Accept:"application/json"},e.headers)})};function t(e){try{return JSON.parse(e)}catch(e){throw e.message=`Failed to parsed response body as JSON: ${e.message}`,e}}}let q={};"u">typeof globalThis?q=globalThis:"u">typeof window?q=window:"u">typeof global?q=global:"u">typeof self&&(q=self);var D=q;function F(e={}){let t=e.implementation||D.Observable;if(!t)throw Error("`Observable` is not available in global scope, and n
2o implementation was passed");return{onReturn:(e,r)=>new t(t=>(e.error.subscribe(e=>t.error(e)),e.progress.subscribe(e=>t.next(Object.assign({type:"progress"},e))),e.response.subscribe(e=>{t.next(Object.assign({type:"response"},e)),t.complete()}),e.request.publish(r),()=>e.abort.publish()))}}function U(){return{onRequest:e=>{if("xhr"!==e.adapter)return;let t=e.request,r=e.context;function n(e){return t=>{let n=t.lengthComputable?t.loaded/t.total*100:-1;r.channels.progress.publish({stage:e,percent:n,total:t.total,loaded:t.loaded,lengthComputable:t.lengthComputable})}}"upload"in t&&"onprogress"in t.upload&&(t.upload.onprogress=n("upload")),"onprogress"in t&&(t.onprogress=n("download"))}}}let L=(e={})=>{let t=e.implementation||Promise;if(!t)throw Error("`Promise` is not available in global scope, and no implementation was passed");return{onReturn:(r,n)=>new t((t,i)=>{let o=n.options.cancelToken;o&&o.promise.then(e=>{r.abort.publish(e),i(e)}),r.error.subscribe(i),r.response.subscribe(r=>{t(e.onlyBody?r.body:r)}),setTimeout(()=>{try{r.request.publish(n)}catch(e){i(e)}},0)})}};class B{__CANCEL__=!0;message;constructor(e){this.message=e}toString(){return"Cancel"+(this.message?`: ${this.message}`:"")}}class V{promise;reason;constructor(e){if("function"!=typeof e)throw TypeError("executor must be a function.");let t=null;this.promise=new Promise(e=>{t=e}),e(e=>{this.reason||(this.reason=new B(e),t(this.reason))})}static source=()=>{let e;return{token:new V(t=>{e=t}),cancel:e}}}L.Cancel=B,L.CancelToken=V,L.isCancel=e=>!(!e||!e?.__CANCEL__);var W=(e,t,r)=>("GET"===r.method||"HEAD"===r.method)&&(e.isNetworkError||!1);function z(e){return 100*Math.pow(2,e)+100*Math.random()}let H=(e={})=>(e=>{let t=e.maxRetries||5,r=e.retryDelay||z,n=e.shouldRetry;return{onError:(e,i)=>{var o;let s=i.options,a=s.maxRetries||t,u=s.retryDelay||r,c=s.shouldRetry||n,l=s.attemptNumber||0;if(null!==(o=s.body)&&"object"==typeof o&&"function"==typeof o.pipe||!c(e,l,s)||l>=a)return e;let f=Object.assign({},i,{options:Object.assign({},s,{attemptNumber:l+1})});return setTimeout(()=>i.channels.request.publish(f),u(l)),null}}})({shouldRetry:W,...e});H.shouldRetry=W,h=A;var G=r(7472);function J(e){return"function"==typeof e}function Y(e){var t=e(function(e){Error.call(e),e.stack=Error().stack});return t.prototype=Object.create(Error.prototype),t.prototype.constructor=t,t}var K=Y(function(e){return function(t){e(this),this.message=t?t.length+" errors occurred during unsubscription:\n"+t.map(function(e,t){return t+1+") "+e.toString()}).join("\n "):"",this.name="UnsubscriptionError",this.errors=t}});function Q(e,t){if(e){var r=e.indexOf(t);0<=r&&e.splice(r,1)}}var X=function(){function e(e){this.initialTeardown=e,this.closed=!1,this._parentage=null,this._finalizers=null}return e.prototype.unsubscribe=function(){if(!this.closed){this.closed=!0;var e,t,r,n,i,o=this._parentage;if(o){if(this._parentage=null,Array.isArray(o))try{for(var s=(0,G.__values)(o),a=s.next();!a.done;a=s.next())a.value.remove(this)}catch(t){e={error:t}}finally{try{a&&!a.done&&(t=s.return)&&t.call(s)}finally{if(e)throw e.error}}else o.remove(this)}var u=this.initialTeardown;if(J(u))try{u()}catch(e){i=e instanceof K?e.errors:[e]}var c=this._finalizers;if(c){this._finalizers=null;try{for(var l=(0,G.__values)(c),f=l.next();!f.done;f=l.next()){var p=f.value;try{et(p)}catch(e){i=null!=i?i:[],e instanceof K?i=(0,G.__spreadArray)((0,G.__spreadArray)([],(0,G.__read)(i)),(0,G.__read)(e.errors)):i.push(e)}}}catch(e){r={error:e}}finally{try{f&&!f.done&&(n=l.return)&&n.call(l)}finally{if(r)throw r.error}}}if(i)throw new K(i)}},e.prototype.add=function(t){var r;if(t&&t!==this){if(this.closed)et(t);else{if(t instanceof e){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!==(r=this._finalizers)&&void 0!==r?r:[]).push(t)}}},e.prototype._hasParent=function(e){var t=this._parentage;return t===e||Array.isArray(t)&&t.includes(e)},e.prototype._addParent=function(e){var t=this._parentage;this._parentage=Array.isArray(t)?(t.push(e),t):t?[t,e]:e},e.prototype._removeParent=function(e){var t=this._parentage;t===e?this._parentage=null:Array.isArray(t)&&Q(t,e)},e.prototype.remove=function(t){var r=this._finalizers;r&&Q(r,t),t instanceof e&&t._removeParent(this)},e.EMPTY=function(){var t=new e;return t.closed=!0,t}(),e}(),Z=X.EMPTY;function ee(e){return e instanceof X||e&&"closed"in e&&J(e.remove)&&J(e.add)&&J(e.unsubscribe)}function et(e){J(e)?e():e.unsubscribe()}var er={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNext
2Context:!1},en={setTimeout:function(e,t){for(var r=[],n=2;n<arguments.length;n++)r[n-2]=arguments[n];var i=en.delegate;return(null==i?void 0:i.setTimeout)?i.setTimeout.apply(i,(0,G.__spreadArray)([e,t],(0,G.__read)(r))):setTimeout.apply(void 0,(0,G.__spreadArray)([e,t],(0,G.__read)(r)))},clearTimeout:function(e){var t=en.delegate;return((null==t?void 0:t.clearTimeout)||clearTimeout)(e)},delegate:void 0};function ei(e){en.setTimeout(function(){var t=er.onUnhandledError;if(t)t(e);else throw e})}function eo(){}var es=function(){return ec("C",void 0,void 0)}();function ea(e){return ec("E",void 0,e)}function eu(e){return ec("N",e,void 0)}function ec(e,t,r){return{kind:e,value:t,error:r}}var el=null;function ef(e){if(er.useDeprecatedSynchronousErrorHandling){var t=!el;if(t&&(el={errorThrown:!1,error:null}),e(),t){var r=el,n=r.errorThrown,i=r.error;if(el=null,n)throw i}}else e()}function ep(e){er.useDeprecatedSynchronousErrorHandling&&el&&(el.errorThrown=!0,el.error=e)}var eh=function(e){function t(t){var r=e.call(this)||this;return r.isStopped=!1,t?(r.destination=t,ee(t)&&t.add(r)):r.destination=ew,r}return(0,G.__extends)(t,e),t.create=function(e,t,r){return new eb(e,t,r)},t.prototype.next=function(e){this.isStopped?ev(eu(e),this):this._next(e)},t.prototype.error=function(e){this.isStopped?ev(ea(e),this):(this.isStopped=!0,this._error(e))},t.prototype.complete=function(){this.isStopped?ev(es,this):(this.isStopped=!0,this._complete())},t.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,e.prototype.unsubscribe.call(this),this.destination=null)},t.prototype._next=function(e){this.destination.next(e)},t.prototype._error=function(e){try{this.destination.error(e)}finally{this.unsubscribe()}},t.prototype._complete=function(){try{this.destination.complete()}finally{this.unsubscribe()}},t}(X),ed=Function.prototype.bind;function ey(e,t){return ed.call(e,t)}var eg=function(){function e(e){this.partialObserver=e}return e.prototype.next=function(e){var t=this.partialObserver;if(t.next)try{t.next(e)}catch(e){em(e)}},e.prototype.error=function(e){var t=this.partialObserver;if(t.error)try{t.error(e)}catch(e){em(e)}else em(e)},e.prototype.complete=function(){var e=this.partialObserver;if(e.complete)try{e.complete()}catch(e){em(e)}},e}(),eb=function(e){function t(t,r,n){var i,o,s=e.call(this)||this;return J(t)||!t?i={next:null!=t?t:void 0,error:null!=r?r:void 0,complete:null!=n?n:void 0}:s&&er.useDeprecatedNextContext?((o=Object.create(t)).unsubscribe=function(){return s.unsubscribe()},i={next:t.next&&ey(t.next,o),error:t.error&&ey(t.error,o),complete:t.complete&&ey(t.complete,o)}):i=t,s.destination=new eg(i),s}return(0,G.__extends)(t,e),t}(eh);function em(e){er.useDeprecatedSynchronousErrorHandling?ep(e):ei(e)}function ev(e,t){var r=er.onStoppedNotification;r&&en.setTimeout(function(){return r(e,t)})}var ew={closed:!0,next:eo,error:function(e){throw e},complete:eo},e_=function(){return"function"==typeof Symbol&&Symbol.observable||"@@observable"}();function eE(e){return e}function eS(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return eA(e)}function eA(e){return 0===e.length?eE:1===e.length?e[0]:function(t){return e.reduce(function(e,t){return t(e)},t)}}var eO=function(){function e(e){e&&(this._subscribe=e)}return e.prototype.lift=function(t){var r=new e;return r.source=this,r.operator=t,r},e.prototype.subscribe=function(e,t,r){var n=this,i=ej(e)?e:new eb(e,t,r);return ef(function(){var e=n,t=e.operator,r=e.source;i.add(t?t.call(i,r):r?n._subscribe(i):n._trySubscribe(i))}),i},e.prototype._trySubscribe=function(e){try{return this._subscribe(e)}catch(t){e.error(t)}},e.prototype.forEach=function(e,t){var r=this;return new(t=eR(t))(function(t,n){var i=new eb({next:function(t){try{e(t)}catch(e){n(e),i.unsubscribe()}},error:n,complete:t});r.subscribe(i)})},e.prototype._subscribe=function(e){var t;return null===(t=this.source)||void 0===t?void 0:t.subscribe(e)},e.prototype[e_]=function(){return this},e.prototype.pipe=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return eA(e)(this)},e.prototype.toPromise=function(e){var t=this;return new(e=eR(e))(function(e,r){var n;t.subscribe(function(e){return n=e},function(e){return r(e)},function(){return e(n)})})},e.create=function(t){return new e(t)},e}();function eR(e){var t;return null!==(t=null!=e?e:er.Promise)&&void 0!==t?t:Promise}function ex(e){return e&&J(e.next)&&J(e.error)&&J(e.complete)}function ej(e){return e&&e instanceof eh||ex(e)&&ee(e)}var eC=function(e){return e&&"number"==typeof e.length&&"function"!=typeof e};function eP(e){return J(null==e?void 0:e.then)}function eI(e){return J(e[e_])}function eT(e){return Symbol.asyncIterator&&J(null==e?void 0:e[Symbol.asyncIterator])}function e$(e){return TypeError("You provided "+(null!==e&&"object"==typeof e?"an invali
2d object":"'"+e+"'")+" where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.")}var ek=function(){return"function"==typeof Symbol&&Symbol.iterator?Symbol.iterator:"@@iterator"}();function eN(e){return J(null==e?void 0:e[ek])}function eM(e){return(0,G.__asyncGenerator)(this,arguments,function(){var t,r,n;return(0,G.__generator)(this,function(i){switch(i.label){case 0:t=e.getReader(),i.label=1;case 1:i.trys.push([1,,9,10]),i.label=2;case 2:return[4,(0,G.__await)(t.read())];case 3:if(n=(r=i.sent()).value,!r.done)return[3,5];return[4,(0,G.__await)(void 0)];case 4:return[2,i.sent()];case 5:return[4,(0,G.__await)(n)];case 6:return[4,i.sent()];case 7:return i.sent(),[3,2];case 8:return[3,10];case 9:return t.releaseLock(),[7];case 10:return[2]}})})}function eq(e){return J(null==e?void 0:e.getReader)}function eD(e){if(e instanceof eO)return e;if(null!=e){if(eI(e))return eF(e);if(eC(e))return eU(e);if(eP(e))return eL(e);if(eT(e))return eV(e);if(eN(e))return eB(e);if(eq(e))return eW(e)}throw e$(e)}function eF(e){return new eO(function(t){var r=e[e_]();if(J(r.subscribe))return r.subscribe(t);throw TypeError("Provided object does not correctly implement Symbol.observable")})}function eU(e){return new eO(function(t){for(var r=0;r<e.length&&!t.closed;r++)t.next(e[r]);t.complete()})}function eL(e){return new eO(function(t){e.then(function(e){t.closed||(t.next(e),t.complete())},function(e){return t.error(e)}).then(null,ei)})}function eB(e){return new eO(function(t){var r,n;try{for(var i=(0,G.__values)(e),o=i.next();!o.done;o=i.next()){var s=o.value;if(t.next(s),t.closed)return}}catch(e){r={error:e}}finally{try{o&&!o.done&&(n=i.return)&&n.call(i)}finally{if(r)throw r.error}}t.complete()})}function eV(e){return new eO(function(t){ez(e,t).catch(function(e){return t.error(e)})})}function eW(e){return eV(eM(e))}function ez(e,t){var r,n,i,o;return(0,G.__awaiter)(this,void 0,void 0,function(){var s;return(0,G.__generator)(this,function(a){switch(a.label){case 0:a.trys.push([0,5,6,11]),r=(0,G.__asyncValues)(e),a.label=1;case 1:return[4,r.next()];case 2:if((n=a.sent()).done)return[3,4];if(s=n.value,t.next(s),t.closed)return[2];a.label=3;case 3:return[3,1];case 4:return[3,11];case 5:return i={error:a.sent()},[3,11];case 6:if(a.trys.push([6,,9,10]),!(n&&!n.done&&(o=r.return)))return[3,8];return[4,o.call(r)];case 7:a.sent(),a.label=8;case 8:return[3,10];case 9:if(i)throw i.error;return[7];case 10:return[7];case 11:return t.complete(),[2]}})})}function eH(e){return new eO(function(t){eD(e()).subscribe(t)})}function eG(e){return!!e&&(e instanceof eO||J(e.lift)&&J(e.subscribe))}function eJ(e){return e&&J(e.schedule)}function eY(e){return e[e.length-1]}function eK(e){return J(eY(e))?e.pop():void 0}function eQ(e){return eJ(eY(e))?e.pop():void 0}function eX(e,t){return"number"==typeof eY(e)?e.pop():t}function eZ(e,t,r,n,i){void 0===n&&(n=0),void 0===i&&(i=!1);var o=t.schedule(function(){r(),i?e.add(this.schedule(null,n)):this.unsubscribe()},n);if(e.add(o),!i)return o}function e0(e){return J(null==e?void 0:e.lift)}function e1(e){return function(t){if(e0(t))return t.lift(function(t){try{return e(t,this)}catch(e){this.error(e)}});throw TypeError("Unable to lift unknown Observable type")}}function e3(e,t,r,n,i){return new e2(e,t,r,n,i)}var e2=function(e){function t(t,r,n,i,o,s){var a=e.call(this,t)||this;return a.onFinalize=o,a.shouldUnsubscribe=s,a._next=r?function(e){try{r(e)}catch(e){t.error(e)}}:e.prototype._next,a._error=i?function(e){try{i(e)}catch(e){t.error(e)}finally{this.unsubscribe()}}:e.prototype._error,a._complete=n?function(){try{n()}catch(e){t.error(e)}finally{this.unsubscribe()}}:e.prototype._complete,a}return(0,G.__extends)(t,e),t.prototype.unsubscribe=function(){var t;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){var r=this.closed;e.prototype.unsubscribe.call(this),r||null===(t=this.onFinalize)||void 0===t||t.call(this)}},t}(eh);function e6(e,t){return void 0===t&&(t=0),e1(function(r,n){r.subscribe(e3(n,function(r){return eZ(n,e,function(){return n.next(r)},t)},function(){return eZ(n,e,function(){return n.complete()},t)},function(r){return eZ(n,e,function(){return n.error(r)},t)}
2))})}function e8(e,t){return void 0===t&&(t=0),e1(function(r,n){n.add(e.schedule(function(){return r.subscribe(n)},t))})}function e4(e,t){return eD(e).pipe(e8(t),e6(t))}function e9(e,t){return eD(e).pipe(e8(t),e6(t))}function e7(e,t){return new eO(function(r){var n=0;return t.schedule(function(){n===e.length?r.complete():(r.next(e[n++]),r.closed||this.schedule())})})}function e5(e,t){return new eO(function(r){var n;return eZ(r,t,function(){n=e[ek](),eZ(r,t,function(){var e,t,i;try{t=(e=n.next()).value,i=e.done}catch(e){r.error(e);return}i?r.complete():r.next(t)},0,!0)}),function(){return J(null==n?void 0:n.return)&&n.return()}})}function te(e,t){if(!e)throw Error("Iterable cannot be null");return new eO(function(r){eZ(r,t,function(){var n=e[Symbol.asyncIterator]();eZ(r,t,function(){n.next().then(function(e){e.done?r.complete():r.next(e.value)})},0,!0)})})}function tt(e,t){return te(eM(e),t)}function tr(e,t){if(null!=e){if(eI(e))return e4(e,t);if(eC(e))return e7(e,t);if(eP(e))return e9(e,t);if(eT(e))return te(e,t);if(eN(e))return e5(e,t);if(eq(e))return tt(e,t)}throw e$(e)}function tn(e,t){return t?tr(e,t):eD(e)}function ti(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var r=eQ(e);return tn(e,r)}function to(e,t){return e1(function(r,n){var i=0;r.subscribe(e3(n,function(r){n.next(e.call(t,r,i++))}))})}function ts(e,t,r,n,i,o,s,a){var u=[],c=0,l=0,f=!1,p=function(){!f||u.length||c||t.complete()},h=function(e){return c<n?d(e):u.push(e)},d=function(e){o&&t.next(e),c++;var a=!1;eD(r(e,l++)).subscribe(e3(t,function(e){null==i||i(e),o?h(e):t.next(e)},function(){a=!0},void 0,function(){if(a)try{c--;for(var e=function(){var e=u.shift();s?eZ(t,s,function(){return d(e)}):d(e)};u.length&&c<n;)e();p()}catch(e){t.error(e)}}))};return e.subscribe(e3(t,h,function(){f=!0,p()})),function(){null==a||a()}}function ta(e,t,r){return(void 0===r&&(r=1/0),J(t))?ta(function(r,n){return to(function(e,i){return t(r,e,n,i)})(eD(e(r,n)))},r):("number"==typeof t&&(r=t),e1(function(t,n){return ts(t,n,e,r)}))}var tu=Y(function(e){return function(){e(this),this.name="EmptyError",this.message="no elements in sequence"}});function tc(e,t){var r="object"==typeof t;return new Promise(function(n,i){var o,s=!1;e.subscribe({next:function(e){o=e,s=!0},error:i,complete:function(){s?n(o):r?n(t.defaultValue):i(new tu)}})})}var tl=Y(function(e){return function(){e(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"}}),tf=function(e){function t(){var t=e.call(this)||this;return t.closed=!1,t.currentObservers=null,t.observers=[],t.isStopped=!1,t.hasError=!1,t.thrownError=null,t}return(0,G.__extends)(t,e),t.prototype.lift=function(e){var t=new tp(this,this);return t.operator=e,t},t.prototype._throwIfClosed=function(){if(this.closed)throw new tl},t.prototype.next=function(e){var t=this;ef(function(){var r,n;if(t._throwIfClosed(),!t.isStopped){t.currentObservers||(t.currentObservers=Array.from(t.observers));try{for(var i=(0,G.__values)(t.currentObservers),o=i.next();!o.done;o=i.next())o.value.next(e)}catch(e){r={error:e}}finally{try{o&&!o.done&&(n=i.return)&&n.call(i)}finally{if(r)throw r.error}}}})},t.prototype.error=function(e){var t=this;ef(function(){if(t._throwIfClosed(),!t.isStopped){t.hasError=t.isStopped=!0,t.thrownError=e;for(var r=t.observers;r.length;)r.shift().error(e)}})},t.prototype.complete=function(){var e=this;ef(function(){if(e._throwIfClosed(),!e.isStopped){e.isStopped=!0;for(var t=e.observers;t.length;)t.shift().complete()}})},t.prototype.unsubscribe=function(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null},Object.defineProperty(t.prototype,"observed",{get:function(){var e;return(null===(e=this.observers)||void 0===e?void 0:e.length)>0},enumerable:!1,configurable:!0}),t.prototype._trySubscribe=function(t){return this._throwIfClosed(),e.prototype._trySubscribe.call(this,t)},t.prototype._subscribe=function(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)},t.prototype._innerSubscribe=function(e){var t=this,r=this,n=r.hasError,i=r.isStopped,o=r.observers;return n||i?Z:(this.currentObservers=null,o.push(e),new X(function(){t.currentObservers=null,Q(o,e)}))},t.prototype._checkFinalizedStatuses=function(e){var t=this,r=t.hasError,n=t.thrownError,i=t.isStopped;r?e.error(n):i&&e.complete()},t.prototype.asObservable=function(){var e=new eO;return e.source=this,e},t.create=function(e,t){return new tp(e,t)},t}(eO),tp=function(e){function t(t,r){var n=e.call(this)||this;return n.destination=t,n.source=r,n}return(0,G.__extends)(t,e),t.prototype.next=function(e){var t,r;null===(r=null===(t=this.destination)||void 0===t?void 0:t.next)||void 0===r||r.call(t,e)},t.prototype.error=function(e){var t,r;null===(r=null===(t=this.destination)||void 0===t?void 0:t.error)||void 0===r||r.call(t,e)},t.prototype.complete=function(){var e,t;null===(t=null===(e=this.destination)||void 0===e?void 0:e.complete)||void 0===t||t.call(e)},t.prototype._subscribe=function(e){var t,r;return null!==(r=null===(t=this.source)||void 0===t?void 0:t.subscribe(e))&&void 0!==r?r:Z},t}(tf),th={now:function(){return(th.delegate||Date).now()},delegate:void 0},td=function(e){function t(t,r,n){void 0===t&&(t=1/0),void 0===r&&(r=1/0),void 0===n&&(n=th);var i=e.call(this)||this;return i._bufferSize=t,i._windowTime=r,i._timestampProvider=n,i._buffer=[],i._infiniteTimeWindow=!0,i._infiniteTimeWindow=r===1/0,i._bufferSize=Math.max(1,t),i._windowTime=Math.max(1,r),i}return(0,G.__extends)(t,e),t.prototype.next=function(t){var r=this,n=r.isStopped,i=r._buffer,o=r._infiniteTimeWindow,s=r._timestampProvider,a=r._windowTime;!n&&(i.push(t),o||i.push(s.now()+a)),this._trimBuffer(),e.prototype.next.call(this,t)},t.prototype._subscribe=function(e){this._throwIfClosed(),this._trimBuffer();for(var t=this._innerSubscribe(e),r=this,n=r._infiniteTimeWindow,i=r._buffer.slice(),o=0;o<i.length&&!e.closed;o+=n?1:2)e.next(i[o]);return this._checkFinalizedStatuses(e),t},t.prototype._trimBuffer=function(){var e=this,t=e._bufferSize,r=e._timestampProvider,n=e._buffer,i=e._infiniteTimeWindow,o=(i?1:2)*t;if(t<1/0&&o<n.length&&n.splice(0,n.length-o),!i){for(var s=r.now(),a=0,u=1;u<n.length&&n[u]<=s;u+=2)a=u;a&&n.splice(0,a+1)}},t}(tf);function ty(e){void 0===e&&(e={});var t=e.connector,r=void 0===t?function(){return new tf}:t,n=e.resetOnError,i=void 0===n||n,o=e.resetOnComplete,s=void 0===o||o,a=e.resetOnRefCountZero,u=void 0===a||a;return function(e){var t,n,o,a=0,c=!1,l=!1,f=function(){null==n||n.unsubscribe(),n=void 0},p=function(){f(),t=o=void 0,c=l=!1},h=function(){var e=t;p(),null==e||e.unsubscribe()};return e1(function(e,d){a++,l||c||f();var y=o=null!=o?o:r();
2d.add(function(){0!=--a||l||c||(n=tg(h,u))}),y.subscribe(d),!t&&a>0&&(t=new eb({next:function(e){return y.next(e)},error:function(e){l=!0,f(),n=tg(p,i,e),y.error(e)},complete:function(){c=!0,f(),n=tg(p,s),y.complete()}}),eD(e).subscribe(t))})(e)}}function tg(e,t){for(var r=[],n=2;n<arguments.length;n++)r[n-2]=arguments[n];if(!0===t){e();return}if(!1!==t){var i=new eb({next:function(){i.unsubscribe(),e()}});return eD(t.apply(void 0,(0,G.__spreadArray)([],(0,G.__read)(r)))).subscribe(i)}}function tb(e,t,r){var n,i,o,s,a=!1;return e&&"object"==typeof e?(s=void 0===(n=e.bufferSize)?1/0:n,t=void 0===(i=e.windowTime)?1/0:i,a=void 0!==(o=e.refCount)&&o,r=e.scheduler):s=null!=e?e:1/0,ty({connector:function(){return new td(s,t,r)},resetOnError:!0,resetOnComplete:!1,resetOnRefCountZero:a})}function tm(e){return e1(function(t,r){var n,i=null,o=!1;i=t.subscribe(e3(r,void 0,void 0,function(s){n=eD(e(s,tm(e)(t))),i?(i.unsubscribe(),i=null,n.subscribe(r)):o=!0})),o&&(i.unsubscribe(),i=null,n.subscribe(r))})}function tv(e){return void 0===e&&(e=1/0),ta(eE,e)}function tw(){return tv(1)}function t_(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return tw()(tn(e,eQ(e)))}var tE=function(e){function t(t,r){return e.call(this)||this}return(0,G.__extends)(t,e),t.prototype.schedule=function(e,t){return void 0===t&&(t=0),this},t}(X),tS={setInterval:function(e,t){for(var r=[],n=2;n<arguments.length;n++)r[n-2]=arguments[n];var i=tS.delegate;return(null==i?void 0:i.setInterval)?i.setInterval.apply(i,(0,G.__spreadArray)([e,t],(0,G.__read)(r))):setInterval.apply(void 0,(0,G.__spreadArray)([e,t],(0,G.__read)(r)))},clearInterval:function(e){var t=tS.delegate;return((null==t?void 0:t.clearInterval)||clearInterval)(e)},delegate:void 0},tA=function(e){function t(t,r){var n=e.call(this,t,r)||this;
2return n.scheduler=t,n.work=r,n.pending=!1,n}return(0,G.__extends)(t,e),t.prototype.schedule=function(e,t){if(void 0===t&&(t=0),this.closed)return this;this.state=e;var r,n=this.id,i=this.scheduler;return null!=n&&(this.id=this.recycleAsyncId(i,n,t)),this.pending=!0,this.delay=t,this.id=null!==(r=this.id)&&void 0!==r?r:this.requestAsyncId(i,this.id,t),this},t.prototype.requestAsyncId=function(e,t,r){return void 0===r&&(r=0),tS.setInterval(e.flush.bind(e,this),r)},t.prototype.recycleAsyncId=function(e,t,r){if(void 0===r&&(r=0),null!=r&&this.delay===r&&!1===this.pending)return t;null!=t&&tS.clearInterval(t)},t.prototype.execute=function(e,t){if(this.closed)return Error("executing a cancelled action");this.pending=!1;var r=this._execute(e,t);if(r)return r;!1===this.pending&&null!=this.id&&(this.id=this.recycleAsyncId(this.scheduler,this.id,null))},t.prototype._execute=function(e,t){var r,n=!1;try{this.work(e)}catch(e){n=!0,r=e||Error("Scheduled action threw falsy error")}if(n)return this.unsubscribe(),r},t.prototype.unsubscribe=function(){if(!this.closed){var t=this,r=t.id,n=t.scheduler,i=n.actions;this.work=this.state=this.scheduler=null,this.pending=!1,Q(i,this),null!=r&&(this.id=this.recycleAsyncId(n,r,null)),this.delay=null,e.prototype.unsubscribe.call(this)}},t}(tE),tO=function(){function e(t,r){void 0===r&&(r=e.now),this.schedulerActionCtor=t,this.now=r}return e.prototype.schedule=function(e,t,r){return void 0===t&&(t=0),new this.schedulerActionCtor(this,e).schedule(r,t)},e.now=th.now,e}(),tR=new(function(e){function t(t,r){void 0===r&&(r=tO.now);var n=e.call(this,t,r)||this;return n.actions=[],n._active=!1,n}return(0,G.__extends)(t,e),t.prototype.flush=function(e){var t,r=this.actions;if(this._active){r.push(e);return}this._active=!0;do if(t=e.execute(e.state,e.delay))break;while(e=r.shift());if(this._active=!1,t){for(;e=r.shift();)e.unsubscribe();throw t}},t}(tO))(tA);function tx(e){return e instanceof Date&&!isNaN(e)}function tj(e,t,r){void 0===e&&(e=0),void 0===r&&(r=tR);var n=-1;return null!=t&&(eJ(t)?r=t:n=t),new eO(function(t){var i=tx(e)?+e-r.now():e;i<0&&(i=0);var o=0;return r.schedule(function(){t.closed||(t.next(o++),0<=n?this.schedule(void 0,n):t.complete())},i)})}function tC(e,t){var r=J(e)?e:function(){return e},n=function(e){return e.error(r())};return new eO(t?function(e){return t.schedule(n,0,e)}:n)}function tP(e,t,r){var n=J(e)||t||r?{next:e,error:t,complete:r}:e;return n?e1(function(e,t){null===(r=n.subscribe)||void 0===r||r.call(n);var r,i=!0;e.subscribe(e3(t,function(e){var r;null===(r=n.next)||void 0===r||r.call(n,e),t.next(e)},function(){var e;i=!1,null===(e=n.complete)||void 0===e||e.call(n),t.complete()},function(e){var r;i=!1,null===(r=n.error)||void 0===r||r.call(n,e),t.error(e)},function(){var e,t;i&&(null===(e=n.unsubscribe)||void 0===e||e.call(n)),null===(t=n.finalize)||void 0===t||t.call(n)}))}):eE}function tI(e){return e1(function(t,r){try{t.subscribe(r)}finally{r.add(e)}})}var tT=new eO(function(e){return e.complete()});function t$(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var r=eQ(e),n=eX(e,1/0),i=e;return i.length?1===i.length?eD(i[0]):tv(n)(tn(i,r)):tT}function tk(e,t){var r="object"==typeof t;return new Promise(function(n,i){var o=new eb({next:function(e){n(e),o.unsubscribe()},error:i,complete:function(){r?n(t.defaultValue):i(new tu)}});e.subscribe(o)})}var tN=r(8156);function tM(e,t,r){return void 0===r&&(r=eE),function(n){tq(t,function(){for(var i=e.length,o=Array(i),s=i,a=i,u=function(i){tq(t,function(){var u=tn(e[i],t),c=!1;u.subscribe(e3(n,function(e){o[i]=e,!c&&(c=!0,a--),a||n.next(r(o.slice()))},function(){--s||n.complete()}))},n)},c=0;c<i;c++)u(c)},n)}}function tq(e,t,r){e?eZ(r,e,t):t()}var tD=Array.isArray;function tF(e){return 1===e.length&&tD(e[0])?e[0]:e}var tU=Array.isArray;function tL(e,t){return tU(t)?e.apply(void 0,(0,G.__spreadArray)([],(0,G.__read)(t))):e(t)}function tB(e){return to(function(t){return tL(e,t)})}function tV(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var r=eK(e);return r?eS(tV.apply(void 0,(0,G.__spreadArray)([],(0,G.__read)(e))),tB(r)):e1(function(t,r){tM((0,G.__spreadArray)([t],(0,G.__read)(tF(e))))(r)})}function tW(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return tV.apply(void 0,(0,G.__spreadArray)([],(0,G.__read)(e)))}function tz(e,t){return e1(function(r,n){var i=0;r.subscribe(e3(n,function(r){return e.call(t,r,i++)&&n.next(r)}))})}function tH(e,t){return J(t)?ta(e,t,1):ta(e,1)}function tG(e,t,r,n,i){return function(o,s){var a=r,u=t,c=0;o.subscribe(e3(s,function(t){var r=c++;u=a?e(u,t,r):(a=!0,t),n&&s.next(u)},i&&function(){a&&s.next(u),s.complete()}
2))}}function tJ(e,t){return e1(tG(e,t,arguments.length>=2,!1,!0))}let tY=/_key\s*==\s*['"](.*)['"]/,tK=/^\d*:\d*$/;function tQ(e){return"number"==typeof e||"string"==typeof e&&/^\[\d+\]$/.test(e)}function tX(e){return"string"==typeof e?tY.test(e.trim()):"object"==typeof e&&"_key"in e}function tZ(e){if("string"==typeof e&&tK.test(e))return!0;if(!Array.isArray(e)||2!==e.length)return!1;let[t,r]=e;return("number"==typeof t||""===t)&&("number"==typeof r||""===r)}function t0(e){return Number(e.replace(/[^\d]/g,""))}function t1(e){return{_key:e.match(tY)[1]}}function t3(e){let[t,r]=e.split(":").map(e=>""===e?e:Number(e));return[t,r]}let t2="drafts",t6="versions",t8=".",t4=`${t2}${t8}`,t9=`${t6}${t8}`;function t7(e){return e.startsWith(t4)}function t5(e){return e.startsWith(t9)}function re(e){return t5(e)?t4+rn(e):t7(e)?e:t4+e}function rt(e,t){if("drafts"===t||"published"===t)throw Error('Version can not be "published" or "drafts"');return`${t9}${t}${t8}${rn(e)}`}function rr(e){if(!t5(e))return;let[t,r]=e.split(t8);return r}function rn(e){return t5(e)?e.split(t8).slice(2).join(t8):t7(e)?e.slice(t4.length):e}let ri=e=>crypto.getRandomValues(new Uint8Array(e)),ro=(e,t,r)=>{let n=(2<<Math.log(e.length-1)/Math.LN2)-1,i=-~(1.6*n*t/e.length);return (o=t)=>{let s="";for(;;){let t=r(i),a=0|i;for(;a--;)if((s+=e[t[a]&n]||"").length===o)return s}}},rs=(e,t=21)=>ro(e,t,ri),ra=/\r\n|[\n\r\u2028\u2029]/;function ru(e,t,r){let n=e.split(ra),{start:i,end:o,markerLines:s}=rc({start:rl(t.start,n),end:t.end?rl(t.end,n):void 0},n),a=`${o}`.length;return e.split(ra,o).slice(i,o).map((e,t)=>{let n=i+1+t,o=` ${` ${n}`.slice(-a)} |`,u=s[n],c=!s[n+1];if(!u)return` ${o}${e.length>0?` ${e}`:""}`;let l="";if(Array.isArray(u)){let t=e.slice(0,Math.max(u[0]-1,0)).replace(/[^\t]/g," "),n=u[1]||1;l=[` 3 `,o.replace(/\d/g," ")," ",t,"^".repeat(n)].join(""),c&&r&&(l+=" "+r)}return[">",o,e.length>0?` ${e}`:"",l].join("")}).join(` 4`)}function rc(e,t){let r={...e.start},n={...r,...e.end},i=2,o=3,s=r.line??-1,a=r.column??0,u=n.line,c=n.column,l=Math.max(s-(i+1),0),f=Math.min(t.length,u+o);-1===s&&(l=0),-1===u&&(f=t.length);let p=u-s,h={};if(p)for(let e=0;e<=p;e++){let r=e+s;if(a){if(0===e){let e=t[r-1].length;h[r]=[a,e-a+1]}else if(e===p)h[r]=[0,c];else{let n=t[r-e].length;h[r]=[0,n]}}else h[r]=!0}else a===c?a?h[s]=[a,0]:h[s]=!0:h[s]=[a,c-a];return{start:l,end:f,markerLines:h}}function rl(e,t){let r=0;for(let n=0;n<t.length;n++){let i=t[n].length+1;if(r+i>e)return{line:n+1,column:e-r};r+=i}return{line:t.length,column:t[t.length-1]?.length??0}}let rf=5;class rp extends Error{response;statusCode=400;responseBody;traceId;details;constructor(e,t){let r=rd(e,t);super(r.message),Object.assign(this,r)}}class rh extends Error{response;statusCode=500;responseBody;traceId;details;constructor(e){let t=rd(e);super(t.message),Object.assign(this,t)}}function rd(e,t){let r=e.body,n={response:e,statusCode:e.statusCode,responseBody:r_(r,e),traceId:rw(e),message:"",details:void 0};if(!(0,tN.Uy)(r))return n.message=`${rv(e,r)}${rE(n.traceId)}`,n;let i=r.error;if("string"==typeof i&&"string"==typeof r.message)return n.message=`${i} - ${r.message}${rE(n.traceId)}`,n;if("object"!=typeof i||null===i)return"string"==typeof i?n.message=`${i}${rE(n.traceId)}`:"string"==typeof r.message?n.message=`${r.message}${rE(n.traceId)}`:n.message=`${rv(e,r)}${rE(n.traceId)}`,n;if(ry(i)||rg(i)){let e=i.items||[],t=e.slice(0,rf).map(e=>e.error?.description).filter(Boolean),o=t.length?`: 5- ${t.join(` 6- `)}`:"";return e.length>rf&&(o+=` 7...and ${e.length-rf} more`),n.message=`${i.description}${rE(n.traceId)}${o}`,n.details=r.error,n}if(rb(i)){let e=t?.options?.query?.tag;return n.message=rm(i,e,n.traceId),n.details=r.error,n}return"description"in i&&"string"==typeof i.description?(n.message=`${i.description}${rE(n.traceId)}`,n.details=i):n.message=`${rv(e,r)}${rE(n.traceId)}`,n}function ry(e){return"type"in e&&"mutationError"===e.type&&"description"in e&&"string"==typeof e.description}function rg(e){return"type"in e&&"actionError"===e.type&&"description"in e&&"string"==typeof e.description}function rb(e){return(0,tN.Uy)(e)&&"queryParseError"===e.type&&"string"==typeof e.query&&"number"==typeof e.start&&"number"==typeof e.end}function rm(e,t,r){let{query:n,start:i,end:o,description:s}=e,a=r?` 8(traceId: ${r})`:"";if(!n||typeof i>"u")return`GROQ query parse error: ${s}${a}`;let u=t?` 9 10Tag: ${t}`:"";return`GROQ query parse error: 11${ru(n,{start:i,end:o},s)}${u}${a}`}function rv(e,t){let r="string"==typeof t?` (${rS(t,100)})`:"",n=e.statusMessage?` ${e.statusMessage}`:"";return`${e.method}-request to ${e.url} resulted in HTTP ${e.statusCode}${n}${r}`}function rw(e){let t=e?.headers?.traceparent;if(t)return t.split("-")[1]}function r_(e,t){return -1!==(t.headers["content-type"]||"").toLowerCase().indexOf("application/json")?JSON.stringify(e,null,2):e}function rE(e){return e?` (traceId: ${e})`:""}function rS(e,t){return e.length>t?`${e.slice(0,t)}\u2026`:e}
11class rA extends Error{projectId;addOriginUrl;constructor({projectId:e,credentials:t}={}){if(super("CorsOriginError"),this.name="CorsOriginError",this.projectId=e,e&&"u">typeof location){let r=new URL(`https://sanity.io/manage/project/${e}/api`),{origin:n}=location;r.searchParams.set("cors","add"),r.searchParams.set("origin",n),t&&r.searchParams.set("credentials",""),this.addOriginUrl=r,this.message=`The current origin is not allowed to connect to the Live Content API. Add it here: ${r}`}else e?this.message=`The current origin is not allowed to connect to the Live Content API. Change your configuration here: https://sanity.io/manage/project/${e}/api`:this.message="The current origin is not allowed to connect to the Live Content API."}}let rO={onResponse:(e,t)=>{if(e.statusCode>=500)throw new rh(e);if(e.statusCode>=400)throw new rp(e,t);return e}};function rR(e={}){let t={},r=t=>void 0!==e.ignoreWarnings&&(Array.isArray(e.ignoreWarnings)?e.ignoreWarnings:[e.ignoreWarnings]).some(e=>"string"==typeof e?t.includes(e):e instanceof RegExp&&e.test(t));return{onResponse:e=>{let n=e.headers["x-sanity-warning"];for(let e of Array.isArray(n)?n:[n])!e||t[e]||r(e)||(t[e]=!0,console.warn(e));return e}}}function rx(e,t={}){return _([H({shouldRetry:rj}),...e,rR(t),N(),M(),U(),rO,F({implementation:eO})])}function rj(e,t,r){if(0===r.maxRetries)return!1;let n="GET"===r.method||"HEAD"===r.method,i=(r.uri||r.url).startsWith("/data/query"),o=e.response&&(429===e.response.statusCode||502===e.response.statusCode||503===e.response.statusCode);return(!!n||!!i)&&!!o||H.shouldRetry(e,t,r)}let rC="https://www.sanity.io/help/";function rP(e){return rC+e}let rI=["image","file"],rT=["before","after","replace"],r$=e=>{if(!/^(~[a-z0-9]{1}[-\w]{0,63}|[a-z0-9]{1}[-\w]{0,63})$/.test(e))throw Error("Datasets can only contain lowercase characters, numbers, underscores and dashes, and start with tilde, and be maximum 64 characters")},rk=e=>{if(!/^[-a-z0-9]+$/i.test(e))throw Error("`projectId` can only contain only a-z, 0-9 and dashes")},rN=e=>{if(-1===rI.indexOf(e))throw Error(`Invalid asset type: ${e}. Must be one of ${rI.join(", ")}`)},rM=(e,t)=>{if(null===t||"object"!=typeof t||Array.isArray(t))throw Error(`${e}() takes an object of properties`)},rq=(e,t)=>{if("string"!=typeof t||!/^[a-z0-9_][a-z0-9_.-]{0,127}$/i.test(t)||t.includes(".."))throw Error(`${e}(): "${t}" is not a valid document ID`)},rD=(e,t)=>{if(!t._id)throw Error(`${e}() requires that the document contains an ID ("_id" property)`);rq(e,t._id)},rF=(e,t)=>{if("string"!=typeof t)throw Error(`\`${e}()\`: \`${t}\` is not a valid document type`)},rU=(e,t)=>{if(!t._type)throw Error(`\`${e}()\` requires that the document contains a type (\`_type\` property)`);rF(e,t._type)},rL=(e,t)=>{if(t._id&&t._id!==e)throw Error(`The provided document ID (\`${t._id}\`) does not match the generated version ID (\`${e}\`)`)},rB=(e,t,r)=>{let n="insert(at, selector, items)";
11if(-1===rT.indexOf(e)){let e=rT.map(e=>`"${e}"`).join(", ");throw Error(`${n} takes an "at"-argument which is one of: ${e}`)}if("string"!=typeof t)throw Error(`${n} takes a "selector"-argument which must be a string`);if(!Array.isArray(r))throw Error(`${n} takes an "items"-argument which must be an array`)},rV=e=>{if(e.dataset)return e.dataset;let t=e.resource;if(t&&"dataset"===t.type){let e=t.id.split(".");if(2!==e.length)throw Error('Dataset resource ID must be in the format "project.dataset"');return e[1]}throw Error("`dataset` must be provided to perform queries")},rW=e=>{if("string"!=typeof e||!/^[a-z0-9._-]{1,75}$/i.test(e))throw Error("Tag can only contain alphanumeric characters, underscores, dashes and dots, and be between one and 75 characters long.");return e},rz=e=>{let t=e.resource;if(!t)throw Error("`resource` must be provided to perform resource queries");let{type:r,id:n}=t;switch(r){case"dataset":if(2!==n.split(".").length)throw Error('Dataset resource ID must be in the format "project.dataset"');return;case"dashboard":case"media-library":case"canvas":return;default:throw Error(`Unsupported resource type: ${r.toString()}`)}},rH=(e,t)=>{if(t.resource)throw Error(`\`${e}\` does not support resource-based operations`)};function rG(e){let t=!1,r;return(...n)=>(t||(r=e(...n),t=!0),r)}let rJ=e=>rG((...t)=>console.warn(e.join(" "),...t)),rY=rJ(["Because you set `withCredentials` to true, we will override your `useCdn`","setting to be false since (cookie-based) credentials are never set on the CDN"]),rK=rJ(["Since you haven't set a value for `useCdn`, we will deliver content using our","global, edge-cached API-CDN. If you wish to have content delivered faster, set","`useCdn: false` to use the Live API. Note: You may incur higher costs using the live API."]),rQ=rJ(["The Sanity client is configured with the `perspective` set to `drafts` or `previewDrafts`, which doesn't support the API-CDN.","The Live API will be used instead. Set `useCdn: false` in your configuration to hide this warning."]),rX=rJ(["The `previewDrafts` perspective has been renamed to `drafts` and will be removed in a future API version"]),rZ=rJ(["You have configured Sanity client to use a token in the browser. This may cause unintentional security issues.",`See ${rP("js-client-browser-token")} for more information and how to hide this warning.`]),r0=rJ(["You have configured Sanity client to use a token, but also provided `withCredentials: true`.","This is no longer supported - only token will be used - remove `withCredentials: true`."]),r1=rJ(["Using the Sanity client without specifying an API version is deprecated.",`See ${rP("js-client-api-version")}`]),r3=rJ(["The default export of @sanity/client has been deprecated. Use the named export `createClient` instead."]),r2=rJ(["You have called `createVersion()` with a defined `document`. The recommended approach is to provide a `baseId` and `releaseId` instead."]),r6=rJ(["The `~experimental_resource` configuration property has been renamed to `resource`.","Please update your client configuration to use `resource` instead. Support for `~experimental_resource` will be removed in a future version."]),r8="apicdn.sanity.io",r4={apiHost:"https://api.sanity.io",apiVersion:"1",useProjectHostname:!0,stega:{enabled:!1}},r9=["localhost","127.0.0.1","0.0.0.0"],r7=e=>-1!==r9.indexOf(e);function r5(e){if("1"===e||"X"===e)return;let t=new Date(e);if(!(/^\d{4}-\d{2}-\d{2}$/.test(e)&&t instanceof Date&&t.getTime()>0))throw Error("Invalid API version string, expected `1` or date in format `YYYY-MM-DD`")}function ne(e){if(Array.isArray(e)&&e.length>1&&e.includes("raw"))throw TypeError('Invalid API perspective value: "raw". The raw-perspective can not be combined with other perspectives')}let nt=(e,t)=>{let r={...t,...e,stega:{..."boolean"==typeof t.stega?{enabled:t.stega}:t.stega||r4.stega,..."boolean"==typeof e.stega?{enabled:e.stega}:e.stega||{}}};r.apiVersion||r1();let n={...r4,...r};n["~experimental_resource"]&&!n.resource&&(r6(),n.resource=n["~experimental_resource"]);let i=n.resource,o=n.useProjectHostname&&!i;if(typeof Promise>"u"){let e=rP("js-client-promise-polyfill");throw Error(`No native Promise-implementation found, polyfill needed - see ${e}`)}if(o&&!n.projectId)throw Error("Configuration must contain `projectId`");if(i&&rz(n),"u">typeof n.perspective&&ne(n.perspective),"encodeSourceMap"in n)throw Error("It looks like you're using options meant for '@sanity/preview-kit/client'. 'encodeSourceMap' is not supported in '@sanity/client'. Did you mean 'stega.enabled'?");if("encodeSourceMapAtPath"in n)throw Error("It looks like you're using options meant for '@sanity/preview-kit/client'. 'encodeSourceMapAtPath' is not supported in '@sanity/client'. Did you mean 'stega.filter'?");
11if("boolean"!=typeof n.stega.enabled)throw Error(`stega.enabled must be a boolean, received ${n.stega.enabled}`);if(n.stega.enabled&&void 0===n.stega.studioUrl)throw Error("stega.studioUrl must be defined when stega.enabled is true");if(n.stega.enabled&&"string"!=typeof n.stega.studioUrl&&"function"!=typeof n.stega.studioUrl)throw Error(`stega.studioUrl must be a string or a function, received ${n.stega.studioUrl}`);let s="u">typeof window&&window.location&&window.location.hostname,a=s&&r7(window.location.hostname),u=!!n.token;n.withCredentials&&u&&(r0(),n.withCredentials=!1),s&&a&&u&&!0!==n.ignoreBrowserTokenWarning?rZ():typeof n.useCdn>"u"&&rK(),o&&rk(n.projectId),n.dataset&&r$(n.dataset),"requestTagPrefix"in n&&(n.requestTagPrefix=n.requestTagPrefix?rW(n.requestTagPrefix).replace(/\.+$/,""):void 0),n.apiVersion=`${n.apiVersion}`.replace(/^v/,""),n.isDefaultApi=n.apiHost===r4.apiHost,!0===n.useCdn&&n.withCredentials&&rY(),n.useCdn=!1!==n.useCdn&&!n.withCredentials,r5(n.apiVersion);let c=n.apiHost.split("://",2),l=c[0],f=c[1],p=n.isDefaultApi?r8:f;return o?(n.url=`${l}://${n.projectId}.${f}/v${n.apiVersion}`,n.cdnUrl=`${l}://${n.projectId}.${p}/v${n.apiVersion}`):(n.url=`${n.apiHost}/v${n.apiVersion}`,n.cdnUrl=n.url),n};class nr extends Error{name="ConnectionFailedError";status;constructor(e,t={}){let{status:r,...n}=t;super(e,n),this.status=r}}
11class nn extends Error{name="DisconnectError";reason;constructor(e,t,r={}){super(e,r),this.reason=t}}class ni extends Error{name="ChannelError";data;constructor(e,t){super(e),this.data=t}}class no extends Error{name="MessageError";data;constructor(e,t,r={}){super(e,r),this.data=t}}class ns extends Error{name="MessageParseError"}let na=["channelError","disconnect"];function nu(e,t){return eH(()=>{let t=e();return eG(t)?t:ti(t)}).pipe(ta(e=>nc(e,t)))}function nc(e,t){return new eO(r=>{let n=t.includes("open"),i=t.includes("reconnect");function o(t){if("data"in t){let[e,n]=nl(t);r.error(e?new ns("Unable to parse EventSource error message",{cause:n}):new no((n?.data).message,n));return}let n=t.status,o="number"==typeof n?n:void 0;if(void 0!==o){r.error(new nr("EventSource connection failed",{status:o}));return}e.readyState===e.CLOSED?r.error(new nr("EventSource connection failed")):i&&r.next({type:"reconnect"})}function s(){r.next({type:"open"})}function a(t){let[n,i]=nl(t);if(n){r.error(new ns("Unable to parse EventSource message",{cause:n}));return}if("channelError"===t.type){let t=new URL(e.url).searchParams.get("tag");r.error(new ni(nf(i?.data,t),i.data));return}if("disconnect"===t.type){r.error(new nn(`Server disconnected client: ${i.data?.reason||"unknown error"}`));return}r.next({type:t.type,id:t.lastEventId,...i.data?{data:i.data}:{}})}e.addEventListener("error",o),n&&e.addEventListener("open",s);let u=[...new Set([...na,...t])].filter(e=>"error"!==e&&"open"!==e&&"reconnect"!==e);return u.forEach(t=>e.addEventListener(t,a)),()=>{e.removeEventListener("error",o),n&&e.removeEventListener("open",s),u.forEach(t=>e.removeEventListener(t,a)),e.close()}})}function nl(e){try{let t="string"==typeof e.data&&JSON.parse(e.data);return[null,{type:e.type,id:e.lastEventId,...np(t)?{}:{data:t}}]}catch(e){return[e,null]}}function nf(e,t){let r=e.error;return r?rb(r)?rm(r,t):r.description?r.description:"string"==typeof r?r:JSON.stringify(r,null,2):e.message||"Unknown listener error"}function np(e){for(let t in e)return!1;return!0}function nh(e){if("string"==typeof e)return{id:e};if(Array.isArray(e))return{query:"*[_id in $ids]",params:{ids:e}};if("object"==typeof e&&null!==e&&"query"in e&&"string"==typeof e.query)return"params"in e&&"object"==typeof e.params&&null!==e.params?{query:e.query,params:e.params}:{query:e.query};let t=["* Document ID (<docId>)","* Array of document IDs","* Object containing `query`"].join(` 12`);throw Error(`Unknown selection - must be one of: 13 14${t}`)}class nd{selection;operations;constructor(e,t={}){this.selection=e,this.operations=t}set(e){return this._assign("set",e)}setIfMissing(e){return this._assign("setIfMissing",e)}diffMatchPatch(e){return rM("diffMatchPatch",e),this._assign("diffMatchPatch",e)}unset(e){if(!Array.isArray(e))throw Error("unset(attrs) takes an array of attributes to unset, non-array given");return this.operations=Object.assign({},this.operations,{unset:e}),this}inc(e){return this._assign("inc",e)}dec(e){return this._assign("dec",e)}insert(e,t,r){return rB(e,t,r),this._assign("insert",{[e]:t,items:r})}append(e,t){return this.insert("after",`${e}[-1]`,t)}prepend(e,t){return this.insert("before",`${e}[0]`,t)}splice(e,t,r,n){let i=t<0?t-1:t,o=typeof r>"u"||-1===r?-1:Math.max(0,t+r),s=i<0&&o>=0?"":o,a=`${e}[${i}:${s}]`;return this.insert("replace",a,n||[])}ifRevisionId(e){return this.operations.ifRevisionID=e,this}serialize(){return{...nh(this.selection),...this.operations}}toJSON(){return this.serialize()}reset(){return this.operations={},this}_assign(e,t,r=!0){return rM(e,t),this.operations=Object.assign({},this.operations,{[e]:Object.assign({},r&&this.operations[e]||{},t)}),this}_set(e,t){return this._assign(e,t,!1)}}class ny extends nd{#a;constructor(e,t,r){super(e,t),this.#a=r}clone(){return new ny(this.selection,{...this.operations},this.#a)}commit(e){if(!this.#a)throw Error("No `client` passed to patch, either provide one or pass the patch to a clients `mutate()` method");let t=Object.assign({returnFirst:"string"==typeof this.selection,returnDocuments:!0},e);return this.#a.mutate({patch:this.serialize()},t)}}class ng extends nd{#a;constructor(e,t,r){super(e,t),this.#a=r}clone(){return new ng(this.selection,{...this.operations},this.#a)}commit(e){if(!this.#a)throw Error("No `client` passed to patch, either provide one or pass the patch to a clients `mutate()` method");let t=Object.assign({returnFirst:"string"==typeof this.selection,returnDocuments:!0},e);return this.#a.mutate({patch:this.serialize()},t)}}let nb={returnDocuments:!1};
14class nm{operations;trxId;constructor(e=[],t){this.operations=e,this.trxId=t}create(e){return rM("create",e),this._add({create:e})}createIfNotExists(e){let t="createIfNotExists";return rM(t,e),rD(t,e),this._add({[t]:e})}createOrReplace(e){let t="createOrReplace";return rM(t,e),rD(t,e),this._add({[t]:e})}delete(e){return rq("delete",e),this._add({delete:{id:e}})}transactionId(e){return e?(this.trxId=e,this):this.trxId}serialize(){return[...this.operations]}toJSON(){return this.serialize()}reset(){return this.operations=[],this}_add(e){return this.operations.push(e),this}}class nv extends nm{#a;constructor(e,t,r){super(e,r),this.#a=t}clone(){return new nv([...this.operations],this.#a,this.trxId)}commit(e){if(!this.#a)throw Error("No `client` passed to transaction, either provide one or pass the transaction to a clients `mutate()` method");return this.#a.mutate(this.serialize(),Object.assign({transactionId:this.trxId},nb,e||{}))}patch(e,t){let r="function"==typeof t,n="string"!=typeof e&&e instanceof ng,i="object"==typeof e&&("query"in e||"id"in e);if(n)return this._add({patch:e.serialize()});if(r){let r=t(new ng(e,{},this.#a));if(!(r instanceof ng))throw Error("function passed to `patch()` must return the patch");return this._add({patch:r.serialize()})}if(i){let r=new ng(e,t||{},this.#a);return this._add({patch:r.serialize()})}return this._add({patch:{id:e,...t}})}}class nw extends nm{#a;constructor(e,t,r){super(e,r),this.#a=t}clone(){return new nw([...this.operations],this.#a,this.trxId)}commit(e){if(!this.#a)throw Error("No `client` passed to transaction, either provide one or pass the transaction to a clients `mutate()` method");return this.#a.mutate(this.serialize(),Object.assign({transactionId:this.trxId},nb,e||{}))}patch(e,t){let r="function"==typeof t;if("string"!=typeof e&&e instanceof ny)return this._add({patch:e.serialize()});if(r){let r=t(new ny(e,{},this.#a));if(!(r instanceof ny))throw Error("function passed to `patch()` must return the patch");return this._add({patch:r.serialize()})}return this._add({patch:{id:e,...t}})}}let n_="X-Sanity-Project-ID";function nE(e,t={}){let r={};e.headers&&Object.assign(r,e.headers);let n=t.token||e.token;n&&(r.Authorization=`Bearer ${n}`),t.useGlobalApi||e.useProjectHostname||!e.projectId||(r[n_]=e.projectId);let i=!!(typeof t.withCredentials>"u"?e.withCredentials:t.withCredentials),o=typeof t.timeout>"u"?e.timeout:t.timeout;return Object.assign({},t,{headers:Object.assign({},r,t.headers||{}),timeout:typeof o>"u"?3e5:o,proxy:t.proxy||e.proxy,json:!0,withCredentials:i,fetch:"object"==typeof t.fetch&&"object"==typeof e.fetch?{...e.fetch,...t.fetch}:t.fetch||e.fetch})}let nS=({query:e,params:t={},options:r={}})=>{let n=new URLSearchParams,{tag:i,includeMutations:o,returnQuery:s,...a}=r;for(let[r,o]of(i&&n.append("tag",i),n.append("query",e),Object.entries(t)))void 0!==o&&n.append(`$${r}`,JSON.stringify(o));for(let[e,t]of Object.entries(a))t&&n.append(e,`${t}`);return!1===s&&n.append("returnQuery","false"),!1===o&&n.append("includeMutations","false"),`?${n}`},nA=(e,t)=>!1===e?void 0:typeof e>"u"?t:e,nO=(e={})=>({dryRun:e.dryRun,returnIds:!0,returnDocuments:nA(e.returnDocuments,!0),visibility:e.visibility||"sync",autoGenerateArrayKeys:e.autoGenerateArrayKeys,skipCrossDatasetReferenceValidation:e.skipCrossDatasetReferenceValidation}),nR=e=>"response"===e.type,nx=e=>e.body,nj=(e,t)=>e.reduce((e,r)=>(e[t(r)]=r,e),Object.create(null)),nC=11264;function nP(e,t,n,i,o={},s={}){let a="stega"in s?{...n||{},..."boolean"==typeof s.stega?{enabled:s.stega}:s.stega||{}}:n,u=a.enabled?(0,tN.NG)(o):o,c=!1===s.filterResponse?e=>e:e=>e.result,{cache:l,next:f,...p}={useAbortSignal:"u">typeof s.signal,resultSourceMap:a.enabled?"withKeyArraySelector":s.resultSourceMap,...s,returnQuery:!1===s.filterResponse&&!1!==s.returnQuery},h=nH(e,t,"query",{query:i,params:u},"u">typeof l||"u">typeof f?{...p,fetch:{cache:l,next:f}}:p);return a.enabled?h.pipe(tW(tn(r.e(5887).then(r.bind(r,5887)).then(function(e){return e.stegaEncodeSourceMap$1}).then(({stegaEncodeSourceMap:e})=>e))),to(([e,t])=>{let r=t(e.result,e.resultSourceMap,a);return c({...e,result:r})})):h.pipe(to(c))}function nI(e,t,r,n={}){let i={uri:n2(e,"doc",(()=>{if(!n.releaseId)return r;let e=rr(r);if(!e){if(t7(r))throw Error(`The document ID (\`${r}\`) is a draft, but \`options.releaseId\` is set as \`${n.releaseId}\``);return rt(r,n.releaseId)}if(e!==n.releaseId)throw Error(`The document ID (\`${r}\`) is already a version of \`${e}\` release, but this does not match the provided \`options.releaseId\` (\`${n.releaseId}\`)`);return r})()),json:!0,tag:n.tag,signal:n.signal,query:void 0!==n.includeAllVersions?{includeAllVersions:n.includeAllVersions}:void 0};return n1(e,t,i).pipe(tz(nR),to(e=>{let t=e.body.documents;return t?n.includeAllVersions?t:t[0]:n.includeAllVersions?[]:void 0}))}function nT(e,t,r,n={}){let i={uri:n2(e,"doc",r.join(",")),json:!0,tag:n.tag,signal:n.signal};return n1(e,t,i).pipe(tz(nR),to(e=>{let t=nj(e.body.documents||[],e=>e._id);return r.map(e=>t[e]||null)}))}let n$=100;function nk(e,t,r,n={}){if(0===r.length)return ti(new Set);let i=[];for(let e=0;e<r.length;e+=n$)i.push(r.slice(e,e+n$));let o=r=>n1(e,t,{uri:n2(e,"doc",r.map(encodeURIComponent).join(",")),tag:n.tag,signal:n.signal,query:{excludeContent:!0}}).pipe(tz(nR),to(e=>{let t=new Set;for(let r of e.body.omitted||[])"existence"===r.reason&&t.add(r.id);return new Set(r.filter(e=>!t.has(e)))}));return tn(i).pipe(tH(o),tJ((e,t)=>{for(let r of t)e.add(r);return e},new Set))}function nN(e,t,r,n={}){return nH(e,t,"query",{query:"*[sanity::partOfRelease($releaseId)]",params:{releaseId:r}},n)}function nM(e,t,r,n){return rD("createIfNotExists",r),nG(e,t,r,"createIfNotExists",n)}function nq(e,t,r,n){return rD("createOrReplace",r),nG(e,t,r,"createOrReplace",n
14)}function nD(e,t,r,n,i){return rD("createVersion",r),rU("createVersion",r),r2(),nz(e,t,{actionType:"sanity.action.document.version.create",publishedId:n,document:r},i)}function nF(e,t,r,n,i,o,s){if(!n)throw Error("`createVersion()` requires `baseId` when no `document` is provided");if(!r)throw Error("`createVersion()` requires `publishedId` when `baseId` is provided");return rq("createVersion",n),rq("createVersion",r),nz(e,t,{actionType:"sanity.action.document.version.create",publishedId:r,baseId:n,versionId:i?rt(r,i):re(r),ifBaseRevisionId:o},s)}function nU(e,t,r,n){return nH(e,t,"mutate",{mutations:[{delete:nh(r)}]},n)}function nL(e,t,r,n=!1,i){return nz(e,t,{actionType:"sanity.action.document.version.discard",versionId:r,purge:n},i)}function nB(e,t,r,n){return rD("replaceVersion",r),rU("replaceVersion",r),nz(e,t,{actionType:"sanity.action.document.version.replace",document:r},n)}function nV(e,t,r,n,i){return nz(e,t,{actionType:"sanity.action.document.version.unpublish",versionId:r,publishedId:n},i)}function nW(e,t,r,n){let i;return nH(e,t,"mutate",{mutations:Array.isArray(i=r instanceof ng||r instanceof ny?{patch:r.serialize()}:r instanceof nv||r instanceof nw?r.serialize():r)?i:[i],transactionId:n&&n.transactionId||void 0},n)}function nz(e,t,r,n){let i=Array.isArray(r)?r:[r];return nH(e,t,"actions",{actions:i,transactionId:n&&n.transactionId||void 0,skipCrossDatasetReferenceValidation:n&&n.skipCrossDatasetReferenceValidation||void 0,dryRun:n&&n.dryRun||void 0},n)}function nH(e,t,r,n,i={}){let o="mutate"===r,s="actions"===r,a="query"===r,u=o||s?"":nS(n),c=!o&&!s&&u.length<nC,l=c?u:"",f=i.returnFirst,{timeout:p,token:h,tag:d,headers:y,returnQuery:g,lastLiveEventId:b,cacheMode:m}=i,v={method:c?"GET":"POST",uri:n2(e,r,l),json:!0,body:c?void 0:n,query:o&&nO(i),timeout:p,headers:y,token:h,tag:d,returnQuery:g,perspective:i.perspective,variant:i.variant,resultSourceMap:i.resultSourceMap,lastLiveEventId:Array.isArray(b)?b[0]:b,cacheMode:m,canUseCdn:a,signal:i.signal,fetch:i.fetch,useAbortSignal:i.useAbortSignal,useCdn:i.useCdn};return n1(e,t,v).pipe(tz(nR),to(nx),to(e=>{if(!o)return e;let t=e.results||[];if(i.returnDocuments)return f?t[0]&&t[0].document:t.map(e=>e.document);let r=f?"documentId":"documentIds",n=f?t[0]&&t[0].id:t.map(e=>e.id);return{transactionId:e.transactionId,results:t,[r]:n}}))}function nG(e,t,r,n,i={}){return nH(e,t,"mutate",{mutations:[{[n]:r}]},Object.assign({returnFirst:!0,returnDocuments:!0},i))}let nJ=e=>{let t=e.config();return void 0!==t.dataset&&void 0!==t.projectId||void 0!==t.resource},nY=(e,t)=>nJ(e)&&t.startsWith(n2(e,"query")),nK=(e,t)=>nJ(e)&&t.startsWith(n2(e,"mutate")),nQ=(e,t)=>nJ(e)&&t.startsWith(n2(e,"doc","")),nX=(e,t)=>nJ(e)&&t.startsWith(n2(e,"listen")),nZ=(e,t)=>nJ(e)&&t.startsWith(n2(e,"history","")),n0=(e,t)=>t.startsWith("/data/")||nY(e,t)||nK(e,t)||nQ(e,t)||nX(e,t)||nZ(e,t);function n1(e,t,r){let n=Error(),i=r.url||r.uri,o=e.config(),s=typeof r.canUseCdn>"u"?["GET","HEAD"].indexOf(r.method||"GET")>=0&&n0(e,i):r.canUseCdn,a=(r.useCdn??o.useCdn)&&s,u=r.tag&&o.requestTagPrefix?[o.requestTagPrefix,r.tag].join("."):r.tag||o.requestTagPrefix;if(u&&null!==r.tag&&(r.query={tag:rW(u),...r.query}),["GET","HEAD","POST"].indexOf(r.method||"GET")>=0&&nY(e,i)){let e=r.resultSourceMap??o.resultSourceMap;void 0!==e&&!1!==e&&(r.query={resultSourceMap:e,...r.query});let t=r.perspective||o.perspective;"u">typeof t&&("previewDrafts"===t&&rX(),ne(t),r.query={perspective:Array.isArray(t)?t.join(","):t,...r.query},(Array.isArray(t)&&t.length>0||"previewDrafts"===t||"drafts"===t)&&a&&(a=!1,rQ()));let n=r.variant||o.variant;if("u">typeof n&&("string"==typeof n&&(r.query={variant:n,...r.query}),"object"==typeof n)){let e=Object.entries(n),t=n5(e).slice(0,1);if(e.length>1){let t=new Intl.ListFormat("en");console.warn(`The Sanity client's beta \`variant\` option currently only supports one condition. Dropped: ${t.format(e.slice(1).map(([e])=>JSON.stringify(e)))}.`)}r.query={...Object.fromEntries(t),...r.query}}r.lastLiveEventId&&(r.query={...r.query,lastLiveEventId:r.lastLiveEventId}),!1===r.returnQuery&&(r.query={returnQuery:"false",...r.query}),a&&"noStale"==r.cacheMode&&(r.query={cacheMode:"noStale",...r.query})}let c=nE(o,Object.assign({}
14,r,{url:n6(e,i,a),callSiteStack:n})),l=new eO(e=>t(c,o.requester).subscribe(e));return r.signal?l.pipe(n8(r.signal)):l}function n3(e,t,r){return n1(e,t,r).pipe(tz(e=>"response"===e.type),to(e=>e.body))}function n2(e,t,r){let n=e.config();if(n.resource){rz(n);let e=n7(n),i=void 0!==r?`${t}/${r}`:t;return`${e}/${i}`.replace(/\/($|\?)/,"$1")}let i=rV(n),o=`/${t}/${i}`;return`/data${void 0!==r?`${o}/${r}`:o}`.replace(/\/($|\?)/,"$1")}function n6(e,t,r=!1){let{url:n,cdnUrl:i}=e.config();return`${r?i:n}/${t.replace(/^\//,"")}`}function n8(e){return t=>new eO(r=>{let n=()=>r.error(n9(e));if(e&&e.aborted){n();return}let i=t.subscribe(r);return e.addEventListener("abort",n),()=>{e.removeEventListener("abort",n),i.unsubscribe()}})}let n4=!!globalThis.DOMException;function n9(e){if(n4)return new DOMException(e?.reason??"The operation was aborted.","AbortError");let t=Error(e?.reason??"The operation was aborted.");return t.name="AbortError",t}let n7=e=>{let t=e.resource;if(!t)throw Error("`resource` must be provided to perform resource queries");let{type:r,id:n}=t;switch(r){case"dataset":{let e=n.split(".");if(2!==e.length)throw Error('Dataset ID must be in the format "project.dataset"');return`/projects/${e[0]}/datasets/${e[1]}`}case"canvas":return`/canvases/${n}`;case"media-library":return`/media-libraries/${n}`;case"dashboard":return`/dashboards/${n}`;default:throw Error(`Unsupported resource type: ${r.toString()}`)}};function n5(e){return e.map(([e,t])=>["variantCondition",`${e}:${t}`])}function ie(e,t,r){let n=rV(e.config());return n3(e,t,{method:"POST",uri:`/agent/action/generate/${n}`,body:r})}function it(e,t,r){let n=rV(e.config());return n3(e,t,{method:"POST",uri:`/agent/action/patch/${n}`,body:r})}function ir(e,t,r){let n=rV(e.config());return n3(e,t,{method:"POST",uri:`/agent/action/prompt/${n}`,body:r})}function ii(e,t,r){let n=rV(e.config());return n3(e,t,{method:"POST",uri:`/agent/action/transform/${n}`,body:r})}function io(e,t,r){let n=rV(e.config());return n3(e,t,{method:"POST",uri:`/agent/action/translate/${n}`,body:r})}class is{#a;#u;constructor(e,t){this.#a=e,this.#u=t}generate(e){return ie(this.#a,this.#u,e)}transform(e){return ii(this.#a,this.#u,e)}translate(e){return io(this.#a,this.#u,e)}}class ia{#a;#u;constructor(e,t){this.#a=e,this.#u=t}generate(e){return tc(ie(this.#a,this.#u,e))}transform(e){return tc(ii(this.#a,this.#u,e))}translate(e){return tc(io(this.#a,this.#u,e))}prompt(e){return tc(ir(this.#a,this.#u,e))}patch(e){return tc(it(this.#a,this.#u,e))}}class iu{#a;#u;constructor(e,t){this.#a=e,this.#u=t}upload(e,t,r){return il(this.#a,this.#u,e,t,r)}}class ic{#a;#u;constructor(e,t){this.#a=e,this.#u=t}upload(e,t,r){return tc(il(this.#a,this.#u,e,t,r).pipe(tz(e=>"response"===e.type),to(e=>e.body.document)))}}function il(e,t,r,n,i={}){rN(r);let o=i.extract||void 0;o&&!o.length&&(o=["none"]);let s=e.config(),a=ih(i,n),{tag:u,label:c,title:l,description:f,creditLine:p,filename:h,source:d}=a,y=s.resource?.type==="media-library",g=y?{title:l,filename:h}:{label:c,title:l,description:f,filename:h,meta:o,creditLine:p};return d&&!y&&(g.sourceId=d.id,g.sourceName=d.name,g.sourceUrl=d.url),n1(e,t,{tag:u,method:"POST",timeout:a.timeout||0,uri:ip(s,r),headers:a.contentType?{"Content-Type":a.contentType}:{},query:g,body:n})}function ip(e,t){let r="image"===t?"images":"files",n=e.resource;if(n){let{type:e,id:t}=n;switch(e){case"dataset":throw Error("Assets are not supported for dataset resources, yet. Configure the client with `{projectId: <projectId>, dataset: <datasetId>}` instead.");case"canvas":return`/canvases/${t}/assets/${r}`;case"media-library":return`/media-libraries/${t}/upload`;case"dashboard":return`/dashboards/${t}/assets/${r}`;default:throw Error(`Unsupported resource type: ${e.toString()}`)}}let i=rV(e);return`assets/${r}/${i}`}function ih(e,t){return!(typeof File>"u")&&t instanceof File?Object.assign({filename:!1===e.preserveFilename?void 0:t.name,contentType:t.type},e):e}var id=(e,t)=>Object.keys(t).concat(Object.keys(e)).reduce((r,n)=>(r[n]=typeof e[n]>"u"?t[n]:e[n],r),{});let iy=(e,t)=>t.reduce((t,r)=>(typeof e[r]>"u"||(t[r]=e[r]),t),{}),ig=eH(()=>r.e(3892).then(r.bind(r,3892))).pipe(to(({default:e})=>e),tb(1)),ib=new Set([408,429]);function im(){return function(e){return e.pipe(tm((e,t)=>e instanceof nr&&("number"!=typeof e.status||e.status<400||e.status>=500||ib.has(e.status))?t_(ti({type:"reconnect"}),tj(1e3).pipe(ta(()=>t))):tC(()=>e)))}}let iv=14800,iw=["includePreviousRevision","includeResult","includeMutations","includeAllVersions","visibility","effectFormat","enableResume","tag"],i_={includeResult:!0};function iE(e,t,r={}){let{url:n,token:i,withCredentials:o,requestTagPrefix:s,headers:a}=this.config(),u=r.tag&&s?[s,r.tag].join("."):r.tag,c={...id(r,i_),tag:u},l=nS({query:e,params:t,options:{tag:u,...iy(c,iw)}}),f=`${n}${n2(this,"listen",l)}`;if(f.length>iv)return tC(()=>Error("Query too large for listener"));let p=c.events?c.events:["mutation"],h={};return o&&(h.withCredentials=!0),(i||a)&&(h.headers={},i&&(h.headers.Authorization=`Bearer ${i}`),a&&Object.assign(h.headers,a)),nu(()=>(typeof EventSource>"u"||h.headers?ig:ti(EventSource)).pipe(to(e=>
14new e(f,h))),p).pipe(im(),tz(e=>p.includes(e.type)),to(e=>({type:e.type,..."data"in e?e.data:{}})))}function iS(e,t){return iA("function"==typeof e?{predicate:e,...t}:e)}function iA(e){return t=>{let r,n=!1,{predicate:i,...o}=e;return t$(t.pipe(tP(t=>{e.predicate(t)&&(n=!0,r=t)}),tI(()=>{n=!1,r=void 0}),ty(o)),new eO(e=>{n&&e.next(r),e.complete()}))}}let iO="2021-03-25";class iR{#a;constructor(e){this.#a=e}events({includeDrafts:e=!1,tag:t,waitFor:r}={}){let{projectId:n,apiVersion:i,token:o,withCredentials:s,requestTagPrefix:a,headers:u}=this.#a.config(),c=i.replace(/^v/,"");if("X"!==c&&c<iO)throw Error(`The live events API requires API version ${iO} or later. The current API version is ${c}. Please update your API version to use this feature.`);if(e&&!o&&!s)throw Error("The live events API requires a token or withCredentials when 'includeDrafts: true'. Please update your client configuration. The token should have the lowest possible access role.");let l=n2(this.#a,"live/events"),f=new URL(this.#a.getUrl(l,!1)),p=t&&a?[a,t].join("."):t;p&&f.searchParams.set("tag",p),e&&f.searchParams.set("includeDrafts","true"),r&&f.searchParams.set("waitFor",r);let h={};e&&s&&(h.withCredentials=!0),(e&&o||u)&&(h.headers={},e&&o&&(h.headers.Authorization=`Bearer ${o}`),u&&Object.assign(h.headers,u));let d=`${f.href}::${JSON.stringify(h)}`,y=ij.get(d);if(y)return y;let g=nu(()=>(typeof EventSource>"u"||h.headers?ig:ti(EventSource)).pipe(to(e=>new e(f.href,h))),["message","restart","welcome","reconnect","goaway"]),b=ix(new URL(this.#a.getUrl("/check/cors",!1)),n,!0===h.withCredentials),m=g.pipe(im(),ta(e=>"reconnect"===e.type?b.pipe(ta(()=>ti(e))):ti(e)),tm(e=>e instanceof rA?tC(()=>e):b.pipe(ta(()=>{throw e}))),to(e=>{if("message"===e.type){let{data:t,...r}=e;return{...r,tags:t.tags}}return e})).pipe(tI(()=>ij.delete(d)),iS({predicate:e=>"welcome"===e.type}));return ij.set(d,m),m}}function ix(e,t,r){return new eO(n=>{let i=new AbortController,{signal:o}=i;return fetch(e,{method:"GET",mode:"cors",credentials:"omit",signal:o}).then(e=>{if(!(o.aborted||!e.ok))return e.json()}).then(e=>{if(!o.aborted){if(r&&e?.result?.withCredentials===!1){n.error(new rA({projectId:t,credentials:!0}));return}if(e?.result?.allowed===!1){n.error(new rA({projectId:t,credentials:r}));return}n.next(),n.complete()}}).catch(()=>{o.aborted||n.closed||(n.next(),n.complete())}),()=>i.abort()})}let ij=new Map;class iC{#a;#u;constructor(e,t){this.#a=e,this.#u=t}create(e,t){return iT(this.#a,this.#u,"PUT",e,t)}edit(e,t){return iT(this.#a,this.#u,"PATCH",e,t)}delete(e){return iT(this.#a,this.#u,"DELETE",e)}list(){rH("dataset",this.#a.config());let e=this.#a.config(),t=e.projectId,r="/datasets";return!1===e.useProjectHostname&&(r=`/projects/${t}/datasets`),n3(this.#a,this.#u,{uri:r,tag:null})}getEmbeddingsSettings(e){return rH("dataset",this.#a.config()),r$(e),n3(this.#a,this.#u,{uri:iI(this.#a,e),tag:null})}editEmbeddingsSettings(e,t){return rH("dataset",this.#a.config()),r$(e),n3(this.#a,this.#u,{method:"PUT",uri:iI(this.#a,e),body:t,tag:null})}}class iP{#a;#u;constructor(e,t){this.#a=e,this.#u=t}create(e,t){return rH("dataset",this.#a.config()),tc(iT(this.#a,this.#u,"PUT",e,t))}edit(e,t){return rH("dataset",this.#a.config()),tc(iT(this.#a,this.#u,"PATCH",e,t))}delete(e){return rH("dataset",this.#a.config()),tc(iT(this.#a,this.#u,"DELETE",e))}list(){rH("dataset",this.#a.config());let e=this.#a.config(),t=e.projectId,r="/datasets";return!1===e.useProjectHostname&&(r=`/projects/${t}/datasets`),tc(n3(this.#a,this.#u,{uri:r,tag:null}))}getEmbeddingsSettings(e){return rH("dataset",this.#a.config()),r$(e),tc(n3(this.#a,this.#u,{uri:iI(this.#a,e),tag:null}))}editEmbeddingsSettings(e,t){return rH("dataset",this.#a.config()),r$(e),tc(n3(this.#a,this.#u,{method:"PUT",uri:iI(this.#a,e),body:t,tag:null}))}}function iI(e,t){let r=e.config();return!1===r.useProjectHostname?`/projects/${r.projectId}/datasets/${t}/settings/embeddings`:`/datasets/${t}/settings/embeddings`}function iT(e,t,r,n,i){return rH("dataset",e.config()),r$(n),n3(e,t,{method:r,uri:`/datasets/${n}`,body:i,tag:null})}class i${#a;#u;constructor(e,t){this.#a=e,this.#u=t}getPlaybackInfo(e,t={}){let r=this.#a.config(),n=(r.resource||r["~experimental_resource"])?.id,{instanceId:i,library
14Id:o}=iq(e),s=o||n;if(!s)throw Error("Could not determine Media Library ID - you need to provide a valid Media Library ID in the client config or a Media Library GDR");let a=iD(i,s),u=iF(t);return n3(this.#a,this.#u,{method:"GET",uri:a,query:u})}}class ik{#a;#u;constructor(e,t){this.#a=e,this.#u=t}getPlaybackInfo(e,t={}){return tc(new i$(this.#a.observable,this.#u).getPlaybackInfo(e,t))}}let iN=/^media-library:(ml[^:]+):([^:]+)$/;function iM(e){return"object"==typeof e&&"_ref"in e}function iq(e){let t=iM(e)?e._ref:e,r=iN.exec(t);if(r){let[,e,t]=r;return{libraryId:e,instanceId:t}}if("string"==typeof e&&e.startsWith("video-"))return{instanceId:e};throw Error(`Invalid video asset instance identifier "${t}": must be a valid video instance id or a Global Dataset Reference (GDR) to the video asset in the Media Library`)}function iD(e,t){return`/media-libraries/${t}/video/${e}/playback-info`}function iF(e){let t={};if(e.transformations){let{thumbnail:r,animated:n,storyboard:i}=e.transformations;r&&(r.width&&(t.thumbnailWidth=r.width),r.height&&(t.thumbnailHeight=r.height),void 0!==r.time&&(t.thumbnailTime=r.time),r.fit&&(t.thumbnailFit=r.fit),r.format&&(t.thumbnailFormat=r.format)),n&&(n.width&&(t.animatedWidth=n.width),n.height&&(t.animatedHeight=n.height),void 0!==n.start&&(t.animatedStart=n.start),void 0!==n.end&&(t.animatedEnd=n.end),n.fps&&(t.animatedFps=n.fps),n.format&&(t.animatedFormat=n.format)),i&&i.format&&(t.storyboardFormat=i.format)}return e.expiration&&(t.expiration=e.expiration),t}class iU{#a;#u;constructor(e,t){this.#a=e,this.#u=t}list(e){let t={},r="/projects";return e?.includeMembers===!1&&(t.includeMembers="false"),e?.includeFeatures===!1&&(t.includeFeatures="false"),e?.organizationId&&(t.organizationId=e.organizationId),e?.onlyExplicitMembership&&(t.onlyExplicitMembership="true"),n3(this.#a,this.#u,{uri:r,query:t})}getById(e){return n3(this.#a,this.#u,{uri:`/projects/${e}`})}}class iL{#a;#u;constructor(e,t){this.#a=e,this.#u=t}list(e){let t={},r="/projects";return e?.includeMembers===!1&&(t.includeMembers="false"),e?.includeFeatures===!1&&(t.includeFeatures="false"),e?.organizationId&&(t.organizationId=e.organizationId),e?.onlyExplicitMembership&&(t.onlyExplicitMembership="true"),tc(n3(this.#a,this.#u,{uri:r,query:t}))}getById(e){return tc(n3(this.#a,this.#u,{uri:`/projects/${e}`}))}}let iB=rs("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789",8),iV=(e,t)=>t?rt(e,t):re(e);function iW(e,{releaseId:t,publishedId:r,document:n}){if(r&&n._id){let e=iV(r,t);return rL(e,n),e}if(n._id){let r=t7(n._id),i=t5(n._id);if(!r&&!i)throw Error(`\`${e}()\` requires a document with an \`_id\` that is a version or draft ID`);if(t){if(r)throw Error(`\`${e}()\` was called with a document ID (\`${n._id}\`) that is a draft ID, but a release ID (\`${t}\`) was also provided.`);let i=rr(n._id);if(i!==t)throw Error(`\`${e}()\` was called with a document ID (\`${n._id}\`) that is a version ID, but the release ID (\`${t}\`) does not match the document's version ID (\`${i}\`).`)}return n._id}if(r)return iV(r,t);throw Error(`\`${e}()\` requires either a publishedId or a document with an \`_id\``)}let iz=(e,t)=>{if("object"==typeof e&&null!==e&&("releaseId"in e||"metadata"in e)){let{releaseId:r=iB(),metadata:n={}}=e;return[r,n,t]}return[iB(),{},e]},iH=(e,t)=>{let[r,n,i]=iz(e,t);return{action:{actionType:"sanity.action.release.create",releaseId:r,metadata:{...n,releaseType:n.releaseType||"undecided"}},options:i}};class iG{#a;#u;constructor(e,t){this.#a=e,this.#u=t}get({releaseId:e},t){return nI(this.#a,this.#u,`_.releases.${e}`,t)}create(e,t){let{action:r,options:n}=iH(e,t),{releaseId:i,metadata:o}=r;return nz(this.#a,this.#u,r,n).pipe(to(e=>({...e,releaseId:i,metadata:o})))}edit({releaseId:e,patch:t},r){let n={actionType:"sanity.action.release.edit",releaseId:e,patch:t};return nz(this.#a,this.#u,n,r)}publish({releaseId:e},t){let r={actionType:"sanity.action.release.publish",releaseId:e};return nz(this.#a,this.#u,r,t)}archive({releaseId:e},t){let r={actionType:"sanity.action.release.archive",releaseId:e};return nz(this.#a,this.#u,r,t)}unarchive({releaseId:e},t){let r={actionType:"sanity.action.release.unarchive",releaseId:e};return nz(this.#a,this.#u,r,t)}schedule({releaseId:e,publishAt:t},r){let n={actionType:"sanity.action.release.schedule",releaseId:e,publishAt:t};return nz(this.#a,this.#u,n,r)}unschedule({releaseId:e},t){let r={actionType:"sanity.action.release.unschedule",releaseId:e};return nz(this.#a,this.#u,r,t)}delete({releaseId:e},t){let r={actionType:"sanity.action.release.delete",releaseId:e};return nz(this.#a,this.#u,r,t)}fetchDocuments({releaseId:e},t){return nN(this.#a,this.#u,e,t)}}class iJ{#a;#u;constructor(e,t){this.#a=e,this.#u=t}get({releaseId:e},t){return tc(nI(this.#a,this.#u,`_.releases.${e}`,t))}async create(e,t){let{action:r,options:n}=iH(e,t),{releaseId:i,metadata:o}=r;return{...await tc(nz(this.#a,this.#u,r,n)),releaseId:i,metadata:o}}edit({releaseId:e,patch:t},r){let n={actionType:"sanity.action.release.edit",releaseId:e,patch:t};return tc(nz(this.#a,this.#u,n,r))}publish({releaseId:e},t){let r={actionType:"sanity.action.release.publish",releaseId:e};return tc(nz(this.#a,this.#u,r,t))}archive({releaseId:e},t){let r={actionType:"sanity.action.release.archive",releaseId:e};return tc(nz(this.#a,this.#u,r,t))}unarchive({releaseId:e},t){let r={actionType:"sanity.action.release.unarchive",releaseId:e};return tc(nz(this.#a,this.#u,r,t))}schedule({releaseId:e,publishAt:t},r){let n={actionType:"sanity.action.release.schedule",releaseId:e,publishAt:t};return tc(nz(this.#a,this.#u,n,r))}unschedule({releaseId:e},t){let r={actionType:"sanity.action.release.unschedule",releaseId:e};return tc(nz(this.#a,this.#u,r,t))}delete({releaseId:e},t){let r={actionType:"sanity.action.release.delete",releaseId:e};return tc(nz(this.#a,this.#u,r,t))}fetchDocuments({releaseId:e},t){return tc(nN(this.#a,this.#u,e,t))}}class iY{#a;#u;constructor(e,t){this.#a=e,this.#u=t}getById(e){return n3(this.#a,this.#u,{uri:`/users/${e}`})}}class iK{#a;#u;
14constructor(e,t){this.#a=e,this.#u=t}getById(e){return tc(n3(this.#a,this.#u,{uri:`/users/${e}`}))}}class iQ{assets;datasets;live;mediaLibrary;projects;users;agent;releases;#c;#l;#u;listen=iE;constructor(e,t=r4){this.config(t),this.#l=e;let r=t._requestHandler;this.#u=r?(()=>{let n;return(i,o)=>{let s=i;return n||(n=new iX(e,{...t,_requestHandler:void 0})),r(s,t=>e(t,o),n)}})():e,this.assets=new iu(this,this.#u),this.datasets=new iC(this,this.#u),this.live=new iR(this),this.mediaLibrary={video:new i$(this,this.#u)},this.projects=new iU(this,this.#u),this.users=new iY(this,this.#u),this.agent={action:new is(this,this.#u)},this.releases=new iG(this,this.#u)}clone(){return new iQ(this.#l,this.config())}config(e){if(void 0===e)return{...this.#c};if(this.#c&&!1===this.#c.allowReconfigure)throw Error("Existing client instance cannot be reconfigured - use `withConfig(newConfig)` to return a new client");return this.#c=nt(e,this.#c||{}),this}withConfig(e){let t=this.config();return new iQ(this.#l,{...t,...e,stega:{...t.stega||{},..."boolean"==typeof e?.stega?{enabled:e.stega}:e?.stega||{}}})}fetch(e,t,r){return nP(this,this.#u,this.#c.stega,e,t,r)}getDocument(e,t){if(t?.includeAllVersions===!0)return nI(this,this.#u,e,{...t,includeAllVersions:!0});let r={signal:t?.signal,tag:t?.tag,releaseId:t?.releaseId,...t&&"includeAllVersions"in t?{includeAllVersions:!1}:{}};return nI(this,this.#u,e,r)}getDocuments(e,t){return nT(this,this.#u,e,t)}documentsExists(e,t){return nk(this,this.#u,e,t)}create(e,t){return nG(this,this.#u,e,"create",t)}createIfNotExists(e,t){return nM(this,this.#u,e,t)}createOrReplace(e,t){return nq(this,this.#u,e,t)}createVersion({document:e,publishedId:t,releaseId:r,baseId:n,ifBaseRevisionId:i},o){if(!e)return nF(this,this.#u,t,n,r,i,o);let s=iW("createVersion",{document:e,publishedId:t,releaseId:r}),a={...e,_id:s},u=t||rn(e._id);return nD(this,this.#u,a,u,o)}delete(e,t){return nU(this,this.#u,e,t)}discardVersion({releaseId:e,publishedId:t},r,n){let i=iV(t,e);return nL(this,this.#u,i,r,n)}replaceVersion({document:e,publishedId:t,releaseId:r},n){let i=iW("replaceVersion",{document:e,publishedId:t,releaseId:r}),o={...e,_id:i};return nB(this,this.#u,o,n)}unpublishVersion({releaseId:e,publishedId:t},r){let n=rt(t,e);return nV(this,this.#u,n,t,r)}mutate(e,t){return nW(this,this.#u,e,t)}patch(e,t){return new ny(e,t,this)}transaction(e){return new nw(e,this)}action(e,t){return nz(this,this.#u,e,t)}request(e){return n3(this,this.#u,e)}getUrl(e,t){return n6(this,e,t)}getDataUrl(e,t){return n2(this,e,t)}}class iX{assets;datasets;live;mediaLibrary;projects;users;agent;releases;observable;#c;#l;#u;listen=iE;constructor(e,t=r4){this.config(t),this.#l=e;let r=t._requestHandler;this.#u=r?(()=>{let n;return(i,o)=>{let s=i;return n||(n=new iX(e,{...t,_requestHandler:void 0})),r(s,t=>e(t,o),n)}})():e,this.assets=new ic(this,this.#u),this.datasets=new iP(this,this.#u),this.live=new iR(this),this.mediaLibrary={video:new ik(this,this.#u)},this.projects=new iL(this,this.#u),this.users=new iK(this,this.#u),this.agent={action:new ia(this,this.#u)},this.releases=new iJ(this,this.#u),this.observable=new iQ(e,t)}clone(){return new iX(this.#l,this.config())}config(e){if(void 0===e)return{...this.#c};if(this.#c&&!1===this.#c.allowReconfigure)throw Error("Existing client instance cannot be reconfigured - use `withConfig(newConfig)` to return a new client");return this.observable&&this.observable.config(e),this.#c=nt(e,this.#c||{}),this}withConfig(e){let t=this.config();return new iX(this.#l,{...t,...e,stega:{...t.stega||{},..."boolean"==typeof e?.stega?{enabled:e.stega}:e?.stega||{}}})}fetch(e,t,r){return tc(nP(this,this.#u,this.#c.stega,e,t,r))}getDocument(e,t){if(t?.includeAllVersions===!0)return tc(nI(this,this.#u,e,{...t,includeAllVersions:!0}));let r={signal:t?.signal,tag:t?.tag,releaseId:t?.releaseId,...t&&"includeAllVersions"in t?{includeAllVersions:!1}:{}};return tc(nI(this,this.#u,e,r))}getDocuments(e,t){return tc(nT(this,this.#u,e,t))}documentsExists(e,t){return tc(nk(this,this.#u,e,t))}create(e,t){return tc(nG(this,this.#u,e,"create",t))}createIfNotExists(e,t){return tc(nM(this,this.#u,e,t))}createOrReplace(e,t){return tc(nq(this,this.#u,e,t))}createVersion({document:e,publishedId:t,releaseId:r,baseId:n,ifBaseRevisionId:i},o){if(!e)return tk(nF(this,this.#u,t,n,r,i,o));let s=iW("createVersion",{document:e,publishedId:t,releaseId:r}),a={...e,_id:s},u=t||rn(e._id);return tk(nD(this,this.#u,a,u,o))}delete(e,t){return tc(nU(this,this.#u,e,t))}discardVersion({releaseId:e,publishedId:t},r,n){let i=iV(t,e);return tc(nL(this,this.#u,i,r,n))}replaceVersion({document:e,publishedId:t,releaseId:r},n){let i=iW("replaceVersion",{document:e,publishedId:t,releaseId:r}),o={...e,_id:i};return tk(nB(this,this.#u,o,n))}unpublishVersion({releaseId:e,publishedId:t},r){let n=rt(t,e);return tc(nV(this,this.#u,n,t,r))}mutate(e,t){return tc(nW(this,this.#u,e,t))}patch(e,t){return new ng(e,t,this)}transaction(e){return new nv(e,this)}action(e,t){return tc(nz(this,this.#u,e,t))}request(e){return tc(n3(this,this.#u,e))}dataRequest(e,t,r){return tc(nH(this,this.#u,e,t,r))}getUrl(e,t){return n6(this,e,t)}getDataUrl(e,t){return n2(this,e,t)}}function iZ(e){return function(t){return r3(),e(t)}}let i0=function(e,t){return{requester:rx(e),createClient:r=>{let n=rx(e,{ignoreWarnings:r.ignoreWarnings});return new t((e,t)=>
14(t||n)({maxRedirects:0,maxRetries:r.maxRetries,retryDelay:r.retryDelay,lineage:r.lineage,...e}),r)}}}([],iX),i1=(i0.requester,i0.createClient);iZ(i1)},6271:function(e,t,r){"use strict";let n;r.d(t,{WK:function(){return x}});let i="image-Tb9Ew8CXIwaY6R1kjMvI0uRR-2000x3000-jpg";function o(e){let[,t,r,n]=e.split("-");if(!t||!r||!n)throw Error(`Malformed asset _ref '${e}'. Expected an id like "${i}".`);let[o,s]=r.split("x"),a=+o,u=+s;if(!(isFinite(a)&&isFinite(u)))throw Error(`Malformed asset _ref '${e}'. Expected an id like "${i}".`);return{id:t,width:a,height:u,format:n}}let s=e=>{let t=e;return!!t&&"string"==typeof t._ref},a=e=>{let t=e;return!!t&&"string"==typeof t._id},u=e=>{let t=e;return!!t&&!!t.asset&&"string"==typeof t.asset.url},c=e=>{if("object"==typeof e&&null!==e){let t=e;return t._upload&&(!t.asset||!t.asset._ref)}return!1};function l(e){let t;if(!e)return null;if("string"==typeof e&&f(e))t={asset:{_ref:p(e)}};else if("string"==typeof e)t={asset:{_ref:e}};else if(s(e))t={asset:e};else if(a(e))t={asset:{_ref:e._id||""}};else if(u(e))t={asset:{_ref:p(e.asset.url)}};else{if("object"!=typeof e.asset)return null;t={...e}}let r=e;return r.crop&&(t.crop=r.crop),r.hotspot&&(t.hotspot=r.hotspot),h(t)}function f(e){return/^https?:\/\//.test(`${e}`)}function p(e){return`image-${e.split("/").slice(-1)[0]}`.replace(/\.([a-z]+)$/,"-$1")}function h(e){if(e.crop&&e.hotspot)return e;let t={...e};return t.crop||(t.crop={left:0,top:0,bottom:0,right:0}),t.hotspot||(t.hotspot={x:.5,y:.5,height:1,width:1}),t}let d=[["width","w"],["height","h"],["format","fm"],["download","dl"],["blur","blur"],["sharpen","sharp"],["invert","invert"],["orientation","or"],["minHeight","min-h"],["maxHeight","max-h"],["minWidth","min-w"],["maxWidth","max-w"],["quality","q"],["fit","fit"],["crop","crop"],["saturation","sat"],["auto","auto"],["dpr","dpr"],["pad","pad"],["frame","frame"]];function y(e){let t={...e||{}},r=t.source;delete t.source;let n=l(r);if(!n){if(r&&c(r))return"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR42mP8HwQACfsD/QNViZkAAAAASUVORK5CYII=";throw Error(`Unable to resolve image URL from source (${JSON.stringify(r)})`)}let i=o(n.asset._ref||n.asset._id||""),s=Math.round(n.crop.left*i.width),a=Math.round(n.crop.top*i.height),u={left:s,top:a,width:Math.round(i.width-n.crop.right*i.width-s),height:Math.round(i.height-n.crop.bottom*i.height-a)},f=n.hotspot.height*i.height/2,p=n.hotspot.width*i.width/2,h=n.hotspot.x*i.width,d=n.hotspot.y*i.height,y={left:h-p,top:d-f,right:h+p,bottom:d+f};return t.rect||t.focalPoint||t.ignoreImageParams||t.crop||(t={...t,...b({crop:u,hotspot:y},t)}),g({...t,asset:i})}function g(e){let t;let r=(e.baseUrl||"https://cdn.sanity.io").replace(/\/+$/,""),n=e.vanityName?`/${e.vanityName}`:"",i=`${e.asset.id}-${e.asset.width}x${e.asset.height}.${e.asset.format}${n}`;t=e.mediaLibraryId?`${r}/media-libraries/${e.mediaLibraryId}/images/${i}`:e.canvasId?`${r}/images/canvases/${e.canvasId}/${i}`:`${r}/images/${e.projectId}/${e.dataset}/${i}`;let o=[];if(e.rect){let{left:t,top:r,width:n,height:i}=e.rect;(0!==t||0!==r||i!==e.asset.height||n!==e.asset.width)&&o.push(`rect=${t},${r},${n},${i}`)}e.bg&&o.push(`bg=${e.bg}`),e.focalPoint&&(o.push(`fp-x=${e.focalPoint.x}`),o.push(`fp-y=${e.focalPoint.y}`));let s=[e.flipHorizontal&&"h",e.flipVertical&&"v"].filter(Boolean).join("");return s&&o.push(`flip=${s}`),d.forEach(t=>{let[r,n]=t;"u">typeof e[r]?o.push(`${n}=${encodeURIComponent(e[r])}`):"u">typeof e[n]&&o.push(`${n}=${encodeURIComponent(e[n])}`)}),0===o.length?t:`${t}?${o.join("&")}`}function b(e,t){let r;let n=t.width,i=t.height;if(!(n&&i))return{width:n,height:i,rect:e.crop};let o=e.crop,s=e.hotspot,a=n/i;if(o.width/o.height>a){let e=Math.round(o.height),t=Math.round(e*a),n=Math.max(0,Math.round(o.top)),i=Math.max(0,Math.round(Math.round((s.right-s.left)/2+s.left)-t/2));i<o.left?i=o.left:i+t>o.left+o.width&&(i=o.left+o.width-t),r={left:i,top:n,width:t,height:e}}else{let e=o.width,t=Math.round(e/a),n=Math.max(0,Math.round(o.left)),i=Math.max(0,Math.round(Math.round((s.bottom-s.top)/2+s.top)-t/2));i<o.top?i=o.top:i+t>o.top+o.height&&(i=o.top+o.height-t),r={left:n,top:i,width:e,height:t}}return{width:n,height:i,rect:r}}let m=["clip","crop","fill","fillmax","max","scale","min"],v=["top","bottom","left","right","center","focalpoint","entropy"],w=["format"];function _(e){return!!e&&"config"in e&&"function"==typeof e.config}function E(e){return!!e&&"clientConfig"in e&&"object"==typeof e.clientConfig}function S(e){let{apiHost:t,projectId:r,dataset:n}=e,i={baseUrl:(t||"https://api.sanity.io").replace(/^https:\/\/api\./,"https://cdn.")},o=e.resource??e["~experimental_resource"];if(o?.type==="media-library"){if("string"!=typeof o.id||0===o.id.length)throw Error('Media library clients must include an id in "resource"');return{...i,mediaLibraryId:o.id}}if(o?.type==="canvas"){if("string"!=typeof o.id||0===o.id.length)throw Error('Canvas clients must include an id in "resource"');return{...i,canvasId:o.id}}if(o?.type==="dataset"){if("string"!=typeof o.id||0===o.id.length)throw Error('Dataset clients must include an id in "resource"');let[e,t]=o.id.split(".");if(!e||!t)throw Error('Dataset resource id must be in the format "projectId.dataset", got: '+o.id);return{...i,projectId:e,dataset:t}}return{...i,projectId:r,dataset:n}}function A(e){for(let t of d){let[r,n]=t;if(e===r||e===n)return r}return e}function O(e){return _(e)?S(e.config()):E(e)?S(e.clientConfig):e||{}}function R(e,t){return new e(null,O(t))}function x(e){return R(C,e)}function j(e,t){let r=t.baseUrl||e.baseUrl,n={baseUrl:r};for(let e in t)t.hasOwnProperty(e)&&(n[A(e)]=t[e]);return{baseUrl:r,...n}}class C{options;constructor(e,t){this.options=e?{...e.options||{},...t||{}}:{...t||{}}}withOptions(e){return new C(this,j(this.options,e))}image(e){return this.withOptions({source:e})}dataset(e){return this.withOptions({dataset:e})}projectId(e){return this.withOptions({projectId:e})}withClient(e){let t=O(e),r={...this.options};return delete r.baseUrl,delete r.projectId,delete r.dataset,delete r.mediaLibraryId,delete r.canvasId,new C(null,{...t,...r})}bg(e){return this.withOptions({bg:e})}dpr(e){return this.withOptions(e&&1!==e?{dpr:e}:{})}width(e){return this.withOptions({width:e})}height(e){return this.withOptions({height:e})}focalPoint(e,t){return this.withOptions({focalPoint:{x:e,y:t}})}maxWidth(e){return this.withOptions({maxWidth:e})}minWidth(e){return this.withOptions({minWidth:e})}maxHeight(e){return this.withOptions({maxHeight:e})}minHeight(e){return this.withOptions({minHeight:e})}size(e,t){return this.withOptions({width:e,height:t})}blur(e){return this.withOptions({blur:e})}
14sharpen(e){return this.withOptions({sharpen:e})}rect(e,t,r,n){return this.withOptions({rect:{left:e,top:t,width:r,height:n}})}format(e){return this.withOptions({format:e})}invert(e){return this.withOptions({invert:e})}orientation(e){return this.withOptions({orientation:e})}quality(e){return this.withOptions({quality:e})}forceDownload(e){return this.withOptions({download:e})}flipHorizontal(){return this.withOptions({flipHorizontal:!0})}flipVertical(){return this.withOptions({flipVertical:!0})}ignoreImageParams(){return this.withOptions({ignoreImageParams:!0})}fit(e){if(-1===m.indexOf(e))throw Error(`Invalid fit mode "${e}"`);return this.withOptions({fit:e})}crop(e){if(-1===v.indexOf(e))throw Error(`Invalid crop mode "${e}"`);return this.withOptions({crop:e})}saturation(e){return this.withOptions({saturation:e})}auto(e){if(-1===w.indexOf(e))throw Error(`Invalid auto mode "${e}"`);return this.withOptions({auto:e})}pad(e){return this.withOptions({pad:e})}vanityName(e){return this.withOptions({vanityName:e})}frame(e){if(1!==e)throw Error(`Invalid frame value "${e}"`);return this.withOptions({frame:e})}url(){return y(this.options)}toString(){return this.url()}}n=["The default export of @sanity/image-url has been deprecated. Use the named export `createImageUrlBuilder` instead."],function e(e){let t=!1,r;return(...n)=>(t||(r=e(...n),t=!0),r)}((...e)=>{console.warn(n.join(" "),...e)})}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.