(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4657],{54177:function(t,e){"use strict";e.byteLength=function(t){var e=a(t),r=e[0],n=e[1];return(r+n)*3/4-n},e.toByteArray=function(t){var e,r,i=a(t),s=i[0],u=i[1],c=new o((s+u)*3/4-u),f=0,l=u>0?s-4:s;for(r=0;r>16&255,c[f++]=e>>8&255,c[f++]=255&e;return 2===u&&(e=n[t.charCodeAt(r)]<<2|n[t.charCodeAt(r+1)]>>4,c[f++]=255&e),1===u&&(e=n[t.charCodeAt(r)]<<10|n[t.charCodeAt(r+1)]<<4|n[t.charCodeAt(r+2)]>>2,c[f++]=e>>8&255,c[f++]=255&e),c},e.fromByteArray=function(t){for(var e,n=t.length,o=n%3,i=[],s=0,u=n-o;s>18&63]+r[o>>12&63]+r[o>>6&63]+r[63&o]);return i.join("")}(t,s,s+16383>u?u:s+16383));return 1===o?i.push(r[(e=t[n-1])>>2]+r[e<<4&63]+"=="):2===o&&i.push(r[(e=(t[n-2]<<8)+t[n-1])>>10]+r[e>>4&63]+r[e<<2&63]+"="),i.join("")};for(var r=[],n=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,u=i.length;s0)throw Error("Invalid string. Length must be a multiple of 4");var r=t.indexOf("=");-1===r&&(r=e);var n=r===e?0:4-r%4;return[r,n]}n["-".charCodeAt(0)]=62,n["_".charCodeAt(0)]=63},87376:function(t,e,r){"use strict";var n=r(54177),o=r(94045),i="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;function s(t){if(t>2147483647)throw RangeError('The value "'+t+'" is invalid for option "size"');var e=new Uint8Array(t);return Object.setPrototypeOf(e,u.prototype),e}function u(t,e,r){if("number"==typeof t){if("string"==typeof e)throw TypeError('The "string" argument must be of type string. Received type number');return f(t)}return a(t,e,r)}function a(t,e,r){if("string"==typeof t)return function(t,e){if(("string"!=typeof e||""===e)&&(e="utf8"),!u.isEncoding(e))throw TypeError("Unknown encoding: "+e);var r=0|d(t,e),n=s(r),o=n.write(t,e);return o!==r&&(n=n.slice(0,o)),n}(t,e);if(ArrayBuffer.isView(t))return function(t){if(S(t,Uint8Array)){var e=new Uint8Array(t);return h(e.buffer,e.byteOffset,e.byteLength)}return l(t)}(t);if(null==t)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t);if(S(t,ArrayBuffer)||t&&S(t.buffer,ArrayBuffer)||"undefined"!=typeof SharedArrayBuffer&&(S(t,SharedArrayBuffer)||t&&S(t.buffer,SharedArrayBuffer)))return h(t,e,r);if("number"==typeof t)throw TypeError('The "value" argument must not be of type number. Received type number');var n=t.valueOf&&t.valueOf();if(null!=n&&n!==t)return u.from(n,e,r);var o=function(t){if(u.isBuffer(t)){var e,r=0|p(t.length),n=s(r);return 0===n.length||t.copy(n,0,0,r),n}return void 0!==t.length?"number"!=typeof t.length||(e=t.length)!=e?s(0):l(t):"Buffer"===t.type&&Array.isArray(t.data)?l(t.data):void 0}(t);if(o)return o;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof t[Symbol.toPrimitive])return u.from(t[Symbol.toPrimitive]("string"),e,r);throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t)}function c(t){if("number"!=typeof t)throw TypeError('"size" argument must be of type number');if(t<0)throw RangeError('The value "'+t+'" is invalid for option "size"')}function f(t){return c(t),s(t<0?0:0|p(t))}function l(t){for(var e=t.length<0?0:0|p(t.length),r=s(e),n=0;n=2147483647)throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x7fffffff bytes");return 0|t}function d(t,e){if(u.isBuffer(t))return t.length;if(ArrayBuffer.isView(t)||S(t,ArrayBuffer))return t.byteLength;if("string"!=typeof t)throw TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof t);var r=t.length,n=arguments.length>2&&!0===arguments[2];if(!n&&0===r)return 0;for(var o=!1;;)switch(e){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return O(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return T(t).length;default:if(o)return n?-1:O(t).length;e=(""+e).toLowerCase(),o=!0}}function y(t,e,r){var o,i,s=!1;if((void 0===e||e<0)&&(e=0),e>this.length||((void 0===r||r>this.length)&&(r=this.length),r<=0||(r>>>=0)<=(e>>>=0)))return"";for(t||(t="utf8");;)switch(t){case"hex":return function(t,e,r){var n=t.length;(!e||e<0)&&(e=0),(!r||r<0||r>n)&&(r=n);for(var o="",i=e;i2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),(i=r=+r)!=i&&(r=o?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(o)return -1;r=t.length-1}else if(r<0){if(!o)return -1;r=0}if("string"==typeof e&&(e=u.from(e,n)),u.isBuffer(e))return 0===e.length?-1:b(t,e,r,n,o);if("number"==typeof e)return(e&=255,"function"==typeof Uint8Array.prototype.indexOf)?o?Uint8Array.prototype.indexOf.call(t,e,r):Uint8Array.prototype.lastIndexOf.call(t,e,r):b(t,[e],r,n,o);throw TypeError("val must be string, number or Buffer")}function b(t,e,r,n,o){var i,s=1,u=t.length,a=e.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(t.length<2||e.length<2)return -1;s=2,u/=2,a/=2,r/=2}function c(t,e){return 1===s?t[e]:t.readUInt16BE(e*s)}if(o){var f=-1;for(i=r;iu&&(r=u-a),i=r;i>=0;i--){for(var l=!0,h=0;h239?4:c>223?3:c>191?2:1;if(o+l<=r)switch(l){case 1:c<128&&(f=c);break;case 2:(192&(i=t[o+1]))==128&&(a=(31&c)<<6|63&i)>127&&(f=a);break;case 3:i=t[o+1],s=t[o+2],(192&i)==128&&(192&s)==128&&(a=(15&c)<<12|(63&i)<<6|63&s)>2047&&(a<55296||a>57343)&&(f=a);break;case 4:i=t[o+1],s=t[o+2],u=t[o+3],(192&i)==128&&(192&s)==128&&(192&u)==128&&(a=(15&c)<<18|(63&i)<<12|(63&s)<<6|63&u)>65535&&a<1114112&&(f=a)}null===f?(f=65533,l=1):f>65535&&(f-=65536,n.push(f>>>10&1023|55296),f=56320|1023&f),n.push(f),o+=l}return function(t){var e=t.length;if(e<=4096)return String.fromCharCode.apply(String,t);for(var r="",n=0;nr)throw RangeError("Trying to access beyond buffer length")}function E(t,e,r,n,o,i){if(!u.isBuffer(t))throw TypeError('"buffer" argument must be a Buffer instance');if(e>o||et.length)throw RangeError("Index out of range")}function C(t,e,r,n,o,i){if(r+n>t.length||r<0)throw RangeError("Index out of range")}function A(t,e,r,n,i){return e=+e,r>>>=0,i||C(t,e,r,4,34028234663852886e22,-34028234663852886e22),o.write(t,e,r,n,23,4),r+4}function x(t,e,r,n,i){return e=+e,r>>>=0,i||C(t,e,r,8,17976931348623157e292,-17976931348623157e292),o.write(t,e,r,n,52,8),r+8}e.lW=u,e.h2=50,u.TYPED_ARRAY_SUPPORT=function(){try{var t=new Uint8Array(1),e={foo:function(){return 42}};return Object.setPrototypeOf(e,Uint8Array.prototype),Object.setPrototypeOf(t,e),42===t.foo()}catch(t){return!1}}(),u.TYPED_ARRAY_SUPPORT||"undefined"==typeof console||"function"!=typeof console.error||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(u.prototype,"parent",{enumerable:!0,get:function(){if(u.isBuffer(this))return this.buffer}}),Object.defineProperty(u.prototype,"offset",{enumerable:!0,get:function(){if(u.isBuffer(this))return this.byteOffset}}),u.poolSize=8192,u.from=function(t,e,r){return a(t,e,r)},Object.setPrototypeOf(u.prototype,Uint8Array.prototype),Object.setPrototypeOf(u,Uint8Array),u.alloc=function(t,e,r){return(c(t),t<=0)?s(t):void 0!==e?"string"==typeof r?s(t).fill(e,r):s(t).fill(e):s(t)},u.allocUnsafe=function(t){return f(t)},u.allocUnsafeSlow=function(t){return f(t)},u.isBuffer=function(t){return null!=t&&!0===t._isBuffer&&t!==u.prototype},u.compare=function(t,e){if(S(t,Uint8Array)&&(t=u.from(t,t.offset,t.byteLength)),S(e,Uint8Array)&&(e=u.from(e,e.offset,e.byteLength)),!u.isBuffer(t)||!u.isBuffer(e))throw TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(t===e)return 0;for(var r=t.length,n=e.length,o=0,i=Math.min(r,n);on.length?u.from(i).copy(n,o):Uint8Array.prototype.set.call(n,i,o);else if(u.isBuffer(i))i.copy(n,o);else throw TypeError('"list" argument must be an Array of Buffers');o+=i.length}return n},u.byteLength=d,u.prototype._isBuffer=!0,u.prototype.swap16=function(){var t=this.length;if(t%2!=0)throw RangeError("Buffer size must be a multiple of 16-bits");for(var e=0;er&&(t+=" ... "),""},i&&(u.prototype[i]=u.prototype.inspect),u.prototype.compare=function(t,e,r,n,o){if(S(t,Uint8Array)&&(t=u.from(t,t.offset,t.byteLength)),!u.isBuffer(t))throw TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof t);if(void 0===e&&(e=0),void 0===r&&(r=t?t.length:0),void 0===n&&(n=0),void 0===o&&(o=this.length),e<0||r>t.length||n<0||o>this.length)throw RangeError("out of range index");if(n>=o&&e>=r)return 0;if(n>=o)return -1;if(e>=r)return 1;if(e>>>=0,r>>>=0,n>>>=0,o>>>=0,this===t)return 0;for(var i=o-n,s=r-e,a=Math.min(i,s),c=this.slice(n,o),f=t.slice(e,r),l=0;l>>=0,isFinite(r)?(r>>>=0,void 0===n&&(n="utf8")):(n=r,r=void 0);else throw Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var o,i,s,u,a,c,f,l,h=this.length-e;if((void 0===r||r>h)&&(r=h),t.length>0&&(r<0||e<0)||e>this.length)throw RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var p=!1;;)switch(n){case"hex":return function(t,e,r,n){r=Number(r)||0;var o=t.length-r;n?(n=Number(n))>o&&(n=o):n=o;var i=e.length;n>i/2&&(n=i/2);for(var s=0;s>8,o.push(r%256),o.push(n);return o}(t,this.length-f),this,f,l);default:if(p)throw TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),p=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}},u.prototype.slice=function(t,e){var r=this.length;t=~~t,e=void 0===e?r:~~e,t<0?(t+=r)<0&&(t=0):t>r&&(t=r),e<0?(e+=r)<0&&(e=0):e>r&&(e=r),e>>=0,e>>>=0,r||w(t,e,this.length);for(var n=this[t],o=1,i=0;++i>>=0,e>>>=0,r||w(t,e,this.length);for(var n=this[t+--e],o=1;e>0&&(o*=256);)n+=this[t+--e]*o;return n},u.prototype.readUint8=u.prototype.readUInt8=function(t,e){return t>>>=0,e||w(t,1,this.length),this[t]},u.prototype.readUint16LE=u.prototype.readUInt16LE=function(t,e){return t>>>=0,e||w(t,2,this.length),this[t]|this[t+1]<<8},u.prototype.readUint16BE=u.prototype.readUInt16BE=function(t,e){return t>>>=0,e||w(t,2,this.length),this[t]<<8|this[t+1]},u.prototype.readUint32LE=u.prototype.readUInt32LE=function(t,e){return t>>>=0,e||w(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+16777216*this[t+3]},u.prototype.readUint32BE=u.prototype.readUInt32BE=function(t,e){return t>>>=0,e||w(t,4,this.length),16777216*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},u.prototype.readIntLE=function(t,e,r){t>>>=0,e>>>=0,r||w(t,e,this.length);for(var n=this[t],o=1,i=0;++i=(o*=128)&&(n-=Math.pow(2,8*e)),n},u.prototype.readIntBE=function(t,e,r){t>>>=0,e>>>=0,r||w(t,e,this.length);for(var n=e,o=1,i=this[t+--n];n>0&&(o*=256);)i+=this[t+--n]*o;return i>=(o*=128)&&(i-=Math.pow(2,8*e)),i},u.prototype.readInt8=function(t,e){return(t>>>=0,e||w(t,1,this.length),128&this[t])?-((255-this[t]+1)*1):this[t]},u.prototype.readInt16LE=function(t,e){t>>>=0,e||w(t,2,this.length);var r=this[t]|this[t+1]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt16BE=function(t,e){t>>>=0,e||w(t,2,this.length);var r=this[t+1]|this[t]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt32LE=function(t,e){return t>>>=0,e||w(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},u.prototype.readInt32BE=function(t,e){return t>>>=0,e||w(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},u.prototype.readFloatLE=function(t,e){return t>>>=0,e||w(t,4,this.length),o.read(this,t,!0,23,4)},u.prototype.readFloatBE=function(t,e){return t>>>=0,e||w(t,4,this.length),o.read(this,t,!1,23,4)},u.prototype.readDoubleLE=function(t,e){return t>>>=0,e||w(t,8,this.length),o.read(this,t,!0,52,8)},u.prototype.readDoubleBE=function(t,e){return t>>>=0,e||w(t,8,this.length),o.read(this,t,!1,52,8)},u.prototype.writeUintLE=u.prototype.writeUIntLE=function(t,e,r,n){if(t=+t,e>>>=0,r>>>=0,!n){var o=Math.pow(2,8*r)-1;E(this,t,e,r,o,0)}var i=1,s=0;for(this[e]=255&t;++s>>=0,r>>>=0,!n){var o=Math.pow(2,8*r)-1;E(this,t,e,r,o,0)}var i=r-1,s=1;for(this[e+i]=255&t;--i>=0&&(s*=256);)this[e+i]=t/s&255;return e+r},u.prototype.writeUint8=u.prototype.writeUInt8=function(t,e,r){return t=+t,e>>>=0,r||E(this,t,e,1,255,0),this[e]=255&t,e+1},u.prototype.writeUint16LE=u.prototype.writeUInt16LE=function(t,e,r){return t=+t,e>>>=0,r||E(this,t,e,2,65535,0),this[e]=255&t,this[e+1]=t>>>8,e+2},u.prototype.writeUint16BE=u.prototype.writeUInt16BE=function(t,e,r){return t=+t,e>>>=0,r||E(this,t,e,2,65535,0),this[e]=t>>>8,this[e+1]=255&t,e+2},u.prototype.writeUint32LE=u.prototype.writeUInt32LE=function(t,e,r){return t=+t,e>>>=0,r||E(this,t,e,4,4294967295,0),this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=255&t,e+4},u.prototype.writeUint32BE=u.prototype.writeUInt32BE=function(t,e,r){return t=+t,e>>>=0,r||E(this,t,e,4,4294967295,0),this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t,e+4},u.prototype.writeIntLE=function(t,e,r,n){if(t=+t,e>>>=0,!n){var o=Math.pow(2,8*r-1);E(this,t,e,r,o-1,-o)}var i=0,s=1,u=0;for(this[e]=255&t;++i>0)-u&255;return e+r},u.prototype.writeIntBE=function(t,e,r,n){if(t=+t,e>>>=0,!n){var o=Math.pow(2,8*r-1);E(this,t,e,r,o-1,-o)}var i=r-1,s=1,u=0;for(this[e+i]=255&t;--i>=0&&(s*=256);)t<0&&0===u&&0!==this[e+i+1]&&(u=1),this[e+i]=(t/s>>0)-u&255;return e+r},u.prototype.writeInt8=function(t,e,r){return t=+t,e>>>=0,r||E(this,t,e,1,127,-128),t<0&&(t=255+t+1),this[e]=255&t,e+1},u.prototype.writeInt16LE=function(t,e,r){return t=+t,e>>>=0,r||E(this,t,e,2,32767,-32768),this[e]=255&t,this[e+1]=t>>>8,e+2},u.prototype.writeInt16BE=function(t,e,r){return t=+t,e>>>=0,r||E(this,t,e,2,32767,-32768),this[e]=t>>>8,this[e+1]=255&t,e+2},u.prototype.writeInt32LE=function(t,e,r){return t=+t,e>>>=0,r||E(this,t,e,4,2147483647,-2147483648),this[e]=255&t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24,e+4},u.prototype.writeInt32BE=function(t,e,r){return t=+t,e>>>=0,r||E(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t,e+4},u.prototype.writeFloatLE=function(t,e,r){return A(this,t,e,!0,r)},u.prototype.writeFloatBE=function(t,e,r){return A(this,t,e,!1,r)},u.prototype.writeDoubleLE=function(t,e,r){return x(this,t,e,!0,r)},u.prototype.writeDoubleBE=function(t,e,r){return x(this,t,e,!1,r)},u.prototype.copy=function(t,e,r,n){if(!u.isBuffer(t))throw TypeError("argument should be a Buffer");if(r||(r=0),n||0===n||(n=this.length),e>=t.length&&(e=t.length),e||(e=0),n>0&&n=this.length)throw RangeError("Index out of range");if(n<0)throw RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),t.length-e>>=0,r=void 0===r?this.length:r>>>0,t||(t=0),"number"==typeof t)for(o=e;o55295&&r<57344){if(!o){if(r>56319||s+1===n){(e-=3)>-1&&i.push(239,191,189);continue}o=r;continue}if(r<56320){(e-=3)>-1&&i.push(239,191,189),o=r;continue}r=(o-55296<<10|r-56320)+65536}else o&&(e-=3)>-1&&i.push(239,191,189);if(o=null,r<128){if((e-=1)<0)break;i.push(r)}else if(r<2048){if((e-=2)<0)break;i.push(r>>6|192,63&r|128)}else if(r<65536){if((e-=3)<0)break;i.push(r>>12|224,r>>6&63|128,63&r|128)}else if(r<1114112){if((e-=4)<0)break;i.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}else throw Error("Invalid code point")}return i}function T(t){return n.toByteArray(function(t){if((t=(t=t.split("=")[0]).trim().replace(R,"")).length<2)return"";for(;t.length%4!=0;)t+="=";return t}(t))}function I(t,e,r,n){for(var o=0;o=e.length)&&!(o>=t.length);++o)e[o+r]=t[o];return o}function S(t,e){return t instanceof e||null!=t&&null!=t.constructor&&null!=t.constructor.name&&t.constructor.name===e.name}var j=function(){for(var t="0123456789abcdef",e=Array(256),r=0;r<16;++r)for(var n=16*r,o=0;o<16;++o)e[n+o]=t[r]+t[o];return e}()},94045:function(t,e){e.read=function(t,e,r,n,o){var i,s,u=8*o-n-1,a=(1<>1,f=-7,l=r?o-1:0,h=r?-1:1,p=t[e+l];for(l+=h,i=p&(1<<-f)-1,p>>=-f,f+=u;f>0;i=256*i+t[e+l],l+=h,f-=8);for(s=i&(1<<-f)-1,i>>=-f,f+=n;f>0;s=256*s+t[e+l],l+=h,f-=8);if(0===i)i=1-c;else{if(i===a)return s?NaN:1/0*(p?-1:1);s+=Math.pow(2,n),i-=c}return(p?-1:1)*s*Math.pow(2,i-n)},e.write=function(t,e,r,n,o,i){var s,u,a,c=8*i-o-1,f=(1<>1,h=23===o?5960464477539062e-23:0,p=n?0:i-1,d=n?1:-1,y=e<0||0===e&&1/e<0?1:0;for(isNaN(e=Math.abs(e))||e===1/0?(u=isNaN(e)?1:0,s=f):(s=Math.floor(Math.log(e)/Math.LN2),e*(a=Math.pow(2,-s))<1&&(s--,a*=2),s+l>=1?e+=h/a:e+=h*Math.pow(2,1-l),e*a>=2&&(s++,a/=2),s+l>=f?(u=0,s=f):s+l>=1?(u=(e*a-1)*Math.pow(2,o),s+=l):(u=e*Math.pow(2,l-1)*Math.pow(2,o),s=0));o>=8;t[r+p]=255&u,p+=d,u/=256,o-=8);for(s=s<0;t[r+p]=255&s,p+=d,s/=256,c-=8);t[r+p-d]|=128*y}},80029:function(t,e,r){"use strict";r.d(e,{y:function(){return f}});var n=r(33561),o=r(33957),i=r(56927),s=r(40306),u=r(45340),a=r(68255),c=r(19049),f=function(){function t(t){t&&(this._subscribe=t)}return t.prototype.lift=function(e){var r=new t;return r.source=this,r.operator=e,r},t.prototype.subscribe=function(t,e,r){var i,s=this,u=(i=t)&&i instanceof n.Lv||i&&(0,a.m)(i.next)&&(0,a.m)(i.error)&&(0,a.m)(i.complete)&&(0,o.Nn)(i)?t:new n.Hp(t,e,r);return(0,c.x)(function(){var t=s.operator,e=s.source;u.add(t?t.call(u,e):e?s._subscribe(u):s._trySubscribe(u))}),u},t.prototype._trySubscribe=function(t){try{return this._subscribe(t)}catch(e){t.error(e)}},t.prototype.forEach=function(t,e){var r=this;return new(e=l(e))(function(e,o){var i=new n.Hp({next:function(e){try{t(e)}catch(t){o(t),i.unsubscribe()}},error:o,complete:e});r.subscribe(i)})},t.prototype._subscribe=function(t){var e;return null===(e=this.source)||void 0===e?void 0:e.subscribe(t)},t.prototype[i.L]=function(){return this},t.prototype.pipe=function(){for(var t=[],e=0;e1)for(var r=1;r{let e=t.charCodeAt(0);if(e>255)throw Error(`Only ASCII edit info can be encoded. Error attempting to encode ${n} on character ${t} (${e})`);return Array.from(e.toString(4).padStart(4,"0")).map(t=>String.fromCodePoint(o[t])).join("")}).join("")}`}`}Object.fromEntries(Object.entries(o).map(t=>t.reverse())),Object.fromEntries(Object.entries(n).map(t=>t.reverse()));var u=`${Object.values(n).map(t=>`\\u{${t.toString(16)}}`).join("")}`,a=RegExp(`[${u}]{4,}`,"gu");function c(t){var e,r;return t&&JSON.parse({cleaned:(e=JSON.stringify(t)).replace(a,""),encoded:(null==(r=e.match(a))?void 0:r[0])||""}.cleaned)}},32504:function(t,e,r){"use strict";r.d(e,{Ap:function(){return tt},eI:function(){return ed}});let n=!(typeof navigator>"u")&&"ReactNative"===navigator.product,o={timeout:n?6e4:12e4},i=function(t){let e={...o,..."string"==typeof t?{url:t}:t};if(e.timeout=function t(e){if(!1===e||0===e)return!1;if(e.connect||e.socket)return e;let r=Number(e);return isNaN(r)?t(o.timeout):{connect:r,socket:r}}(e.timeout),e.query){let{url:t,searchParams:r}=function(t){let e=t.indexOf("?");if(-1===e)return{url:t,searchParams:new URLSearchParams};let r=t.slice(0,e),o=t.slice(e+1);if(!n)return{url:r,searchParams:new URLSearchParams(o)};if("function"!=typeof decodeURIComponent)throw Error("Broken `URLSearchParams` implementation, and `decodeURIComponent` is not defined");let i=new URLSearchParams;for(let t of o.split("&")){let[e,r]=t.split("=");e&&i.append(s(e),s(r||""))}return{url:r,searchParams:i}}(e.url);for(let[n,o]of Object.entries(e.query)){if(void 0!==o){if(Array.isArray(o))for(let t of o)r.append(n,t);else r.append(n,o)}let i=r.toString();i&&(e.url=`${t}?${i}`)}}return e.method=e.body&&!e.method?"POST":(e.method||"GET").toUpperCase(),e};function s(t){return decodeURIComponent(t.replace(/\+/g," "))}let u=/^https?:\/\//i,a=function(t){if(!u.test(t.url))throw Error(`"${t.url}" is not a valid URL`)};function c(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}let f=["request","response","progress","error","abort"],l=["processOptions","validateOptions","interceptRequest","finalizeOptions","onRequest","onResponse","onError","onReturn","onHeaders"];var h=function(t){return t.replace(/^\s+|\s+$/g,"")},p=c(function(t){if(!t)return{};for(var e,r={},n=h(t).split("\n"),o=0;o"u"?r[u]=a:(e=r[u],"[object Array]"===Object.prototype.toString.call(e)?r[u].push(a):r[u]=[r[u],a])}return r});class d{onabort;onerror;onreadystatechange;ontimeout;readyState=0;response;responseText="";responseType="";status;statusText;withCredentials;#t;#e;#r;#n={};#o;#i={};#s;open(t,e,r){this.#t=t,this.#e=e,this.#r="",this.readyState=1,this.onreadystatechange?.(),this.#o=void 0}abort(){this.#o&&this.#o.abort()}getAllResponseHeaders(){return this.#r}setRequestHeader(t,e){this.#n[t]=e}setInit(t,e=!0){this.#i=t,this.#s=e}send(t){let e="arraybuffer"!==this.responseType,r={...this.#i,method:this.#t,headers:this.#n,body:t};"function"==typeof AbortController&&this.#s&&(this.#o=new AbortController,"u">typeof EventTarget&&this.#o.signal instanceof EventTarget&&(r.signal=this.#o.signal)),"u">typeof document&&(r.credentials=this.withCredentials?"include":"omit"),fetch(this.#e,r).then(t=>(t.headers.forEach((t,e)=>{this.#r+=`${e}: ${t}\r `}),this.status=t.status,this.statusText=t.statusText,this.readyState=3,this.onreadystatechange?.(),e?t.text():t.arrayBuffer())).then(t=>{"string"==typeof t?this.responseText=t:this.response=t,this.readyState=4,this.onreadystatechange?.()}).catch(t=>{"AbortError"!==t.name?this.onerror?.(t):this.onabort?.()})}}let y="function"==typeof XMLHttpRequest?"xhr":"fetch",g="xhr"===y?XMLHttpRequest:d,m=(t,e)=>{let r=t.options,n=t.applyMiddleware("finalizeOptions",r),o={},i=t.applyMiddleware("interceptRequest",void 0,{adapter:y,context:t});if(i){let t=setTimeout(e,0,null,i);return{abort:()=>clearTimeout(t)}}let s=new g;s instanceof d&&"object"==typeof n.fetch&&s.setInit(n.fetch,n.useAbortSignal??!0);let u=n.headers,a=n.timeout,c=!1,f=!1,l=!1;if(s.onerror=t=>{b(s instanceof d?t instanceof Error?t:Error(`Request error while attempting to reach is ${n.url}`,{cause:t}):Error(`Request error while attempting to reach is ${n.url}${t.lengthComputable?`(${t.loaded} of ${t.total} bytes transferred)`:""}`))},s.ontimeout=t=>{b(Error(`Request timeout while attempting to reach ${n.url}${t.lengthComputable?`(${t.loaded} of ${t.total} bytes transferred)`:""}`))},s.onabort=()=>{m(!0),c=!0},s.onreadystatechange=()=>{a&&(m(),o.socket=setTimeout(()=>h("ESOCKETTIMEDOUT"),a.socket)),c||4!==s.readyState||0===s.status||function(){if(!(c||f||l)){if(0===s.status)return void b(Error("Unknown XHR error"));m(),f=!0,e(null,{body:s.response||(""===s.responseType||"text"===s.responseType?s.responseText:""),url:n.url,method:n.method,headers:p(s.getAllResponseHeaders()),statusCode:s.status,statusMessage:s.statusText})}}()},s.open(n.method,n.url,!0),s.withCredentials=!!n.withCredentials,u&&s.setRequestHeader)for(let t in u)u.hasOwnProperty(t)&&s.setRequestHeader(t,u[t]);return n.rawBody&&(s.responseType="arraybuffer"),t.applyMiddleware("onRequest",{options:n,adapter:y,request:s,context:t}),s.send(n.body||null),a&&(o.connect=setTimeout(()=>h("ETIMEDOUT"),a.connect)),{abort:function(){c=!0,s&&s.abort()}};function h(e){l=!0,s.abort();let r=Error("ESOCKETTIMEDOUT"===e?`Socket timed out on request to ${n.url}`:`Connection timed out on request to ${n.url}`);r.code=e,t.channels.error.publish(r)}function m(t){(t||c||s.readyState>=2&&o.connect)&&clearTimeout(o.connect),o.socket&&clearTimeout(o.socket)}function b(t){if(f)return;m(!0),f=!0,s=null;let r=t||Error(`Network error while attempting to reach ${n.url}`);r.isNetworkError=!0,r.request=n,e(r)}},b=(t=[],e=m)=>(function t(e,r){let n=[],o=l.reduce((t,e)=>(t[e]=t[e]||[],t),{processOptions:[i],validateOptions:[a]});function s(t){let e;let n=f.reduce((t,e)=>(t[e]=function(){let t=Object.create(null),e=0;return{publish:function(e){for(let r in t)t[r](e)},subscribe:function(r){let n=e++;return t[n]=r,function(){delete t[n]}}}}(),t),{}),i=function(t,e,...r){let n="onError"===t,i=e;for(let e=0;e{e=r(t,(e,r)=>((t,e,r)=>{let o=t,s=e;if(!o)try{s=i("onResponse",e,r)}catch(t){s=null,o=t}(o=o&&i("onError",o,r))?n.error.publish(o):s&&n.response.publish(s)})(e,r,t))});n.abort.subscribe(()=>{a(),e&&e.abort()});let c=i("onReturn",n,u);return c===n&&n.request.publish(u),c}return s.use=function(t){if(!t)throw Error("Tried to add middleware that resolved to falsey value");if("function"==typeof t)throw Error("Tried to add middleware that was a function. It probably expects you to pass options to it.");if(t.onReturn&&o.onReturn.length>0)throw Error("Tried to add new middleware with `onReturn` handler, but another handler has already been registered for this event");return l.forEach(e=>{t[e]&&o[e].push(t[e])}),n.push(t),s},s.clone=()=>t(n,r),e.forEach(s.use),s})(t,e);var v,w,E=r(68571),C=r(87376).lW,A={exports:{}},x=function(t){function e(t){let n,o,i,s=null;function u(...t){if(!u.enabled)return;let r=Number(new Date),o=r-(n||r);u.diff=o,u.prev=n,u.curr=r,n=r,t[0]=e.coerce(t[0]),"string"!=typeof t[0]&&t.unshift("%O");let i=0;t[0]=t[0].replace(/%([a-zA-Z%])/g,(r,n)=>{if("%%"===r)return"%";i++;let o=e.formatters[n];if("function"==typeof o){let e=t[i];r=o.call(u,e),t.splice(i,1),i--}return r}),e.formatArgs.call(u,t),(u.log||e.log).apply(u,t)}return u.namespace=t,u.useColors=e.useColors(),u.color=e.selectColor(t),u.extend=r,u.destroy=e.destroy,Object.defineProperty(u,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==s?s:(o!==e.namespaces&&(o=e.namespaces,i=e.enabled(t)),i),set:t=>{s=t}}),"function"==typeof e.init&&e.init(u),u}function r(t,r){let n=e(this.namespace+(typeof r>"u"?":":r)+t);return n.log=this.log,n}function n(t){return t.toString().substring(2,t.toString().length-2).replace(/\.\*\?$/,"*")}return e.debug=e,e.default=e,e.coerce=function(t){return t instanceof Error?t.stack||t.message:t},e.disable=function(){let t=[...e.names.map(n),...e.skips.map(n).map(t=>"-"+t)].join(",");return e.enable(""),t},e.enable=function(t){let r;e.save(t),e.namespaces=t,e.names=[],e.skips=[];let n=("string"==typeof t?t:"").split(/[\s,]+/),o=n.length;for(r=0;r=1.5*r?"s":"")}return w=1,v=function(e,r){r=r||{};var n,o,i=typeof e;if("string"===i&&e.length>0)return function(t){if(!((t=String(t)).length>100)){var e=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(t);if(e){var r=parseFloat(e[1]);switch((e[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*r;case"weeks":case"week":case"w":return 6048e5*r;case"days":case"day":case"d":return 864e5*r;case"hours":case"hour":case"hrs":case"hr":case"h":return 36e5*r;case"minutes":case"minute":case"mins":case"min":case"m":return 6e4*r;case"seconds":case"second":case"secs":case"sec":case"s":return 1e3*r;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return r;default:return}}}}(e);if("number"===i&&isFinite(e))return r.long?(o=Math.abs(e))>=864e5?t(e,o,864e5,"day"):o>=36e5?t(e,o,36e5,"hour"):o>=6e4?t(e,o,6e4,"minute"):o>=1e3?t(e,o,1e3,"second"):e+" ms":(n=Math.abs(e))>=864e5?Math.round(e/864e5)+"d":n>=36e5?Math.round(e/36e5)+"h":n>=6e4?Math.round(e/6e4)+"m":n>=1e3?Math.round(e/1e3)+"s":e+"ms";throw Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}}(),e.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(t).forEach(r=>{e[r]=t[r]}),e.names=[],e.skips=[],e.formatters={},e.selectColor=function(t){let r=0;for(let e=0;e{"%%"!==t&&(n++,"%c"===t&&(o=n))}),e.splice(o,0,r)},e.save=function(t){try{t?e.storage.setItem("debug",t):e.storage.removeItem("debug")}catch{}},e.load=function(){let t;try{t=e.storage.getItem("debug")}catch{}return!t&&"u">typeof E&&"env"in E&&(t=E.env.DEBUG),t},e.useColors=function(){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+)/))&&("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&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"u">typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},e.storage=function(){try{return localStorage}catch{}}(),e.destroy=(r=!1,()=>{r||(r=!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`."))}),e.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"],e.log=console.debug||console.log||(()=>{}),t.exports=x(e);let{formatters:n}=t.exports;n.j=function(t){try{return JSON.stringify(t)}catch(t){return"[UnexpectedJSONParseError]: "+t.message}}}(A,A.exports),c(A.exports),Object.prototype.hasOwnProperty;let R=typeof C>"u"?()=>!1:t=>C.isBuffer(t);function O(t){return"[object Object]"===Object.prototype.toString.call(t)}let T=["boolean","string","number"],I={};"u">typeof globalThis?I=globalThis:"u">typeof window?I=window:"u">typeof global?I=global:"u">typeof self&&(I=self);var S=I;let j=(t={})=>{let e=t.implementation||Promise;if(!e)throw Error("`Promise` is not available in global scope, and no implementation was passed");return{onReturn:(r,n)=>new e((e,o)=>{let i=n.options.cancelToken;i&&i.promise.then(t=>{r.abort.publish(t),o(t)}),r.error.subscribe(o),r.response.subscribe(r=>{e(t.onlyBody?r.body:r)}),setTimeout(()=>{try{r.request.publish(n)}catch(t){o(t)}},0)})}};class q{__CANCEL__=!0;message;constructor(t){this.message=t}toString(){return"Cancel"+(this.message?`: ${this.message}`:"")}}class U{promise;reason;constructor(t){if("function"!=typeof t)throw TypeError("executor must be a function.");let e=null;this.promise=new Promise(t=>{e=t}),t(t=>{this.reason||(this.reason=new q(t),e(this.reason))})}static source=()=>{let t;return{token:new U(e=>{t=e}),cancel:t}}}j.Cancel=q,j.CancelToken=U,j.isCancel=t=>!(!t||!t?.__CANCEL__);var P=(t,e,r)=>("GET"===r.method||"HEAD"===r.method)&&(t.isNetworkError||!1);function $(t){return 100*Math.pow(2,t)+100*Math.random()}let L=(t={})=>(t=>{let e=t.maxRetries||5,r=t.retryDelay||$,n=t.shouldRetry;return{onError:(t,o)=>{var i;let s=o.options,u=s.maxRetries||e,a=s.retryDelay||r,c=s.shouldRetry||n,f=s.attemptNumber||0;if(null!==(i=s.body)&&"object"==typeof i&&"function"==typeof i.pipe||!c(t,f,s)||f>=u)return t;let l=Object.assign({},o,{options:Object.assign({},s,{attemptNumber:f+1})});return setTimeout(()=>o.channels.request.publish(l),a(f)),null}}})({shouldRetry:P,...t});L.shouldRetry=P;var _=r(80029),k=r(97178),B=r(58198),F=r(88400),D=r(83780),M=r(36246),N=r(29230),z=r(13311),H=r(3339),J=r(40306),G=r(56822);function V(){for(var t=[],e=0;et.error?.description).filter(Boolean),o=n.length?`: - ${n.join(` - `)}`:"";return t.length>5&&(o+=` ...and ${t.length-5} more`),r.message=`${e.error.description}${o}`,r.details=e.error,r}return e.error&&e.error.description?(r.message=e.error.description,r.details=e.error):r.message=e.error||e.message||function(t){let e=t.statusMessage?` ${t.statusMessage}`:"";return`${t.method}-request to ${t.url} resulted in HTTP ${t.statusCode}${e}`}(t),r}function W(t){return"object"==typeof t&&null!==t&&!Array.isArray(t)}class tt extends Error{projectId;addOriginUrl;constructor({projectId:t}){super("CorsOriginError"),this.name="CorsOriginError",this.projectId=t;let e=new URL(`https://sanity.io/manage/project/${t}/api`);if("u">typeof location){let{origin:t}=location;e.searchParams.set("cors","add"),e.searchParams.set("origin",t),this.addOriginUrl=e,this.message=`The current origin is not allowed to connect to the Live Content API. Add it here: ${e}`}else this.message=`The current origin is not allowed to connect to the Live Content API. Change your configuration here: ${e}`}}let te={onResponse:t=>{if(t.statusCode>=500)throw new Q(t);if(t.statusCode>=400)throw new Z(t);return t}},tr={onResponse:t=>{let e=t.headers["x-sanity-warning"];return(Array.isArray(e)?e:[e]).filter(Boolean).forEach(t=>console.warn(t)),t}};function tn(t,e,r){if(0===r.maxRetries)return!1;let n="GET"===r.method||"HEAD"===r.method,o=(r.uri||r.url).startsWith("/data/query"),i=t.response&&(429===t.response.statusCode||502===t.response.statusCode||503===t.response.statusCode);return(!!n||!!o)&&!!i||L.shouldRetry(t,e,r)}function to(t){if("string"==typeof t)return{id:t};if(Array.isArray(t))return{query:"*[_id in $ids]",params:{ids:t}};if("object"==typeof t&&null!==t&&"query"in t&&"string"==typeof t.query)return"params"in t&&"object"==typeof t.params&&null!==t.params?{query:t.query,params:t.params}:{query:t.query};let e=["* Document ID ()","* Array of document IDs","* Object containing `query`"].join(` `);throw Error(`Unknown selection - must be one of: ${e}`)}let ti=["image","file"],ts=["before","after","replace"],tu=t=>{if(!/^(~[a-z0-9]{1}[-\w]{0,63}|[a-z0-9]{1}[-\w]{0,63})$/.test(t))throw Error("Datasets can only contain lowercase characters, numbers, underscores and dashes, and start with tilde, and be maximum 64 characters")},ta=t=>{if(!/^[-a-z0-9]+$/i.test(t))throw Error("`projectId` can only contain only a-z, 0-9 and dashes")},tc=t=>{if(-1===ti.indexOf(t))throw Error(`Invalid asset type: ${t}. Must be one of ${ti.join(", ")}`)},tf=(t,e)=>{if(null===e||"object"!=typeof e||Array.isArray(e))throw Error(`${t}() takes an object of properties`)},tl=(t,e)=>{if("string"!=typeof e||!/^[a-z0-9_][a-z0-9_.-]{0,127}$/i.test(e)||e.includes(".."))throw Error(`${t}(): "${e}" is not a valid document ID`)},th=(t,e)=>{if(!e._id)throw Error(`${t}() requires that the document contains an ID ("_id" property)`);tl(t,e._id)},tp=(t,e,r)=>{let n="insert(at, selector, items)";if(-1===ts.indexOf(t)){let t=ts.map(t=>`"${t}"`).join(", ");throw Error(`${n} takes an "at"-argument which is one of: ${t}`)}if("string"!=typeof e)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`)},td=t=>{if(!t.dataset)throw Error("`dataset` must be provided to perform queries");return t.dataset||""},ty=t=>{if("string"!=typeof t||!/^[a-z0-9._-]{1,75}$/i.test(t))throw Error("Tag can only contain alphanumeric characters, underscores, dashes and dots, and be between one and 75 characters long.");return t};class tg{selection;operations;constructor(t,e={}){this.selection=t,this.operations=e}set(t){return this._assign("set",t)}setIfMissing(t){return this._assign("setIfMissing",t)}diffMatchPatch(t){return tf("diffMatchPatch",t),this._assign("diffMatchPatch",t)}unset(t){if(!Array.isArray(t))throw Error("unset(attrs) takes an array of attributes to unset, non-array given");return this.operations=Object.assign({},this.operations,{unset:t}),this}inc(t){return this._assign("inc",t)}dec(t){return this._assign("dec",t)}insert(t,e,r){return tp(t,e,r),this._assign("insert",{[t]:e,items:r})}append(t,e){return this.insert("after",`${t}[-1]`,e)}prepend(t,e){return this.insert("before",`${t}[0]`,e)}splice(t,e,r,n){let o=e<0?e-1:e,i=typeof r>"u"||-1===r?-1:Math.max(0,e+r),s=`${t}[${o}:${o<0&&i>=0?"":i}]`;return this.insert("replace",s,n||[])}ifRevisionId(t){return this.operations.ifRevisionID=t,this}serialize(){return{...to(this.selection),...this.operations}}toJSON(){return this.serialize()}reset(){return this.operations={},this}_assign(t,e,r=!0){return tf(t,e),this.operations=Object.assign({},this.operations,{[t]:Object.assign({},r&&this.operations[t]||{},e)}),this}_set(t,e){return this._assign(t,e,!1)}}class tm extends tg{#u;constructor(t,e,r){super(t,e),this.#u=r}clone(){return new tm(this.selection,{...this.operations},this.#u)}commit(t){if(!this.#u)throw Error("No `client` passed to patch, either provide one or pass the patch to a clients `mutate()` method");let e=Object.assign({returnFirst:"string"==typeof this.selection,returnDocuments:!0},t);return this.#u.mutate({patch:this.serialize()},e)}}class tb extends tg{#u;constructor(t,e,r){super(t,e),this.#u=r}clone(){return new tb(this.selection,{...this.operations},this.#u)}commit(t){if(!this.#u)throw Error("No `client` passed to patch, either provide one or pass the patch to a clients `mutate()` method");let e=Object.assign({returnFirst:"string"==typeof this.selection,returnDocuments:!0},t);return this.#u.mutate({patch:this.serialize()},e)}}let tv={returnDocuments:!1};class tw{operations;trxId;constructor(t=[],e){this.operations=t,this.trxId=e}create(t){return tf("create",t),this._add({create:t})}createIfNotExists(t){let e="createIfNotExists";return tf(e,t),th(e,t),this._add({[e]:t})}createOrReplace(t){let e="createOrReplace";return tf(e,t),th(e,t),this._add({[e]:t})}delete(t){return tl("delete",t),this._add({delete:{id:t}})}transactionId(t){return t?(this.trxId=t,this):this.trxId}serialize(){return[...this.operations]}toJSON(){return this.serialize()}reset(){return this.operations=[],this}_add(t){return this.operations.push(t),this}}class tE extends tw{#u;constructor(t,e,r){super(t,r),this.#u=e}clone(){return new tE([...this.operations],this.#u,this.trxId)}commit(t){if(!this.#u)throw Error("No `client` passed to transaction, either provide one or pass the transaction to a clients `mutate()` method");return this.#u.mutate(this.serialize(),Object.assign({transactionId:this.trxId},tv,t||{}))}patch(t,e){let r="function"==typeof e;if("string"!=typeof t&&t instanceof tb)return this._add({patch:t.serialize()});if(r){let r=e(new tb(t,{},this.#u));if(!(r instanceof tb))throw Error("function passed to `patch()` must return the patch");return this._add({patch:r.serialize()})}return this._add({patch:{id:t,...e}})}}class tC extends tw{#u;constructor(t,e,r){super(t,r),this.#u=e}clone(){return new tC([...this.operations],this.#u,this.trxId)}commit(t){if(!this.#u)throw Error("No `client` passed to transaction, either provide one or pass the transaction to a clients `mutate()` method");return this.#u.mutate(this.serialize(),Object.assign({transactionId:this.trxId},tv,t||{}))}patch(t,e){let r="function"==typeof e;if("string"!=typeof t&&t instanceof tm)return this._add({patch:t.serialize()});if(r){let r=e(new tm(t,{},this.#u));if(!(r instanceof tm))throw Error("function passed to `patch()` must return the patch");return this._add({patch:r.serialize()})}return this._add({patch:{id:t,...e}})}}function tA(t){return"https://www.sanity.io/help/"+t}let tx=t=>{var e;let r,n;return e=(...e)=>console.warn(t.join(" "),...e),r=!1,(...t)=>(r||(n=e(...t),r=!0),n)},tR=tx(["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"]),tO=tx(["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."]),tT=tx(["The Sanity client is configured with the `perspective` set to `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."]),tI=tx(["You have configured Sanity client to use a token in the browser. This may cause unintentional security issues.",`See ${tA("js-client-browser-token")} for more information and how to hide this warning.`]),tS=tx(["Using the Sanity client without specifying an API version is deprecated.",`See ${tA("js-client-api-version")}`]),tj=(tx(["The default export of @sanity/client has been deprecated. Use the named export `createClient` instead."]),{apiHost:"https://api.sanity.io",apiVersion:"1",useProjectHostname:!0,stega:{enabled:!1}}),tq=["localhost","127.0.0.1","0.0.0.0"],tU=t=>-1!==tq.indexOf(t),tP=function(t){switch(t){case"previewDrafts":case"published":case"raw":return;default:throw TypeError("Invalid API perspective string, expected `published`, `previewDrafts` or `raw`")}},t$=(t,e)=>{let r={...e,...t,stega:{..."boolean"==typeof e.stega?{enabled:e.stega}:e.stega||tj.stega,..."boolean"==typeof t.stega?{enabled:t.stega}:t.stega||{}}};r.apiVersion||tS();let n={...tj,...r},o=n.useProjectHostname;if(typeof Promise>"u"){let t=tA("js-client-promise-polyfill");throw Error(`No native Promise-implementation found, polyfill needed - see ${t}`)}if(o&&!n.projectId)throw Error("Configuration must contain `projectId`");if("string"==typeof n.perspective&&tP(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'?");if("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 i="u">typeof window&&window.location&&window.location.hostname,s=i&&tU(window.location.hostname);i&&s&&n.token&&!0!==n.ignoreBrowserTokenWarning?tI():typeof n.useCdn>"u"&&tO(),o&&ta(n.projectId),n.dataset&&tu(n.dataset),"requestTagPrefix"in n&&(n.requestTagPrefix=n.requestTagPrefix?ty(n.requestTagPrefix).replace(/\.+$/,""):void 0),n.apiVersion=`${n.apiVersion}`.replace(/^v/,""),n.isDefaultApi=n.apiHost===tj.apiHost,!0===n.useCdn&&n.withCredentials&&tR(),n.useCdn=!1!==n.useCdn&&!n.withCredentials,function(t){if("1"===t||"X"===t)return;let e=new Date(t);if(!(/^\d{4}-\d{2}-\d{2}$/.test(t)&&e instanceof Date&&e.getTime()>0))throw Error("Invalid API version string, expected `1` or date in format `YYYY-MM-DD`")}(n.apiVersion);let u=n.apiHost.split("://",2),a=u[0],c=u[1],f=n.isDefaultApi?"apicdn.sanity.io":c;return n.useProjectHostname?(n.url=`${a}://${n.projectId}.${c}/v${n.apiVersion}`,n.cdnUrl=`${a}://${n.projectId}.${f}/v${n.apiVersion}`):(n.url=`${n.apiHost}/v${n.apiVersion}`,n.cdnUrl=n.url),n},tL=({query:t,params:e={},options:r={}})=>{let n=new URLSearchParams,{tag:o,includeMutations:i,returnQuery:s,...u}=r;for(let[r,i]of(o&&n.append("tag",o),n.append("query",t),Object.entries(e)))n.append(`$${r}`,JSON.stringify(i));for(let[t,e]of Object.entries(u))e&&n.append(t,`${e}`);return!1===s&&n.append("returnQuery","false"),!1===i&&n.append("includeMutations","false"),`?${n}`},t_=(t,e)=>!1===t?void 0:typeof t>"u"?e:t,tk=(t={})=>({dryRun:t.dryRun,returnIds:!0,returnDocuments:t_(t.returnDocuments,!0),visibility:t.visibility||"sync",autoGenerateArrayKeys:t.autoGenerateArrayKeys,skipCrossDatasetReferenceValidation:t.skipCrossDatasetReferenceValidation}),tB=t=>"response"===t.type,tF=t=>t.body,tD=(t,e)=>t.reduce((t,r)=>(t[e(r)]=r,t),Object.create(null));function tM(t,e,n,o,i={},s={}){let u="stega"in s?{...n||{},..."boolean"==typeof s.stega?{enabled:s.stega}:s.stega||{}}:n,a=u.enabled?(0,F.N)(i):i,c=!1===s.filterResponse?t=>t:t=>t.result,{cache:f,next:l,...h}={useAbortSignal:"u">typeof s.signal,resultSourceMap:u.enabled?"withKeyArraySelector":s.resultSourceMap,...s,returnQuery:!1===s.filterResponse&&!1!==s.returnQuery},p=tY(t,e,"query",{query:o,params:a},"u">typeof f||"u">typeof l?{...h,fetch:{cache:f,next:l}}:h);return u.enabled?p.pipe(function(){for(var t=[],e=0;et))),(0,X.U)(([t,e])=>{let r=e(t.result,t.resultSourceMap,u);return c({...t,result:r})})):p.pipe((0,X.U)(c))}function tN(t,e,r,n={}){let o={uri:tW(t,"doc",r),json:!0,tag:n.tag,signal:n.signal};return tQ(t,e,o).pipe((0,Y.h)(tB),(0,X.U)(t=>t.body.documents&&t.body.documents[0]))}function tz(t,e,r,n={}){let o={uri:tW(t,"doc",r.join(",")),json:!0,tag:n.tag,signal:n.signal};return tQ(t,e,o).pipe((0,Y.h)(tB),(0,X.U)(t=>{let e=tD(t.body.documents||[],t=>t._id);return r.map(t=>e[t]||null)}))}function tH(t,e,r,n){return th("createIfNotExists",r),tZ(t,e,r,"createIfNotExists",n)}function tJ(t,e,r,n){return th("createOrReplace",r),tZ(t,e,r,"createOrReplace",n)}function tG(t,e,r,n){return tY(t,e,"mutate",{mutations:[{delete:to(r)}]},n)}function tV(t,e,r,n){let o;return tY(t,e,"mutate",{mutations:Array.isArray(o=r instanceof tb||r instanceof tm?{patch:r.serialize()}:r instanceof tE||r instanceof tC?r.serialize():r)?o:[o],transactionId:n&&n.transactionId||void 0},n)}function tX(t,e,r,n){let o=Array.isArray(r)?r:[r];return tY(t,e,"actions",{actions:o,transactionId:n&&n.transactionId||void 0,skipCrossDatasetReferenceValidation:n&&n.skipCrossDatasetReferenceValidation||void 0,dryRun:n&&n.dryRun||void 0},n)}function tY(t,e,r,n,o={}){let i="mutate"===r,s="actions"===r,u=i||s?"":tL(n),a=!i&&!s&&u.length<11264,c=o.returnFirst,{timeout:f,token:l,tag:h,headers:p,returnQuery:d,lastLiveEventId:y}=o,g=tW(t,r,a?u:"");return tQ(t,e,{method:a?"GET":"POST",uri:g,json:!0,body:a?void 0:n,query:i&&tk(o),timeout:f,headers:p,token:l,tag:h,returnQuery:d,perspective:o.perspective,resultSourceMap:o.resultSourceMap,lastLiveEventId:Array.isArray(y)?y[0]:y,canUseCdn:"query"===r,signal:o.signal,fetch:o.fetch,useAbortSignal:o.useAbortSignal,useCdn:o.useCdn}).pipe((0,Y.h)(tB),(0,X.U)(tF),(0,X.U)(t=>{if(!i)return t;let e=t.results||[];if(o.returnDocuments)return c?e[0]&&e[0].document:e.map(t=>t.document);let r=c?e[0]&&e[0].id:e.map(t=>t.id);return{transactionId:t.transactionId,results:e,[c?"documentId":"documentIds"]:r}}))}function tZ(t,e,r,n,o={}){return tY(t,e,"mutate",{mutations:[{[n]:r}]},Object.assign({returnFirst:!0,returnDocuments:!0},o))}function tQ(t,e,r){var n;let o=r.url||r.uri,i=t.config(),s=typeof r.canUseCdn>"u"?["GET","HEAD"].indexOf(r.method||"GET")>=0&&0===o.indexOf("/data/"):r.canUseCdn,u=(r.useCdn??i.useCdn)&&s,a=r.tag&&i.requestTagPrefix?[i.requestTagPrefix,r.tag].join("."):r.tag||i.requestTagPrefix;if(a&&null!==r.tag&&(r.query={tag:ty(a),...r.query}),["GET","HEAD","POST"].indexOf(r.method||"GET")>=0&&0===o.indexOf("/data/query/")){let t=r.resultSourceMap??i.resultSourceMap;void 0!==t&&!1!==t&&(r.query={resultSourceMap:t,...r.query});let e=r.perspective||i.perspective;"string"==typeof e&&"raw"!==e&&(tP(e),r.query={perspective:e,...r.query},"previewDrafts"===e&&u&&(u=!1,tT())),r.lastLiveEventId&&(r.query={...r.query,lastLiveEventId:r.lastLiveEventId}),!1===r.returnQuery&&(r.query={returnQuery:"false",...r.query})}let c=function(t,e={}){let r={},n=e.token||t.token;n&&(r.Authorization=`Bearer ${n}`),e.useGlobalApi||t.useProjectHostname||!t.projectId||(r["X-Sanity-Project-ID"]=t.projectId);let o=!!(typeof e.withCredentials>"u"?t.token||t.withCredentials:e.withCredentials),i=typeof e.timeout>"u"?t.timeout:e.timeout;return Object.assign({},e,{headers:Object.assign({},r,e.headers||{}),timeout:typeof i>"u"?3e5:i,proxy:e.proxy||t.proxy,json:!0,withCredentials:o,fetch:"object"==typeof e.fetch&&"object"==typeof t.fetch?{...t.fetch,...e.fetch}:e.fetch||t.fetch})}(i,Object.assign({},r,{url:t0(t,o,u)})),f=new _.y(t=>e(c,i.requester).subscribe(t));return r.signal?f.pipe((n=r.signal,t=>new _.y(e=>{let r=()=>e.error(function(t){if(t1)return new DOMException(t?.reason??"The operation was aborted.","AbortError");let e=Error(t?.reason??"The operation was aborted.");return e.name="AbortError",e}(n));if(n&&n.aborted){r();return}let o=t.subscribe(e);return n.addEventListener("abort",r),()=>{n.removeEventListener("abort",r),o.unsubscribe()}}))):f}function tK(t,e,r){return tQ(t,e,r).pipe((0,Y.h)(t=>"response"===t.type),(0,X.U)(t=>t.body))}function tW(t,e,r){let n=td(t.config()),o=`/${e}/${n}`;return`/data${r?`${o}/${r}`:o}`.replace(/\/($|\?)/,"$1")}function t0(t,e,r=!1){let{url:n,cdnUrl:o}=t.config();return`${r?o:n}/${e.replace(/^\//,"")}`}let t1=!!globalThis.DOMException;class t2{#u;#a;constructor(t,e){this.#u=t,this.#a=e}upload(t,e,r){return t6(this.#u,this.#a,t,e,r)}}class t3{#u;#a;constructor(t,e){this.#u=t,this.#a=e}upload(t,e,r){let n=t6(this.#u,this.#a,t,e,r);return(0,B.n)(n.pipe((0,Y.h)(t=>"response"===t.type),(0,X.U)(t=>t.body.document)))}}function t6(t,e,r,n,o={}){tc(r);let i=o.extract||void 0;i&&!i.length&&(i=["none"]);let s=td(t.config()),u="image"===r?"images":"files",a=!(typeof File>"u")&&n instanceof File?Object.assign({filename:!1===o.preserveFilename?void 0:n.name,contentType:n.type},o):o,{tag:c,label:f,title:l,description:h,creditLine:p,filename:d,source:y}=a,g={label:f,title:l,description:h,filename:d,meta:i,creditLine:p};return y&&(g.sourceId=y.id,g.sourceName=y.name,g.sourceUrl=y.url),tQ(t,e,{tag:c,method:"POST",timeout:a.timeout||0,uri:`/assets/${u}/${s}`,headers:a.contentType?{"Content-Type":a.contentType}:{},query:g,body:n})}var t5=(t,e)=>Object.keys(e).concat(Object.keys(t)).reduce((r,n)=>(r[n]=typeof t[n]>"u"?e[n]:t[n],r),{});let t8=(t,e)=>e.reduce((e,r)=>(typeof t[r]>"u"||(e[r]=t[r]),e),{}),t4=["includePreviousRevision","includeResult","includeMutations","visibility","effectFormat","tag"],t9={includeResult:!0};function t7(t,e,n={}){let{url:o,token:i,withCredentials:s,requestTagPrefix:u}=this.config(),a=n.tag&&u?[u,n.tag].join("."):n.tag,c={...t5(n,t9),tag:a},f=tL({query:t,params:e,options:{tag:a,...t8(c,t4)}}),l=`${o}${tW(this,"listen",f)}`;if(l.length>14800)return new _.y(t=>t.error(Error("Query too large for listener")));let h=c.events?c.events:["mutation"],p=-1!==h.indexOf("reconnect"),d={};return(i||s)&&(d.withCredentials=!0),i&&(d.headers={Authorization:`Bearer ${i}`}),new _.y(t=>{let e,n,o=!1,i=!1;function s(){o||(p&&t.next({type:"reconnect"}),o||e.readyState!==e.CLOSED||(f(),clearTimeout(n),n=setTimeout(g,100)))}function u(e){t.error(function(t){if(t instanceof Error)return t;let e=et(t);return e instanceof Error?e:Error(e.error?e.error.description?e.error.description:"string"==typeof e.error?e.error:JSON.stringify(e.error,null,2):e.message||"Unknown listener error")}(e))}function a(e){let r=et(e);return r instanceof Error?t.error(r):t.next(r)}function c(){o=!0,f(),t.complete()}function f(){e&&(e.removeEventListener("error",s),e.removeEventListener("channelError",u),e.removeEventListener("disconnect",c),h.forEach(t=>e.removeEventListener(t,a)),e.close())}async function y(){let{default:t}=await r.e(7722).then(r.t.bind(r,67722,19));if(i)return;let e=new t(l,d);return e.addEventListener("error",s),e.addEventListener("channelError",u),e.addEventListener("disconnect",c),h.forEach(t=>e.addEventListener(t,a)),e}function g(){y().then(t=>{t&&(e=t,i&&f())}).catch(e=>{t.error(e),m()})}function m(){o=!0,f(),i=!0}return g(),m})}function et(t){try{let e=t.data&&JSON.parse(t.data)||{};return Object.assign({type:t.type},e)}catch(t){return t}}let ee="2021-03-26";class er{#u;constructor(t){this.#u=t}events({includeDrafts:t=!1,tag:e}={}){let{projectId:n,apiVersion:o,token:i,withCredentials:s,requestTagPrefix:u}=this.#u.config(),a=o.replace(/^v/,"");if("X"!==a&&a{let e,o,i=!1,s=!1;function u(r){if(!i){if("data"in r){let e=en(r);t.error(Error(e.message,{cause:e}))}e.readyState===e.CLOSED&&(c(),clearTimeout(o),o=setTimeout(d,100))}}function a(e){let r=en(e);return r instanceof Error?t.error(r):t.next(r)}function c(){if(e){for(let t of(e.removeEventListener("error",u),h))e.removeEventListener(t,a);e.close()}}async function l(){let t=typeof EventSource>"u"||p.headers||p.withCredentials?(await r.e(7722).then(r.t.bind(r,67722,19))).default:EventSource;if(s)return;try{if(await fetch(f,{method:"OPTIONS",mode:"cors",credentials:p.withCredentials?"include":"omit",headers:p.headers}),s)return}catch{throw new tt({projectId:n})}let e=new t(f.toString(),p);for(let t of(e.addEventListener("error",u),h))e.addEventListener(t,a);return e}function d(){l().then(t=>{t&&(e=t,s&&c())}).catch(e=>{t.error(e),y()})}function y(){i=!0,c(),s=!0}return d(),y})}}function en(t){try{let e=t.data&&JSON.parse(t.data)||{};return{type:t.type,id:t.lastEventId,...e}}catch(t){return t}}class eo{#u;#a;constructor(t,e){this.#u=t,this.#a=e}create(t,e){return es(this.#u,this.#a,"PUT",t,e)}edit(t,e){return es(this.#u,this.#a,"PATCH",t,e)}delete(t){return es(this.#u,this.#a,"DELETE",t)}list(){return tK(this.#u,this.#a,{uri:"/datasets",tag:null})}}class ei{#u;#a;constructor(t,e){this.#u=t,this.#a=e}create(t,e){return(0,B.n)(es(this.#u,this.#a,"PUT",t,e))}edit(t,e){return(0,B.n)(es(this.#u,this.#a,"PATCH",t,e))}delete(t){return(0,B.n)(es(this.#u,this.#a,"DELETE",t))}list(){return(0,B.n)(tK(this.#u,this.#a,{uri:"/datasets",tag:null}))}}function es(t,e,r,n,o){return tu(n),tK(t,e,{method:r,uri:`/datasets/${n}`,body:o,tag:null})}class eu{#u;#a;constructor(t,e){this.#u=t,this.#a=e}list(t){let e=t?.includeMembers===!1?"/projects?includeMembers=false":"/projects";return tK(this.#u,this.#a,{uri:e})}getById(t){return tK(this.#u,this.#a,{uri:`/projects/${t}`})}}class ea{#u;#a;constructor(t,e){this.#u=t,this.#a=e}list(t){let e=t?.includeMembers===!1?"/projects?includeMembers=false":"/projects";return(0,B.n)(tK(this.#u,this.#a,{uri:e}))}getById(t){return(0,B.n)(tK(this.#u,this.#a,{uri:`/projects/${t}`}))}}class ec{#u;#a;constructor(t,e){this.#u=t,this.#a=e}getById(t){return tK(this.#u,this.#a,{uri:`/users/${t}`})}}class ef{#u;#a;constructor(t,e){this.#u=t,this.#a=e}getById(t){return(0,B.n)(tK(this.#u,this.#a,{uri:`/users/${t}`}))}}class el{assets;datasets;live;projects;users;#c;#a;listen=t7;constructor(t,e=tj){this.config(e),this.#a=t,this.assets=new t2(this,this.#a),this.datasets=new eo(this,this.#a),this.live=new er(this),this.projects=new eu(this,this.#a),this.users=new ec(this,this.#a)}clone(){return new el(this.#a,this.config())}config(t){if(void 0===t)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=t$(t,this.#c||{}),this}withConfig(t){let e=this.config();return new el(this.#a,{...e,...t,stega:{...e.stega||{},..."boolean"==typeof t?.stega?{enabled:t.stega}:t?.stega||{}}})}fetch(t,e,r){return tM(this,this.#a,this.#c.stega,t,e,r)}getDocument(t,e){return tN(this,this.#a,t,e)}getDocuments(t,e){return tz(this,this.#a,t,e)}create(t,e){return tZ(this,this.#a,t,"create",e)}createIfNotExists(t,e){return tH(this,this.#a,t,e)}createOrReplace(t,e){return tJ(this,this.#a,t,e)}delete(t,e){return tG(this,this.#a,t,e)}mutate(t,e){return tV(this,this.#a,t,e)}patch(t,e){return new tm(t,e,this)}transaction(t){return new tC(t,this)}action(t,e){return tX(this,this.#a,t,e)}request(t){return tK(this,this.#a,t)}getUrl(t,e){return t0(this,t,e)}getDataUrl(t,e){return tW(this,t,e)}}class eh{assets;datasets;live;projects;users;observable;#c;#a;listen=t7;constructor(t,e=tj){this.config(e),this.#a=t,this.assets=new t3(this,this.#a),this.datasets=new ei(this,this.#a),this.live=new er(this),this.projects=new ea(this,this.#a),this.users=new ef(this,this.#a),this.observable=new el(t,e)}clone(){return new eh(this.#a,this.config())}config(t){if(void 0===t)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(t),this.#c=t$(t,this.#c||{}),this}withConfig(t){let e=this.config();return new eh(this.#a,{...e,...t,stega:{...e.stega||{},..."boolean"==typeof t?.stega?{enabled:t.stega}:t?.stega||{}}})}fetch(t,e,r){return(0,B.n)(tM(this,this.#a,this.#c.stega,t,e,r))}getDocument(t,e){return(0,B.n)(tN(this,this.#a,t,e))}getDocuments(t,e){return(0,B.n)(tz(this,this.#a,t,e))}create(t,e){return(0,B.n)(tZ(this,this.#a,t,"create",e))}createIfNotExists(t,e){return(0,B.n)(tH(this,this.#a,t,e))}createOrReplace(t,e){return(0,B.n)(tJ(this,this.#a,t,e))}delete(t,e){return(0,B.n)(tG(this,this.#a,t,e))}mutate(t,e){return(0,B.n)(tV(this,this.#a,t,e))}patch(t,e){return new tb(t,e,this)}transaction(t){return new tE(t,this)}action(t,e){return(0,B.n)(tX(this,this.#a,t,e))}request(t){return(0,B.n)(tK(this,this.#a,t))}dataRequest(t,e,r){return(0,B.n)(tY(this,this.#a,t,e,r))}getUrl(t,e){return t0(this,t,e)}getDataUrl(t,e){return tW(this,t,e)}}let ep=function(t,e){let r=b([L({shouldRetry:tn}),...t,tr,{processOptions:t=>{let e=t.body;return!e||"function"==typeof e.pipe||R(e)||-1===T.indexOf(typeof e)&&!Array.isArray(e)&&!function(t){if(!1===O(t))return!1;let e=t.constructor;if(void 0===e)return!0;let r=e.prototype;return!(!1===O(r)||!1===r.hasOwnProperty("isPrototypeOf"))}(e)?t:Object.assign({},t,{body:JSON.stringify(t.body),headers:Object.assign({},t.headers,{"Content-Type":"application/json"})})}},{onResponse:t=>{let e=t.headers["content-type"]||"",r=-1!==e.indexOf("application/json");return t.body&&e&&r?Object.assign({},t,{body:function(t){try{return JSON.parse(t)}catch(t){throw t.message=`Failed to parsed response body as JSON: ${t.message}`,t}}(t.body)}):t},processOptions:t=>Object.assign({},t,{headers:Object.assign({Accept:"application/json"},t.headers)})},{onRequest:t=>{if("xhr"!==t.adapter)return;let e=t.request,r=t.context;function n(t){return e=>{let n=e.lengthComputable?e.loaded/e.total*100:-1;r.channels.progress.publish({stage:t,percent:n,total:e.total,loaded:e.loaded,lengthComputable:e.lengthComputable})}}"upload"in e&&"onprogress"in e.upload&&(e.upload.onprogress=n("upload")),"onprogress"in e&&(e.onprogress=n("download"))}},te,function(t={}){let e=t.implementation||S.Observable;if(!e)throw Error("`Observable` is not available in global scope, and no implementation was passed");return{onReturn:(t,r)=>new e(e=>(t.error.subscribe(t=>e.error(t)),t.progress.subscribe(t=>e.next(Object.assign({type:"progress"},t))),t.response.subscribe(t=>{e.next(Object.assign({type:"response"},t)),e.complete()}),t.request.publish(r),()=>t.abort.publish()))}}({implementation:_.y})]);return{requester:r,createClient:t=>new e((e,n)=>(n||r)({maxRedirects:0,maxRetries:t.maxRetries,retryDelay:t.retryDelay,...e}),t)}}([],eh),ed=(ep.requester,ep.createClient)},83780:function(t,e,r){"use strict";r.d(e,{CR:function(){return c},FC:function(){return p},Jh:function(){return u},KL:function(){return d},XA:function(){return a},ZT:function(){return o},ev:function(){return l},fl:function(){return f},mG:function(){return s},pi:function(){return i},qq:function(){return h}});var n=function(t,e){return(n=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r])})(t,e)};function o(t,e){if("function"!=typeof e&&null!==e)throw TypeError("Class extends value "+String(e)+" is not a constructor or null");function r(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)}var i=function(){return(i=Object.assign||function(t){for(var e,r=1,n=arguments.length;r0&&o[o.length-1])&&(6===u[0]||2===u[0])){i=0;continue}if(3===u[0]&&(!o||u[1]>o[0]&&u[1]=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function c(t,e){var r="function"==typeof Symbol&&t[Symbol.iterator];if(!r)return t;var n,o,i=r.call(t),s=[];try{for(;(void 0===e||e-- >0)&&!(n=i.next()).done;)s.push(n.value)}catch(t){o={error:t}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(o)throw o.error}}return s}function f(){for(var t=[],e=0;e1||u(t,e)})},e&&(n[t]=e(n[t])))}function u(t,e){try{var r;(r=o[t](e)).value instanceof h?Promise.resolve(r.value.v).then(a,c):f(i[0][2],r)}catch(t){f(i[0][3],t)}}function a(t){u("next",t)}function c(t){u("throw",t)}function f(t,e){t(e),i.shift(),i.length&&u(i[0][0],i[0][1])}}function d(t){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var e,r=t[Symbol.asyncIterator];return r?r.call(t):(t=a(t),e={},n("next"),n("throw"),n("return"),e[Symbol.asyncIterator]=function(){return this},e);function n(r){e[r]=t[r]&&function(e){return new Promise(function(n,o){!function(t,e,r,n){Promise.resolve(n).then(function(e){t({value:e,done:r})},e)}(n,o,(e=t[r](e)).done,e.value)})}}}"function"==typeof SuppressedError&&SuppressedError},84222:function(t,e,r){"use strict";r.d(e,{i:function(){return o}});var n=r(7653);function o(t){let e=(0,n.useRef)(null);return(0,n.useInsertionEffect)(()=>{e.current=t},[t]),(0,n.useCallback)((...t)=>(0,e.current)(...t),[])}}}]);