1!function(){try{var t="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},e=(new t.Error).stack;e&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[e]="dc24b644-9e49-44d6-ad66-f72975f04dde",t._sentryDebugIdIdentifier="sentry-dbid-dc24b644-9e49-44d6-ad66-f72975f04dde")}catch(t){}}(),(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4579],{237:(t,e,r)=>{"use strict";r.d(e,{c:()=>v});var n=r(38299),o=r(88536),i=r(79619);function s(t,e){return void 0===e&&(e=0),(0,i.N)(function(r,n){n.add(t.schedule(function(){return r.subscribe(n)},e))})}var a=r(65132),u=r(46068),c=r(70418),l=r(15940);function f(t,e){if(!t)throw Error("Iterable cannot be null");return new a.c(function(r){(0,l.N)(r,e,function(){var n=t[Symbol.asyncIterator]();(0,l.N)(r,e,function(){n.next().then(function(t){t.done?r.complete():r.next(t.value)})},0,!0)})})}var h=r(85226),p=r(383),d=r(32812),y=r(49696),g=r(40316),b=r(8381),m=r(6137);function v(t,e){if(null!=t){if((0,h.l)(t))return(0,n.Tg)(t).pipe(s(e),(0,o.Q)(e));if((0,d.X)(t))return new a.c(function(r){var n=0;return e.schedule(function(){n===t.length?r.complete():(r.next(t[n++]),r.closed||this.schedule())})});if((0,p.y)(t))return(0,n.Tg)(t).pipe(s(e),(0,o.Q)(e));if((0,g.T)(t))return f(t,e);if((0,y.x)(t))return new a.c(function(r){var n;return(0,l.N)(r,e,function(){n=t[u.l](),(0,l.N)(r,e,function(){var t,e,o;try{e=(t=n.next()).value,o=t.done}catch(t){r.error(t);return}o?r.complete():r.next(e)},0,!0)}),function(){return(0,c.T)(null==n?void 0:n.return)&&n.return()}});if((0,m.U)(t))return f((0,m.C)(t),e)}throw(0,b.L)(t)}},383:(t,e,r)=>{"use strict";r.d(e,{y:()=>o});var n=r(70418);function o(t){return(0,n.T)(null==t?void 0:t.then)}},5661:(t,e,r)=>{"use strict";function n(t,e){return t.reduce(function(t,r,n){return t[r]=e[n],t},{})}r.d(e,{e:()=>n})},6137:(t,e,r)=>{"use strict";r.d(e,{C:()=>i,U:()=>s});var n=r(49303),o=r(70418);function i(t){return(0,n.AQ)(this,arguments,function(){var e,r,o;return(0,n.YH)(this,function(i){switch(i.label){case 0:e=t.getReader(),i.label=1;case 1:i.trys.push([1,,9,10]),i.label=2;case 2:return[4,(0,n.N3)(e.read())];case 3:if(o=(r=i.sent()).value,!r.done)return[3,5];return[4,(0,n.N3)(void 0)];case 4:return[2,i.sent()];case 5:return[4,(0,n.N3)(o)];case 6:return[4,i.sent()];case 7:return i.sent(),[3,2];case 8:return[3,10];case 9:return e.releaseLock(),[7];case 10:return[2]}})})}function s(t){return(0,o.T)(null==t?void 0:t.getReader)}},8381:(t,e,r)=>{"use strict";function n(t){return TypeError("You provided "+(null!==t&&"object"==typeof t?"an invalid object":"'"+t+"'")+" where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.")}r.d(e,{L:()=>n})},9615:(t,e,r)=>{"use strict";r.d(e,{$:()=>n});var n={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1}},10336:(t,e,r)=>{"use strict";function n(t){return t}r.d(e,{D:()=>n})},15512:(t,e,r)=>{"use strict";function n(t){var e=t(function(t){Error.call(t),t.stack=Error().stack});return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}r.d(e,{L:()=>n})},15940:(t,e,r)=>{"use strict";function n(t,e,r,n,o){void 0===n&&(n=0),void 0===o&&(o=!1);var i=e.schedule(function(){r(),o?t.add(this.schedule(null,n)):this.unsubscribe()},n);if(t.add(i),!o)return i}r.d(e,{N:()=>n})},16975:(t,e,r)=>{"use strict";r.d(e,{T:()=>i});var n=r(79619),o=r(77973);function i(t,e){return(0,n.N)(function(r,n){var i=0;r.subscribe((0,o._)(n,function(r){n.next(t.call(e,r,i++))}))})}},22227:(t,e,r)=>{"use strict";r.d(e,{G:()=>n});var n=(0,r(15512).L)(function(t){return function(){t(this),this.name="EmptyError",this.message="no elements in sequence"}})},24211:(t,e,r)=>{"use strict";r.d(e,{f:()=>o});var n=r(49303),o={setTimeout:function(t,e){for(var r=[],i=2;i<arguments.length;i++)r[i-2]=arguments[i];var s=o.delegate;return(null==s?void 0:s.setTimeout)?s.setTimeout.apply(s,(0,n.fX)([t,e],(0,n.zs)(r))):setTimeout.apply(void 0,(0,n.fX)([t,e],(0,n.zs)(r)))},clearTimeout:function(t){var e=o.delegate;return((null==e?void 0:e.clearTimeout)||clearTimeout)(t)},delegate:void 0}},24355:(t,e,r)=>{"use strict";r.d(e,{s:()=>n});var n="function"==typeof Symbol&&Symbol.observable||"@@observable"},26801:(t,e)=>{"use strict";e.byteLength=function(t){var e=u(t),r=e[0],n=e[1];return(r+n)*3/4-n},e.toByteArray=function(t){var e,r,i=u(t),s=i[0],a=i[1],c=new o((s+a)*3/4-a),l=0,f=a>0?s-4:s;for(r=0;r<f;r+=4)e=n[t.charCodeAt(r)]<<18|n[t.charCodeAt(r+1)]<<12|n[t.charCodeAt(r+2)]<<6|n[t.charCodeAt(r+3)],c[l++]=e>>16&255,c[l++]=e>>8&255,c[l++]=255&e;return 2===a&&(e=n[t.charCodeAt(r)]<<2|n[t.charCodeAt(r+1)]>>4,c[l++]=255&e),1===a&&(e=n[t.charCodeAt(r)]<<10|n[t.charCodeAt(r+1)]<<4|n[t.charCodeAt(r+2)]>>2,c[l++]=e>>8&255,c[l++]=255&e),c},e.fromByteArray=function(t){for(var e,n=t.length,o=n%3,i=[],s=0,a=n-o;s<a;s+=16383)i.push(function(t,e,n){for(var o,i=[],s=e;s<n;s+=3)o=(t[s]<<16&0xff0000)+(t[s+1]<<8&65280)+(255&t[s+2]),i.push(r[o>>18&63]+r[o>>12&63]+r[o>>6&63]+r[63&o]);return i.join("")}(t,s,s+16383>a?a: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
1+/",s=0,a=i.length;s<a;++s)r[s]=i[s],n[i.charCodeAt(s)]=s;function u(t){var e=t.length;if(e%4>0)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[45]=62,n[95]=63},27763:(t,e,r)=>{"use strict";r.d(e,{m:()=>i});var n=r(9615),o=r(24211);function i(t){o.f.setTimeout(function(){var e=n.$.onUnhandledError;if(e)e(t);else throw t})}},32812:(t,e,r)=>{"use strict";r.d(e,{X:()=>n});var n=function(t){return t&&"number"==typeof t.length&&"function"!=typeof t}},36171:(t,e,r)=>{"use strict";r.d(e,{R0:()=>u,lI:()=>a,ms:()=>s});var n=r(70418),o=r(44267);function i(t){return t[t.length-1]}function s(t){return(0,n.T)(i(t))?t.pop():void 0}function a(t){return(0,o.m)(i(t))?t.pop():void 0}function u(t,e){return"number"==typeof i(t)?t.pop():e}},36569:(t,e,r)=>{"use strict";r.d(e,{P:()=>p,z:()=>h});var n=r(65132),o=r(53196),i=r(97993),s=r(10336),a=r(66687),u=r(36171),c=r(5661),l=r(77973),f=r(15940);function h(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];var r=(0,u.lI)(t),l=(0,u.ms)(t),f=(0,o.D)(t),h=f.args,d=f.keys;if(0===h.length)return(0,i.H)([],r);var y=new n.c(p(h,r,d?function(t){return(0,c.e)(d,t)}:s.D));return l?y.pipe((0,a.I)(l)):y}function p(t,e,r){return void 0===r&&(r=s.D),function(n){d(e,function(){for(var o=t.length,s=Array(o),a=o,u=o,c=function(o){d(e,function(){var c=(0,i.H)(t[o],e),f=!1;c.subscribe((0,l._)(n,function(t){s[o]=t,!f&&(f=!0,u--),u||n.next(r(s.slice()))},function(){--a||n.complete()}))},n)},f=0;f<o;f++)c(f)},n)}}function d(t,e,r){t?(0,f.N)(r,t,e):e()}},38299:(t,e,r)=>{"use strict";r.d(e,{Tg:()=>y});var n=r(49303),o=r(32812),i=r(383),s=r(65132),a=r(85226),u=r(40316),c=r(8381),l=r(49696),f=r(6137),h=r(70418),p=r(27763),d=r(24355);function y(t){if(t instanceof s.c)return t;if(null!=t){var e,r,y,b,m;if((0,a.l)(t)){return e=t,new s.c(function(t){var r=e[d.s]();if((0,h.T)(r.subscribe))return r.subscribe(t);throw TypeError("Provided object does not correctly implement Symbol.observable")})}if((0,o.X)(t)){return r=t,new s.c(function(t){for(var e=0;e<r.length&&!t.closed;e++)t.next(r[e]);t.complete()})}if((0,i.y)(t)){return y=t,new s.c(function(t){y.then(function(e){t.closed||(t.next(e),t.complete())},function(e){return t.error(e)}).then(null,p.m)})}if((0,u.T)(t))return g(t);if((0,l.x)(t)){return b=t,new s.c(function(t){var e,r;try{for(var o=(0,n.Ju)(b),i=o.next();!i.done;i=o.next()){var s=i.value;if(t.next(s),t.closed)return}}catch(t){e={error:t}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(e)throw e.error}}t.complete()})}if((0,f.U)(t)){return m=t,g((0,f.C)(m))}}throw(0,c.L)(t)}function g(t){return new s.c(function(e){(function(t,e){var r,o,i,s;return(0,n.sH)(this,void 0,void 0,function(){var a;return(0,n.YH)(this,function(u){switch(u.label){case 0:u.trys.push([0,5,6,11]),r=(0,n.xN)(t),u.label=1;case 1:return[4,r.next()];case 2:if((o=u.sent()).done)return[3,4];if(a=o.value,e.next(a),e.closed)return[2];u.label=3;case 3:return[3,1];case 4:return[3,11];case 5:return i={error:u.sent()},[3,11];case 6:if(u.trys.push([6,,9,10]),!(o&&!o.done&&(s=r.return)))return[3,8];return[4,s.call(r)];case 7:u.sent(),u.label=8;case 8:return[3,10];case 9:if(i)throw i.error;return[7];case 10:return[7];case 11:return e.complete(),[2]}})})})(t,e).catch(function(t){return e.error(t)})})}},40316:(t,e,r)=>{"use strict";r.d(e,{T:()=>o});var n=r(70418);function o(t){return Symbol.asyncIterator&&(0,n.T)(null==t?void 0:t[Symbol.asyncIterator])}},41751:(t,e,r)=>{"use strict";r.d(e,{Y:()=>i,l:()=>s});var n=r(9615),o=null;function i(t){if(n.$.useDeprecatedSynchronousErrorHandling){var e=!o;if(e&&(o={errorThrown:!1,error:null}),t(),e){var r=o,i=r.errorThrown,s=r.error;if(o=null,i)throw s}}else t()}function s(t){n.$.useDeprecatedSynchronousErrorHandling&&o&&(o.errorThrown=!0,o.error=t)}},42803:(t,e,r)=>{"use strict";r.d(e,{C:()=>s,Q:()=>c});var n={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},i=[,,,,].fill(String.fromCodePoint(o[0])).join("");function s(t,e,r="auto"){let n;return!0===r||"auto"===r&&(!(!Number.isNaN(Number(t))||/[a-z]/i.test(t)&&!/\d+(?:[-:\/]\d+){2}(?:T\d+(?:[-:\/]\d+){1,2}(\.\d+)?Z?)?/.test(t))&&Date.parse(t)||function(t){try{new URL(t,t.startsWith("/")?"https://acme.com":void 0)}catch{return!1}return!0}(t))?t:`${t}${n=JSON.stringify(e),`${i}${Array.from(n).map(t=>{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 a=`${Object.values(n).map(t=>`\\u{${t.toString(16)}}`).join("")}`,u=RegExp(`[${a}]{4,}`,"gu");function c(t){var e,r;return t&&JSON.parse({cleaned:(e=JSON.stringify(t)).replace(u,""),encoded:(null==(r=e.match(u))?void 0:r[0])||""}.cleaned)}},44267:(t,e,r)=>{"use strict";r.d(e,{m:()=>
1o});var n=r(70418);function o(t){return t&&(0,n.T)(t.schedule)}},45426:(t,e,r)=>{"use strict";r.d(e,{s:()=>o});var n=r(22227);function o(t,e){var r="object"==typeof e;return new Promise(function(o,i){var s,a=!1;t.subscribe({next:function(t){s=t,a=!0},error:i,complete:function(){a?o(s):r?o(e.defaultValue):i(new n.G)}})})}},46068:(t,e,r)=>{"use strict";r.d(e,{l:()=>n});var n="function"==typeof Symbol&&Symbol.iterator?Symbol.iterator:"@@iterator"},47006:(t,e,r)=>{"use strict";r.d(e,{Ms:()=>b,vU:()=>p});var n=r(49303),o=r(70418),i=r(90240),s=r(9615),a=r(27763),u=r(84474),c=l("C",void 0,void 0);function l(t,e,r){return{kind:t,value:e,error:r}}var f=r(24211),h=r(41751),p=function(t){function e(e){var r=t.call(this)||this;return r.isStopped=!1,e?(r.destination=e,(0,i.Uv)(e)&&e.add(r)):r.destination=w,r}return(0,n.C6)(e,t),e.create=function(t,e,r){return new b(t,e,r)},e.prototype.next=function(t){this.isStopped?v(l("N",t,void 0),this):this._next(t)},e.prototype.error=function(t){this.isStopped?v(l("E",void 0,t),this):(this.isStopped=!0,this._error(t))},e.prototype.complete=function(){this.isStopped?v(c,this):(this.isStopped=!0,this._complete())},e.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,t.prototype.unsubscribe.call(this),this.destination=null)},e.prototype._next=function(t){this.destination.next(t)},e.prototype._error=function(t){try{this.destination.error(t)}finally{this.unsubscribe()}},e.prototype._complete=function(){try{this.destination.complete()}finally{this.unsubscribe()}},e}(i.yU),d=Function.prototype.bind;function y(t,e){return d.call(t,e)}var g=function(){function t(t){this.partialObserver=t}return t.prototype.next=function(t){var e=this.partialObserver;if(e.next)try{e.next(t)}catch(t){m(t)}},t.prototype.error=function(t){var e=this.partialObserver;if(e.error)try{e.error(t)}catch(t){m(t)}else m(t)},t.prototype.complete=function(){var t=this.partialObserver;if(t.complete)try{t.complete()}catch(t){m(t)}},t}(),b=function(t){function e(e,r,n){var i,a,u=t.call(this)||this;return(0,o.T)(e)||!e?i={next:null!=e?e:void 0,error:null!=r?r:void 0,complete:null!=n?n:void 0}:u&&s.$.useDeprecatedNextContext?((a=Object.create(e)).unsubscribe=function(){return u.unsubscribe()},i={next:e.next&&y(e.next,a),error:e.error&&y(e.error,a),complete:e.complete&&y(e.complete,a)}):i=e,u.destination=new g(i),u}return(0,n.C6)(e,t),e}(p);function m(t){s.$.useDeprecatedSynchronousErrorHandling?(0,h.l)(t):(0,a.m)(t)}function v(t,e){var r=s.$.onStoppedNotification;r&&f.f.setTimeout(function(){return r(t,e)})}var w={closed:!0,next:u.l,error:function(t){throw t},complete:u.l}},49303:(t,e,r)=>{"use strict";r.d(e,{AQ:()=>h,C6:()=>o,Cl:()=>i,Ju:()=>u,N3:()=>f,YH:()=>a,fX:()=>l,sH:()=>s,xN:()=>p,zs:()=>c});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;r<n;r++)for(var o in e=arguments[r])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t}).apply(this,arguments)};function s(t,e,r,n){return new(r||(r=Promise))(function(o,i){function s(t){try{u(n.next(t))}catch(t){i(t)}}function a(t){try{u(n.throw(t))}catch(t){i(t)}}function u(t){var e;t.done?o(t.value):((e=t.value)instanceof r?e:new r(function(t){t(e)})).then(s,a)}u((n=n.apply(t,e||[])).next())})}function a(t,e){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},s=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return s.next=a(0),s.throw=a(1),s.return=a(2),"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(a){return function(u){var c=[a,u];if(r)throw TypeError("Generator is already executing.");for(;s&&(s=0,c[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&c[0]?n.return:c[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,c[1])).done)return o;switch(n=0,o&&(c=[2&c[0],o.value]),c[0]){case 0:case 1:o=c;break;case 4:return i.label++,{value:c[1],done:!1};case 5:i.label++,n=c[1],c=[0];continue;case 7:c=i.ops.pop(),i.trys.pop();continue;default:if(!(o=(o=i.trys).length>0&&o[o.length-1])&&(6===c[0]||2===c[0])){i=0;continue}if(3===c[0]&&(!o||c[1]>o[0]&&c[1]<o[3])){i.label=c[1];break}if(6===c[0]&&i.label<o[1]){i.label=o[1],o=c;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(c);break}o[2]&&i.ops.pop(),i.trys.pop();continue}c=e.call(t,i)}catch(t){c=[6,t],n=0}
1finally{r=o=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}}}function u(t){var e="function"==typeof Symbol&&Symbol.iterator,r=e&&t[e],n=0;if(r)return r.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&n>=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 l(t,e,r){if(r||2==arguments.length)for(var n,o=0,i=e.length;o<i;o++)!n&&o in e||(n||(n=Array.prototype.slice.call(e,0,o)),n[o]=e[o]);return t.concat(n||Array.prototype.slice.call(e))}function f(t){return this instanceof f?(this.v=t,this):new f(t)}function h(t,e,r){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var n,o=r.apply(t,e||[]),i=[];return n=Object.create(("function"==typeof AsyncIterator?AsyncIterator:Object).prototype),s("next"),s("throw"),s("return",function(t){return function(e){return Promise.resolve(e).then(t,c)}}),n[Symbol.asyncIterator]=function(){return this},n;function s(t,e){o[t]&&(n[t]=function(e){return new Promise(function(r,n){i.push([t,e,r,n])>1||a(t,e)})},e&&(n[t]=e(n[t])))}function a(t,e){try{var r;(r=o[t](e)).value instanceof f?Promise.resolve(r.value.v).then(u,c):l(i[0][2],r)}catch(t){l(i[0][3],t)}}function u(t){a("next",t)}function c(t){a("throw",t)}function l(t,e){t(e),i.shift(),i.length&&a(i[0][0],i[0][1])}}function p(t){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var e,r=t[Symbol.asyncIterator];return r?r.call(t):(t=u(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){var i,s,a;i=n,s=o,a=(e=t[r](e)).done,Promise.resolve(e.value).then(function(t){i({value:t,done:a})},s)})}}}Object.create,Object.create,"function"==typeof SuppressedError&&SuppressedError},49304:(t,e,r)=>{"use strict";var n=r(26801),o=r(81852),i="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;function s(t){if(t>0x7fffffff)throw RangeError('The value "'+t+'" is invalid for option "size"');var e=new Uint8Array(t);return Object.setPrototypeOf(e,a.prototype),e}function a(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 l(t)}return u(t,e,r)}function u(t,e,r){if("string"==typeof t){var n=t,o=e;if(("string"!=typeof o||""===o)&&(o="utf8"),!a.isEncoding(o))throw TypeError("Unknown encoding: "+o);var i=0|d(n,o),u=s(i),c=u.write(n,o);return c!==i&&(u=u.slice(0,c)),u}if(ArrayBuffer.isView(t)){var l=t;if(S(l,Uint8Array)){var y=new Uint8Array(l);return h(y.buffer,y.byteOffset,y.byteLength)}return f(l)}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 g=t.valueOf&&t.valueOf();if(null!=g&&g!==t)return a.from(g,e,r);var b=function(t){if(a.isBuffer(t)){var e=0|p(t.length),r=s(e);return 0===r.length||t.copy(r,0,0,e),r}return void 0!==t.length?"number"!=typeof t.length||function(t){return t!=t}(t.length)?s(0):f(t):"Buffer"===t.type&&Array.isArray(t.data)?f(t.data):void 0}(t);if(b)return b;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof t[Symbol.toPrimitive])return a.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');
vendor: 16,403 bytes, line 1
1if(t<0)throw RangeError('The value "'+t+'" is invalid for option "size"')}function l(t){return c(t),s(t<0?0:0|p(t))}function f(t){for(var e=t.length<0?0:0|p(t.length),r=s(e),n=0;n<e;n+=1)r[n]=255&t[n];return r}function h(t,e,r){var n;if(e<0||t.byteLength<e)throw RangeError('"offset" is outside of buffer bounds');if(t.byteLength<e+(r||0))throw RangeError('"length" is outside of buffer bounds');return Object.setPrototypeOf(n=void 0===e&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,e):new Uint8Array(t,e,r),a.prototype),n}function p(t){if(t>=0x7fffffff)throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x7fffffff bytes");return 0|t}function d(t,e){if(a.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 R(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return O(t).length;default:if(o)return n?-1:R(t).length;e=(""+e).toLowerCase(),o=!0}}function y(t,e,r){var o,i,s,a=!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;i<r;++i)o+=j[t[i]];return o}(this,e,r);case"utf8":case"utf-8":return v(this,e,r);case"ascii":return function(t,e,r){var n="";r=Math.min(t.length,r);for(var o=e;o<r;++o)n+=String.fromCharCode(127&t[o]);return n}(this,e,r);case"latin1":case"binary":return function(t,e,r){var n="";r=Math.min(t.length,r);for(var o=e;o<r;++o)n+=String.fromCharCode(t[o]);return n}(this,e,r);case"base64":return o=this,i=e,s=r,0===i&&s===o.length?n.fromByteArray(o):n.fromByteArray(o.slice(i,s));case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return function(t,e,r){for(var n=t.slice(e,r),o="",i=0;i<n.length-1;i+=2)o+=String.fromCharCode(n[i]+256*n[i+1]);return o}(this,e,r);default:if(a)throw TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),a=!0}}function g(t,e,r){var n=t[e];t[e]=t[r],t[r]=n}function b(t,e,r,n,o){var i;if(0===t.length)return -1;if("string"==typeof r?(n=r,r=0):r>0x7fffffff?r=0x7fffffff:r<-0x80000000&&(r=-0x80000000),(i=r*=1)!=i&&(r=o?0:t.length-1),r<0&&(r=t.length+r),r>=t.length)if(o)return -1;else r=t.length-1;else if(r<0)if(!o)return -1;else r=0;if("string"==typeof e&&(e=a.from(e,n)),a.isBuffer(e))return 0===e.length?-1:m(t,e,r,n,o);if("number"==typeof e){if(e&=255,"function"==typeof Uint8Array.prototype.indexOf)if(o)return Uint8Array.prototype.indexOf.call(t,e,r);else return Uint8Array.prototype.lastIndexOf.call(t,e,r);return m(t,[e],r,n,o)}throw TypeError("val must be string, number or Buffer")}function m(t,e,r,n,o){var i,s=1,a=t.length,u=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,a/=2,u/=2,r/=2}function c(t,e){return 1===s?t[e]:t.readUInt16BE(e*s)}if(o){var l=-1;for(i=r;i<a;i++)if(c(t,i)===c(e,-1===l?0:i-l)){if(-1===l&&(l=i),i-l+1===u)return l*s}else -1!==l&&(i-=i-l),l=-1}else for(r+u>a&&(r=a-u),i=r;i>=0;i--){for(var f=!0,h=0;h<u;h++)if(c(t,i+h)!==c(e,h)){f=!1;break}if(f)return i}return -1}function v(t,e,r){r=Math.min(t.length,r);for(var n=[],o=e;o<r;){var i,s,a,u,c=t[o],l=null,f=c>239?4:c>223?3:c>191?2:1;if(o+f<=r)switch(f){case 1:c<128&&(l=c);break;case 2:(192&(i=t[o+1]))==128&&(u=(31&c)<<6|63&i)>127&&(l=u);break;case 3:i=t[o+1],s=t[o+2],(192&i)==128&&(192&s)==128&&(u=(15&c)<<12|(63&i)<<6|63&s)>2047&&(u<55296||u>57343)&&(l=u);break;case 4:i=t[o+1],s=t[o+2],a=t[o+3],(192&i)==128&&(192&s)==128&&(192&a)==128&&(u=(15&c)<<18|(63&i)<<12|(63&s)<<6|63&a)>65535&&u<1114112&&(l=u)}null===l?(l=65533,f=1):l>65535&&(l-=65536,n.push(l>>>10&1023|55296),l=56320|1023&l),n.push(l),o+=f}var h=n,p=h.length;if(p<=4096)return String.fromCharCode.apply(String,h);for(var d="",y=0;y<p;)d+=String.fromCharCode.apply(String,h.slice(y,y+=4096));return d}function w(t,e,r){if(t%1!=0||t<0)throw RangeError("offset is not uint");if(t+e>r)throw RangeError("Trying to access beyond buffer length")}function E(t,e,r,n,o,i){if(!a.isBuffer(t))throw TypeError('"buffer" argument must be a Buffer instance');if(e>o||e<i)throw RangeError('"value" argument is out of bounds');if(r+n>t.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 x(t,e,r,n,i){return e*=1,r>>>=0,i||C(t,e,r,4,34028234663852886e22,-34028234663852886e22),o.write(t,e,r,n,23,4),r+4}function A(t,e,r,n,i){return e*=1,r>>>=0,i||C(t,e,r,8,17976931348623157e292,-17976931348623157e292),o.write(t,e,r,n,52,8),r+8}e.hp=a,e.IS=50,a.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}}(),a.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(a.prototype,"parent",{enumerable:!0,get:function(){if(a.isBuffer(this))return this.buffer}}),Object.defineProperty(a.prototype,"offset",{enumerable:!0,get:function(){if(a.isBuffer(this))return this.byteOffset}}),a.poolSize=8192,a.from=function(t,e,r){return u(t,e,r)},Object.setPrototypeOf(a.prototype,Uint8Array.prototype),Object.setPrototypeOf(a,Uint8Array),a.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)},a.allocUnsafe=function(t){return l(t)},a.allocUnsafeSlow=function(t){return l(t)},a.isBuffer=function(t){return null!=t&&!0===t._isBuffer&&t!==a.prototype},a.compare=function(t,e){if(S(t,Uint8Array)&&(t=a.from(t,t.offset,t.byteLength)),S(e,Uint8Array)&&(e=a.from(e,e.offset,e.byteLength)),!a.isBuffer(t)||!a.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);o<i;++o)if(t[o]!==e[o]){r=t[o],n=e[o];break}return r<n?-1:+(n<r)},a.isEncoding=function(t){switch(String(t).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},a.concat=function(t,e){if(!Array.isArray(t))throw TypeError('"list" argument must be an Array of Buffers');if(0===t.length)return a.alloc(0);if(void 0===e)for(r=0,e=0;r<t.length;++r)e+=t[r].length;var r,n=a.allocUnsafe(e),o=0;for(r=0;r<t.length;++r){var i=t[r];if(S(i,Uint8Array))o+i.length>n.length?a.from(i).copy(n,o):Uint8Array.prototype.set.call(n,i,o);else if(a.isBuffer(i))i.copy(n,o);else throw TypeError('"list" argument must be an Array of Buffers');o+=i.length}return n},a.byteLength=d,a.prototype._isBuffer=!0,a.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;e<t;e+=2)g(this,e,e+1);return this},a.prototype.swap32=function(){var t=this.length;if(t%4!=0)throw RangeError("Buffer size must be a multiple of 32-bits");for(var e=0;e<t;e+=4)g(this,e,e+3),g(this,e+1,e+2);return this},a.prototype.swap64=function(){var t=this.length;if(t%8!=0)throw RangeError("Buffer size must be a multiple of 64-bits");for(var e=0;e<t;e+=8)g(this,e,e+7),g(this,e+1,e+6),g(this,e+2,e+5),g(this,e+3,e+4);return this},a.prototype.toString=function(){var t=this.length;return 0===t?"":0==arguments.length?v(this,0,t):y.apply(this,arguments)},a.prototype.toLocaleString=a.prototype.toString,a.prototype.equals=function(t){if(!a.isBuffer(t))throw TypeError("Argument must be a Buffer");return this===t||0===a.compare(this,t)},a.prototype.inspect=function(){var t="",r=e.IS;return t=this.toString("hex",0,r).replace(/(.{2})/g,"$1 ").trim(),this.length>r&&(t+=" ... "),"<Buffer "+t+">"},i&&(a.prototype[i]=a.prototype.inspect),a.prototype.compare=function(t,e,r,n,o){if(S(t,Uint8Array)&&(t=a.from(t,t.offset,t.byteLength)),!a.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,u=Math.min(i,s),c=this.slice(n,o),l=t.slice(e,r),f=0;f<u;++f)if(c[f]!==l[f]){i=c[f],s=l[f];break}return i<s?-1:+(s<i)},a.prototype.includes=function(t,e,r){return -1!==this.indexOf(t,e,r)},a.prototype.indexOf=function(t,e,r){return b(this,t,e,r,!0)},a.prototype.lastIndexOf=function(t,e,r){return b(this,t,e,r,!1)},a.prototype.write=function(t,e,r,n){if(void 0===e)n="utf8",r=this.length,e=0;else if(void 0===r&&"string"==typeof e)n=e,r=this.length,e=0;else if(isFinite(e))e>>>=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,a,u,c,l,f,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<n;++s){var a,u=parseInt(e.substr(2*s,2),16);if((a=u)!=a)break;t[r+s]=u}return s}(this,t,e,r);case"utf8":case"utf-8":return o=e,i=r,I(R(t,this.length-o),this,o,i);case"ascii":case"latin1":case"binary":return s=e,a=r,I(function(t){for(var e=[],r=0;r<t.length;++r)e.push(255&t.charCodeAt(r));return e}(t),this,s,a);case"base64":return u=e,c=r,I(O(t),this,u,c);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return l=e,f=r,I(function(t,e){for(var r,n,o=[],i=0;i<t.length&&!((e-=2)<0);++i)n=(r=t.charCodeAt(i))>>8,o.push(r%256),o.push(n);return o}(t,this.length-l),this,l,f);default:if(p)throw TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),p=!0}},a.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}},a.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<t&&(e=t);var n=this.subarray(t,e);return Object.setPrototypeOf(n,a.prototype),n},a.prototype.readUintLE=a.prototype.readUIntLE=function(t,e,r){t>>>=0,e>>>=0,r||w(t,e,this.length);for(var n=this[t],o=1,i=0;++i<e&&(o*=256);)n+=this[t+i]*o;return n},a.prototype.readUintBE=a.prototype.readUIntBE=function(t,e,r){t>>>=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},a.prototype.readUint8=a.prototype.readUInt8=function(t,e){return t>>>=0,e||w(t,1,this.length),this[t]},a.prototype.readUint16LE=a.prototype.readUInt16LE=function(t,e){return t>>>=0,e||w(t,2,this.length),this[t]|this[t+1]<<8},a.prototype.readUint16BE=a.prototype.readUInt16BE=function(t,e){return t>>>=0,e||w(t,2,this.length),this[t]<<8|this[t+1]},a.prototype.readUint32LE=a.prototype.readUInt32LE=function(t,e){return t>>>=0,e||w(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+0x1000000*this[t+3]},a.prototype.readUint32BE=a.prototype.readUInt32BE=function(t,e){return t>>>=0,e||w(t,4,this.length),0x1000000*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},a.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<e&&(o*=256);)n+=this[t+i]*o;return n>=(o*=128)&&(n-=Math.pow(2,8*e)),n},a.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},a.prototype.readInt8=function(t,e){return(t>>>=0,e||w(t,1,this.length),128&this[t])?-((255-this[t]+1)*1):this[t]},a.prototype.readInt16LE=function(t,e){t>>>=0,e||w(t,2,this.length);var r=this[t]|this[t+1]<<8;return 32768&r?0xffff0000|r:r},a.prototype.readInt16BE=function(t,e){t>>>=0,e||w(t,2,this.length);var r=this[t+1]|this[t]<<8;return 32768&r?0xffff0000|r:r},a.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},a.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]},a.prototype.readFloatLE=function(t,e){return t>>>=0,e||w(t,4,this.length),o.read(this,t,!0,23,4)},a.prototype.readFloatBE=function(t,e){return t>>>=0,e||w(t,4,this.length),o.read(this,t,!1,23,4)},a.prototype.readDoubleLE=function(t,e){return t>>>=0,e||w(t,8,this.length),o.read(this,t,!0,52,8)},a.prototype.readDoubleBE=function(t,e){return t>>>=0,e||w(t,8,this.length),o.read(this,t,!1,52,8)},a.prototype.writeUintLE=a.prototype.writeUIntLE=function(t,e,r,n){if(t*=1,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<r&&(i*=256);)this[e+s]=t/i&255;return e+r},a.prototype.writeUintBE=a.prototype.writeUIntBE=function(t,e,r,n){if(t*=1,e>>>=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},a.prototype.writeUint8=a.prototype.writeUInt8=function(t,e,r){return t*=1,e>>>=0,r||E(this,t,e,1,255,0),this[e]=255&t,e+1},a.prototype.writeUint16LE=a.prototype.writeUInt16LE=function(t,e,r){return t*=1,e>>>=0,r||E(this,t,e,2,65535,0),this[e]=255&t,this[e+1]=t>>>8,e+2},a.prototype.writeUint16BE=a.prototype.writeUInt16BE=function(t,e,r){return t*=1,e>>>=0,r||E(this,t,e,2,65535,0),this[e]=t>>>8,this[e+1]=255&t,e+2},a.prototype.writeUint32LE=a.prototype.writeUInt32LE=function(t,e,r){return t*=1,e>>>=0,r||E(this,t,e,4,0xffffffff,0),this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=255&t,e+4},a.prototype.writeUint32BE=a.prototype.writeUInt32BE=function(t,e,r){return t*=1,e>>>=0,r||E(this,t,e,4,0xffffffff,0),this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t,e+4},a.prototype.writeIntLE=function(t,e,r,n){if(t*=1,e>>>=0,!n){var o=Math.pow(2,8*r-1);E(this,t,e,r,o-1,-o)}var i=0,s=1,a=0;for(this[e]=255&t;++i<r&&(s*=256);)t<0&&0===a&&0!==this[e+i-1]&&(a=1),this[e+i]=(t/s|0)-a&255;return e+r},a.prototype.writeIntBE=function(t,e,r,n){if(t*=1,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,a=0;for(this[e+i]=255&t;--i>=0&&(s*=256);)t<0&&0===a&&0!==this[e+i+1]&&(a=1),this[e+i]=(t/s|0)-a&255;return e+r},a.prototype.writeInt8=function(t,e,r){return t*=1,e>>>=0,r||E(this,t,e,1,127,-128),t<0&&(t=255+t+1),this[e]=255&t,e+1},a.prototype.writeInt16LE=function(t,e,r){return t*=1,e>>>=0,r||E(this,t,e,2,32767,-32768),this[e]=255&t,this[e+1]=t>>>8,e+2},a.prototype.writeInt16BE=function(t,e,r){return t*=1,e>>>=0,r||E(this,t,e,2,32767,-32768),this[e]=t>>>8,this[e+1]=255&t,e+2},a.prototype.writeInt32LE=function(t,e,r){return t*=1,e>>>=0,r||E(this,t,e,4,0x7fffffff,-0x80000000),this[e]=255&t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24,e+4},a.prototype.writeInt32BE=function(t,e,r){return t*=1,e>>>=0,r||E(this,t,e,4,0x7fffffff,-0x80000000),t<0&&(t=0xffffffff+t+1),this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t,e+4},a.prototype.writeFloatLE=function(t,e,r){return x(this,t,e,!0,r)},a.prototype.writeFloatBE=function(t,e,r){return x(this,t,e,!1,r)},a.prototype.writeDoubleLE=function(t,e,r){return A(this,t,e,!0,r)},a.prototype.writeDoubleBE=function(t,e,r){return A(this,t,e,!1,r)},a.prototype.copy=function(t,e,r,n){if(!a.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<r&&(n=r),n===r||0===t.length||0===this.length)return 0;if(e<0)throw RangeError("targetStart out of bounds");if(r<0||r>=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<n-r&&(n=t.length-e+r);var o=n-r;return this===t&&"function"==typeof Uint8Array.prototype.copyWithin?this.copyWithin(e,r,n):Uint8Array.prototype.set.call(t,this.subarray(r,n),e),o}
1,a.prototype.fill=function(t,e,r,n){if("string"==typeof t){if("string"==typeof e?(n=e,e=0,r=this.length):"string"==typeof r&&(n=r,r=this.length),void 0!==n&&"string"!=typeof n)throw TypeError("encoding must be a string");if("string"==typeof n&&!a.isEncoding(n))throw TypeError("Unknown encoding: "+n);if(1===t.length){var o,i=t.charCodeAt(0);("utf8"===n&&i<128||"latin1"===n)&&(t=i)}}else"number"==typeof t?t&=255:"boolean"==typeof t&&(t=Number(t));if(e<0||this.length<e||this.length<r)throw RangeError("Out of range index");if(r<=e)return this;if(e>>>=0,r=void 0===r?this.length:r>>>0,t||(t=0),"number"==typeof t)for(o=e;o<r;++o)this[o]=t;else{var s=a.isBuffer(t)?t:a.from(t,n),u=s.length;if(0===u)throw TypeError('The value "'+t+'" is invalid for argument "value"');for(o=0;o<r-e;++o)this[o+e]=s[o%u]}return this};var T=/[^+/0-9A-Za-z-_]/g;function R(t,e){e=e||1/0;for(var r,n=t.length,o=null,i=[],s=0;s<n;++s){if((r=t.charCodeAt(s))>55295&&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 O(t){return n.toByteArray(function(t){if((t=(t=t.split("=")[0]).trim().replace(T,"")).length<2)return"";for(;t.length%4!=0;)t+="=";return t}(t))}function I(t,e,r,n){for(var o=0;o<n&&!(o+r>=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}()},49395:(t,e,r)=>{"use strict";r.d(e,{K:()=>o});var n=Array.isArray;function o(t){return 1===t.length&&n(t[0])?t[0]:t}},49696:(t,e,r)=>{"use strict";r.d(e,{x:()=>i});var n=r(46068),o=r(70418);function i(t){return(0,o.T)(null==t?void 0:t[n.l])}},53196:(t,e,r)=>{"use strict";r.d(e,{D:()=>a});var n=Array.isArray,o=Object.getPrototypeOf,i=Object.prototype,s=Object.keys;function a(t){if(1===t.length){var e,r=t[0];if(n(r))return{args:r,keys:null};if((e=r)&&"object"==typeof e&&o(e)===i){var a=s(r);return{args:a.map(function(t){return r[t]}),keys:a}}}return{args:t,keys:null}}},65132:(t,e,r)=>{"use strict";r.d(e,{c:()=>l});var n=r(47006),o=r(90240),i=r(24355),s=r(89166),a=r(9615),u=r(70418),c=r(41751),l=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=this,s=!function(t){return t&&t instanceof n.vU||t&&(0,u.T)(t.next)&&(0,u.T)(t.error)&&(0,u.T)(t.complete)&&(0,o.Uv)(t)}(t)?new n.Ms(t,e,r):t;return(0,c.Y)(function(){var t=i.operator,e=i.source;s.add(t?t.call(s,e):e?i._subscribe(s):i._trySubscribe(s))}),s},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=f(e))(function(e,o){var i=new n.Ms({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.subscribe(t)},t.prototype[i.s]=function(){return this},t.prototype.pipe=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return(0,s.m)(t)(this)},t.prototype.toPromise=function(t){var e=this;return new(t=f(t))(function(t,r){var n;e.subscribe(function(t){return n=t},function(t){return r(t)},function(){return t(n)})})},t.create=function(e){return new t(e)},t}();function f(t){var e;return null!=(e=null!=t?t:a.$.Promise)?e:Promise}},66687:(t,e,r)=>{"use strict";r.d(e,{I:()=>s});var n=r(49303),o=r(16975),i=Array.isArray;function s(t){return(0,o.T)(function(e){return i(e)?t.apply(void 0,(0,n.fX)([],(0,n.zs)(e))):t(e)}
1)}},70418:(t,e,r)=>{"use strict";function n(t){return"function"==typeof t}r.d(e,{T:()=>n})},71361:(t,e,r)=>{"use strict";function n(t,e){if(t){var r=t.indexOf(e);0<=r&&t.splice(r,1)}}r.d(e,{o:()=>n})},71843:(t,e,r)=>{"use strict";r.d(e,{u_:()=>Z,UU:()=>eo});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 a=/^https?:\/\//i,u=function(t){if(!a.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 l=["request","response","progress","error","abort"],f=["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<n.length;o++){var i=n[o],s=i.indexOf(":"),a=h(i.slice(0,s)).toLowerCase(),u=h(i.slice(s+1));typeof r[a]>"u"?r[a]=u:(e=r[a],"[object Array]"===Object.prototype.toString.call(e)?r[a].push(u):r[a]=[r[a],u])}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 2`}),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,b=(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 a=n.headers,u=n.timeout,c=!1,l=!1,f=!1;if(s.onerror=t=>{m(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=>{m(Error(`Request timeout while attempting to reach ${n.url}${t.lengthComputable?`(${t.loaded} of ${t.total} bytes transferred)`:""}`))},s.onabort=()=>{b(!0),c=!0},s.onreadystatechange=()=>{u&&(b(),o.socket=setTimeout(()=>h("ESOCKETTIMEDOUT"),u.socket)),c||4!==s.readyState||0===s.status||function(){if(!(c||l||f)){if(0===s.status)return m(Error("Unknown XHR error"));b(),l=!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,a&&s.setRequestHeader)for(let t in a)a.hasOwnProperty(t)&&s.setRequestHeader(t,a[t]);return n.rawBody&&(s.responseType="arraybuffer"),t.applyMiddleware("onRequest",{options:n,adapter:y,request:s,context:t}),s.send(n.body||null),u&&(o.connect=setTimeout(()=>h("ETIMEDOUT"),u.connect)),{abort:function(){c=!0,s&&s.abort()}};function h(e){f=!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 b(t){(t||c||s.readyState>=2&&o.connect)&&clearTimeout(o.connect),o.socket&&clearTimeout(o.socket)}function m(t){if(l)return;b(!0),l=!0,s=null;let r=t||Error(`Network error while attempting to reach ${n.url}`);r.isNetworkError=!0,r.request=n,e(r)}};var m,v,w=r(87358),E=r(49304).hp,C={exports:{}},x=function(t){function e(t){let n,o,i,s=null;function a(...t){if(!a.enabled)return;let r=Number(new Date);a.diff=r-(n||r),a.prev=n,a.curr=r,n=r,t[0]=e.coerce(t[0]),"string"!=typeof t[0]&&t.unshift("%O");let o=0;t[0]=t[0].replace(/%([a-zA-Z%])/g,(r,n)=>{if("%%"===r)return"%";o++;let i=e.formatters[n];if("function"==typeof i){let e=t[o];r=i.call(a,e),t.splice(o,1),o--}return r}),e.formatArgs.call(a,t),(a.log||e.log).apply(a,t)}return a.namespace=t,a.useColors=e.useColors(),a.color=e.selectColor(t),a.extend=r,a.destroy=e.destroy,Object.defineProperty(a,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==s?s:(o!==e.namespaces&&(o=e.namespaces,i=e.enabled(t)),i),set
2:t=>{s=t}}),"function"==typeof e.init&&e.init(a),a}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<o;r++)n[r]&&("-"===(t=n[r].replace(/\*/g,".*?"))[0]?e.skips.push(RegExp("^"+t.slice(1)+"$")):e.names.push(RegExp("^"+t+"$")))},e.enabled=function(t){let r,n;if("*"===t[t.length-1])return!0;for(r=0,n=e.skips.length;r<n;r++)if(e.skips[r].test(t))return!1;for(r=0,n=e.names.length;r<n;r++)if(e.names[r].test(t))return!0;return!1},e.humanize=function(){if(v)return m;v=1;function t(t,e,r,n){return Math.round(t/r)+" "+n+(e>=1.5*r?"s":"")}return m=function(e,r){r=r||{};var n,o,i=typeof e;if("string"===i&&e.length>0){var s=e;if(!((s=String(s)).length>100)){var a=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(s);if(a){var u=parseFloat(a[1]);switch((a[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*u;case"weeks":case"week":case"w":return 6048e5*u;case"days":case"day":case"d":return 864e5*u;case"hours":case"hour":case"hrs":case"hr":case"h":return 36e5*u;case"minutes":case"minute":case"mins":case"min":case"m":return 6e4*u;case"seconds":case"second":case"secs":case"sec":case"s":return 1e3*u;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return u}}}return}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.length;e++)r=(r<<5)-r+t.charCodeAt(e)|0;return e.colors[Math.abs(r)%e.colors.length]},e.enable(e.load()),e};!function(t,e){let r;e.formatArgs=function(e){if(e[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+e[0]+(this.useColors?"%c ":" ")+"+"+t.exports.humanize(this.diff),!this.useColors)return;let r="color: "+this.color;e.splice(1,0,r,"color: inherit");let n=0,o=0;e[0].replace(/%[a-zA-Z%]/g,t=>{"%%"!==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 w&&"env"in w&&(t=w.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{}}(),r=!1,e.destroy=()=>{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","#33
2CCCC","#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}}}(C,C.exports),c(C.exports),Object.prototype.hasOwnProperty;let A=typeof E>"u"?()=>!1:t=>E.isBuffer(t);function T(t){return"[object Object]"===Object.prototype.toString.call(t)}let R=["boolean","string","number"],O={};"u">typeof globalThis?O=globalThis:"u">typeof window?O=window:"u">typeof global?O=global:"u">typeof self&&(O=self);var I=O;let S=(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 j{__CANCEL__=!0;message;constructor(t){this.message=t}toString(){return"Cancel"+(this.message?`: ${this.message}`:"")}}class q{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 j(t),e(this.reason))})}static source=()=>{let t;return{token:new q(e=>{t=e}),cancel:t}}}S.Cancel=j,S.CancelToken=q,S.isCancel=t=>!(!t||!t?.__CANCEL__);var U=(t,e,r)=>("GET"===r.method||"HEAD"===r.method)&&(t.isNetworkError||!1);function $(t){return 100*Math.pow(2,t)+100*Math.random()}let P=(t={})=>(t=>{let e=t.maxRetries||5,r=t.retryDelay||$,n=t.shouldRetry;return{onError:(t,o)=>{var i;let s=o.options,a=s.maxRetries||e,u=s.retryDelay||r,c=s.shouldRetry||n,l=s.attemptNumber||0;if(null!==(i=s.body)&&"object"==typeof i&&"function"==typeof i.pipe||!c(t,l,s)||l>=a)return t;let f=Object.assign({},o,{options:Object.assign({},s,{attemptNumber:l+1})});return setTimeout(()=>o.channels.request.publish(f),u(l)),null}}})({shouldRetry:U,...t});P.shouldRetry=U;var _=r(65132),k=r(97993),B=r(45426),F=r(42803),L=r(49303),N=r(36569),D=r(79619),M=r(49395),z=r(66687),H=r(89166),J=r(36171);function X(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];var r=(0,J.ms)(t);return r?(0,H.F)(X.apply(void 0,(0,L.fX)([],(0,L.zs)(t))),(0,z.I)(r)):(0,D.N)(function(e,r){(0,N.P)((0,L.fX)([e],(0,L.zs)((0,M.K)(t))))(r)})}var Y=r(16975),V=r(97561);class G extends Error{response;statusCode=400;responseBody;details;constructor(t){let e=K(t);super(e.message),Object.assign(this,e)}}class Q extends Error{response;statusCode=500;responseBody;details;constructor(t){let e=K(t);super(e.message),Object.assign(this,e)}}function K(t){var e,r,n;let o=t.body,i={response:t,statusCode:t.statusCode,responseBody:(e=o,-1!==(t.headers["content-type"]||"").toLowerCase().indexOf("application/json")?JSON.stringify(e,null,2):e),message:"",details:void 0};if(o.error&&o.message)return i.message=`${o.error} - ${o.message}`,i;if(W(r=o)&&W(r.error)&&"mutationError"===r.error.type&&"string"==typeof r.error.description||W(n=o)&&W(n.error)&&"actionError"===n.error.type&&"string"==typeof n.error.description){let t=o.error.items||[],e=t.slice(0,5).map(t=>t.error?.description).filter(Boolean),r=e.length?`: 3- ${e.join(` 4- `)}`:"";return t.length>5&&(r+=` 5...and ${t.length-5} more`),i.message=`${o.error.description}${r}`,i.details=o.error,i}return o.error&&o.error.description?(i.message=o.error.description,i.details=o.error):i.message=o.error||o.message||function(t){let e=t.statusMessage?` ${t.statusMessage}`:"";return`${t.method}-request to ${t.url} resulted in HTTP ${t.statusCode}${e}`}(t),i}function W(t){return"object"==typeof t&&null!==t&&!Array.isArray(t)}
5class Z 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 tt={onResponse:t=>{if(t.statusCode>=500)throw new Q(t);if(t.statusCode>=400)throw new G(t);return t}},te={onResponse:t=>{let e=t.headers["x-sanity-warning"];return(Array.isArray(e)?e:[e]).filter(Boolean).forEach(t=>console.warn(t)),t}};function tr(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||P.shouldRetry(t,e,r)}function tn(t){return"https://www.sanity.io/help/"+t}let to=["image","file"],ti=["before","after","replace"],ts=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,e)=>{if(null===e||"object"!=typeof e||Array.isArray(e))throw Error(`${t}() takes an object of properties`)},tu=(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`)},tc=(t,e)=>{if(!e._id)throw Error(`${t}() requires that the document contains an ID ("_id" property)`);tu(t,e._id)},tl=t=>{if(!t.dataset)throw Error("`dataset` must be provided to perform queries");return t.dataset||""},tf=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},th=t=>(function(t){let e=!1,r;return(...n)=>(e||(r=t(...n),e=!0),r)})((...e)=>console.warn(t.join(" "),...e)),tp=th(["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"]),td=th(["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."]),ty=th(["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."]),tg=th(["You have configured Sanity client to use a token in the browser. This may cause unintentional security issues.",`See ${tn("js-client-browser-token")} for more information and how to hide this warning.`]),tb=th(["Using the Sanity client without specifying an API version is deprecated.",`See ${tn("js-client-api-version")}`]),tm=(th(["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}}),tv=["localhost","127.0.0.1","0.0.0.0"];function tw(t){if(Array.isArray(t)){for(let e of t)if("published"!==e&&"drafts"!==e&&!("string"==typeof e&&e.startsWith("r")&&"raw"!==e))throw TypeError("Invalid API perspective value, expected `published`, `drafts` or a valid release identifier string");return}switch(t){case"previewDrafts":case"drafts":case"published":case"raw":return;default:throw TypeError("Invalid API perspective string, expected `published`, `previewDrafts` or `raw`")}}let tE=(t,e)=>{let r,n={...e,...t,stega:{..."boolean"==typeof e.stega?{enabled:e.stega}:e.stega||tm.stega,..."boolean"==typeof t.stega?{enabled:t.stega}:t.stega||{}}};n.apiVersion||tb();let o={...tm,...n},i=o.useProjectHostname;if(typeof Promise>"u"){let t=tn("js-client-promise-polyfill");throw Error(`No native Promise-implementation found, polyfill needed - see ${t}`)}if(i&&!o.projectId)throw Error("Configuration must contain `projectId`");if("u">typeof o.perspective&&tw(o.perspective),"encodeSourceMap"in o)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 o)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'?");
5if("boolean"!=typeof o.stega.enabled)throw Error(`stega.enabled must be a boolean, received ${o.stega.enabled}`);if(o.stega.enabled&&void 0===o.stega.studioUrl)throw Error("stega.studioUrl must be defined when stega.enabled is true");if(o.stega.enabled&&"string"!=typeof o.stega.studioUrl&&"function"!=typeof o.stega.studioUrl)throw Error(`stega.studioUrl must be a string or a function, received ${o.stega.studioUrl}`);let s="u">typeof window&&window.location&&window.location.hostname,a=s&&(r=window.location.hostname,-1!==tv.indexOf(r));s&&a&&o.token&&!0!==o.ignoreBrowserTokenWarning?tg():typeof o.useCdn>"u"&&td(),i&&(t=>{if(!/^[-a-z0-9]+$/i.test(t))throw Error("`projectId` can only contain only a-z, 0-9 and dashes")})(o.projectId),o.dataset&&ts(o.dataset),"requestTagPrefix"in o&&(o.requestTagPrefix=o.requestTagPrefix?tf(o.requestTagPrefix).replace(/\.+$/,""):void 0),o.apiVersion=`${o.apiVersion}`.replace(/^v/,""),o.isDefaultApi=o.apiHost===tm.apiHost,!0===o.useCdn&&o.withCredentials&&tp(),o.useCdn=!1!==o.useCdn&&!o.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`")}(o.apiVersion);let u=o.apiHost.split("://",2),c=u[0],l=u[1],f=o.isDefaultApi?"apicdn.sanity.io":l;return o.useProjectHostname?(o.url=`${c}://${o.projectId}.${l}/v${o.apiVersion}`,o.cdnUrl=`${c}://${o.projectId}.${f}/v${o.apiVersion}`):(o.url=`${o.apiHost}/v${o.apiVersion}`,o.cdnUrl=o.url),o};function tC(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 (<docId>)","* Array of document IDs","* Object containing `query`"].join(` 6`);throw Error(`Unknown selection - must be one of: 7 8${e}`)}class tx{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 ta("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((t,e,r)=>{let n="insert(at, selector, items)";if(-1===ti.indexOf(t)){let t=ti.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`)})(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{...tC(this.selection),...this.operations}}toJSON(){return this.serialize()}reset(){return this.operations={},this}_assign(t,e,r=!0){return ta(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 tA extends tx{#a;constructor(t,e,r){super(t,e),this.#a=r}clone(){return new tA(this.selection,{...this.operations},this.#a)}commit(t){if(!this.#a)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.#a.mutate({patch:this.serialize()},e)}}class tT extends tx{#a;constructor(t,e,r){super(t,e),this.#a=r}clone(){return new tT(this.selection,{...this.operations},this.#a)}commit(t){if(!this.#a)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.#a.mutate({patch:this.serialize()},e)}}let tR={returnDocuments:!1};class tO{operations;trxId;constructor(t=[],e){this.operations=t,this.trxId=e}create(t){return ta("create",t),this._add({create:t})}createIfNotExists(t){let e="createIfNotExists";return ta(e,t),tc(e,t),this._add({[e]:t})}createOrReplace(t){let e="createOrReplace";return ta(e,t),tc(e,t),this._add({[e]:t})}delete(t){return tu("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 tI extends tO{#a;constructor(t,e,r){super(t,r),this.#a=e}clone(){return new tI([...this.operations],this.#a,this.trxId)}commit(t){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},tR,t||{}))}patch(t,e){let r="function"==typeof e;if("string"!=typeof t&&t instanceof tT)return this._add({patch:t.serialize()});if(r){let r=e(new tT(t,{},this.#a));if(!(r instanceof tT))throw Error("function passed to `patch()` must return the patch");return this._add({patch:r.serialize()})}return this._add({patch:{id:t,...e}})}}class tS extends tO{#a;constructor(t,e,r){super(t,r),this.#a=e}clone(){return new tS([...this.operations],this.#a,this.trxId)}commit(t){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},tR,t||{}))}patch(t,e){let r="function"==typeof e;if("string"!=typeof t&&t instanceof tA)return this._add({patch:t.serialize()});if(r){let r=e(new tA(t,{},this.#a));if(!(r instanceof tA))throw Error("function passed to `patch()` must return the patch");return this._add({patch:r.serialize()})}return this._add({patch:{id:t,...e}})}}let tj=({query:t,params:e={},options:r={}})=>{let n=new URLSearchParams,{tag:o,includeMutations:i,returnQuery:s,...a}=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(a))e&&n.append(t,`${e}`);return!1===s&&n.append("returnQuery","false"),!1===i&&n.append("includeMutations","fal
8se"),`?${n}`},tq=t=>"response"===t.type,tU=t=>t.body;function t$(t,e,n,o,i={},s={}){let a="stega"in s?{...n||{},..."boolean"==typeof s.stega?{enabled:s.stega}:s.stega||{}}:n,u=a.enabled?(0,F.Q)(i):i,c=!1===s.filterResponse?t=>t:t=>t.result,{cache:l,next:f,...h}={useAbortSignal:"u">typeof s.signal,resultSourceMap:a.enabled?"withKeyArraySelector":s.resultSourceMap,...s,returnQuery:!1===s.filterResponse&&!1!==s.returnQuery},p=tD(t,e,"query",{query:o,params:u},"u">typeof l||"u">typeof f?{...h,fetch:{cache:l,next:f}}:h);return a.enabled?p.pipe(function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return X.apply(void 0,(0,L.fX)([],(0,L.zs)(t)))}((0,k.H)(r.e(8197).then(r.bind(r,8197)).then(function(t){return t.stegaEncodeSourceMap$1}).then(({stegaEncodeSourceMap:t})=>t))),(0,Y.T)(([t,e])=>{let r=e(t.result,t.resultSourceMap,a);return c({...t,result:r})})):p.pipe((0,Y.T)(c))}function tP(t,e,r,n={}){let o={uri:tJ(t,"doc",r),json:!0,tag:n.tag,signal:n.signal};return tz(t,e,o).pipe((0,V.p)(tq),(0,Y.T)(t=>t.body.documents&&t.body.documents[0]))}function t_(t,e,r,n={}){let o={uri:tJ(t,"doc",r.join(",")),json:!0,tag:n.tag,signal:n.signal};return tz(t,e,o).pipe((0,V.p)(tq),(0,Y.T)(t=>{let e,n,o=(e=t.body.documents||[],n=t=>t._id,e.reduce((t,e)=>(t[n(e)]=e,t),Object.create(null)));return r.map(t=>o[t]||null)}))}function tk(t,e,r,n){return tc("createIfNotExists",r),tM(t,e,r,"createIfNotExists",n)}function tB(t,e,r,n){return tc("createOrReplace",r),tM(t,e,r,"createOrReplace",n)}function tF(t,e,r,n){return tD(t,e,"mutate",{mutations:[{delete:tC(r)}]},n)}function tL(t,e,r,n){let o;return tD(t,e,"mutate",{mutations:Array.isArray(o=r instanceof tT||r instanceof tA?{patch:r.serialize()}:r instanceof tI||r instanceof tS?r.serialize():r)?o:[o],transactionId:n&&n.transactionId||void 0},n)}function tN(t,e,r,n){let o=Array.isArray(r)?r:[r],i=n&&n.transactionId||void 0;return tD(t,e,"actions",{actions:o,transactionId:i,skipCrossDatasetReferenceValidation:n&&n.skipCrossDatasetReferenceValidation||void 0,dryRun:n&&n.dryRun||void 0},n)}function tD(t,e,r,n,o={}){let i="mutate"===r,s="actions"===r,a=i||s?"":tj(n),u=!i&&!s&&a.length<11264,c=u?a:"",l=o.returnFirst,{timeout:f,token:h,tag:p,headers:d,returnQuery:y,lastLiveEventId:g,cacheMode:b}=o,m={method:u?"GET":"POST",uri:tJ(t,r,c),json:!0,body:u?void 0:n,query:i&&((t={})=>{let e,r;return{dryRun:t.dryRun,returnIds:!0,returnDocuments:(e=t.returnDocuments,r=!0,!1===e?void 0:typeof e>"u"?r:e),visibility:t.visibility||"sync",autoGenerateArrayKeys:t.autoGenerateArrayKeys,skipCrossDatasetReferenceValidation:t.skipCrossDatasetReferenceValidation}})(o),timeout:f,headers:d,token:h,tag:p,returnQuery:y,perspective:o.perspective,resultSourceMap:o.resultSourceMap,lastLiveEventId:Array.isArray(g)?g[0]:g,cacheMode:b,canUseCdn:"query"===r,signal:o.signal,fetch:o.fetch,useAbortSignal:o.useAbortSignal,useCdn:o.useCdn};return tz(t,e,m).pipe((0,V.p)(tq),(0,Y.T)(tU),(0,Y.T)(t=>{if(!i)return t;let e=t.results||[];if(o.returnDocuments)return l?e[0]&&e[0].document:e.map(t=>t.document);let r=l?e[0]&&e[0].id:e.map(t=>t.id);return{transactionId:t.transactionId,results:e,[l?"documentId":"documentIds"]:r}}))}function tM(t,e,r,n,o={}){return tD(t,e,"mutate",{mutations:[{[n]:r}]},Object.assign({returnFirst:!0,returnDocuments:!0},o))}function tz(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,a=(r.useCdn??i.useCdn)&&s,u=r.tag&&i.requestTagPrefix?[i.requestTagPrefix,r.tag].join("."):r.tag||i.requestTagPrefix;if(u&&null!==r.tag&&(r.query={tag:tf(u),...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;"u">typeof e&&(tw(e),r.query={perspective:Array.isArray(e)?e.join(","):e,...r.query},"previewDrafts"===e&&a&&(a=!1,ty())),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=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:tX(t,o,a)})),l=new _.c(t=>e(c,i.requester).subscribe(t));return r.signal?l.pipe((n=r.signal,t=>new _.c(e=>{let r=()=>e.error(function(t){if(tY)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)return void r();let o=t.subscribe(e);return n.addEventListener("abort",r),()=>{n.removeEventListener("abort",r),o.unsubscribe()}}))):l}function tH(t,e,r){return tz(t,e,r).pipe((0,V.p)(t=>"response"===t.type),(0,Y.T)(t=>t.body))}function tJ(t,e,r){let n=tl(t.config()),o=`/${e}/${n}`;return`/data${r?`${o}/${r}`:o}`.replace(/\/($|\?)/,"$1")}function tX(t,e,r=!1){let{url:n,cdnUrl:o}=t.config();return`${r?o:n}/${e.replace(/^\//,"")}`}let tY=!!globalThis.DOMException;class tV{#a;#u;
8constructor(t,e){this.#a=t,this.#u=e}upload(t,e,r){return tQ(this.#a,this.#u,t,e,r)}}class tG{#a;#u;constructor(t,e){this.#a=t,this.#u=e}upload(t,e,r){let n=tQ(this.#a,this.#u,t,e,r);return(0,B.s)(n.pipe((0,V.p)(t=>"response"===t.type),(0,Y.T)(t=>t.body.document)))}}function tQ(t,e,r,n,o={}){var i,s;if(-1===to.indexOf(r))throw Error(`Invalid asset type: ${r}. Must be one of ${to.join(", ")}`);let a=o.extract||void 0;a&&!a.length&&(a=["none"]);let u=tl(t.config()),c="image"===r?"images":"files",l=(i=o,s=n,!(typeof File>"u")&&s instanceof File?Object.assign({filename:!1===i.preserveFilename?void 0:s.name,contentType:s.type},i):i),{tag:f,label:h,title:p,description:d,creditLine:y,filename:g,source:b}=l,m={label:h,title:p,description:d,filename:g,meta:a,creditLine:y};return b&&(m.sourceId=b.id,m.sourceName=b.name,m.sourceUrl=b.url),tz(t,e,{tag:f,method:"POST",timeout:l.timeout||0,uri:`/assets/${c}/${u}`,headers:l.contentType?{"Content-Type":l.contentType}:{},query:m,body:n})}let tK=["includePreviousRevision","includeResult","includeMutations","visibility","effectFormat","tag"],tW={includeResult:!0};function tZ(t,e,n={}){let{url:o,token:i,withCredentials:s,requestTagPrefix:a}=this.config(),u=n.tag&&a?[a,n.tag].join("."):n.tag,c={...Object.keys(tW).concat(Object.keys(n)).reduce((t,e)=>(t[e]=typeof n[e]>"u"?tW[e]:n[e],t),{}),tag:u},l=tj({query:t,params:e,options:{tag:u,...tK.reduce((t,e)=>(typeof c[e]>"u"||(t[e]=c[e]),t),{})}}),f=`${o}${tJ(this,"listen",l)}`;if(f.length>14800)return new _.c(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 _.c(t=>{let e,n,o=!1,i=!1;function s(){o||(p&&t.next({type:"reconnect"}),o||e.readyState!==e.CLOSED||(l(),clearTimeout(n),n=setTimeout(g,100)))}function a(e){t.error(function(t){var e;if(t instanceof Error)return t;let r=t0(t);return r instanceof Error?r:Error((e=r).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 u(e){let r=t0(e);return r instanceof Error?t.error(r):t.next(r)}function c(){o=!0,l(),t.complete()}function l(){e&&(e.removeEventListener("error",s),e.removeEventListener("channelError",a),e.removeEventListener("disconnect",c),h.forEach(t=>e.removeEventListener(t,u)),e.close())}async function y(){let{default:t}=await r.e(3724).then(r.t.bind(r,63724,19));if(i)return;let e=new t(f,d);return e.addEventListener("error",s),e.addEventListener("channelError",a),e.addEventListener("disconnect",c),h.forEach(t=>e.addEventListener(t,u)),e}function g(){y().then(t=>{t&&(e=t,i&&l())}).catch(e=>{t.error(e),b()})}function b(){o=!0,l(),i=!0}return g(),b})}function t0(t){try{let e=t.data&&JSON.parse(t.data)||{};return Object.assign({type:t.type},e)}catch(t){return t}}let t1="2021-03-26";class t2{#a;constructor(t){this.#a=t}events({includeDrafts:t=!1,tag:e}={}){let{projectId:n,apiVersion:o,token:i,withCredentials:s,requestTagPrefix:a}=this.#a.config(),u=o.replace(/^v/,"");if("X"!==u&&u<t1)throw Error(`The live events API requires API version ${t1} or later. The current API version is ${u}. Please update your API version to use this feature.`);if(t&&!i&&!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.");if(t&&"X"!==u)throw Error("The live events API requires API version X when 'includeDrafts: true'. This API is experimental and may change or even be removed.");let c=tJ(this.#a,"live/events"),l=new URL(this.#a.getUrl(c,!1)),f=e&&a?[a,e].join("."):e;f&&l.searchParams.set("tag",f),t&&l.searchParams.set("includeDrafts","true");let h=["restart","message","welcome","reconnect"],p={};return t&&i&&(p.headers={Authorization:`Bearer ${i}`}),t&&s&&(p.withCredentials=!0),new _.c(t=>{let e,o,i=!1,s=!1;function a(r){if(!i){if("data"in r){let e=t3(r);t.error(Error(e.message,{cause:e}))}e.readyState===e.CLOSED&&(c(),clearTimeout(o),o=setTimeout(d,100))}}function u(e){let r=t3(e);return r instanceof Error?t.error(r):t.next(r)}function c(){if(e){for(let t of(e.removeEventListener("error",a),h))e.removeEventListener(t,u);e.close()}}async function f(){let t=typeof EventSource>"u"||p.headers||p.withCredentials?(await r.e(3724).then(r.t.bind(r,63724,19))).default:EventSource;if(s)return;try{if(await fetch(l,{method:"OPTIONS",mode:"cors",credentials:p.withCredentials?"include":"omit",headers:p.headers}),s)return}catch{throw new Z({projectId:n})}let e=new t(l.toString(),p);for(let t of(e.addEventListener("error",a),h))e.addEventListener(t,u);return e}function d(){f().then(t=>{t&&(e=t,s&&c())}).catch(e=>{t.error(e),y()})}function y(){i=!0,c(),s=!0}return d(),y})}}function t3(t){try{let e=t.data&&JSON.parse(t.data)||{};return{type:t.type,id:t.lastEventId,...e}}catch(t){return t}}class t6{#a;#u;
8constructor(t,e){this.#a=t,this.#u=e}create(t,e){return t8(this.#a,this.#u,"PUT",t,e)}edit(t,e){return t8(this.#a,this.#u,"PATCH",t,e)}delete(t){return t8(this.#a,this.#u,"DELETE",t)}list(){return tH(this.#a,this.#u,{uri:"/datasets",tag:null})}}class t5{#a;#u;constructor(t,e){this.#a=t,this.#u=e}create(t,e){return(0,B.s)(t8(this.#a,this.#u,"PUT",t,e))}edit(t,e){return(0,B.s)(t8(this.#a,this.#u,"PATCH",t,e))}delete(t){return(0,B.s)(t8(this.#a,this.#u,"DELETE",t))}list(){return(0,B.s)(tH(this.#a,this.#u,{uri:"/datasets",tag:null}))}}function t8(t,e,r,n,o){return ts(n),tH(t,e,{method:r,uri:`/datasets/${n}`,body:o,tag:null})}class t4{#a;#u;constructor(t,e){this.#a=t,this.#u=e}list(t){let e=t?.includeMembers===!1?"/projects?includeMembers=false":"/projects";return tH(this.#a,this.#u,{uri:e})}getById(t){return tH(this.#a,this.#u,{uri:`/projects/${t}`})}}class t9{#a;#u;constructor(t,e){this.#a=t,this.#u=e}list(t){let e=t?.includeMembers===!1?"/projects?includeMembers=false":"/projects";return(0,B.s)(tH(this.#a,this.#u,{uri:e}))}getById(t){return(0,B.s)(tH(this.#a,this.#u,{uri:`/projects/${t}`}))}}class t7{#a;#u;constructor(t,e){this.#a=t,this.#u=e}getById(t){return tH(this.#a,this.#u,{uri:`/users/${t}`})}}class et{#a;#u;constructor(t,e){this.#a=t,this.#u=e}getById(t){return(0,B.s)(tH(this.#a,this.#u,{uri:`/users/${t}`}))}}class ee{assets;datasets;live;projects;users;#c;#u;listen=tZ;constructor(t,e=tm){this.config(e),this.#u=t,this.assets=new tV(this,this.#u),this.datasets=new t6(this,this.#u),this.live=new t2(this),this.projects=new t4(this,this.#u),this.users=new t7(this,this.#u)}clone(){return new ee(this.#u,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=tE(t,this.#c||{}),this}withConfig(t){let e=this.config();return new ee(this.#u,{...e,...t,stega:{...e.stega||{},..."boolean"==typeof t?.stega?{enabled:t.stega}:t?.stega||{}}})}fetch(t,e,r){return t$(this,this.#u,this.#c.stega,t,e,r)}getDocument(t,e){return tP(this,this.#u,t,e)}getDocuments(t,e){return t_(this,this.#u,t,e)}create(t,e){return tM(this,this.#u,t,"create",e)}createIfNotExists(t,e){return tk(this,this.#u,t,e)}createOrReplace(t,e){return tB(this,this.#u,t,e)}delete(t,e){return tF(this,this.#u,t,e)}mutate(t,e){return tL(this,this.#u,t,e)}patch(t,e){return new tA(t,e,this)}transaction(t){return new tS(t,this)}action(t,e){return tN(this,this.#u,t,e)}request(t){return tH(this,this.#u,t)}getUrl(t,e){return tX(this,t,e)}getDataUrl(t,e){return tJ(this,t,e)}}class er{assets;datasets;live;projects;users;observable;#c;#u;listen=tZ;constructor(t,e=tm){this.config(e),this.#u=t,this.assets=new tG(this,this.#u),this.datasets=new t5(this,this.#u),this.live=new t2(this),this.projects=new t9(this,this.#u),this.users=new et(this,this.#u),this.observable=new ee(t,e)}clone(){return new er(this.#u,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=tE(t,this.#c||{}),this}withConfig(t){let e=this.config();return new er(this.#u,{...e,...t,stega:{...e.stega||{},..."boolean"==typeof t?.stega?{enabled:t.stega}:t?.stega||{}}})}fetch(t,e,r){return(0,B.s)(t$(this,this.#u,this.#c.stega,t,e,r))}getDocument(t,e){return(0,B.s)(tP(this,this.#u,t,e))}getDocuments(t,e){return(0,B.s)(t_(this,this.#u,t,e))}create(t,e){return(0,B.s)(tM(this,this.#u,t,"create",e))}createIfNotExists(t,e){return(0,B.s)(tk(this,this.#u,t,e))}createOrReplace(t,e){return(0,B.s)(tB(this,this.#u,t,e))}delete(t,e){return(0,B.s)(tF(this,this.#u,t,e))}mutate(t,e){return(0,B.s)(tL(this,this.#u,t,e))}patch(t,e){return new tT(t,e,this)}transaction(t){return new tI(t,this)}action(t,e){return(0,B.s)(tN(this,this.#u,t,e))}request(t){return(0,B.s)(tH(this,this.#u,t))}dataRequest(t,e,r){return(0,B.s)(tD(this,this.#u,t,e,r))}getUrl(t,e){return tX(this,t,e)}getDataUrl(t,e){return tJ(this,t,e)}}let en=function(t,e){let r=((t=[],e=b)=>(function t(e,r){let n=[],o=f.reduce((t,e)=>(t[e]=t[e]||[],t),{processOptions:[i],validateOptions:[u]});function s(t){let e,n=l.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<o[t].length&&(i=(0,o[t][e])(i,...r),!n||i);e++);return i},s=i("processOptions",t);i("validateOptions",s);let a={options:s,channels:n,applyMiddleware:i},u=n.request.subscribe(t=>{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(()=>{u(),e&&e.abort()});let c=i("onReturn",n,a);return c===n&&n.request.publish(a),c}return s.use=function(t){if(!t)throw Error("Tried to add middleware that resolved to fal
8sey 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 f.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))([P({shouldRetry:tr}),...t,te,{processOptions:t=>{let e=t.body;return!e||"function"==typeof e.pipe||A(e)||-1===R.indexOf(typeof e)&&!Array.isArray(e)&&!function(t){if(!1===T(t))return!1;let e=t.constructor;if(void 0===e)return!0;let r=e.prototype;return!1!==T(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"))}},tt,function(t={}){let e=t.implementation||I.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:_.c})]);return{requester:r,createClient:t=>new e((e,n)=>(n||r)({maxRedirects:0,maxRetries:t.maxRetries,retryDelay:t.retryDelay,...e}),t)}}([],er),eo=(en.requester,en.createClient)},77973:(t,e,r)=>{"use strict";r.d(e,{H:()=>i,_:()=>o});var n=r(49303);function o(t,e,r,n,o){return new i(t,e,r,n,o)}var i=function(t){function e(e,r,n,o,i,s){var a=t.call(this,e)||this;return a.onFinalize=i,a.shouldUnsubscribe=s,a._next=r?function(t){try{r(t)}catch(t){e.error(t)}}:t.prototype._next,a._error=o?function(t){try{o(t)}catch(t){e.error(t)}finally{this.unsubscribe()}}:t.prototype._error,a._complete=n?function(){try{n()}catch(t){e.error(t)}finally{this.unsubscribe()}}:t.prototype._complete,a}return(0,n.C6)(e,t),e.prototype.unsubscribe=function(){var e;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){var r=this.closed;t.prototype.unsubscribe.call(this),r||null==(e=this.onFinalize)||e.call(this)}},e}(r(47006).vU)},79619:(t,e,r)=>{"use strict";r.d(e,{N:()=>i,S:()=>o});var n=r(70418);function o(t){return(0,n.T)(null==t?void 0:t.lift)}function i(t){return function(e){if(o(e))return e.lift(function(e){try{return t(e,this)}catch(t){this.error(t)}});throw TypeError("Unable to lift unknown Observable type")}}},81852:(t,e)=>{e.read=function(t,e,r,n,o){var i,s,a=8*o-n-1,u=(1<<a)-1,c=u>>1,l=-7,f=r?o-1:0,h=r?-1:1,p=t[e+f];for(f+=h,i=p&(1<<-l)-1,p>>=-l,l+=a;l>0;i=256*i+t[e+f],f+=h,l-=8);for(s=i&(1<<-l)-1,i>>=-l,l+=n;l>0;s=256*s+t[e+f],f+=h,l-=8);if(0===i)i=1-c;else{if(i===u)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,a,u,c=8*i-o-1,l=(1<<c)-1,f=l>>1,h=5960464477539062e-23*(23===o),p=n?0:i-1,d=n?1:-1,y=+(e<0||0===e&&1/e<0);for(isNaN(e=Math.abs(e))||e===1/0?(a=+!!isNaN(e),s=l):(s=Math.floor(Math.log(e)/Math.LN2),e*(u=Math.pow(2,-s))<1&&(s--,u*=2),s+f>=1?e+=h/u:e+=h*Math.pow(2,1-f),e*u>=2&&(s++,u/=2),s+f>=l?(a=0,s=l):s+f>=1?(a=(e*u-1)*Math.pow(2,o),s+=f):(a=e*Math.pow(2,f-1)*Math.pow(2,o),s=0));o>=8;t[r+p]=255&a,p+=d,a/=256,o-=8);for(s=s<<o|a,c+=o;c>0;t[r+p]=255&s,p+=d,s/=256,c-=8);t[r+p-d]|=128*y}},84474:(t,e,r)=>{"use strict";function n(){}r.d(e,{l:()=>n})},85226:(t,e,r)=>{"use strict";r.d(e,{l:()=>i});var n=r(24355),o=r(70418);function i(t){return(0,o.T)(t[n.s])}},87953:(t,e,r)=>{"use strict";r.d(e,{J:()=>
8o});var n=r(12115);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),[])}},88536:(t,e,r)=>{"use strict";r.d(e,{Q:()=>s});var n=r(15940),o=r(79619),i=r(77973);function s(t,e){return void 0===e&&(e=0),(0,o.N)(function(r,o){r.subscribe((0,i._)(o,function(r){return(0,n.N)(o,t,function(){return o.next(r)},e)},function(){return(0,n.N)(o,t,function(){return o.complete()},e)},function(r){return(0,n.N)(o,t,function(){return o.error(r)},e)}))})}},89166:(t,e,r)=>{"use strict";r.d(e,{F:()=>o,m:()=>i});var n=r(10336);function o(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return i(t)}function i(t){return 0===t.length?n.D:1===t.length?t[0]:function(e){return t.reduce(function(t,e){return e(t)},e)}}},90240:(t,e,r)=>{"use strict";r.d(e,{Kn:()=>u,yU:()=>a,Uv:()=>c});var n=r(49303),o=r(70418),i=(0,r(15512).L)(function(t){return function(e){t(this),this.message=e?e.length+" errors occurred during unsubscription:\n"+e.map(function(t,e){return e+1+") "+t.toString()}).join("\n "):"",this.name="UnsubscriptionError",this.errors=e}}),s=r(71361),a=function(){var t;function e(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}return e.prototype.unsubscribe=function(){if(!this.closed){this.closed=!0;var t,e,r,s,a,u=this._parentage;if(u)if(this._parentage=null,Array.isArray(u))try{for(var c=(0,n.Ju)(u),f=c.next();!f.done;f=c.next())f.value.remove(this)}catch(e){t={error:e}}finally{try{f&&!f.done&&(e=c.return)&&e.call(c)}finally{if(t)throw t.error}}else u.remove(this);var h=this.initialTeardown;if((0,o.T)(h))try{h()}catch(t){a=t instanceof i?t.errors:[t]}var p=this._finalizers;if(p){this._finalizers=null;try{for(var d=(0,n.Ju)(p),y=d.next();!y.done;y=d.next()){var g=y.value;try{l(g)}catch(t){a=null!=a?a:[],t instanceof i?a=(0,n.fX)((0,n.fX)([],(0,n.zs)(a)),(0,n.zs)(t.errors)):a.push(t)}}}catch(t){r={error:t}}finally{try{y&&!y.done&&(s=d.return)&&s.call(d)}finally{if(r)throw r.error}}}if(a)throw new i(a)}},e.prototype.add=function(t){var r;if(t&&t!==this)if(this.closed)l(t);else{if(t instanceof e){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=null!=(r=this._finalizers)?r:[]).push(t)}},e.prototype._hasParent=function(t){var e=this._parentage;return e===t||Array.isArray(e)&&e.includes(t)},e.prototype._addParent=function(t){var e=this._parentage;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t},e.prototype._removeParent=function(t){var e=this._parentage;e===t?this._parentage=null:Array.isArray(e)&&(0,s.o)(e,t)},e.prototype.remove=function(t){var r=this._finalizers;r&&(0,s.o)(r,t),t instanceof e&&t._removeParent(this)},(t=new e).closed=!0,e.EMPTY=t,e}(),u=a.EMPTY;function c(t){return t instanceof a||t&&"closed"in t&&(0,o.T)(t.remove)&&(0,o.T)(t.add)&&(0,o.T)(t.unsubscribe)}function l(t){(0,o.T)(t)?t():t.unsubscribe()}},97561:(t,e,r)=>{"use strict";r.d(e,{p:()=>i});var n=r(79619),o=r(77973);function i(t,e){return(0,n.N)(function(r,n){var i=0;r.subscribe((0,o._)(n,function(r){return t.call(e,r,i++)&&n.next(r)}))})}},97993:(t,e,r)=>{"use strict";r.d(e,{H:()=>i});var n=r(237),o=r(38299);function i(t,e){return e?(0,n.c)(t,e):(0,o.Tg)(t)}}}]);
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.